@audira/carbon-react-native 0.0.1-alpha.1
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/LICENSE +21 -0
- package/lib/commonjs/_carbon-react-native/index.js +25 -0
- package/lib/commonjs/_carbon-react-native/index.js.map +1 -0
- package/lib/commonjs/_style-sheet/create.js +59 -0
- package/lib/commonjs/_style-sheet/create.js.map +1 -0
- package/lib/commonjs/_style-sheet/index.js +12 -0
- package/lib/commonjs/_style-sheet/index.js.map +1 -0
- package/lib/commonjs/components/accordion/_context.js +9 -0
- package/lib/commonjs/components/accordion/_context.js.map +1 -0
- package/lib/commonjs/components/accordion/_header-border.js +33 -0
- package/lib/commonjs/components/accordion/_header-border.js.map +1 -0
- package/lib/commonjs/components/accordion/_header.js +156 -0
- package/lib/commonjs/components/accordion/_header.js.map +1 -0
- package/lib/commonjs/components/accordion/_item.js +91 -0
- package/lib/commonjs/components/accordion/_item.js.map +1 -0
- package/lib/commonjs/components/accordion/_motion.js +18 -0
- package/lib/commonjs/components/accordion/_motion.js.map +1 -0
- package/lib/commonjs/components/accordion/_styles.js +24 -0
- package/lib/commonjs/components/accordion/_styles.js.map +1 -0
- package/lib/commonjs/components/accordion/index.js +74 -0
- package/lib/commonjs/components/accordion/index.js.map +1 -0
- package/lib/commonjs/components/accordion/types.js +2 -0
- package/lib/commonjs/components/accordion/types.js.map +1 -0
- package/lib/commonjs/components/button/base/index.js +153 -0
- package/lib/commonjs/components/button/base/index.js.map +1 -0
- package/lib/commonjs/components/button/base-color/index.js +155 -0
- package/lib/commonjs/components/button/base-color/index.js.map +1 -0
- package/lib/commonjs/components/button/ghost/index.js +92 -0
- package/lib/commonjs/components/button/ghost/index.js.map +1 -0
- package/lib/commonjs/components/button/ghost-danger/index.js +92 -0
- package/lib/commonjs/components/button/ghost-danger/index.js.map +1 -0
- package/lib/commonjs/components/button/ghost-icon/index.js +81 -0
- package/lib/commonjs/components/button/ghost-icon/index.js.map +1 -0
- package/lib/commonjs/components/button/index.js +127 -0
- package/lib/commonjs/components/button/index.js.map +1 -0
- package/lib/commonjs/components/button/primary/index.js +74 -0
- package/lib/commonjs/components/button/primary/index.js.map +1 -0
- package/lib/commonjs/components/button/primary-danger/index.js +74 -0
- package/lib/commonjs/components/button/primary-danger/index.js.map +1 -0
- package/lib/commonjs/components/button/secondary/index.js +74 -0
- package/lib/commonjs/components/button/secondary/index.js.map +1 -0
- package/lib/commonjs/components/button/size.js +2 -0
- package/lib/commonjs/components/button/size.js.map +1 -0
- package/lib/commonjs/components/button/tertiary/index.js +89 -0
- package/lib/commonjs/components/button/tertiary/index.js.map +1 -0
- package/lib/commonjs/components/button/tertiary-danger/index.js +89 -0
- package/lib/commonjs/components/button/tertiary-danger/index.js.map +1 -0
- package/lib/commonjs/components/checkbox/index.js +117 -0
- package/lib/commonjs/components/checkbox/index.js.map +1 -0
- package/lib/commonjs/components/checkbox-group/index.js +98 -0
- package/lib/commonjs/components/checkbox-group/index.js.map +1 -0
- package/lib/commonjs/components/checkbox-input/index.js +208 -0
- package/lib/commonjs/components/checkbox-input/index.js.map +1 -0
- package/lib/commonjs/components/collapsible/index.js +134 -0
- package/lib/commonjs/components/collapsible/index.js.map +1 -0
- package/lib/commonjs/components/form-helper-text/index.js +41 -0
- package/lib/commonjs/components/form-helper-text/index.js.map +1 -0
- package/lib/commonjs/components/form-label/index.js +35 -0
- package/lib/commonjs/components/form-label/index.js.map +1 -0
- package/lib/commonjs/components/icon/index.js +42 -0
- package/lib/commonjs/components/icon/index.js.map +1 -0
- package/lib/commonjs/components/index.js +176 -0
- package/lib/commonjs/components/index.js.map +1 -0
- package/lib/commonjs/components/notification/_status-hooks/_base.js +52 -0
- package/lib/commonjs/components/notification/_status-hooks/_base.js.map +1 -0
- package/lib/commonjs/components/notification/_status-hooks/error/index.js +47 -0
- package/lib/commonjs/components/notification/_status-hooks/error/index.js.map +1 -0
- package/lib/commonjs/components/notification/_status-hooks/index.js +50 -0
- package/lib/commonjs/components/notification/_status-hooks/index.js.map +1 -0
- package/lib/commonjs/components/notification/_status-hooks/informational/index.js +47 -0
- package/lib/commonjs/components/notification/_status-hooks/informational/index.js.map +1 -0
- package/lib/commonjs/components/notification/_status-hooks/success/index.js +47 -0
- package/lib/commonjs/components/notification/_status-hooks/success/index.js.map +1 -0
- package/lib/commonjs/components/notification/_status-hooks/warning/index.js +47 -0
- package/lib/commonjs/components/notification/_status-hooks/warning/index.js.map +1 -0
- package/lib/commonjs/components/notification/_variant-context.js +24 -0
- package/lib/commonjs/components/notification/_variant-context.js.map +1 -0
- package/lib/commonjs/components/notification/_variants/_button-ghost.js +43 -0
- package/lib/commonjs/components/notification/_variants/_button-ghost.js.map +1 -0
- package/lib/commonjs/components/notification/_variants/_button-tertiary.js +43 -0
- package/lib/commonjs/components/notification/_variants/_button-tertiary.js.map +1 -0
- package/lib/commonjs/components/notification/_variants/actionable/index.js +42 -0
- package/lib/commonjs/components/notification/_variants/actionable/index.js.map +1 -0
- package/lib/commonjs/components/notification/_variants/actionable-inline/index.js +42 -0
- package/lib/commonjs/components/notification/_variants/actionable-inline/index.js.map +1 -0
- package/lib/commonjs/components/notification/_variants/callout/index.js +35 -0
- package/lib/commonjs/components/notification/_variants/callout/index.js.map +1 -0
- package/lib/commonjs/components/notification/_variants/callout-inline/index.js +35 -0
- package/lib/commonjs/components/notification/_variants/callout-inline/index.js.map +1 -0
- package/lib/commonjs/components/notification/_variants/index.js +61 -0
- package/lib/commonjs/components/notification/_variants/index.js.map +1 -0
- package/lib/commonjs/components/notification/_variants/toast/index.js +63 -0
- package/lib/commonjs/components/notification/_variants/toast/index.js.map +1 -0
- package/lib/commonjs/components/notification/actionable/error/index.js +49 -0
- package/lib/commonjs/components/notification/actionable/error/index.js.map +1 -0
- package/lib/commonjs/components/notification/actionable/index.js +50 -0
- package/lib/commonjs/components/notification/actionable/index.js.map +1 -0
- package/lib/commonjs/components/notification/actionable/informational/index.js +49 -0
- package/lib/commonjs/components/notification/actionable/informational/index.js.map +1 -0
- package/lib/commonjs/components/notification/actionable/success/index.js +49 -0
- package/lib/commonjs/components/notification/actionable/success/index.js.map +1 -0
- package/lib/commonjs/components/notification/actionable/warning/index.js +49 -0
- package/lib/commonjs/components/notification/actionable/warning/index.js.map +1 -0
- package/lib/commonjs/components/notification/actionable-inline/error/index.js +48 -0
- package/lib/commonjs/components/notification/actionable-inline/error/index.js.map +1 -0
- package/lib/commonjs/components/notification/actionable-inline/index.js +50 -0
- package/lib/commonjs/components/notification/actionable-inline/index.js.map +1 -0
- package/lib/commonjs/components/notification/actionable-inline/informational/index.js +48 -0
- package/lib/commonjs/components/notification/actionable-inline/informational/index.js.map +1 -0
- package/lib/commonjs/components/notification/actionable-inline/success/index.js +48 -0
- package/lib/commonjs/components/notification/actionable-inline/success/index.js.map +1 -0
- package/lib/commonjs/components/notification/actionable-inline/warning/index.js +48 -0
- package/lib/commonjs/components/notification/actionable-inline/warning/index.js.map +1 -0
- package/lib/commonjs/components/notification/base/index.js +170 -0
- package/lib/commonjs/components/notification/base/index.js.map +1 -0
- package/lib/commonjs/components/notification/callout/error/index.js +49 -0
- package/lib/commonjs/components/notification/callout/error/index.js.map +1 -0
- package/lib/commonjs/components/notification/callout/index.js +50 -0
- package/lib/commonjs/components/notification/callout/index.js.map +1 -0
- package/lib/commonjs/components/notification/callout/informational/index.js +49 -0
- package/lib/commonjs/components/notification/callout/informational/index.js.map +1 -0
- package/lib/commonjs/components/notification/callout/success/index.js +49 -0
- package/lib/commonjs/components/notification/callout/success/index.js.map +1 -0
- package/lib/commonjs/components/notification/callout/warning/index.js +49 -0
- package/lib/commonjs/components/notification/callout/warning/index.js.map +1 -0
- package/lib/commonjs/components/notification/callout-inline/error/index.js +48 -0
- package/lib/commonjs/components/notification/callout-inline/error/index.js.map +1 -0
- package/lib/commonjs/components/notification/callout-inline/index.js +50 -0
- package/lib/commonjs/components/notification/callout-inline/index.js.map +1 -0
- package/lib/commonjs/components/notification/callout-inline/informational/index.js +48 -0
- package/lib/commonjs/components/notification/callout-inline/informational/index.js.map +1 -0
- package/lib/commonjs/components/notification/callout-inline/success/index.js +48 -0
- package/lib/commonjs/components/notification/callout-inline/success/index.js.map +1 -0
- package/lib/commonjs/components/notification/callout-inline/warning/index.js +48 -0
- package/lib/commonjs/components/notification/callout-inline/warning/index.js.map +1 -0
- package/lib/commonjs/components/notification/index.js +62 -0
- package/lib/commonjs/components/notification/index.js.map +1 -0
- package/lib/commonjs/components/notification/subtitle/index.js +30 -0
- package/lib/commonjs/components/notification/subtitle/index.js.map +1 -0
- package/lib/commonjs/components/notification/subtitle-link/index.js +29 -0
- package/lib/commonjs/components/notification/subtitle-link/index.js.map +1 -0
- package/lib/commonjs/components/notification/toast/error/index.js +49 -0
- package/lib/commonjs/components/notification/toast/error/index.js.map +1 -0
- package/lib/commonjs/components/notification/toast/index.js +50 -0
- package/lib/commonjs/components/notification/toast/index.js.map +1 -0
- package/lib/commonjs/components/notification/toast/informational/index.js +49 -0
- package/lib/commonjs/components/notification/toast/informational/index.js.map +1 -0
- package/lib/commonjs/components/notification/toast/success/index.js +49 -0
- package/lib/commonjs/components/notification/toast/success/index.js.map +1 -0
- package/lib/commonjs/components/notification/toast/warning/index.js +49 -0
- package/lib/commonjs/components/notification/toast/warning/index.js.map +1 -0
- package/lib/commonjs/components/notification/types.js +2 -0
- package/lib/commonjs/components/notification/types.js.map +1 -0
- package/lib/commonjs/components/radio-button/index.js +106 -0
- package/lib/commonjs/components/radio-button/index.js.map +1 -0
- package/lib/commonjs/components/radio-button-group/_item-context.js +9 -0
- package/lib/commonjs/components/radio-button-group/_item-context.js.map +1 -0
- package/lib/commonjs/components/radio-button-group/_item.js +52 -0
- package/lib/commonjs/components/radio-button-group/_item.js.map +1 -0
- package/lib/commonjs/components/radio-button-group/_types/index.js +6 -0
- package/lib/commonjs/components/radio-button-group/_types/index.js.map +1 -0
- package/lib/commonjs/components/radio-button-group/_types/ref-base.js +6 -0
- package/lib/commonjs/components/radio-button-group/_types/ref-base.js.map +1 -0
- package/lib/commonjs/components/radio-button-group/index.js +141 -0
- package/lib/commonjs/components/radio-button-group/index.js.map +1 -0
- package/lib/commonjs/components/radio-button-input/index.js +200 -0
- package/lib/commonjs/components/radio-button-input/index.js.map +1 -0
- package/lib/commonjs/components/switch/index.js +245 -0
- package/lib/commonjs/components/switch/index.js.map +1 -0
- package/lib/commonjs/components/text/index.js +70 -0
- package/lib/commonjs/components/text/index.js.map +1 -0
- package/lib/commonjs/components/toggle/base/index.js +115 -0
- package/lib/commonjs/components/toggle/base/index.js.map +1 -0
- package/lib/commonjs/components/toggle/default/index.js +23 -0
- package/lib/commonjs/components/toggle/default/index.js.map +1 -0
- package/lib/commonjs/components/toggle/index.js +50 -0
- package/lib/commonjs/components/toggle/index.js.map +1 -0
- package/lib/commonjs/components/toggle/small/index.js +23 -0
- package/lib/commonjs/components/toggle/small/index.js.map +1 -0
- package/lib/commonjs/components/toggle/state.js +2 -0
- package/lib/commonjs/components/toggle/state.js.map +1 -0
- package/lib/commonjs/constants/color/code.json +273 -0
- package/lib/commonjs/constants/color/index.js +19 -0
- package/lib/commonjs/constants/color/index.js.map +1 -0
- package/lib/commonjs/constants/color/tokens/gray-10.js +181 -0
- package/lib/commonjs/constants/color/tokens/gray-10.js.map +1 -0
- package/lib/commonjs/constants/color/tokens/gray-100.js +181 -0
- package/lib/commonjs/constants/color/tokens/gray-100.js.map +1 -0
- package/lib/commonjs/constants/color/tokens/index.js +28 -0
- package/lib/commonjs/constants/color/tokens/index.js.map +1 -0
- package/lib/commonjs/constants/index.js +24 -0
- package/lib/commonjs/constants/index.js.map +1 -0
- package/lib/commonjs/constants/motion/index.js +71 -0
- package/lib/commonjs/constants/motion/index.js.map +1 -0
- package/lib/commonjs/constants/spacing.js +22 -0
- package/lib/commonjs/constants/spacing.js.map +1 -0
- package/lib/commonjs/constants/typography/font-family.js +23 -0
- package/lib/commonjs/constants/typography/font-family.js.map +1 -0
- package/lib/commonjs/constants/typography/index.js +28 -0
- package/lib/commonjs/constants/typography/index.js.map +1 -0
- package/lib/commonjs/constants/typography/type-sets.js +141 -0
- package/lib/commonjs/constants/typography/type-sets.js.map +1 -0
- package/lib/commonjs/contexts/global-config/context.js +12 -0
- package/lib/commonjs/contexts/global-config/context.js.map +1 -0
- package/lib/commonjs/contexts/global-config/provider.js +22 -0
- package/lib/commonjs/contexts/global-config/provider.js.map +1 -0
- package/lib/commonjs/contexts/index.js +28 -0
- package/lib/commonjs/contexts/index.js.map +1 -0
- package/lib/commonjs/contexts/theme/context.js +14 -0
- package/lib/commonjs/contexts/theme/context.js.map +1 -0
- package/lib/commonjs/contexts/theme/index.js +17 -0
- package/lib/commonjs/contexts/theme/index.js.map +1 -0
- package/lib/commonjs/contexts/theme/provider.js +31 -0
- package/lib/commonjs/contexts/theme/provider.js.map +1 -0
- package/lib/commonjs/globals/color-scheme/index.js +16 -0
- package/lib/commonjs/globals/color-scheme/index.js.map +1 -0
- package/lib/commonjs/globals/index.js +11 -0
- package/lib/commonjs/globals/index.js.map +1 -0
- package/lib/commonjs/helpers/color/get-color-scheme.js +15 -0
- package/lib/commonjs/helpers/color/get-color-scheme.js.map +1 -0
- package/lib/commonjs/helpers/color/get-color-token.js +14 -0
- package/lib/commonjs/helpers/color/get-color-token.js.map +1 -0
- package/lib/commonjs/helpers/color/hex-to-rgba.js +11 -0
- package/lib/commonjs/helpers/color/hex-to-rgba.js.map +1 -0
- package/lib/commonjs/helpers/color/index.js +39 -0
- package/lib/commonjs/helpers/color/index.js.map +1 -0
- package/lib/commonjs/helpers/index.js +11 -0
- package/lib/commonjs/helpers/index.js.map +1 -0
- package/lib/commonjs/index.js +94 -0
- package/lib/commonjs/index.js.map +1 -0
- package/lib/commonjs/styles/common.js +25 -0
- package/lib/commonjs/styles/common.js.map +1 -0
- package/lib/commonjs/styles/flex.js +82 -0
- package/lib/commonjs/styles/flex.js.map +1 -0
- package/lib/commonjs/styles/index.js +39 -0
- package/lib/commonjs/styles/index.js.map +1 -0
- package/lib/commonjs/styles/text.js +67 -0
- package/lib/commonjs/styles/text.js.map +1 -0
- package/lib/commonjs/types/@carbon/icons/index.d.js +2 -0
- package/lib/commonjs/types/@carbon/icons/index.d.js.map +1 -0
- package/lib/commonjs/types/index.js +6 -0
- package/lib/commonjs/types/index.js.map +1 -0
- package/lib/commonjs/types/shared.js +2 -0
- package/lib/commonjs/types/shared.js.map +1 -0
- package/lib/commonjs/types/theme/color-scheme.js +2 -0
- package/lib/commonjs/types/theme/color-scheme.js.map +1 -0
- package/lib/commonjs/types/theme/color-token.js +2 -0
- package/lib/commonjs/types/theme/color-token.js.map +1 -0
- package/lib/commonjs/types/theme/index.js +2 -0
- package/lib/commonjs/types/theme/index.js.map +1 -0
- package/lib/commonjs/types/typography.js +6 -0
- package/lib/commonjs/types/typography.js.map +1 -0
- package/lib/module/_carbon-react-native/index.js +21 -0
- package/lib/module/_carbon-react-native/index.js.map +1 -0
- package/lib/module/_style-sheet/create.js +55 -0
- package/lib/module/_style-sheet/create.js.map +1 -0
- package/lib/module/_style-sheet/index.js +8 -0
- package/lib/module/_style-sheet/index.js.map +1 -0
- package/lib/module/components/accordion/_context.js +5 -0
- package/lib/module/components/accordion/_context.js.map +1 -0
- package/lib/module/components/accordion/_header-border.js +29 -0
- package/lib/module/components/accordion/_header-border.js.map +1 -0
- package/lib/module/components/accordion/_header.js +149 -0
- package/lib/module/components/accordion/_header.js.map +1 -0
- package/lib/module/components/accordion/_item.js +87 -0
- package/lib/module/components/accordion/_item.js.map +1 -0
- package/lib/module/components/accordion/_motion.js +14 -0
- package/lib/module/components/accordion/_motion.js.map +1 -0
- package/lib/module/components/accordion/_styles.js +21 -0
- package/lib/module/components/accordion/_styles.js.map +1 -0
- package/lib/module/components/accordion/index.js +70 -0
- package/lib/module/components/accordion/index.js.map +1 -0
- package/lib/module/components/accordion/types.js +2 -0
- package/lib/module/components/accordion/types.js.map +1 -0
- package/lib/module/components/button/base/index.js +149 -0
- package/lib/module/components/button/base/index.js.map +1 -0
- package/lib/module/components/button/base-color/index.js +151 -0
- package/lib/module/components/button/base-color/index.js.map +1 -0
- package/lib/module/components/button/ghost/index.js +88 -0
- package/lib/module/components/button/ghost/index.js.map +1 -0
- package/lib/module/components/button/ghost-danger/index.js +88 -0
- package/lib/module/components/button/ghost-danger/index.js.map +1 -0
- package/lib/module/components/button/ghost-icon/index.js +77 -0
- package/lib/module/components/button/ghost-icon/index.js.map +1 -0
- package/lib/module/components/button/index.js +14 -0
- package/lib/module/components/button/index.js.map +1 -0
- package/lib/module/components/button/primary/index.js +70 -0
- package/lib/module/components/button/primary/index.js.map +1 -0
- package/lib/module/components/button/primary-danger/index.js +70 -0
- package/lib/module/components/button/primary-danger/index.js.map +1 -0
- package/lib/module/components/button/secondary/index.js +70 -0
- package/lib/module/components/button/secondary/index.js.map +1 -0
- package/lib/module/components/button/size.js +2 -0
- package/lib/module/components/button/size.js.map +1 -0
- package/lib/module/components/button/tertiary/index.js +85 -0
- package/lib/module/components/button/tertiary/index.js.map +1 -0
- package/lib/module/components/button/tertiary-danger/index.js +85 -0
- package/lib/module/components/button/tertiary-danger/index.js.map +1 -0
- package/lib/module/components/checkbox/index.js +113 -0
- package/lib/module/components/checkbox/index.js.map +1 -0
- package/lib/module/components/checkbox-group/index.js +93 -0
- package/lib/module/components/checkbox-group/index.js.map +1 -0
- package/lib/module/components/checkbox-input/index.js +203 -0
- package/lib/module/components/checkbox-input/index.js.map +1 -0
- package/lib/module/components/collapsible/index.js +128 -0
- package/lib/module/components/collapsible/index.js.map +1 -0
- package/lib/module/components/form-helper-text/index.js +37 -0
- package/lib/module/components/form-helper-text/index.js.map +1 -0
- package/lib/module/components/form-label/index.js +31 -0
- package/lib/module/components/form-label/index.js.map +1 -0
- package/lib/module/components/icon/index.js +35 -0
- package/lib/module/components/icon/index.js.map +1 -0
- package/lib/module/components/index.js +20 -0
- package/lib/module/components/index.js.map +1 -0
- package/lib/module/components/notification/_status-hooks/_base.js +48 -0
- package/lib/module/components/notification/_status-hooks/_base.js.map +1 -0
- package/lib/module/components/notification/_status-hooks/error/index.js +42 -0
- package/lib/module/components/notification/_status-hooks/error/index.js.map +1 -0
- package/lib/module/components/notification/_status-hooks/index.js +7 -0
- package/lib/module/components/notification/_status-hooks/index.js.map +1 -0
- package/lib/module/components/notification/_status-hooks/informational/index.js +42 -0
- package/lib/module/components/notification/_status-hooks/informational/index.js.map +1 -0
- package/lib/module/components/notification/_status-hooks/success/index.js +42 -0
- package/lib/module/components/notification/_status-hooks/success/index.js.map +1 -0
- package/lib/module/components/notification/_status-hooks/warning/index.js +42 -0
- package/lib/module/components/notification/_status-hooks/warning/index.js.map +1 -0
- package/lib/module/components/notification/_variant-context.js +19 -0
- package/lib/module/components/notification/_variant-context.js.map +1 -0
- package/lib/module/components/notification/_variants/_button-ghost.js +39 -0
- package/lib/module/components/notification/_variants/_button-ghost.js.map +1 -0
- package/lib/module/components/notification/_variants/_button-tertiary.js +39 -0
- package/lib/module/components/notification/_variants/_button-tertiary.js.map +1 -0
- package/lib/module/components/notification/_variants/actionable/index.js +38 -0
- package/lib/module/components/notification/_variants/actionable/index.js.map +1 -0
- package/lib/module/components/notification/_variants/actionable-inline/index.js +38 -0
- package/lib/module/components/notification/_variants/actionable-inline/index.js.map +1 -0
- package/lib/module/components/notification/_variants/callout/index.js +31 -0
- package/lib/module/components/notification/_variants/callout/index.js.map +1 -0
- package/lib/module/components/notification/_variants/callout-inline/index.js +31 -0
- package/lib/module/components/notification/_variants/callout-inline/index.js.map +1 -0
- package/lib/module/components/notification/_variants/index.js +8 -0
- package/lib/module/components/notification/_variants/index.js.map +1 -0
- package/lib/module/components/notification/_variants/toast/index.js +59 -0
- package/lib/module/components/notification/_variants/toast/index.js.map +1 -0
- package/lib/module/components/notification/actionable/error/index.js +45 -0
- package/lib/module/components/notification/actionable/error/index.js.map +1 -0
- package/lib/module/components/notification/actionable/index.js +7 -0
- package/lib/module/components/notification/actionable/index.js.map +1 -0
- package/lib/module/components/notification/actionable/informational/index.js +45 -0
- package/lib/module/components/notification/actionable/informational/index.js.map +1 -0
- package/lib/module/components/notification/actionable/success/index.js +45 -0
- package/lib/module/components/notification/actionable/success/index.js.map +1 -0
- package/lib/module/components/notification/actionable/warning/index.js +45 -0
- package/lib/module/components/notification/actionable/warning/index.js.map +1 -0
- package/lib/module/components/notification/actionable-inline/error/index.js +44 -0
- package/lib/module/components/notification/actionable-inline/error/index.js.map +1 -0
- package/lib/module/components/notification/actionable-inline/index.js +7 -0
- package/lib/module/components/notification/actionable-inline/index.js.map +1 -0
- package/lib/module/components/notification/actionable-inline/informational/index.js +44 -0
- package/lib/module/components/notification/actionable-inline/informational/index.js.map +1 -0
- package/lib/module/components/notification/actionable-inline/success/index.js +44 -0
- package/lib/module/components/notification/actionable-inline/success/index.js.map +1 -0
- package/lib/module/components/notification/actionable-inline/warning/index.js +44 -0
- package/lib/module/components/notification/actionable-inline/warning/index.js.map +1 -0
- package/lib/module/components/notification/base/index.js +165 -0
- package/lib/module/components/notification/base/index.js.map +1 -0
- package/lib/module/components/notification/callout/error/index.js +45 -0
- package/lib/module/components/notification/callout/error/index.js.map +1 -0
- package/lib/module/components/notification/callout/index.js +7 -0
- package/lib/module/components/notification/callout/index.js.map +1 -0
- package/lib/module/components/notification/callout/informational/index.js +45 -0
- package/lib/module/components/notification/callout/informational/index.js.map +1 -0
- package/lib/module/components/notification/callout/success/index.js +45 -0
- package/lib/module/components/notification/callout/success/index.js.map +1 -0
- package/lib/module/components/notification/callout/warning/index.js +45 -0
- package/lib/module/components/notification/callout/warning/index.js.map +1 -0
- package/lib/module/components/notification/callout-inline/error/index.js +44 -0
- package/lib/module/components/notification/callout-inline/error/index.js.map +1 -0
- package/lib/module/components/notification/callout-inline/index.js +7 -0
- package/lib/module/components/notification/callout-inline/index.js.map +1 -0
- package/lib/module/components/notification/callout-inline/informational/index.js +44 -0
- package/lib/module/components/notification/callout-inline/informational/index.js.map +1 -0
- package/lib/module/components/notification/callout-inline/success/index.js +44 -0
- package/lib/module/components/notification/callout-inline/success/index.js.map +1 -0
- package/lib/module/components/notification/callout-inline/warning/index.js +44 -0
- package/lib/module/components/notification/callout-inline/warning/index.js.map +1 -0
- package/lib/module/components/notification/index.js +12 -0
- package/lib/module/components/notification/index.js.map +1 -0
- package/lib/module/components/notification/subtitle/index.js +26 -0
- package/lib/module/components/notification/subtitle/index.js.map +1 -0
- package/lib/module/components/notification/subtitle-link/index.js +25 -0
- package/lib/module/components/notification/subtitle-link/index.js.map +1 -0
- package/lib/module/components/notification/toast/error/index.js +45 -0
- package/lib/module/components/notification/toast/error/index.js.map +1 -0
- package/lib/module/components/notification/toast/index.js +7 -0
- package/lib/module/components/notification/toast/index.js.map +1 -0
- package/lib/module/components/notification/toast/informational/index.js +45 -0
- package/lib/module/components/notification/toast/informational/index.js.map +1 -0
- package/lib/module/components/notification/toast/success/index.js +45 -0
- package/lib/module/components/notification/toast/success/index.js.map +1 -0
- package/lib/module/components/notification/toast/warning/index.js +45 -0
- package/lib/module/components/notification/toast/warning/index.js.map +1 -0
- package/lib/module/components/notification/types.js +2 -0
- package/lib/module/components/notification/types.js.map +1 -0
- package/lib/module/components/radio-button/index.js +102 -0
- package/lib/module/components/radio-button/index.js.map +1 -0
- package/lib/module/components/radio-button-group/_item-context.js +5 -0
- package/lib/module/components/radio-button-group/_item-context.js.map +1 -0
- package/lib/module/components/radio-button-group/_item.js +48 -0
- package/lib/module/components/radio-button-group/_item.js.map +1 -0
- package/lib/module/components/radio-button-group/_types/index.js +4 -0
- package/lib/module/components/radio-button-group/_types/index.js.map +1 -0
- package/lib/module/components/radio-button-group/_types/ref-base.js +4 -0
- package/lib/module/components/radio-button-group/_types/ref-base.js.map +1 -0
- package/lib/module/components/radio-button-group/index.js +136 -0
- package/lib/module/components/radio-button-group/index.js.map +1 -0
- package/lib/module/components/radio-button-input/index.js +196 -0
- package/lib/module/components/radio-button-input/index.js.map +1 -0
- package/lib/module/components/switch/index.js +238 -0
- package/lib/module/components/switch/index.js.map +1 -0
- package/lib/module/components/text/index.js +66 -0
- package/lib/module/components/text/index.js.map +1 -0
- package/lib/module/components/toggle/base/index.js +111 -0
- package/lib/module/components/toggle/base/index.js.map +1 -0
- package/lib/module/components/toggle/default/index.js +19 -0
- package/lib/module/components/toggle/default/index.js.map +1 -0
- package/lib/module/components/toggle/index.js +7 -0
- package/lib/module/components/toggle/index.js.map +1 -0
- package/lib/module/components/toggle/small/index.js +19 -0
- package/lib/module/components/toggle/small/index.js.map +1 -0
- package/lib/module/components/toggle/state.js +2 -0
- package/lib/module/components/toggle/state.js.map +1 -0
- package/lib/module/constants/color/code.json +273 -0
- package/lib/module/constants/color/index.js +6 -0
- package/lib/module/constants/color/index.js.map +1 -0
- package/lib/module/constants/color/tokens/gray-10.js +176 -0
- package/lib/module/constants/color/tokens/gray-10.js.map +1 -0
- package/lib/module/constants/color/tokens/gray-100.js +176 -0
- package/lib/module/constants/color/tokens/gray-100.js.map +1 -0
- package/lib/module/constants/color/tokens/index.js +5 -0
- package/lib/module/constants/color/tokens/index.js.map +1 -0
- package/lib/module/constants/index.js +8 -0
- package/lib/module/constants/index.js.map +1 -0
- package/lib/module/constants/motion/index.js +67 -0
- package/lib/module/constants/motion/index.js.map +1 -0
- package/lib/module/constants/spacing.js +18 -0
- package/lib/module/constants/spacing.js.map +1 -0
- package/lib/module/constants/typography/font-family.js +19 -0
- package/lib/module/constants/typography/font-family.js.map +1 -0
- package/lib/module/constants/typography/index.js +5 -0
- package/lib/module/constants/typography/index.js.map +1 -0
- package/lib/module/constants/typography/type-sets.js +137 -0
- package/lib/module/constants/typography/type-sets.js.map +1 -0
- package/lib/module/contexts/global-config/context.js +8 -0
- package/lib/module/contexts/global-config/context.js.map +1 -0
- package/lib/module/contexts/global-config/provider.js +18 -0
- package/lib/module/contexts/global-config/provider.js.map +1 -0
- package/lib/module/contexts/index.js +5 -0
- package/lib/module/contexts/index.js.map +1 -0
- package/lib/module/contexts/theme/context.js +10 -0
- package/lib/module/contexts/theme/context.js.map +1 -0
- package/lib/module/contexts/theme/index.js +4 -0
- package/lib/module/contexts/theme/index.js.map +1 -0
- package/lib/module/contexts/theme/provider.js +27 -0
- package/lib/module/contexts/theme/provider.js.map +1 -0
- package/lib/module/globals/color-scheme/index.js +11 -0
- package/lib/module/globals/color-scheme/index.js.map +1 -0
- package/lib/module/globals/index.js +5 -0
- package/lib/module/globals/index.js.map +1 -0
- package/lib/module/helpers/color/get-color-scheme.js +11 -0
- package/lib/module/helpers/color/get-color-scheme.js.map +1 -0
- package/lib/module/helpers/color/get-color-token.js +10 -0
- package/lib/module/helpers/color/get-color-token.js.map +1 -0
- package/lib/module/helpers/color/hex-to-rgba.js +7 -0
- package/lib/module/helpers/color/hex-to-rgba.js.map +1 -0
- package/lib/module/helpers/color/index.js +6 -0
- package/lib/module/helpers/color/index.js.map +1 -0
- package/lib/module/helpers/index.js +5 -0
- package/lib/module/helpers/index.js.map +1 -0
- package/lib/module/index.js +11 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/styles/common.js +21 -0
- package/lib/module/styles/common.js.map +1 -0
- package/lib/module/styles/flex.js +78 -0
- package/lib/module/styles/flex.js.map +1 -0
- package/lib/module/styles/index.js +6 -0
- package/lib/module/styles/index.js.map +1 -0
- package/lib/module/styles/text.js +63 -0
- package/lib/module/styles/text.js.map +1 -0
- package/lib/module/types/@carbon/icons/index.d.js +2 -0
- package/lib/module/types/@carbon/icons/index.d.js.map +1 -0
- package/lib/module/types/index.js +4 -0
- package/lib/module/types/index.js.map +1 -0
- package/lib/module/types/shared.js +2 -0
- package/lib/module/types/shared.js.map +1 -0
- package/lib/module/types/theme/color-scheme.js +2 -0
- package/lib/module/types/theme/color-scheme.js.map +1 -0
- package/lib/module/types/theme/color-token.js +2 -0
- package/lib/module/types/theme/color-token.js.map +1 -0
- package/lib/module/types/theme/index.js +2 -0
- package/lib/module/types/theme/index.js.map +1 -0
- package/lib/module/types/typography.js +4 -0
- package/lib/module/types/typography.js.map +1 -0
- package/lib/typescript/commonjs/package.json +1 -0
- package/lib/typescript/commonjs/src/_carbon-react-native/index.d.ts +7 -0
- package/lib/typescript/commonjs/src/_carbon-react-native/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/_style-sheet/create.d.ts +6 -0
- package/lib/typescript/commonjs/src/_style-sheet/create.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/_style-sheet/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/_style-sheet/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/accordion/_context.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/accordion/_context.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/accordion/_header-border.d.ts +10 -0
- package/lib/typescript/commonjs/src/components/accordion/_header-border.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/accordion/_header.d.ts +13 -0
- package/lib/typescript/commonjs/src/components/accordion/_header.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/accordion/_item.d.ts +23 -0
- package/lib/typescript/commonjs/src/components/accordion/_item.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/accordion/_motion.d.ts +3 -0
- package/lib/typescript/commonjs/src/components/accordion/_motion.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/accordion/_styles.d.ts +16 -0
- package/lib/typescript/commonjs/src/components/accordion/_styles.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/accordion/index.d.ts +16 -0
- package/lib/typescript/commonjs/src/components/accordion/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/accordion/types.d.ts +2 -0
- package/lib/typescript/commonjs/src/components/accordion/types.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/button/base/index.d.ts +37 -0
- package/lib/typescript/commonjs/src/components/button/base/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/button/base-color/index.d.ts +21 -0
- package/lib/typescript/commonjs/src/components/button/base-color/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/button/ghost/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/button/ghost/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/button/ghost-danger/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/button/ghost-danger/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/button/ghost-icon/index.d.ts +8 -0
- package/lib/typescript/commonjs/src/components/button/ghost-icon/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/button/index.d.ts +12 -0
- package/lib/typescript/commonjs/src/components/button/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/button/primary/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/button/primary/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/button/primary-danger/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/button/primary-danger/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/button/secondary/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/button/secondary/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/button/size.d.ts +2 -0
- package/lib/typescript/commonjs/src/components/button/size.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/button/tertiary/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/button/tertiary/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/button/tertiary-danger/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/button/tertiary-danger/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/checkbox/index.d.ts +32 -0
- package/lib/typescript/commonjs/src/components/checkbox/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/checkbox-group/index.d.ts +21 -0
- package/lib/typescript/commonjs/src/components/checkbox-group/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/checkbox-input/index.d.ts +25 -0
- package/lib/typescript/commonjs/src/components/checkbox-input/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/collapsible/index.d.ts +26 -0
- package/lib/typescript/commonjs/src/components/collapsible/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/form-helper-text/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/components/form-helper-text/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/form-label/index.d.ts +10 -0
- package/lib/typescript/commonjs/src/components/form-label/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/icon/index.d.ts +13 -0
- package/lib/typescript/commonjs/src/components/icon/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/index.d.ts +18 -0
- package/lib/typescript/commonjs/src/components/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_status-hooks/_base.d.ts +28 -0
- package/lib/typescript/commonjs/src/components/notification/_status-hooks/_base.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_status-hooks/error/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/components/notification/_status-hooks/error/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_status-hooks/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/notification/_status-hooks/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_status-hooks/informational/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/components/notification/_status-hooks/informational/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_status-hooks/success/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/components/notification/_status-hooks/success/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_status-hooks/warning/index.d.ts +11 -0
- package/lib/typescript/commonjs/src/components/notification/_status-hooks/warning/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_variant-context.d.ts +10 -0
- package/lib/typescript/commonjs/src/components/notification/_variant-context.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/_button-ghost.d.ts +7 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/_button-ghost.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/_button-tertiary.d.ts +7 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/_button-tertiary.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/actionable/index.d.ts +30 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/actionable/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/actionable-inline/index.d.ts +30 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/actionable-inline/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/callout/index.d.ts +13 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/callout/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/callout-inline/index.d.ts +13 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/callout-inline/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/index.d.ts +6 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/toast/index.d.ts +17 -0
- package/lib/typescript/commonjs/src/components/notification/_variants/toast/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/actionable/error/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/actionable/error/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/actionable/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/notification/actionable/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/actionable/informational/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/actionable/informational/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/actionable/success/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/actionable/success/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/actionable/warning/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/actionable/warning/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/actionable-inline/error/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/actionable-inline/error/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/actionable-inline/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/notification/actionable-inline/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/actionable-inline/informational/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/actionable-inline/informational/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/actionable-inline/success/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/actionable-inline/success/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/actionable-inline/warning/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/actionable-inline/warning/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/base/index.d.ts +29 -0
- package/lib/typescript/commonjs/src/components/notification/base/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/callout/error/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/callout/error/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/callout/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/notification/callout/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/callout/informational/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/callout/informational/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/callout/success/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/callout/success/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/callout/warning/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/callout/warning/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/callout-inline/error/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/callout-inline/error/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/callout-inline/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/notification/callout-inline/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/callout-inline/informational/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/callout-inline/informational/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/callout-inline/success/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/callout-inline/success/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/callout-inline/warning/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/callout-inline/warning/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/index.d.ts +10 -0
- package/lib/typescript/commonjs/src/components/notification/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/subtitle/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/notification/subtitle/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/subtitle-link/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/notification/subtitle-link/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/toast/error/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/toast/error/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/toast/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/notification/toast/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/toast/informational/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/toast/informational/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/toast/success/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/toast/success/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/toast/warning/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/notification/toast/warning/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/notification/types.d.ts +2 -0
- package/lib/typescript/commonjs/src/components/notification/types.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/radio-button/index.d.ts +32 -0
- package/lib/typescript/commonjs/src/components/radio-button/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/radio-button-group/_item-context.d.ts +8 -0
- package/lib/typescript/commonjs/src/components/radio-button-group/_item-context.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/radio-button-group/_item.d.ts +3 -0
- package/lib/typescript/commonjs/src/components/radio-button-group/_item.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/radio-button-group/_types/index.d.ts +27 -0
- package/lib/typescript/commonjs/src/components/radio-button-group/_types/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/radio-button-group/_types/ref-base.d.ts +9 -0
- package/lib/typescript/commonjs/src/components/radio-button-group/_types/ref-base.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/radio-button-group/index.d.ts +6 -0
- package/lib/typescript/commonjs/src/components/radio-button-group/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/radio-button-input/index.d.ts +22 -0
- package/lib/typescript/commonjs/src/components/radio-button-input/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/switch/index.d.ts +33 -0
- package/lib/typescript/commonjs/src/components/switch/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/text/index.d.ts +8 -0
- package/lib/typescript/commonjs/src/components/text/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/toggle/base/index.d.ts +33 -0
- package/lib/typescript/commonjs/src/components/toggle/base/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/toggle/default/index.d.ts +10 -0
- package/lib/typescript/commonjs/src/components/toggle/default/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/toggle/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/toggle/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/toggle/small/index.d.ts +8 -0
- package/lib/typescript/commonjs/src/components/toggle/small/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/toggle/state.d.ts +2 -0
- package/lib/typescript/commonjs/src/components/toggle/state.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/constants/color/index.d.ts +4 -0
- package/lib/typescript/commonjs/src/constants/color/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/constants/color/tokens/gray-10.d.ts +172 -0
- package/lib/typescript/commonjs/src/constants/color/tokens/gray-10.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/constants/color/tokens/gray-100.d.ts +172 -0
- package/lib/typescript/commonjs/src/constants/color/tokens/gray-100.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/constants/color/tokens/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/constants/color/tokens/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/constants/index.d.ts +6 -0
- package/lib/typescript/commonjs/src/constants/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/constants/motion/index.d.ts +63 -0
- package/lib/typescript/commonjs/src/constants/motion/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/constants/spacing.d.ts +17 -0
- package/lib/typescript/commonjs/src/constants/spacing.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/constants/typography/font-family.d.ts +17 -0
- package/lib/typescript/commonjs/src/constants/typography/font-family.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/constants/typography/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/constants/typography/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/constants/typography/type-sets.d.ts +3 -0
- package/lib/typescript/commonjs/src/constants/typography/type-sets.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/contexts/global-config/context.d.ts +10 -0
- package/lib/typescript/commonjs/src/contexts/global-config/context.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/contexts/global-config/provider.d.ts +6 -0
- package/lib/typescript/commonjs/src/contexts/global-config/provider.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/contexts/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/contexts/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/contexts/theme/context.d.ts +7 -0
- package/lib/typescript/commonjs/src/contexts/theme/context.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/contexts/theme/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/contexts/theme/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/contexts/theme/provider.d.ts +11 -0
- package/lib/typescript/commonjs/src/contexts/theme/provider.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/globals/color-scheme/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/globals/color-scheme/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/globals/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/globals/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/helpers/color/get-color-scheme.d.ts +4 -0
- package/lib/typescript/commonjs/src/helpers/color/get-color-scheme.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/helpers/color/get-color-token.d.ts +3 -0
- package/lib/typescript/commonjs/src/helpers/color/get-color-token.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/helpers/color/hex-to-rgba.d.ts +2 -0
- package/lib/typescript/commonjs/src/helpers/color/hex-to-rgba.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/helpers/color/index.d.ts +4 -0
- package/lib/typescript/commonjs/src/helpers/color/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/helpers/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/helpers/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/index.d.ts +9 -0
- package/lib/typescript/commonjs/src/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/styles/common.d.ts +18 -0
- package/lib/typescript/commonjs/src/styles/common.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/styles/flex.d.ts +75 -0
- package/lib/typescript/commonjs/src/styles/flex.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/styles/index.d.ts +4 -0
- package/lib/typescript/commonjs/src/styles/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/styles/text.d.ts +59 -0
- package/lib/typescript/commonjs/src/styles/text.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/index.d.ts +5 -0
- package/lib/typescript/commonjs/src/types/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/shared.d.ts +2 -0
- package/lib/typescript/commonjs/src/types/shared.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/theme/color-scheme.d.ts +2 -0
- package/lib/typescript/commonjs/src/types/theme/color-scheme.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/theme/color-token.d.ts +2 -0
- package/lib/typescript/commonjs/src/types/theme/color-token.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/theme/index.d.ts +3 -0
- package/lib/typescript/commonjs/src/types/theme/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/types/typography.d.ts +11 -0
- package/lib/typescript/commonjs/src/types/typography.d.ts.map +1 -0
- package/lib/typescript/module/package.json +1 -0
- package/lib/typescript/module/src/_carbon-react-native/index.d.ts +7 -0
- package/lib/typescript/module/src/_carbon-react-native/index.d.ts.map +1 -0
- package/lib/typescript/module/src/_style-sheet/create.d.ts +6 -0
- package/lib/typescript/module/src/_style-sheet/create.d.ts.map +1 -0
- package/lib/typescript/module/src/_style-sheet/index.d.ts +5 -0
- package/lib/typescript/module/src/_style-sheet/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/accordion/_context.d.ts +9 -0
- package/lib/typescript/module/src/components/accordion/_context.d.ts.map +1 -0
- package/lib/typescript/module/src/components/accordion/_header-border.d.ts +10 -0
- package/lib/typescript/module/src/components/accordion/_header-border.d.ts.map +1 -0
- package/lib/typescript/module/src/components/accordion/_header.d.ts +13 -0
- package/lib/typescript/module/src/components/accordion/_header.d.ts.map +1 -0
- package/lib/typescript/module/src/components/accordion/_item.d.ts +23 -0
- package/lib/typescript/module/src/components/accordion/_item.d.ts.map +1 -0
- package/lib/typescript/module/src/components/accordion/_motion.d.ts +3 -0
- package/lib/typescript/module/src/components/accordion/_motion.d.ts.map +1 -0
- package/lib/typescript/module/src/components/accordion/_styles.d.ts +16 -0
- package/lib/typescript/module/src/components/accordion/_styles.d.ts.map +1 -0
- package/lib/typescript/module/src/components/accordion/index.d.ts +16 -0
- package/lib/typescript/module/src/components/accordion/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/accordion/types.d.ts +2 -0
- package/lib/typescript/module/src/components/accordion/types.d.ts.map +1 -0
- package/lib/typescript/module/src/components/button/base/index.d.ts +37 -0
- package/lib/typescript/module/src/components/button/base/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/button/base-color/index.d.ts +21 -0
- package/lib/typescript/module/src/components/button/base-color/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/button/ghost/index.d.ts +5 -0
- package/lib/typescript/module/src/components/button/ghost/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/button/ghost-danger/index.d.ts +5 -0
- package/lib/typescript/module/src/components/button/ghost-danger/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/button/ghost-icon/index.d.ts +8 -0
- package/lib/typescript/module/src/components/button/ghost-icon/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/button/index.d.ts +12 -0
- package/lib/typescript/module/src/components/button/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/button/primary/index.d.ts +5 -0
- package/lib/typescript/module/src/components/button/primary/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/button/primary-danger/index.d.ts +5 -0
- package/lib/typescript/module/src/components/button/primary-danger/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/button/secondary/index.d.ts +5 -0
- package/lib/typescript/module/src/components/button/secondary/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/button/size.d.ts +2 -0
- package/lib/typescript/module/src/components/button/size.d.ts.map +1 -0
- package/lib/typescript/module/src/components/button/tertiary/index.d.ts +5 -0
- package/lib/typescript/module/src/components/button/tertiary/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/button/tertiary-danger/index.d.ts +5 -0
- package/lib/typescript/module/src/components/button/tertiary-danger/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/checkbox/index.d.ts +32 -0
- package/lib/typescript/module/src/components/checkbox/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/checkbox-group/index.d.ts +21 -0
- package/lib/typescript/module/src/components/checkbox-group/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/checkbox-input/index.d.ts +25 -0
- package/lib/typescript/module/src/components/checkbox-input/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/collapsible/index.d.ts +26 -0
- package/lib/typescript/module/src/components/collapsible/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/form-helper-text/index.d.ts +11 -0
- package/lib/typescript/module/src/components/form-helper-text/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/form-label/index.d.ts +10 -0
- package/lib/typescript/module/src/components/form-label/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/icon/index.d.ts +13 -0
- package/lib/typescript/module/src/components/icon/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/index.d.ts +18 -0
- package/lib/typescript/module/src/components/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_status-hooks/_base.d.ts +28 -0
- package/lib/typescript/module/src/components/notification/_status-hooks/_base.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_status-hooks/error/index.d.ts +11 -0
- package/lib/typescript/module/src/components/notification/_status-hooks/error/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_status-hooks/index.d.ts +5 -0
- package/lib/typescript/module/src/components/notification/_status-hooks/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_status-hooks/informational/index.d.ts +11 -0
- package/lib/typescript/module/src/components/notification/_status-hooks/informational/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_status-hooks/success/index.d.ts +11 -0
- package/lib/typescript/module/src/components/notification/_status-hooks/success/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_status-hooks/warning/index.d.ts +11 -0
- package/lib/typescript/module/src/components/notification/_status-hooks/warning/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_variant-context.d.ts +10 -0
- package/lib/typescript/module/src/components/notification/_variant-context.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_variants/_button-ghost.d.ts +7 -0
- package/lib/typescript/module/src/components/notification/_variants/_button-ghost.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_variants/_button-tertiary.d.ts +7 -0
- package/lib/typescript/module/src/components/notification/_variants/_button-tertiary.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_variants/actionable/index.d.ts +30 -0
- package/lib/typescript/module/src/components/notification/_variants/actionable/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_variants/actionable-inline/index.d.ts +30 -0
- package/lib/typescript/module/src/components/notification/_variants/actionable-inline/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_variants/callout/index.d.ts +13 -0
- package/lib/typescript/module/src/components/notification/_variants/callout/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_variants/callout-inline/index.d.ts +13 -0
- package/lib/typescript/module/src/components/notification/_variants/callout-inline/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_variants/index.d.ts +6 -0
- package/lib/typescript/module/src/components/notification/_variants/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/_variants/toast/index.d.ts +17 -0
- package/lib/typescript/module/src/components/notification/_variants/toast/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/actionable/error/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/actionable/error/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/actionable/index.d.ts +5 -0
- package/lib/typescript/module/src/components/notification/actionable/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/actionable/informational/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/actionable/informational/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/actionable/success/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/actionable/success/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/actionable/warning/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/actionable/warning/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/actionable-inline/error/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/actionable-inline/error/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/actionable-inline/index.d.ts +5 -0
- package/lib/typescript/module/src/components/notification/actionable-inline/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/actionable-inline/informational/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/actionable-inline/informational/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/actionable-inline/success/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/actionable-inline/success/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/actionable-inline/warning/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/actionable-inline/warning/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/base/index.d.ts +29 -0
- package/lib/typescript/module/src/components/notification/base/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/callout/error/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/callout/error/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/callout/index.d.ts +5 -0
- package/lib/typescript/module/src/components/notification/callout/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/callout/informational/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/callout/informational/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/callout/success/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/callout/success/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/callout/warning/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/callout/warning/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/callout-inline/error/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/callout-inline/error/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/callout-inline/index.d.ts +5 -0
- package/lib/typescript/module/src/components/notification/callout-inline/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/callout-inline/informational/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/callout-inline/informational/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/callout-inline/success/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/callout-inline/success/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/callout-inline/warning/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/callout-inline/warning/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/index.d.ts +10 -0
- package/lib/typescript/module/src/components/notification/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/subtitle/index.d.ts +5 -0
- package/lib/typescript/module/src/components/notification/subtitle/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/subtitle-link/index.d.ts +5 -0
- package/lib/typescript/module/src/components/notification/subtitle-link/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/toast/error/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/toast/error/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/toast/index.d.ts +5 -0
- package/lib/typescript/module/src/components/notification/toast/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/toast/informational/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/toast/informational/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/toast/success/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/toast/success/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/toast/warning/index.d.ts +9 -0
- package/lib/typescript/module/src/components/notification/toast/warning/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/notification/types.d.ts +2 -0
- package/lib/typescript/module/src/components/notification/types.d.ts.map +1 -0
- package/lib/typescript/module/src/components/radio-button/index.d.ts +32 -0
- package/lib/typescript/module/src/components/radio-button/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/radio-button-group/_item-context.d.ts +8 -0
- package/lib/typescript/module/src/components/radio-button-group/_item-context.d.ts.map +1 -0
- package/lib/typescript/module/src/components/radio-button-group/_item.d.ts +3 -0
- package/lib/typescript/module/src/components/radio-button-group/_item.d.ts.map +1 -0
- package/lib/typescript/module/src/components/radio-button-group/_types/index.d.ts +27 -0
- package/lib/typescript/module/src/components/radio-button-group/_types/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/radio-button-group/_types/ref-base.d.ts +9 -0
- package/lib/typescript/module/src/components/radio-button-group/_types/ref-base.d.ts.map +1 -0
- package/lib/typescript/module/src/components/radio-button-group/index.d.ts +6 -0
- package/lib/typescript/module/src/components/radio-button-group/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/radio-button-input/index.d.ts +22 -0
- package/lib/typescript/module/src/components/radio-button-input/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/switch/index.d.ts +33 -0
- package/lib/typescript/module/src/components/switch/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/text/index.d.ts +8 -0
- package/lib/typescript/module/src/components/text/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/toggle/base/index.d.ts +33 -0
- package/lib/typescript/module/src/components/toggle/base/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/toggle/default/index.d.ts +10 -0
- package/lib/typescript/module/src/components/toggle/default/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/toggle/index.d.ts +5 -0
- package/lib/typescript/module/src/components/toggle/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/toggle/small/index.d.ts +8 -0
- package/lib/typescript/module/src/components/toggle/small/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/toggle/state.d.ts +2 -0
- package/lib/typescript/module/src/components/toggle/state.d.ts.map +1 -0
- package/lib/typescript/module/src/constants/color/index.d.ts +4 -0
- package/lib/typescript/module/src/constants/color/index.d.ts.map +1 -0
- package/lib/typescript/module/src/constants/color/tokens/gray-10.d.ts +172 -0
- package/lib/typescript/module/src/constants/color/tokens/gray-10.d.ts.map +1 -0
- package/lib/typescript/module/src/constants/color/tokens/gray-100.d.ts +172 -0
- package/lib/typescript/module/src/constants/color/tokens/gray-100.d.ts.map +1 -0
- package/lib/typescript/module/src/constants/color/tokens/index.d.ts +3 -0
- package/lib/typescript/module/src/constants/color/tokens/index.d.ts.map +1 -0
- package/lib/typescript/module/src/constants/index.d.ts +6 -0
- package/lib/typescript/module/src/constants/index.d.ts.map +1 -0
- package/lib/typescript/module/src/constants/motion/index.d.ts +63 -0
- package/lib/typescript/module/src/constants/motion/index.d.ts.map +1 -0
- package/lib/typescript/module/src/constants/spacing.d.ts +17 -0
- package/lib/typescript/module/src/constants/spacing.d.ts.map +1 -0
- package/lib/typescript/module/src/constants/typography/font-family.d.ts +17 -0
- package/lib/typescript/module/src/constants/typography/font-family.d.ts.map +1 -0
- package/lib/typescript/module/src/constants/typography/index.d.ts +3 -0
- package/lib/typescript/module/src/constants/typography/index.d.ts.map +1 -0
- package/lib/typescript/module/src/constants/typography/type-sets.d.ts +3 -0
- package/lib/typescript/module/src/constants/typography/type-sets.d.ts.map +1 -0
- package/lib/typescript/module/src/contexts/global-config/context.d.ts +10 -0
- package/lib/typescript/module/src/contexts/global-config/context.d.ts.map +1 -0
- package/lib/typescript/module/src/contexts/global-config/provider.d.ts +6 -0
- package/lib/typescript/module/src/contexts/global-config/provider.d.ts.map +1 -0
- package/lib/typescript/module/src/contexts/index.d.ts +3 -0
- package/lib/typescript/module/src/contexts/index.d.ts.map +1 -0
- package/lib/typescript/module/src/contexts/theme/context.d.ts +7 -0
- package/lib/typescript/module/src/contexts/theme/context.d.ts.map +1 -0
- package/lib/typescript/module/src/contexts/theme/index.d.ts +3 -0
- package/lib/typescript/module/src/contexts/theme/index.d.ts.map +1 -0
- package/lib/typescript/module/src/contexts/theme/provider.d.ts +11 -0
- package/lib/typescript/module/src/contexts/theme/provider.d.ts.map +1 -0
- package/lib/typescript/module/src/globals/color-scheme/index.d.ts +5 -0
- package/lib/typescript/module/src/globals/color-scheme/index.d.ts.map +1 -0
- package/lib/typescript/module/src/globals/index.d.ts +3 -0
- package/lib/typescript/module/src/globals/index.d.ts.map +1 -0
- package/lib/typescript/module/src/helpers/color/get-color-scheme.d.ts +4 -0
- package/lib/typescript/module/src/helpers/color/get-color-scheme.d.ts.map +1 -0
- package/lib/typescript/module/src/helpers/color/get-color-token.d.ts +3 -0
- package/lib/typescript/module/src/helpers/color/get-color-token.d.ts.map +1 -0
- package/lib/typescript/module/src/helpers/color/hex-to-rgba.d.ts +2 -0
- package/lib/typescript/module/src/helpers/color/hex-to-rgba.d.ts.map +1 -0
- package/lib/typescript/module/src/helpers/color/index.d.ts +4 -0
- package/lib/typescript/module/src/helpers/color/index.d.ts.map +1 -0
- package/lib/typescript/module/src/helpers/index.d.ts +3 -0
- package/lib/typescript/module/src/helpers/index.d.ts.map +1 -0
- package/lib/typescript/module/src/index.d.ts +9 -0
- package/lib/typescript/module/src/index.d.ts.map +1 -0
- package/lib/typescript/module/src/styles/common.d.ts +18 -0
- package/lib/typescript/module/src/styles/common.d.ts.map +1 -0
- package/lib/typescript/module/src/styles/flex.d.ts +75 -0
- package/lib/typescript/module/src/styles/flex.d.ts.map +1 -0
- package/lib/typescript/module/src/styles/index.d.ts +4 -0
- package/lib/typescript/module/src/styles/index.d.ts.map +1 -0
- package/lib/typescript/module/src/styles/text.d.ts +59 -0
- package/lib/typescript/module/src/styles/text.d.ts.map +1 -0
- package/lib/typescript/module/src/types/index.d.ts +5 -0
- package/lib/typescript/module/src/types/index.d.ts.map +1 -0
- package/lib/typescript/module/src/types/shared.d.ts +2 -0
- package/lib/typescript/module/src/types/shared.d.ts.map +1 -0
- package/lib/typescript/module/src/types/theme/color-scheme.d.ts +2 -0
- package/lib/typescript/module/src/types/theme/color-scheme.d.ts.map +1 -0
- package/lib/typescript/module/src/types/theme/color-token.d.ts +2 -0
- package/lib/typescript/module/src/types/theme/color-token.d.ts.map +1 -0
- package/lib/typescript/module/src/types/theme/index.d.ts +3 -0
- package/lib/typescript/module/src/types/theme/index.d.ts.map +1 -0
- package/lib/typescript/module/src/types/typography.d.ts +11 -0
- package/lib/typescript/module/src/types/typography.d.ts.map +1 -0
- package/package.json +73 -0
- package/src/_carbon-react-native/index.tsx +37 -0
- package/src/_style-sheet/create.ts +145 -0
- package/src/_style-sheet/index.ts +9 -0
- package/src/components/accordion/_context.tsx +19 -0
- package/src/components/accordion/_header-border.tsx +68 -0
- package/src/components/accordion/_header.tsx +269 -0
- package/src/components/accordion/_item.tsx +186 -0
- package/src/components/accordion/_motion.ts +27 -0
- package/src/components/accordion/_styles.ts +24 -0
- package/src/components/accordion/index.tsx +152 -0
- package/src/components/accordion/types.ts +4 -0
- package/src/components/button/base/index.tsx +270 -0
- package/src/components/button/base-color/index.tsx +277 -0
- package/src/components/button/ghost/index.tsx +132 -0
- package/src/components/button/ghost-danger/index.tsx +132 -0
- package/src/components/button/ghost-icon/index.tsx +125 -0
- package/src/components/button/index.tsx +11 -0
- package/src/components/button/primary/index.tsx +108 -0
- package/src/components/button/primary-danger/index.tsx +108 -0
- package/src/components/button/secondary/index.tsx +108 -0
- package/src/components/button/size.ts +7 -0
- package/src/components/button/tertiary/index.tsx +125 -0
- package/src/components/button/tertiary-danger/index.tsx +125 -0
- package/src/components/checkbox/index.tsx +239 -0
- package/src/components/checkbox-group/index.tsx +197 -0
- package/src/components/checkbox-input/index.tsx +368 -0
- package/src/components/collapsible/index.tsx +289 -0
- package/src/components/form-helper-text/index.tsx +84 -0
- package/src/components/form-label/index.tsx +66 -0
- package/src/components/icon/index.tsx +53 -0
- package/src/components/index.tsx +23 -0
- package/src/components/notification/_status-hooks/_base.tsx +97 -0
- package/src/components/notification/_status-hooks/error/index.tsx +61 -0
- package/src/components/notification/_status-hooks/index.tsx +4 -0
- package/src/components/notification/_status-hooks/informational/index.tsx +61 -0
- package/src/components/notification/_status-hooks/success/index.tsx +61 -0
- package/src/components/notification/_status-hooks/warning/index.tsx +61 -0
- package/src/components/notification/_variant-context.tsx +35 -0
- package/src/components/notification/_variants/_button-ghost.tsx +65 -0
- package/src/components/notification/_variants/_button-tertiary.tsx +65 -0
- package/src/components/notification/_variants/actionable/index.tsx +105 -0
- package/src/components/notification/_variants/actionable-inline/index.tsx +105 -0
- package/src/components/notification/_variants/callout/index.tsx +76 -0
- package/src/components/notification/_variants/callout-inline/index.tsx +76 -0
- package/src/components/notification/_variants/index.tsx +5 -0
- package/src/components/notification/_variants/toast/index.tsx +135 -0
- package/src/components/notification/actionable/error/index.tsx +86 -0
- package/src/components/notification/actionable/index.tsx +4 -0
- package/src/components/notification/actionable/informational/index.tsx +86 -0
- package/src/components/notification/actionable/success/index.tsx +86 -0
- package/src/components/notification/actionable/warning/index.tsx +86 -0
- package/src/components/notification/actionable-inline/error/index.tsx +85 -0
- package/src/components/notification/actionable-inline/index.tsx +4 -0
- package/src/components/notification/actionable-inline/informational/index.tsx +85 -0
- package/src/components/notification/actionable-inline/success/index.tsx +85 -0
- package/src/components/notification/actionable-inline/warning/index.tsx +85 -0
- package/src/components/notification/base/index.tsx +319 -0
- package/src/components/notification/callout/error/index.tsx +86 -0
- package/src/components/notification/callout/index.tsx +4 -0
- package/src/components/notification/callout/informational/index.tsx +86 -0
- package/src/components/notification/callout/success/index.tsx +86 -0
- package/src/components/notification/callout/warning/index.tsx +86 -0
- package/src/components/notification/callout-inline/error/index.tsx +85 -0
- package/src/components/notification/callout-inline/index.tsx +4 -0
- package/src/components/notification/callout-inline/informational/index.tsx +85 -0
- package/src/components/notification/callout-inline/success/index.tsx +85 -0
- package/src/components/notification/callout-inline/warning/index.tsx +85 -0
- package/src/components/notification/index.tsx +17 -0
- package/src/components/notification/subtitle/index.tsx +58 -0
- package/src/components/notification/subtitle-link/index.tsx +57 -0
- package/src/components/notification/toast/error/index.tsx +86 -0
- package/src/components/notification/toast/index.tsx +4 -0
- package/src/components/notification/toast/informational/index.tsx +86 -0
- package/src/components/notification/toast/success/index.tsx +86 -0
- package/src/components/notification/toast/warning/index.tsx +86 -0
- package/src/components/notification/types.ts +3 -0
- package/src/components/radio-button/index.tsx +238 -0
- package/src/components/radio-button-group/_item-context.tsx +15 -0
- package/src/components/radio-button-group/_item.tsx +91 -0
- package/src/components/radio-button-group/_types/index.ts +55 -0
- package/src/components/radio-button-group/_types/ref-base.ts +11 -0
- package/src/components/radio-button-group/index.tsx +251 -0
- package/src/components/radio-button-input/index.tsx +366 -0
- package/src/components/switch/index.tsx +448 -0
- package/src/components/text/index.tsx +135 -0
- package/src/components/toggle/base/index.tsx +254 -0
- package/src/components/toggle/default/index.tsx +41 -0
- package/src/components/toggle/index.tsx +4 -0
- package/src/components/toggle/small/index.tsx +39 -0
- package/src/components/toggle/state.ts +4 -0
- package/src/constants/color/code.json +273 -0
- package/src/constants/color/index.ts +7 -0
- package/src/constants/color/tokens/gray-10.ts +197 -0
- package/src/constants/color/tokens/gray-100.ts +197 -0
- package/src/constants/color/tokens/index.ts +2 -0
- package/src/constants/index.ts +11 -0
- package/src/constants/motion/index.ts +34 -0
- package/src/constants/spacing.ts +17 -0
- package/src/constants/typography/font-family.ts +16 -0
- package/src/constants/typography/index.ts +2 -0
- package/src/constants/typography/type-sets.ts +151 -0
- package/src/contexts/global-config/context.ts +20 -0
- package/src/contexts/global-config/provider.tsx +26 -0
- package/src/contexts/index.tsx +2 -0
- package/src/contexts/theme/context.ts +26 -0
- package/src/contexts/theme/index.tsx +5 -0
- package/src/contexts/theme/provider.tsx +55 -0
- package/src/globals/color-scheme/index.ts +13 -0
- package/src/globals/index.ts +5 -0
- package/src/helpers/color/get-color-scheme.ts +19 -0
- package/src/helpers/color/get-color-token.ts +14 -0
- package/src/helpers/color/hex-to-rgba.ts +11 -0
- package/src/helpers/color/index.ts +3 -0
- package/src/helpers/index.ts +5 -0
- package/src/index.tsx +9 -0
- package/src/styles/common.ts +21 -0
- package/src/styles/flex.ts +78 -0
- package/src/styles/index.ts +3 -0
- package/src/styles/text.ts +66 -0
- package/src/types/@carbon/icons/index.d.ts +1 -0
- package/src/types/index.ts +9 -0
- package/src/types/shared.ts +1 -0
- package/src/types/theme/color-scheme.ts +1 -0
- package/src/types/theme/color-token.ts +170 -0
- package/src/types/theme/index.ts +2 -0
- package/src/types/typography.ts +36 -0
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { forwardRef, useCallback, useContext, useImperativeHandle, useRef } from 'react';
|
|
4
|
+
import { Pressable, StyleSheet, View } from 'react-native';
|
|
5
|
+
import { SpacingConstant } from "../../constants/index.js";
|
|
6
|
+
import { ThemeContext } from "../../contexts/index.js";
|
|
7
|
+
import { CommonStyle, FlexStyle } from "../../styles/index.js";
|
|
8
|
+
import { FormLabel } from "../form-label/index.js";
|
|
9
|
+
import { RadioButtonInput } from "../radio-button-input/index.js";
|
|
10
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
11
|
+
export const RadioButton = /*#__PURE__*/forwardRef(function RadioButton({
|
|
12
|
+
controlled,
|
|
13
|
+
checked,
|
|
14
|
+
value,
|
|
15
|
+
interactiveState = 'normal',
|
|
16
|
+
label,
|
|
17
|
+
role = 'radio',
|
|
18
|
+
'aria-label': ariaLabel,
|
|
19
|
+
onChange,
|
|
20
|
+
onPress,
|
|
21
|
+
radioButtonInputProps,
|
|
22
|
+
formLabelProps,
|
|
23
|
+
pressableProps,
|
|
24
|
+
style,
|
|
25
|
+
...props
|
|
26
|
+
}, forwardedRef) {
|
|
27
|
+
const themeContext = useContext(ThemeContext),
|
|
28
|
+
radioButtonInputRef = useRef(null),
|
|
29
|
+
viewRef = useRef(null),
|
|
30
|
+
pressHandler = useCallback(event => {
|
|
31
|
+
onPress?.(event);
|
|
32
|
+
radioButtonInputRef.current?.setChecked(true);
|
|
33
|
+
}, [onPress]);
|
|
34
|
+
useImperativeHandle(forwardedRef, () => {
|
|
35
|
+
return Object.assign(viewRef.current ?? {}, {
|
|
36
|
+
get checked() {
|
|
37
|
+
return radioButtonInputRef.current.checked;
|
|
38
|
+
},
|
|
39
|
+
setChecked(checked_) {
|
|
40
|
+
radioButtonInputRef.current?.setChecked(checked_);
|
|
41
|
+
}
|
|
42
|
+
});
|
|
43
|
+
}, []);
|
|
44
|
+
return /*#__PURE__*/_jsxs(View, {
|
|
45
|
+
...props,
|
|
46
|
+
"aria-label": ariaLabel || label,
|
|
47
|
+
style: [FlexStyle.flex_row, style],
|
|
48
|
+
ref: viewRef,
|
|
49
|
+
children: [/*#__PURE__*/_jsx(Pressable, {
|
|
50
|
+
...pressableProps,
|
|
51
|
+
role: role,
|
|
52
|
+
disabled: interactiveState === 'disabled',
|
|
53
|
+
"aria-label": pressableProps?.['aria-label'] ?? label,
|
|
54
|
+
onPress: pressHandler,
|
|
55
|
+
style: [CommonStyle.absolute, CommonStyle.w_full, CommonStyle.h_full, baseStyle.pressable, pressableProps?.style]
|
|
56
|
+
}), /*#__PURE__*/_jsx(RadioButtonInput, {
|
|
57
|
+
...radioButtonInputProps,
|
|
58
|
+
role: "none",
|
|
59
|
+
controlled: controlled,
|
|
60
|
+
checked: checked,
|
|
61
|
+
value: value,
|
|
62
|
+
interactiveState: interactiveState,
|
|
63
|
+
onChange: onChange,
|
|
64
|
+
onPress: onPress,
|
|
65
|
+
style: [baseStyle.radioButtonInput, radioButtonInputProps?.style],
|
|
66
|
+
ref: radioButtonInputRef
|
|
67
|
+
}), /*#__PURE__*/_jsx(FormLabel, {
|
|
68
|
+
...formLabelProps,
|
|
69
|
+
label: label,
|
|
70
|
+
textProps: {
|
|
71
|
+
...formLabelProps?.textProps,
|
|
72
|
+
type: formLabelProps?.textProps?.type || 'body_compact_01',
|
|
73
|
+
style: [getTextColorStyle(interactiveState, themeContext.color), formLabelProps?.textProps?.style]
|
|
74
|
+
},
|
|
75
|
+
style: [baseStyle.label, formLabelProps?.style]
|
|
76
|
+
})]
|
|
77
|
+
});
|
|
78
|
+
});
|
|
79
|
+
const baseStyle = StyleSheet.create({
|
|
80
|
+
pressable: {
|
|
81
|
+
zIndex: 1
|
|
82
|
+
},
|
|
83
|
+
radioButtonInput: {
|
|
84
|
+
zIndex: 2
|
|
85
|
+
},
|
|
86
|
+
label: {
|
|
87
|
+
marginLeft: SpacingConstant.spacing_03
|
|
88
|
+
}
|
|
89
|
+
}),
|
|
90
|
+
mapTextColor = {
|
|
91
|
+
normal: 'text_primary',
|
|
92
|
+
disabled: 'text_disabled',
|
|
93
|
+
error: 'text_primary',
|
|
94
|
+
read_only: 'text_primary',
|
|
95
|
+
warning: 'text_primary'
|
|
96
|
+
};
|
|
97
|
+
function getTextColorStyle(interactiveState, color) {
|
|
98
|
+
return {
|
|
99
|
+
color: color[mapTextColor[interactiveState]]
|
|
100
|
+
};
|
|
101
|
+
}
|
|
102
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["forwardRef","useCallback","useContext","useImperativeHandle","useRef","Pressable","StyleSheet","View","SpacingConstant","ThemeContext","CommonStyle","FlexStyle","FormLabel","RadioButtonInput","jsx","_jsx","jsxs","_jsxs","RadioButton","controlled","checked","value","interactiveState","label","role","ariaLabel","onChange","onPress","radioButtonInputProps","formLabelProps","pressableProps","style","props","forwardedRef","themeContext","radioButtonInputRef","viewRef","pressHandler","event","current","setChecked","Object","assign","checked_","flex_row","ref","children","disabled","absolute","w_full","h_full","baseStyle","pressable","radioButtonInput","textProps","type","getTextColorStyle","color","create","zIndex","marginLeft","spacing_03","mapTextColor","normal","error","read_only","warning"],"sourceRoot":"../../../../src","sources":["components/radio-button/index.tsx"],"mappings":";;AAAA,SACCA,UAAU,EACVC,WAAW,EACXC,UAAU,EACVC,mBAAmB,EACnBC,MAAM,QACA,OAAO;AAEd,SACCC,SAAS,EACTC,UAAU,EACVC,IAAI,QAIE,cAAc;AAErB,SACCC,eAAe,QACT,0BAAiB;AAExB,SACCC,YAAY,QACN,yBAAgB;AAEvB,SACCC,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K,EACfM,cAAc,EAAEE,KAAK;IACnB,CACH,CAAC;EAAA,CACG,CAAC;AAGT,CACD,CAAC;AAED,MACCoB,SAAS,GACR7C,UAAU,CAACoD,MAAM,CAAC;IACjBN,SAAS,EAAE;MACVO,MAAM,EAAE;IACT,CAAC;IACDN,gBAAgB,EAAE;MACjBM,MAAM,EAAE;IACT,CAAC;IACDpC,KAAK,EAAE;MACNqC,UAAU,EAAEpD,eAAe,CAACqD;IAC7B;EACD,CAAC,CAAC;EAEHC,YAGC,GACA;IACCC,MAAM,EAAE,cAAc;IACtBhB,QAAQ,EAAE,eAAe;IACzBiB,KAAK,EAAE,cAAc;IACrBC,SAAS,EAAE,cAAc;IACzBC,OAAO,EAAE;EACV,CAAC;AAEH,SAASV,iBAAiBA,CACzBlC,gBAAkD,EAClDmC,KAA4B,EAChB;EACZ,OAAO;IACNA,KAAK,EAAEA,KAAK,CAACK,YAAY,CAACxC,gBAAgB,CAAC;EAC5C,CAAC;AACF","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["createContext","RadioButtonGroupItemContext"],"sourceRoot":"../../../../src","sources":["components/radio-button-group/_item-context.tsx"],"mappings":";;AAAA,SACCA,aAAa,QACP,OAAO;AAYd,OAAO,MAAMC,2BAA2B,gBAAGD,aAAa,CAA8B,CAAC,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { forwardRef, useCallback, useContext, useImperativeHandle, useRef } from 'react';
|
|
4
|
+
import { RadioButton } from "../radio-button/index.js";
|
|
5
|
+
import { RadioButtonGroupItemContext } from "./_item-context.js";
|
|
6
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
7
|
+
export const RadioButtonGroupItem = /*#__PURE__*/forwardRef(function RadioButtonGroupItem({
|
|
8
|
+
value: valueProp,
|
|
9
|
+
onPress,
|
|
10
|
+
...props
|
|
11
|
+
}, forwardedRef) {
|
|
12
|
+
const {
|
|
13
|
+
controlled,
|
|
14
|
+
value,
|
|
15
|
+
setValue
|
|
16
|
+
} = useContext(RadioButtonGroupItemContext),
|
|
17
|
+
radioButtonRef = useRef(null),
|
|
18
|
+
pressHandler = useCallback(event => {
|
|
19
|
+
onPress?.(event);
|
|
20
|
+
if (!controlled) {
|
|
21
|
+
setValue?.(valueProp);
|
|
22
|
+
}
|
|
23
|
+
}, [controlled, valueProp, setValue, onPress]);
|
|
24
|
+
useImperativeHandle(forwardedRef, () => {
|
|
25
|
+
return Object.assign(radioButtonRef.current ?? {}, {
|
|
26
|
+
setChecked(checkedParam) {
|
|
27
|
+
if (!controlled) {
|
|
28
|
+
let checked;
|
|
29
|
+
if (typeof checkedParam === 'boolean') {
|
|
30
|
+
checked = checkedParam;
|
|
31
|
+
} else {
|
|
32
|
+
checked = checkedParam(!!radioButtonRef.current?.checked);
|
|
33
|
+
}
|
|
34
|
+
setValue?.(checked ? valueProp : undefined);
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
});
|
|
38
|
+
}, [controlled, valueProp, setValue]);
|
|
39
|
+
return /*#__PURE__*/_jsx(RadioButton, {
|
|
40
|
+
...props,
|
|
41
|
+
value: value,
|
|
42
|
+
controlled: true,
|
|
43
|
+
checked: value === valueProp,
|
|
44
|
+
onPress: pressHandler,
|
|
45
|
+
ref: radioButtonRef
|
|
46
|
+
});
|
|
47
|
+
});
|
|
48
|
+
//# sourceMappingURL=_item.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["forwardRef","useCallback","useContext","useImperativeHandle","useRef","RadioButton","RadioButtonGroupItemContext","jsx","_jsx","RadioButtonGroupItem","value","valueProp","onPress","props","forwardedRef","controlled","setValue","radioButtonRef","pressHandler","event","Object","assign","current","setChecked","checkedParam","checked","undefined","ref"],"sourceRoot":"../../../../src","sources":["components/radio-button-group/_item.tsx"],"mappings":";;AAAA,SACCA,UAAU,EACVC,WAAW,EACXC,UAAU,E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NQ,KAAK;IACVH,KAAK,EAAGA,KAAO;IACfK,UAAU;IACVU,OAAO,EAAGf,KAAK,KAAKC,SAAW;IAC/BC,OAAO,EAAGM,YAAc;IACxBS,GAAG,EAAGV;EAAgB,CACtB,CAAC;AAGJ,CACD,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../../../../src","sources":["components/radio-button-group/_types/index.ts"],"mappings":"","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":[],"sourceRoot":"../../../../../src","sources":["components/radio-button-group/_types/ref-base.ts"],"mappings":"","ignoreList":[]}
|
|
@@ -0,0 +1,136 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { forwardRef, useContext, useEffect, useImperativeHandle, useRef, useState } from 'react';
|
|
4
|
+
import { StyleSheet, View } from 'react-native';
|
|
5
|
+
import IconWarningAltFilled from '@carbon/icons/es/warning--alt--filled/16';
|
|
6
|
+
import IconWarningFilled from '@carbon/icons/es/warning--filled/16';
|
|
7
|
+
import { SpacingConstant } from "../../constants/index.js";
|
|
8
|
+
import { ThemeContext } from "../../contexts/index.js";
|
|
9
|
+
import { FlexStyle } from "../../styles/index.js";
|
|
10
|
+
import { FormHelperText } from "../form-helper-text/index.js";
|
|
11
|
+
import { FormLabel } from "../form-label/index.js";
|
|
12
|
+
import { Icon } from "../icon/index.js";
|
|
13
|
+
import { RadioButtonGroupItemContext } from "./_item-context.js";
|
|
14
|
+
import { RadioButtonGroupItem } from "./_item.js";
|
|
15
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
16
|
+
const Component = /*#__PURE__*/forwardRef(function RadioButtonGroup({
|
|
17
|
+
controlled,
|
|
18
|
+
selectedValue: selectedValueProp,
|
|
19
|
+
orientation = 'vertical',
|
|
20
|
+
legend,
|
|
21
|
+
helperText,
|
|
22
|
+
helperTextMode = 'normal',
|
|
23
|
+
helperTextModeIcon = true,
|
|
24
|
+
onChange,
|
|
25
|
+
formHelperTextProps,
|
|
26
|
+
children,
|
|
27
|
+
role = 'radiogroup',
|
|
28
|
+
style,
|
|
29
|
+
...props
|
|
30
|
+
}, forwardedRef) {
|
|
31
|
+
const viewRef = useRef(null),
|
|
32
|
+
ref = useRef({
|
|
33
|
+
isMounted: false,
|
|
34
|
+
selectedValue: selectedValueProp
|
|
35
|
+
}),
|
|
36
|
+
[selectedValueSelf, setSelectedValueSelf] = useState(selectedValueProp),
|
|
37
|
+
selectedValue = controlled ? selectedValueProp : selectedValueSelf;
|
|
38
|
+
useEffect(() => {
|
|
39
|
+
if (!ref.current.isMounted) {
|
|
40
|
+
ref.current.isMounted = true;
|
|
41
|
+
} else {
|
|
42
|
+
ref.current.selectedValue = selectedValue;
|
|
43
|
+
onChange?.(selectedValue);
|
|
44
|
+
}
|
|
45
|
+
}, [selectedValue, onChange]);
|
|
46
|
+
useImperativeHandle(forwardedRef, () => {
|
|
47
|
+
return Object.assign(viewRef.current ?? {}, {
|
|
48
|
+
get selectedValue() {
|
|
49
|
+
return ref.current.selectedValue;
|
|
50
|
+
},
|
|
51
|
+
setSelectedValue(valueParam) {
|
|
52
|
+
if (!controlled) {
|
|
53
|
+
if (typeof valueParam !== 'function') {
|
|
54
|
+
setSelectedValueSelf(valueParam);
|
|
55
|
+
} else {
|
|
56
|
+
setSelectedValueSelf(valueParam(ref.current.selectedValue));
|
|
57
|
+
}
|
|
58
|
+
}
|
|
59
|
+
}
|
|
60
|
+
});
|
|
61
|
+
}, [controlled]);
|
|
62
|
+
return /*#__PURE__*/_jsxs(View, {
|
|
63
|
+
...props,
|
|
64
|
+
role: role,
|
|
65
|
+
style: style,
|
|
66
|
+
ref: viewRef,
|
|
67
|
+
children: [/*#__PURE__*/_jsx(FormLabel, {
|
|
68
|
+
label: legend,
|
|
69
|
+
style: baseStyle.legend
|
|
70
|
+
}), /*#__PURE__*/_jsx(View, {
|
|
71
|
+
style: [baseStyle.wrapper, wrapperOrientationStyle[orientation]],
|
|
72
|
+
children: /*#__PURE__*/_jsx(RadioButtonGroupItemContext.Provider, {
|
|
73
|
+
value: {
|
|
74
|
+
controlled,
|
|
75
|
+
value: selectedValue,
|
|
76
|
+
setValue: setSelectedValueSelf
|
|
77
|
+
},
|
|
78
|
+
children: children
|
|
79
|
+
})
|
|
80
|
+
}), !!helperText && /*#__PURE__*/_jsx(FormHelperText, {
|
|
81
|
+
...formHelperTextProps,
|
|
82
|
+
error: helperTextMode === 'error',
|
|
83
|
+
text: helperText,
|
|
84
|
+
textLeading: helperTextModeIcon && helperTextMode === 'error' ? /*#__PURE__*/_jsx(IconErrorRenderer, {}) : helperTextModeIcon && helperTextMode === 'warning' ? /*#__PURE__*/_jsx(IconWarningRenderer, {}) : formHelperTextProps?.textLeading,
|
|
85
|
+
style: [baseStyle.formHelperText, formHelperTextProps?.style]
|
|
86
|
+
})]
|
|
87
|
+
});
|
|
88
|
+
});
|
|
89
|
+
export const RadioButtonGroup = Object.assign(Component, {
|
|
90
|
+
Item: RadioButtonGroupItem
|
|
91
|
+
});
|
|
92
|
+
const baseStyle = StyleSheet.create({
|
|
93
|
+
wrapper: {
|
|
94
|
+
columnGap: SpacingConstant.spacing_05,
|
|
95
|
+
rowGap: SpacingConstant.spacing_03
|
|
96
|
+
},
|
|
97
|
+
legend: {
|
|
98
|
+
marginBottom: SpacingConstant.spacing_03
|
|
99
|
+
},
|
|
100
|
+
formHelperText: {
|
|
101
|
+
marginTop: SpacingConstant.spacing_03
|
|
102
|
+
}
|
|
103
|
+
}),
|
|
104
|
+
wrapperOrientationStyle = StyleSheet.create({
|
|
105
|
+
vertical: {
|
|
106
|
+
flexDirection: 'column'
|
|
107
|
+
},
|
|
108
|
+
horizontal: {
|
|
109
|
+
...FlexStyle.flex_wrap,
|
|
110
|
+
flexDirection: 'row'
|
|
111
|
+
}
|
|
112
|
+
});
|
|
113
|
+
function IconErrorRenderer(props) {
|
|
114
|
+
const themeContext = useContext(ThemeContext);
|
|
115
|
+
return /*#__PURE__*/_jsx(Icon, {
|
|
116
|
+
...props,
|
|
117
|
+
src: IconWarningFilled,
|
|
118
|
+
fill: themeContext.color.support_error,
|
|
119
|
+
width: 18,
|
|
120
|
+
height: 18
|
|
121
|
+
});
|
|
122
|
+
}
|
|
123
|
+
|
|
124
|
+
// eslint-disable-next-line @typescript-eslint/no-unsafe-member-access
|
|
125
|
+
IconWarningAltFilled.content[0].attrs.fill = 'black';
|
|
126
|
+
function IconWarningRenderer(props) {
|
|
127
|
+
const themeContext = useContext(ThemeContext);
|
|
128
|
+
return /*#__PURE__*/_jsx(Icon, {
|
|
129
|
+
...props,
|
|
130
|
+
src: IconWarningAltFilled,
|
|
131
|
+
fill: themeContext.color.support_warning,
|
|
132
|
+
width: 18,
|
|
133
|
+
height: 18
|
|
134
|
+
});
|
|
135
|
+
}
|
|
136
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["forwardRef","useContext","useEffect","useImperativeHandle","useRef","useState","StyleSheet","View","IconWarningAltFilled","IconWarningFilled","SpacingConstant","ThemeContext","FlexStyle","FormHelperText","FormLabel","Icon","RadioButtonGroupItemContext","RadioButtonGroupItem","jsx","_jsx","jsxs","_jsxs","Component","RadioButtonGroup","controlled","selectedValue","selectedValueProp","orientation","legend","helperText","helperTextMode","helperTextModeIcon","onChange","formHelperTextProps","children","role","style","props","forwardedRef","viewRef","ref","isMounted","selectedValueSelf","setSelectedValueSelf","current","Object","assign","setSelectedValue","valueParam","label","baseStyle","wrapper","wrapperOrientationStyle","Provider","value","setValue","error","text","textLeading","IconErrorRenderer","IconWarningRenderer","formHelperText","Item","create","columnGap","spacing_05","rowGap","spacing_03","marginBottom","marginTop","vertical","flexDirection","horizontal","flex_wrap","themeContext","src","fill","color","support_error","width","height","content","attrs","support_warning"],"sourceRoot":"../../../../src","sources":["components/radio-button-group/index.tsx"],"mappings":";;AAAA,SACCA,UAAU,E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CQ,IAAA,CAACJ,IAAI;IAAA,GACCsB,KAAK;IACVsC,GAAG,EAAGlE,iBAAmB;IACzBmE,IAAI,EAAGF,YAAY,CAACG,KAAK,CAACC,aAAe;IACzCC,KAAK,EAAG,EAAI;IACZC,MAAM,EAAG;EAAI,CACb,CAAC;AAGJ;;AAEA;AACAxE,oBAAoB,CAACyE,OAAO,CAAC,CAAC,CAAC,CAACC,KAAK,CAACN,IAAI,GAAG,OAAO;AACpD,SAAShB,mBAAmBA,CAACvB,KAAwB,EAAE;EAEtD,MAAMqC,YAAY,GAAGzE,UAAU,CAACU,YAAY,CAAC;EAE7C,oBACCQ,IAAA,CAACJ,IAAI;IAAA,GACCsB,KAAK;IACVsC,GAAG,EAAGnE,oBAAsB;IAC5BoE,IAAI,EAAGF,YAAY,CAACG,KAAK,CAACM,eAAiB;IAC3CJ,KAAK,EAAG,EAAI;IACZC,MAAM,EAAG;EAAI,CACb,CAAC;AAGJ","ignoreList":[]}
|
|
@@ -0,0 +1,196 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { forwardRef, useCallback, useContext, useEffect, useImperativeHandle, useRef, useState } from 'react';
|
|
4
|
+
import { Pressable, StyleSheet, View } from 'react-native';
|
|
5
|
+
import { ThemeContext } from "../../contexts/index.js";
|
|
6
|
+
import { CommonStyle, FlexStyle } from "../../styles/index.js";
|
|
7
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
8
|
+
export const RadioButtonInput = /*#__PURE__*/forwardRef(function RadioButtonInput({
|
|
9
|
+
controlled,
|
|
10
|
+
checked: checkedProp = false,
|
|
11
|
+
value,
|
|
12
|
+
interactiveState = 'normal',
|
|
13
|
+
role = 'radio',
|
|
14
|
+
onChange,
|
|
15
|
+
onBlur,
|
|
16
|
+
onFocus,
|
|
17
|
+
onPress,
|
|
18
|
+
style,
|
|
19
|
+
...props
|
|
20
|
+
}, forwardedRef) {
|
|
21
|
+
const themeContext = useContext(ThemeContext),
|
|
22
|
+
viewRef = useRef(null),
|
|
23
|
+
ref = useRef({
|
|
24
|
+
isMounted: false,
|
|
25
|
+
checked: checkedProp
|
|
26
|
+
}),
|
|
27
|
+
[isFocused, setIsFocused] = useState(false),
|
|
28
|
+
[checkedSelf, setCheckedSelf] = useState(checkedProp),
|
|
29
|
+
checked = controlled ? checkedProp : checkedSelf,
|
|
30
|
+
blurHandler = useCallback(event => {
|
|
31
|
+
onBlur?.(event);
|
|
32
|
+
setIsFocused(false);
|
|
33
|
+
}, [onBlur]),
|
|
34
|
+
focusHandler = useCallback(event => {
|
|
35
|
+
onFocus?.(event);
|
|
36
|
+
setIsFocused(true);
|
|
37
|
+
}, [onFocus]),
|
|
38
|
+
pressHandler = useCallback(event => {
|
|
39
|
+
onPress?.(event);
|
|
40
|
+
if (!controlled) {
|
|
41
|
+
setCheckedSelf(true);
|
|
42
|
+
}
|
|
43
|
+
}, [controlled, onPress]);
|
|
44
|
+
useEffect(() => {
|
|
45
|
+
if (!ref.current.isMounted) {
|
|
46
|
+
ref.current.isMounted = true;
|
|
47
|
+
} else {
|
|
48
|
+
ref.current.checked = checked;
|
|
49
|
+
onChange?.(checked, value);
|
|
50
|
+
}
|
|
51
|
+
}, [checked, value, onChange]);
|
|
52
|
+
useImperativeHandle(forwardedRef, () => {
|
|
53
|
+
return Object.assign(viewRef.current ?? {}, {
|
|
54
|
+
get checked() {
|
|
55
|
+
return ref.current.checked;
|
|
56
|
+
},
|
|
57
|
+
setChecked(checked_) {
|
|
58
|
+
if (!controlled) {
|
|
59
|
+
if (typeof checked_ === 'boolean') {
|
|
60
|
+
ref.current.checked = checked_;
|
|
61
|
+
} else {
|
|
62
|
+
ref.current.checked = checked_(ref.current.checked);
|
|
63
|
+
}
|
|
64
|
+
setCheckedSelf(ref.current.checked);
|
|
65
|
+
}
|
|
66
|
+
}
|
|
67
|
+
});
|
|
68
|
+
}, [controlled]);
|
|
69
|
+
return /*#__PURE__*/_jsxs(Pressable, {
|
|
70
|
+
...props,
|
|
71
|
+
role: role,
|
|
72
|
+
disabled: interactiveState === 'disabled',
|
|
73
|
+
onBlur: blurHandler,
|
|
74
|
+
onFocus: focusHandler,
|
|
75
|
+
onPress: pressHandler,
|
|
76
|
+
style: [FlexStyle.items_center, FlexStyle.justify_center, CommonStyle.relative, baseStyle.radioButton, getInteractiveStateStyle('container', interactiveState, checked, themeContext.color), style],
|
|
77
|
+
ref: viewRef,
|
|
78
|
+
children: [/*#__PURE__*/_jsx(View, {
|
|
79
|
+
style: [CommonStyle.absolute, CommonStyle.overflow_hidden, baseStyle.focusBox, isFocused ? {
|
|
80
|
+
borderColor: themeContext.color.focus
|
|
81
|
+
} : null]
|
|
82
|
+
}), /*#__PURE__*/_jsx(View, {
|
|
83
|
+
style: [FlexStyle.flex_initial, baseStyle.marker, getInteractiveStateStyle('marker', interactiveState, checked, themeContext.color)]
|
|
84
|
+
})]
|
|
85
|
+
});
|
|
86
|
+
});
|
|
87
|
+
const size = 18,
|
|
88
|
+
baseStyle = StyleSheet.create({
|
|
89
|
+
radioButton: {
|
|
90
|
+
width: size,
|
|
91
|
+
height: size,
|
|
92
|
+
borderRadius: size,
|
|
93
|
+
borderWidth: 1
|
|
94
|
+
},
|
|
95
|
+
focusBox: {
|
|
96
|
+
width: size + 6,
|
|
97
|
+
height: size + 6,
|
|
98
|
+
borderRadius: size + 3,
|
|
99
|
+
borderWidth: 2,
|
|
100
|
+
borderColor: 'transparent'
|
|
101
|
+
},
|
|
102
|
+
marker: {
|
|
103
|
+
borderRadius: size,
|
|
104
|
+
width: size / 2,
|
|
105
|
+
height: size / 2
|
|
106
|
+
}
|
|
107
|
+
}),
|
|
108
|
+
mapInteractiveStateStyle = {
|
|
109
|
+
normal: {
|
|
110
|
+
true: {
|
|
111
|
+
container: {
|
|
112
|
+
borderColor: 'icon_primary'
|
|
113
|
+
},
|
|
114
|
+
marker: {
|
|
115
|
+
backgroundColor: 'icon_primary'
|
|
116
|
+
}
|
|
117
|
+
},
|
|
118
|
+
false: {
|
|
119
|
+
container: {
|
|
120
|
+
borderColor: 'icon_primary'
|
|
121
|
+
}
|
|
122
|
+
}
|
|
123
|
+
},
|
|
124
|
+
disabled: {
|
|
125
|
+
true: {
|
|
126
|
+
container: {
|
|
127
|
+
borderColor: 'icon_disabled'
|
|
128
|
+
},
|
|
129
|
+
marker: {
|
|
130
|
+
backgroundColor: 'icon_disabled'
|
|
131
|
+
}
|
|
132
|
+
},
|
|
133
|
+
false: {
|
|
134
|
+
container: {
|
|
135
|
+
borderColor: 'icon_disabled'
|
|
136
|
+
}
|
|
137
|
+
}
|
|
138
|
+
},
|
|
139
|
+
error: {
|
|
140
|
+
true: {
|
|
141
|
+
container: {
|
|
142
|
+
borderColor: 'support_error'
|
|
143
|
+
},
|
|
144
|
+
marker: {
|
|
145
|
+
backgroundColor: 'icon_primary'
|
|
146
|
+
}
|
|
147
|
+
},
|
|
148
|
+
false: {
|
|
149
|
+
container: {
|
|
150
|
+
borderColor: 'support_error'
|
|
151
|
+
}
|
|
152
|
+
}
|
|
153
|
+
},
|
|
154
|
+
read_only: {
|
|
155
|
+
true: {
|
|
156
|
+
container: {
|
|
157
|
+
borderColor: 'icon_disabled'
|
|
158
|
+
},
|
|
159
|
+
marker: {
|
|
160
|
+
backgroundColor: 'icon_primary'
|
|
161
|
+
}
|
|
162
|
+
},
|
|
163
|
+
false: {
|
|
164
|
+
container: {
|
|
165
|
+
borderColor: 'icon_disabled'
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
},
|
|
169
|
+
warning: {
|
|
170
|
+
true: {
|
|
171
|
+
container: {
|
|
172
|
+
borderColor: 'icon_primary'
|
|
173
|
+
},
|
|
174
|
+
marker: {
|
|
175
|
+
backgroundColor: 'icon_primary'
|
|
176
|
+
}
|
|
177
|
+
},
|
|
178
|
+
false: {
|
|
179
|
+
container: {
|
|
180
|
+
borderColor: 'icon_primary'
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
};
|
|
185
|
+
function getInteractiveStateStyle(key, interactiveState, checked, color) {
|
|
186
|
+
const style = mapInteractiveStateStyle[interactiveState][`${checked}`],
|
|
187
|
+
parsedStyle = {};
|
|
188
|
+
if (style[key]?.backgroundColor) {
|
|
189
|
+
parsedStyle.backgroundColor = color[style[key].backgroundColor];
|
|
190
|
+
}
|
|
191
|
+
if (style[key]?.borderColor) {
|
|
192
|
+
parsedStyle.borderColor = color[style[key].borderColor];
|
|
193
|
+
}
|
|
194
|
+
return parsedStyle;
|
|
195
|
+
}
|
|
196
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["forwardRef","useCallback","useContext","useEffect","useImperativeHandle","useRef","useState","Pressable","StyleSheet","View","ThemeContext","CommonStyle","FlexStyle","jsx","_jsx","jsxs","_jsxs","RadioButtonInput","controlled","checked","checkedProp","value","interactiveState","role","onChange","onBlur","onFocus","onPress","style","props","forwardedRef","themeContext","viewRef","ref","isMounted","isFocused","setIsFocused","checkedSelf","setCheckedSelf","blurHandler","event","focusHandler","pressHandler","current","Object","assign","setChecked","checked_","disabled","items_center","justify_center","relative","baseStyle","radioButton","getInteractiveStateStyle","color","children","absolute","overflow_hidden","focusBox","borderColor","focus","flex_initial","marker","size","create","width","height","borderRadius","borderWidth","mapInteractiveStateStyle","normal","true","container","backgroundColor","false","error","read_only","warning","key","parsedStyle"],"sourceRoot":"../../../../src","sources":["components/radio-button-input/index.tsx"],"mappings":";;AAAA,SACCA,UAAU,EACVC,WAAW,EACXC,UAAU,EACVC,SAAS,EACTC,mBAAmB,EACnBC,MAAM,EACNC,QAAQ,QACF,OAAO;AAEd,SACCC,SAAS,EACTC,UAAU,EACVC,IAAI,QAIE,cAAc;AAErB,SACCC,YAAY,QACN,yBAAgB;AAEvB,SACCC,WAAW,EACXC,SAAS,QACH,uBAAc;AAAA,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAyCrB,OAAO,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