react-native-mantine 0.1.15 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/commonjs/components/Accordion/index.js +251 -0
- package/lib/commonjs/components/Accordion/index.js.map +1 -0
- package/lib/commonjs/components/ActionIcon/ActionIcon.js +23 -28
- package/lib/commonjs/components/ActionIcon/ActionIcon.js.map +1 -1
- package/lib/commonjs/components/Anchor/index.js +108 -0
- package/lib/commonjs/components/Anchor/index.js.map +1 -0
- package/lib/commonjs/components/AspectRatio/index.js +66 -0
- package/lib/commonjs/components/AspectRatio/index.js.map +1 -0
- package/lib/commonjs/components/Avatar/index.js +129 -0
- package/lib/commonjs/components/Avatar/index.js.map +1 -0
- package/lib/commonjs/components/BackgroundImage/index.js +56 -0
- package/lib/commonjs/components/BackgroundImage/index.js.map +1 -0
- package/lib/commonjs/components/Badge/index.js +190 -0
- package/lib/commonjs/components/Badge/index.js.map +1 -0
- package/lib/commonjs/components/Blockquote/index.js +98 -0
- package/lib/commonjs/components/Blockquote/index.js.map +1 -0
- package/lib/commonjs/components/BoxView/index.js +66 -2
- package/lib/commonjs/components/BoxView/index.js.map +1 -1
- package/lib/commonjs/components/Breadcrumbs/index.js +58 -0
- package/lib/commonjs/components/Breadcrumbs/index.js.map +1 -0
- package/lib/commonjs/components/Burger/index.js +183 -0
- package/lib/commonjs/components/Burger/index.js.map +1 -0
- package/lib/commonjs/components/Button/Button.styles.js +35 -18
- package/lib/commonjs/components/Button/Button.styles.js.map +1 -1
- package/lib/commonjs/components/Button/index.js +2 -1
- package/lib/commonjs/components/Button/index.js.map +1 -1
- package/lib/commonjs/components/Card/index.js +136 -0
- package/lib/commonjs/components/Card/index.js.map +1 -0
- package/lib/commonjs/components/Center/index.js +36 -0
- package/lib/commonjs/components/Center/index.js.map +1 -0
- package/lib/commonjs/components/Checkbox/index.js +140 -0
- package/lib/commonjs/components/Checkbox/index.js.map +1 -0
- package/lib/commonjs/components/Chip/index.js +269 -0
- package/lib/commonjs/components/Chip/index.js.map +1 -0
- package/lib/commonjs/components/CloseButton/index.js +137 -0
- package/lib/commonjs/components/CloseButton/index.js.map +1 -0
- package/lib/commonjs/components/Code/index.js +68 -0
- package/lib/commonjs/components/Code/index.js.map +1 -0
- package/lib/commonjs/components/Collapse/index.js +83 -0
- package/lib/commonjs/components/Collapse/index.js.map +1 -0
- package/lib/commonjs/components/ColorSwatch/index.js +96 -0
- package/lib/commonjs/components/ColorSwatch/index.js.map +1 -0
- package/lib/commonjs/components/Container/index.js +71 -0
- package/lib/commonjs/components/Container/index.js.map +1 -0
- package/lib/commonjs/components/CopyButton/index.js +54 -0
- package/lib/commonjs/components/CopyButton/index.js.map +1 -0
- package/lib/commonjs/components/Dialog/index.js +140 -0
- package/lib/commonjs/components/Dialog/index.js.map +1 -0
- package/lib/commonjs/components/Divider/index.js +148 -0
- package/lib/commonjs/components/Divider/index.js.map +1 -0
- package/lib/commonjs/components/Drawer/index.js +252 -0
- package/lib/commonjs/components/Drawer/index.js.map +1 -0
- package/lib/commonjs/components/Flex/index.js +63 -0
- package/lib/commonjs/components/Flex/index.js.map +1 -0
- package/lib/commonjs/components/Grid/index.js +145 -0
- package/lib/commonjs/components/Grid/index.js.map +1 -0
- package/lib/commonjs/components/Group/index.js +22 -1
- package/lib/commonjs/components/Group/index.js.map +1 -1
- package/lib/commonjs/components/Highlight/index.js +74 -0
- package/lib/commonjs/components/Highlight/index.js.map +1 -0
- package/lib/commonjs/components/Image/index.js +133 -0
- package/lib/commonjs/components/Image/index.js.map +1 -0
- package/lib/commonjs/components/Indicator/index.js +199 -0
- package/lib/commonjs/components/Indicator/index.js.map +1 -0
- package/lib/commonjs/components/Kbd/index.js +96 -0
- package/lib/commonjs/components/Kbd/index.js.map +1 -0
- package/lib/commonjs/components/List/index.js +217 -0
- package/lib/commonjs/components/List/index.js.map +1 -0
- package/lib/commonjs/components/Loader/Loader.js +25 -18
- package/lib/commonjs/components/Loader/Loader.js.map +1 -1
- package/lib/commonjs/components/LoadingOverlay/index.js +84 -0
- package/lib/commonjs/components/LoadingOverlay/index.js.map +1 -0
- package/lib/commonjs/components/Mark/index.js +47 -0
- package/lib/commonjs/components/Mark/index.js.map +1 -0
- package/lib/commonjs/components/MediaQuery/index.js +89 -0
- package/lib/commonjs/components/MediaQuery/index.js.map +1 -0
- package/lib/commonjs/components/Menu/index.js +306 -0
- package/lib/commonjs/components/Menu/index.js.map +1 -0
- package/lib/commonjs/components/Modal/index.js +236 -0
- package/lib/commonjs/components/Modal/index.js.map +1 -0
- package/lib/commonjs/components/MultiSelect/index.js +300 -0
- package/lib/commonjs/components/MultiSelect/index.js.map +1 -0
- package/lib/commonjs/components/NativeSelect/index.js +295 -0
- package/lib/commonjs/components/NativeSelect/index.js.map +1 -0
- package/lib/commonjs/components/NavLink/index.js +164 -0
- package/lib/commonjs/components/NavLink/index.js.map +1 -0
- package/lib/commonjs/components/Notification/index.js +143 -0
- package/lib/commonjs/components/Notification/index.js.map +1 -0
- package/lib/commonjs/components/NumberInput/index.js +268 -0
- package/lib/commonjs/components/NumberInput/index.js.map +1 -0
- package/lib/commonjs/components/Overlay/index.js +78 -0
- package/lib/commonjs/components/Overlay/index.js.map +1 -0
- package/lib/commonjs/components/Pagination/index.js +254 -0
- package/lib/commonjs/components/Pagination/index.js.map +1 -0
- package/lib/commonjs/components/Paper/index.js +156 -0
- package/lib/commonjs/components/Paper/index.js.map +1 -0
- package/lib/commonjs/components/PasswordInput/index.js +68 -0
- package/lib/commonjs/components/PasswordInput/index.js.map +1 -0
- package/lib/commonjs/components/PinInput/index.js +186 -0
- package/lib/commonjs/components/PinInput/index.js.map +1 -0
- package/lib/commonjs/components/Popover/index.js +163 -0
- package/lib/commonjs/components/Popover/index.js.map +1 -0
- package/lib/commonjs/components/Portal/index.js +70 -0
- package/lib/commonjs/components/Portal/index.js.map +1 -0
- package/lib/commonjs/components/Progress/index.js +124 -0
- package/lib/commonjs/components/Progress/index.js.map +1 -0
- package/lib/commonjs/components/Radio/index.js +136 -0
- package/lib/commonjs/components/Radio/index.js.map +1 -0
- package/lib/commonjs/components/Rating/index.js +152 -0
- package/lib/commonjs/components/Rating/index.js.map +1 -0
- package/lib/commonjs/components/RingProgress/index.js +175 -0
- package/lib/commonjs/components/RingProgress/index.js.map +1 -0
- package/lib/commonjs/components/SegmentedControl/index.js +226 -0
- package/lib/commonjs/components/SegmentedControl/index.js.map +1 -0
- package/lib/commonjs/components/Select/index.js +245 -0
- package/lib/commonjs/components/Select/index.js.map +1 -0
- package/lib/commonjs/components/SimpleGrid/index.js +102 -0
- package/lib/commonjs/components/SimpleGrid/index.js.map +1 -0
- package/lib/commonjs/components/Skeleton/index.js +112 -0
- package/lib/commonjs/components/Skeleton/index.js.map +1 -0
- package/lib/commonjs/components/Slider/index.js +276 -0
- package/lib/commonjs/components/Slider/index.js.map +1 -0
- package/lib/commonjs/components/Space/index.js +45 -0
- package/lib/commonjs/components/Space/index.js.map +1 -0
- package/lib/commonjs/components/Spoiler/index.js +110 -0
- package/lib/commonjs/components/Spoiler/index.js.map +1 -0
- package/lib/commonjs/components/Stepper/index.js +276 -0
- package/lib/commonjs/components/Stepper/index.js.map +1 -0
- package/lib/commonjs/components/Switch/index.js +119 -0
- package/lib/commonjs/components/Switch/index.js.map +1 -0
- package/lib/commonjs/components/Table/index.js +314 -0
- package/lib/commonjs/components/Table/index.js.map +1 -0
- package/lib/commonjs/components/Text/index.js +7 -2
- package/lib/commonjs/components/Text/index.js.map +1 -1
- package/lib/commonjs/components/TextInput/index.js +185 -0
- package/lib/commonjs/components/TextInput/index.js.map +1 -0
- package/lib/commonjs/components/Textarea/index.js +54 -0
- package/lib/commonjs/components/Textarea/index.js.map +1 -0
- package/lib/commonjs/components/ThemeIcon/index.js +145 -0
- package/lib/commonjs/components/ThemeIcon/index.js.map +1 -0
- package/lib/commonjs/components/Timeline/index.js +242 -0
- package/lib/commonjs/components/Timeline/index.js.map +1 -0
- package/lib/commonjs/components/Title/index.js +45 -0
- package/lib/commonjs/components/Title/index.js.map +1 -0
- package/lib/commonjs/components/Tooltip/index.js +187 -0
- package/lib/commonjs/components/Tooltip/index.js.map +1 -0
- package/lib/commonjs/components/TransferList/index.js +293 -0
- package/lib/commonjs/components/TransferList/index.js.map +1 -0
- package/lib/commonjs/components/Transition/index.js +175 -0
- package/lib/commonjs/components/Transition/index.js.map +1 -0
- package/lib/commonjs/components/index.js +759 -0
- package/lib/commonjs/components/index.js.map +1 -1
- package/lib/commonjs/theme/create-theme.js +1 -0
- package/lib/commonjs/theme/create-theme.js.map +1 -1
- package/lib/commonjs/theme/default-theme.js +2 -0
- package/lib/commonjs/theme/default-theme.js.map +1 -1
- package/lib/commonjs/theme/functions/attach-functions.js +12 -2
- package/lib/commonjs/theme/functions/attach-functions.js.map +1 -1
- package/lib/commonjs/theme/functions/fns/helpers.js +44 -0
- package/lib/commonjs/theme/functions/fns/helpers.js.map +1 -0
- package/lib/commonjs/theme/functions/fns/index.js +5 -1
- package/lib/commonjs/theme/functions/fns/index.js.map +1 -1
- package/lib/commonjs/theme/functions/fns/theme-color/theme-color.js +26 -4
- package/lib/commonjs/theme/functions/fns/theme-color/theme-color.js.map +1 -1
- package/lib/commonjs/theme/functions/fns/variant.js +89 -2
- package/lib/commonjs/theme/functions/fns/variant.js.map +1 -1
- package/lib/commonjs/theme/utils/rem.js +8 -6
- package/lib/commonjs/theme/utils/rem.js.map +1 -1
- package/lib/module/components/Accordion/index.js +246 -0
- package/lib/module/components/Accordion/index.js.map +1 -0
- package/lib/module/components/ActionIcon/ActionIcon.js +25 -29
- package/lib/module/components/ActionIcon/ActionIcon.js.map +1 -1
- package/lib/module/components/Anchor/index.js +102 -0
- package/lib/module/components/Anchor/index.js.map +1 -0
- package/lib/module/components/AspectRatio/index.js +60 -0
- package/lib/module/components/AspectRatio/index.js.map +1 -0
- package/lib/module/components/Avatar/index.js +123 -0
- package/lib/module/components/Avatar/index.js.map +1 -0
- package/lib/module/components/BackgroundImage/index.js +50 -0
- package/lib/module/components/BackgroundImage/index.js.map +1 -0
- package/lib/module/components/Badge/index.js +184 -0
- package/lib/module/components/Badge/index.js.map +1 -0
- package/lib/module/components/Blockquote/index.js +92 -0
- package/lib/module/components/Blockquote/index.js.map +1 -0
- package/lib/module/components/BoxView/index.js +66 -2
- package/lib/module/components/BoxView/index.js.map +1 -1
- package/lib/module/components/Breadcrumbs/index.js +52 -0
- package/lib/module/components/Breadcrumbs/index.js.map +1 -0
- package/lib/module/components/Burger/index.js +180 -0
- package/lib/module/components/Burger/index.js.map +1 -0
- package/lib/module/components/Button/Button.styles.js +35 -18
- package/lib/module/components/Button/Button.styles.js.map +1 -1
- package/lib/module/components/Button/index.js +1 -0
- package/lib/module/components/Button/index.js.map +1 -1
- package/lib/module/components/Card/index.js +130 -0
- package/lib/module/components/Card/index.js.map +1 -0
- package/lib/module/components/Center/index.js +30 -0
- package/lib/module/components/Center/index.js.map +1 -0
- package/lib/module/components/Checkbox/index.js +134 -0
- package/lib/module/components/Checkbox/index.js.map +1 -0
- package/lib/module/components/Chip/index.js +263 -0
- package/lib/module/components/Chip/index.js.map +1 -0
- package/lib/module/components/CloseButton/index.js +132 -0
- package/lib/module/components/CloseButton/index.js.map +1 -0
- package/lib/module/components/Code/index.js +62 -0
- package/lib/module/components/Code/index.js.map +1 -0
- package/lib/module/components/Collapse/index.js +77 -0
- package/lib/module/components/Collapse/index.js.map +1 -0
- package/lib/module/components/ColorSwatch/index.js +90 -0
- package/lib/module/components/ColorSwatch/index.js.map +1 -0
- package/lib/module/components/Container/index.js +65 -0
- package/lib/module/components/Container/index.js.map +1 -0
- package/lib/module/components/CopyButton/index.js +48 -0
- package/lib/module/components/CopyButton/index.js.map +1 -0
- package/lib/module/components/Dialog/index.js +134 -0
- package/lib/module/components/Dialog/index.js.map +1 -0
- package/lib/module/components/Divider/index.js +142 -0
- package/lib/module/components/Divider/index.js.map +1 -0
- package/lib/module/components/Drawer/index.js +246 -0
- package/lib/module/components/Drawer/index.js.map +1 -0
- package/lib/module/components/Flex/index.js +57 -0
- package/lib/module/components/Flex/index.js.map +1 -0
- package/lib/module/components/Grid/index.js +139 -0
- package/lib/module/components/Grid/index.js.map +1 -0
- package/lib/module/components/Group/index.js +22 -1
- package/lib/module/components/Group/index.js.map +1 -1
- package/lib/module/components/Highlight/index.js +70 -0
- package/lib/module/components/Highlight/index.js.map +1 -0
- package/lib/module/components/Image/index.js +127 -0
- package/lib/module/components/Image/index.js.map +1 -0
- package/lib/module/components/Indicator/index.js +193 -0
- package/lib/module/components/Indicator/index.js.map +1 -0
- package/lib/module/components/Kbd/index.js +90 -0
- package/lib/module/components/Kbd/index.js.map +1 -0
- package/lib/module/components/List/index.js +211 -0
- package/lib/module/components/List/index.js.map +1 -0
- package/lib/module/components/Loader/Loader.js +26 -19
- package/lib/module/components/Loader/Loader.js.map +1 -1
- package/lib/module/components/LoadingOverlay/index.js +80 -0
- package/lib/module/components/LoadingOverlay/index.js.map +1 -0
- package/lib/module/components/Mark/index.js +41 -0
- package/lib/module/components/Mark/index.js.map +1 -0
- package/lib/module/components/MediaQuery/index.js +82 -0
- package/lib/module/components/MediaQuery/index.js.map +1 -0
- package/lib/module/components/Menu/index.js +300 -0
- package/lib/module/components/Menu/index.js.map +1 -0
- package/lib/module/components/Modal/index.js +230 -0
- package/lib/module/components/Modal/index.js.map +1 -0
- package/lib/module/components/MultiSelect/index.js +294 -0
- package/lib/module/components/MultiSelect/index.js.map +1 -0
- package/lib/module/components/NativeSelect/index.js +289 -0
- package/lib/module/components/NativeSelect/index.js.map +1 -0
- package/lib/module/components/NavLink/index.js +158 -0
- package/lib/module/components/NavLink/index.js.map +1 -0
- package/lib/module/components/Notification/index.js +137 -0
- package/lib/module/components/Notification/index.js.map +1 -0
- package/lib/module/components/NumberInput/index.js +262 -0
- package/lib/module/components/NumberInput/index.js.map +1 -0
- package/lib/module/components/Overlay/index.js +72 -0
- package/lib/module/components/Overlay/index.js.map +1 -0
- package/lib/module/components/Pagination/index.js +248 -0
- package/lib/module/components/Pagination/index.js.map +1 -0
- package/lib/module/components/Paper/index.js +150 -0
- package/lib/module/components/Paper/index.js.map +1 -0
- package/lib/module/components/PasswordInput/index.js +62 -0
- package/lib/module/components/PasswordInput/index.js.map +1 -0
- package/lib/module/components/PinInput/index.js +182 -0
- package/lib/module/components/PinInput/index.js.map +1 -0
- package/lib/module/components/Popover/index.js +157 -0
- package/lib/module/components/Popover/index.js.map +1 -0
- package/lib/module/components/Portal/index.js +62 -0
- package/lib/module/components/Portal/index.js.map +1 -0
- package/lib/module/components/Progress/index.js +120 -0
- package/lib/module/components/Progress/index.js.map +1 -0
- package/lib/module/components/Radio/index.js +130 -0
- package/lib/module/components/Radio/index.js.map +1 -0
- package/lib/module/components/Rating/index.js +146 -0
- package/lib/module/components/Rating/index.js.map +1 -0
- package/lib/module/components/RingProgress/index.js +169 -0
- package/lib/module/components/RingProgress/index.js.map +1 -0
- package/lib/module/components/SegmentedControl/index.js +220 -0
- package/lib/module/components/SegmentedControl/index.js.map +1 -0
- package/lib/module/components/Select/index.js +239 -0
- package/lib/module/components/Select/index.js.map +1 -0
- package/lib/module/components/SimpleGrid/index.js +96 -0
- package/lib/module/components/SimpleGrid/index.js.map +1 -0
- package/lib/module/components/Skeleton/index.js +106 -0
- package/lib/module/components/Skeleton/index.js.map +1 -0
- package/lib/module/components/Slider/index.js +270 -0
- package/lib/module/components/Slider/index.js.map +1 -0
- package/lib/module/components/Space/index.js +41 -0
- package/lib/module/components/Space/index.js.map +1 -0
- package/lib/module/components/Spoiler/index.js +104 -0
- package/lib/module/components/Spoiler/index.js.map +1 -0
- package/lib/module/components/Stepper/index.js +270 -0
- package/lib/module/components/Stepper/index.js.map +1 -0
- package/lib/module/components/Switch/index.js +113 -0
- package/lib/module/components/Switch/index.js.map +1 -0
- package/lib/module/components/Table/index.js +308 -0
- package/lib/module/components/Table/index.js.map +1 -0
- package/lib/module/components/Text/index.js +7 -2
- package/lib/module/components/Text/index.js.map +1 -1
- package/lib/module/components/TextInput/index.js +179 -0
- package/lib/module/components/TextInput/index.js.map +1 -0
- package/lib/module/components/Textarea/index.js +50 -0
- package/lib/module/components/Textarea/index.js.map +1 -0
- package/lib/module/components/ThemeIcon/index.js +140 -0
- package/lib/module/components/ThemeIcon/index.js.map +1 -0
- package/lib/module/components/Timeline/index.js +236 -0
- package/lib/module/components/Timeline/index.js.map +1 -0
- package/lib/module/components/Title/index.js +39 -0
- package/lib/module/components/Title/index.js.map +1 -0
- package/lib/module/components/Tooltip/index.js +181 -0
- package/lib/module/components/Tooltip/index.js.map +1 -0
- package/lib/module/components/TransferList/index.js +287 -0
- package/lib/module/components/TransferList/index.js.map +1 -0
- package/lib/module/components/Transition/index.js +169 -0
- package/lib/module/components/Transition/index.js.map +1 -0
- package/lib/module/components/index.js +101 -0
- package/lib/module/components/index.js.map +1 -1
- package/lib/module/theme/create-theme.js +1 -0
- package/lib/module/theme/create-theme.js.map +1 -1
- package/lib/module/theme/default-theme.js +2 -0
- package/lib/module/theme/default-theme.js.map +1 -1
- package/lib/module/theme/functions/attach-functions.js +12 -2
- package/lib/module/theme/functions/attach-functions.js.map +1 -1
- package/lib/module/theme/functions/fns/helpers.js +34 -0
- package/lib/module/theme/functions/fns/helpers.js.map +1 -0
- package/lib/module/theme/functions/fns/index.js +3 -1
- package/lib/module/theme/functions/fns/index.js.map +1 -1
- package/lib/module/theme/functions/fns/theme-color/theme-color.js +26 -4
- package/lib/module/theme/functions/fns/theme-color/theme-color.js.map +1 -1
- package/lib/module/theme/functions/fns/variant.js +89 -2
- package/lib/module/theme/functions/fns/variant.js.map +1 -1
- package/lib/module/theme/utils/rem.js +8 -6
- package/lib/module/theme/utils/rem.js.map +1 -1
- package/lib/typescript/commonjs/src/components/Accordion/index.d.ts +54 -0
- package/lib/typescript/commonjs/src/components/Accordion/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/ActionIcon/ActionIcon.d.ts +4 -4
- package/lib/typescript/commonjs/src/components/ActionIcon/ActionIcon.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/Anchor/index.d.ts +25 -0
- package/lib/typescript/commonjs/src/components/Anchor/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/AspectRatio/index.d.ts +12 -0
- package/lib/typescript/commonjs/src/components/AspectRatio/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Avatar/index.d.ts +23 -0
- package/lib/typescript/commonjs/src/components/Avatar/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/BackgroundImage/index.d.ts +15 -0
- package/lib/typescript/commonjs/src/components/BackgroundImage/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Badge/index.d.ts +24 -0
- package/lib/typescript/commonjs/src/components/Badge/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Blockquote/index.d.ts +18 -0
- package/lib/typescript/commonjs/src/components/Blockquote/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/BoxView/index.d.ts +28 -0
- package/lib/typescript/commonjs/src/components/BoxView/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/Breadcrumbs/index.d.ts +12 -0
- package/lib/typescript/commonjs/src/components/Breadcrumbs/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Burger/index.d.ts +21 -0
- package/lib/typescript/commonjs/src/components/Burger/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Button/Button.styles.d.ts +5 -0
- package/lib/typescript/commonjs/src/components/Button/Button.styles.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/Button/index.d.ts +1 -0
- package/lib/typescript/commonjs/src/components/Button/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/Card/index.d.ts +24 -0
- package/lib/typescript/commonjs/src/components/Card/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Center/index.d.ts +15 -0
- package/lib/typescript/commonjs/src/components/Center/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Checkbox/index.d.ts +24 -0
- package/lib/typescript/commonjs/src/components/Checkbox/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Chip/index.d.ts +51 -0
- package/lib/typescript/commonjs/src/components/Chip/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/CloseButton/index.d.ts +22 -0
- package/lib/typescript/commonjs/src/components/CloseButton/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Code/index.d.ts +15 -0
- package/lib/typescript/commonjs/src/components/Code/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Collapse/index.d.ts +20 -0
- package/lib/typescript/commonjs/src/components/Collapse/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/ColorSwatch/index.d.ts +20 -0
- package/lib/typescript/commonjs/src/components/ColorSwatch/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Container/index.d.ts +20 -0
- package/lib/typescript/commonjs/src/components/Container/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/CopyButton/index.d.ts +15 -0
- package/lib/typescript/commonjs/src/components/CopyButton/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Dialog/index.d.ts +31 -0
- package/lib/typescript/commonjs/src/components/Dialog/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Divider/index.d.ts +20 -0
- package/lib/typescript/commonjs/src/components/Divider/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Drawer/index.d.ts +36 -0
- package/lib/typescript/commonjs/src/components/Drawer/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Flex/index.d.ts +27 -0
- package/lib/typescript/commonjs/src/components/Flex/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Grid/index.d.ts +38 -0
- package/lib/typescript/commonjs/src/components/Grid/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Group/index.d.ts +2 -1
- package/lib/typescript/commonjs/src/components/Group/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/Highlight/index.d.ts +19 -0
- package/lib/typescript/commonjs/src/components/Highlight/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Image/index.d.ts +31 -0
- package/lib/typescript/commonjs/src/components/Image/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Indicator/index.d.ts +32 -0
- package/lib/typescript/commonjs/src/components/Indicator/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Input/Input.styles.d.ts +5 -5
- package/lib/typescript/commonjs/src/components/Kbd/index.d.ts +12 -0
- package/lib/typescript/commonjs/src/components/Kbd/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/List/index.d.ts +42 -0
- package/lib/typescript/commonjs/src/components/List/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Loader/Loader.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/LoadingOverlay/index.d.ts +23 -0
- package/lib/typescript/commonjs/src/components/LoadingOverlay/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Mark/index.d.ts +14 -0
- package/lib/typescript/commonjs/src/components/Mark/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/MediaQuery/index.d.ts +24 -0
- package/lib/typescript/commonjs/src/components/MediaQuery/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Menu/index.d.ts +64 -0
- package/lib/typescript/commonjs/src/components/Menu/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Modal/index.d.ts +40 -0
- package/lib/typescript/commonjs/src/components/Modal/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/MultiSelect/index.d.ts +53 -0
- package/lib/typescript/commonjs/src/components/MultiSelect/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/NativeSelect/index.d.ts +45 -0
- package/lib/typescript/commonjs/src/components/NativeSelect/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/NavLink/index.d.ts +30 -0
- package/lib/typescript/commonjs/src/components/NavLink/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Notification/index.d.ts +28 -0
- package/lib/typescript/commonjs/src/components/Notification/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/NumberInput/index.d.ts +47 -0
- package/lib/typescript/commonjs/src/components/NumberInput/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Overlay/index.d.ts +24 -0
- package/lib/typescript/commonjs/src/components/Overlay/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Pagination/index.d.ts +37 -0
- package/lib/typescript/commonjs/src/components/Pagination/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Paper/index.d.ts +18 -0
- package/lib/typescript/commonjs/src/components/Paper/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/PasswordInput/index.d.ts +15 -0
- package/lib/typescript/commonjs/src/components/PasswordInput/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/PinInput/index.d.ts +33 -0
- package/lib/typescript/commonjs/src/components/PinInput/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Popover/index.d.ts +44 -0
- package/lib/typescript/commonjs/src/components/Popover/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Portal/index.d.ts +10 -0
- package/lib/typescript/commonjs/src/components/Portal/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Progress/index.d.ts +29 -0
- package/lib/typescript/commonjs/src/components/Progress/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Radio/index.d.ts +24 -0
- package/lib/typescript/commonjs/src/components/Radio/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Rating/index.d.ts +32 -0
- package/lib/typescript/commonjs/src/components/Rating/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/RingProgress/index.d.ts +61 -0
- package/lib/typescript/commonjs/src/components/RingProgress/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/SegmentedControl/index.d.ts +35 -0
- package/lib/typescript/commonjs/src/components/SegmentedControl/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Select/index.d.ts +53 -0
- package/lib/typescript/commonjs/src/components/Select/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/SimpleGrid/index.d.ts +22 -0
- package/lib/typescript/commonjs/src/components/SimpleGrid/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Skeleton/index.d.ts +22 -0
- package/lib/typescript/commonjs/src/components/Skeleton/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Slider/index.d.ts +43 -0
- package/lib/typescript/commonjs/src/components/Slider/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Space/index.d.ts +13 -0
- package/lib/typescript/commonjs/src/components/Space/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Spoiler/index.d.ts +22 -0
- package/lib/typescript/commonjs/src/components/Spoiler/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Stepper/index.d.ts +55 -0
- package/lib/typescript/commonjs/src/components/Stepper/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Switch/index.d.ts +24 -0
- package/lib/typescript/commonjs/src/components/Switch/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Table/index.d.ts +72 -0
- package/lib/typescript/commonjs/src/components/Table/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Text/index.d.ts +4 -0
- package/lib/typescript/commonjs/src/components/Text/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/components/TextInput/index.d.ts +31 -0
- package/lib/typescript/commonjs/src/components/TextInput/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Textarea/index.d.ts +12 -0
- package/lib/typescript/commonjs/src/components/Textarea/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/ThemeIcon/index.d.ts +21 -0
- package/lib/typescript/commonjs/src/components/ThemeIcon/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Timeline/index.d.ts +52 -0
- package/lib/typescript/commonjs/src/components/Timeline/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Title/index.d.ts +14 -0
- package/lib/typescript/commonjs/src/components/Title/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Tooltip/index.d.ts +36 -0
- package/lib/typescript/commonjs/src/components/Tooltip/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/TransferList/index.d.ts +42 -0
- package/lib/typescript/commonjs/src/components/TransferList/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/Transition/index.d.ts +25 -0
- package/lib/typescript/commonjs/src/components/Transition/index.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/components/index.d.ts +69 -0
- package/lib/typescript/commonjs/src/components/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/create-theme.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/default-theme.d.ts +20 -0
- package/lib/typescript/commonjs/src/theme/default-theme.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/functions/attach-functions.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/functions/fns/helpers.d.ts +23 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/helpers.d.ts.map +1 -0
- package/lib/typescript/commonjs/src/theme/functions/fns/index.d.ts +22 -1
- package/lib/typescript/commonjs/src/theme/functions/fns/index.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/functions/fns/theme-color/theme-color.d.ts +8 -1
- package/lib/typescript/commonjs/src/theme/functions/fns/theme-color/theme-color.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/functions/fns/variant.d.ts +19 -1
- package/lib/typescript/commonjs/src/theme/functions/fns/variant.d.ts.map +1 -1
- package/lib/typescript/commonjs/src/theme/utils/rem.d.ts +2 -2
- package/lib/typescript/commonjs/src/theme/utils/rem.d.ts.map +1 -1
- package/lib/typescript/module/src/components/Accordion/index.d.ts +54 -0
- package/lib/typescript/module/src/components/Accordion/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/ActionIcon/ActionIcon.d.ts +4 -4
- package/lib/typescript/module/src/components/ActionIcon/ActionIcon.d.ts.map +1 -1
- package/lib/typescript/module/src/components/Anchor/index.d.ts +25 -0
- package/lib/typescript/module/src/components/Anchor/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/AspectRatio/index.d.ts +12 -0
- package/lib/typescript/module/src/components/AspectRatio/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Avatar/index.d.ts +23 -0
- package/lib/typescript/module/src/components/Avatar/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/BackgroundImage/index.d.ts +15 -0
- package/lib/typescript/module/src/components/BackgroundImage/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Badge/index.d.ts +24 -0
- package/lib/typescript/module/src/components/Badge/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Blockquote/index.d.ts +18 -0
- package/lib/typescript/module/src/components/Blockquote/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/BoxView/index.d.ts +28 -0
- package/lib/typescript/module/src/components/BoxView/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/Breadcrumbs/index.d.ts +12 -0
- package/lib/typescript/module/src/components/Breadcrumbs/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Burger/index.d.ts +21 -0
- package/lib/typescript/module/src/components/Burger/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Button/Button.styles.d.ts +5 -0
- package/lib/typescript/module/src/components/Button/Button.styles.d.ts.map +1 -1
- package/lib/typescript/module/src/components/Button/index.d.ts +1 -0
- package/lib/typescript/module/src/components/Button/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/Card/index.d.ts +24 -0
- package/lib/typescript/module/src/components/Card/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Center/index.d.ts +15 -0
- package/lib/typescript/module/src/components/Center/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Checkbox/index.d.ts +24 -0
- package/lib/typescript/module/src/components/Checkbox/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Chip/index.d.ts +51 -0
- package/lib/typescript/module/src/components/Chip/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/CloseButton/index.d.ts +22 -0
- package/lib/typescript/module/src/components/CloseButton/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Code/index.d.ts +15 -0
- package/lib/typescript/module/src/components/Code/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Collapse/index.d.ts +20 -0
- package/lib/typescript/module/src/components/Collapse/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/ColorSwatch/index.d.ts +20 -0
- package/lib/typescript/module/src/components/ColorSwatch/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Container/index.d.ts +20 -0
- package/lib/typescript/module/src/components/Container/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/CopyButton/index.d.ts +15 -0
- package/lib/typescript/module/src/components/CopyButton/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Dialog/index.d.ts +31 -0
- package/lib/typescript/module/src/components/Dialog/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Divider/index.d.ts +20 -0
- package/lib/typescript/module/src/components/Divider/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Drawer/index.d.ts +36 -0
- package/lib/typescript/module/src/components/Drawer/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Flex/index.d.ts +27 -0
- package/lib/typescript/module/src/components/Flex/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Grid/index.d.ts +38 -0
- package/lib/typescript/module/src/components/Grid/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Group/index.d.ts +2 -1
- package/lib/typescript/module/src/components/Group/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/Highlight/index.d.ts +19 -0
- package/lib/typescript/module/src/components/Highlight/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Image/index.d.ts +31 -0
- package/lib/typescript/module/src/components/Image/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Indicator/index.d.ts +32 -0
- package/lib/typescript/module/src/components/Indicator/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Input/Input.styles.d.ts +5 -5
- package/lib/typescript/module/src/components/Kbd/index.d.ts +12 -0
- package/lib/typescript/module/src/components/Kbd/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/List/index.d.ts +42 -0
- package/lib/typescript/module/src/components/List/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Loader/Loader.d.ts.map +1 -1
- package/lib/typescript/module/src/components/LoadingOverlay/index.d.ts +23 -0
- package/lib/typescript/module/src/components/LoadingOverlay/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Mark/index.d.ts +14 -0
- package/lib/typescript/module/src/components/Mark/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/MediaQuery/index.d.ts +24 -0
- package/lib/typescript/module/src/components/MediaQuery/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Menu/index.d.ts +64 -0
- package/lib/typescript/module/src/components/Menu/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Modal/index.d.ts +40 -0
- package/lib/typescript/module/src/components/Modal/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/MultiSelect/index.d.ts +53 -0
- package/lib/typescript/module/src/components/MultiSelect/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/NativeSelect/index.d.ts +45 -0
- package/lib/typescript/module/src/components/NativeSelect/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/NavLink/index.d.ts +30 -0
- package/lib/typescript/module/src/components/NavLink/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Notification/index.d.ts +28 -0
- package/lib/typescript/module/src/components/Notification/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/NumberInput/index.d.ts +47 -0
- package/lib/typescript/module/src/components/NumberInput/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Overlay/index.d.ts +24 -0
- package/lib/typescript/module/src/components/Overlay/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Pagination/index.d.ts +37 -0
- package/lib/typescript/module/src/components/Pagination/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Paper/index.d.ts +18 -0
- package/lib/typescript/module/src/components/Paper/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/PasswordInput/index.d.ts +15 -0
- package/lib/typescript/module/src/components/PasswordInput/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/PinInput/index.d.ts +33 -0
- package/lib/typescript/module/src/components/PinInput/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Popover/index.d.ts +44 -0
- package/lib/typescript/module/src/components/Popover/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Portal/index.d.ts +10 -0
- package/lib/typescript/module/src/components/Portal/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Progress/index.d.ts +29 -0
- package/lib/typescript/module/src/components/Progress/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Radio/index.d.ts +24 -0
- package/lib/typescript/module/src/components/Radio/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Rating/index.d.ts +32 -0
- package/lib/typescript/module/src/components/Rating/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/RingProgress/index.d.ts +61 -0
- package/lib/typescript/module/src/components/RingProgress/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/SegmentedControl/index.d.ts +35 -0
- package/lib/typescript/module/src/components/SegmentedControl/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Select/index.d.ts +53 -0
- package/lib/typescript/module/src/components/Select/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/SimpleGrid/index.d.ts +22 -0
- package/lib/typescript/module/src/components/SimpleGrid/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Skeleton/index.d.ts +22 -0
- package/lib/typescript/module/src/components/Skeleton/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Slider/index.d.ts +43 -0
- package/lib/typescript/module/src/components/Slider/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Space/index.d.ts +13 -0
- package/lib/typescript/module/src/components/Space/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Spoiler/index.d.ts +22 -0
- package/lib/typescript/module/src/components/Spoiler/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Stepper/index.d.ts +55 -0
- package/lib/typescript/module/src/components/Stepper/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Switch/index.d.ts +24 -0
- package/lib/typescript/module/src/components/Switch/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Table/index.d.ts +72 -0
- package/lib/typescript/module/src/components/Table/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Text/index.d.ts +4 -0
- package/lib/typescript/module/src/components/Text/index.d.ts.map +1 -1
- package/lib/typescript/module/src/components/TextInput/index.d.ts +31 -0
- package/lib/typescript/module/src/components/TextInput/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Textarea/index.d.ts +12 -0
- package/lib/typescript/module/src/components/Textarea/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/ThemeIcon/index.d.ts +21 -0
- package/lib/typescript/module/src/components/ThemeIcon/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Timeline/index.d.ts +52 -0
- package/lib/typescript/module/src/components/Timeline/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Title/index.d.ts +14 -0
- package/lib/typescript/module/src/components/Title/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Tooltip/index.d.ts +36 -0
- package/lib/typescript/module/src/components/Tooltip/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/TransferList/index.d.ts +42 -0
- package/lib/typescript/module/src/components/TransferList/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/Transition/index.d.ts +25 -0
- package/lib/typescript/module/src/components/Transition/index.d.ts.map +1 -0
- package/lib/typescript/module/src/components/index.d.ts +69 -0
- package/lib/typescript/module/src/components/index.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/create-theme.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/default-theme.d.ts +20 -0
- package/lib/typescript/module/src/theme/default-theme.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/functions/attach-functions.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/functions/fns/helpers.d.ts +23 -0
- package/lib/typescript/module/src/theme/functions/fns/helpers.d.ts.map +1 -0
- package/lib/typescript/module/src/theme/functions/fns/index.d.ts +22 -1
- package/lib/typescript/module/src/theme/functions/fns/index.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/functions/fns/theme-color/theme-color.d.ts +8 -1
- package/lib/typescript/module/src/theme/functions/fns/theme-color/theme-color.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/functions/fns/variant.d.ts +19 -1
- package/lib/typescript/module/src/theme/functions/fns/variant.d.ts.map +1 -1
- package/lib/typescript/module/src/theme/utils/rem.d.ts +2 -2
- package/lib/typescript/module/src/theme/utils/rem.d.ts.map +1 -1
- package/package.json +3 -1
- package/src/components/Accordion/index.tsx +297 -0
- package/src/components/ActionIcon/ActionIcon.tsx +61 -44
- package/src/components/Anchor/index.tsx +139 -0
- package/src/components/AspectRatio/index.tsx +68 -0
- package/src/components/Avatar/index.tsx +164 -0
- package/src/components/BackgroundImage/index.tsx +77 -0
- package/src/components/Badge/index.tsx +193 -0
- package/src/components/Blockquote/index.tsx +104 -0
- package/src/components/BoxView/index.tsx +90 -2
- package/src/components/Breadcrumbs/index.tsx +64 -0
- package/src/components/Burger/index.tsx +230 -0
- package/src/components/Button/Button.styles.ts +36 -16
- package/src/components/Button/index.tsx +3 -1
- package/src/components/Card/index.tsx +166 -0
- package/src/components/Center/index.tsx +40 -0
- package/src/components/Checkbox/index.tsx +168 -0
- package/src/components/Chip/index.tsx +350 -0
- package/src/components/CloseButton/index.tsx +154 -0
- package/src/components/Code/index.tsx +83 -0
- package/src/components/Collapse/index.tsx +108 -0
- package/src/components/ColorSwatch/index.tsx +106 -0
- package/src/components/Container/index.tsx +92 -0
- package/src/components/CopyButton/index.tsx +60 -0
- package/src/components/Dialog/index.tsx +189 -0
- package/src/components/Divider/index.tsx +161 -0
- package/src/components/Drawer/index.tsx +315 -0
- package/src/components/Flex/index.tsx +87 -0
- package/src/components/Grid/index.tsx +167 -0
- package/src/components/Group/index.tsx +24 -5
- package/src/components/Highlight/index.tsx +93 -0
- package/src/components/Image/index.tsx +180 -0
- package/src/components/Indicator/index.tsx +240 -0
- package/src/components/Kbd/index.tsx +84 -0
- package/src/components/List/index.tsx +294 -0
- package/src/components/Loader/Loader.tsx +27 -17
- package/src/components/LoadingOverlay/index.tsx +103 -0
- package/src/components/Mark/index.tsx +51 -0
- package/src/components/MediaQuery/index.tsx +133 -0
- package/src/components/Menu/index.tsx +395 -0
- package/src/components/Modal/index.tsx +318 -0
- package/src/components/MultiSelect/index.tsx +458 -0
- package/src/components/NativeSelect/index.tsx +387 -0
- package/src/components/NavLink/index.tsx +205 -0
- package/src/components/Notification/index.tsx +175 -0
- package/src/components/NumberInput/index.tsx +356 -0
- package/src/components/Overlay/index.tsx +100 -0
- package/src/components/Pagination/index.tsx +336 -0
- package/src/components/Paper/index.tsx +155 -0
- package/src/components/PasswordInput/index.tsx +78 -0
- package/src/components/PinInput/index.tsx +251 -0
- package/src/components/Popover/index.tsx +244 -0
- package/src/components/Portal/index.tsx +75 -0
- package/src/components/Progress/index.tsx +182 -0
- package/src/components/Radio/index.tsx +169 -0
- package/src/components/Rating/index.tsx +214 -0
- package/src/components/RingProgress/index.tsx +206 -0
- package/src/components/SegmentedControl/index.tsx +259 -0
- package/src/components/Select/index.tsx +377 -0
- package/src/components/SimpleGrid/index.tsx +119 -0
- package/src/components/Skeleton/index.tsx +149 -0
- package/src/components/Slider/index.tsx +338 -0
- package/src/components/Space/index.tsx +48 -0
- package/src/components/Spoiler/index.tsx +123 -0
- package/src/components/Stepper/index.tsx +388 -0
- package/src/components/Switch/index.tsx +146 -0
- package/src/components/Table/index.tsx +402 -0
- package/src/components/Text/index.tsx +6 -1
- package/src/components/TextInput/index.tsx +232 -0
- package/src/components/Textarea/index.tsx +61 -0
- package/src/components/ThemeIcon/index.tsx +167 -0
- package/src/components/Timeline/index.tsx +331 -0
- package/src/components/Title/index.tsx +53 -0
- package/src/components/Tooltip/index.tsx +259 -0
- package/src/components/TransferList/index.tsx +399 -0
- package/src/components/Transition/index.tsx +225 -0
- package/src/components/index.tsx +101 -0
- package/src/theme/create-theme.ts +1 -0
- package/src/theme/default-theme.ts +24 -0
- package/src/theme/functions/attach-functions.ts +8 -1
- package/src/theme/functions/fns/helpers.ts +36 -0
- package/src/theme/functions/fns/index.ts +2 -0
- package/src/theme/functions/fns/theme-color/theme-color.ts +34 -3
- package/src/theme/functions/fns/variant.ts +110 -2
- package/src/theme/utils/rem.ts +9 -7
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","forwardRef","useState","TouchableOpacity","BoxView","Text","useComponentDefaultProps","createStyles","rem","jsx","_jsx","sizes","xs","sm","md","lg","xl","useStyles","theme","color","emptyColor","size","colors","primaryColor","emptyColors","gray","sizeValue","root","flexDirection","alignItems","symbolWrapper","marginHorizontal","symbol","fontSize","lineHeight","symbolFilled","primaryBgColor","symbolEmpty","symbolHovered","opacity","defaultProps","count","fractions","readOnly","highlightSelectedOnly","StarSymbol","filled","children","Rating","props","ref","value","controlledValue","defaultValue","onChange","emptySymbol","style","others","styles","sx","name","uncontrolledValue","setUncontrolledValue","hoveredValue","setHoveredValue","undefined","handleClick","index","newValue","renderSymbol","currentValue","isActive","fillPercentage","Math","floor","isHovered","symbolContent","emptySymbolContent","onPress","onPressIn","onPressOut","disabled","activeOpacity","Array","from","length","_","displayName"],"sourceRoot":"../../../../src","sources":["components/Rating/index.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAIC,UAAU,EAAEC,QAAQ,QAAQ,OAAO;AACnD,SAASC,gBAAgB,QAAQ,cAAc;AAC/C,SAASC,OAAO,QAAQ,qBAAY;AACpC,SAASC,IAAI,QAAQ,kBAAS;AAE9B,SAASC,wBAAw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EtC,QAAS;MACnBa,KAAK,EAAEE,MAAM,CAAC5B,aAAc;MAC5BoD,aAAa,EAAE,GAAI;MAAAnC,QAAA,eAEnBrC,IAAA,CAACN,OAAO;QAAA2C,QAAA,EACLyB,cAAc,GAAG,CAAC,gBACjB9D,IAAA,CAACL,IAAI;UACHmD,KAAK,EAAE,CACLE,MAAM,CAAC1B,MAAM,EACb0B,MAAM,CAACvB,YAAY,EACnBwC,SAAS,IAAI,CAAC/B,qBAAqB,IAAIc,MAAM,CAACpB,aAAa,CAC3D;UAAAS,QAAA,EAED6B;QAAa,CACV,CAAC,gBAEPlE,IAAA,CAACL,IAAI;UACHmD,KAAK,EAAE,CACLE,MAAM,CAAC1B,MAAM,EACb0B,MAAM,CAACrB,WAAW,EAClBsC,SAAS,IAAI,CAAC/B,qBAAqB,IAAIc,MAAM,CAACpB,aAAa,CAC3D;UAAAS,QAAA,EAED8B;QAAkB,CACf;MACP,CACM;IAAC,GA9BLV,KA+BW,CAAC;EAEvB,CAAC;EAED,oBACEzD,IAAA,CAACN,OAAO;IAAC8C,GAAG,EAAEA,GAAI;IAACM,KAAK,EAAEG,EAAE,CAACD,MAAM,CAAC/B,IAAI,EAAE6B,KAAK,CAAE;IAAA,GAAKC,MAAM;IAAAV,QAAA,EACzDoC,KAAK,CAACC,IAAI,CAAC;MAAEC,MAAM,EAAE5C;IAAO,CAAC,EAAE,CAAC6C,CAAC,EAAEnB,KAAK,KAAKE,YAAY,CAACF,KAAK,CAAC;EAAC,CAC3D,CAAC;AAEd,CAAC,CAAC;AAEFnB,MAAM,CAACuC,WAAW,GAAG,QAAQ","ignoreList":[]}
|
|
@@ -0,0 +1,169 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React, { forwardRef } from 'react';
|
|
4
|
+
import { View } from 'react-native';
|
|
5
|
+
import { BoxView } from "../BoxView/index.js";
|
|
6
|
+
import { Text } from "../Text/index.js";
|
|
7
|
+
import { useComponentDefaultProps, useTheme } from "../../theme/theme-provider.js";
|
|
8
|
+
import { createStyles } from "../../theme/index.js";
|
|
9
|
+
import { rem } from "../../theme/utils/rem.js";
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* NOTE: This is a simplified version of RingProgress.
|
|
13
|
+
* For full SVG-based circular progress, install react-native-svg:
|
|
14
|
+
* yarn add react-native-svg
|
|
15
|
+
*
|
|
16
|
+
* This version uses View-based rendering with transform rotation.
|
|
17
|
+
* For production use, consider implementing with react-native-svg.
|
|
18
|
+
*/
|
|
19
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
20
|
+
const useStyles = createStyles((theme, {
|
|
21
|
+
size,
|
|
22
|
+
thickness,
|
|
23
|
+
rootColor
|
|
24
|
+
}) => ({
|
|
25
|
+
root: {
|
|
26
|
+
width: size,
|
|
27
|
+
height: size,
|
|
28
|
+
position: 'relative',
|
|
29
|
+
alignItems: 'center',
|
|
30
|
+
justifyContent: 'center'
|
|
31
|
+
},
|
|
32
|
+
track: {
|
|
33
|
+
position: 'absolute',
|
|
34
|
+
width: size,
|
|
35
|
+
height: size,
|
|
36
|
+
borderRadius: size / 2,
|
|
37
|
+
borderWidth: thickness,
|
|
38
|
+
borderColor: rootColor
|
|
39
|
+
},
|
|
40
|
+
label: {
|
|
41
|
+
position: 'absolute',
|
|
42
|
+
fontSize: rem(14),
|
|
43
|
+
fontWeight: '600',
|
|
44
|
+
color: theme.colorScheme === 'dark' ? (theme.colors.dark || [])[0] : theme.black
|
|
45
|
+
},
|
|
46
|
+
// Simplified progress representation
|
|
47
|
+
progressContainer: {
|
|
48
|
+
position: 'absolute',
|
|
49
|
+
width: size,
|
|
50
|
+
height: size,
|
|
51
|
+
borderRadius: size / 2,
|
|
52
|
+
overflow: 'hidden'
|
|
53
|
+
}
|
|
54
|
+
}));
|
|
55
|
+
const defaultProps = {
|
|
56
|
+
size: 120,
|
|
57
|
+
thickness: 12,
|
|
58
|
+
roundCaps: false
|
|
59
|
+
};
|
|
60
|
+
export const RingProgress = /*#__PURE__*/forwardRef((props, ref) => {
|
|
61
|
+
const {
|
|
62
|
+
sections,
|
|
63
|
+
size,
|
|
64
|
+
thickness,
|
|
65
|
+
label,
|
|
66
|
+
rootColor: customRootColor,
|
|
67
|
+
roundCaps,
|
|
68
|
+
style,
|
|
69
|
+
...others
|
|
70
|
+
} = useComponentDefaultProps('RingProgress', defaultProps, props);
|
|
71
|
+
const theme = useTheme();
|
|
72
|
+
const rootColor = customRootColor || (theme.colorScheme === 'dark' ? (theme.colors.dark || [])[4] : (theme.colors.gray || [])[2]);
|
|
73
|
+
const {
|
|
74
|
+
styles,
|
|
75
|
+
sx
|
|
76
|
+
} = useStyles({
|
|
77
|
+
size,
|
|
78
|
+
thickness,
|
|
79
|
+
rootColor
|
|
80
|
+
}, {
|
|
81
|
+
name: 'RingProgress'
|
|
82
|
+
});
|
|
83
|
+
|
|
84
|
+
// Calculate total value and normalize sections
|
|
85
|
+
const normalizedSections = sections.map(section => ({
|
|
86
|
+
...section,
|
|
87
|
+
percentage: section.value / 100 * 100
|
|
88
|
+
}));
|
|
89
|
+
|
|
90
|
+
// Render simplified ring using borders and transforms
|
|
91
|
+
// Note: This is a basic implementation. For full SVG support, use react-native-svg
|
|
92
|
+
const renderSections = () => {
|
|
93
|
+
let currentAngle = 0;
|
|
94
|
+
return normalizedSections.map((section, index) => {
|
|
95
|
+
const colors = theme.colors[section.color] || theme.colors[theme.primaryColor];
|
|
96
|
+
const sectionColor = colors?.[6] || colors?.[5] || theme.primaryBgColor;
|
|
97
|
+
const angle = section.percentage / 100 * 360;
|
|
98
|
+
const rotation = currentAngle;
|
|
99
|
+
currentAngle += angle;
|
|
100
|
+
|
|
101
|
+
// Simplified representation - just show colored arcs
|
|
102
|
+
// This is a placeholder implementation
|
|
103
|
+
return /*#__PURE__*/_jsx(View, {
|
|
104
|
+
style: {
|
|
105
|
+
position: 'absolute',
|
|
106
|
+
width: size,
|
|
107
|
+
height: size,
|
|
108
|
+
borderRadius: size / 2,
|
|
109
|
+
borderWidth: thickness,
|
|
110
|
+
borderColor: 'transparent',
|
|
111
|
+
borderTopColor: sectionColor,
|
|
112
|
+
transform: [{
|
|
113
|
+
rotate: `${rotation}deg`
|
|
114
|
+
}]
|
|
115
|
+
}
|
|
116
|
+
}, index);
|
|
117
|
+
});
|
|
118
|
+
};
|
|
119
|
+
return /*#__PURE__*/_jsxs(BoxView, {
|
|
120
|
+
ref: ref,
|
|
121
|
+
style: sx(styles.root, style),
|
|
122
|
+
...others,
|
|
123
|
+
children: [/*#__PURE__*/_jsx(View, {
|
|
124
|
+
style: styles.track
|
|
125
|
+
}), /*#__PURE__*/_jsx(View, {
|
|
126
|
+
style: styles.progressContainer,
|
|
127
|
+
children: renderSections()
|
|
128
|
+
}), label && (typeof label === 'string' ? /*#__PURE__*/_jsx(Text, {
|
|
129
|
+
style: styles.label,
|
|
130
|
+
children: label
|
|
131
|
+
}) : /*#__PURE__*/_jsx(View, {
|
|
132
|
+
style: {
|
|
133
|
+
position: 'absolute'
|
|
134
|
+
},
|
|
135
|
+
children: label
|
|
136
|
+
}))]
|
|
137
|
+
});
|
|
138
|
+
});
|
|
139
|
+
RingProgress.displayName = 'RingProgress';
|
|
140
|
+
|
|
141
|
+
/**
|
|
142
|
+
* USAGE NOTE:
|
|
143
|
+
* This is a simplified implementation of RingProgress.
|
|
144
|
+
* For production-quality circular progress with accurate rendering,
|
|
145
|
+
* install react-native-svg and implement using SVG circles with
|
|
146
|
+
* stroke-dasharray and stroke-dashoffset.
|
|
147
|
+
*
|
|
148
|
+
* Example with react-native-svg:
|
|
149
|
+
* ```tsx
|
|
150
|
+
* import Svg, { Circle } from 'react-native-svg';
|
|
151
|
+
*
|
|
152
|
+
* const circumference = 2 * Math.PI * radius;
|
|
153
|
+
* const strokeDashoffset = circumference - (percentage / 100) * circumference;
|
|
154
|
+
*
|
|
155
|
+
* <Svg width={size} height={size}>
|
|
156
|
+
* <Circle
|
|
157
|
+
* cx={size / 2}
|
|
158
|
+
* cy={size / 2}
|
|
159
|
+
* r={radius}
|
|
160
|
+
* stroke={color}
|
|
161
|
+
* strokeWidth={thickness}
|
|
162
|
+
* strokeDasharray={circumference}
|
|
163
|
+
* strokeDashoffset={strokeDashoffset}
|
|
164
|
+
* fill="none"
|
|
165
|
+
* />
|
|
166
|
+
* </Svg>
|
|
167
|
+
* ```
|
|
168
|
+
*/
|
|
169
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","forwardRef","View","BoxView","Text","useComponentDefaultProps","useTheme","createStyles","rem","jsx","_jsx","jsxs","_jsxs","useStyles","theme","size","thickness","rootColor","root","width","height","position","alignItems","justifyContent","track","borderRadius","borderWidth","borderColor","label","fontSize","fontWeight","color","colorScheme","colors","dark","black","progressContainer","overflow","defaultProps","roundCaps","RingProgress","props","ref","sections","customRootColor","style","others","gray","styles","sx","name","normalizedSections","map","section","percentage","value","renderSections","currentAngle","index","primaryColor","sectionColor","primaryBgColor","angle","rotation","borderTopColor","transform","rotate","children","displayName"],"sourceRoot":"../../../../src","sources":["components/RingProgress/index.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAIC,UAAU,QAAQ,OAAO;AACzC,SAASC,IAAI,QAAQ,cAAc;AACnC,SAASC,OAAO,QAAQ,qBAAY;AACpC,SAASC,IAAI,QAAQ,kBAAS;AAE9B,SAASC,wBAAwB,EAAEC,QAAQ,QAAQ,+BAA4B;AAC/E,SAASC,YAAY,QAAQ,sBAAa;AAC1C,SAASC,GAAG,QAAQ,0BAAuB;;AAE3C;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AAPA,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AAsCA,MAAMC,SAAS,GAAGN,YAAY,CAC5B,CACEO,KAAK,EACL;EACEC,IAAI;EACJC,SAAS;EACTC;AAKF,CAAC,MACG;EACJC,IAAI,EAAE;IACJC,KAAK,EAAEJ,IAAI;IACXK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GAAI,CAAC;UACvBW,WAAW,EAAEV,SAAS;UACtBW,WAAW,EAAE,aAAa;UAC1BqC,cAAc,EAAEJ,YAAY;UAC5BK,SAAS,EAAE,CAAC;YAAEC,MAAM,EAAE,GAAGH,QAAQ;UAAM,CAAC;QAC1C;MAAE,GAVGL,KAWN,CAAC;IAEN,CAAC,CAAC;EACJ,CAAC;EAED,oBACE9C,KAAA,CAACT,OAAO;IAACuC,GAAG,EAAEA,GAAI;IAACG,KAAK,EAAEI,EAAE,CAACD,MAAM,CAAC9B,IAAI,EAAE2B,KAAK,CAAE;IAAA,GAAKC,MAAM;IAAAqB,QAAA,gBAC1DzD,IAAA,CAACR,IAAI;MAAC2C,KAAK,EAAEG,MAAM,CAACxB;IAAM,CAAE,CAAC,eAC7Bd,IAAA,CAACR,IAAI;MAAC2C,KAAK,EAAEG,MAAM,CAACZ,iBAAkB;MAAA+B,QAAA,EAAEX,cAAc,CAAC;IAAC,CAAO,CAAC,EAC/D5B,KAAK,KACJ,OAAOA,KAAK,KAAK,QAAQ,gBACvBlB,IAAA,CAACN,IAAI;MAACyC,KAAK,EAAEG,MAAM,CAACpB,KAAM;MAAAuC,QAAA,EAAEvC;IAAK,CAAO,CAAC,gBAEzClB,IAAA,CAACR,IAAI;MAAC2C,KAAK,EAAE;QAAExB,QAAQ,EAAE;MAAW,CAAE;MAAA8C,QAAA,EAAEvC;IAAK,CAAO,CACrD,CACF;EAAA,CACM,CAAC;AAEd,CAAC,CAAC;AAEFY,YAAY,CAAC4B,WAAW,GAAG,cAAc;;AAEzC;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA;AACA","ignoreList":[]}
|
|
@@ -0,0 +1,220 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React, { forwardRef, useState, useRef, useEffect } from 'react';
|
|
4
|
+
import { TouchableOpacity, Animated } from 'react-native';
|
|
5
|
+
import { BoxView } from "../BoxView/index.js";
|
|
6
|
+
import { Text } from "../Text/index.js";
|
|
7
|
+
import { useComponentDefaultProps } from "../../theme/theme-provider.js";
|
|
8
|
+
import { createStyles } from "../../theme/index.js";
|
|
9
|
+
import { rem } from "../../theme/utils/rem.js";
|
|
10
|
+
import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
|
|
11
|
+
const sizes = {
|
|
12
|
+
xs: {
|
|
13
|
+
fontSize: rem(10),
|
|
14
|
+
padding: rem(4),
|
|
15
|
+
height: rem(24)
|
|
16
|
+
},
|
|
17
|
+
sm: {
|
|
18
|
+
fontSize: rem(12),
|
|
19
|
+
padding: rem(6),
|
|
20
|
+
height: rem(28)
|
|
21
|
+
},
|
|
22
|
+
md: {
|
|
23
|
+
fontSize: rem(14),
|
|
24
|
+
padding: rem(8),
|
|
25
|
+
height: rem(32)
|
|
26
|
+
},
|
|
27
|
+
lg: {
|
|
28
|
+
fontSize: rem(16),
|
|
29
|
+
padding: rem(10),
|
|
30
|
+
height: rem(38)
|
|
31
|
+
},
|
|
32
|
+
xl: {
|
|
33
|
+
fontSize: rem(18),
|
|
34
|
+
padding: rem(12),
|
|
35
|
+
height: rem(44)
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
const useStyles = createStyles((theme, {
|
|
39
|
+
radius,
|
|
40
|
+
disabled,
|
|
41
|
+
orientation,
|
|
42
|
+
fullWidth
|
|
43
|
+
}, {
|
|
44
|
+
size
|
|
45
|
+
}) => {
|
|
46
|
+
const sizeStyles = sizes[size] || sizes.md;
|
|
47
|
+
return {
|
|
48
|
+
root: {
|
|
49
|
+
position: 'relative',
|
|
50
|
+
flexDirection: orientation === 'horizontal' ? 'row' : 'column',
|
|
51
|
+
backgroundColor: theme.colorScheme === 'dark' ? theme.colors.dark?.[6] : theme.colors.gray?.[1],
|
|
52
|
+
borderRadius: theme.fn.radius(radius),
|
|
53
|
+
padding: rem(4),
|
|
54
|
+
opacity: disabled ? 0.5 : 1,
|
|
55
|
+
...(fullWidth && {
|
|
56
|
+
width: '100%'
|
|
57
|
+
})
|
|
58
|
+
},
|
|
59
|
+
indicator: {
|
|
60
|
+
position: 'absolute',
|
|
61
|
+
backgroundColor: theme.white,
|
|
62
|
+
borderRadius: theme.fn.radius(radius),
|
|
63
|
+
shadowColor: '#000',
|
|
64
|
+
shadowOffset: {
|
|
65
|
+
width: 0,
|
|
66
|
+
height: 1
|
|
67
|
+
},
|
|
68
|
+
shadowOpacity: 0.05,
|
|
69
|
+
shadowRadius: 1,
|
|
70
|
+
elevation: 1,
|
|
71
|
+
...(theme.colorScheme === 'dark' && {
|
|
72
|
+
backgroundColor: theme.colors.dark?.[5]
|
|
73
|
+
})
|
|
74
|
+
},
|
|
75
|
+
segment: {
|
|
76
|
+
flex: 1,
|
|
77
|
+
paddingHorizontal: sizeStyles.padding,
|
|
78
|
+
paddingVertical: sizeStyles.padding,
|
|
79
|
+
minHeight: sizeStyles.height,
|
|
80
|
+
justifyContent: 'center',
|
|
81
|
+
alignItems: 'center',
|
|
82
|
+
borderRadius: theme.fn.radius(radius),
|
|
83
|
+
zIndex: 1
|
|
84
|
+
},
|
|
85
|
+
label: {
|
|
86
|
+
fontSize: sizeStyles.fontSize,
|
|
87
|
+
fontWeight: '500',
|
|
88
|
+
textAlign: 'center'
|
|
89
|
+
},
|
|
90
|
+
activeLabel: {
|
|
91
|
+
color: theme.colorScheme === 'dark' ? theme.white : theme.black
|
|
92
|
+
},
|
|
93
|
+
inactiveLabel: {
|
|
94
|
+
color: theme.colorScheme === 'dark' ? theme.colors.dark?.[1] : theme.colors.gray?.[7]
|
|
95
|
+
},
|
|
96
|
+
disabledLabel: {
|
|
97
|
+
color: theme.colorScheme === 'dark' ? theme.colors.dark?.[3] : theme.colors.gray?.[5]
|
|
98
|
+
}
|
|
99
|
+
};
|
|
100
|
+
});
|
|
101
|
+
const defaultProps = {
|
|
102
|
+
size: 'md',
|
|
103
|
+
color: 'blue',
|
|
104
|
+
radius: 'sm',
|
|
105
|
+
disabled: false,
|
|
106
|
+
orientation: 'horizontal',
|
|
107
|
+
fullWidth: false,
|
|
108
|
+
transitionDuration: 200
|
|
109
|
+
};
|
|
110
|
+
export const SegmentedControl = /*#__PURE__*/forwardRef((props, ref) => {
|
|
111
|
+
const {
|
|
112
|
+
value: controlledValue,
|
|
113
|
+
defaultValue,
|
|
114
|
+
onChange,
|
|
115
|
+
data,
|
|
116
|
+
size,
|
|
117
|
+
color,
|
|
118
|
+
radius,
|
|
119
|
+
disabled,
|
|
120
|
+
orientation,
|
|
121
|
+
fullWidth,
|
|
122
|
+
transitionDuration,
|
|
123
|
+
style,
|
|
124
|
+
...others
|
|
125
|
+
} = useComponentDefaultProps('SegmentedControl', defaultProps, props);
|
|
126
|
+
const {
|
|
127
|
+
styles,
|
|
128
|
+
sx
|
|
129
|
+
} = useStyles({
|
|
130
|
+
color,
|
|
131
|
+
radius,
|
|
132
|
+
disabled,
|
|
133
|
+
orientation,
|
|
134
|
+
fullWidth
|
|
135
|
+
}, {
|
|
136
|
+
name: 'SegmentedControl',
|
|
137
|
+
size
|
|
138
|
+
});
|
|
139
|
+
|
|
140
|
+
// Normalize data to SegmentedControlItem[]
|
|
141
|
+
const normalizedData = data.map(item => typeof item === 'string' ? {
|
|
142
|
+
label: item,
|
|
143
|
+
value: item,
|
|
144
|
+
disabled: false
|
|
145
|
+
} : item);
|
|
146
|
+
const [uncontrolledValue, setUncontrolledValue] = useState(defaultValue ?? normalizedData[0]?.value ?? '');
|
|
147
|
+
const [segmentLayouts, setSegmentLayouts] = useState([]);
|
|
148
|
+
const value = controlledValue !== undefined ? controlledValue : uncontrolledValue;
|
|
149
|
+
const activeIndex = normalizedData.findIndex(item => item.value === value);
|
|
150
|
+
const indicatorPosition = useRef(new Animated.Value(0)).current;
|
|
151
|
+
const indicatorSize = useRef(new Animated.Value(0)).current;
|
|
152
|
+
useEffect(() => {
|
|
153
|
+
if (segmentLayouts[activeIndex]) {
|
|
154
|
+
const layout = segmentLayouts[activeIndex];
|
|
155
|
+
Animated.parallel([Animated.timing(indicatorPosition, {
|
|
156
|
+
toValue: orientation === 'horizontal' ? layout.x : layout.y,
|
|
157
|
+
duration: transitionDuration,
|
|
158
|
+
useNativeDriver: false
|
|
159
|
+
}), Animated.timing(indicatorSize, {
|
|
160
|
+
toValue: orientation === 'horizontal' ? layout.width : layout.height,
|
|
161
|
+
duration: transitionDuration,
|
|
162
|
+
useNativeDriver: false
|
|
163
|
+
})]).start();
|
|
164
|
+
}
|
|
165
|
+
}, [activeIndex, segmentLayouts, orientation, transitionDuration, indicatorPosition, indicatorSize]);
|
|
166
|
+
const handleSegmentLayout = (index, event) => {
|
|
167
|
+
const {
|
|
168
|
+
x,
|
|
169
|
+
y,
|
|
170
|
+
width,
|
|
171
|
+
height
|
|
172
|
+
} = event.nativeEvent.layout;
|
|
173
|
+
setSegmentLayouts(prev => {
|
|
174
|
+
const newLayouts = [...prev];
|
|
175
|
+
newLayouts[index] = {
|
|
176
|
+
x,
|
|
177
|
+
y,
|
|
178
|
+
width,
|
|
179
|
+
height
|
|
180
|
+
};
|
|
181
|
+
return newLayouts;
|
|
182
|
+
});
|
|
183
|
+
};
|
|
184
|
+
const handlePress = item => {
|
|
185
|
+
if (disabled || item.disabled) return;
|
|
186
|
+
if (controlledValue === undefined) {
|
|
187
|
+
setUncontrolledValue(item.value);
|
|
188
|
+
}
|
|
189
|
+
onChange?.(item.value);
|
|
190
|
+
};
|
|
191
|
+
const indicatorStyle = {
|
|
192
|
+
[orientation === 'horizontal' ? 'left' : 'top']: indicatorPosition,
|
|
193
|
+
[orientation === 'horizontal' ? 'width' : 'height']: indicatorSize,
|
|
194
|
+
[orientation === 'horizontal' ? 'height' : 'width']: '100%'
|
|
195
|
+
};
|
|
196
|
+
return /*#__PURE__*/_jsxs(BoxView, {
|
|
197
|
+
ref: ref,
|
|
198
|
+
style: sx(styles.root, style),
|
|
199
|
+
...others,
|
|
200
|
+
children: [segmentLayouts.length === normalizedData.length && /*#__PURE__*/_jsx(Animated.View, {
|
|
201
|
+
style: [styles.indicator, indicatorStyle]
|
|
202
|
+
}), normalizedData.map((item, index) => {
|
|
203
|
+
const isActive = item.value === value;
|
|
204
|
+
const isDisabled = disabled || item.disabled;
|
|
205
|
+
return /*#__PURE__*/_jsx(TouchableOpacity, {
|
|
206
|
+
style: styles.segment,
|
|
207
|
+
onPress: () => handlePress(item),
|
|
208
|
+
disabled: isDisabled,
|
|
209
|
+
activeOpacity: 0.7,
|
|
210
|
+
onLayout: event => handleSegmentLayout(index, event),
|
|
211
|
+
children: /*#__PURE__*/_jsx(Text, {
|
|
212
|
+
style: [styles.label, isActive ? styles.activeLabel : styles.inactiveLabel, isDisabled && styles.disabledLabel],
|
|
213
|
+
children: item.label
|
|
214
|
+
})
|
|
215
|
+
}, item.value);
|
|
216
|
+
})]
|
|
217
|
+
});
|
|
218
|
+
});
|
|
219
|
+
SegmentedControl.displayName = 'SegmentedControl';
|
|
220
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["React","forwardRef","useState","useRef","useEffect","TouchableOpacity","Animated","BoxView","Text","useComponentDefaultProps","createStyles","rem","jsx","_jsx","jsxs","_jsxs","sizes","xs","fontSize","padding","height","sm","md","lg","xl","useStyles","theme","radius","disabled","orientation","fullWidth","size","sizeStyles","root","position","flexDirection","backgroundColor","colorScheme","colors","dark","gray","borderRadius","fn","opacity","width","indicator","white","shadowColor","shadowOffset","shadowOpacity","shadowRadius","elevation","segment","flex","paddingHorizontal","paddingVertical","minHeight","justifyContent","alignItems","zIndex","label","fontWeight","textAlign","activeLabel","color","black","inactiveLabel","disabledLabel","defaultProps","transitionDuration","SegmentedControl","props","ref","value","controlledValue","defaultValue","onChange","data","style","others","styles","sx","name","normalizedData","map","item","uncontrolledValue","setUncontrolledValue","segmentLayouts","setSegmentLayouts","undefined","activeIndex","findIndex","indicatorPosition","Value","current","indicatorSize","layout","parallel","timing","toValue","x","y","duration","useNativeDriver","start","handleSegmentLayout","index","event","nativeEvent","prev","newLayouts","handlePress","indicatorStyle","children","length","View","isActive","isDisabled","onPress","activeOpacity","onLayout","displayName"],"sourceRoot":"../../../../src","sources":["components/SegmentedControl/index.tsx"],"mappings":";;AAAA,OAAOA,KAAK,IAAIC,UAAU,EAAEC,QAAQ,EAAEC,MAAM,EAAEC,SAAS,QAAQ,OAAO;AACtE,SAASC,gBAAgB,EAAEC,QAAQ,QAAQ,cAAc;AAEzD,SAASC,OAAO,QAAQ,qBAAY;AACpC,SAASC,IAAI,QAAQ,kBAAS;AAE9B,SAASC,wBAAwB,QAAQ,+BAA4B;AACrE,SAASC,YAAY,QAAQ,sBAAa;AAC1C,SAASC,GAAG,QAAQ,0BAAuB;AAAC,SAAAC,GAAA,IAAAC,IAAA,EAAAC,IAAA,IAAAC,KAAA;AA8C5C,MAAMC,KAAK,GAAG;EACZC,EAAE,EAAE;IAAEC,QAAQ,EAAEP,GAAG,CAAC,EAAE,CAAC;IAAEQ,OAAO,EAAER,GAAG,CAAC,CAAC,CAAC;IAAES,MAAM,EAAET,GAAG,CAAC,EAAE;EAAE,CAAC;EAC3DU,EAAE,EAAE;IAAEH,QAAQ,EAAEP,GAAG,CAAC,EAAE,CAAC;IAAEQ,OAAO,EAAER,GAAG,CAAC,CAAC,CAAC;IAAES,MAAM,EAAET,GAAG,CAAC,EAAE;EAAE,CAAC;EAC3DW,EAAE,EAAE;IAAEJ,QAAQ,EAAEP,GAAG,CAAC,EAAE,CAAC;IAAEQ,OAAO,EAAER,GAAG,CAAC,CAAC,CAAC;IAAES,MAAM,EAAET,GAAG,CAAC,EAAE;EAAE,CAAC;EAC3DY,EAAE,EAAE;IAAEL,QAAQ,EAAEP,GAAG,CAAC,EAAE,CAAC;IAAEQ,OAAO,EAAER,GAAG,CAAC,EAAE,CAAC;IAAES,MAAM,EAAET,GAAG,CAAC,EAAE;EAAE,CAAC;EAC5Da,EAA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AEE,MAAM,CAAC5B,OAAQ;QACtBmE,OAAO,EAAEA,CAAA,KAAMP,WAAW,CAAC3B,IAAI,CAAE;QACjCzD,QAAQ,EAAE0F,UAAW;QACrBE,aAAa,EAAE,GAAI;QACnBC,QAAQ,EAAGb,KAAK,IAAKF,mBAAmB,CAACC,KAAK,EAAEC,KAAK,CAAE;QAAAM,QAAA,eAEvDrG,IAAA,CAACL,IAAI;UACHsE,KAAK,EAAE,CACLE,MAAM,CAACpB,KAAK,EACZyD,QAAQ,GAAGrC,MAAM,CAACjB,WAAW,GAAGiB,MAAM,CAACd,aAAa,EACpDoD,UAAU,IAAItC,MAAM,CAACb,aAAa,CAClC;UAAA+C,QAAA,EAED7B,IAAI,CAACzB;QAAK,CACP;MAAC,GAfFyB,IAAI,CAACZ,KAgBM,CAAC;IAEvB,CAAC,CAAC;EAAA,CACK,CAAC;AAEd,CAAC,CAAC;AAEFH,gBAAgB,CAACoD,WAAW,GAAG,kBAAkB","ignoreList":[]}
|
|
@@ -0,0 +1,239 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import React, { forwardRef, useState } from 'react';
|
|
4
|
+
import { Modal, ScrollView, TouchableOpacity } from 'react-native';
|
|
5
|
+
import { BoxView } from "../BoxView/index.js";
|
|
6
|
+
import { Text } from "../Text/index.js";
|
|
7
|
+
import { TextInput } from "../TextInput/index.js";
|
|
8
|
+
import { useComponentDefaultProps } from "../../theme/theme-provider.js";
|
|
9
|
+
import { createStyles } from "../../theme/index.js";
|
|
10
|
+
import { rem } from "../../theme/utils/rem.js";
|
|
11
|
+
import { jsx as _jsx, jsxs as _jsxs, Fragment as _Fragment } from "react/jsx-runtime";
|
|
12
|
+
const useStyles = createStyles((theme, {
|
|
13
|
+
color
|
|
14
|
+
}) => {
|
|
15
|
+
const colors = theme.colors[color] || theme.colors[theme.primaryColor];
|
|
16
|
+
return {
|
|
17
|
+
modalOverlay: {
|
|
18
|
+
flex: 1,
|
|
19
|
+
backgroundColor: 'rgba(0, 0, 0, 0.5)',
|
|
20
|
+
justifyContent: 'flex-end'
|
|
21
|
+
},
|
|
22
|
+
modalContent: {
|
|
23
|
+
backgroundColor: theme.colorScheme === 'dark' ? (theme.colors.dark || [])[7] : theme.white,
|
|
24
|
+
borderTopLeftRadius: theme.radius.lg,
|
|
25
|
+
borderTopRightRadius: theme.radius.lg,
|
|
26
|
+
maxHeight: '80%'
|
|
27
|
+
},
|
|
28
|
+
searchContainer: {
|
|
29
|
+
padding: theme.spacing.md,
|
|
30
|
+
borderBottomWidth: 1,
|
|
31
|
+
borderBottomColor: theme.colorScheme === 'dark' ? (theme.colors.dark || [])[4] : (theme.colors.gray || [])[2]
|
|
32
|
+
},
|
|
33
|
+
listContainer: {
|
|
34
|
+
paddingVertical: rem(8)
|
|
35
|
+
},
|
|
36
|
+
item: {
|
|
37
|
+
paddingVertical: rem(12),
|
|
38
|
+
paddingHorizontal: theme.spacing.md,
|
|
39
|
+
flexDirection: 'row',
|
|
40
|
+
alignItems: 'center'
|
|
41
|
+
},
|
|
42
|
+
itemSelected: {
|
|
43
|
+
backgroundColor: theme.colorScheme === 'dark' ? (theme.colors.dark || [])[5] : colors?.[0] || (theme.colors.gray || [])[0]
|
|
44
|
+
},
|
|
45
|
+
itemDisabled: {
|
|
46
|
+
opacity: 0.4
|
|
47
|
+
},
|
|
48
|
+
itemText: {
|
|
49
|
+
fontSize: rem(14),
|
|
50
|
+
color: theme.colorScheme === 'dark' ? (theme.colors.dark || [])[0] : theme.black
|
|
51
|
+
},
|
|
52
|
+
itemTextSelected: {
|
|
53
|
+
fontWeight: '600',
|
|
54
|
+
color: colors?.[6] || colors?.[5] || theme.primaryBgColor
|
|
55
|
+
},
|
|
56
|
+
groupLabel: {
|
|
57
|
+
paddingVertical: rem(8),
|
|
58
|
+
paddingHorizontal: theme.spacing.md,
|
|
59
|
+
fontSize: rem(12),
|
|
60
|
+
fontWeight: '600',
|
|
61
|
+
color: theme.colorScheme === 'dark' ? (theme.colors.dark || [])[2] : (theme.colors.gray || [])[6],
|
|
62
|
+
textTransform: 'uppercase'
|
|
63
|
+
},
|
|
64
|
+
emptyState: {
|
|
65
|
+
padding: theme.spacing.xl,
|
|
66
|
+
alignItems: 'center'
|
|
67
|
+
},
|
|
68
|
+
emptyText: {
|
|
69
|
+
color: theme.colorScheme === 'dark' ? (theme.colors.dark || [])[2] : (theme.colors.gray || [])[6]
|
|
70
|
+
}
|
|
71
|
+
};
|
|
72
|
+
});
|
|
73
|
+
const defaultProps = {
|
|
74
|
+
size: 'md',
|
|
75
|
+
radius: 'sm',
|
|
76
|
+
color: 'blue',
|
|
77
|
+
disabled: false,
|
|
78
|
+
searchable: false,
|
|
79
|
+
clearable: false,
|
|
80
|
+
maxDropdownHeight: 400,
|
|
81
|
+
searchPlaceholder: 'Search...',
|
|
82
|
+
clearButtonLabel: 'Clear'
|
|
83
|
+
};
|
|
84
|
+
const normalizeData = data => {
|
|
85
|
+
return data.map(item => typeof item === 'string' ? {
|
|
86
|
+
value: item,
|
|
87
|
+
label: item
|
|
88
|
+
} : item);
|
|
89
|
+
};
|
|
90
|
+
export const Select = /*#__PURE__*/forwardRef((props, ref) => {
|
|
91
|
+
const {
|
|
92
|
+
data,
|
|
93
|
+
value: controlledValue,
|
|
94
|
+
defaultValue,
|
|
95
|
+
onChange,
|
|
96
|
+
placeholder,
|
|
97
|
+
label,
|
|
98
|
+
description,
|
|
99
|
+
error,
|
|
100
|
+
size,
|
|
101
|
+
radius,
|
|
102
|
+
color,
|
|
103
|
+
disabled,
|
|
104
|
+
searchable,
|
|
105
|
+
searchPlaceholder,
|
|
106
|
+
clearable,
|
|
107
|
+
clearButtonLabel,
|
|
108
|
+
maxDropdownHeight,
|
|
109
|
+
icon,
|
|
110
|
+
rightSection,
|
|
111
|
+
style,
|
|
112
|
+
...others
|
|
113
|
+
} = useComponentDefaultProps('Select', defaultProps, props);
|
|
114
|
+
const [opened, setOpened] = useState(false);
|
|
115
|
+
const [searchQuery, setSearchQuery] = useState('');
|
|
116
|
+
const [value, setValue] = useState(defaultValue || '');
|
|
117
|
+
const {
|
|
118
|
+
styles
|
|
119
|
+
} = useStyles({
|
|
120
|
+
color,
|
|
121
|
+
size
|
|
122
|
+
}, {
|
|
123
|
+
name: 'Select'
|
|
124
|
+
});
|
|
125
|
+
const isControlled = controlledValue !== undefined;
|
|
126
|
+
const currentValue = isControlled ? controlledValue : value;
|
|
127
|
+
const normalizedData = normalizeData(data);
|
|
128
|
+
const selectedItem = normalizedData.find(item => item.value === currentValue);
|
|
129
|
+
const filteredData = searchable ? normalizedData.filter(item => item.label.toLowerCase().includes(searchQuery.toLowerCase())) : normalizedData;
|
|
130
|
+
const handleSelect = itemValue => {
|
|
131
|
+
if (!isControlled) {
|
|
132
|
+
setValue(itemValue);
|
|
133
|
+
}
|
|
134
|
+
onChange?.(itemValue);
|
|
135
|
+
setOpened(false);
|
|
136
|
+
setSearchQuery('');
|
|
137
|
+
};
|
|
138
|
+
const handleClear = () => {
|
|
139
|
+
if (!isControlled) {
|
|
140
|
+
setValue('');
|
|
141
|
+
}
|
|
142
|
+
onChange?.('');
|
|
143
|
+
};
|
|
144
|
+
const groupedData = {};
|
|
145
|
+
let ungroupedItems = [];
|
|
146
|
+
filteredData.forEach(item => {
|
|
147
|
+
if (item.group) {
|
|
148
|
+
if (!groupedData[item.group]) {
|
|
149
|
+
groupedData[item.group] = [];
|
|
150
|
+
}
|
|
151
|
+
groupedData[item.group].push(item);
|
|
152
|
+
} else {
|
|
153
|
+
ungroupedItems.push(item);
|
|
154
|
+
}
|
|
155
|
+
});
|
|
156
|
+
return /*#__PURE__*/_jsxs(_Fragment, {
|
|
157
|
+
children: [/*#__PURE__*/_jsx(TextInput, {
|
|
158
|
+
ref: ref,
|
|
159
|
+
label: label,
|
|
160
|
+
description: description,
|
|
161
|
+
error: error,
|
|
162
|
+
size: size,
|
|
163
|
+
radius: radius,
|
|
164
|
+
icon: icon,
|
|
165
|
+
rightSection: rightSection,
|
|
166
|
+
value: selectedItem?.label || '',
|
|
167
|
+
placeholder: placeholder,
|
|
168
|
+
editable: !disabled,
|
|
169
|
+
onPress: () => !disabled && setOpened(true),
|
|
170
|
+
style: style,
|
|
171
|
+
...others
|
|
172
|
+
}), /*#__PURE__*/_jsx(Modal, {
|
|
173
|
+
visible: opened,
|
|
174
|
+
transparent: true,
|
|
175
|
+
animationType: "slide",
|
|
176
|
+
onRequestClose: () => setOpened(false),
|
|
177
|
+
children: /*#__PURE__*/_jsx(TouchableOpacity, {
|
|
178
|
+
activeOpacity: 1,
|
|
179
|
+
style: styles.modalOverlay,
|
|
180
|
+
onPress: () => setOpened(false),
|
|
181
|
+
children: /*#__PURE__*/_jsxs(TouchableOpacity, {
|
|
182
|
+
activeOpacity: 1,
|
|
183
|
+
style: styles.modalContent,
|
|
184
|
+
children: [searchable && /*#__PURE__*/_jsx(BoxView, {
|
|
185
|
+
style: styles.searchContainer,
|
|
186
|
+
children: /*#__PURE__*/_jsx(TextInput, {
|
|
187
|
+
placeholder: searchPlaceholder,
|
|
188
|
+
value: searchQuery,
|
|
189
|
+
onChange: e => setSearchQuery(e.nativeEvent.text),
|
|
190
|
+
autoFocus: true
|
|
191
|
+
})
|
|
192
|
+
}), /*#__PURE__*/_jsxs(ScrollView, {
|
|
193
|
+
style: {
|
|
194
|
+
maxHeight: maxDropdownHeight
|
|
195
|
+
},
|
|
196
|
+
contentContainerStyle: styles.listContainer,
|
|
197
|
+
children: [clearable && currentValue && /*#__PURE__*/_jsx(TouchableOpacity, {
|
|
198
|
+
style: styles.item,
|
|
199
|
+
onPress: handleClear,
|
|
200
|
+
children: /*#__PURE__*/_jsx(Text, {
|
|
201
|
+
style: styles.itemText,
|
|
202
|
+
children: clearButtonLabel
|
|
203
|
+
})
|
|
204
|
+
}), ungroupedItems.map(item => /*#__PURE__*/_jsx(TouchableOpacity, {
|
|
205
|
+
style: [styles.item, currentValue === item.value && styles.itemSelected, item.disabled && styles.itemDisabled],
|
|
206
|
+
onPress: () => !item.disabled && handleSelect(item.value),
|
|
207
|
+
disabled: item.disabled,
|
|
208
|
+
children: /*#__PURE__*/_jsx(Text, {
|
|
209
|
+
style: [styles.itemText, currentValue === item.value && styles.itemTextSelected],
|
|
210
|
+
children: item.label
|
|
211
|
+
})
|
|
212
|
+
}, item.value)), Object.keys(groupedData).map(group => /*#__PURE__*/_jsxs(React.Fragment, {
|
|
213
|
+
children: [/*#__PURE__*/_jsx(Text, {
|
|
214
|
+
style: styles.groupLabel,
|
|
215
|
+
children: group
|
|
216
|
+
}), (groupedData[group] || []).map(item => /*#__PURE__*/_jsx(TouchableOpacity, {
|
|
217
|
+
style: [styles.item, currentValue === item.value && styles.itemSelected, item.disabled && styles.itemDisabled],
|
|
218
|
+
onPress: () => !item.disabled && handleSelect(item.value),
|
|
219
|
+
disabled: item.disabled,
|
|
220
|
+
children: /*#__PURE__*/_jsx(Text, {
|
|
221
|
+
style: [styles.itemText, currentValue === item.value && styles.itemTextSelected],
|
|
222
|
+
children: item.label
|
|
223
|
+
})
|
|
224
|
+
}, item.value))]
|
|
225
|
+
}, group)), filteredData.length === 0 && /*#__PURE__*/_jsx(BoxView, {
|
|
226
|
+
style: styles.emptyState,
|
|
227
|
+
children: /*#__PURE__*/_jsx(Text, {
|
|
228
|
+
style: styles.emptyText,
|
|
229
|
+
children: "No options found"
|
|
230
|
+
})
|
|
231
|
+
})]
|
|
232
|
+
})]
|
|
233
|
+
})
|
|
234
|
+
})
|
|
235
|
+
})]
|
|
236
|
+
});
|
|
237
|
+
});
|
|
238
|
+
Select.displayName = 'Select';
|
|
239
|
+
//# sourceMappingURL=index.js.map
|