Skip to content

Commit 66f6aa9

Browse files
committed
Updated with core changes.
1 parent e8fe86f commit 66f6aa9

File tree

9 files changed

+20
-20
lines changed

9 files changed

+20
-20
lines changed

packages/react-core/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -54,7 +54,7 @@
5454
"tslib": "^2.8.1"
5555
},
5656
"devDependencies": {
57-
"@patternfly/patternfly": "6.5.0-prerelease.12",
57+
"@patternfly/patternfly": "6.5.0-prerelease.14",
5858
"case-anything": "^3.1.2",
5959
"css": "^3.0.0",
6060
"fs-extra": "^11.3.0"
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { css } from '@patternfly/react-styles';
22
import styles from '@patternfly/react-styles/css/components/Card/card';
33

4-
export interface CardDescriptionProps {
4+
export interface CardSubtitleProps {
55
/** Content rendered inside the description. */
66
children?: React.ReactNode;
77
/** Additional classes added to the description. */
@@ -10,14 +10,14 @@ export interface CardDescriptionProps {
1010
id?: string;
1111
}
1212

13-
export const CardDescription: React.FunctionComponent<CardDescriptionProps> = ({
13+
export const CardSubtitle: React.FunctionComponent<CardSubtitleProps> = ({
1414
children = null,
1515
className = '',
1616
id = '',
1717
...props
18-
}: ModalBoxDescriptionProps) => (
19-
<div {...props} id={id} className={css(styles.cardDescription, className)}>
18+
}: CardSubtitleProps) => (
19+
<div {...props} id={id} className={css(styles.cardSubtitle, className)}>
2020
{children}
2121
</div>
2222
);
23-
CardDescription.displayName = 'CardDescription';
23+
CardSubtitle.displayName = 'CardSubtitle';
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,21 @@
11
import { render, screen } from '@testing-library/react';
2-
import { CardDescription } from '../CardDescription';
2+
import { CardSubtitle } from '../CardSubtitle';
33

4-
describe('CardDescription', () => {
4+
describe('CardSubtitle', () => {
55
test('renders with PatternFly Core styles', () => {
6-
const { asFragment } = render(<CardDescription>text</CardDescription>);
6+
const { asFragment } = render(<CardSubtitle>text</CardSubtitle>);
77
expect(asFragment()).toMatchSnapshot();
88
});
99

1010
test('className is added to the root element', () => {
11-
render(<CardDescription className="extra-class">text</CardDescription>);
11+
render(<CardSubtitle className="extra-class">text</CardSubtitle>);
1212
expect(screen.getByText('text')).toHaveClass('extra-class');
1313
});
1414

1515
test('extra props are spread to the root element', () => {
16-
const testId = 'card-description';
16+
const testId = 'card-subtitle';
1717

18-
render(<CardDescription data-testid={testId} />);
18+
render(<CardSubtitle data-testid={testId} />);
1919
expect(screen.getByTestId(testId)).toBeInTheDocument();
2020
});
2121
});

packages/react-core/src/components/Card/examples/Card.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -9,7 +9,7 @@ propComponents:
99
'CardHeaderActionsObject',
1010
'CardHeaderSelectableActionsObject',
1111
'CardTitle',
12-
'CardDescription',
12+
'CardSubtitle',
1313
'CardBody',
1414
'CardFooter',
1515
'CardExpandableContent'
@@ -27,7 +27,7 @@ import PlusIcon from '@patternfly/react-icons/dist/esm/icons/plus-icon';
2727

2828
### Basic cards
2929

30-
Basic cards typically have a `<CardTitle>`, `<CardDescription>`, `<CardBody>` and `<CardFooter>`. You may omit these components as needed, but it is recommended to at least include a `<CardBody>` to provide details about the card item.
30+
Basic cards typically have a `<CardTitle>`, `<CardSubtitle>`, `<CardBody>` and `<CardFooter>`. You may omit these components as needed, but it is recommended to at least include a `<CardBody>` to provide details about the card item.
3131

3232
```ts file='./CardBasic.tsx'
3333

packages/react-core/src/components/Card/examples/CardBasic.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,9 @@
1-
import { Card, CardTitle, CardDescription, CardBody, CardFooter } from '@patternfly/react-core';
1+
import { Card, CardTitle, CardSubtitle, CardBody, CardFooter } from '@patternfly/react-core';
22

33
export const CardBasic: React.FunctionComponent = () => (
44
<Card ouiaId="BasicCard">
55
<CardTitle>Title</CardTitle>
6-
<CardDescription>Description</CardDescription>
6+
<CardSubtitle>Subtitle</CardSubtitle>
77
<CardBody>Body</CardBody>
88
<CardFooter>Footer</CardFooter>
99
</Card>

packages/react-docs/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@
2323
"test:a11y": "patternfly-a11y --config patternfly-a11y.config"
2424
},
2525
"dependencies": {
26-
"@patternfly/patternfly": "6.5.0-prerelease.12",
26+
"@patternfly/patternfly": "6.5.0-prerelease.14",
2727
"@patternfly/react-charts": "workspace:^",
2828
"@patternfly/react-code-editor": "workspace:^",
2929
"@patternfly/react-core": "workspace:^",

packages/react-icons/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,7 +33,7 @@
3333
"@fortawesome/free-brands-svg-icons": "^5.15.4",
3434
"@fortawesome/free-regular-svg-icons": "^5.15.4",
3535
"@fortawesome/free-solid-svg-icons": "^5.15.4",
36-
"@patternfly/patternfly": "6.5.0-prerelease.12",
36+
"@patternfly/patternfly": "6.5.0-prerelease.14",
3737
"fs-extra": "^11.3.0",
3838
"tslib": "^2.8.1"
3939
},

packages/react-styles/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,7 @@
1919
"clean": "rimraf dist css"
2020
},
2121
"devDependencies": {
22-
"@patternfly/patternfly": "6.5.0-prerelease.12",
22+
"@patternfly/patternfly": "6.5.0-prerelease.14",
2323
"change-case": "^5.4.4",
2424
"fs-extra": "^11.3.0"
2525
},

packages/react-tokens/package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@
3030
},
3131
"devDependencies": {
3232
"@adobe/css-tools": "^4.4.4",
33-
"@patternfly/patternfly": "6.5.0-prerelease.12",
33+
"@patternfly/patternfly": "6.5.0-prerelease.14",
3434
"fs-extra": "^11.3.0"
3535
}
3636
}

0 commit comments

Comments
 (0)