@patternfly/react-core 5.0.0-alpha.1 → 5.0.0-alpha.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +8 -0
- package/dist/esm/components/Accordion/AccordionContent.js +2 -2
- package/dist/esm/components/Accordion/AccordionContent.js.map +1 -1
- package/dist/esm/components/Accordion/AccordionExpandableContentBody.d.ts +7 -0
- package/dist/esm/components/Accordion/AccordionExpandableContentBody.d.ts.map +1 -0
- package/dist/esm/components/Accordion/AccordionExpandableContentBody.js +6 -0
- package/dist/esm/components/Accordion/AccordionExpandableContentBody.js.map +1 -0
- package/dist/esm/components/Accordion/index.d.ts +1 -1
- package/dist/esm/components/Accordion/index.d.ts.map +1 -1
- package/dist/esm/components/Accordion/index.js +1 -1
- package/dist/esm/components/Accordion/index.js.map +1 -1
- package/dist/esm/components/Tabs/Tabs.d.ts +2 -4
- package/dist/esm/components/Tabs/Tabs.d.ts.map +1 -1
- package/dist/esm/components/Tabs/Tabs.js +3 -5
- package/dist/esm/components/Tabs/Tabs.js.map +1 -1
- package/dist/js/components/Accordion/AccordionContent.js +2 -2
- package/dist/js/components/Accordion/AccordionContent.js.map +1 -1
- package/dist/js/components/Accordion/AccordionExpandableContentBody.d.ts +7 -0
- package/dist/js/components/Accordion/AccordionExpandableContentBody.d.ts.map +1 -0
- package/dist/js/components/Accordion/AccordionExpandableContentBody.js +11 -0
- package/dist/js/components/Accordion/AccordionExpandableContentBody.js.map +1 -0
- package/dist/js/components/Accordion/index.d.ts +1 -1
- package/dist/js/components/Accordion/index.d.ts.map +1 -1
- package/dist/js/components/Accordion/index.js +1 -1
- package/dist/js/components/Accordion/index.js.map +1 -1
- package/dist/js/components/Tabs/Tabs.d.ts +2 -4
- package/dist/js/components/Tabs/Tabs.d.ts.map +1 -1
- package/dist/js/components/Tabs/Tabs.js +3 -5
- package/dist/js/components/Tabs/Tabs.js.map +1 -1
- package/dist/umd/react-core.min.js +1 -1
- package/package.json +2 -2
- package/src/components/Accordion/AccordionContent.tsx +2 -2
- package/src/components/Accordion/AccordionExpandableContentBody.tsx +13 -0
- package/src/components/Accordion/__tests__/AccordionContent.test.tsx +4 -4
- package/src/components/Accordion/__tests__/AccordionExpandedContentBody.test.tsx +5 -5
- package/src/components/Accordion/examples/Accordion.md +1 -1
- package/src/components/Accordion/examples/AccordionBordered.tsx +5 -5
- package/src/components/Accordion/index.ts +1 -1
- package/src/components/Tabs/Tabs.tsx +5 -9
- package/src/components/Tabs/__tests__/Tabs.test.tsx +23 -23
- package/src/demos/Tabs.md +0 -1
- package/dist/esm/components/Accordion/AccordionExpandedContentBody.d.ts +0 -7
- package/dist/esm/components/Accordion/AccordionExpandedContentBody.d.ts.map +0 -1
- package/dist/esm/components/Accordion/AccordionExpandedContentBody.js +0 -6
- package/dist/esm/components/Accordion/AccordionExpandedContentBody.js.map +0 -1
- package/dist/js/components/Accordion/AccordionExpandedContentBody.d.ts +0 -7
- package/dist/js/components/Accordion/AccordionExpandedContentBody.d.ts.map +0 -1
- package/dist/js/components/Accordion/AccordionExpandedContentBody.js +0 -11
- package/dist/js/components/Accordion/AccordionExpandedContentBody.js.map +0 -1
- package/src/components/Accordion/AccordionExpandedContentBody.tsx +0 -13
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@patternfly/react-core",
|
|
3
|
-
"version": "5.0.0-alpha.
|
|
3
|
+
"version": "5.0.0-alpha.3",
|
|
4
4
|
"description": "This library provides a set of common React components for use with the PatternFly reference implementation.",
|
|
5
5
|
"main": "dist/js/index.js",
|
|
6
6
|
"module": "dist/esm/index.js",
|
|
@@ -71,5 +71,5 @@
|
|
|
71
71
|
"react": "^16.8 || ^17 || ^18",
|
|
72
72
|
"react-dom": "^16.8 || ^17 || ^18"
|
|
73
73
|
},
|
|
74
|
-
"gitHead": "
|
|
74
|
+
"gitHead": "095f5b13df51b2fa9ffe73bee9e01e8613d54f06"
|
|
75
75
|
}
|
|
@@ -2,7 +2,7 @@ import * as React from 'react';
|
|
|
2
2
|
import { css } from '@patternfly/react-styles';
|
|
3
3
|
import styles from '@patternfly/react-styles/css/components/Accordion/accordion';
|
|
4
4
|
import { AccordionContext } from './AccordionContext';
|
|
5
|
-
import {
|
|
5
|
+
import { AccordionExpandableContentBody } from './AccordionExpandableContentBody';
|
|
6
6
|
|
|
7
7
|
export interface AccordionContentProps extends React.HTMLProps<HTMLDivElement> {
|
|
8
8
|
/** Content rendered inside the Accordion */
|
|
@@ -50,7 +50,7 @@ export const AccordionContent: React.FunctionComponent<AccordionContentProps> =
|
|
|
50
50
|
aria-label={ariaLabel}
|
|
51
51
|
{...props}
|
|
52
52
|
>
|
|
53
|
-
{isCustomContent ? children : <
|
|
53
|
+
{isCustomContent ? children : <AccordionExpandableContentBody>{children}</AccordionExpandableContentBody>}
|
|
54
54
|
</Container>
|
|
55
55
|
);
|
|
56
56
|
}}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import * as React from 'react';
|
|
2
|
+
import { css } from '@patternfly/react-styles';
|
|
3
|
+
import styles from '@patternfly/react-styles/css/components/Accordion/accordion';
|
|
4
|
+
|
|
5
|
+
export interface AccordionExpandableContentBodyProps {
|
|
6
|
+
/** Content rendered inside the accordion content body */
|
|
7
|
+
children?: React.ReactNode;
|
|
8
|
+
}
|
|
9
|
+
|
|
10
|
+
export const AccordionExpandableContentBody: React.FunctionComponent<AccordionExpandableContentBodyProps> = ({
|
|
11
|
+
children = null
|
|
12
|
+
}: AccordionExpandableContentBodyProps) => <div className={css(styles.accordionExpandableContentBody)}>{children}</div>;
|
|
13
|
+
AccordionExpandableContentBody.displayName = 'AccordionExpandableContentBody';
|
|
@@ -5,8 +5,8 @@ import { render, screen } from '@testing-library/react';
|
|
|
5
5
|
import { AccordionContent } from '../AccordionContent';
|
|
6
6
|
import { AccordionContext } from '../AccordionContext';
|
|
7
7
|
|
|
8
|
-
jest.mock('../
|
|
9
|
-
|
|
8
|
+
jest.mock('../AccordionExpandableContentBody', () => ({
|
|
9
|
+
AccordionExpandableContentBody: ({ children }) => <div aria-label="Expanded content body mock">{children}</div>
|
|
10
10
|
}));
|
|
11
11
|
|
|
12
12
|
test('Renders without children', () => {
|
|
@@ -29,7 +29,7 @@ test('Renders children', () => {
|
|
|
29
29
|
expect(screen.getByText('Test')).toBeVisible();
|
|
30
30
|
});
|
|
31
31
|
|
|
32
|
-
test('Renders with children wrapped in
|
|
32
|
+
test('Renders with children wrapped in AccordionExpandableContentBody by default', () => {
|
|
33
33
|
render(
|
|
34
34
|
<AccordionContext.Provider value={{ ContentContainer: 'h3' }}>
|
|
35
35
|
<AccordionContent>Test</AccordionContent>
|
|
@@ -39,7 +39,7 @@ test('Renders with children wrapped in AccordionExpandedContentBody by default',
|
|
|
39
39
|
expect(screen.getByText('Test')).toHaveAccessibleName('Expanded content body mock');
|
|
40
40
|
});
|
|
41
41
|
|
|
42
|
-
test('Does not render children wrapped in
|
|
42
|
+
test('Does not render children wrapped in AccordionExpandableContentBody when isCustomContent=true', () => {
|
|
43
43
|
render(
|
|
44
44
|
<AccordionContext.Provider value={{ ContentContainer: 'h3' }}>
|
|
45
45
|
<AccordionContent isCustomContent>Test</AccordionContent>
|
|
@@ -2,10 +2,10 @@ import React from 'react';
|
|
|
2
2
|
|
|
3
3
|
import { render, screen } from '@testing-library/react';
|
|
4
4
|
|
|
5
|
-
import {
|
|
5
|
+
import { AccordionExpandableContentBody } from '../AccordionExpandableContentBody';
|
|
6
6
|
|
|
7
7
|
test('Renders without children', () => {
|
|
8
|
-
const { asFragment } = render(<
|
|
8
|
+
const { asFragment } = render(<AccordionExpandableContentBody />);
|
|
9
9
|
|
|
10
10
|
/* a snapshot test is used here because this component isn't selectable via better screen queries without children
|
|
11
11
|
as it doesn't spread other props to its container
|
|
@@ -14,20 +14,20 @@ test('Renders without children', () => {
|
|
|
14
14
|
});
|
|
15
15
|
|
|
16
16
|
test('Renders children', () => {
|
|
17
|
-
render(<
|
|
17
|
+
render(<AccordionExpandableContentBody>Test</AccordionExpandableContentBody>);
|
|
18
18
|
|
|
19
19
|
expect(screen.getByText('Test')).toBeVisible();
|
|
20
20
|
});
|
|
21
21
|
|
|
22
22
|
test('Renders with class name pf-c-accordion__expandable-content-body', () => {
|
|
23
|
-
render(<
|
|
23
|
+
render(<AccordionExpandableContentBody>Test</AccordionExpandableContentBody>);
|
|
24
24
|
|
|
25
25
|
expect(screen.getByText('Test')).toHaveClass('pf-c-accordion__expandable-content-body');
|
|
26
26
|
});
|
|
27
27
|
|
|
28
28
|
test('Matches the snapshot', () => {
|
|
29
29
|
const { asFragment } = render(
|
|
30
|
-
<
|
|
30
|
+
<AccordionExpandableContentBody>Test</AccordionExpandableContentBody>
|
|
31
31
|
);
|
|
32
32
|
expect(asFragment()).toMatchSnapshot();
|
|
33
33
|
});
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
id: Accordion
|
|
3
3
|
section: components
|
|
4
4
|
cssPrefix: pf-c-accordion
|
|
5
|
-
propComponents: ['Accordion', 'AccordionItem', 'AccordionContent', 'AccordionToggle',
|
|
5
|
+
propComponents: ['Accordion', 'AccordionItem', 'AccordionContent', 'AccordionToggle', AccordionExpandableContentBody]
|
|
6
6
|
---
|
|
7
7
|
|
|
8
8
|
import ArrowRightIcon from '@patternfly/react-icons/dist/esm/icons/arrow-right-icon';
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
AccordionItem,
|
|
5
5
|
AccordionContent,
|
|
6
6
|
AccordionToggle,
|
|
7
|
-
|
|
7
|
+
AccordionExpandableContentBody,
|
|
8
8
|
Button,
|
|
9
9
|
Checkbox
|
|
10
10
|
} from '@patternfly/react-core';
|
|
@@ -88,7 +88,7 @@ export const AccordionBordered: React.FunctionComponent = () => {
|
|
|
88
88
|
Item four
|
|
89
89
|
</AccordionToggle>
|
|
90
90
|
<AccordionContent id="bordered-expand4" isHidden={expanded !== 'bordered-toggle4'} isCustomContent>
|
|
91
|
-
<
|
|
91
|
+
<AccordionExpandableContentBody>
|
|
92
92
|
Donec vel posuere orci. Phasellus quis tortor a ex hendrerit efficitur. Aliquam lacinia ligula pharetra,
|
|
93
93
|
sagittis ex ut, pellentesque diam. Vestibulum ante ipsum primis in faucibus orci luctus et ultrices
|
|
94
94
|
posuere cubilia Curae; Vestibulum ultricies nulla nibh. Etiam vel dui fermentum ligula ullamcorper
|
|
@@ -96,12 +96,12 @@ export const AccordionBordered: React.FunctionComponent = () => {
|
|
|
96
96
|
parturient montes, nascetur ridiculus mus. Mauris et velit neque. Donec ultricies condimentum mauris,
|
|
97
97
|
pellentesque imperdiet libero convallis convallis. Aliquam erat volutpat. Donec rutrum semper tempus.
|
|
98
98
|
Proin dictum imperdiet nibh, quis dapibus nulla. Integer sed tincidunt lectus, sit amet auctor eros.
|
|
99
|
-
</
|
|
100
|
-
<
|
|
99
|
+
</AccordionExpandableContentBody>
|
|
100
|
+
<AccordionExpandableContentBody>
|
|
101
101
|
<Button variant="link" size="lg" isInline>
|
|
102
102
|
Call to action <ArrowRightIcon />
|
|
103
103
|
</Button>
|
|
104
|
-
</
|
|
104
|
+
</AccordionExpandableContentBody>
|
|
105
105
|
</AccordionContent>
|
|
106
106
|
</AccordionItem>
|
|
107
107
|
<AccordionItem>
|
|
@@ -61,10 +61,8 @@ export interface TabsProps extends Omit<React.HTMLProps<HTMLElement | HTMLDivEle
|
|
|
61
61
|
isBox?: boolean;
|
|
62
62
|
/** Enables vertical tab styling */
|
|
63
63
|
isVertical?: boolean;
|
|
64
|
-
/**
|
|
65
|
-
|
|
66
|
-
/** Enables border bottom styling for secondary tabs */
|
|
67
|
-
hasSecondaryBorderBottom?: boolean;
|
|
64
|
+
/** Disables border bottom tab styling on tabs. Defaults to false. To remove the bottom border, set this prop to true. */
|
|
65
|
+
hasNoBorderBottom?: boolean;
|
|
68
66
|
/** Aria-label for the left scroll button */
|
|
69
67
|
leftScrollAriaLabel?: string;
|
|
70
68
|
/** Aria-label for the right scroll button */
|
|
@@ -177,7 +175,7 @@ export class Tabs extends React.Component<TabsProps, TabsState> {
|
|
|
177
175
|
isSecondary: false,
|
|
178
176
|
isVertical: false,
|
|
179
177
|
isBox: false,
|
|
180
|
-
|
|
178
|
+
hasNoBorderBottom: false,
|
|
181
179
|
leftScrollAriaLabel: 'Scroll left',
|
|
182
180
|
rightScrollAriaLabel: 'Scroll right',
|
|
183
181
|
component: TabsComponent.div,
|
|
@@ -375,9 +373,7 @@ export class Tabs extends React.Component<TabsProps, TabsState> {
|
|
|
375
373
|
isSecondary,
|
|
376
374
|
isVertical,
|
|
377
375
|
isBox,
|
|
378
|
-
|
|
379
|
-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
380
|
-
hasSecondaryBorderBottom,
|
|
376
|
+
hasNoBorderBottom,
|
|
381
377
|
leftScrollAriaLabel,
|
|
382
378
|
rightScrollAriaLabel,
|
|
383
379
|
'aria-label': ariaLabel,
|
|
@@ -460,7 +456,7 @@ export class Tabs extends React.Component<TabsProps, TabsState> {
|
|
|
460
456
|
isBox && styles.modifiers.box,
|
|
461
457
|
showScrollButtons && styles.modifiers.scrollable,
|
|
462
458
|
usePageInsets && styles.modifiers.pageInsets,
|
|
463
|
-
|
|
459
|
+
hasNoBorderBottom && styles.modifiers.noBorderBottom,
|
|
464
460
|
formatBreakpointMods(inset, styles),
|
|
465
461
|
variantStyle[variant],
|
|
466
462
|
hasOverflowTab && styles.modifiers.overflow,
|
|
@@ -357,7 +357,7 @@ test('should render box tabs of light variant', () => {
|
|
|
357
357
|
|
|
358
358
|
test('should render tabs with no bottom border', () => {
|
|
359
359
|
const { asFragment } = render(
|
|
360
|
-
<Tabs id="noBottomBorderTabs"
|
|
360
|
+
<Tabs id="noBottomBorderTabs" hasNoBorderBottom>
|
|
361
361
|
<Tab id="tab1" eventKey={0} title={<TabTitleText>"Tab item 1"</TabTitleText>}>
|
|
362
362
|
Tab 1 section
|
|
363
363
|
</Tab>
|
|
@@ -372,9 +372,9 @@ test('should render tabs with no bottom border', () => {
|
|
|
372
372
|
expect(asFragment()).toMatchSnapshot();
|
|
373
373
|
});
|
|
374
374
|
|
|
375
|
-
test('should
|
|
375
|
+
test('should render secondary tabs with no bottom border when passed hasNoBorderBottom', () => {
|
|
376
376
|
render(
|
|
377
|
-
<Tabs id="noBottomBorderTabs" aria-label="Secondary bottom border">
|
|
377
|
+
<Tabs isSecondary hasNoBorderBottom id="noBottomBorderTabs" aria-label="Secondary bottom border">
|
|
378
378
|
<Tab id="tab1" eventKey={0} title={<TabTitleText>"Tab item 1"</TabTitleText>}>
|
|
379
379
|
Tab 1 section
|
|
380
380
|
</Tab>
|
|
@@ -389,28 +389,28 @@ test('should not render tabs with secondary border bottom when not passed hasSec
|
|
|
389
389
|
|
|
390
390
|
const tabsContainer = screen.queryByLabelText('Secondary bottom border');
|
|
391
391
|
|
|
392
|
-
expect(tabsContainer).
|
|
392
|
+
expect(tabsContainer).toHaveClass('pf-m-no-border-bottom');
|
|
393
393
|
});
|
|
394
394
|
|
|
395
|
-
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
|
|
400
|
-
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
395
|
+
test('should render secondary tabs with border bottom', () => {
|
|
396
|
+
render(
|
|
397
|
+
<Tabs isSecondary id="bottomBorderTabs" aria-label="Secondary bottom border">
|
|
398
|
+
<Tab id="tab1" eventKey={0} title={<TabTitleText>"Tab item 1"</TabTitleText>}>
|
|
399
|
+
Tab 1 section
|
|
400
|
+
</Tab>
|
|
401
|
+
<Tab id="tab2" eventKey={1} title={<TabTitleText>"Tab item 2"</TabTitleText>}>
|
|
402
|
+
Tab 2 section
|
|
403
|
+
</Tab>
|
|
404
|
+
<Tab id="tab3" eventKey={2} title={<TabTitleText>"Tab item 3"</TabTitleText>}>
|
|
405
|
+
Tab 3 section
|
|
406
|
+
</Tab>
|
|
407
|
+
</Tabs>
|
|
408
|
+
);
|
|
409
|
+
|
|
410
|
+
const tabsContainer = screen.queryByLabelText('Secondary bottom border');
|
|
411
|
+
|
|
412
|
+
expect(tabsContainer).not.toHaveClass('pf-m-no-border-bottom');
|
|
413
|
+
});
|
|
414
414
|
|
|
415
415
|
test('should not render scroll buttons by default', () => {
|
|
416
416
|
render(
|
package/src/demos/Tabs.md
CHANGED
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
export interface AccordionExpandedContentBodyProps {
|
|
3
|
-
/** Content rendered inside the accordion content body */
|
|
4
|
-
children?: React.ReactNode;
|
|
5
|
-
}
|
|
6
|
-
export declare const AccordionExpandedContentBody: React.FunctionComponent<AccordionExpandedContentBodyProps>;
|
|
7
|
-
//# sourceMappingURL=AccordionExpandedContentBody.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"AccordionExpandedContentBody.d.ts","sourceRoot":"","sources":["../../../../src/components/Accordion/AccordionExpandedContentBody.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,MAAM,WAAW,iCAAiC;IAChD,0DAA0D;IAC1D,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC5B;AAED,eAAO,MAAM,4BAA4B,EAAE,KAAK,CAAC,iBAAiB,CAAC,iCAAiC,CAEiB,CAAC"}
|
|
@@ -1,6 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { css } from '@patternfly/react-styles';
|
|
3
|
-
import styles from '@patternfly/react-styles/css/components/Accordion/accordion';
|
|
4
|
-
export const AccordionExpandedContentBody = ({ children = null }) => React.createElement("div", { className: css(styles.accordionExpandableContentBody) }, children);
|
|
5
|
-
AccordionExpandedContentBody.displayName = 'AccordionExpandedContentBody';
|
|
6
|
-
//# sourceMappingURL=AccordionExpandedContentBody.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"AccordionExpandedContentBody.js","sourceRoot":"","sources":["../../../../src/components/Accordion/AccordionExpandedContentBody.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAAE,GAAG,EAAE,MAAM,0BAA0B,CAAC;AAC/C,OAAO,MAAM,MAAM,6DAA6D,CAAC;AAOjF,MAAM,CAAC,MAAM,4BAA4B,GAA+D,CAAC,EACvG,QAAQ,GAAG,IAAI,EACmB,EAAE,EAAE,CAAC,6BAAK,SAAS,EAAE,GAAG,CAAC,MAAM,CAAC,8BAA8B,CAAC,IAAG,QAAQ,CAAO,CAAC;AACtH,4BAA4B,CAAC,WAAW,GAAG,8BAA8B,CAAC"}
|
|
@@ -1,7 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
export interface AccordionExpandedContentBodyProps {
|
|
3
|
-
/** Content rendered inside the accordion content body */
|
|
4
|
-
children?: React.ReactNode;
|
|
5
|
-
}
|
|
6
|
-
export declare const AccordionExpandedContentBody: React.FunctionComponent<AccordionExpandedContentBodyProps>;
|
|
7
|
-
//# sourceMappingURL=AccordionExpandedContentBody.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"AccordionExpandedContentBody.d.ts","sourceRoot":"","sources":["../../../../src/components/Accordion/AccordionExpandedContentBody.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAI/B,MAAM,WAAW,iCAAiC;IAChD,0DAA0D;IAC1D,QAAQ,CAAC,EAAE,KAAK,CAAC,SAAS,CAAC;CAC5B;AAED,eAAO,MAAM,4BAA4B,EAAE,KAAK,CAAC,iBAAiB,CAAC,iCAAiC,CAEiB,CAAC"}
|
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
"use strict";
|
|
2
|
-
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.AccordionExpandedContentBody = void 0;
|
|
4
|
-
const tslib_1 = require("tslib");
|
|
5
|
-
const React = tslib_1.__importStar(require("react"));
|
|
6
|
-
const react_styles_1 = require("@patternfly/react-styles");
|
|
7
|
-
const accordion_1 = tslib_1.__importDefault(require("@patternfly/react-styles/css/components/Accordion/accordion"));
|
|
8
|
-
const AccordionExpandedContentBody = ({ children = null }) => React.createElement("div", { className: react_styles_1.css(accordion_1.default.accordionExpandableContentBody) }, children);
|
|
9
|
-
exports.AccordionExpandedContentBody = AccordionExpandedContentBody;
|
|
10
|
-
exports.AccordionExpandedContentBody.displayName = 'AccordionExpandedContentBody';
|
|
11
|
-
//# sourceMappingURL=AccordionExpandedContentBody.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"AccordionExpandedContentBody.js","sourceRoot":"","sources":["../../../../src/components/Accordion/AccordionExpandedContentBody.tsx"],"names":[],"mappings":";;;;AAAA,qDAA+B;AAC/B,2DAA+C;AAC/C,oHAAiF;AAO1E,MAAM,4BAA4B,GAA+D,CAAC,EACvG,QAAQ,GAAG,IAAI,EACmB,EAAE,EAAE,CAAC,6BAAK,SAAS,EAAE,kBAAG,CAAC,mBAAM,CAAC,8BAA8B,CAAC,IAAG,QAAQ,CAAO,CAAC;AAFzG,QAAA,4BAA4B,gCAE6E;AACtH,oCAA4B,CAAC,WAAW,GAAG,8BAA8B,CAAC"}
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
import * as React from 'react';
|
|
2
|
-
import { css } from '@patternfly/react-styles';
|
|
3
|
-
import styles from '@patternfly/react-styles/css/components/Accordion/accordion';
|
|
4
|
-
|
|
5
|
-
export interface AccordionExpandedContentBodyProps {
|
|
6
|
-
/** Content rendered inside the accordion content body */
|
|
7
|
-
children?: React.ReactNode;
|
|
8
|
-
}
|
|
9
|
-
|
|
10
|
-
export const AccordionExpandedContentBody: React.FunctionComponent<AccordionExpandedContentBodyProps> = ({
|
|
11
|
-
children = null
|
|
12
|
-
}: AccordionExpandedContentBodyProps) => <div className={css(styles.accordionExpandableContentBody)}>{children}</div>;
|
|
13
|
-
AccordionExpandedContentBody.displayName = 'AccordionExpandedContentBody';
|