@cube-dev/ui-kit 0.8.5 → 0.9.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/README.md +26 -0
- package/dist/cjs/components/Base.js +58 -0
- package/dist/cjs/components/Block.js +25 -0
- package/dist/cjs/components/GlobalStyles.js +322 -0
- package/dist/cjs/components/GridProvider.js +84 -0
- package/dist/cjs/components/HiddenInput.js +39 -0
- package/dist/cjs/components/OpenTrasition.js +38 -0
- package/dist/cjs/components/Root.js +50 -0
- package/dist/cjs/components/actions/Action.js +136 -0
- package/dist/cjs/components/actions/Button/Button.js +313 -0
- package/dist/cjs/components/actions/Button/Submit.js +29 -0
- package/dist/cjs/components/actions/Button/index.js +23 -0
- package/dist/cjs/components/actions/ButtonGroup/ButtonGroup.js +28 -0
- package/dist/cjs/components/actions/index.js +28 -0
- package/dist/cjs/components/content/ActiveZone/ActiveZone.js +44 -0
- package/dist/cjs/components/content/Avatar/Avatar.js +39 -0
- package/dist/cjs/components/content/Badge/Badge.js +58 -0
- package/dist/cjs/components/content/Card/Card.js +30 -0
- package/dist/cjs/components/content/Content.js +42 -0
- package/dist/cjs/components/content/Divider.js +53 -0
- package/dist/cjs/components/content/Footer.js +36 -0
- package/dist/cjs/components/content/Header.js +35 -0
- package/dist/cjs/components/content/Paragraph.js +27 -0
- package/dist/cjs/components/content/Placeholder/Placeholder.js +51 -0
- package/dist/cjs/components/content/PrismCode/PrismCode.js +44 -0
- package/dist/cjs/components/content/Result/Result.js +105 -0
- package/dist/cjs/components/content/Skeleton/Skeleton.js +79 -0
- package/dist/cjs/components/content/Tag/Tag.js +94 -0
- package/dist/cjs/components/content/Text.js +81 -0
- package/dist/cjs/components/content/Title.js +69 -0
- package/dist/cjs/components/forms/Checkbox/Checkbox.js +177 -0
- package/dist/cjs/components/forms/Checkbox/CheckboxGroup.js +110 -0
- package/dist/cjs/components/forms/Checkbox/context.js +14 -0
- package/dist/cjs/components/forms/FieldWrapper.js +82 -0
- package/dist/cjs/components/forms/FileInput/FileInput.js +151 -0
- package/dist/cjs/components/forms/Form/Field.js +234 -0
- package/dist/cjs/components/forms/Form/Form.js +125 -0
- package/dist/cjs/components/forms/Form/index.js +20 -0
- package/dist/cjs/components/forms/Form/useForm.js +280 -0
- package/dist/cjs/components/forms/Form/validation.js +149 -0
- package/dist/cjs/components/forms/Label.js +90 -0
- package/dist/cjs/components/forms/NumberInput/NumberInput.js +50 -0
- package/dist/cjs/components/forms/NumberInput/StepButton.js +35 -0
- package/dist/cjs/components/forms/PasswordInput/PasswordInput.js +43 -0
- package/dist/cjs/components/forms/RadioGroup/Radio.js +181 -0
- package/dist/cjs/components/forms/RadioGroup/RadioGroup.js +113 -0
- package/dist/cjs/components/forms/RadioGroup/context.js +18 -0
- package/dist/cjs/components/forms/SearchInput/SearchInput.js +45 -0
- package/dist/cjs/components/forms/Switch/Switch.js +156 -0
- package/dist/cjs/components/forms/TextArea/TextArea.js +63 -0
- package/dist/cjs/components/forms/TextInput/TextInput.js +33 -0
- package/dist/cjs/components/forms/TextInput/TextInputBase.js +167 -0
- package/dist/cjs/components/forms/index.js +30 -0
- package/dist/cjs/components/layout/Flex.js +26 -0
- package/dist/cjs/components/layout/Flow.js +27 -0
- package/dist/cjs/components/layout/Grid.js +33 -0
- package/dist/cjs/components/layout/Prefix.js +46 -0
- package/dist/cjs/components/layout/Space.js +35 -0
- package/dist/cjs/components/layout/Suffix.js +45 -0
- package/dist/cjs/components/navigation/LegacyTabs/LegacyTabs.js +255 -0
- package/dist/cjs/components/navigation/Link/Link.js +18 -0
- package/dist/cjs/components/organisms/Alert/Alert.js +41 -0
- package/dist/cjs/components/organisms/CopySnippet/CopySnippet.js +112 -0
- package/dist/cjs/components/organisms/DirectoryTree/DirectoryTree.js +166 -0
- package/dist/cjs/components/organisms/FileTabs/FileTabs.js +300 -0
- package/dist/cjs/components/organisms/Modal/Modal.js +258 -0
- package/dist/cjs/components/organisms/SearchResults/SearchResults.js +108 -0
- package/dist/cjs/components/organisms/StatsCard/StatsCard.js +20 -0
- package/dist/cjs/components/organisms/TopBar/TopBar.js +33 -0
- package/dist/cjs/components/other/Base64Upload/Base64Upload.js +110 -0
- package/dist/cjs/components/other/CloudLogo/CloudLogo.js +43 -0
- package/dist/cjs/components/overlays/AlertDialog/AlertDialog.js +59 -0
- package/dist/cjs/components/overlays/AlertDialog/AlertDialogApiProvider.js +114 -0
- package/dist/cjs/components/overlays/AlertDialog/AlertDialogZone.js +58 -0
- package/dist/cjs/components/overlays/AlertDialog/index.js +24 -0
- package/dist/cjs/components/overlays/AlertDialog/types.js +11 -0
- package/dist/cjs/components/overlays/Dialog/Dialog.js +181 -0
- package/dist/cjs/components/overlays/Dialog/DialogContainer.js +42 -0
- package/dist/cjs/components/overlays/Dialog/DialogForm.js +56 -0
- package/dist/cjs/components/overlays/Dialog/DialogTrigger.js +116 -0
- package/dist/cjs/components/overlays/Dialog/context.js +14 -0
- package/dist/cjs/components/overlays/Dialog/index.js +25 -0
- package/dist/cjs/components/overlays/Modal/Modal.js +86 -0
- package/dist/cjs/components/overlays/Modal/OpenTransition.js +26 -0
- package/dist/cjs/components/overlays/Modal/Overlay.js +40 -0
- package/dist/cjs/components/overlays/Modal/Popover.js +59 -0
- package/dist/cjs/components/overlays/Modal/Tray.js +95 -0
- package/dist/cjs/components/overlays/Modal/Underlay.js +51 -0
- package/dist/cjs/components/overlays/Modal/index.js +22 -0
- package/dist/cjs/components/overlays/Notification/Notification.js +44 -0
- package/dist/cjs/components/overlays/OverlayWrapper.js +35 -0
- package/dist/cjs/components/overlays/Tooltip/Tooltip.js +100 -0
- package/dist/cjs/components/overlays/Tooltip/TooltipProvider.js +26 -0
- package/dist/cjs/components/overlays/Tooltip/TooltipTrigger.js +71 -0
- package/dist/cjs/components/overlays/Tooltip/context.js +17 -0
- package/dist/cjs/components/pickers/ComboBox/ComboBox.js +170 -0
- package/dist/cjs/components/pickers/Select/Select.js +257 -0
- package/dist/cjs/components/portal/Portal.js +48 -0
- package/dist/cjs/components/portal/PortalProvider.js +28 -0
- package/dist/cjs/components/portal/index.js +25 -0
- package/dist/cjs/components/portal/storybook/templates/basic.js +17 -0
- package/dist/cjs/components/portal/storybook/templates/index.js +22 -0
- package/dist/cjs/components/portal/types.js +11 -0
- package/dist/cjs/components/portal/usePortal.js +48 -0
- package/dist/cjs/components/status/LoadingAnimation/LoadingAnimation.js +139 -0
- package/dist/cjs/components/status/Spin/Spin.js +38 -0
- package/dist/cjs/components/types.js +11 -0
- package/dist/cjs/data/themes.js +33 -0
- package/dist/cjs/index.js +182 -30
- package/dist/cjs/provider.js +51 -0
- package/dist/cjs/providers/BreakpointsProvider.js +20 -0
- package/dist/cjs/providers/StylesProvider.js +42 -0
- package/dist/cjs/services/notification.js +67 -0
- package/dist/cjs/shared/form.js +11 -0
- package/dist/cjs/shared/index.js +22 -0
- package/dist/cjs/stories/FormFieldArgs.js +288 -0
- package/dist/cjs/stories/components/ConfirmDeletionDialogForm.js +36 -0
- package/dist/cjs/stories/components/DialogFormApp.js +27 -0
- package/dist/cjs/stories/components/StyledButton.js +37 -0
- package/dist/cjs/stories/lists/baseProps.js +42 -0
- package/dist/cjs/styled/index.js +22 -0
- package/dist/cjs/styled/styled.js +106 -0
- package/dist/cjs/styles/align.js +24 -0
- package/dist/cjs/styles/border.js +52 -0
- package/dist/cjs/styles/boxShadow.combinator.js +26 -0
- package/dist/cjs/styles/color.js +43 -0
- package/dist/cjs/styles/dimension.js +89 -0
- package/dist/cjs/styles/display.js +17 -0
- package/dist/cjs/styles/fill.js +42 -0
- package/dist/cjs/styles/flow.js +24 -0
- package/dist/cjs/styles/font.js +27 -0
- package/dist/cjs/styles/fontStyle.js +23 -0
- package/dist/cjs/styles/gap.js +67 -0
- package/dist/cjs/styles/groupRadius.js +64 -0
- package/dist/cjs/styles/height.js +19 -0
- package/dist/cjs/styles/index.js +105 -0
- package/dist/cjs/styles/justify.js +24 -0
- package/dist/cjs/styles/list.js +87 -0
- package/dist/cjs/styles/margin.js +50 -0
- package/dist/cjs/styles/marginBlock.js +36 -0
- package/dist/cjs/styles/marginInline.js +40 -0
- package/dist/cjs/styles/outline.js +28 -0
- package/dist/cjs/styles/padding.js +51 -0
- package/dist/cjs/styles/paddingBlock.js +40 -0
- package/dist/cjs/styles/paddingInline.js +40 -0
- package/dist/cjs/styles/predefined.js +122 -0
- package/dist/cjs/styles/preset.js +55 -0
- package/dist/cjs/styles/radius.js +76 -0
- package/dist/cjs/styles/reset.js +104 -0
- package/dist/cjs/styles/shadow.js +27 -0
- package/dist/cjs/styles/styledScrollbar.js +55 -0
- package/dist/cjs/styles/transition.js +88 -0
- package/dist/cjs/styles/types.js +11 -0
- package/dist/cjs/styles/width.js +19 -0
- package/dist/cjs/test/setup.js +14 -0
- package/dist/cjs/tokens.js +233 -0
- package/dist/cjs/utils/ResizeSensor.js +324 -0
- package/dist/cjs/utils/colors.js +19 -0
- package/dist/cjs/utils/dotize.js +194 -0
- package/dist/cjs/utils/escape-string.js +21 -0
- package/dist/cjs/utils/filterBaseProps.js +69 -0
- package/dist/cjs/utils/index.js +46 -0
- package/dist/cjs/utils/interactions.js +29 -0
- package/dist/cjs/utils/mergeStyles.js +36 -0
- package/dist/cjs/utils/modules.js +16 -0
- package/dist/cjs/utils/promise.js +18 -0
- package/dist/cjs/utils/react/Slots.js +48 -0
- package/dist/cjs/utils/react/chain.js +25 -0
- package/dist/cjs/utils/react/index.js +30 -0
- package/dist/cjs/utils/react/isTextOnly.js +17 -0
- package/dist/cjs/utils/react/mapProps.js +30 -0
- package/dist/cjs/utils/react/mergeProps.js +67 -0
- package/dist/cjs/utils/react/modAttrs.js +26 -0
- package/dist/cjs/utils/react/nullableValue.js +46 -0
- package/dist/cjs/utils/react/useCombinedRefs.js +30 -0
- package/dist/cjs/utils/react/useId.js +87 -0
- package/dist/cjs/utils/react/useLayoutEffect.js +36 -0
- package/dist/cjs/utils/react/wrapNodeIfPlain.js +22 -0
- package/dist/cjs/utils/renderStyles.js +132 -0
- package/dist/cjs/utils/responsive.js +72 -0
- package/dist/cjs/utils/string.js +16 -0
- package/dist/cjs/utils/styles.js +870 -0
- package/dist/cjs/utils/transitions.js +67 -0
- package/dist/cjs/utils/tree.js +28 -0
- package/dist/cjs/utils/warnings.js +55 -0
- package/dist/es/components/Base.js +52 -0
- package/dist/es/components/Block.js +22 -0
- package/dist/es/components/GlobalStyles.js +319 -0
- package/dist/es/components/GridProvider.js +63 -0
- package/dist/es/components/HiddenInput.js +33 -0
- package/dist/es/components/OpenTrasition.js +31 -0
- package/dist/es/components/Root.js +46 -0
- package/dist/es/components/actions/Action.js +130 -0
- package/dist/es/components/actions/Button/Button.js +309 -0
- package/dist/es/components/actions/Button/Submit.js +26 -0
- package/dist/es/components/actions/Button/index.js +11 -0
- package/dist/es/components/actions/ButtonGroup/ButtonGroup.js +25 -0
- package/dist/es/components/actions/index.js +15 -0
- package/dist/es/components/content/ActiveZone/ActiveZone.js +41 -0
- package/dist/es/components/content/Avatar/Avatar.js +36 -0
- package/dist/es/components/content/Badge/Badge.js +52 -0
- package/dist/es/components/content/Card/Card.js +27 -0
- package/dist/es/components/content/Content.js +39 -0
- package/dist/es/components/content/Divider.js +50 -0
- package/dist/es/components/content/Footer.js +33 -0
- package/dist/es/components/content/Header.js +32 -0
- package/dist/es/components/content/Paragraph.js +24 -0
- package/dist/es/components/content/Placeholder/Placeholder.js +48 -0
- package/dist/es/components/content/PrismCode/PrismCode.js +38 -0
- package/dist/es/components/content/Result/Result.js +102 -0
- package/dist/es/components/content/Skeleton/Skeleton.js +75 -0
- package/dist/es/components/content/Tag/Tag.js +88 -0
- package/dist/es/components/content/Text.js +78 -0
- package/dist/es/components/content/Title.js +66 -0
- package/dist/es/components/forms/Checkbox/Checkbox.js +174 -0
- package/dist/es/components/forms/Checkbox/CheckboxGroup.js +107 -0
- package/dist/es/components/forms/Checkbox/context.js +11 -0
- package/dist/es/components/forms/FieldWrapper.js +79 -0
- package/dist/es/components/forms/FileInput/FileInput.js +148 -0
- package/dist/es/components/forms/Form/Field.js +230 -0
- package/dist/es/components/forms/Form/Form.js +121 -0
- package/dist/es/components/forms/Form/index.js +14 -0
- package/dist/es/components/forms/Form/useForm.js +275 -0
- package/dist/es/components/forms/Form/validation.js +141 -0
- package/dist/es/components/forms/Label.js +87 -0
- package/dist/es/components/forms/NumberInput/NumberInput.js +47 -0
- package/dist/es/components/forms/NumberInput/StepButton.js +31 -0
- package/dist/es/components/forms/PasswordInput/PasswordInput.js +40 -0
- package/dist/es/components/forms/RadioGroup/Radio.js +178 -0
- package/dist/es/components/forms/RadioGroup/RadioGroup.js +110 -0
- package/dist/es/components/forms/RadioGroup/context.js +14 -0
- package/dist/es/components/forms/SearchInput/SearchInput.js +42 -0
- package/dist/es/components/forms/Switch/Switch.js +153 -0
- package/dist/es/components/forms/TextArea/TextArea.js +60 -0
- package/dist/es/components/forms/TextInput/TextInput.js +30 -0
- package/dist/es/components/forms/TextInput/TextInputBase.js +164 -0
- package/dist/es/components/forms/index.js +22 -0
- package/dist/es/components/layout/Flex.js +23 -0
- package/dist/es/components/layout/Flow.js +24 -0
- package/dist/es/components/layout/Grid.js +30 -0
- package/dist/es/components/layout/Prefix.js +43 -0
- package/dist/es/components/layout/Space.js +32 -0
- package/dist/es/components/layout/Suffix.js +42 -0
- package/dist/es/components/navigation/LegacyTabs/LegacyTabs.js +251 -0
- package/dist/es/components/navigation/Link/Link.js +15 -0
- package/dist/es/components/organisms/Alert/Alert.js +35 -0
- package/dist/es/components/organisms/CopySnippet/CopySnippet.js +105 -0
- package/dist/es/components/organisms/DirectoryTree/DirectoryTree.js +162 -0
- package/dist/es/components/organisms/FileTabs/FileTabs.js +296 -0
- package/dist/es/components/organisms/Modal/Modal.js +251 -0
- package/dist/es/components/organisms/SearchResults/SearchResults.js +104 -0
- package/dist/es/components/organisms/StatsCard/StatsCard.js +16 -0
- package/dist/es/components/organisms/TopBar/TopBar.js +29 -0
- package/dist/es/components/other/Base64Upload/Base64Upload.js +104 -0
- package/dist/es/components/other/CloudLogo/CloudLogo.js +37 -0
- package/dist/es/components/overlays/AlertDialog/AlertDialog.js +56 -0
- package/dist/es/components/overlays/AlertDialog/AlertDialogApiProvider.js +106 -0
- package/dist/es/components/overlays/AlertDialog/AlertDialogZone.js +54 -0
- package/dist/es/components/overlays/AlertDialog/index.js +12 -0
- package/dist/es/components/overlays/AlertDialog/types.js +10 -0
- package/dist/es/components/overlays/Dialog/Dialog.js +178 -0
- package/dist/es/components/overlays/Dialog/DialogContainer.js +38 -0
- package/dist/es/components/overlays/Dialog/DialogForm.js +53 -0
- package/dist/es/components/overlays/Dialog/DialogTrigger.js +113 -0
- package/dist/es/components/overlays/Dialog/context.js +11 -0
- package/dist/es/components/overlays/Dialog/index.js +13 -0
- package/dist/es/components/overlays/Modal/Modal.js +83 -0
- package/dist/es/components/overlays/Modal/OpenTransition.js +19 -0
- package/dist/es/components/overlays/Modal/Overlay.js +37 -0
- package/dist/es/components/overlays/Modal/Popover.js +56 -0
- package/dist/es/components/overlays/Modal/Tray.js +92 -0
- package/dist/es/components/overlays/Modal/Underlay.js +48 -0
- package/dist/{mjs/components/overlays/Modal/index.d.ts → es/components/overlays/Modal/index.js} +9 -0
- package/dist/es/components/overlays/Notification/Notification.js +37 -0
- package/dist/es/components/overlays/OverlayWrapper.js +31 -0
- package/dist/es/components/overlays/Tooltip/Tooltip.js +97 -0
- package/dist/es/components/overlays/Tooltip/TooltipProvider.js +23 -0
- package/dist/es/components/overlays/Tooltip/TooltipTrigger.js +68 -0
- package/dist/es/components/overlays/Tooltip/context.js +11 -0
- package/dist/es/components/pickers/ComboBox/ComboBox.js +167 -0
- package/dist/es/components/pickers/Select/Select.js +253 -0
- package/dist/es/components/portal/Portal.js +41 -0
- package/dist/es/components/portal/PortalProvider.js +24 -0
- package/dist/es/components/portal/index.js +11 -0
- package/dist/es/components/portal/storybook/templates/basic.js +13 -0
- package/dist/es/components/portal/storybook/templates/index.js +10 -0
- package/dist/es/components/portal/types.js +10 -0
- package/dist/es/components/portal/usePortal.js +41 -0
- package/dist/es/components/status/LoadingAnimation/LoadingAnimation.js +132 -0
- package/dist/es/components/status/Spin/Spin.js +35 -0
- package/dist/es/components/types.js +10 -0
- package/dist/es/data/themes.js +31 -0
- package/dist/es/index.js +96 -0
- package/dist/es/provider.js +46 -0
- package/dist/es/providers/BreakpointsProvider.js +16 -0
- package/dist/es/providers/StylesProvider.js +37 -0
- package/dist/es/services/notification.js +61 -0
- package/dist/es/shared/form.js +10 -0
- package/dist/es/shared/index.js +10 -0
- package/dist/es/stories/FormFieldArgs.js +285 -0
- package/dist/es/stories/components/ConfirmDeletionDialogForm.js +33 -0
- package/dist/es/stories/components/DialogFormApp.js +23 -0
- package/dist/es/stories/components/StyledButton.js +33 -0
- package/dist/es/stories/lists/baseProps.js +39 -0
- package/dist/es/styled/index.js +10 -0
- package/dist/es/styled/styled.js +84 -0
- package/dist/es/styles/align.js +20 -0
- package/dist/es/styles/border.js +48 -0
- package/dist/es/styles/boxShadow.combinator.js +22 -0
- package/dist/es/styles/color.js +39 -0
- package/dist/es/styles/dimension.js +85 -0
- package/dist/es/styles/display.js +13 -0
- package/dist/es/styles/fill.js +38 -0
- package/dist/es/styles/flow.js +20 -0
- package/dist/es/styles/font.js +23 -0
- package/dist/es/styles/fontStyle.js +19 -0
- package/dist/es/styles/gap.js +63 -0
- package/dist/es/styles/groupRadius.js +60 -0
- package/dist/es/styles/height.js +15 -0
- package/dist/es/styles/index.js +99 -0
- package/dist/es/styles/justify.js +20 -0
- package/dist/es/styles/list.js +84 -0
- package/dist/es/styles/margin.js +46 -0
- package/dist/es/styles/marginBlock.js +32 -0
- package/dist/es/styles/marginInline.js +36 -0
- package/dist/es/styles/outline.js +24 -0
- package/dist/es/styles/padding.js +47 -0
- package/dist/es/styles/paddingBlock.js +36 -0
- package/dist/es/styles/paddingInline.js +36 -0
- package/dist/es/styles/predefined.js +120 -0
- package/dist/es/styles/preset.js +51 -0
- package/dist/es/styles/radius.js +72 -0
- package/dist/es/styles/reset.js +100 -0
- package/dist/es/styles/shadow.js +23 -0
- package/dist/es/styles/styledScrollbar.js +51 -0
- package/dist/es/styles/transition.js +84 -0
- package/dist/es/styles/types.js +10 -0
- package/dist/es/styles/width.js +15 -0
- package/dist/es/test/setup.js +12 -0
- package/dist/es/tokens.js +230 -0
- package/dist/es/utils/ResizeSensor.js +320 -0
- package/dist/es/utils/colors.js +15 -0
- package/dist/es/utils/dotize.js +191 -0
- package/dist/es/utils/escape-string.js +18 -0
- package/dist/es/utils/filterBaseProps.js +65 -0
- package/dist/es/utils/index.js +42 -0
- package/dist/es/utils/interactions.js +25 -0
- package/dist/es/utils/mergeStyles.js +32 -0
- package/dist/es/utils/modules.js +12 -0
- package/dist/es/utils/promise.js +14 -0
- package/dist/es/utils/react/Slots.js +42 -0
- package/dist/es/utils/react/chain.js +21 -0
- package/dist/{mjs/utils/react/index.d.ts → es/utils/react/index.js} +9 -0
- package/dist/es/utils/react/isTextOnly.js +13 -0
- package/dist/es/utils/react/mapProps.js +25 -0
- package/dist/es/utils/react/mergeProps.js +60 -0
- package/dist/es/utils/react/modAttrs.js +22 -0
- package/dist/es/utils/react/nullableValue.js +37 -0
- package/dist/es/utils/react/useCombinedRefs.js +26 -0
- package/dist/es/utils/react/useId.js +81 -0
- package/dist/es/utils/react/useLayoutEffect.js +14 -0
- package/dist/es/utils/react/wrapNodeIfPlain.js +18 -0
- package/dist/es/utils/renderStyles.js +127 -0
- package/dist/es/utils/responsive.js +66 -0
- package/dist/es/utils/string.js +12 -0
- package/dist/es/utils/styles.js +844 -0
- package/dist/es/utils/transitions.js +63 -0
- package/dist/es/utils/tree.js +24 -0
- package/dist/es/utils/warnings.js +48 -0
- package/dist/package.json +79 -0
- package/dist/{cjs → types}/components/Base.d.ts +0 -0
- package/dist/{cjs → types}/components/Block.d.ts +0 -0
- package/dist/{cjs → types}/components/GlobalStyles.d.ts +0 -0
- package/dist/{cjs → types}/components/GridProvider.d.ts +0 -0
- package/dist/{cjs → types}/components/HiddenInput.d.ts +0 -0
- package/dist/{cjs → types}/components/OpenTrasition.d.ts +0 -0
- package/dist/{cjs → types}/components/Root.d.ts +0 -0
- package/dist/{cjs → types}/components/actions/Action.d.ts +0 -0
- package/dist/{cjs → types}/components/actions/Button/Button.d.ts +1 -1
- package/dist/{cjs → types}/components/actions/Button/Submit.d.ts +0 -0
- package/dist/types/components/actions/Button/index.d.ts +2 -0
- package/dist/{cjs → types}/components/actions/ButtonGroup/ButtonGroup.d.ts +0 -0
- package/dist/types/components/actions/index.d.ts +10 -0
- package/dist/{cjs → types}/components/content/ActiveZone/ActiveZone.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Avatar/Avatar.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Badge/Badge.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Card/Card.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Content.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Divider.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Footer.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Header.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Paragraph.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Placeholder/Placeholder.d.ts +0 -0
- package/dist/{cjs → types}/components/content/PrismCode/PrismCode.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Result/Result.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Skeleton/Skeleton.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Tag/Tag.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Text.d.ts +0 -0
- package/dist/{cjs → types}/components/content/Title.d.ts +0 -0
- package/dist/{mjs → types}/components/forms/Checkbox/Checkbox.d.ts +1 -1
- package/dist/{mjs → types}/components/forms/Checkbox/CheckboxGroup.d.ts +1 -1
- package/dist/{cjs → types}/components/forms/Checkbox/context.d.ts +0 -0
- package/dist/{cjs → types}/components/forms/FieldWrapper.d.ts +0 -0
- package/dist/{cjs → types}/components/forms/FileInput/FileInput.d.ts +1 -1
- package/dist/{cjs → types}/components/forms/Form/Field.d.ts +0 -0
- package/dist/{cjs → types}/components/forms/Form/Form.d.ts +0 -0
- package/dist/types/components/forms/Form/index.d.ts +14 -0
- package/dist/{cjs → types}/components/forms/Form/useForm.d.ts +0 -0
- package/dist/{cjs → types}/components/forms/Form/validation.d.ts +0 -0
- package/dist/{cjs → types}/components/forms/Label.d.ts +0 -0
- package/dist/{mjs → types}/components/forms/NumberInput/NumberInput.d.ts +1 -1
- package/dist/{cjs → types}/components/forms/NumberInput/StepButton.d.ts +0 -0
- package/dist/{cjs → types}/components/forms/PasswordInput/PasswordInput.d.ts +0 -0
- package/dist/{mjs → types}/components/forms/RadioGroup/Radio.d.ts +1 -1
- package/dist/{mjs → types}/components/forms/RadioGroup/RadioGroup.d.ts +1 -1
- package/dist/{cjs → types}/components/forms/RadioGroup/context.d.ts +0 -0
- package/dist/{cjs → types}/components/forms/SearchInput/SearchInput.d.ts +0 -0
- package/dist/{cjs → types}/components/forms/Switch/Switch.d.ts +1 -1
- package/dist/{cjs → types}/components/forms/TextArea/TextArea.d.ts +0 -0
- package/dist/{cjs → types}/components/forms/TextInput/TextInput.d.ts +0 -0
- package/dist/{cjs → types}/components/forms/TextInput/TextInputBase.d.ts +1 -1
- package/dist/types/components/forms/index.d.ts +35 -0
- package/dist/{cjs → types}/components/layout/Flex.d.ts +0 -0
- package/dist/{cjs → types}/components/layout/Flow.d.ts +0 -0
- package/dist/{cjs → types}/components/layout/Grid.d.ts +0 -0
- package/dist/{cjs → types}/components/layout/Prefix.d.ts +0 -0
- package/dist/{cjs → types}/components/layout/Space.d.ts +0 -0
- package/dist/{cjs → types}/components/layout/Suffix.d.ts +0 -0
- package/dist/{cjs → types}/components/navigation/LegacyTabs/LegacyTabs.d.ts +0 -0
- package/dist/{cjs → types}/components/navigation/Link/Link.d.ts +0 -0
- package/dist/{cjs → types}/components/organisms/Alert/Alert.d.ts +0 -0
- package/dist/{cjs → types}/components/organisms/CopySnippet/CopySnippet.d.ts +0 -0
- package/dist/{cjs → types}/components/organisms/DirectoryTree/DirectoryTree.d.ts +0 -0
- package/dist/{cjs → types}/components/organisms/FileTabs/FileTabs.d.ts +0 -0
- package/dist/{mjs → types}/components/organisms/Modal/Modal.d.ts +2 -0
- package/dist/{cjs → types}/components/organisms/SearchResults/SearchResults.d.ts +0 -0
- package/dist/{cjs → types}/components/organisms/StatsCard/StatsCard.d.ts +0 -0
- package/dist/{cjs → types}/components/organisms/TopBar/TopBar.d.ts +0 -0
- package/dist/{cjs → types}/components/other/Base64Upload/Base64Upload.d.ts +0 -0
- package/dist/{cjs → types}/components/other/CloudLogo/CloudLogo.d.ts +0 -0
- package/dist/{mjs → types}/components/overlays/AlertDialog/AlertDialog.d.ts +3 -2
- package/dist/types/components/overlays/AlertDialog/AlertDialogApiProvider.d.ts +48 -0
- package/dist/types/components/overlays/AlertDialog/AlertDialogZone.d.ts +9 -0
- package/dist/types/components/overlays/AlertDialog/index.d.ts +3 -0
- package/dist/types/components/overlays/AlertDialog/types.d.ts +39 -0
- package/dist/{mjs → types}/components/overlays/Dialog/Dialog.d.ts +1 -1
- package/dist/{mjs → types}/components/overlays/Dialog/DialogContainer.d.ts +9 -4
- package/dist/{cjs → types}/components/overlays/Dialog/DialogForm.d.ts +0 -0
- package/dist/{cjs → types}/components/overlays/Dialog/DialogTrigger.d.ts +0 -0
- package/dist/{cjs → types}/components/overlays/Dialog/context.d.ts +0 -0
- package/dist/types/components/overlays/Dialog/index.d.ts +4 -0
- package/dist/{cjs → types}/components/overlays/Modal/Modal.d.ts +3 -2
- package/dist/{cjs → types}/components/overlays/Modal/OpenTransition.d.ts +0 -0
- package/dist/{cjs → types}/components/overlays/Modal/Overlay.d.ts +3 -2
- package/dist/{mjs → types}/components/overlays/Modal/Popover.d.ts +1 -0
- package/dist/{mjs → types}/components/overlays/Modal/Tray.d.ts +2 -1
- package/dist/{cjs → types}/components/overlays/Modal/Underlay.d.ts +0 -0
- package/dist/{cjs → types}/components/overlays/Modal/index.d.ts +0 -0
- package/dist/{cjs → types}/components/overlays/Notification/Notification.d.ts +0 -0
- package/dist/{mjs → types}/components/overlays/OverlayWrapper.d.ts +2 -2
- package/dist/{cjs → types}/components/overlays/Tooltip/Tooltip.d.ts +1 -1
- package/dist/{cjs → types}/components/overlays/Tooltip/TooltipProvider.d.ts +0 -0
- package/dist/{cjs → types}/components/overlays/Tooltip/TooltipTrigger.d.ts +1 -1
- package/dist/{cjs → types}/components/overlays/Tooltip/context.d.ts +0 -0
- package/dist/{mjs → types}/components/pickers/ComboBox/ComboBox.d.ts +2 -2
- package/dist/{mjs → types}/components/pickers/Select/Select.d.ts +1 -1
- package/dist/types/components/portal/Portal.d.ts +26 -0
- package/dist/types/components/portal/PortalProvider.d.ts +13 -0
- package/dist/types/components/portal/index.d.ts +3 -0
- package/dist/types/components/portal/storybook/templates/basic.d.ts +3 -0
- package/dist/types/components/portal/storybook/templates/index.d.ts +1 -0
- package/dist/types/components/portal/types.d.ts +21 -0
- package/dist/types/components/portal/usePortal.d.ts +10 -0
- package/dist/{cjs → types}/components/status/LoadingAnimation/LoadingAnimation.d.ts +0 -0
- package/dist/{cjs → types}/components/status/Spin/Spin.d.ts +0 -0
- package/dist/{mjs → types}/components/types.d.ts +3 -4
- package/dist/{cjs → types}/data/themes.d.ts +0 -0
- package/dist/{mjs → types}/index.d.ts +7 -56
- package/dist/{mjs → types}/provider.d.ts +1 -2
- package/dist/{cjs → types}/providers/BreakpointsProvider.d.ts +0 -0
- package/dist/{cjs → types}/providers/StylesProvider.d.ts +0 -0
- package/dist/{cjs → types}/services/notification.d.ts +0 -0
- package/dist/{cjs → types}/shared/form.d.ts +0 -0
- package/dist/{cjs → types}/shared/index.d.ts +0 -0
- package/dist/{cjs → types}/stories/FormFieldArgs.d.ts +0 -0
- package/dist/{cjs → types}/stories/components/ConfirmDeletionDialogForm.d.ts +0 -0
- package/dist/{cjs → types}/stories/components/DialogFormApp.d.ts +0 -0
- package/dist/types/stories/components/StyledButton.d.ts +119 -0
- package/dist/{cjs → types}/stories/lists/baseProps.d.ts +0 -0
- package/dist/types/styled/index.d.ts +1 -0
- package/dist/types/styled/styled.d.ts +30 -0
- package/dist/{cjs → types}/styles/align.d.ts +0 -0
- package/dist/{cjs → types}/styles/border.d.ts +0 -0
- package/dist/{cjs → types}/styles/boxShadow.combinator.d.ts +0 -0
- package/dist/{cjs → types}/styles/color.d.ts +0 -0
- package/dist/{cjs → types}/styles/dimension.d.ts +0 -0
- package/dist/{cjs → types}/styles/display.d.ts +0 -0
- package/dist/{cjs → types}/styles/fill.d.ts +0 -0
- package/dist/{cjs → types}/styles/flow.d.ts +0 -0
- package/dist/{cjs → types}/styles/font.d.ts +0 -0
- package/dist/{cjs → types}/styles/fontStyle.d.ts +0 -0
- package/dist/{cjs → types}/styles/gap.d.ts +0 -0
- package/dist/{cjs → types}/styles/groupRadius.d.ts +0 -0
- package/dist/{cjs → types}/styles/height.d.ts +0 -0
- package/dist/{cjs → types}/styles/index.d.ts +0 -0
- package/dist/{cjs → types}/styles/justify.d.ts +0 -0
- package/dist/{cjs → types}/styles/list.d.ts +0 -0
- package/dist/{cjs → types}/styles/margin.d.ts +0 -0
- package/dist/{cjs → types}/styles/marginBlock.d.ts +0 -0
- package/dist/{cjs → types}/styles/marginInline.d.ts +0 -0
- package/dist/{cjs → types}/styles/outline.d.ts +0 -0
- package/dist/{cjs → types}/styles/padding.d.ts +0 -0
- package/dist/{cjs → types}/styles/paddingBlock.d.ts +0 -0
- package/dist/{cjs → types}/styles/paddingInline.d.ts +0 -0
- package/dist/{cjs → types}/styles/predefined.d.ts +0 -0
- package/dist/{cjs → types}/styles/preset.d.ts +0 -0
- package/dist/{cjs → types}/styles/radius.d.ts +0 -0
- package/dist/{cjs → types}/styles/reset.d.ts +0 -0
- package/dist/{cjs → types}/styles/shadow.d.ts +0 -0
- package/dist/{cjs → types}/styles/styledScrollbar.d.ts +0 -0
- package/dist/{cjs → types}/styles/transition.d.ts +0 -0
- package/dist/{cjs → types}/styles/types.d.ts +0 -0
- package/dist/{cjs → types}/styles/width.d.ts +0 -0
- package/dist/types/test/setup.d.ts +3 -0
- package/dist/{cjs → types}/tokens.d.ts +0 -0
- package/dist/{cjs → types}/utils/ResizeSensor.d.ts +0 -0
- package/dist/{cjs → types}/utils/colors.d.ts +0 -0
- package/dist/{cjs → types}/utils/dotize.d.ts +0 -0
- package/dist/{cjs → types}/utils/escape-string.d.ts +0 -0
- package/dist/{cjs → types}/utils/filterBaseProps.d.ts +0 -0
- package/dist/{cjs → types}/utils/index.d.ts +0 -0
- package/dist/{cjs → types}/utils/interactions.d.ts +0 -0
- package/dist/{cjs → types}/utils/mergeStyles.d.ts +0 -0
- package/dist/{cjs → types}/utils/modules.d.ts +0 -0
- package/dist/{cjs → types}/utils/promise.d.ts +0 -0
- package/dist/{cjs → types}/utils/react/Slots.d.ts +0 -0
- package/dist/{cjs → types}/utils/react/chain.d.ts +0 -0
- package/dist/{cjs → types}/utils/react/index.d.ts +0 -0
- package/dist/{cjs → types}/utils/react/isTextOnly.d.ts +0 -0
- package/dist/{cjs → types}/utils/react/mapProps.d.ts +0 -0
- package/dist/{cjs → types}/utils/react/mergeProps.d.ts +0 -0
- package/dist/{cjs → types}/utils/react/modAttrs.d.ts +0 -0
- package/dist/{cjs → types}/utils/react/nullableValue.d.ts +0 -0
- package/dist/{cjs → types}/utils/react/useCombinedRefs.d.ts +0 -0
- package/dist/{cjs → types}/utils/react/useId.d.ts +0 -0
- package/dist/{cjs → types}/utils/react/useLayoutEffect.d.ts +0 -0
- package/dist/{cjs → types}/utils/react/wrapNodeIfPlain.d.ts +0 -0
- package/dist/{cjs → types}/utils/renderStyles.d.ts +0 -0
- package/dist/{cjs → types}/utils/responsive.d.ts +0 -0
- package/dist/{cjs → types}/utils/string.d.ts +0 -0
- package/dist/{cjs → types}/utils/styles.d.ts +0 -0
- package/dist/{cjs → types}/utils/transitions.d.ts +0 -0
- package/dist/{cjs → types}/utils/tree.d.ts +0 -0
- package/dist/types/utils/warnings.d.ts +9 -0
- package/package.json +73 -58
- package/dist/cjs/App.d.ts +0 -3
- package/dist/cjs/components/forms/Checkbox/Checkbox.d.ts +0 -19
- package/dist/cjs/components/forms/Checkbox/CheckboxGroup.d.ts +0 -16
- package/dist/cjs/components/forms/Form/index.d.ts +0 -5
- package/dist/cjs/components/forms/NumberInput/NumberInput.d.ts +0 -15
- package/dist/cjs/components/forms/RadioGroup/Radio.d.ts +0 -27
- package/dist/cjs/components/forms/RadioGroup/RadioGroup.d.ts +0 -17
- package/dist/cjs/components/organisms/Modal/Modal.d.ts +0 -26
- package/dist/cjs/components/overlays/AlertDialog/AlertDialog.d.ts +0 -20
- package/dist/cjs/components/overlays/Dialog/Dialog.d.ts +0 -21
- package/dist/cjs/components/overlays/Dialog/DialogContainer.d.ts +0 -22
- package/dist/cjs/components/overlays/Dialog/api.d.ts +0 -24
- package/dist/cjs/components/overlays/Dialog/index.d.ts +0 -12
- package/dist/cjs/components/overlays/Modal/Popover.d.ts +0 -16
- package/dist/cjs/components/overlays/Modal/Tray.d.ts +0 -13
- package/dist/cjs/components/overlays/OverlayWrapper.d.ts +0 -10
- package/dist/cjs/components/pickers/ComboBox/ComboBox.d.ts +0 -25
- package/dist/cjs/components/pickers/Select/Select.d.ts +0 -48
- package/dist/cjs/components/types.d.ts +0 -82
- package/dist/cjs/index.d.ts +0 -200
- package/dist/cjs/index.js.map +0 -1
- package/dist/cjs/provider.d.ts +0 -24
- package/dist/cjs/stories/components/StyledButton.d.ts +0 -4
- package/dist/cjs/styled.d.ts +0 -11
- package/dist/cjs/utils/warnings.d.ts +0 -3
- package/dist/mjs/App.d.ts +0 -3
- package/dist/mjs/components/Base.d.ts +0 -4
- package/dist/mjs/components/Block.d.ts +0 -8
- package/dist/mjs/components/GlobalStyles.d.ts +0 -1
- package/dist/mjs/components/GridProvider.d.ts +0 -10
- package/dist/mjs/components/HiddenInput.d.ts +0 -1
- package/dist/mjs/components/OpenTrasition.d.ts +0 -14
- package/dist/mjs/components/Root.d.ts +0 -17
- package/dist/mjs/components/actions/Action.d.ts +0 -24
- package/dist/mjs/components/actions/Button/Button.d.ts +0 -19
- package/dist/mjs/components/actions/Button/Submit.d.ts +0 -3
- package/dist/mjs/components/actions/ButtonGroup/ButtonGroup.d.ts +0 -3
- package/dist/mjs/components/content/ActiveZone/ActiveZone.d.ts +0 -9
- package/dist/mjs/components/content/Avatar/Avatar.d.ts +0 -8
- package/dist/mjs/components/content/Badge/Badge.d.ts +0 -7
- package/dist/mjs/components/content/Card/Card.d.ts +0 -5
- package/dist/mjs/components/content/Content.d.ts +0 -5
- package/dist/mjs/components/content/Divider.d.ts +0 -5
- package/dist/mjs/components/content/Footer.d.ts +0 -5
- package/dist/mjs/components/content/Header.d.ts +0 -5
- package/dist/mjs/components/content/Paragraph.d.ts +0 -6
- package/dist/mjs/components/content/Placeholder/Placeholder.d.ts +0 -8
- package/dist/mjs/components/content/PrismCode/PrismCode.d.ts +0 -17
- package/dist/mjs/components/content/Result/Result.d.ts +0 -20
- package/dist/mjs/components/content/Skeleton/Skeleton.d.ts +0 -56
- package/dist/mjs/components/content/Tag/Tag.d.ts +0 -10
- package/dist/mjs/components/content/Text.d.ts +0 -37
- package/dist/mjs/components/content/Title.d.ts +0 -12
- package/dist/mjs/components/forms/Checkbox/context.d.ts +0 -3
- package/dist/mjs/components/forms/FieldWrapper.d.ts +0 -32
- package/dist/mjs/components/forms/FileInput/FileInput.d.ts +0 -27
- package/dist/mjs/components/forms/Form/Field.d.ts +0 -31
- package/dist/mjs/components/forms/Form/Form.d.ts +0 -30
- package/dist/mjs/components/forms/Form/index.d.ts +0 -5
- package/dist/mjs/components/forms/Form/useForm.d.ts +0 -52
- package/dist/mjs/components/forms/Form/validation.d.ts +0 -2
- package/dist/mjs/components/forms/Label.d.ts +0 -18
- package/dist/mjs/components/forms/NumberInput/StepButton.d.ts +0 -5
- package/dist/mjs/components/forms/PasswordInput/PasswordInput.d.ts +0 -12
- package/dist/mjs/components/forms/RadioGroup/context.d.ts +0 -4
- package/dist/mjs/components/forms/SearchInput/SearchInput.d.ts +0 -10
- package/dist/mjs/components/forms/Switch/Switch.d.ts +0 -19
- package/dist/mjs/components/forms/TextArea/TextArea.d.ts +0 -19
- package/dist/mjs/components/forms/TextInput/TextInput.d.ts +0 -12
- package/dist/mjs/components/forms/TextInput/TextInputBase.d.ts +0 -42
- package/dist/mjs/components/layout/Flex.d.ts +0 -5
- package/dist/mjs/components/layout/Flow.d.ts +0 -5
- package/dist/mjs/components/layout/Grid.d.ts +0 -5
- package/dist/mjs/components/layout/Prefix.d.ts +0 -7
- package/dist/mjs/components/layout/Space.d.ts +0 -6
- package/dist/mjs/components/layout/Suffix.d.ts +0 -7
- package/dist/mjs/components/navigation/LegacyTabs/LegacyTabs.d.ts +0 -43
- package/dist/mjs/components/navigation/Link/Link.d.ts +0 -3
- package/dist/mjs/components/organisms/Alert/Alert.d.ts +0 -8
- package/dist/mjs/components/organisms/CopySnippet/CopySnippet.d.ts +0 -26
- package/dist/mjs/components/organisms/DirectoryTree/DirectoryTree.d.ts +0 -44
- package/dist/mjs/components/organisms/FileTabs/FileTabs.d.ts +0 -34
- package/dist/mjs/components/organisms/SearchResults/SearchResults.d.ts +0 -31
- package/dist/mjs/components/organisms/StatsCard/StatsCard.d.ts +0 -8
- package/dist/mjs/components/organisms/TopBar/TopBar.d.ts +0 -6
- package/dist/mjs/components/other/Base64Upload/Base64Upload.d.ts +0 -5
- package/dist/mjs/components/other/CloudLogo/CloudLogo.d.ts +0 -4
- package/dist/mjs/components/overlays/Dialog/DialogForm.d.ts +0 -27
- package/dist/mjs/components/overlays/Dialog/DialogTrigger.d.ts +0 -36
- package/dist/mjs/components/overlays/Dialog/api.d.ts +0 -24
- package/dist/mjs/components/overlays/Dialog/context.d.ts +0 -7
- package/dist/mjs/components/overlays/Dialog/index.d.ts +0 -12
- package/dist/mjs/components/overlays/Modal/Modal.d.ts +0 -13
- package/dist/mjs/components/overlays/Modal/OpenTransition.d.ts +0 -2
- package/dist/mjs/components/overlays/Modal/Overlay.d.ts +0 -6
- package/dist/mjs/components/overlays/Modal/Underlay.d.ts +0 -9
- package/dist/mjs/components/overlays/Notification/Notification.d.ts +0 -7
- package/dist/mjs/components/overlays/Tooltip/Tooltip.d.ts +0 -16
- package/dist/mjs/components/overlays/Tooltip/TooltipProvider.d.ts +0 -13
- package/dist/mjs/components/overlays/Tooltip/TooltipTrigger.d.ts +0 -20
- package/dist/mjs/components/overlays/Tooltip/context.d.ts +0 -16
- package/dist/mjs/components/status/LoadingAnimation/LoadingAnimation.d.ts +0 -6
- package/dist/mjs/components/status/Spin/Spin.d.ts +0 -8
- package/dist/mjs/data/themes.d.ts +0 -23
- package/dist/mjs/index.js +0 -46
- package/dist/mjs/index.js.map +0 -1
- package/dist/mjs/providers/BreakpointsProvider.d.ts +0 -8
- package/dist/mjs/providers/StylesProvider.d.ts +0 -10
- package/dist/mjs/services/notification.d.ts +0 -25
- package/dist/mjs/shared/form.d.ts +0 -70
- package/dist/mjs/shared/index.d.ts +0 -3
- package/dist/mjs/stories/FormFieldArgs.d.ts +0 -325
- package/dist/mjs/stories/components/ConfirmDeletionDialogForm.d.ts +0 -7
- package/dist/mjs/stories/components/DialogFormApp.d.ts +0 -2
- package/dist/mjs/stories/components/StyledButton.d.ts +0 -4
- package/dist/mjs/stories/lists/baseProps.d.ts +0 -1
- package/dist/mjs/styled.d.ts +0 -11
- package/dist/mjs/styles/align.d.ts +0 -9
- package/dist/mjs/styles/border.d.ts +0 -11
- package/dist/mjs/styles/boxShadow.combinator.d.ts +0 -6
- package/dist/mjs/styles/color.d.ts +0 -6
- package/dist/mjs/styles/dimension.d.ts +0 -4
- package/dist/mjs/styles/display.d.ts +0 -9
- package/dist/mjs/styles/fill.d.ts +0 -6
- package/dist/mjs/styles/flow.d.ts +0 -9
- package/dist/mjs/styles/font.d.ts +0 -9
- package/dist/mjs/styles/fontStyle.d.ts +0 -8
- package/dist/mjs/styles/gap.d.ts +0 -21
- package/dist/mjs/styles/groupRadius.d.ts +0 -11
- package/dist/mjs/styles/height.d.ts +0 -9
- package/dist/mjs/styles/index.d.ts +0 -8
- package/dist/mjs/styles/justify.d.ts +0 -9
- package/dist/mjs/styles/list.d.ts +0 -9
- package/dist/mjs/styles/margin.d.ts +0 -12
- package/dist/mjs/styles/marginBlock.d.ts +0 -8
- package/dist/mjs/styles/marginInline.d.ts +0 -8
- package/dist/mjs/styles/outline.d.ts +0 -8
- package/dist/mjs/styles/padding.d.ts +0 -12
- package/dist/mjs/styles/paddingBlock.d.ts +0 -8
- package/dist/mjs/styles/paddingInline.d.ts +0 -8
- package/dist/mjs/styles/predefined.d.ts +0 -1
- package/dist/mjs/styles/preset.d.ts +0 -13
- package/dist/mjs/styles/radius.d.ts +0 -16
- package/dist/mjs/styles/reset.d.ts +0 -6
- package/dist/mjs/styles/shadow.d.ts +0 -8
- package/dist/mjs/styles/styledScrollbar.d.ts +0 -54
- package/dist/mjs/styles/transition.d.ts +0 -9
- package/dist/mjs/styles/types.d.ts +0 -111
- package/dist/mjs/styles/width.d.ts +0 -9
- package/dist/mjs/tokens.d.ts +0 -159
- package/dist/mjs/utils/ResizeSensor.d.ts +0 -9
- package/dist/mjs/utils/colors.d.ts +0 -1
- package/dist/mjs/utils/dotize.d.ts +0 -21
- package/dist/mjs/utils/escape-string.d.ts +0 -1
- package/dist/mjs/utils/filterBaseProps.d.ts +0 -12
- package/dist/mjs/utils/index.d.ts +0 -1
- package/dist/mjs/utils/interactions.d.ts +0 -6
- package/dist/mjs/utils/mergeStyles.d.ts +0 -2
- package/dist/mjs/utils/modules.d.ts +0 -1
- package/dist/mjs/utils/promise.d.ts +0 -1
- package/dist/mjs/utils/react/Slots.d.ts +0 -4
- package/dist/mjs/utils/react/chain.d.ts +0 -4
- package/dist/mjs/utils/react/isTextOnly.d.ts +0 -1
- package/dist/mjs/utils/react/mapProps.d.ts +0 -6
- package/dist/mjs/utils/react/mergeProps.d.ts +0 -9
- package/dist/mjs/utils/react/modAttrs.d.ts +0 -6
- package/dist/mjs/utils/react/nullableValue.d.ts +0 -19
- package/dist/mjs/utils/react/useCombinedRefs.d.ts +0 -2
- package/dist/mjs/utils/react/useId.d.ts +0 -15
- package/dist/mjs/utils/react/useLayoutEffect.d.ts +0 -2
- package/dist/mjs/utils/react/wrapNodeIfPlain.d.ts +0 -2
- package/dist/mjs/utils/renderStyles.d.ts +0 -10
- package/dist/mjs/utils/responsive.d.ts +0 -9
- package/dist/mjs/utils/string.d.ts +0 -1
- package/dist/mjs/utils/styles.d.ts +0 -198
- package/dist/mjs/utils/transitions.d.ts +0 -8
- package/dist/mjs/utils/tree.d.ts +0 -1
- package/dist/mjs/utils/warnings.d.ts +0 -3
@@ -0,0 +1,42 @@
|
|
1
|
+
/**
|
2
|
+
* @license MIT
|
3
|
+
* author: Cube Dev Team
|
4
|
+
* @cube-dev/ui-kit v0.9.0
|
5
|
+
* Released under the MIT license.
|
6
|
+
*/
|
7
|
+
|
8
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
9
|
+
import { forwardRef, useEffect, useRef } from 'react';
|
10
|
+
import { CloseOutlined, SearchOutlined } from '@ant-design/icons';
|
11
|
+
import { useSearchFieldState } from '@react-stately/searchfield';
|
12
|
+
import { useSearchField } from '@react-aria/searchfield';
|
13
|
+
import { useCombinedRefs } from '../../../utils/react';
|
14
|
+
import { TextInputBase, } from '../TextInput/TextInputBase';
|
15
|
+
import { useProviderProps } from '../../../provider';
|
16
|
+
import { Button } from '../../actions/Button/Button';
|
17
|
+
import { ariaToCubeButtonProps } from '../../../utils/react/mapProps';
|
18
|
+
import { castNullableStringValue, } from '../../../utils/react/nullableValue';
|
19
|
+
export const SearchInput = forwardRef((props, ref) => {
|
20
|
+
props = castNullableStringValue(props);
|
21
|
+
props = useProviderProps(props);
|
22
|
+
let { isClearable, value } = props;
|
23
|
+
const localRef = useRef(null);
|
24
|
+
const combinedRef = useCombinedRefs(ref, localRef);
|
25
|
+
let inputRef = useRef(null);
|
26
|
+
useEffect(() => {
|
27
|
+
const el = combinedRef && combinedRef.current;
|
28
|
+
if (el && value != null && el.value !== value) {
|
29
|
+
el.value = value;
|
30
|
+
}
|
31
|
+
}, [combinedRef, value]);
|
32
|
+
let state = useSearchFieldState(props);
|
33
|
+
let { inputProps, clearButtonProps } = useSearchField(props, state, inputRef);
|
34
|
+
return (_jsx(TextInputBase, { inputProps: inputProps, ref: ref, inputRef: inputRef, inputStyles: { paddingRight: '4x' }, type: "search", prefix: _jsx(SearchOutlined, {}, void 0), suffixPosition: "after", suffix: isClearable
|
35
|
+
&& state.value !== ''
|
36
|
+
&& !props.isReadOnly && (_jsx(Button, { type: "clear", ...ariaToCubeButtonProps(clearButtonProps), color: {
|
37
|
+
'': '#dark.50',
|
38
|
+
'hovered | pressed': '#purple-text',
|
39
|
+
}, radius: "right (1r - 1bw)", padding: ".5x 1x", placeSelf: "stretch", icon: _jsx(CloseOutlined, {}, void 0) }, void 0)), ...props }, void 0));
|
40
|
+
});
|
41
|
+
|
42
|
+
|
@@ -0,0 +1,153 @@
|
|
1
|
+
/**
|
2
|
+
* @license MIT
|
3
|
+
* author: Cube Dev Team
|
4
|
+
* @cube-dev/ui-kit v0.9.0
|
5
|
+
* Released under the MIT license.
|
6
|
+
*/
|
7
|
+
|
8
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
9
|
+
import { useFocusableRef } from '@react-spectrum/utils';
|
10
|
+
import { forwardRef, useRef } from 'react';
|
11
|
+
import { useSwitch } from '@react-aria/switch';
|
12
|
+
import { useHover } from '@react-aria/interactions';
|
13
|
+
import { useToggleState } from '@react-stately/toggle';
|
14
|
+
import { useProviderProps } from '../../../provider';
|
15
|
+
import { BLOCK_STYLES, OUTER_STYLES } from '../../../styles/list';
|
16
|
+
import { extractStyles } from '../../../utils/styles';
|
17
|
+
import { Base } from '../../Base';
|
18
|
+
import { useFocus } from '../../../utils/interactions';
|
19
|
+
import { mergeProps } from '../../../utils/react';
|
20
|
+
import { filterBaseProps } from '../../../utils/filterBaseProps';
|
21
|
+
import { useContextStyles } from '../../../providers/StylesProvider';
|
22
|
+
import { HiddenInput } from '../../HiddenInput';
|
23
|
+
import { INLINE_LABEL_STYLES, LABEL_STYLES } from '../Label';
|
24
|
+
import { LoadingOutlined } from '@ant-design/icons';
|
25
|
+
import { useFormProps } from '../Form/Form';
|
26
|
+
import { FieldWrapper } from '../FieldWrapper';
|
27
|
+
import { castNullableIsSelected, } from '../../../utils/react/nullableValue';
|
28
|
+
const STYLES = {
|
29
|
+
position: 'relative',
|
30
|
+
display: 'flex',
|
31
|
+
placeItems: 'center start',
|
32
|
+
gap: '1x',
|
33
|
+
flow: 'row',
|
34
|
+
preset: 'input',
|
35
|
+
width: 'min-content',
|
36
|
+
cursor: 'pointer',
|
37
|
+
};
|
38
|
+
const INPUT_STYLES = {
|
39
|
+
position: 'relative',
|
40
|
+
display: 'grid',
|
41
|
+
placeItems: 'center',
|
42
|
+
radius: 'round',
|
43
|
+
fill: {
|
44
|
+
'': '#dark.50',
|
45
|
+
checked: '#purple',
|
46
|
+
disabled: '#dark.12',
|
47
|
+
},
|
48
|
+
color: '#white',
|
49
|
+
border: false,
|
50
|
+
width: '5.25x 5.25x',
|
51
|
+
height: '3x 3x',
|
52
|
+
outline: {
|
53
|
+
'': '#purple-03.0',
|
54
|
+
focused: '#purple-03',
|
55
|
+
},
|
56
|
+
transition: 'theme',
|
57
|
+
cursor: 'pointer',
|
58
|
+
};
|
59
|
+
const THUMB_STYLES = {
|
60
|
+
position: 'absolute',
|
61
|
+
width: '2.5x',
|
62
|
+
height: '2.5x',
|
63
|
+
radius: 'round',
|
64
|
+
fill: 'currentColor',
|
65
|
+
shadow: '0px 2px 4px #dark.20;',
|
66
|
+
top: '.25x',
|
67
|
+
left: {
|
68
|
+
'': '.25x',
|
69
|
+
checked: '2.5x',
|
70
|
+
},
|
71
|
+
transition: 'left',
|
72
|
+
cursor: 'pointer',
|
73
|
+
};
|
74
|
+
function Switch(props, ref) {
|
75
|
+
props = castNullableIsSelected(props);
|
76
|
+
props = useProviderProps(props);
|
77
|
+
props = useFormProps(props);
|
78
|
+
let { qa, isDisabled = false, autoFocus, children, label, labelProps, labelStyles, thumbStyles, isLoading, insideForm, validationState, message, description, labelPosition, inputStyles, requiredMark = true, tooltip, ...otherProps } = props;
|
79
|
+
label = label || children;
|
80
|
+
let wrapperContextStyles = useContextStyles('Switch_Wrapper', props);
|
81
|
+
let inputContextStyles = useContextStyles('Switch', props);
|
82
|
+
let labelContextStyles = useContextStyles('Switch_Label', props);
|
83
|
+
let thumbContextStyles = useContextStyles('Switch_Thumb', props);
|
84
|
+
let styles = extractStyles(props, OUTER_STYLES, {
|
85
|
+
...(insideForm ? {} : STYLES),
|
86
|
+
...wrapperContextStyles,
|
87
|
+
});
|
88
|
+
inputStyles = extractStyles(props, BLOCK_STYLES, {
|
89
|
+
...INPUT_STYLES,
|
90
|
+
...inputContextStyles,
|
91
|
+
...(insideForm && labelPosition === 'side'
|
92
|
+
? {
|
93
|
+
marginTop: '-3px',
|
94
|
+
placeSelf: 'start',
|
95
|
+
}
|
96
|
+
: null),
|
97
|
+
...inputStyles,
|
98
|
+
});
|
99
|
+
thumbStyles = {
|
100
|
+
...THUMB_STYLES,
|
101
|
+
...thumbContextStyles,
|
102
|
+
...thumbStyles,
|
103
|
+
};
|
104
|
+
labelStyles = {
|
105
|
+
...(insideForm ? LABEL_STYLES : INLINE_LABEL_STYLES),
|
106
|
+
...labelContextStyles,
|
107
|
+
...labelStyles,
|
108
|
+
};
|
109
|
+
let { isFocused, focusProps } = useFocus({ isDisabled }, true);
|
110
|
+
let { hoverProps, isHovered } = useHover({ isDisabled });
|
111
|
+
let inputRef = useRef(null);
|
112
|
+
let domRef = useFocusableRef(ref, inputRef);
|
113
|
+
// eslint-disable-next-line react-hooks/rules-of-hooks
|
114
|
+
let { inputProps } = useSwitch(props, useToggleState(props), inputRef);
|
115
|
+
const switchField = (_jsxs(Base, { qa: `${qa || 'Switch'}Wrapper`, styles: { position: 'relative' }, children: [_jsx(HiddenInput, { "data-qa": qa || 'Switch', ...mergeProps(inputProps, focusProps), ref: inputRef }, void 0), _jsx(Base, { mods: {
|
116
|
+
checked: inputProps.checked,
|
117
|
+
disabled: isDisabled,
|
118
|
+
hovered: isHovered,
|
119
|
+
focused: isFocused,
|
120
|
+
}, styles: inputStyles, children: _jsx(Base, { qa: "SwitchThumb", styles: thumbStyles, "aria-hidden": "true", mods: {
|
121
|
+
checked: inputProps.checked,
|
122
|
+
} }, void 0) }, void 0)] }, void 0));
|
123
|
+
if (insideForm) {
|
124
|
+
return (_jsx(FieldWrapper, { ...{
|
125
|
+
as: 'label',
|
126
|
+
labelPosition,
|
127
|
+
label,
|
128
|
+
styles,
|
129
|
+
labelStyles,
|
130
|
+
labelProps,
|
131
|
+
isDisabled,
|
132
|
+
validationState,
|
133
|
+
message,
|
134
|
+
description,
|
135
|
+
requiredMark,
|
136
|
+
tooltip,
|
137
|
+
Component: switchField,
|
138
|
+
ref: domRef,
|
139
|
+
} }, void 0));
|
140
|
+
}
|
141
|
+
return (_jsxs(Base, { as: "label", styles: styles, ...hoverProps, ...filterBaseProps(otherProps), ref: domRef, children: [switchField, label && (_jsxs(Base, { styles: labelStyles, mods: {
|
142
|
+
disabled: isDisabled,
|
143
|
+
}, ...filterBaseProps(labelProps), children: [label, isLoading ? (_jsxs(_Fragment, { children: [label ? _jsx(_Fragment, { children: "\u00A0" }, void 0) : null, _jsx(LoadingOutlined, {}, void 0)] }, void 0)) : null] }, void 0))] }, void 0));
|
144
|
+
}
|
145
|
+
/**
|
146
|
+
* Switches allow users to turn an individual option on or off.
|
147
|
+
* They are usually used to activate or deactivate a specific setting.
|
148
|
+
*/
|
149
|
+
let _Switch = forwardRef(Switch);
|
150
|
+
_Switch.cubeInputType = 'Checkbox';
|
151
|
+
export { _Switch as Switch };
|
152
|
+
|
153
|
+
|
@@ -0,0 +1,60 @@
|
|
1
|
+
/**
|
2
|
+
* @license MIT
|
3
|
+
* author: Cube Dev Team
|
4
|
+
* @cube-dev/ui-kit v0.9.0
|
5
|
+
* Released under the MIT license.
|
6
|
+
*/
|
7
|
+
|
8
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
9
|
+
import { forwardRef, useCallback, useLayoutEffect, useRef } from 'react';
|
10
|
+
import { TextInputBase, } from '../TextInput/TextInputBase';
|
11
|
+
import { useControlledState } from '@react-stately/utils';
|
12
|
+
import { useProviderProps } from '../../../provider';
|
13
|
+
import { useTextField } from '@react-aria/textfield';
|
14
|
+
import { chain } from '@react-aria/utils';
|
15
|
+
import { castNullableStringValue, } from '../../../utils/react/nullableValue';
|
16
|
+
function TextArea(props, ref) {
|
17
|
+
props = castNullableStringValue(props);
|
18
|
+
props = useProviderProps(props);
|
19
|
+
let { autoSize = false, isDisabled = false, isReadOnly = false, isRequired = false, onChange, rows, ...otherProps } = props;
|
20
|
+
rows = rows || 3;
|
21
|
+
let [inputValue, setInputValue] = useControlledState(props.value, props.defaultValue, () => { });
|
22
|
+
let inputRef = useRef(null);
|
23
|
+
let onHeightChange = useCallback(() => {
|
24
|
+
if (autoSize && inputRef.current) {
|
25
|
+
let input = inputRef.current;
|
26
|
+
let prevAlignment = input.style.alignSelf;
|
27
|
+
let computedStyle = getComputedStyle(input);
|
28
|
+
input.style.alignSelf = 'start';
|
29
|
+
input.style.height = 'auto';
|
30
|
+
input.style.height = input.scrollHeight
|
31
|
+
? `calc(${input.scrollHeight}px + (2 * var(--border-width)))`
|
32
|
+
: `${parseFloat(computedStyle.paddingTop)
|
33
|
+
+ parseFloat(computedStyle.paddingBottom)
|
34
|
+
+ parseFloat(computedStyle.lineHeight) * (rows || 3)
|
35
|
+
+ 2}px`;
|
36
|
+
input.style.alignSelf = prevAlignment;
|
37
|
+
}
|
38
|
+
}, [inputRef]);
|
39
|
+
useLayoutEffect(() => {
|
40
|
+
if (inputRef.current) {
|
41
|
+
onHeightChange();
|
42
|
+
}
|
43
|
+
}, [onHeightChange, inputValue, inputRef]);
|
44
|
+
let { labelProps, inputProps } = useTextField({
|
45
|
+
...props,
|
46
|
+
onChange: chain(onChange, setInputValue),
|
47
|
+
inputElementType: 'textarea',
|
48
|
+
}, inputRef);
|
49
|
+
return (_jsx(TextInputBase, { ...otherProps, ref: ref, inputRef: inputRef, labelProps: labelProps, inputProps: inputProps, multiLine: true, isDisabled: isDisabled, isReadOnly: isReadOnly, isRequired: isRequired, rows: rows }, void 0));
|
50
|
+
}
|
51
|
+
/**
|
52
|
+
* TextInputs are text inputs that allow users to input custom text entries
|
53
|
+
* with a keyboard. Various decorations can be displayed around the field to
|
54
|
+
* communicate the entry requirements.
|
55
|
+
*/
|
56
|
+
const _TextArea = forwardRef(TextArea);
|
57
|
+
_TextArea.cubeInputType = 'Text';
|
58
|
+
export { _TextArea as TextArea };
|
59
|
+
|
60
|
+
|
@@ -0,0 +1,30 @@
|
|
1
|
+
/**
|
2
|
+
* @license MIT
|
3
|
+
* author: Cube Dev Team
|
4
|
+
* @cube-dev/ui-kit v0.9.0
|
5
|
+
* Released under the MIT license.
|
6
|
+
*/
|
7
|
+
|
8
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
9
|
+
import { forwardRef, useRef } from 'react';
|
10
|
+
import { TextInputBase } from './TextInputBase';
|
11
|
+
import { useProviderProps } from '../../../provider';
|
12
|
+
import { useTextField } from '@react-aria/textfield';
|
13
|
+
import { castNullableStringValue, } from '../../../utils/react/nullableValue';
|
14
|
+
function TextInput(props, ref) {
|
15
|
+
castNullableStringValue(props);
|
16
|
+
props = useProviderProps(props);
|
17
|
+
let inputRef = useRef(null);
|
18
|
+
let { labelProps, inputProps } = useTextField(props, inputRef);
|
19
|
+
return (_jsx(TextInputBase, { ...props, labelProps: labelProps, inputProps: inputProps, ref: ref, inputRef: inputRef }, void 0));
|
20
|
+
}
|
21
|
+
/**
|
22
|
+
* TextInputs are text inputs that allow users to input custom text entries
|
23
|
+
* with a keyboard. Various decorations can be displayed around the field to
|
24
|
+
* communicate the entry requirements.
|
25
|
+
*/
|
26
|
+
const _TextInput = forwardRef(TextInput);
|
27
|
+
_TextInput.cubeInputType = 'Text';
|
28
|
+
export { _TextInput as TextInput };
|
29
|
+
|
30
|
+
|
@@ -0,0 +1,164 @@
|
|
1
|
+
/**
|
2
|
+
* @license MIT
|
3
|
+
* author: Cube Dev Team
|
4
|
+
* @cube-dev/ui-kit v0.9.0
|
5
|
+
* Released under the MIT license.
|
6
|
+
*/
|
7
|
+
|
8
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
9
|
+
import { WarningOutlined, CheckOutlined, LoadingOutlined, } from '@ant-design/icons';
|
10
|
+
import { createFocusableRef } from '@react-spectrum/utils';
|
11
|
+
import { cloneElement, forwardRef, useImperativeHandle, useRef, useState, } from 'react';
|
12
|
+
import { useFormProps } from '../Form/Form';
|
13
|
+
import { useHover } from '@react-aria/interactions';
|
14
|
+
import { useProviderProps } from '../../../provider';
|
15
|
+
import { Base } from '../../Base';
|
16
|
+
import { extractStyles } from '../../../utils/styles';
|
17
|
+
import { BLOCK_STYLES, POSITION_STYLES, DIMENSION_STYLES, } from '../../../styles/list';
|
18
|
+
import { useFocus } from '../../../utils/interactions';
|
19
|
+
import { Prefix } from '../../layout/Prefix';
|
20
|
+
import { Suffix } from '../../layout/Suffix';
|
21
|
+
import { useContextStyles } from '../../../providers/StylesProvider';
|
22
|
+
import { FieldWrapper } from '../FieldWrapper';
|
23
|
+
import { Space } from '../../layout/Space';
|
24
|
+
import { Block } from '../../Block';
|
25
|
+
import { mergeProps } from '../../../utils/react';
|
26
|
+
const WRAPPER_STYLES = {
|
27
|
+
display: 'grid',
|
28
|
+
position: 'relative',
|
29
|
+
};
|
30
|
+
const STYLE_LIST = [...POSITION_STYLES, ...DIMENSION_STYLES];
|
31
|
+
const INPUT_STYLE_PROPS_LIST = [...BLOCK_STYLES, 'resize'];
|
32
|
+
export const DEFAULT_INPUT_STYLES = {
|
33
|
+
display: 'block',
|
34
|
+
width: 'initial 100% initial',
|
35
|
+
height: 'initial initial initial',
|
36
|
+
color: {
|
37
|
+
'': '#dark.85',
|
38
|
+
invalid: '#danger-text',
|
39
|
+
focused: '#dark.85',
|
40
|
+
disabled: '#dark.30',
|
41
|
+
},
|
42
|
+
fill: {
|
43
|
+
'': '#white',
|
44
|
+
disabled: '#dark.04',
|
45
|
+
},
|
46
|
+
border: {
|
47
|
+
'': true,
|
48
|
+
focused: true,
|
49
|
+
valid: '#success-text.50',
|
50
|
+
invalid: '#danger-text.50',
|
51
|
+
disabled: true,
|
52
|
+
},
|
53
|
+
outline: {
|
54
|
+
'': '#purple-03.0',
|
55
|
+
focused: '#purple-03',
|
56
|
+
'invalid & focused': '#danger.50',
|
57
|
+
'valid & focused': '#success.50',
|
58
|
+
},
|
59
|
+
transition: 'theme',
|
60
|
+
radius: true,
|
61
|
+
padding: {
|
62
|
+
'': '(1.25x - 1bw) 1x (1.25x - 1bw) (1.5x - 1bw)',
|
63
|
+
'[data-size="small"]': '(.75x - 1px) (1.5x - 1px)',
|
64
|
+
},
|
65
|
+
fontWeight: 400,
|
66
|
+
textAlign: 'left',
|
67
|
+
reset: 'input',
|
68
|
+
preset: 'default',
|
69
|
+
flexGrow: 1,
|
70
|
+
margin: 0,
|
71
|
+
resize: 'none',
|
72
|
+
};
|
73
|
+
function TextInputBase(props, ref) {
|
74
|
+
props = useProviderProps(props);
|
75
|
+
props = useFormProps(props);
|
76
|
+
let { qa, label, labelPosition = 'top', labelStyles, isRequired, necessityIndicator, necessityLabel, validationState, message, description, prefix, isDisabled, multiLine, autoFocus, labelProps, inputProps, wrapperProps, inputRef, isLoading, loadingIndicator, value, inputStyles = {}, wrapperStyles = {}, suffix, suffixPosition = 'before', wrapperRef, requiredMark = true, tooltip, isHidden, rows = 1, size, ...otherProps } = props;
|
77
|
+
let [suffixWidth, setSuffixWidth] = useState(0);
|
78
|
+
let [prefixWidth, setPrefixWidth] = useState(0);
|
79
|
+
let styles = extractStyles(otherProps, STYLE_LIST);
|
80
|
+
let type = otherProps.type;
|
81
|
+
let contextStyles = useContextStyles('Input', otherProps);
|
82
|
+
inputStyles = extractStyles(otherProps, INPUT_STYLE_PROPS_LIST, {
|
83
|
+
...DEFAULT_INPUT_STYLES,
|
84
|
+
...contextStyles,
|
85
|
+
...inputStyles,
|
86
|
+
});
|
87
|
+
wrapperStyles = {
|
88
|
+
...WRAPPER_STYLES,
|
89
|
+
...wrapperStyles,
|
90
|
+
};
|
91
|
+
if (prefix) {
|
92
|
+
inputStyles.paddingLeft = `${prefixWidth}px`;
|
93
|
+
}
|
94
|
+
if (validationState || isLoading || suffix) {
|
95
|
+
inputStyles.paddingRight = `${suffixWidth}px`;
|
96
|
+
}
|
97
|
+
let ElementType = multiLine ? 'textarea' : 'input';
|
98
|
+
let { isFocused, focusProps } = useFocus({ isDisabled });
|
99
|
+
let { hoverProps, isHovered } = useHover({ isDisabled });
|
100
|
+
let domRef = useRef(null);
|
101
|
+
let defaultInputRef = useRef(null);
|
102
|
+
inputRef = inputRef || defaultInputRef;
|
103
|
+
// Expose imperative interface for ref
|
104
|
+
useImperativeHandle(ref, () => ({
|
105
|
+
...createFocusableRef(domRef, inputRef),
|
106
|
+
select() {
|
107
|
+
if (inputRef?.current) {
|
108
|
+
inputRef.current.select();
|
109
|
+
}
|
110
|
+
},
|
111
|
+
getInputElement() {
|
112
|
+
return inputRef?.current;
|
113
|
+
},
|
114
|
+
}));
|
115
|
+
let isInvalid = validationState === 'invalid';
|
116
|
+
let validationIcon = isInvalid ? (_jsx(WarningOutlined, { style: { color: 'var(--danger-color)' } }, void 0)) : (_jsx(CheckOutlined, { style: { color: 'var(--success-color)' } }, void 0));
|
117
|
+
let validation = cloneElement(validationIcon);
|
118
|
+
suffix =
|
119
|
+
typeof suffix === 'string' ? (_jsx(Block, { padding: "1x right", children: suffix }, void 0)) : (suffix);
|
120
|
+
// Fix safari bug: https://github.com/philipwalton/flexbugs/issues/270
|
121
|
+
if (!inputProps?.placeholder) {
|
122
|
+
if (!inputProps) {
|
123
|
+
inputProps = {};
|
124
|
+
}
|
125
|
+
inputProps.placeholder = ' ';
|
126
|
+
}
|
127
|
+
let textField = (_jsxs(Base, { ref: wrapperRef, qa: `${qa || 'TextInput'}Wrapper`, mods: {
|
128
|
+
invalid: isInvalid,
|
129
|
+
valid: validationState === 'valid',
|
130
|
+
loadable: !!loadingIndicator,
|
131
|
+
multiline: multiLine,
|
132
|
+
}, "data-size": size, styles: wrapperStyles, ...wrapperProps, children: [_jsx(Base, { qa: qa || 'TextInput', as: ElementType, ...mergeProps(inputProps, focusProps, hoverProps), ref: inputRef, rows: multiLine ? rows : undefined, mods: {
|
133
|
+
invalid: isInvalid,
|
134
|
+
valid: validationState === 'valid',
|
135
|
+
disabled: isDisabled,
|
136
|
+
hovered: isHovered,
|
137
|
+
focused: isFocused,
|
138
|
+
}, style: {
|
139
|
+
WebkitTextSecurity: multiLine && type === 'password' ? 'disc' : 'initial',
|
140
|
+
}, autoFocus: autoFocus, "data-size": size, styles: inputStyles }, void 0), _jsx(Prefix, { padding: "0 1x 0 1.5x", onWidthChange: setPrefixWidth, opacity: isDisabled ? '@disabled-opacity' : false, placeItems: "center", children: typeof prefix === 'string' ? (_jsx(Block, { padding: "1x left", children: prefix }, void 0)) : (prefix) }, void 0), _jsxs(Suffix, { padding: ".5x left", onWidthChange: setSuffixWidth, opacity: isDisabled ? '@disabled-opacity' : false, children: [suffixPosition === 'before' ? suffix : null, (validationState && !isLoading) || isLoading ? (_jsxs(Space, { gap: false, padding: `0 ${suffix ? '1x' : '1.5x'} 0 0`, children: [validationState && !isLoading ? validation : null, isLoading && _jsx(LoadingOutlined, {}, void 0)] }, void 0)) : null, suffixPosition === 'after' ? suffix : null] }, void 0)] }, void 0));
|
141
|
+
return (_jsx(FieldWrapper, { ...{
|
142
|
+
labelPosition,
|
143
|
+
label,
|
144
|
+
styles,
|
145
|
+
isRequired,
|
146
|
+
labelStyles,
|
147
|
+
necessityIndicator,
|
148
|
+
necessityLabel,
|
149
|
+
labelProps,
|
150
|
+
isDisabled,
|
151
|
+
validationState,
|
152
|
+
message,
|
153
|
+
description,
|
154
|
+
requiredMark,
|
155
|
+
tooltip,
|
156
|
+
isHidden,
|
157
|
+
Component: textField,
|
158
|
+
ref: domRef,
|
159
|
+
} }, void 0));
|
160
|
+
}
|
161
|
+
const _TextInputBase = forwardRef(TextInputBase);
|
162
|
+
export { _TextInputBase as TextInputBase };
|
163
|
+
|
164
|
+
|
@@ -0,0 +1,22 @@
|
|
1
|
+
/**
|
2
|
+
* @license MIT
|
3
|
+
* author: Cube Dev Team
|
4
|
+
* @cube-dev/ui-kit v0.9.0
|
5
|
+
* Released under the MIT license.
|
6
|
+
*/
|
7
|
+
|
8
|
+
import { TextInput } from './TextInput/TextInput';
|
9
|
+
import { PasswordInput } from './PasswordInput/PasswordInput';
|
10
|
+
import { NumberInput } from './NumberInput/NumberInput';
|
11
|
+
import { FileInput } from './FileInput/FileInput';
|
12
|
+
import { TextArea } from './TextArea/TextArea';
|
13
|
+
const Input = Object.assign(TextInput, {
|
14
|
+
Text: TextInput,
|
15
|
+
Password: PasswordInput,
|
16
|
+
Number: NumberInput,
|
17
|
+
TextArea: TextArea,
|
18
|
+
File: FileInput,
|
19
|
+
});
|
20
|
+
export { Input, TextInput, NumberInput, TextArea, PasswordInput, FileInput };
|
21
|
+
|
22
|
+
|
@@ -0,0 +1,23 @@
|
|
1
|
+
/**
|
2
|
+
* @license MIT
|
3
|
+
* author: Cube Dev Team
|
4
|
+
* @cube-dev/ui-kit v0.9.0
|
5
|
+
* Released under the MIT license.
|
6
|
+
*/
|
7
|
+
|
8
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
9
|
+
import { forwardRef } from 'react';
|
10
|
+
import { Base } from '../Base';
|
11
|
+
import { CONTAINER_STYLES } from '../../styles/list';
|
12
|
+
import { extractStyles } from '../../utils/styles';
|
13
|
+
import { filterBaseProps } from '../../utils/filterBaseProps';
|
14
|
+
const DEFAULT_STYLES = {
|
15
|
+
display: 'flex',
|
16
|
+
flow: 'row',
|
17
|
+
};
|
18
|
+
export const Flex = forwardRef((props, ref) => {
|
19
|
+
const styles = extractStyles(props, CONTAINER_STYLES, DEFAULT_STYLES);
|
20
|
+
return (_jsx(Base, { ...filterBaseProps(props, { eventProps: true }), styles: styles, ref: ref }, void 0));
|
21
|
+
});
|
22
|
+
|
23
|
+
|
@@ -0,0 +1,24 @@
|
|
1
|
+
/**
|
2
|
+
* @license MIT
|
3
|
+
* author: Cube Dev Team
|
4
|
+
* @cube-dev/ui-kit v0.9.0
|
5
|
+
* Released under the MIT license.
|
6
|
+
*/
|
7
|
+
|
8
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
9
|
+
import { forwardRef } from 'react';
|
10
|
+
import { Base } from '../Base';
|
11
|
+
import { CONTAINER_STYLES } from '../../styles/list';
|
12
|
+
import { extractStyles } from '../../utils/styles';
|
13
|
+
import { filterBaseProps } from '../../utils/filterBaseProps';
|
14
|
+
const DEFAULT_STYLES = {
|
15
|
+
display: 'block',
|
16
|
+
flow: 'column',
|
17
|
+
};
|
18
|
+
const STYLE_PROPS = CONTAINER_STYLES;
|
19
|
+
export const Flow = forwardRef((props, ref) => {
|
20
|
+
const styles = extractStyles(props, STYLE_PROPS, DEFAULT_STYLES);
|
21
|
+
return (_jsx(Base, { ...filterBaseProps(props, { eventProps: true }), styles: styles, ref: ref }, void 0));
|
22
|
+
});
|
23
|
+
|
24
|
+
|
@@ -0,0 +1,30 @@
|
|
1
|
+
/**
|
2
|
+
* @license MIT
|
3
|
+
* author: Cube Dev Team
|
4
|
+
* @cube-dev/ui-kit v0.9.0
|
5
|
+
* Released under the MIT license.
|
6
|
+
*/
|
7
|
+
|
8
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
9
|
+
import { forwardRef } from 'react';
|
10
|
+
import { Base } from '../Base';
|
11
|
+
import { CONTAINER_STYLES } from '../../styles/list';
|
12
|
+
import { extractStyles } from '../../utils/styles';
|
13
|
+
import { filterBaseProps } from '../../utils/filterBaseProps';
|
14
|
+
const DEFAULT_STYLES = {
|
15
|
+
display: 'grid',
|
16
|
+
flow: 'row',
|
17
|
+
gap: '@(column-gap, 0)',
|
18
|
+
};
|
19
|
+
const PROP_MAP = {
|
20
|
+
template: 'gridTemplate',
|
21
|
+
columns: 'gridColumns',
|
22
|
+
rows: 'gridRows',
|
23
|
+
areas: 'gridAreas',
|
24
|
+
};
|
25
|
+
export const Grid = forwardRef((props, ref) => {
|
26
|
+
const styles = extractStyles(props, CONTAINER_STYLES, DEFAULT_STYLES, PROP_MAP);
|
27
|
+
return (_jsx(Base, { ...filterBaseProps(props, { eventProps: true }), styles: styles, ref: ref }, void 0));
|
28
|
+
});
|
29
|
+
|
30
|
+
|
@@ -0,0 +1,43 @@
|
|
1
|
+
/**
|
2
|
+
* @license MIT
|
3
|
+
* author: Cube Dev Team
|
4
|
+
* @cube-dev/ui-kit v0.9.0
|
5
|
+
* Released under the MIT license.
|
6
|
+
*/
|
7
|
+
|
8
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
9
|
+
import { forwardRef, useEffect } from 'react';
|
10
|
+
import { Base } from '../Base';
|
11
|
+
import { CONTAINER_STYLES } from '../../styles/list';
|
12
|
+
import { extractStyles, parseStyle } from '../../utils/styles';
|
13
|
+
import { filterBaseProps } from '../../utils/filterBaseProps';
|
14
|
+
import { useCombinedRefs } from '../../utils/react';
|
15
|
+
const DEFAULT_STYLES = {
|
16
|
+
position: 'absolute',
|
17
|
+
display: 'grid',
|
18
|
+
placeContent: 'stretch',
|
19
|
+
placeItems: 'center',
|
20
|
+
flow: 'column',
|
21
|
+
gap: 0,
|
22
|
+
left: '@prefix-gap',
|
23
|
+
top: '@prefix-gap',
|
24
|
+
bottom: '@prefix-gap',
|
25
|
+
color: '#dark.75',
|
26
|
+
height: '(100% - (2 * @prefix-gap))',
|
27
|
+
};
|
28
|
+
export const Prefix = forwardRef((allProps, outerRef) => {
|
29
|
+
let { onWidthChange, outerGap = '1bw', children, ...props } = allProps;
|
30
|
+
const styles = extractStyles(props, CONTAINER_STYLES, DEFAULT_STYLES);
|
31
|
+
const ref = useCombinedRefs(outerRef);
|
32
|
+
useEffect(() => {
|
33
|
+
if (ref?.current && onWidthChange) {
|
34
|
+
onWidthChange(ref.current.offsetWidth);
|
35
|
+
}
|
36
|
+
}, [children, ref, onWidthChange]);
|
37
|
+
return (_jsx(Base, { ...filterBaseProps(props, { eventProps: true }), styles: styles, ref: ref, style: {
|
38
|
+
// @ts-ignore
|
39
|
+
'--prefix-gap': parseStyle(outerGap).value,
|
40
|
+
}, children: children }, void 0));
|
41
|
+
});
|
42
|
+
|
43
|
+
|
@@ -0,0 +1,32 @@
|
|
1
|
+
/**
|
2
|
+
* @license MIT
|
3
|
+
* author: Cube Dev Team
|
4
|
+
* @cube-dev/ui-kit v0.9.0
|
5
|
+
* Released under the MIT license.
|
6
|
+
*/
|
7
|
+
|
8
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
9
|
+
import { forwardRef } from 'react';
|
10
|
+
import { Base } from '../Base';
|
11
|
+
import { CONTAINER_STYLES } from '../../styles/list';
|
12
|
+
import { extractStyles } from '../../utils/styles';
|
13
|
+
import { filterBaseProps } from '../../utils/filterBaseProps';
|
14
|
+
const DEFAULT_STYLES = {
|
15
|
+
display: 'flex',
|
16
|
+
gap: true,
|
17
|
+
};
|
18
|
+
export const Space = forwardRef(function Space(props, ref) {
|
19
|
+
const flow = props.direction
|
20
|
+
? props.direction === 'vertical'
|
21
|
+
? 'column'
|
22
|
+
: 'row'
|
23
|
+
: props.flow || 'row';
|
24
|
+
const styles = extractStyles(props, CONTAINER_STYLES, {
|
25
|
+
...DEFAULT_STYLES,
|
26
|
+
flow,
|
27
|
+
alignItems: flow === 'row' ? 'center' : 'stretch',
|
28
|
+
});
|
29
|
+
return (_jsx(Base, { ...filterBaseProps(props, { eventProps: true }), styles: styles, ref: ref }, void 0));
|
30
|
+
});
|
31
|
+
|
32
|
+
|
@@ -0,0 +1,42 @@
|
|
1
|
+
/**
|
2
|
+
* @license MIT
|
3
|
+
* author: Cube Dev Team
|
4
|
+
* @cube-dev/ui-kit v0.9.0
|
5
|
+
* Released under the MIT license.
|
6
|
+
*/
|
7
|
+
|
8
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
9
|
+
import { forwardRef, useEffect } from 'react';
|
10
|
+
import { Base } from '../Base';
|
11
|
+
import { CONTAINER_STYLES } from '../../styles/list';
|
12
|
+
import { extractStyles, parseStyle } from '../../utils/styles';
|
13
|
+
import { filterBaseProps } from '../../utils/filterBaseProps';
|
14
|
+
import { useCombinedRefs } from '../../utils/react';
|
15
|
+
const DEFAULT_STYLES = {
|
16
|
+
position: 'absolute',
|
17
|
+
display: 'grid',
|
18
|
+
placeContent: 'stretch',
|
19
|
+
placeItems: 'center',
|
20
|
+
flow: 'column',
|
21
|
+
gap: 0,
|
22
|
+
right: '@suffix-gap',
|
23
|
+
top: '@suffix-gap',
|
24
|
+
bottom: '@suffix-gap',
|
25
|
+
color: '#dark.75',
|
26
|
+
height: '(100% - (2 * @suffix-gap))',
|
27
|
+
};
|
28
|
+
export const Suffix = forwardRef((allProps, outerRef) => {
|
29
|
+
let { onWidthChange, outerGap = '1bw', children, ...props } = allProps;
|
30
|
+
const styles = extractStyles(props, CONTAINER_STYLES, DEFAULT_STYLES);
|
31
|
+
const ref = useCombinedRefs(outerRef);
|
32
|
+
useEffect(() => {
|
33
|
+
if (ref && ref.current && onWidthChange) {
|
34
|
+
onWidthChange(ref.current.offsetWidth);
|
35
|
+
}
|
36
|
+
}, [children, ref, onWidthChange]);
|
37
|
+
return (_jsx(Base, { ...filterBaseProps(props, { eventProps: true }), styles: styles, ref: ref, style: {
|
38
|
+
'--suffix-gap': parseStyle(outerGap).value,
|
39
|
+
}, children: children }, void 0));
|
40
|
+
});
|
41
|
+
|
42
|
+
|