pixelize-native-library 1.0.6
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/README.md +34 -0
- package/lib/module/core/MODULE.md +94 -0
- package/lib/module/core/a11y/MODULE.md +22 -0
- package/lib/module/core/a11y/index.js +26 -0
- package/lib/module/core/a11y/index.js.map +1 -0
- package/lib/module/core/icon/MODULE.md +35 -0
- package/lib/module/core/icon/index.js +92 -0
- package/lib/module/core/icon/index.js.map +1 -0
- package/lib/module/core/style/index.js +4 -0
- package/lib/module/core/style/index.js.map +1 -0
- package/lib/module/core/style/layoutStyle.js +4 -0
- package/lib/module/core/style/layoutStyle.js.map +1 -0
- package/lib/module/core/style/variants.js +115 -0
- package/lib/module/core/style/variants.js.map +1 -0
- package/lib/module/index.js +13 -0
- package/lib/module/index.js.map +1 -0
- package/lib/module/modules/accordion/Accordion.js +194 -0
- package/lib/module/modules/accordion/Accordion.js.map +1 -0
- package/lib/module/modules/accordion/Accordion.variants.js +143 -0
- package/lib/module/modules/accordion/Accordion.variants.js.map +1 -0
- package/lib/module/modules/accordion/MODULE.md +97 -0
- package/lib/module/modules/accordion/index.js +10 -0
- package/lib/module/modules/accordion/index.js.map +1 -0
- package/lib/module/modules/alert-dialog/AlertDialog.js +62 -0
- package/lib/module/modules/alert-dialog/AlertDialog.js.map +1 -0
- package/lib/module/modules/alert-dialog/AlertDialog.variants.js +44 -0
- package/lib/module/modules/alert-dialog/AlertDialog.variants.js.map +1 -0
- package/lib/module/modules/alert-dialog/MODULE.md +81 -0
- package/lib/module/modules/alert-dialog/index.js +10 -0
- package/lib/module/modules/alert-dialog/index.js.map +1 -0
- package/lib/module/modules/avatar/Avatar.js +57 -0
- package/lib/module/modules/avatar/Avatar.js.map +1 -0
- package/lib/module/modules/avatar/Avatar.variants.js +127 -0
- package/lib/module/modules/avatar/Avatar.variants.js.map +1 -0
- package/lib/module/modules/avatar/MODULE.md +76 -0
- package/lib/module/modules/avatar/index.js +12 -0
- package/lib/module/modules/avatar/index.js.map +1 -0
- package/lib/module/modules/badge/Badge.js +56 -0
- package/lib/module/modules/badge/Badge.js.map +1 -0
- package/lib/module/modules/badge/Badge.variants.js +124 -0
- package/lib/module/modules/badge/Badge.variants.js.map +1 -0
- package/lib/module/modules/badge/MODULE.md +82 -0
- package/lib/module/modules/badge/index.js +12 -0
- package/lib/module/modules/badge/index.js.map +1 -0
- package/lib/module/modules/bottom-nav/BottomNav.js +257 -0
- package/lib/module/modules/bottom-nav/BottomNav.js.map +1 -0
- package/lib/module/modules/bottom-nav/BottomNav.search.js +153 -0
- package/lib/module/modules/bottom-nav/BottomNav.search.js.map +1 -0
- package/lib/module/modules/bottom-nav/BottomNav.variants.js +164 -0
- package/lib/module/modules/bottom-nav/BottomNav.variants.js.map +1 -0
- package/lib/module/modules/bottom-nav/BottomNavOverflowSheet.js +297 -0
- package/lib/module/modules/bottom-nav/BottomNavOverflowSheet.js.map +1 -0
- package/lib/module/modules/bottom-nav/MODULE.md +198 -0
- package/lib/module/modules/bottom-nav/index.js +16 -0
- package/lib/module/modules/bottom-nav/index.js.map +1 -0
- package/lib/module/modules/button/Button.js +173 -0
- package/lib/module/modules/button/Button.js.map +1 -0
- package/lib/module/modules/button/Button.variants.js +173 -0
- package/lib/module/modules/button/Button.variants.js.map +1 -0
- package/lib/module/modules/button/MODULE.md +87 -0
- package/lib/module/modules/button/index.js +12 -0
- package/lib/module/modules/button/index.js.map +1 -0
- package/lib/module/modules/button-group/ButtonGroup.js +106 -0
- package/lib/module/modules/button-group/ButtonGroup.js.map +1 -0
- package/lib/module/modules/button-group/ButtonGroup.variants.js +220 -0
- package/lib/module/modules/button-group/ButtonGroup.variants.js.map +1 -0
- package/lib/module/modules/button-group/MODULE.md +129 -0
- package/lib/module/modules/button-group/index.js +11 -0
- package/lib/module/modules/button-group/index.js.map +1 -0
- package/lib/module/modules/card/Card.js +39 -0
- package/lib/module/modules/card/Card.js.map +1 -0
- package/lib/module/modules/card/Card.variants.js +75 -0
- package/lib/module/modules/card/Card.variants.js.map +1 -0
- package/lib/module/modules/card/MODULE.md +81 -0
- package/lib/module/modules/card/index.js +10 -0
- package/lib/module/modules/card/index.js.map +1 -0
- package/lib/module/modules/checkbox/Checkbox.js +115 -0
- package/lib/module/modules/checkbox/Checkbox.js.map +1 -0
- package/lib/module/modules/checkbox/Checkbox.variants.js +122 -0
- package/lib/module/modules/checkbox/Checkbox.variants.js.map +1 -0
- package/lib/module/modules/checkbox/MODULE.md +76 -0
- package/lib/module/modules/checkbox/index.js +11 -0
- package/lib/module/modules/checkbox/index.js.map +1 -0
- package/lib/module/modules/divider/Divider.js +35 -0
- package/lib/module/modules/divider/Divider.js.map +1 -0
- package/lib/module/modules/divider/Divider.variants.js +51 -0
- package/lib/module/modules/divider/Divider.variants.js.map +1 -0
- package/lib/module/modules/divider/MODULE.md +61 -0
- package/lib/module/modules/divider/index.js +10 -0
- package/lib/module/modules/divider/index.js.map +1 -0
- package/lib/module/modules/drawer/Drawer.js +171 -0
- package/lib/module/modules/drawer/Drawer.js.map +1 -0
- package/lib/module/modules/drawer/Drawer.variants.js +118 -0
- package/lib/module/modules/drawer/Drawer.variants.js.map +1 -0
- package/lib/module/modules/drawer/MODULE.md +161 -0
- package/lib/module/modules/drawer/index.js +10 -0
- package/lib/module/modules/drawer/index.js.map +1 -0
- package/lib/module/modules/empty-state/EmptyState.js +79 -0
- package/lib/module/modules/empty-state/EmptyState.js.map +1 -0
- package/lib/module/modules/empty-state/EmptyState.variants.js +54 -0
- package/lib/module/modules/empty-state/EmptyState.variants.js.map +1 -0
- package/lib/module/modules/empty-state/MODULE.md +78 -0
- package/lib/module/modules/empty-state/index.js +13 -0
- package/lib/module/modules/empty-state/index.js.map +1 -0
- package/lib/module/modules/file-upload/FileUpload.js +132 -0
- package/lib/module/modules/file-upload/FileUpload.js.map +1 -0
- package/lib/module/modules/file-upload/FileUpload.variants.js +179 -0
- package/lib/module/modules/file-upload/FileUpload.variants.js.map +1 -0
- package/lib/module/modules/file-upload/MODULE.md +130 -0
- package/lib/module/modules/file-upload/index.js +10 -0
- package/lib/module/modules/file-upload/index.js.map +1 -0
- package/lib/module/modules/filter-sheet/FilterChip.js +79 -0
- package/lib/module/modules/filter-sheet/FilterChip.js.map +1 -0
- package/lib/module/modules/filter-sheet/FilterSheet.js +98 -0
- package/lib/module/modules/filter-sheet/FilterSheet.js.map +1 -0
- package/lib/module/modules/filter-sheet/FilterSheet.variants.js +156 -0
- package/lib/module/modules/filter-sheet/FilterSheet.variants.js.map +1 -0
- package/lib/module/modules/filter-sheet/FilterSheetBody.js +175 -0
- package/lib/module/modules/filter-sheet/FilterSheetBody.js.map +1 -0
- package/lib/module/modules/filter-sheet/MODULE.md +115 -0
- package/lib/module/modules/filter-sheet/filterSheet.helpers.js +90 -0
- package/lib/module/modules/filter-sheet/filterSheet.helpers.js.map +1 -0
- package/lib/module/modules/filter-sheet/index.js +14 -0
- package/lib/module/modules/filter-sheet/index.js.map +1 -0
- package/lib/module/modules/input/Input.js +132 -0
- package/lib/module/modules/input/Input.js.map +1 -0
- package/lib/module/modules/input/Input.variants.js +122 -0
- package/lib/module/modules/input/Input.variants.js.map +1 -0
- package/lib/module/modules/input/MODULE.md +97 -0
- package/lib/module/modules/input/index.js +13 -0
- package/lib/module/modules/input/index.js.map +1 -0
- package/lib/module/modules/menu/MODULE.md +103 -0
- package/lib/module/modules/menu/Menu.js +128 -0
- package/lib/module/modules/menu/Menu.js.map +1 -0
- package/lib/module/modules/menu/Menu.variants.js +75 -0
- package/lib/module/modules/menu/Menu.variants.js.map +1 -0
- package/lib/module/modules/menu/index.js +12 -0
- package/lib/module/modules/menu/index.js.map +1 -0
- package/lib/module/modules/modal/MODULE.md +138 -0
- package/lib/module/modules/modal/Modal.js +101 -0
- package/lib/module/modules/modal/Modal.js.map +1 -0
- package/lib/module/modules/modal/Modal.variants.js +92 -0
- package/lib/module/modules/modal/Modal.variants.js.map +1 -0
- package/lib/module/modules/modal/ModalPortalContext.js +25 -0
- package/lib/module/modules/modal/ModalPortalContext.js.map +1 -0
- package/lib/module/modules/modal/ModalPortalProvider.js +22 -0
- package/lib/module/modules/modal/ModalPortalProvider.js.map +1 -0
- package/lib/module/modules/modal/index.js +16 -0
- package/lib/module/modules/modal/index.js.map +1 -0
- package/lib/module/modules/modal/renderWebPortal.js +18 -0
- package/lib/module/modules/modal/renderWebPortal.js.map +1 -0
- package/lib/module/modules/modal/renderWebPortal.web.js +24 -0
- package/lib/module/modules/modal/renderWebPortal.web.js.map +1 -0
- package/lib/module/modules/multi-select/MODULE.md +100 -0
- package/lib/module/modules/multi-select/MultiSelect.js +204 -0
- package/lib/module/modules/multi-select/MultiSelect.js.map +1 -0
- package/lib/module/modules/multi-select/MultiSelect.variants.js +195 -0
- package/lib/module/modules/multi-select/MultiSelect.variants.js.map +1 -0
- package/lib/module/modules/multi-select/index.js +11 -0
- package/lib/module/modules/multi-select/index.js.map +1 -0
- package/lib/module/modules/number-input/MODULE.md +108 -0
- package/lib/module/modules/number-input/NumberInput.js +253 -0
- package/lib/module/modules/number-input/NumberInput.js.map +1 -0
- package/lib/module/modules/number-input/NumberInput.variants.js +200 -0
- package/lib/module/modules/number-input/NumberInput.variants.js.map +1 -0
- package/lib/module/modules/number-input/index.js +12 -0
- package/lib/module/modules/number-input/index.js.map +1 -0
- package/lib/module/modules/pin-input/MODULE.md +134 -0
- package/lib/module/modules/pin-input/PinInput.js +158 -0
- package/lib/module/modules/pin-input/PinInput.js.map +1 -0
- package/lib/module/modules/pin-input/PinInput.variants.js +183 -0
- package/lib/module/modules/pin-input/PinInput.variants.js.map +1 -0
- package/lib/module/modules/pin-input/index.js +11 -0
- package/lib/module/modules/pin-input/index.js.map +1 -0
- package/lib/module/modules/progress-bar/MODULE.md +101 -0
- package/lib/module/modules/progress-bar/ProgressBar.js +102 -0
- package/lib/module/modules/progress-bar/ProgressBar.js.map +1 -0
- package/lib/module/modules/progress-bar/ProgressBar.variants.js +151 -0
- package/lib/module/modules/progress-bar/ProgressBar.variants.js.map +1 -0
- package/lib/module/modules/progress-bar/index.js +12 -0
- package/lib/module/modules/progress-bar/index.js.map +1 -0
- package/lib/module/modules/radio-group/MODULE.md +75 -0
- package/lib/module/modules/radio-group/RadioGroup.js +87 -0
- package/lib/module/modules/radio-group/RadioGroup.js.map +1 -0
- package/lib/module/modules/radio-group/RadioGroup.variants.js +163 -0
- package/lib/module/modules/radio-group/RadioGroup.variants.js.map +1 -0
- package/lib/module/modules/radio-group/index.js +11 -0
- package/lib/module/modules/radio-group/index.js.map +1 -0
- package/lib/module/modules/reorder/MODULE.md +131 -0
- package/lib/module/modules/reorder/Reorder.js +291 -0
- package/lib/module/modules/reorder/Reorder.js.map +1 -0
- package/lib/module/modules/reorder/Reorder.variants.js +172 -0
- package/lib/module/modules/reorder/Reorder.variants.js.map +1 -0
- package/lib/module/modules/reorder/index.js +11 -0
- package/lib/module/modules/reorder/index.js.map +1 -0
- package/lib/module/modules/select/MODULE.md +91 -0
- package/lib/module/modules/select/Select.js +178 -0
- package/lib/module/modules/select/Select.js.map +1 -0
- package/lib/module/modules/select/Select.variants.js +146 -0
- package/lib/module/modules/select/Select.variants.js.map +1 -0
- package/lib/module/modules/select/index.js +10 -0
- package/lib/module/modules/select/index.js.map +1 -0
- package/lib/module/modules/skeleton/MODULE.md +87 -0
- package/lib/module/modules/skeleton/Skeleton.js +78 -0
- package/lib/module/modules/skeleton/Skeleton.js.map +1 -0
- package/lib/module/modules/skeleton/Skeleton.variants.js +145 -0
- package/lib/module/modules/skeleton/Skeleton.variants.js.map +1 -0
- package/lib/module/modules/skeleton/index.js +10 -0
- package/lib/module/modules/skeleton/index.js.map +1 -0
- package/lib/module/modules/slider/MODULE.md +95 -0
- package/lib/module/modules/slider/Slider.js +183 -0
- package/lib/module/modules/slider/Slider.js.map +1 -0
- package/lib/module/modules/slider/Slider.variants.js +258 -0
- package/lib/module/modules/slider/Slider.variants.js.map +1 -0
- package/lib/module/modules/slider/index.js +10 -0
- package/lib/module/modules/slider/index.js.map +1 -0
- package/lib/module/modules/spinner/MODULE.md +97 -0
- package/lib/module/modules/spinner/Spinner.js +58 -0
- package/lib/module/modules/spinner/Spinner.js.map +1 -0
- package/lib/module/modules/spinner/Spinner.variants.js +131 -0
- package/lib/module/modules/spinner/Spinner.variants.js.map +1 -0
- package/lib/module/modules/spinner/index.js +11 -0
- package/lib/module/modules/spinner/index.js.map +1 -0
- package/lib/module/modules/stepper/MODULE.md +88 -0
- package/lib/module/modules/stepper/Stepper.js +100 -0
- package/lib/module/modules/stepper/Stepper.js.map +1 -0
- package/lib/module/modules/stepper/Stepper.variants.js +146 -0
- package/lib/module/modules/stepper/Stepper.variants.js.map +1 -0
- package/lib/module/modules/stepper/index.js +10 -0
- package/lib/module/modules/stepper/index.js.map +1 -0
- package/lib/module/modules/switch/MODULE.md +65 -0
- package/lib/module/modules/switch/Switch.js +53 -0
- package/lib/module/modules/switch/Switch.js.map +1 -0
- package/lib/module/modules/switch/Switch.variants.js +61 -0
- package/lib/module/modules/switch/Switch.variants.js.map +1 -0
- package/lib/module/modules/switch/index.js +10 -0
- package/lib/module/modules/switch/index.js.map +1 -0
- package/lib/module/modules/tabs/MODULE.md +80 -0
- package/lib/module/modules/tabs/Tabs.js +127 -0
- package/lib/module/modules/tabs/Tabs.js.map +1 -0
- package/lib/module/modules/tabs/Tabs.variants.js +135 -0
- package/lib/module/modules/tabs/Tabs.variants.js.map +1 -0
- package/lib/module/modules/tabs/index.js +12 -0
- package/lib/module/modules/tabs/index.js.map +1 -0
- package/lib/module/modules/textarea/MODULE.md +91 -0
- package/lib/module/modules/textarea/Textarea.js +136 -0
- package/lib/module/modules/textarea/Textarea.js.map +1 -0
- package/lib/module/modules/textarea/Textarea.variants.js +113 -0
- package/lib/module/modules/textarea/Textarea.variants.js.map +1 -0
- package/lib/module/modules/textarea/index.js +10 -0
- package/lib/module/modules/textarea/index.js.map +1 -0
- package/lib/module/modules/timeline/MODULE.md +95 -0
- package/lib/module/modules/timeline/Timeline.js +92 -0
- package/lib/module/modules/timeline/Timeline.js.map +1 -0
- package/lib/module/modules/timeline/Timeline.variants.js +146 -0
- package/lib/module/modules/timeline/Timeline.variants.js.map +1 -0
- package/lib/module/modules/timeline/index.js +12 -0
- package/lib/module/modules/timeline/index.js.map +1 -0
- package/lib/module/modules/toast/MODULE.md +104 -0
- package/lib/module/modules/toast/Toast.js +178 -0
- package/lib/module/modules/toast/Toast.js.map +1 -0
- package/lib/module/modules/toast/Toast.variants.js +120 -0
- package/lib/module/modules/toast/Toast.variants.js.map +1 -0
- package/lib/module/modules/toast/index.js +13 -0
- package/lib/module/modules/toast/index.js.map +1 -0
- package/lib/module/modules/tooltip/MODULE.md +86 -0
- package/lib/module/modules/tooltip/Tooltip.js +115 -0
- package/lib/module/modules/tooltip/Tooltip.js.map +1 -0
- package/lib/module/modules/tooltip/Tooltip.variants.js +75 -0
- package/lib/module/modules/tooltip/Tooltip.variants.js.map +1 -0
- package/lib/module/modules/tooltip/index.js +10 -0
- package/lib/module/modules/tooltip/index.js.map +1 -0
- package/lib/module/package.json +1 -0
- package/lib/module/theme/MODULE.md +87 -0
- package/lib/module/theme/index.js +15 -0
- package/lib/module/theme/index.js.map +1 -0
- package/lib/module/theme/platform/MODULE.md +102 -0
- package/lib/module/theme/platform/colorScheme.native.js +24 -0
- package/lib/module/theme/platform/colorScheme.native.js.map +1 -0
- package/lib/module/theme/platform/elevation.native.js +75 -0
- package/lib/module/theme/platform/elevation.native.js.map +1 -0
- package/lib/module/theme/platform/fonts.native.js +58 -0
- package/lib/module/theme/platform/fonts.native.js.map +1 -0
- package/lib/module/theme/platform/index.js +14 -0
- package/lib/module/theme/platform/index.js.map +1 -0
- package/lib/module/theme/platform/units.native.js +18 -0
- package/lib/module/theme/platform/units.native.js.map +1 -0
- package/lib/module/theme/provider/PixelizeProvider.js +149 -0
- package/lib/module/theme/provider/PixelizeProvider.js.map +1 -0
- package/lib/module/theme/provider/colorModeStorage.js +63 -0
- package/lib/module/theme/provider/colorModeStorage.js.map +1 -0
- package/lib/module/theme/provider/index.js +8 -0
- package/lib/module/theme/provider/index.js.map +1 -0
- package/lib/module/theme/provider/useTheme.js +13 -0
- package/lib/module/theme/provider/useTheme.js.map +1 -0
- package/lib/module/theme/provider/useThemeColors.js +13 -0
- package/lib/module/theme/provider/useThemeColors.js.map +1 -0
- package/lib/module/theme/provider/useThemeMode.js +13 -0
- package/lib/module/theme/provider/useThemeMode.js.map +1 -0
- package/lib/module/theme/tokens/MODULE.md +102 -0
- package/lib/module/theme/tokens/brands/emerald/palette.dark.js +9 -0
- package/lib/module/theme/tokens/brands/emerald/palette.dark.js.map +1 -0
- package/lib/module/theme/tokens/brands/emerald/palette.light.js +125 -0
- package/lib/module/theme/tokens/brands/emerald/palette.light.js.map +1 -0
- package/lib/module/theme/tokens/brands/index.js +91 -0
- package/lib/module/theme/tokens/brands/index.js.map +1 -0
- package/lib/module/theme/tokens/brands/lavender/palette.dark.js +9 -0
- package/lib/module/theme/tokens/brands/lavender/palette.dark.js.map +1 -0
- package/lib/module/theme/tokens/brands/lavender/palette.light.js +376 -0
- package/lib/module/theme/tokens/brands/lavender/palette.light.js.map +1 -0
- package/lib/module/theme/tokens/brands/meadow/palette.dark.js +9 -0
- package/lib/module/theme/tokens/brands/meadow/palette.dark.js.map +1 -0
- package/lib/module/theme/tokens/brands/meadow/palette.light.js +126 -0
- package/lib/module/theme/tokens/brands/meadow/palette.light.js.map +1 -0
- package/lib/module/theme/tokens/brands/radiant/palette.dark.js +9 -0
- package/lib/module/theme/tokens/brands/radiant/palette.dark.js.map +1 -0
- package/lib/module/theme/tokens/brands/radiant/palette.light.js +125 -0
- package/lib/module/theme/tokens/brands/radiant/palette.light.js.map +1 -0
- package/lib/module/theme/tokens/brands/rosewood/palette.dark.js +9 -0
- package/lib/module/theme/tokens/brands/rosewood/palette.dark.js.map +1 -0
- package/lib/module/theme/tokens/brands/rosewood/palette.light.js +125 -0
- package/lib/module/theme/tokens/brands/rosewood/palette.light.js.map +1 -0
- package/lib/module/theme/tokens/brands/skyline/palette.dark.js +9 -0
- package/lib/module/theme/tokens/brands/skyline/palette.dark.js.map +1 -0
- package/lib/module/theme/tokens/brands/skyline/palette.light.js +126 -0
- package/lib/module/theme/tokens/brands/skyline/palette.light.js.map +1 -0
- package/lib/module/theme/tokens/brands/slate/palette.dark.js +11 -0
- package/lib/module/theme/tokens/brands/slate/palette.dark.js.map +1 -0
- package/lib/module/theme/tokens/brands/slate/palette.light.js +129 -0
- package/lib/module/theme/tokens/brands/slate/palette.light.js.map +1 -0
- package/lib/module/theme/tokens/brands/storefront/palette.dark.js +7 -0
- package/lib/module/theme/tokens/brands/storefront/palette.dark.js.map +1 -0
- package/lib/module/theme/tokens/brands/storefront/palette.light.js +127 -0
- package/lib/module/theme/tokens/brands/storefront/palette.light.js.map +1 -0
- package/lib/module/theme/tokens/brands/zinc/palette.dark.js +222 -0
- package/lib/module/theme/tokens/brands/zinc/palette.dark.js.map +1 -0
- package/lib/module/theme/tokens/brands/zinc/palette.light.js +393 -0
- package/lib/module/theme/tokens/brands/zinc/palette.light.js.map +1 -0
- package/lib/module/theme/tokens/builders/accentText.js +66 -0
- package/lib/module/theme/tokens/builders/accentText.js.map +1 -0
- package/lib/module/theme/tokens/builders/buildBrandTokens.js +38 -0
- package/lib/module/theme/tokens/builders/buildBrandTokens.js.map +1 -0
- package/lib/module/theme/tokens/builders/buildDarkPalette.js +300 -0
- package/lib/module/theme/tokens/builders/buildDarkPalette.js.map +1 -0
- package/lib/module/theme/tokens/builders/color.js +187 -0
- package/lib/module/theme/tokens/builders/color.js.map +1 -0
- package/lib/module/theme/tokens/index.js +27 -0
- package/lib/module/theme/tokens/index.js.map +1 -0
- package/lib/module/theme/tokens/primitives/borderWidths.js +16 -0
- package/lib/module/theme/tokens/primitives/borderWidths.js.map +1 -0
- package/lib/module/theme/tokens/primitives/breakpoints.js +18 -0
- package/lib/module/theme/tokens/primitives/breakpoints.js.map +1 -0
- package/lib/module/theme/tokens/primitives/elevation.js +95 -0
- package/lib/module/theme/tokens/primitives/elevation.js.map +1 -0
- package/lib/module/theme/tokens/primitives/fontSizes.js +22 -0
- package/lib/module/theme/tokens/primitives/fontSizes.js.map +1 -0
- package/lib/module/theme/tokens/primitives/fontWeights.js +23 -0
- package/lib/module/theme/tokens/primitives/fontWeights.js.map +1 -0
- package/lib/module/theme/tokens/primitives/index.js +14 -0
- package/lib/module/theme/tokens/primitives/index.js.map +1 -0
- package/lib/module/theme/tokens/primitives/letterSpacings.js +18 -0
- package/lib/module/theme/tokens/primitives/letterSpacings.js.map +1 -0
- package/lib/module/theme/tokens/primitives/lineHeights.js +21 -0
- package/lib/module/theme/tokens/primitives/lineHeights.js.map +1 -0
- package/lib/module/theme/tokens/primitives/radii.js +21 -0
- package/lib/module/theme/tokens/primitives/radii.js.map +1 -0
- package/lib/module/theme/tokens/primitives/sizes.js +34 -0
- package/lib/module/theme/tokens/primitives/sizes.js.map +1 -0
- package/lib/module/theme/tokens/primitives/space.js +30 -0
- package/lib/module/theme/tokens/primitives/space.js.map +1 -0
- package/lib/module/theme/tokens/primitives/zIndices.js +23 -0
- package/lib/module/theme/tokens/primitives/zIndices.js.map +1 -0
- package/lib/module/theme/tokens/roles/index.js +126 -0
- package/lib/module/theme/tokens/roles/index.js.map +1 -0
- package/lib/module/theme/tokens/types.js +2 -0
- package/lib/module/theme/tokens/types.js.map +1 -0
- package/lib/typescript/core/a11y/index.d.ts +7 -0
- package/lib/typescript/core/a11y/index.d.ts.map +1 -0
- package/lib/typescript/core/icon/index.d.ts +60 -0
- package/lib/typescript/core/icon/index.d.ts.map +1 -0
- package/lib/typescript/core/style/index.d.ts +4 -0
- package/lib/typescript/core/style/index.d.ts.map +1 -0
- package/lib/typescript/core/style/layoutStyle.d.ts +19 -0
- package/lib/typescript/core/style/layoutStyle.d.ts.map +1 -0
- package/lib/typescript/core/style/variants.d.ts +55 -0
- package/lib/typescript/core/style/variants.d.ts.map +1 -0
- package/lib/typescript/index.d.ts +11 -0
- package/lib/typescript/index.d.ts.map +1 -0
- package/lib/typescript/modules/accordion/Accordion.d.ts +57 -0
- package/lib/typescript/modules/accordion/Accordion.d.ts.map +1 -0
- package/lib/typescript/modules/accordion/Accordion.variants.d.ts +131 -0
- package/lib/typescript/modules/accordion/Accordion.variants.d.ts.map +1 -0
- package/lib/typescript/modules/accordion/index.d.ts +9 -0
- package/lib/typescript/modules/accordion/index.d.ts.map +1 -0
- package/lib/typescript/modules/alert-dialog/AlertDialog.d.ts +24 -0
- package/lib/typescript/modules/alert-dialog/AlertDialog.d.ts.map +1 -0
- package/lib/typescript/modules/alert-dialog/AlertDialog.variants.d.ts +29 -0
- package/lib/typescript/modules/alert-dialog/AlertDialog.variants.d.ts.map +1 -0
- package/lib/typescript/modules/alert-dialog/index.d.ts +9 -0
- package/lib/typescript/modules/alert-dialog/index.d.ts.map +1 -0
- package/lib/typescript/modules/avatar/Avatar.d.ts +30 -0
- package/lib/typescript/modules/avatar/Avatar.d.ts.map +1 -0
- package/lib/typescript/modules/avatar/Avatar.variants.d.ts +123 -0
- package/lib/typescript/modules/avatar/Avatar.variants.d.ts.map +1 -0
- package/lib/typescript/modules/avatar/index.d.ts +11 -0
- package/lib/typescript/modules/avatar/index.d.ts.map +1 -0
- package/lib/typescript/modules/badge/Badge.d.ts +19 -0
- package/lib/typescript/modules/badge/Badge.d.ts.map +1 -0
- package/lib/typescript/modules/badge/Badge.variants.d.ts +102 -0
- package/lib/typescript/modules/badge/Badge.variants.d.ts.map +1 -0
- package/lib/typescript/modules/badge/index.d.ts +10 -0
- package/lib/typescript/modules/badge/index.d.ts.map +1 -0
- package/lib/typescript/modules/bottom-nav/BottomNav.d.ts +106 -0
- package/lib/typescript/modules/bottom-nav/BottomNav.d.ts.map +1 -0
- package/lib/typescript/modules/bottom-nav/BottomNav.search.d.ts +61 -0
- package/lib/typescript/modules/bottom-nav/BottomNav.search.d.ts.map +1 -0
- package/lib/typescript/modules/bottom-nav/BottomNav.variants.d.ts +122 -0
- package/lib/typescript/modules/bottom-nav/BottomNav.variants.d.ts.map +1 -0
- package/lib/typescript/modules/bottom-nav/BottomNavOverflowSheet.d.ts +39 -0
- package/lib/typescript/modules/bottom-nav/BottomNavOverflowSheet.d.ts.map +1 -0
- package/lib/typescript/modules/bottom-nav/index.d.ts +12 -0
- package/lib/typescript/modules/bottom-nav/index.d.ts.map +1 -0
- package/lib/typescript/modules/button/Button.d.ts +43 -0
- package/lib/typescript/modules/button/Button.d.ts.map +1 -0
- package/lib/typescript/modules/button/Button.variants.d.ts +156 -0
- package/lib/typescript/modules/button/Button.variants.d.ts.map +1 -0
- package/lib/typescript/modules/button/index.d.ts +10 -0
- package/lib/typescript/modules/button/index.d.ts.map +1 -0
- package/lib/typescript/modules/button-group/ButtonGroup.d.ts +37 -0
- package/lib/typescript/modules/button-group/ButtonGroup.d.ts.map +1 -0
- package/lib/typescript/modules/button-group/ButtonGroup.variants.d.ts +217 -0
- package/lib/typescript/modules/button-group/ButtonGroup.variants.d.ts.map +1 -0
- package/lib/typescript/modules/button-group/index.d.ts +10 -0
- package/lib/typescript/modules/button-group/index.d.ts.map +1 -0
- package/lib/typescript/modules/card/Card.d.ts +20 -0
- package/lib/typescript/modules/card/Card.d.ts.map +1 -0
- package/lib/typescript/modules/card/Card.variants.d.ts +51 -0
- package/lib/typescript/modules/card/Card.variants.d.ts.map +1 -0
- package/lib/typescript/modules/card/index.d.ts +9 -0
- package/lib/typescript/modules/card/index.d.ts.map +1 -0
- package/lib/typescript/modules/checkbox/Checkbox.d.ts +43 -0
- package/lib/typescript/modules/checkbox/Checkbox.d.ts.map +1 -0
- package/lib/typescript/modules/checkbox/Checkbox.variants.d.ts +120 -0
- package/lib/typescript/modules/checkbox/Checkbox.variants.d.ts.map +1 -0
- package/lib/typescript/modules/checkbox/index.d.ts +10 -0
- package/lib/typescript/modules/checkbox/index.d.ts.map +1 -0
- package/lib/typescript/modules/divider/Divider.d.ts +18 -0
- package/lib/typescript/modules/divider/Divider.d.ts.map +1 -0
- package/lib/typescript/modules/divider/Divider.variants.d.ts +42 -0
- package/lib/typescript/modules/divider/Divider.variants.d.ts.map +1 -0
- package/lib/typescript/modules/divider/index.d.ts +9 -0
- package/lib/typescript/modules/divider/index.d.ts.map +1 -0
- package/lib/typescript/modules/drawer/Drawer.d.ts +44 -0
- package/lib/typescript/modules/drawer/Drawer.d.ts.map +1 -0
- package/lib/typescript/modules/drawer/Drawer.variants.d.ts +80 -0
- package/lib/typescript/modules/drawer/Drawer.variants.d.ts.map +1 -0
- package/lib/typescript/modules/drawer/index.d.ts +8 -0
- package/lib/typescript/modules/drawer/index.d.ts.map +1 -0
- package/lib/typescript/modules/empty-state/EmptyState.d.ts +29 -0
- package/lib/typescript/modules/empty-state/EmptyState.d.ts.map +1 -0
- package/lib/typescript/modules/empty-state/EmptyState.variants.d.ts +43 -0
- package/lib/typescript/modules/empty-state/EmptyState.variants.d.ts.map +1 -0
- package/lib/typescript/modules/empty-state/index.d.ts +10 -0
- package/lib/typescript/modules/empty-state/index.d.ts.map +1 -0
- package/lib/typescript/modules/file-upload/FileUpload.d.ts +44 -0
- package/lib/typescript/modules/file-upload/FileUpload.d.ts.map +1 -0
- package/lib/typescript/modules/file-upload/FileUpload.variants.d.ts +114 -0
- package/lib/typescript/modules/file-upload/FileUpload.variants.d.ts.map +1 -0
- package/lib/typescript/modules/file-upload/index.d.ts +9 -0
- package/lib/typescript/modules/file-upload/index.d.ts.map +1 -0
- package/lib/typescript/modules/filter-sheet/FilterChip.d.ts +25 -0
- package/lib/typescript/modules/filter-sheet/FilterChip.d.ts.map +1 -0
- package/lib/typescript/modules/filter-sheet/FilterSheet.d.ts +54 -0
- package/lib/typescript/modules/filter-sheet/FilterSheet.d.ts.map +1 -0
- package/lib/typescript/modules/filter-sheet/FilterSheet.variants.d.ts +98 -0
- package/lib/typescript/modules/filter-sheet/FilterSheet.variants.d.ts.map +1 -0
- package/lib/typescript/modules/filter-sheet/FilterSheetBody.d.ts +28 -0
- package/lib/typescript/modules/filter-sheet/FilterSheetBody.d.ts.map +1 -0
- package/lib/typescript/modules/filter-sheet/filterSheet.helpers.d.ts +45 -0
- package/lib/typescript/modules/filter-sheet/filterSheet.helpers.d.ts.map +1 -0
- package/lib/typescript/modules/filter-sheet/index.d.ts +12 -0
- package/lib/typescript/modules/filter-sheet/index.d.ts.map +1 -0
- package/lib/typescript/modules/input/Input.d.ts +33 -0
- package/lib/typescript/modules/input/Input.d.ts.map +1 -0
- package/lib/typescript/modules/input/Input.variants.d.ts +116 -0
- package/lib/typescript/modules/input/Input.variants.d.ts.map +1 -0
- package/lib/typescript/modules/input/index.d.ts +10 -0
- package/lib/typescript/modules/input/index.d.ts.map +1 -0
- package/lib/typescript/modules/menu/Menu.d.ts +43 -0
- package/lib/typescript/modules/menu/Menu.d.ts.map +1 -0
- package/lib/typescript/modules/menu/Menu.variants.d.ts +41 -0
- package/lib/typescript/modules/menu/Menu.variants.d.ts.map +1 -0
- package/lib/typescript/modules/menu/index.d.ts +10 -0
- package/lib/typescript/modules/menu/index.d.ts.map +1 -0
- package/lib/typescript/modules/modal/Modal.d.ts +32 -0
- package/lib/typescript/modules/modal/Modal.d.ts.map +1 -0
- package/lib/typescript/modules/modal/Modal.variants.d.ts +72 -0
- package/lib/typescript/modules/modal/Modal.variants.d.ts.map +1 -0
- package/lib/typescript/modules/modal/ModalPortalContext.d.ts +2 -0
- package/lib/typescript/modules/modal/ModalPortalContext.d.ts.map +1 -0
- package/lib/typescript/modules/modal/ModalPortalProvider.d.ts +21 -0
- package/lib/typescript/modules/modal/ModalPortalProvider.d.ts.map +1 -0
- package/lib/typescript/modules/modal/index.d.ts +16 -0
- package/lib/typescript/modules/modal/index.d.ts.map +1 -0
- package/lib/typescript/modules/modal/renderWebPortal.d.ts +15 -0
- package/lib/typescript/modules/modal/renderWebPortal.d.ts.map +1 -0
- package/lib/typescript/modules/modal/renderWebPortal.web.d.ts +19 -0
- package/lib/typescript/modules/modal/renderWebPortal.web.d.ts.map +1 -0
- package/lib/typescript/modules/multi-select/MultiSelect.d.ts +33 -0
- package/lib/typescript/modules/multi-select/MultiSelect.d.ts.map +1 -0
- package/lib/typescript/modules/multi-select/MultiSelect.variants.d.ts +149 -0
- package/lib/typescript/modules/multi-select/MultiSelect.variants.d.ts.map +1 -0
- package/lib/typescript/modules/multi-select/index.d.ts +10 -0
- package/lib/typescript/modules/multi-select/index.d.ts.map +1 -0
- package/lib/typescript/modules/number-input/NumberInput.d.ts +34 -0
- package/lib/typescript/modules/number-input/NumberInput.d.ts.map +1 -0
- package/lib/typescript/modules/number-input/NumberInput.variants.d.ts +170 -0
- package/lib/typescript/modules/number-input/NumberInput.variants.d.ts.map +1 -0
- package/lib/typescript/modules/number-input/index.d.ts +11 -0
- package/lib/typescript/modules/number-input/index.d.ts.map +1 -0
- package/lib/typescript/modules/pin-input/PinInput.d.ts +40 -0
- package/lib/typescript/modules/pin-input/PinInput.d.ts.map +1 -0
- package/lib/typescript/modules/pin-input/PinInput.variants.d.ts +164 -0
- package/lib/typescript/modules/pin-input/PinInput.variants.d.ts.map +1 -0
- package/lib/typescript/modules/pin-input/index.d.ts +10 -0
- package/lib/typescript/modules/pin-input/index.d.ts.map +1 -0
- package/lib/typescript/modules/progress-bar/ProgressBar.d.ts +21 -0
- package/lib/typescript/modules/progress-bar/ProgressBar.d.ts.map +1 -0
- package/lib/typescript/modules/progress-bar/ProgressBar.variants.d.ts +112 -0
- package/lib/typescript/modules/progress-bar/ProgressBar.variants.d.ts.map +1 -0
- package/lib/typescript/modules/progress-bar/index.d.ts +11 -0
- package/lib/typescript/modules/progress-bar/index.d.ts.map +1 -0
- package/lib/typescript/modules/radio-group/RadioGroup.d.ts +27 -0
- package/lib/typescript/modules/radio-group/RadioGroup.d.ts.map +1 -0
- package/lib/typescript/modules/radio-group/RadioGroup.variants.d.ts +142 -0
- package/lib/typescript/modules/radio-group/RadioGroup.variants.d.ts.map +1 -0
- package/lib/typescript/modules/radio-group/index.d.ts +10 -0
- package/lib/typescript/modules/radio-group/index.d.ts.map +1 -0
- package/lib/typescript/modules/reorder/Reorder.d.ts +43 -0
- package/lib/typescript/modules/reorder/Reorder.d.ts.map +1 -0
- package/lib/typescript/modules/reorder/Reorder.variants.d.ts +116 -0
- package/lib/typescript/modules/reorder/Reorder.variants.d.ts.map +1 -0
- package/lib/typescript/modules/reorder/index.d.ts +9 -0
- package/lib/typescript/modules/reorder/index.d.ts.map +1 -0
- package/lib/typescript/modules/select/Select.d.ts +31 -0
- package/lib/typescript/modules/select/Select.d.ts.map +1 -0
- package/lib/typescript/modules/select/Select.variants.d.ts +127 -0
- package/lib/typescript/modules/select/Select.variants.d.ts.map +1 -0
- package/lib/typescript/modules/select/index.d.ts +9 -0
- package/lib/typescript/modules/select/index.d.ts.map +1 -0
- package/lib/typescript/modules/skeleton/Skeleton.d.ts +27 -0
- package/lib/typescript/modules/skeleton/Skeleton.d.ts.map +1 -0
- package/lib/typescript/modules/skeleton/Skeleton.variants.d.ts +119 -0
- package/lib/typescript/modules/skeleton/Skeleton.variants.d.ts.map +1 -0
- package/lib/typescript/modules/skeleton/index.d.ts +9 -0
- package/lib/typescript/modules/skeleton/index.d.ts.map +1 -0
- package/lib/typescript/modules/slider/Slider.d.ts +44 -0
- package/lib/typescript/modules/slider/Slider.d.ts.map +1 -0
- package/lib/typescript/modules/slider/Slider.variants.d.ts +211 -0
- package/lib/typescript/modules/slider/Slider.variants.d.ts.map +1 -0
- package/lib/typescript/modules/slider/index.d.ts +9 -0
- package/lib/typescript/modules/slider/index.d.ts.map +1 -0
- package/lib/typescript/modules/spinner/Spinner.d.ts +19 -0
- package/lib/typescript/modules/spinner/Spinner.d.ts.map +1 -0
- package/lib/typescript/modules/spinner/Spinner.variants.d.ts +113 -0
- package/lib/typescript/modules/spinner/Spinner.variants.d.ts.map +1 -0
- package/lib/typescript/modules/spinner/index.d.ts +10 -0
- package/lib/typescript/modules/spinner/index.d.ts.map +1 -0
- package/lib/typescript/modules/stepper/Stepper.d.ts +26 -0
- package/lib/typescript/modules/stepper/Stepper.d.ts.map +1 -0
- package/lib/typescript/modules/stepper/Stepper.variants.d.ts +107 -0
- package/lib/typescript/modules/stepper/Stepper.variants.d.ts.map +1 -0
- package/lib/typescript/modules/stepper/index.d.ts +8 -0
- package/lib/typescript/modules/stepper/index.d.ts.map +1 -0
- package/lib/typescript/modules/switch/Switch.d.ts +22 -0
- package/lib/typescript/modules/switch/Switch.d.ts.map +1 -0
- package/lib/typescript/modules/switch/Switch.variants.d.ts +60 -0
- package/lib/typescript/modules/switch/Switch.variants.d.ts.map +1 -0
- package/lib/typescript/modules/switch/index.d.ts +8 -0
- package/lib/typescript/modules/switch/index.d.ts.map +1 -0
- package/lib/typescript/modules/tabs/Tabs.d.ts +31 -0
- package/lib/typescript/modules/tabs/Tabs.d.ts.map +1 -0
- package/lib/typescript/modules/tabs/Tabs.variants.d.ts +114 -0
- package/lib/typescript/modules/tabs/Tabs.variants.d.ts.map +1 -0
- package/lib/typescript/modules/tabs/index.d.ts +10 -0
- package/lib/typescript/modules/tabs/index.d.ts.map +1 -0
- package/lib/typescript/modules/textarea/Textarea.d.ts +25 -0
- package/lib/typescript/modules/textarea/Textarea.d.ts.map +1 -0
- package/lib/typescript/modules/textarea/Textarea.variants.d.ts +99 -0
- package/lib/typescript/modules/textarea/Textarea.variants.d.ts.map +1 -0
- package/lib/typescript/modules/textarea/index.d.ts +9 -0
- package/lib/typescript/modules/textarea/index.d.ts.map +1 -0
- package/lib/typescript/modules/timeline/Timeline.d.ts +28 -0
- package/lib/typescript/modules/timeline/Timeline.d.ts.map +1 -0
- package/lib/typescript/modules/timeline/Timeline.variants.d.ts +103 -0
- package/lib/typescript/modules/timeline/Timeline.variants.d.ts.map +1 -0
- package/lib/typescript/modules/timeline/index.d.ts +9 -0
- package/lib/typescript/modules/timeline/index.d.ts.map +1 -0
- package/lib/typescript/modules/toast/Toast.d.ts +38 -0
- package/lib/typescript/modules/toast/Toast.d.ts.map +1 -0
- package/lib/typescript/modules/toast/Toast.variants.d.ts +80 -0
- package/lib/typescript/modules/toast/Toast.variants.d.ts.map +1 -0
- package/lib/typescript/modules/toast/index.d.ts +12 -0
- package/lib/typescript/modules/toast/index.d.ts.map +1 -0
- package/lib/typescript/modules/tooltip/Tooltip.d.ts +31 -0
- package/lib/typescript/modules/tooltip/Tooltip.d.ts.map +1 -0
- package/lib/typescript/modules/tooltip/Tooltip.variants.d.ts +52 -0
- package/lib/typescript/modules/tooltip/Tooltip.variants.d.ts.map +1 -0
- package/lib/typescript/modules/tooltip/index.d.ts +9 -0
- package/lib/typescript/modules/tooltip/index.d.ts.map +1 -0
- package/lib/typescript/package.json +1 -0
- package/lib/typescript/theme/index.d.ts +11 -0
- package/lib/typescript/theme/index.d.ts.map +1 -0
- package/lib/typescript/theme/platform/colorScheme.native.d.ts +12 -0
- package/lib/typescript/theme/platform/colorScheme.native.d.ts.map +1 -0
- package/lib/typescript/theme/platform/elevation.native.d.ts +35 -0
- package/lib/typescript/theme/platform/elevation.native.d.ts.map +1 -0
- package/lib/typescript/theme/platform/fonts.native.d.ts +41 -0
- package/lib/typescript/theme/platform/fonts.native.d.ts.map +1 -0
- package/lib/typescript/theme/platform/index.d.ts +15 -0
- package/lib/typescript/theme/platform/index.d.ts.map +1 -0
- package/lib/typescript/theme/platform/units.native.d.ts +13 -0
- package/lib/typescript/theme/platform/units.native.d.ts.map +1 -0
- package/lib/typescript/theme/provider/PixelizeProvider.d.ts +81 -0
- package/lib/typescript/theme/provider/PixelizeProvider.d.ts.map +1 -0
- package/lib/typescript/theme/provider/colorModeStorage.d.ts +43 -0
- package/lib/typescript/theme/provider/colorModeStorage.d.ts.map +1 -0
- package/lib/typescript/theme/provider/index.d.ts +8 -0
- package/lib/typescript/theme/provider/index.d.ts.map +1 -0
- package/lib/typescript/theme/provider/useTheme.d.ts +4 -0
- package/lib/typescript/theme/provider/useTheme.d.ts.map +1 -0
- package/lib/typescript/theme/provider/useThemeColors.d.ts +9 -0
- package/lib/typescript/theme/provider/useThemeColors.d.ts.map +1 -0
- package/lib/typescript/theme/provider/useThemeMode.d.ts +4 -0
- package/lib/typescript/theme/provider/useThemeMode.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/emerald/palette.dark.d.ts +3 -0
- package/lib/typescript/theme/tokens/brands/emerald/palette.dark.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/emerald/palette.light.d.ts +4 -0
- package/lib/typescript/theme/tokens/brands/emerald/palette.light.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/index.d.ts +30 -0
- package/lib/typescript/theme/tokens/brands/index.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/lavender/palette.dark.d.ts +3 -0
- package/lib/typescript/theme/tokens/brands/lavender/palette.dark.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/lavender/palette.light.d.ts +4 -0
- package/lib/typescript/theme/tokens/brands/lavender/palette.light.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/meadow/palette.dark.d.ts +3 -0
- package/lib/typescript/theme/tokens/brands/meadow/palette.dark.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/meadow/palette.light.d.ts +4 -0
- package/lib/typescript/theme/tokens/brands/meadow/palette.light.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/radiant/palette.dark.d.ts +3 -0
- package/lib/typescript/theme/tokens/brands/radiant/palette.dark.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/radiant/palette.light.d.ts +4 -0
- package/lib/typescript/theme/tokens/brands/radiant/palette.light.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/rosewood/palette.dark.d.ts +3 -0
- package/lib/typescript/theme/tokens/brands/rosewood/palette.dark.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/rosewood/palette.light.d.ts +4 -0
- package/lib/typescript/theme/tokens/brands/rosewood/palette.light.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/skyline/palette.dark.d.ts +3 -0
- package/lib/typescript/theme/tokens/brands/skyline/palette.dark.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/skyline/palette.light.d.ts +4 -0
- package/lib/typescript/theme/tokens/brands/skyline/palette.light.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/slate/palette.dark.d.ts +3 -0
- package/lib/typescript/theme/tokens/brands/slate/palette.dark.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/slate/palette.light.d.ts +4 -0
- package/lib/typescript/theme/tokens/brands/slate/palette.light.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/storefront/palette.dark.d.ts +3 -0
- package/lib/typescript/theme/tokens/brands/storefront/palette.dark.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/storefront/palette.light.d.ts +4 -0
- package/lib/typescript/theme/tokens/brands/storefront/palette.light.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/zinc/palette.dark.d.ts +4 -0
- package/lib/typescript/theme/tokens/brands/zinc/palette.dark.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/brands/zinc/palette.light.d.ts +4 -0
- package/lib/typescript/theme/tokens/brands/zinc/palette.light.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/builders/accentText.d.ts +42 -0
- package/lib/typescript/theme/tokens/builders/accentText.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/builders/buildBrandTokens.d.ts +21 -0
- package/lib/typescript/theme/tokens/builders/buildBrandTokens.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/builders/buildDarkPalette.d.ts +13 -0
- package/lib/typescript/theme/tokens/builders/buildDarkPalette.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/builders/color.d.ts +59 -0
- package/lib/typescript/theme/tokens/builders/color.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/index.d.ts +21 -0
- package/lib/typescript/theme/tokens/index.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/primitives/borderWidths.d.ts +15 -0
- package/lib/typescript/theme/tokens/primitives/borderWidths.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/primitives/breakpoints.d.ts +17 -0
- package/lib/typescript/theme/tokens/primitives/breakpoints.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/primitives/elevation.d.ts +109 -0
- package/lib/typescript/theme/tokens/primitives/elevation.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/primitives/fontSizes.d.ts +21 -0
- package/lib/typescript/theme/tokens/primitives/fontSizes.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/primitives/fontWeights.d.ts +21 -0
- package/lib/typescript/theme/tokens/primitives/fontWeights.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/primitives/index.d.ts +23 -0
- package/lib/typescript/theme/tokens/primitives/index.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/primitives/letterSpacings.d.ts +17 -0
- package/lib/typescript/theme/tokens/primitives/letterSpacings.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/primitives/lineHeights.d.ts +20 -0
- package/lib/typescript/theme/tokens/primitives/lineHeights.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/primitives/radii.d.ts +20 -0
- package/lib/typescript/theme/tokens/primitives/radii.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/primitives/sizes.d.ts +33 -0
- package/lib/typescript/theme/tokens/primitives/sizes.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/primitives/space.d.ts +29 -0
- package/lib/typescript/theme/tokens/primitives/space.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/primitives/zIndices.d.ts +22 -0
- package/lib/typescript/theme/tokens/primitives/zIndices.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/roles/index.d.ts +68 -0
- package/lib/typescript/theme/tokens/roles/index.d.ts.map +1 -0
- package/lib/typescript/theme/tokens/types.d.ts +103 -0
- package/lib/typescript/theme/tokens/types.d.ts.map +1 -0
- package/package.json +259 -0
- package/registry.json +175 -0
|
@@ -0,0 +1,178 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Toast — a `ToastProvider` + `useToast()` hook, not a component a consumer places directly (it has
|
|
5
|
+
* no visual home of its own to lay out: it always floats above whatever the provider wraps). Every
|
|
6
|
+
* screen mounts `ToastProvider` once, near the root; any descendant calls `useToast().show(...)`.
|
|
7
|
+
*
|
|
8
|
+
* Deliberately NOT React Native's `<Modal>`: a confirmed iOS bug drops or breaks a second `<Modal>`
|
|
9
|
+
* presented while a sibling Modal — this library's own, or an OS share sheet — is still mounted or
|
|
10
|
+
* mid-dismiss-animation, so a toast shown over one would silently fail. The overlay is instead a
|
|
11
|
+
* plain absolutely-positioned `View` mounted at the provider's own root, entirely outside RN's Modal
|
|
12
|
+
* system, so it floats over anything without competing for the same presentation stack.
|
|
13
|
+
*
|
|
14
|
+
* Single-slot by design: `show()` while a toast is already visible replaces its message/tone and
|
|
15
|
+
* restarts the auto-dismiss timer (and, since a fresh message reads as a new event, restarts the
|
|
16
|
+
* entrance animation) rather than queueing a second one. `dismiss()` always dismisses that one slot,
|
|
17
|
+
* and is a safe no-op when nothing is showing.
|
|
18
|
+
*/
|
|
19
|
+
|
|
20
|
+
import { createContext, memo, useCallback, useContext, useEffect, useMemo, useRef, useState } from "react";
|
|
21
|
+
import { AccessibilityInfo, Animated, Pressable, StyleSheet, Text, View } from "react-native";
|
|
22
|
+
import { useReducedMotion } from "../../core/a11y/index.js";
|
|
23
|
+
import { Icon } from "../../core/icon/index.js";
|
|
24
|
+
import { useTheme } from "../../theme/index.js";
|
|
25
|
+
import { CLOSE_BUTTON_SIZE, CLOSE_HIT_SLOP, CLOSE_ICON_SIZE, DEFAULT_TOAST_DURATION, resolveToastTone, toastAccentBarStructure, toastCardStructure, toastOverlayStructure } from "./Toast.variants.js";
|
|
26
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
27
|
+
// The entrance/exit fade+slide duration, and how far the card travels while animating in. Component
|
|
28
|
+
// design constants — not on the theme's numeric scale, same status `PRESS_FADE_MS` etc. have in
|
|
29
|
+
// `Button.tsx`.
|
|
30
|
+
const ANIMATION_MS = 200;
|
|
31
|
+
const TRANSLATE_DISTANCE = 24;
|
|
32
|
+
const ToastContext = /*#__PURE__*/createContext(undefined);
|
|
33
|
+
export const ToastProvider = /*#__PURE__*/memo(function ToastProvider({
|
|
34
|
+
children,
|
|
35
|
+
position = "top"
|
|
36
|
+
}) {
|
|
37
|
+
const theme = useTheme();
|
|
38
|
+
const reducedMotion = useReducedMotion();
|
|
39
|
+
const [toast, setToast] = useState(null);
|
|
40
|
+
const progress = useRef(new Animated.Value(0)).current;
|
|
41
|
+
const dismissTimer = useRef(null);
|
|
42
|
+
const unmountTimer = useRef(null);
|
|
43
|
+
const clearTimers = useCallback(() => {
|
|
44
|
+
if (dismissTimer.current !== null) clearTimeout(dismissTimer.current);
|
|
45
|
+
if (unmountTimer.current !== null) clearTimeout(unmountTimer.current);
|
|
46
|
+
dismissTimer.current = null;
|
|
47
|
+
unmountTimer.current = null;
|
|
48
|
+
}, []);
|
|
49
|
+
|
|
50
|
+
// The unmount is scheduled on its own plain timer rather than the `Animated.timing` completion
|
|
51
|
+
// callback: that callback rides `requestAnimationFrame` (even under `useNativeDriver`), which does
|
|
52
|
+
// not resolve on a predictable JS-timer tick in tests (or match a plain `setTimeout` on-device) —
|
|
53
|
+
// a second timer of the same duration keeps the removal deterministic everywhere.
|
|
54
|
+
const hide = useCallback(() => {
|
|
55
|
+
clearTimers();
|
|
56
|
+
Animated.timing(progress, {
|
|
57
|
+
toValue: 0,
|
|
58
|
+
duration: reducedMotion ? 0 : ANIMATION_MS,
|
|
59
|
+
useNativeDriver: true
|
|
60
|
+
}).start();
|
|
61
|
+
unmountTimer.current = setTimeout(() => setToast(null), reducedMotion ? 0 : ANIMATION_MS);
|
|
62
|
+
}, [clearTimers, progress, reducedMotion]);
|
|
63
|
+
const show = useCallback(options => {
|
|
64
|
+
clearTimers();
|
|
65
|
+
progress.setValue(0);
|
|
66
|
+
setToast({
|
|
67
|
+
message: options.message,
|
|
68
|
+
tone: options.tone ?? "neutral"
|
|
69
|
+
});
|
|
70
|
+
// The real cross-platform screen-reader announcement: `accessibilityLiveRegion` (see
|
|
71
|
+
// `ToastCard`'s Text) is Android-only, so it alone leaves iOS VoiceOver silent. This
|
|
72
|
+
// imperative call reaches both VoiceOver and TalkBack.
|
|
73
|
+
AccessibilityInfo.announceForAccessibility(options.message);
|
|
74
|
+
Animated.timing(progress, {
|
|
75
|
+
toValue: 1,
|
|
76
|
+
duration: reducedMotion ? 0 : ANIMATION_MS,
|
|
77
|
+
useNativeDriver: true
|
|
78
|
+
}).start();
|
|
79
|
+
dismissTimer.current = setTimeout(hide, options.duration ?? DEFAULT_TOAST_DURATION);
|
|
80
|
+
}, [clearTimers, hide, progress, reducedMotion]);
|
|
81
|
+
|
|
82
|
+
// Unmount-only cleanup: `clearTimers` is referentially stable (empty deps), so this never re-fires.
|
|
83
|
+
useEffect(() => clearTimers, [clearTimers]);
|
|
84
|
+
const contextValue = useMemo(() => ({
|
|
85
|
+
show,
|
|
86
|
+
dismiss: hide
|
|
87
|
+
}), [show, hide]);
|
|
88
|
+
return /*#__PURE__*/_jsxs(ToastContext.Provider, {
|
|
89
|
+
value: contextValue,
|
|
90
|
+
children: [children, /*#__PURE__*/_jsx(View, {
|
|
91
|
+
pointerEvents: "box-none",
|
|
92
|
+
style: toastOverlayStructure(theme, {
|
|
93
|
+
position
|
|
94
|
+
}),
|
|
95
|
+
children: toast !== null && /*#__PURE__*/_jsx(ToastCard, {
|
|
96
|
+
toast: toast,
|
|
97
|
+
theme: theme,
|
|
98
|
+
position: position,
|
|
99
|
+
progress: progress,
|
|
100
|
+
onDismiss: hide
|
|
101
|
+
})
|
|
102
|
+
})]
|
|
103
|
+
});
|
|
104
|
+
});
|
|
105
|
+
// Memoized like any other of this library's own child components: `ToastProvider` hands it
|
|
106
|
+
// already-stable props (state, refs, and `hide`'s own `useCallback`), so this avoids re-rendering
|
|
107
|
+
// the card on a `ToastProvider` re-render that didn't actually change any of them.
|
|
108
|
+
const ToastCard = /*#__PURE__*/memo(function ToastCard({
|
|
109
|
+
toast,
|
|
110
|
+
theme,
|
|
111
|
+
position,
|
|
112
|
+
progress,
|
|
113
|
+
onDismiss
|
|
114
|
+
}) {
|
|
115
|
+
const toneColors = resolveToastTone(theme.colors, toast.tone);
|
|
116
|
+
const translateY = progress.interpolate({
|
|
117
|
+
inputRange: [0, 1],
|
|
118
|
+
outputRange: position === "top" ? [-TRANSLATE_DISTANCE, 0] : [TRANSLATE_DISTANCE, 0]
|
|
119
|
+
});
|
|
120
|
+
return /*#__PURE__*/_jsxs(Animated.View, {
|
|
121
|
+
testID: "pixelize-toast",
|
|
122
|
+
accessibilityRole: "alert",
|
|
123
|
+
style: [toastCardStructure(theme), {
|
|
124
|
+
backgroundColor: toneColors.background
|
|
125
|
+
}, theme.elevation.lg, {
|
|
126
|
+
opacity: progress,
|
|
127
|
+
transform: [{
|
|
128
|
+
translateY
|
|
129
|
+
}]
|
|
130
|
+
}],
|
|
131
|
+
children: [/*#__PURE__*/_jsx(View, {
|
|
132
|
+
style: [toastAccentBarStructure(theme), {
|
|
133
|
+
backgroundColor: toneColors.accent
|
|
134
|
+
}]
|
|
135
|
+
}), /*#__PURE__*/_jsx(Text, {
|
|
136
|
+
numberOfLines: 3,
|
|
137
|
+
style: [theme.fontStyleForWeight(theme.fontWeights.medium), styles.message, {
|
|
138
|
+
fontSize: theme.fontSizes.sm,
|
|
139
|
+
color: toneColors.text
|
|
140
|
+
}],
|
|
141
|
+
children: toast.message
|
|
142
|
+
}), /*#__PURE__*/_jsx(Pressable, {
|
|
143
|
+
testID: "pixelize-toast-close",
|
|
144
|
+
accessibilityRole: "button",
|
|
145
|
+
accessibilityLabel: "Dismiss notification",
|
|
146
|
+
hitSlop: CLOSE_HIT_SLOP,
|
|
147
|
+
onPress: onDismiss,
|
|
148
|
+
style: styles.closeButton,
|
|
149
|
+
children: /*#__PURE__*/_jsx(Icon, {
|
|
150
|
+
name: "x",
|
|
151
|
+
size: CLOSE_ICON_SIZE,
|
|
152
|
+
color: theme.colors.fg.muted,
|
|
153
|
+
strokeWidth: 2
|
|
154
|
+
})
|
|
155
|
+
})]
|
|
156
|
+
});
|
|
157
|
+
});
|
|
158
|
+
|
|
159
|
+
/** Throws outside a `ToastProvider` — same contract as `useTheme()`. */
|
|
160
|
+
export function useToast() {
|
|
161
|
+
const ctx = useContext(ToastContext);
|
|
162
|
+
if (!ctx) {
|
|
163
|
+
throw new Error("useToast must be used inside <ToastProvider>. Wrap your app in " + "<ToastProvider> from 'pixelize-native-library/toast'.");
|
|
164
|
+
}
|
|
165
|
+
return ctx;
|
|
166
|
+
}
|
|
167
|
+
const styles = StyleSheet.create({
|
|
168
|
+
message: {
|
|
169
|
+
flex: 1
|
|
170
|
+
},
|
|
171
|
+
closeButton: {
|
|
172
|
+
width: CLOSE_BUTTON_SIZE,
|
|
173
|
+
height: CLOSE_BUTTON_SIZE,
|
|
174
|
+
alignItems: "center",
|
|
175
|
+
justifyContent: "center"
|
|
176
|
+
}
|
|
177
|
+
});
|
|
178
|
+
//# sourceMappingURL=Toast.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["createContext","memo","useCallback","useContext","useEffect","useMemo","useRef","useState","AccessibilityInfo","Animated","Pressable","StyleSheet","Text","View","useReducedMotion","Icon","useTheme","CLOSE_BUTTON_SIZE","CLOSE_HIT_SLOP","CLOSE_ICON_SIZE","DEFAULT_TOAST_DURATION","resolveToastTone","toastAccentBarStructure","toastCardStructure","toastOverlayStructure","jsx","_jsx","jsxs","_jsxs","ANIMATION_MS","TRANSLATE_DISTANCE","ToastContext","undefined","ToastProvider","children","position","theme","reducedMotion","toast","setToast","progress","Value","current","dismissTimer","unmountTimer","clearTimers","clearTimeout","hide","timing","toValue","duration","useNativeDriver","start","setTimeout","show","options","setValue","message","tone","announceForAccessibility","contextValue","dismiss","Provider","value","pointerEvents","style","ToastCard","onDismiss","toneColors","colors","translateY","interpolate","inputRange","outputRange","testID","accessibilityRole","backgroundColor","background","elevation","lg","opacity","transform","accent","numberOfLines","fontStyleForWeight","fontWeights","medium","styles","fontSize","fontSizes","sm","color","text","accessibilityLabel","hitSlop","onPress","closeButton","name","size","fg","muted","strokeWidth","useToast","ctx","Error","create","flex","width","height","alignItems","justifyContent"],"sourceRoot":"../../../../src","sources":["modules/toast/Toast.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,aAAa,EAAEC,IAAI,EAAEC,WAAW,EAAEC,UAAU,EAAEC,SAAS,EAAEC,OAAO,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AAE1G,SAASC,iBAAiB,EAAEC,QAAQ,EAAEC,SAAS,EAAEC,UAAU,EAAEC,IAAI,EAAEC,IAAI,QAAQ,cAAc;AAE7F,SAASC,gBAAgB,QAAQ,0BAAiB;AAClD,SAASC,IAAI,QAAQ,0BAAiB;AAEtC,SAASC,QAAQ,QAAQ,sBAAa;AAEtC,SACEC,iBAAiB,EACjBC,cAAc,EACdC,eAAe,EACfC,sBAAsB,EACtBC,gBAAgB,EAChBC,uBAAuB,EACvBC,kBAAkB,EAClBC,qBAAqB,QAChB,qBAAkB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AA2B1B;AACA;AACA;AACA,MAAMC,YAAY,GAAG,GAAG;AACxB,MAAMC,kBAAkB,GAAG,EAAE;AAE7B,MAAMC,YAAY,gBAAG/B,aAAa,CAAgCgC,SAAS,CAAC;AAE5E,OAAO,MAAMC,aAAa,gBAAGhC,IAAI,CAAC,SAASgC,aAAaA,CAAC;EACvDC,QAAQ;EACRC,QAAQ,GAAG;AACO,CAAC,EAAE;EACrB,MAAMC,KAAK,GAAGpB,QAAQ,CAAC,CAAC;EACxB,MAAMqB,aAAa,GAAGvB,gBAAgB,CAA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
* - STRUCTURE (padding, radius, gap, the accent bar's width, the overlay's edge inset, the overlay's
|
|
6
|
+
* z-index) lives in the themed resolvers below, static per (brand, mode), registered once via
|
|
7
|
+
* `StyleSheet.create`.
|
|
8
|
+
* - COLOUR is `tone`-driven and resolved from the theme's ROLE colours by `resolveToastTone`, never
|
|
9
|
+
* a raw ramp and never a hardcoded hex.
|
|
10
|
+
* - ACCESSIBILITY: the screen-reader announcement (WCAG 4.1.3) is one cross-platform imperative
|
|
11
|
+
* `AccessibilityInfo.announceForAccessibility` call in `Toast.tsx`'s `show()`, not a tone-driven
|
|
12
|
+
* resolver here — every tone announces the same way.
|
|
13
|
+
*
|
|
14
|
+
* Free of React and of `lucide`, so the WCAG + behaviour tests import it directly (mocking only
|
|
15
|
+
* `react-native`'s `StyleSheet`, as `core/style` does).
|
|
16
|
+
*/
|
|
17
|
+
|
|
18
|
+
import { createThemedVariants } from "../../core/style/index.js";
|
|
19
|
+
/** Same floor as Button/Input/Checkbox — 44dp (WCAG 2.5.5 / HIG). Duplicated, not imported: modules
|
|
20
|
+
* stay isolated. */
|
|
21
|
+
export const MIN_TOUCH_TARGET = 44;
|
|
22
|
+
const slopFor = size => Math.max(0, Math.ceil((MIN_TOUCH_TARGET - size) / 2));
|
|
23
|
+
|
|
24
|
+
/** The close button's own visual box + glyph. Toast takes no `size` prop, so this is a fixed pair,
|
|
25
|
+
* not a scale — mirrors `BUTTON_SIZES`' shape for exactly one size. */
|
|
26
|
+
export const CLOSE_BUTTON_SIZE = 24;
|
|
27
|
+
export const CLOSE_ICON_SIZE = 16;
|
|
28
|
+
export const CLOSE_HIT_SLOP = slopFor(CLOSE_BUTTON_SIZE);
|
|
29
|
+
|
|
30
|
+
/** `duration?: number` on `ToastOptions` defaults to this when omitted. */
|
|
31
|
+
export const DEFAULT_TOAST_DURATION = 3000;
|
|
32
|
+
/**
|
|
33
|
+
* Maps `tone` onto the theme's role colours. The whole reason the prop is a closed union and not
|
|
34
|
+
* `color?: string`: every colour a Toast can show is one of these role lookups, so it can never be
|
|
35
|
+
* an off-palette value an app invented, and it inverts light↔dark for free.
|
|
36
|
+
*
|
|
37
|
+
* The card always sits on `bg.raised` — the same "elevated surface" role `Card`'s own `elevated`
|
|
38
|
+
* variant uses (`Card.variants.ts`). The accent bar and the message BOTH read `status.<role>.text`,
|
|
39
|
+
* deliberately NOT `status.<role>.solid`: `solid` is only measured against its own pale `subtle` fill
|
|
40
|
+
* (`roleColors.test.ts`'s `status.solid` vs `status.onSolid`/`subtle` promises), and on
|
|
41
|
+
* `success`/`warning`/`info` in light mode it falls as low as ~1.9:1 against `bg.raised` — nowhere
|
|
42
|
+
* near the 3:1 floor a rendered accent bar needs. `text` is the rung `readableOn` already proved
|
|
43
|
+
* ≥ 4.5:1 nearby, which comfortably clears the bar's lighter 3:1 floor too — one role, measured here
|
|
44
|
+
* for both jobs, rather than a second unverified pairing (`Toast.test.ts`).
|
|
45
|
+
*/
|
|
46
|
+
export function resolveToastTone(colors, tone) {
|
|
47
|
+
if (tone === "neutral") {
|
|
48
|
+
return {
|
|
49
|
+
background: colors.bg.raised,
|
|
50
|
+
accent: colors.border.interactive,
|
|
51
|
+
text: colors.fg.default
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
const status = colors.status[tone];
|
|
55
|
+
return {
|
|
56
|
+
background: colors.bg.raised,
|
|
57
|
+
accent: status.text,
|
|
58
|
+
text: status.text
|
|
59
|
+
};
|
|
60
|
+
}
|
|
61
|
+
|
|
62
|
+
/**
|
|
63
|
+
* Structural styles only — the card's padding, radius, and gap. No colour (tone-driven, applied
|
|
64
|
+
* inline over this) and no shadow (elevation is applied directly from `theme.elevation.lg`, same
|
|
65
|
+
* idiom as `Card`), so this compiles once per theme identity via the `WeakMap`-cached themed
|
|
66
|
+
* resolver and never rebuilds per render. `overflow: "hidden"` lets the accent bar's square corners
|
|
67
|
+
* get clipped by the card's own rounding instead of resolving a second radius for the bar.
|
|
68
|
+
*/
|
|
69
|
+
export const toastCardStructure = createThemedVariants(theme => ({
|
|
70
|
+
base: {
|
|
71
|
+
flexDirection: "row",
|
|
72
|
+
alignItems: "center",
|
|
73
|
+
columnGap: theme.space[3],
|
|
74
|
+
borderRadius: theme.radii.md,
|
|
75
|
+
paddingVertical: theme.space[3],
|
|
76
|
+
paddingRight: theme.space[3],
|
|
77
|
+
overflow: "hidden"
|
|
78
|
+
}
|
|
79
|
+
}));
|
|
80
|
+
|
|
81
|
+
/** The accent bar's width — a structural constant on the theme's `space` scale, not a hardcoded dp. */
|
|
82
|
+
export const toastAccentBarStructure = createThemedVariants(theme => ({
|
|
83
|
+
base: {
|
|
84
|
+
width: theme.space[1],
|
|
85
|
+
alignSelf: "stretch"
|
|
86
|
+
}
|
|
87
|
+
}));
|
|
88
|
+
|
|
89
|
+
/**
|
|
90
|
+
* The overlay's inset from the screen edge it hugs, plus its stacking order. `position` is
|
|
91
|
+
* provider-level (one overlay for the whole app), not per-toast, so it lives here as a themed
|
|
92
|
+
* structural variant rather than something `resolveToastTone` touches. `zIndex` is themed (not a
|
|
93
|
+
* per-render inline value) for the same reason as the rest of this file: it's a structural,
|
|
94
|
+
* theme-scoped constant, so it belongs in the cached resolver, not recomputed as a fresh object
|
|
95
|
+
* every render in `Toast.tsx`.
|
|
96
|
+
*/
|
|
97
|
+
export const toastOverlayStructure = createThemedVariants(theme => ({
|
|
98
|
+
base: {
|
|
99
|
+
position: "absolute",
|
|
100
|
+
left: 0,
|
|
101
|
+
right: 0,
|
|
102
|
+
alignItems: "center",
|
|
103
|
+
paddingHorizontal: theme.space[4],
|
|
104
|
+
zIndex: theme.zIndices.toast
|
|
105
|
+
},
|
|
106
|
+
variants: {
|
|
107
|
+
position: {
|
|
108
|
+
top: {
|
|
109
|
+
top: theme.space[4]
|
|
110
|
+
},
|
|
111
|
+
bottom: {
|
|
112
|
+
bottom: theme.space[4]
|
|
113
|
+
}
|
|
114
|
+
}
|
|
115
|
+
},
|
|
116
|
+
defaultVariants: {
|
|
117
|
+
position: "top"
|
|
118
|
+
}
|
|
119
|
+
}));
|
|
120
|
+
//# sourceMappingURL=Toast.variants.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["createThemedVariants","MIN_TOUCH_TARGET","slopFor","size","Math","max","ceil","CLOSE_BUTTON_SIZE","CLOSE_ICON_SIZE","CLOSE_HIT_SLOP","DEFAULT_TOAST_DURATION","resolveToastTone","colors","tone","background","bg","raised","accent","border","interactive","text","fg","default","status","toastCardStructure","theme","base","flexDirection","alignItems","columnGap","space","borderRadius","radii","md","paddingVertical","paddingRight","overflow","toastAccentBarStructure","width","alignSelf","toastOverlayStructure","position","left","right","paddingHorizontal","zIndex","zIndices","toast","variants","top","bottom","defaultVariants"],"sourceRoot":"../../../../src","sources":["modules/toast/Toast.variants.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAIA,SAASA,oBAAoB,QAAQ,2BAAkB;AAKvD;AACA;AACA,OAAO,MAAMC,gBAAgB,GAAG,EAAE;AAClC,MAAMC,OAAO,GAAIC,IAAY,IAAaC,IAAI,CAACC,GAAG,CAAC,CAAC,EAAED,IAAI,CAACE,IAAI,CAAC,CAACL,gBAAgB,GAAGE,IAAI,IAAI,CAAC,CAAC,CAAC;;AAE/F;AACA;AACA,OAAO,MAAMI,iBAAiB,GAAG,EAAE;AACnC,OAAO,MAAMC,eAAe,GAAG,EAAE;AACjC,OAAO,MAAMC,cAAc,GAAGP,OAAO,CAACK,iBAAiB,CAAC;;AAExD;AACA,OAAO,MAAMG,sBAAsB,GAAG,IAAI;AAW1C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,gBAAgBA,CAACC,MAAkB,EAAEC,IAAe,EAAmB;EACrF,IAAIA,IAAI,KAAK,SAAS,EAAE;IACtB,OAAO;MACLC,UAAU,EAAEF,MAAM,CAACG,EAAE,CAACC,MA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AK,CAAC,CAAC,CAAC;IACjCe,MAAM,EAAEpB,KAAK,CAACqB,QAAQ,CAACC;EACzB,CAAC;EACDC,QAAQ,EAAE;IACRP,QAAQ,EAAE;MACRQ,GAAG,EAAE;QAAEA,GAAG,EAAExB,KAAK,CAACK,KAAK,CAAC,CAAC;MAAE,CAAC;MAC5BoB,MAAM,EAAE;QAAEA,MAAM,EAAEzB,KAAK,CAACK,KAAK,CAAC,CAAC;MAAE;IACnC;EACF,CAAC;EACDqB,eAAe,EAAE;IAAEV,QAAQ,EAAE;EAAM;AACrC,CAAC,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Public surface of `pixelize-native-library/toast`. Value exports and type exports are split for
|
|
5
|
+
* `verbatimModuleSyntax`. The pure resolvers (`resolveToastTone`, …) stay internal — a consumer
|
|
6
|
+
* configures a toast through `show(options)`, never by importing them.
|
|
7
|
+
*
|
|
8
|
+
* No `IconName` re-export here: unlike `Button`, Toast takes no public `icon` prop — its dismiss
|
|
9
|
+
* glyph is a fixed internal choice, not something a consumer selects.
|
|
10
|
+
*/
|
|
11
|
+
|
|
12
|
+
export { ToastProvider, useToast } from "./Toast.js";
|
|
13
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["ToastProvider","useToast"],"sourceRoot":"../../../../src","sources":["modules/toast/index.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,aAAa,EAAEC,QAAQ,QAAQ,YAAS","ignoreList":[]}
|
|
@@ -0,0 +1,86 @@
|
|
|
1
|
+
# tooltip/ — a long-press tip that also reaches screen readers without the gesture
|
|
2
|
+
|
|
3
|
+
`Tooltip` wraps a single trigger element (via `React.cloneElement`, never `{...rest}`) and reveals
|
|
4
|
+
a short themed bubble on long-press. It has no visual node of its own for an app to place — the
|
|
5
|
+
trigger keeps its own layout — so, unlike the other modules, it exposes no `style` prop.
|
|
6
|
+
|
|
7
|
+
## Files
|
|
8
|
+
|
|
9
|
+
| File | Role |
|
|
10
|
+
|------|------|
|
|
11
|
+
| `Tooltip.tsx` | The component. `cloneElement` composition, show/hide timing, fade-in, a11y hint wiring. |
|
|
12
|
+
| `Tooltip.variants.ts` | Pure resolvers (`mergeAccessibilityHint`, `TOOLTIP_TIMING`) + the themed structural resolver `tooltipBubbleStructure`. No React, no lucide. |
|
|
13
|
+
| `index.ts` | Public surface: `Tooltip`, `TooltipProps`, `TooltipTriggerProps`, `TooltipPlacement`. |
|
|
14
|
+
| `__tests__/Tooltip.test.ts` | Pure: WCAG contrast (all brands × modes) + the hint-merge contract + timing sanity. |
|
|
15
|
+
| `__tests__/Tooltip.render.test.tsx` | Render: reveal/hide, auto-hide fallback, hint merge, placement. |
|
|
16
|
+
|
|
17
|
+
## Props
|
|
18
|
+
|
|
19
|
+
| Prop | Type | Default | Notes |
|
|
20
|
+
|------|------|---------|-------|
|
|
21
|
+
| `label` | `string` | — | The tip's text. Also what gets merged into the trigger's `accessibilityHint`. |
|
|
22
|
+
| `children` | `ReactElement<TooltipTriggerProps>` | — | A single element accepting `onLongPress`/`onPressOut`/`accessibilityHint` (e.g. a `Pressable`). |
|
|
23
|
+
| `placement` | `top \| bottom` | `bottom` | Which side of the trigger the bubble opens toward. |
|
|
24
|
+
| `testID` | `string` | — | On the host `View`; also seeds `${testID}-bubble` on the visible bubble. |
|
|
25
|
+
|
|
26
|
+
No `style` prop (see the file-header note) and no `tone`/`variant`/`size` — the bubble always
|
|
27
|
+
reads `bg.raised` / `fg.default`, so there is nothing appearance-wise for a caller to choose.
|
|
28
|
+
|
|
29
|
+
## Accessibility contract (WCAG)
|
|
30
|
+
|
|
31
|
+
- **1.3.1 / no gesture-only content** — the whole point of this module: `accessibilityHint` on
|
|
32
|
+
the trigger is set to `mergeAccessibilityHint(existingHint, label)`, so a screen-reader user gets
|
|
33
|
+
the tip's content read out with the trigger itself, with no long-press required. The existing
|
|
34
|
+
hint (if the trigger already had one) is preserved, never overwritten.
|
|
35
|
+
- **1.4.3** — the bubble text (`fg.default` on `bg.raised`) is measured ≥ 4.5:1 for every brand ×
|
|
36
|
+
mode. No non-text/interactive boundary to measure — the bubble has no border.
|
|
37
|
+
- **The bubble is hidden from the accessibility tree** (`accessibilityElementsHidden` +
|
|
38
|
+
`importantForAccessibility="no-hide-descendants"`) once visible — its content already reached
|
|
39
|
+
assistive tech via the merged hint above, so exposing it too would double-announce the same
|
|
40
|
+
text (the same pattern as Button hiding its spinner from AT).
|
|
41
|
+
- **2.3.3** — the fade-in is skipped (`duration: 0`) when `useReducedMotion()` is true; the bubble
|
|
42
|
+
still appears immediately, so reduced motion never means "no tip."
|
|
43
|
+
- **Touch target** — Tooltip renders no interactive control of its own; the trigger child owns its
|
|
44
|
+
own touch target (e.g. an icon `Button` already enforces ≥ 44dp via `hitSlop`).
|
|
45
|
+
|
|
46
|
+
## Patterns copied from Button (the reference module)
|
|
47
|
+
|
|
48
|
+
1. **Structure vs colour split** — the bubble's padding/radius/placement offset live in
|
|
49
|
+
`tooltipBubbleStructure` (`createThemedVariants`); colour is resolved from `RoleColors` inline.
|
|
50
|
+
2. **Pure, testable resolvers** in `Tooltip.variants.ts` — no React/lucide, so the WCAG measurement
|
|
51
|
+
and the hint-merge contract are unit-tested against real palettes, never eyeballed.
|
|
52
|
+
3. **No `{...rest}`** — composition is `React.cloneElement` on the single child (explicitly
|
|
53
|
+
sanctioned as composition, not a rest spread), injecting three named props only.
|
|
54
|
+
4. **Reduced motion respected**, same `useReducedMotion()` seam as Button's press fade.
|
|
55
|
+
|
|
56
|
+
## Design decisions specific to this module
|
|
57
|
+
|
|
58
|
+
- **`onLongPress`/`onPressOut` chain, `accessibilityHint` merges.** The two gesture callbacks call
|
|
59
|
+
the child's own handler first (if any) before doing their job, so Tooltip never silently breaks
|
|
60
|
+
a trigger that already used them. `accessibilityHint` is different: it is a single string, not a
|
|
61
|
+
callback, so "never clobber" means composing the two strings via `mergeAccessibilityHint`, not
|
|
62
|
+
chaining.
|
|
63
|
+
- **No measurement library (v1).** The bubble anchors to the trigger's **left edge** with a fixed
|
|
64
|
+
`theme.space[1]` gap above/below (`left: 0`, `top`/`bottom: 100%`), rather than centering under
|
|
65
|
+
the trigger's actual measured width. This is the sanctioned v1 simplification; it can read
|
|
66
|
+
slightly off-center under a wide trigger. A `Popover`-style measured-anchor module would be the
|
|
67
|
+
place to fix that, not a prop added here.
|
|
68
|
+
- **`sizes["3xs"]`** (the smallest step of the shared `sizes` primitive, 224dp) caps the bubble's
|
|
69
|
+
width instead of a newly-invented magic number.
|
|
70
|
+
- **Auto-hide fallback** (`TOOLTIP_TIMING.autoHideMs`, 2.5s) — guards against the tip staying open
|
|
71
|
+
forever if `onPressOut` never fires (a cancelled gesture, or assistive tech invoking
|
|
72
|
+
`onLongPress` directly without a matching press-out).
|
|
73
|
+
|
|
74
|
+
## Known gaps
|
|
75
|
+
|
|
76
|
+
- **Requires a trigger that forwards `onLongPress`/`onPressOut`/`accessibilityHint`.** A library
|
|
77
|
+
component with a closed prop contract that doesn't expose those props (e.g. this library's own
|
|
78
|
+
`Button` today) won't actually receive the gesture or the hint merge — `cloneElement` sets the
|
|
79
|
+
props on the element, but a component that destructures its own explicit prop list and ignores
|
|
80
|
+
unknown ones will simply drop them. Works today with a raw RN `Pressable`/`TouchableOpacity`, or
|
|
81
|
+
any future library component that adds these to its explicit prop list.
|
|
82
|
+
- No collision/viewport-edge detection — a bubble near a screen edge is not repositioned inward.
|
|
83
|
+
|
|
84
|
+
## Performance
|
|
85
|
+
|
|
86
|
+
Wrapped in `React.memo` (repo-wide re-render audit, 2026-07-17 — see root `CLAUDE.md`). `clearHideTimer`/`hide`/`show` are `useCallback`'d, and the `onLongPress`/`onPressOut` handlers `cloneElement` injects into the consumer-supplied `children` trigger are extracted to `handleLongPress`/`handlePressOut` (`useCallback`) instead of inline lambdas — same idiom `Menu.tsx` uses for its own trigger, since a fresh closure there would defeat a memoized trigger (e.g. this library's own `Button`).
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Tooltip — wraps a single trigger element and reveals a short themed tip on long-press, without
|
|
5
|
+
* requiring the trigger to know anything about it. No `style` prop: unlike the other modules,
|
|
6
|
+
* Tooltip renders no sized node of its own for an app to place — the trigger child keeps whatever
|
|
7
|
+
* layout it already has, and the wrapping host below exists only to anchor the bubble.
|
|
8
|
+
*
|
|
9
|
+
* Composition is `React.cloneElement` on the single child, never `{...rest}`: `onLongPress` and
|
|
10
|
+
* `onPressOut` are injected (chaining any handler the child already defined, so Tooltip never
|
|
11
|
+
* silently breaks a trigger that already used them), and `accessibilityHint` is MERGED via
|
|
12
|
+
* `mergeAccessibilityHint` — the one prop that must never be clobbered, since it is how a
|
|
13
|
+
* screen-reader user gets the tip's content without performing the gesture at all.
|
|
14
|
+
*/
|
|
15
|
+
|
|
16
|
+
import { cloneElement, memo, useCallback, useEffect, useRef, useState } from "react";
|
|
17
|
+
import { Animated, StyleSheet, Text, View } from "react-native";
|
|
18
|
+
import { useReducedMotion } from "../../core/a11y/index.js";
|
|
19
|
+
import { useTheme } from "../../theme/index.js";
|
|
20
|
+
import { mergeAccessibilityHint, TOOLTIP_TIMING, tooltipBubbleStructure } from "./Tooltip.variants.js";
|
|
21
|
+
|
|
22
|
+
/** The subset of props Tooltip reads from / injects into its trigger child. */
|
|
23
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
24
|
+
export const Tooltip = /*#__PURE__*/memo(function Tooltip({
|
|
25
|
+
label,
|
|
26
|
+
children,
|
|
27
|
+
placement = "bottom",
|
|
28
|
+
testID
|
|
29
|
+
}) {
|
|
30
|
+
const theme = useTheme();
|
|
31
|
+
const reducedMotion = useReducedMotion();
|
|
32
|
+
const [visible, setVisible] = useState(false);
|
|
33
|
+
const opacity = useRef(new Animated.Value(0)).current;
|
|
34
|
+
const hideTimer = useRef(null);
|
|
35
|
+
const clearHideTimer = useCallback(() => {
|
|
36
|
+
if (hideTimer.current !== null) {
|
|
37
|
+
clearTimeout(hideTimer.current);
|
|
38
|
+
hideTimer.current = null;
|
|
39
|
+
}
|
|
40
|
+
}, []);
|
|
41
|
+
const hide = useCallback(() => {
|
|
42
|
+
clearHideTimer();
|
|
43
|
+
setVisible(false);
|
|
44
|
+
}, [clearHideTimer]);
|
|
45
|
+
const show = useCallback(() => {
|
|
46
|
+
clearHideTimer();
|
|
47
|
+
setVisible(true);
|
|
48
|
+
opacity.setValue(reducedMotion ? 1 : 0);
|
|
49
|
+
Animated.timing(opacity, {
|
|
50
|
+
toValue: 1,
|
|
51
|
+
duration: reducedMotion ? 0 : TOOLTIP_TIMING.fadeInMs,
|
|
52
|
+
useNativeDriver: true
|
|
53
|
+
}).start();
|
|
54
|
+
// Fallback dismiss: guarantees the tip can't get stuck open if `onPressOut` never fires (e.g.
|
|
55
|
+
// the gesture is cancelled by a scroll, or assistive tech triggers `onLongPress` directly).
|
|
56
|
+
hideTimer.current = setTimeout(hide, TOOLTIP_TIMING.autoHideMs);
|
|
57
|
+
}, [clearHideTimer, hide, opacity, reducedMotion]);
|
|
58
|
+
useEffect(() => clearHideTimer, [clearHideTimer]);
|
|
59
|
+
|
|
60
|
+
// Passed to `children` — a consumer-supplied CHILD component (typically this library's own
|
|
61
|
+
// Pressable/Button) — via cloneElement, so it is memoized like any other child-bound callback
|
|
62
|
+
// (same idiom `Menu.tsx` uses for its own trigger).
|
|
63
|
+
const handleLongPress = useCallback(event => {
|
|
64
|
+
children.props.onLongPress?.(event);
|
|
65
|
+
show();
|
|
66
|
+
}, [children, show]);
|
|
67
|
+
const handlePressOut = useCallback(event => {
|
|
68
|
+
children.props.onPressOut?.(event);
|
|
69
|
+
hide();
|
|
70
|
+
}, [children, hide]);
|
|
71
|
+
const trigger = /*#__PURE__*/cloneElement(children, {
|
|
72
|
+
onLongPress: handleLongPress,
|
|
73
|
+
onPressOut: handlePressOut,
|
|
74
|
+
accessibilityHint: mergeAccessibilityHint(children.props.accessibilityHint, label)
|
|
75
|
+
});
|
|
76
|
+
return /*#__PURE__*/_jsxs(View, {
|
|
77
|
+
style: styles.host,
|
|
78
|
+
testID: testID,
|
|
79
|
+
children: [trigger, visible &&
|
|
80
|
+
/*#__PURE__*/
|
|
81
|
+
// Hidden from the accessibility tree on purpose: the tip's content already reached
|
|
82
|
+
// screen-reader users via the merged `accessibilityHint` above, so surfacing this bubble
|
|
83
|
+
// too would announce the same text twice (the same "hide the sighted-only echo" pattern
|
|
84
|
+
// as Button's spinner).
|
|
85
|
+
_jsx(Animated.View, {
|
|
86
|
+
testID: testID ? `${testID}-bubble` : undefined,
|
|
87
|
+
pointerEvents: "none",
|
|
88
|
+
accessibilityElementsHidden: true,
|
|
89
|
+
importantForAccessibility: "no-hide-descendants",
|
|
90
|
+
style: [tooltipBubbleStructure(theme, {
|
|
91
|
+
placement
|
|
92
|
+
}), {
|
|
93
|
+
backgroundColor: theme.colors.bg.raised,
|
|
94
|
+
opacity,
|
|
95
|
+
zIndex: theme.zIndices.tooltip
|
|
96
|
+
}],
|
|
97
|
+
children: /*#__PURE__*/_jsx(Text, {
|
|
98
|
+
style: [theme.fontStyleForWeight(theme.fontWeights.regular), {
|
|
99
|
+
fontSize: theme.fontSizes.sm,
|
|
100
|
+
color: theme.colors.fg.default
|
|
101
|
+
}],
|
|
102
|
+
children: label
|
|
103
|
+
})
|
|
104
|
+
})]
|
|
105
|
+
});
|
|
106
|
+
});
|
|
107
|
+
const styles = StyleSheet.create({
|
|
108
|
+
// `flex-start`: hugs the trigger's own size instead of stretching cross-axis in a flex parent,
|
|
109
|
+
// so wrapping a child in Tooltip changes its layout as little as possible.
|
|
110
|
+
host: {
|
|
111
|
+
position: "relative",
|
|
112
|
+
alignSelf: "flex-start"
|
|
113
|
+
}
|
|
114
|
+
});
|
|
115
|
+
//# sourceMappingURL=Tooltip.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["cloneElement","memo","useCallback","useEffect","useRef","useState","Animated","StyleSheet","Text","View","useReducedMotion","useTheme","mergeAccessibilityHint","TOOLTIP_TIMING","tooltipBubbleStructure","jsx","_jsx","jsxs","_jsxs","Tooltip","label","children","placement","testID","theme","reducedMotion","visible","setVisible","opacity","Value","current","hideTimer","clearHideTimer","clearTimeout","hide","show","setValue","timing","toValue","duration","fadeInMs","useNativeDriver","start","setTimeout","autoHideMs","handleLongPress","event","props","onLongPress","handlePressOut","onPressOut","trigger","accessibilityHint","style","styles","host","undefined","pointerEvents","accessibilityElementsHidden","importantForAccessibility","backgroundColor","colors","bg","raised","zIndex","zIndices","tooltip","fontStyleForWeight","fontWeights","regular","fontSize","fontSizes","sm","color","fg","default","create","position","alignSelf"],"sourceRoot":"../../../../src","sources":["modules/tooltip/Tooltip.tsx"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAEA,SAASA,YAAY,EAAEC,IAAI,EAAEC,WAAW,EAAEC,SAAS,EAAEC,MAAM,EAAEC,QAAQ,QAAQ,OAAO;AACpF,SAASC,QAAQ,EAAEC,UAAU,EAAEC,IAAI,EAAEC,IAAI,QAAQ,cAAc;AAI/D,SAASC,gBAAgB,QAAQ,0BAAiB;AAClD,SAASC,QAAQ,QAAQ,sBAAa;AAEtC,SAASC,sBAAsB,EAAEC,cAAc,EAAEC,sBAAsB,QAAQ,uBAAoB;;AAGnG;AAAA,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAgBA,OAAO,MAAMC,OAAO,gBAAGlB,IAAI,CAAC,SAASkB,OAAOA,CAAC;EAC3CC,KAAK;EACLC,QAAQ;EACRC,SAAS,GAAG,QAAQ;EACpBC;AACY,CAAC,EAAE;EACf,MAAMC,KAAK,GAAGb,QAAQ,CAAC,CAAC;EACxB,MAAMc,aAAa,GAAGf,gB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A,CAACR,IAAI;QACH6C,KAAK,EAAE,CACL7B,KAAK,CAAC2C,kBAAkB,CAAC3C,KAAK,CAAC4C,WAAW,CAACC,OAAO,CAAC,EACnD;UAAEC,QAAQ,EAAE9C,KAAK,CAAC+C,SAAS,CAACC,EAAE;UAAEC,KAAK,EAAEjD,KAAK,CAACqC,MAAM,CAACa,EAAE,CAACC;QAAQ,CAAC,CAChE;QAAAtD,QAAA,EAEDD;MAAK,CACF;IAAC,CACM,CAChB;EAAA,CACG,CAAC;AAEX,CAAC,CAAC;AAEF,MAAMkC,MAAM,GAAG/C,UAAU,CAACqE,MAAM,CAAC;EAC/B;EACA;EACArB,IAAI,EAAE;IAAEsB,QAAQ,EAAE,UAAU;IAAEC,SAAS,EAAE;EAAa;AACxD,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,75 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Tooltip's pure resolvers + the themed structural variant resolver — same split as Button:
|
|
5
|
+
*
|
|
6
|
+
* - STRUCTURE (padding, radius, the placement offset) lives in `tooltipBubbleStructure`, a
|
|
7
|
+
* `createThemedVariants` resolver, static per (brand, mode), registered once.
|
|
8
|
+
* - COLOUR is not tone-driven here — the bubble always reads `bg.raised` / `fg.default`, so it is
|
|
9
|
+
* resolved inline in the component from `theme.colors`, never a hardcoded hex.
|
|
10
|
+
* - The accessibility-hint MERGE is `mergeAccessibilityHint`, kept pure so "never clobber the
|
|
11
|
+
* child's existing hint" is unit-testable without mounting React.
|
|
12
|
+
*
|
|
13
|
+
* Free of `lucide` and of any React tree, so the WCAG + behaviour tests import it directly
|
|
14
|
+
* (mocking only `react-native`'s `StyleSheet`, as `core/style` does).
|
|
15
|
+
*/
|
|
16
|
+
|
|
17
|
+
import { sizes } from "../../theme/tokens/index.js";
|
|
18
|
+
import { createThemedVariants } from "../../core/style/index.js";
|
|
19
|
+
/**
|
|
20
|
+
* Design constants, not theme tokens — this module's own timing, not a scale other components
|
|
21
|
+
* share.
|
|
22
|
+
*/
|
|
23
|
+
export const TOOLTIP_TIMING = {
|
|
24
|
+
/** Fade-in duration; skipped (duration 0) when the OS reduce-motion setting is on (WCAG 2.3.3). */
|
|
25
|
+
fadeInMs: 150,
|
|
26
|
+
/** Fallback auto-dismiss so a tip can't stay stuck open if `onPressOut` never fires. */
|
|
27
|
+
autoHideMs: 2500
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
/**
|
|
31
|
+
* Appends `label` to any `accessibilityHint` the trigger already carries, so screen-reader users
|
|
32
|
+
* get the tip's content without needing the long-press gesture — the child's own hint is
|
|
33
|
+
* preserved, never overwritten. Reuses the existing sentence's terminal punctuation if there is
|
|
34
|
+
* one, so the merged hint reads as two sentences rather than a run-on.
|
|
35
|
+
*/
|
|
36
|
+
export function mergeAccessibilityHint(existing, label) {
|
|
37
|
+
const trimmed = existing?.trim();
|
|
38
|
+
if (!trimmed) return label;
|
|
39
|
+
const separator = /[.!?]$/.test(trimmed) ? " " : ". ";
|
|
40
|
+
return `${trimmed}${separator}${label}`;
|
|
41
|
+
}
|
|
42
|
+
|
|
43
|
+
/**
|
|
44
|
+
* Structural styles only — no colour (the bubble's fill/label are resolved from `RoleColors` in
|
|
45
|
+
* the component). `left: 0` anchors the bubble to the trigger's left edge rather than stretching
|
|
46
|
+
* it to the trigger's full width: a v1 simplification (no measurement library) that reads better
|
|
47
|
+
* for small icon-sized triggers than forcing the tip's width to match them. `maxWidth` reuses the
|
|
48
|
+
* shared `sizes` primitive's smallest step rather than a new hardcoded number.
|
|
49
|
+
*/
|
|
50
|
+
export const tooltipBubbleStructure = createThemedVariants(theme => ({
|
|
51
|
+
base: {
|
|
52
|
+
position: "absolute",
|
|
53
|
+
left: 0,
|
|
54
|
+
maxWidth: sizes["3xs"],
|
|
55
|
+
paddingHorizontal: theme.space[3],
|
|
56
|
+
paddingVertical: theme.space[2],
|
|
57
|
+
borderRadius: theme.radii.sm
|
|
58
|
+
},
|
|
59
|
+
variants: {
|
|
60
|
+
placement: {
|
|
61
|
+
bottom: {
|
|
62
|
+
top: "100%",
|
|
63
|
+
marginTop: theme.space[1]
|
|
64
|
+
},
|
|
65
|
+
top: {
|
|
66
|
+
bottom: "100%",
|
|
67
|
+
marginBottom: theme.space[1]
|
|
68
|
+
}
|
|
69
|
+
}
|
|
70
|
+
},
|
|
71
|
+
defaultVariants: {
|
|
72
|
+
placement: "bottom"
|
|
73
|
+
}
|
|
74
|
+
}));
|
|
75
|
+
//# sourceMappingURL=Tooltip.variants.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["sizes","createThemedVariants","TOOLTIP_TIMING","fadeInMs","autoHideMs","mergeAccessibilityHint","existing","label","trimmed","trim","separator","test","tooltipBubbleStructure","theme","base","position","left","maxWidth","paddingHorizontal","space","paddingVertical","borderRadius","radii","sm","variants","placement","bottom","top","marginTop","marginBottom","defaultVariants"],"sourceRoot":"../../../../src","sources":["modules/tooltip/Tooltip.variants.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;;AAGA,SAASA,KAAK,QAAQ,6BAAoB;AAC1C,SAASC,oBAAoB,QAAQ,2BAAkB;AAIvD;AACA;AACA;AACA;AACA,OAAO,MAAMC,cAAc,GAAG;EAC5B;EACAC,QAAQ,EAAE,GAAG;EACb;EACAC,UAAU,EAAE;AACd,CAAU;;AAEV;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,SAASC,sBAAsBA,CAACC,QAA4B,EAAEC,KAAa,EAAU;EAC1F,MAAMC,OAAO,GAAGF,QAAQ,EAAEG,IAAI,CAAC,CAAC;EAChC,IAAI,CAACD,OAAO,EAAE,OAAOD,KAAK;EAC1B,MAAMG,SAAS,GAAG,QAAQ,CAACC,IAAI,CAACH,OAAO,CAAC,GAAG,GAAG,GAAG,IAAI;EACrD,OAAO,GAAGA,OAAO,GAAGE,SAAS,GAAGH,KAAK,EAAE;AACzC;;AAEA;AACA;AACA;AACA;AACA;AACA;AACA;AACA,OAAO,MAAMK,sBAAsB,GAAGX,oBAAoB,CAAEY,KAAY,KAAM;EAC5EC,IAAI,EAAE;IACJC,QAAQ,EAAE,UAAU;IACpBC,IAAI,EAAE,CAAC;IACPC,QAAQ,EAAEjB,KAAK,CAAC,KAAK,CAAC;IACtBkB,iBAAiB,EAAEL,KAAK,CAACM,KAAK,CAAC,CAAC,CAAC;IACjCC,eAAe,EAAEP,KAAK,CAACM,KAAK,CAAC,CAAC,CAAC;IAC/BE,YAAY,EAAER,KAAK,CAACS,KAAK,CAACC;EAC5B,CAAC;EACDC,QAAQ,EAAE;IACRC,SAAS,EAAE;MACTC,MAAM,EAAE;QAAEC,GAAG,EAAE,MAAM;QAAEC,SAAS,EAAEf,KAAK,CAACM,KAAK,CAAC,CAAC;MAAE,CAAC;MAClDQ,GAAG,EAAE;QAAED,MAAM,EAAE,MAAM;QAAEG,YAAY,EAAEhB,KAAK,CAACM,KAAK,CAAC,CAAC;MAAE;IACtD;EACF,CAAC;EACDW,eAAe,EAAE;IAAEL,SAAS,EAAE;EAAS;AACzC,CAAC,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
/**
|
|
4
|
+
* Public surface of `pixelize-native-library/tooltip`. Value exports and type exports are split for
|
|
5
|
+
* `verbatimModuleSyntax`. The pure resolvers (`mergeAccessibilityHint`, `tooltipBubbleStructure`,
|
|
6
|
+
* `TOOLTIP_TIMING`) stay internal — a consumer configures a Tooltip through its props only.
|
|
7
|
+
*/
|
|
8
|
+
|
|
9
|
+
export { Tooltip } from "./Tooltip.js";
|
|
10
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["Tooltip"],"sourceRoot":"../../../../src","sources":["modules/tooltip/index.ts"],"mappings":";;AAAA;AACA;AACA;AACA;AACA;;AAEA,SAASA,OAAO,QAAQ,cAAW","ignoreList":[]}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"type":"module"}
|