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,140 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.Checkbox = void 0;
|
|
7
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
var _index = require("../BoxView/index.js");
|
|
10
|
+
var _index2 = require("../Text/index.js");
|
|
11
|
+
var _themeProvider = require("../../theme/theme-provider.js");
|
|
12
|
+
var _index3 = require("../../theme/index.js");
|
|
13
|
+
var _rem = require("../../theme/utils/rem.js");
|
|
14
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
15
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
16
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
17
|
+
const sizes = {
|
|
18
|
+
xs: (0, _rem.rem)(14),
|
|
19
|
+
sm: (0, _rem.rem)(18),
|
|
20
|
+
md: (0, _rem.rem)(22),
|
|
21
|
+
lg: (0, _rem.rem)(28),
|
|
22
|
+
xl: (0, _rem.rem)(36)
|
|
23
|
+
};
|
|
24
|
+
const useStyles = (0, _index3.createStyles)((theme, {
|
|
25
|
+
size,
|
|
26
|
+
color,
|
|
27
|
+
disabled
|
|
28
|
+
}) => {
|
|
29
|
+
const colors = theme.colors[color] || theme.colors[theme.primaryColor];
|
|
30
|
+
const checkboxSize = sizes[size] || sizes.md;
|
|
31
|
+
return {
|
|
32
|
+
root: {
|
|
33
|
+
flexDirection: 'row',
|
|
34
|
+
alignItems: 'center',
|
|
35
|
+
opacity: disabled ? 0.5 : 1
|
|
36
|
+
},
|
|
37
|
+
checkbox: {
|
|
38
|
+
width: checkboxSize,
|
|
39
|
+
height: checkboxSize,
|
|
40
|
+
borderRadius: theme.radius.sm,
|
|
41
|
+
borderWidth: 2,
|
|
42
|
+
borderColor: theme.colorScheme === 'dark' ? (theme.colors.dark || [])[4] : (theme.colors.gray || [])[4],
|
|
43
|
+
backgroundColor: 'transparent',
|
|
44
|
+
justifyContent: 'center',
|
|
45
|
+
alignItems: 'center'
|
|
46
|
+
},
|
|
47
|
+
checked: {
|
|
48
|
+
borderColor: colors?.[6] || colors?.[5] || theme.primaryBgColor,
|
|
49
|
+
backgroundColor: colors?.[6] || colors?.[5] || theme.primaryBgColor
|
|
50
|
+
},
|
|
51
|
+
checkmark: {
|
|
52
|
+
color: theme.white,
|
|
53
|
+
fontSize: checkboxSize * 0.6,
|
|
54
|
+
fontWeight: 'bold'
|
|
55
|
+
},
|
|
56
|
+
label: {
|
|
57
|
+
fontSize: theme.fontSizes.sm,
|
|
58
|
+
color: theme.colorScheme === 'dark' ? (theme.colors.dark || [])[0] : theme.black,
|
|
59
|
+
marginLeft: theme.spacing.sm,
|
|
60
|
+
flex: 1
|
|
61
|
+
}
|
|
62
|
+
};
|
|
63
|
+
});
|
|
64
|
+
const defaultProps = {
|
|
65
|
+
size: 'md',
|
|
66
|
+
color: 'blue',
|
|
67
|
+
checked: false,
|
|
68
|
+
indeterminate: false,
|
|
69
|
+
disabled: false
|
|
70
|
+
};
|
|
71
|
+
const Checkbox = exports.Checkbox = /*#__PURE__*/(0, _react.forwardRef)((props, ref) => {
|
|
72
|
+
const {
|
|
73
|
+
label,
|
|
74
|
+
size,
|
|
75
|
+
color,
|
|
76
|
+
checked,
|
|
77
|
+
onChange,
|
|
78
|
+
indeterminate,
|
|
79
|
+
disabled,
|
|
80
|
+
style,
|
|
81
|
+
wrapperStyle,
|
|
82
|
+
...otherProps
|
|
83
|
+
} = (0, _themeProvider.useComponentDefaultProps)('Checkbox', defaultProps, props);
|
|
84
|
+
const {
|
|
85
|
+
styles,
|
|
86
|
+
sx
|
|
87
|
+
} = useStyles({
|
|
88
|
+
size,
|
|
89
|
+
color,
|
|
90
|
+
disabled
|
|
91
|
+
}, {
|
|
92
|
+
name: 'Checkbox'
|
|
93
|
+
});
|
|
94
|
+
const scaleAnim = (0, _react.useRef)(new _reactNative.Animated.Value(checked ? 1 : 0)).current;
|
|
95
|
+
(0, _react.useEffect)(() => {
|
|
96
|
+
_reactNative.Animated.spring(scaleAnim, {
|
|
97
|
+
toValue: checked || indeterminate ? 1 : 0,
|
|
98
|
+
useNativeDriver: true,
|
|
99
|
+
tension: 100,
|
|
100
|
+
friction: 7
|
|
101
|
+
}).start();
|
|
102
|
+
}, [checked, indeterminate, scaleAnim]);
|
|
103
|
+
const handlePress = () => {
|
|
104
|
+
if (!disabled) {
|
|
105
|
+
onChange?.(!checked);
|
|
106
|
+
}
|
|
107
|
+
};
|
|
108
|
+
const checkboxContent = /*#__PURE__*/(0, _jsxRuntime.jsx)(_index.BoxView, {
|
|
109
|
+
style: sx(styles.checkbox, (checked || indeterminate) && styles.checked, style),
|
|
110
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.Animated.View, {
|
|
111
|
+
style: {
|
|
112
|
+
transform: [{
|
|
113
|
+
scale: scaleAnim
|
|
114
|
+
}],
|
|
115
|
+
opacity: scaleAnim
|
|
116
|
+
},
|
|
117
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_index2.Text, {
|
|
118
|
+
style: styles.checkmark,
|
|
119
|
+
children: indeterminate ? '−' : '✓'
|
|
120
|
+
})
|
|
121
|
+
})
|
|
122
|
+
});
|
|
123
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.Pressable, {
|
|
124
|
+
ref: ref,
|
|
125
|
+
onPress: handlePress,
|
|
126
|
+
disabled: disabled,
|
|
127
|
+
style: sx(styles.root, wrapperStyle),
|
|
128
|
+
accessibilityRole: "checkbox",
|
|
129
|
+
accessibilityState: {
|
|
130
|
+
checked: checked || indeterminate
|
|
131
|
+
},
|
|
132
|
+
...otherProps,
|
|
133
|
+
children: [checkboxContent, label && /*#__PURE__*/(0, _jsxRuntime.jsx)(_index2.Text, {
|
|
134
|
+
style: styles.label,
|
|
135
|
+
children: label
|
|
136
|
+
})]
|
|
137
|
+
});
|
|
138
|
+
});
|
|
139
|
+
Checkbox.displayName = 'Checkbox';
|
|
140
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_index","_index2","_themeProvider","_index3","_rem","_jsxRuntime","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","sizes","xs","rem","sm","md","lg","xl","useStyles","createStyles","theme","size","color","disabled","colors","primaryColor","checkboxSize","root","flexDirection","alignItems","opacity","checkbox","width","height","borderRadius","radius","borderWidth","borderColor","colorScheme","dark","gray","backgroundColor","justifyContent","checked","primaryBgColor","checkmark","white","fontSize","fontWeight","label","fontSizes","black","marginLeft","spacing","flex","defaultProps","indeterminate","Checkbox","exports","forwardRef","props","ref","onChange","style","wrapperStyle","otherProps","useComponentDefaultProps","styles","sx","name","scaleAnim","useRef","Animated","Value","current","useEffect","spring","toValue","useNativeDriver","tension","friction","start","handlePress","checkboxContent","jsx","BoxView","children","View","transform","scale","Text","jsxs","Pressable","onPress","accessibilityRole","accessibilityState","displayName"],"sourceRoot":"../../../../src","sources":["components/Checkbox/index.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAF,OAAA;AACA,IAAAG,OAAA,GAAAH,OAAA;AAEA,IAAAI,cAAA,GAAAJ,OAAA;AACA,IAAAK,OAAA,GAAAL,OAAA;AACA,IAAAM,IAAA,GAAAN,OAAA;AAA4C,IAAAO,WAAA,GAAAP,OAAA;AAAA,SAAAQ,yBAAAC,CAAA,6BAAAC,OAAA,mBAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,CAAA,WAAAA,CAAA,GAAAG,CAAA,GAAAD,CAAA,KAAAF,CAAA;AAAA,SAAAV,wBAAAU,CAAA,EAAAE,CAAA,SAAAA,CAAA,IAAAF,CAAA,IAAAA,CAAA,CAAAI,UAAA,SAAAJ,CAAA,eAAAA,CAAA,uBAAAA,CAAA,yBAAAA,CAAA,WAAAK,OAAA,EAAAL,CAAA,QAAAG,CAAA,GAAAJ,wBAAA,CAAAG,CAAA,OAAAC,CAAA,IAAAA,CAAA,CAAAG,GAAA,CAAAN,CAAA,UAAAG,CAAA,CAAAI,GAAA,CAAAP,CAAA,OAAAQ,CAAA,KAAAC,SAAA,UAAAC,CAAA,GAAAC,MAAA,CAAAC,cAAA,IAAAD,MAAA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ty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.ChipGroup = exports.Chip = void 0;
|
|
7
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
var _index = require("../BoxView/index.js");
|
|
10
|
+
var _index2 = require("../Text/index.js");
|
|
11
|
+
var _themeProvider = require("../../theme/theme-provider.js");
|
|
12
|
+
var _index3 = require("../../theme/index.js");
|
|
13
|
+
var _rem = require("../../theme/utils/rem.js");
|
|
14
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
15
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
16
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
17
|
+
const sizes = {
|
|
18
|
+
xs: {
|
|
19
|
+
height: (0, _rem.rem)(24),
|
|
20
|
+
fontSize: (0, _rem.rem)(10),
|
|
21
|
+
paddingHorizontal: (0, _rem.rem)(8)
|
|
22
|
+
},
|
|
23
|
+
sm: {
|
|
24
|
+
height: (0, _rem.rem)(28),
|
|
25
|
+
fontSize: (0, _rem.rem)(12),
|
|
26
|
+
paddingHorizontal: (0, _rem.rem)(10)
|
|
27
|
+
},
|
|
28
|
+
md: {
|
|
29
|
+
height: (0, _rem.rem)(32),
|
|
30
|
+
fontSize: (0, _rem.rem)(14),
|
|
31
|
+
paddingHorizontal: (0, _rem.rem)(12)
|
|
32
|
+
},
|
|
33
|
+
lg: {
|
|
34
|
+
height: (0, _rem.rem)(36),
|
|
35
|
+
fontSize: (0, _rem.rem)(16),
|
|
36
|
+
paddingHorizontal: (0, _rem.rem)(14)
|
|
37
|
+
},
|
|
38
|
+
xl: {
|
|
39
|
+
height: (0, _rem.rem)(42),
|
|
40
|
+
fontSize: (0, _rem.rem)(18),
|
|
41
|
+
paddingHorizontal: (0, _rem.rem)(16)
|
|
42
|
+
}
|
|
43
|
+
};
|
|
44
|
+
const useStyles = (0, _index3.createStyles)((theme, {
|
|
45
|
+
size,
|
|
46
|
+
color,
|
|
47
|
+
radius,
|
|
48
|
+
variant,
|
|
49
|
+
checked,
|
|
50
|
+
disabled
|
|
51
|
+
}) => {
|
|
52
|
+
const colors = theme.colors[color] || theme.colors[theme.primaryColor];
|
|
53
|
+
const sizeStyles = sizes[size] || sizes.md;
|
|
54
|
+
const getVariantStyles = () => {
|
|
55
|
+
if (!checked) {
|
|
56
|
+
return {
|
|
57
|
+
backgroundColor: theme.colorScheme === 'dark' ? theme.colors.dark?.[6] : theme.colors.gray?.[1],
|
|
58
|
+
borderWidth: 1,
|
|
59
|
+
borderColor: theme.colorScheme === 'dark' ? theme.colors.dark?.[4] : theme.colors.gray?.[4]
|
|
60
|
+
};
|
|
61
|
+
}
|
|
62
|
+
switch (variant) {
|
|
63
|
+
case 'filled':
|
|
64
|
+
return {
|
|
65
|
+
backgroundColor: colors?.[6] || colors?.[5] || theme.primaryBgColor,
|
|
66
|
+
borderWidth: 0
|
|
67
|
+
};
|
|
68
|
+
case 'outline':
|
|
69
|
+
return {
|
|
70
|
+
backgroundColor: 'transparent',
|
|
71
|
+
borderWidth: 1,
|
|
72
|
+
borderColor: colors?.[6] || colors?.[5] || theme.primaryBgColor
|
|
73
|
+
};
|
|
74
|
+
case 'light':
|
|
75
|
+
return {
|
|
76
|
+
backgroundColor: theme.colorScheme === 'dark' ? theme.fn.rgba(colors?.[9] || theme.primaryBgColor, 0.25) : colors?.[0] || (theme.colors.gray || [])[1],
|
|
77
|
+
borderWidth: 0
|
|
78
|
+
};
|
|
79
|
+
default:
|
|
80
|
+
return {
|
|
81
|
+
backgroundColor: colors?.[6] || colors?.[5] || theme.primaryBgColor,
|
|
82
|
+
borderWidth: 0
|
|
83
|
+
};
|
|
84
|
+
}
|
|
85
|
+
};
|
|
86
|
+
const getTextColor = () => {
|
|
87
|
+
if (!checked) {
|
|
88
|
+
return theme.colorScheme === 'dark' ? theme.white : theme.black;
|
|
89
|
+
}
|
|
90
|
+
switch (variant) {
|
|
91
|
+
case 'filled':
|
|
92
|
+
return theme.white;
|
|
93
|
+
case 'outline':
|
|
94
|
+
case 'light':
|
|
95
|
+
return colors?.[6] || colors?.[5] || theme.primaryBgColor;
|
|
96
|
+
default:
|
|
97
|
+
return theme.white;
|
|
98
|
+
}
|
|
99
|
+
};
|
|
100
|
+
return {
|
|
101
|
+
root: {
|
|
102
|
+
flexDirection: 'row',
|
|
103
|
+
alignItems: 'center',
|
|
104
|
+
justifyContent: 'center',
|
|
105
|
+
height: sizeStyles.height,
|
|
106
|
+
paddingHorizontal: sizeStyles.paddingHorizontal,
|
|
107
|
+
borderRadius: theme.fn.radius(radius),
|
|
108
|
+
...getVariantStyles(),
|
|
109
|
+
...(disabled && {
|
|
110
|
+
opacity: 0.6
|
|
111
|
+
})
|
|
112
|
+
},
|
|
113
|
+
icon: {
|
|
114
|
+
marginRight: (0, _rem.rem)(6)
|
|
115
|
+
},
|
|
116
|
+
text: {
|
|
117
|
+
fontSize: sizeStyles.fontSize,
|
|
118
|
+
fontWeight: checked ? '600' : '500',
|
|
119
|
+
color: getTextColor()
|
|
120
|
+
}
|
|
121
|
+
};
|
|
122
|
+
});
|
|
123
|
+
const defaultProps = {
|
|
124
|
+
size: 'sm',
|
|
125
|
+
color: 'blue',
|
|
126
|
+
radius: 'xl',
|
|
127
|
+
variant: 'filled',
|
|
128
|
+
disabled: false,
|
|
129
|
+
type: 'checkbox'
|
|
130
|
+
};
|
|
131
|
+
const Chip = exports.Chip = /*#__PURE__*/(0, _react.forwardRef)((props, ref) => {
|
|
132
|
+
const {
|
|
133
|
+
children,
|
|
134
|
+
size,
|
|
135
|
+
color,
|
|
136
|
+
radius,
|
|
137
|
+
variant,
|
|
138
|
+
checked: controlledChecked,
|
|
139
|
+
defaultChecked,
|
|
140
|
+
onChange,
|
|
141
|
+
disabled,
|
|
142
|
+
icon,
|
|
143
|
+
style,
|
|
144
|
+
textStyle,
|
|
145
|
+
value,
|
|
146
|
+
type,
|
|
147
|
+
...others
|
|
148
|
+
} = (0, _themeProvider.useComponentDefaultProps)('Chip', defaultProps, props);
|
|
149
|
+
const [uncontrolledChecked, setUncontrolledChecked] = _react.default.useState(defaultChecked || false);
|
|
150
|
+
const checked = controlledChecked !== undefined ? controlledChecked : uncontrolledChecked;
|
|
151
|
+
const {
|
|
152
|
+
styles,
|
|
153
|
+
sx
|
|
154
|
+
} = useStyles({
|
|
155
|
+
size,
|
|
156
|
+
color,
|
|
157
|
+
radius,
|
|
158
|
+
variant,
|
|
159
|
+
checked,
|
|
160
|
+
disabled
|
|
161
|
+
}, {
|
|
162
|
+
name: 'Chip'
|
|
163
|
+
});
|
|
164
|
+
const handlePress = () => {
|
|
165
|
+
if (disabled) return;
|
|
166
|
+
const newChecked = !checked;
|
|
167
|
+
if (controlledChecked === undefined) {
|
|
168
|
+
setUncontrolledChecked(newChecked);
|
|
169
|
+
}
|
|
170
|
+
onChange?.(newChecked);
|
|
171
|
+
};
|
|
172
|
+
const showIcon = checked && icon;
|
|
173
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsxs)(_reactNative.TouchableOpacity, {
|
|
174
|
+
ref: ref,
|
|
175
|
+
style: sx(styles.root, style),
|
|
176
|
+
onPress: handlePress,
|
|
177
|
+
disabled: disabled,
|
|
178
|
+
activeOpacity: 0.7,
|
|
179
|
+
...others,
|
|
180
|
+
children: [showIcon && /*#__PURE__*/(0, _jsxRuntime.jsx)(_index.BoxView, {
|
|
181
|
+
style: styles.icon,
|
|
182
|
+
children: icon
|
|
183
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_index2.Text, {
|
|
184
|
+
style: sx(styles.text, textStyle),
|
|
185
|
+
children: children
|
|
186
|
+
})]
|
|
187
|
+
});
|
|
188
|
+
});
|
|
189
|
+
Chip.displayName = 'Chip';
|
|
190
|
+
|
|
191
|
+
// Chip.Group component for managing multiple chips
|
|
192
|
+
|
|
193
|
+
const useGroupStyles = (0, _index3.createStyles)((_theme, {
|
|
194
|
+
spacing: _spacing
|
|
195
|
+
}) => ({
|
|
196
|
+
root: {
|
|
197
|
+
flexDirection: 'row',
|
|
198
|
+
flexWrap: 'wrap',
|
|
199
|
+
gap: 8
|
|
200
|
+
}
|
|
201
|
+
}));
|
|
202
|
+
const defaultGroupProps = {
|
|
203
|
+
multiple: false,
|
|
204
|
+
spacing: 'sm'
|
|
205
|
+
};
|
|
206
|
+
const ChipGroup = exports.ChipGroup = /*#__PURE__*/(0, _react.forwardRef)((props, ref) => {
|
|
207
|
+
const {
|
|
208
|
+
children,
|
|
209
|
+
value: controlledValue,
|
|
210
|
+
defaultValue,
|
|
211
|
+
onChange,
|
|
212
|
+
multiple,
|
|
213
|
+
style,
|
|
214
|
+
spacing,
|
|
215
|
+
...otherProps
|
|
216
|
+
} = (0, _themeProvider.useComponentDefaultProps)('ChipGroup', defaultGroupProps, props);
|
|
217
|
+
const [uncontrolledValue, setUncontrolledValue] = _react.default.useState(defaultValue || (multiple ? [] : ''));
|
|
218
|
+
const value = controlledValue !== undefined ? controlledValue : uncontrolledValue;
|
|
219
|
+
const {
|
|
220
|
+
styles,
|
|
221
|
+
sx
|
|
222
|
+
} = useGroupStyles({
|
|
223
|
+
spacing
|
|
224
|
+
}, {
|
|
225
|
+
name: 'ChipGroup'
|
|
226
|
+
});
|
|
227
|
+
const handleChipChange = (chipValue, checked) => {
|
|
228
|
+
let newValue;
|
|
229
|
+
if (multiple) {
|
|
230
|
+
const currentArray = Array.isArray(value) ? value : [];
|
|
231
|
+
newValue = checked ? [...currentArray, chipValue] : currentArray.filter(v => v !== chipValue);
|
|
232
|
+
} else {
|
|
233
|
+
newValue = checked ? chipValue : '';
|
|
234
|
+
}
|
|
235
|
+
if (controlledValue === undefined) {
|
|
236
|
+
setUncontrolledValue(newValue);
|
|
237
|
+
}
|
|
238
|
+
onChange?.(newValue);
|
|
239
|
+
};
|
|
240
|
+
const isChecked = chipValue => {
|
|
241
|
+
if (multiple && Array.isArray(value)) {
|
|
242
|
+
return value.includes(chipValue);
|
|
243
|
+
}
|
|
244
|
+
return value === chipValue;
|
|
245
|
+
};
|
|
246
|
+
const enhancedChildren = _react.default.Children.map(children, child => {
|
|
247
|
+
if (/*#__PURE__*/_react.default.isValidElement(child) && child.type === Chip) {
|
|
248
|
+
const chipValue = child.props.value;
|
|
249
|
+
if (chipValue !== undefined) {
|
|
250
|
+
return /*#__PURE__*/_react.default.cloneElement(child, {
|
|
251
|
+
checked: isChecked(chipValue),
|
|
252
|
+
onChange: checked => handleChipChange(chipValue, checked)
|
|
253
|
+
});
|
|
254
|
+
}
|
|
255
|
+
}
|
|
256
|
+
return child;
|
|
257
|
+
});
|
|
258
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_index.BoxView, {
|
|
259
|
+
ref: ref,
|
|
260
|
+
style: sx(styles.root, style),
|
|
261
|
+
...otherProps,
|
|
262
|
+
children: enhancedChildren
|
|
263
|
+
});
|
|
264
|
+
});
|
|
265
|
+
ChipGroup.displayName = 'Chip.Group';
|
|
266
|
+
|
|
267
|
+
// Attach Group to Chip
|
|
268
|
+
Chip.Group = ChipGroup;
|
|
269
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_index","_index2","_themeProvider","_index3","_rem","_jsxRuntime","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","sizes","xs","height","rem","fontSize","paddingHorizontal","sm","md","lg","xl","useStyles","createStyles","theme","size","color","radius","variant","checked","disabled","colors","primaryColor","sizeStyles","getVariantStyles","backgroundColor","colorScheme","dark","gray","borderWidth","borderColor","primaryBgColor","fn","rgba","getTextColor","white","black","root","flexDirection","alignItems","justifyContent","borderRadius","opacity","icon","marginRight","text","fontWeight","defaultProps","type","Chip","exports","forwardRef","props","ref","children","controlledChecked","defaultChecked","onChange","style","textStyle","value","others","useComponentDefaultProps","uncontrolledChecked","setUncontrolledChecked","React","useState","undefined","styles","sx","name","handlePress","newChecked","showIcon","jsxs","TouchableOpacity","onPress","activeOpacity","jsx","BoxView","Text","displayName","useGroupStyles","_theme","spacing","_spacing","flexWrap","gap","defaultGroupProps","multiple","ChipGroup","controlledValue","defaultValue","otherProps","uncontrolledValue","setUncontrolledValue","handleChipChange","chipValue","newValue","currentArray","Array","isArray","filter","v","isChecked","includes","enhancedChildren","Children","map","child","isValidElement","cloneElement","Group"],"sourceRoot":"../../../../src","sources":["components/Chip/index.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAF,OAAA;AACA,IAAAG,OAAA,GAAAH,OAAA;AAQA,IAAAI,cAAA,GAAAJ,OAAA;AACA,IAAAK,OAAA,GAAAL,OAAA;AACA,IAAAM,IAAA,GAAAN,OAAA;AAA4C,IAAAO,WAAA,GAAAP,OAAA;AAAA,SAAAQ,yBAAAC,CAAA,6BAAAC,OAAA,mBAAAC,CAAA,OAAAD,OAAA,IAAAE,CAAA,OAAAF,OAAA,YAAAF,wBAAA,YAAAA,CAAAC,CAAA,WAAAA,CAAA,GAAAG,CAAA,GAAAD,CAAA,KAAAF,CAAA;AAAA,SAAAV,wBAAAU,CAAA,EAAAE,CAAA,SAAAA,CAAA,IAAAF,CAAA,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B,CAACC,SAAS,EAAE9E,OAAO;QACrE,CAAC,CAAC;MACJ;IACF;IACA,OAAO0F,KAAK;EACd,CAAC,CAAC;EAEF,oBACE,IAAAhI,WAAA,CAAAiG,GAAA,EAACtG,MAAA,CAAAuG,OAAO;IAAC1B,GAAG,EAAEA,GAAI;IAACK,KAAK,EAAEW,EAAE,CAACD,MAAM,CAAC/B,IAAI,EAAEqB,KAAK,CAAE;IAAA,GAAKmC,UAAU;IAAAvC,QAAA,EAC7DoD;EAAgB,CACV,CAAC;AAEd,CAAC,CAAC;AAEFhB,SAAS,CAACT,WAAW,GAAG,YAAY;;AAEpC;AACChC,IAAI,CAAS+D,KAAK,GAAGtB,SAAS","ignoreList":[]}
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
Object.defineProperty(exports, "__esModule", {
|
|
4
|
+
value: true
|
|
5
|
+
});
|
|
6
|
+
exports.CloseButton = void 0;
|
|
7
|
+
var _react = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _reactNative = require("react-native");
|
|
9
|
+
var _index = require("../BoxView/index.js");
|
|
10
|
+
var _themeProvider = require("../../theme/theme-provider.js");
|
|
11
|
+
var _index2 = require("../../theme/index.js");
|
|
12
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
13
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
14
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
15
|
+
const sizes = {
|
|
16
|
+
xs: 16,
|
|
17
|
+
sm: 22,
|
|
18
|
+
md: 28,
|
|
19
|
+
lg: 34,
|
|
20
|
+
xl: 44
|
|
21
|
+
};
|
|
22
|
+
const iconSizes = {
|
|
23
|
+
xs: 12,
|
|
24
|
+
sm: 16,
|
|
25
|
+
md: 20,
|
|
26
|
+
lg: 24,
|
|
27
|
+
xl: 28
|
|
28
|
+
};
|
|
29
|
+
const useStyles = (0, _index2.createStyles)((theme, {
|
|
30
|
+
size,
|
|
31
|
+
radius,
|
|
32
|
+
disabled
|
|
33
|
+
}) => {
|
|
34
|
+
const buttonSize = typeof size === 'number' ? size : (0, _index2.getSize)({
|
|
35
|
+
size,
|
|
36
|
+
sizes
|
|
37
|
+
});
|
|
38
|
+
return {
|
|
39
|
+
root: {
|
|
40
|
+
width: buttonSize,
|
|
41
|
+
height: buttonSize,
|
|
42
|
+
borderRadius: theme.fn.radius(radius),
|
|
43
|
+
justifyContent: 'center',
|
|
44
|
+
alignItems: 'center',
|
|
45
|
+
backgroundColor: 'transparent',
|
|
46
|
+
opacity: disabled ? 0.4 : 1
|
|
47
|
+
},
|
|
48
|
+
rootHover: {
|
|
49
|
+
backgroundColor: theme.colorScheme === 'dark' ? theme.colors.dark?.[5] : theme.colors.gray?.[0]
|
|
50
|
+
}
|
|
51
|
+
};
|
|
52
|
+
});
|
|
53
|
+
const CloseIcon = ({
|
|
54
|
+
size,
|
|
55
|
+
color
|
|
56
|
+
}) => /*#__PURE__*/(0, _jsxRuntime.jsxs)(_index.BoxView, {
|
|
57
|
+
style: {
|
|
58
|
+
width: size,
|
|
59
|
+
height: size,
|
|
60
|
+
position: 'relative'
|
|
61
|
+
},
|
|
62
|
+
children: [/*#__PURE__*/(0, _jsxRuntime.jsx)(_index.BoxView, {
|
|
63
|
+
style: {
|
|
64
|
+
position: 'absolute',
|
|
65
|
+
width: size,
|
|
66
|
+
height: 2,
|
|
67
|
+
backgroundColor: color,
|
|
68
|
+
top: (size - 2) / 2,
|
|
69
|
+
transform: [{
|
|
70
|
+
rotate: '45deg'
|
|
71
|
+
}]
|
|
72
|
+
}
|
|
73
|
+
}), /*#__PURE__*/(0, _jsxRuntime.jsx)(_index.BoxView, {
|
|
74
|
+
style: {
|
|
75
|
+
position: 'absolute',
|
|
76
|
+
width: size,
|
|
77
|
+
height: 2,
|
|
78
|
+
backgroundColor: color,
|
|
79
|
+
top: (size - 2) / 2,
|
|
80
|
+
transform: [{
|
|
81
|
+
rotate: '-45deg'
|
|
82
|
+
}]
|
|
83
|
+
}
|
|
84
|
+
})]
|
|
85
|
+
});
|
|
86
|
+
const defaultProps = {
|
|
87
|
+
size: 'md',
|
|
88
|
+
radius: 'sm',
|
|
89
|
+
accessibilityLabel: 'Close',
|
|
90
|
+
disabled: false
|
|
91
|
+
};
|
|
92
|
+
const CloseButton = exports.CloseButton = /*#__PURE__*/(0, _react.forwardRef)((props, ref) => {
|
|
93
|
+
const {
|
|
94
|
+
onPress,
|
|
95
|
+
size = 'md',
|
|
96
|
+
radius = 'sm',
|
|
97
|
+
iconColor,
|
|
98
|
+
icon,
|
|
99
|
+
accessibilityLabel,
|
|
100
|
+
style,
|
|
101
|
+
disabled,
|
|
102
|
+
...others
|
|
103
|
+
} = (0, _themeProvider.useComponentDefaultProps)('CloseButton', defaultProps, props);
|
|
104
|
+
const {
|
|
105
|
+
styles,
|
|
106
|
+
sx,
|
|
107
|
+
theme
|
|
108
|
+
} = useStyles({
|
|
109
|
+
size,
|
|
110
|
+
radius,
|
|
111
|
+
disabled
|
|
112
|
+
}, {
|
|
113
|
+
name: 'CloseButton'
|
|
114
|
+
});
|
|
115
|
+
const iconSize = typeof size === 'number' ? Math.round(size * 0.7) : (0, _index2.getSize)({
|
|
116
|
+
size,
|
|
117
|
+
sizes: iconSizes
|
|
118
|
+
});
|
|
119
|
+
const defaultIconColor = iconColor || (theme.colorScheme === 'dark' ? theme.colors.dark?.[0] : theme.colors.gray?.[7]) || '#000';
|
|
120
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_reactNative.TouchableOpacity, {
|
|
121
|
+
ref: ref,
|
|
122
|
+
onPress: onPress,
|
|
123
|
+
disabled: disabled,
|
|
124
|
+
activeOpacity: 0.6,
|
|
125
|
+
accessible: true,
|
|
126
|
+
accessibilityLabel: accessibilityLabel,
|
|
127
|
+
accessibilityRole: "button",
|
|
128
|
+
style: sx(styles.root, style),
|
|
129
|
+
...others,
|
|
130
|
+
children: icon || /*#__PURE__*/(0, _jsxRuntime.jsx)(CloseIcon, {
|
|
131
|
+
size: iconSize,
|
|
132
|
+
color: defaultIconColor
|
|
133
|
+
})
|
|
134
|
+
});
|
|
135
|
+
});
|
|
136
|
+
CloseButton.displayName = 'CloseButton';
|
|
137
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_reactNative","_index","_themeProvider","_index2","_jsxRuntime","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","sizes","xs","sm","md","lg","xl","iconSizes","useStyles","createStyles","theme","size","radius","disabled","buttonSize","getSize","root","width","height","borderRadius","fn","justifyContent","alignItems","backgroundColor","opacity","rootHover","colorScheme","colors","dark","gray","CloseIcon","color","jsxs","BoxView","style","position","children","jsx","top","transform","rotate","defaultProps","accessibilityLabel","CloseButton","exports","forwardRef","props","ref","onPress","iconColor","icon","others","useComponentDefaultProps","styles","sx","name","iconSize","Math","round","defaultIconColor","TouchableOpacity","activeOpacity","accessible","accessibilityRole","displayName"],"sourceRoot":"../../../../src","sources":["components/CloseButton/index.tsx"],"mappings":";;;;;;AAAA,IAAAA,MAAA,GAAAC,uBAAA,CAAAC,OAAA;AACA,IAAAC,YAAA,GAAAD,OAAA;AACA,IAAAE,MAAA,GAAAF,OAAA;AAEA,IAAA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var _react = _interopRequireWildcard(require("react"));
|
|
8
|
+
var _index = require("../Text/index.js");
|
|
9
|
+
var _themeProvider = require("../../theme/theme-provider.js");
|
|
10
|
+
var _index2 = require("../BoxView/index.js");
|
|
11
|
+
var _jsxRuntime = require("react/jsx-runtime");
|
|
12
|
+
function _getRequireWildcardCache(e) { if ("function" != typeof WeakMap) return null; var r = new WeakMap(), t = new WeakMap(); return (_getRequireWildcardCache = function (e) { return e ? t : r; })(e); }
|
|
13
|
+
function _interopRequireWildcard(e, r) { if (!r && e && e.__esModule) return e; if (null === e || "object" != typeof e && "function" != typeof e) return { default: e }; var t = _getRequireWildcardCache(r); if (t && t.has(e)) return t.get(e); var n = { __proto__: null }, a = Object.defineProperty && Object.getOwnPropertyDescriptor; for (var u in e) if ("default" !== u && {}.hasOwnProperty.call(e, u)) { var i = a ? Object.getOwnPropertyDescriptor(e, u) : null; i && (i.get || i.set) ? Object.defineProperty(n, u, i) : n[u] = e[u]; } return n.default = e, t && t.set(e, n), n; }
|
|
14
|
+
/**
|
|
15
|
+
* Code component renders inline code or code blocks with monospace font
|
|
16
|
+
*/
|
|
17
|
+
const Code = exports.Code = /*#__PURE__*/(0, _react.forwardRef)((props, ref) => {
|
|
18
|
+
const {
|
|
19
|
+
children,
|
|
20
|
+
color,
|
|
21
|
+
block = false,
|
|
22
|
+
style,
|
|
23
|
+
...others
|
|
24
|
+
} = props;
|
|
25
|
+
const theme = (0, _themeProvider.useTheme)();
|
|
26
|
+
|
|
27
|
+
// Get background and text colors
|
|
28
|
+
const backgroundColor = theme.colors.gray?.[0] || '#F6F6F6';
|
|
29
|
+
const textColor = color ? theme.colors[color]?.[theme.primaryShade] || color : theme.light.text;
|
|
30
|
+
|
|
31
|
+
// Monospace font - in React Native, we can use 'Courier' or 'Courier New'
|
|
32
|
+
const codeStyles = {
|
|
33
|
+
fontFamily: 'Courier',
|
|
34
|
+
fontSize: theme.fontSizes.sm || 14,
|
|
35
|
+
backgroundColor: backgroundColor,
|
|
36
|
+
color: textColor,
|
|
37
|
+
paddingHorizontal: block ? 16 : 4,
|
|
38
|
+
paddingVertical: block ? 12 : 2,
|
|
39
|
+
borderRadius: theme.radius.sm || 4
|
|
40
|
+
};
|
|
41
|
+
if (block) {
|
|
42
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_index2.BoxView, {
|
|
43
|
+
ref: ref,
|
|
44
|
+
style: [{
|
|
45
|
+
backgroundColor: backgroundColor,
|
|
46
|
+
borderRadius: theme.radius.sm || 4,
|
|
47
|
+
padding: 16
|
|
48
|
+
}, style],
|
|
49
|
+
children: /*#__PURE__*/(0, _jsxRuntime.jsx)(_index.Text, {
|
|
50
|
+
style: [{
|
|
51
|
+
fontFamily: 'Courier',
|
|
52
|
+
fontSize: theme.fontSizes.sm || 14,
|
|
53
|
+
color: textColor
|
|
54
|
+
}],
|
|
55
|
+
...others,
|
|
56
|
+
children: children
|
|
57
|
+
})
|
|
58
|
+
});
|
|
59
|
+
}
|
|
60
|
+
return /*#__PURE__*/(0, _jsxRuntime.jsx)(_index.Text, {
|
|
61
|
+
ref: ref,
|
|
62
|
+
style: [codeStyles, style],
|
|
63
|
+
...others,
|
|
64
|
+
children: children
|
|
65
|
+
});
|
|
66
|
+
});
|
|
67
|
+
Code.displayName = 'Code';
|
|
68
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["_react","_interopRequireWildcard","require","_index","_themeProvider","_index2","_jsxRuntime","_getRequireWildcardCache","e","WeakMap","r","t","__esModule","default","has","get","n","__proto__","a","Object","defineProperty","getOwnPropertyDescriptor","u","hasOwnProperty","call","i","set","Code","exports","forwardRef","props","ref","children","color","block","style","others","theme","useTheme","backgroundColor","colors","gray","textColor","primaryShade","light","text","codeStyles","fontFamily","fontSize","fontSizes","sm","paddingHorizontal","paddingVertical","borderRadius","radius","jsx","BoxView","padding","Text","displayName"],"sourceRoot":"../../../../src","sources":["components/Code/index.tsx"],"mappings":";;;;;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