@patternfly/react-core 5.3.0-prerelease.9 → 5.3.0
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 +99 -0
- package/README.md +1 -0
- package/components/package.json +1 -1
- package/deprecated/package.json +1 -1
- package/dist/dynamic/components/AboutModal/package.json +1 -1
- package/dist/dynamic/components/Accordion/package.json +1 -1
- package/dist/dynamic/components/ActionList/package.json +1 -1
- package/dist/dynamic/components/Alert/package.json +1 -1
- package/dist/dynamic/components/Avatar/package.json +1 -1
- package/dist/dynamic/components/BackToTop/package.json +1 -1
- package/dist/dynamic/components/Backdrop/package.json +1 -1
- package/dist/dynamic/components/BackgroundImage/package.json +1 -1
- package/dist/dynamic/components/Badge/package.json +1 -1
- package/dist/dynamic/components/Banner/package.json +1 -1
- package/dist/dynamic/components/Brand/package.json +1 -1
- package/dist/dynamic/components/Breadcrumb/package.json +1 -1
- package/dist/dynamic/components/Button/package.json +1 -1
- package/dist/dynamic/components/CalendarMonth/package.json +1 -1
- package/dist/dynamic/components/Card/package.json +1 -1
- package/dist/dynamic/components/Checkbox/package.json +1 -1
- package/dist/dynamic/components/Chip/package.json +1 -1
- package/dist/dynamic/components/ClipboardCopy/package.json +1 -1
- package/dist/dynamic/components/CodeBlock/package.json +1 -1
- package/dist/dynamic/components/DataList/package.json +1 -1
- package/dist/dynamic/components/DatePicker/package.json +1 -1
- package/dist/dynamic/components/DescriptionList/package.json +1 -1
- package/dist/dynamic/components/Divider/package.json +1 -1
- package/dist/dynamic/components/DragDrop/package.json +1 -1
- package/dist/dynamic/components/Drawer/package.json +1 -1
- package/dist/dynamic/components/Dropdown/package.json +1 -1
- package/dist/dynamic/components/DualListSelector/package.json +1 -1
- package/dist/dynamic/components/EmptyState/package.json +1 -1
- package/dist/dynamic/components/ExpandableSection/package.json +1 -1
- package/dist/dynamic/components/FileUpload/package.json +1 -1
- package/dist/dynamic/components/Form/package.json +1 -1
- package/dist/dynamic/components/FormSelect/package.json +1 -1
- package/dist/dynamic/components/HelperText/package.json +1 -1
- package/dist/dynamic/components/Hint/package.json +1 -1
- package/dist/dynamic/components/Icon/package.json +1 -1
- package/dist/dynamic/components/InputGroup/package.json +1 -1
- package/dist/dynamic/components/JumpLinks/package.json +1 -1
- package/dist/dynamic/components/Label/package.json +1 -1
- package/dist/dynamic/components/List/package.json +1 -1
- package/dist/dynamic/components/LoginPage/package.json +1 -1
- package/dist/dynamic/components/Masthead/package.json +1 -1
- package/dist/dynamic/components/Menu/package.json +1 -1
- package/dist/dynamic/components/MenuToggle/package.json +1 -1
- package/dist/dynamic/components/Modal/package.json +1 -1
- package/dist/dynamic/components/MultipleFileUpload/package.json +1 -1
- package/dist/dynamic/components/Nav/package.json +1 -1
- package/dist/dynamic/components/NotificationBadge/package.json +1 -1
- package/dist/dynamic/components/NotificationDrawer/package.json +1 -1
- package/dist/dynamic/components/NumberInput/package.json +1 -1
- package/dist/dynamic/components/OverflowMenu/package.json +1 -1
- package/dist/dynamic/components/Page/package.json +1 -1
- package/dist/dynamic/components/Pagination/package.json +1 -1
- package/dist/dynamic/components/Panel/package.json +1 -1
- package/dist/dynamic/components/Popover/package.json +1 -1
- package/dist/dynamic/components/Progress/package.json +1 -1
- package/dist/dynamic/components/ProgressStepper/package.json +1 -1
- package/dist/dynamic/components/Radio/package.json +1 -1
- package/dist/dynamic/components/SearchInput/package.json +1 -1
- package/dist/dynamic/components/Select/package.json +1 -1
- package/dist/dynamic/components/Sidebar/package.json +1 -1
- package/dist/dynamic/components/SimpleList/package.json +1 -1
- package/dist/dynamic/components/Skeleton/package.json +1 -1
- package/dist/dynamic/components/SkipToContent/package.json +1 -1
- package/dist/dynamic/components/Slider/package.json +1 -1
- package/dist/dynamic/components/Spinner/package.json +1 -1
- package/dist/dynamic/components/Switch/package.json +1 -1
- package/dist/dynamic/components/Tabs/package.json +1 -1
- package/dist/dynamic/components/Text/package.json +1 -1
- package/dist/dynamic/components/TextArea/package.json +1 -1
- package/dist/dynamic/components/TextInput/package.json +1 -1
- package/dist/dynamic/components/TextInputGroup/package.json +1 -1
- package/dist/dynamic/components/Tile/package.json +1 -1
- package/dist/dynamic/components/TimePicker/package.json +1 -1
- package/dist/dynamic/components/Timestamp/package.json +1 -1
- package/dist/dynamic/components/Title/package.json +1 -1
- package/dist/dynamic/components/ToggleGroup/package.json +1 -1
- package/dist/dynamic/components/Toolbar/package.json +1 -1
- package/dist/dynamic/components/Tooltip/package.json +1 -1
- package/dist/dynamic/components/TreeView/package.json +1 -1
- package/dist/dynamic/components/Truncate/package.json +1 -1
- package/dist/dynamic/components/Wizard/hooks/package.json +1 -1
- package/dist/dynamic/components/Wizard/package.json +1 -1
- package/dist/dynamic/deprecated/components/ApplicationLauncher/package.json +1 -1
- package/dist/dynamic/deprecated/components/ContextSelector/package.json +1 -1
- package/dist/dynamic/deprecated/components/Dropdown/package.json +1 -1
- package/dist/dynamic/deprecated/components/OptionsMenu/package.json +1 -1
- package/dist/dynamic/deprecated/components/PageHeader/package.json +1 -1
- package/dist/dynamic/deprecated/components/Select/package.json +1 -1
- package/dist/dynamic/deprecated/components/Wizard/package.json +1 -1
- package/dist/dynamic/deprecated/components/package.json +1 -1
- package/dist/dynamic/helpers/FocusTrap/FocusTrap/package.json +1 -1
- package/dist/dynamic/helpers/GenerateId/GenerateId/package.json +1 -1
- package/dist/dynamic/helpers/KeyboardHandler/package.json +1 -1
- package/dist/dynamic/helpers/OUIA/ouia/package.json +1 -1
- package/dist/dynamic/helpers/Popper/Popper/package.json +1 -1
- package/dist/dynamic/helpers/constants/package.json +1 -1
- package/dist/dynamic/helpers/datetimeUtils/package.json +1 -1
- package/dist/dynamic/helpers/favorites/package.json +1 -1
- package/dist/dynamic/helpers/fileUtils/package.json +1 -1
- package/dist/dynamic/helpers/htmlConstants/package.json +1 -1
- package/dist/dynamic/helpers/package.json +1 -1
- package/dist/dynamic/helpers/resizeObserver/package.json +1 -1
- package/dist/dynamic/helpers/typeUtils/package.json +1 -1
- package/dist/dynamic/helpers/useInterval/package.json +1 -1
- package/dist/dynamic/helpers/useIsomorphicLayout/package.json +1 -1
- package/dist/dynamic/helpers/useUnmountEffect/package.json +1 -1
- package/dist/dynamic/helpers/util/package.json +1 -1
- package/dist/dynamic/layouts/Bullseye/package.json +1 -1
- package/dist/dynamic/layouts/Flex/package.json +1 -1
- package/dist/dynamic/layouts/Gallery/package.json +1 -1
- package/dist/dynamic/layouts/Grid/package.json +1 -1
- package/dist/dynamic/layouts/Level/package.json +1 -1
- package/dist/dynamic/layouts/Split/package.json +1 -1
- package/dist/dynamic/layouts/Stack/package.json +1 -1
- package/dist/dynamic/next/components/DualListSelector/package.json +1 -1
- package/dist/dynamic/next/components/Modal/package.json +1 -1
- package/dist/dynamic/next/components/package.json +1 -1
- package/dist/dynamic/styles/package.json +1 -1
- package/dist/esm/components/CalendarMonth/CalendarMonth.d.ts.map +1 -1
- package/dist/esm/components/CalendarMonth/CalendarMonth.js +30 -12
- package/dist/esm/components/CalendarMonth/CalendarMonth.js.map +1 -1
- package/dist/esm/components/Card/Card.d.ts +13 -5
- package/dist/esm/components/Card/Card.d.ts.map +1 -1
- package/dist/esm/components/Card/Card.js +7 -3
- package/dist/esm/components/Card/Card.js.map +1 -1
- package/dist/esm/components/Card/CardHeader.d.ts +3 -1
- package/dist/esm/components/Card/CardHeader.d.ts.map +1 -1
- package/dist/esm/components/Card/CardHeader.js +10 -10
- package/dist/esm/components/Card/CardHeader.js.map +1 -1
- package/dist/esm/components/ClipboardCopy/ClipboardCopy.d.ts +2 -2
- package/dist/esm/components/ClipboardCopy/ClipboardCopy.d.ts.map +1 -1
- package/dist/esm/components/ClipboardCopy/ClipboardCopy.js +10 -2
- package/dist/esm/components/ClipboardCopy/ClipboardCopy.js.map +1 -1
- package/dist/esm/components/Dropdown/Dropdown.d.ts +4 -0
- package/dist/esm/components/Dropdown/Dropdown.d.ts.map +1 -1
- package/dist/esm/components/Dropdown/Dropdown.js +4 -3
- package/dist/esm/components/Dropdown/Dropdown.js.map +1 -1
- package/dist/esm/components/Label/Label.d.ts +2 -0
- package/dist/esm/components/Label/Label.d.ts.map +1 -1
- package/dist/esm/components/Label/Label.js +9 -8
- package/dist/esm/components/Label/Label.js.map +1 -1
- package/dist/esm/components/MenuToggle/MenuToggle.d.ts +9 -0
- package/dist/esm/components/MenuToggle/MenuToggle.d.ts.map +1 -1
- package/dist/esm/components/MenuToggle/MenuToggle.js +29 -3
- package/dist/esm/components/MenuToggle/MenuToggle.js.map +1 -1
- package/dist/esm/components/MenuToggle/MenuToggleCheckbox.js +2 -2
- package/dist/esm/components/MenuToggle/MenuToggleCheckbox.js.map +1 -1
- package/dist/esm/components/TextArea/TextArea.d.ts +0 -4
- package/dist/esm/components/TextArea/TextArea.d.ts.map +1 -1
- package/dist/esm/components/TextArea/TextArea.js.map +1 -1
- package/dist/esm/helpers/GenerateId/GenerateId.d.ts +5 -1
- package/dist/esm/helpers/GenerateId/GenerateId.d.ts.map +1 -1
- package/dist/esm/helpers/GenerateId/GenerateId.js +14 -2
- package/dist/esm/helpers/GenerateId/GenerateId.js.map +1 -1
- package/dist/js/components/CalendarMonth/CalendarMonth.d.ts.map +1 -1
- package/dist/js/components/CalendarMonth/CalendarMonth.js +30 -12
- package/dist/js/components/CalendarMonth/CalendarMonth.js.map +1 -1
- package/dist/js/components/Card/Card.d.ts +13 -5
- package/dist/js/components/Card/Card.d.ts.map +1 -1
- package/dist/js/components/Card/Card.js +7 -3
- package/dist/js/components/Card/Card.js.map +1 -1
- package/dist/js/components/Card/CardHeader.d.ts +3 -1
- package/dist/js/components/Card/CardHeader.d.ts.map +1 -1
- package/dist/js/components/Card/CardHeader.js +10 -10
- package/dist/js/components/Card/CardHeader.js.map +1 -1
- package/dist/js/components/ClipboardCopy/ClipboardCopy.d.ts +2 -2
- package/dist/js/components/ClipboardCopy/ClipboardCopy.d.ts.map +1 -1
- package/dist/js/components/ClipboardCopy/ClipboardCopy.js +10 -2
- package/dist/js/components/ClipboardCopy/ClipboardCopy.js.map +1 -1
- package/dist/js/components/Dropdown/Dropdown.d.ts +4 -0
- package/dist/js/components/Dropdown/Dropdown.d.ts.map +1 -1
- package/dist/js/components/Dropdown/Dropdown.js +4 -3
- package/dist/js/components/Dropdown/Dropdown.js.map +1 -1
- package/dist/js/components/Label/Label.d.ts +2 -0
- package/dist/js/components/Label/Label.d.ts.map +1 -1
- package/dist/js/components/Label/Label.js +9 -8
- package/dist/js/components/Label/Label.js.map +1 -1
- package/dist/js/components/MenuToggle/MenuToggle.d.ts +9 -0
- package/dist/js/components/MenuToggle/MenuToggle.d.ts.map +1 -1
- package/dist/js/components/MenuToggle/MenuToggle.js +30 -4
- package/dist/js/components/MenuToggle/MenuToggle.js.map +1 -1
- package/dist/js/components/MenuToggle/MenuToggleCheckbox.js +2 -2
- package/dist/js/components/MenuToggle/MenuToggleCheckbox.js.map +1 -1
- package/dist/js/components/TextArea/TextArea.d.ts +0 -4
- package/dist/js/components/TextArea/TextArea.d.ts.map +1 -1
- package/dist/js/components/TextArea/TextArea.js.map +1 -1
- package/dist/js/helpers/GenerateId/GenerateId.d.ts +5 -1
- package/dist/js/helpers/GenerateId/GenerateId.d.ts.map +1 -1
- package/dist/js/helpers/GenerateId/GenerateId.js +14 -2
- package/dist/js/helpers/GenerateId/GenerateId.js.map +1 -1
- package/dist/umd/react-core.min.js +1 -1
- package/helpers/package.json +1 -1
- package/layouts/package.json +1 -1
- package/next/package.json +1 -1
- package/package.json +6 -6
- package/src/components/CalendarMonth/CalendarMonth.tsx +38 -13
- package/src/components/Card/Card.tsx +24 -7
- package/src/components/Card/CardHeader.tsx +11 -10
- package/src/components/Card/examples/Card.md +11 -9
- package/src/components/Card/examples/CardClickableSelectable.tsx +11 -8
- package/src/components/Card/examples/CardSelectable.tsx +3 -6
- package/src/components/Card/examples/CardSingleSelectable.tsx +14 -6
- package/src/components/Chip/__tests__/ChipGroup.test.tsx +3 -1
- package/src/components/ClipboardCopy/ClipboardCopy.tsx +17 -3
- package/src/components/ClipboardCopy/__tests__/ClipboardCopy.test.tsx +2 -0
- package/src/components/ClipboardCopy/__tests__/__snapshots__/ClipboardCopy.test.tsx.snap +1 -1
- package/src/components/DragDrop/examples/DragDrop.md +1 -0
- package/src/components/Drawer/__tests__/Drawer.test.tsx +2 -0
- package/src/components/Drawer/__tests__/DrawerPanelContent.test.tsx +2 -0
- package/src/components/Drawer/__tests__/Generated/DrawerPanelContent.test.tsx +2 -0
- package/src/components/Drawer/__tests__/Generated/__snapshots__/DrawerPanelContent.test.tsx.snap +1 -1
- package/src/components/Drawer/__tests__/__snapshots__/Drawer.test.tsx.snap +8 -8
- package/src/components/Dropdown/Dropdown.tsx +12 -2
- package/src/components/Form/__tests__/FormFieldGroup.test.tsx +2 -0
- package/src/components/Form/__tests__/FormSection.test.tsx +2 -0
- package/src/components/Form/__tests__/__snapshots__/FormFieldGroup.test.tsx.snap +2 -2
- package/src/components/Form/__tests__/__snapshots__/FormSection.test.tsx.snap +2 -2
- package/src/components/Label/Label.tsx +16 -5
- package/src/components/Label/__tests__/LabelGroup.test.tsx +2 -0
- package/src/components/Label/__tests__/__snapshots__/LabelGroup.test.tsx.snap +8 -8
- package/src/components/Label/examples/LabelCompact.tsx +19 -1
- package/src/components/Label/examples/LabelFilled.tsx +106 -16
- package/src/components/Label/examples/LabelOutline.tsx +168 -16
- package/src/components/MenuToggle/MenuToggle.tsx +35 -0
- package/src/components/MenuToggle/MenuToggleCheckbox.tsx +2 -2
- package/src/components/MenuToggle/__tests__/MenuToggle.test.tsx +15 -0
- package/src/components/MenuToggle/examples/MenuToggle.md +39 -14
- package/src/components/MenuToggle/examples/MenuToggleSplitButtonCheckboxWithToggleText.tsx +51 -0
- package/src/components/MenuToggle/examples/MenuToggleStatus.tsx +20 -0
- package/src/components/MultipleFileUpload/__tests__/MultipleFileUpload.test.tsx +2 -0
- package/src/components/MultipleFileUpload/__tests__/MultipleFileUploadStatus.test.tsx +2 -0
- package/src/components/MultipleFileUpload/__tests__/__snapshots__/MultipleFileUploadStatus.test.tsx.snap +16 -16
- package/src/components/SearchInput/__tests__/SearchInput.test.tsx +1 -0
- package/src/components/SearchInput/__tests__/__snapshots__/SearchInput.test.tsx.snap +2 -2
- package/src/components/Select/examples/Select.md +30 -11
- package/src/components/Select/examples/SelectMultiTypeaheadCheckbox.tsx +6 -1
- package/src/components/Select/examples/SelectValidated.tsx +74 -0
- package/src/components/Tabs/__tests__/Tabs.test.tsx +2 -0
- package/src/components/Tabs/__tests__/__snapshots__/Tabs.test.tsx.snap +3 -3
- package/src/components/TextArea/TextArea.tsx +0 -4
- package/src/components/Toolbar/__tests__/Toolbar.test.tsx +2 -0
- package/src/components/Toolbar/__tests__/__snapshots__/Toolbar.test.tsx.snap +11 -11
- package/src/demos/AlertGroup.md +2 -0
- package/src/demos/BackToTop.md +1 -0
- package/src/demos/Banner.md +5 -4
- package/src/demos/CardView/CardView.md +2 -0
- package/src/demos/CardView/examples/CardView.tsx +1 -1
- package/src/demos/DataList/examples/DataListBasic.tsx +1 -1
- package/src/demos/DataList/examples/DataListExpandableControlInToolbar.tsx +1 -1
- package/src/demos/DataListDemo.md +1 -0
- package/src/demos/Filters/examples/FilterAttributeSearch.tsx +1 -1
- package/src/demos/Filters/examples/FilterCheckboxSelect.tsx +1 -1
- package/src/demos/Filters/examples/FilterFaceted.tsx +1 -1
- package/src/demos/Filters/examples/FilterMixedSelectGroup.tsx +1 -1
- package/src/demos/Filters/examples/FilterSameSelectGroup.tsx +1 -1
- package/src/demos/Filters/examples/FilterSearchInput.tsx +1 -1
- package/src/demos/Filters/examples/FilterSingleSelect.tsx +1 -1
- package/src/demos/JumpLinks.md +2 -1
- package/src/demos/Nav.md +2 -0
- package/src/demos/PrimaryDetail.md +1 -0
- package/src/demos/RTL/RTL.md +1 -1
- package/src/demos/RTL/examples/{PaginatedTable.jsx → PaginatedTable.tsx} +48 -22
- package/src/demos/Tabs.md +5 -2
- package/src/demos/Toolbar.md +1 -0
- package/src/demos/Wizard/WizardDemo.md +1 -0
- package/src/demos/examples/AlertGroup/AlertGroupToastWithNotificationDrawer.tsx +2 -2
- package/src/demos/examples/BackToTop/BackToTopNameDemo.tsx +1 -1
- package/src/demos/examples/Card/CardStatus.tsx +1 -1
- package/src/demos/examples/JumpLinks/JumpLinksWithDrawer.js +1 -1
- package/src/demos/examples/Nav/NavDefault.tsx +2 -2
- package/src/demos/examples/Nav/NavDrilldown.tsx +1 -1
- package/src/demos/examples/Nav/NavExpandable.tsx +2 -2
- package/src/demos/examples/Nav/NavGrouped.tsx +1 -1
- package/src/demos/examples/Nav/NavHorizontal.tsx +1 -1
- package/src/demos/examples/Nav/NavHorizontalWithSubnav.tsx +1 -1
- package/src/demos/examples/Nav/NavWithSubnav.tsx +2 -2
- package/src/demos/examples/Nav/deprecated/NavLight.tsx +1 -1
- package/src/demos/examples/Nav/deprecated/NavTertiary.tsx +2 -2
- package/src/demos/examples/PrimaryDetail/PrimaryDetailCardView.tsx +1 -1
- package/src/demos/examples/PrimaryDetail/PrimaryDetailContentPadding.tsx +1 -1
- package/src/demos/examples/PrimaryDetail/PrimaryDetailDataListInCard.tsx +1 -1
- package/src/demos/examples/PrimaryDetail/PrimaryDetailFullPage.tsx +1 -1
- package/src/demos/examples/PrimaryDetail/PrimaryDetailInlineModifier.tsx +1 -1
- package/src/demos/examples/PrimaryDetail/PrimaryDetailSimpleListInCard.tsx +1 -1
- package/src/demos/examples/Tabs/ModalTabs.tsx +1 -1
- package/src/demos/examples/Tabs/NestedTabs.tsx +1 -1
- package/src/demos/examples/Tabs/NestedUnindentedTabs.tsx +1 -1
- package/src/demos/examples/Tabs/TabsAndTable.tsx +2 -2
- package/src/demos/examples/Toolbar/ConsoleLogViewerToolbar.tsx +1 -1
- package/src/demos/examples/Wizard/InModal.tsx +1 -1
- package/src/demos/examples/Wizard/InPage.tsx +1 -1
- package/src/deprecated/components/Select/__tests__/Select.test.tsx +2 -0
- package/src/deprecated/components/Select/__tests__/__snapshots__/Select.test.tsx.snap +25 -25
- package/src/helpers/GenerateId/GenerateId.ts +17 -3
- package/src/helpers/GenerateId/__mocks__/GenerateId.ts +11 -0
- package/src/helpers/GenerateId/__tests__/GenerateId.test.tsx +3 -1
|
@@ -3,6 +3,8 @@ import { render } from '@testing-library/react';
|
|
|
3
3
|
import { MultipleFileUploadStatus } from '../MultipleFileUploadStatus';
|
|
4
4
|
import InProgressIcon from '@patternfly/react-icons/dist/esm/icons/in-progress-icon';
|
|
5
5
|
|
|
6
|
+
jest.mock('../../../helpers/GenerateId/GenerateId');
|
|
7
|
+
|
|
6
8
|
describe('MultipleFileUploadStatus', () => {
|
|
7
9
|
test('renders with expected class names', () => {
|
|
8
10
|
const { asFragment } = render(<MultipleFileUploadStatus>Foo</MultipleFileUploadStatus>);
|
|
@@ -9,10 +9,10 @@ exports[`MultipleFileUploadStatus renders custom class names 1`] = `
|
|
|
9
9
|
class="pf-v5-c-expandable-section pf-m-expanded"
|
|
10
10
|
>
|
|
11
11
|
<button
|
|
12
|
-
aria-controls="
|
|
12
|
+
aria-controls="generated-id-content"
|
|
13
13
|
aria-expanded="true"
|
|
14
14
|
class="pf-v5-c-expandable-section__toggle"
|
|
15
|
-
id="
|
|
15
|
+
id="generated-id-toggle"
|
|
16
16
|
type="button"
|
|
17
17
|
>
|
|
18
18
|
<span
|
|
@@ -48,9 +48,9 @@ exports[`MultipleFileUploadStatus renders custom class names 1`] = `
|
|
|
48
48
|
</span>
|
|
49
49
|
</button>
|
|
50
50
|
<div
|
|
51
|
-
aria-labelledby="
|
|
51
|
+
aria-labelledby="generated-id-toggle"
|
|
52
52
|
class="pf-v5-c-expandable-section__content"
|
|
53
|
-
id="
|
|
53
|
+
id="generated-id-content"
|
|
54
54
|
role="region"
|
|
55
55
|
>
|
|
56
56
|
<ul
|
|
@@ -74,10 +74,10 @@ exports[`MultipleFileUploadStatus renders status toggle icon 1`] = `
|
|
|
74
74
|
class="pf-v5-c-expandable-section pf-m-expanded"
|
|
75
75
|
>
|
|
76
76
|
<button
|
|
77
|
-
aria-controls="
|
|
77
|
+
aria-controls="generated-id-content"
|
|
78
78
|
aria-expanded="true"
|
|
79
79
|
class="pf-v5-c-expandable-section__toggle"
|
|
80
|
-
id="
|
|
80
|
+
id="generated-id-toggle"
|
|
81
81
|
type="button"
|
|
82
82
|
>
|
|
83
83
|
<span
|
|
@@ -127,9 +127,9 @@ exports[`MultipleFileUploadStatus renders status toggle icon 1`] = `
|
|
|
127
127
|
</span>
|
|
128
128
|
</button>
|
|
129
129
|
<div
|
|
130
|
-
aria-labelledby="
|
|
130
|
+
aria-labelledby="generated-id-toggle"
|
|
131
131
|
class="pf-v5-c-expandable-section__content"
|
|
132
|
-
id="
|
|
132
|
+
id="generated-id-content"
|
|
133
133
|
role="region"
|
|
134
134
|
>
|
|
135
135
|
<ul
|
|
@@ -153,10 +153,10 @@ exports[`MultipleFileUploadStatus renders status toggle text 1`] = `
|
|
|
153
153
|
class="pf-v5-c-expandable-section pf-m-expanded"
|
|
154
154
|
>
|
|
155
155
|
<button
|
|
156
|
-
aria-controls="
|
|
156
|
+
aria-controls="generated-id-content"
|
|
157
157
|
aria-expanded="true"
|
|
158
158
|
class="pf-v5-c-expandable-section__toggle"
|
|
159
|
-
id="
|
|
159
|
+
id="generated-id-toggle"
|
|
160
160
|
type="button"
|
|
161
161
|
>
|
|
162
162
|
<span
|
|
@@ -194,9 +194,9 @@ exports[`MultipleFileUploadStatus renders status toggle text 1`] = `
|
|
|
194
194
|
</span>
|
|
195
195
|
</button>
|
|
196
196
|
<div
|
|
197
|
-
aria-labelledby="
|
|
197
|
+
aria-labelledby="generated-id-toggle"
|
|
198
198
|
class="pf-v5-c-expandable-section__content"
|
|
199
|
-
id="
|
|
199
|
+
id="generated-id-content"
|
|
200
200
|
role="region"
|
|
201
201
|
>
|
|
202
202
|
<ul
|
|
@@ -220,10 +220,10 @@ exports[`MultipleFileUploadStatus renders with expected class names 1`] = `
|
|
|
220
220
|
class="pf-v5-c-expandable-section pf-m-expanded"
|
|
221
221
|
>
|
|
222
222
|
<button
|
|
223
|
-
aria-controls="
|
|
223
|
+
aria-controls="generated-id-content"
|
|
224
224
|
aria-expanded="true"
|
|
225
225
|
class="pf-v5-c-expandable-section__toggle"
|
|
226
|
-
id="
|
|
226
|
+
id="generated-id-toggle"
|
|
227
227
|
type="button"
|
|
228
228
|
>
|
|
229
229
|
<span
|
|
@@ -259,9 +259,9 @@ exports[`MultipleFileUploadStatus renders with expected class names 1`] = `
|
|
|
259
259
|
</span>
|
|
260
260
|
</button>
|
|
261
261
|
<div
|
|
262
|
-
aria-labelledby="
|
|
262
|
+
aria-labelledby="generated-id-toggle"
|
|
263
263
|
class="pf-v5-c-expandable-section__content"
|
|
264
|
-
id="
|
|
264
|
+
id="generated-id-content"
|
|
265
265
|
role="region"
|
|
266
266
|
>
|
|
267
267
|
<ul
|
|
@@ -11,6 +11,7 @@ import badgeStyles from '@patternfly/react-styles/css/components/Badge/badge';
|
|
|
11
11
|
import textInputGroupStyles from '@patternfly/react-styles/css/components/TextInputGroup/text-input-group';
|
|
12
12
|
|
|
13
13
|
jest.mock('../../../helpers/OUIA/ouia');
|
|
14
|
+
jest.mock('../../../helpers/GenerateId/GenerateId');
|
|
14
15
|
|
|
15
16
|
const props = {
|
|
16
17
|
onChange: jest.fn(),
|
|
@@ -364,7 +364,7 @@ exports[`SearchInput advanced search with custom attributes 1`] = `
|
|
|
364
364
|
>
|
|
365
365
|
<label
|
|
366
366
|
class="pf-v5-c-form__label"
|
|
367
|
-
for="
|
|
367
|
+
for="generated-id"
|
|
368
368
|
>
|
|
369
369
|
<span
|
|
370
370
|
class="pf-v5-c-form__label-text"
|
|
@@ -382,7 +382,7 @@ exports[`SearchInput advanced search with custom attributes 1`] = `
|
|
|
382
382
|
>
|
|
383
383
|
<input
|
|
384
384
|
aria-invalid="false"
|
|
385
|
-
id="
|
|
385
|
+
id="generated-id"
|
|
386
386
|
type="text"
|
|
387
387
|
value=""
|
|
388
388
|
/>
|
|
@@ -15,7 +15,10 @@ import BellIcon from '@patternfly/react-icons/dist/esm/icons/bell-icon';
|
|
|
15
15
|
|
|
16
16
|
Select builds off of the menu component suite to adapt commonly used properties and functions to create a select menu. See the [menu documentation](/components/menus/menu) for a full list of properties that may be used to further customize a select menu. View the [custom menu examples](/components/menus/custom-menus) to see examples of fully functional select menus.
|
|
17
17
|
|
|
18
|
+
For use cases that do not require a lot of customization, there are various template components available to use in the `@react-templates` package. These templates have a streamlined API and logic, making them easier to set up and use, but are limited in scope and flexibility. See the [templates page](/components/menus/select/react-templates) for details.
|
|
19
|
+
|
|
18
20
|
### Single select
|
|
21
|
+
|
|
19
22
|
To let users select a single item from a list, use a single select menu.
|
|
20
23
|
|
|
21
24
|
You can add multiple `<SelectOption>` components to build out a list of menu items. For each select option, pass a relevant option label to the `value` property.
|
|
@@ -28,30 +31,42 @@ To disable the select menu toggle, use the `isDisabled` property. In the followi
|
|
|
28
31
|
|
|
29
32
|
### Select option variants
|
|
30
33
|
|
|
31
|
-
The following example showcases different option variants and customizations that are commonly used in a select menu.
|
|
34
|
+
The following example showcases different option variants and customizations that are commonly used in a select menu.
|
|
32
35
|
|
|
33
|
-
To create these variants, you can pass different properties into a `<SelectOption>` component.
|
|
36
|
+
To create these variants, you can pass different properties into a `<SelectOption>` component.
|
|
34
37
|
|
|
35
|
-
This example provides examples of:
|
|
38
|
+
This example provides examples of:
|
|
36
39
|
|
|
37
40
|
- An option with a description, which is created by using the `description` property.
|
|
38
|
-
- An option with a link, which is created by passing a URL into the `to` property. For external links, use the `isExternalLink` property so that the option is styled with an outbound link icon.
|
|
39
|
-
- An option with an icon, which is created by using the `icon` property.
|
|
40
|
-
- An option that is disabled by using the `isDisabled` property.
|
|
41
|
+
- An option with a link, which is created by passing a URL into the `to` property. For external links, use the `isExternalLink` property so that the option is styled with an outbound link icon.
|
|
42
|
+
- An option with an icon, which is created by using the `icon` property.
|
|
43
|
+
- An option that is disabled by using the `isDisabled` property.
|
|
41
44
|
|
|
42
45
|
```ts file="./SelectOptionVariations.tsx"
|
|
43
46
|
|
|
44
47
|
```
|
|
45
48
|
|
|
46
49
|
### With grouped items
|
|
50
|
+
|
|
47
51
|
To group related select options together, use 1 or more `<SelectGroup>` components and title each group using the `label` property.
|
|
48
52
|
|
|
49
53
|
```ts file="./SelectGrouped.tsx"
|
|
50
54
|
|
|
51
55
|
```
|
|
52
56
|
|
|
57
|
+
### With validation
|
|
58
|
+
|
|
59
|
+
To create a toggle with a status, pass in `status` to the `MenuToggle`. The default icon associated with each status may be overridden by using the `statusIcon` property.
|
|
60
|
+
|
|
61
|
+
When the status value is "warning" or "danger", you must include helper text that conveys what is causing the warning/error.
|
|
62
|
+
|
|
63
|
+
```ts isBeta file="./SelectValidated.tsx"
|
|
64
|
+
|
|
65
|
+
```
|
|
66
|
+
|
|
53
67
|
### Checkbox select
|
|
54
|
-
|
|
68
|
+
|
|
69
|
+
To let users select multiple list options via checkbox input, use a checkbox select.
|
|
55
70
|
|
|
56
71
|
To create a checkbox select, pass `role="menu"` to the `<Select>`, and `hasCheckbox` into each `<SelectOption>` component. To indicate that an option is selected, use the `isSelected` property.
|
|
57
72
|
|
|
@@ -62,6 +77,7 @@ By default, the menu toggle will display a badge to indicate the number of items
|
|
|
62
77
|
```
|
|
63
78
|
|
|
64
79
|
### Typeahead
|
|
80
|
+
|
|
65
81
|
Typeahead is a select variant that replaces the typical button toggle for opening the select menu with a text input and button toggle combo. As a user enters characters into the text input, the menu options will be filtered to match.
|
|
66
82
|
|
|
67
83
|
To make a typeahead, pass `variant=typeahead` into the `<MenuToggle>` component and link an `onClick` function to the `<TextInputGroupMain>` component.
|
|
@@ -71,7 +87,8 @@ To make a typeahead, pass `variant=typeahead` into the `<MenuToggle>` component
|
|
|
71
87
|
```
|
|
72
88
|
|
|
73
89
|
### Typeahead with create option
|
|
74
|
-
|
|
90
|
+
|
|
91
|
+
If a user enters a value into a typeahead select menu that does not exist, you can allow them to create an option of that value.
|
|
75
92
|
|
|
76
93
|
To enable the creation ability, pass a predetermined `value` into a `<SelectOption>` component. You can use the `placeholder` property to change the default text shown in the text input.
|
|
77
94
|
|
|
@@ -82,6 +99,7 @@ The following example outlines the code implementation required to create a work
|
|
|
82
99
|
```
|
|
83
100
|
|
|
84
101
|
### Multiple typeahead with chips
|
|
102
|
+
|
|
85
103
|
A multiple typeahead can be used to allow users to select multiple options from a list. Additionally, you can render a chip group to be placed in the select toggle.
|
|
86
104
|
|
|
87
105
|
When more items than the allowed limit are selected, overflowing items will be hidden under a "more" button. The following example hides items after more than 3 are selected. To show hidden items, select the “more” button. Select "show less" to hide extra items again.
|
|
@@ -91,6 +109,7 @@ When more items than the allowed limit are selected, overflowing items will be h
|
|
|
91
109
|
```
|
|
92
110
|
|
|
93
111
|
### Multiple typeahead with create option
|
|
112
|
+
|
|
94
113
|
If the text that is entered into a typeahead doesn't match a menu item, users can choose to create a new option that matches the text input. You can also combine this create functionality with a chip group to display created items as chips."
|
|
95
114
|
|
|
96
115
|
```ts file="./SelectMultiTypeaheadCreatable.tsx"
|
|
@@ -98,13 +117,14 @@ If the text that is entered into a typeahead doesn't match a menu item, users ca
|
|
|
98
117
|
```
|
|
99
118
|
|
|
100
119
|
### Multiple typeahead with checkboxes
|
|
120
|
+
|
|
101
121
|
By default, a multiple typeahead select allows you to select multiple menu items, placing a checkmark beside selected items. Like basic checkbox select menus, you can add checkboxes to your menu items. This approach may be more accurate and comprehensive for more complex menu scenarios like filtering.
|
|
102
122
|
|
|
103
123
|
```ts file="./SelectMultiTypeaheadCheckbox.tsx"
|
|
104
124
|
|
|
105
125
|
```
|
|
106
126
|
|
|
107
|
-
### With view more
|
|
127
|
+
### With view more
|
|
108
128
|
|
|
109
129
|
To reduce the processing load for long select lists, you can add a "View more" action to load additional items.
|
|
110
130
|
|
|
@@ -118,7 +138,6 @@ The following example shows 3 items before the "View more" link, but you can adj
|
|
|
118
138
|
|
|
119
139
|
You can add a `<MenuFooter>` component to a select menu to hold additional actions that users can take on menu items, through elements such as link buttons. A footer will be placed beneath a divider at the end of the select menu.
|
|
120
140
|
|
|
121
|
-
|
|
122
141
|
```ts file="./SelectFooter.tsx"
|
|
123
142
|
|
|
124
|
-
```
|
|
143
|
+
```
|
|
@@ -44,7 +44,12 @@ export const SelectMultiTypeaheadCheckbox: React.FunctionComponent = () => {
|
|
|
44
44
|
// When no options are found after filtering, display 'No results found'
|
|
45
45
|
if (!newSelectOptions.length) {
|
|
46
46
|
newSelectOptions = [
|
|
47
|
-
{
|
|
47
|
+
{
|
|
48
|
+
isDisabled: false,
|
|
49
|
+
children: `No results found for "${inputValue}"`,
|
|
50
|
+
value: 'no results',
|
|
51
|
+
hasCheckbox: false
|
|
52
|
+
}
|
|
48
53
|
];
|
|
49
54
|
}
|
|
50
55
|
|
|
@@ -0,0 +1,74 @@
|
|
|
1
|
+
import React from 'react';
|
|
2
|
+
import {
|
|
3
|
+
Select,
|
|
4
|
+
SelectOption,
|
|
5
|
+
SelectList,
|
|
6
|
+
MenuToggle,
|
|
7
|
+
MenuToggleElement,
|
|
8
|
+
MenuToggleStatus,
|
|
9
|
+
HelperText,
|
|
10
|
+
HelperTextItem
|
|
11
|
+
} from '@patternfly/react-core';
|
|
12
|
+
|
|
13
|
+
export const SelectValidated: React.FunctionComponent = () => {
|
|
14
|
+
const [isOpen, setIsOpen] = React.useState(false);
|
|
15
|
+
const [selected, setSelected] = React.useState<string>('Select a value');
|
|
16
|
+
const [status, setStatus] = React.useState<MenuToggleStatus>();
|
|
17
|
+
|
|
18
|
+
const onToggleClick = () => {
|
|
19
|
+
setIsOpen(!isOpen);
|
|
20
|
+
};
|
|
21
|
+
|
|
22
|
+
const onSelect = (_event: React.MouseEvent<Element, MouseEvent> | undefined, value: string | number | undefined) => {
|
|
23
|
+
// eslint-disable-next-line no-console
|
|
24
|
+
console.log('selected', value);
|
|
25
|
+
|
|
26
|
+
setSelected(value as string);
|
|
27
|
+
setStatus((value as string).toLowerCase() as MenuToggleStatus);
|
|
28
|
+
setIsOpen(false);
|
|
29
|
+
};
|
|
30
|
+
|
|
31
|
+
const toggle = (toggleRef: React.Ref<MenuToggleElement>) => (
|
|
32
|
+
<MenuToggle
|
|
33
|
+
ref={toggleRef}
|
|
34
|
+
onClick={onToggleClick}
|
|
35
|
+
isExpanded={isOpen}
|
|
36
|
+
style={
|
|
37
|
+
{
|
|
38
|
+
width: '200px'
|
|
39
|
+
} as React.CSSProperties
|
|
40
|
+
}
|
|
41
|
+
status={status}
|
|
42
|
+
>
|
|
43
|
+
{selected}
|
|
44
|
+
</MenuToggle>
|
|
45
|
+
);
|
|
46
|
+
|
|
47
|
+
return (
|
|
48
|
+
<React.Fragment>
|
|
49
|
+
<Select
|
|
50
|
+
id="single-select"
|
|
51
|
+
isOpen={isOpen}
|
|
52
|
+
selected={selected}
|
|
53
|
+
onSelect={onSelect}
|
|
54
|
+
onOpenChange={(isOpen) => setIsOpen(isOpen)}
|
|
55
|
+
toggle={toggle}
|
|
56
|
+
shouldFocusToggleOnSelect
|
|
57
|
+
>
|
|
58
|
+
<SelectList>
|
|
59
|
+
<SelectOption value="Success">Success</SelectOption>
|
|
60
|
+
<SelectOption value="Warning">Warning</SelectOption>
|
|
61
|
+
<SelectOption value="Danger">Danger</SelectOption>
|
|
62
|
+
</SelectList>
|
|
63
|
+
</Select>
|
|
64
|
+
{(status === MenuToggleStatus.warning || status === MenuToggleStatus.danger) && (
|
|
65
|
+
<HelperText isLiveRegion>
|
|
66
|
+
<HelperTextItem variant={status === MenuToggleStatus.warning ? 'warning' : 'error'}>
|
|
67
|
+
{status === MenuToggleStatus.warning && 'Warning text that explains the issue.'}
|
|
68
|
+
{status === MenuToggleStatus.danger && 'Danger text that explains the issue.'}
|
|
69
|
+
</HelperTextItem>
|
|
70
|
+
</HelperText>
|
|
71
|
+
)}
|
|
72
|
+
</React.Fragment>
|
|
73
|
+
);
|
|
74
|
+
};
|
|
@@ -7,6 +7,8 @@ import { TabTitleIcon } from '../TabTitleIcon';
|
|
|
7
7
|
import { TabContent } from '../TabContent';
|
|
8
8
|
import { TabContentBody } from '../TabContentBody';
|
|
9
9
|
|
|
10
|
+
jest.mock('../../../helpers/GenerateId/GenerateId');
|
|
11
|
+
|
|
10
12
|
test('should render simple tabs', () => {
|
|
11
13
|
const { asFragment } = render(
|
|
12
14
|
<Tabs id="simpleTabs">
|
|
@@ -408,12 +408,12 @@ exports[`should render expandable vertical tabs 1`] = `
|
|
|
408
408
|
>
|
|
409
409
|
<button
|
|
410
410
|
aria-disabled="false"
|
|
411
|
-
aria-labelledby="
|
|
411
|
+
aria-labelledby="generated-id-text generated-id-button"
|
|
412
412
|
class="pf-v5-c-button pf-m-plain"
|
|
413
413
|
data-ouia-component-id="OUIA-Generated-Button-plain-3"
|
|
414
414
|
data-ouia-component-type="PF5/Button"
|
|
415
415
|
data-ouia-safe="true"
|
|
416
|
-
id="
|
|
416
|
+
id="generated-id-button"
|
|
417
417
|
type="button"
|
|
418
418
|
>
|
|
419
419
|
<span
|
|
@@ -436,7 +436,7 @@ exports[`should render expandable vertical tabs 1`] = `
|
|
|
436
436
|
</span>
|
|
437
437
|
<span
|
|
438
438
|
class="pf-v5-c-tabs__toggle-text"
|
|
439
|
-
id="
|
|
439
|
+
id="generated-id-text"
|
|
440
440
|
>
|
|
441
441
|
toggle
|
|
442
442
|
</span>
|
|
@@ -36,10 +36,6 @@ export interface TextAreaProps extends Omit<HTMLProps<HTMLTextAreaElement>, 'onC
|
|
|
36
36
|
value?: string | number;
|
|
37
37
|
/** A callback for when the text area value changes. */
|
|
38
38
|
onChange?: (event: React.ChangeEvent<HTMLTextAreaElement>, value: string) => void;
|
|
39
|
-
/** Callback function when text area is focused */
|
|
40
|
-
onFocus?: (event?: React.FocusEvent<HTMLTextAreaElement>) => void;
|
|
41
|
-
/** Callback function when text area is blurred (focus leaves) */
|
|
42
|
-
onBlur?: (event?: React.FocusEvent<HTMLTextAreaElement>) => void;
|
|
43
39
|
/** Sets the orientation to limit the resize to */
|
|
44
40
|
resizeOrientation?: 'horizontal' | 'vertical' | 'both';
|
|
45
41
|
/** Custom flag to show that the text area requires an associated id or aria-label. */
|
|
@@ -10,6 +10,8 @@ import { ToolbarFilter } from '../ToolbarFilter';
|
|
|
10
10
|
import { ToolbarGroup } from '../ToolbarGroup';
|
|
11
11
|
import { Button } from '../../Button/Button';
|
|
12
12
|
|
|
13
|
+
jest.mock('../../../helpers/GenerateId/GenerateId');
|
|
14
|
+
|
|
13
15
|
describe('Toolbar', () => {
|
|
14
16
|
it('should render inset', () => {
|
|
15
17
|
const items = (
|
|
@@ -103,7 +103,7 @@ exports[`Toolbar should render with custom chip content 1`] = `
|
|
|
103
103
|
class="pf-v5-c-toolbar__item pf-m-chip-group"
|
|
104
104
|
>
|
|
105
105
|
<div
|
|
106
|
-
aria-labelledby="
|
|
106
|
+
aria-labelledby="generated-id"
|
|
107
107
|
class="pf-v5-c-chip-group pf-m-category"
|
|
108
108
|
data-ouia-component-type="PF5/ChipGroup"
|
|
109
109
|
data-ouia-safe="true"
|
|
@@ -114,12 +114,12 @@ exports[`Toolbar should render with custom chip content 1`] = `
|
|
|
114
114
|
>
|
|
115
115
|
<span
|
|
116
116
|
class="pf-v5-c-chip-group__label"
|
|
117
|
-
id="
|
|
117
|
+
id="generated-id"
|
|
118
118
|
>
|
|
119
119
|
Status
|
|
120
120
|
</span>
|
|
121
121
|
<ul
|
|
122
|
-
aria-labelledby="
|
|
122
|
+
aria-labelledby="generated-id"
|
|
123
123
|
class="pf-v5-c-chip-group__list"
|
|
124
124
|
role="list"
|
|
125
125
|
>
|
|
@@ -137,7 +137,7 @@ exports[`Toolbar should render with custom chip content 1`] = `
|
|
|
137
137
|
>
|
|
138
138
|
<span
|
|
139
139
|
class="pf-v5-c-chip__text"
|
|
140
|
-
id="
|
|
140
|
+
id="generated-id"
|
|
141
141
|
>
|
|
142
142
|
New
|
|
143
143
|
</span>
|
|
@@ -148,12 +148,12 @@ exports[`Toolbar should render with custom chip content 1`] = `
|
|
|
148
148
|
<button
|
|
149
149
|
aria-disabled="false"
|
|
150
150
|
aria-label="close"
|
|
151
|
-
aria-labelledby="
|
|
151
|
+
aria-labelledby="remove_generated-id generated-id"
|
|
152
152
|
class="pf-v5-c-button pf-m-plain"
|
|
153
153
|
data-ouia-component-id="close"
|
|
154
154
|
data-ouia-component-type="PF5/Button"
|
|
155
155
|
data-ouia-safe="true"
|
|
156
|
-
id="
|
|
156
|
+
id="remove_generated-id"
|
|
157
157
|
type="button"
|
|
158
158
|
>
|
|
159
159
|
<svg
|
|
@@ -187,7 +187,7 @@ exports[`Toolbar should render with custom chip content 1`] = `
|
|
|
187
187
|
>
|
|
188
188
|
<span
|
|
189
189
|
class="pf-v5-c-chip__text"
|
|
190
|
-
id="
|
|
190
|
+
id="generated-id"
|
|
191
191
|
>
|
|
192
192
|
Pending
|
|
193
193
|
</span>
|
|
@@ -198,12 +198,12 @@ exports[`Toolbar should render with custom chip content 1`] = `
|
|
|
198
198
|
<button
|
|
199
199
|
aria-disabled="false"
|
|
200
200
|
aria-label="close"
|
|
201
|
-
aria-labelledby="
|
|
201
|
+
aria-labelledby="remove_generated-id generated-id"
|
|
202
202
|
class="pf-v5-c-button pf-m-plain"
|
|
203
203
|
data-ouia-component-id="close"
|
|
204
204
|
data-ouia-component-type="PF5/Button"
|
|
205
205
|
data-ouia-safe="true"
|
|
206
|
-
id="
|
|
206
|
+
id="remove_generated-id"
|
|
207
207
|
type="button"
|
|
208
208
|
>
|
|
209
209
|
<svg
|
|
@@ -231,12 +231,12 @@ exports[`Toolbar should render with custom chip content 1`] = `
|
|
|
231
231
|
<button
|
|
232
232
|
aria-disabled="false"
|
|
233
233
|
aria-label="Close chip group"
|
|
234
|
-
aria-labelledby="
|
|
234
|
+
aria-labelledby="remove_group_generated-id generated-id"
|
|
235
235
|
class="pf-v5-c-button pf-m-plain"
|
|
236
236
|
data-ouia-component-id="Close chip group"
|
|
237
237
|
data-ouia-component-type="PF5/Button"
|
|
238
238
|
data-ouia-safe="true"
|
|
239
|
-
id="
|
|
239
|
+
id="remove_group_generated-id"
|
|
240
240
|
type="button"
|
|
241
241
|
>
|
|
242
242
|
<svg
|
package/src/demos/AlertGroup.md
CHANGED
|
@@ -6,6 +6,8 @@ section: components
|
|
|
6
6
|
import { useEffect } from 'react';
|
|
7
7
|
import SearchIcon from '@patternfly/react-icons/dist/js/icons/search-icon';
|
|
8
8
|
import EllipsisVIcon from '@patternfly/react-icons/dist/esm/icons/ellipsis-v-icon';
|
|
9
|
+
import { DashboardWrapper } from '@patternfly/react-core/dist/js/demos/DashboardWrapper';
|
|
10
|
+
import { DashboardHeader } from '@patternfly/react-core/dist/js/demos/DashboardHeader';
|
|
9
11
|
|
|
10
12
|
## Demos
|
|
11
13
|
|
package/src/demos/BackToTop.md
CHANGED
package/src/demos/Banner.md
CHANGED
|
@@ -5,6 +5,7 @@ section: components
|
|
|
5
5
|
|
|
6
6
|
import { css } from '@patternfly/react-styles';
|
|
7
7
|
import display from '@patternfly/react-styles/css/utilities/Display/display';
|
|
8
|
+
import { DashboardWrapper } from '@patternfly/react-core/dist/js/demos/DashboardWrapper';
|
|
8
9
|
|
|
9
10
|
## Demos
|
|
10
11
|
|
|
@@ -25,7 +26,7 @@ import {
|
|
|
25
26
|
Text
|
|
26
27
|
} from '@patternfly/react-core';
|
|
27
28
|
|
|
28
|
-
import { DashboardWrapper } from '@patternfly/react-core/
|
|
29
|
+
import { DashboardWrapper } from '@patternfly/react-core/dist/js/demos/DashboardWrapper';
|
|
29
30
|
import { css } from '@patternfly/react-styles';
|
|
30
31
|
import display from '@patternfly/react-styles/css/utilities/Display/display';
|
|
31
32
|
|
|
@@ -91,7 +92,7 @@ import {
|
|
|
91
92
|
TextContent,
|
|
92
93
|
Text
|
|
93
94
|
} from '@patternfly/react-core';
|
|
94
|
-
import { DashboardWrapper } from '@patternfly/react-core/
|
|
95
|
+
import { DashboardWrapper } from '@patternfly/react-core/dist/js/demos/DashboardWrapper';
|
|
95
96
|
import { css } from '@patternfly/react-styles';
|
|
96
97
|
import display from '@patternfly/react-styles/css/utilities/Display/display';
|
|
97
98
|
|
|
@@ -134,8 +135,8 @@ class BannerDemo extends React.Component {
|
|
|
134
135
|
<PageSection>
|
|
135
136
|
<Gallery hasGutter>
|
|
136
137
|
{Array.from({ length: 30 }).map((_value, index) => (
|
|
137
|
-
<GalleryItem key={
|
|
138
|
-
<Card key={
|
|
138
|
+
<GalleryItem key={index}>
|
|
139
|
+
<Card key={index}>
|
|
139
140
|
<CardBody>This is a card</CardBody>
|
|
140
141
|
</Card>
|
|
141
142
|
</GalleryItem>
|
|
@@ -18,6 +18,8 @@ import restIcon from '../assets/FuseConnector_Icons_REST.png';
|
|
|
18
18
|
import EllipsisVIcon from '@patternfly/react-icons/dist/esm/icons/ellipsis-v-icon';
|
|
19
19
|
import { data } from '@patternfly/react-core/src/demos/CardView/examples/CardViewData.jsx';
|
|
20
20
|
|
|
21
|
+
import { DashboardWrapper } from '@patternfly/react-core/dist/js/demos/DashboardWrapper';
|
|
22
|
+
|
|
21
23
|
## Demos
|
|
22
24
|
|
|
23
25
|
This demonstrates how you can assemble a full page view that contains a grid of equal sized cards that includes a toolbar for managing card grid contents.
|
|
@@ -51,7 +51,7 @@ import swaggerIcon from './assets/camel-swagger-java_200x150.png';
|
|
|
51
51
|
import azureIcon from './assets/FuseConnector_Icons_AzureServices.png';
|
|
52
52
|
import restIcon from './assets/FuseConnector_Icons_REST.png';
|
|
53
53
|
import EllipsisVIcon from '@patternfly/react-icons/dist/esm/icons/ellipsis-v-icon';
|
|
54
|
-
import { DashboardWrapper } from '@patternfly/react-core/
|
|
54
|
+
import { DashboardWrapper } from '@patternfly/react-core/dist/js/demos/DashboardWrapper';
|
|
55
55
|
import { data } from '@patternfly/react-core/src/demos/CardView/examples/CardViewData.jsx';
|
|
56
56
|
|
|
57
57
|
export const CardViewBasic: React.FunctionComponent = () => {
|
|
@@ -24,7 +24,7 @@ import {
|
|
|
24
24
|
ToolbarContent
|
|
25
25
|
} from '@patternfly/react-core';
|
|
26
26
|
import EllipsisVIcon from '@patternfly/react-icons/dist/esm/icons/ellipsis-v-icon';
|
|
27
|
-
import { DashboardWrapper } from '@patternfly/react-core/
|
|
27
|
+
import { DashboardWrapper } from '@patternfly/react-core/dist/js/demos/DashboardWrapper';
|
|
28
28
|
|
|
29
29
|
import CodeBranchIcon from '@patternfly/react-icons/dist/esm/icons/code-branch-icon';
|
|
30
30
|
import CodeIcon from '@patternfly/react-icons/dist/esm/icons/code-icon';
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
TextContent
|
|
29
29
|
} from '@patternfly/react-core';
|
|
30
30
|
|
|
31
|
-
import { DashboardWrapper } from '@patternfly/react-core/
|
|
31
|
+
import { DashboardWrapper } from '@patternfly/react-core/dist/js/demos/DashboardWrapper';
|
|
32
32
|
|
|
33
33
|
import CodeBranchIcon from '@patternfly/react-icons/dist/esm/icons/code-branch-icon';
|
|
34
34
|
import AngleRightIcon from '@patternfly/react-icons/dist/esm/icons/angle-right-icon';
|
|
@@ -14,6 +14,7 @@ import CubeIcon from '@patternfly/react-icons/dist/esm/icons/cube-icon';
|
|
|
14
14
|
import ExclamationTriangleIcon from '@patternfly/react-icons/dist/esm/icons/exclamation-triangle-icon';
|
|
15
15
|
import CheckCircleIcon from '@patternfly/react-icons/dist/esm/icons/check-circle-icon';
|
|
16
16
|
import TimesCircleIcon from '@patternfly/react-icons/dist/esm/icons/times-circle-icon';
|
|
17
|
+
import { DashboardWrapper } from '@patternfly/react-core/dist/js/demos/DashboardWrapper';
|
|
17
18
|
|
|
18
19
|
## Demos
|
|
19
20
|
|
|
@@ -651,7 +651,7 @@ export const FilterAttributeSearch: React.FunctionComponent = () => {
|
|
|
651
651
|
<Table aria-label="Selectable table">
|
|
652
652
|
<Thead>
|
|
653
653
|
<Tr>
|
|
654
|
-
<Th />
|
|
654
|
+
<Th screenReaderText="Row select" />
|
|
655
655
|
<Th width={20}>{columnNames.name}</Th>
|
|
656
656
|
<Th width={10}>{columnNames.threads}</Th>
|
|
657
657
|
<Th width={10}>{columnNames.apps}</Th>
|
|
@@ -377,7 +377,7 @@ export const FilterCheckboxSelect: React.FunctionComponent = () => {
|
|
|
377
377
|
<Table aria-label="Selectable table">
|
|
378
378
|
<Thead>
|
|
379
379
|
<Tr>
|
|
380
|
-
<Th />
|
|
380
|
+
<Th screenReaderText="Row select" />
|
|
381
381
|
<Th width={20}>{columnNames.name}</Th>
|
|
382
382
|
<Th width={10}>{columnNames.threads}</Th>
|
|
383
383
|
<Th width={10}>{columnNames.apps}</Th>
|
|
@@ -467,7 +467,7 @@ export const FilterFaceted: React.FunctionComponent = () => {
|
|
|
467
467
|
<Table aria-label="Selectable table">
|
|
468
468
|
<Thead>
|
|
469
469
|
<Tr>
|
|
470
|
-
<Th />
|
|
470
|
+
<Th screenReaderText="Row select" />
|
|
471
471
|
<Th width={20}>{columnNames.name}</Th>
|
|
472
472
|
<Th width={10}>{columnNames.threads}</Th>
|
|
473
473
|
<Th width={10}>{columnNames.apps}</Th>
|
|
@@ -517,7 +517,7 @@ export const FilterMixedSelectGroup: React.FunctionComponent = () => {
|
|
|
517
517
|
<Table aria-label="Selectable table">
|
|
518
518
|
<Thead>
|
|
519
519
|
<Tr>
|
|
520
|
-
<Th />
|
|
520
|
+
<Th screenReaderText="Row select" />
|
|
521
521
|
<Th width={20}>{columnNames.name}</Th>
|
|
522
522
|
<Th width={10}>{columnNames.threads}</Th>
|
|
523
523
|
<Th width={10}>{columnNames.apps}</Th>
|
|
@@ -490,7 +490,7 @@ export const FilterSameSelectGroup: React.FunctionComponent = () => {
|
|
|
490
490
|
<Table aria-label="Selectable table">
|
|
491
491
|
<Thead>
|
|
492
492
|
<Tr>
|
|
493
|
-
<Th />
|
|
493
|
+
<Th screenReaderText="Row select" />
|
|
494
494
|
<Th width={20}>{columnNames.name}</Th>
|
|
495
495
|
<Th width={10}>{columnNames.threads}</Th>
|
|
496
496
|
<Th width={10}>{columnNames.apps}</Th>
|