@patternfly/react-core 4.202.32 → 4.202.35
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 +27 -0
- package/dist/esm/components/ApplicationLauncher/ApplicationLauncher.d.ts +9 -2
- package/dist/esm/components/ApplicationLauncher/ApplicationLauncher.d.ts.map +1 -1
- package/dist/esm/components/ApplicationLauncher/ApplicationLauncher.js.map +1 -1
- package/dist/esm/components/Brand/Brand.d.ts +23 -3
- package/dist/esm/components/Brand/Brand.d.ts.map +1 -1
- package/dist/esm/components/Brand/Brand.js +12 -2
- package/dist/esm/components/Brand/Brand.js.map +1 -1
- package/dist/esm/components/ContextSelector/ContextSelector.d.ts +10 -2
- package/dist/esm/components/ContextSelector/ContextSelector.d.ts.map +1 -1
- package/dist/esm/components/ContextSelector/ContextSelector.js +3 -2
- package/dist/esm/components/ContextSelector/ContextSelector.js.map +1 -1
- package/dist/esm/components/ContextSelector/ContextSelectorToggle.js +3 -3
- package/dist/esm/components/ContextSelector/ContextSelectorToggle.js.map +1 -1
- package/dist/esm/components/Dropdown/Dropdown.d.ts +9 -2
- package/dist/esm/components/Dropdown/Dropdown.d.ts.map +1 -1
- package/dist/esm/components/Dropdown/Dropdown.js +2 -2
- package/dist/esm/components/Dropdown/Dropdown.js.map +1 -1
- package/dist/esm/components/OptionsMenu/OptionsMenu.d.ts +9 -2
- package/dist/esm/components/OptionsMenu/OptionsMenu.d.ts.map +1 -1
- package/dist/esm/components/OptionsMenu/OptionsMenu.js.map +1 -1
- package/dist/esm/components/Select/Select.d.ts +9 -2
- package/dist/esm/components/Select/Select.d.ts.map +1 -1
- package/dist/esm/components/Select/Select.js.map +1 -1
- package/dist/esm/components/Tabs/Tabs.d.ts +2 -0
- package/dist/esm/components/Tabs/Tabs.d.ts.map +1 -1
- package/dist/esm/components/Tabs/Tabs.js +3 -2
- package/dist/esm/components/Tabs/Tabs.js.map +1 -1
- package/dist/esm/components/Wizard/Wizard.d.ts +2 -0
- package/dist/esm/components/Wizard/Wizard.d.ts.map +1 -1
- package/dist/esm/components/Wizard/Wizard.js +3 -2
- package/dist/esm/components/Wizard/Wizard.js.map +1 -1
- package/dist/esm/components/Wizard/WizardHeader.d.ts +2 -0
- package/dist/esm/components/Wizard/WizardHeader.d.ts.map +1 -1
- package/dist/esm/components/Wizard/WizardHeader.js +2 -2
- package/dist/esm/components/Wizard/WizardHeader.js.map +1 -1
- package/dist/esm/helpers/Popper/Popper.d.ts +0 -10
- package/dist/esm/helpers/Popper/Popper.d.ts.map +1 -1
- package/dist/esm/helpers/Popper/Popper.js.map +1 -1
- package/dist/js/components/ApplicationLauncher/ApplicationLauncher.d.ts +9 -2
- package/dist/js/components/ApplicationLauncher/ApplicationLauncher.d.ts.map +1 -1
- package/dist/js/components/ApplicationLauncher/ApplicationLauncher.js.map +1 -1
- package/dist/js/components/Brand/Brand.d.ts +23 -3
- package/dist/js/components/Brand/Brand.d.ts.map +1 -1
- package/dist/js/components/Brand/Brand.js +12 -2
- package/dist/js/components/Brand/Brand.js.map +1 -1
- package/dist/js/components/ContextSelector/ContextSelector.d.ts +10 -2
- package/dist/js/components/ContextSelector/ContextSelector.d.ts.map +1 -1
- package/dist/js/components/ContextSelector/ContextSelector.js +3 -2
- package/dist/js/components/ContextSelector/ContextSelector.js.map +1 -1
- package/dist/js/components/ContextSelector/ContextSelectorToggle.js +3 -3
- package/dist/js/components/ContextSelector/ContextSelectorToggle.js.map +1 -1
- package/dist/js/components/Dropdown/Dropdown.d.ts +9 -2
- package/dist/js/components/Dropdown/Dropdown.d.ts.map +1 -1
- package/dist/js/components/Dropdown/Dropdown.js +2 -2
- package/dist/js/components/Dropdown/Dropdown.js.map +1 -1
- package/dist/js/components/OptionsMenu/OptionsMenu.d.ts +9 -2
- package/dist/js/components/OptionsMenu/OptionsMenu.d.ts.map +1 -1
- package/dist/js/components/OptionsMenu/OptionsMenu.js.map +1 -1
- package/dist/js/components/Select/Select.d.ts +9 -2
- package/dist/js/components/Select/Select.d.ts.map +1 -1
- package/dist/js/components/Select/Select.js.map +1 -1
- package/dist/js/components/Tabs/Tabs.d.ts +2 -0
- package/dist/js/components/Tabs/Tabs.d.ts.map +1 -1
- package/dist/js/components/Tabs/Tabs.js +3 -2
- package/dist/js/components/Tabs/Tabs.js.map +1 -1
- package/dist/js/components/Wizard/Wizard.d.ts +2 -0
- package/dist/js/components/Wizard/Wizard.d.ts.map +1 -1
- package/dist/js/components/Wizard/Wizard.js +3 -2
- package/dist/js/components/Wizard/Wizard.js.map +1 -1
- package/dist/js/components/Wizard/WizardHeader.d.ts +2 -0
- package/dist/js/components/Wizard/WizardHeader.d.ts.map +1 -1
- package/dist/js/components/Wizard/WizardHeader.js +2 -2
- package/dist/js/components/Wizard/WizardHeader.js.map +1 -1
- package/dist/js/helpers/Popper/Popper.d.ts +0 -10
- package/dist/js/helpers/Popper/Popper.d.ts.map +1 -1
- package/dist/js/helpers/Popper/Popper.js.map +1 -1
- package/dist/umd/react-core.css +64 -0
- package/dist/umd/react-core.js +157 -134
- package/dist/umd/react-core.min.css +64 -0
- package/dist/umd/react-core.min.js +4 -4
- package/package.json +5 -5
- package/src/components/ApplicationLauncher/ApplicationLauncher.tsx +9 -2
- package/src/components/Brand/Brand.tsx +61 -8
- package/src/components/Brand/__tests__/Brand.test.tsx +15 -4
- package/src/components/Brand/__tests__/__snapshots__/Brand.test.tsx.snap +1 -1
- package/src/components/Brand/examples/Brand.md +13 -0
- package/src/components/Brand/examples/BrandResponsive.tsx +18 -0
- package/src/components/Brand/examples/pf-c-brand--logo-base.jpg +0 -0
- package/src/components/Brand/examples/pf-c-brand--logo-on-lg.svg +32 -0
- package/src/components/Brand/examples/pf-c-brand--logo-on-md.svg +42 -0
- package/src/components/Brand/examples/pf-c-brand--logo-on-sm.svg +17 -0
- package/src/components/Brand/examples/pf-c-brand--logo-on-xl.svg +39 -0
- package/src/components/Brand/examples/pf-c-brand--logo.svg +10 -0
- package/src/components/ContextSelector/ContextSelector.tsx +12 -4
- package/src/components/ContextSelector/ContextSelectorToggle.tsx +3 -3
- package/src/components/Dropdown/Dropdown.tsx +11 -3
- package/src/components/OptionsMenu/OptionsMenu.tsx +9 -2
- package/src/components/Select/Select.tsx +10 -3
- package/src/components/Tabs/Tabs.tsx +5 -0
- package/src/components/Tabs/__tests__/Tabs.test.tsx +17 -0
- package/src/components/Tabs/__tests__/__snapshots__/Tabs.test.tsx.snap +153 -0
- package/src/components/TextInputGroup/__tests__/TextInputGroup.test.tsx +47 -146
- package/src/components/TextInputGroup/__tests__/TextInputGroupMain.test.tsx +302 -0
- package/src/components/TextInputGroup/__tests__/TextInputGroupUtilities.test.tsx +34 -0
- package/src/components/TextInputGroup/__tests__/__snapshots__/TextInputGroup.test.tsx.snap +2 -203
- package/src/components/TextInputGroup/__tests__/__snapshots__/TextInputGroupMain.test.tsx.snap +21 -0
- package/src/components/TextInputGroup/__tests__/__snapshots__/TextInputGroupUtilities.test.tsx.snap +13 -0
- package/src/components/Wizard/Wizard.tsx +5 -0
- package/src/components/Wizard/WizardHeader.tsx +5 -2
- package/src/components/Wizard/examples/Wizard.md +168 -103
- package/src/demos/Tabs.md +5 -0
- package/src/demos/examples/Tabs/TabsAndTablesAutoWidthTabs.tsx +442 -0
- package/src/helpers/Popper/Popper.tsx +0 -11
- package/src/components/AboutModal/__tests__/Generated/AboutModal.test.tsx +0 -27
- package/src/components/AboutModal/__tests__/Generated/AboutModalBox.test.tsx +0 -13
- package/src/components/AboutModal/__tests__/Generated/AboutModalBoxBrand.test.tsx +0 -13
- package/src/components/AboutModal/__tests__/Generated/AboutModalBoxCloseButton.test.tsx +0 -13
- package/src/components/AboutModal/__tests__/Generated/AboutModalBoxContent.test.tsx +0 -21
- package/src/components/AboutModal/__tests__/Generated/AboutModalBoxHeader.test.tsx +0 -13
- package/src/components/AboutModal/__tests__/Generated/AboutModalBoxHero.test.tsx +0 -13
- package/src/components/AboutModal/__tests__/Generated/AboutModalContainer.test.tsx +0 -27
- package/src/components/AboutModal/__tests__/Generated/__snapshots__/AboutModal.test.tsx.snap +0 -3
- package/src/components/AboutModal/__tests__/Generated/__snapshots__/AboutModalBox.test.tsx.snap +0 -15
- package/src/components/AboutModal/__tests__/Generated/__snapshots__/AboutModalBoxBrand.test.tsx.snap +0 -15
- package/src/components/AboutModal/__tests__/Generated/__snapshots__/AboutModalBoxCloseButton.test.tsx.snap +0 -33
- package/src/components/AboutModal/__tests__/Generated/__snapshots__/AboutModalBoxContent.test.tsx.snap +0 -27
- package/src/components/AboutModal/__tests__/Generated/__snapshots__/AboutModalBoxHeader.test.tsx.snap +0 -19
- package/src/components/AboutModal/__tests__/Generated/__snapshots__/AboutModalBoxHero.test.tsx.snap +0 -10
- package/src/components/AboutModal/__tests__/Generated/__snapshots__/AboutModalContainer.test.tsx.snap +0 -3
- package/src/components/Accordion/__tests__/Generated/Accordion.test.tsx +0 -22
- package/src/components/Accordion/__tests__/Generated/__snapshots__/Accordion.test.tsx.snap +0 -12
- package/src/components/Alert/__tests__/Generated/Alert.test.tsx +0 -26
- package/src/components/Alert/__tests__/Generated/__snapshots__/Alert.test.tsx.snap +0 -47
- package/src/components/ApplicationLauncher/__tests__/Generated/ApplicationLauncher.test.tsx +0 -36
- package/src/components/ApplicationLauncher/__tests__/Generated/__snapshots__/ApplicationLauncher.test.tsx.snap +0 -30
- package/src/components/Avatar/__tests__/Generated/Avatar.test.tsx +0 -13
- package/src/components/Avatar/__tests__/Generated/__snapshots__/Avatar.test.tsx.snap +0 -11
- package/src/components/Backdrop/__tests__/Generated/Backdrop.test.tsx +0 -13
- package/src/components/Backdrop/__tests__/Generated/__snapshots__/Backdrop.test.tsx.snap +0 -11
- package/src/components/BackgroundImage/__tests__/Generated/BackgroundImage.test.tsx +0 -13
- package/src/components/BackgroundImage/__tests__/Generated/__snapshots__/BackgroundImage.test.tsx.snap +0 -47
- package/src/components/Badge/__tests__/Generated/Badge.test.tsx +0 -13
- package/src/components/Badge/__tests__/Generated/__snapshots__/Badge.test.tsx.snap +0 -9
- package/src/components/Brand/__tests__/Generated/Brand.test.tsx +0 -13
- package/src/components/Brand/__tests__/Generated/__snapshots__/Brand.test.tsx.snap +0 -11
- package/src/components/Breadcrumb/__tests__/Generated/Breadcrumb.test.tsx +0 -13
- package/src/components/Breadcrumb/__tests__/Generated/BreadcrumbHeading.test.tsx +0 -15
- package/src/components/Breadcrumb/__tests__/Generated/BreadcrumbItem.test.tsx +0 -22
- package/src/components/Breadcrumb/__tests__/Generated/__snapshots__/Breadcrumb.test.tsx.snap +0 -19
- package/src/components/Breadcrumb/__tests__/Generated/__snapshots__/BreadcrumbHeading.test.tsx.snap +0 -22
- package/src/components/Breadcrumb/__tests__/Generated/__snapshots__/BreadcrumbItem.test.tsx.snap +0 -17
- package/src/components/Button/__tests__/Generated/Button.test.tsx +0 -31
- package/src/components/Button/__tests__/Generated/__snapshots__/Button.test.tsx.snap +0 -17
- package/src/components/Card/__tests__/Generated/Card.test.tsx +0 -15
- package/src/components/Card/__tests__/Generated/CardBody.test.tsx +0 -13
- package/src/components/Card/__tests__/Generated/CardFooter.test.tsx +0 -13
- package/src/components/Card/__tests__/Generated/CardHead.test.tsx +0 -13
- package/src/components/Card/__tests__/Generated/CardHeader.test.tsx +0 -13
- package/src/components/Card/__tests__/Generated/__snapshots__/Card.test.tsx.snap +0 -15
- package/src/components/Card/__tests__/Generated/__snapshots__/CardBody.test.tsx.snap +0 -11
- package/src/components/Card/__tests__/Generated/__snapshots__/CardFooter.test.tsx.snap +0 -11
- package/src/components/Card/__tests__/Generated/__snapshots__/CardHead.test.tsx.snap +0 -11
- package/src/components/Card/__tests__/Generated/__snapshots__/CardHeader.test.tsx.snap +0 -11
- package/src/components/Checkbox/__tests__/Generated/Checkbox.test.tsx +0 -26
- package/src/components/Checkbox/__tests__/Generated/__snapshots__/Checkbox.test.tsx.snap +0 -35
- package/src/components/Chip/__tests__/Generated/Chip.test.tsx +0 -24
- package/src/components/Chip/__tests__/Generated/__snapshots__/Chip.test.tsx.snap +0 -46
- package/src/components/ChipGroup/__tests__/Generated/ChipGroup.test.tsx +0 -24
- package/src/components/ChipGroup/__tests__/Generated/__snapshots__/ChipGroup.test.tsx.snap +0 -33
- package/src/components/ClipboardCopy/__tests__/Generated/ClipboardCopyButton.test.tsx +0 -26
- package/src/components/ClipboardCopy/__tests__/Generated/ClipboardCopyExpanded.test.tsx +0 -21
- package/src/components/ClipboardCopy/__tests__/Generated/ClipboardCopyToggle.test.tsx +0 -22
- package/src/components/ClipboardCopy/__tests__/Generated/__snapshots__/ClipboardCopyButton.test.tsx.snap +0 -31
- package/src/components/ClipboardCopy/__tests__/Generated/__snapshots__/ClipboardCopyExpanded.test.tsx.snap +0 -14
- package/src/components/ClipboardCopy/__tests__/Generated/__snapshots__/ClipboardCopyToggle.test.tsx.snap +0 -32
- package/src/components/ContextSelector/__tests__/Generated/ContextSelector.test.tsx +0 -28
- package/src/components/ContextSelector/__tests__/Generated/ContextSelectorItem.test.tsx +0 -23
- package/src/components/ContextSelector/__tests__/Generated/ContextSelectorMenuList.test.tsx +0 -13
- package/src/components/ContextSelector/__tests__/Generated/ContextSelectorToggle.test.tsx +0 -26
- package/src/components/ContextSelector/__tests__/Generated/__snapshots__/ContextSelector.test.tsx.snap +0 -49
- package/src/components/ContextSelector/__tests__/Generated/__snapshots__/ContextSelectorItem.test.tsx.snap +0 -15
- package/src/components/ContextSelector/__tests__/Generated/__snapshots__/ContextSelectorMenuList.test.tsx.snap +0 -12
- package/src/components/ContextSelector/__tests__/Generated/__snapshots__/ContextSelectorToggle.test.tsx.snap +0 -35
- package/src/components/DataList/__tests__/Generated/DataList.test.tsx +0 -21
- package/src/components/DataList/__tests__/Generated/__snapshots__/DataList.test.tsx.snap +0 -12
- package/src/components/Divider/__tests__/Generated/Divider.test.tsx +0 -13
- package/src/components/Divider/__tests__/Generated/__snapshots__/Divider.test.tsx.snap +0 -9
- package/src/components/Drawer/__tests__/Generated/Drawer.test.tsx +0 -13
- package/src/components/Drawer/__tests__/Generated/__snapshots__/Drawer.test.tsx.snap +0 -13
- package/src/components/Dropdown/__tests__/Generated/Dropdown.test.tsx +0 -27
- package/src/components/Dropdown/__tests__/Generated/DropdownGroup.test.tsx +0 -13
- package/src/components/Dropdown/__tests__/Generated/DropdownToggle.test.tsx +0 -34
- package/src/components/Dropdown/__tests__/Generated/DropdownToggleAction.test.tsx +0 -22
- package/src/components/Dropdown/__tests__/Generated/DropdownToggleCheckbox.test.tsx +0 -25
- package/src/components/Dropdown/__tests__/Generated/Toggle.test.tsx +0 -31
- package/src/components/Dropdown/__tests__/Generated/__snapshots__/Dropdown.test.tsx.snap +0 -27
- package/src/components/Dropdown/__tests__/Generated/__snapshots__/DropdownGroup.test.tsx.snap +0 -16
- package/src/components/Dropdown/__tests__/Generated/__snapshots__/DropdownToggle.test.tsx.snap +0 -34
- package/src/components/Dropdown/__tests__/Generated/__snapshots__/DropdownToggleAction.test.tsx.snap +0 -15
- package/src/components/Dropdown/__tests__/Generated/__snapshots__/DropdownToggleCheckbox.test.tsx.snap +0 -30
- package/src/components/Dropdown/__tests__/Generated/__snapshots__/Toggle.test.tsx.snap +0 -17
- package/src/components/EmptyState/__tests__/Generated/EmptyState.test.tsx +0 -13
- package/src/components/EmptyState/__tests__/Generated/__snapshots__/EmptyState.test.tsx.snap +0 -17
- package/src/components/ExpandableSection/__tests__/Generated/ExpandableSection.test.tsx +0 -24
- package/src/components/ExpandableSection/__tests__/Generated/__snapshots__/ExpandableSection.test.tsx.snap +0 -46
- package/src/components/Form/__tests__/Generated/ActionGroup.test.tsx +0 -13
- package/src/components/Form/__tests__/Generated/Form.test.tsx +0 -13
- package/src/components/Form/__tests__/Generated/FormGroup.test.tsx +0 -27
- package/src/components/Form/__tests__/Generated/FormHelperText.test.tsx +0 -13
- package/src/components/Form/__tests__/Generated/__snapshots__/ActionGroup.test.tsx.snap +0 -19
- package/src/components/Form/__tests__/Generated/__snapshots__/Form.test.tsx.snap +0 -12
- package/src/components/Form/__tests__/Generated/__snapshots__/FormGroup.test.tsx.snap +0 -38
- package/src/components/Form/__tests__/Generated/__snapshots__/FormHelperText.test.tsx.snap +0 -11
- package/src/components/FormSelect/__tests__/Generated/FormSelect.test.tsx +0 -26
- package/src/components/FormSelect/__tests__/Generated/__snapshots__/FormSelect.test.tsx.snap +0 -18
- package/src/components/InputGroup/__tests__/Generated/InputGroup.test.tsx +0 -13
- package/src/components/InputGroup/__tests__/Generated/InputGroupText.test.tsx +0 -13
- package/src/components/InputGroup/__tests__/Generated/__snapshots__/InputGroup.test.tsx.snap +0 -13
- package/src/components/InputGroup/__tests__/Generated/__snapshots__/InputGroupText.test.tsx.snap +0 -13
- package/src/components/Label/__tests__/Generated/Label.test.tsx +0 -13
- package/src/components/Label/__tests__/Generated/__snapshots__/Label.test.tsx.snap +0 -17
- package/src/components/LabelGroup/__tests__/Generated/LabelGroup.test.tsx +0 -29
- package/src/components/LabelGroup/__tests__/Generated/__snapshots__/LabelGroup.test.tsx.snap +0 -34
- package/src/components/LoginPage/__tests__/Generated/Login.test.tsx +0 -13
- package/src/components/LoginPage/__tests__/Generated/LoginFooterItem.test.tsx +0 -13
- package/src/components/LoginPage/__tests__/Generated/LoginForm.test.tsx +0 -34
- package/src/components/LoginPage/__tests__/Generated/LoginMainBody.test.tsx +0 -13
- package/src/components/LoginPage/__tests__/Generated/LoginMainFooter.test.tsx +0 -21
- package/src/components/LoginPage/__tests__/Generated/LoginMainFooterBandItem.test.tsx +0 -13
- package/src/components/LoginPage/__tests__/Generated/LoginMainFooterLinksItem.test.tsx +0 -22
- package/src/components/LoginPage/__tests__/Generated/LoginMainHeader.test.tsx +0 -13
- package/src/components/LoginPage/__tests__/Generated/LoginPage.test.tsx +0 -30
- package/src/components/LoginPage/__tests__/Generated/__snapshots__/Login.test.tsx.snap +0 -19
- package/src/components/LoginPage/__tests__/Generated/__snapshots__/LoginFooterItem.test.tsx.snap +0 -7
- package/src/components/LoginPage/__tests__/Generated/__snapshots__/LoginForm.test.tsx.snap +0 -150
- package/src/components/LoginPage/__tests__/Generated/__snapshots__/LoginMainBody.test.tsx.snap +0 -11
- package/src/components/LoginPage/__tests__/Generated/__snapshots__/LoginMainFooter.test.tsx.snap +0 -11
- package/src/components/LoginPage/__tests__/Generated/__snapshots__/LoginMainFooterBandItem.test.tsx.snap +0 -11
- package/src/components/LoginPage/__tests__/Generated/__snapshots__/LoginMainFooterLinksItem.test.tsx.snap +0 -17
- package/src/components/LoginPage/__tests__/Generated/__snapshots__/LoginMainHeader.test.tsx.snap +0 -24
- package/src/components/LoginPage/__tests__/Generated/__snapshots__/LoginPage.test.tsx.snap +0 -60
- package/src/components/Modal/__tests__/Generated/Modal.test.tsx +0 -35
- package/src/components/Modal/__tests__/Generated/ModalBox.test.tsx +0 -22
- package/src/components/Modal/__tests__/Generated/ModalBoxBody.test.tsx +0 -13
- package/src/components/Modal/__tests__/Generated/ModalBoxCloseButton.test.tsx +0 -13
- package/src/components/Modal/__tests__/Generated/ModalBoxDescription.test.tsx +0 -13
- package/src/components/Modal/__tests__/Generated/ModalBoxFooter.test.tsx +0 -13
- package/src/components/Modal/__tests__/Generated/ModalBoxHeader.test.tsx +0 -13
- package/src/components/Modal/__tests__/Generated/ModalContent.test.tsx +0 -36
- package/src/components/Modal/__tests__/Generated/__snapshots__/Modal.test.tsx.snap +0 -3
- package/src/components/Modal/__tests__/Generated/__snapshots__/ModalBox.test.tsx.snap +0 -18
- package/src/components/Modal/__tests__/Generated/__snapshots__/ModalBoxBody.test.tsx.snap +0 -11
- package/src/components/Modal/__tests__/Generated/__snapshots__/ModalBoxCloseButton.test.tsx.snap +0 -29
- package/src/components/Modal/__tests__/Generated/__snapshots__/ModalBoxDescription.test.tsx.snap +0 -12
- package/src/components/Modal/__tests__/Generated/__snapshots__/ModalBoxFooter.test.tsx.snap +0 -11
- package/src/components/Modal/__tests__/Generated/__snapshots__/ModalBoxHeader.test.tsx.snap +0 -11
- package/src/components/Modal/__tests__/Generated/__snapshots__/ModalContent.test.tsx.snap +0 -3
- package/src/components/Nav/__tests__/Generated/Nav.test.tsx +0 -22
- package/src/components/Nav/__tests__/Generated/__snapshots__/Nav.test.tsx.snap +0 -15
- package/src/components/NotificationBadge/__tests__/Generated/NotificationBadge.test.tsx +0 -15
- package/src/components/NotificationBadge/__tests__/Generated/__snapshots__/NotificationBadge.test.tsx.snap +0 -23
- package/src/components/NotificationDrawer/__tests__/Generated/NotificationDrawer.test.tsx +0 -13
- package/src/components/NotificationDrawer/__tests__/Generated/NotificationDrawerBody.test.tsx +0 -13
- package/src/components/NotificationDrawer/__tests__/Generated/NotificationDrawerGroup.test.tsx +0 -23
- package/src/components/NotificationDrawer/__tests__/Generated/NotificationDrawerGroupList.test.tsx +0 -13
- package/src/components/NotificationDrawer/__tests__/Generated/NotificationDrawerHeader.test.tsx +0 -15
- package/src/components/NotificationDrawer/__tests__/Generated/NotificationDrawerList.test.tsx +0 -13
- package/src/components/NotificationDrawer/__tests__/Generated/NotificationDrawerListItem.test.tsx +0 -22
- package/src/components/NotificationDrawer/__tests__/Generated/NotificationDrawerListItemBody.test.tsx +0 -15
- package/src/components/NotificationDrawer/__tests__/Generated/NotificationDrawerListItemHeader.test.tsx +0 -22
- package/src/components/NotificationDrawer/__tests__/Generated/__snapshots__/NotificationDrawer.test.tsx.snap +0 -13
- package/src/components/NotificationDrawer/__tests__/Generated/__snapshots__/NotificationDrawerBody.test.tsx.snap +0 -13
- package/src/components/NotificationDrawer/__tests__/Generated/__snapshots__/NotificationDrawerGroup.test.tsx.snap +0 -51
- package/src/components/NotificationDrawer/__tests__/Generated/__snapshots__/NotificationDrawerGroupList.test.tsx.snap +0 -13
- package/src/components/NotificationDrawer/__tests__/Generated/__snapshots__/NotificationDrawerHeader.test.tsx.snap +0 -31
- package/src/components/NotificationDrawer/__tests__/Generated/__snapshots__/NotificationDrawerList.test.tsx.snap +0 -13
- package/src/components/NotificationDrawer/__tests__/Generated/__snapshots__/NotificationDrawerListItem.test.tsx.snap +0 -14
- package/src/components/NotificationDrawer/__tests__/Generated/__snapshots__/NotificationDrawerListItemBody.test.tsx.snap +0 -20
- package/src/components/NotificationDrawer/__tests__/Generated/__snapshots__/NotificationDrawerListItemHeader.test.tsx.snap +0 -44
- package/src/components/OptionsMenu/__tests__/Generated/OptionsMenu.test.tsx +0 -26
- package/src/components/OptionsMenu/__tests__/Generated/__snapshots__/OptionsMenu.test.tsx.snap +0 -24
- package/src/components/OverflowMenu/__tests__/Generated/OverflowMenu.test.tsx +0 -13
- package/src/components/OverflowMenu/__tests__/Generated/OverflowMenuContent.test.tsx +0 -13
- package/src/components/OverflowMenu/__tests__/Generated/OverflowMenuGroup.test.tsx +0 -15
- package/src/components/OverflowMenu/__tests__/Generated/OverflowMenuItem.test.tsx +0 -13
- package/src/components/OverflowMenu/__tests__/Generated/__snapshots__/OverflowMenu.test.tsx.snap +0 -11
- package/src/components/OverflowMenu/__tests__/Generated/__snapshots__/OverflowMenuContent.test.tsx.snap +0 -11
- package/src/components/OverflowMenu/__tests__/Generated/__snapshots__/OverflowMenuGroup.test.tsx.snap +0 -11
- package/src/components/OverflowMenu/__tests__/Generated/__snapshots__/OverflowMenuItem.test.tsx.snap +0 -13
- package/src/components/Page/__tests__/Generated/PageHeader.test.tsx +0 -28
- package/src/components/Page/__tests__/Generated/PageSection.test.tsx +0 -22
- package/src/components/Page/__tests__/Generated/__snapshots__/PageHeader.test.tsx.snap +0 -10
- package/src/components/Page/__tests__/Generated/__snapshots__/PageSection.test.tsx.snap +0 -13
- package/src/components/Popover/__tests__/Generated/Popover.test.tsx +0 -40
- package/src/components/Popover/__tests__/Generated/__snapshots__/Popover.test.tsx.snap +0 -9
- package/src/components/Progress/__tests__/Generated/Progress.test.tsx +0 -27
- package/src/components/Progress/__tests__/Generated/__snapshots__/Progress.test.tsx.snap +0 -63
- package/src/components/SkipToContent/__tests__/Generated/SkipToContent.test.tsx +0 -15
- package/src/components/SkipToContent/__tests__/Generated/__snapshots__/SkipToContent.test.tsx.snap +0 -15
- package/src/components/Spinner/__tests__/Generated/Spinner.test.tsx +0 -13
- package/src/components/Spinner/__tests__/Generated/__snapshots__/Spinner.test.tsx.snap +0 -22
- package/src/components/Tabs/__tests__/Generated/TabButton.test.tsx +0 -20
- package/src/components/Tabs/__tests__/Generated/Tabs.test.tsx +0 -29
- package/src/components/Tabs/__tests__/Generated/__snapshots__/TabButton.test.tsx.snap +0 -16
- package/src/components/Tabs/__tests__/Generated/__snapshots__/Tabs.test.tsx.snap +0 -75
- package/src/components/Text/__tests__/Generated/Text.test.tsx +0 -13
- package/src/components/Text/__tests__/Generated/__snapshots__/Text.test.tsx.snap +0 -15
- package/src/components/Toolbar/__tests__/Generated/Toolbar.test.tsx +0 -24
- package/src/components/Toolbar/__tests__/Generated/ToolbarItem.test.tsx +0 -20
- package/src/components/Toolbar/__tests__/Generated/__snapshots__/Toolbar.test.tsx.snap +0 -25
- package/src/components/Toolbar/__tests__/Generated/__snapshots__/ToolbarItem.test.tsx.snap +0 -14
- package/src/components/Tooltip/__tests__/Generated/Tooltip.test.tsx +0 -33
- package/src/components/Tooltip/__tests__/Generated/__snapshots__/Tooltip.test.tsx.snap +0 -9
- package/src/layouts/Bullseye/__tests__/Generated/Bullseye.test.tsx +0 -13
- package/src/layouts/Bullseye/__tests__/Generated/__snapshots__/Bullseye.test.tsx.snap +0 -11
- package/src/layouts/Flex/__tests__/Generated/Flex.test.tsx +0 -13
- package/src/layouts/Flex/__tests__/Generated/__snapshots__/Flex.test.tsx.snap +0 -11
- package/src/layouts/Gallery/__tests__/Generated/Gallery.test.tsx +0 -13
- package/src/layouts/Gallery/__tests__/Generated/__snapshots__/Gallery.test.tsx.snap +0 -11
- package/src/layouts/Grid/__tests__/Generated/Grid.test.tsx +0 -15
- package/src/layouts/Grid/__tests__/Generated/GridItem.test.tsx +0 -36
- package/src/layouts/Grid/__tests__/Generated/__snapshots__/Grid.test.tsx.snap +0 -11
- package/src/layouts/Grid/__tests__/Generated/__snapshots__/GridItem.test.tsx.snap +0 -11
- package/src/layouts/Level/__tests__/Generated/Level.test.tsx +0 -13
- package/src/layouts/Level/__tests__/Generated/__snapshots__/Level.test.tsx.snap +0 -11
- package/src/layouts/Split/__tests__/Generated/Split.test.tsx +0 -13
- package/src/layouts/Split/__tests__/Generated/__snapshots__/Split.test.tsx.snap +0 -11
- package/src/layouts/Stack/__tests__/Generated/Stack.test.tsx +0 -13
- package/src/layouts/Stack/__tests__/Generated/__snapshots__/Stack.test.tsx.snap +0 -11
|
@@ -0,0 +1,442 @@
|
|
|
1
|
+
/* eslint-disable no-console */
|
|
2
|
+
import React from 'react';
|
|
3
|
+
import {
|
|
4
|
+
Button,
|
|
5
|
+
Divider,
|
|
6
|
+
Drawer,
|
|
7
|
+
DrawerContent,
|
|
8
|
+
DrawerContentBody,
|
|
9
|
+
DrawerPanelContent,
|
|
10
|
+
DrawerHead,
|
|
11
|
+
DrawerActions,
|
|
12
|
+
DrawerCloseButton,
|
|
13
|
+
DrawerPanelBody,
|
|
14
|
+
Dropdown,
|
|
15
|
+
Flex,
|
|
16
|
+
FlexItem,
|
|
17
|
+
KebabToggle,
|
|
18
|
+
Label,
|
|
19
|
+
LabelGroup,
|
|
20
|
+
OptionsMenu,
|
|
21
|
+
OptionsMenuToggle,
|
|
22
|
+
OverflowMenu,
|
|
23
|
+
OverflowMenuContent,
|
|
24
|
+
OverflowMenuControl,
|
|
25
|
+
OverflowMenuGroup,
|
|
26
|
+
OverflowMenuItem,
|
|
27
|
+
PageSection,
|
|
28
|
+
PageSectionVariants,
|
|
29
|
+
Pagination,
|
|
30
|
+
PaginationVariant,
|
|
31
|
+
Progress,
|
|
32
|
+
ProgressSize,
|
|
33
|
+
Select,
|
|
34
|
+
SelectVariant,
|
|
35
|
+
Tabs,
|
|
36
|
+
Tab,
|
|
37
|
+
TabContent,
|
|
38
|
+
TabContentBody,
|
|
39
|
+
TabTitleText,
|
|
40
|
+
Title,
|
|
41
|
+
Toolbar,
|
|
42
|
+
ToolbarItem,
|
|
43
|
+
ToolbarContent,
|
|
44
|
+
ToolbarToggleGroup
|
|
45
|
+
} from '@patternfly/react-core';
|
|
46
|
+
import {
|
|
47
|
+
TableComposable,
|
|
48
|
+
Thead,
|
|
49
|
+
Tbody,
|
|
50
|
+
Tr,
|
|
51
|
+
Th,
|
|
52
|
+
Td,
|
|
53
|
+
IAction,
|
|
54
|
+
ActionsColumn,
|
|
55
|
+
CustomActionsToggleProps
|
|
56
|
+
} from '@patternfly/react-table';
|
|
57
|
+
import DashboardWrapper from '../DashboardWrapper';
|
|
58
|
+
import CodeIcon from '@patternfly/react-icons/dist/esm/icons/code-icon';
|
|
59
|
+
import CodeBranchIcon from '@patternfly/react-icons/dist/esm/icons/code-branch-icon';
|
|
60
|
+
import CubeIcon from '@patternfly/react-icons/dist/esm/icons/cube-icon';
|
|
61
|
+
import FilterIcon from '@patternfly/react-icons/dist/esm/icons/filter-icon';
|
|
62
|
+
import SortAmountDownIcon from '@patternfly/react-icons/dist/esm/icons/sort-amount-down-icon';
|
|
63
|
+
|
|
64
|
+
interface Repository {
|
|
65
|
+
name: string;
|
|
66
|
+
branches: number | null;
|
|
67
|
+
prs: number | null;
|
|
68
|
+
workspaces: number;
|
|
69
|
+
lastCommit: string;
|
|
70
|
+
}
|
|
71
|
+
|
|
72
|
+
export const TablesAndTabs = () => {
|
|
73
|
+
// tab properties
|
|
74
|
+
const [activeTabKey, setActiveTabKey] = React.useState<number>(0);
|
|
75
|
+
// Toggle currently active tab
|
|
76
|
+
const handleTabClick = (tabIndex: number) => {
|
|
77
|
+
setActiveTabKey(tabIndex);
|
|
78
|
+
};
|
|
79
|
+
|
|
80
|
+
// secondary tab properties
|
|
81
|
+
const [secondaryActiveTabKey, setSecondaryActiveTabKey] = React.useState<number>(10);
|
|
82
|
+
const handleSecondaryTabClick = (tabIndex: number) => {
|
|
83
|
+
setSecondaryActiveTabKey(tabIndex);
|
|
84
|
+
};
|
|
85
|
+
|
|
86
|
+
// drawer properties
|
|
87
|
+
const [isExpanded, setIsExpanded] = React.useState<boolean>(false);
|
|
88
|
+
|
|
89
|
+
// table properties
|
|
90
|
+
// In real usage, this data would come from some external source like an API via props.
|
|
91
|
+
const repositories: Repository[] = [
|
|
92
|
+
{ name: 'Node 1', branches: 10, prs: 25, workspaces: 5, lastCommit: '2 days ago' },
|
|
93
|
+
{ name: 'Node 2', branches: 8, prs: 30, workspaces: 2, lastCommit: '2 days ago' },
|
|
94
|
+
{ name: 'Node 3', branches: 12, prs: 48, workspaces: 13, lastCommit: '30 days ago' },
|
|
95
|
+
{ name: 'Node 4', branches: 3, prs: 8, workspaces: 20, lastCommit: '8 days ago' },
|
|
96
|
+
{ name: 'Node 5', branches: 33, prs: 21, workspaces: 2, lastCommit: '26 days ago' }
|
|
97
|
+
];
|
|
98
|
+
|
|
99
|
+
const columnNames = {
|
|
100
|
+
name: 'Repositories',
|
|
101
|
+
branches: 'Branches',
|
|
102
|
+
prs: 'Pull requests',
|
|
103
|
+
workspaces: 'Workspaces',
|
|
104
|
+
lastCommit: 'Last commit'
|
|
105
|
+
};
|
|
106
|
+
|
|
107
|
+
const [selectedRepoNames, setSelectedRepoNames] = React.useState<string[]>([]);
|
|
108
|
+
const setRepoSelected = (event: React.FormEvent<HTMLInputElement>, repo: Repository, isSelecting = true) => {
|
|
109
|
+
setSelectedRepoNames(prevSelected => {
|
|
110
|
+
const otherSelectedRepoNames = prevSelected.filter(r => r !== repo.name);
|
|
111
|
+
return isSelecting ? [...otherSelectedRepoNames, repo.name] : otherSelectedRepoNames;
|
|
112
|
+
});
|
|
113
|
+
event.stopPropagation();
|
|
114
|
+
};
|
|
115
|
+
const onSelectAll = (isSelecting = true) => setSelectedRepoNames(isSelecting ? repositories.map(r => r.name) : []);
|
|
116
|
+
const allRowsSelected = selectedRepoNames.length === repositories.length;
|
|
117
|
+
const isRepoSelected = (repo: Repository) => selectedRepoNames.includes(repo.name);
|
|
118
|
+
|
|
119
|
+
const [rowClicked, setRowClicked] = React.useState<string>(null);
|
|
120
|
+
const isRowClicked = (repo: Repository) => rowClicked === repo.name;
|
|
121
|
+
|
|
122
|
+
const defaultActions: IAction[] = [
|
|
123
|
+
{
|
|
124
|
+
title: 'Some action',
|
|
125
|
+
onClick: event => {
|
|
126
|
+
event.stopPropagation();
|
|
127
|
+
console.log('clicked on Some action');
|
|
128
|
+
}
|
|
129
|
+
},
|
|
130
|
+
{
|
|
131
|
+
title: <a href="https://www.patternfly.org">Link action</a>,
|
|
132
|
+
onClick: event => {
|
|
133
|
+
event.stopPropagation();
|
|
134
|
+
console.log('clicked on Link action');
|
|
135
|
+
}
|
|
136
|
+
},
|
|
137
|
+
{
|
|
138
|
+
isSeparator: true
|
|
139
|
+
},
|
|
140
|
+
{
|
|
141
|
+
title: 'Third action',
|
|
142
|
+
onClick: event => {
|
|
143
|
+
event.stopPropagation();
|
|
144
|
+
console.log('clicked on Third action');
|
|
145
|
+
}
|
|
146
|
+
}
|
|
147
|
+
];
|
|
148
|
+
|
|
149
|
+
const customActionsToggle = (props: CustomActionsToggleProps) => (
|
|
150
|
+
<KebabToggle
|
|
151
|
+
isDisabled={props.isDisabled}
|
|
152
|
+
onToggle={(value, event) => {
|
|
153
|
+
props.onToggle(value);
|
|
154
|
+
event.stopPropagation();
|
|
155
|
+
}}
|
|
156
|
+
/>
|
|
157
|
+
);
|
|
158
|
+
|
|
159
|
+
const toolbar = (
|
|
160
|
+
<Toolbar id="page-layout-table-column-management-action-toolbar-top" usePageInsets>
|
|
161
|
+
<ToolbarContent>
|
|
162
|
+
<ToolbarToggleGroup toggleIcon={<FilterIcon />} breakpoint="xl">
|
|
163
|
+
<ToolbarItem>
|
|
164
|
+
<Select
|
|
165
|
+
onToggle={() => {}}
|
|
166
|
+
variant={SelectVariant.single}
|
|
167
|
+
aria-label="Select Input"
|
|
168
|
+
placeholderText="Name"
|
|
169
|
+
/>
|
|
170
|
+
</ToolbarItem>
|
|
171
|
+
</ToolbarToggleGroup>
|
|
172
|
+
<ToolbarItem>
|
|
173
|
+
<OptionsMenu
|
|
174
|
+
id="page-layout-table-column-management-action-toolbar-top-options-menu-toggle"
|
|
175
|
+
isPlain
|
|
176
|
+
menuItems={[]}
|
|
177
|
+
toggle={
|
|
178
|
+
<OptionsMenuToggle
|
|
179
|
+
toggleTemplate={<SortAmountDownIcon aria-hidden="true" />}
|
|
180
|
+
aria-label="Sort"
|
|
181
|
+
hideCaret
|
|
182
|
+
/>
|
|
183
|
+
}
|
|
184
|
+
/>
|
|
185
|
+
</ToolbarItem>
|
|
186
|
+
<OverflowMenu breakpoint="md">
|
|
187
|
+
<OverflowMenuContent className="pf-u-display-none pf-u-display-block-on-lg">
|
|
188
|
+
<OverflowMenuGroup groupType="button" isPersistent>
|
|
189
|
+
<OverflowMenuItem isPersistent>
|
|
190
|
+
<Button variant="primary">Generate</Button>
|
|
191
|
+
</OverflowMenuItem>
|
|
192
|
+
<OverflowMenuItem isPersistent>
|
|
193
|
+
<Button variant="secondary">Deploy</Button>
|
|
194
|
+
</OverflowMenuItem>
|
|
195
|
+
</OverflowMenuGroup>
|
|
196
|
+
</OverflowMenuContent>
|
|
197
|
+
<OverflowMenuControl hasAdditionalOptions>
|
|
198
|
+
<Dropdown
|
|
199
|
+
onSelect={() => {}}
|
|
200
|
+
toggle={<KebabToggle onToggle={() => {}} />}
|
|
201
|
+
isOpen={false}
|
|
202
|
+
isPlain
|
|
203
|
+
dropdownItems={[]}
|
|
204
|
+
/>
|
|
205
|
+
</OverflowMenuControl>
|
|
206
|
+
</OverflowMenu>
|
|
207
|
+
<ToolbarItem variant="pagination">
|
|
208
|
+
<Pagination
|
|
209
|
+
itemCount={36}
|
|
210
|
+
widgetId="pagination-options-menu-bottom"
|
|
211
|
+
page={1}
|
|
212
|
+
variant={PaginationVariant.top}
|
|
213
|
+
isCompact
|
|
214
|
+
/>
|
|
215
|
+
</ToolbarItem>
|
|
216
|
+
</ToolbarContent>
|
|
217
|
+
</Toolbar>
|
|
218
|
+
);
|
|
219
|
+
|
|
220
|
+
const tableComposable = (
|
|
221
|
+
<TableComposable aria-label="`Composable` table">
|
|
222
|
+
<Thead noWrap>
|
|
223
|
+
<Tr>
|
|
224
|
+
<Th
|
|
225
|
+
select={{
|
|
226
|
+
onSelect: (_event, isSelecting) => onSelectAll(isSelecting),
|
|
227
|
+
isSelected: allRowsSelected
|
|
228
|
+
}}
|
|
229
|
+
/>
|
|
230
|
+
<Th>{columnNames.name}</Th>
|
|
231
|
+
<Th>{columnNames.branches}</Th>
|
|
232
|
+
<Th>{columnNames.prs}</Th>
|
|
233
|
+
<Th>{columnNames.workspaces}</Th>
|
|
234
|
+
<Th>{columnNames.lastCommit}</Th>
|
|
235
|
+
</Tr>
|
|
236
|
+
</Thead>
|
|
237
|
+
<Tbody>
|
|
238
|
+
{repositories.map((repo, rowIndex) => (
|
|
239
|
+
<Tr
|
|
240
|
+
key={repo.name}
|
|
241
|
+
onRowClick={event => {
|
|
242
|
+
if ((event.target as HTMLInputElement).type !== 'checkbox') {
|
|
243
|
+
setRowClicked(rowClicked === repo.name ? null : repo.name);
|
|
244
|
+
setIsExpanded(!isRowClicked(repo));
|
|
245
|
+
}
|
|
246
|
+
}}
|
|
247
|
+
isHoverable
|
|
248
|
+
isRowSelected={repo.name === rowClicked}
|
|
249
|
+
>
|
|
250
|
+
<Td
|
|
251
|
+
key={`${rowIndex}_0`}
|
|
252
|
+
select={{
|
|
253
|
+
rowIndex,
|
|
254
|
+
onSelect: (event, isSelected) => setRepoSelected(event, repo, isSelected),
|
|
255
|
+
isSelected: isRepoSelected(repo)
|
|
256
|
+
}}
|
|
257
|
+
/>
|
|
258
|
+
<Td dataLabel={columnNames.name}>
|
|
259
|
+
{repo.name}
|
|
260
|
+
<div>
|
|
261
|
+
<a href="#">siemur/test-space</a>
|
|
262
|
+
</div>
|
|
263
|
+
</Td>
|
|
264
|
+
<Td dataLabel={columnNames.branches}>
|
|
265
|
+
<Flex>
|
|
266
|
+
<FlexItem>{repo.branches}</FlexItem>
|
|
267
|
+
<FlexItem>
|
|
268
|
+
<CodeBranchIcon key="icon" />
|
|
269
|
+
</FlexItem>
|
|
270
|
+
</Flex>
|
|
271
|
+
</Td>
|
|
272
|
+
<Td dataLabel={columnNames.prs}>
|
|
273
|
+
<Flex>
|
|
274
|
+
<FlexItem>{repo.prs}</FlexItem>
|
|
275
|
+
<FlexItem>
|
|
276
|
+
<CodeIcon key="icon" />
|
|
277
|
+
</FlexItem>
|
|
278
|
+
</Flex>
|
|
279
|
+
</Td>
|
|
280
|
+
<Td dataLabel={columnNames.workspaces}>
|
|
281
|
+
<Flex>
|
|
282
|
+
<FlexItem>{repo.workspaces}</FlexItem>
|
|
283
|
+
<FlexItem>
|
|
284
|
+
<CubeIcon key="icon" />
|
|
285
|
+
</FlexItem>
|
|
286
|
+
</Flex>
|
|
287
|
+
</Td>
|
|
288
|
+
<Td dataLabel={columnNames.lastCommit}>{repo.lastCommit}</Td>
|
|
289
|
+
<Td key={`${rowIndex}_5`}>
|
|
290
|
+
<ActionsColumn items={defaultActions} actionsToggle={customActionsToggle} />
|
|
291
|
+
</Td>
|
|
292
|
+
</Tr>
|
|
293
|
+
))}
|
|
294
|
+
</Tbody>
|
|
295
|
+
</TableComposable>
|
|
296
|
+
);
|
|
297
|
+
|
|
298
|
+
const panelContent = (
|
|
299
|
+
<DrawerPanelContent widths={{ default: 'width_33', xl: 'width_33' }}>
|
|
300
|
+
<DrawerHead>
|
|
301
|
+
<DrawerActions>
|
|
302
|
+
<DrawerCloseButton
|
|
303
|
+
onClick={() => {
|
|
304
|
+
setRowClicked(null);
|
|
305
|
+
setIsExpanded(false);
|
|
306
|
+
}}
|
|
307
|
+
/>
|
|
308
|
+
</DrawerActions>
|
|
309
|
+
<Flex spaceItems={{ default: 'spaceItemsSm' }} direction={{ default: 'column' }}>
|
|
310
|
+
<FlexItem>
|
|
311
|
+
<Title headingLevel="h2" size="lg">
|
|
312
|
+
{rowClicked}
|
|
313
|
+
</Title>
|
|
314
|
+
</FlexItem>
|
|
315
|
+
<FlexItem>
|
|
316
|
+
<a href="#">siemur/test-space</a>
|
|
317
|
+
</FlexItem>
|
|
318
|
+
</Flex>
|
|
319
|
+
</DrawerHead>
|
|
320
|
+
<DrawerPanelBody hasNoPadding>
|
|
321
|
+
<Tabs
|
|
322
|
+
activeKey={secondaryActiveTabKey}
|
|
323
|
+
onSelect={(_event, tabIndex) => handleSecondaryTabClick(Number(tabIndex))}
|
|
324
|
+
hasBorderBottom={false}
|
|
325
|
+
inset={{ default: 'insetMd', md: 'insetSm' }}
|
|
326
|
+
id="tabs-tables-secondary-tabs"
|
|
327
|
+
>
|
|
328
|
+
<Tab eventKey={10} title={<TabTitleText>Overview</TabTitleText>} tabContentId={`tabContent${10}`} />
|
|
329
|
+
<Tab eventKey={11} title={<TabTitleText>Activity</TabTitleText>} tabContentId={`tabContent${11}`} />
|
|
330
|
+
<Tab eventKey={12} title={<TabTitleText>Status</TabTitleText>} tabContentId={`tabContent${12}`} />
|
|
331
|
+
</Tabs>
|
|
332
|
+
</DrawerPanelBody>
|
|
333
|
+
<DrawerPanelBody>
|
|
334
|
+
<TabContent
|
|
335
|
+
key={10}
|
|
336
|
+
eventKey={10}
|
|
337
|
+
id={`tabContent${10}`}
|
|
338
|
+
activeKey={secondaryActiveTabKey}
|
|
339
|
+
hidden={10 !== secondaryActiveTabKey}
|
|
340
|
+
>
|
|
341
|
+
<TabContentBody>
|
|
342
|
+
<Flex direction={{ default: 'column' }} spaceItems={{ default: 'spaceItemsLg' }}>
|
|
343
|
+
<FlexItem>
|
|
344
|
+
<p>
|
|
345
|
+
The content of the drawer really is up to you. It could have form fields, definition lists, text
|
|
346
|
+
lists, labels, charts, progress bars, etc. Spacing recommendation is 24px margins. You can put tabs in
|
|
347
|
+
here, and can also make the drawer scrollable.
|
|
348
|
+
</p>
|
|
349
|
+
</FlexItem>
|
|
350
|
+
<FlexItem>
|
|
351
|
+
<Progress value={33} title="Capacity" size={ProgressSize.sm} />
|
|
352
|
+
</FlexItem>
|
|
353
|
+
<FlexItem>
|
|
354
|
+
<Progress value={66} title="Modules" size={ProgressSize.sm} />
|
|
355
|
+
</FlexItem>
|
|
356
|
+
<Flex direction={{ default: 'column' }}>
|
|
357
|
+
<FlexItem>
|
|
358
|
+
<Title headingLevel="h3">Tags</Title>
|
|
359
|
+
</FlexItem>
|
|
360
|
+
<FlexItem>
|
|
361
|
+
<LabelGroup>
|
|
362
|
+
{[1, 2, 3, 4, 5].map(labelNumber => (
|
|
363
|
+
<Label variant="outline" key={`label-${labelNumber}`}>{`Tag ${labelNumber}`}</Label>
|
|
364
|
+
))}
|
|
365
|
+
</LabelGroup>
|
|
366
|
+
</FlexItem>
|
|
367
|
+
</Flex>
|
|
368
|
+
</Flex>
|
|
369
|
+
</TabContentBody>
|
|
370
|
+
</TabContent>
|
|
371
|
+
<TabContent
|
|
372
|
+
key={11}
|
|
373
|
+
eventKey={11}
|
|
374
|
+
id={`tabContent${11}`}
|
|
375
|
+
activeKey={secondaryActiveTabKey}
|
|
376
|
+
hidden={11 !== secondaryActiveTabKey}
|
|
377
|
+
>
|
|
378
|
+
<TabContentBody>Activity panel</TabContentBody>
|
|
379
|
+
</TabContent>
|
|
380
|
+
<TabContent
|
|
381
|
+
key={12}
|
|
382
|
+
eventKey={12}
|
|
383
|
+
id={`tabContent${12}`}
|
|
384
|
+
activeKey={secondaryActiveTabKey}
|
|
385
|
+
hidden={12 !== secondaryActiveTabKey}
|
|
386
|
+
>
|
|
387
|
+
<TabContentBody>Status panel</TabContentBody>
|
|
388
|
+
</TabContent>
|
|
389
|
+
</DrawerPanelBody>
|
|
390
|
+
</DrawerPanelContent>
|
|
391
|
+
);
|
|
392
|
+
|
|
393
|
+
const tabContent = (
|
|
394
|
+
<Drawer isExpanded={isExpanded} isInline>
|
|
395
|
+
<DrawerContent panelContent={panelContent}>
|
|
396
|
+
<DrawerContentBody>
|
|
397
|
+
{toolbar}
|
|
398
|
+
<Divider />
|
|
399
|
+
{tableComposable}
|
|
400
|
+
<Pagination
|
|
401
|
+
id="page-layout-table-column-management-action-toolbar-bottom"
|
|
402
|
+
itemCount={36}
|
|
403
|
+
widgetId="pagination-options-menu-bottom"
|
|
404
|
+
page={1}
|
|
405
|
+
variant={PaginationVariant.bottom}
|
|
406
|
+
/>
|
|
407
|
+
</DrawerContentBody>
|
|
408
|
+
</DrawerContent>
|
|
409
|
+
</Drawer>
|
|
410
|
+
);
|
|
411
|
+
|
|
412
|
+
return (
|
|
413
|
+
<DashboardWrapper hasNoBreadcrumb>
|
|
414
|
+
<React.Fragment>
|
|
415
|
+
<PageSection variant={PageSectionVariants.light}>
|
|
416
|
+
<Title headingLevel="h1" size="2xl">
|
|
417
|
+
Nodes
|
|
418
|
+
</Title>
|
|
419
|
+
</PageSection>
|
|
420
|
+
<PageSection type="tabs" variant={PageSectionVariants.light} padding={{ default: 'noPadding' }}>
|
|
421
|
+
<Tabs
|
|
422
|
+
activeKey={activeTabKey}
|
|
423
|
+
onSelect={(_event, tabIndex) => handleTabClick(Number(tabIndex))}
|
|
424
|
+
usePageInsets
|
|
425
|
+
id="tabs-table-tabs-list"
|
|
426
|
+
>
|
|
427
|
+
<Tab eventKey={0} title={<TabTitleText>Nodes</TabTitleText>} tabContentId={`tabContent${0}`} />
|
|
428
|
+
<Tab eventKey={1} title={<TabTitleText>Node connectors</TabTitleText>} tabContentId={`tabContent${1}`} />
|
|
429
|
+
</Tabs>
|
|
430
|
+
</PageSection>
|
|
431
|
+
<PageSection variant={PageSectionVariants.light} padding={{ default: 'noPadding' }}>
|
|
432
|
+
<TabContent key={0} eventKey={0} id={`tabContent${0}`} activeKey={activeTabKey} hidden={0 !== activeTabKey}>
|
|
433
|
+
<TabContentBody>{tabContent}</TabContentBody>
|
|
434
|
+
</TabContent>
|
|
435
|
+
<TabContent key={1} eventKey={1} id={`tabContent${1}`} activeKey={activeTabKey} hidden={1 !== activeTabKey}>
|
|
436
|
+
<TabContentBody>Node connectors panel</TabContentBody>
|
|
437
|
+
</TabContent>
|
|
438
|
+
</PageSection>
|
|
439
|
+
</React.Fragment>
|
|
440
|
+
</DashboardWrapper>
|
|
441
|
+
);
|
|
442
|
+
};
|
|
@@ -14,17 +14,6 @@ const getOppositePlacement = (placement: Placement): any =>
|
|
|
14
14
|
(matched: string) => hash[matched as 'left' | 'right' | 'bottom' | 'top'] as BasePlacement
|
|
15
15
|
);
|
|
16
16
|
|
|
17
|
-
export interface ToggleMenuBaseProps {
|
|
18
|
-
/** The container to append the menu to. Defaults to 'inline'
|
|
19
|
-
* If your menu is being cut off you can append it to an element higher up the DOM tree.
|
|
20
|
-
* Some examples:
|
|
21
|
-
* menuAppendTo="parent"
|
|
22
|
-
* menuAppendTo={() => document.body}
|
|
23
|
-
* menuAppendTo={document.getElementById('target')}
|
|
24
|
-
*/
|
|
25
|
-
menuAppendTo?: HTMLElement | (() => HTMLElement) | 'parent' | 'inline';
|
|
26
|
-
}
|
|
27
|
-
|
|
28
17
|
export const getOpacityTransition = (animationDuration: number) =>
|
|
29
18
|
`opacity ${animationDuration}ms cubic-bezier(.54, 1.5, .38, 1.11)`;
|
|
30
19
|
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This test was generated
|
|
3
|
-
*/
|
|
4
|
-
import * as React from 'react';
|
|
5
|
-
import { render } from '@testing-library/react';
|
|
6
|
-
import { AboutModal } from '../../AboutModal';
|
|
7
|
-
// any missing imports can usually be resolved by adding them here
|
|
8
|
-
import {} from '../..';
|
|
9
|
-
|
|
10
|
-
it('AboutModal should match snapshot (auto-generated)', () => {
|
|
11
|
-
const view = render(
|
|
12
|
-
<AboutModal
|
|
13
|
-
children={<div>ReactNode</div>}
|
|
14
|
-
className={"''"}
|
|
15
|
-
isOpen={false}
|
|
16
|
-
onClose={(): any => undefined}
|
|
17
|
-
productName={"''"}
|
|
18
|
-
trademark={"''"}
|
|
19
|
-
brandImageSrc={'string'}
|
|
20
|
-
brandImageAlt={'string'}
|
|
21
|
-
backgroundImageSrc={"''"}
|
|
22
|
-
noAboutModalBoxContentContainer={false}
|
|
23
|
-
appendTo={null}
|
|
24
|
-
/>
|
|
25
|
-
);
|
|
26
|
-
expect(view.container).toMatchSnapshot();
|
|
27
|
-
});
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This test was generated
|
|
3
|
-
*/
|
|
4
|
-
import * as React from 'react';
|
|
5
|
-
import { render } from '@testing-library/react';
|
|
6
|
-
import { AboutModalBox } from '../../AboutModalBox';
|
|
7
|
-
// any missing imports can usually be resolved by adding them here
|
|
8
|
-
import {} from '../..';
|
|
9
|
-
|
|
10
|
-
it('AboutModalBox should match snapshot (auto-generated)', () => {
|
|
11
|
-
const view = render(<AboutModalBox children={<div>ReactNode</div>} className={"''"} />);
|
|
12
|
-
expect(view.container).toMatchSnapshot();
|
|
13
|
-
});
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This test was generated
|
|
3
|
-
*/
|
|
4
|
-
import * as React from 'react';
|
|
5
|
-
import { render } from '@testing-library/react';
|
|
6
|
-
import { AboutModalBoxBrand } from '../../AboutModalBoxBrand';
|
|
7
|
-
// any missing imports can usually be resolved by adding them here
|
|
8
|
-
import {} from '../..';
|
|
9
|
-
|
|
10
|
-
it('AboutModalBoxBrand should match snapshot (auto-generated)', () => {
|
|
11
|
-
const view = render(<AboutModalBoxBrand className={"''"} src={"''"} alt={'string'} />);
|
|
12
|
-
expect(view.container).toMatchSnapshot();
|
|
13
|
-
});
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This test was generated
|
|
3
|
-
*/
|
|
4
|
-
import * as React from 'react';
|
|
5
|
-
import { render } from '@testing-library/react';
|
|
6
|
-
import { AboutModalBoxCloseButton } from '../../AboutModalBoxCloseButton';
|
|
7
|
-
// any missing imports can usually be resolved by adding them here
|
|
8
|
-
import {} from '../..';
|
|
9
|
-
|
|
10
|
-
it('AboutModalBoxCloseButton should match snapshot (auto-generated)', () => {
|
|
11
|
-
const view = render(<AboutModalBoxCloseButton className={"''"} onClose={() => undefined as any} />);
|
|
12
|
-
expect(view.container).toMatchSnapshot();
|
|
13
|
-
});
|
|
@@ -1,21 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This test was generated
|
|
3
|
-
*/
|
|
4
|
-
import * as React from 'react';
|
|
5
|
-
import { render } from '@testing-library/react';
|
|
6
|
-
import { AboutModalBoxContent } from '../../AboutModalBoxContent';
|
|
7
|
-
// any missing imports can usually be resolved by adding them here
|
|
8
|
-
import {} from '../..';
|
|
9
|
-
|
|
10
|
-
it('AboutModalBoxContent should match snapshot (auto-generated)', () => {
|
|
11
|
-
const view = render(
|
|
12
|
-
<AboutModalBoxContent
|
|
13
|
-
children={<div>ReactNode</div>}
|
|
14
|
-
className={"''"}
|
|
15
|
-
id={'string'}
|
|
16
|
-
trademark={'string'}
|
|
17
|
-
noAboutModalBoxContentContainer={false}
|
|
18
|
-
/>
|
|
19
|
-
);
|
|
20
|
-
expect(view.container).toMatchSnapshot();
|
|
21
|
-
});
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This test was generated
|
|
3
|
-
*/
|
|
4
|
-
import * as React from 'react';
|
|
5
|
-
import { render } from '@testing-library/react';
|
|
6
|
-
import { AboutModalBoxHeader } from '../../AboutModalBoxHeader';
|
|
7
|
-
// any missing imports can usually be resolved by adding them here
|
|
8
|
-
import {} from '../..';
|
|
9
|
-
|
|
10
|
-
it('AboutModalBoxHeader should match snapshot (auto-generated)', () => {
|
|
11
|
-
const view = render(<AboutModalBoxHeader className={"''"} productName={"''"} id={'string'} />);
|
|
12
|
-
expect(view.container).toMatchSnapshot();
|
|
13
|
-
});
|
|
@@ -1,13 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This test was generated
|
|
3
|
-
*/
|
|
4
|
-
import * as React from 'react';
|
|
5
|
-
import { render } from '@testing-library/react';
|
|
6
|
-
import { AboutModalBoxHero } from '../../AboutModalBoxHero';
|
|
7
|
-
// any missing imports can usually be resolved by adding them here
|
|
8
|
-
import {} from '../..';
|
|
9
|
-
|
|
10
|
-
it('AboutModalBoxHero should match snapshot (auto-generated)', () => {
|
|
11
|
-
const view = render(<AboutModalBoxHero className={'string'} backgroundImageSrc={'string'} />);
|
|
12
|
-
expect(view.container).toMatchSnapshot();
|
|
13
|
-
});
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* This test was generated
|
|
3
|
-
*/
|
|
4
|
-
import * as React from 'react';
|
|
5
|
-
import { render } from '@testing-library/react';
|
|
6
|
-
import { AboutModalContainer } from '../../AboutModalContainer';
|
|
7
|
-
// any missing imports can usually be resolved by adding them here
|
|
8
|
-
import {} from '../..';
|
|
9
|
-
|
|
10
|
-
it('AboutModalContainer should match snapshot (auto-generated)', () => {
|
|
11
|
-
const view = render(
|
|
12
|
-
<AboutModalContainer
|
|
13
|
-
children={<div>ReactNode</div>}
|
|
14
|
-
className={"''"}
|
|
15
|
-
isOpen={false}
|
|
16
|
-
onClose={() => undefined}
|
|
17
|
-
productName={"''"}
|
|
18
|
-
trademark={'string'}
|
|
19
|
-
brandImageSrc={'string'}
|
|
20
|
-
brandImageAlt={'string'}
|
|
21
|
-
backgroundImageSrc={'string'}
|
|
22
|
-
aria-labelledby={'string'}
|
|
23
|
-
aria-describedby={'string'}
|
|
24
|
-
/>
|
|
25
|
-
);
|
|
26
|
-
expect(view.container).toMatchSnapshot();
|
|
27
|
-
});
|
package/src/components/AboutModal/__tests__/Generated/__snapshots__/AboutModalBox.test.tsx.snap
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
-
|
|
3
|
-
exports[`AboutModalBox should match snapshot (auto-generated) 1`] = `
|
|
4
|
-
<div>
|
|
5
|
-
<div
|
|
6
|
-
aria-modal="true"
|
|
7
|
-
class="pf-c-about-modal-box ''"
|
|
8
|
-
role="dialog"
|
|
9
|
-
>
|
|
10
|
-
<div>
|
|
11
|
-
ReactNode
|
|
12
|
-
</div>
|
|
13
|
-
</div>
|
|
14
|
-
</div>
|
|
15
|
-
`;
|
package/src/components/AboutModal/__tests__/Generated/__snapshots__/AboutModalBoxBrand.test.tsx.snap
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
-
|
|
3
|
-
exports[`AboutModalBoxBrand should match snapshot (auto-generated) 1`] = `
|
|
4
|
-
<div>
|
|
5
|
-
<div
|
|
6
|
-
class="pf-c-about-modal-box__brand ''"
|
|
7
|
-
>
|
|
8
|
-
<img
|
|
9
|
-
alt="string"
|
|
10
|
-
class="pf-c-about-modal-box__brand-image"
|
|
11
|
-
src="''"
|
|
12
|
-
/>
|
|
13
|
-
</div>
|
|
14
|
-
</div>
|
|
15
|
-
`;
|
|
@@ -1,33 +0,0 @@
|
|
|
1
|
-
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
|
2
|
-
|
|
3
|
-
exports[`AboutModalBoxCloseButton should match snapshot (auto-generated) 1`] = `
|
|
4
|
-
<div>
|
|
5
|
-
<div
|
|
6
|
-
class="pf-c-about-modal-box__close ''"
|
|
7
|
-
>
|
|
8
|
-
<button
|
|
9
|
-
aria-disabled="false"
|
|
10
|
-
aria-label="Close Dialog"
|
|
11
|
-
class="pf-c-button pf-m-plain"
|
|
12
|
-
data-ouia-component-id="OUIA-Generated-Button-plain-1"
|
|
13
|
-
data-ouia-component-type="PF4/Button"
|
|
14
|
-
data-ouia-safe="true"
|
|
15
|
-
type="button"
|
|
16
|
-
>
|
|
17
|
-
<svg
|
|
18
|
-
aria-hidden="true"
|
|
19
|
-
fill="currentColor"
|
|
20
|
-
height="1em"
|
|
21
|
-
role="img"
|
|
22
|
-
style="vertical-align: -0.125em;"
|
|
23
|
-
viewBox="0 0 352 512"
|
|
24
|
-
width="1em"
|
|
25
|
-
>
|
|
26
|
-
<path
|
|
27
|
-
d="M242.72 256l100.07-100.07c12.28-12.28 12.28-32.19 0-44.48l-22.24-22.24c-12.28-12.28-32.19-12.28-44.48 0L176 189.28 75.93 89.21c-12.28-12.28-32.19-12.28-44.48 0L9.21 111.45c-12.28 12.28-12.28 32.19 0 44.48L109.28 256 9.21 356.07c-12.28 12.28-12.28 32.19 0 44.48l22.24 22.24c12.28 12.28 32.2 12.28 44.48 0L176 322.72l100.07 100.07c12.28 12.28 32.2 12.28 44.48 0l22.24-22.24c12.28-12.28 12.28-32.19 0-44.48L242.72 256z"
|
|
28
|
-
/>
|
|
29
|
-
</svg>
|
|
30
|
-
</button>
|
|
31
|
-
</div>
|
|
32
|
-
</div>
|
|
33
|
-
`;
|