@techzyapp/ui-library 1.0.25 → 1.0.27
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/dist/{AdminRoot-CgvtgUpW.js → AdminRoot-C4OyuOIr.js} +4 -4
- package/dist/{AdminRoot-CgvtgUpW.js.map → AdminRoot-C4OyuOIr.js.map} +1 -1
- package/dist/{AdminRoot-BkPPRkyQ.cjs → AdminRoot-bHywlbML.cjs} +2 -2
- package/dist/{AdminRoot-BkPPRkyQ.cjs.map → AdminRoot-bHywlbML.cjs.map} +1 -1
- package/dist/{Alert-udX1ybuC.cjs → Alert-DeGgilkH.cjs} +2 -2
- package/dist/{Alert-udX1ybuC.cjs.map → Alert-DeGgilkH.cjs.map} +1 -1
- package/dist/{Alert-DXmzM_rh.js → Alert-rNjfqj2Z.js} +3 -3
- package/dist/{Alert-DXmzM_rh.js.map → Alert-rNjfqj2Z.js.map} +1 -1
- package/dist/{AuthLayout-BRUxDgzs.cjs → AuthLayout-ChILVWZ-.cjs} +2 -2
- package/dist/{AuthLayout-BRUxDgzs.cjs.map → AuthLayout-ChILVWZ-.cjs.map} +1 -1
- package/dist/{AuthLayout-CP9qu6Bv.js → AuthLayout-zAS3jlYc.js} +2 -2
- package/dist/{AuthLayout-CP9qu6Bv.js.map → AuthLayout-zAS3jlYc.js.map} +1 -1
- package/dist/{Avatar-Q50J8wdN.js → Avatar-BGPGxry2.js} +25 -25
- package/dist/{Avatar-Q50J8wdN.js.map → Avatar-BGPGxry2.js.map} +1 -1
- package/dist/Avatar-D_YivyqV.cjs +2 -0
- package/dist/{Avatar-Dgf04PBC.cjs.map → Avatar-D_YivyqV.cjs.map} +1 -1
- package/dist/{AvatarGroup-uW0SD5P4.cjs → AvatarGroup-Bnf_RSc9.cjs} +2 -2
- package/dist/{AvatarGroup-uW0SD5P4.cjs.map → AvatarGroup-Bnf_RSc9.cjs.map} +1 -1
- package/dist/{AvatarGroup-YaNasLMS.js → AvatarGroup-Difz4lLR.js} +2 -2
- package/dist/{AvatarGroup-YaNasLMS.js.map → AvatarGroup-Difz4lLR.js.map} +1 -1
- package/dist/Badge-BmFgusOa.js +50 -0
- package/dist/{Badge-DSWigoGC.js.map → Badge-BmFgusOa.js.map} +1 -1
- package/dist/Badge-DVbe1rAI.cjs +2 -0
- package/dist/{Badge-BQpr2Jee.cjs.map → Badge-DVbe1rAI.cjs.map} +1 -1
- package/dist/{Breadcrumbs-DQHHeLId.js → Breadcrumbs-BJHKk0Sn.js} +3 -3
- package/dist/{Breadcrumbs-DQHHeLId.js.map → Breadcrumbs-BJHKk0Sn.js.map} +1 -1
- package/dist/{Breadcrumbs-CsYTiX2h.cjs → Breadcrumbs-CGcpMlxm.cjs} +2 -2
- package/dist/{Breadcrumbs-CsYTiX2h.cjs.map → Breadcrumbs-CGcpMlxm.cjs.map} +1 -1
- package/dist/Button-BZ_o-akc.cjs +2 -0
- package/dist/{Button-CXmDOzPk.cjs.map → Button-BZ_o-akc.cjs.map} +1 -1
- package/dist/Button-obe6rono.js +72 -0
- package/dist/{Button-DBs8xnA5.js.map → Button-obe6rono.js.map} +1 -1
- package/dist/{Calendar-CtteUt82.js → Calendar-SCih0NtS.js} +4 -4
- package/dist/{Calendar-CtteUt82.js.map → Calendar-SCih0NtS.js.map} +1 -1
- package/dist/{Calendar-B2nMXk4C.cjs → Calendar-lfpNwivC.cjs} +2 -2
- package/dist/{Calendar-B2nMXk4C.cjs.map → Calendar-lfpNwivC.cjs.map} +1 -1
- package/dist/{Card-DYKnWt-L.js → Card-BRJV2JZE.js} +2 -2
- package/dist/{Card-DYKnWt-L.js.map → Card-BRJV2JZE.js.map} +1 -1
- package/dist/{Card-DGF22HbS.cjs → Card-KvvNlchc.cjs} +2 -2
- package/dist/{Card-DGF22HbS.cjs.map → Card-KvvNlchc.cjs.map} +1 -1
- package/dist/{Chip-DdKhcstm.js → Chip-CQ4cYVl_.js} +31 -31
- package/dist/{Chip-DdKhcstm.js.map → Chip-CQ4cYVl_.js.map} +1 -1
- package/dist/Chip-CYz4vxHm.cjs +2 -0
- package/dist/{Chip-gUH_7nQc.cjs.map → Chip-CYz4vxHm.cjs.map} +1 -1
- package/dist/ChoiceCardGroup-D3HL7dHj.js +181 -0
- package/dist/{ChoiceCardGroup-DBohUnRj.js.map → ChoiceCardGroup-D3HL7dHj.js.map} +1 -1
- package/dist/ChoiceCardGroup-pIOKIUI0.cjs +2 -0
- package/dist/{ChoiceCardGroup-d0VVTUi5.cjs.map → ChoiceCardGroup-pIOKIUI0.cjs.map} +1 -1
- package/dist/{CodeBlock-DD_d3-sM.js → CodeBlock-DddGTLu1.js} +3 -3
- package/dist/{CodeBlock-DD_d3-sM.js.map → CodeBlock-DddGTLu1.js.map} +1 -1
- package/dist/{CodeBlock-C6tQtbHU.cjs → CodeBlock-H75dbOvg.cjs} +2 -2
- package/dist/{CodeBlock-C6tQtbHU.cjs.map → CodeBlock-H75dbOvg.cjs.map} +1 -1
- package/dist/ColorPicker-CKc8k-Dp.cjs +2 -0
- package/dist/ColorPicker-CKc8k-Dp.cjs.map +1 -0
- package/dist/{ColorPicker-Dw6Qk0iy.js → ColorPicker-Cw-2X6u9.js} +35 -26
- package/dist/ColorPicker-Cw-2X6u9.js.map +1 -0
- package/dist/ColorPickerPanel-DQ4CFnGa.cjs +2 -0
- package/dist/ColorPickerPanel-DQ4CFnGa.cjs.map +1 -0
- package/dist/ColorPickerPanel-PYaF5wPL.js +322 -0
- package/dist/ColorPickerPanel-PYaF5wPL.js.map +1 -0
- package/dist/ColorRamp-AkY9gq6Y.cjs +2 -0
- package/dist/ColorRamp-AkY9gq6Y.cjs.map +1 -0
- package/dist/ColorRamp-DnlJNKfy.js +126 -0
- package/dist/ColorRamp-DnlJNKfy.js.map +1 -0
- package/dist/{ConfigProvider-Bszl3Wr3.cjs → ConfigProvider-BicoaBLj.cjs} +2 -2
- package/dist/ConfigProvider-BicoaBLj.cjs.map +1 -0
- package/dist/{ConfigProvider-DR9YMy9U.js → ConfigProvider-DL9fylMo.js} +2 -2
- package/dist/ConfigProvider-DL9fylMo.js.map +1 -0
- package/dist/CopyButton-BqFGC-Ca.cjs +2 -0
- package/dist/{CopyButton-Ct-8AmmX.cjs.map → CopyButton-BqFGC-Ca.cjs.map} +1 -1
- package/dist/CopyButton-D6-kcVCA.js +43 -0
- package/dist/{CopyButton-DJ1PSJZU.js.map → CopyButton-D6-kcVCA.js.map} +1 -1
- package/dist/DashedButton-B7xodc3N.cjs +2 -0
- package/dist/{DashedButton-3C4IZuo4.cjs.map → DashedButton-B7xodc3N.cjs.map} +1 -1
- package/dist/DashedButton-iM7kzopW.js +59 -0
- package/dist/{DashedButton-BXZAyMtw.js.map → DashedButton-iM7kzopW.js.map} +1 -1
- package/dist/{DatePicker-BxEydgfu.cjs → DatePicker-BvGFP2AL.cjs} +2 -2
- package/dist/{DatePicker-BxEydgfu.cjs.map → DatePicker-BvGFP2AL.cjs.map} +1 -1
- package/dist/{DatePicker-CJioG5M7.js → DatePicker-DP7yASzq.js} +5 -5
- package/dist/{DatePicker-CJioG5M7.js.map → DatePicker-DP7yASzq.js.map} +1 -1
- package/dist/DatePicker.module-BDtTsg8M.cjs +2 -0
- package/dist/{DatePicker.module-tE-tGNBd.cjs.map → DatePicker.module-BDtTsg8M.cjs.map} +1 -1
- package/dist/DatePicker.module-CMMQyEhG.js +138 -0
- package/dist/{DatePicker.module-BZDftL4g.js.map → DatePicker.module-CMMQyEhG.js.map} +1 -1
- package/dist/{DateTimePicker-e2zj2bhS.js → DateTimePicker-CzRduOFz.js} +8 -8
- package/dist/{DateTimePicker-e2zj2bhS.js.map → DateTimePicker-CzRduOFz.js.map} +1 -1
- package/dist/{DateTimePicker-COEj2Z0F.cjs → DateTimePicker-DOzft9kg.cjs} +2 -2
- package/dist/{DateTimePicker-COEj2Z0F.cjs.map → DateTimePicker-DOzft9kg.cjs.map} +1 -1
- package/dist/EmptyState-A5nPGnHA.js +38 -0
- package/dist/{EmptyState-BTd7aVgu.js.map → EmptyState-A5nPGnHA.js.map} +1 -1
- package/dist/EmptyState-CTTOy9aY.cjs +2 -0
- package/dist/{EmptyState-Bv4XXnD1.cjs.map → EmptyState-CTTOy9aY.cjs.map} +1 -1
- package/dist/{FileCard-DY8N9Lzz.js → FileCard-BmPEEcue.js} +4 -4
- package/dist/{FileCard-DY8N9Lzz.js.map → FileCard-BmPEEcue.js.map} +1 -1
- package/dist/{FileCard-DW5Ur8Aj.cjs → FileCard-C4BkGMtK.cjs} +2 -2
- package/dist/{FileCard-DW5Ur8Aj.cjs.map → FileCard-C4BkGMtK.cjs.map} +1 -1
- package/dist/FileUploader-D_F64mob.cjs +2 -0
- package/dist/FileUploader-D_F64mob.cjs.map +1 -0
- package/dist/{FileUploader-BYF5FvUc.js → FileUploader-Dv_3bjZA.js} +217 -217
- package/dist/FileUploader-Dv_3bjZA.js.map +1 -0
- package/dist/{Flag-CB4YyPj3.cjs → Flag-BM_2VJ1v.cjs} +2 -2
- package/dist/{Flag-CB4YyPj3.cjs.map → Flag-BM_2VJ1v.cjs.map} +1 -1
- package/dist/{Flag-yA1y5XzR.js → Flag-CzCEpB8E.js} +2 -2
- package/dist/{Flag-yA1y5XzR.js.map → Flag-CzCEpB8E.js.map} +1 -1
- package/dist/{FullscreenToggle-0lskYnpx.cjs → FullscreenToggle-BL0nBrsL.cjs} +2 -2
- package/dist/{FullscreenToggle-0lskYnpx.cjs.map → FullscreenToggle-BL0nBrsL.cjs.map} +1 -1
- package/dist/{FullscreenToggle-jSLruiKt.js → FullscreenToggle-HZQOIa21.js} +3 -3
- package/dist/{FullscreenToggle-jSLruiKt.js.map → FullscreenToggle-HZQOIa21.js.map} +1 -1
- package/dist/IconButton-B87ipBK3.cjs +2 -0
- package/dist/{IconButton-BN-bZxEi.cjs.map → IconButton-B87ipBK3.cjs.map} +1 -1
- package/dist/IconButton-CBp8QuTO.js +68 -0
- package/dist/{IconButton-BEGWfcVc.js.map → IconButton-CBp8QuTO.js.map} +1 -1
- package/dist/Loader-0Imnbael.cjs +2 -0
- package/dist/{Loader-B5YqzEYy.cjs.map → Loader-0Imnbael.cjs.map} +1 -1
- package/dist/Loader-fffFnQqS.js +28 -0
- package/dist/{Loader-BZIa8hwv.js.map → Loader-fffFnQqS.js.map} +1 -1
- package/dist/MobileFrame-8FSsYA_w.js +91 -0
- package/dist/MobileFrame-8FSsYA_w.js.map +1 -0
- package/dist/MobileFrame-Dsfgd_4k.cjs +2 -0
- package/dist/MobileFrame-Dsfgd_4k.cjs.map +1 -0
- package/dist/{Modal-0V-REVV-.cjs → Modal--e2qGisF.cjs} +2 -2
- package/dist/{Modal-0V-REVV-.cjs.map → Modal--e2qGisF.cjs.map} +1 -1
- package/dist/{Modal-B7yoFC3o.js → Modal-DJljaPqV.js} +3 -3
- package/dist/{Modal-B7yoFC3o.js.map → Modal-DJljaPqV.js.map} +1 -1
- package/dist/{MultiSelect-gj9Ymeh2.cjs → MultiSelect-CvecZeMU.cjs} +2 -2
- package/dist/{MultiSelect-gj9Ymeh2.cjs.map → MultiSelect-CvecZeMU.cjs.map} +1 -1
- package/dist/{MultiSelect-C8xuXaoR.js → MultiSelect-DLoS04lZ.js} +4 -4
- package/dist/{MultiSelect-C8xuXaoR.js.map → MultiSelect-DLoS04lZ.js.map} +1 -1
- package/dist/{NumberField-CEt95jcC.cjs → NumberField-C_HZXBuw.cjs} +2 -2
- package/dist/{NumberField-CEt95jcC.cjs.map → NumberField-C_HZXBuw.cjs.map} +1 -1
- package/dist/{NumberField-2yM0mmyj.js → NumberField-DYGVQdL5.js} +4 -4
- package/dist/{NumberField-2yM0mmyj.js.map → NumberField-DYGVQdL5.js.map} +1 -1
- package/dist/{OtpField-CkliY82J.js → OtpField-CpQr_ZqL.js} +3 -3
- package/dist/{OtpField-CkliY82J.js.map → OtpField-CpQr_ZqL.js.map} +1 -1
- package/dist/{OtpField-on-K0_fM.cjs → OtpField-DKbUP0F6.cjs} +2 -2
- package/dist/{OtpField-on-K0_fM.cjs.map → OtpField-DKbUP0F6.cjs.map} +1 -1
- package/dist/{PageLayout-DzPh_G6H.js → PageLayout-CCcPCfJF.js} +2 -2
- package/dist/{PageLayout-DzPh_G6H.js.map → PageLayout-CCcPCfJF.js.map} +1 -1
- package/dist/{PageLayout-DGHu7Vm3.cjs → PageLayout-CuWXukUv.cjs} +2 -2
- package/dist/{PageLayout-DGHu7Vm3.cjs.map → PageLayout-CuWXukUv.cjs.map} +1 -1
- package/dist/PageNotFound-JKOnpyHD.cjs +2 -0
- package/dist/{PageNotFound-B8_eIT8p.cjs.map → PageNotFound-JKOnpyHD.cjs.map} +1 -1
- package/dist/{PageNotFound-CCFfPHgA.js → PageNotFound-LWH2tU5E.js} +9 -9
- package/dist/{PageNotFound-CCFfPHgA.js.map → PageNotFound-LWH2tU5E.js.map} +1 -1
- package/dist/Pagination-BwtbmITJ.js +139 -0
- package/dist/{Pagination-CmskZjcz.js.map → Pagination-BwtbmITJ.js.map} +1 -1
- package/dist/Pagination-M7njqOUt.cjs +2 -0
- package/dist/{Pagination-BdVebW2L.cjs.map → Pagination-M7njqOUt.cjs.map} +1 -1
- package/dist/PaletteField-CUyzLrny.js +54 -0
- package/dist/PaletteField-CUyzLrny.js.map +1 -0
- package/dist/PaletteField-iBIvOvNi.cjs +2 -0
- package/dist/PaletteField-iBIvOvNi.cjs.map +1 -0
- package/dist/RadioGroup-Byy-eSY3.cjs +2 -0
- package/dist/{RadioGroup-C8u7eNBS.cjs.map → RadioGroup-Byy-eSY3.cjs.map} +1 -1
- package/dist/RadioGroup-D_1_Heta.js +141 -0
- package/dist/{RadioGroup-DbodUJW8.js.map → RadioGroup-D_1_Heta.js.map} +1 -1
- package/dist/RemoveDialog-DUrD2Em8.js +47 -0
- package/dist/{RemoveDialog-CV75B0aN.js.map → RemoveDialog-DUrD2Em8.js.map} +1 -1
- package/dist/RemoveDialog-FZWYAxRy.cjs +2 -0
- package/dist/{RemoveDialog-DmOk0ezc.cjs.map → RemoveDialog-FZWYAxRy.cjs.map} +1 -1
- package/dist/{RichTextEditor-Bm8FFbcR.js → RichTextEditor-CG6LoNiw.js} +9 -9
- package/dist/RichTextEditor-CG6LoNiw.js.map +1 -0
- package/dist/{RichTextEditor-uXddgtlk.cjs → RichTextEditor-mpMCG8jX.cjs} +2 -2
- package/dist/RichTextEditor-mpMCG8jX.cjs.map +1 -0
- package/dist/RootLayout-CPxDqfGb.cjs +2 -0
- package/dist/{RootLayout-kssj9exn.cjs.map → RootLayout-CPxDqfGb.cjs.map} +1 -1
- package/dist/RootLayout-D3K-pAMO.js +515 -0
- package/dist/{RootLayout-Cf7Rr9Iz.js.map → RootLayout-D3K-pAMO.js.map} +1 -1
- package/dist/{Select-CdX3Ks7y.js → Select-BB9oOoWZ.js} +3 -3
- package/dist/{Select-CdX3Ks7y.js.map → Select-BB9oOoWZ.js.map} +1 -1
- package/dist/{Select-7vEGJCvA.cjs → Select-iP2p5jad.cjs} +2 -2
- package/dist/{Select-7vEGJCvA.cjs.map → Select-iP2p5jad.cjs.map} +1 -1
- package/dist/{Sidebar-DcKIEfhy.cjs → Sidebar-Boi7UgHV.cjs} +2 -2
- package/dist/{Sidebar-DcKIEfhy.cjs.map → Sidebar-Boi7UgHV.cjs.map} +1 -1
- package/dist/{Sidebar-YH-DoNG9.js → Sidebar-CsPnv4mu.js} +60 -60
- package/dist/{Sidebar-YH-DoNG9.js.map → Sidebar-CsPnv4mu.js.map} +1 -1
- package/dist/Slider-D3dbEOQY.cjs +2 -0
- package/dist/{Slider-dxYVXRev.cjs.map → Slider-D3dbEOQY.cjs.map} +1 -1
- package/dist/Slider-D7SvowmM.js +184 -0
- package/dist/{Slider-oGXd5e9X.js.map → Slider-D7SvowmM.js.map} +1 -1
- package/dist/{SpeedDial-DWNuC6f8.js → SpeedDial-B8XMUATN.js} +2 -2
- package/dist/{SpeedDial-DWNuC6f8.js.map → SpeedDial-B8XMUATN.js.map} +1 -1
- package/dist/{SpeedDial-9_Yk8AGx.cjs → SpeedDial-CZ22T8GL.cjs} +2 -2
- package/dist/{SpeedDial-9_Yk8AGx.cjs.map → SpeedDial-CZ22T8GL.cjs.map} +1 -1
- package/dist/{Stepper-CuqFpamY.js → Stepper-B_e_PGZE.js} +70 -70
- package/dist/{Stepper-CuqFpamY.js.map → Stepper-B_e_PGZE.js.map} +1 -1
- package/dist/Stepper-BjkkWawQ.cjs +2 -0
- package/dist/{Stepper-B1z_u650.cjs.map → Stepper-BjkkWawQ.cjs.map} +1 -1
- package/dist/{SwatchPicker-CCJltwHI.cjs → SwatchPicker-C8amdDnA.cjs} +2 -2
- package/dist/{SwatchPicker-CCJltwHI.cjs.map → SwatchPicker-C8amdDnA.cjs.map} +1 -1
- package/dist/{SwatchPicker-CqyWngFJ.js → SwatchPicker-DXEE9xqY.js} +2 -2
- package/dist/{SwatchPicker-CqyWngFJ.js.map → SwatchPicker-DXEE9xqY.js.map} +1 -1
- package/dist/Switch-CodRZD3y.cjs +2 -0
- package/dist/{Switch-DRkZ6kHJ.cjs.map → Switch-CodRZD3y.cjs.map} +1 -1
- package/dist/Switch-ESrhkpJC.js +85 -0
- package/dist/{Switch-DMPJ0fhB.js.map → Switch-ESrhkpJC.js.map} +1 -1
- package/dist/Table-Cr1zUtNQ.cjs +2 -0
- package/dist/Table-Cr1zUtNQ.cjs.map +1 -0
- package/dist/{Table-Drdhfm99.js → Table-DdoUcZoN.js} +60 -51
- package/dist/Table-DdoUcZoN.js.map +1 -0
- package/dist/Tabs-CZDX7BN-.cjs +2 -0
- package/dist/{Tabs-BiKDy_fv.cjs.map → Tabs-CZDX7BN-.cjs.map} +1 -1
- package/dist/Tabs-v1GEGUDQ.js +190 -0
- package/dist/{Tabs-ytbBzAxG.js.map → Tabs-v1GEGUDQ.js.map} +1 -1
- package/dist/{TagsField-CEt_PC5y.js → TagsField-B389eDp4.js} +4 -4
- package/dist/{TagsField-CEt_PC5y.js.map → TagsField-B389eDp4.js.map} +1 -1
- package/dist/{TagsField-DpDbf0ru.cjs → TagsField-OfrpyHZO.cjs} +2 -2
- package/dist/{TagsField-DpDbf0ru.cjs.map → TagsField-OfrpyHZO.cjs.map} +1 -1
- package/dist/{TextField-BWdmF-HE.js → TextField-7MobCad5.js} +4 -4
- package/dist/{TextField-BWdmF-HE.js.map → TextField-7MobCad5.js.map} +1 -1
- package/dist/{TextField-Df_kGy2l.cjs → TextField-B785pRgK.cjs} +2 -2
- package/dist/{TextField-Df_kGy2l.cjs.map → TextField-B785pRgK.cjs.map} +1 -1
- package/dist/TextField.module-6gYcR9TL.js +27 -0
- package/dist/TextField.module-6gYcR9TL.js.map +1 -0
- package/dist/TextField.module-DsNCo8vN.cjs +2 -0
- package/dist/TextField.module-DsNCo8vN.cjs.map +1 -0
- package/dist/{ThemeToggle-CgxF6oUu.js → ThemeToggle-BGdvqXad.js} +3 -3
- package/dist/{ThemeToggle-CgxF6oUu.js.map → ThemeToggle-BGdvqXad.js.map} +1 -1
- package/dist/{ThemeToggle-BJdXhmfc.cjs → ThemeToggle-BkmZ7s_u.cjs} +2 -2
- package/dist/{ThemeToggle-BJdXhmfc.cjs.map → ThemeToggle-BkmZ7s_u.cjs.map} +1 -1
- package/dist/{TimeColumns-DxVN0V8l.cjs → TimeColumns-B-xm1DGM.cjs} +2 -2
- package/dist/{TimeColumns-DxVN0V8l.cjs.map → TimeColumns-B-xm1DGM.cjs.map} +1 -1
- package/dist/{TimeColumns-n-fz50mr.js → TimeColumns-BRlDKx_i.js} +3 -3
- package/dist/{TimeColumns-n-fz50mr.js.map → TimeColumns-BRlDKx_i.js.map} +1 -1
- package/dist/{TimePicker-Bopxx3zU.js → TimePicker-B_3Ubip0.js} +6 -6
- package/dist/{TimePicker-Bopxx3zU.js.map → TimePicker-B_3Ubip0.js.map} +1 -1
- package/dist/{TimePicker-DvoemiGz.cjs → TimePicker-DvEIdE4v.cjs} +2 -2
- package/dist/{TimePicker-DvoemiGz.cjs.map → TimePicker-DvEIdE4v.cjs.map} +1 -1
- package/dist/Timeline-CKEosWka.cjs +2 -0
- package/dist/{Timeline-ONU_3gi3.cjs.map → Timeline-CKEosWka.cjs.map} +1 -1
- package/dist/Timeline-ufVXmpMY.js +71 -0
- package/dist/{Timeline-D3kzt1dy.js.map → Timeline-ufVXmpMY.js.map} +1 -1
- package/dist/{Toaster-DZSzFse_.cjs → Toaster-BIFRuqbC.cjs} +2 -2
- package/dist/{Toaster-DZSzFse_.cjs.map → Toaster-BIFRuqbC.cjs.map} +1 -1
- package/dist/{Toaster-BxIY2H4V.js → Toaster-DuzcRbio.js} +2 -2
- package/dist/{Toaster-BxIY2H4V.js.map → Toaster-DuzcRbio.js.map} +1 -1
- package/dist/{TranslatedFields-BtDLkQy7.cjs → TranslatedFields-D_a0NVKI.cjs} +2 -2
- package/dist/{TranslatedFields-BtDLkQy7.cjs.map → TranslatedFields-D_a0NVKI.cjs.map} +1 -1
- package/dist/{TranslatedFields-DmR8LKSG.js → TranslatedFields-HmP0Mg5t.js} +5 -5
- package/dist/{TranslatedFields-DmR8LKSG.js.map → TranslatedFields-HmP0Mg5t.js.map} +1 -1
- package/dist/{UserCard-J8Bpbh3x.js → UserCard-B1phOVKj.js} +4 -4
- package/dist/{UserCard-J8Bpbh3x.js.map → UserCard-B1phOVKj.js.map} +1 -1
- package/dist/{UserCard-C1yFvVIc.cjs → UserCard-BvOcDm5W.cjs} +2 -2
- package/dist/{UserCard-C1yFvVIc.cjs.map → UserCard-BvOcDm5W.cjs.map} +1 -1
- package/dist/color-CgR8ybWZ.cjs +2 -0
- package/dist/color-CgR8ybWZ.cjs.map +1 -0
- package/dist/color-EQJ2DrcQ.js +24 -0
- package/dist/color-EQJ2DrcQ.js.map +1 -0
- package/dist/components/Alert/index.cjs +1 -1
- package/dist/components/Alert/index.js +1 -1
- package/dist/components/AuthLayout/index.cjs +1 -1
- package/dist/components/AuthLayout/index.js +1 -1
- package/dist/components/Avatar/index.cjs +1 -1
- package/dist/components/Avatar/index.js +2 -2
- package/dist/components/Badge/index.cjs +1 -1
- package/dist/components/Badge/index.js +1 -1
- package/dist/components/Breadcrumbs/index.cjs +1 -1
- package/dist/components/Breadcrumbs/index.js +1 -1
- package/dist/components/Button/index.cjs +1 -1
- package/dist/components/Button/index.js +1 -1
- package/dist/components/Card/index.cjs +1 -1
- package/dist/components/Card/index.js +1 -1
- package/dist/components/Chip/index.cjs +1 -1
- package/dist/components/Chip/index.js +1 -1
- package/dist/components/ChoiceCard/index.cjs +1 -1
- package/dist/components/ChoiceCard/index.js +1 -1
- package/dist/components/CodeBlock/index.cjs +1 -1
- package/dist/components/CodeBlock/index.js +1 -1
- package/dist/components/ColorPicker/ColorPicker.d.cts +5 -0
- package/dist/components/ColorPicker/ColorPicker.d.ts +5 -0
- package/dist/components/ColorPicker/ColorPickerPanel.d.cts +6 -1
- package/dist/components/ColorPicker/ColorPickerPanel.d.ts +6 -1
- package/dist/components/ColorPicker/colorUtils.d.cts +3 -12
- package/dist/components/ColorPicker/colorUtils.d.ts +3 -12
- package/dist/components/ColorPicker/index.cjs +1 -1
- package/dist/components/ColorPicker/index.js +1 -1
- package/dist/components/ColorRamp/ColorRamp.d.cts +36 -0
- package/dist/components/ColorRamp/ColorRamp.d.ts +36 -0
- package/dist/components/ColorRamp/index.cjs +2 -0
- package/dist/components/ColorRamp/index.cjs.map +1 -0
- package/dist/components/ColorRamp/index.d.cts +3 -0
- package/dist/components/ColorRamp/index.d.ts +3 -0
- package/dist/components/ColorRamp/index.js +6 -0
- package/dist/components/ColorRamp/index.js.map +1 -0
- package/dist/components/CopyButton/index.cjs +1 -1
- package/dist/components/CopyButton/index.js +1 -1
- package/dist/components/DashedButton/index.cjs +1 -1
- package/dist/components/DashedButton/index.js +1 -1
- package/dist/components/DatePicker/index.cjs +1 -1
- package/dist/components/DatePicker/index.js +1 -1
- package/dist/components/DateTimePicker/index.cjs +1 -1
- package/dist/components/DateTimePicker/index.js +1 -1
- package/dist/components/EmptyState/index.cjs +1 -1
- package/dist/components/EmptyState/index.js +1 -1
- package/dist/components/FileCard/index.cjs +1 -1
- package/dist/components/FileCard/index.js +1 -1
- package/dist/components/FileUploader/index.cjs +1 -1
- package/dist/components/FileUploader/index.js +1 -1
- package/dist/components/Flag/index.cjs +1 -1
- package/dist/components/Flag/index.js +1 -1
- package/dist/components/FullscreenToggle/index.cjs +1 -1
- package/dist/components/FullscreenToggle/index.js +1 -1
- package/dist/components/IconButton/index.cjs +1 -1
- package/dist/components/IconButton/index.js +1 -1
- package/dist/components/Loader/index.cjs +1 -1
- package/dist/components/Loader/index.js +1 -1
- package/dist/components/MobileFrame/MobileFrame.d.cts +45 -0
- package/dist/components/MobileFrame/MobileFrame.d.ts +45 -0
- package/dist/components/MobileFrame/frames.d.cts +27 -0
- package/dist/components/MobileFrame/frames.d.ts +27 -0
- package/dist/components/MobileFrame/index.cjs +2 -0
- package/dist/components/MobileFrame/index.cjs.map +1 -0
- package/dist/components/MobileFrame/index.d.cts +4 -0
- package/dist/components/MobileFrame/index.d.ts +4 -0
- package/dist/components/MobileFrame/index.js +8 -0
- package/dist/components/MobileFrame/index.js.map +1 -0
- package/dist/components/Modal/index.cjs +1 -1
- package/dist/components/Modal/index.js +1 -1
- package/dist/components/MultiSelect/index.cjs +1 -1
- package/dist/components/MultiSelect/index.js +1 -1
- package/dist/components/NumberField/index.cjs +1 -1
- package/dist/components/NumberField/index.js +1 -1
- package/dist/components/OtpField/index.cjs +1 -1
- package/dist/components/OtpField/index.js +1 -1
- package/dist/components/PageLayout/index.cjs +1 -1
- package/dist/components/PageLayout/index.js +1 -1
- package/dist/components/PageNotFound/index.cjs +1 -1
- package/dist/components/PageNotFound/index.js +1 -1
- package/dist/components/Pagination/index.cjs +1 -1
- package/dist/components/Pagination/index.js +1 -1
- package/dist/components/PaletteField/PaletteField.d.cts +30 -0
- package/dist/components/PaletteField/PaletteField.d.ts +30 -0
- package/dist/components/PaletteField/index.cjs +2 -0
- package/dist/components/PaletteField/index.cjs.map +1 -0
- package/dist/components/PaletteField/index.d.cts +2 -0
- package/dist/components/PaletteField/index.d.ts +2 -0
- package/dist/components/PaletteField/index.js +6 -0
- package/dist/components/PaletteField/index.js.map +1 -0
- package/dist/components/Radio/index.cjs +1 -1
- package/dist/components/Radio/index.js +1 -1
- package/dist/components/RemoveDialog/index.cjs +1 -1
- package/dist/components/RemoveDialog/index.js +1 -1
- package/dist/components/RichTextEditor/index.cjs +1 -1
- package/dist/components/RichTextEditor/index.js +1 -1
- package/dist/components/RootLayout/index.cjs +1 -1
- package/dist/components/RootLayout/index.js +1 -1
- package/dist/components/Select/index.cjs +1 -1
- package/dist/components/Select/index.js +1 -1
- package/dist/components/Sidebar/index.cjs +1 -1
- package/dist/components/Sidebar/index.js +1 -1
- package/dist/components/Slider/index.cjs +1 -1
- package/dist/components/Slider/index.js +1 -1
- package/dist/components/SpeedDial/index.cjs +1 -1
- package/dist/components/SpeedDial/index.js +1 -1
- package/dist/components/Stepper/index.cjs +1 -1
- package/dist/components/Stepper/index.js +1 -1
- package/dist/components/SwatchPicker/index.cjs +1 -1
- package/dist/components/SwatchPicker/index.js +1 -1
- package/dist/components/Switch/index.cjs +1 -1
- package/dist/components/Switch/index.js +1 -1
- package/dist/components/Table/index.cjs +1 -1
- package/dist/components/Table/index.js +1 -1
- package/dist/components/Tabs/index.cjs +1 -1
- package/dist/components/Tabs/index.js +1 -1
- package/dist/components/TagsField/index.cjs +1 -1
- package/dist/components/TagsField/index.js +1 -1
- package/dist/components/TextField/index.cjs +1 -1
- package/dist/components/TextField/index.js +1 -1
- package/dist/components/ThemeToggle/index.cjs +1 -1
- package/dist/components/ThemeToggle/index.js +1 -1
- package/dist/components/TimePicker/index.cjs +1 -1
- package/dist/components/TimePicker/index.js +1 -1
- package/dist/components/Timeline/index.cjs +1 -1
- package/dist/components/Timeline/index.js +1 -1
- package/dist/components/Toast/index.cjs +1 -1
- package/dist/components/Toast/index.js +1 -1
- package/dist/components/TranslatedFields/index.cjs +1 -1
- package/dist/components/TranslatedFields/index.js +1 -1
- package/dist/components/UserCard/index.cjs +1 -1
- package/dist/components/UserCard/index.js +1 -1
- package/dist/components/index.d.cts +3 -0
- package/dist/components/index.d.ts +3 -0
- package/dist/entries/app.cjs +1 -1
- package/dist/entries/app.js +1 -1
- package/dist/entries/components.cjs +1 -1
- package/dist/entries/components.js +149 -141
- package/dist/entries/components.js.map +1 -1
- package/dist/entries/helpers.cjs +1 -1
- package/dist/entries/helpers.d.cts +2 -0
- package/dist/entries/helpers.d.ts +2 -0
- package/dist/entries/helpers.js +18 -8
- package/dist/entries/helpers.js.map +1 -1
- package/dist/entries/i18n.cjs +1 -1
- package/dist/entries/i18n.js +2 -2
- package/dist/entries/theme.cjs +1 -1
- package/dist/entries/theme.js +1 -1
- package/dist/helpers/color.d.cts +17 -0
- package/dist/helpers/color.d.ts +17 -0
- package/dist/helpers/palette.d.cts +68 -0
- package/dist/helpers/palette.d.ts +68 -0
- package/dist/i18n/messages.d.cts +11 -0
- package/dist/i18n/messages.d.ts +11 -0
- package/dist/index.cjs +1 -1
- package/dist/index.css +16 -12
- package/dist/index.js +211 -193
- package/dist/index.js.map +1 -1
- package/dist/{messages-ogohLC5P.js → messages-B06Kl5rI.js} +100 -23
- package/dist/messages-B06Kl5rI.js.map +1 -0
- package/dist/{messages-DKT0SRM0.cjs → messages-CJqxqL3t.cjs} +9 -9
- package/dist/messages-CJqxqL3t.cjs.map +1 -0
- package/dist/palette-B031dM4E.js +70 -0
- package/dist/palette-B031dM4E.js.map +1 -0
- package/dist/palette-BycMHbED.cjs +2 -0
- package/dist/palette-BycMHbED.cjs.map +1 -0
- package/dist/theme/ConfigProvider.d.cts +8 -8
- package/dist/theme/ConfigProvider.d.ts +8 -8
- package/package.json +1 -1
- package/dist/Avatar-Dgf04PBC.cjs +0 -2
- package/dist/Badge-BQpr2Jee.cjs +0 -2
- package/dist/Badge-DSWigoGC.js +0 -50
- package/dist/Button-CXmDOzPk.cjs +0 -2
- package/dist/Button-DBs8xnA5.js +0 -72
- package/dist/Chip-gUH_7nQc.cjs +0 -2
- package/dist/ChoiceCardGroup-DBohUnRj.js +0 -181
- package/dist/ChoiceCardGroup-d0VVTUi5.cjs +0 -2
- package/dist/ColorPicker-DtzFwNWk.cjs +0 -2
- package/dist/ColorPicker-DtzFwNWk.cjs.map +0 -1
- package/dist/ColorPicker-Dw6Qk0iy.js.map +0 -1
- package/dist/ColorPickerPanel--wBX-m7J.cjs +0 -2
- package/dist/ColorPickerPanel--wBX-m7J.cjs.map +0 -1
- package/dist/ColorPickerPanel-Dp7bnnVf.js +0 -336
- package/dist/ColorPickerPanel-Dp7bnnVf.js.map +0 -1
- package/dist/ConfigProvider-Bszl3Wr3.cjs.map +0 -1
- package/dist/ConfigProvider-DR9YMy9U.js.map +0 -1
- package/dist/CopyButton-Ct-8AmmX.cjs +0 -2
- package/dist/CopyButton-DJ1PSJZU.js +0 -31
- package/dist/DashedButton-3C4IZuo4.cjs +0 -2
- package/dist/DashedButton-BXZAyMtw.js +0 -59
- package/dist/DatePicker.module-BZDftL4g.js +0 -138
- package/dist/DatePicker.module-tE-tGNBd.cjs +0 -2
- package/dist/EmptyState-BTd7aVgu.js +0 -38
- package/dist/EmptyState-Bv4XXnD1.cjs +0 -2
- package/dist/FileUploader-B7VfhcR7.cjs +0 -2
- package/dist/FileUploader-B7VfhcR7.cjs.map +0 -1
- package/dist/FileUploader-BYF5FvUc.js.map +0 -1
- package/dist/IconButton-BEGWfcVc.js +0 -68
- package/dist/IconButton-BN-bZxEi.cjs +0 -2
- package/dist/Loader-B5YqzEYy.cjs +0 -2
- package/dist/Loader-BZIa8hwv.js +0 -29
- package/dist/PageNotFound-B8_eIT8p.cjs +0 -2
- package/dist/Pagination-BdVebW2L.cjs +0 -2
- package/dist/Pagination-CmskZjcz.js +0 -139
- package/dist/RadioGroup-C8u7eNBS.cjs +0 -2
- package/dist/RadioGroup-DbodUJW8.js +0 -141
- package/dist/RemoveDialog-CV75B0aN.js +0 -47
- package/dist/RemoveDialog-DmOk0ezc.cjs +0 -2
- package/dist/RichTextEditor-Bm8FFbcR.js.map +0 -1
- package/dist/RichTextEditor-uXddgtlk.cjs.map +0 -1
- package/dist/RootLayout-Cf7Rr9Iz.js +0 -515
- package/dist/RootLayout-kssj9exn.cjs +0 -2
- package/dist/Slider-dxYVXRev.cjs +0 -2
- package/dist/Slider-oGXd5e9X.js +0 -184
- package/dist/Stepper-B1z_u650.cjs +0 -2
- package/dist/Switch-DMPJ0fhB.js +0 -85
- package/dist/Switch-DRkZ6kHJ.cjs +0 -2
- package/dist/Table-BPit83Pn.cjs +0 -2
- package/dist/Table-BPit83Pn.cjs.map +0 -1
- package/dist/Table-Drdhfm99.js.map +0 -1
- package/dist/Tabs-BiKDy_fv.cjs +0 -2
- package/dist/Tabs-ytbBzAxG.js +0 -190
- package/dist/TextField.module-QePvGeJ3.js +0 -27
- package/dist/TextField.module-QePvGeJ3.js.map +0 -1
- package/dist/TextField.module-m-UllwzG.cjs +0 -2
- package/dist/TextField.module-m-UllwzG.cjs.map +0 -1
- package/dist/Timeline-D3kzt1dy.js +0 -71
- package/dist/Timeline-ONU_3gi3.cjs +0 -2
- package/dist/messages-DKT0SRM0.cjs.map +0 -1
- package/dist/messages-ogohLC5P.js.map +0 -1
package/dist/Button-DBs8xnA5.js
DELETED
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
import { jsxs as z, jsx as s } from "react/jsx-runtime";
|
|
2
|
-
import { forwardRef as W, isValidElement as v, cloneElement as y } from "react";
|
|
3
|
-
import { clsx as B } from "clsx";
|
|
4
|
-
import { L as i } from "./Loader-BZIa8hwv.js";
|
|
5
|
-
const E = "_button_eb4w2_1", j = "_sm_eb4w2_23", L = "_md_eb4w2_29", N = "_lg_eb4w2_35", $ = "_contained_eb4w2_42", A = "_filled_eb4w2_52", R = "_outlined_eb4w2_61", V = "_text_eb4w2_72", k = "_fullWidth_eb4w2_82", q = "_rounded_eb4w2_86", C = "_disabled_eb4w2_94", D = "_loading_eb4w2_98", F = "_label_eb4w2_103", t = {
|
|
6
|
-
button: E,
|
|
7
|
-
sm: j,
|
|
8
|
-
md: L,
|
|
9
|
-
lg: N,
|
|
10
|
-
contained: $,
|
|
11
|
-
filled: A,
|
|
12
|
-
outlined: R,
|
|
13
|
-
text: V,
|
|
14
|
-
fullWidth: k,
|
|
15
|
-
rounded: q,
|
|
16
|
-
disabled: C,
|
|
17
|
-
loading: D,
|
|
18
|
-
label: F
|
|
19
|
-
}, M = W(function({
|
|
20
|
-
variant: r = "contained",
|
|
21
|
-
color: d = "accent",
|
|
22
|
-
size: o = "md",
|
|
23
|
-
loading: e = !1,
|
|
24
|
-
fullWidth: u = !1,
|
|
25
|
-
rounded: f = !1,
|
|
26
|
-
disabled: _ = !1,
|
|
27
|
-
startIcon: a,
|
|
28
|
-
endIcon: m,
|
|
29
|
-
className: w,
|
|
30
|
-
style: p,
|
|
31
|
-
type: x = "button",
|
|
32
|
-
children: l,
|
|
33
|
-
...h
|
|
34
|
-
}, g) {
|
|
35
|
-
const b = e && !a, c = (n) => v(n) ? y(n, {
|
|
36
|
-
size: n.props.size ?? o
|
|
37
|
-
}) : n;
|
|
38
|
-
return /* @__PURE__ */ z(
|
|
39
|
-
"button",
|
|
40
|
-
{
|
|
41
|
-
ref: g,
|
|
42
|
-
type: x,
|
|
43
|
-
disabled: _ || e,
|
|
44
|
-
"aria-busy": e || void 0,
|
|
45
|
-
className: B(
|
|
46
|
-
t.button,
|
|
47
|
-
t[r],
|
|
48
|
-
t[o],
|
|
49
|
-
u && t.fullWidth,
|
|
50
|
-
f && t.rounded,
|
|
51
|
-
e && t.loading,
|
|
52
|
-
_ && t.disabled,
|
|
53
|
-
w
|
|
54
|
-
),
|
|
55
|
-
style: {
|
|
56
|
-
"--tz-btn-rgb": `var(--tz-color-${d}-rgb)`,
|
|
57
|
-
"--tz-btn-on": `var(--tz-color-${d}-contrast, #fff)`,
|
|
58
|
-
...p
|
|
59
|
-
},
|
|
60
|
-
...h,
|
|
61
|
-
children: [
|
|
62
|
-
e && !b ? /* @__PURE__ */ s(i, { size: o, "aria-hidden": "true" }) : c(a),
|
|
63
|
-
l != null && l !== !1 && /* @__PURE__ */ s("span", { className: t.label, children: l }),
|
|
64
|
-
b ? /* @__PURE__ */ s(i, { size: o, "aria-hidden": "true" }) : !e && c(m)
|
|
65
|
-
]
|
|
66
|
-
}
|
|
67
|
-
);
|
|
68
|
-
});
|
|
69
|
-
export {
|
|
70
|
-
M as B
|
|
71
|
-
};
|
|
72
|
-
//# sourceMappingURL=Button-DBs8xnA5.js.map
|
package/dist/Chip-gUH_7nQc.cjs
DELETED
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";const c=require("react/jsx-runtime"),w=require("react"),C=require("clsx"),I=require("./Icon-BVULqOJD.cjs"),q=require("./ConfigProvider-Bszl3Wr3.cjs"),A="_chip_1yjgf_3",B="_sm_1yjgf_20",N="_md_1yjgf_25",z="_lg_1yjgf_30",P="_contained_1yjgf_37",R="_filled_1yjgf_42",T="_outlined_1yjgf_46",$="_text_1yjgf_51",E="_clickable_1yjgf_57",M="_disabled_1yjgf_82",D="_startIcon_1yjgf_89",F="_avatar_1yjgf_95",G="_withAvatar_1yjgf_102",H="_withDelete_1yjgf_106",J="_deleteBtn_1yjgf_127",t={chip:A,sm:B,md:N,lg:z,contained:P,filled:R,outlined:T,text:$,clickable:E,disabled:M,startIcon:D,avatar:F,withAvatar:G,withDelete:H,deleteBtn:J},L=w.forwardRef(function({variant:f="filled",color:r="primary",size:_="md",clickable:u=!1,disabled:n=!1,startIcon:d,avatar:l,onDelete:s,deleteIcon:g,deleteLabel:j,deleteTabIndex:h,className:y,style:m,children:i,onKeyDown:o,...p},b){const x=q.useT(),a=u&&!n,v=e=>{e.stopPropagation(),n||s==null||s()},k=e=>{a&&(e.key==="Enter"||e.key===" ")&&(e.preventDefault(),e.currentTarget.click()),o==null||o(e)};return c.jsxs("div",{ref:b,className:C.clsx(t.chip,t[f],t[_],a&&t.clickable,n&&t.disabled,l&&t.withAvatar,s&&t.withDelete,y),style:{"--tz-btn-rgb":`var(--tz-color-${r}-rgb)`,"--tz-btn-on":`var(--tz-color-${r}-contrast, #fff)`,...m},role:a?"button":void 0,tabIndex:a?0:void 0,"aria-disabled":n||void 0,onKeyDown:k,...p,children:[l?c.jsx("span",{className:t.avatar,children:l}):d?c.jsx("span",{className:t.startIcon,children:d}):null,i!=null&&i!==""?c.jsx("span",{children:i}):null,s?c.jsx("button",{type:"button",className:t.deleteBtn,onClick:v,onMouseDown:e=>e.preventDefault(),"aria-label":j??x("common.remove"),tabIndex:h,disabled:n,children:g??c.jsx(I.Icon,{name:"CloseCircle",size:_})}):null]})});exports.Chip=L;
|
|
2
|
-
//# sourceMappingURL=Chip-gUH_7nQc.cjs.map
|
|
@@ -1,181 +0,0 @@
|
|
|
1
|
-
import { jsx as t, jsxs as S } from "react/jsx-runtime";
|
|
2
|
-
import { useContext as P, createContext as R, forwardRef as j, useState as w, useId as H } from "react";
|
|
3
|
-
import { clsx as k } from "clsx";
|
|
4
|
-
import { u as J } from "./formContext-B7ln1Miy.js";
|
|
5
|
-
import { T as K } from "./Typography-Cta6Rg4L.js";
|
|
6
|
-
import { a as Q } from "./names-r21QPjcU.js";
|
|
7
|
-
import { I as U } from "./Icon-DaTvzLBu.js";
|
|
8
|
-
const F = R(null);
|
|
9
|
-
function W() {
|
|
10
|
-
return P(F);
|
|
11
|
-
}
|
|
12
|
-
const X = "_group_3p33b_2", Y = "_groupLabel_3p33b_8", Z = "_required_3p33b_13", ee = "_grid_3p33b_17", re = "_card_3p33b_24", se = "_disabled_3p33b_42", te = "_selected_3p33b_42", oe = "_input_3p33b_51", le = "_error_3p33b_55", ae = "_left_3p33b_67", ce = "_text_3p33b_71", ie = "_sm_3p33b_77", ne = "_md_3p33b_85", de = "_lg_3p33b_93", _e = "_indicator_3p33b_117", pe = "_radioDot_3p33b_162", me = "_iconBox_3p33b_185", be = "_label_3p33b_212", ue = "_description_3p33b_219", r = {
|
|
13
|
-
group: X,
|
|
14
|
-
groupLabel: Y,
|
|
15
|
-
required: Z,
|
|
16
|
-
grid: ee,
|
|
17
|
-
card: re,
|
|
18
|
-
disabled: se,
|
|
19
|
-
selected: te,
|
|
20
|
-
input: oe,
|
|
21
|
-
error: le,
|
|
22
|
-
left: ae,
|
|
23
|
-
text: ce,
|
|
24
|
-
sm: ie,
|
|
25
|
-
md: ne,
|
|
26
|
-
lg: de,
|
|
27
|
-
indicator: _e,
|
|
28
|
-
radioDot: pe,
|
|
29
|
-
iconBox: me,
|
|
30
|
-
label: be,
|
|
31
|
-
description: ue
|
|
32
|
-
}, fe = new Set(Q), he = j(function({
|
|
33
|
-
value: l,
|
|
34
|
-
label: n,
|
|
35
|
-
description: d,
|
|
36
|
-
icon: o,
|
|
37
|
-
align: a,
|
|
38
|
-
color: h,
|
|
39
|
-
size: x,
|
|
40
|
-
error: I,
|
|
41
|
-
checked: _,
|
|
42
|
-
onChange: p,
|
|
43
|
-
name: z,
|
|
44
|
-
disabled: A,
|
|
45
|
-
className: B,
|
|
46
|
-
style: D,
|
|
47
|
-
...E
|
|
48
|
-
}, q) {
|
|
49
|
-
const e = W(), v = h ?? (e == null ? void 0 : e.color) ?? "primary", N = x ?? (e == null ? void 0 : e.size) ?? "md", C = I ?? (e == null ? void 0 : e.error) ?? !1, m = A ?? (e == null ? void 0 : e.disabled) ?? !1, i = z ?? (e == null ? void 0 : e.name), y = a ?? (e == null ? void 0 : e.align) ?? (o == null ? "left" : "center"), [b, g] = w(!1), u = e ? e.isSelected(l) : _ !== void 0 ? _ : b, G = (c) => {
|
|
50
|
-
if (!m) {
|
|
51
|
-
if (e) {
|
|
52
|
-
e.toggle(l);
|
|
53
|
-
return;
|
|
54
|
-
}
|
|
55
|
-
_ === void 0 && g(c.target.checked), p == null || p(c.target.checked);
|
|
56
|
-
}
|
|
57
|
-
}, L = typeof o == "string" && fe.has(o) ? /* @__PURE__ */ t(U, { name: o, size: N }) : o;
|
|
58
|
-
return /* @__PURE__ */ S(
|
|
59
|
-
"label",
|
|
60
|
-
{
|
|
61
|
-
className: k(
|
|
62
|
-
r.card,
|
|
63
|
-
r[N],
|
|
64
|
-
y === "left" && r.left,
|
|
65
|
-
u && r.selected,
|
|
66
|
-
C && r.error,
|
|
67
|
-
m && r.disabled,
|
|
68
|
-
B
|
|
69
|
-
),
|
|
70
|
-
style: {
|
|
71
|
-
"--tz-btn-rgb": `var(--tz-color-${v}-rgb)`,
|
|
72
|
-
"--tz-btn-on": `var(--tz-color-${v}-contrast, #fff)`,
|
|
73
|
-
...D
|
|
74
|
-
},
|
|
75
|
-
children: [
|
|
76
|
-
/* @__PURE__ */ t(
|
|
77
|
-
"input",
|
|
78
|
-
{
|
|
79
|
-
ref: q,
|
|
80
|
-
type: e != null && e.exclusive ? "radio" : "checkbox",
|
|
81
|
-
className: r.input,
|
|
82
|
-
name: i,
|
|
83
|
-
value: l,
|
|
84
|
-
checked: u,
|
|
85
|
-
onChange: G,
|
|
86
|
-
disabled: m,
|
|
87
|
-
"aria-invalid": C || void 0,
|
|
88
|
-
...E
|
|
89
|
-
}
|
|
90
|
-
),
|
|
91
|
-
/* @__PURE__ */ t(
|
|
92
|
-
"span",
|
|
93
|
-
{
|
|
94
|
-
className: k(r.indicator, (e == null ? void 0 : e.exclusive) && r.radioDot),
|
|
95
|
-
"aria-hidden": "true"
|
|
96
|
-
}
|
|
97
|
-
),
|
|
98
|
-
o != null && /* @__PURE__ */ t("span", { className: r.iconBox, "aria-hidden": "true", children: L }),
|
|
99
|
-
(n != null || d != null) && /* @__PURE__ */ S("span", { className: r.text, children: [
|
|
100
|
-
n != null && /* @__PURE__ */ t("span", { className: r.label, children: n }),
|
|
101
|
-
d != null && /* @__PURE__ */ t("span", { className: r.description, children: d })
|
|
102
|
-
] })
|
|
103
|
-
]
|
|
104
|
-
}
|
|
105
|
-
);
|
|
106
|
-
}), Ae = j(
|
|
107
|
-
function({
|
|
108
|
-
exclusive: l = !1,
|
|
109
|
-
value: n,
|
|
110
|
-
defaultValue: d,
|
|
111
|
-
onChange: o,
|
|
112
|
-
name: a,
|
|
113
|
-
options: h,
|
|
114
|
-
label: x,
|
|
115
|
-
minCardWidth: I = 160,
|
|
116
|
-
align: _,
|
|
117
|
-
size: p = "md",
|
|
118
|
-
color: z = "primary",
|
|
119
|
-
error: A,
|
|
120
|
-
required: B = !1,
|
|
121
|
-
disabled: D = !1,
|
|
122
|
-
children: E,
|
|
123
|
-
className: q,
|
|
124
|
-
style: e,
|
|
125
|
-
...v
|
|
126
|
-
}, N) {
|
|
127
|
-
const C = H(), m = a ?? `choice-${C}`, i = J(), y = !!(i && a), b = i && a ? i.field(a) : void 0, g = n !== void 0 ? n : y ? i.values[a] : void 0, u = g !== void 0, [G, L] = w(d), c = u ? g : G, T = A ?? (b == null ? void 0 : b.error) ?? !1, O = {
|
|
128
|
-
name: m,
|
|
129
|
-
exclusive: l,
|
|
130
|
-
isSelected: (s) => l ? c === s : Array.isArray(c) && c.includes(s),
|
|
131
|
-
toggle: (s) => {
|
|
132
|
-
let f;
|
|
133
|
-
if (l)
|
|
134
|
-
f = s;
|
|
135
|
-
else {
|
|
136
|
-
const $ = Array.isArray(c) ? c : [];
|
|
137
|
-
f = $.includes(s) ? $.filter((V) => V !== s) : [...$, s];
|
|
138
|
-
}
|
|
139
|
-
u || L(f), y && i.setValue(a, f), o == null || o(f);
|
|
140
|
-
},
|
|
141
|
-
size: p,
|
|
142
|
-
align: _,
|
|
143
|
-
color: z,
|
|
144
|
-
disabled: D,
|
|
145
|
-
error: T
|
|
146
|
-
};
|
|
147
|
-
return /* @__PURE__ */ S(
|
|
148
|
-
"div",
|
|
149
|
-
{
|
|
150
|
-
ref: N,
|
|
151
|
-
role: l ? "radiogroup" : "group",
|
|
152
|
-
"aria-invalid": T || void 0,
|
|
153
|
-
className: k(r.group, q),
|
|
154
|
-
style: e,
|
|
155
|
-
...v,
|
|
156
|
-
children: [
|
|
157
|
-
x != null && /* @__PURE__ */ S("span", { className: r.groupLabel, children: [
|
|
158
|
-
/* @__PURE__ */ t(K, { as: "span", variant: "bodySmall", color: "muted", children: x }),
|
|
159
|
-
B && /* @__PURE__ */ t("span", { className: r.required, "aria-hidden": "true", children: "*" })
|
|
160
|
-
] }),
|
|
161
|
-
/* @__PURE__ */ t("div", { className: r.grid, style: { "--cc-min": `${I}px` }, children: /* @__PURE__ */ t(F.Provider, { value: O, children: h ? h.map((s) => /* @__PURE__ */ t(
|
|
162
|
-
he,
|
|
163
|
-
{
|
|
164
|
-
value: s.value,
|
|
165
|
-
label: s.label,
|
|
166
|
-
description: s.description,
|
|
167
|
-
icon: s.icon,
|
|
168
|
-
disabled: s.disabled
|
|
169
|
-
},
|
|
170
|
-
s.value
|
|
171
|
-
)) : E }) })
|
|
172
|
-
]
|
|
173
|
-
}
|
|
174
|
-
);
|
|
175
|
-
}
|
|
176
|
-
);
|
|
177
|
-
export {
|
|
178
|
-
he as C,
|
|
179
|
-
Ae as a
|
|
180
|
-
};
|
|
181
|
-
//# sourceMappingURL=ChoiceCardGroup-DBohUnRj.js.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";const r=require("react/jsx-runtime"),a=require("react"),$=require("clsx"),O=require("./formContext-bTWrqdEV.cjs"),V=require("./Typography-BFatE1_A.cjs"),P=require("./names-BJnFU_5m.cjs"),H=require("./Icon-BVULqOJD.cjs"),w=a.createContext(null);function J(){return a.useContext(w)}const K="_group_3p33b_2",Q="_groupLabel_3p33b_8",U="_required_3p33b_13",W="_grid_3p33b_17",X="_card_3p33b_24",Y="_disabled_3p33b_42",Z="_selected_3p33b_42",ee="_input_3p33b_51",se="_error_3p33b_55",re="_left_3p33b_67",te="_text_3p33b_71",oe="_sm_3p33b_77",ce="_md_3p33b_85",le="_lg_3p33b_93",ne="_indicator_3p33b_117",ie="_radioDot_3p33b_162",ae="_iconBox_3p33b_185",de="_label_3p33b_212",_e="_description_3p33b_219",s={group:K,groupLabel:Q,required:U,grid:W,card:X,disabled:Y,selected:Z,input:ee,error:se,left:re,text:te,sm:oe,md:ce,lg:le,indicator:ne,radioDot:ie,iconBox:ae,label:de,description:_e},ue=new Set(P.ICON_NAMES),R=a.forwardRef(function({value:c,label:d,description:_,icon:o,align:l,color:h,size:C,error:q,checked:u,onChange:b,name:S,disabled:I,className:z,style:A,...B},D){const e=J(),v=h??(e==null?void 0:e.color)??"primary",N=C??(e==null?void 0:e.size)??"md",j=q??(e==null?void 0:e.error)??!1,p=I??(e==null?void 0:e.disabled)??!1,i=S??(e==null?void 0:e.name),y=l??(e==null?void 0:e.align)??(o==null?"left":"center"),[x,g]=a.useState(!1),f=e?e.isSelected(c):u!==void 0?u:x,E=n=>{if(!p){if(e){e.toggle(c);return}u===void 0&&g(n.target.checked),b==null||b(n.target.checked)}},G=typeof o=="string"&&ue.has(o)?r.jsx(H.Icon,{name:o,size:N}):o;return r.jsxs("label",{className:$.clsx(s.card,s[N],y==="left"&&s.left,f&&s.selected,j&&s.error,p&&s.disabled,z),style:{"--tz-btn-rgb":`var(--tz-color-${v}-rgb)`,"--tz-btn-on":`var(--tz-color-${v}-contrast, #fff)`,...A},children:[r.jsx("input",{ref:D,type:e!=null&&e.exclusive?"radio":"checkbox",className:s.input,name:i,value:c,checked:f,onChange:E,disabled:p,"aria-invalid":j||void 0,...B}),r.jsx("span",{className:$.clsx(s.indicator,(e==null?void 0:e.exclusive)&&s.radioDot),"aria-hidden":"true"}),o!=null&&r.jsx("span",{className:s.iconBox,"aria-hidden":"true",children:G}),(d!=null||_!=null)&&r.jsxs("span",{className:s.text,children:[d!=null&&r.jsx("span",{className:s.label,children:d}),_!=null&&r.jsx("span",{className:s.description,children:_})]})]})}),be=a.forwardRef(function({exclusive:c=!1,value:d,defaultValue:_,onChange:o,name:l,options:h,label:C,minCardWidth:q=160,align:u,size:b="md",color:S="primary",error:I,required:z=!1,disabled:A=!1,children:B,className:D,style:e,...v},N){const j=a.useId(),p=l??`choice-${j}`,i=O.useFormContext(),y=!!(i&&l),x=i&&l?i.field(l):void 0,g=d!==void 0?d:y?i.values[l]:void 0,f=g!==void 0,[E,G]=a.useState(_),n=f?g:E,k=I??(x==null?void 0:x.error)??!1,F={name:p,exclusive:c,isSelected:t=>c?n===t:Array.isArray(n)&&n.includes(t),toggle:t=>{let m;if(c)m=t;else{const L=Array.isArray(n)?n:[];m=L.includes(t)?L.filter(M=>M!==t):[...L,t]}f||G(m),y&&i.setValue(l,m),o==null||o(m)},size:b,align:u,color:S,disabled:A,error:k};return r.jsxs("div",{ref:N,role:c?"radiogroup":"group","aria-invalid":k||void 0,className:$.clsx(s.group,D),style:e,...v,children:[C!=null&&r.jsxs("span",{className:s.groupLabel,children:[r.jsx(V.Typography,{as:"span",variant:"bodySmall",color:"muted",children:C}),z&&r.jsx("span",{className:s.required,"aria-hidden":"true",children:"*"})]}),r.jsx("div",{className:s.grid,style:{"--cc-min":`${q}px`},children:r.jsx(w.Provider,{value:F,children:h?h.map(t=>r.jsx(R,{value:t.value,label:t.label,description:t.description,icon:t.icon,disabled:t.disabled},t.value)):B})})]})});exports.ChoiceCard=R;exports.ChoiceCardGroup=be;
|
|
2
|
-
//# sourceMappingURL=ChoiceCardGroup-d0VVTUi5.cjs.map
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";const r=require("react/jsx-runtime"),t=require("react"),p=require("clsx"),X=require("./formContext-bTWrqdEV.cjs"),Y=require("./FloatingPanel-U6sGYiSK.cjs"),I=require("./Typography-BFatE1_A.cjs"),e=require("./ColorPickerPanel--wBX-m7J.cjs"),Z=require("./ConfigProvider-Bszl3Wr3.cjs"),ee=232,se=t.forwardRef(function({label:y,size:w="md",error:S,helperText:V,required:E=!1,fullWidth:O=!0,disabled:C=!1,value:P,defaultValue:H,onChange:f,swatches:W,name:o,placeholder:g,id:D,className:L,style:U},a){const _=Z.useT(),$=t.useId(),x=D??$,j=`${x}-helper`,c=X.useFormContext(),k=!!(c&&o),l=c&&o?c.field(o):void 0,T=P!==void 0?P:k?c.values[o]??"":void 0,q=T!==void 0,[z,A]=t.useState(H??""),R=q?T:z,i=e.parseColor(R||""),u=i?e.formatColor(i):null,G=u?u[0]==="#"?u.toUpperCase():u:null,v=S??(l==null?void 0:l.error)??!1,h=V??(l==null?void 0:l.helperText),J=s=>{q||A(s),k&&c.setValue(o,s),f==null||f(s)},d=t.useRef(null),N=t.useRef(null),[m,b]=t.useState(!1),K=t.useCallback(s=>{d.current=s,typeof a=="function"?a(s):a&&(a.current=s)},[a]),M=t.useCallback(s=>{var n;b(!1),s&&((n=d.current)==null||n.focus())},[]),Q=s=>{var B,F;const n=s.relatedTarget;n&&((B=N.current)!=null&&B.contains(n)||(F=d.current)!=null&&F.contains(n))||l==null||l.onBlur(s)};return r.jsxs("div",{className:p.clsx(e.styles.field,e.styles[w],O&&e.styles.fullWidth,v&&e.styles.error,C&&e.styles.disabled,L),style:U,children:[y!=null&&r.jsxs("label",{htmlFor:x,className:e.styles.label,children:[r.jsx(I.Typography,{as:"span",variant:"bodySmall",color:"muted",children:y}),E&&r.jsx("span",{className:e.styles.required,"aria-hidden":"true",children:"*"})]}),r.jsxs("button",{ref:K,id:x,name:o,type:"button",className:p.clsx(e.styles.control,m&&e.styles.open),disabled:C,"aria-haspopup":"dialog","aria-expanded":m,"aria-invalid":v||void 0,"aria-describedby":h!=null?j:void 0,"aria-label":y||i||g?void 0:_("colorPicker.pick"),onClick:()=>b(s=>!s),onBlur:Q,children:[r.jsx("span",{className:p.clsx(e.styles.value,!i&&e.styles.placeholder),children:G??g}),r.jsx("span",{className:p.clsx(e.styles.preview,!i&&e.styles.previewEmpty),style:i?{"--cp-fill":u}:void 0,"aria-hidden":"true"})]}),r.jsx(Y.FloatingPanel,{ref:N,open:m,triggerRef:d,onClose:M,role:"dialog",ariaLabel:"Color picker",width:ee,children:r.jsx(e.ColorPickerPanel,{value:R,onChange:J,swatches:W})}),h!=null&&r.jsx(I.Typography,{as:"span",id:j,variant:"bodySmall",color:v?"error":"muted",className:e.styles.helper,children:h})]})});exports.ColorPicker=se;
|
|
2
|
-
//# sourceMappingURL=ColorPicker-DtzFwNWk.cjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ColorPicker-DtzFwNWk.cjs","sources":["../src/components/ColorPicker/ColorPicker.tsx"],"sourcesContent":["import {\n forwardRef,\n useCallback,\n useId,\n useRef,\n useState,\n type CSSProperties,\n type FocusEvent,\n type ReactNode,\n} from 'react'\nimport { clsx } from 'clsx'\nimport { useFormContext } from '../../form/formContext'\nimport { useT } from '../../theme'\nimport { FloatingPanel } from '../FloatingPanel/FloatingPanel'\nimport { Typography } from '../Typography'\nimport { ColorPickerPanel } from './ColorPickerPanel'\nimport { formatColor, parseColor } from './colorUtils'\nimport styles from './ColorPicker.module.css'\n\nexport type ColorPickerSize = 'sm' | 'md' | 'lg'\n\n/** Popover width (px). */\nconst POPOVER_WIDTH = 232\n\nexport interface ColorPickerProps {\n /** Label rendered above the field. */\n label?: ReactNode\n /** Preset size — control height, swatch and font. */\n size?: ColorPickerSize\n /** Marks the field invalid: red border/ring + the `helperText` in the error color. */\n error?: boolean\n /** Helper / validation text under the field. Adopts the error color while `error`. */\n helperText?: ReactNode\n /** Adds a red asterisk after the label. */\n required?: boolean\n /** Stretches the field to fill its container width. Defaults to `true`. */\n fullWidth?: boolean\n /** Disables the field. */\n disabled?: boolean\n /** Controlled value — a CSS color string: `#rrggbb` hex, or `rgba(r, g, b, a)` when translucent. */\n value?: string\n /** Initial value for uncontrolled use (hex or `rgb()`/`rgba()`). */\n defaultValue?: string\n /** Fires with the next color: `#rrggbb` when opaque, `rgba(r, g, b, a)` when not (or `''` when cleared). */\n onChange?: (color: string) => void\n /** Quick-pick swatches shown in the popover. Defaults to a curated palette. */\n swatches?: string[]\n /** Form field name — auto-binds to a surrounding `<Form>` (value is the hex string). */\n name?: string\n /** Placeholder shown in the trigger when no color is set. Omit to show nothing. */\n placeholder?: string\n /** Id for the trigger (label association). */\n id?: string\n className?: string\n style?: CSSProperties\n}\n\n/**\n * A color field with a beautiful popover picker: a saturation/value square, a hue slider, an alpha\n * (opacity) slider, a color input, quick-pick swatches and a clear button. The input accepts hex\n * (`#rgb`/`#rrggbb`/`#rrggbbaa`) or `rgb()`/`rgba()`, and the value comes back as `#rrggbb` when\n * fully opaque or `rgba(r, g, b, a)` when translucent. Clicking the trigger opens the popover, which\n * — like `Dropdown` — is portaled to `<body>`, opens below (flips above only when it would\n * overflow), locks page scroll and re-positions on scroll/resize. Controlled (`value` + `onChange`)\n * or uncontrolled (`defaultValue`), and binds to a surrounding `<Form>` by `name` (its form value is\n * the color string; validate with e.g. `z.string().regex(/^#[0-9a-f]{6}$/i, 'Pick a color')`, or a\n * looser pattern if you allow `rgba()`). Styling uses `--tz-*` tokens (the spectrum gradients and\n * the alpha checkerboard are the unavoidable exceptions).\n */\nexport const ColorPicker = forwardRef<HTMLButtonElement, ColorPickerProps>(function ColorPicker(\n {\n label,\n size = 'md',\n error,\n helperText,\n required = false,\n fullWidth = true,\n disabled = false,\n value,\n defaultValue,\n onChange,\n swatches,\n name,\n placeholder,\n id: idProp,\n className,\n style,\n },\n ref,\n) {\n const t = useT()\n const reactId = useId()\n const id = idProp ?? reactId\n const helperId = `${id}-helper`\n\n // Auto-bind to a surrounding <Form> by `name` — the form value is the hex string.\n const form = useFormContext()\n const isFormBound = Boolean(form && name)\n const bound = form && name ? form.field(name) : undefined\n\n const externalValue: string | undefined =\n value !== undefined\n ? value\n : isFormBound\n ? ((form!.values[name!] as string | undefined) ?? '')\n : undefined\n const isControlled = externalValue !== undefined\n const [internal, setInternal] = useState<string>(defaultValue ?? '')\n const currentColor = isControlled ? externalValue! : internal\n const parsed = parseColor(currentColor || '')\n // canonical string for the value (`#rrggbb` when opaque, `rgba(...)` when not), null when unset\n const displayValue = parsed ? formatColor(parsed) : null\n // hex shows uppercase in the trigger; rgba() stays as-is\n const displayText = displayValue\n ? displayValue[0] === '#'\n ? displayValue.toUpperCase()\n : displayValue\n : null\n\n const resolvedError = error ?? bound?.error ?? false\n const resolvedHelperText = helperText ?? bound?.helperText\n\n const commit = (color: string) => {\n if (!isControlled) setInternal(color)\n if (isFormBound) form!.setValue(name!, color)\n onChange?.(color)\n }\n\n // ── popover (positioning / scroll-lock / dismiss come from FloatingPanel) ──────────────────────\n const triggerRef = useRef<HTMLButtonElement | null>(null)\n const popoverRef = useRef<HTMLDivElement | null>(null)\n const [open, setOpen] = useState(false)\n\n const setTriggerRef = useCallback(\n (node: HTMLButtonElement | null) => {\n triggerRef.current = node\n if (typeof ref === 'function') ref(node)\n else if (ref) (ref as { current: HTMLButtonElement | null }).current = node\n },\n [ref],\n )\n\n const closePopover = useCallback((refocus: boolean) => {\n setOpen(false)\n if (refocus) triggerRef.current?.focus()\n }, [])\n\n // mark the form field touched when focus leaves the whole widget — but not when it moves into the\n // (portaled) popover or stays on the trigger, so a form-bound picker shows its error like every\n // other popover field (Select/DatePicker) instead of only after submit\n const handleTriggerBlur = (event: FocusEvent<HTMLButtonElement>) => {\n const next = event.relatedTarget as Node | null\n if (next && (popoverRef.current?.contains(next) || triggerRef.current?.contains(next))) return\n bound?.onBlur(event as unknown as FocusEvent<HTMLInputElement>)\n }\n\n return (\n <div\n className={clsx(\n styles.field,\n styles[size],\n fullWidth && styles.fullWidth,\n resolvedError && styles.error,\n disabled && styles.disabled,\n className,\n )}\n style={style}\n >\n {label != null && (\n <label htmlFor={id} className={styles.label}>\n <Typography as=\"span\" variant=\"bodySmall\" color=\"muted\">\n {label}\n </Typography>\n {required && (\n <span className={styles.required} aria-hidden=\"true\">\n *\n </span>\n )}\n </label>\n )}\n\n <button\n ref={setTriggerRef}\n id={id}\n name={name}\n type=\"button\"\n className={clsx(styles.control, open && styles.open)}\n disabled={disabled}\n aria-haspopup=\"dialog\"\n aria-expanded={open}\n aria-invalid={resolvedError || undefined}\n aria-describedby={resolvedHelperText != null ? helperId : undefined}\n aria-label={label || parsed || placeholder ? undefined : t('colorPicker.pick')}\n onClick={() => setOpen((o) => !o)}\n onBlur={handleTriggerBlur}\n >\n <span className={clsx(styles.value, !parsed && styles.placeholder)}>\n {displayText ?? placeholder}\n </span>\n <span\n className={clsx(styles.preview, !parsed && styles.previewEmpty)}\n style={parsed ? ({ '--cp-fill': displayValue } as CSSProperties) : undefined}\n aria-hidden=\"true\"\n />\n </button>\n\n <FloatingPanel\n ref={popoverRef}\n open={open}\n triggerRef={triggerRef}\n onClose={closePopover}\n role=\"dialog\"\n ariaLabel=\"Color picker\"\n width={POPOVER_WIDTH}\n >\n <ColorPickerPanel value={currentColor} onChange={commit} swatches={swatches} />\n </FloatingPanel>\n\n {resolvedHelperText != null && (\n <Typography\n as=\"span\"\n id={helperId}\n variant=\"bodySmall\"\n color={resolvedError ? 'error' : 'muted'}\n className={styles.helper}\n >\n {resolvedHelperText}\n </Typography>\n )}\n </div>\n )\n})\n"],"names":["POPOVER_WIDTH","ColorPicker","forwardRef","label","size","error","helperText","required","fullWidth","disabled","value","defaultValue","onChange","swatches","name","placeholder","idProp","className","style","ref","t","useT","reactId","useId","id","helperId","form","useFormContext","isFormBound","bound","externalValue","isControlled","internal","setInternal","useState","currentColor","parsed","parseColor","displayValue","formatColor","displayText","resolvedError","resolvedHelperText","commit","color","triggerRef","useRef","popoverRef","open","setOpen","setTriggerRef","useCallback","node","closePopover","refocus","_a","handleTriggerBlur","event","next","_b","jsxs","clsx","styles","jsx","Typography","o","FloatingPanel","ColorPickerPanel"],"mappings":"wSAsBMA,GAAgB,IA+CTC,GAAcC,EAAAA,WAAgD,SACzE,CACE,MAAAC,EACA,KAAAC,EAAO,KACP,MAAAC,EACA,WAAAC,EACA,SAAAC,EAAW,GACX,UAAAC,EAAY,GACZ,SAAAC,EAAW,GACX,MAAAC,EACA,aAAAC,EACA,SAAAC,EACA,SAAAC,EACA,KAAAC,EACA,YAAAC,EACA,GAAIC,EACJ,UAAAC,EACA,MAAAC,CACF,EACAC,EACA,CACA,MAAMC,EAAIC,EAAAA,KAAA,EACJC,EAAUC,EAAAA,MAAA,EACVC,EAAKR,GAAUM,EACfG,EAAW,GA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AAA,CAAA,CACd,CAAA,CAAA,EAGFyB,EAAAA,IAACG,EAAAA,cAAA,CACC,IAAKnB,EACL,KAAAC,EACA,WAAAH,EACA,QAASQ,EACT,KAAK,SACL,UAAU,eACV,MAAOrD,GAEP,eAACmE,EAAAA,iBAAA,CAAiB,MAAOhC,EAAc,SAAUQ,EAAQ,SAAA9B,CAAA,CAAoB,CAAA,CAAA,EAG9E6B,GAAsB,MACrBqB,EAAAA,IAACC,EAAAA,WAAA,CACC,GAAG,OACH,GAAIvC,EACJ,QAAQ,YACR,MAAOgB,EAAgB,QAAU,QACjC,UAAWqB,EAAAA,OAAO,OAEjB,SAAApB,CAAA,CAAA,CACH,CAAA,CAAA,CAIR,CAAC"}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ColorPicker-Dw6Qk0iy.js","sources":["../src/components/ColorPicker/ColorPicker.tsx"],"sourcesContent":["import {\n forwardRef,\n useCallback,\n useId,\n useRef,\n useState,\n type CSSProperties,\n type FocusEvent,\n type ReactNode,\n} from 'react'\nimport { clsx } from 'clsx'\nimport { useFormContext } from '../../form/formContext'\nimport { useT } from '../../theme'\nimport { FloatingPanel } from '../FloatingPanel/FloatingPanel'\nimport { Typography } from '../Typography'\nimport { ColorPickerPanel } from './ColorPickerPanel'\nimport { formatColor, parseColor } from './colorUtils'\nimport styles from './ColorPicker.module.css'\n\nexport type ColorPickerSize = 'sm' | 'md' | 'lg'\n\n/** Popover width (px). */\nconst POPOVER_WIDTH = 232\n\nexport interface ColorPickerProps {\n /** Label rendered above the field. */\n label?: ReactNode\n /** Preset size — control height, swatch and font. */\n size?: ColorPickerSize\n /** Marks the field invalid: red border/ring + the `helperText` in the error color. */\n error?: boolean\n /** Helper / validation text under the field. Adopts the error color while `error`. */\n helperText?: ReactNode\n /** Adds a red asterisk after the label. */\n required?: boolean\n /** Stretches the field to fill its container width. Defaults to `true`. */\n fullWidth?: boolean\n /** Disables the field. */\n disabled?: boolean\n /** Controlled value — a CSS color string: `#rrggbb` hex, or `rgba(r, g, b, a)` when translucent. */\n value?: string\n /** Initial value for uncontrolled use (hex or `rgb()`/`rgba()`). */\n defaultValue?: string\n /** Fires with the next color: `#rrggbb` when opaque, `rgba(r, g, b, a)` when not (or `''` when cleared). */\n onChange?: (color: string) => void\n /** Quick-pick swatches shown in the popover. Defaults to a curated palette. */\n swatches?: string[]\n /** Form field name — auto-binds to a surrounding `<Form>` (value is the hex string). */\n name?: string\n /** Placeholder shown in the trigger when no color is set. Omit to show nothing. */\n placeholder?: string\n /** Id for the trigger (label association). */\n id?: string\n className?: string\n style?: CSSProperties\n}\n\n/**\n * A color field with a beautiful popover picker: a saturation/value square, a hue slider, an alpha\n * (opacity) slider, a color input, quick-pick swatches and a clear button. The input accepts hex\n * (`#rgb`/`#rrggbb`/`#rrggbbaa`) or `rgb()`/`rgba()`, and the value comes back as `#rrggbb` when\n * fully opaque or `rgba(r, g, b, a)` when translucent. Clicking the trigger opens the popover, which\n * — like `Dropdown` — is portaled to `<body>`, opens below (flips above only when it would\n * overflow), locks page scroll and re-positions on scroll/resize. Controlled (`value` + `onChange`)\n * or uncontrolled (`defaultValue`), and binds to a surrounding `<Form>` by `name` (its form value is\n * the color string; validate with e.g. `z.string().regex(/^#[0-9a-f]{6}$/i, 'Pick a color')`, or a\n * looser pattern if you allow `rgba()`). Styling uses `--tz-*` tokens (the spectrum gradients and\n * the alpha checkerboard are the unavoidable exceptions).\n */\nexport const ColorPicker = forwardRef<HTMLButtonElement, ColorPickerProps>(function ColorPicker(\n {\n label,\n size = 'md',\n error,\n helperText,\n required = false,\n fullWidth = true,\n disabled = false,\n value,\n defaultValue,\n onChange,\n swatches,\n name,\n placeholder,\n id: idProp,\n className,\n style,\n },\n ref,\n) {\n const t = useT()\n const reactId = useId()\n const id = idProp ?? reactId\n const helperId = `${id}-helper`\n\n // Auto-bind to a surrounding <Form> by `name` — the form value is the hex string.\n const form = useFormContext()\n const isFormBound = Boolean(form && name)\n const bound = form && name ? form.field(name) : undefined\n\n const externalValue: string | undefined =\n value !== undefined\n ? value\n : isFormBound\n ? ((form!.values[name!] as string | undefined) ?? '')\n : undefined\n const isControlled = externalValue !== undefined\n const [internal, setInternal] = useState<string>(defaultValue ?? '')\n const currentColor = isControlled ? externalValue! : internal\n const parsed = parseColor(currentColor || '')\n // canonical string for the value (`#rrggbb` when opaque, `rgba(...)` when not), null when unset\n const displayValue = parsed ? formatColor(parsed) : null\n // hex shows uppercase in the trigger; rgba() stays as-is\n const displayText = displayValue\n ? displayValue[0] === '#'\n ? displayValue.toUpperCase()\n : displayValue\n : null\n\n const resolvedError = error ?? bound?.error ?? false\n const resolvedHelperText = helperText ?? bound?.helperText\n\n const commit = (color: string) => {\n if (!isControlled) setInternal(color)\n if (isFormBound) form!.setValue(name!, color)\n onChange?.(color)\n }\n\n // ── popover (positioning / scroll-lock / dismiss come from FloatingPanel) ──────────────────────\n const triggerRef = useRef<HTMLButtonElement | null>(null)\n const popoverRef = useRef<HTMLDivElement | null>(null)\n const [open, setOpen] = useState(false)\n\n const setTriggerRef = useCallback(\n (node: HTMLButtonElement | null) => {\n triggerRef.current = node\n if (typeof ref === 'function') ref(node)\n else if (ref) (ref as { current: HTMLButtonElement | null }).current = node\n },\n [ref],\n )\n\n const closePopover = useCallback((refocus: boolean) => {\n setOpen(false)\n if (refocus) triggerRef.current?.focus()\n }, [])\n\n // mark the form field touched when focus leaves the whole widget — but not when it moves into the\n // (portaled) popover or stays on the trigger, so a form-bound picker shows its error like every\n // other popover field (Select/DatePicker) instead of only after submit\n const handleTriggerBlur = (event: FocusEvent<HTMLButtonElement>) => {\n const next = event.relatedTarget as Node | null\n if (next && (popoverRef.current?.contains(next) || triggerRef.current?.contains(next))) return\n bound?.onBlur(event as unknown as FocusEvent<HTMLInputElement>)\n }\n\n return (\n <div\n className={clsx(\n styles.field,\n styles[size],\n fullWidth && styles.fullWidth,\n resolvedError && styles.error,\n disabled && styles.disabled,\n className,\n )}\n style={style}\n >\n {label != null && (\n <label htmlFor={id} className={styles.label}>\n <Typography as=\"span\" variant=\"bodySmall\" color=\"muted\">\n {label}\n </Typography>\n {required && (\n <span className={styles.required} aria-hidden=\"true\">\n *\n </span>\n )}\n </label>\n )}\n\n <button\n ref={setTriggerRef}\n id={id}\n name={name}\n type=\"button\"\n className={clsx(styles.control, open && styles.open)}\n disabled={disabled}\n aria-haspopup=\"dialog\"\n aria-expanded={open}\n aria-invalid={resolvedError || undefined}\n aria-describedby={resolvedHelperText != null ? helperId : undefined}\n aria-label={label || parsed || placeholder ? undefined : t('colorPicker.pick')}\n onClick={() => setOpen((o) => !o)}\n onBlur={handleTriggerBlur}\n >\n <span className={clsx(styles.value, !parsed && styles.placeholder)}>\n {displayText ?? placeholder}\n </span>\n <span\n className={clsx(styles.preview, !parsed && styles.previewEmpty)}\n style={parsed ? ({ '--cp-fill': displayValue } as CSSProperties) : undefined}\n aria-hidden=\"true\"\n />\n </button>\n\n <FloatingPanel\n ref={popoverRef}\n open={open}\n triggerRef={triggerRef}\n onClose={closePopover}\n role=\"dialog\"\n ariaLabel=\"Color picker\"\n width={POPOVER_WIDTH}\n >\n <ColorPickerPanel value={currentColor} onChange={commit} swatches={swatches} />\n </FloatingPanel>\n\n {resolvedHelperText != null && (\n <Typography\n as=\"span\"\n id={helperId}\n variant=\"bodySmall\"\n color={resolvedError ? 'error' : 'muted'}\n className={styles.helper}\n >\n {resolvedHelperText}\n </Typography>\n )}\n </div>\n )\n})\n"],"names":["POPOVER_WIDTH","ColorPicker","forwardRef","label","size","error","helperText","required","fullWidth","disabled","value","defaultValue","onChange","swatches","name","placeholder","idProp","className","style","ref","t","useT","reactId","useId","id","helperId","form","useFormContext","isFormBound","bound","externalValue","isControlled","internal","setInternal","useState","currentColor","parsed","parseColor","displayValue","formatColor","displayText","resolvedError","resolvedHelperText","commit","color","triggerRef","useRef","popoverRef","open","setOpen","setTriggerRef","useCallback","node","closePopover","refocus","_a","handleTriggerBlur","event","next","_b","jsxs","clsx","styles","jsx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UAAA;AAAA,QAAA;AAAA,MACH;AAAA,IAAA;AAAA,EAAA;AAIR,CAAC;"}
|
|
@@ -1,2 +0,0 @@
|
|
|
1
|
-
"use strict";const _=require("react/jsx-runtime"),g=require("react"),Z=require("clsx"),P=require("./Icon-BVULqOJD.cjs"),ee=require("./ConfigProvider-Bszl3Wr3.cjs"),d=n=>Math.min(1,Math.max(0,n)),A=n=>Math.min(255,Math.max(0,Math.round(n)));function te(n){let s=n.trim().replace(/^#/,"");return/^[0-9a-fA-F]{3}$/.test(s)&&(s=s.split("").map(a=>a+a).join("")),/^[0-9a-fA-F]{6}$/.test(s)?`#${s.toLowerCase()}`:null}function H(n){const s=(te(n)??"#000000").slice(1);return{r:parseInt(s.slice(0,2),16),g:parseInt(s.slice(2,4),16),b:parseInt(s.slice(4,6),16)}}function N({r:n,g:s,b:a}){const e=c=>Math.round(d(c/255)*255).toString(16).padStart(2,"0");return`#${e(n)}${e(s)}${e(a)}`}function T({r:n,g:s,b:a}){const e=n/255,c=s/255,i=a/255,u=Math.max(e,c,i),l=Math.min(e,c,i),h=u-l;let p=0;h!==0&&(u===e?p=(c-i)/h%6:u===c?p=(i-e)/h+2:p=(e-c)/h+4,p*=60,p<0&&(p+=360));const v=u===0?0:h/u;return{h:p,s:v,v:u}}function y({h:n,s,v:a}){const e=a*s,c=e*(1-Math.abs(n/60%2-1)),i=a-e;let u=0,l=0,h=0;return n<60?[u,l,h]=[e,c,0]:n<120?[u,l,h]=[c,e,0]:n<180?[u,l,h]=[0,e,c]:n<240?[u,l,h]=[0,c,e]:n<300?[u,l,h]=[c,0,e]:[u,l,h]=[e,0,c],{r:(u+i)*255,g:(l+i)*255,b:(h+i)*255}}const re=n=>T(H(n));function se(n){const{r:s,g:a,b:e}=H(n);return(s*299+a*587+e*114)/1e3>=150?"#04202b":"#ffffff"}const ne=/^rgba?\(\s*([\d.]+)\s*[, ]\s*([\d.]+)\s*[, ]\s*([\d.]+)\s*(?:[,/]\s*([\d.]+%?)\s*)?\)$/i;function M(n){const s=n.trim();if(!s)return null;let a=s.replace(/^#/,"");if(/^[0-9a-fA-F]{3,4}$/.test(a)&&(a=a.split("").map(c=>c+c).join("")),/^[0-9a-fA-F]{6}$/.test(a))return{r:parseInt(a.slice(0,2),16),g:parseInt(a.slice(2,4),16),b:parseInt(a.slice(4,6),16),a:1};if(/^[0-9a-fA-F]{8}$/.test(a))return{r:parseInt(a.slice(0,2),16),g:parseInt(a.slice(2,4),16),b:parseInt(a.slice(4,6),16),a:d(parseInt(a.slice(6,8),16)/255)};const e=s.match(ne);if(e){let c=1;return e[4]!=null&&(c=e[4].endsWith("%")?d(parseFloat(e[4])/100):d(parseFloat(e[4]))),{r:A(+e[1]),g:A(+e[2]),b:A(+e[3]),a:c}}return null}function b({r:n,g:s,b:a,a:e}){return e>=1?N({r:n,g:s,b:a}):`rgba(${A(n)}, ${A(s)}, ${A(a)}, ${Math.round(d(e)*100)/100})`}const ae="_field_5rt4i_1",oe="_fullWidth_5rt4i_6",ce="_label_5rt4i_11",le="_required_5rt4i_17",ie="_control_5rt4i_23",ue="_open_5rt4i_44",he="_error_5rt4i_49",pe="_disabled_5rt4i_57",_e="_value_5rt4i_64",fe="_placeholder_5rt4i_73",de="_preview_5rt4i_81",me="_previewEmpty_5rt4i_101",be="_helper_5rt4i_113",we="_popover_5rt4i_118",ve="_sv_5rt4i_128",xe="_svThumb_5rt4i_139",ge="_hue_5rt4i_150",ke="_hueThumb_5rt4i_168",ye="_alphaThumb_5rt4i_169",Ae="_alpha_5rt4i_169",Te="_hexRow_5rt4i_202",Ce="_currentSwatch_5rt4i_207",$e="_hexField_5rt4i_223",Ie="_hexInput_5rt4i_235",De="_swatches_5rt4i_247",Me="_swatch_5rt4i_247",je="_swatchClear_5rt4i_264",Se="_sm_5rt4i_278",Re="_md_5rt4i_282",Ee="_lg_5rt4i_286",f={field:ae,fullWidth:oe,label:ce,required:le,control:ie,open:ue,error:he,disabled:pe,value:_e,placeholder:fe,preview:de,previewEmpty:me,helper:be,popover:we,sv:ve,svThumb:xe,hue:ge,hueThumb:ke,alphaThumb:ye,alpha:Ae,hexRow:Te,currentSwatch:Ce,hexField:$e,hexInput:Ie,swatches:De,swatch:Me,swatchClear:je,sm:Se,md:Re,lg:Ee},L=["#13404e","#039aa1","#00a854","#0ea5e9","#6366f1","#7c3aed","#f04134","#f59e0b","#ffbf00","#10b981","#64748b","#0f172a","#ffffff"],F=re("#13404e");function Pe({value:n,onChange:s,swatches:a=L,clearable:e=!0}){const c=ee.useT(),i=M(n||""),u=i?b(i):null,[l,h]=g.useState(i?T(i):F),p=g.useRef(l);p.current=l;const[v,C]=g.useState((i==null?void 0:i.a)??1),x=g.useRef(v);x.current=v,g.useEffect(()=>{if(!i)return;const r=b({...y(p.current),a:x.current});u!==r&&(h(T(i)),C(i.a))},[u]);const $=r=>{h(r),s(b({...y(r),a:x.current}))},R=r=>{C(r),s(b({...y(p.current),a:r}))},j=r=>t=>{t.preventDefault();const o=t.currentTarget,m=(D,Q)=>r(D,Q,o.getBoundingClientRect());m(t.clientX,t.clientY);const w=D=>m(D.clientX,D.clientY),k=()=>{window.removeEventListener("pointermove",w),window.removeEventListener("pointerup",k)};window.addEventListener("pointermove",w),window.addEventListener("pointerup",k)},q=j((r,t,o)=>{const m=d((r-o.left)/o.width),w=d(1-(t-o.top)/o.height);$({...p.current,s:m,v:w})}),K=j((r,t,o)=>{const m=d((r-o.left)/o.width)*360;$({...p.current,h:m})}),U=j((r,t,o)=>{R(d((r-o.left)/o.width))}),I=.01,W=r=>{const{h:t,s:o,v:m}=p.current;let w=o,k=m;switch(r.key){case"ArrowLeft":w=d(o-I);break;case"ArrowRight":w=d(o+I);break;case"ArrowUp":k=d(m+I);break;case"ArrowDown":k=d(m-I);break;default:return}r.preventDefault(),$({h:t,s:w,v:k})},z=r=>{const{h:t}=p.current;let o=t;switch(r.key){case"ArrowLeft":case"ArrowDown":o=Math.max(0,t-1);break;case"ArrowRight":case"ArrowUp":o=Math.min(360,t+1);break;case"Home":o=0;break;case"End":o=360;break;default:return}r.preventDefault(),$({...p.current,h:o})},B=r=>{let t=x.current;switch(r.key){case"ArrowLeft":case"ArrowDown":t=d(x.current-.01);break;case"ArrowRight":case"ArrowUp":t=d(x.current+.01);break;case"Home":t=0;break;case"End":t=1;break;default:return}r.preventDefault(),R(t)},[V,E]=g.useState("");g.useEffect(()=>{E(u??"")},[u]);const X=r=>{E(r);const t=M(r);t&&(h(T(t)),C(t.a),s(b(t)))},Y=()=>{s(""),h(F),C(1)},G=b({...y(l),a:v}),O=N(y(l)),S=y(l),J=`${Math.round(S.r)}, ${Math.round(S.g)}, ${Math.round(S.b)}`;return _.jsxs("div",{className:f.popover,style:{"--cp-hue":l.h},children:[_.jsx("div",{className:f.sv,onPointerDown:q,onKeyDown:W,role:"slider",tabIndex:0,"aria-label":c("colorPicker.saturation"),"aria-valuetext":`${Math.round(l.s*100)}% saturation, ${Math.round(l.v*100)}% brightness`,children:_.jsx("span",{className:f.svThumb,style:{left:`${l.s*100}%`,top:`${(1-l.v)*100}%`,background:O}})}),_.jsx("div",{className:f.hue,onPointerDown:K,onKeyDown:z,role:"slider",tabIndex:0,"aria-label":c("colorPicker.hue"),"aria-valuemin":0,"aria-valuemax":360,"aria-valuenow":Math.round(l.h),children:_.jsx("span",{className:f.hueThumb,style:{left:`${l.h/360*100}%`}})}),_.jsx("div",{className:f.alpha,onPointerDown:U,onKeyDown:B,role:"slider",tabIndex:0,"aria-label":c("colorPicker.opacity"),"aria-valuemin":0,"aria-valuemax":100,"aria-valuenow":Math.round(v*100),style:{"--cp-rgb":J},children:_.jsx("span",{className:f.alphaThumb,style:{left:`${v*100}%`}})}),_.jsxs("div",{className:f.hexRow,children:[_.jsx("span",{className:f.currentSwatch,style:{"--cp-fill":G}}),_.jsx("span",{className:f.hexField,children:_.jsx("input",{className:f.hexInput,value:V,spellCheck:!1,maxLength:28,"aria-label":c("colorPicker.value"),onChange:r=>X(r.target.value)})})]}),_.jsxs("div",{className:f.swatches,children:[e&&_.jsx("button",{type:"button",className:Z.clsx(f.swatch,f.swatchClear),"aria-label":c("colorPicker.noColor"),"aria-pressed":!i,onClick:Y,children:!i&&_.jsx(P.Icon,{name:"TickCircle",size:"sm"})}),a.map(r=>{const t=M(r);if(!t)return null;const o=b({r:t.r,g:t.g,b:t.b,a:1}),m=u===o;return _.jsx("button",{type:"button",className:f.swatch,style:{background:o,color:se(o)},"aria-label":o,"aria-pressed":m,onClick:()=>{h(T(t)),s(b({r:t.r,g:t.g,b:t.b,a:x.current}))},children:m&&_.jsx(P.Icon,{name:"TickCircle",size:"sm"})},r)})]})]})}exports.ColorPickerPanel=Pe;exports.DEFAULT_SWATCHES=L;exports.formatColor=b;exports.parseColor=M;exports.styles=f;
|
|
2
|
-
//# sourceMappingURL=ColorPickerPanel--wBX-m7J.cjs.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"ColorPickerPanel--wBX-m7J.cjs","sources":["../src/components/ColorPicker/colorUtils.ts","../src/components/ColorPicker/ColorPickerPanel.tsx"],"sourcesContent":["/** Color math for the ColorPicker: hex ⇄ rgb ⇄ hsv, plus hex validation. All internal, no deps. */\n\nexport interface HSV {\n /** Hue 0–360 */\n h: number\n /** Saturation 0–1 */\n s: number\n /** Value/brightness 0–1 */\n v: number\n}\n\nexport interface RGB {\n r: number\n g: number\n b: number\n}\n\nexport interface RGBA extends RGB {\n /** Alpha 0–1 */\n a: number\n}\n\nexport const clamp01 = (n: number): number => Math.min(1, Math.max(0, n))\nconst clamp255 = (n: number): number => Math.min(255, Math.max(0, Math.round(n)))\n\n/** Normalizes any `#rgb`/`#rrggbb` (with or without `#`) to a lowercase `#rrggbb`, or `null` if invalid. */\nexport function normalizeHex(input: string): string | null {\n let h = input.trim().replace(/^#/, '')\n if (/^[0-9a-fA-F]{3}$/.test(h)) {\n h = h\n .split('')\n .map((c) => c + c)\n .join('')\n }\n return /^[0-9a-fA-F]{6}$/.test(h) ? `#${h.toLowerCase()}` : null\n}\n\n/** True for a complete `#rrggbb` (or `#rgb`) color. */\nexport const isValidHex = (input: string): boolean => normalizeHex(input) !== null\n\nexport function hexToRgb(hex: string): RGB {\n const h = (normalizeHex(hex) ?? '#000000').slice(1)\n return {\n r: parseInt(h.slice(0, 2), 16),\n g: parseInt(h.slice(2, 4), 16),\n b: parseInt(h.slice(4, 6), 16),\n }\n}\n\nexport function rgbToHex({ r, g, b }: RGB): string {\n const to = (n: number) =>\n Math.round(clamp01(n / 255) * 255)\n .toString(16)\n .padStart(2, '0')\n return `#${to(r)}${to(g)}${to(b)}`\n}\n\n/** RGB (0–255) → HSV. */\nexport function rgbToHsv({ r, g, b }: RGB): HSV {\n const rn = r / 255\n const gn = g / 255\n const bn = b / 255\n const max = Math.max(rn, gn, bn)\n const min = Math.min(rn, gn, bn)\n const d = max - min\n\n let h = 0\n if (d !== 0) {\n if (max === rn) h = ((gn - bn) / d) % 6\n else if (max === gn) h = (bn - rn) / d + 2\n else h = (rn - gn) / d + 4\n h *= 60\n if (h < 0) h += 360\n }\n const s = max === 0 ? 0 : d / max\n return { h, s, v: max }\n}\n\n/** HSV → RGB (0–255). */\nexport function hsvToRgb({ h, s, v }: HSV): RGB {\n const c = v * s\n const x = c * (1 - Math.abs(((h / 60) % 2) - 1))\n const m = v - c\n let r = 0\n let g = 0\n let b = 0\n if (h < 60) [r, g, b] = [c, x, 0]\n else if (h < 120) [r, g, b] = [x, c, 0]\n else if (h < 180) [r, g, b] = [0, c, x]\n else if (h < 240) [r, g, b] = [0, x, c]\n else if (h < 300) [r, g, b] = [x, 0, c]\n else [r, g, b] = [c, 0, x]\n return { r: (r + m) * 255, g: (g + m) * 255, b: (b + m) * 255 }\n}\n\nexport const hexToHsv = (hex: string): HSV => rgbToHsv(hexToRgb(hex))\nexport const hsvToHex = (hsv: HSV): string => rgbToHex(hsvToRgb(hsv))\n\n/** A readable text/handle color (near-black or white) for sitting on top of a given hex fill. */\nexport function contrastOn(hex: string): string {\n const { r, g, b } = hexToRgb(hex)\n return (r * 299 + g * 587 + b * 114) / 1000 >= 150 ? '#04202b' : '#ffffff'\n}\n\nconst RGB_FUNC =\n /^rgba?\\(\\s*([\\d.]+)\\s*[, ]\\s*([\\d.]+)\\s*[, ]\\s*([\\d.]+)\\s*(?:[,/]\\s*([\\d.]+%?)\\s*)?\\)$/i\n\n/**\n * Parses any CSS color the picker understands — `#rgb` / `#rgba` / `#rrggbb` / `#rrggbbaa` hex (with\n * or without `#`), or `rgb()` / `rgba()` (alpha as `0–1` or a `%`) — to `{ r, g, b, a }` (`a` is\n * `0–1`), or `null` when it doesn't match.\n */\nexport function parseColor(input: string): RGBA | null {\n const s = input.trim()\n if (!s) return null\n\n // hex (with or without #) — 3 / 4 / 6 / 8 digits (3 & 4 expand each nibble to a byte)\n let h = s.replace(/^#/, '')\n if (/^[0-9a-fA-F]{3,4}$/.test(h)) {\n h = h\n .split('')\n .map((c) => c + c)\n .join('')\n }\n if (/^[0-9a-fA-F]{6}$/.test(h)) {\n return {\n r: parseInt(h.slice(0, 2), 16),\n g: parseInt(h.slice(2, 4), 16),\n b: parseInt(h.slice(4, 6), 16),\n a: 1,\n }\n }\n if (/^[0-9a-fA-F]{8}$/.test(h)) {\n return {\n r: parseInt(h.slice(0, 2), 16),\n g: parseInt(h.slice(2, 4), 16),\n b: parseInt(h.slice(4, 6), 16),\n a: clamp01(parseInt(h.slice(6, 8), 16) / 255),\n }\n }\n\n // rgb() / rgba()\n const m = s.match(RGB_FUNC)\n if (m) {\n let a = 1\n if (m[4] != null) {\n a = m[4].endsWith('%') ? clamp01(parseFloat(m[4]) / 100) : clamp01(parseFloat(m[4]))\n }\n return { r: clamp255(+m[1]), g: clamp255(+m[2]), b: clamp255(+m[3]), a }\n }\n return null\n}\n\n/**\n * Formats `{ r, g, b, a }` back to a CSS string: `#rrggbb` when fully opaque (`a >= 1`), else\n * `rgba(r, g, b, a)` with alpha rounded to 2 decimals.\n */\nexport function formatColor({ r, g, b, a }: RGBA): string {\n if (a >= 1) return rgbToHex({ r, g, b })\n return `rgba(${clamp255(r)}, ${clamp255(g)}, ${clamp255(b)}, ${Math.round(clamp01(a) * 100) / 100})`\n}\n","import {\n useEffect,\n useRef,\n useState,\n type CSSProperties,\n type KeyboardEvent as ReactKeyboardEvent,\n type PointerEvent as ReactPointerEvent,\n} from 'react'\nimport { clsx } from 'clsx'\nimport { useT } from '../../theme'\nimport { Icon } from '../Icon'\nimport {\n clamp01,\n contrastOn,\n formatColor,\n hexToHsv,\n hsvToRgb,\n parseColor,\n rgbToHex,\n rgbToHsv,\n type HSV,\n} from './colorUtils'\nimport styles from './ColorPicker.module.css'\n\n/** A pleasant default palette shown as quick-pick swatches. */\nexport const DEFAULT_SWATCHES = [\n '#13404e',\n '#039aa1',\n '#00a854',\n '#0ea5e9',\n '#6366f1',\n '#7c3aed',\n '#f04134',\n '#f59e0b',\n '#ffbf00',\n '#10b981',\n '#64748b',\n '#0f172a',\n '#ffffff',\n]\n\nconst FALLBACK_HSV: HSV = hexToHsv('#13404e')\n\nexport interface ColorPickerPanelProps {\n /** Current color — a CSS color string (`#rrggbb`, `rgba(...)`, or `''` when unset). */\n value: string\n /** Fires with the next color: `#rrggbb` when opaque, `rgba(r, g, b, a)` when translucent, `''` when cleared. */\n onChange: (color: string) => void\n /** Quick-pick swatches. Defaults to a curated palette. */\n swatches?: string[]\n /** Show the leading \"no color\" swatch that clears the value. Defaults to `true`. */\n clearable?: boolean\n}\n\n/**\n * The color-picking surface — a saturation/value square, hue + alpha sliders, a color input and\n * quick-pick swatches. Controlled by a single color `string` (`value` / `onChange`), so it drops into\n * any popover. Working state is kept as HSV + alpha (hue survives dragging at grey/black), re-derived\n * from `value` only on external changes. Used by `ColorPicker` (the field) and the `RichTextEditor`\n * text-color control. Token-styled except the spectrum gradients + alpha checkerboard (literal colors).\n */\nexport function ColorPickerPanel({\n value,\n onChange,\n swatches = DEFAULT_SWATCHES,\n clearable = true,\n}: ColorPickerPanelProps) {\n const t = useT()\n const parsed = parseColor(value || '')\n // canonical string for the value (`#rrggbb` when opaque, `rgba(...)` when not), null when unset\n const displayValue = parsed ? formatColor(parsed) : null\n\n // working HSV + alpha (HSV keeps hue stable while dragging at grey/black; alpha is the opacity)\n const [hsv, setHsv] = useState<HSV>(parsed ? rgbToHsv(parsed) : FALLBACK_HSV)\n const hsvRef = useRef(hsv)\n hsvRef.current = hsv\n const [alpha, setAlpha] = useState<number>(parsed?.a ?? 1)\n const alphaRef = useRef(alpha)\n alphaRef.current = alpha\n\n // re-derive HSV + alpha only when the value changes from OUTSIDE our own edits (prop/preset/input)\n useEffect(() => {\n if (!parsed) return\n const cur = formatColor({ ...hsvToRgb(hsvRef.current), a: alphaRef.current })\n if (displayValue !== cur) {\n setHsv(rgbToHsv(parsed))\n setAlpha(parsed.a)\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [displayValue])\n\n const applyHsv = (next: HSV) => {\n setHsv(next)\n onChange(formatColor({ ...hsvToRgb(next), a: alphaRef.current }))\n }\n\n const applyAlpha = (next: number) => {\n setAlpha(next)\n onChange(formatColor({ ...hsvToRgb(hsvRef.current), a: next }))\n }\n\n // drag (SV square + hue/alpha sliders)\n const drag =\n (onMove: (clientX: number, clientY: number, rect: DOMRect) => void) =>\n (event: ReactPointerEvent<HTMLDivElement>) => {\n event.preventDefault()\n const el = event.currentTarget\n const move = (clientX: number, clientY: number) =>\n onMove(clientX, clientY, el.getBoundingClientRect())\n move(event.clientX, event.clientY)\n const onPointerMove = (e: PointerEvent) => move(e.clientX, e.clientY)\n const onPointerUp = () => {\n window.removeEventListener('pointermove', onPointerMove)\n window.removeEventListener('pointerup', onPointerUp)\n }\n window.addEventListener('pointermove', onPointerMove)\n window.addEventListener('pointerup', onPointerUp)\n }\n\n const onSvDown = drag((x, y, rect) => {\n const s = clamp01((x - rect.left) / rect.width)\n const v = clamp01(1 - (y - rect.top) / rect.height)\n applyHsv({ ...hsvRef.current, s, v })\n })\n\n const onHueDown = drag((x, _y, rect) => {\n const h = clamp01((x - rect.left) / rect.width) * 360\n applyHsv({ ...hsvRef.current, h })\n })\n\n const onAlphaDown = drag((x, _y, rect) => {\n applyAlpha(clamp01((x - rect.left) / rect.width))\n })\n\n // keyboard control — arrows nudge, Home/End jump to the extents (mirrors Calendar/TimeColumns a11y)\n const SV_STEP = 0.01\n const onSvKey = (event: ReactKeyboardEvent<HTMLDivElement>) => {\n const { h, s, v } = hsvRef.current\n let ns = s\n let nv = v\n switch (event.key) {\n case 'ArrowLeft':\n ns = clamp01(s - SV_STEP)\n break\n case 'ArrowRight':\n ns = clamp01(s + SV_STEP)\n break\n case 'ArrowUp':\n nv = clamp01(v + SV_STEP)\n break\n case 'ArrowDown':\n nv = clamp01(v - SV_STEP)\n break\n default:\n return\n }\n event.preventDefault()\n applyHsv({ h, s: ns, v: nv })\n }\n const onHueKey = (event: ReactKeyboardEvent<HTMLDivElement>) => {\n const { h } = hsvRef.current\n let nh = h\n switch (event.key) {\n case 'ArrowLeft':\n case 'ArrowDown':\n nh = Math.max(0, h - 1)\n break\n case 'ArrowRight':\n case 'ArrowUp':\n nh = Math.min(360, h + 1)\n break\n case 'Home':\n nh = 0\n break\n case 'End':\n nh = 360\n break\n default:\n return\n }\n event.preventDefault()\n applyHsv({ ...hsvRef.current, h: nh })\n }\n const onAlphaKey = (event: ReactKeyboardEvent<HTMLDivElement>) => {\n let na = alphaRef.current\n switch (event.key) {\n case 'ArrowLeft':\n case 'ArrowDown':\n na = clamp01(alphaRef.current - 0.01)\n break\n case 'ArrowRight':\n case 'ArrowUp':\n na = clamp01(alphaRef.current + 0.01)\n break\n case 'Home':\n na = 0\n break\n case 'End':\n na = 1\n break\n default:\n return\n }\n event.preventDefault()\n applyAlpha(na)\n }\n\n // color input (accepts hex / rgb() / rgba()) + clear\n const [colorDraft, setColorDraft] = useState('')\n useEffect(() => {\n setColorDraft(displayValue ?? '')\n }, [displayValue])\n\n const onColorInput = (raw: string) => {\n setColorDraft(raw)\n const p = parseColor(raw)\n if (p) {\n setHsv(rgbToHsv(p))\n setAlpha(p.a)\n onChange(formatColor(p))\n }\n }\n\n const handleClear = () => {\n onChange('')\n setHsv(FALLBACK_HSV)\n setAlpha(1)\n }\n\n // working color (hsv + alpha): the current swatch + the SV thumb (opaque) + the alpha track base\n const workingColor = formatColor({ ...hsvToRgb(hsv), a: alpha })\n const solidHex = rgbToHex(hsvToRgb(hsv))\n const cur = hsvToRgb(hsv)\n const cpRgb = `${Math.round(cur.r)}, ${Math.round(cur.g)}, ${Math.round(cur.b)}`\n\n return (\n <div className={styles.popover} style={{ '--cp-hue': hsv.h } as CSSProperties}>\n <div\n className={styles.sv}\n onPointerDown={onSvDown}\n onKeyDown={onSvKey}\n role=\"slider\"\n tabIndex={0}\n aria-label={t('colorPicker.saturation')}\n aria-valuetext={`${Math.round(hsv.s * 100)}% saturation, ${Math.round(hsv.v * 100)}% brightness`}\n >\n <span\n className={styles.svThumb}\n style={{ left: `${hsv.s * 100}%`, top: `${(1 - hsv.v) * 100}%`, background: solidHex }}\n />\n </div>\n\n <div\n className={styles.hue}\n onPointerDown={onHueDown}\n onKeyDown={onHueKey}\n role=\"slider\"\n tabIndex={0}\n aria-label={t('colorPicker.hue')}\n aria-valuemin={0}\n aria-valuemax={360}\n aria-valuenow={Math.round(hsv.h)}\n >\n <span className={styles.hueThumb} style={{ left: `${(hsv.h / 360) * 100}%` }} />\n </div>\n\n <div\n className={styles.alpha}\n onPointerDown={onAlphaDown}\n onKeyDown={onAlphaKey}\n role=\"slider\"\n tabIndex={0}\n aria-label={t('colorPicker.opacity')}\n aria-valuemin={0}\n aria-valuemax={100}\n aria-valuenow={Math.round(alpha * 100)}\n style={{ '--cp-rgb': cpRgb } as CSSProperties}\n >\n <span className={styles.alphaThumb} style={{ left: `${alpha * 100}%` }} />\n </div>\n\n <div className={styles.hexRow}>\n <span\n className={styles.currentSwatch}\n style={{ '--cp-fill': workingColor } as CSSProperties}\n />\n <span className={styles.hexField}>\n <input\n className={styles.hexInput}\n value={colorDraft}\n spellCheck={false}\n maxLength={28}\n aria-label={t('colorPicker.value')}\n onChange={(e) => onColorInput(e.target.value)}\n />\n </span>\n </div>\n\n <div className={styles.swatches}>\n {/* \"no color\" — clears the value (the diagonal-stripe swatch); hidden when not clearable */}\n {clearable && (\n <button\n type=\"button\"\n className={clsx(styles.swatch, styles.swatchClear)}\n aria-label={t('colorPicker.noColor')}\n aria-pressed={!parsed}\n onClick={handleClear}\n >\n {!parsed && <Icon name=\"TickCircle\" size=\"sm\" />}\n </button>\n )}\n {swatches.map((sw) => {\n const p = parseColor(sw)\n if (!p) return null\n const swHex = formatColor({ r: p.r, g: p.g, b: p.b, a: 1 })\n const selected = displayValue === swHex\n return (\n <button\n key={sw}\n type=\"button\"\n className={styles.swatch}\n style={{ background: swHex, color: contrastOn(swHex) }}\n aria-label={swHex}\n aria-pressed={selected}\n onClick={() => {\n setHsv(rgbToHsv(p))\n onChange(formatColor({ r: p.r, g: p.g, b: p.b, a: alphaRef.current }))\n }}\n >\n {selected && <Icon name=\"TickCircle\" size=\"sm\" />}\n </button>\n )\n })}\n </div>\n </div>\n )\n}\n"],"names":["clamp01","clamp255","normalizeHex","input","h","c","hexToRgb","hex","rgbToHex","r","g","b","to","n","rgbToHsv","rn","gn","bn","max","min","d","s","hsvToRgb","v","x","m","hexToHsv","contrastOn","RGB_FUNC","parseColor","a","formatColor","DEFAULT_SWATCHES","FALLBACK_HSV","ColorPickerPanel","value","onChange","swatches","clearable","t","useT","parsed","displayValue","hsv","setHsv","useState","hsvRef","useRef","alpha","setAlpha","alphaRef","useEffect","cur","applyHsv","next","applyAlpha","drag","onMove","event","el","move","clientX","clientY","onPointerMove","e","onPointerUp","onSvDown","y","rect","onHueDown","_y","onAlphaDown","SV_STEP","onSvKey","ns","nv","onHueKey","nh","onAlphaKey","na","colorDraft","setColorDraft","onColorInput","raw","p","handleClear","workingColor","solidHex","cpRgb","jsxs","styles","jsx","clsx","Icon","sw","swHex","selected"],"mappings":"oKAs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