@fuf-stack/uniform 1.18.3 → 1.19.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/dist/Checkboxes/index.cjs +7 -5
- package/dist/Checkboxes/index.d.cts +1 -1
- package/dist/Checkboxes/index.d.ts +1 -1
- package/dist/Checkboxes/index.js +2 -3
- package/dist/{Checkboxes-BGrK_mwQ.js → Checkboxes-D1hppxDE.js} +7 -10
- package/dist/Checkboxes-D1hppxDE.js.map +1 -0
- package/dist/{Checkboxes-Dk7yyRVR.cjs → Checkboxes-DegQ22uN.cjs} +18 -21
- package/dist/Checkboxes-DegQ22uN.cjs.map +1 -0
- package/dist/FieldArray/index.cjs +7 -5
- package/dist/FieldArray/index.d.cts +1 -1
- package/dist/FieldArray/index.d.ts +1 -1
- package/dist/FieldArray/index.js +2 -3
- package/dist/{FieldArray-Bs2ViU8m.js → FieldArray-BVL5Tz0Q.js} +51 -71
- package/dist/FieldArray-BVL5Tz0Q.js.map +1 -0
- package/dist/{FieldArray-C6RHZcKa.cjs → FieldArray-CeiNCobX.cjs} +66 -86
- package/dist/FieldArray-CeiNCobX.cjs.map +1 -0
- package/dist/FieldCard/index.cjs +4 -4
- package/dist/FieldCard/index.d.cts +1 -1
- package/dist/FieldCard/index.d.ts +1 -1
- package/dist/FieldCard/index.js +2 -3
- package/dist/{FieldCard-BxK_IJOR.cjs → FieldCard-C0kNSLj7.cjs} +20 -24
- package/dist/FieldCard-C0kNSLj7.cjs.map +1 -0
- package/dist/{FieldCard-16yCF83m.js → FieldCard-SjYNs4sL.js} +8 -12
- package/dist/FieldCard-SjYNs4sL.js.map +1 -0
- package/dist/{FieldCopyTestIdButton-BoEdlzLs.js → FieldCopyTestIdButton-Dpmo0uBV.js} +4 -7
- package/dist/FieldCopyTestIdButton-Dpmo0uBV.js.map +1 -0
- package/dist/{FieldCopyTestIdButton-4uupFq1U.cjs → FieldCopyTestIdButton-DrUzXwTo.cjs} +14 -17
- package/dist/FieldCopyTestIdButton-DrUzXwTo.cjs.map +1 -0
- package/dist/{FieldValidationError-Br6iopZj.cjs → FieldValidationError-8H8LxDjk.cjs} +14 -17
- package/dist/FieldValidationError-8H8LxDjk.cjs.map +1 -0
- package/dist/{FieldValidationError-XQaViV52.js → FieldValidationError-ktTyyyip.js} +4 -7
- package/dist/FieldValidationError-ktTyyyip.js.map +1 -0
- package/dist/Form/index.cjs +7 -5
- package/dist/Form/index.d.cts +1 -1
- package/dist/Form/index.d.ts +1 -2
- package/dist/Form/index.js +2 -3
- package/dist/{Form--SsSvsxl.cjs → Form-Dqa1b7Y7.cjs} +17 -22
- package/dist/Form-Dqa1b7Y7.cjs.map +1 -0
- package/dist/{Form-ccsEssie.js → Form-Wzy7pBVt.js} +8 -13
- package/dist/Form-Wzy7pBVt.js.map +1 -0
- package/dist/{FormContext-CCe8drkp.d.ts → FormContext-B4KQxdl7.d.ts} +1 -1
- package/dist/{FormContext-CCe8drkp.d.ts.map → FormContext-B4KQxdl7.d.ts.map} +1 -1
- package/dist/{FormContext-BSLO2-sO.cjs → FormContext-BrY1FQYR.cjs} +29 -37
- package/dist/{FormContext-BSLO2-sO.cjs.map → FormContext-BrY1FQYR.cjs.map} +1 -1
- package/dist/{FormContext-RSA21aDt.d.cts → FormContext-BuG3xZFe.d.cts} +1 -1
- package/dist/{FormContext-RSA21aDt.d.cts.map → FormContext-BuG3xZFe.d.cts.map} +1 -1
- package/dist/{FormContext-kE3YKhp_.js → FormContext-CLfMWHQM.js} +4 -7
- package/dist/{FormContext-kE3YKhp_.js.map → FormContext-CLfMWHQM.js.map} +1 -1
- package/dist/Grid/index.cjs +7 -5
- package/dist/Grid/index.d.cts +1 -1
- package/dist/Grid/index.d.ts +1 -1
- package/dist/Grid/index.js +2 -3
- package/dist/{Grid-BaqBa1ku.js → Grid-Bzyi97Cx.js} +4 -7
- package/dist/Grid-Bzyi97Cx.js.map +1 -0
- package/dist/{Grid-D5Yf0nD_.cjs → Grid-DdYQQ_UM.cjs} +14 -17
- package/dist/Grid-DdYQQ_UM.cjs.map +1 -0
- package/dist/Input/index.cjs +7 -5
- package/dist/Input/index.d.cts +1 -1
- package/dist/Input/index.d.ts +1 -1
- package/dist/Input/index.js +2 -3
- package/dist/{Input-BCs_eyJ9.js → Input-BDWP4hOr.js} +6 -9
- package/dist/{Input-BCs_eyJ9.js.map → Input-BDWP4hOr.js.map} +1 -1
- package/dist/{Input-B3p_4ntD.cjs → Input-BXJ4DSha.cjs} +18 -21
- package/dist/Input-BXJ4DSha.cjs.map +1 -0
- package/dist/RadioBoxes/index.cjs +7 -5
- package/dist/RadioBoxes/index.d.cts +1 -1
- package/dist/RadioBoxes/index.d.ts +1 -1
- package/dist/RadioBoxes/index.js +2 -3
- package/dist/{RadioBoxes-C3Cwrn2I.js → RadioBoxes-BR3X986V.js} +16 -23
- package/dist/RadioBoxes-BR3X986V.js.map +1 -0
- package/dist/{RadioBoxes-xRvNe5U8.cjs → RadioBoxes-Cim3InDW.cjs} +33 -40
- package/dist/RadioBoxes-Cim3InDW.cjs.map +1 -0
- package/dist/RadioTabs/index.cjs +7 -5
- package/dist/RadioTabs/index.d.cts +1 -1
- package/dist/RadioTabs/index.d.ts +1 -1
- package/dist/RadioTabs/index.js +2 -3
- package/dist/{RadioTabs-DfOGIsEf.js → RadioTabs-CsVqYCE9.js} +6 -9
- package/dist/RadioTabs-CsVqYCE9.js.map +1 -0
- package/dist/{RadioTabs-BaHvYcd-.cjs → RadioTabs-t-x2XnuI.cjs} +18 -21
- package/dist/RadioTabs-t-x2XnuI.cjs.map +1 -0
- package/dist/Radios/index.cjs +7 -5
- package/dist/Radios/index.d.cts +1 -1
- package/dist/Radios/index.d.ts +1 -1
- package/dist/Radios/index.js +2 -3
- package/dist/{Radios-xM-09vB5.js → Radios-CYwW3bZa.js} +13 -19
- package/dist/Radios-CYwW3bZa.js.map +1 -0
- package/dist/{Radios-BfA3uL35.cjs → Radios-CjEFdyD6.cjs} +25 -31
- package/dist/Radios-CjEFdyD6.cjs.map +1 -0
- package/dist/Select/index.cjs +7 -5
- package/dist/Select/index.d.cts +1 -1
- package/dist/Select/index.d.ts +1 -1
- package/dist/Select/index.js +2 -3
- package/dist/{Select-DH_YaruM.cjs → Select-BEed8xan.cjs} +23 -28
- package/dist/Select-BEed8xan.cjs.map +1 -0
- package/dist/{Select-DlEUzYl6.js → Select-BILyyM7Z.js} +9 -14
- package/dist/Select-BILyyM7Z.js.map +1 -0
- package/dist/Slider/index.cjs +7 -5
- package/dist/Slider/index.d.cts +1 -1
- package/dist/Slider/index.d.ts +1 -1
- package/dist/Slider/index.js +2 -3
- package/dist/{Slider-C-dMrJZ6.cjs → Slider-CFYP86ku.cjs} +16 -19
- package/dist/Slider-CFYP86ku.cjs.map +1 -0
- package/dist/{Slider-CTFuVrp2.js → Slider-DxRcLu-j.js} +5 -8
- package/dist/{Slider-CTFuVrp2.js.map → Slider-DxRcLu-j.js.map} +1 -1
- package/dist/SubmitButton/index.cjs +7 -5
- package/dist/SubmitButton/index.d.cts +1 -1
- package/dist/SubmitButton/index.d.ts +1 -1
- package/dist/SubmitButton/index.js +2 -3
- package/dist/{SubmitButton-Bh1RN0F1.js → SubmitButton-Bu3NNFyt.js} +5 -8
- package/dist/SubmitButton-Bu3NNFyt.js.map +1 -0
- package/dist/{SubmitButton-CJ6s1mZr.cjs → SubmitButton-D7xacDyS.cjs} +15 -18
- package/dist/SubmitButton-D7xacDyS.cjs.map +1 -0
- package/dist/Switch/index.cjs +7 -5
- package/dist/Switch/index.d.cts +1 -1
- package/dist/Switch/index.d.ts +1 -1
- package/dist/Switch/index.js +2 -3
- package/dist/{Switch-CXrz-M3V.js → Switch-CMpXZdLc.js} +5 -8
- package/dist/{Switch-CXrz-M3V.js.map → Switch-CMpXZdLc.js.map} +1 -1
- package/dist/{Switch-CeUMwheZ.cjs → Switch-Dt9TGQ8d.cjs} +16 -19
- package/dist/Switch-Dt9TGQ8d.cjs.map +1 -0
- package/dist/SwitchBox/index.cjs +7 -5
- package/dist/SwitchBox/index.d.cts +1 -1
- package/dist/SwitchBox/index.d.ts +1 -1
- package/dist/SwitchBox/index.js +2 -3
- package/dist/{SwitchBox-C-aLl2nX.js → SwitchBox-Cg7NPfp_.js} +5 -8
- package/dist/SwitchBox-Cg7NPfp_.js.map +1 -0
- package/dist/{SwitchBox-mGUPvJE0.cjs → SwitchBox-DMPp_Ed-.cjs} +21 -24
- package/dist/SwitchBox-DMPp_Ed-.cjs.map +1 -0
- package/dist/TextArea/index.cjs +7 -5
- package/dist/TextArea/index.d.cts +1 -1
- package/dist/TextArea/index.d.ts +1 -1
- package/dist/TextArea/index.js +2 -3
- package/dist/{TextArea-BLkVYmHZ.js → TextArea-Bxi2pXvY.js} +6 -9
- package/dist/TextArea-Bxi2pXvY.js.map +1 -0
- package/dist/{TextArea-BYEuk4Ng.cjs → TextArea-DDwzXW-y.cjs} +18 -21
- package/dist/TextArea-DDwzXW-y.cjs.map +1 -0
- package/dist/helpers/index.cjs +397 -10
- package/dist/helpers/index.cjs.map +1 -0
- package/dist/helpers/index.d.cts +224 -2
- package/dist/helpers/index.d.cts.map +1 -0
- package/dist/helpers/index.d.ts +224 -2
- package/dist/helpers/index.d.ts.map +1 -0
- package/dist/helpers/index.js +387 -2
- package/dist/helpers/index.js.map +1 -0
- package/dist/hooks/useClientValidation/index.cjs +3 -3
- package/dist/hooks/useClientValidation/index.d.cts +1 -1
- package/dist/hooks/useClientValidation/index.d.ts +1 -1
- package/dist/hooks/useClientValidation/index.js +2 -3
- package/dist/hooks/useController/index.cjs +3 -3
- package/dist/hooks/useController/index.d.cts +1 -1
- package/dist/hooks/useController/index.d.ts +1 -1
- package/dist/hooks/useController/index.js +2 -3
- package/dist/hooks/useFormContext/index.cjs +8 -3
- package/dist/hooks/useFormContext/index.cjs.map +1 -0
- package/dist/hooks/useFormContext/index.d.cts +1 -1
- package/dist/hooks/useFormContext/index.d.ts +1 -3
- package/dist/hooks/useFormContext/index.js +6 -2
- package/dist/hooks/useFormContext/index.js.map +1 -0
- package/dist/hooks/useInput/index.cjs +8 -8
- package/dist/hooks/useInput/index.d.cts +1 -1
- package/dist/hooks/useInput/index.d.ts +1 -1
- package/dist/hooks/useInput/index.js +2 -3
- package/dist/hooks/useInputValueDebounce/index.cjs +92 -2
- package/dist/hooks/useInputValueDebounce/index.cjs.map +1 -0
- package/dist/hooks/useInputValueDebounce/index.d.cts +1 -1
- package/dist/hooks/useInputValueDebounce/index.d.ts +1 -1
- package/dist/hooks/useInputValueDebounce/index.js +90 -2
- package/dist/hooks/useInputValueDebounce/index.js.map +1 -0
- package/dist/hooks/useInputValueTransform/index.cjs +3 -3
- package/dist/hooks/useInputValueTransform/index.d.cts +1 -1
- package/dist/hooks/useInputValueTransform/index.d.ts +1 -1
- package/dist/hooks/useInputValueTransform/index.js +2 -3
- package/dist/hooks/useUniformField/index.cjs +135 -2
- package/dist/hooks/useUniformField/index.cjs.map +1 -0
- package/dist/hooks/useUniformField/index.d.cts +1 -1
- package/dist/hooks/useUniformField/index.d.ts +1 -5
- package/dist/hooks/useUniformField/index.js +132 -2
- package/dist/hooks/useUniformField/index.js.map +1 -0
- package/dist/hooks/useUniformFieldArray/index.cjs +83 -2
- package/dist/hooks/useUniformFieldArray/index.cjs.map +1 -0
- package/dist/hooks/useUniformFieldArray/index.d.cts +1 -1
- package/dist/hooks/useUniformFieldArray/index.d.ts +1 -26
- package/dist/hooks/useUniformFieldArray/index.js +81 -2
- package/dist/hooks/useUniformFieldArray/index.js.map +1 -0
- package/dist/hooks/useWatchUserChange/index.cjs +3 -3
- package/dist/hooks/useWatchUserChange/index.d.cts +1 -1
- package/dist/hooks/useWatchUserChange/index.d.ts +1 -1
- package/dist/hooks/useWatchUserChange/index.js +2 -3
- package/dist/{index-TmijvCD0.d.ts → index-25CYKzg4.d.cts} +22 -22
- package/dist/index-25CYKzg4.d.cts.map +1 -0
- package/dist/{index-CeiIXmAI.d.cts → index-3e3711-8.d.cts} +36 -36
- package/dist/index-3e3711-8.d.cts.map +1 -0
- package/dist/{index-E6etS7_8.d.ts → index-6hu79Fof.d.ts} +34 -34
- package/dist/index-6hu79Fof.d.ts.map +1 -0
- package/dist/index-AmOFlE3L.d.cts +278 -0
- package/dist/index-AmOFlE3L.d.cts.map +1 -0
- package/dist/{index-wwmQClW-.d.cts → index-B-6CMF1H.d.ts} +21 -21
- package/dist/index-B-6CMF1H.d.ts.map +1 -0
- package/dist/{index-ahxY6Q0X.d.cts → index-B6WwxkLx2.d.ts} +3 -3
- package/dist/index-B6WwxkLx2.d.ts.map +1 -0
- package/dist/{index-BlJFGN_o.d.ts → index-B9lVf5LI.d.ts} +48 -48
- package/dist/index-B9lVf5LI.d.ts.map +1 -0
- package/dist/{index-ttNINAv3.d.ts → index-BV1VKQdy.d.cts} +3 -3
- package/dist/{index-qo0Ta_R3.d.cts.map → index-BV1VKQdy.d.cts.map} +1 -1
- package/dist/{index-C1-F9Ga-.d.cts → index-BdYKQ59a.d.cts} +7 -7
- package/dist/index-BdYKQ59a.d.cts.map +1 -0
- package/dist/{index-Bl1Adhfx.d.ts → index-BwAI1VFS.d.ts} +6 -6
- package/dist/index-BwAI1VFS.d.ts.map +1 -0
- package/dist/{index-BsCPUK2g.d.cts → index-BzIB-MQg.d.cts} +48 -48
- package/dist/index-BzIB-MQg.d.cts.map +1 -0
- package/dist/{index-DFzyOxvt.d.cts → index-C-DiLZRu.d.cts} +6 -6
- package/dist/index-C-DiLZRu.d.cts.map +1 -0
- package/dist/{index-BKQc5PQn.d.cts → index-C9up4f3f.d.cts} +34 -34
- package/dist/index-C9up4f3f.d.cts.map +1 -0
- package/dist/{index-Dty4h2eA.d.ts → index-CE0aQlFw.d.ts} +7 -7
- package/dist/index-CE0aQlFw.d.ts.map +1 -0
- package/dist/{index-BrMk3Wee.d.ts → index-CY2Mpaz3.d.cts} +4 -4
- package/dist/index-CY2Mpaz3.d.cts.map +1 -0
- package/dist/index-CuRn5Thx.d.ts +278 -0
- package/dist/index-CuRn5Thx.d.ts.map +1 -0
- package/dist/{index-qo0Ta_R3.d.cts → index-Cv4ERj3i.d.ts} +3 -3
- package/dist/{index-ttNINAv3.d.ts.map → index-Cv4ERj3i.d.ts.map} +1 -1
- package/dist/{index-ByyEP8UR.d.cts → index-D6XwSwTP.d.cts} +6 -6
- package/dist/{index-ByyEP8UR.d.cts.map → index-D6XwSwTP.d.cts.map} +1 -1
- package/dist/{index-Dr06SNZN.d.cts → index-DD_RPe91.d.ts} +4 -4
- package/dist/index-DD_RPe91.d.ts.map +1 -0
- package/dist/{index-DLR8z1lG.d.cts → index-DFWSHdua.d.ts} +3 -3
- package/dist/{index-CPkTYivq.d.ts.map → index-DFWSHdua.d.ts.map} +1 -1
- package/dist/{index-B0rp5NJy.d.cts → index-DMwNV_Br.d.cts} +35 -36
- package/dist/index-DMwNV_Br.d.cts.map +1 -0
- package/dist/index-DeEmP3Jc.d.cts +1 -0
- package/dist/{index-mmk9VKYu.d.ts → index-DiD7s23-.d.cts} +21 -21
- package/dist/index-DiD7s23-.d.cts.map +1 -0
- package/dist/{index--NM5Ctp6.d.ts → index-Dj3NDj0T.d.ts} +4 -4
- package/dist/{index--NM5Ctp6.d.ts.map → index-Dj3NDj0T.d.ts.map} +1 -1
- package/dist/{index-CPkTYivq.d.ts → index-DkiQkdCW.d.cts} +3 -3
- package/dist/{index-DLR8z1lG.d.cts.map → index-DkiQkdCW.d.cts.map} +1 -1
- package/dist/{index-CI0AWMsR.d.ts → index-DkxqHE_P2.d.ts} +3 -3
- package/dist/{index-B7Xz_OY2.d.cts.map → index-DkxqHE_P2.d.ts.map} +1 -1
- package/dist/{index-B7Xz_OY2.d.cts → index-Dld6NP_K.d.cts} +3 -3
- package/dist/index-Dld6NP_K.d.cts.map +1 -0
- package/dist/{index-CZq5eXSP.d.ts → index-DlebotZ4.d.ts} +36 -36
- package/dist/index-DlebotZ4.d.ts.map +1 -0
- package/dist/index-DsC0y6kU.d.cts +70 -0
- package/dist/index-DsC0y6kU.d.cts.map +1 -0
- package/dist/index-DwqOejxR.d.ts +70 -0
- package/dist/index-DwqOejxR.d.ts.map +1 -0
- package/dist/{index-BaxXDaOZ.d.ts → index-Gs3zrYoY.d.ts} +35 -37
- package/dist/index-Gs3zrYoY.d.ts.map +1 -0
- package/dist/{index-BlX_mF6D.d.cts → index-N5wvPOq3.d.ts} +22 -22
- package/dist/index-N5wvPOq3.d.ts.map +1 -0
- package/dist/{index-BNYtqtXt.d.cts → index-NjKV8LJD.d.cts} +4 -4
- package/dist/{index-BNYtqtXt.d.cts.map → index-NjKV8LJD.d.cts.map} +1 -1
- package/dist/{index-DVZCz730.d.ts → index-fgARdsoB.d.ts} +6 -6
- package/dist/{index-DVZCz730.d.ts.map → index-fgARdsoB.d.ts.map} +1 -1
- package/dist/{index-CMehV9mc.d.ts → index-jCfJAgDc.d.cts} +3 -3
- package/dist/index-jCfJAgDc.d.cts.map +1 -0
- package/dist/{index--KhDRPu3.d.cts → index-pwXVq8hR.d.cts} +6 -6
- package/dist/index-pwXVq8hR.d.cts.map +1 -0
- package/dist/index-sQecLSpR.d.cts +1 -0
- package/dist/{index-BgyvEfYZ.d.ts → index-wV1E_PkS.d.ts} +6 -6
- package/dist/index-wV1E_PkS.d.ts.map +1 -0
- package/dist/index.cjs +63 -63
- package/dist/index.d.cts +27 -27
- package/dist/index.d.ts +27 -29
- package/dist/index.js +29 -30
- package/dist/partials/FieldCopyTestIdButton/index.cjs +7 -5
- package/dist/partials/FieldCopyTestIdButton/index.d.cts +1 -1
- package/dist/partials/FieldCopyTestIdButton/index.d.ts +1 -1
- package/dist/partials/FieldCopyTestIdButton/index.js +2 -3
- package/dist/partials/FieldValidationError/index.cjs +7 -5
- package/dist/partials/FieldValidationError/index.d.cts +1 -1
- package/dist/partials/FieldValidationError/index.d.ts +1 -1
- package/dist/partials/FieldValidationError/index.js +2 -3
- package/dist/{useClientValidation-B4xrGBJZ.d.ts → useClientValidation-BWElhQ91.d.ts} +2 -3
- package/dist/useClientValidation-BWElhQ91.d.ts.map +1 -0
- package/dist/{useClientValidation-DksyV18M.js → useClientValidation-Dn_kJkE5.js} +5 -6
- package/dist/{useClientValidation-DksyV18M.js.map → useClientValidation-Dn_kJkE5.js.map} +1 -1
- package/dist/{useClientValidation-B_dYQB5o.d.cts → useClientValidation-DtnfCE5T.d.cts} +2 -3
- package/dist/{useClientValidation-B4xrGBJZ.d.ts.map → useClientValidation-DtnfCE5T.d.cts.map} +1 -1
- package/dist/{useClientValidation-Dnj_wuwf.cjs → useClientValidation-NKOuXuHV.cjs} +16 -17
- package/dist/useClientValidation-NKOuXuHV.cjs.map +1 -0
- package/dist/{useController-NjuthTyL.js → useController-B-6PzFna.js} +4 -5
- package/dist/{useController-NjuthTyL.js.map → useController-B-6PzFna.js.map} +1 -1
- package/dist/{useController-D8MEXnmB.d.cts → useController-CNiqy_2D.d.cts} +1 -1
- package/dist/{useController-D8MEXnmB.d.cts.map → useController-CNiqy_2D.d.cts.map} +1 -1
- package/dist/{useController-CHOpoCoz.d.ts → useController-Cc0UNQMm.d.ts} +1 -1
- package/dist/{useController-CHOpoCoz.d.ts.map → useController-Cc0UNQMm.d.ts.map} +1 -1
- package/dist/{useController-B_SSp5Z5.cjs → useController-DVRh86Zy.cjs} +11 -12
- package/dist/{useController-B_SSp5Z5.cjs.map → useController-DVRh86Zy.cjs.map} +1 -1
- package/dist/{useFormContext-vdeeDsAs.cjs → useFormContext-Bum4VP1o.cjs} +20 -21
- package/dist/{useFormContext-vdeeDsAs.cjs.map → useFormContext-Bum4VP1o.cjs.map} +1 -1
- package/dist/{useFormContext-Di67HIf7.js → useFormContext-Bzpyonu6.js} +5 -6
- package/dist/{useFormContext-Di67HIf7.js.map → useFormContext-Bzpyonu6.js.map} +1 -1
- package/dist/{useFormContext-C6OOtqZ5.d.ts → useFormContext-DEMm-bsc.d.ts} +22 -22
- package/dist/useFormContext-DEMm-bsc.d.ts.map +1 -0
- package/dist/{useFormContext-Dh97YG47.d.cts → useFormContext-Dey5DbWr.d.cts} +22 -22
- package/dist/useFormContext-Dey5DbWr.d.cts.map +1 -0
- package/dist/{useInput-BWzvIUpW.js → useInput-CVm3tP78.js} +1 -2
- package/dist/{useInputValueDebounce-ZLyAmuXV.d.cts → useInputValueDebounce-puGRVJ6t.d.cts} +1 -1
- package/dist/{useInputValueDebounce-ZLyAmuXV.d.cts.map → useInputValueDebounce-puGRVJ6t.d.cts.map} +1 -1
- package/dist/{useInputValueDebounce-Dhlv1NUY.d.ts → useInputValueDebounce-sFOlecIQ.d.ts} +1 -1
- package/dist/{useInputValueDebounce-Dhlv1NUY.d.ts.map → useInputValueDebounce-sFOlecIQ.d.ts.map} +1 -1
- package/dist/{useInputValueTransform-CNCBU7a9.d.cts → useInputValueTransform-BwAfw8Xb.d.cts} +1 -1
- package/dist/{useInputValueTransform-CNCBU7a9.d.cts.map → useInputValueTransform-BwAfw8Xb.d.cts.map} +1 -1
- package/dist/{useInputValueTransform-C-fmz3ke.js → useInputValueTransform-CXdmtc0Q.js} +2 -3
- package/dist/{useInputValueTransform-C-fmz3ke.js.map → useInputValueTransform-CXdmtc0Q.js.map} +1 -1
- package/dist/{useInputValueTransform-tsMNM7g_.d.ts → useInputValueTransform-CdoaxNyD.d.ts} +1 -1
- package/dist/{useInputValueTransform-tsMNM7g_.d.ts.map → useInputValueTransform-CdoaxNyD.d.ts.map} +1 -1
- package/dist/{useInputValueTransform-BBRvvhDe.cjs → useInputValueTransform-DKH-7F9D.cjs} +8 -9
- package/dist/{useInputValueTransform-BBRvvhDe.cjs.map → useInputValueTransform-DKH-7F9D.cjs.map} +1 -1
- package/dist/{useUniformField-Bd_oDkYE.d.cts → useUniformField-DB8jF52F.d.cts} +5 -5
- package/dist/{useUniformField-Bd_oDkYE.d.cts.map → useUniformField-DB8jF52F.d.cts.map} +1 -1
- package/dist/{useUniformField-BDKjYBKu.d.ts → useUniformField-iHk8xYXN.d.ts} +5 -5
- package/dist/{useUniformField-BDKjYBKu.d.ts.map → useUniformField-iHk8xYXN.d.ts.map} +1 -1
- package/dist/{useUniformFieldArray-lV3Nbum2.d.ts → useUniformFieldArray-B0SPtHeT.d.ts} +18 -18
- package/dist/useUniformFieldArray-B0SPtHeT.d.ts.map +1 -0
- package/dist/{useUniformFieldArray-CWiaXKO6.d.cts → useUniformFieldArray-okvikMJp.d.cts} +18 -18
- package/dist/useUniformFieldArray-okvikMJp.d.cts.map +1 -0
- package/dist/{useWatchUserChange-C1Kluht2.cjs → useWatchUserChange-CBuIa5kU.cjs} +9 -10
- package/dist/{useWatchUserChange-C1Kluht2.cjs.map → useWatchUserChange-CBuIa5kU.cjs.map} +1 -1
- package/dist/{useWatchUserChange-BnnrFjyq.d.ts → useWatchUserChange-CH4x16_r.d.ts} +1 -1
- package/dist/{useWatchUserChange-BnnrFjyq.d.ts.map → useWatchUserChange-CH4x16_r.d.ts.map} +1 -1
- package/dist/{useWatchUserChange-Dj9Imxfi.js → useWatchUserChange-CLgLc5W4.js} +3 -4
- package/dist/{useWatchUserChange-Dj9Imxfi.js.map → useWatchUserChange-CLgLc5W4.js.map} +1 -1
- package/dist/{useWatchUserChange-DalJOKBC.d.cts → useWatchUserChange-CZu_ZZ38.d.cts} +1 -1
- package/dist/{useWatchUserChange-DalJOKBC.d.cts.map → useWatchUserChange-CZu_ZZ38.d.cts.map} +1 -1
- package/package.json +74 -70
- package/dist/Checkboxes-BGrK_mwQ.js.map +0 -1
- package/dist/Checkboxes-Dk7yyRVR.cjs.map +0 -1
- package/dist/FieldArray-Bs2ViU8m.js.map +0 -1
- package/dist/FieldArray-C6RHZcKa.cjs.map +0 -1
- package/dist/FieldCard-16yCF83m.js.map +0 -1
- package/dist/FieldCard-BxK_IJOR.cjs.map +0 -1
- package/dist/FieldCopyTestIdButton-4uupFq1U.cjs.map +0 -1
- package/dist/FieldCopyTestIdButton-BoEdlzLs.js.map +0 -1
- package/dist/FieldValidationError-Br6iopZj.cjs.map +0 -1
- package/dist/FieldValidationError-XQaViV52.js.map +0 -1
- package/dist/Form--SsSvsxl.cjs.map +0 -1
- package/dist/Form-ccsEssie.js.map +0 -1
- package/dist/Grid-BaqBa1ku.js.map +0 -1
- package/dist/Grid-D5Yf0nD_.cjs.map +0 -1
- package/dist/Input-B3p_4ntD.cjs.map +0 -1
- package/dist/RadioBoxes-C3Cwrn2I.js.map +0 -1
- package/dist/RadioBoxes-xRvNe5U8.cjs.map +0 -1
- package/dist/RadioTabs-BaHvYcd-.cjs.map +0 -1
- package/dist/RadioTabs-DfOGIsEf.js.map +0 -1
- package/dist/Radios-BfA3uL35.cjs.map +0 -1
- package/dist/Radios-xM-09vB5.js.map +0 -1
- package/dist/Select-DH_YaruM.cjs.map +0 -1
- package/dist/Select-DlEUzYl6.js.map +0 -1
- package/dist/Slider-C-dMrJZ6.cjs.map +0 -1
- package/dist/SubmitButton-Bh1RN0F1.js.map +0 -1
- package/dist/SubmitButton-CJ6s1mZr.cjs.map +0 -1
- package/dist/Switch-CeUMwheZ.cjs.map +0 -1
- package/dist/SwitchBox-C-aLl2nX.js.map +0 -1
- package/dist/SwitchBox-mGUPvJE0.cjs.map +0 -1
- package/dist/TextArea-BLkVYmHZ.js.map +0 -1
- package/dist/TextArea-BYEuk4Ng.cjs.map +0 -1
- package/dist/helpers-33jajRcN.js +0 -390
- package/dist/helpers-33jajRcN.js.map +0 -1
- package/dist/helpers-Bd_QpqXg.cjs +0 -444
- package/dist/helpers-Bd_QpqXg.cjs.map +0 -1
- package/dist/index--KhDRPu3.d.cts.map +0 -1
- package/dist/index-B0rp5NJy.d.cts.map +0 -1
- package/dist/index-BBw9RSKy.d.ts +0 -278
- package/dist/index-BBw9RSKy.d.ts.map +0 -1
- package/dist/index-BKQc5PQn.d.cts.map +0 -1
- package/dist/index-BLgXFM85.d.cts +0 -224
- package/dist/index-BLgXFM85.d.cts.map +0 -1
- package/dist/index-BaxXDaOZ.d.ts.map +0 -1
- package/dist/index-BgyvEfYZ.d.ts.map +0 -1
- package/dist/index-BjHnNRSC.d.cts +0 -278
- package/dist/index-BjHnNRSC.d.cts.map +0 -1
- package/dist/index-Bl1Adhfx.d.ts.map +0 -1
- package/dist/index-BlJFGN_o.d.ts.map +0 -1
- package/dist/index-BlX_mF6D.d.cts.map +0 -1
- package/dist/index-BrMk3Wee.d.ts.map +0 -1
- package/dist/index-BsCPUK2g.d.cts.map +0 -1
- package/dist/index-C1-F9Ga-.d.cts.map +0 -1
- package/dist/index-CI0AWMsR.d.ts.map +0 -1
- package/dist/index-CMehV9mc.d.ts.map +0 -1
- package/dist/index-CZq5eXSP.d.ts.map +0 -1
- package/dist/index-CeiIXmAI.d.cts.map +0 -1
- package/dist/index-DFzyOxvt.d.cts.map +0 -1
- package/dist/index-Dr06SNZN.d.cts.map +0 -1
- package/dist/index-Dty4h2eA.d.ts.map +0 -1
- package/dist/index-E6etS7_8.d.ts.map +0 -1
- package/dist/index-TmijvCD0.d.ts.map +0 -1
- package/dist/index-ahxY6Q0X.d.cts.map +0 -1
- package/dist/index-mmk9VKYu.d.ts.map +0 -1
- package/dist/index-w8E8Koak.d.ts +0 -224
- package/dist/index-w8E8Koak.d.ts.map +0 -1
- package/dist/index-wwmQClW-.d.cts.map +0 -1
- package/dist/useClientValidation-B_dYQB5o.d.cts.map +0 -1
- package/dist/useClientValidation-Dnj_wuwf.cjs.map +0 -1
- package/dist/useFormContext-C6OOtqZ5.d.ts.map +0 -1
- package/dist/useFormContext-CLymm_7t.js +0 -6
- package/dist/useFormContext-CLymm_7t.js.map +0 -1
- package/dist/useFormContext-CkeSOfWD.cjs +0 -6
- package/dist/useFormContext-CkeSOfWD.cjs.map +0 -1
- package/dist/useFormContext-Dh97YG47.d.cts.map +0 -1
- package/dist/useInputValueDebounce-CRaM7HEM.cjs +0 -99
- package/dist/useInputValueDebounce-CRaM7HEM.cjs.map +0 -1
- package/dist/useInputValueDebounce-DJO5uzLb.js +0 -93
- package/dist/useInputValueDebounce-DJO5uzLb.js.map +0 -1
- package/dist/useUniformField-6c4OCAfb.cjs +0 -142
- package/dist/useUniformField-6c4OCAfb.cjs.map +0 -1
- package/dist/useUniformField-C-Xyu-8v.js +0 -135
- package/dist/useUniformField-C-Xyu-8v.js.map +0 -1
- package/dist/useUniformFieldArray-BKvA0FQW.js +0 -84
- package/dist/useUniformFieldArray-BKvA0FQW.js.map +0 -1
- package/dist/useUniformFieldArray-CRCbV1J2.cjs +0 -90
- package/dist/useUniformFieldArray-CRCbV1J2.cjs.map +0 -1
- package/dist/useUniformFieldArray-CWiaXKO6.d.cts.map +0 -1
- package/dist/useUniformFieldArray-lV3Nbum2.d.ts.map +0 -1
- /package/dist/{index-BMCcWGYS.d.ts → index--okzibnx.d.ts} +0 -0
- /package/dist/{index-C8k_zgEm.d.cts → index-B2TCFhpj.d.ts} +0 -0
- /package/dist/{index-DDRpa5CJ.d.cts → index-BtBZHVmz.d.cts} +0 -0
- /package/dist/{index-GGHuYh77.d.ts → index-CI4LJief.d.ts} +0 -0
- /package/dist/{useInput-BVZvtfNg.d.ts → useInput-93TCCrkB.d.cts} +0 -0
- /package/dist/{useInput-CKmKH9Ij.d.cts → useInput-C_fY--wx.d.ts} +0 -0
|
@@ -1,3 +1,84 @@
|
|
|
1
|
-
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
+
require("../../FormContext-BrY1FQYR.cjs");
|
|
3
|
+
const require_helpers_index = require("../../helpers/index.cjs");
|
|
4
|
+
const require_useFormContext = require("../../useFormContext-Bum4VP1o.cjs");
|
|
5
|
+
const require_hooks_useUniformField_index = require("../useUniformField/index.cjs");
|
|
6
|
+
let react = require("react");
|
|
7
|
+
let _fuf_stack_pixel_motion = require("@fuf-stack/pixel-motion");
|
|
8
|
+
let react_hook_form = require("react-hook-form");
|
|
9
|
+
//#region src/hooks/useUniformFieldArray/useUniformFieldArray.ts
|
|
10
|
+
/**
|
|
11
|
+
* Enhanced useFieldArray hook with initialization and animation logic.
|
|
12
|
+
* Based on React Hook Form's useFieldArray with additional features:
|
|
13
|
+
* - Automatic initialization when lastElementNotRemovable is set
|
|
14
|
+
* - Animation control (disabled during initialization)
|
|
15
|
+
* - Support for flat arrays (arrays of primitives)
|
|
16
|
+
*
|
|
17
|
+
* Note: Automatic validation triggering on length change is disabled to prevent
|
|
18
|
+
* triggering form-wide validation. Array validation still runs on form submission.
|
|
19
|
+
*
|
|
20
|
+
* @see https://react-hook-form.com/docs/usefieldarray
|
|
21
|
+
*/
|
|
22
|
+
const useUniformFieldArray = ({ name, flat = false, elementInitialValue: _elementInitialValue = null, lastElementNotRemovable = false, disabled, testId: explicitTestId, label }) => {
|
|
23
|
+
const uniformField = require_hooks_useUniformField_index.useUniformField({
|
|
24
|
+
name,
|
|
25
|
+
disabled,
|
|
26
|
+
testId: explicitTestId,
|
|
27
|
+
label
|
|
28
|
+
});
|
|
29
|
+
const { control } = uniformField;
|
|
30
|
+
const { fields, append, remove, insert, move } = (0, react_hook_form.useFieldArray)({
|
|
31
|
+
control,
|
|
32
|
+
name
|
|
33
|
+
});
|
|
34
|
+
const { trigger, setValue } = require_useFormContext.useFormContext();
|
|
35
|
+
const needsInitialize = (0, react.useMemo)(() => {
|
|
36
|
+
return lastElementNotRemovable && fields.length === 0;
|
|
37
|
+
}, [lastElementNotRemovable, fields.length]);
|
|
38
|
+
const hasInitialized = (0, react.useRef)(!needsInitialize);
|
|
39
|
+
(0, react.useEffect)(() => {
|
|
40
|
+
if (needsInitialize) hasInitialized.current = false;
|
|
41
|
+
}, [needsInitialize]);
|
|
42
|
+
(0, react.useEffect)(() => {
|
|
43
|
+
if (hasInitialized.current) setTimeout(() => {
|
|
44
|
+
trigger(name);
|
|
45
|
+
}, 200);
|
|
46
|
+
}, [fields.length]);
|
|
47
|
+
const [disableAnimation, setDisableAnimation] = (0, react.useState)(true);
|
|
48
|
+
const prefersReducedMotion = (0, _fuf_stack_pixel_motion.useReducedMotion)();
|
|
49
|
+
(0, react.useEffect)(() => {
|
|
50
|
+
if (hasInitialized.current) setDisableAnimation(!!prefersReducedMotion);
|
|
51
|
+
}, [prefersReducedMotion]);
|
|
52
|
+
const elementInitialValue = (0, react.useMemo)(() => {
|
|
53
|
+
return flat ? { [require_helpers_index.flatArrayKey]: _elementInitialValue ?? null } : _elementInitialValue ?? {};
|
|
54
|
+
}, [flat, _elementInitialValue]);
|
|
55
|
+
(0, react.useEffect)(() => {
|
|
56
|
+
if (needsInitialize) {
|
|
57
|
+
setValue(name, [elementInitialValue], {
|
|
58
|
+
shouldDirty: false,
|
|
59
|
+
shouldTouch: false
|
|
60
|
+
});
|
|
61
|
+
hasInitialized.current = true;
|
|
62
|
+
if (!prefersReducedMotion && disableAnimation) setTimeout(() => {
|
|
63
|
+
setDisableAnimation(false);
|
|
64
|
+
}, 1);
|
|
65
|
+
}
|
|
66
|
+
}, [needsInitialize]);
|
|
67
|
+
return {
|
|
68
|
+
fields,
|
|
69
|
+
append,
|
|
70
|
+
remove,
|
|
71
|
+
insert,
|
|
72
|
+
move,
|
|
73
|
+
disableAnimation,
|
|
74
|
+
elementInitialValue,
|
|
75
|
+
...uniformField
|
|
76
|
+
};
|
|
77
|
+
};
|
|
78
|
+
//#endregion
|
|
79
|
+
//#region src/hooks/useUniformFieldArray/index.ts
|
|
80
|
+
/* v8 ignore stop */
|
|
81
|
+
//#endregion
|
|
82
|
+
exports.useUniformFieldArray = useUniformFieldArray;
|
|
2
83
|
|
|
3
|
-
|
|
84
|
+
//# sourceMappingURL=index.cjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.cjs","names":["useUniformField","useFormContext","flatArrayKey"],"sources":["../../../src/hooks/useUniformFieldArray/useUniformFieldArray.ts","../../../src/hooks/useUniformFieldArray/index.ts"],"sourcesContent":["import type { ReactNode } from 'react';\nimport type { ArrayPath, FieldValues, Path } from 'react-hook-form';\n\nimport { useEffect, useMemo, useRef, useState } from 'react';\nimport { useFieldArray as useRHFFieldArray } from 'react-hook-form';\n\nimport { useReducedMotion } from '@fuf-stack/pixel-motion';\n\nimport { flatArrayKey } from '../../helpers';\nimport { useFormContext } from '../useFormContext';\nimport { useUniformField } from '../useUniformField';\n\nexport interface UseUniformFieldArrayProps<\n TFieldValues extends FieldValues = FieldValues,\n> {\n /** Field name for the array */\n name: ArrayPath<TFieldValues>;\n /** Whether this is a flat array (array of primitives) */\n flat?: boolean;\n /** Initial value for new array elements */\n elementInitialValue?: unknown;\n /** Whether the last element cannot be removed (always maintain at least one element) */\n lastElementNotRemovable?: boolean;\n /** Disable the field */\n disabled?: boolean;\n /** Optional explicit test id used to build stable test ids */\n testId?: string;\n /** Optional label content */\n label?: ReactNode;\n}\n\n/**\n * Enhanced useFieldArray hook with initialization and animation logic.\n * Based on React Hook Form's useFieldArray with additional features:\n * - Automatic initialization when lastElementNotRemovable is set\n * - Animation control (disabled during initialization)\n * - Support for flat arrays (arrays of primitives)\n *\n * Note: Automatic validation triggering on length change is disabled to prevent\n * triggering form-wide validation. Array validation still runs on form submission.\n *\n * @see https://react-hook-form.com/docs/usefieldarray\n */\nexport const useUniformFieldArray = <\n TFieldValues extends FieldValues = FieldValues,\n>({\n name,\n flat = false,\n elementInitialValue: _elementInitialValue = null,\n lastElementNotRemovable = false,\n disabled,\n testId: explicitTestId,\n label,\n}: UseUniformFieldArrayProps<TFieldValues>) => {\n // Get uniform field state and utilities\n const uniformField = useUniformField<TFieldValues>({\n name: name as Path<TFieldValues> & string,\n disabled,\n testId: explicitTestId,\n label,\n });\n\n const { control } = uniformField;\n\n const { fields, append, remove, insert, move } = useRHFFieldArray({\n control,\n name,\n });\n\n const { trigger, setValue } = useFormContext<TFieldValues>();\n\n // Determine if initialization is needed (initially or after reset).\n // This flag automatically handles both scenarios:\n // - Initial mount: fields.length starts at 0\n // - Form reset: fields.length becomes 0 again\n // Additional initialization conditions can be added here later (e.g., minElements > 0)\n // Using useMemo ensures this value is properly tracked by React and effects can depend on it\n const needsInitialize = useMemo(() => {\n return lastElementNotRemovable && fields.length === 0;\n }, [lastElementNotRemovable, fields.length]);\n\n // Track whether initialization has completed. Initialized contextually:\n // - If initialization IS needed (needsInitialize = true): starts as false, set to true after init\n // - If initialization is NOT needed (needsInitialize = false): starts as true (already initialized)\n // This ref is used to:\n // 1. Skip validation during initialization/re-initialization\n // 2. Gate animation enabling until after initialization\n // 3. Gate motion preference effect until after initialization\n const hasInitialized = useRef(!needsInitialize);\n\n // Reset initialization flag when needsInitialize changes to true.\n // This handles form reset: when fields become empty (needsInitialize becomes true),\n // hasInitialized is reset to false, triggering re-initialization in the effect below.\n useEffect(() => {\n if (needsInitialize) {\n hasInitialized.current = false;\n }\n }, [needsInitialize]);\n\n // Validate array-level constraints (min/max items) when length changes.\n // This ensures min/max errors appear instantly when user adds/removes items.\n // Note: Child field validation also runs, but new empty fields won't show as invalid\n // because useFormContext only sets invalid=true for touched fields or after form submission.\n // Skip validation during initialization/re-initialization to avoid showing errors prematurely.\n useEffect(() => {\n if (hasInitialized.current) {\n setTimeout(() => {\n trigger(name as Path<TFieldValues>);\n }, 200);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [fields.length]);\n\n // Animation control: Start with animations disabled to prevent animating in initial elements.\n // Will be enabled after initialization completes (unless user prefers reduced motion).\n const [disableAnimation, setDisableAnimation] = useState(true);\n\n // Respond to user's motion preference changes (after initialization).\n // During initialization, animations stay disabled regardless of preference.\n const prefersReducedMotion = useReducedMotion();\n useEffect(() => {\n if (hasInitialized.current) {\n setDisableAnimation(!!prefersReducedMotion);\n }\n }, [prefersReducedMotion]);\n\n // Prepare initial element value based on mode\n // - flat=true: arrays of primitives → object with flatArrayKey and null value by default\n // - flat=false: arrays of objects → empty object by default\n const elementInitialValue = useMemo(() => {\n return flat\n ? { [flatArrayKey]: _elementInitialValue ?? null }\n : (_elementInitialValue ?? {});\n }, [flat, _elementInitialValue]);\n\n // Initialization/Re-initialization: Add initial element when needed.\n // This handles both initial mount and form reset scenarios by reacting to needsInitialize.\n // CRITICAL: This effect MUST be the LAST hook in this component.\n // It sets hasInitialized.current = true, which acts as a gate for other effects.\n // If this runs before other effects, hasInitialized will be true during their first run,\n // causing them to execute logic meant only for post-initialization (e.g., validation,\n // animation enabling). By placing this last, all other effects run first with\n // hasInitialized = false, allowing them to skip initialization-phase logic.\n useEffect(\n () => {\n if (needsInitialize) {\n // use setValue instead of append to avoid focusing the added element\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n setValue(name as Path<TFieldValues>, [elementInitialValue] as any, {\n shouldDirty: false,\n shouldTouch: false,\n });\n\n // Mark initialization as complete\n hasInitialized.current = true;\n\n // Enable animations after a brief delay (unless user prefers reduced motion or animations are already enabled).\n // This only runs on initial mount when animations start disabled.\n // On reset, disableAnimation is typically false, so this setTimeout won't run and animations stay enabled.\n if (!prefersReducedMotion && disableAnimation) {\n setTimeout(() => {\n setDisableAnimation(false);\n }, 1);\n }\n }\n },\n // Run when needsInitialize changes (initial mount or reset)\n // needsInitialize is memoized based on fields.length and lastElementNotRemovable\n // Other dependencies are intentionally omitted:\n // - append, setValue, trigger, setDisableAnimation are stable refs/functions\n // - elementInitialValue, name, flat, prefersReducedMotion, disableAnimation are props/stable values\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [needsInitialize],\n );\n\n return {\n // Field array methods and state\n fields,\n append,\n remove,\n insert,\n move,\n disableAnimation,\n elementInitialValue,\n // Uniform field state and utilities (spread all)\n ...uniformField,\n };\n};\n","/* v8 ignore start */\n\nexport * from './useUniformFieldArray';\n\n/* v8 ignore stop */\n"],"mappings":";;;;;;;;;;;;;;;;;;;;;AA2CA,MAAa,wBAEX,EACA,MACA,OAAO,OACP,qBAAqB,uBAAuB,MAC5C,0BAA0B,OAC1B,UACA,QAAQ,gBACR,YAC6C;CAE7C,MAAM,eAAeA,oCAAAA,gBAA8B;EAC3C;EACN;EACA,QAAQ;EACR;EACD,CAAC;CAEF,MAAM,EAAE,YAAY;CAEpB,MAAM,EAAE,QAAQ,QAAQ,QAAQ,QAAQ,UAAA,GAAA,gBAAA,eAA0B;EAChE;EACA;EACD,CAAC;CAEF,MAAM,EAAE,SAAS,aAAaC,uBAAAA,gBAA8B;CAQ5D,MAAM,mBAAA,GAAA,MAAA,eAAgC;AACpC,SAAO,2BAA2B,OAAO,WAAW;IACnD,CAAC,yBAAyB,OAAO,OAAO,CAAC;CAS5C,MAAM,kBAAA,GAAA,MAAA,QAAwB,CAAC,gBAAgB;AAK/C,EAAA,GAAA,MAAA,iBAAgB;AACd,MAAI,gBACF,gBAAe,UAAU;IAE1B,CAAC,gBAAgB,CAAC;AAOrB,EAAA,GAAA,MAAA,iBAAgB;AACd,MAAI,eAAe,QACjB,kBAAiB;AACf,WAAQ,KAA2B;KAClC,IAAI;IAGR,CAAC,OAAO,OAAO,CAAC;CAInB,MAAM,CAAC,kBAAkB,wBAAA,GAAA,MAAA,UAAgC,KAAK;CAI9D,MAAM,wBAAA,GAAA,wBAAA,mBAAyC;AAC/C,EAAA,GAAA,MAAA,iBAAgB;AACd,MAAI,eAAe,QACjB,qBAAoB,CAAC,CAAC,qBAAqB;IAE5C,CAAC,qBAAqB,CAAC;CAK1B,MAAM,uBAAA,GAAA,MAAA,eAAoC;AACxC,SAAO,OACH,GAAGC,sBAAAA,eAAe,wBAAwB,MAAM,GAC/C,wBAAwB,EAAE;IAC9B,CAAC,MAAM,qBAAqB,CAAC;AAUhC,EAAA,GAAA,MAAA,iBACQ;AACJ,MAAI,iBAAiB;AAGnB,YAAS,MAA4B,CAAC,oBAAoB,EAAS;IACjE,aAAa;IACb,aAAa;IACd,CAAC;AAGF,kBAAe,UAAU;AAKzB,OAAI,CAAC,wBAAwB,iBAC3B,kBAAiB;AACf,wBAAoB,MAAM;MACzB,EAAE;;IAUX,CAAC,gBAAgB,CAClB;AAED,QAAO;EAEL;EACA;EACA;EACA;EACA;EACA;EACA;EAEA,GAAG;EACJ"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as useUniformFieldArray, t as UseUniformFieldArrayProps } from "../../useUniformFieldArray-
|
|
1
|
+
import { n as useUniformFieldArray, t as UseUniformFieldArrayProps } from "../../useUniformFieldArray-okvikMJp.cjs";
|
|
2
2
|
export { UseUniformFieldArrayProps, useUniformFieldArray };
|
|
@@ -1,27 +1,2 @@
|
|
|
1
|
-
import "../../
|
|
2
|
-
import "../../index-DVZCz730.js";
|
|
3
|
-
import "../../index-Bl1Adhfx.js";
|
|
4
|
-
import "../../FormContext-CCe8drkp.js";
|
|
5
|
-
import "../../index--NM5Ctp6.js";
|
|
6
|
-
import "../../index-ttNINAv3.js";
|
|
7
|
-
import "../../index-TmijvCD0.js";
|
|
8
|
-
import "../../index-BaxXDaOZ.js";
|
|
9
|
-
import "../../index-BrMk3Wee.js";
|
|
10
|
-
import "../../index-E6etS7_8.js";
|
|
11
|
-
import "../../index-BBw9RSKy.js";
|
|
12
|
-
import "../../index-BlJFGN_o.js";
|
|
13
|
-
import "../../index-CPkTYivq.js";
|
|
14
|
-
import "../../index-CZq5eXSP.js";
|
|
15
|
-
import "../../index-BgyvEfYZ.js";
|
|
16
|
-
import "../../index-mmk9VKYu.js";
|
|
17
|
-
import "../../useClientValidation-B4xrGBJZ.js";
|
|
18
|
-
import "../../useController-CHOpoCoz.js";
|
|
19
|
-
import "../../useFormContext-C6OOtqZ5.js";
|
|
20
|
-
import "../../index-BMCcWGYS.js";
|
|
21
|
-
import "../../useInput-BVZvtfNg.js";
|
|
22
|
-
import "../../useUniformField-BDKjYBKu.js";
|
|
23
|
-
import "../../index-CMehV9mc.js";
|
|
24
|
-
import "../../index-CI0AWMsR.js";
|
|
25
|
-
import "../../useWatchUserChange-BnnrFjyq.js";
|
|
26
|
-
import { n as useUniformFieldArray, t as UseUniformFieldArrayProps } from "../../useUniformFieldArray-lV3Nbum2.js";
|
|
1
|
+
import { n as useUniformFieldArray, t as UseUniformFieldArrayProps } from "../../useUniformFieldArray-B0SPtHeT.js";
|
|
27
2
|
export { UseUniformFieldArrayProps, useUniformFieldArray };
|
|
@@ -1,3 +1,82 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { flatArrayKey } from "../../helpers/index.js";
|
|
2
|
+
import { n as useFormContext$1 } from "../../useFormContext-Bzpyonu6.js";
|
|
3
|
+
import { useUniformField } from "../useUniformField/index.js";
|
|
4
|
+
import { useEffect, useMemo, useRef, useState } from "react";
|
|
5
|
+
import { useReducedMotion } from "@fuf-stack/pixel-motion";
|
|
6
|
+
import { useFieldArray } from "react-hook-form";
|
|
7
|
+
//#region src/hooks/useUniformFieldArray/useUniformFieldArray.ts
|
|
8
|
+
/**
|
|
9
|
+
* Enhanced useFieldArray hook with initialization and animation logic.
|
|
10
|
+
* Based on React Hook Form's useFieldArray with additional features:
|
|
11
|
+
* - Automatic initialization when lastElementNotRemovable is set
|
|
12
|
+
* - Animation control (disabled during initialization)
|
|
13
|
+
* - Support for flat arrays (arrays of primitives)
|
|
14
|
+
*
|
|
15
|
+
* Note: Automatic validation triggering on length change is disabled to prevent
|
|
16
|
+
* triggering form-wide validation. Array validation still runs on form submission.
|
|
17
|
+
*
|
|
18
|
+
* @see https://react-hook-form.com/docs/usefieldarray
|
|
19
|
+
*/
|
|
20
|
+
const useUniformFieldArray = ({ name, flat = false, elementInitialValue: _elementInitialValue = null, lastElementNotRemovable = false, disabled, testId: explicitTestId, label }) => {
|
|
21
|
+
const uniformField = useUniformField({
|
|
22
|
+
name,
|
|
23
|
+
disabled,
|
|
24
|
+
testId: explicitTestId,
|
|
25
|
+
label
|
|
26
|
+
});
|
|
27
|
+
const { control } = uniformField;
|
|
28
|
+
const { fields, append, remove, insert, move } = useFieldArray({
|
|
29
|
+
control,
|
|
30
|
+
name
|
|
31
|
+
});
|
|
32
|
+
const { trigger, setValue } = useFormContext$1();
|
|
33
|
+
const needsInitialize = useMemo(() => {
|
|
34
|
+
return lastElementNotRemovable && fields.length === 0;
|
|
35
|
+
}, [lastElementNotRemovable, fields.length]);
|
|
36
|
+
const hasInitialized = useRef(!needsInitialize);
|
|
37
|
+
useEffect(() => {
|
|
38
|
+
if (needsInitialize) hasInitialized.current = false;
|
|
39
|
+
}, [needsInitialize]);
|
|
40
|
+
useEffect(() => {
|
|
41
|
+
if (hasInitialized.current) setTimeout(() => {
|
|
42
|
+
trigger(name);
|
|
43
|
+
}, 200);
|
|
44
|
+
}, [fields.length]);
|
|
45
|
+
const [disableAnimation, setDisableAnimation] = useState(true);
|
|
46
|
+
const prefersReducedMotion = useReducedMotion();
|
|
47
|
+
useEffect(() => {
|
|
48
|
+
if (hasInitialized.current) setDisableAnimation(!!prefersReducedMotion);
|
|
49
|
+
}, [prefersReducedMotion]);
|
|
50
|
+
const elementInitialValue = useMemo(() => {
|
|
51
|
+
return flat ? { [flatArrayKey]: _elementInitialValue ?? null } : _elementInitialValue ?? {};
|
|
52
|
+
}, [flat, _elementInitialValue]);
|
|
53
|
+
useEffect(() => {
|
|
54
|
+
if (needsInitialize) {
|
|
55
|
+
setValue(name, [elementInitialValue], {
|
|
56
|
+
shouldDirty: false,
|
|
57
|
+
shouldTouch: false
|
|
58
|
+
});
|
|
59
|
+
hasInitialized.current = true;
|
|
60
|
+
if (!prefersReducedMotion && disableAnimation) setTimeout(() => {
|
|
61
|
+
setDisableAnimation(false);
|
|
62
|
+
}, 1);
|
|
63
|
+
}
|
|
64
|
+
}, [needsInitialize]);
|
|
65
|
+
return {
|
|
66
|
+
fields,
|
|
67
|
+
append,
|
|
68
|
+
remove,
|
|
69
|
+
insert,
|
|
70
|
+
move,
|
|
71
|
+
disableAnimation,
|
|
72
|
+
elementInitialValue,
|
|
73
|
+
...uniformField
|
|
74
|
+
};
|
|
75
|
+
};
|
|
76
|
+
//#endregion
|
|
77
|
+
//#region src/hooks/useUniformFieldArray/index.ts
|
|
78
|
+
/* v8 ignore stop */
|
|
79
|
+
//#endregion
|
|
80
|
+
export { useUniformFieldArray };
|
|
2
81
|
|
|
3
|
-
|
|
82
|
+
//# sourceMappingURL=index.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index.js","names":["useRHFFieldArray","useFormContext"],"sources":["../../../src/hooks/useUniformFieldArray/useUniformFieldArray.ts","../../../src/hooks/useUniformFieldArray/index.ts"],"sourcesContent":["import type { ReactNode } from 'react';\nimport type { ArrayPath, FieldValues, Path } from 'react-hook-form';\n\nimport { useEffect, useMemo, useRef, useState } from 'react';\nimport { useFieldArray as useRHFFieldArray } from 'react-hook-form';\n\nimport { useReducedMotion } from '@fuf-stack/pixel-motion';\n\nimport { flatArrayKey } from '../../helpers';\nimport { useFormContext } from '../useFormContext';\nimport { useUniformField } from '../useUniformField';\n\nexport interface UseUniformFieldArrayProps<\n TFieldValues extends FieldValues = FieldValues,\n> {\n /** Field name for the array */\n name: ArrayPath<TFieldValues>;\n /** Whether this is a flat array (array of primitives) */\n flat?: boolean;\n /** Initial value for new array elements */\n elementInitialValue?: unknown;\n /** Whether the last element cannot be removed (always maintain at least one element) */\n lastElementNotRemovable?: boolean;\n /** Disable the field */\n disabled?: boolean;\n /** Optional explicit test id used to build stable test ids */\n testId?: string;\n /** Optional label content */\n label?: ReactNode;\n}\n\n/**\n * Enhanced useFieldArray hook with initialization and animation logic.\n * Based on React Hook Form's useFieldArray with additional features:\n * - Automatic initialization when lastElementNotRemovable is set\n * - Animation control (disabled during initialization)\n * - Support for flat arrays (arrays of primitives)\n *\n * Note: Automatic validation triggering on length change is disabled to prevent\n * triggering form-wide validation. Array validation still runs on form submission.\n *\n * @see https://react-hook-form.com/docs/usefieldarray\n */\nexport const useUniformFieldArray = <\n TFieldValues extends FieldValues = FieldValues,\n>({\n name,\n flat = false,\n elementInitialValue: _elementInitialValue = null,\n lastElementNotRemovable = false,\n disabled,\n testId: explicitTestId,\n label,\n}: UseUniformFieldArrayProps<TFieldValues>) => {\n // Get uniform field state and utilities\n const uniformField = useUniformField<TFieldValues>({\n name: name as Path<TFieldValues> & string,\n disabled,\n testId: explicitTestId,\n label,\n });\n\n const { control } = uniformField;\n\n const { fields, append, remove, insert, move } = useRHFFieldArray({\n control,\n name,\n });\n\n const { trigger, setValue } = useFormContext<TFieldValues>();\n\n // Determine if initialization is needed (initially or after reset).\n // This flag automatically handles both scenarios:\n // - Initial mount: fields.length starts at 0\n // - Form reset: fields.length becomes 0 again\n // Additional initialization conditions can be added here later (e.g., minElements > 0)\n // Using useMemo ensures this value is properly tracked by React and effects can depend on it\n const needsInitialize = useMemo(() => {\n return lastElementNotRemovable && fields.length === 0;\n }, [lastElementNotRemovable, fields.length]);\n\n // Track whether initialization has completed. Initialized contextually:\n // - If initialization IS needed (needsInitialize = true): starts as false, set to true after init\n // - If initialization is NOT needed (needsInitialize = false): starts as true (already initialized)\n // This ref is used to:\n // 1. Skip validation during initialization/re-initialization\n // 2. Gate animation enabling until after initialization\n // 3. Gate motion preference effect until after initialization\n const hasInitialized = useRef(!needsInitialize);\n\n // Reset initialization flag when needsInitialize changes to true.\n // This handles form reset: when fields become empty (needsInitialize becomes true),\n // hasInitialized is reset to false, triggering re-initialization in the effect below.\n useEffect(() => {\n if (needsInitialize) {\n hasInitialized.current = false;\n }\n }, [needsInitialize]);\n\n // Validate array-level constraints (min/max items) when length changes.\n // This ensures min/max errors appear instantly when user adds/removes items.\n // Note: Child field validation also runs, but new empty fields won't show as invalid\n // because useFormContext only sets invalid=true for touched fields or after form submission.\n // Skip validation during initialization/re-initialization to avoid showing errors prematurely.\n useEffect(() => {\n if (hasInitialized.current) {\n setTimeout(() => {\n trigger(name as Path<TFieldValues>);\n }, 200);\n }\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [fields.length]);\n\n // Animation control: Start with animations disabled to prevent animating in initial elements.\n // Will be enabled after initialization completes (unless user prefers reduced motion).\n const [disableAnimation, setDisableAnimation] = useState(true);\n\n // Respond to user's motion preference changes (after initialization).\n // During initialization, animations stay disabled regardless of preference.\n const prefersReducedMotion = useReducedMotion();\n useEffect(() => {\n if (hasInitialized.current) {\n setDisableAnimation(!!prefersReducedMotion);\n }\n }, [prefersReducedMotion]);\n\n // Prepare initial element value based on mode\n // - flat=true: arrays of primitives → object with flatArrayKey and null value by default\n // - flat=false: arrays of objects → empty object by default\n const elementInitialValue = useMemo(() => {\n return flat\n ? { [flatArrayKey]: _elementInitialValue ?? null }\n : (_elementInitialValue ?? {});\n }, [flat, _elementInitialValue]);\n\n // Initialization/Re-initialization: Add initial element when needed.\n // This handles both initial mount and form reset scenarios by reacting to needsInitialize.\n // CRITICAL: This effect MUST be the LAST hook in this component.\n // It sets hasInitialized.current = true, which acts as a gate for other effects.\n // If this runs before other effects, hasInitialized will be true during their first run,\n // causing them to execute logic meant only for post-initialization (e.g., validation,\n // animation enabling). By placing this last, all other effects run first with\n // hasInitialized = false, allowing them to skip initialization-phase logic.\n useEffect(\n () => {\n if (needsInitialize) {\n // use setValue instead of append to avoid focusing the added element\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n setValue(name as Path<TFieldValues>, [elementInitialValue] as any, {\n shouldDirty: false,\n shouldTouch: false,\n });\n\n // Mark initialization as complete\n hasInitialized.current = true;\n\n // Enable animations after a brief delay (unless user prefers reduced motion or animations are already enabled).\n // This only runs on initial mount when animations start disabled.\n // On reset, disableAnimation is typically false, so this setTimeout won't run and animations stay enabled.\n if (!prefersReducedMotion && disableAnimation) {\n setTimeout(() => {\n setDisableAnimation(false);\n }, 1);\n }\n }\n },\n // Run when needsInitialize changes (initial mount or reset)\n // needsInitialize is memoized based on fields.length and lastElementNotRemovable\n // Other dependencies are intentionally omitted:\n // - append, setValue, trigger, setDisableAnimation are stable refs/functions\n // - elementInitialValue, name, flat, prefersReducedMotion, disableAnimation are props/stable values\n // eslint-disable-next-line react-hooks/exhaustive-deps\n [needsInitialize],\n );\n\n return {\n // Field array methods and state\n fields,\n append,\n remove,\n insert,\n move,\n disableAnimation,\n elementInitialValue,\n // Uniform field state and utilities (spread all)\n ...uniformField,\n };\n};\n","/* v8 ignore start */\n\nexport * from './useUniformFieldArray';\n\n/* v8 ignore stop */\n"],"mappings":";;;;;;;;;;;;;;;;;;;AA2CA,MAAa,wBAEX,EACA,MACA,OAAO,OACP,qBAAqB,uBAAuB,MAC5C,0BAA0B,OAC1B,UACA,QAAQ,gBACR,YAC6C;CAE7C,MAAM,eAAe,gBAA8B;EAC3C;EACN;EACA,QAAQ;EACR;EACD,CAAC;CAEF,MAAM,EAAE,YAAY;CAEpB,MAAM,EAAE,QAAQ,QAAQ,QAAQ,QAAQ,SAASA,cAAiB;EAChE;EACA;EACD,CAAC;CAEF,MAAM,EAAE,SAAS,aAAaC,kBAA8B;CAQ5D,MAAM,kBAAkB,cAAc;AACpC,SAAO,2BAA2B,OAAO,WAAW;IACnD,CAAC,yBAAyB,OAAO,OAAO,CAAC;CAS5C,MAAM,iBAAiB,OAAO,CAAC,gBAAgB;AAK/C,iBAAgB;AACd,MAAI,gBACF,gBAAe,UAAU;IAE1B,CAAC,gBAAgB,CAAC;AAOrB,iBAAgB;AACd,MAAI,eAAe,QACjB,kBAAiB;AACf,WAAQ,KAA2B;KAClC,IAAI;IAGR,CAAC,OAAO,OAAO,CAAC;CAInB,MAAM,CAAC,kBAAkB,uBAAuB,SAAS,KAAK;CAI9D,MAAM,uBAAuB,kBAAkB;AAC/C,iBAAgB;AACd,MAAI,eAAe,QACjB,qBAAoB,CAAC,CAAC,qBAAqB;IAE5C,CAAC,qBAAqB,CAAC;CAK1B,MAAM,sBAAsB,cAAc;AACxC,SAAO,OACH,GAAG,eAAe,wBAAwB,MAAM,GAC/C,wBAAwB,EAAE;IAC9B,CAAC,MAAM,qBAAqB,CAAC;AAUhC,iBACQ;AACJ,MAAI,iBAAiB;AAGnB,YAAS,MAA4B,CAAC,oBAAoB,EAAS;IACjE,aAAa;IACb,aAAa;IACd,CAAC;AAGF,kBAAe,UAAU;AAKzB,OAAI,CAAC,wBAAwB,iBAC3B,kBAAiB;AACf,wBAAoB,MAAM;MACzB,EAAE;;IAUX,CAAC,gBAAgB,CAClB;AAED,QAAO;EAEL;EACA;EACA;EACA;EACA;EACA;EACA;EAEA,GAAG;EACJ"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
1
|
+
Object.defineProperty(exports, Symbol.toStringTag, { value: "Module" });
|
|
2
|
+
const require_useWatchUserChange = require("../../useWatchUserChange-CBuIa5kU.cjs");
|
|
3
3
|
//#region src/hooks/useWatchUserChange/index.ts
|
|
4
4
|
/* v8 ignore stop */
|
|
5
|
-
|
|
6
5
|
//#endregion
|
|
7
6
|
exports.useWatchUserChange = require_useWatchUserChange.useWatchUserChange;
|
|
7
|
+
|
|
8
8
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as useWatchUserChange, t as UseWatchUserChangeOptions } from "../../useWatchUserChange-
|
|
1
|
+
import { n as useWatchUserChange, t as UseWatchUserChangeOptions } from "../../useWatchUserChange-CZu_ZZ38.cjs";
|
|
2
2
|
export { UseWatchUserChangeOptions, useWatchUserChange };
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as useWatchUserChange, t as UseWatchUserChangeOptions } from "../../useWatchUserChange-
|
|
1
|
+
import { n as useWatchUserChange, t as UseWatchUserChangeOptions } from "../../useWatchUserChange-CH4x16_r.js";
|
|
2
2
|
export { UseWatchUserChangeOptions, useWatchUserChange };
|
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import { t as useWatchUserChange } from "../../useWatchUserChange-
|
|
2
|
-
|
|
1
|
+
import { t as useWatchUserChange } from "../../useWatchUserChange-CLgLc5W4.js";
|
|
3
2
|
//#region src/hooks/useWatchUserChange/index.ts
|
|
4
3
|
/* v8 ignore stop */
|
|
5
|
-
|
|
6
4
|
//#endregion
|
|
7
5
|
export { useWatchUserChange };
|
|
6
|
+
|
|
8
7
|
//# sourceMappingURL=index.js.map
|
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
import { t as
|
|
1
|
+
import { n as ClassNameValue, t as TVReturnType } from "./index-DsC0y6kU.cjs";
|
|
2
|
+
import { t as InputValueTransform } from "./useInputValueTransform-BwAfw8Xb.cjs";
|
|
3
|
+
import * as _$react_jsx_runtime0 from "react/jsx-runtime";
|
|
2
4
|
import { TVClassName, TVProps } from "@fuf-stack/pixel-utils";
|
|
3
5
|
import { ReactNode } from "react";
|
|
4
|
-
import * as react_jsx_runtime4 from "react/jsx-runtime";
|
|
5
|
-
import * as tailwind_variants109 from "tailwind-variants";
|
|
6
6
|
|
|
7
7
|
//#region src/Input/Input.d.ts
|
|
8
|
-
declare const inputVariants:
|
|
8
|
+
declare const inputVariants: TVReturnType<{
|
|
9
9
|
[key: string]: {
|
|
10
|
-
[key: string]:
|
|
11
|
-
base?:
|
|
12
|
-
input?:
|
|
13
|
-
inputWrapper?:
|
|
14
|
-
clearButton?:
|
|
10
|
+
[key: string]: ClassNameValue | {
|
|
11
|
+
base?: ClassNameValue;
|
|
12
|
+
input?: ClassNameValue;
|
|
13
|
+
inputWrapper?: ClassNameValue;
|
|
14
|
+
clearButton?: ClassNameValue;
|
|
15
15
|
};
|
|
16
16
|
};
|
|
17
17
|
} | {
|
|
18
18
|
[x: string]: {
|
|
19
|
-
[x: string]:
|
|
20
|
-
base?:
|
|
21
|
-
input?:
|
|
22
|
-
inputWrapper?:
|
|
23
|
-
clearButton?:
|
|
19
|
+
[x: string]: ClassNameValue | {
|
|
20
|
+
base?: ClassNameValue;
|
|
21
|
+
input?: ClassNameValue;
|
|
22
|
+
inputWrapper?: ClassNameValue;
|
|
23
|
+
clearButton?: ClassNameValue;
|
|
24
24
|
};
|
|
25
25
|
};
|
|
26
26
|
} | {}, {
|
|
@@ -30,11 +30,11 @@ declare const inputVariants: tailwind_variants109.TVReturnType<{
|
|
|
30
30
|
inputWrapper: string;
|
|
31
31
|
}, undefined, {
|
|
32
32
|
[key: string]: {
|
|
33
|
-
[key: string]:
|
|
34
|
-
base?:
|
|
35
|
-
input?:
|
|
36
|
-
inputWrapper?:
|
|
37
|
-
clearButton?:
|
|
33
|
+
[key: string]: ClassNameValue | {
|
|
34
|
+
base?: ClassNameValue;
|
|
35
|
+
input?: ClassNameValue;
|
|
36
|
+
inputWrapper?: ClassNameValue;
|
|
37
|
+
clearButton?: ClassNameValue;
|
|
38
38
|
};
|
|
39
39
|
};
|
|
40
40
|
} | {}, {
|
|
@@ -42,7 +42,7 @@ declare const inputVariants: tailwind_variants109.TVReturnType<{
|
|
|
42
42
|
clearButton: string; /** actual input element */
|
|
43
43
|
input: string; /** inner wrapper (HeroUI inputWrapper slot) */
|
|
44
44
|
inputWrapper: string;
|
|
45
|
-
},
|
|
45
|
+
}, TVReturnType<unknown, {
|
|
46
46
|
/** wrapper around the whole input */base: string; /** clear button */
|
|
47
47
|
clearButton: string; /** actual input element */
|
|
48
48
|
input: string; /** inner wrapper (HeroUI inputWrapper slot) */
|
|
@@ -97,7 +97,7 @@ declare const Input: ({
|
|
|
97
97
|
startContent,
|
|
98
98
|
type,
|
|
99
99
|
...uniformFieldProps
|
|
100
|
-
}: InputProps) =>
|
|
100
|
+
}: InputProps) => _$react_jsx_runtime0.JSX.Element;
|
|
101
101
|
//#endregion
|
|
102
102
|
export { InputProps as n, Input as t };
|
|
103
|
-
//# sourceMappingURL=index-
|
|
103
|
+
//# sourceMappingURL=index-25CYKzg4.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-25CYKzg4.d.cts","names":[],"sources":["../src/Input/Input.tsx"],"mappings":";;;;;;;cAca,aAAA;;mBAWX,cAAA;;;;;;;;;;;;;;;;;;;iBAXwB;;;;;;;;;;;;;;;;;;;;;;KAarB,YAAA,GAAe,OAAA,QAAe,aAAA;AAAA,KAC9B,SAAA,GAAY,WAAA,QAAmB,aAAA;AAAA,UAEnB,UAAA,SAAmB,YAAA;;EAElC,SAAA;;EAEA,SAAA,GAAY,SAAA;;EAEZ,SAAA;;EAEA,aAAA;;EAEA,QAAA;;EAEA,UAAA,GAAa,SAAA;;EAEb,KAAA,GAAQ,SAAA;;EAER,IAAA;;EAEA,OAAA;EArBe;EAuBf,WAAA;EAvBkB;EAyBlB,IAAA;EAxBG;EA0BH,YAAA,GAAe,SAAA;;EAEf,MAAA;EA5B+C;EA8B/C,SAAA,GAAY,mBAAA;EA5Bc;EA8B1B,IAAA;AAAA;;;;cAMI,KAAA;EAAS,SAAA,EAAA,UAAA;EAAA,SAAA;EAAA,aAAA;EAAA,UAAA;EAAA,IAAA;EAAA,OAAA;EAAA,WAAA;EAAA,IAAA;EAAA,YAAA;EAAA,IAAA;EAAA,GAAA;AAAA,GAYZ,UAAA,KAAU,oBAAA,CAAA,GAAA,CAAA,OAAA"}
|
|
@@ -1,36 +1,36 @@
|
|
|
1
|
-
import
|
|
2
|
-
import * as
|
|
1
|
+
import { n as ClassNameValue, t as TVReturnType } from "./index-DsC0y6kU.cjs";
|
|
2
|
+
import * as _$react_jsx_runtime0 from "react/jsx-runtime";
|
|
3
3
|
import { TVClassName, TVProps } from "@fuf-stack/pixel-utils";
|
|
4
4
|
import { ReactNode } from "react";
|
|
5
5
|
import { SwitchProps } from "@heroui/switch";
|
|
6
6
|
|
|
7
7
|
//#region src/Switch/Switch.d.ts
|
|
8
|
-
declare const switchVariants:
|
|
8
|
+
declare const switchVariants: TVReturnType<{
|
|
9
9
|
[key: string]: {
|
|
10
|
-
[key: string]:
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
10
|
+
[key: string]: ClassNameValue | {
|
|
11
|
+
label?: ClassNameValue;
|
|
12
|
+
errorMessage?: ClassNameValue;
|
|
13
|
+
base?: ClassNameValue;
|
|
14
|
+
wrapper?: ClassNameValue;
|
|
15
|
+
thumb?: ClassNameValue;
|
|
16
|
+
thumbIcon?: ClassNameValue;
|
|
17
|
+
startContent?: ClassNameValue;
|
|
18
|
+
endContent?: ClassNameValue;
|
|
19
|
+
outerWrapper?: ClassNameValue;
|
|
20
20
|
};
|
|
21
21
|
};
|
|
22
22
|
} | {
|
|
23
23
|
[x: string]: {
|
|
24
|
-
[x: string]:
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
24
|
+
[x: string]: ClassNameValue | {
|
|
25
|
+
label?: ClassNameValue;
|
|
26
|
+
errorMessage?: ClassNameValue;
|
|
27
|
+
base?: ClassNameValue;
|
|
28
|
+
wrapper?: ClassNameValue;
|
|
29
|
+
thumb?: ClassNameValue;
|
|
30
|
+
thumbIcon?: ClassNameValue;
|
|
31
|
+
startContent?: ClassNameValue;
|
|
32
|
+
endContent?: ClassNameValue;
|
|
33
|
+
outerWrapper?: ClassNameValue;
|
|
34
34
|
};
|
|
35
35
|
};
|
|
36
36
|
} | {}, {
|
|
@@ -45,16 +45,16 @@ declare const switchVariants: tailwind_variants128.TVReturnType<{
|
|
|
45
45
|
wrapper: string;
|
|
46
46
|
}, undefined, {
|
|
47
47
|
[key: string]: {
|
|
48
|
-
[key: string]:
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
48
|
+
[key: string]: ClassNameValue | {
|
|
49
|
+
label?: ClassNameValue;
|
|
50
|
+
errorMessage?: ClassNameValue;
|
|
51
|
+
base?: ClassNameValue;
|
|
52
|
+
wrapper?: ClassNameValue;
|
|
53
|
+
thumb?: ClassNameValue;
|
|
54
|
+
thumbIcon?: ClassNameValue;
|
|
55
|
+
startContent?: ClassNameValue;
|
|
56
|
+
endContent?: ClassNameValue;
|
|
57
|
+
outerWrapper?: ClassNameValue;
|
|
58
58
|
};
|
|
59
59
|
};
|
|
60
60
|
} | {}, {
|
|
@@ -67,7 +67,7 @@ declare const switchVariants: tailwind_variants128.TVReturnType<{
|
|
|
67
67
|
thumb: string;
|
|
68
68
|
thumbIcon: string;
|
|
69
69
|
wrapper: string;
|
|
70
|
-
},
|
|
70
|
+
}, TVReturnType<unknown, {
|
|
71
71
|
base: string;
|
|
72
72
|
endContent: string;
|
|
73
73
|
errorMessage: string;
|
|
@@ -112,7 +112,7 @@ declare const Switch: ({
|
|
|
112
112
|
startContent,
|
|
113
113
|
thumbIcon,
|
|
114
114
|
...uniformFieldProps
|
|
115
|
-
}: SwitchProps$1) =>
|
|
115
|
+
}: SwitchProps$1) => _$react_jsx_runtime0.JSX.Element;
|
|
116
116
|
//#endregion
|
|
117
117
|
export { SwitchProps$1 as n, Switch as t };
|
|
118
|
-
//# sourceMappingURL=index-
|
|
118
|
+
//# sourceMappingURL=index-3e3711-8.d.cts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-3e3711-8.d.cts","names":[],"sources":["../src/Switch/Switch.tsx"],"mappings":";;;;;;;cAaa,cAAA;;mBAeX,cAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAEG,YAAA,GAAe,OAAA,QAAe,cAAA;AAAA,KAC9B,SAAA,GAAY,WAAA,QAAmB,cAAA;AAAA,UAEnB,aAAA,SAAoB,YAAA;;EAEnC,SAAA;;EAEA,SAAA,GAAY,SAAA;;EAEZ,QAAA;;EAEA,UAAA,GAAa,SAAA;;EAEb,KAAA,GAAQ,SAAA;;EAER,IAAA;EAEA,IAAA;;EAEA,YAAA,GAAe,SAAA;;EAEf,MAAA;;EAEA,SAAA,GAAY,WAAA;AAAA;;;;cAMR,MAAA;EAAU,SAAA;EAAA,UAAA;EAAA,IAAA;EAAA,IAAA;EAAA,YAAA;EAAA,SAAA;EAAA,GAAA;AAAA,GAQb,aAAA,KAAW,oBAAA,CAAA,GAAA,CAAA,OAAA"}
|
|
@@ -1,34 +1,34 @@
|
|
|
1
|
+
import { n as ClassNameValue, t as TVReturnType } from "./index-DwqOejxR.js";
|
|
1
2
|
import { TVClassName, TVProps } from "@fuf-stack/pixel-utils";
|
|
2
3
|
import { ReactElement, ReactNode } from "react";
|
|
3
|
-
import * as tailwind_variants0 from "tailwind-variants";
|
|
4
4
|
|
|
5
5
|
//#region src/Radios/Radios.d.ts
|
|
6
|
-
declare const radiosVariants:
|
|
6
|
+
declare const radiosVariants: TVReturnType<{
|
|
7
7
|
[key: string]: {
|
|
8
|
-
[key: string]:
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
8
|
+
[key: string]: ClassNameValue | {
|
|
9
|
+
label?: ClassNameValue;
|
|
10
|
+
base?: ClassNameValue;
|
|
11
|
+
wrapper?: ClassNameValue;
|
|
12
|
+
itemBase?: ClassNameValue;
|
|
13
|
+
itemControl?: ClassNameValue;
|
|
14
|
+
itemDescription?: ClassNameValue;
|
|
15
|
+
itemLabel?: ClassNameValue;
|
|
16
|
+
itemLabelWrapper?: ClassNameValue;
|
|
17
|
+
itemWrapper?: ClassNameValue;
|
|
18
18
|
};
|
|
19
19
|
};
|
|
20
20
|
} | {
|
|
21
21
|
[x: string]: {
|
|
22
|
-
[x: string]:
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
22
|
+
[x: string]: ClassNameValue | {
|
|
23
|
+
label?: ClassNameValue;
|
|
24
|
+
base?: ClassNameValue;
|
|
25
|
+
wrapper?: ClassNameValue;
|
|
26
|
+
itemBase?: ClassNameValue;
|
|
27
|
+
itemControl?: ClassNameValue;
|
|
28
|
+
itemDescription?: ClassNameValue;
|
|
29
|
+
itemLabel?: ClassNameValue;
|
|
30
|
+
itemLabelWrapper?: ClassNameValue;
|
|
31
|
+
itemWrapper?: ClassNameValue;
|
|
32
32
|
};
|
|
33
33
|
};
|
|
34
34
|
} | {}, {
|
|
@@ -43,16 +43,16 @@ declare const radiosVariants: tailwind_variants0.TVReturnType<{
|
|
|
43
43
|
wrapper: string;
|
|
44
44
|
}, undefined, {
|
|
45
45
|
[key: string]: {
|
|
46
|
-
[key: string]:
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
46
|
+
[key: string]: ClassNameValue | {
|
|
47
|
+
label?: ClassNameValue;
|
|
48
|
+
base?: ClassNameValue;
|
|
49
|
+
wrapper?: ClassNameValue;
|
|
50
|
+
itemBase?: ClassNameValue;
|
|
51
|
+
itemControl?: ClassNameValue;
|
|
52
|
+
itemDescription?: ClassNameValue;
|
|
53
|
+
itemLabel?: ClassNameValue;
|
|
54
|
+
itemLabelWrapper?: ClassNameValue;
|
|
55
|
+
itemWrapper?: ClassNameValue;
|
|
56
56
|
};
|
|
57
57
|
};
|
|
58
58
|
} | {}, {
|
|
@@ -65,7 +65,7 @@ declare const radiosVariants: tailwind_variants0.TVReturnType<{
|
|
|
65
65
|
itemWrapper: string;
|
|
66
66
|
label: string;
|
|
67
67
|
wrapper: string;
|
|
68
|
-
},
|
|
68
|
+
}, TVReturnType<unknown, {
|
|
69
69
|
base: string;
|
|
70
70
|
itemBase: string;
|
|
71
71
|
itemControl: string;
|
|
@@ -120,4 +120,4 @@ declare const Radios: ({
|
|
|
120
120
|
}: RadiosProps) => ReactElement;
|
|
121
121
|
//#endregion
|
|
122
122
|
export { RadiosProps as n, Radios as t };
|
|
123
|
-
//# sourceMappingURL=index-
|
|
123
|
+
//# sourceMappingURL=index-6hu79Fof.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"index-6hu79Fof.d.ts","names":[],"sources":["../src/Radios/Radios.tsx"],"mappings":";;;;;cAaa,cAAA;;mBAgBX,cAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;KAEG,YAAA,GAAe,OAAA,QAAe,cAAA;AAAA,KAC9B,SAAA,GAAY,WAAA,QAAmB,cAAA;AAAA,UAEnB,WAAA;;EAEf,QAAA;;EAEA,KAAA,GAAQ,SAAA;;EAER,IAAA,GAAO,SAAA;;EAEP,MAAA;;EAEA,KAAA;AAAA;AAAA,UAGe,WAAA,SAAoB,YAAA;;EAEnC,SAAA;;EAEA,SAAA,GAAY,SAAA;;EAEZ,QAAA;;EAEA,MAAA;;EAEA,KAAA,GAAQ,SAAA;;EAER,IAAA;;EAEA,OAAA,EAAS,WAAA;;EAET,MAAA;AAAA;;;;cAMI,MAAA;EAAU,SAAA;EAAA,MAAA;EAAA,IAAA;EAAA,OAAA;EAAA,GAAA;AAAA,GAMb,WAAA,KAAc,YAAA"}
|