@cdx-ui/components 0.0.1-alpha.3 → 0.0.1-alpha.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +20 -2
- package/lib/commonjs/components/AlertDialog/index.js +117 -0
- package/lib/commonjs/components/AlertDialog/index.js.map +1 -0
- package/lib/commonjs/components/Avatar/index.js +156 -0
- package/lib/commonjs/components/Avatar/index.js.map +1 -0
- package/lib/commonjs/components/Avatar/styles.js +80 -0
- package/lib/commonjs/components/Avatar/styles.js.map +1 -0
- package/lib/commonjs/components/BottomSheet/index.js +248 -0
- package/lib/commonjs/components/BottomSheet/index.js.map +1 -0
- package/lib/commonjs/components/BottomSheet/styles.js +61 -0
- package/lib/commonjs/components/BottomSheet/styles.js.map +1 -0
- package/lib/commonjs/components/Box/Box.js +1 -0
- package/lib/commonjs/components/Box/Box.js.map +1 -1
- package/lib/commonjs/components/Button/buttonSharedVariants.js +200 -0
- package/lib/commonjs/components/Button/buttonSharedVariants.js.map +1 -0
- package/lib/commonjs/components/Button/index.js +31 -13
- package/lib/commonjs/components/Button/index.js.map +1 -1
- package/lib/commonjs/components/Button/styles.js +170 -187
- package/lib/commonjs/components/Button/styles.js.map +1 -1
- package/lib/commonjs/components/Card/index.js +104 -0
- package/lib/commonjs/components/Card/index.js.map +1 -0
- package/lib/commonjs/components/Card/styles.js +28 -0
- package/lib/commonjs/components/Card/styles.js.map +1 -0
- package/lib/commonjs/components/Checkbox/index.js +180 -0
- package/lib/commonjs/components/Checkbox/index.js.map +1 -0
- package/lib/commonjs/components/Checkbox/styles.js +68 -0
- package/lib/commonjs/components/Checkbox/styles.js.map +1 -0
- package/lib/commonjs/components/Chip/index.js +103 -0
- package/lib/commonjs/components/Chip/index.js.map +1 -0
- package/lib/commonjs/components/Chip/styles.js +50 -0
- package/lib/commonjs/components/Chip/styles.js.map +1 -0
- package/lib/commonjs/components/Dialog/index.js +275 -0
- package/lib/commonjs/components/Dialog/index.js.map +1 -0
- package/lib/commonjs/components/Dialog/styles.js +63 -0
- package/lib/commonjs/components/Dialog/styles.js.map +1 -0
- package/lib/commonjs/components/Form/FormLabelRoot.js +33 -0
- package/lib/commonjs/components/Form/FormLabelRoot.js.map +1 -0
- package/lib/commonjs/components/Form/FormLabelRoot.web.js +18 -0
- package/lib/commonjs/components/Form/FormLabelRoot.web.js.map +1 -0
- package/lib/commonjs/components/Form/FormRoot.js +25 -0
- package/lib/commonjs/components/Form/FormRoot.js.map +1 -0
- package/lib/commonjs/components/Form/FormRoot.web.js +17 -0
- package/lib/commonjs/components/Form/FormRoot.web.js.map +1 -0
- package/lib/commonjs/components/Form/index.js +255 -0
- package/lib/commonjs/components/Form/index.js.map +1 -0
- package/lib/commonjs/components/Form/styles.js +57 -0
- package/lib/commonjs/components/Form/styles.js.map +1 -0
- package/lib/commonjs/components/Heading/index.js +35 -0
- package/lib/commonjs/components/Heading/index.js.map +1 -0
- package/lib/commonjs/components/Heading/styles.js +24 -0
- package/lib/commonjs/components/Heading/styles.js.map +1 -0
- package/lib/commonjs/components/Icon/index.js +61 -0
- package/lib/commonjs/components/Icon/index.js.map +1 -0
- package/lib/commonjs/components/IconButton/index.js +80 -0
- package/lib/commonjs/components/IconButton/index.js.map +1 -0
- package/lib/commonjs/components/IconButton/styles.js +91 -0
- package/lib/commonjs/components/IconButton/styles.js.map +1 -0
- package/lib/commonjs/components/Image/Image.js +69 -0
- package/lib/commonjs/components/Image/Image.js.map +1 -0
- package/lib/commonjs/components/Image/index.js +13 -0
- package/lib/commonjs/components/Image/index.js.map +1 -0
- package/lib/commonjs/components/Input/BaseInput.android.js +20 -0
- package/lib/commonjs/components/Input/BaseInput.android.js.map +1 -0
- package/lib/commonjs/components/Input/index.js +10 -16
- package/lib/commonjs/components/Input/index.js.map +1 -1
- package/lib/commonjs/components/Input/styles.js +16 -30
- package/lib/commonjs/components/Input/styles.js.map +1 -1
- package/lib/commonjs/components/Link/index.js +94 -0
- package/lib/commonjs/components/Link/index.js.map +1 -0
- package/lib/commonjs/components/Link/styles.js +16 -0
- package/lib/commonjs/components/Link/styles.js.map +1 -0
- package/lib/commonjs/components/ProgressSegmented/index.js +62 -0
- package/lib/commonjs/components/ProgressSegmented/index.js.map +1 -0
- package/lib/commonjs/components/ProgressSegmented/styles.js +21 -0
- package/lib/commonjs/components/ProgressSegmented/styles.js.map +1 -0
- package/lib/commonjs/components/Select/SelectTriggerHost.js +10 -0
- package/lib/commonjs/components/Select/SelectTriggerHost.js.map +1 -0
- package/lib/commonjs/components/Select/SelectTriggerHost.web.js +98 -0
- package/lib/commonjs/components/Select/SelectTriggerHost.web.js.map +1 -0
- package/lib/commonjs/components/Select/index.js +13 -13
- package/lib/commonjs/components/Select/index.js.map +1 -1
- package/lib/commonjs/components/Select/styles.js +29 -53
- package/lib/commonjs/components/Select/styles.js.map +1 -1
- package/lib/commonjs/components/Stack/HStack.js +8 -21
- package/lib/commonjs/components/Stack/HStack.js.map +1 -1
- package/lib/commonjs/components/Stack/VStack.js +8 -21
- package/lib/commonjs/components/Stack/VStack.js.map +1 -1
- package/lib/commonjs/components/Stack/styles.js +39 -0
- package/lib/commonjs/components/Stack/styles.js.map +1 -0
- package/lib/commonjs/components/Switch/BaseSwitch.js +46 -0
- package/lib/commonjs/components/Switch/BaseSwitch.js.map +1 -0
- package/lib/commonjs/components/Switch/BaseSwitch.web.js +56 -0
- package/lib/commonjs/components/Switch/BaseSwitch.web.js.map +1 -0
- package/lib/commonjs/components/Switch/index.js +13 -0
- package/lib/commonjs/components/Switch/index.js.map +1 -0
- package/lib/commonjs/components/Switch/styles.js +128 -0
- package/lib/commonjs/components/Switch/styles.js.map +1 -0
- package/lib/commonjs/components/Text/index.js +18 -9
- package/lib/commonjs/components/Text/index.js.map +1 -1
- package/lib/commonjs/components/Text/styles.js +24 -0
- package/lib/commonjs/components/Text/styles.js.map +1 -0
- package/lib/commonjs/components/VirtualizedList/index.js +19 -0
- package/lib/commonjs/components/VirtualizedList/index.js.map +1 -0
- package/lib/commonjs/components/index.js +192 -0
- package/lib/commonjs/components/index.js.map +1 -1
- package/lib/commonjs/index.js +40 -0
- package/lib/commonjs/index.js.map +1 -1
- package/lib/commonjs/metro/withCdxMetroConfig.js +24 -0
- package/lib/commonjs/metro/withCdxMetroConfig.js.map +1 -0
- package/lib/commonjs/styles/index.js +17 -0
- package/lib/commonjs/styles/index.js.map +1 -0
- package/lib/commonjs/styles/primitives.js +123 -0
- package/lib/commonjs/styles/primitives.js.map +1 -0
- package/lib/module/components/AlertDialog/index.js +112 -0
- package/lib/module/components/AlertDialog/index.js.map +1 -0
- package/lib/module/components/Avatar/index.js +152 -0
- package/lib/module/components/Avatar/index.js.map +1 -0
- package/lib/module/components/Avatar/styles.js +77 -0
- package/lib/module/components/Avatar/styles.js.map +1 -0
- package/lib/module/components/BottomSheet/index.js +242 -0
- package/lib/module/components/BottomSheet/index.js.map +1 -0
- package/lib/module/components/BottomSheet/styles.js +58 -0
- package/lib/module/components/BottomSheet/styles.js.map +1 -0
- package/lib/module/components/Box/Box.js +1 -0
- package/lib/module/components/Box/Box.js.map +1 -1
- package/lib/module/components/Button/buttonSharedVariants.js +195 -0
- package/lib/module/components/Button/buttonSharedVariants.js.map +1 -0
- package/lib/module/components/Button/index.js +32 -14
- package/lib/module/components/Button/index.js.map +1 -1
- package/lib/module/components/Button/styles.js +168 -186
- package/lib/module/components/Button/styles.js.map +1 -1
- package/lib/module/components/Card/index.js +100 -0
- package/lib/module/components/Card/index.js.map +1 -0
- package/lib/module/components/Card/styles.js +25 -0
- package/lib/module/components/Card/styles.js.map +1 -0
- package/lib/module/components/Checkbox/index.js +176 -0
- package/lib/module/components/Checkbox/index.js.map +1 -0
- package/lib/module/components/Checkbox/styles.js +64 -0
- package/lib/module/components/Checkbox/styles.js.map +1 -0
- package/lib/module/components/Chip/index.js +99 -0
- package/lib/module/components/Chip/index.js.map +1 -0
- package/lib/module/components/Chip/styles.js +46 -0
- package/lib/module/components/Chip/styles.js.map +1 -0
- package/lib/module/components/Dialog/index.js +267 -0
- package/lib/module/components/Dialog/index.js.map +1 -0
- package/lib/module/components/Dialog/styles.js +60 -0
- package/lib/module/components/Dialog/styles.js.map +1 -0
- package/lib/module/components/Form/FormLabelRoot.js +29 -0
- package/lib/module/components/Form/FormLabelRoot.js.map +1 -0
- package/lib/module/components/Form/FormLabelRoot.web.js +13 -0
- package/lib/module/components/Form/FormLabelRoot.web.js.map +1 -0
- package/lib/module/components/Form/FormRoot.js +21 -0
- package/lib/module/components/Form/FormRoot.js.map +1 -0
- package/lib/module/components/Form/FormRoot.web.js +12 -0
- package/lib/module/components/Form/FormRoot.web.js.map +1 -0
- package/lib/module/components/Form/index.js +252 -0
- package/lib/module/components/Form/index.js.map +1 -0
- package/lib/module/components/Form/styles.js +53 -0
- package/lib/module/components/Form/styles.js.map +1 -0
- package/lib/module/components/Heading/index.js +31 -0
- package/lib/module/components/Heading/index.js.map +1 -0
- package/lib/module/components/Heading/styles.js +20 -0
- package/lib/module/components/Heading/styles.js.map +1 -0
- package/lib/module/components/Icon/index.js +57 -0
- package/lib/module/components/Icon/index.js.map +1 -0
- package/lib/module/components/IconButton/index.js +76 -0
- package/lib/module/components/IconButton/index.js.map +1 -0
- package/lib/module/components/IconButton/styles.js +87 -0
- package/lib/module/components/IconButton/styles.js.map +1 -0
- package/lib/module/components/Image/Image.js +67 -0
- package/lib/module/components/Image/Image.js.map +1 -0
- package/lib/module/components/Image/index.js +4 -0
- package/lib/module/components/Image/index.js.map +1 -0
- package/lib/module/components/Input/BaseInput.android.js +16 -0
- package/lib/module/components/Input/BaseInput.android.js.map +1 -0
- package/lib/module/components/Input/index.js +10 -16
- package/lib/module/components/Input/index.js.map +1 -1
- package/lib/module/components/Input/styles.js +16 -30
- package/lib/module/components/Input/styles.js.map +1 -1
- package/lib/module/components/Link/index.js +85 -0
- package/lib/module/components/Link/index.js.map +1 -0
- package/lib/module/components/Link/styles.js +12 -0
- package/lib/module/components/Link/styles.js.map +1 -0
- package/lib/module/components/ProgressSegmented/index.js +58 -0
- package/lib/module/components/ProgressSegmented/index.js.map +1 -0
- package/lib/module/components/ProgressSegmented/styles.js +17 -0
- package/lib/module/components/ProgressSegmented/styles.js.map +1 -0
- package/lib/module/components/Select/SelectTriggerHost.js +7 -0
- package/lib/module/components/Select/SelectTriggerHost.js.map +1 -0
- package/lib/module/components/Select/SelectTriggerHost.web.js +93 -0
- package/lib/module/components/Select/SelectTriggerHost.web.js.map +1 -0
- package/lib/module/components/Select/index.js +14 -14
- package/lib/module/components/Select/index.js.map +1 -1
- package/lib/module/components/Select/styles.js +29 -53
- package/lib/module/components/Select/styles.js.map +1 -1
- package/lib/module/components/Stack/HStack.js +8 -21
- package/lib/module/components/Stack/HStack.js.map +1 -1
- package/lib/module/components/Stack/VStack.js +8 -21
- package/lib/module/components/Stack/VStack.js.map +1 -1
- package/lib/module/components/Stack/styles.js +35 -0
- package/lib/module/components/Stack/styles.js.map +1 -0
- package/lib/module/components/Switch/BaseSwitch.js +42 -0
- package/lib/module/components/Switch/BaseSwitch.js.map +1 -0
- package/lib/module/components/Switch/BaseSwitch.web.js +52 -0
- package/lib/module/components/Switch/BaseSwitch.web.js.map +1 -0
- package/lib/module/components/Switch/index.js +9 -0
- package/lib/module/components/Switch/index.js.map +1 -0
- package/lib/module/components/Switch/styles.js +125 -0
- package/lib/module/components/Switch/styles.js.map +1 -0
- package/lib/module/components/Text/index.js +19 -1
- package/lib/module/components/Text/index.js.map +1 -1
- package/lib/module/components/Text/styles.js +20 -0
- package/lib/module/components/Text/styles.js.map +1 -0
- package/lib/module/components/VirtualizedList/index.js +15 -0
- package/lib/module/components/VirtualizedList/index.js.map +1 -0
- package/lib/module/components/index.js +16 -0
- package/lib/module/components/index.js.map +1 -1
- package/lib/module/index.js +3 -0
- package/lib/module/index.js.map +1 -1
- package/lib/module/metro/withCdxMetroConfig.js +20 -0
- package/lib/module/metro/withCdxMetroConfig.js.map +1 -0
- package/lib/module/styles/index.js +4 -0
- package/lib/module/styles/index.js.map +1 -0
- package/lib/module/styles/primitives.js +119 -0
- package/lib/module/styles/primitives.js.map +1 -0
- package/lib/typescript/components/AlertDialog/index.d.ts +30 -0
- package/lib/typescript/components/AlertDialog/index.d.ts.map +1 -0
- package/lib/typescript/components/Avatar/index.d.ts +40 -0
- package/lib/typescript/components/Avatar/index.d.ts.map +1 -0
- package/lib/typescript/components/Avatar/styles.d.ts +16 -0
- package/lib/typescript/components/Avatar/styles.d.ts.map +1 -0
- package/lib/typescript/components/BottomSheet/index.d.ts +61 -0
- package/lib/typescript/components/BottomSheet/index.d.ts.map +1 -0
- package/lib/typescript/components/BottomSheet/styles.d.ts +16 -0
- package/lib/typescript/components/BottomSheet/styles.d.ts.map +1 -0
- package/lib/typescript/components/Box/Box.d.ts +1 -0
- package/lib/typescript/components/Box/Box.d.ts.map +1 -1
- package/lib/typescript/components/Button/buttonSharedVariants.d.ts +29 -0
- package/lib/typescript/components/Button/buttonSharedVariants.d.ts.map +1 -0
- package/lib/typescript/components/Button/index.d.ts +6 -3
- package/lib/typescript/components/Button/index.d.ts.map +1 -1
- package/lib/typescript/components/Button/styles.d.ts +14 -8
- package/lib/typescript/components/Button/styles.d.ts.map +1 -1
- package/lib/typescript/components/Card/index.d.ts +30 -0
- package/lib/typescript/components/Card/index.d.ts.map +1 -0
- package/lib/typescript/components/Card/styles.d.ts +6 -0
- package/lib/typescript/components/Card/styles.d.ts.map +1 -0
- package/lib/typescript/components/Checkbox/index.d.ts +46 -0
- package/lib/typescript/components/Checkbox/index.d.ts.map +1 -0
- package/lib/typescript/components/Checkbox/styles.d.ts +18 -0
- package/lib/typescript/components/Checkbox/styles.d.ts.map +1 -0
- package/lib/typescript/components/Chip/index.d.ts +27 -0
- package/lib/typescript/components/Chip/index.d.ts.map +1 -0
- package/lib/typescript/components/Chip/styles.d.ts +12 -0
- package/lib/typescript/components/Chip/styles.d.ts.map +1 -0
- package/lib/typescript/components/Dialog/index.d.ts +61 -0
- package/lib/typescript/components/Dialog/index.d.ts.map +1 -0
- package/lib/typescript/components/Dialog/styles.d.ts +14 -0
- package/lib/typescript/components/Dialog/styles.d.ts.map +1 -0
- package/lib/typescript/components/Form/FormLabelRoot.d.ts +18 -0
- package/lib/typescript/components/Form/FormLabelRoot.d.ts.map +1 -0
- package/lib/typescript/components/Form/FormLabelRoot.web.d.ts +20 -0
- package/lib/typescript/components/Form/FormLabelRoot.web.d.ts.map +1 -0
- package/lib/typescript/components/Form/FormRoot.d.ts +12 -0
- package/lib/typescript/components/Form/FormRoot.d.ts.map +1 -0
- package/lib/typescript/components/Form/FormRoot.web.d.ts +10 -0
- package/lib/typescript/components/Form/FormRoot.web.d.ts.map +1 -0
- package/lib/typescript/components/Form/index.d.ts +64 -0
- package/lib/typescript/components/Form/index.d.ts.map +1 -0
- package/lib/typescript/components/Form/styles.d.ts +22 -0
- package/lib/typescript/components/Form/styles.d.ts.map +1 -0
- package/lib/typescript/components/Heading/index.d.ts +10 -0
- package/lib/typescript/components/Heading/index.d.ts.map +1 -0
- package/lib/typescript/components/Heading/styles.d.ts +6 -0
- package/lib/typescript/components/Heading/styles.d.ts.map +1 -0
- package/lib/typescript/components/Icon/index.d.ts +27 -0
- package/lib/typescript/components/Icon/index.d.ts.map +1 -0
- package/lib/typescript/components/IconButton/index.d.ts +15 -0
- package/lib/typescript/components/IconButton/index.d.ts.map +1 -0
- package/lib/typescript/components/IconButton/styles.d.ts +16 -0
- package/lib/typescript/components/IconButton/styles.d.ts.map +1 -0
- package/lib/typescript/components/Image/Image.d.ts +47 -0
- package/lib/typescript/components/Image/Image.d.ts.map +1 -0
- package/lib/typescript/components/Image/index.d.ts +2 -0
- package/lib/typescript/components/Image/index.d.ts.map +1 -0
- package/lib/typescript/components/Input/BaseInput.android.d.ts +3 -0
- package/lib/typescript/components/Input/BaseInput.android.d.ts.map +1 -0
- package/lib/typescript/components/Input/index.d.ts +7 -5
- package/lib/typescript/components/Input/index.d.ts.map +1 -1
- package/lib/typescript/components/Input/styles.d.ts +5 -7
- package/lib/typescript/components/Input/styles.d.ts.map +1 -1
- package/lib/typescript/components/Link/index.d.ts +26 -0
- package/lib/typescript/components/Link/index.d.ts.map +1 -0
- package/lib/typescript/components/Link/styles.d.ts +4 -0
- package/lib/typescript/components/Link/styles.d.ts.map +1 -0
- package/lib/typescript/components/ProgressSegmented/index.d.ts +15 -0
- package/lib/typescript/components/ProgressSegmented/index.d.ts.map +1 -0
- package/lib/typescript/components/ProgressSegmented/styles.d.ts +8 -0
- package/lib/typescript/components/ProgressSegmented/styles.d.ts.map +1 -0
- package/lib/typescript/components/Select/SelectTriggerHost.d.ts +3 -0
- package/lib/typescript/components/Select/SelectTriggerHost.d.ts.map +1 -0
- package/lib/typescript/components/Select/SelectTriggerHost.web.d.ts +13 -0
- package/lib/typescript/components/Select/SelectTriggerHost.web.d.ts.map +1 -0
- package/lib/typescript/components/Select/index.d.ts +7 -4
- package/lib/typescript/components/Select/index.d.ts.map +1 -1
- package/lib/typescript/components/Select/styles.d.ts +6 -8
- package/lib/typescript/components/Select/styles.d.ts.map +1 -1
- package/lib/typescript/components/Stack/HStack.d.ts +1 -12
- package/lib/typescript/components/Stack/HStack.d.ts.map +1 -1
- package/lib/typescript/components/Stack/VStack.d.ts +1 -12
- package/lib/typescript/components/Stack/VStack.d.ts.map +1 -1
- package/lib/typescript/components/Stack/styles.d.ts +10 -0
- package/lib/typescript/components/Stack/styles.d.ts.map +1 -0
- package/lib/typescript/components/Switch/BaseSwitch.d.ts +9 -0
- package/lib/typescript/components/Switch/BaseSwitch.d.ts.map +1 -0
- package/lib/typescript/components/Switch/BaseSwitch.web.d.ts +15 -0
- package/lib/typescript/components/Switch/BaseSwitch.web.d.ts.map +1 -0
- package/lib/typescript/components/Switch/index.d.ts +7 -0
- package/lib/typescript/components/Switch/index.d.ts.map +1 -0
- package/lib/typescript/components/Switch/styles.d.ts +26 -0
- package/lib/typescript/components/Switch/styles.d.ts.map +1 -0
- package/lib/typescript/components/Text/index.d.ts +9 -1
- package/lib/typescript/components/Text/index.d.ts.map +1 -1
- package/lib/typescript/components/Text/styles.d.ts +6 -0
- package/lib/typescript/components/Text/styles.d.ts.map +1 -0
- package/lib/typescript/components/VirtualizedList/index.d.ts +8 -0
- package/lib/typescript/components/VirtualizedList/index.d.ts.map +1 -0
- package/lib/typescript/components/index.d.ts +16 -0
- package/lib/typescript/components/index.d.ts.map +1 -1
- package/lib/typescript/index.d.ts +3 -0
- package/lib/typescript/index.d.ts.map +1 -1
- package/lib/typescript/metro/withCdxMetroConfig.d.ts +19 -0
- package/lib/typescript/metro/withCdxMetroConfig.d.ts.map +1 -0
- package/lib/typescript/styles/index.d.ts +2 -0
- package/lib/typescript/styles/index.d.ts.map +1 -0
- package/lib/typescript/styles/primitives.d.ts +85 -0
- package/lib/typescript/styles/primitives.d.ts.map +1 -0
- package/package.json +23 -16
- package/src/components/AlertDialog/index.tsx +124 -0
- package/src/components/Avatar/index.tsx +172 -0
- package/src/components/Avatar/styles.ts +83 -0
- package/src/components/BottomSheet/index.tsx +316 -0
- package/src/components/BottomSheet/styles.ts +79 -0
- package/src/components/Box/Box.tsx +1 -0
- package/src/components/Button/buttonSharedVariants.ts +281 -0
- package/src/components/Button/index.tsx +24 -15
- package/src/components/Button/styles.ts +195 -229
- package/src/components/Card/index.tsx +115 -0
- package/src/components/Card/styles.ts +41 -0
- package/src/components/Checkbox/index.tsx +207 -0
- package/src/components/Checkbox/styles.ts +103 -0
- package/src/components/Chip/index.tsx +91 -0
- package/src/components/Chip/styles.ts +51 -0
- package/src/components/Dialog/index.tsx +304 -0
- package/src/components/Dialog/styles.ts +88 -0
- package/src/components/Form/FormLabelRoot.tsx +33 -0
- package/src/components/Form/FormLabelRoot.web.tsx +18 -0
- package/src/components/Form/FormRoot.tsx +19 -0
- package/src/components/Form/FormRoot.web.tsx +12 -0
- package/src/components/Form/index.tsx +272 -0
- package/src/components/Form/styles.ts +75 -0
- package/src/components/Heading/index.tsx +36 -0
- package/src/components/Heading/styles.tsx +26 -0
- package/src/components/Icon/index.tsx +54 -0
- package/src/components/IconButton/index.tsx +93 -0
- package/src/components/IconButton/styles.ts +131 -0
- package/src/components/Image/Image.tsx +77 -0
- package/src/components/Image/index.ts +1 -0
- package/src/components/Input/BaseInput.android.tsx +13 -0
- package/src/components/Input/index.tsx +9 -22
- package/src/components/Input/styles.ts +42 -37
- package/src/components/Link/index.tsx +83 -0
- package/src/components/Link/styles.ts +20 -0
- package/src/components/ProgressSegmented/index.tsx +81 -0
- package/src/components/ProgressSegmented/styles.ts +19 -0
- package/src/components/Select/SelectTriggerHost.tsx +4 -0
- package/src/components/Select/SelectTriggerHost.web.tsx +136 -0
- package/src/components/Select/index.tsx +14 -14
- package/src/components/Select/styles.ts +68 -75
- package/src/components/Stack/HStack.tsx +8 -19
- package/src/components/Stack/VStack.tsx +8 -23
- package/src/components/Stack/styles.ts +37 -0
- package/src/components/Switch/BaseSwitch.tsx +38 -0
- package/src/components/Switch/BaseSwitch.web.tsx +69 -0
- package/src/components/Switch/index.tsx +11 -0
- package/src/components/Switch/styles.ts +120 -0
- package/src/components/Text/index.tsx +16 -0
- package/src/components/Text/styles.tsx +26 -0
- package/src/components/VirtualizedList/index.tsx +19 -0
- package/src/components/index.ts +16 -0
- package/src/index.ts +3 -0
- package/src/metro/withCdxMetroConfig.ts +29 -0
- package/src/styles/index.ts +1 -0
- package/src/styles/primitives.ts +107 -0
- package/lib/commonjs/components/Text/Text.js +0 -30
- package/lib/commonjs/components/Text/Text.js.map +0 -1
- package/lib/module/components/Text/Text.js +0 -26
- package/lib/module/components/Text/Text.js.map +0 -1
- package/lib/typescript/components/Text/Text.d.ts +0 -11
- package/lib/typescript/components/Text/Text.d.ts.map +0 -1
- package/src/components/Text/Text.tsx +0 -58
- package/src/components/Text/index.ts +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["forwardRef","ActivityIndicator","Pressable","Text","View","createButton","cn","useStyleContext","withStyleContext","buttonGroupVariants","buttonRootVariants","buttonSpinnerVariants","buttonTextVariants","jsx","_jsx","SCOPE","Root","useButtonStyleContext","ButtonPrimitive","Group","Spinner","
|
|
1
|
+
{"version":3,"names":["forwardRef","ActivityIndicator","Pressable","Text","View","createButton","cn","useStyleContext","withStyleContext","Icon","buttonGroupVariants","buttonIconVariants","buttonRootVariants","buttonSpinnerVariants","buttonTextVariants","jsx","_jsx","SCOPE","Root","useButtonStyleContext","ButtonPrimitive","Group","Spinner","ButtonRoot","variant","color","size","mode","fullWidth","className","children","style","props","ref","computedClassName","context","displayName","ButtonLabel","ButtonGroup","flexDirection","isAttached","groupClassName","ButtonIcon","as","ButtonSpinner","colorClassName","computedColorClassName","Button","Object","assign","Label"],"sourceRoot":"../../../../src","sources":["components/Button/index.tsx"],"mappings":";;AAAA,SAASA,UAAU,QAA2C,OAAO;AACrE,SACEC,iBAAiB,EACjBC,SAAS,EACTC,IAAI,EACJC,IAAI,QAKC,cAAc;AACrB,SAASC,YAAY,QAA2B,oBAAoB;AACpE,SAASC,EAAE,EAAEC,eAAe,EAAEC,gBAAgB,QAAQ,eAAe;AACrE,SAASC,IAAI,QAAmB,SAAS;AACzC,SAGEC,mBAAmB,EACnBC,kBAAkB,EAClBC,kBAAkB,EAClBC,qBAAqB,EACrBC,kBAAkB,QACb,UAAU;AAAC,SAAAC,GAAA,IAAAC,IAAA;AAElB,MAAMC,KAAK,GAAG,QAAQ;AAEtB,MAAMC,IAAI,GAAGV,gBAAgB,CAACN,SAAS,EAAEe,KAAK,CAAC;AAE/C,MAAME,qBAAqB,GAAGA,CAAA,KAAMZ,eAAe,CAACU,KAAK,CAAuB;AAEhF,MAAMG,eAAe,GAAGf,YAAY,CAAC;EACnCa,IAAI;EACJf,IAAI;EACJkB,KAAK,EAAEjB,IAAI;EACXkB,OAAO,EAAErB,iBAAiB;EAC1BQ,IAAI,EAAEL;AACR,CAAC,CAAC;;AAEF;AACA;AACA;;AAOA,MAAMmB,UAAU,gBAAGvB,UAAU,CAC3B,CACE;E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AAc;EAAEd,KAAK;EAAE,GAAGC;AAAM,CAAC,EAAEC,GAAG,KAAK;EACvD,MAAM;IAAET,OAAO;IAAEC,KAAK;IAAEE;EAAK,CAAC,GAAGR,qBAAqB,CAAC,CAAC;EACxD,MAAM2B,sBAAsB,GAAGxC,EAAE,CAC/BO,qBAAqB,CAAC;IAAEW,OAAO;IAAEC,KAAK;IAAEE;EAAK,CAAC,CAAC,EAC/CkB,cACF,CAAC;EAED,oBACE7B,IAAA,CAACI,eAAe,CAACE,OAAO;IACtBW,GAAG,EAAEA,GAAI;IACTJ,SAAS,EAAEA,SAAU;IACrBgB,cAAc,EAAEC,sBAAuB;IACvCf,KAAK,EAAEA,KAAM;IAAA,GACTC;EAAK,CACV,CAAC;AAEN,CACF,CAAC;AAEDY,aAAa,CAACR,WAAW,GAAG,gBAAgB;AAS5C,OAAO,MAAMW,MAAM,GAAGC,MAAM,CAACC,MAAM,CAAC1B,UAAU,EAAE;EAC9C2B,KAAK,EAAEb,WAAW;EAClBhB,KAAK,EAAEiB,WAAW;EAClB7B,IAAI,EAAEiC,UAAU;EAChBpB,OAAO,EAAEsB;AACX,CAAC,CAA4B","ignoreList":[]}
|
|
@@ -2,102 +2,74 @@
|
|
|
2
2
|
|
|
3
3
|
import { Platform } from 'react-native';
|
|
4
4
|
import { cva } from 'class-variance-authority';
|
|
5
|
+
import { COLOR_BORDER_DEFAULT, DISABLED_CURSOR, DISABLED_OPACITY, RADIUS_SM, TRANSITION_COLORS } from '../../styles/primitives';
|
|
6
|
+
import { sharedFilledForegroundTextCompounds, sharedFilledSurfaceCompounds, sharedGhostSurfaceCompounds, sharedOutlineGhostForegroundTextCompounds } from './buttonSharedVariants';
|
|
7
|
+
const buttonStrongSurfaceCompounds = sharedFilledSurfaceCompounds.map(c => ({
|
|
8
|
+
variant: 'strong',
|
|
9
|
+
...c
|
|
10
|
+
}));
|
|
11
|
+
const buttonGhostSurfaceCompounds = sharedGhostSurfaceCompounds.map(c => ({
|
|
12
|
+
variant: 'ghost',
|
|
13
|
+
...c
|
|
14
|
+
}));
|
|
15
|
+
const buttonStrongForegroundTextCompounds = sharedFilledForegroundTextCompounds.map(c => ({
|
|
16
|
+
variant: 'strong',
|
|
17
|
+
...c
|
|
18
|
+
}));
|
|
19
|
+
const buttonOutlineGhostForegroundTextCompounds = sharedOutlineGhostForegroundTextCompounds.map(c => ({
|
|
20
|
+
variant: ['outline', 'ghost'],
|
|
21
|
+
...c
|
|
22
|
+
}));
|
|
5
23
|
|
|
6
24
|
// TODO: Split into 2 files
|
|
7
25
|
// TODO: Create cva wrapper
|
|
8
26
|
|
|
9
|
-
export const buttonRootVariants = cva(['flex-row items-center justify-center', '
|
|
10
|
-
// TODO: Transition not working on mobile
|
|
11
|
-
'data-[disabled=true]:opacity-60 data-[disabled=true]:cursor-not-allowed data-[disabled=true]:pointer-events-none', 'data-[focus-visible=true]:ring-2 data-[focus-visible=true]:ring-ring data-[focus-visible=true]:ring-offset-2 data-[focus-visible=true]:ring-offset-bg'], {
|
|
27
|
+
export const buttonRootVariants = cva(['flex-row items-center justify-center', RADIUS_SM, 'web:outline-none web:focus:outline-none web:focus-visible:outline-none', TRANSITION_COLORS, DISABLED_OPACITY, DISABLED_CURSOR, 'web:data-[focus-visible=true]:ring-2 web:data-[focus-visible=true]:ring-slate-400/50 web:data-[focus-visible=true]:ring-offset-2'], {
|
|
12
28
|
variants: {
|
|
13
29
|
variant: {
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
ghost: ['bg-transparent', 'data-[hover=true]:bg-surface', 'data-[active=true]:bg-surface-raised']
|
|
30
|
+
strong: [],
|
|
31
|
+
outline: ['bg-transparent', `border ${COLOR_BORDER_DEFAULT}`, 'data-[hover=true]:bg-slate-50', 'data-[active=true]:bg-slate-100'],
|
|
32
|
+
ghost: ['bg-transparent', 'data-[hover=true]:bg-slate-50', 'data-[active=true]:bg-slate-100']
|
|
18
33
|
},
|
|
19
34
|
color: {
|
|
20
|
-
|
|
21
|
-
|
|
35
|
+
action: [],
|
|
36
|
+
danger: [],
|
|
37
|
+
warning: [],
|
|
22
38
|
success: [],
|
|
23
|
-
|
|
39
|
+
info: []
|
|
24
40
|
},
|
|
25
41
|
size: {
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
42
|
+
default: 'h-10 px-4 gap-2',
|
|
43
|
+
small: 'h-8 px-3 gap-1.5'
|
|
44
|
+
},
|
|
45
|
+
mode: {
|
|
46
|
+
light: [],
|
|
47
|
+
dark: []
|
|
29
48
|
},
|
|
30
49
|
fullWidth: {
|
|
31
50
|
true: 'w-full',
|
|
32
51
|
false: ''
|
|
33
52
|
}
|
|
34
53
|
},
|
|
35
|
-
compoundVariants: [
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
variant: 'solid',
|
|
44
|
-
color: 'secondary',
|
|
45
|
-
className: ['bg-amber-500', Platform.select({
|
|
46
|
-
default: 'data-[active=true]:bg-amber-700',
|
|
47
|
-
web: 'data-[hover=true]:bg-amber-600 data-[active=true]:data-[hover=true]:bg-amber-700'
|
|
48
|
-
})]
|
|
49
|
-
}, {
|
|
50
|
-
variant: 'solid',
|
|
51
|
-
color: 'success',
|
|
52
|
-
className: ['bg-green-500', Platform.select({
|
|
53
|
-
default: 'data-[active=true]:bg-green-700',
|
|
54
|
-
web: 'data-[hover=true]:bg-green-600 data-[active=true]:data-[hover=true]:bg-green-700'
|
|
55
|
-
})]
|
|
56
|
-
}, {
|
|
57
|
-
variant: 'solid',
|
|
58
|
-
color: 'danger',
|
|
59
|
-
className: ['bg-red-500', Platform.select({
|
|
60
|
-
default: 'data-[active=true]:bg-red-700',
|
|
61
|
-
web: 'data-[hover=true]:bg-red-600 data-[active=true]:data-[hover=true]:bg-red-700'
|
|
62
|
-
})]
|
|
63
|
-
}, {
|
|
64
|
-
variant: 'subtle',
|
|
65
|
-
color: 'primary',
|
|
66
|
-
className: ['bg-blue-100', Platform.select({
|
|
67
|
-
default: 'data-[active=true]:bg-blue-200',
|
|
68
|
-
web: 'data-[hover=true]:bg-blue-200 data-[active=true]:data-[hover=true]:bg-blue-300'
|
|
69
|
-
})]
|
|
70
|
-
}, {
|
|
71
|
-
variant: 'subtle',
|
|
72
|
-
color: 'secondary',
|
|
73
|
-
className: ['bg-amber-200', Platform.select({
|
|
74
|
-
default: 'data-[active=true]:bg-amber-300',
|
|
75
|
-
web: 'data-[hover=true]:bg-amber-300 data-[active=true]:data-[hover=true]:bg-amber-400'
|
|
76
|
-
})]
|
|
77
|
-
}, {
|
|
78
|
-
variant: 'subtle',
|
|
79
|
-
color: 'success',
|
|
80
|
-
className: ['bg-green-200', Platform.select({
|
|
81
|
-
default: 'data-[active=true]:bg-green-300',
|
|
82
|
-
web: 'data-[hover=true]:bg-green-300 data-[active=true]:data-[hover=true]:bg-green-400'
|
|
83
|
-
})]
|
|
84
|
-
}, {
|
|
85
|
-
variant: 'subtle',
|
|
86
|
-
color: 'danger',
|
|
87
|
-
className: ['bg-red-200', Platform.select({
|
|
88
|
-
default: 'data-[active=true]:bg-red-300',
|
|
89
|
-
web: 'data-[hover=true]:bg-red-300 data-[active=true]:data-[hover=true]:bg-red-400'
|
|
54
|
+
compoundVariants: [...buttonStrongSurfaceCompounds,
|
|
55
|
+
// --- outline × color (light mode) ---
|
|
56
|
+
{
|
|
57
|
+
variant: 'outline',
|
|
58
|
+
color: 'action',
|
|
59
|
+
className: ['border-slate-300', Platform.select({
|
|
60
|
+
default: 'data-[active=true]:border-slate-500 data-[active=true]:bg-slate-100',
|
|
61
|
+
web: 'data-[hover=true]:border-slate-400 data-[hover=true]:bg-slate-50 data-[active=true]:data-[hover=true]:border-slate-500 data-[active=true]:data-[hover=true]:bg-slate-100'
|
|
90
62
|
})]
|
|
91
63
|
}, {
|
|
92
64
|
variant: 'outline',
|
|
93
|
-
color: '
|
|
94
|
-
className: ['border-
|
|
95
|
-
default: 'data-[active=true]:border-
|
|
96
|
-
web: 'data-[hover=true]:border-
|
|
65
|
+
color: 'danger',
|
|
66
|
+
className: ['border-red-600', Platform.select({
|
|
67
|
+
default: 'data-[active=true]:border-red-800 data-[active=true]:bg-red-100',
|
|
68
|
+
web: 'data-[hover=true]:border-red-700 data-[hover=true]:bg-red-50 data-[active=true]:data-[hover=true]:border-red-800 data-[active=true]:data-[hover=true]:bg-red-100'
|
|
97
69
|
})]
|
|
98
70
|
}, {
|
|
99
71
|
variant: 'outline',
|
|
100
|
-
color: '
|
|
72
|
+
color: 'warning',
|
|
101
73
|
className: ['border-amber-500', Platform.select({
|
|
102
74
|
default: 'data-[active=true]:border-amber-700 data-[active=true]:bg-amber-50',
|
|
103
75
|
web: 'data-[hover=true]:border-amber-600 data-[hover=true]:bg-amber-50 data-[active=true]:data-[hover=true]:border-amber-700 data-[active=true]:data-[hover=true]:bg-amber-100'
|
|
@@ -105,175 +77,174 @@ export const buttonRootVariants = cva(['flex-row items-center justify-center', '
|
|
|
105
77
|
}, {
|
|
106
78
|
variant: 'outline',
|
|
107
79
|
color: 'success',
|
|
108
|
-
className: ['border-green-
|
|
109
|
-
default: 'data-[active=true]:border-green-
|
|
110
|
-
web: 'data-[hover=true]:border-green-
|
|
80
|
+
className: ['border-green-600', Platform.select({
|
|
81
|
+
default: 'data-[active=true]:border-green-800 data-[active=true]:bg-green-100',
|
|
82
|
+
web: 'data-[hover=true]:border-green-700 data-[hover=true]:bg-green-50 data-[active=true]:data-[hover=true]:border-green-800 data-[active=true]:data-[hover=true]:bg-green-100'
|
|
111
83
|
})]
|
|
112
84
|
}, {
|
|
113
85
|
variant: 'outline',
|
|
114
|
-
color: '
|
|
115
|
-
className: ['border-
|
|
116
|
-
default: 'data-[active=true]:border-
|
|
117
|
-
web: 'data-[hover=true]:border-
|
|
86
|
+
color: 'info',
|
|
87
|
+
className: ['border-sky-500', Platform.select({
|
|
88
|
+
default: 'data-[active=true]:border-sky-700 data-[active=true]:bg-sky-100',
|
|
89
|
+
web: 'data-[hover=true]:border-sky-600 data-[hover=true]:bg-sky-50 data-[active=true]:data-[hover=true]:border-sky-700 data-[active=true]:data-[hover=true]:bg-sky-100'
|
|
118
90
|
})]
|
|
119
|
-
},
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
91
|
+
},
|
|
92
|
+
// --- outline × action × mode: dark ---
|
|
93
|
+
{
|
|
94
|
+
variant: 'outline',
|
|
95
|
+
color: 'action',
|
|
96
|
+
mode: 'dark',
|
|
97
|
+
className: ['bg-transparent border-slate-700', Platform.select({
|
|
98
|
+
default: 'data-[active=true]:bg-slate-700',
|
|
99
|
+
web: 'data-[hover=true]:bg-slate-800 data-[active=true]:data-[hover=true]:bg-slate-700'
|
|
100
|
+
})]
|
|
101
|
+
},
|
|
102
|
+
// --- outline × semantic colors × mode: dark ---
|
|
103
|
+
{
|
|
104
|
+
variant: 'outline',
|
|
105
|
+
color: 'danger',
|
|
106
|
+
mode: 'dark',
|
|
107
|
+
className: ['bg-transparent border-red-500', Platform.select({
|
|
108
|
+
default: 'data-[active=true]:bg-red-950',
|
|
109
|
+
web: 'data-[hover=true]:bg-red-950/50 data-[active=true]:data-[hover=true]:bg-red-950'
|
|
125
110
|
})]
|
|
126
111
|
}, {
|
|
127
|
-
variant: '
|
|
128
|
-
color: '
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
112
|
+
variant: 'outline',
|
|
113
|
+
color: 'warning',
|
|
114
|
+
mode: 'dark',
|
|
115
|
+
className: ['bg-transparent border-amber-500', Platform.select({
|
|
116
|
+
default: 'data-[active=true]:bg-amber-950',
|
|
117
|
+
web: 'data-[hover=true]:bg-amber-950/50 data-[active=true]:data-[hover=true]:bg-amber-950'
|
|
132
118
|
})]
|
|
133
119
|
}, {
|
|
134
|
-
variant: '
|
|
120
|
+
variant: 'outline',
|
|
135
121
|
color: 'success',
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
122
|
+
mode: 'dark',
|
|
123
|
+
className: ['bg-transparent border-green-500', Platform.select({
|
|
124
|
+
default: 'data-[active=true]:bg-green-950',
|
|
125
|
+
web: 'data-[hover=true]:bg-green-950/50 data-[active=true]:data-[hover=true]:bg-green-950'
|
|
139
126
|
})]
|
|
140
127
|
}, {
|
|
141
|
-
variant: '
|
|
142
|
-
color: '
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
128
|
+
variant: 'outline',
|
|
129
|
+
color: 'info',
|
|
130
|
+
mode: 'dark',
|
|
131
|
+
className: ['bg-transparent border-sky-500', Platform.select({
|
|
132
|
+
default: 'data-[active=true]:bg-sky-950',
|
|
133
|
+
web: 'data-[hover=true]:bg-sky-950/50 data-[active=true]:data-[hover=true]:bg-sky-950'
|
|
146
134
|
})]
|
|
147
|
-
}],
|
|
135
|
+
}, ...buttonGhostSurfaceCompounds],
|
|
148
136
|
defaultVariants: {
|
|
149
|
-
variant: '
|
|
150
|
-
color: '
|
|
151
|
-
size: '
|
|
137
|
+
variant: 'strong',
|
|
138
|
+
color: 'action',
|
|
139
|
+
size: 'default',
|
|
140
|
+
mode: 'light',
|
|
152
141
|
fullWidth: false
|
|
153
142
|
}
|
|
154
143
|
});
|
|
155
144
|
export const buttonTextVariants = cva(['font-medium', 'text-center'], {
|
|
156
145
|
variants: {
|
|
157
146
|
variant: {
|
|
158
|
-
|
|
159
|
-
subtle: [],
|
|
147
|
+
strong: [],
|
|
160
148
|
outline: [],
|
|
161
149
|
ghost: []
|
|
162
150
|
},
|
|
163
151
|
color: {
|
|
164
|
-
|
|
165
|
-
|
|
152
|
+
action: [],
|
|
153
|
+
danger: [],
|
|
154
|
+
warning: [],
|
|
166
155
|
success: [],
|
|
167
|
-
|
|
156
|
+
info: []
|
|
168
157
|
},
|
|
169
158
|
size: {
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
159
|
+
default: 'text-base',
|
|
160
|
+
small: 'text-sm'
|
|
161
|
+
},
|
|
162
|
+
mode: {
|
|
163
|
+
light: [],
|
|
164
|
+
dark: []
|
|
173
165
|
}
|
|
174
166
|
},
|
|
175
|
-
compoundVariants: [
|
|
176
|
-
variant: 'subtle',
|
|
177
|
-
color: 'primary',
|
|
178
|
-
className: 'text-blue-950'
|
|
179
|
-
}, {
|
|
180
|
-
variant: 'subtle',
|
|
181
|
-
color: 'secondary',
|
|
182
|
-
className: 'text-amber-950'
|
|
183
|
-
}, {
|
|
184
|
-
variant: 'subtle',
|
|
185
|
-
color: 'success',
|
|
186
|
-
className: 'text-green-950'
|
|
187
|
-
}, {
|
|
188
|
-
variant: 'subtle',
|
|
189
|
-
color: 'danger',
|
|
190
|
-
className: 'text-red-950'
|
|
191
|
-
}, {
|
|
192
|
-
variant: ['outline', 'ghost'],
|
|
193
|
-
color: 'primary',
|
|
194
|
-
className: ['text-blue-500', Platform.select({
|
|
195
|
-
default: 'data-[active=true]:text-blue-700',
|
|
196
|
-
web: 'data-[hover=true]:text-blue-600 data-[active=true]:data-[hover=true]:text-blue-700'
|
|
197
|
-
})]
|
|
198
|
-
}, {
|
|
199
|
-
variant: ['outline', 'ghost'],
|
|
200
|
-
color: 'secondary',
|
|
201
|
-
className: ['text-amber-600', Platform.select({
|
|
202
|
-
default: 'data-[active=true]:text-amber-800',
|
|
203
|
-
web: 'data-[hover=true]:text-amber-700 data-[active=true]:data-[hover=true]:text-amber-800'
|
|
204
|
-
})]
|
|
205
|
-
}, {
|
|
206
|
-
variant: ['outline', 'ghost'],
|
|
207
|
-
color: 'success',
|
|
208
|
-
className: ['text-green-600', Platform.select({
|
|
209
|
-
default: 'data-[active=true]:text-green-800',
|
|
210
|
-
web: 'data-[hover=true]:text-green-700 data-[active=true]:data-[hover=true]:text-green-800'
|
|
211
|
-
})]
|
|
212
|
-
}, {
|
|
213
|
-
variant: ['outline', 'ghost'],
|
|
214
|
-
color: 'danger',
|
|
215
|
-
className: ['text-red-500', Platform.select({
|
|
216
|
-
default: 'data-[active=true]:text-red-700',
|
|
217
|
-
web: 'data-[hover=true]:text-red-600 data-[active=true]:data-[hover=true]:text-red-700'
|
|
218
|
-
})]
|
|
219
|
-
}],
|
|
167
|
+
compoundVariants: [...buttonStrongForegroundTextCompounds, ...buttonOutlineGhostForegroundTextCompounds],
|
|
220
168
|
defaultVariants: {
|
|
221
|
-
variant: '
|
|
222
|
-
color: '
|
|
223
|
-
size: '
|
|
169
|
+
variant: 'strong',
|
|
170
|
+
color: 'action',
|
|
171
|
+
size: 'default',
|
|
172
|
+
mode: 'light'
|
|
224
173
|
}
|
|
225
174
|
});
|
|
226
175
|
export const buttonSpinnerVariants = cva([], {
|
|
227
176
|
variants: {
|
|
228
177
|
variant: {
|
|
229
|
-
|
|
230
|
-
subtle: [],
|
|
178
|
+
strong: 'accent-white',
|
|
231
179
|
outline: [],
|
|
232
180
|
ghost: []
|
|
233
181
|
},
|
|
234
182
|
color: {
|
|
235
|
-
|
|
236
|
-
|
|
183
|
+
action: [],
|
|
184
|
+
danger: [],
|
|
185
|
+
warning: [],
|
|
237
186
|
success: [],
|
|
238
|
-
|
|
187
|
+
info: []
|
|
188
|
+
},
|
|
189
|
+
mode: {
|
|
190
|
+
light: [],
|
|
191
|
+
dark: []
|
|
239
192
|
}
|
|
240
193
|
},
|
|
241
|
-
compoundVariants: [
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
194
|
+
compoundVariants: [
|
|
195
|
+
// --- outline/ghost × color (light mode) ---
|
|
196
|
+
{
|
|
197
|
+
variant: ['outline', 'ghost'],
|
|
198
|
+
color: 'action',
|
|
199
|
+
className: 'accent-slate-900'
|
|
245
200
|
}, {
|
|
246
|
-
variant: '
|
|
247
|
-
color: '
|
|
248
|
-
className: 'accent-
|
|
201
|
+
variant: ['outline', 'ghost'],
|
|
202
|
+
color: 'danger',
|
|
203
|
+
className: 'accent-red-600'
|
|
249
204
|
}, {
|
|
250
|
-
variant: '
|
|
205
|
+
variant: ['outline', 'ghost'],
|
|
206
|
+
color: 'warning',
|
|
207
|
+
className: 'accent-amber-600'
|
|
208
|
+
}, {
|
|
209
|
+
variant: ['outline', 'ghost'],
|
|
251
210
|
color: 'success',
|
|
252
|
-
className: 'accent-green-
|
|
211
|
+
className: 'accent-green-600'
|
|
253
212
|
}, {
|
|
254
|
-
variant: '
|
|
255
|
-
color: '
|
|
256
|
-
className: 'accent-
|
|
213
|
+
variant: ['outline', 'ghost'],
|
|
214
|
+
color: 'info',
|
|
215
|
+
className: 'accent-sky-600'
|
|
216
|
+
},
|
|
217
|
+
// --- outline/ghost × color × mode: dark ---
|
|
218
|
+
{
|
|
219
|
+
variant: ['outline', 'ghost'],
|
|
220
|
+
color: 'action',
|
|
221
|
+
mode: 'dark',
|
|
222
|
+
className: 'accent-white'
|
|
257
223
|
}, {
|
|
258
224
|
variant: ['outline', 'ghost'],
|
|
259
|
-
color: '
|
|
260
|
-
|
|
225
|
+
color: 'danger',
|
|
226
|
+
mode: 'dark',
|
|
227
|
+
className: 'accent-red-300'
|
|
261
228
|
}, {
|
|
262
229
|
variant: ['outline', 'ghost'],
|
|
263
|
-
color: '
|
|
264
|
-
|
|
230
|
+
color: 'warning',
|
|
231
|
+
mode: 'dark',
|
|
232
|
+
className: 'accent-amber-300'
|
|
265
233
|
}, {
|
|
266
234
|
variant: ['outline', 'ghost'],
|
|
267
235
|
color: 'success',
|
|
268
|
-
|
|
236
|
+
mode: 'dark',
|
|
237
|
+
className: 'accent-green-300'
|
|
269
238
|
}, {
|
|
270
239
|
variant: ['outline', 'ghost'],
|
|
271
|
-
color: '
|
|
272
|
-
|
|
240
|
+
color: 'info',
|
|
241
|
+
mode: 'dark',
|
|
242
|
+
className: 'accent-sky-300'
|
|
273
243
|
}],
|
|
274
244
|
defaultVariants: {
|
|
275
|
-
variant: '
|
|
276
|
-
color: '
|
|
245
|
+
variant: 'strong',
|
|
246
|
+
color: 'action',
|
|
247
|
+
mode: 'light'
|
|
277
248
|
}
|
|
278
249
|
});
|
|
279
250
|
export const buttonGroupVariants = cva([], {
|
|
@@ -306,4 +277,15 @@ export const buttonGroupVariants = cva([], {
|
|
|
306
277
|
isAttached: false
|
|
307
278
|
}
|
|
308
279
|
});
|
|
280
|
+
export const buttonIconVariants = cva([], {
|
|
281
|
+
variants: {
|
|
282
|
+
size: {
|
|
283
|
+
default: 'size-5',
|
|
284
|
+
small: 'size-4'
|
|
285
|
+
}
|
|
286
|
+
},
|
|
287
|
+
defaultVariants: {
|
|
288
|
+
size: 'default'
|
|
289
|
+
}
|
|
290
|
+
});
|
|
309
291
|
//# sourceMappingURL=styles.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["Platform","cva","
|
|
1
|
+
{"version":3,"names":["Platform","cva","COLOR_BORDER_DEFAULT","DISABLED_CURSOR","DISABLED_OPACITY","RADIUS_SM","TRANSITION_COLORS","sharedFilledForegroundTextCompounds","sharedFilledSurfaceCompounds","sharedGhostSurfaceCompounds","sharedOutlineGhostForegroundTextCompounds","buttonStrongSurfaceCompounds","map","c","variant","buttonGhostSurfaceCompounds","buttonStrongForegroundTextCompounds","buttonOutlineGhostForegroundTextCompounds","buttonRootVariants","variants","strong","outline","ghost","color","action","danger","warning","success","info","size","default","small","mode","light","dark","fullWidth","true","false","compoundVariants","className","select","web","defaultVariants","buttonTextVariants","buttonSpinnerVariants","buttonGroupVariants","flexDirection","row","column","isAttached","buttonIconVariants"],"sourceRoot":"../../../../src","sources":["components/Button/styles.ts"],"mappings":";;AAAA,SAASA,QAAQ,QAAQ,cAAc;AACvC,SAASC,GAAG,QAA2B,0BAA0B;AACjE,SACEC,oBAAoB,EACpBC,eAAe,EACfC,gBAAgB,EAChBC,SAAS,EACTC,iBAAiB,QACZ,yBAAyB;AAChC,SACEC,mCAAmC,EACnCC,4BAA4B,EAC5BC,2BAA2B,EAC3BC,yCAAyC,QACpC,wBAAwB;AAE/B,MAAMC,4BAA4B,GAAGH,4BAA4B,CAACI,GAAG,CAAEC,CAAC,KAAM;EAC5EC,OAAO,EAAE,QAAiB;EAC1B,GA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AAE/C,QAAQ,CAACwC,MAAM,CAAC;QAAEC,GAAG,EAAE,UAAU;QAAEX,OAAO,EAAE;MAAG,CAAC,CAAC;MACtDkB,MAAM,EAAEhD,QAAQ,CAACwC,MAAM,CAAC;QAAEC,GAAG,EAAE,UAAU;QAAEX,OAAO,EAAE;MAAG,CAAC,CAAC;MACzD,aAAa,EAAE9B,QAAQ,CAACwC,MAAM,CAAC;QAAEC,GAAG,EAAE,kBAAkB;QAAEX,OAAO,EAAE;MAAG,CAAC,CAAC;MACxE,gBAAgB,EAAE9B,QAAQ,CAACwC,MAAM,CAAC;QAAEC,GAAG,EAAE,kBAAkB;QAAEX,OAAO,EAAE;MAAG,CAAC;IAC5E,CAAC;IACDmB,UAAU,EAAE;MACVb,IAAI,EAAE,OAAO;MACbC,KAAK,EAAE;IACT;EACF,CAAC;EACDK,eAAe,EAAE;IACfI,aAAa,EAAE,KAAK;IACpBG,UAAU,EAAE;EACd;AACF,CAAC,CAAC;AAEF,OAAO,MAAMC,kBAAkB,GAAGjD,GAAG,CAAC,EAAE,EAAE;EACxCkB,QAAQ,EAAE;IACRU,IAAI,EAAE;MACJC,OAAO,EAAE,QAAQ;MACjBC,KAAK,EAAE;IACT;EACF,CAAC;EACDW,eAAe,EAAE;IACfb,IAAI,EAAE;EACR;AACF,CAAC,CAAC","ignoreList":[]}
|
|
@@ -0,0 +1,100 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
|
|
3
|
+
import { forwardRef } from 'react';
|
|
4
|
+
import { View } from 'react-native';
|
|
5
|
+
import { cn } from '@cdx-ui/utils';
|
|
6
|
+
import { cardContentVariants, cardFooterVariants, cardHeaderVariants, cardRootVariants } from './styles';
|
|
7
|
+
|
|
8
|
+
// =============================================================================
|
|
9
|
+
// STYLED ROOT COMPONENT
|
|
10
|
+
// =============================================================================
|
|
11
|
+
import { jsx as _jsx } from "react/jsx-runtime";
|
|
12
|
+
const CardRoot = /*#__PURE__*/forwardRef(({
|
|
13
|
+
className,
|
|
14
|
+
children,
|
|
15
|
+
style,
|
|
16
|
+
...props
|
|
17
|
+
}, ref) => {
|
|
18
|
+
const computedClassName = cn(cardRootVariants(), className);
|
|
19
|
+
return /*#__PURE__*/_jsx(View, {
|
|
20
|
+
ref: ref,
|
|
21
|
+
className: computedClassName,
|
|
22
|
+
style: style,
|
|
23
|
+
...props,
|
|
24
|
+
children: children
|
|
25
|
+
});
|
|
26
|
+
});
|
|
27
|
+
CardRoot.displayName = 'Card';
|
|
28
|
+
|
|
29
|
+
// =============================================================================
|
|
30
|
+
// STYLED HEADER COMPONENT
|
|
31
|
+
// =============================================================================
|
|
32
|
+
|
|
33
|
+
const CardHeader = /*#__PURE__*/forwardRef(({
|
|
34
|
+
className,
|
|
35
|
+
children,
|
|
36
|
+
style,
|
|
37
|
+
...props
|
|
38
|
+
}, ref) => {
|
|
39
|
+
const computedClassName = cn(cardHeaderVariants(), className);
|
|
40
|
+
return /*#__PURE__*/_jsx(View, {
|
|
41
|
+
ref: ref,
|
|
42
|
+
className: computedClassName,
|
|
43
|
+
style: style,
|
|
44
|
+
...props,
|
|
45
|
+
children: children
|
|
46
|
+
});
|
|
47
|
+
});
|
|
48
|
+
CardHeader.displayName = 'Card.Header';
|
|
49
|
+
|
|
50
|
+
// =============================================================================
|
|
51
|
+
// STYLED CONTENT COMPONENT
|
|
52
|
+
// =============================================================================
|
|
53
|
+
|
|
54
|
+
const CardContent = /*#__PURE__*/forwardRef(({
|
|
55
|
+
className,
|
|
56
|
+
children,
|
|
57
|
+
style,
|
|
58
|
+
...props
|
|
59
|
+
}, ref) => {
|
|
60
|
+
const computedClassName = cn(cardContentVariants(), className);
|
|
61
|
+
return /*#__PURE__*/_jsx(View, {
|
|
62
|
+
ref: ref,
|
|
63
|
+
className: computedClassName,
|
|
64
|
+
style: style,
|
|
65
|
+
...props,
|
|
66
|
+
children: children
|
|
67
|
+
});
|
|
68
|
+
});
|
|
69
|
+
CardContent.displayName = 'Card.Content';
|
|
70
|
+
|
|
71
|
+
// =============================================================================
|
|
72
|
+
// STYLED FOOTER COMPONENT
|
|
73
|
+
// =============================================================================
|
|
74
|
+
|
|
75
|
+
const CardFooter = /*#__PURE__*/forwardRef(({
|
|
76
|
+
className,
|
|
77
|
+
children,
|
|
78
|
+
style,
|
|
79
|
+
...props
|
|
80
|
+
}, ref) => {
|
|
81
|
+
const computedClassName = cn(cardFooterVariants(), className);
|
|
82
|
+
return /*#__PURE__*/_jsx(View, {
|
|
83
|
+
ref: ref,
|
|
84
|
+
className: computedClassName,
|
|
85
|
+
style: style,
|
|
86
|
+
...props,
|
|
87
|
+
children: children
|
|
88
|
+
});
|
|
89
|
+
});
|
|
90
|
+
CardFooter.displayName = 'Card.Footer';
|
|
91
|
+
|
|
92
|
+
// =============================================================================
|
|
93
|
+
// COMPOUND COMPONENT
|
|
94
|
+
// =============================================================================
|
|
95
|
+
|
|
96
|
+
export const Card = CardRoot;
|
|
97
|
+
Card.Header = CardHeader;
|
|
98
|
+
Card.Content = CardContent;
|
|
99
|
+
Card.Footer = CardFooter;
|
|
100
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"names":["forwardRef","View","cn","cardContentVariants","cardFooterVariants","cardHeaderVariants","cardRootVariants","jsx","_jsx","CardRoot","className","children","style","props","ref","computedClassName","displayName","CardHeader","CardContent","CardFooter","Card","Header","Content","Footer"],"sourceRoot":"../../../../src","sources":["components/Card/index.tsx"],"mappings":";;AAAA,SAASA,UAAU,QAAwB,OAAO;AAClD,SAASC,IAAI,QAAwB,cAAc;AACnD,SAASC,EAAE,QAAQ,eAAe;AAClC,SACEC,mBAAmB,EACnBC,kBAAkB,EAClBC,kBAAkB,EAClBC,gBAAgB,QACX,UAAU;;AAEjB;AACA;AACA;AAAA,SAAAC,GAAA,IAAAC,IAAA;AAOA,MAAMC,QAAQ,gBAAGT,UAAU,CAAkB,CAAC;EAAEU,SAAS;EAAEC,QAAQ;EAAEC,KAAK;EAAE,GAA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