welcome-ui 1.0.0-beta.3 → 1.0.0-beta.4
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/dist/AXB53BZF-BxNazDnS.mjs +25 -0
- package/dist/AXB53BZF-KWM2jKTz.js +1 -0
- package/dist/Accordion.js +16 -30
- package/dist/Accordion.mjs +27 -515
- package/dist/Alert.js +37 -1
- package/dist/Alert.mjs +118 -5
- package/dist/AspectRatio.mjs +7 -7
- package/dist/Avatar.js +3 -3
- package/dist/Avatar.mjs +16 -15
- package/dist/BYC7LY2E-BAjGN7k_.mjs +1074 -0
- package/dist/BYC7LY2E-BkAEL2VD.js +1 -0
- package/dist/Badge.js +3 -3
- package/dist/Badge.mjs +10 -10
- package/dist/Breadcrumb.js +1 -54
- package/dist/Breadcrumb.mjs +7 -437
- package/dist/Button.js +78 -0
- package/dist/Button.mjs +136 -0
- package/dist/ButtonGroup.js +32 -0
- package/dist/ButtonGroup.mjs +51 -0
- package/dist/Card.js +17 -0
- package/dist/Card.mjs +29 -0
- package/dist/Checkbox.js +1 -0
- package/dist/Checkbox.mjs +6 -0
- package/dist/ClearButton.js +14 -0
- package/dist/ClearButton.mjs +26 -0
- package/dist/CloseButton.js +6 -0
- package/dist/CloseButton.mjs +15 -0
- package/dist/CustomInput-9aCUiD6o.js +1070 -0
- package/dist/CustomInput-CenfXh_H.mjs +7825 -0
- package/dist/DatePicker.js +1 -0
- package/dist/DatePicker.mjs +108 -0
- package/dist/DateTimePicker.js +38 -0
- package/dist/DateTimePicker.mjs +109 -0
- package/dist/DateTimePickerCommon.js +1 -0
- package/dist/DateTimePickerCommon.mjs +14 -0
- package/dist/Drawer.js +64 -0
- package/dist/Drawer.mjs +267 -0
- package/dist/DropdownMenu.js +45 -0
- package/dist/DropdownMenu.mjs +776 -0
- package/dist/Field.js +72 -0
- package/dist/Field.mjs +177 -0
- package/dist/FieldGroup.js +13 -0
- package/dist/FieldGroup.mjs +26 -0
- package/dist/FileDrop.js +46 -0
- package/dist/FileDrop.mjs +2325 -0
- package/dist/FileUpload.js +3 -0
- package/dist/FileUpload.mjs +88 -0
- package/dist/Grid.js +1 -0
- package/dist/Grid.mjs +57 -0
- package/dist/Hint.js +8 -0
- package/dist/Hint.mjs +22 -0
- package/dist/ITI7HKP4-BPa8qpnl.js +1 -0
- package/dist/ITI7HKP4-Couz1Z73.mjs +473 -0
- package/dist/Icon.js +17 -0
- package/dist/Icon.mjs +51 -0
- package/dist/IconFont.js +17 -0
- package/dist/IconFont.mjs +348 -0
- package/dist/InputText.js +8 -0
- package/dist/InputText.mjs +81 -0
- package/dist/JC64G2H7-CQsqXPS_.mjs +965 -0
- package/dist/JC64G2H7-YkBMNrtl.js +1 -0
- package/dist/KUU7WJ55-DN8gk6_R.js +1 -0
- package/dist/KUU7WJ55-bC4FU_j7.mjs +61 -0
- package/dist/LVA2YJMS-B2HZjIhJ.js +14 -0
- package/dist/LVA2YJMS-Dm5ieEMw.mjs +1479 -0
- package/dist/Label.js +35 -0
- package/dist/Label.mjs +78 -0
- package/dist/Link.js +43 -0
- package/dist/Link.mjs +77 -0
- package/dist/Loader.js +30 -0
- package/dist/Loader.mjs +48 -0
- package/dist/Logo.js +1 -0
- package/dist/Logo.mjs +8 -0
- package/dist/MTZPJQMC-5Xg78Uyy.js +1 -0
- package/dist/MTZPJQMC-DZ3zg4be.mjs +13 -0
- package/dist/Modal.js +181 -0
- package/dist/Modal.mjs +365 -0
- package/dist/NLEBE274-DvH3XTTw.js +1 -0
- package/dist/NLEBE274-FThuwZH_.mjs +84 -0
- package/dist/P2CTZE2T-5jxBu6ix.mjs +297 -0
- package/dist/P2CTZE2T-q8vyaGc0.js +1 -0
- package/dist/P4IRICAX-DF0_vmod.mjs +37 -0
- package/dist/P4IRICAX-nhgZ26A1.js +1 -0
- package/dist/Pagination.js +46 -0
- package/dist/Pagination.mjs +158 -0
- package/dist/PasswordInput.js +1 -0
- package/dist/PasswordInput.mjs +54 -0
- package/dist/Picker.js +8 -0
- package/dist/Picker.mjs +50 -0
- package/dist/Popover.js +1 -0
- package/dist/Popover.mjs +8 -0
- package/dist/QYJ6MIDR-CRK3satR.js +1 -0
- package/dist/QYJ6MIDR-Cy39pEs2.mjs +97 -0
- package/dist/Radio.js +60 -0
- package/dist/Radio.mjs +118 -0
- package/dist/RadioGroup.js +8 -0
- package/dist/RadioGroup.mjs +68 -0
- package/dist/RadioTab.js +61 -0
- package/dist/RadioTab.mjs +104 -0
- package/dist/SYRFVSLH-BpAfr7UE.js +1 -0
- package/dist/SYRFVSLH-DyepaZf7.mjs +48 -0
- package/dist/Search.js +70 -0
- package/dist/Search.mjs +225 -0
- package/dist/Select.js +122 -0
- package/dist/Select.mjs +1071 -0
- package/dist/Shape.js +23 -0
- package/dist/Shape.mjs +37 -0
- package/dist/Slider.js +190 -0
- package/dist/Slider.mjs +531 -0
- package/dist/Stack.js +1 -0
- package/dist/Stack.mjs +32 -0
- package/dist/Swiper.js +141 -0
- package/dist/Swiper.mjs +448 -0
- package/dist/System.js +1 -1
- package/dist/System.mjs +5 -5
- package/dist/Table.js +55 -0
- package/dist/Table.mjs +75 -0
- package/dist/Tabs.js +82 -0
- package/dist/Tabs.mjs +539 -0
- package/dist/Tag.js +78 -0
- package/dist/Tag.mjs +135 -0
- package/dist/Text.js +46 -0
- package/dist/Text.mjs +97 -0
- package/dist/Textarea.js +6 -0
- package/dist/Textarea.mjs +55 -0
- package/dist/TimePicker.js +4 -0
- package/dist/TimePicker.mjs +88 -0
- package/dist/Toast.js +42 -0
- package/dist/Toast.mjs +264 -0
- package/dist/Toggle.js +75 -0
- package/dist/Toggle.mjs +93 -0
- package/dist/Tooltip.js +68 -0
- package/dist/Tooltip.mjs +303 -0
- package/dist/UniversalLink.js +4 -0
- package/dist/UniversalLink.mjs +25 -0
- package/dist/VEVQD5MH-De4r89YE.mjs +20 -0
- package/dist/VEVQD5MH-mN1wMozH.js +1 -0
- package/dist/VGCJ63VH-BNLwLOaC.js +1 -0
- package/dist/VGCJ63VH-fv0YLRh8.mjs +186 -0
- package/dist/VariantIcon.js +8 -0
- package/dist/VariantIcon.mjs +32 -0
- package/dist/Welcome-BNr4uu5n.mjs +48 -0
- package/dist/Welcome-Dw9OaREs.js +3 -0
- package/dist/WelcomeLoader.js +11 -0
- package/dist/WelcomeLoader.mjs +9453 -0
- package/dist/X5NMLKT6-BzhcQu_I.js +1 -0
- package/dist/X5NMLKT6-DGZEtYXj.mjs +25 -0
- package/dist/YV4JVR4I-1ezWeCCz.mjs +341 -0
- package/dist/YV4JVR4I-DIthYWMj.js +15 -0
- package/dist/_commonjsHelpers-CXJ7dpIk.mjs +9 -0
- package/dist/_commonjsHelpers-DvH0V_XJ.js +1 -0
- package/dist/create-event-YSlay9Ef.js +1 -0
- package/dist/create-event-rXDe5aCQ.mjs +8 -0
- package/dist/downshift.esm-DAo-GJwH.js +1 -0
- package/dist/downshift.esm-K4YLLQXl.mjs +1085 -0
- package/dist/field-styles-CeV7pnOp.mjs +86 -0
- package/dist/field-styles-D_gf6ypV.js +63 -0
- package/dist/get-max-width-height-CDLBnp_J.js +1 -0
- package/dist/get-max-width-height-DoUro2T7.mjs +8 -0
- package/dist/hide-focus-rings-root-BNyva1yb.mjs +14 -0
- package/dist/hide-focus-rings-root-DGU4Klq5.js +5 -0
- package/dist/index-1C9Z0d5Q.mjs +446 -0
- package/dist/index-BHi0wohR.js +142 -0
- package/dist/index-BLom3M2B.js +2 -0
- package/dist/{index-WmqrMIzg.mjs → index-BYdkhqH4.mjs} +6344 -6386
- package/dist/index-C_r0bVmL.js +56 -0
- package/dist/index-CgT8GWHS.js +1 -0
- package/dist/index-ColyClKR.mjs +239 -0
- package/dist/index-CrhKWaM2.js +54 -0
- package/dist/index-Cs1IZBks.js +17 -0
- package/dist/index-DCOLdphy.mjs +184 -0
- package/dist/index-DHOW43M6.mjs +132 -0
- package/dist/index-SbQUT2mU.mjs +639 -0
- package/dist/index.js +5 -147
- package/dist/index.mjs +1448 -537
- package/dist/overflow-ellipsis-C2ESrF8C.js +5 -0
- package/dist/overflow-ellipsis-DGV5Kgt-.mjs +10 -0
- package/dist/radio-group-29lMl-2M.mjs +51 -0
- package/dist/radio-group-BpImAAmy.js +1 -0
- package/dist/throttle-BB1Y3bfD.js +1 -0
- package/dist/throttle-BDBzFeFj.mjs +13 -0
- package/dist/types/components/Alert/Title.d.ts +1 -1
- package/dist/types/components/Alert/index.d.ts +3 -3
- package/dist/types/components/Alert/styles.d.ts +2 -2
- package/dist/types/components/Avatar/index.d.ts +1 -1
- package/dist/types/components/Avatar/styles.d.ts +2 -2
- package/dist/types/components/Badge/styles.d.ts +2 -2
- package/dist/types/components/Card/Cover.d.ts +1 -1
- package/dist/types/components/Card/Cover.styles.d.ts +1 -1
- package/dist/types/components/Checkbox/index.d.ts +13 -0
- package/dist/types/components/Checkbox/styles.d.ts +3 -0
- package/dist/types/components/Checkbox/theme.d.ts +8 -0
- package/dist/types/components/ClearButton/styles.d.ts +1 -1
- package/dist/types/components/CloseButton/styles.d.ts +1 -1
- package/dist/types/components/DatePicker/index.d.ts +15 -0
- package/dist/types/components/DateTimePicker/index.d.ts +5 -0
- package/dist/types/components/DateTimePicker/styles.d.ts +1 -0
- package/dist/types/components/DateTimePickerCommon/CustomHeader.d.ts +18 -0
- package/dist/types/components/DateTimePickerCommon/CustomInput.d.ts +17 -0
- package/dist/types/components/DateTimePickerCommon/CustomPopper.d.ts +4 -0
- package/dist/types/components/DateTimePickerCommon/datePickerStyles.d.ts +1 -0
- package/dist/types/components/DateTimePickerCommon/index.d.ts +5 -0
- package/dist/types/components/DateTimePickerCommon/styles.d.ts +9 -0
- package/dist/types/components/DateTimePickerCommon/theme.d.ts +9 -0
- package/dist/types/components/DateTimePickerCommon/utils.d.ts +6 -0
- package/dist/types/components/Drawer/AssetDrawer/Header.d.ts +31 -0
- package/dist/types/components/Drawer/AssetDrawer/index.d.ts +4 -0
- package/dist/types/components/Drawer/AssetDrawer/styles.d.ts +3 -0
- package/dist/types/components/Drawer/Close.d.ts +5 -0
- package/dist/types/components/Drawer/Content.d.ts +4 -0
- package/dist/types/components/Drawer/Footer.d.ts +4 -0
- package/dist/types/components/Drawer/Title.d.ts +3 -0
- package/dist/types/components/Drawer/index.d.ts +52 -0
- package/dist/types/components/Drawer/styles.d.ts +10 -0
- package/dist/types/components/Drawer/theme.d.ts +17 -0
- package/dist/types/components/DropdownMenu/Arrow.d.ts +4 -0
- package/dist/types/components/DropdownMenu/Arrow.styled.d.ts +4 -0
- package/dist/types/components/DropdownMenu/Item.d.ts +4 -0
- package/dist/types/components/DropdownMenu/Item.styled.d.ts +1 -0
- package/dist/types/components/DropdownMenu/Separator.d.ts +4 -0
- package/dist/types/components/DropdownMenu/Separator.styled.d.ts +1 -0
- package/dist/types/components/DropdownMenu/index.d.ts +25 -0
- package/dist/types/components/DropdownMenu/styles.d.ts +1 -0
- package/dist/types/components/DropdownMenu/theme.d.ts +8 -0
- package/dist/types/components/Field/index.d.ts +26 -0
- package/dist/types/components/Field/styles.d.ts +21 -0
- package/dist/types/components/Field/utils.d.ts +5 -0
- package/dist/types/components/FieldGroup/index.d.ts +11 -0
- package/dist/types/components/FieldGroup/styles.d.ts +1 -0
- package/dist/types/components/FileDrop/FilePreview.d.ts +9 -0
- package/dist/types/components/FileDrop/Message.d.ts +7 -0
- package/dist/types/components/FileDrop/Preview.d.ts +3 -0
- package/dist/types/components/FileDrop/index.d.ts +52 -0
- package/dist/types/components/FileDrop/styles.d.ts +9 -0
- package/dist/types/components/FileDrop/theme.d.ts +9 -0
- package/dist/types/components/FileDrop/utils.d.ts +3 -0
- package/dist/types/components/FileUpload/index.d.ts +35 -0
- package/dist/types/components/FileUpload/styles.d.ts +1 -0
- package/dist/types/components/Files/index.d.ts +8 -0
- package/dist/types/components/Files/types.d.ts +72 -0
- package/dist/types/components/Grid/Item.d.ts +14 -0
- package/dist/types/components/Grid/index.d.ts +31 -0
- package/dist/types/components/Hint/index.d.ts +10 -0
- package/dist/types/components/Hint/styles.d.ts +4 -0
- package/dist/types/components/Hint/theme.d.ts +9 -0
- package/dist/types/components/Icon/index.d.ts +26 -0
- package/dist/types/components/Icon/styles.d.ts +9 -0
- package/dist/types/components/Icon/theme.d.ts +10 -0
- package/dist/types/components/IconFont/index.d.ts +311 -0
- package/dist/types/components/IconFont/styles.d.ts +7 -0
- package/dist/types/components/IconFont/unicode.json.d.ts +303 -0
- package/dist/types/components/InputText/index.d.ts +21 -0
- package/dist/types/components/InputText/styles.d.ts +3 -0
- package/dist/types/components/Label/index.d.ts +16 -0
- package/dist/types/components/Label/styles.d.ts +5 -0
- package/dist/types/components/Label/theme.d.ts +4 -0
- package/dist/types/components/Link/index.d.ts +15 -0
- package/dist/types/components/Link/styles.d.ts +2 -0
- package/dist/types/components/Link/theme.d.ts +16 -0
- package/dist/types/components/Link/utils.d.ts +1 -0
- package/dist/types/components/Loader/index.d.ts +11 -0
- package/dist/types/components/Loader/styles.d.ts +6 -0
- package/dist/types/components/Loader/theme.d.ts +8 -0
- package/dist/types/components/Logo/Solutions.d.ts +3 -0
- package/dist/types/components/Logo/Symbol.d.ts +3 -0
- package/dist/types/components/Logo/Welcome.d.ts +3 -0
- package/dist/types/components/Logo/Wui.d.ts +3 -0
- package/dist/types/components/Logo/index.d.ts +7 -0
- package/dist/types/components/Logo/styles.d.ts +1 -0
- package/dist/types/components/Modal/Assets/AssetWithTitle.d.ts +9 -0
- package/dist/types/components/Modal/Assets/Backdrop.d.ts +4 -0
- package/dist/types/components/Modal/Assets/Iframe.d.ts +5 -0
- package/dist/types/components/Modal/Assets/index.d.ts +17 -0
- package/dist/types/components/Modal/Assets/styles.d.ts +7 -0
- package/dist/types/components/Modal/Close.d.ts +6 -0
- package/dist/types/components/Modal/Content.d.ts +16 -0
- package/dist/types/components/Modal/Footer.d.ts +12 -0
- package/dist/types/components/Modal/Header.d.ts +12 -0
- package/dist/types/components/Modal/index.d.ts +53 -0
- package/dist/types/components/Modal/styles.d.ts +11 -0
- package/dist/types/components/Modal/theme.d.ts +17 -0
- package/dist/types/components/Pagination/index.d.ts +14 -0
- package/dist/types/components/Pagination/styles.d.ts +7 -0
- package/dist/types/components/Pagination/theme.d.ts +9 -0
- package/dist/types/components/Pagination/utils.d.ts +7 -0
- package/dist/types/components/PasswordInput/ToggleButton.d.ts +9 -0
- package/dist/types/components/PasswordInput/index.d.ts +5 -0
- package/dist/types/components/Picker/index.d.ts +17 -0
- package/dist/types/components/Picker/styles.d.ts +2 -0
- package/dist/types/components/Popover/Arrow.d.ts +6 -0
- package/dist/types/components/Popover/Content.d.ts +9 -0
- package/dist/types/components/Popover/Popover.d.ts +14 -0
- package/dist/types/components/Popover/PopoverHover.d.ts +14 -0
- package/dist/types/components/Popover/Trigger.d.ts +10 -0
- package/dist/types/components/Popover/index.d.ts +3 -0
- package/dist/types/components/Popover/styles.d.ts +12 -0
- package/dist/types/components/Popover/theme.d.ts +8 -0
- package/dist/types/components/Popover/usePopover.d.ts +15 -0
- package/dist/types/components/Radio/index.d.ts +12 -0
- package/dist/types/components/Radio/styles.d.ts +7 -0
- package/dist/types/components/Radio/theme.d.ts +11 -0
- package/dist/types/components/RadioGroup/index.d.ts +17 -0
- package/dist/types/components/RadioGroup/styles.d.ts +4 -0
- package/dist/types/components/RadioTab/index.d.ts +14 -0
- package/dist/types/components/RadioTab/styles.d.ts +18 -0
- package/dist/types/components/RadioTab/theme.d.ts +7 -0
- package/dist/types/components/Search/index.d.ts +29 -0
- package/dist/types/components/Search/styles.d.ts +15 -0
- package/dist/types/components/Select/index.d.ts +54 -0
- package/dist/types/components/Select/multipleSelections.d.ts +3 -0
- package/dist/types/components/Select/styles.d.ts +32 -0
- package/dist/types/components/Select/utils.d.ts +18 -0
- package/dist/types/components/Shape/index.d.ts +6 -0
- package/dist/types/components/Shape/styles.d.ts +2 -0
- package/dist/types/components/Slider/Range.d.ts +17 -0
- package/dist/types/components/Slider/index.d.ts +27 -0
- package/dist/types/components/Slider/styles.d.ts +19 -0
- package/dist/types/components/Slider/theme.d.ts +11 -0
- package/dist/types/components/Stack/index.d.ts +7 -0
- package/dist/types/components/Swiper/index.d.ts +80 -0
- package/dist/types/components/Swiper/styles.d.ts +138 -0
- package/dist/types/components/Swiper/theme.d.ts +11 -0
- package/dist/types/components/Swiper/use-interval.d.ts +1 -0
- package/dist/types/components/Table/index.d.ts +18 -0
- package/dist/types/components/Table/styles.d.ts +13 -0
- package/dist/types/components/Table/theme.d.ts +15 -0
- package/dist/types/components/Tabs/ActiveBar.d.ts +13 -0
- package/dist/types/components/Tabs/TabList.d.ts +13 -0
- package/dist/types/components/Tabs/TabPanel.d.ts +11 -0
- package/dist/types/components/Tabs/index.d.ts +18 -0
- package/dist/types/components/Tabs/styles.d.ts +9 -0
- package/dist/types/components/Tabs/theme.d.ts +28 -0
- package/dist/types/components/Tabs/utils.d.ts +1 -0
- package/dist/types/components/Tag/index.d.ts +17 -0
- package/dist/types/components/Tag/styles.d.ts +15 -0
- package/dist/types/components/Tag/theme.d.ts +14 -0
- package/dist/types/components/Text/index.d.ts +25 -0
- package/dist/types/components/Text/styles.d.ts +2 -0
- package/dist/types/components/Textarea/index.d.ts +18 -0
- package/dist/types/components/Textarea/styles.d.ts +2 -0
- package/dist/types/components/Textarea/theme.d.ts +4 -0
- package/dist/types/components/TimePicker/index.d.ts +13 -0
- package/dist/types/components/TimePicker/styles.d.ts +1 -0
- package/dist/types/components/Toast/Growl.d.ts +12 -0
- package/dist/types/components/Toast/Snackbar.d.ts +18 -0
- package/dist/types/components/Toast/ToastWrapper.d.ts +16 -0
- package/dist/types/components/Toast/index.d.ts +27 -0
- package/dist/types/components/Toast/styles.d.ts +19 -0
- package/dist/types/components/Toast/theme.d.ts +22 -0
- package/dist/types/components/Toast/utils.d.ts +26 -0
- package/dist/types/components/Toggle/index.d.ts +11 -0
- package/dist/types/components/Toggle/styles.d.ts +12 -0
- package/dist/types/components/Toggle/theme.d.ts +10 -0
- package/dist/types/components/Tooltip/index.d.ts +11 -0
- package/dist/types/components/Tooltip/styles.d.ts +10 -0
- package/dist/types/components/Tooltip/theme.d.ts +4 -0
- package/dist/types/components/UniversalLink/index.d.ts +7 -0
- package/dist/types/components/UniversalLink/styles.d.ts +1 -0
- package/dist/types/components/VariantIcon/index.d.ts +11 -0
- package/dist/types/components/VariantIcon/styles.d.ts +4 -0
- package/dist/types/components/VariantIcon/theme.d.ts +10 -0
- package/dist/types/components/WelcomeLoader/index.d.ts +2 -0
- package/dist/types/components/WelcomeLoader/loader.json.d.ts +3 -0
- package/dist/types/components/index.d.ts +43 -1
- package/dist/types/index.d.ts +2 -1
- package/dist/types/theme/defaultFields.d.ts +39 -0
- package/dist/types/theme/index.d.ts +52 -2
- package/dist/types/theme/typography.d.ts +2 -2
- package/dist/types/utils/clamp.d.ts +1 -0
- package/dist/types/utils/create-event.d.ts +8 -0
- package/dist/types/utils/field-styles.d.ts +21 -0
- package/dist/types/utils/format-bytes.d.ts +1 -0
- package/dist/types/utils/get-max-width-height.d.ts +1 -0
- package/dist/types/utils/hex-to-rgb.d.ts +1 -0
- package/dist/types/utils/hex-to-rgba.d.ts +1 -0
- package/dist/types/utils/hide-focus-rings-root.d.ts +8 -0
- package/dist/types/utils/index.d.ts +1 -0
- package/dist/types/utils/overflow-ellipsis.d.ts +1 -0
- package/dist/types/utils/throttle.d.ts +5 -0
- package/dist/types/utils/use-copy-text.d.ts +5 -0
- package/dist/types/utils/use-create-portal.d.ts +4 -0
- package/dist/types/utils/use-fork-ref.d.ts +3 -0
- package/dist/types/utils/use-isomorphic-layout-effect.d.ts +2 -0
- package/dist/types/utils/use-viewport.d.ts +6 -0
- package/dist/types/utils/wrap-children.d.ts +1 -0
- package/dist/use-isomorphic-layout-effect-C1_Gy5Nu.js +1 -0
- package/dist/use-isomorphic-layout-effect-Izr-e2pi.mjs +6 -0
- package/dist/use-viewport-BDDjd1nl.js +1 -0
- package/dist/use-viewport-m3glsbna.mjs +16 -0
- package/dist/usePopover-CZsYHcTW.js +31 -0
- package/dist/usePopover-CcsC9Y-s.mjs +143 -0
- package/dist/wrap-children-BLDjJiiy.js +1 -0
- package/dist/wrap-children-aq69jtFP.mjs +12 -0
- package/package.json +56 -4
- package/dist/X5NMLKT6-BC1Q56kB.mjs +0 -1258
- package/dist/X5NMLKT6-vrNG8i_R.js +0 -14
- package/dist/index-0MPAX4B5.mjs +0 -320
- package/dist/index-BNA_A0oa.js +0 -155
- package/dist/index-BXJQXgy9.js +0 -13
- package/dist/index-Bwrtxit1.mjs +0 -84
- package/dist/index-Ct2FOeyM.js +0 -17
- package/dist/index-DRNn5iIc.js +0 -142
- package/dist/index-Du8Nrf16.mjs +0 -128
- package/dist/index-MifIgNHW.mjs +0 -47
- package/dist/index-V28zHt_Z.js +0 -68
package/dist/Tag.mjs
ADDED
|
@@ -0,0 +1,135 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { C } from "./index-ColyClKR.mjs";
|
|
3
|
+
import d from "react";
|
|
4
|
+
import { forwardRef as w } from "./System.mjs";
|
|
5
|
+
import { w as S } from "./wrap-children-aq69jtFP.mjs";
|
|
6
|
+
import m, { css as n, th as i, system as b } from "@xstyled/styled-components";
|
|
7
|
+
import { StyledIcon as A } from "./Icon.mjs";
|
|
8
|
+
import { o as p } from "./overflow-ellipsis-DGV5Kgt-.mjs";
|
|
9
|
+
import { g } from "./get-max-width-height-DoUro2T7.mjs";
|
|
10
|
+
const E = (e, t, s) => n`
|
|
11
|
+
${i(`tags.shape.${e}`)}
|
|
12
|
+
padding: 0;
|
|
13
|
+
${(t || s) && n`
|
|
14
|
+
width: ${g(t || "0", s)};
|
|
15
|
+
height: ${g(t || "0", s)};
|
|
16
|
+
`}
|
|
17
|
+
`, h = m.div.withConfig({
|
|
18
|
+
shouldForwardProp: (e) => !["hasClickAction", "hasLink", "hasRemoveAction"].includes(e)
|
|
19
|
+
})(
|
|
20
|
+
({ h: e, hasClickAction: t, hasLink: s, hasRemoveAction: c, length: a, size: o, variant: r, w: l }) => n`
|
|
21
|
+
${i("tags.default")};
|
|
22
|
+
${i(`tags.variants.${r}`)};
|
|
23
|
+
${i(`tags.sizes.${o}`)}
|
|
24
|
+
position: relative;
|
|
25
|
+
display: inline-flex;
|
|
26
|
+
align-items: center;
|
|
27
|
+
justify-content: center;
|
|
28
|
+
line-height: initial; /* avoid cropped font */
|
|
29
|
+
transition: medium;
|
|
30
|
+
max-width: 100%;
|
|
31
|
+
${p}
|
|
32
|
+
${b}
|
|
33
|
+
${a !== 1 && n`
|
|
34
|
+
span,
|
|
35
|
+
p {
|
|
36
|
+
${p}
|
|
37
|
+
}
|
|
38
|
+
`}
|
|
39
|
+
${a === 1 && n`
|
|
40
|
+
justify-content: center;
|
|
41
|
+
${E(o, l, e)};
|
|
42
|
+
`};
|
|
43
|
+
|
|
44
|
+
${(s || t) && n`
|
|
45
|
+
cursor: pointer;
|
|
46
|
+
text-decoration: none;
|
|
47
|
+
|
|
48
|
+
&:hover,
|
|
49
|
+
&:focus {
|
|
50
|
+
${i(`tags.hover.${r}`)};
|
|
51
|
+
}
|
|
52
|
+
`};
|
|
53
|
+
|
|
54
|
+
${c && n`
|
|
55
|
+
padding-right: xl;
|
|
56
|
+
`}
|
|
57
|
+
|
|
58
|
+
> *:not(:last-child) {
|
|
59
|
+
margin-right: xxs;
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
& > svg {
|
|
63
|
+
width: ${i(`tags.icon.${o}`)};
|
|
64
|
+
height: ${i(`tags.icon.${o}`)};
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
> *:not(:only-child) {
|
|
68
|
+
${/* sc-selector */
|
|
69
|
+
A}:last-child {
|
|
70
|
+
opacity: 1;
|
|
71
|
+
transition: opacity ${i.transition("medium")};
|
|
72
|
+
cursor: pointer;
|
|
73
|
+
|
|
74
|
+
&:hover {
|
|
75
|
+
opacity: 0.7;
|
|
76
|
+
}
|
|
77
|
+
}
|
|
78
|
+
}
|
|
79
|
+
`
|
|
80
|
+
), I = m.divBox(
|
|
81
|
+
({ size: e }) => n`
|
|
82
|
+
position: absolute;
|
|
83
|
+
${i(`tags.sizes.${e}`)};
|
|
84
|
+
top: 0;
|
|
85
|
+
bottom: 0;
|
|
86
|
+
right: 0;
|
|
87
|
+
display: flex;
|
|
88
|
+
align-items: center;
|
|
89
|
+
justify-content: center;
|
|
90
|
+
`
|
|
91
|
+
), k = m.buttonBox`
|
|
92
|
+
all: unset;
|
|
93
|
+
display: flex;
|
|
94
|
+
`, R = w(
|
|
95
|
+
({
|
|
96
|
+
as: e,
|
|
97
|
+
children: t,
|
|
98
|
+
dataTestId: s,
|
|
99
|
+
href: c,
|
|
100
|
+
onClick: a,
|
|
101
|
+
onRemove: o,
|
|
102
|
+
size: r = "md",
|
|
103
|
+
to: l,
|
|
104
|
+
variant: $ = "default",
|
|
105
|
+
...f
|
|
106
|
+
}, u) => {
|
|
107
|
+
const y = S(t), x = !!(t || t === 0) && ["number", "string"].includes(typeof t) ? t.toString().length : void 0, v = !!c || !!l;
|
|
108
|
+
return /* @__PURE__ */ d.createElement(
|
|
109
|
+
h,
|
|
110
|
+
{
|
|
111
|
+
as: e,
|
|
112
|
+
"data-testid": s,
|
|
113
|
+
hasClickAction: !!a,
|
|
114
|
+
hasLink: v,
|
|
115
|
+
hasRemoveAction: !!o,
|
|
116
|
+
href: c,
|
|
117
|
+
length: x,
|
|
118
|
+
onClick: a,
|
|
119
|
+
ref: u,
|
|
120
|
+
size: r,
|
|
121
|
+
to: l,
|
|
122
|
+
variant: $,
|
|
123
|
+
...f
|
|
124
|
+
},
|
|
125
|
+
y,
|
|
126
|
+
!!o && /* @__PURE__ */ d.createElement(I, { size: r }, /* @__PURE__ */ d.createElement(k, { onClick: o, title: "Remove", type: "button" }, /* @__PURE__ */ d.createElement(C, { size: "xs", title: "Remove" })))
|
|
127
|
+
);
|
|
128
|
+
}
|
|
129
|
+
);
|
|
130
|
+
R.displayName = "Tag";
|
|
131
|
+
const P = h;
|
|
132
|
+
export {
|
|
133
|
+
P as StyledTag,
|
|
134
|
+
R as Tag
|
|
135
|
+
};
|
package/dist/Text.js
ADDED
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const m=require("react"),b=require("./System.js"),s=require("@xstyled/styled-components"),p={h0:"h1",h1:"h2",h2:"h3",h3:"h4",h4:"h5",h5:"h6",h6:"h6"},f=e=>s.css`
|
|
2
|
+
/* stylelint-disable-next-line value-no-vendor-prefix */
|
|
3
|
+
display: -webkit-box;
|
|
4
|
+
/* stylelint-disable-next-line property-no-vendor-prefix */
|
|
5
|
+
-webkit-box-orient: vertical;
|
|
6
|
+
/* stylelint-disable-next-line property-no-vendor-prefix */
|
|
7
|
+
-webkit-line-clamp: ${e||"none"};
|
|
8
|
+
line-height: normal;
|
|
9
|
+
overflow: hidden;
|
|
10
|
+
word-break: ${e===1?"break-all":null};
|
|
11
|
+
`,x=s.p(({lines:e,theme:l,variant:t,withDash:o})=>{const n=p[t],h=t==null?void 0:t.startsWith("h"),i=e&&e!==1/0&&t.startsWith("h")&&l.fonts.headings.includes("welcome-font");return s.css`
|
|
12
|
+
${s.th(`texts.${n||t}`)};
|
|
13
|
+
|
|
14
|
+
/* Start fallback for non-webkit */
|
|
15
|
+
display: block;
|
|
16
|
+
${e&&e!==1/0&&f(e)};
|
|
17
|
+
/* End fallback for non-webkit */
|
|
18
|
+
|
|
19
|
+
${o&&h&&s.css`
|
|
20
|
+
display: flex;
|
|
21
|
+
|
|
22
|
+
&:before {
|
|
23
|
+
content: '';
|
|
24
|
+
width: 16;
|
|
25
|
+
height: 4;
|
|
26
|
+
display: flex;
|
|
27
|
+
align-self: center;
|
|
28
|
+
flex-shrink: 0;
|
|
29
|
+
background-color: primary-40;
|
|
30
|
+
margin-right: md;
|
|
31
|
+
}
|
|
32
|
+
`}
|
|
33
|
+
|
|
34
|
+
@media (min-width: lg) {
|
|
35
|
+
${s.th(`texts.${t}`)};
|
|
36
|
+
${s.system};
|
|
37
|
+
}
|
|
38
|
+
|
|
39
|
+
${i&&s.css`
|
|
40
|
+
& {
|
|
41
|
+
line-height: 1.4;
|
|
42
|
+
}
|
|
43
|
+
`}
|
|
44
|
+
|
|
45
|
+
${s.system};
|
|
46
|
+
`}),y={h0:"h1",h1:"h1",h2:"h2",h3:"h3",h4:"h4",h5:"h5",h6:"h6",lg:"p",md:"p",sm:"p",xs:"p","subtitle-md":"span","subtitle-sm":"span"},r=b.forwardRef(({as:e,children:l,dataTestId:t,lines:o,variant:n="md",withDash:h,...i},c)=>{const d=e||y[n],a=i.className||"";return m.createElement(x,{as:d,"data-testid":t,lines:o,ref:c,variant:n,withDash:h,...i,className:`${a} wui-text`},l)});r.displayName="Text";exports.Text=r;
|
package/dist/Text.mjs
ADDED
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import p from "react";
|
|
3
|
+
import { forwardRef as f } from "./System.mjs";
|
|
4
|
+
import b, { css as n, th as r, system as d } from "@xstyled/styled-components";
|
|
5
|
+
const x = {
|
|
6
|
+
h0: "h1",
|
|
7
|
+
h1: "h2",
|
|
8
|
+
h2: "h3",
|
|
9
|
+
h3: "h4",
|
|
10
|
+
h4: "h5",
|
|
11
|
+
h5: "h6",
|
|
12
|
+
h6: "h6"
|
|
13
|
+
}, g = (e) => n`
|
|
14
|
+
/* stylelint-disable-next-line value-no-vendor-prefix */
|
|
15
|
+
display: -webkit-box;
|
|
16
|
+
/* stylelint-disable-next-line property-no-vendor-prefix */
|
|
17
|
+
-webkit-box-orient: vertical;
|
|
18
|
+
/* stylelint-disable-next-line property-no-vendor-prefix */
|
|
19
|
+
-webkit-line-clamp: ${e || "none"};
|
|
20
|
+
line-height: normal;
|
|
21
|
+
overflow: hidden;
|
|
22
|
+
word-break: ${e === 1 ? "break-all" : null};
|
|
23
|
+
`, y = b.p(({ lines: e, theme: o, variant: t, withDash: s }) => {
|
|
24
|
+
const l = x[t], h = t == null ? void 0 : t.startsWith("h"), i = e && e !== 1 / 0 && t.startsWith("h") && o.fonts.headings.includes("welcome-font");
|
|
25
|
+
return n`
|
|
26
|
+
${r(`texts.${l || t}`)};
|
|
27
|
+
|
|
28
|
+
/* Start fallback for non-webkit */
|
|
29
|
+
display: block;
|
|
30
|
+
${e && e !== 1 / 0 && g(e)};
|
|
31
|
+
/* End fallback for non-webkit */
|
|
32
|
+
|
|
33
|
+
${s && h && n`
|
|
34
|
+
display: flex;
|
|
35
|
+
|
|
36
|
+
&:before {
|
|
37
|
+
content: '';
|
|
38
|
+
width: 16;
|
|
39
|
+
height: 4;
|
|
40
|
+
display: flex;
|
|
41
|
+
align-self: center;
|
|
42
|
+
flex-shrink: 0;
|
|
43
|
+
background-color: primary-40;
|
|
44
|
+
margin-right: md;
|
|
45
|
+
}
|
|
46
|
+
`}
|
|
47
|
+
|
|
48
|
+
@media (min-width: lg) {
|
|
49
|
+
${r(`texts.${t}`)};
|
|
50
|
+
${d};
|
|
51
|
+
}
|
|
52
|
+
|
|
53
|
+
${i && n`
|
|
54
|
+
& {
|
|
55
|
+
line-height: 1.4;
|
|
56
|
+
}
|
|
57
|
+
`}
|
|
58
|
+
|
|
59
|
+
${d};
|
|
60
|
+
`;
|
|
61
|
+
}), k = {
|
|
62
|
+
h0: "h1",
|
|
63
|
+
h1: "h1",
|
|
64
|
+
h2: "h2",
|
|
65
|
+
h3: "h3",
|
|
66
|
+
h4: "h4",
|
|
67
|
+
h5: "h5",
|
|
68
|
+
h6: "h6",
|
|
69
|
+
lg: "p",
|
|
70
|
+
md: "p",
|
|
71
|
+
sm: "p",
|
|
72
|
+
xs: "p",
|
|
73
|
+
"subtitle-md": "span",
|
|
74
|
+
"subtitle-sm": "span"
|
|
75
|
+
}, u = f(
|
|
76
|
+
({ as: e, children: o, dataTestId: t, lines: s, variant: l = "md", withDash: h, ...i }, a) => {
|
|
77
|
+
const c = e || k[l], m = i.className || "";
|
|
78
|
+
return /* @__PURE__ */ p.createElement(
|
|
79
|
+
y,
|
|
80
|
+
{
|
|
81
|
+
as: c,
|
|
82
|
+
"data-testid": t,
|
|
83
|
+
lines: s,
|
|
84
|
+
ref: a,
|
|
85
|
+
variant: l,
|
|
86
|
+
withDash: h,
|
|
87
|
+
...i,
|
|
88
|
+
className: `${m} wui-text`
|
|
89
|
+
},
|
|
90
|
+
o
|
|
91
|
+
);
|
|
92
|
+
}
|
|
93
|
+
);
|
|
94
|
+
u.displayName = "Text";
|
|
95
|
+
export {
|
|
96
|
+
u as Text
|
|
97
|
+
};
|
package/dist/Textarea.js
ADDED
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const S=require("react"),a=require("./System.js"),e=require("@xstyled/styled-components"),T=require("./field-styles-D_gf6ypV.js"),p=e("textarea").withConfig({shouldForwardProp:a.shouldForwardProp})(({size:t,variant:r})=>e.css`
|
|
2
|
+
${T.defaultFieldStyles({size:t,variant:r})};
|
|
3
|
+
${e.th("textareas")};
|
|
4
|
+
line-height: lg;
|
|
5
|
+
${e.system};
|
|
6
|
+
`),s=a.forwardRef(({autoFocus:t,dataTestId:r,disabled:o,maxLength:i,minRows:l=5,name:d,onBlur:c,onChange:n,onFocus:u,onKeyDown:y,placeholder:f,size:h="md",value:m,variant:x,...g},w)=>S.createElement(p,{autoFocus:t,"data-testid":r,disabled:o,maxLength:i,name:d,onBlur:c,onChange:n,onFocus:u,onKeyDown:y,placeholder:f,ref:w,rows:l,size:h,value:m,variant:x,...g}));s.displayName="Textarea";exports.Textarea=s;
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import u from "react";
|
|
3
|
+
import { shouldForwardProp as w, forwardRef as y } from "./System.mjs";
|
|
4
|
+
import _, { css as $, th as g, system as T } from "@xstyled/styled-components";
|
|
5
|
+
import { d as F } from "./field-styles-CeV7pnOp.mjs";
|
|
6
|
+
const R = _("textarea").withConfig({ shouldForwardProp: w })(
|
|
7
|
+
({ size: e, variant: t }) => $`
|
|
8
|
+
${F({ size: e, variant: t })};
|
|
9
|
+
${g("textareas")};
|
|
10
|
+
line-height: lg;
|
|
11
|
+
${T};
|
|
12
|
+
`
|
|
13
|
+
), C = y(
|
|
14
|
+
({
|
|
15
|
+
autoFocus: e,
|
|
16
|
+
dataTestId: t,
|
|
17
|
+
disabled: a,
|
|
18
|
+
maxLength: r,
|
|
19
|
+
minRows: o = 5,
|
|
20
|
+
name: s,
|
|
21
|
+
onBlur: d,
|
|
22
|
+
onChange: i,
|
|
23
|
+
onFocus: l,
|
|
24
|
+
onKeyDown: m,
|
|
25
|
+
placeholder: f,
|
|
26
|
+
size: p = "md",
|
|
27
|
+
value: c,
|
|
28
|
+
variant: n,
|
|
29
|
+
...x
|
|
30
|
+
}, h) => /* @__PURE__ */ u.createElement(
|
|
31
|
+
R,
|
|
32
|
+
{
|
|
33
|
+
autoFocus: e,
|
|
34
|
+
"data-testid": t,
|
|
35
|
+
disabled: a,
|
|
36
|
+
maxLength: r,
|
|
37
|
+
name: s,
|
|
38
|
+
onBlur: d,
|
|
39
|
+
onChange: i,
|
|
40
|
+
onFocus: l,
|
|
41
|
+
onKeyDown: m,
|
|
42
|
+
placeholder: f,
|
|
43
|
+
ref: h,
|
|
44
|
+
rows: o,
|
|
45
|
+
size: p,
|
|
46
|
+
value: c,
|
|
47
|
+
variant: n,
|
|
48
|
+
...x
|
|
49
|
+
}
|
|
50
|
+
)
|
|
51
|
+
);
|
|
52
|
+
C.displayName = "Textarea";
|
|
53
|
+
export {
|
|
54
|
+
C as Textarea
|
|
55
|
+
};
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const s=require("react"),c=require("./CustomInput-9aCUiD6o.js"),H=require("./System.js"),I=require("@xstyled/styled-components"),O=I.div`
|
|
2
|
+
position: relative;
|
|
3
|
+
${c.fixAriaMessageStyle}
|
|
4
|
+
`,S=H.forwardRef(({autoFocus:y,dataTestId:E,dateFormat:k="HH:mm",disabled:P,icon:a,iconPlacement:u="left",onBlur:m,onChange:t,onFocus:n,placeholder:g,popperProps:h,size:d="md",timeIntervals:p=15,transparent:q,value:l=c.DEFAULT_DATE,...f},D)=>{const i=e=>c.getDate(e,p),F=g||f.placeholderText,[R,T]=s.useState(y&&"time"||null),[b,o]=s.useState(i(l));s.useEffect(()=>{t&&t(i(l))},[]),s.useEffect(()=>{var r;const e=i(l);((r=new Date(l))==null?void 0:r.getTime())-(e==null?void 0:e.getTime())!==0&&t&&t(e),o(e)},[l]);const x=e=>{T("time"),n&&n(e)},A=e=>{T(null),m&&m(e)},M=e=>{e.preventDefault(),o(null),t&&t()},N=e=>{if(!e)return;const r=i(e);e.setFullYear(r.getFullYear(),r.getMonth(),r.getDate()),o(e),t&&t(new Date(e))};return s.createElement(O,null,s.createElement(c.StyledTimePicker,{calendarClassName:"time-picker-popper",customInput:s.createElement(c.CustomInput,{className:"time-picker","data-testid":E,focused:R,handleBlur:A,handleFocus:x,icon:a,iconPlacement:u,onReset:M,ref:D,size:d}),dateFormat:k,disabled:P,iconPlacement:!!a&&u,onChange:N,placeholderText:F,popperContainer:c.CustomPopper,popperProps:h,selected:b,showTimeSelect:!0,showTimeSelectOnly:!0,size:d,timeIntervals:p,transparent:q,...f,isClearable:!1}))});S.displayName="TimePicker";exports.TimePicker=S;
|
|
@@ -0,0 +1,88 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import c, { useState as T, useEffect as E } from "react";
|
|
3
|
+
import { f as M, a as Y, c as w, b as I, D as L, g as O } from "./CustomInput-CenfXh_H.mjs";
|
|
4
|
+
import { forwardRef as U } from "./System.mjs";
|
|
5
|
+
import W from "@xstyled/styled-components";
|
|
6
|
+
const $ = W.div`
|
|
7
|
+
position: relative;
|
|
8
|
+
${M}
|
|
9
|
+
`, j = U(
|
|
10
|
+
({
|
|
11
|
+
autoFocus: k,
|
|
12
|
+
dataTestId: y,
|
|
13
|
+
dateFormat: D = "HH:mm",
|
|
14
|
+
disabled: S,
|
|
15
|
+
icon: i,
|
|
16
|
+
iconPlacement: m = "left",
|
|
17
|
+
onBlur: o,
|
|
18
|
+
onChange: t,
|
|
19
|
+
onFocus: p,
|
|
20
|
+
placeholder: _,
|
|
21
|
+
popperProps: h,
|
|
22
|
+
size: d = "md",
|
|
23
|
+
timeIntervals: n = 15,
|
|
24
|
+
transparent: x,
|
|
25
|
+
value: l = L,
|
|
26
|
+
...u
|
|
27
|
+
}, F) => {
|
|
28
|
+
const r = (e) => O(e, n), P = _ || u.placeholderText, [R, f] = T(k && "time" || null), [g, a] = T(r(l));
|
|
29
|
+
E(() => {
|
|
30
|
+
t && t(r(l));
|
|
31
|
+
}, []), E(() => {
|
|
32
|
+
var s;
|
|
33
|
+
const e = r(l);
|
|
34
|
+
((s = new Date(l)) == null ? void 0 : s.getTime()) - (e == null ? void 0 : e.getTime()) !== 0 && t && t(e), a(e);
|
|
35
|
+
}, [l]);
|
|
36
|
+
const A = (e) => {
|
|
37
|
+
f("time"), p && p(e);
|
|
38
|
+
}, N = (e) => {
|
|
39
|
+
f(null), o && o(e);
|
|
40
|
+
}, b = (e) => {
|
|
41
|
+
e.preventDefault(), a(null), t && t();
|
|
42
|
+
}, H = (e) => {
|
|
43
|
+
if (!e) return;
|
|
44
|
+
const s = r(e);
|
|
45
|
+
e.setFullYear(s.getFullYear(), s.getMonth(), s.getDate()), a(e), t && t(new Date(e));
|
|
46
|
+
};
|
|
47
|
+
return /* @__PURE__ */ c.createElement($, null, /* @__PURE__ */ c.createElement(
|
|
48
|
+
Y,
|
|
49
|
+
{
|
|
50
|
+
calendarClassName: "time-picker-popper",
|
|
51
|
+
customInput: /* @__PURE__ */ c.createElement(
|
|
52
|
+
w,
|
|
53
|
+
{
|
|
54
|
+
className: "time-picker",
|
|
55
|
+
"data-testid": y,
|
|
56
|
+
focused: R,
|
|
57
|
+
handleBlur: N,
|
|
58
|
+
handleFocus: A,
|
|
59
|
+
icon: i,
|
|
60
|
+
iconPlacement: m,
|
|
61
|
+
onReset: b,
|
|
62
|
+
ref: F,
|
|
63
|
+
size: d
|
|
64
|
+
}
|
|
65
|
+
),
|
|
66
|
+
dateFormat: D,
|
|
67
|
+
disabled: S,
|
|
68
|
+
iconPlacement: !!i && m,
|
|
69
|
+
onChange: H,
|
|
70
|
+
placeholderText: P,
|
|
71
|
+
popperContainer: I,
|
|
72
|
+
popperProps: h,
|
|
73
|
+
selected: g,
|
|
74
|
+
showTimeSelect: !0,
|
|
75
|
+
showTimeSelectOnly: !0,
|
|
76
|
+
size: d,
|
|
77
|
+
timeIntervals: n,
|
|
78
|
+
transparent: x,
|
|
79
|
+
...u,
|
|
80
|
+
isClearable: !1
|
|
81
|
+
}
|
|
82
|
+
));
|
|
83
|
+
}
|
|
84
|
+
);
|
|
85
|
+
j.displayName = "TimePicker";
|
|
86
|
+
export {
|
|
87
|
+
j as TimePicker
|
|
88
|
+
};
|
package/dist/Toast.js
ADDED
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
"use client";"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const a=require("react"),l=require("@xstyled/styled-components"),q=require("./index-BHi0wohR.js"),T=require("./Box.js"),A=require("./Alert.js"),B=require("./CloseButton.js"),C=require("./System.js"),M=require("./Button.js");var N=t=>typeof t=="function",$=(t,e)=>N(t)?t(e):t,R=(()=>{let t=0;return()=>(++t).toString()})(),G=20,x=new Map,z=1e3,P=t=>{if(x.has(t))return;let e=setTimeout(()=>{x.delete(t),h({type:4,toastId:t})},z);x.set(t,e)},H=t=>{let e=x.get(t);e&&clearTimeout(e)},S=(t,e)=>{switch(e.type){case 0:return{...t,toasts:[e.toast,...t.toasts].slice(0,G)};case 1:return e.toast.id&&H(e.toast.id),{...t,toasts:t.toasts.map(o=>o.id===e.toast.id?{...o,...e.toast}:o)};case 2:let{toast:s}=e;return t.toasts.find(o=>o.id===s.id)?S(t,{type:1,toast:s}):S(t,{type:0,toast:s});case 3:let{toastId:n}=e;return n?P(n):t.toasts.forEach(o=>{P(o.id)}),{...t,toasts:t.toasts.map(o=>o.id===n||n===void 0?{...o,visible:!1}:o)};case 4:return e.toastId===void 0?{...t,toasts:[]}:{...t,toasts:t.toasts.filter(o=>o.id!==e.toastId)};case 5:return{...t,pausedAt:e.time};case 6:let r=e.time-(t.pausedAt||0);return{...t,pausedAt:void 0,toasts:t.toasts.map(o=>({...o,pauseDuration:o.pauseDuration+r}))}}},E=[],k={toasts:[],pausedAt:void 0},h=t=>{k=S(k,t),E.forEach(e=>{e(k)})},L={blank:4e3,error:4e3,success:2e3,loading:1/0,custom:4e3},W=(t={})=>{let[e,s]=a.useState(k);a.useEffect(()=>(E.push(s),()=>{let r=E.indexOf(s);r>-1&&E.splice(r,1)}),[e]);let n=e.toasts.map(r=>{var o,u;return{...t,...t[r.type],...r,duration:r.duration||((o=t[r.type])==null?void 0:o.duration)||(t==null?void 0:t.duration)||L[r.type],style:{...t.style,...(u=t[r.type])==null?void 0:u.style,...r.style}}});return{...e,toasts:n}},Y=(t,e="blank",s)=>({createdAt:Date.now(),visible:!0,type:e,ariaProps:{role:"status","aria-live":"polite"},message:t,pauseDuration:0,...s,id:(s==null?void 0:s.id)||R()}),v=t=>(e,s)=>{let n=Y(e,t,s);return h({type:2,toast:n}),n.id},c=(t,e)=>v("blank")(t,e);c.error=v("error");c.success=v("success");c.loading=v("loading");c.custom=v("custom");c.dismiss=t=>{h({type:3,toastId:t})};c.remove=t=>h({type:4,toastId:t});c.promise=(t,e,s)=>{let n=c.loading(e.loading,{...s,...s==null?void 0:s.loading});return t.then(r=>(c.success($(e.success,r),{id:n,...s,...s==null?void 0:s.success}),r)).catch(r=>{c.error($(e.error,r),{id:n,...s,...s==null?void 0:s.error})}),t};var _=(t,e)=>{h({type:1,toast:{id:t,height:e}})},j=()=>{h({type:5,time:Date.now()})},U=t=>{let{toasts:e,pausedAt:s}=W(t);a.useEffect(()=>{if(s)return;let o=Date.now(),u=e.map(i=>{if(i.duration===1/0)return;let f=(i.duration||0)+i.pauseDuration-(o-i.createdAt);if(f<0){i.visible&&c.dismiss(i.id);return}return setTimeout(()=>c.dismiss(i.id),f)});return()=>{u.forEach(i=>i&&clearTimeout(i))}},[e,s]);let n=a.useCallback(()=>{s&&h({type:6,time:Date.now()})},[s]),r=a.useCallback((o,u)=>{let{reverseOrder:i=!1,gutter:f=8,defaultPosition:p}=u||{},m=e.filter(d=>(d.position||p)===(o.position||p)&&d.height),g=m.findIndex(d=>d.id===o.id),y=m.filter((d,b)=>b<g&&d.visible).length;return m.filter(d=>d.visible).slice(...i?[y+1]:[0,y]).reduce((d,b)=>d+(b.height||0)+f,0)},[e]);return{toasts:e,handlers:{updateHeight:_,startPause:j,endPause:n,calculateOffset:r}}},w=c;function F(t=!1){const[e,s]=a.useState(!1);return a.useEffect(()=>{s(!0)},[]),a.useMemo(()=>t?n=>n:e?(n,r,o)=>q.reactDomExports.createPortal(n,r||document.body,o):()=>null,[t,e])}const J=l(T.Box)(({isBottom:t})=>l.css`
|
|
2
|
+
${l.th("toasts.default")}
|
|
3
|
+
${t?l.th("toasts.bottom"):l.th("toasts.top")}
|
|
4
|
+
|
|
5
|
+
position: fixed;
|
|
6
|
+
z-index: 9999;
|
|
7
|
+
transition: all 400ms ease-out;
|
|
8
|
+
`),K=l(A.Alert)(()=>l.css`
|
|
9
|
+
position: relative;
|
|
10
|
+
padding: lg;
|
|
11
|
+
${l.th("toasts.growls.default")};
|
|
12
|
+
|
|
13
|
+
div:first-of-type {
|
|
14
|
+
align-self: baseline;
|
|
15
|
+
}
|
|
16
|
+
|
|
17
|
+
button {
|
|
18
|
+
flex-shrink: 0;
|
|
19
|
+
}
|
|
20
|
+
`),Q=l(T.Box)(()=>l.css`
|
|
21
|
+
display: flex;
|
|
22
|
+
align-items: center;
|
|
23
|
+
padding-bottom: xs;
|
|
24
|
+
${l.th("toasts.growls.title")};
|
|
25
|
+
|
|
26
|
+
& > *:first-child {
|
|
27
|
+
flex-shrink: 0;
|
|
28
|
+
}
|
|
29
|
+
`),V=l(A.Alert)`
|
|
30
|
+
display: flex;
|
|
31
|
+
align-items: center;
|
|
32
|
+
padding: sm md;
|
|
33
|
+
${l.th("toasts.snackbar.default")};
|
|
34
|
+
|
|
35
|
+
> div {
|
|
36
|
+
align-self: center !important;
|
|
37
|
+
}
|
|
38
|
+
`,X=l.box(({variant:t})=>l.css`
|
|
39
|
+
${l.th("toasts.snackbar.separator.default")};
|
|
40
|
+
${l.th(`toasts.snackbar.separator.${t}`)};
|
|
41
|
+
padding-left: sm;
|
|
42
|
+
`),Z={"top-left":{top:0,left:0},"top-center":{top:0,left:"50%"},"top-right":{top:0,right:0},"bottom-left":{bottom:0,left:0},"bottom-center":{bottom:0,left:"50%"},"bottom-right":{bottom:0,right:0}},tt=({calculateOffset:t,toast:e,updateHeight:s})=>{var m,g,y;if(typeof e.message=="string")return console.warn("You must pass a React component or a HTML element."),null;const n=t(e,{reverseOrder:!1,gutter:0}),r=d=>{if(d&&typeof e.height!="number"){const b=d.getBoundingClientRect().height;s(e.id,b)}},o=(m=e.position)==null?void 0:m.includes("center"),u=(g=e.position)==null?void 0:g.includes("top"),i=(y=e.position)==null?void 0:y.includes("bottom"),f=()=>{e.onClose&&e.onClose(),w.dismiss(e.id)},p={opacity:e.visible?1:0,transform:`translate(${o?"-50%":"0"}, ${n*(u?1:-1)}px)`,...Z[e.position]};return a.createElement(J,{isBottom:i,opacity:p.opacity,ref:r,style:p,transform:p.transform,...e.ariaProps},a.cloneElement(e.message,{onClose:f}))},D=C.forwardRef(({children:t,dataTestId:e,hasCloseButton:s=!0,icon:n,onClose:r,variant:o="default"},u)=>{const i=e?`${e}-close-button`:void 0;return a.createElement(K,{"data-testid":e,hasCloseButton:s,icon:n,ref:u,variant:o},s&&a.createElement(B.CloseButton,{dataTestId:i,onClick:r,position:"absolute",right:"sm",top:"sm"}),a.createElement(T.Box,{pr:"xl"},t))});D.displayName="Growl";const I=C.forwardRef(({children:t,cta:e,hasCloseButton:s=!0,icon:n,onClose:r,variant:o="default",...u},i)=>a.createElement(V,{icon:n,ref:i,variant:o,...u},a.createElement(T.Box,{alignItems:"center",display:"flex",gap:"sm"},t,e&&a.createElement(X,{variant:o},e),s&&a.createElement(B.CloseButton,{onClick:r,size:"xs"})))),et=C.forwardRef((t,e)=>a.createElement(M.Button,{flexShrink:0,ref:e,size:"xs",variant:"ghost",...t}));I.displayName="Snackbar";const st=({pauseOnHover:t=!0})=>{const e=a.useContext(l.ThemeContext),s=F(),{handlers:n,toasts:r}=U(),{calculateOffset:o,endPause:u,startPause:i,updateHeight:f}=n,p=t?i:void 0,m=t?u:void 0;return a.createElement(l.ThemeProvider,{theme:e},r.length>0&&s(a.createElement("div",{onMouseEnter:p,onMouseLeave:m},r.map(g=>a.createElement(tt,{calculateOffset:o,key:g.id,toast:g,updateHeight:f})))))},ot=({children:t,...e})=>a.createElement(Q,{...e},t),O=(t,e)=>{var o,u;const r={duration:7e3,position:(typeof t=="string"?void 0:((o=t==null?void 0:t.type)==null?void 0:o.displayName)||((u=t==null?void 0:t.type)==null?void 0:u.name))==="Growl"?"top-right":"bottom-center",...e};return w(t,r)},rt=t=>{w.remove(t)},nt=t=>{w.dismiss(t)},at=()=>O,it={Title:ot,Growl:D,Snackbar:I,SnackbarAction:et};exports.Notifications=st;exports.Toast=it;exports.dismiss=nt;exports.remove=rt;exports.toast=O;exports.useToast=at;
|