@zentauri-ui/zentauri-components 1.6.3 → 1.7.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +40 -6
- package/cli/cli.integration.test.ts +8 -0
- package/cli/index.mjs +47 -1
- package/cli/registry.json +2 -0
- package/dist/charts/area.js +11 -10
- package/dist/charts/area.js.map +1 -1
- package/dist/charts/area.mjs +4 -3
- package/dist/charts/area.mjs.map +1 -1
- package/dist/charts/bar.js +10 -9
- package/dist/charts/bar.js.map +1 -1
- package/dist/charts/bar.mjs +4 -3
- package/dist/charts/bar.mjs.map +1 -1
- package/dist/charts/bubble.js +10 -9
- package/dist/charts/bubble.js.map +1 -1
- package/dist/charts/bubble.mjs +4 -3
- package/dist/charts/bubble.mjs.map +1 -1
- package/dist/charts/line.js +10 -9
- package/dist/charts/line.js.map +1 -1
- package/dist/charts/line.mjs +4 -3
- package/dist/charts/line.mjs.map +1 -1
- package/dist/charts/pie.js +6 -5
- package/dist/charts/pie.js.map +1 -1
- package/dist/charts/pie.mjs +3 -2
- package/dist/charts/pie.mjs.map +1 -1
- package/dist/charts/shared/chart-frame.d.ts.map +1 -1
- package/dist/{chunk-QSIJKHC5.mjs → chunk-4XVNQ7IY.mjs} +223 -214
- package/dist/chunk-4XVNQ7IY.mjs.map +1 -0
- package/dist/chunk-4ZKBLVQX.js +248 -0
- package/dist/chunk-4ZKBLVQX.js.map +1 -0
- package/dist/chunk-6QQUQLPB.js +107 -0
- package/dist/chunk-6QQUQLPB.js.map +1 -0
- package/dist/chunk-ABOZ5QIX.js +84 -0
- package/dist/chunk-ABOZ5QIX.js.map +1 -0
- package/dist/chunk-ACGVDY5J.mjs +220 -0
- package/dist/chunk-ACGVDY5J.mjs.map +1 -0
- package/dist/{chunk-PPVJ4INP.mjs → chunk-ASJQP53L.mjs} +3 -3
- package/dist/{chunk-PPVJ4INP.mjs.map → chunk-ASJQP53L.mjs.map} +1 -1
- package/dist/{chunk-D55YIHBN.js → chunk-BTJYXKCW.js} +223 -214
- package/dist/chunk-BTJYXKCW.js.map +1 -0
- package/dist/{chunk-MM3P52WS.js → chunk-CL55KGDF.js} +56 -52
- package/dist/chunk-CL55KGDF.js.map +1 -0
- package/dist/chunk-CSFLMMAT.mjs +198 -0
- package/dist/chunk-CSFLMMAT.mjs.map +1 -0
- package/dist/chunk-EDARAO7X.js +206 -0
- package/dist/chunk-EDARAO7X.js.map +1 -0
- package/dist/chunk-EIRCCTNA.js +175 -0
- package/dist/chunk-EIRCCTNA.js.map +1 -0
- package/dist/chunk-EN4VLNBF.js +197 -0
- package/dist/chunk-EN4VLNBF.js.map +1 -0
- package/dist/chunk-FHLZH3PB.mjs +326 -0
- package/dist/chunk-FHLZH3PB.mjs.map +1 -0
- package/dist/chunk-FXYPRPAT.mjs +35 -0
- package/dist/chunk-FXYPRPAT.mjs.map +1 -0
- package/dist/{chunk-SPX2QDIB.mjs → chunk-G2WARVAM.mjs} +8 -4
- package/dist/chunk-G2WARVAM.mjs.map +1 -0
- package/dist/chunk-HCGSEPOD.mjs +196 -0
- package/dist/chunk-HCGSEPOD.mjs.map +1 -0
- package/dist/chunk-HDO5ZM2S.mjs +82 -0
- package/dist/chunk-HDO5ZM2S.mjs.map +1 -0
- package/dist/chunk-HMNIH3KJ.mjs +277 -0
- package/dist/chunk-HMNIH3KJ.mjs.map +1 -0
- package/dist/chunk-HNLQXHSQ.mjs +263 -0
- package/dist/chunk-HNLQXHSQ.mjs.map +1 -0
- package/dist/{chunk-M6FS7X54.mjs → chunk-ITVMSCOJ.mjs} +56 -52
- package/dist/chunk-ITVMSCOJ.mjs.map +1 -0
- package/dist/chunk-K6IZANTI.mjs +80 -0
- package/dist/chunk-K6IZANTI.mjs.map +1 -0
- package/dist/chunk-K7TCW5PJ.js +338 -0
- package/dist/chunk-K7TCW5PJ.js.map +1 -0
- package/dist/chunk-KTGV76M3.mjs +325 -0
- package/dist/chunk-KTGV76M3.mjs.map +1 -0
- package/dist/chunk-MTTXLC2V.mjs +100 -0
- package/dist/chunk-MTTXLC2V.mjs.map +1 -0
- package/dist/{chunk-JOMSI4WH.js → chunk-NFEA5TN2.js} +52 -47
- package/dist/chunk-NFEA5TN2.js.map +1 -0
- package/dist/chunk-NHQ3S4Y6.mjs +282 -0
- package/dist/chunk-NHQ3S4Y6.mjs.map +1 -0
- package/dist/{chunk-OVTWPGMW.mjs → chunk-NMQAHUYA.mjs} +52 -47
- package/dist/chunk-NMQAHUYA.mjs.map +1 -0
- package/dist/{chunk-MWR5DIA5.mjs → chunk-OULU7OC4.mjs} +3 -3
- package/dist/{chunk-MWR5DIA5.mjs.map → chunk-OULU7OC4.mjs.map} +1 -1
- package/dist/chunk-OZHETX4J.mjs +169 -0
- package/dist/chunk-OZHETX4J.mjs.map +1 -0
- package/dist/chunk-OZMSE44N.mjs +235 -0
- package/dist/chunk-OZMSE44N.mjs.map +1 -0
- package/dist/chunk-P5WLYJ2C.mjs +272 -0
- package/dist/chunk-P5WLYJ2C.mjs.map +1 -0
- package/dist/chunk-PHEUJ4EF.js +84 -0
- package/dist/chunk-PHEUJ4EF.js.map +1 -0
- package/dist/chunk-PMWRJ2KS.mjs +192 -0
- package/dist/chunk-PMWRJ2KS.mjs.map +1 -0
- package/dist/chunk-PR4QXFJT.js +132 -0
- package/dist/chunk-PR4QXFJT.js.map +1 -0
- package/dist/chunk-QAJOE3HJ.js +281 -0
- package/dist/chunk-QAJOE3HJ.js.map +1 -0
- package/dist/chunk-QBPVJH4P.mjs +128 -0
- package/dist/chunk-QBPVJH4P.mjs.map +1 -0
- package/dist/{chunk-MTJRPLMG.js → chunk-QNUDODDX.js} +8 -4
- package/dist/chunk-QNUDODDX.js.map +1 -0
- package/dist/{chunk-DO2LEXUY.js → chunk-QQ6F4LZK.js} +5 -5
- package/dist/{chunk-DO2LEXUY.js.map → chunk-QQ6F4LZK.js.map} +1 -1
- package/dist/chunk-QXHS3HHZ.mjs +340 -0
- package/dist/chunk-QXHS3HHZ.mjs.map +1 -0
- package/dist/chunk-QYLTKBH7.js +338 -0
- package/dist/chunk-QYLTKBH7.js.map +1 -0
- package/dist/chunk-TTTYW3TR.js +207 -0
- package/dist/chunk-TTTYW3TR.js.map +1 -0
- package/dist/chunk-W3QRRWQX.js +37 -0
- package/dist/chunk-W3QRRWQX.js.map +1 -0
- package/dist/chunk-WPXQHWPV.js +232 -0
- package/dist/chunk-WPXQHWPV.js.map +1 -0
- package/dist/chunk-XRDVD2EN.js +288 -0
- package/dist/chunk-XRDVD2EN.js.map +1 -0
- package/dist/chunk-XYEMP4K7.js +273 -0
- package/dist/chunk-XYEMP4K7.js.map +1 -0
- package/dist/chunk-YAO62VH2.js +342 -0
- package/dist/chunk-YAO62VH2.js.map +1 -0
- package/dist/{chunk-PVTTWOYV.js → chunk-Z6S36PDD.js} +7 -7
- package/dist/{chunk-PVTTWOYV.js.map → chunk-Z6S36PDD.js.map} +1 -1
- package/dist/chunk-ZYKJC5HH.js +296 -0
- package/dist/chunk-ZYKJC5HH.js.map +1 -0
- package/dist/design-system/accordion.d.ts +70 -0
- package/dist/design-system/accordion.d.ts.map +1 -0
- package/dist/design-system/alert.d.ts +39 -0
- package/dist/design-system/alert.d.ts.map +1 -0
- package/dist/design-system/avatar.d.ts +36 -0
- package/dist/design-system/avatar.d.ts.map +1 -0
- package/dist/design-system/badge.d.ts +71 -0
- package/dist/design-system/badge.d.ts.map +1 -0
- package/dist/design-system/breadcrumb.d.ts +27 -0
- package/dist/design-system/breadcrumb.d.ts.map +1 -0
- package/dist/design-system/button.d.ts +48 -0
- package/dist/design-system/button.d.ts.map +1 -0
- package/dist/design-system/card.d.ts +65 -0
- package/dist/design-system/card.d.ts.map +1 -0
- package/dist/design-system/checkbox.d.ts +32 -0
- package/dist/design-system/checkbox.d.ts.map +1 -0
- package/dist/design-system/divider.d.ts +45 -0
- package/dist/design-system/divider.d.ts.map +1 -0
- package/dist/design-system/drawer.d.ts +67 -0
- package/dist/design-system/drawer.d.ts.map +1 -0
- package/dist/design-system/dropdown.d.ts +79 -0
- package/dist/design-system/dropdown.d.ts.map +1 -0
- package/dist/design-system/dynamic-stepper.d.ts +29 -0
- package/dist/design-system/dynamic-stepper.d.ts.map +1 -0
- package/dist/design-system/empty-state.d.ts +29 -0
- package/dist/design-system/empty-state.d.ts.map +1 -0
- package/dist/design-system/file-upload.d.ts +19 -0
- package/dist/design-system/file-upload.d.ts.map +1 -0
- package/dist/design-system/index.d.ts +32 -0
- package/dist/design-system/index.d.ts.map +1 -0
- package/dist/design-system/inputs.d.ts +31 -0
- package/dist/design-system/inputs.d.ts.map +1 -0
- package/dist/design-system/modal.d.ts +66 -0
- package/dist/design-system/modal.d.ts.map +1 -0
- package/dist/design-system/pagination.d.ts +65 -0
- package/dist/design-system/pagination.d.ts.map +1 -0
- package/dist/design-system/progress.d.ts +57 -0
- package/dist/design-system/progress.d.ts.map +1 -0
- package/dist/design-system/radio-group.d.ts +37 -0
- package/dist/design-system/radio-group.d.ts.map +1 -0
- package/dist/design-system/select.d.ts +92 -0
- package/dist/design-system/select.d.ts.map +1 -0
- package/dist/design-system/skeleton.d.ts +104 -0
- package/dist/design-system/skeleton.d.ts.map +1 -0
- package/dist/design-system/slider.d.ts +44 -0
- package/dist/design-system/slider.d.ts.map +1 -0
- package/dist/design-system/spinner.d.ts +39 -0
- package/dist/design-system/spinner.d.ts.map +1 -0
- package/dist/design-system/stepper.d.ts +42 -0
- package/dist/design-system/stepper.d.ts.map +1 -0
- package/dist/design-system/table.d.ts +77 -0
- package/dist/design-system/table.d.ts.map +1 -0
- package/dist/design-system/tabs.d.ts +49 -0
- package/dist/design-system/tabs.d.ts.map +1 -0
- package/dist/design-system/toast.d.ts +43 -0
- package/dist/design-system/toast.d.ts.map +1 -0
- package/dist/design-system/toggle.d.ts +73 -0
- package/dist/design-system/toggle.d.ts.map +1 -0
- package/dist/design-system/tokens.d.ts +15 -0
- package/dist/design-system/tokens.d.ts.map +1 -0
- package/dist/design-system/tooltip.d.ts +41 -0
- package/dist/design-system/tooltip.d.ts.map +1 -0
- package/dist/design-system/typography.d.ts +42 -0
- package/dist/design-system/typography.d.ts.map +1 -0
- package/dist/hooks/useResizeObserver.js +6 -31
- package/dist/hooks/useResizeObserver.js.map +1 -1
- package/dist/hooks/useResizeObserver.mjs +1 -33
- package/dist/hooks/useResizeObserver.mjs.map +1 -1
- package/dist/ui/accordion/animated.js +7 -7
- package/dist/ui/accordion/animated.mjs +2 -2
- package/dist/ui/accordion/variants.d.ts +5 -5
- package/dist/ui/accordion/variants.d.ts.map +1 -1
- package/dist/ui/accordion.js +9 -9
- package/dist/ui/accordion.mjs +2 -2
- package/dist/ui/alert/animated.js +2 -2
- package/dist/ui/alert/animated.mjs +1 -1
- package/dist/ui/alert/variants.d.ts +4 -4
- package/dist/ui/alert/variants.d.ts.map +1 -1
- package/dist/ui/alert.js +10 -10
- package/dist/ui/alert.mjs +2 -2
- package/dist/ui/avatar/animated.js +5 -5
- package/dist/ui/avatar/animated.mjs +2 -2
- package/dist/ui/avatar/variants.d.ts +1 -1
- package/dist/ui/avatar/variants.d.ts.map +1 -1
- package/dist/ui/avatar.js +9 -9
- package/dist/ui/avatar.mjs +2 -2
- package/dist/ui/badge/animated.js +2 -2
- package/dist/ui/badge/animated.mjs +1 -1
- package/dist/ui/badge/variants.d.ts +29 -32
- package/dist/ui/badge/variants.d.ts.map +1 -1
- package/dist/ui/badge.js +4 -4
- package/dist/ui/badge.mjs +2 -2
- package/dist/ui/breadcrumb/variants.d.ts +1 -1
- package/dist/ui/breadcrumb/variants.d.ts.map +1 -1
- package/dist/ui/breadcrumb.js +42 -40
- package/dist/ui/breadcrumb.js.map +1 -1
- package/dist/ui/breadcrumb.mjs +42 -40
- package/dist/ui/breadcrumb.mjs.map +1 -1
- package/dist/ui/buttons/animated.js +3 -3
- package/dist/ui/buttons/animated.mjs +1 -1
- package/dist/ui/buttons/variants.d.ts +2 -2
- package/dist/ui/buttons/variants.d.ts.map +1 -1
- package/dist/ui/buttons.js +4 -4
- package/dist/ui/buttons.mjs +2 -2
- package/dist/ui/card/animated.js +7 -7
- package/dist/ui/card/animated.mjs +2 -2
- package/dist/ui/card/variants.d.ts +7 -7
- package/dist/ui/card/variants.d.ts.map +1 -1
- package/dist/ui/card.js +12 -12
- package/dist/ui/card.mjs +2 -2
- package/dist/ui/checkbox/animated/animations.d.ts +32 -0
- package/dist/ui/checkbox/animated/animations.d.ts.map +1 -0
- package/dist/ui/checkbox/animated/checkbox-animated.d.ts +6 -0
- package/dist/ui/checkbox/animated/checkbox-animated.d.ts.map +1 -0
- package/dist/ui/checkbox/animated/index.d.ts +4 -0
- package/dist/ui/checkbox/animated/index.d.ts.map +1 -0
- package/dist/ui/checkbox/animated/types.d.ts +8 -0
- package/dist/ui/checkbox/animated/types.d.ts.map +1 -0
- package/dist/ui/checkbox/animated.js +153 -0
- package/dist/ui/checkbox/animated.js.map +1 -0
- package/dist/ui/checkbox/animated.mjs +150 -0
- package/dist/ui/checkbox/animated.mjs.map +1 -0
- package/dist/ui/checkbox/checkbox-base.d.ts +6 -0
- package/dist/ui/checkbox/checkbox-base.d.ts.map +1 -0
- package/dist/ui/checkbox/checkbox.d.ts +6 -0
- package/dist/ui/checkbox/checkbox.d.ts.map +1 -0
- package/dist/ui/checkbox/index.d.ts +4 -0
- package/dist/ui/checkbox/index.d.ts.map +1 -0
- package/dist/ui/checkbox/types.d.ts +19 -0
- package/dist/ui/checkbox/types.d.ts.map +1 -0
- package/dist/ui/checkbox/variants.d.ts +11 -0
- package/dist/ui/checkbox/variants.d.ts.map +1 -0
- package/dist/ui/checkbox.js +150 -0
- package/dist/ui/checkbox.js.map +1 -0
- package/dist/ui/checkbox.mjs +137 -0
- package/dist/ui/checkbox.mjs.map +1 -0
- package/dist/ui/divider/animated.js +2 -2
- package/dist/ui/divider/animated.mjs +1 -1
- package/dist/ui/divider/variants.d.ts +4 -4
- package/dist/ui/divider/variants.d.ts.map +1 -1
- package/dist/ui/divider.js +6 -6
- package/dist/ui/divider.mjs +2 -2
- package/dist/ui/drawer/animated.js +11 -11
- package/dist/ui/drawer/animated.mjs +2 -2
- package/dist/ui/drawer/variants.d.ts +1 -1
- package/dist/ui/drawer/variants.d.ts.map +1 -1
- package/dist/ui/drawer.js +11 -11
- package/dist/ui/drawer.mjs +1 -1
- package/dist/ui/dropdown/variants.d.ts +4 -4
- package/dist/ui/dropdown/variants.d.ts.map +1 -1
- package/dist/ui/dropdown.js +106 -104
- package/dist/ui/dropdown.js.map +1 -1
- package/dist/ui/dropdown.mjs +106 -104
- package/dist/ui/dropdown.mjs.map +1 -1
- package/dist/ui/dynamic-stepper/variants.d.ts +5 -9
- package/dist/ui/dynamic-stepper/variants.d.ts.map +1 -1
- package/dist/ui/dynamic-stepper.js +100 -93
- package/dist/ui/dynamic-stepper.js.map +1 -1
- package/dist/ui/dynamic-stepper.mjs +98 -91
- package/dist/ui/dynamic-stepper.mjs.map +1 -1
- package/dist/ui/empty-state/animated.js +2 -2
- package/dist/ui/empty-state/animated.mjs +1 -1
- package/dist/ui/empty-state/variants.d.ts +3 -3
- package/dist/ui/empty-state/variants.d.ts.map +1 -1
- package/dist/ui/empty-state.js +10 -10
- package/dist/ui/empty-state.mjs +2 -2
- package/dist/ui/file-upload/variants.d.ts.map +1 -1
- package/dist/ui/file-upload.js +28 -26
- package/dist/ui/file-upload.js.map +1 -1
- package/dist/ui/file-upload.mjs +28 -26
- package/dist/ui/file-upload.mjs.map +1 -1
- package/dist/ui/inputs/animated.js +3 -3
- package/dist/ui/inputs/animated.mjs +1 -1
- package/dist/ui/inputs/variants.d.ts +1 -1
- package/dist/ui/inputs/variants.d.ts.map +1 -1
- package/dist/ui/inputs.js +4 -4
- package/dist/ui/inputs.mjs +2 -2
- package/dist/ui/modal/animated.js +4 -4
- package/dist/ui/modal/animated.mjs +1 -1
- package/dist/ui/modal/variants.d.ts +1 -1
- package/dist/ui/modal/variants.d.ts.map +1 -1
- package/dist/ui/modal.js +12 -12
- package/dist/ui/modal.mjs +2 -2
- package/dist/ui/pagination/variants.d.ts +3 -7
- package/dist/ui/pagination/variants.d.ts.map +1 -1
- package/dist/ui/pagination.js +84 -84
- package/dist/ui/pagination.js.map +1 -1
- package/dist/ui/pagination.mjs +81 -81
- package/dist/ui/pagination.mjs.map +1 -1
- package/dist/ui/progress/animated.js +8 -8
- package/dist/ui/progress/animated.mjs +2 -2
- package/dist/ui/progress/variants.d.ts +3 -3
- package/dist/ui/progress/variants.d.ts.map +1 -1
- package/dist/ui/progress.js +9 -9
- package/dist/ui/progress.mjs +2 -2
- package/dist/ui/radio-group/animated/animations.d.ts +32 -0
- package/dist/ui/radio-group/animated/animations.d.ts.map +1 -0
- package/dist/ui/radio-group/animated/index.d.ts +4 -0
- package/dist/ui/radio-group/animated/index.d.ts.map +1 -0
- package/dist/ui/radio-group/animated/radio-group-animated.d.ts +10 -0
- package/dist/ui/radio-group/animated/radio-group-animated.d.ts.map +1 -0
- package/dist/ui/radio-group/animated/types.d.ts +11 -0
- package/dist/ui/radio-group/animated/types.d.ts.map +1 -0
- package/dist/ui/radio-group/animated.js +177 -0
- package/dist/ui/radio-group/animated.js.map +1 -0
- package/dist/ui/radio-group/animated.mjs +173 -0
- package/dist/ui/radio-group/animated.mjs.map +1 -0
- package/dist/ui/radio-group/index.d.ts +4 -0
- package/dist/ui/radio-group/index.d.ts.map +1 -0
- package/dist/ui/radio-group/radio-group-context.d.ts +13 -0
- package/dist/ui/radio-group/radio-group-context.d.ts.map +1 -0
- package/dist/ui/radio-group/radio-group.d.ts +10 -0
- package/dist/ui/radio-group/radio-group.d.ts.map +1 -0
- package/dist/ui/radio-group/types.d.ts +26 -0
- package/dist/ui/radio-group/types.d.ts.map +1 -0
- package/dist/ui/radio-group/variants.d.ts +14 -0
- package/dist/ui/radio-group/variants.d.ts.map +1 -0
- package/dist/ui/radio-group.js +171 -0
- package/dist/ui/radio-group.js.map +1 -0
- package/dist/ui/radio-group.mjs +153 -0
- package/dist/ui/radio-group.mjs.map +1 -0
- package/dist/ui/search.js +2 -2
- package/dist/ui/search.mjs +1 -1
- package/dist/ui/select/variants.d.ts +6 -6
- package/dist/ui/select/variants.d.ts.map +1 -1
- package/dist/ui/select.js +122 -123
- package/dist/ui/select.js.map +1 -1
- package/dist/ui/select.mjs +122 -123
- package/dist/ui/select.mjs.map +1 -1
- package/dist/ui/skeleton/animated.js +8 -8
- package/dist/ui/skeleton/animated.mjs +1 -1
- package/dist/ui/skeleton/variants.d.ts +5 -4
- package/dist/ui/skeleton/variants.d.ts.map +1 -1
- package/dist/ui/skeleton.js +9 -9
- package/dist/ui/skeleton.mjs +1 -1
- package/dist/ui/slider/variants.d.ts +3 -3
- package/dist/ui/slider/variants.d.ts.map +1 -1
- package/dist/ui/slider.js +69 -67
- package/dist/ui/slider.js.map +1 -1
- package/dist/ui/slider.mjs +69 -67
- package/dist/ui/slider.mjs.map +1 -1
- package/dist/ui/spinner/animated/variants.d.ts +2 -2
- package/dist/ui/spinner/animated/variants.d.ts.map +1 -1
- package/dist/ui/spinner/animated.js +44 -38
- package/dist/ui/spinner/animated.js.map +1 -1
- package/dist/ui/spinner/animated.mjs +44 -38
- package/dist/ui/spinner/animated.mjs.map +1 -1
- package/dist/ui/stepper/variants.d.ts +1 -1
- package/dist/ui/stepper/variants.d.ts.map +1 -1
- package/dist/ui/stepper.js +57 -50
- package/dist/ui/stepper.js.map +1 -1
- package/dist/ui/stepper.mjs +57 -50
- package/dist/ui/stepper.mjs.map +1 -1
- package/dist/ui/table/animated.js +8 -8
- package/dist/ui/table/animated.mjs +2 -2
- package/dist/ui/table/variants.d.ts +2 -2
- package/dist/ui/table/variants.d.ts.map +1 -1
- package/dist/ui/table.js +14 -14
- package/dist/ui/table.mjs +1 -1
- package/dist/ui/tabs/animated.js +2 -2
- package/dist/ui/tabs/animated.mjs +1 -1
- package/dist/ui/tabs/variants.d.ts +2 -2
- package/dist/ui/tabs/variants.d.ts.map +1 -1
- package/dist/ui/tabs.js +9 -9
- package/dist/ui/tabs.mjs +1 -1
- package/dist/ui/toast/animated.js +7 -7
- package/dist/ui/toast/animated.mjs +1 -1
- package/dist/ui/toast/variants.d.ts +3 -3
- package/dist/ui/toast/variants.d.ts.map +1 -1
- package/dist/ui/toast.js +12 -12
- package/dist/ui/toast.mjs +1 -1
- package/dist/ui/toggle/animated/toggle-animated.d.ts.map +1 -1
- package/dist/ui/toggle/animated.js +13 -6
- package/dist/ui/toggle/animated.js.map +1 -1
- package/dist/ui/toggle/animated.mjs +12 -5
- package/dist/ui/toggle/animated.mjs.map +1 -1
- package/dist/ui/toggle/toggle-base.d.ts +2 -0
- package/dist/ui/toggle/toggle-base.d.ts.map +1 -1
- package/dist/ui/toggle/variants.d.ts +4 -4
- package/dist/ui/toggle/variants.d.ts.map +1 -1
- package/dist/ui/toggle.js +5 -94
- package/dist/ui/toggle.js.map +1 -1
- package/dist/ui/toggle.mjs +4 -93
- package/dist/ui/toggle.mjs.map +1 -1
- package/dist/ui/tooltip/animated.js +3 -3
- package/dist/ui/tooltip/animated.mjs +1 -1
- package/dist/ui/tooltip/variants.d.ts +3 -3
- package/dist/ui/tooltip/variants.d.ts.map +1 -1
- package/dist/ui/tooltip.js +7 -7
- package/dist/ui/tooltip.mjs +1 -1
- package/dist/ui/typography/variants.d.ts +1 -3
- package/dist/ui/typography/variants.d.ts.map +1 -1
- package/dist/ui/typography.js +51 -41
- package/dist/ui/typography.js.map +1 -1
- package/dist/ui/typography.mjs +51 -41
- package/dist/ui/typography.mjs.map +1 -1
- package/package.json +2 -1
- package/src/charts/shared/chart-frame.tsx +19 -8
- package/src/design-system/accordion.ts +111 -0
- package/src/design-system/alert.ts +64 -0
- package/src/design-system/avatar.ts +61 -0
- package/src/design-system/badge.ts +85 -0
- package/src/design-system/breadcrumb.ts +45 -0
- package/src/design-system/button.ts +81 -0
- package/src/design-system/card.ts +104 -0
- package/src/design-system/checkbox.ts +47 -0
- package/src/design-system/divider.ts +73 -0
- package/src/design-system/drawer.ts +111 -0
- package/src/design-system/dropdown.ts +130 -0
- package/src/design-system/dynamic-stepper.ts +218 -0
- package/src/design-system/empty-state.ts +39 -0
- package/src/design-system/file-upload.ts +30 -0
- package/src/design-system/index.ts +31 -0
- package/src/design-system/inputs.ts +74 -0
- package/src/design-system/modal.ts +110 -0
- package/src/design-system/pagination.ts +92 -0
- package/src/design-system/progress.ts +86 -0
- package/src/design-system/radio-group.ts +54 -0
- package/src/design-system/select.ts +155 -0
- package/src/design-system/skeleton.ts +129 -0
- package/src/design-system/slider.ts +70 -0
- package/src/design-system/spinner.ts +59 -0
- package/src/design-system/stepper.ts +66 -0
- package/src/design-system/table.ts +115 -0
- package/src/design-system/tabs.ts +73 -0
- package/src/design-system/toast.ts +69 -0
- package/src/design-system/toggle.ts +120 -0
- package/src/design-system/tokens.ts +22 -0
- package/src/design-system/tooltip.ts +63 -0
- package/src/design-system/typography.ts +64 -0
- package/src/ui/accordion/variants.ts +24 -106
- package/src/ui/alert/alert.test.tsx +1 -1
- package/src/ui/alert/variants.ts +25 -77
- package/src/ui/avatar/variants.ts +21 -66
- package/src/ui/badge/badge.test.tsx +1 -1
- package/src/ui/badge/variants.ts +28 -89
- package/src/ui/breadcrumb/variants.ts +24 -40
- package/src/ui/buttons/button.test.tsx +25 -5
- package/src/ui/buttons/variants.ts +15 -84
- package/src/ui/card/card.test.tsx +1 -1
- package/src/ui/card/variants.ts +46 -121
- package/src/ui/checkbox/animated/animations.ts +12 -0
- package/src/ui/checkbox/animated/checkbox-animated.tsx +145 -0
- package/src/ui/checkbox/animated/index.ts +9 -0
- package/src/ui/checkbox/animated/types.ts +9 -0
- package/src/ui/checkbox/checkbox-base.tsx +134 -0
- package/src/ui/checkbox/checkbox.test.tsx +53 -0
- package/src/ui/checkbox/checkbox.tsx +8 -0
- package/src/ui/checkbox/index.ts +15 -0
- package/src/ui/checkbox/types.ts +40 -0
- package/src/ui/checkbox/variants.ts +50 -0
- package/src/ui/divider/variants.ts +32 -70
- package/src/ui/drawer/drawer-base.tsx +1 -1
- package/src/ui/drawer/variants.ts +41 -132
- package/src/ui/dropdown/variants.ts +36 -142
- package/src/ui/dynamic-stepper/variants.ts +32 -216
- package/src/ui/empty-state/variants.ts +29 -44
- package/src/ui/file-upload/variants.ts +12 -36
- package/src/ui/inputs/input.test.tsx +11 -11
- package/src/ui/inputs/variants.ts +308 -371
- package/src/ui/modal/variants.ts +29 -120
- package/src/ui/pagination/pagination.test.tsx +1 -1
- package/src/ui/pagination/variants.ts +22 -95
- package/src/ui/progress/variants.ts +41 -112
- package/src/ui/radio-group/animated/animations.ts +12 -0
- package/src/ui/radio-group/animated/index.ts +10 -0
- package/src/ui/radio-group/animated/radio-group-animated.tsx +173 -0
- package/src/ui/radio-group/animated/types.ts +13 -0
- package/src/ui/radio-group/index.ts +19 -0
- package/src/ui/radio-group/radio-group-context.ts +23 -0
- package/src/ui/radio-group/radio-group.test.tsx +61 -0
- package/src/ui/radio-group/radio-group.tsx +159 -0
- package/src/ui/radio-group/types.ts +62 -0
- package/src/ui/radio-group/variants.ts +61 -0
- package/src/ui/select/variants.ts +40 -165
- package/src/ui/skeleton/variants.ts +154 -250
- package/src/ui/slider/variants.ts +34 -67
- package/src/ui/spinner/animated/variants.ts +10 -39
- package/src/ui/stepper/stepper.test.tsx +12 -4
- package/src/ui/stepper/variants.ts +23 -68
- package/src/ui/table/variants.ts +36 -106
- package/src/ui/tabs/variants.ts +26 -73
- package/src/ui/toast/variants.ts +24 -75
- package/src/ui/toggle/animated/toggle-animated.tsx +14 -4
- package/src/ui/toggle/toggle-base.tsx +3 -7
- package/src/ui/toggle/variants.ts +27 -111
- package/src/ui/tooltip/variants.ts +18 -57
- package/src/ui/typography/typography.test.tsx +1 -1
- package/src/ui/typography/variants.ts +17 -54
- package/dist/chunk-25EAVVGS.mjs +0 -267
- package/dist/chunk-25EAVVGS.mjs.map +0 -1
- package/dist/chunk-4F56BLZQ.js +0 -336
- package/dist/chunk-4F56BLZQ.js.map +0 -1
- package/dist/chunk-4PZIDDC6.js +0 -279
- package/dist/chunk-4PZIDDC6.js.map +0 -1
- package/dist/chunk-73RHHGIA.mjs +0 -197
- package/dist/chunk-73RHHGIA.mjs.map +0 -1
- package/dist/chunk-746CV3AN.js +0 -246
- package/dist/chunk-746CV3AN.js.map +0 -1
- package/dist/chunk-CFTDAGKD.js +0 -130
- package/dist/chunk-CFTDAGKD.js.map +0 -1
- package/dist/chunk-CXNDE4VC.js +0 -273
- package/dist/chunk-CXNDE4VC.js.map +0 -1
- package/dist/chunk-D55YIHBN.js.map +0 -1
- package/dist/chunk-EU63V22F.mjs +0 -126
- package/dist/chunk-EU63V22F.mjs.map +0 -1
- package/dist/chunk-EZS47EZW.mjs +0 -70
- package/dist/chunk-EZS47EZW.mjs.map +0 -1
- package/dist/chunk-GHJN3Z3V.js +0 -292
- package/dist/chunk-GHJN3Z3V.js.map +0 -1
- package/dist/chunk-GIC3J6HR.mjs +0 -196
- package/dist/chunk-GIC3J6HR.mjs.map +0 -1
- package/dist/chunk-GPAUYUM3.js +0 -232
- package/dist/chunk-GPAUYUM3.js.map +0 -1
- package/dist/chunk-HARD4NMB.mjs +0 -268
- package/dist/chunk-HARD4NMB.mjs.map +0 -1
- package/dist/chunk-HV7LVRK3.js +0 -277
- package/dist/chunk-HV7LVRK3.js.map +0 -1
- package/dist/chunk-JE6B3DHW.mjs +0 -220
- package/dist/chunk-JE6B3DHW.mjs.map +0 -1
- package/dist/chunk-JOMSI4WH.js.map +0 -1
- package/dist/chunk-KA5MORDC.js +0 -336
- package/dist/chunk-KA5MORDC.js.map +0 -1
- package/dist/chunk-M6FS7X54.mjs.map +0 -1
- package/dist/chunk-MM3P52WS.js.map +0 -1
- package/dist/chunk-MTJRPLMG.js.map +0 -1
- package/dist/chunk-OB6TYS5Q.js +0 -205
- package/dist/chunk-OB6TYS5Q.js.map +0 -1
- package/dist/chunk-OHST7AHC.mjs +0 -99
- package/dist/chunk-OHST7AHC.mjs.map +0 -1
- package/dist/chunk-OVTWPGMW.mjs.map +0 -1
- package/dist/chunk-OZ4SFJ3S.mjs +0 -264
- package/dist/chunk-OZ4SFJ3S.mjs.map +0 -1
- package/dist/chunk-PSIAOIXJ.mjs +0 -278
- package/dist/chunk-PSIAOIXJ.mjs.map +0 -1
- package/dist/chunk-QNF4JPFP.js +0 -339
- package/dist/chunk-QNF4JPFP.js.map +0 -1
- package/dist/chunk-QSIJKHC5.mjs.map +0 -1
- package/dist/chunk-QWC2QBRJ.js +0 -175
- package/dist/chunk-QWC2QBRJ.js.map +0 -1
- package/dist/chunk-RFFGQYDQ.mjs +0 -337
- package/dist/chunk-RFFGQYDQ.mjs.map +0 -1
- package/dist/chunk-S5H2OMTZ.mjs +0 -233
- package/dist/chunk-S5H2OMTZ.mjs.map +0 -1
- package/dist/chunk-SPX2QDIB.mjs.map +0 -1
- package/dist/chunk-TIPNRH26.js +0 -102
- package/dist/chunk-TIPNRH26.js.map +0 -1
- package/dist/chunk-V2PEOBAT.mjs +0 -324
- package/dist/chunk-V2PEOBAT.mjs.map +0 -1
- package/dist/chunk-V3XNH7Y4.mjs +0 -169
- package/dist/chunk-V3XNH7Y4.mjs.map +0 -1
- package/dist/chunk-VGWA26BN.js +0 -72
- package/dist/chunk-VGWA26BN.js.map +0 -1
- package/dist/chunk-WNLDXBS6.mjs +0 -323
- package/dist/chunk-WNLDXBS6.mjs.map +0 -1
- package/dist/chunk-YIO7DFUA.js +0 -207
- package/dist/chunk-YIO7DFUA.js.map +0 -1
package/src/ui/modal/variants.ts
CHANGED
|
@@ -1,126 +1,35 @@
|
|
|
1
1
|
import { cva } from "class-variance-authority";
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
3
|
+
import {
|
|
4
|
+
zuiModalContentAppearances,
|
|
5
|
+
zuiModalContentBase,
|
|
6
|
+
zuiModalContentPositions,
|
|
7
|
+
zuiModalContentSizes,
|
|
8
|
+
zuiModalOverlayBase,
|
|
9
|
+
zuiModalTriggerAppearances,
|
|
10
|
+
zuiModalTriggerBase,
|
|
11
|
+
} from "../../design-system/modal";
|
|
6
12
|
|
|
7
|
-
export const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
"border-black/15 dark:border-white/15 bg-slate-50/70 dark:bg-slate-950/70 backdrop-blur-xl text-slate-900 dark:text-slate-50",
|
|
16
|
-
sky: "border-sky-800 dark:border-sky-600 bg-sky-50 dark:bg-sky-950/70 backdrop-blur-xl text-sky-800 dark:text-sky-50",
|
|
17
|
-
rose: "border-rose-800 dark:border-rose-600 bg-rose-50 dark:bg-rose-950/70 backdrop-blur-xl text-rose-800 dark:text-rose-50",
|
|
18
|
-
purple:
|
|
19
|
-
"border-purple-800 dark:border-purple-600 bg-purple-50 dark:bg-purple-950/70 backdrop-blur-xl text-purple-800 dark:text-purple-50",
|
|
20
|
-
pink: "border-pink-800 dark:border-pink-600 bg-pink-50 dark:bg-pink-950/70 backdrop-blur-xl text-pink-800 dark:text-pink-50",
|
|
21
|
-
orange:
|
|
22
|
-
"border-orange-800 dark:border-orange-600 bg-orange-50 dark:bg-orange-950/70 backdrop-blur-xl text-orange-800 dark:text-orange-50",
|
|
23
|
-
yellow:
|
|
24
|
-
"border-yellow-800 dark:border-yellow-600 bg-yellow-50 dark:bg-yellow-950/70 backdrop-blur-xl text-yellow-800 dark:text-yellow-50",
|
|
25
|
-
teal: "border-teal-800 dark:border-teal-600 bg-teal-50 dark:bg-teal-950/70 backdrop-blur-xl text-teal-800 dark:text-teal-50",
|
|
26
|
-
indigo:
|
|
27
|
-
"border-indigo-800 dark:border-indigo-600 bg-indigo-50 dark:bg-indigo-950/70 backdrop-blur-xl text-indigo-800 dark:text-indigo-50",
|
|
28
|
-
emerald:
|
|
29
|
-
"border-emerald-800 dark:border-emerald-600 bg-emerald-50 dark:bg-emerald-950/70 backdrop-blur-xl text-emerald-800 dark:text-emerald-50",
|
|
30
|
-
gray: "border-gray-800 dark:border-gray-600 bg-gray-50 dark:bg-gray-950/70 backdrop-blur-xl text-gray-800 dark:text-gray-50",
|
|
31
|
-
amber:
|
|
32
|
-
"border-amber-800 dark:border-amber-600 bg-amber-50 dark:bg-amber-950/70 backdrop-blur-xl text-amber-800 dark:text-amber-50",
|
|
33
|
-
violet:
|
|
34
|
-
"border-violet-800 dark:border-violet-600 bg-violet-50 dark:bg-violet-950/70 backdrop-blur-xl text-violet-800 dark:text-violet-50",
|
|
35
|
-
"gradient-blue":
|
|
36
|
-
"border-blue-800 dark:border-blue-600 bg-linear-to-r from-blue-50 dark:from-blue-950/70 to-purple-50 dark:to-purple-950/70 backdrop-blur-xl text-blue-800 dark:text-blue-50",
|
|
37
|
-
"gradient-green":
|
|
38
|
-
"border-green-800 dark:border-green-600 bg-linear-to-r from-green-50 dark:from-green-950/70 to-lime-50 dark:to-lime-950/70 backdrop-blur-xl text-green-800 dark:text-green-50",
|
|
39
|
-
"gradient-red":
|
|
40
|
-
"border-red-800 dark:border-red-600 bg-linear-to-r from-red-50 dark:from-red-950/70 to-pink-50 dark:to-pink-950/70 backdrop-blur-xl text-red-800 dark:text-red-50",
|
|
41
|
-
"gradient-yellow":
|
|
42
|
-
"border-yellow-800 dark:border-yellow-600 bg-linear-to-r from-yellow-50 dark:from-yellow-950/70 to-orange-50 dark:to-orange-950/70 backdrop-blur-xl text-yellow-800 dark:text-yellow-50",
|
|
43
|
-
"gradient-purple":
|
|
44
|
-
"border-purple-800 dark:border-purple-600 bg-linear-to-r from-purple-50 dark:from-purple-950/70 to-pink-50 dark:to-pink-950/70 backdrop-blur-xl text-purple-800 dark:text-purple-50",
|
|
45
|
-
"gradient-teal":
|
|
46
|
-
"border-teal-800 dark:border-teal-600 bg-linear-to-r from-teal-50 dark:from-teal-950/70 to-cyan-50 dark:to-cyan-950/70 backdrop-blur-xl text-teal-800 dark:text-teal-50",
|
|
47
|
-
"gradient-indigo":
|
|
48
|
-
"border-indigo-800 dark:border-indigo-600 bg-linear-to-r from-indigo-50 dark:from-indigo-950/70 to-purple-50 dark:to-purple-950/70 backdrop-blur-xl text-indigo-800 dark:text-indigo-50",
|
|
49
|
-
"gradient-pink":
|
|
50
|
-
"border-pink-800 dark:border-pink-600 bg-linear-to-r from-pink-50 dark:from-pink-950/70 to-rose-50 dark:to-rose-950/70 backdrop-blur-xl text-pink-800 dark:text-pink-50",
|
|
51
|
-
"gradient-orange":
|
|
52
|
-
"border-orange-800 dark:border-orange-600 bg-linear-to-r from-orange-50 dark:from-orange-950/70 to-red-50 dark:to-red-950/70 backdrop-blur-xl text-orange-800 dark:text-orange-50",
|
|
53
|
-
},
|
|
54
|
-
},
|
|
55
|
-
defaultVariants: {
|
|
56
|
-
appearance: "default",
|
|
57
|
-
},
|
|
13
|
+
export const modalOverlayVariants = cva(zuiModalOverlayBase);
|
|
14
|
+
|
|
15
|
+
export const modalTriggerVariants = cva(zuiModalTriggerBase, {
|
|
16
|
+
variants: {
|
|
17
|
+
appearance: zuiModalTriggerAppearances,
|
|
18
|
+
},
|
|
19
|
+
defaultVariants: {
|
|
20
|
+
appearance: "default",
|
|
58
21
|
},
|
|
59
|
-
);
|
|
22
|
+
});
|
|
60
23
|
|
|
61
|
-
export const modalContentVariants = cva(
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
},
|
|
72
|
-
position: {
|
|
73
|
-
center: "top-1/2 translate-y-[-50%]",
|
|
74
|
-
top: "top-10 translate-y-0",
|
|
75
|
-
bottom: "bottom-10 translate-y-0",
|
|
76
|
-
},
|
|
77
|
-
appearance: {
|
|
78
|
-
default: "bg-slate-50 dark:bg-slate-950",
|
|
79
|
-
glass:
|
|
80
|
-
"border-black/15 dark:border-white/15 bg-slate-50/70 dark:bg-slate-950/70 backdrop-blur-xl",
|
|
81
|
-
sky: "border-sky-800 dark:border-sky-600 bg-sky-50 dark:bg-sky-950/70 backdrop-blur-xl",
|
|
82
|
-
rose: "border-rose-800 dark:border-rose-600 bg-rose-50 dark:bg-rose-950/70 backdrop-blur-xl",
|
|
83
|
-
purple:
|
|
84
|
-
"border-purple-800 dark:border-purple-600 bg-purple-50 dark:bg-purple-950/70 backdrop-blur-xl",
|
|
85
|
-
pink: "border-pink-800 dark:border-pink-600 bg-pink-50 dark:bg-pink-950/70 backdrop-blur-xl",
|
|
86
|
-
orange:
|
|
87
|
-
"border-orange-800 dark:border-orange-600 bg-orange-50 dark:bg-orange-950/70 backdrop-blur-xl",
|
|
88
|
-
yellow:
|
|
89
|
-
"border-yellow-800 dark:border-yellow-600 bg-yellow-50 dark:bg-yellow-950/70 backdrop-blur-xl",
|
|
90
|
-
teal: "border-teal-800 dark:border-teal-600 bg-teal-50 dark:bg-teal-950/70 backdrop-blur-xl",
|
|
91
|
-
indigo:
|
|
92
|
-
"border-indigo-800 dark:border-indigo-600 bg-indigo-50 dark:bg-indigo-950/70 backdrop-blur-xl",
|
|
93
|
-
emerald:
|
|
94
|
-
"border-emerald-800 dark:border-emerald-600 bg-emerald-50 dark:bg-emerald-950/70 backdrop-blur-xl",
|
|
95
|
-
gray: "border-gray-800 dark:border-gray-600 bg-gray-50 dark:bg-gray-950/70 backdrop-blur-xl",
|
|
96
|
-
amber:
|
|
97
|
-
"border-amber-800 dark:border-amber-600 bg-amber-50 dark:bg-amber-950/70 backdrop-blur-xl",
|
|
98
|
-
violet:
|
|
99
|
-
"border-violet-800 dark:border-violet-600 bg-violet-50 dark:bg-violet-950/70 backdrop-blur-xl",
|
|
100
|
-
"gradient-blue":
|
|
101
|
-
"border-blue-800 dark:border-blue-600 bg-linear-to-r from-blue-50 dark:from-blue-950/70 to-purple-50 dark:to-purple-950/70 backdrop-blur-xl",
|
|
102
|
-
"gradient-green":
|
|
103
|
-
"border-green-800 dark:border-green-600 bg-linear-to-r from-green-50 dark:from-green-950/70 to-lime-50 dark:to-lime-950/70 backdrop-blur-xl",
|
|
104
|
-
"gradient-red":
|
|
105
|
-
"border-red-800 dark:border-red-600 bg-linear-to-r from-red-50 dark:from-red-950/70 to-pink-50 dark:to-pink-950/70 backdrop-blur-xl",
|
|
106
|
-
"gradient-yellow":
|
|
107
|
-
"border-yellow-800 dark:border-yellow-600 bg-linear-to-r from-yellow-50 dark:from-yellow-950/70 to-orange-50 dark:to-orange-950/70 backdrop-blur-xl",
|
|
108
|
-
"gradient-purple":
|
|
109
|
-
"border-purple-800 dark:border-purple-600 bg-linear-to-r from-purple-50 dark:from-purple-950/70 to-pink-50 dark:to-pink-950/70 backdrop-blur-xl",
|
|
110
|
-
"gradient-teal":
|
|
111
|
-
"border-teal-800 dark:border-teal-600 bg-linear-to-r from-teal-50 dark:from-teal-950/70 to-cyan-50 dark:to-cyan-950/70 backdrop-blur-xl",
|
|
112
|
-
"gradient-indigo":
|
|
113
|
-
"border-indigo-800 dark:border-indigo-600 bg-linear-to-r from-indigo-50 dark:from-indigo-950/70 to-purple-50 dark:to-purple-950/70 backdrop-blur-xl",
|
|
114
|
-
"gradient-pink":
|
|
115
|
-
"border-pink-800 dark:border-pink-600 bg-linear-to-r from-pink-50 dark:from-pink-950/70 to-rose-50 dark:to-rose-950/70 backdrop-blur-xl",
|
|
116
|
-
"gradient-orange":
|
|
117
|
-
"border-orange-800 dark:border-orange-600 bg-linear-to-r from-orange-50 dark:from-orange-950/70 to-red-50 dark:to-red-950/70 backdrop-blur-xl",
|
|
118
|
-
},
|
|
119
|
-
},
|
|
120
|
-
defaultVariants: {
|
|
121
|
-
size: "md",
|
|
122
|
-
position: "center",
|
|
123
|
-
appearance: "default",
|
|
124
|
-
},
|
|
24
|
+
export const modalContentVariants = cva(zuiModalContentBase, {
|
|
25
|
+
variants: {
|
|
26
|
+
size: zuiModalContentSizes,
|
|
27
|
+
position: zuiModalContentPositions,
|
|
28
|
+
appearance: zuiModalContentAppearances,
|
|
29
|
+
},
|
|
30
|
+
defaultVariants: {
|
|
31
|
+
size: "md",
|
|
32
|
+
position: "center",
|
|
33
|
+
appearance: "default",
|
|
125
34
|
},
|
|
126
|
-
);
|
|
35
|
+
});
|
|
@@ -147,7 +147,7 @@ describe("Pagination (component library)", () => {
|
|
|
147
147
|
it("should apply list variant classes for the selected appearance", () => {
|
|
148
148
|
render(<Pagination pageCount={3} page={1} appearance="emerald" />);
|
|
149
149
|
const list = document.querySelector('[data-slot="pagination-list"]');
|
|
150
|
-
expect(list?.className).toMatch(
|
|
150
|
+
expect(list?.className).toMatch(/--zui-pagination-list-emerald-border/);
|
|
151
151
|
});
|
|
152
152
|
|
|
153
153
|
it("should render anchors for page controls when getPageHref is provided", () => {
|
|
@@ -1,100 +1,27 @@
|
|
|
1
1
|
import { cva } from "class-variance-authority";
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
link: "border-transparent bg-transparent",
|
|
20
|
-
glass:
|
|
21
|
-
"border-black/15 dark:border-white/15 bg-black/5 dark:bg-white/5 backdrop-blur-md",
|
|
22
|
-
emerald: "border-emerald-500/25 bg-emerald-50 dark:bg-emerald-950/20",
|
|
23
|
-
indigo: "border-indigo-500/25 bg-indigo-50 dark:bg-indigo-950/20",
|
|
24
|
-
purple: "border-purple-500/25 bg-purple-50 dark:bg-purple-950/20",
|
|
25
|
-
pink: "border-pink-500/25 bg-pink-50 dark:bg-pink-950/20",
|
|
26
|
-
rose: "border-rose-500/25 bg-rose-50 dark:bg-rose-950/20",
|
|
27
|
-
sky: "border-sky-500/25 bg-sky-50 dark:bg-sky-950/20",
|
|
28
|
-
teal: "border-teal-500/25 bg-teal-50 dark:bg-teal-950/20",
|
|
29
|
-
yellow: "border-yellow-500/25 bg-yellow-50 dark:bg-yellow-950/20",
|
|
30
|
-
orange: "border-orange-500/25 bg-orange-50 dark:bg-orange-950/20",
|
|
31
|
-
gray: "border-gray-500/25 bg-gray-50 dark:bg-gray-950/20",
|
|
32
|
-
amber: "border-amber-500/25 bg-amber-50 dark:bg-amber-950/20",
|
|
33
|
-
violet: "border-violet-500/25 bg-violet-50 dark:bg-violet-950/20",
|
|
34
|
-
"gradient-blue":
|
|
35
|
-
"border-blue-500/30 bg-linear-to-r from-blue-50 dark:from-blue-950/30 to-purple-50 dark:to-purple-950/30",
|
|
36
|
-
"gradient-green":
|
|
37
|
-
"border-lime-500/30 bg-linear-to-r from-green-50 dark:from-green-950/30 to-lime-50 dark:to-lime-950/30",
|
|
38
|
-
"gradient-red":
|
|
39
|
-
"border-pink-500/30 bg-linear-to-r from-red-50 dark:from-red-950/30 to-pink-50 dark:to-pink-950/30",
|
|
40
|
-
"gradient-yellow":
|
|
41
|
-
"border-orange-500/30 bg-linear-to-r from-yellow-50 dark:from-yellow-950/30 to-orange-50 dark:to-orange-950/30",
|
|
42
|
-
"gradient-purple":
|
|
43
|
-
"border-pink-500/30 bg-linear-to-r from-purple-50 dark:from-purple-950/30 to-pink-50 dark:to-pink-950/30",
|
|
44
|
-
"gradient-teal":
|
|
45
|
-
"border-cyan-500/30 bg-linear-to-r from-teal-50 dark:from-teal-950/30 to-cyan-50 dark:to-cyan-950/30",
|
|
46
|
-
"gradient-indigo":
|
|
47
|
-
"border-purple-500/30 bg-linear-to-r from-indigo-50 dark:from-indigo-950/30 to-purple-50 dark:to-purple-950/30",
|
|
48
|
-
"gradient-pink":
|
|
49
|
-
"border-rose-500/30 bg-linear-to-r from-pink-50 dark:from-pink-950/30 to-rose-50 dark:to-rose-950/30",
|
|
50
|
-
"gradient-orange":
|
|
51
|
-
"border-orange-500/30 bg-linear-to-r from-orange-50 dark:from-orange-950/30 to-red-50 dark:to-red-950/30",
|
|
52
|
-
},
|
|
53
|
-
size: {
|
|
54
|
-
sm: "gap-0.5",
|
|
55
|
-
md: "gap-1",
|
|
56
|
-
lg: "gap-1",
|
|
57
|
-
xl: "gap-1.5",
|
|
58
|
-
"2xl": "gap-1.5",
|
|
59
|
-
"3xl": "gap-2",
|
|
60
|
-
"4xl": "gap-2",
|
|
61
|
-
"5xl": "gap-2",
|
|
62
|
-
"6xl": "gap-2",
|
|
63
|
-
"7xl": "gap-2.5",
|
|
64
|
-
"8xl": "gap-2.5",
|
|
65
|
-
"9xl": "gap-2.5",
|
|
66
|
-
"10xl": "gap-3",
|
|
67
|
-
icon: "gap-1",
|
|
68
|
-
},
|
|
69
|
-
},
|
|
70
|
-
defaultVariants: {
|
|
71
|
-
appearance: "default",
|
|
72
|
-
size: "md",
|
|
73
|
-
},
|
|
3
|
+
import {
|
|
4
|
+
zuiPaginationEllipsisBase,
|
|
5
|
+
zuiPaginationEllipsisSizes,
|
|
6
|
+
zuiPaginationListAppearances,
|
|
7
|
+
zuiPaginationListBase,
|
|
8
|
+
zuiPaginationListSizes,
|
|
9
|
+
} from "../../design-system/pagination";
|
|
10
|
+
|
|
11
|
+
export const paginationListVariants = cva(zuiPaginationListBase, {
|
|
12
|
+
variants: {
|
|
13
|
+
appearance: zuiPaginationListAppearances,
|
|
14
|
+
size: zuiPaginationListSizes,
|
|
15
|
+
},
|
|
16
|
+
defaultVariants: {
|
|
17
|
+
appearance: "default",
|
|
18
|
+
size: "md",
|
|
74
19
|
},
|
|
75
|
-
);
|
|
20
|
+
});
|
|
76
21
|
|
|
77
|
-
export const paginationEllipsisVariants = cva(
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
variants: {
|
|
81
|
-
size: {
|
|
82
|
-
sm: "text-xs",
|
|
83
|
-
md: "text-sm",
|
|
84
|
-
lg: "text-base",
|
|
85
|
-
xl: "text-base",
|
|
86
|
-
"2xl": "text-lg",
|
|
87
|
-
"3xl": "text-lg",
|
|
88
|
-
"4xl": "text-xl",
|
|
89
|
-
"5xl": "text-xl",
|
|
90
|
-
"6xl": "text-xl",
|
|
91
|
-
"7xl": "text-2xl",
|
|
92
|
-
"8xl": "text-2xl",
|
|
93
|
-
"9xl": "text-2xl",
|
|
94
|
-
"10xl": "text-2xl",
|
|
95
|
-
icon: "text-sm",
|
|
96
|
-
},
|
|
97
|
-
},
|
|
98
|
-
defaultVariants: { size: "md" },
|
|
22
|
+
export const paginationEllipsisVariants = cva(zuiPaginationEllipsisBase, {
|
|
23
|
+
variants: {
|
|
24
|
+
size: zuiPaginationEllipsisSizes,
|
|
99
25
|
},
|
|
100
|
-
|
|
26
|
+
defaultVariants: { size: "md" },
|
|
27
|
+
});
|
|
@@ -1,119 +1,48 @@
|
|
|
1
1
|
import { cva } from "class-variance-authority";
|
|
2
2
|
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
"[--progress-fill:theme(colors.cyan.700)] dark:[--progress-fill:theme(colors.cyan.300)]",
|
|
30
|
-
ghost:
|
|
31
|
-
"[--progress-fill:theme(colors.slate.800)] dark:[--progress-fill:theme(colors.slate.200)]",
|
|
32
|
-
glass:
|
|
33
|
-
"[--progress-fill:theme(colors.slate.900)] dark:[--progress-fill:theme(colors.white)]",
|
|
34
|
-
"gradient-blue":
|
|
35
|
-
"[--progress-fill:linear-gradient(90deg,theme(colors.blue.500),theme(colors.purple.500))] dark:[--progress-fill:linear-gradient(90deg,theme(colors.blue.500),theme(colors.purple.500))]",
|
|
36
|
-
"gradient-green":
|
|
37
|
-
"[--progress-fill:linear-gradient(90deg,theme(colors.green.500),theme(colors.lime.500))] dark:[--progress-fill:linear-gradient(90deg,theme(colors.green.500),theme(colors.lime.500))]",
|
|
38
|
-
"gradient-red":
|
|
39
|
-
"[--progress-fill:linear-gradient(90deg,theme(colors.red.500),theme(colors.pink.500))] dark:[--progress-fill:linear-gradient(90deg,theme(colors.red.500),theme(colors.pink.500))]",
|
|
40
|
-
"gradient-yellow":
|
|
41
|
-
"[--progress-fill:linear-gradient(90deg,theme(colors.yellow.500),theme(colors.orange.500))] dark:[--progress-fill:linear-gradient(90deg,theme(colors.yellow.500),theme(colors.orange.500))]",
|
|
42
|
-
"gradient-purple":
|
|
43
|
-
"[--progress-fill:linear-gradient(90deg,theme(colors.purple.500),theme(colors.pink.500))] dark:[--progress-fill:linear-gradient(90deg,theme(colors.purple.500),theme(colors.pink.500))]",
|
|
44
|
-
"gradient-teal":
|
|
45
|
-
"[--progress-fill:linear-gradient(90deg,theme(colors.teal.500),theme(colors.cyan.500))] dark:[--progress-fill:linear-gradient(90deg,theme(colors.teal.500),theme(colors.cyan.500))]",
|
|
46
|
-
"gradient-indigo":
|
|
47
|
-
"[--progress-fill:linear-gradient(90deg,theme(colors.indigo.500),theme(colors.purple.500))] dark:[--progress-fill:linear-gradient(90deg,theme(colors.indigo.500),theme(colors.purple.500))]",
|
|
48
|
-
"gradient-pink":
|
|
49
|
-
"[--progress-fill:linear-gradient(90deg,theme(colors.pink.500),theme(colors.rose.500))] dark:[--progress-fill:linear-gradient(90deg,theme(colors.pink.500),theme(colors.rose.500))]",
|
|
50
|
-
"gradient-orange":
|
|
51
|
-
"[--progress-fill:linear-gradient(90deg,theme(colors.orange.500),theme(colors.red.500))] dark:[--progress-fill:linear-gradient(90deg,theme(colors.orange.500),theme(colors.red.500))]",
|
|
52
|
-
},
|
|
53
|
-
size: {
|
|
54
|
-
xs: "text-[0.65rem]",
|
|
55
|
-
sm: "text-xs",
|
|
56
|
-
md: "text-sm",
|
|
57
|
-
lg: "text-base",
|
|
58
|
-
xl: "text-lg",
|
|
59
|
-
},
|
|
60
|
-
shape: {
|
|
61
|
-
flat: "rounded-none",
|
|
62
|
-
rounded: "rounded-md",
|
|
63
|
-
pill: "rounded-full",
|
|
64
|
-
},
|
|
65
|
-
striped: {
|
|
66
|
-
true: "",
|
|
67
|
-
false: "",
|
|
68
|
-
},
|
|
69
|
-
animated: {
|
|
70
|
-
true: "",
|
|
71
|
-
false: "",
|
|
72
|
-
},
|
|
73
|
-
},
|
|
74
|
-
defaultVariants: {
|
|
75
|
-
appearance: "default",
|
|
76
|
-
size: "md",
|
|
77
|
-
shape: "rounded",
|
|
78
|
-
striped: false,
|
|
79
|
-
animated: false,
|
|
80
|
-
},
|
|
3
|
+
import {
|
|
4
|
+
zuiProgressAppearances,
|
|
5
|
+
zuiProgressBarBase,
|
|
6
|
+
zuiProgressBarStriped,
|
|
7
|
+
zuiProgressBase,
|
|
8
|
+
zuiProgressBoolean,
|
|
9
|
+
zuiProgressShapes,
|
|
10
|
+
zuiProgressSizes,
|
|
11
|
+
zuiProgressTrackBase,
|
|
12
|
+
zuiProgressTrackSizes,
|
|
13
|
+
} from "../../design-system/progress";
|
|
14
|
+
|
|
15
|
+
export const progressVariants = cva(zuiProgressBase, {
|
|
16
|
+
variants: {
|
|
17
|
+
appearance: zuiProgressAppearances,
|
|
18
|
+
size: zuiProgressSizes,
|
|
19
|
+
shape: zuiProgressShapes,
|
|
20
|
+
striped: zuiProgressBoolean,
|
|
21
|
+
animated: zuiProgressBoolean,
|
|
22
|
+
},
|
|
23
|
+
defaultVariants: {
|
|
24
|
+
appearance: "default",
|
|
25
|
+
size: "md",
|
|
26
|
+
shape: "rounded",
|
|
27
|
+
striped: false,
|
|
28
|
+
animated: false,
|
|
81
29
|
},
|
|
82
|
-
);
|
|
30
|
+
});
|
|
83
31
|
|
|
84
|
-
export const progressTrackVariants = cva(
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
lg: "h-3",
|
|
93
|
-
xl: "h-4",
|
|
94
|
-
},
|
|
95
|
-
shape: {
|
|
96
|
-
flat: "rounded-none",
|
|
97
|
-
rounded: "rounded-md",
|
|
98
|
-
pill: "rounded-full",
|
|
99
|
-
},
|
|
100
|
-
},
|
|
101
|
-
defaultVariants: {
|
|
102
|
-
size: "md",
|
|
103
|
-
shape: "rounded",
|
|
104
|
-
},
|
|
32
|
+
export const progressTrackVariants = cva(zuiProgressTrackBase, {
|
|
33
|
+
variants: {
|
|
34
|
+
size: zuiProgressTrackSizes,
|
|
35
|
+
shape: zuiProgressShapes,
|
|
36
|
+
},
|
|
37
|
+
defaultVariants: {
|
|
38
|
+
size: "md",
|
|
39
|
+
shape: "rounded",
|
|
105
40
|
},
|
|
106
|
-
);
|
|
41
|
+
});
|
|
107
42
|
|
|
108
|
-
export const progressBarVariants = cva(
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
variants: {
|
|
112
|
-
striped: {
|
|
113
|
-
true: "bg-[repeating-linear-gradient(135deg,rgba(15,23,42,0.12)_0,rgba(15,23,42,0.12)_10px,transparent_10px,transparent_20px)] dark:bg-[repeating-linear-gradient(135deg,rgba(255,255,255,0.18)_0,rgba(255,255,255,0.18)_10px,transparent_10px,transparent_20px)]",
|
|
114
|
-
false: "[background:var(--progress-fill)]",
|
|
115
|
-
},
|
|
116
|
-
},
|
|
117
|
-
defaultVariants: { striped: false },
|
|
43
|
+
export const progressBarVariants = cva(zuiProgressBarBase, {
|
|
44
|
+
variants: {
|
|
45
|
+
striped: zuiProgressBarStriped,
|
|
118
46
|
},
|
|
119
|
-
|
|
47
|
+
defaultVariants: { striped: false },
|
|
48
|
+
});
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
export const radioGroupAnimationPresets = {
|
|
2
|
+
pop: {
|
|
3
|
+
initial: { scale: 0.35, opacity: 0 },
|
|
4
|
+
animate: { scale: 1, opacity: 1 },
|
|
5
|
+
transition: { type: "spring", stiffness: 520, damping: 28 },
|
|
6
|
+
},
|
|
7
|
+
fade: {
|
|
8
|
+
initial: { scale: 0.85, opacity: 0 },
|
|
9
|
+
animate: { scale: 1, opacity: 1 },
|
|
10
|
+
transition: { duration: 0.16, ease: "easeOut" },
|
|
11
|
+
},
|
|
12
|
+
} as const;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
export { RadioGroupAnimated, RadioGroupItemAnimated } from "./radio-group-animated";
|
|
4
|
+
export type {
|
|
5
|
+
RadioGroupAnimatedProps,
|
|
6
|
+
RadioGroupAnimation,
|
|
7
|
+
RadioGroupAnimationPresets,
|
|
8
|
+
RadioGroupItemAnimatedProps,
|
|
9
|
+
} from "./types";
|
|
10
|
+
export { radioGroupAnimationPresets } from "./animations";
|
|
@@ -0,0 +1,173 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
|
|
3
|
+
import { motion } from "framer-motion";
|
|
4
|
+
import { useCallback, useId, useState } from "react";
|
|
5
|
+
|
|
6
|
+
import { cn } from "../../../lib/utils";
|
|
7
|
+
|
|
8
|
+
import { radioGroupAnimationPresets } from "./animations";
|
|
9
|
+
import type {
|
|
10
|
+
RadioGroupAnimatedProps,
|
|
11
|
+
RadioGroupItemAnimatedProps,
|
|
12
|
+
} from "./types";
|
|
13
|
+
import {
|
|
14
|
+
RadioGroupContext,
|
|
15
|
+
useRadioGroupContext,
|
|
16
|
+
} from "../radio-group-context";
|
|
17
|
+
import {
|
|
18
|
+
radioGroupControlVariants,
|
|
19
|
+
radioGroupIndicatorVariants,
|
|
20
|
+
radioGroupItemVariants,
|
|
21
|
+
radioGroupRootVariants,
|
|
22
|
+
} from "../variants";
|
|
23
|
+
|
|
24
|
+
export function RadioGroupAnimated(props: RadioGroupAnimatedProps) {
|
|
25
|
+
const {
|
|
26
|
+
className,
|
|
27
|
+
value,
|
|
28
|
+
defaultValue,
|
|
29
|
+
name,
|
|
30
|
+
disabled,
|
|
31
|
+
required,
|
|
32
|
+
onValueChange,
|
|
33
|
+
orientation,
|
|
34
|
+
appearance,
|
|
35
|
+
size,
|
|
36
|
+
children,
|
|
37
|
+
ref,
|
|
38
|
+
animation: _animation,
|
|
39
|
+
...rest
|
|
40
|
+
} = props;
|
|
41
|
+
const generatedName = useId();
|
|
42
|
+
const isControlled = value !== undefined;
|
|
43
|
+
const [uncontrolled, setUncontrolled] = useState(defaultValue);
|
|
44
|
+
const resolvedValue = isControlled ? value : uncontrolled;
|
|
45
|
+
|
|
46
|
+
const setValue = useCallback(
|
|
47
|
+
(next: string) => {
|
|
48
|
+
if (!isControlled) {
|
|
49
|
+
setUncontrolled(next);
|
|
50
|
+
}
|
|
51
|
+
onValueChange?.(next);
|
|
52
|
+
},
|
|
53
|
+
[isControlled, onValueChange],
|
|
54
|
+
);
|
|
55
|
+
|
|
56
|
+
return (
|
|
57
|
+
<RadioGroupContext.Provider
|
|
58
|
+
value={{
|
|
59
|
+
value: resolvedValue,
|
|
60
|
+
name: name ?? generatedName,
|
|
61
|
+
disabled,
|
|
62
|
+
required,
|
|
63
|
+
appearance: appearance ?? undefined,
|
|
64
|
+
size: size ?? undefined,
|
|
65
|
+
onValueChange: setValue,
|
|
66
|
+
}}
|
|
67
|
+
>
|
|
68
|
+
<div
|
|
69
|
+
ref={ref}
|
|
70
|
+
role="radiogroup"
|
|
71
|
+
data-slot="radio-group"
|
|
72
|
+
data-orientation={orientation ?? "vertical"}
|
|
73
|
+
className={cn(radioGroupRootVariants({ orientation }), className)}
|
|
74
|
+
{...rest}
|
|
75
|
+
>
|
|
76
|
+
{children}
|
|
77
|
+
</div>
|
|
78
|
+
</RadioGroupContext.Provider>
|
|
79
|
+
);
|
|
80
|
+
}
|
|
81
|
+
|
|
82
|
+
RadioGroupAnimated.displayName = "RadioGroup";
|
|
83
|
+
|
|
84
|
+
export function RadioGroupItemAnimated(props: RadioGroupItemAnimatedProps) {
|
|
85
|
+
const {
|
|
86
|
+
className,
|
|
87
|
+
rootClassName,
|
|
88
|
+
controlClassName,
|
|
89
|
+
indicatorClassName,
|
|
90
|
+
value,
|
|
91
|
+
appearance: appearanceProp,
|
|
92
|
+
size: sizeProp,
|
|
93
|
+
disabled: disabledProp,
|
|
94
|
+
required: requiredProp,
|
|
95
|
+
children,
|
|
96
|
+
label,
|
|
97
|
+
id,
|
|
98
|
+
ref,
|
|
99
|
+
"aria-label": ariaLabel,
|
|
100
|
+
animation = "pop",
|
|
101
|
+
...rest
|
|
102
|
+
} = props;
|
|
103
|
+
const generatedId = useId();
|
|
104
|
+
const context = useRadioGroupContext();
|
|
105
|
+
const controlId = id ?? generatedId;
|
|
106
|
+
const checked = context?.value === value;
|
|
107
|
+
const disabled = disabledProp ?? context?.disabled;
|
|
108
|
+
const required = requiredProp ?? context?.required;
|
|
109
|
+
const appearance = appearanceProp ?? context?.appearance;
|
|
110
|
+
const size = sizeProp ?? context?.size;
|
|
111
|
+
const labelContent = label ?? children;
|
|
112
|
+
const hasVisibleLabel =
|
|
113
|
+
labelContent !== undefined && labelContent !== null && labelContent !== false;
|
|
114
|
+
const motionPreset = radioGroupAnimationPresets[animation];
|
|
115
|
+
|
|
116
|
+
return (
|
|
117
|
+
<label
|
|
118
|
+
className={cn(radioGroupItemVariants({ size }), rootClassName, className)}
|
|
119
|
+
data-disabled={disabled ? "true" : undefined}
|
|
120
|
+
data-state={checked ? "checked" : "unchecked"}
|
|
121
|
+
htmlFor={controlId}
|
|
122
|
+
>
|
|
123
|
+
<input
|
|
124
|
+
ref={ref}
|
|
125
|
+
id={controlId}
|
|
126
|
+
type="radio"
|
|
127
|
+
data-slot="radio-group-item"
|
|
128
|
+
className="peer sr-only"
|
|
129
|
+
name={context?.name}
|
|
130
|
+
value={value}
|
|
131
|
+
checked={checked}
|
|
132
|
+
disabled={disabled}
|
|
133
|
+
required={required}
|
|
134
|
+
aria-label={ariaLabel ?? (hasVisibleLabel ? undefined : value)}
|
|
135
|
+
onChange={(event) => {
|
|
136
|
+
if (event.currentTarget.checked) {
|
|
137
|
+
context?.onValueChange(value);
|
|
138
|
+
}
|
|
139
|
+
}}
|
|
140
|
+
{...rest}
|
|
141
|
+
/>
|
|
142
|
+
<span
|
|
143
|
+
aria-hidden="true"
|
|
144
|
+
className={cn(
|
|
145
|
+
radioGroupControlVariants({ appearance, size }),
|
|
146
|
+
controlClassName,
|
|
147
|
+
)}
|
|
148
|
+
data-slot="radio-group-control"
|
|
149
|
+
>
|
|
150
|
+
{checked && (
|
|
151
|
+
<motion.span
|
|
152
|
+
className={cn(
|
|
153
|
+
radioGroupIndicatorVariants({ size }),
|
|
154
|
+
"opacity-100",
|
|
155
|
+
indicatorClassName,
|
|
156
|
+
)}
|
|
157
|
+
data-slot="radio-group-indicator"
|
|
158
|
+
initial={motionPreset.initial}
|
|
159
|
+
animate={motionPreset.animate}
|
|
160
|
+
transition={motionPreset.transition}
|
|
161
|
+
/>
|
|
162
|
+
)}
|
|
163
|
+
</span>
|
|
164
|
+
{hasVisibleLabel && (
|
|
165
|
+
<span className="min-w-0 leading-6" data-slot="radio-group-label">
|
|
166
|
+
{labelContent}
|
|
167
|
+
</span>
|
|
168
|
+
)}
|
|
169
|
+
</label>
|
|
170
|
+
);
|
|
171
|
+
}
|
|
172
|
+
|
|
173
|
+
RadioGroupItemAnimated.displayName = "RadioGroupItem";
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
import type { RadioGroupItemProps, RadioGroupProps } from "../types";
|
|
2
|
+
import type { radioGroupAnimationPresets } from "./animations";
|
|
3
|
+
|
|
4
|
+
export type RadioGroupAnimation = keyof typeof radioGroupAnimationPresets;
|
|
5
|
+
export type RadioGroupAnimationPresets = typeof radioGroupAnimationPresets;
|
|
6
|
+
|
|
7
|
+
export type RadioGroupAnimatedProps = RadioGroupProps & {
|
|
8
|
+
animation?: RadioGroupAnimation;
|
|
9
|
+
};
|
|
10
|
+
|
|
11
|
+
export type RadioGroupItemAnimatedProps = RadioGroupItemProps & {
|
|
12
|
+
animation?: RadioGroupAnimation;
|
|
13
|
+
};
|