@plesk/ui-library 3.31.2 → 3.32.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/cjs/components/Action/Action.js +20 -12
- package/cjs/components/Alert/Alert.js +9 -8
- package/cjs/components/Alert/Alert.stories.js +19 -12
- package/cjs/components/AutoClosable/AutoClosable.js +7 -9
- package/cjs/components/AuxiliaryActions/AuxiliaryActions.js +14 -12
- package/cjs/components/Badge/Badge.js +11 -10
- package/cjs/components/Breadcrumbs/Breadcrumbs.js +18 -15
- package/cjs/components/Button/Button.js +34 -25
- package/cjs/components/Button/Button.stories.js +82 -49
- package/cjs/components/Button/ButtonContext.js +27 -0
- package/cjs/components/ButtonGroup/ButtonGroup.js +6 -5
- package/cjs/components/Card/Card.js +132 -109
- package/cjs/components/Card/CardButton.js +5 -4
- package/cjs/components/Card/PreviewPanel.js +24 -21
- package/cjs/components/CardList/CardList.js +57 -50
- package/cjs/components/CardList/CardListToolbar.js +47 -40
- package/cjs/components/Carousel/Carousel.js +42 -35
- package/cjs/components/Checkbox/Checkbox.js +27 -22
- package/cjs/components/ClosingConfirmation/useClosingConfirmation.js +24 -22
- package/cjs/components/CodeEditor/CodeEditor.js +5 -5
- package/cjs/components/Columns/Column.js +7 -7
- package/cjs/components/Columns/Columns.js +18 -14
- package/cjs/components/ComboBox/ComboBox.js +17 -13
- package/cjs/components/ComboBox/ComboBoxOption.js +2 -3
- package/cjs/components/ComboBoxDropdown/ComboBoxDropdown.js +73 -68
- package/cjs/components/ConsoleOutput/ConsoleOutput.js +9 -9
- package/cjs/components/ContentLoader/ContentLoader.js +24 -16
- package/cjs/components/ContentLoader/IconsLoader.js +19 -17
- package/cjs/components/Cuttable/Cuttable.js +33 -30
- package/cjs/components/Cuttable/Cuttable.stories.js +27 -5
- package/cjs/components/Dialog/Dialog.js +74 -54
- package/cjs/components/Dialog/Dialog.stories.js +18 -14
- package/cjs/components/Drawer/Drawer.js +60 -50
- package/cjs/components/Drawer/Drawer.stories.js +24 -16
- package/cjs/components/Drawer/DrawerProgress.js +40 -31
- package/cjs/components/Drawer/Header.js +34 -26
- package/cjs/components/Dropdown/Dropdown.js +49 -41
- package/cjs/components/ExtendedStatusMessage/ExtendedStatusMessage.js +21 -17
- package/cjs/components/ExtendedStatusMessage/ExtendedStatusMessageActions.js +6 -5
- package/cjs/components/ExtendedStatusMessage/ExtendedStatusMessageDescription.js +6 -5
- package/cjs/components/ExtendedStatusMessage/ExtendedStatusMessageSeparator.js +5 -5
- package/cjs/components/ExtendedStatusMessage/ExtendedStatusMessageTitle.js +6 -5
- package/cjs/components/Figure/Figure.js +12 -9
- package/cjs/components/FocusTrap/FocusTrap.js +13 -14
- package/cjs/components/Form/Form.js +89 -75
- package/cjs/components/Form/Form.stories.js +8 -9
- package/cjs/components/FormField/FormField.js +55 -50
- package/cjs/components/FormFieldCheckbox/FormFieldCheckbox.js +36 -29
- package/cjs/components/FormFieldCheckbox/FormFieldCheckbox.stories.js +9 -3
- package/cjs/components/FormFieldPassword/FormFieldPassword.js +74 -66
- package/cjs/components/FormFieldPassword/PasswordMeter.js +34 -23
- package/cjs/components/FormFieldPassword/estimatePassword.js +11 -11
- package/cjs/components/FormFieldRadioButtons/FormFieldRadioButtons.js +54 -50
- package/cjs/components/FormFieldSelect/FormFieldSelect.js +26 -24
- package/cjs/components/FormFieldText/FormFieldText.js +39 -35
- package/cjs/components/Grid/Grid.js +16 -13
- package/cjs/components/GridCol/GridCol.js +7 -7
- package/cjs/components/Heading/Heading.js +12 -10
- package/cjs/components/Hint/Hint.js +6 -5
- package/cjs/components/Icon/Icon.js +15 -14
- package/cjs/components/Icon/Icon.stories.js +15 -12
- package/cjs/components/Icon/utils.js +9 -6
- package/cjs/components/InPlaceEdit/InPlaceEdit.js +54 -49
- package/cjs/components/Input/Input.js +18 -14
- package/cjs/components/InputFile/InputFile.js +45 -42
- package/cjs/components/InputNumber/InputNumber.js +8 -10
- package/cjs/components/Item/Item.js +34 -22
- package/cjs/components/ItemLink/ItemLink.js +9 -7
- package/cjs/components/ItemLink/ItemLink.stories.js +4 -2
- package/cjs/components/ItemList/ItemList.js +39 -31
- package/cjs/components/ItemList/ItemList.stories.js +26 -27
- package/cjs/components/Label/Label.js +41 -8
- package/cjs/components/Layer/Layer.js +11 -10
- package/cjs/components/Layout/Layout.js +129 -101
- package/cjs/components/Link/Link.js +10 -10
- package/cjs/components/List/List.js +338 -279
- package/cjs/components/List/List.stories.js +21 -19
- package/cjs/components/List/ListAction.js +10 -8
- package/cjs/components/List/ListActions.js +21 -19
- package/cjs/components/List/ListActionsDivider.js +4 -3
- package/cjs/components/List/ListEmptyView.js +38 -23
- package/cjs/components/List/ListOperation.js +28 -21
- package/cjs/components/LocaleProvider/LocaleProvider.js +6 -6
- package/cjs/components/Markdown/Markdown.js +5 -4
- package/cjs/components/Media/Media.js +30 -22
- package/cjs/components/Media/MediaSection.js +7 -6
- package/cjs/components/Menu/Menu.js +7 -6
- package/cjs/components/Menu/Menu.stories.js +35 -33
- package/cjs/components/Menu/MenuBaseItem.js +18 -14
- package/cjs/components/Menu/MenuDivider.js +6 -6
- package/cjs/components/Menu/MenuHeader.js +7 -6
- package/cjs/components/Menu/MenuItem.js +12 -9
- package/cjs/components/Menu/MenuSelectableItem.js +7 -6
- package/cjs/components/Overlay/Backdrop.js +5 -4
- package/cjs/components/Overlay/Overlay.js +63 -52
- package/cjs/components/PageHeader/PageHeader.js +36 -25
- package/cjs/components/Pagination/Pagination.js +72 -66
- package/cjs/components/Panel/Panel.js +38 -36
- package/cjs/components/Paragraph/Paragraph.js +6 -5
- package/cjs/components/Plaintext/Plaintext.js +5 -3
- package/cjs/components/Popover/Popover.js +43 -34
- package/cjs/components/Popover/Popover.stories.js +33 -15
- package/cjs/components/Popper/Popper.js +19 -17
- package/cjs/components/Progress/Progress.js +6 -4
- package/cjs/components/ProgressBar/ProgressBar.js +10 -10
- package/cjs/components/ProgressBar/ProgressIndicator.js +5 -5
- package/cjs/components/ProgressDialog/ProgressDialog.js +16 -13
- package/cjs/components/ProgressDialogStep/ProgressDialogStep.js +5 -3
- package/cjs/components/ProgressStep/ProgressStep.js +34 -23
- package/cjs/components/Radio/Radio.js +21 -18
- package/cjs/components/Rating/Rating.js +10 -8
- package/cjs/components/Section/Section.js +55 -50
- package/cjs/components/Section/SectionItem.js +12 -8
- package/cjs/components/SegmentedControl/SegmentedControl.js +86 -75
- package/cjs/components/Select/MultiValue.js +26 -21
- package/cjs/components/Select/Select.js +8 -7
- package/cjs/components/Select/Select.stories.js +41 -40
- package/cjs/components/Select/SelectControl.js +87 -77
- package/cjs/components/Select/SelectOption.js +2 -3
- package/cjs/components/Select/SelectOptionGroup.js +2 -3
- package/cjs/components/Skeleton/Skeleton.js +5 -5
- package/cjs/components/Skeleton/Skeleton.stories.js +7 -3
- package/cjs/components/Skeleton/SkeletonTabs.js +11 -10
- package/cjs/components/Skeleton/SkeletonTabs.stories.js +4 -2
- package/cjs/components/Skeleton/SkeletonText.js +13 -13
- package/cjs/components/Skeleton/SkeletonText.stories.js +10 -4
- package/cjs/components/Spinner/Spinner.js +15 -15
- package/cjs/components/SplitButton/SplitButton.js +18 -14
- package/cjs/components/Spot/Spot.js +19 -15
- package/cjs/components/Spot/SpotPopup.js +33 -29
- package/cjs/components/Spot/SpotPulsar.js +12 -13
- package/cjs/components/Squeezer/Squeezer.js +11 -13
- package/cjs/components/Status/Status.js +7 -7
- package/cjs/components/Status/Status.stories.js +4 -2
- package/cjs/components/StatusMessage/StatusMessage.js +9 -8
- package/cjs/components/Subnav/Subnav.js +7 -6
- package/cjs/components/Switch/Switch.js +21 -17
- package/cjs/components/SwitchesPanel/SwitchesPanel.js +11 -8
- package/cjs/components/SwitchesPanelItem/SwitchesPanelItem.js +34 -26
- package/cjs/components/Tabs/SearchBar.js +57 -51
- package/cjs/components/Tabs/Tab.js +5 -3
- package/cjs/components/Tabs/Tabs.js +157 -129
- package/cjs/components/Tabs/Tabs.stories.js +8 -6
- package/cjs/components/Text/Text.js +7 -7
- package/cjs/components/TextArea/TextArea.js +6 -7
- package/cjs/components/Toast/Toast.js +32 -29
- package/cjs/components/Toaster/Toaster.js +54 -48
- package/cjs/components/Toolbar/Toolbar.js +19 -14
- package/cjs/components/Toolbar/ToolbarExpander.js +7 -7
- package/cjs/components/Toolbar/ToolbarGroup.js +23 -17
- package/cjs/components/Toolbar/ToolbarItem.js +11 -9
- package/cjs/components/Toolbar/ToolbarMenu.js +21 -15
- package/cjs/components/Tooltip/Tooltip.js +26 -21
- package/cjs/components/Tour/Tour.js +3 -4
- package/cjs/components/Translate/Translate.js +4 -1
- package/cjs/components/utils.js +4 -8
- package/cjs/index.js +1 -1
- package/cjs/utils.js +0 -2
- package/dist/.DS_Store +0 -0
- package/dist/plesk-ui-library-rtl.css +1 -1
- package/dist/plesk-ui-library-rtl.css.map +1 -1
- package/dist/plesk-ui-library.css +1 -1
- package/dist/plesk-ui-library.css.map +1 -1
- package/dist/plesk-ui-library.js +4755 -2803
- package/dist/plesk-ui-library.js.map +1 -1
- package/dist/plesk-ui-library.min.js +19 -6
- package/dist/plesk-ui-library.min.js.map +1 -1
- package/esm/components/Action/Action.js +21 -12
- package/esm/components/Alert/Alert.js +10 -8
- package/esm/components/Alert/Alert.stories.js +21 -12
- package/esm/components/AutoClosable/AutoClosable.js +7 -7
- package/esm/components/AuxiliaryActions/AuxiliaryActions.js +14 -10
- package/esm/components/Badge/Badge.js +12 -8
- package/esm/components/Breadcrumbs/Breadcrumbs.js +19 -13
- package/esm/components/Button/Button.js +35 -26
- package/esm/components/Button/Button.stories.js +84 -49
- package/esm/components/Button/ButtonContext.js +18 -0
- package/esm/components/ButtonGroup/ButtonGroup.js +6 -5
- package/esm/components/Card/Card.js +133 -109
- package/esm/components/Card/CardButton.js +5 -4
- package/esm/components/Card/PreviewPanel.js +25 -19
- package/esm/components/CardList/CardList.js +58 -50
- package/esm/components/CardList/CardListToolbar.js +47 -40
- package/esm/components/Carousel/Carousel.js +43 -35
- package/esm/components/Checkbox/Checkbox.js +28 -22
- package/esm/components/ClosingConfirmation/useClosingConfirmation.js +24 -20
- package/esm/components/CodeEditor/CodeEditor.js +5 -6
- package/esm/components/Columns/Column.js +7 -5
- package/esm/components/Columns/Columns.js +18 -14
- package/esm/components/ComboBox/ComboBox.js +17 -13
- package/esm/components/ComboBox/ComboBoxOption.js +2 -2
- package/esm/components/ComboBoxDropdown/ComboBoxDropdown.js +75 -68
- package/esm/components/ConsoleOutput/ConsoleOutput.js +10 -7
- package/esm/components/ContentLoader/ContentLoader.js +25 -14
- package/esm/components/ContentLoader/IconsLoader.js +20 -15
- package/esm/components/Cuttable/Cuttable.js +34 -28
- package/esm/components/Cuttable/Cuttable.stories.js +29 -5
- package/esm/components/Dialog/Dialog.js +75 -53
- package/esm/components/Dialog/Dialog.stories.js +20 -12
- package/esm/components/Drawer/Drawer.js +61 -50
- package/esm/components/Drawer/Drawer.stories.js +26 -14
- package/esm/components/Drawer/DrawerProgress.js +41 -31
- package/esm/components/Drawer/Header.js +35 -26
- package/esm/components/Dropdown/Dropdown.js +51 -41
- package/esm/components/ExtendedStatusMessage/ExtendedStatusMessage.js +22 -17
- package/esm/components/ExtendedStatusMessage/ExtendedStatusMessageActions.js +6 -5
- package/esm/components/ExtendedStatusMessage/ExtendedStatusMessageDescription.js +6 -5
- package/esm/components/ExtendedStatusMessage/ExtendedStatusMessageSeparator.js +5 -5
- package/esm/components/ExtendedStatusMessage/ExtendedStatusMessageTitle.js +6 -5
- package/esm/components/Figure/Figure.js +13 -9
- package/esm/components/FocusTrap/FocusTrap.js +14 -11
- package/esm/components/Form/Form.js +90 -75
- package/esm/components/Form/Form.stories.js +8 -9
- package/esm/components/FormField/FormField.js +56 -50
- package/esm/components/FormFieldCheckbox/FormFieldCheckbox.js +38 -29
- package/esm/components/FormFieldCheckbox/FormFieldCheckbox.stories.js +9 -3
- package/esm/components/FormFieldPassword/FormFieldPassword.js +75 -64
- package/esm/components/FormFieldPassword/PasswordMeter.js +36 -23
- package/esm/components/FormFieldPassword/estimatePassword.js +11 -11
- package/esm/components/FormFieldRadioButtons/FormFieldRadioButtons.js +55 -50
- package/esm/components/FormFieldSelect/FormFieldSelect.js +26 -24
- package/esm/components/FormFieldText/FormFieldText.js +39 -35
- package/esm/components/Grid/Grid.js +16 -13
- package/esm/components/GridCol/GridCol.js +6 -5
- package/esm/components/Heading/Heading.js +13 -10
- package/esm/components/Hint/Hint.js +6 -5
- package/esm/components/Icon/Icon.js +15 -12
- package/esm/components/Icon/Icon.stories.js +15 -12
- package/esm/components/Icon/utils.js +9 -6
- package/esm/components/InPlaceEdit/InPlaceEdit.js +55 -49
- package/esm/components/Input/Input.js +19 -14
- package/esm/components/InputFile/InputFile.js +47 -40
- package/esm/components/InputNumber/InputNumber.js +8 -8
- package/esm/components/Item/Item.js +35 -22
- package/esm/components/ItemLink/ItemLink.js +9 -7
- package/esm/components/ItemLink/ItemLink.stories.js +4 -2
- package/esm/components/ItemList/ItemList.js +39 -31
- package/esm/components/ItemList/ItemList.stories.js +26 -25
- package/esm/components/Label/Label.js +42 -8
- package/esm/components/Layer/Layer.js +11 -8
- package/esm/components/Layout/Layout.js +130 -101
- package/esm/components/Link/Link.js +11 -9
- package/esm/components/List/List.js +341 -280
- package/esm/components/List/List.stories.js +22 -17
- package/esm/components/List/ListAction.js +10 -8
- package/esm/components/List/ListActions.js +22 -17
- package/esm/components/List/ListActionsDivider.js +4 -2
- package/esm/components/List/ListEmptyView.js +39 -23
- package/esm/components/List/ListOperation.js +29 -19
- package/esm/components/LocaleProvider/LocaleProvider.js +6 -4
- package/esm/components/Markdown/Markdown.js +5 -4
- package/esm/components/Media/Media.js +31 -22
- package/esm/components/Media/MediaSection.js +6 -4
- package/esm/components/Menu/Menu.js +7 -6
- package/esm/components/Menu/Menu.stories.js +35 -33
- package/esm/components/Menu/MenuBaseItem.js +18 -12
- package/esm/components/Menu/MenuDivider.js +5 -4
- package/esm/components/Menu/MenuHeader.js +6 -4
- package/esm/components/Menu/MenuItem.js +11 -7
- package/esm/components/Menu/MenuSelectableItem.js +6 -4
- package/esm/components/Overlay/Backdrop.js +5 -4
- package/esm/components/Overlay/Overlay.js +65 -53
- package/esm/components/PageHeader/PageHeader.js +37 -23
- package/esm/components/Pagination/Pagination.js +73 -66
- package/esm/components/Panel/Panel.js +39 -34
- package/esm/components/Paragraph/Paragraph.js +6 -5
- package/esm/components/Plaintext/Plaintext.js +5 -3
- package/esm/components/Popover/Popover.js +44 -34
- package/esm/components/Popover/Popover.stories.js +35 -15
- package/esm/components/Popper/Popper.js +19 -15
- package/esm/components/Progress/Progress.js +6 -4
- package/esm/components/ProgressBar/ProgressBar.js +10 -8
- package/esm/components/ProgressBar/ProgressIndicator.js +5 -5
- package/esm/components/ProgressDialog/ProgressDialog.js +17 -13
- package/esm/components/ProgressDialogStep/ProgressDialogStep.js +4 -1
- package/esm/components/ProgressStep/ProgressStep.js +35 -23
- package/esm/components/Radio/Radio.js +22 -18
- package/esm/components/Rating/Rating.js +10 -8
- package/esm/components/Section/Section.js +56 -50
- package/esm/components/Section/SectionItem.js +13 -8
- package/esm/components/SegmentedControl/SegmentedControl.js +87 -75
- package/esm/components/Select/MultiValue.js +27 -21
- package/esm/components/Select/Select.js +8 -7
- package/esm/components/Select/Select.stories.js +41 -40
- package/esm/components/Select/SelectControl.js +88 -75
- package/esm/components/Select/SelectOption.js +2 -2
- package/esm/components/Select/SelectOptionGroup.js +2 -2
- package/esm/components/Skeleton/Skeleton.js +5 -5
- package/esm/components/Skeleton/Skeleton.stories.js +7 -3
- package/esm/components/Skeleton/SkeletonTabs.js +11 -10
- package/esm/components/Skeleton/SkeletonTabs.stories.js +4 -2
- package/esm/components/Skeleton/SkeletonText.js +13 -13
- package/esm/components/Skeleton/SkeletonText.stories.js +10 -4
- package/esm/components/Spinner/Spinner.js +15 -15
- package/esm/components/SplitButton/SplitButton.js +19 -14
- package/esm/components/Spot/Spot.js +19 -13
- package/esm/components/Spot/SpotPopup.js +34 -28
- package/esm/components/Spot/SpotPulsar.js +13 -11
- package/esm/components/Squeezer/Squeezer.js +11 -11
- package/esm/components/Status/Status.js +7 -5
- package/esm/components/Status/Status.stories.js +4 -2
- package/esm/components/StatusMessage/StatusMessage.js +10 -8
- package/esm/components/Subnav/Subnav.js +7 -6
- package/esm/components/Switch/Switch.js +22 -17
- package/esm/components/SwitchesPanel/SwitchesPanel.js +11 -8
- package/esm/components/SwitchesPanelItem/SwitchesPanelItem.js +35 -26
- package/esm/components/Tabs/SearchBar.js +60 -52
- package/esm/components/Tabs/Tab.js +4 -1
- package/esm/components/Tabs/Tabs.js +158 -129
- package/esm/components/Tabs/Tabs.stories.js +8 -6
- package/esm/components/Text/Text.js +7 -5
- package/esm/components/TextArea/TextArea.js +6 -5
- package/esm/components/Toast/Toast.js +33 -27
- package/esm/components/Toaster/Toaster.js +54 -46
- package/esm/components/Toolbar/Toolbar.js +19 -14
- package/esm/components/Toolbar/ToolbarExpander.js +7 -5
- package/esm/components/Toolbar/ToolbarGroup.js +22 -15
- package/esm/components/Toolbar/ToolbarItem.js +11 -7
- package/esm/components/Toolbar/ToolbarMenu.js +21 -15
- package/esm/components/Tooltip/Tooltip.js +27 -21
- package/esm/components/Tour/Tour.js +3 -2
- package/esm/components/Translate/Translate.js +4 -1
- package/esm/components/utils.js +4 -8
- package/esm/index.js +1 -1
- package/esm/utils.js +1 -3
- package/package.json +56 -60
- package/styleguide/build/bundle.57b0e524.js +2 -0
- package/styleguide/build/{bundle.26082873.js.LICENSE.txt → bundle.57b0e524.js.LICENSE.txt} +13 -4
- package/styleguide/index.html +2 -2
- package/types/src/components/Alert/Alert.stories.d.ts +5 -8
- package/types/src/components/AutoClosable/AutoClosable.d.ts +2 -23
- package/types/src/components/Button/Button.stories.d.ts +4 -2
- package/types/src/components/Button/ButtonContext.d.ts +8 -0
- package/types/src/components/ClosingConfirmation/useClosingConfirmation.d.ts +2 -2
- package/types/src/components/Cuttable/Cuttable.d.ts +2 -2
- package/types/src/components/Cuttable/Cuttable.stories.d.ts +6 -23
- package/types/src/components/Dialog/Dialog.stories.d.ts +6 -2
- package/types/src/components/Drawer/Drawer.stories.d.ts +8 -4
- package/types/src/components/Drawer/DrawerProgress.d.ts +1 -1
- package/types/src/components/FocusTrap/FocusTrap.d.ts +2 -2
- package/types/src/components/Form/Form.d.ts +17 -17
- package/types/src/components/Form/Form.stories.d.ts +3 -1
- package/types/src/components/FormFieldCheckbox/FormFieldCheckbox.stories.d.ts +6 -2
- package/types/src/components/FormFieldSelect/FormFieldSelect.d.ts +0 -1
- package/types/src/components/Icon/Icon.d.ts +0 -1
- package/types/src/components/Icon/Icon.stories.d.ts +3 -1
- package/types/src/components/Input/Input.d.ts +0 -1
- package/types/src/components/ItemLink/ItemLink.stories.d.ts +5 -7
- package/types/src/components/ItemList/ItemList.d.ts +2 -2
- package/types/src/components/ItemList/ItemList.stories.d.ts +46 -175
- package/types/src/components/Label/Label.d.ts +32 -5
- package/types/src/components/Layer/Layer.d.ts +3 -3
- package/types/src/components/List/List.stories.d.ts +9 -7
- package/types/src/components/List/ListActionsDivider.d.ts +4 -4
- package/types/src/components/Menu/Menu.stories.d.ts +5 -3
- package/types/src/components/Panel/Panel.d.ts +2 -2
- package/types/src/components/Popover/Popover.stories.d.ts +7 -3
- package/types/src/components/Select/Select.d.ts +0 -1
- package/types/src/components/Select/Select.stories.d.ts +5 -16
- package/types/src/components/Select/SelectControl.d.ts +2 -2
- package/types/src/components/Skeleton/Skeleton.d.ts +1 -1
- package/types/src/components/Skeleton/Skeleton.stories.d.ts +6 -3
- package/types/src/components/Skeleton/SkeletonTabs.stories.d.ts +5 -6
- package/types/src/components/Skeleton/SkeletonText.d.ts +1 -1
- package/types/src/components/Skeleton/SkeletonText.stories.d.ts +7 -22
- package/types/src/components/Spot/SpotPulsar.d.ts +2 -3
- package/types/src/components/Status/Status.stories.d.ts +5 -16
- package/types/src/components/Tabs/Tabs.stories.d.ts +5 -1
- package/types/src/components/TextArea/TextArea.d.ts +4 -4
- package/types/src/components/Toolbar/ToolbarItem.d.ts +2 -2
- package/types/src/components/Toolbar/ToolbarMenu.d.ts +2 -2
- package/types/src/components/utils.d.ts +5 -5
- package/types/src/utils.d.ts +0 -1
- package/cjs/components/Drawer/ScrollDirection.js +0 -45
- package/esm/components/Drawer/ScrollDirection.js +0 -37
- package/styleguide/build/bundle.26082873.js +0 -2
- package/styleguide/images/default.svg +0 -1
- package/styleguide/images/empty-list_256.png +0 -0
- package/styleguide/images/filtered.svg +0 -1
- package/styleguide/patterns/controls/control-button-tooltip-1-do.png +0 -0
- package/styleguide/patterns/controls/control-button-tooltip-1-dont.png +0 -0
- package/styleguide/patterns/controls/control-button-tooltip-2-do.png +0 -0
- package/styleguide/patterns/controls/control-button-tooltip-2-dont.png +0 -0
- package/styleguide/patterns/controls/control-button-tooltip-3-do.png +0 -0
- package/styleguide/patterns/controls/control-button-tooltip-3-dont.png +0 -0
- package/styleguide/patterns/dialogsWindows/autoclose.png +0 -0
- package/styleguide/patterns/dialogsWindows/focus.png +0 -0
- package/styleguide/patterns/dialogsWindows/header.png +0 -0
- package/styleguide/patterns/dialogsWindows/image.png +0 -0
- package/styleguide/patterns/dialogsWindows/list_submit.png +0 -0
- package/styleguide/patterns/dialogsWindows/new_object.png +0 -0
- package/styleguide/patterns/dialogsWindows/popover-confirm.png +0 -0
- package/styleguide/patterns/dialogsWindows/popover.png +0 -0
- package/styleguide/patterns/dialogsWindows/similar_buttons.png +0 -0
- package/styleguide/patterns/dialogsWindows/submit.png +0 -0
- package/styleguide/patterns/dialogsWindows/toast_controls.png +0 -0
- package/styleguide/patterns/dialogsWindows/toaster_intent.png +0 -0
- package/styleguide/patterns/dialogsWindows/tooltip.png +0 -0
- package/styleguide/patterns/dialogsWindows/tour.png +0 -0
- package/styleguide/patterns/dialogsWindows/when_to_show.png +0 -0
- package/styleguide/patterns/dialogsWindows/width.png +0 -0
- package/types/package.d.ts +0 -138
|
@@ -1,9 +1,6 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
1
|
import _defineProperty from "@babel/runtime/helpers/defineProperty";
|
|
3
2
|
// Copyright 1999-2020. Plesk International GmbH. All rights reserved.
|
|
4
3
|
|
|
5
|
-
/* eslint-disable react/no-deprecated */
|
|
6
|
-
|
|
7
4
|
import React, { Component, createRef } from 'react';
|
|
8
5
|
import PropTypes from 'prop-types';
|
|
9
6
|
import classNames from 'classnames';
|
|
@@ -14,6 +11,8 @@ import Dropdown from '../Dropdown';
|
|
|
14
11
|
import Menu, { MenuItem } from '../Menu';
|
|
15
12
|
import Squeezer from '../Squeezer';
|
|
16
13
|
import ResponsiveContext from '../ResponsiveContext';
|
|
14
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
15
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
17
16
|
const alphaSort = (a, b) => a > b ? 1 : -1;
|
|
18
17
|
|
|
19
18
|
/**
|
|
@@ -150,23 +149,28 @@ class SegmentedControl extends Component {
|
|
|
150
149
|
const {
|
|
151
150
|
title
|
|
152
151
|
} = buttons.find(button => button.value === selected) || {};
|
|
153
|
-
const menu = /*#__PURE__*/
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
152
|
+
const menu = /*#__PURE__*/_jsx(Menu, {
|
|
153
|
+
children: buttons.map(_ref2 => {
|
|
154
|
+
let {
|
|
155
|
+
title,
|
|
156
|
+
value,
|
|
157
|
+
...buttonProps
|
|
158
|
+
} = _ref2;
|
|
159
|
+
const menuItemProps = {};
|
|
160
|
+
if (onChange !== null) {
|
|
161
|
+
menuItemProps.onClick = this.handleChange(value);
|
|
162
|
+
}
|
|
163
|
+
return /*#__PURE__*/_jsx(MenuItem, {
|
|
164
|
+
...buttonProps,
|
|
165
|
+
...menuItemProps,
|
|
166
|
+
children: title
|
|
167
|
+
}, value);
|
|
168
|
+
})
|
|
169
|
+
});
|
|
170
|
+
return /*#__PURE__*/_jsx(Dropdown, {
|
|
171
|
+
menu: menu,
|
|
172
|
+
children: title
|
|
173
|
+
});
|
|
170
174
|
}
|
|
171
175
|
renderButtonGroup() {
|
|
172
176
|
const {
|
|
@@ -182,38 +186,41 @@ class SegmentedControl extends Component {
|
|
|
182
186
|
monoWidth
|
|
183
187
|
} = this.state;
|
|
184
188
|
const isCollapsed = this.state.compact;
|
|
185
|
-
return /*#__PURE__*/
|
|
186
|
-
className: `${baseClassName}__button-group
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
189
|
+
return /*#__PURE__*/_jsx(ButtonGroup, {
|
|
190
|
+
className: `${baseClassName}__button-group`,
|
|
191
|
+
children: buttons.map(_ref3 => {
|
|
192
|
+
let {
|
|
193
|
+
value,
|
|
194
|
+
title,
|
|
195
|
+
...buttonProps
|
|
196
|
+
} = _ref3;
|
|
197
|
+
// uncontrolled
|
|
198
|
+
const handler = {};
|
|
199
|
+
if (onChange !== null) {
|
|
200
|
+
handler.onClick = this.handleChange(value);
|
|
201
|
+
}
|
|
202
|
+
let buttonSelected = false;
|
|
203
|
+
if (multiple && selected && selected instanceof Array && selected.indexOf(value) !== -1) {
|
|
204
|
+
buttonSelected = true;
|
|
205
|
+
} else if (!multiple && selected === value) {
|
|
206
|
+
buttonSelected = true;
|
|
207
|
+
}
|
|
208
|
+
buttonProps.className = classNames(buttonProps.className, `${baseClassName}__button`);
|
|
209
|
+
if (!isCollapsed && monospaced && monoWidth) {
|
|
210
|
+
buttonProps.style = {
|
|
211
|
+
width: monoWidth,
|
|
212
|
+
...buttonProps.style
|
|
213
|
+
};
|
|
214
|
+
}
|
|
215
|
+
return /*#__PURE__*/_jsx(Button, {
|
|
216
|
+
selected: buttonSelected,
|
|
217
|
+
ghost: ghost,
|
|
218
|
+
...handler,
|
|
219
|
+
...buttonProps,
|
|
220
|
+
children: title
|
|
221
|
+
}, value);
|
|
222
|
+
})
|
|
223
|
+
});
|
|
217
224
|
}
|
|
218
225
|
render() {
|
|
219
226
|
const {
|
|
@@ -231,29 +238,34 @@ class SegmentedControl extends Component {
|
|
|
231
238
|
...props
|
|
232
239
|
} = this.props;
|
|
233
240
|
const isCollapsed = this.isResponsive();
|
|
234
|
-
return /*#__PURE__*/
|
|
235
|
-
value: isCollapsed
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
241
|
+
return /*#__PURE__*/_jsx(ResponsiveContext.Provider, {
|
|
242
|
+
value: isCollapsed,
|
|
243
|
+
children: /*#__PURE__*/_jsx(Squeezer, {
|
|
244
|
+
compact: this.compact,
|
|
245
|
+
uncompact: this.uncompact,
|
|
246
|
+
innerRef: el => {
|
|
247
|
+
this.rootRef.current = el;
|
|
248
|
+
},
|
|
249
|
+
children: _ref4 => {
|
|
250
|
+
let {
|
|
251
|
+
ref
|
|
252
|
+
} = _ref4;
|
|
253
|
+
return /*#__PURE__*/_jsxs("div", {
|
|
254
|
+
ref: ref,
|
|
255
|
+
className: classNames(baseClassName, {
|
|
256
|
+
[`${baseClassName}--inline`]: inline,
|
|
257
|
+
[`${baseClassName}--collapsed`]: isCollapsed,
|
|
258
|
+
[`${baseClassName}--vertical`]: label && labelPlacement === 'top'
|
|
259
|
+
}, className),
|
|
260
|
+
...props,
|
|
261
|
+
children: [label && /*#__PURE__*/_jsx("div", {
|
|
262
|
+
className: `${baseClassName}__label`,
|
|
263
|
+
children: label
|
|
264
|
+
}), this.renderControl()]
|
|
265
|
+
});
|
|
266
|
+
}
|
|
267
|
+
})
|
|
268
|
+
});
|
|
257
269
|
}
|
|
258
270
|
}
|
|
259
271
|
SegmentedControl.propTypes = {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
1
|
// Copyright 1999-2019. Plesk International GmbH. All rights reserved.
|
|
3
2
|
|
|
4
3
|
import classNames from 'classnames';
|
|
5
|
-
import React from 'react';
|
|
6
4
|
import { CLS_PREFIX } from '../../constants';
|
|
7
5
|
import Icon from '../Icon';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
8
8
|
const MultiValue = _ref => {
|
|
9
9
|
let {
|
|
10
10
|
baseClassName = `${CLS_PREFIX}select-multi-value`,
|
|
@@ -19,24 +19,30 @@ const MultiValue = _ref => {
|
|
|
19
19
|
e.stopPropagation();
|
|
20
20
|
onRemove();
|
|
21
21
|
};
|
|
22
|
-
return /*#__PURE__*/
|
|
23
|
-
className: classNames(baseClassName)
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
22
|
+
return /*#__PURE__*/_jsx("div", {
|
|
23
|
+
className: classNames(baseClassName),
|
|
24
|
+
...props,
|
|
25
|
+
children: /*#__PURE__*/_jsxs("div", {
|
|
26
|
+
className: `${baseClassName}__content`,
|
|
27
|
+
children: [/*#__PURE__*/_jsx("span", {
|
|
28
|
+
className: `${baseClassName}__label`,
|
|
29
|
+
children: children
|
|
30
|
+
}), /*#__PURE__*/_jsx(Icon, {
|
|
31
|
+
className: `${baseClassName}__remove`,
|
|
32
|
+
size: "12",
|
|
33
|
+
onMouseDown: onMouseDown,
|
|
34
|
+
onClick: onClick,
|
|
35
|
+
children: /*#__PURE__*/_jsx("svg", {
|
|
36
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
37
|
+
viewBox: "0 0 12 12",
|
|
38
|
+
focusable: "false",
|
|
39
|
+
"aria-hidden": "true",
|
|
40
|
+
children: /*#__PURE__*/_jsx("path", {
|
|
41
|
+
d: "M3.85 8.854a.498.498 0 1 1-.704-.704L5.296 6l-2.15-2.15a.498.498 0 0 1 .704-.704L6 5.296l2.15-2.15a.498.498 0 1 1 .704.704L6.704 6l2.15 2.15a.498.498 0 0 1-.704.704L6 6.704l-2.15 2.15z"
|
|
42
|
+
})
|
|
43
|
+
})
|
|
44
|
+
})]
|
|
45
|
+
})
|
|
46
|
+
});
|
|
41
47
|
};
|
|
42
48
|
export default MultiValue;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
1
|
// Copyright 1999-2020. Plesk International GmbH. All rights reserved.
|
|
3
2
|
|
|
4
|
-
import
|
|
3
|
+
import { Children, useState, useRef, isValidElement } from 'react';
|
|
5
4
|
import classNames from 'classnames';
|
|
6
5
|
import { safeInvoke, EventEmitter } from '../utils';
|
|
7
6
|
import { CLS_PREFIX } from '../../constants';
|
|
@@ -10,6 +9,7 @@ import Translate from '../Translate';
|
|
|
10
9
|
import SelectControl from './SelectControl';
|
|
11
10
|
import SelectOptionGroup from './SelectOptionGroup';
|
|
12
11
|
import SelectOption from './SelectOption';
|
|
12
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
13
13
|
// eslint-disable-next-line default-param-last
|
|
14
14
|
const collect = function (children) {
|
|
15
15
|
let options = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : [];
|
|
@@ -268,7 +268,7 @@ const Select = _ref => {
|
|
|
268
268
|
setValue(nextValue);
|
|
269
269
|
safeInvoke(onChange, nextValue);
|
|
270
270
|
};
|
|
271
|
-
const control = /*#__PURE__*/
|
|
271
|
+
const control = /*#__PURE__*/_jsx(SelectControl, {
|
|
272
272
|
id: id,
|
|
273
273
|
name: name,
|
|
274
274
|
current: current,
|
|
@@ -288,7 +288,7 @@ const Select = _ref => {
|
|
|
288
288
|
placeholder: placeholder,
|
|
289
289
|
ref: controlRef
|
|
290
290
|
});
|
|
291
|
-
return /*#__PURE__*/
|
|
291
|
+
return /*#__PURE__*/_jsx(ComboBoxDropdown, {
|
|
292
292
|
className: classNames(baseClassName, className, {
|
|
293
293
|
[`${baseClassName}--size-${size}`]: size
|
|
294
294
|
}),
|
|
@@ -302,12 +302,13 @@ const Select = _ref => {
|
|
|
302
302
|
highlightedIndex: highlightedIndex,
|
|
303
303
|
onHighlightedIndexChange: handleHighlightedIndexChange,
|
|
304
304
|
onClose: handleClose,
|
|
305
|
-
noOptions: /*#__PURE__*/
|
|
305
|
+
noOptions: /*#__PURE__*/_jsx(Translate, {
|
|
306
306
|
content: "Select.noOptions",
|
|
307
307
|
fallback: "No options"
|
|
308
308
|
}),
|
|
309
309
|
emitter: emitterRef.current,
|
|
310
|
-
value: value
|
|
311
|
-
|
|
310
|
+
value: value,
|
|
311
|
+
...props
|
|
312
|
+
});
|
|
312
313
|
};
|
|
313
314
|
export default Select;
|
|
@@ -1,47 +1,48 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
1
|
// Copyright 1999-2020. Plesk International GmbH. All rights reserved.
|
|
3
2
|
|
|
4
|
-
import React from 'react';
|
|
5
3
|
import Select from './Select';
|
|
6
4
|
import SelectOption from './SelectOption';
|
|
7
|
-
|
|
5
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
6
|
+
export const Basic = args => /*#__PURE__*/_jsx(Select, {
|
|
7
|
+
...args
|
|
8
|
+
});
|
|
8
9
|
Basic.args = {
|
|
9
|
-
children: [/*#__PURE__*/
|
|
10
|
-
|
|
11
|
-
},
|
|
12
|
-
|
|
13
|
-
},
|
|
14
|
-
|
|
15
|
-
},
|
|
16
|
-
|
|
17
|
-
},
|
|
18
|
-
|
|
19
|
-
},
|
|
20
|
-
|
|
21
|
-
},
|
|
22
|
-
|
|
23
|
-
},
|
|
24
|
-
|
|
25
|
-
},
|
|
26
|
-
|
|
27
|
-
},
|
|
28
|
-
|
|
29
|
-
},
|
|
30
|
-
|
|
31
|
-
},
|
|
32
|
-
|
|
33
|
-
},
|
|
10
|
+
children: [/*#__PURE__*/_jsx(SelectOption, {
|
|
11
|
+
children: 'One'
|
|
12
|
+
}, "1"), /*#__PURE__*/_jsx(SelectOption, {
|
|
13
|
+
children: 'Two'
|
|
14
|
+
}, "2"), /*#__PURE__*/_jsx(SelectOption, {
|
|
15
|
+
children: 'Three'
|
|
16
|
+
}, "3"), /*#__PURE__*/_jsx(SelectOption, {
|
|
17
|
+
children: 'Four'
|
|
18
|
+
}, "4"), /*#__PURE__*/_jsx(SelectOption, {
|
|
19
|
+
children: 'Five'
|
|
20
|
+
}, "5"), /*#__PURE__*/_jsx(SelectOption, {
|
|
21
|
+
children: 'Six'
|
|
22
|
+
}, "6"), /*#__PURE__*/_jsx(SelectOption, {
|
|
23
|
+
children: 'Seven'
|
|
24
|
+
}, "7"), /*#__PURE__*/_jsx(SelectOption, {
|
|
25
|
+
children: 'Eight'
|
|
26
|
+
}, "8"), /*#__PURE__*/_jsx(SelectOption, {
|
|
27
|
+
children: 'Nine'
|
|
28
|
+
}, "9"), /*#__PURE__*/_jsx(SelectOption, {
|
|
29
|
+
children: 'Ten'
|
|
30
|
+
}, "10"), /*#__PURE__*/_jsx(SelectOption, {
|
|
31
|
+
children: 'Eleven'
|
|
32
|
+
}, "11"), /*#__PURE__*/_jsx(SelectOption, {
|
|
33
|
+
children: 'Twelve'
|
|
34
|
+
}, "12")],
|
|
34
35
|
'data-test': 'select'
|
|
35
36
|
};
|
|
36
|
-
export const SearchableAtBottom = () => {
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
}
|
|
47
|
-
};
|
|
37
|
+
export const SearchableAtBottom = () => /*#__PURE__*/_jsx("div", {
|
|
38
|
+
style: {
|
|
39
|
+
position: 'absolute',
|
|
40
|
+
left: 0,
|
|
41
|
+
bottom: 0,
|
|
42
|
+
padding: 16
|
|
43
|
+
},
|
|
44
|
+
children: /*#__PURE__*/_jsx(Basic, {
|
|
45
|
+
searchable: true,
|
|
46
|
+
...Basic.args
|
|
47
|
+
})
|
|
48
|
+
});
|
|
@@ -1,12 +1,13 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
1
|
// Copyright 1999-2020. Plesk International GmbH. All rights reserved.
|
|
3
2
|
|
|
4
3
|
import classNames from 'classnames';
|
|
5
|
-
import
|
|
4
|
+
import { Fragment, useRef, useState, useLayoutEffect, forwardRef } from 'react';
|
|
6
5
|
import { useTranslate } from '../LocaleProvider';
|
|
7
6
|
import { CLS_PREFIX } from '../../constants';
|
|
8
7
|
import Icon from '../Icon';
|
|
9
8
|
import MultiValue from './MultiValue';
|
|
9
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
10
|
+
import { jsxs as _jsxs } from "react/jsx-runtime";
|
|
10
11
|
const DEFAULT_INPUT_WIDTH = 2;
|
|
11
12
|
let inputMeter;
|
|
12
13
|
const getInputWidth = target => {
|
|
@@ -152,84 +153,96 @@ const SelectControl = /*#__PURE__*/forwardRef(function SelectControl(_ref, ref)
|
|
|
152
153
|
const handleBlur = () => {
|
|
153
154
|
setFocused(false);
|
|
154
155
|
};
|
|
155
|
-
return /*#__PURE__*/
|
|
156
|
+
return /*#__PURE__*/_jsxs("div", {
|
|
156
157
|
className: classNames(baseClassName, {
|
|
157
158
|
[`${baseClassName}--disabled`]: disabled,
|
|
158
159
|
[`${baseClassName}--focused`]: focused,
|
|
159
160
|
[`${baseClassName}--multiple`]: multiple
|
|
160
|
-
})
|
|
161
|
-
|
|
161
|
+
}),
|
|
162
|
+
...props,
|
|
162
163
|
onClick: handleClick,
|
|
163
|
-
ref: ref
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
164
|
+
ref: ref,
|
|
165
|
+
children: [/*#__PURE__*/_jsxs("span", {
|
|
166
|
+
className: `${baseClassName}__value-container`,
|
|
167
|
+
children: [Array.isArray(current) && current.map(_ref3 => {
|
|
168
|
+
let {
|
|
169
|
+
value,
|
|
170
|
+
label
|
|
171
|
+
} = _ref3;
|
|
172
|
+
return /*#__PURE__*/_jsx(MultiValue, {
|
|
173
|
+
onRemove: () => handleValueRemove(value),
|
|
174
|
+
children: label
|
|
175
|
+
}, value);
|
|
176
|
+
}), /*#__PURE__*/_jsx("input", {
|
|
177
|
+
id: id,
|
|
178
|
+
className: `${baseClassName}__input`,
|
|
179
|
+
value: filterValue,
|
|
180
|
+
type: "text",
|
|
181
|
+
onChange: handleInputChange,
|
|
182
|
+
onKeyDown: handleKeyDown,
|
|
183
|
+
onFocus: handleFocus,
|
|
184
|
+
onBlur: handleBlur,
|
|
185
|
+
readOnly: !searchable,
|
|
186
|
+
disabled: disabled,
|
|
187
|
+
ref: inputRef,
|
|
188
|
+
style: {
|
|
189
|
+
width: inputWidth
|
|
190
|
+
}
|
|
191
|
+
}), !filterValue && /*#__PURE__*/_jsxs(Fragment, {
|
|
192
|
+
children: [!Array.isArray(current) && current && /*#__PURE__*/_jsx("span", {
|
|
193
|
+
className: `${baseClassName}__value`,
|
|
194
|
+
children: current.children
|
|
195
|
+
}), !hasValue && placeholder && /*#__PURE__*/_jsx("span", {
|
|
196
|
+
className: `${baseClassName}__placeholder`,
|
|
197
|
+
children: placeholder
|
|
198
|
+
})]
|
|
199
|
+
})]
|
|
200
|
+
}), /*#__PURE__*/_jsxs("span", {
|
|
201
|
+
className: `${baseClassName}__indicators`,
|
|
202
|
+
children: [clearable && hasValue && /*#__PURE__*/_jsx("button", {
|
|
203
|
+
type: "button",
|
|
204
|
+
className: classNames(`${baseClassName}__indicator`, `${baseClassName}__indicator--clear`),
|
|
205
|
+
tabIndex: -1,
|
|
206
|
+
onMouseDown: e => e.preventDefault(),
|
|
207
|
+
onClick: e => {
|
|
208
|
+
e.stopPropagation();
|
|
209
|
+
handleClear();
|
|
210
|
+
},
|
|
211
|
+
children: /*#__PURE__*/_jsx(Icon, {
|
|
212
|
+
className: `${baseClassName}__indicator-icon`,
|
|
213
|
+
children: /*#__PURE__*/_jsx("svg", {
|
|
214
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
215
|
+
viewBox: "-4 -4 16 16",
|
|
216
|
+
"aria-hidden": "true",
|
|
217
|
+
focusable: "false",
|
|
218
|
+
children: /*#__PURE__*/_jsx("path", {
|
|
219
|
+
d: "M.85 7.854a.498.498 0 1 1-.704-.704L3.296 4 .146.85A.498.498 0 0 1 .85.146L4 3.296 7.15.146a.498.498 0 0 1 .704.704L4.704 4l3.15 3.15a.498.498 0 0 1-.704.704L4 4.704.85 7.854z"
|
|
220
|
+
})
|
|
221
|
+
})
|
|
222
|
+
})
|
|
223
|
+
}), /*#__PURE__*/_jsx("button", {
|
|
224
|
+
type: "button",
|
|
225
|
+
className: classNames(`${baseClassName}__indicator`, `${baseClassName}__indicator--dropdown`),
|
|
226
|
+
tabIndex: -1,
|
|
227
|
+
children: /*#__PURE__*/_jsx(Icon, {
|
|
228
|
+
className: `${baseClassName}__indicator-icon`,
|
|
229
|
+
children: /*#__PURE__*/_jsx("svg", {
|
|
230
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
231
|
+
viewBox: "-4 -5 16 16",
|
|
232
|
+
"aria-hidden": "true",
|
|
233
|
+
focusable: "false",
|
|
234
|
+
children: /*#__PURE__*/_jsx("path", {
|
|
235
|
+
d: "M4 4.048L.847.895a.496.496 0 1 0-.702.702l3.452 3.451a.5.5 0 0 0 .806 0l3.452-3.451a.496.496 0 0 0-.702-.702L4 4.048z"
|
|
236
|
+
})
|
|
237
|
+
})
|
|
238
|
+
})
|
|
239
|
+
})]
|
|
240
|
+
}), name && values.map(value => /*#__PURE__*/_jsx("input", {
|
|
241
|
+
type: "hidden",
|
|
242
|
+
name: name,
|
|
243
|
+
value: value
|
|
244
|
+
}, value))]
|
|
245
|
+
});
|
|
233
246
|
});
|
|
234
247
|
SelectControl.displayName = 'SelectControl';
|
|
235
248
|
export default SelectControl;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
1
2
|
// Copyright 1999-2020. Plesk International GmbH. All rights reserved.
|
|
2
3
|
|
|
3
|
-
import React from 'react';
|
|
4
4
|
/**
|
|
5
5
|
* `SelectOption` is a part of [SelectOptionGroup](#!/SelectOptionGroup) component.
|
|
6
6
|
* @since 2.3.0
|
|
@@ -9,7 +9,7 @@ const SelectOption = _props => {
|
|
|
9
9
|
// styleguidist doesn't show Props & Methods if component renders nothing
|
|
10
10
|
// eslint-disable-next-line no-constant-condition
|
|
11
11
|
if (false) {
|
|
12
|
-
return /*#__PURE__*/
|
|
12
|
+
return /*#__PURE__*/_jsx("option", {});
|
|
13
13
|
}
|
|
14
14
|
return null;
|
|
15
15
|
};
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
1
2
|
// Copyright 1999-2020. Plesk International GmbH. All rights reserved.
|
|
2
3
|
|
|
3
|
-
import React from 'react';
|
|
4
4
|
/**
|
|
5
5
|
* `SelectOptionGroup` is a part of [Select](#!/Select) component. It can be used for splitting the list of all options into groups.
|
|
6
6
|
* @since 2.3.0
|
|
@@ -9,7 +9,7 @@ const SelectOptionGroup = _props => {
|
|
|
9
9
|
// styleguidist doesn't show Props & Methods if component renders nothing
|
|
10
10
|
// eslint-disable-next-line no-constant-condition
|
|
11
11
|
if (false) {
|
|
12
|
-
return /*#__PURE__*/
|
|
12
|
+
return /*#__PURE__*/_jsx("optgroup", {});
|
|
13
13
|
}
|
|
14
14
|
return null;
|
|
15
15
|
};
|
|
@@ -1,10 +1,9 @@
|
|
|
1
|
-
import _extends from "@babel/runtime/helpers/extends";
|
|
2
1
|
// Copyright 1999-2022. Plesk International GmbH. All rights reserved.
|
|
3
2
|
|
|
4
|
-
import React from 'react';
|
|
5
3
|
import classNames from 'classnames';
|
|
6
4
|
import { normalizeSize } from '../utils';
|
|
7
5
|
import { CLS_PREFIX } from '../../constants';
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
8
7
|
/**
|
|
9
8
|
* `Skeleton` (or content-placeholder) is placeholder preview of content before the data gets loaded to reduce load-time frustration.
|
|
10
9
|
* Skeleton is used for non-text components, images, media-objects, etc.
|
|
@@ -27,9 +26,10 @@ const Skeleton = _ref => {
|
|
|
27
26
|
maxWidth: normalizeSize(maxWidth),
|
|
28
27
|
height: normalizeSize(height)
|
|
29
28
|
};
|
|
30
|
-
return /*#__PURE__*/
|
|
29
|
+
return /*#__PURE__*/_jsx(Tag, {
|
|
31
30
|
className: classNames(baseClassName, className),
|
|
32
|
-
style: finalStyle
|
|
33
|
-
|
|
31
|
+
style: finalStyle,
|
|
32
|
+
...props
|
|
33
|
+
});
|
|
34
34
|
};
|
|
35
35
|
export default Skeleton;
|