@televet/kibble-ui 5.0.0-beta.hotfix.2 → 5.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/chunks/{alert.types-BKSqs9qY.js → alert.types-CoNGMaZH.js} +2 -2
- package/dist/chunks/{alert.types-BKSqs9qY.js.map → alert.types-CoNGMaZH.js.map} +1 -1
- package/dist/chunks/{alert.types-C_ygg7fh.js → alert.types-DDd-kKhQ.js} +3 -3
- package/dist/chunks/{alert.types-C_ygg7fh.js.map → alert.types-DDd-kKhQ.js.map} +1 -1
- package/dist/chunks/{avatar.component-C-365mx3.js → avatar.component-DOxOCba4.js} +2 -2
- package/dist/chunks/{avatar.component-C-365mx3.js.map → avatar.component-DOxOCba4.js.map} +1 -1
- package/dist/chunks/{avatar.component-B1HGlwVW.js → avatar.component-jnCAquFm.js} +2 -2
- package/dist/chunks/{avatar.component-B1HGlwVW.js.map → avatar.component-jnCAquFm.js.map} +1 -1
- package/dist/chunks/{avatarGroup.component-B-ZOhj7i.js → avatarGroup.component-BrEOOfUM.js} +5 -5
- package/dist/chunks/{avatarGroup.component-B-ZOhj7i.js.map → avatarGroup.component-BrEOOfUM.js.map} +1 -1
- package/dist/chunks/{avatarGroup.component-CTBfGiSm.js → avatarGroup.component-CDfF7iXF.js} +2 -2
- package/dist/chunks/{avatarGroup.component-CTBfGiSm.js.map → avatarGroup.component-CDfF7iXF.js.map} +1 -1
- package/dist/chunks/{buttonGroup.component-CowJsbr7.js → buttonGroup.component-QIrJOCDP.js} +2 -2
- package/dist/chunks/{buttonGroup.component-CowJsbr7.js.map → buttonGroup.component-QIrJOCDP.js.map} +1 -1
- package/dist/chunks/{buttonGroup.component-DUK2FgFn.js → buttonGroup.component-XM_2S4uj.js} +2 -2
- package/dist/chunks/{buttonGroup.component-DUK2FgFn.js.map → buttonGroup.component-XM_2S4uj.js.map} +1 -1
- package/dist/chunks/{calendar.component-tOoK1NrU.js → calendar.component-CRXFd2qS.js} +2 -2
- package/dist/chunks/{calendar.component-tOoK1NrU.js.map → calendar.component-CRXFd2qS.js.map} +1 -1
- package/dist/chunks/{calendar.component-CHIhplfO.js → calendar.component-CobSAMg0.js} +2 -2
- package/dist/chunks/{calendar.component-CHIhplfO.js.map → calendar.component-CobSAMg0.js.map} +1 -1
- package/dist/chunks/{characterCounter.component-CKDigkoD.js → characterCounter.component-Bx1KJdtW.js} +2 -2
- package/dist/chunks/{characterCounter.component-CKDigkoD.js.map → characterCounter.component-Bx1KJdtW.js.map} +1 -1
- package/dist/chunks/{characterCounter.component-Ch3P3GqC.js → characterCounter.component-zxpwPozD.js} +2 -2
- package/dist/chunks/{characterCounter.component-Ch3P3GqC.js.map → characterCounter.component-zxpwPozD.js.map} +1 -1
- package/dist/chunks/{checkbox.component-CiA3Z1zR.js → checkbox.component-BxH9UuK7.js} +2 -2
- package/dist/chunks/{checkbox.component-CiA3Z1zR.js.map → checkbox.component-BxH9UuK7.js.map} +1 -1
- package/dist/chunks/{checkbox.component-DE35wBj-.js → checkbox.component-Dcxu48_o.js} +3 -3
- package/dist/chunks/{checkbox.component-DE35wBj-.js.map → checkbox.component-Dcxu48_o.js.map} +1 -1
- package/dist/chunks/{checkboxGroup.component-CYwGlktu.js → checkboxGroup.component-D79xlf3v.js} +3 -3
- package/dist/chunks/{checkboxGroup.component-CYwGlktu.js.map → checkboxGroup.component-D79xlf3v.js.map} +1 -1
- package/dist/chunks/{checkboxGroup.component-BGBd-roJ.js → checkboxGroup.component-xqwBFmT_.js} +2 -2
- package/dist/chunks/{checkboxGroup.component-BGBd-roJ.js.map → checkboxGroup.component-xqwBFmT_.js.map} +1 -1
- package/dist/chunks/{conversationCard.component-CMdqD3yN.js → conversationCard.component-BsQEPjIv.js} +8 -8
- package/dist/chunks/{conversationCard.component-CMdqD3yN.js.map → conversationCard.component-BsQEPjIv.js.map} +1 -1
- package/dist/chunks/{conversationCard.component-BrDGshOG.js → conversationCard.component-DuPS_G4j.js} +2 -2
- package/dist/chunks/{conversationCard.component-BrDGshOG.js.map → conversationCard.component-DuPS_G4j.js.map} +1 -1
- package/dist/chunks/{datePicker.component-eHU7IZgC.js → datePicker.component-4D-aw-f3.js} +4 -4
- package/dist/chunks/{datePicker.component-eHU7IZgC.js.map → datePicker.component-4D-aw-f3.js.map} +1 -1
- package/dist/chunks/{datePicker.component-C6cD1_HR.js → datePicker.component-txR_j1pV.js} +2 -2
- package/dist/chunks/{datePicker.component-C6cD1_HR.js.map → datePicker.component-txR_j1pV.js.map} +1 -1
- package/dist/chunks/{datePicker.provider-BWHE-9FA.js → datePicker.provider-Bz5WNf8N.js} +3 -3
- package/dist/chunks/{datePicker.provider-BWHE-9FA.js.map → datePicker.provider-Bz5WNf8N.js.map} +1 -1
- package/dist/chunks/{datePicker.provider-DgarjPPd.js → datePicker.provider-WuyAKvhT.js} +2 -2
- package/dist/chunks/{datePicker.provider-DgarjPPd.js.map → datePicker.provider-WuyAKvhT.js.map} +1 -1
- package/dist/chunks/{dateTimePicker.component-Byjxg2lJ.js → dateTimePicker.component-BbMDPLeE.js} +5 -5
- package/dist/chunks/{dateTimePicker.component-Byjxg2lJ.js.map → dateTimePicker.component-BbMDPLeE.js.map} +1 -1
- package/dist/chunks/{dateTimePicker.component-REz9iX4S.js → dateTimePicker.component-XY7Hjy5a.js} +2 -2
- package/dist/chunks/{dateTimePicker.component-REz9iX4S.js.map → dateTimePicker.component-XY7Hjy5a.js.map} +1 -1
- package/dist/chunks/{heading.component-DMAQO_-m.js → heading.component-CuqmU4-A.js} +2 -2
- package/dist/chunks/{heading.component-DMAQO_-m.js.map → heading.component-CuqmU4-A.js.map} +1 -1
- package/dist/chunks/{heading.component-7ikcgDco.js → heading.component-fjhJv_Wg.js} +2 -2
- package/dist/chunks/{heading.component-7ikcgDco.js.map → heading.component-fjhJv_Wg.js.map} +1 -1
- package/dist/chunks/{menu.component-D4-4xRDj.js → menu.component-Ca7XKva4.js} +2 -2
- package/dist/chunks/{menu.component-D4-4xRDj.js.map → menu.component-Ca7XKva4.js.map} +1 -1
- package/dist/chunks/{menu.component-DwTen8Uv.js → menu.component-DotfjNiu.js} +6 -6
- package/dist/chunks/{menu.component-DwTen8Uv.js.map → menu.component-DotfjNiu.js.map} +1 -1
- package/dist/chunks/{modal.types-B0rK6xJy.js → modal.types-C8bk4syw.js} +2 -2
- package/dist/chunks/{modal.types-B0rK6xJy.js.map → modal.types-C8bk4syw.js.map} +1 -1
- package/dist/chunks/{modal.types-74os4Bqi.js → modal.types-CC5_2AVY.js} +2 -2
- package/dist/chunks/{modal.types-74os4Bqi.js.map → modal.types-CC5_2AVY.js.map} +1 -1
- package/dist/chunks/{notificationCounter.component-BexkISUl.js → notificationCounter.component-Bote1ygg.js} +2 -2
- package/dist/chunks/{notificationCounter.component-BexkISUl.js.map → notificationCounter.component-Bote1ygg.js.map} +1 -1
- package/dist/chunks/{notificationCounter.component-DJpUXeXm.js → notificationCounter.component-iPVVGxGV.js} +2 -2
- package/dist/chunks/{notificationCounter.component-DJpUXeXm.js.map → notificationCounter.component-iPVVGxGV.js.map} +1 -1
- package/dist/chunks/{numberInput.component-RCwUUzmH.js → numberInput.component-7wxjZn8E.js} +2 -2
- package/dist/chunks/{numberInput.component-RCwUUzmH.js.map → numberInput.component-7wxjZn8E.js.map} +1 -1
- package/dist/chunks/{numberInput.component-DIABzNV6.js → numberInput.component-DO9D-2yL.js} +2 -2
- package/dist/chunks/{numberInput.component-DIABzNV6.js.map → numberInput.component-DO9D-2yL.js.map} +1 -1
- package/dist/chunks/{pinInput.types-BCzsoF9r.js → pinInput.types-Cg82OPA7.js} +2 -2
- package/dist/chunks/{pinInput.types-BCzsoF9r.js.map → pinInput.types-Cg82OPA7.js.map} +1 -1
- package/dist/chunks/{pinInput.types-CcaAN6P2.js → pinInput.types-DxBsjh8_.js} +2 -2
- package/dist/chunks/{pinInput.types-CcaAN6P2.js.map → pinInput.types-DxBsjh8_.js.map} +1 -1
- package/dist/chunks/{popover.component-DEOUdSu3.js → popover.component-2CfyrrLP.js} +4 -4
- package/dist/chunks/{popover.component-DEOUdSu3.js.map → popover.component-2CfyrrLP.js.map} +1 -1
- package/dist/chunks/{popover.component-BBp_5m8e.js → popover.component-BsAhqfsU.js} +2 -2
- package/dist/chunks/{popover.component-BBp_5m8e.js.map → popover.component-BsAhqfsU.js.map} +1 -1
- package/dist/chunks/{radioGroup.types-DJ68ERdO.js → radioGroup.types-D9XBscp2.js} +4 -4
- package/dist/chunks/{radioGroup.types-DJ68ERdO.js.map → radioGroup.types-D9XBscp2.js.map} +1 -1
- package/dist/chunks/{radioGroup.types-C7A8mLMz.js → radioGroup.types-F8vVdEOh.js} +2 -2
- package/dist/chunks/{radioGroup.types-C7A8mLMz.js.map → radioGroup.types-F8vVdEOh.js.map} +1 -1
- package/dist/chunks/{rating.component-BsuGbcxP.js → rating.component-CQD7qSs1.js} +2 -2
- package/dist/chunks/{rating.component-BsuGbcxP.js.map → rating.component-CQD7qSs1.js.map} +1 -1
- package/dist/chunks/{rating.component-ChzcvUl6.js → rating.component-H2698UHE.js} +2 -2
- package/dist/chunks/{rating.component-ChzcvUl6.js.map → rating.component-H2698UHE.js.map} +1 -1
- package/dist/chunks/{ratingDots.component-D9WQGVcj.js → ratingDots.component-DRlCDGSd.js} +3 -3
- package/dist/chunks/{ratingDots.component-D9WQGVcj.js.map → ratingDots.component-DRlCDGSd.js.map} +1 -1
- package/dist/chunks/{ratingDots.component-CVjSZ9JJ.js → ratingDots.component-Da9isjMP.js} +2 -2
- package/dist/chunks/{ratingDots.component-CVjSZ9JJ.js.map → ratingDots.component-Da9isjMP.js.map} +1 -1
- package/dist/chunks/{select.component-B4mAPqzN.js → select.component-CJiMFmhO.js} +5 -5
- package/dist/chunks/{select.component-B4mAPqzN.js.map → select.component-CJiMFmhO.js.map} +1 -1
- package/dist/chunks/{select.component-CCNxMGvb.js → select.component-HZ3Lf1R2.js} +2 -2
- package/dist/chunks/{select.component-CCNxMGvb.js.map → select.component-HZ3Lf1R2.js.map} +1 -1
- package/dist/chunks/{sortableList.component-BlwtnxVj.js → sortableList.component-BuPCQuzG.js} +2 -2
- package/dist/chunks/{sortableList.component-BlwtnxVj.js.map → sortableList.component-BuPCQuzG.js.map} +1 -1
- package/dist/chunks/{sortableList.component-XfURY7C2.js → sortableList.component-Cng3DSoo.js} +2 -2
- package/dist/chunks/{sortableList.component-XfURY7C2.js.map → sortableList.component-Cng3DSoo.js.map} +1 -1
- package/dist/chunks/{spinner.component-DuW1_IWM.js → spinner.component-BJbnJpC2.js} +2 -2
- package/dist/chunks/{spinner.component-DuW1_IWM.js.map → spinner.component-BJbnJpC2.js.map} +1 -1
- package/dist/chunks/{spinner.component-B3dkvoO9.js → spinner.component-D2Zatj34.js} +2 -2
- package/dist/chunks/{spinner.component-B3dkvoO9.js.map → spinner.component-D2Zatj34.js.map} +1 -1
- package/dist/chunks/{styledAvatar.types-cR6PNPxA.js → styledAvatar.types-6U3cCgR9.js} +2 -2
- package/dist/chunks/{styledAvatar.types-cR6PNPxA.js.map → styledAvatar.types-6U3cCgR9.js.map} +1 -1
- package/dist/chunks/{styledAvatar.types-CcP-Vl9c.js → styledAvatar.types-Djix6HLp.js} +2 -2
- package/dist/chunks/{styledAvatar.types-CcP-Vl9c.js.map → styledAvatar.types-Djix6HLp.js.map} +1 -1
- package/dist/chunks/{switch.component-CpV7mnhR.js → switch.component-BI7FO9E2.js} +2 -2
- package/dist/chunks/{switch.component-CpV7mnhR.js.map → switch.component-BI7FO9E2.js.map} +1 -1
- package/dist/chunks/{switch.component-CgzCLoTB.js → switch.component-CjivfNlp.js} +2 -2
- package/dist/chunks/{switch.component-CgzCLoTB.js.map → switch.component-CjivfNlp.js.map} +1 -1
- package/dist/chunks/{tab.types-DwPEP_5N.js → tab.types-DIfnro0P.js} +2 -2
- package/dist/chunks/{tab.types-DwPEP_5N.js.map → tab.types-DIfnro0P.js.map} +1 -1
- package/dist/chunks/{tab.types-DaJfFBvr.js → tab.types-ilWt-Qk8.js} +3 -3
- package/dist/chunks/{tab.types-DaJfFBvr.js.map → tab.types-ilWt-Qk8.js.map} +1 -1
- package/dist/chunks/{tagBlock.component-Cor6eakc.js → tagBlock.component-B-erWvSO.js} +5 -5
- package/dist/chunks/{tagBlock.component-Cor6eakc.js.map → tagBlock.component-B-erWvSO.js.map} +1 -1
- package/dist/chunks/{tagBlock.component-BGEvRu81.js → tagBlock.component-C-U6kLYO.js} +2 -2
- package/dist/chunks/{tagBlock.component-BGEvRu81.js.map → tagBlock.component-C-U6kLYO.js.map} +1 -1
- package/dist/chunks/{text.component-CeioUl0G.js → text.component-BQUkayTO.js} +2 -2
- package/dist/chunks/{text.component-CeioUl0G.js.map → text.component-BQUkayTO.js.map} +1 -1
- package/dist/chunks/{text.component-CdTyTFds.js → text.component-RbaGyNOr.js} +2 -2
- package/dist/chunks/{text.component-CdTyTFds.js.map → text.component-RbaGyNOr.js.map} +1 -1
- package/dist/chunks/{textInput.component-BC0Hi8R_.js → textInput.component-DL4vmgM1.js} +3 -3
- package/dist/chunks/{textInput.component-BC0Hi8R_.js.map → textInput.component-DL4vmgM1.js.map} +1 -1
- package/dist/chunks/{textInput.component-C1vwy6pL.js → textInput.component-mhII49iH.js} +2 -2
- package/dist/chunks/{textInput.component-C1vwy6pL.js.map → textInput.component-mhII49iH.js.map} +1 -1
- package/dist/chunks/{textarea.component-axjxiv82.js → textarea.component-B_GHJxSZ.js} +3 -3
- package/dist/chunks/{textarea.component-axjxiv82.js.map → textarea.component-B_GHJxSZ.js.map} +1 -1
- package/dist/chunks/{textarea.component-D15hA9Jb.js → textarea.component-DUOK7ium.js} +2 -2
- package/dist/chunks/{textarea.component-D15hA9Jb.js.map → textarea.component-DUOK7ium.js.map} +1 -1
- package/dist/chunks/{theme.provider-WBFdkLH-.js → theme.provider-BzcXUJEg.js} +2 -2
- package/dist/chunks/{theme.provider-WBFdkLH-.js.map → theme.provider-BzcXUJEg.js.map} +1 -1
- package/dist/chunks/{theme.provider-_wLouSRV.js → theme.provider-nGiB4lsb.js} +3 -6
- package/dist/chunks/{theme.provider-_wLouSRV.js.map → theme.provider-nGiB4lsb.js.map} +1 -1
- package/dist/chunks/{timePicker.component-u34pHrzr.js → timePicker.component-81Y42yiZ.js} +3 -3
- package/dist/chunks/{timePicker.component-u34pHrzr.js.map → timePicker.component-81Y42yiZ.js.map} +1 -1
- package/dist/chunks/{timePicker.component-Cz2XxVL6.js → timePicker.component-bQpqeqmS.js} +2 -2
- package/dist/chunks/{timePicker.component-Cz2XxVL6.js.map → timePicker.component-bQpqeqmS.js.map} +1 -1
- package/dist/chunks/{timeRange.component-BiA1VWQ8.js → timeRange.component-CFjI106c.js} +2 -2
- package/dist/chunks/{timeRange.component-BiA1VWQ8.js.map → timeRange.component-CFjI106c.js.map} +1 -1
- package/dist/chunks/{timeRange.component-tU_nCTmS.js → timeRange.component-D8EoIwTO.js} +2 -2
- package/dist/chunks/{timeRange.component-tU_nCTmS.js.map → timeRange.component-D8EoIwTO.js.map} +1 -1
- package/dist/chunks/{timestamp.component-DBmc7D23.js → timestamp.component-BhAAqd43.js} +3 -3
- package/dist/chunks/{timestamp.component-DBmc7D23.js.map → timestamp.component-BhAAqd43.js.map} +1 -1
- package/dist/chunks/{timestamp.component-DYZHgaas.js → timestamp.component-CBVv_SHJ.js} +2 -2
- package/dist/chunks/{timestamp.component-DYZHgaas.js.map → timestamp.component-CBVv_SHJ.js.map} +1 -1
- package/dist/chunks/{tooltip.component-C_NS-AoH.js → tooltip.component-B2kgm41E.js} +72 -69
- package/dist/chunks/tooltip.component-B2kgm41E.js.map +1 -0
- package/dist/chunks/tooltip.component-CIWQSrgZ.js +2 -0
- package/dist/chunks/tooltip.component-CIWQSrgZ.js.map +1 -0
- package/dist/chunks/{withFormControl-wZA87Sd4.js → withFormControl-BwtO61gv.js} +2 -2
- package/dist/chunks/{withFormControl-wZA87Sd4.js.map → withFormControl-BwtO61gv.js.map} +1 -1
- package/dist/chunks/{withFormControl-DePFf9SY.js → withFormControl-Df9GvsWo.js} +2 -2
- package/dist/chunks/{withFormControl-DePFf9SY.js.map → withFormControl-Df9GvsWo.js.map} +1 -1
- package/dist/chunks/{withTruncation-DE3FFPE7.js → withTruncation-5g3W1Yem.js} +2 -2
- package/dist/chunks/{withTruncation-DE3FFPE7.js.map → withTruncation-5g3W1Yem.js.map} +1 -1
- package/dist/chunks/{withTruncation-DTCfQ2yk.js → withTruncation-B-Li8sxr.js} +2 -2
- package/dist/chunks/{withTruncation-DTCfQ2yk.js.map → withTruncation-B-Li8sxr.js.map} +1 -1
- package/dist/cjs/components/Alert/index.cjs +1 -1
- package/dist/cjs/components/Avatar/index.cjs +1 -1
- package/dist/cjs/components/AvatarGroup/index.cjs +1 -1
- package/dist/cjs/components/ButtonGroup/index.cjs +1 -1
- package/dist/cjs/components/Calendar/index.cjs +1 -1
- package/dist/cjs/components/CharacterCounter/index.cjs +1 -1
- package/dist/cjs/components/Checkbox/index.cjs +1 -1
- package/dist/cjs/components/CheckboxGroup/index.cjs +1 -1
- package/dist/cjs/components/ConversationCard/index.cjs +1 -1
- package/dist/cjs/components/DatePicker/index.cjs +1 -1
- package/dist/cjs/components/DateTimePicker/index.cjs +1 -1
- package/dist/cjs/components/Heading/index.cjs +1 -1
- package/dist/cjs/components/Menu/index.cjs +1 -1
- package/dist/cjs/components/Modal/index.cjs +1 -1
- package/dist/cjs/components/NotificationCounter/index.cjs +1 -1
- package/dist/cjs/components/NumberInput/index.cjs +1 -1
- package/dist/cjs/components/PinInput/index.cjs +1 -1
- package/dist/cjs/components/Popover/index.cjs +1 -1
- package/dist/cjs/components/RadioGroup/index.cjs +1 -1
- package/dist/cjs/components/Rating/index.cjs +1 -1
- package/dist/cjs/components/RatingDots/index.cjs +1 -1
- package/dist/cjs/components/Select/index.cjs +1 -1
- package/dist/cjs/components/SortableList/index.cjs +1 -1
- package/dist/cjs/components/Spinner/index.cjs +1 -1
- package/dist/cjs/components/StyledAvatar/index.cjs +1 -1
- package/dist/cjs/components/Switch/index.cjs +1 -1
- package/dist/cjs/components/Tabs/index.cjs +1 -1
- package/dist/cjs/components/TagBlock/index.cjs +1 -1
- package/dist/cjs/components/Text/index.cjs +1 -1
- package/dist/cjs/components/TextInput/index.cjs +1 -1
- package/dist/cjs/components/Textarea/index.cjs +1 -1
- package/dist/cjs/components/TimePicker/index.cjs +1 -1
- package/dist/cjs/components/TimeRange/index.cjs +1 -1
- package/dist/cjs/components/Timestamp/index.cjs +1 -1
- package/dist/cjs/components/Tooltip/index.cjs +1 -1
- package/dist/cjs/components/index.cjs +1 -1
- package/dist/cjs/index.cjs +1 -1
- package/dist/cjs/theme/index.cjs +1 -1
- package/dist/esm/components/Alert/index.js +1 -1
- package/dist/esm/components/Avatar/index.js +1 -1
- package/dist/esm/components/AvatarGroup/index.js +1 -1
- package/dist/esm/components/ButtonGroup/index.js +1 -1
- package/dist/esm/components/Calendar/index.js +1 -1
- package/dist/esm/components/CharacterCounter/index.js +1 -1
- package/dist/esm/components/Checkbox/index.js +1 -1
- package/dist/esm/components/CheckboxGroup/index.js +1 -1
- package/dist/esm/components/ConversationCard/index.js +1 -1
- package/dist/esm/components/DatePicker/index.js +2 -2
- package/dist/esm/components/DateTimePicker/index.js +1 -1
- package/dist/esm/components/Heading/index.js +1 -1
- package/dist/esm/components/Menu/index.js +1 -1
- package/dist/esm/components/Modal/index.js +1 -1
- package/dist/esm/components/NotificationCounter/index.js +1 -1
- package/dist/esm/components/NumberInput/index.js +1 -1
- package/dist/esm/components/PinInput/index.js +1 -1
- package/dist/esm/components/Popover/index.js +1 -1
- package/dist/esm/components/RadioGroup/index.js +1 -1
- package/dist/esm/components/Rating/index.js +1 -1
- package/dist/esm/components/RatingDots/index.js +1 -1
- package/dist/esm/components/Select/index.js +1 -1
- package/dist/esm/components/SortableList/index.js +1 -1
- package/dist/esm/components/Spinner/index.js +1 -1
- package/dist/esm/components/StyledAvatar/index.js +1 -1
- package/dist/esm/components/Switch/index.js +1 -1
- package/dist/esm/components/Tabs/index.js +1 -1
- package/dist/esm/components/TagBlock/index.js +1 -1
- package/dist/esm/components/Text/index.js +1 -1
- package/dist/esm/components/TextInput/index.js +1 -1
- package/dist/esm/components/Textarea/index.js +1 -1
- package/dist/esm/components/TimePicker/index.js +1 -1
- package/dist/esm/components/TimeRange/index.js +1 -1
- package/dist/esm/components/Timestamp/index.js +1 -1
- package/dist/esm/components/Tooltip/index.js +1 -1
- package/dist/esm/components/index.js +36 -36
- package/dist/esm/index.js +37 -37
- package/dist/esm/theme/index.js +1 -1
- package/dist/types/components/Alert/alert.recipe.d.ts +2 -2
- package/dist/types/components/Modal/modal.recipe.d.ts +1 -1
- package/dist/types/components/NumberInput/numberInput.recipe.d.ts +1 -1
- package/dist/types/components/PinInput/pinInput.recipe.d.ts +1 -1
- package/dist/types/components/Popover/popover.recipe.d.ts +2 -2
- package/dist/types/components/Toast/toast.recipe.d.ts +2 -2
- package/dist/types/components/Tooltip/components/tooltipTrigger.component.d.ts +4 -0
- package/package.json +1 -1
- package/dist/chunks/tooltip.component-BkFDi5yK.js +0 -2
- package/dist/chunks/tooltip.component-BkFDi5yK.js.map +0 -1
- package/dist/chunks/tooltip.component-C_NS-AoH.js.map +0 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"withFormControl-wZA87Sd4.js","sources":["../../node_modules/@ark-ui/react/dist/components/field/field-error-text.js","../../node_modules/@ark-ui/react/dist/components/field/field-helper-text.js","../../node_modules/@ark-ui/react/dist/components/field/field-label.js","../../node_modules/@ark-ui/react/dist/utils/use-safe-layout-effect.js","../../node_modules/@ark-ui/react/dist/components/fieldset/use-fieldset-context.js","../../node_modules/@ark-ui/react/dist/components/field/use-field.js","../../node_modules/@ark-ui/react/dist/components/field/field-root.js","../../node_modules/@chakra-ui/react/dist/esm/components/icon/icon.js","../../node_modules/@chakra-ui/react/dist/esm/components/icon/create-icon.js","../../node_modules/@chakra-ui/react/dist/esm/components/field/field.js","../../src/hocs/withFormControl/withFormControl.records.ts","../../src/hocs/withFormControl/withFormControl.tsx"],"sourcesContent":["'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from './use-field-context.js';\n\nconst FieldErrorText = forwardRef((props, ref) => {\n const field = useFieldContext();\n const mergedProps = mergeProps(field.getErrorTextProps(), props);\n if (field?.invalid) {\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n }\n return null;\n});\nFieldErrorText.displayName = \"FieldErrorText\";\n\nexport { FieldErrorText };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from './use-field-context.js';\n\nconst FieldHelperText = forwardRef((props, ref) => {\n const field = useFieldContext();\n const mergedProps = mergeProps(field?.getHelperTextProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nFieldHelperText.displayName = \"FieldHelperText\";\n\nexport { FieldHelperText };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from './use-field-context.js';\n\nconst FieldLabel = forwardRef((props, ref) => {\n const field = useFieldContext();\n const mergedProps = mergeProps(field?.getLabelProps(), props);\n return /* @__PURE__ */ jsx(ark.label, { ...mergedProps, ref });\n});\nFieldLabel.displayName = \"FieldLabel\";\n\nexport { FieldLabel };\n","'use client';\nimport { useLayoutEffect, useEffect } from 'react';\n\nconst useSafeLayoutEffect = typeof window !== \"undefined\" ? useLayoutEffect : useEffect;\n\nexport { useSafeLayoutEffect };\n","'use client';\nimport { createContext } from '../../utils/create-context.js';\n\nconst [FieldsetProvider, useFieldsetContext] = createContext({\n name: \"FieldsetContext\",\n hookName: \"useFieldsetContext\",\n providerName: \"<FieldsetProvider />\",\n strict: false\n});\n\nexport { FieldsetProvider, useFieldsetContext };\n","'use client';\nimport { dataAttr, ariaAttr } from '@zag-js/dom-query';\nimport { useState, useId, useRef, useMemo } from 'react';\nimport { useEnvironmentContext } from '../../providers/environment/use-environment-context.js';\nimport { useSafeLayoutEffect } from '../../utils/use-safe-layout-effect.js';\nimport { useFieldsetContext } from '../fieldset/use-fieldset-context.js';\nimport { parts } from './field.anatomy.js';\n\nconst useField = (props = {}) => {\n const fieldset = useFieldsetContext();\n const env = useEnvironmentContext();\n const { ids, disabled = Boolean(fieldset?.disabled), invalid = false, readOnly = false, required = false } = props;\n const [hasErrorText, setHasErrorText] = useState(false);\n const [hasHelperText, setHasHelperText] = useState(false);\n const uid = useId();\n const id = props.id ?? uid;\n const rootRef = useRef(null);\n const rootId = ids?.control ?? `field::${id}`;\n const errorTextId = ids?.errorText ?? `field::${id}::error-text`;\n const helperTextId = ids?.helperText ?? `field::${id}::helper-text`;\n const labelId = ids?.label ?? `field::${id}::label`;\n useSafeLayoutEffect(() => {\n const rootNode = rootRef.current;\n if (!rootNode) return;\n const checkTextElements = () => {\n const docOrShadowRoot = env.getRootNode();\n setHasErrorText(!!docOrShadowRoot.getElementById(errorTextId));\n setHasHelperText(!!docOrShadowRoot.getElementById(helperTextId));\n };\n checkTextElements();\n const win = env.getWindow();\n const observer = new win.MutationObserver(checkTextElements);\n observer.observe(rootNode, { childList: true, subtree: true });\n return () => observer.disconnect();\n }, [env, errorTextId, helperTextId]);\n const labelIds = useMemo(() => {\n const ids2 = [];\n if (hasErrorText && invalid) ids2.push(errorTextId);\n if (hasHelperText) ids2.push(helperTextId);\n return ids2.join(\" \") || void 0;\n }, [invalid, errorTextId, helperTextId, hasErrorText, hasHelperText]);\n const getRootProps = useMemo(\n () => () => ({\n ...parts.root.attrs,\n id: rootId,\n ref: rootRef,\n role: \"group\",\n \"data-disabled\": dataAttr(disabled),\n \"data-invalid\": dataAttr(invalid),\n \"data-readonly\": dataAttr(readOnly)\n }),\n [disabled, invalid, readOnly, rootId]\n );\n const getLabelProps = useMemo(\n () => () => ({\n ...parts.label.attrs,\n id: labelId,\n \"data-disabled\": dataAttr(disabled),\n \"data-invalid\": dataAttr(invalid),\n \"data-readonly\": dataAttr(readOnly),\n htmlFor: id\n }),\n [disabled, invalid, readOnly, id, labelId]\n );\n const getControlProps = useMemo(\n () => () => ({\n \"aria-describedby\": labelIds,\n \"aria-invalid\": ariaAttr(invalid),\n \"data-invalid\": dataAttr(invalid),\n \"data-required\": dataAttr(required),\n \"data-readonly\": dataAttr(readOnly),\n id,\n required,\n disabled,\n readOnly\n }),\n [labelIds, invalid, required, readOnly, id, disabled]\n );\n const getInputProps = useMemo(\n () => () => ({\n ...getControlProps(),\n ...parts.input.attrs\n }),\n [getControlProps]\n );\n const getTextareaProps = useMemo(\n () => () => ({\n ...getControlProps(),\n ...parts.textarea.attrs\n }),\n [getControlProps]\n );\n const getSelectProps = useMemo(\n () => () => ({\n ...getControlProps(),\n ...parts.select.attrs\n }),\n [getControlProps]\n );\n const getHelperTextProps = useMemo(\n () => () => ({\n id: helperTextId,\n ...parts.helperText.attrs,\n \"data-disabled\": dataAttr(disabled)\n }),\n [disabled, helperTextId]\n );\n const getErrorTextProps = useMemo(\n () => () => ({\n id: errorTextId,\n ...parts.errorText.attrs,\n \"aria-live\": \"polite\"\n }),\n [errorTextId]\n );\n const getRequiredIndicatorProps = useMemo(\n () => () => ({\n \"aria-hidden\": true,\n ...parts.requiredIndicator.attrs\n }),\n []\n );\n return {\n ariaDescribedby: labelIds,\n ids: {\n root: rootId,\n control: id,\n label: labelId,\n errorText: errorTextId,\n helperText: helperTextId\n },\n refs: {\n rootRef\n },\n disabled,\n invalid,\n readOnly,\n required,\n getLabelProps,\n getRootProps,\n getInputProps,\n getTextareaProps,\n getSelectProps,\n getHelperTextProps,\n getErrorTextProps,\n getRequiredIndicatorProps\n };\n};\n\nexport { useField };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { composeRefs } from '../../utils/compose-refs.js';\nimport { createSplitProps } from '../../utils/create-split-props.js';\nimport { ark } from '../factory.js';\nimport { useField } from './use-field.js';\nimport { FieldProvider } from './use-field-context.js';\n\nconst FieldRoot = forwardRef((props, ref) => {\n const [useFieldProps, localProps] = createSplitProps()(props, [\n \"id\",\n \"ids\",\n \"disabled\",\n \"invalid\",\n \"readOnly\",\n \"required\"\n ]);\n const field = useField(useFieldProps);\n const mergedProps = mergeProps(field.getRootProps(), localProps);\n return /* @__PURE__ */ jsx(FieldProvider, { value: field, children: /* @__PURE__ */ jsx(ark.div, { ...mergedProps, ref: composeRefs(ref, field.refs.rootRef) }) });\n});\nFieldRoot.displayName = \"FieldRoot\";\n\nexport { FieldRoot };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport * as React from 'react';\nimport { cx } from '../../utils/cx.js';\nimport { createRecipeContext } from '../../styled-system/create-recipe-context.js';\nimport { chakra } from '../../styled-system/factory.js';\n\nconst { useRecipeResult, PropsProvider } = createRecipeContext({ key: \"icon\" });\nconst Icon = React.forwardRef(\n function Icon2(props, ref) {\n const {\n styles,\n className,\n props: otherProps\n } = useRecipeResult({ asChild: !props.as, ...props });\n return /* @__PURE__ */ jsx(\n chakra.svg,\n {\n ref,\n focusable: false,\n \"aria-hidden\": \"true\",\n ...otherProps,\n css: [styles, props.css],\n className: cx(className, props.className)\n }\n );\n }\n);\nconst IconPropsProvider = PropsProvider;\n\nexport { Icon, IconPropsProvider };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { Children, forwardRef } from 'react';\nimport { Icon } from './icon.js';\n\nfunction createIcon(options) {\n const {\n viewBox = \"0 0 24 24\",\n d: pathDefinition,\n displayName,\n defaultProps = {}\n } = options;\n const path = Children.toArray(options.path);\n const Comp = forwardRef((props, ref) => /* @__PURE__ */ jsx(\n Icon,\n {\n ref,\n asChild: false,\n viewBox,\n ...defaultProps,\n ...props,\n children: path.length ? path : /* @__PURE__ */ jsx(\"path\", { fill: \"currentColor\", d: pathDefinition })\n }\n ));\n Comp.displayName = displayName;\n return Comp;\n}\n\nexport { createIcon };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { Field, useFieldContext } from '@ark-ui/react/field';\nimport { forwardRef } from 'react';\nimport { cx } from '../../utils/cx.js';\nimport { createSlotRecipeContext } from '../../styled-system/create-slot-recipe-context.js';\nimport { chakra } from '../../styled-system/factory.js';\nimport { createIcon } from '../icon/create-icon.js';\n\nconst {\n withProvider,\n withContext,\n useStyles: useFieldStyles,\n useClassNames,\n PropsProvider\n} = createSlotRecipeContext({ key: \"field\" });\nconst FieldRoot = withProvider(\n Field.Root,\n \"root\",\n { forwardAsChild: true }\n);\nconst FieldPropsProvider = PropsProvider;\nconst FieldLabel = withContext(\n Field.Label,\n \"label\",\n { forwardAsChild: true }\n);\nconst FieldHelperText = withContext(Field.HelperText, \"helperText\", { forwardAsChild: true });\nconst FieldErrorText = withContext(\n Field.ErrorText,\n \"errorText\",\n { forwardAsChild: true }\n);\nconst FieldErrorIcon = createIcon({\n d: \"M11.983,0a12.206,12.206,0,0,0-8.51,3.653A11.8,11.8,0,0,0,0,12.207,11.779,11.779,0,0,0,11.8,24h.214A12.111,12.111,0,0,0,24,11.791h0A11.766,11.766,0,0,0,11.983,0ZM10.5,16.542a1.476,1.476,0,0,1,1.449-1.53h.027a1.527,1.527,0,0,1,1.523,1.47,1.475,1.475,0,0,1-1.449,1.53h-.027A1.529,1.529,0,0,1,10.5,16.542ZM11,12.5v-6a1,1,0,0,1,2,0v6a1,1,0,1,1-2,0Z\"\n});\nconst FieldRequiredIndicator = forwardRef(function RequiredIndicator(props, ref) {\n const { fallback, children = \"*\", ...restProps } = props;\n const field = useFieldContext();\n const classNames = useClassNames();\n const styles = useFieldStyles();\n if (!field?.required) {\n return fallback;\n }\n return /* @__PURE__ */ jsx(\n chakra.span,\n {\n ref,\n \"aria-hidden\": \"true\",\n ...restProps,\n className: cx(classNames.requiredIndicator, props.className),\n css: [styles.requiredIndicator, props.css],\n children\n }\n );\n});\n\nexport { FieldErrorIcon, FieldErrorText, FieldHelperText, FieldLabel, FieldPropsProvider, FieldRequiredIndicator, FieldRoot, useFieldStyles };\n","import { FormControlSize } from './withFormControl.types';\n\nexport const optionalTextSizeMap: Record<FormControlSize, number> = {\n sm: 10,\n md: 12,\n lg: 14,\n};\n","import React from 'react';\nimport { Field } from '@chakra-ui/react/field';\nimport { FormControlLabelPosition, FormControlSize } from './withFormControl.types';\nimport { SystemStyleObject } from '@chakra-ui/react/styled-system';\nimport { TypographyVariant } from 'shared/types/typography';\nimport { Text } from 'components/Text/text.component';\nimport { optionalTextSizeMap } from './withFormControl.records';\nimport { fontSizes } from 'theme/tokens/typography/typography.records';\nimport { Flex } from '@chakra-ui/react/flex';\nimport { Icon } from 'components/Icon/icon.component';\nimport { Box } from '@chakra-ui/react/box';\n\nexport interface WithFormControlProps {\n /** If true, the form control will be disabled.\n * @default false\n */\n disabled?: boolean;\n /** The error text to be displayed when the form control is invalid.\n * @default Field is invalid\n */\n errorText?: string;\n /** Props to customize the form control. */\n formControlStyle?: SystemStyleObject;\n /** If true, the form control will take the full width of its container.\n * @default true\n */\n fullWidth?: boolean;\n /** The helper text to be displayed below the form control. */\n helperText?: string;\n /** If true, the form control will be displayed inline with the label. */\n inlineField?: boolean;\n /** If true, the form control will be invalid.\n * @default false\n */\n invalid?: boolean;\n /** The variant of the invalid icon.\n * @default danger\n */\n invalidIconColor?: TypographyVariant;\n /** The label to be displayed above the form control. */\n label?: string | React.ReactNode;\n /** The position of the label relative to the form control.\n * @default start\n */\n labelPosition?: FormControlLabelPosition;\n /** Props to customize the label. */\n labelStyle?: SystemStyleObject;\n /** If true, the form control will be styled for contrast mode.\n * @default false\n */\n onContrast?: boolean;\n /** If true, the form element will be read only.\n * @default false\n */\n readOnly?: boolean;\n /** If true, the form control will be required.\n * @default false\n */\n required?: boolean;\n /** If true, the form control will show an optional text.\n * @default false\n */\n showOptionalElement?: boolean;\n /** The size of the form control.\n * @default md\n */\n size?: FormControlSize;\n /** If true, the form control will show an invalid icon.\n * @default false\n */\n useInvalidIcon?: boolean;\n /** If true, the form control will show an invalid text.\n * @default true\n */\n useInvalidText?: boolean;\n}\n\nexport const withFormControl = <P extends WithFormControlProps>(Component: React.ComponentType<P>): React.FC<P> => {\n const WithFormControl = ({\n disabled = false,\n errorText = 'Field is invalid',\n formControlStyle,\n fullWidth = true,\n helperText,\n inlineField = false,\n invalid = false,\n invalidIconColor = 'danger',\n label,\n labelPosition = 'start',\n labelStyle,\n onContrast = false,\n readOnly = false,\n required = false,\n showOptionalElement = false,\n size = 'md',\n useInvalidIcon = false,\n useInvalidText = true,\n ...props\n }: WithFormControlProps): React.JSX.Element => {\n const labelComponent = (\n <Field.Label\n className=\"FormControl__Label\"\n color={onContrast ? 'text.contrast' : 'text'}\n display=\"flex\"\n flexDirection=\"row\"\n gap={1}\n fontSize={fontSizes[size]}\n fontWeight=\"semibold\"\n {...labelStyle}\n onClick={(e) => {\n e.stopPropagation();\n }}\n >\n <Box as=\"span\">{label}</Box>\n <Field.RequiredIndicator\n className=\"FormControl__RequiredIndicator\"\n color={onContrast ? 'text.danger.contrast' : 'text.danger'}\n {...(!required && {\n fallback: showOptionalElement ? (\n <Text\n as=\"span\"\n variant={onContrast ? 'subtleOnContrast' : 'subtle'}\n fontSize={optionalTextSizeMap[size]}\n display=\"contents\"\n ml={1}\n >\n (Optional)\n </Text>\n ) : (\n <></>\n ),\n })}\n />\n </Field.Label>\n );\n\n return (\n <Field.Root\n className=\"FormControl group\"\n disabled={disabled}\n invalid={invalid}\n readOnly={readOnly}\n required={required}\n width={fullWidth ? '100%' : 'auto'}\n {...formControlStyle}\n >\n <Flex\n className=\"FormControl__Container\"\n flexDirection={inlineField ? 'row' : 'column'}\n w={inlineField ? 'max-content' : '100%'}\n gap={2}\n alignItems={inlineField ? 'center' : 'flex-start'}\n >\n {label && labelPosition === 'start' && labelComponent}\n <Flex className=\"FormControl__Content\" alignItems=\"center\" gap={2} w={inlineField ? 'max-content' : '100%'}>\n <Component\n disabled={disabled}\n invalid={invalid}\n onContrast={onContrast}\n readOnly={readOnly}\n required={required}\n size={size}\n {...(props as P)}\n />\n {useInvalidIcon && invalid && (\n <Icon className=\"FormControl__InvalidIcon\" name=\"warningSign\" variant={invalidIconColor} size={size} />\n )}\n </Flex>\n {label && labelPosition === 'end' && labelComponent}\n </Flex>\n {useInvalidText && invalid && (\n <Field.ErrorText\n className=\"FormControl__ErrorText\"\n fontSize=\"xs\"\n color={onContrast ? 'text.danger.contrast' : 'text.danger'}\n >\n {errorText}\n </Field.ErrorText>\n )}\n {helperText && (\n <Field.HelperText\n className=\"FormControl__HelperText\"\n fontSize=\"xs\"\n color={onContrast ? 'text.subtle.contrast' : 'text.subtle'}\n >\n {helperText}\n </Field.HelperText>\n )}\n </Field.Root>\n );\n };\n\n WithFormControl.displayName = `withFormControl(${Component.displayName || Component.name}`;\n return WithFormControl;\n};\n"],"names":["FieldErrorText","forwardRef","props","ref","field","useFieldContext","mergedProps","mergeProps","jsx","ark","FieldHelperText","FieldLabel","useSafeLayoutEffect","useLayoutEffect","useEffect","FieldsetProvider","useFieldsetContext","createContext","useField","fieldset","env","useEnvironmentContext","ids","disabled","invalid","readOnly","required","hasErrorText","setHasErrorText","useState","hasHelperText","setHasHelperText","uid","useId","id","rootRef","useRef","rootId","errorTextId","helperTextId","labelId","rootNode","checkTextElements","docOrShadowRoot","win","observer","labelIds","useMemo","ids2","getRootProps","parts","dataAttr","getLabelProps","getControlProps","ariaAttr","getInputProps","getTextareaProps","getSelectProps","getHelperTextProps","getErrorTextProps","getRequiredIndicatorProps","FieldRoot","useFieldProps","localProps","createSplitProps","FieldProvider","composeRefs","useRecipeResult","createRecipeContext","Icon","React","styles","className","otherProps","chakra","cx","createIcon","options","viewBox","pathDefinition","displayName","defaultProps","path","Children","Comp","withProvider","withContext","useFieldStyles","useClassNames","createSlotRecipeContext","Field.Root","Field.Label","Field.HelperText","Field.ErrorText","FieldRequiredIndicator","fallback","children","restProps","classNames","optionalTextSizeMap","withFormControl","Component","WithFormControl","errorText","formControlStyle","fullWidth","helperText","inlineField","invalidIconColor","label","labelPosition","labelStyle","onContrast","showOptionalElement","size","useInvalidIcon","useInvalidText","labelComponent","jsxs","fontSizes","e","Box","Field.RequiredIndicator","Text","Fragment","Flex"],"mappings":"s3BAOMA,EAAiBC,EAAU,WAAC,CAACC,EAAOC,IAAQ,CAChD,MAAMC,EAAQC,EAAAA,gBAAiB,EACzBC,EAAcC,EAAU,WAACH,EAAM,kBAAiB,EAAIF,CAAK,EAC/D,OAAIE,GAAO,QACcI,EAAAA,kBAAAA,IAAIC,EAAAA,IAAI,KAAM,CAAE,GAAGH,EAAa,IAAAH,EAAK,EAEvD,IACT,CAAC,EACDH,EAAe,YAAc,iBCR7B,MAAMU,EAAkBT,EAAU,WAAC,CAACC,EAAOC,IAAQ,CACjD,MAAMC,EAAQC,EAAAA,gBAAiB,EACzBC,EAAcC,EAAU,WAACH,GAAO,mBAAkB,EAAIF,CAAK,EACjE,OAAuBM,EAAAA,kBAAAA,IAAIC,EAAAA,IAAI,KAAM,CAAE,GAAGH,EAAa,IAAAH,EAAK,CAC9D,CAAC,EACDO,EAAgB,YAAc,kBCL9B,MAAMC,EAAaV,EAAU,WAAC,CAACC,EAAOC,IAAQ,CAC5C,MAAMC,EAAQC,EAAAA,gBAAiB,EACzBC,EAAcC,EAAU,WAACH,GAAO,cAAa,EAAIF,CAAK,EAC5D,OAAuBM,EAAAA,kBAAAA,IAAIC,EAAAA,IAAI,MAAO,CAAE,GAAGH,EAAa,IAAAH,EAAK,CAC/D,CAAC,EACDQ,EAAW,YAAc,aCTzB,MAAMC,GAAsB,OAAO,OAAW,IAAcC,EAAe,gBAAGC,EAAS,UCAjF,CAACC,GAAkBC,EAAkB,EAAIC,gBAAc,CAC3D,KAAM,kBACN,SAAU,qBACV,aAAc,uBACd,OAAQ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jBhB,EAAA,kBAAA,IAACqF,GAAA,CACC,UAAU,yBACV,SAAS,KACT,MAAOmB,EAAa,uBAAyB,cAE5C,SAAAT,CAAA,CACH,EAEDG,GACClG,EAAA,kBAAA,IAACoF,GAAA,CACC,UAAU,0BACV,SAAS,KACT,MAAOoB,EAAa,uBAAyB,cAE5C,SAAAN,CAAA,CAAA,CACH,CAAA,CAEJ,CAEJ,EAEA,OAAAJ,EAAgB,YAAc,mBAAmBD,EAAU,aAAeA,EAAU,IAAI,GACjFC,CACT","x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9]}
|
|
1
|
+
{"version":3,"file":"withFormControl-BwtO61gv.js","sources":["../../node_modules/@ark-ui/react/dist/components/field/field-error-text.js","../../node_modules/@ark-ui/react/dist/components/field/field-helper-text.js","../../node_modules/@ark-ui/react/dist/components/field/field-label.js","../../node_modules/@ark-ui/react/dist/utils/use-safe-layout-effect.js","../../node_modules/@ark-ui/react/dist/components/fieldset/use-fieldset-context.js","../../node_modules/@ark-ui/react/dist/components/field/use-field.js","../../node_modules/@ark-ui/react/dist/components/field/field-root.js","../../node_modules/@chakra-ui/react/dist/esm/components/icon/icon.js","../../node_modules/@chakra-ui/react/dist/esm/components/icon/create-icon.js","../../node_modules/@chakra-ui/react/dist/esm/components/field/field.js","../../src/hocs/withFormControl/withFormControl.records.ts","../../src/hocs/withFormControl/withFormControl.tsx"],"sourcesContent":["'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from './use-field-context.js';\n\nconst FieldErrorText = forwardRef((props, ref) => {\n const field = useFieldContext();\n const mergedProps = mergeProps(field.getErrorTextProps(), props);\n if (field?.invalid) {\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n }\n return null;\n});\nFieldErrorText.displayName = \"FieldErrorText\";\n\nexport { FieldErrorText };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from './use-field-context.js';\n\nconst FieldHelperText = forwardRef((props, ref) => {\n const field = useFieldContext();\n const mergedProps = mergeProps(field?.getHelperTextProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nFieldHelperText.displayName = \"FieldHelperText\";\n\nexport { FieldHelperText };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from './use-field-context.js';\n\nconst FieldLabel = forwardRef((props, ref) => {\n const field = useFieldContext();\n const mergedProps = mergeProps(field?.getLabelProps(), props);\n return /* @__PURE__ */ jsx(ark.label, { ...mergedProps, ref });\n});\nFieldLabel.displayName = \"FieldLabel\";\n\nexport { FieldLabel };\n","'use client';\nimport { useLayoutEffect, useEffect } from 'react';\n\nconst useSafeLayoutEffect = typeof window !== \"undefined\" ? useLayoutEffect : useEffect;\n\nexport { useSafeLayoutEffect };\n","'use client';\nimport { createContext } from '../../utils/create-context.js';\n\nconst [FieldsetProvider, useFieldsetContext] = createContext({\n name: \"FieldsetContext\",\n hookName: \"useFieldsetContext\",\n providerName: \"<FieldsetProvider />\",\n strict: false\n});\n\nexport { FieldsetProvider, useFieldsetContext };\n","'use client';\nimport { dataAttr, ariaAttr } from '@zag-js/dom-query';\nimport { useState, useId, useRef, useMemo } from 'react';\nimport { useEnvironmentContext } from '../../providers/environment/use-environment-context.js';\nimport { useSafeLayoutEffect } from '../../utils/use-safe-layout-effect.js';\nimport { useFieldsetContext } from '../fieldset/use-fieldset-context.js';\nimport { parts } from './field.anatomy.js';\n\nconst useField = (props = {}) => {\n const fieldset = useFieldsetContext();\n const env = useEnvironmentContext();\n const { ids, disabled = Boolean(fieldset?.disabled), invalid = false, readOnly = false, required = false } = props;\n const [hasErrorText, setHasErrorText] = useState(false);\n const [hasHelperText, setHasHelperText] = useState(false);\n const uid = useId();\n const id = props.id ?? uid;\n const rootRef = useRef(null);\n const rootId = ids?.control ?? `field::${id}`;\n const errorTextId = ids?.errorText ?? `field::${id}::error-text`;\n const helperTextId = ids?.helperText ?? `field::${id}::helper-text`;\n const labelId = ids?.label ?? `field::${id}::label`;\n useSafeLayoutEffect(() => {\n const rootNode = rootRef.current;\n if (!rootNode) return;\n const checkTextElements = () => {\n const docOrShadowRoot = env.getRootNode();\n setHasErrorText(!!docOrShadowRoot.getElementById(errorTextId));\n setHasHelperText(!!docOrShadowRoot.getElementById(helperTextId));\n };\n checkTextElements();\n const win = env.getWindow();\n const observer = new win.MutationObserver(checkTextElements);\n observer.observe(rootNode, { childList: true, subtree: true });\n return () => observer.disconnect();\n }, [env, errorTextId, helperTextId]);\n const labelIds = useMemo(() => {\n const ids2 = [];\n if (hasErrorText && invalid) ids2.push(errorTextId);\n if (hasHelperText) ids2.push(helperTextId);\n return ids2.join(\" \") || void 0;\n }, [invalid, errorTextId, helperTextId, hasErrorText, hasHelperText]);\n const getRootProps = useMemo(\n () => () => ({\n ...parts.root.attrs,\n id: rootId,\n ref: rootRef,\n role: \"group\",\n \"data-disabled\": dataAttr(disabled),\n \"data-invalid\": dataAttr(invalid),\n \"data-readonly\": dataAttr(readOnly)\n }),\n [disabled, invalid, readOnly, rootId]\n );\n const getLabelProps = useMemo(\n () => () => ({\n ...parts.label.attrs,\n id: labelId,\n \"data-disabled\": dataAttr(disabled),\n \"data-invalid\": dataAttr(invalid),\n \"data-readonly\": dataAttr(readOnly),\n htmlFor: id\n }),\n [disabled, invalid, readOnly, id, labelId]\n );\n const getControlProps = useMemo(\n () => () => ({\n \"aria-describedby\": labelIds,\n \"aria-invalid\": ariaAttr(invalid),\n \"data-invalid\": dataAttr(invalid),\n \"data-required\": dataAttr(required),\n \"data-readonly\": dataAttr(readOnly),\n id,\n required,\n disabled,\n readOnly\n }),\n [labelIds, invalid, required, readOnly, id, disabled]\n );\n const getInputProps = useMemo(\n () => () => ({\n ...getControlProps(),\n ...parts.input.attrs\n }),\n [getControlProps]\n );\n const getTextareaProps = useMemo(\n () => () => ({\n ...getControlProps(),\n ...parts.textarea.attrs\n }),\n [getControlProps]\n );\n const getSelectProps = useMemo(\n () => () => ({\n ...getControlProps(),\n ...parts.select.attrs\n }),\n [getControlProps]\n );\n const getHelperTextProps = useMemo(\n () => () => ({\n id: helperTextId,\n ...parts.helperText.attrs,\n \"data-disabled\": dataAttr(disabled)\n }),\n [disabled, helperTextId]\n );\n const getErrorTextProps = useMemo(\n () => () => ({\n id: errorTextId,\n ...parts.errorText.attrs,\n \"aria-live\": \"polite\"\n }),\n [errorTextId]\n );\n const getRequiredIndicatorProps = useMemo(\n () => () => ({\n \"aria-hidden\": true,\n ...parts.requiredIndicator.attrs\n }),\n []\n );\n return {\n ariaDescribedby: labelIds,\n ids: {\n root: rootId,\n control: id,\n label: labelId,\n errorText: errorTextId,\n helperText: helperTextId\n },\n refs: {\n rootRef\n },\n disabled,\n invalid,\n readOnly,\n required,\n getLabelProps,\n getRootProps,\n getInputProps,\n getTextareaProps,\n getSelectProps,\n getHelperTextProps,\n getErrorTextProps,\n getRequiredIndicatorProps\n };\n};\n\nexport { useField };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { composeRefs } from '../../utils/compose-refs.js';\nimport { createSplitProps } from '../../utils/create-split-props.js';\nimport { ark } from '../factory.js';\nimport { useField } from './use-field.js';\nimport { FieldProvider } from './use-field-context.js';\n\nconst FieldRoot = forwardRef((props, ref) => {\n const [useFieldProps, localProps] = createSplitProps()(props, [\n \"id\",\n \"ids\",\n \"disabled\",\n \"invalid\",\n \"readOnly\",\n \"required\"\n ]);\n const field = useField(useFieldProps);\n const mergedProps = mergeProps(field.getRootProps(), localProps);\n return /* @__PURE__ */ jsx(FieldProvider, { value: field, children: /* @__PURE__ */ jsx(ark.div, { ...mergedProps, ref: composeRefs(ref, field.refs.rootRef) }) });\n});\nFieldRoot.displayName = \"FieldRoot\";\n\nexport { FieldRoot };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport * as React from 'react';\nimport { cx } from '../../utils/cx.js';\nimport { createRecipeContext } from '../../styled-system/create-recipe-context.js';\nimport { chakra } from '../../styled-system/factory.js';\n\nconst { useRecipeResult, PropsProvider } = createRecipeContext({ key: \"icon\" });\nconst Icon = React.forwardRef(\n function Icon2(props, ref) {\n const {\n styles,\n className,\n props: otherProps\n } = useRecipeResult({ asChild: !props.as, ...props });\n return /* @__PURE__ */ jsx(\n chakra.svg,\n {\n ref,\n focusable: false,\n \"aria-hidden\": \"true\",\n ...otherProps,\n css: [styles, props.css],\n className: cx(className, props.className)\n }\n );\n }\n);\nconst IconPropsProvider = PropsProvider;\n\nexport { Icon, IconPropsProvider };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { Children, forwardRef } from 'react';\nimport { Icon } from './icon.js';\n\nfunction createIcon(options) {\n const {\n viewBox = \"0 0 24 24\",\n d: pathDefinition,\n displayName,\n defaultProps = {}\n } = options;\n const path = Children.toArray(options.path);\n const Comp = forwardRef((props, ref) => /* @__PURE__ */ jsx(\n Icon,\n {\n ref,\n asChild: false,\n viewBox,\n ...defaultProps,\n ...props,\n children: path.length ? path : /* @__PURE__ */ jsx(\"path\", { fill: \"currentColor\", d: pathDefinition })\n }\n ));\n Comp.displayName = displayName;\n return Comp;\n}\n\nexport { createIcon };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { Field, useFieldContext } from '@ark-ui/react/field';\nimport { forwardRef } from 'react';\nimport { cx } from '../../utils/cx.js';\nimport { createSlotRecipeContext } from '../../styled-system/create-slot-recipe-context.js';\nimport { chakra } from '../../styled-system/factory.js';\nimport { createIcon } from '../icon/create-icon.js';\n\nconst {\n withProvider,\n withContext,\n useStyles: useFieldStyles,\n useClassNames,\n PropsProvider\n} = createSlotRecipeContext({ key: \"field\" });\nconst FieldRoot = withProvider(\n Field.Root,\n \"root\",\n { forwardAsChild: true }\n);\nconst FieldPropsProvider = PropsProvider;\nconst FieldLabel = withContext(\n Field.Label,\n \"label\",\n { forwardAsChild: true }\n);\nconst FieldHelperText = withContext(Field.HelperText, \"helperText\", { forwardAsChild: true });\nconst FieldErrorText = withContext(\n Field.ErrorText,\n \"errorText\",\n { forwardAsChild: true }\n);\nconst FieldErrorIcon = createIcon({\n d: \"M11.983,0a12.206,12.206,0,0,0-8.51,3.653A11.8,11.8,0,0,0,0,12.207,11.779,11.779,0,0,0,11.8,24h.214A12.111,12.111,0,0,0,24,11.791h0A11.766,11.766,0,0,0,11.983,0ZM10.5,16.542a1.476,1.476,0,0,1,1.449-1.53h.027a1.527,1.527,0,0,1,1.523,1.47,1.475,1.475,0,0,1-1.449,1.53h-.027A1.529,1.529,0,0,1,10.5,16.542ZM11,12.5v-6a1,1,0,0,1,2,0v6a1,1,0,1,1-2,0Z\"\n});\nconst FieldRequiredIndicator = forwardRef(function RequiredIndicator(props, ref) {\n const { fallback, children = \"*\", ...restProps } = props;\n const field = useFieldContext();\n const classNames = useClassNames();\n const styles = useFieldStyles();\n if (!field?.required) {\n return fallback;\n }\n return /* @__PURE__ */ jsx(\n chakra.span,\n {\n ref,\n \"aria-hidden\": \"true\",\n ...restProps,\n className: cx(classNames.requiredIndicator, props.className),\n css: [styles.requiredIndicator, props.css],\n children\n }\n );\n});\n\nexport { FieldErrorIcon, FieldErrorText, FieldHelperText, FieldLabel, FieldPropsProvider, FieldRequiredIndicator, FieldRoot, useFieldStyles };\n","import { FormControlSize } from './withFormControl.types';\n\nexport const optionalTextSizeMap: Record<FormControlSize, number> = {\n sm: 10,\n md: 12,\n lg: 14,\n};\n","import React from 'react';\nimport { Field } from '@chakra-ui/react/field';\nimport { FormControlLabelPosition, FormControlSize } from './withFormControl.types';\nimport { SystemStyleObject } from '@chakra-ui/react/styled-system';\nimport { TypographyVariant } from 'shared/types/typography';\nimport { Text } from 'components/Text/text.component';\nimport { optionalTextSizeMap } from './withFormControl.records';\nimport { fontSizes } from 'theme/tokens/typography/typography.records';\nimport { Flex } from '@chakra-ui/react/flex';\nimport { Icon } from 'components/Icon/icon.component';\nimport { Box } from '@chakra-ui/react/box';\n\nexport interface WithFormControlProps {\n /** If true, the form control will be disabled.\n * @default false\n */\n disabled?: boolean;\n /** The error text to be displayed when the form control is invalid.\n * @default Field is invalid\n */\n errorText?: string;\n /** Props to customize the form control. */\n formControlStyle?: SystemStyleObject;\n /** If true, the form control will take the full width of its container.\n * @default true\n */\n fullWidth?: boolean;\n /** The helper text to be displayed below the form control. */\n helperText?: string;\n /** If true, the form control will be displayed inline with the label. */\n inlineField?: boolean;\n /** If true, the form control will be invalid.\n * @default false\n */\n invalid?: boolean;\n /** The variant of the invalid icon.\n * @default danger\n */\n invalidIconColor?: TypographyVariant;\n /** The label to be displayed above the form control. */\n label?: string | React.ReactNode;\n /** The position of the label relative to the form control.\n * @default start\n */\n labelPosition?: FormControlLabelPosition;\n /** Props to customize the label. */\n labelStyle?: SystemStyleObject;\n /** If true, the form control will be styled for contrast mode.\n * @default false\n */\n onContrast?: boolean;\n /** If true, the form element will be read only.\n * @default false\n */\n readOnly?: boolean;\n /** If true, the form control will be required.\n * @default false\n */\n required?: boolean;\n /** If true, the form control will show an optional text.\n * @default false\n */\n showOptionalElement?: boolean;\n /** The size of the form control.\n * @default md\n */\n size?: FormControlSize;\n /** If true, the form control will show an invalid icon.\n * @default false\n */\n useInvalidIcon?: boolean;\n /** If true, the form control will show an invalid text.\n * @default true\n */\n useInvalidText?: boolean;\n}\n\nexport const withFormControl = <P extends WithFormControlProps>(Component: React.ComponentType<P>): React.FC<P> => {\n const WithFormControl = ({\n disabled = false,\n errorText = 'Field is invalid',\n formControlStyle,\n fullWidth = true,\n helperText,\n inlineField = false,\n invalid = false,\n invalidIconColor = 'danger',\n label,\n labelPosition = 'start',\n labelStyle,\n onContrast = false,\n readOnly = false,\n required = false,\n showOptionalElement = false,\n size = 'md',\n useInvalidIcon = false,\n useInvalidText = true,\n ...props\n }: WithFormControlProps): React.JSX.Element => {\n const labelComponent = (\n <Field.Label\n className=\"FormControl__Label\"\n color={onContrast ? 'text.contrast' : 'text'}\n display=\"flex\"\n flexDirection=\"row\"\n gap={1}\n fontSize={fontSizes[size]}\n fontWeight=\"semibold\"\n {...labelStyle}\n onClick={(e) => {\n e.stopPropagation();\n }}\n >\n <Box as=\"span\">{label}</Box>\n <Field.RequiredIndicator\n className=\"FormControl__RequiredIndicator\"\n color={onContrast ? 'text.danger.contrast' : 'text.danger'}\n {...(!required && {\n fallback: showOptionalElement ? (\n <Text\n as=\"span\"\n variant={onContrast ? 'subtleOnContrast' : 'subtle'}\n fontSize={optionalTextSizeMap[size]}\n display=\"contents\"\n ml={1}\n >\n (Optional)\n </Text>\n ) : (\n <></>\n ),\n })}\n />\n </Field.Label>\n );\n\n return (\n <Field.Root\n className=\"FormControl group\"\n disabled={disabled}\n invalid={invalid}\n readOnly={readOnly}\n required={required}\n width={fullWidth ? '100%' : 'auto'}\n {...formControlStyle}\n >\n <Flex\n className=\"FormControl__Container\"\n flexDirection={inlineField ? 'row' : 'column'}\n w={inlineField ? 'max-content' : '100%'}\n gap={2}\n alignItems={inlineField ? 'center' : 'flex-start'}\n >\n {label && labelPosition === 'start' && labelComponent}\n <Flex className=\"FormControl__Content\" alignItems=\"center\" gap={2} w={inlineField ? 'max-content' : '100%'}>\n <Component\n disabled={disabled}\n invalid={invalid}\n onContrast={onContrast}\n readOnly={readOnly}\n required={required}\n size={size}\n {...(props as P)}\n />\n {useInvalidIcon && invalid && (\n <Icon className=\"FormControl__InvalidIcon\" name=\"warningSign\" variant={invalidIconColor} size={size} />\n )}\n </Flex>\n {label && labelPosition === 'end' && labelComponent}\n </Flex>\n {useInvalidText && invalid && (\n <Field.ErrorText\n className=\"FormControl__ErrorText\"\n fontSize=\"xs\"\n color={onContrast ? 'text.danger.contrast' : 'text.danger'}\n >\n {errorText}\n </Field.ErrorText>\n )}\n {helperText && (\n <Field.HelperText\n className=\"FormControl__HelperText\"\n fontSize=\"xs\"\n color={onContrast ? 'text.subtle.contrast' : 'text.subtle'}\n >\n {helperText}\n </Field.HelperText>\n )}\n </Field.Root>\n );\n };\n\n WithFormControl.displayName = `withFormControl(${Component.displayName || Component.name}`;\n return WithFormControl;\n};\n"],"names":["FieldErrorText","forwardRef","props","ref","field","useFieldContext","mergedProps","mergeProps","jsx","ark","FieldHelperText","FieldLabel","useSafeLayoutEffect","useLayoutEffect","useEffect","FieldsetProvider","useFieldsetContext","createContext","useField","fieldset","env","useEnvironmentContext","ids","disabled","invalid","readOnly","required","hasErrorText","setHasErrorText","useState","hasHelperText","setHasHelperText","uid","useId","id","rootRef","useRef","rootId","errorTextId","helperTextId","labelId","rootNode","checkTextElements","docOrShadowRoot","win","observer","labelIds","useMemo","ids2","getRootProps","parts","dataAttr","getLabelProps","getControlProps","ariaAttr","getInputProps","getTextareaProps","getSelectProps","getHelperTextProps","getErrorTextProps","getRequiredIndicatorProps","FieldRoot","useFieldProps","localProps","createSplitProps","FieldProvider","composeRefs","useRecipeResult","createRecipeContext","Icon","React","styles","className","otherProps","chakra","cx","createIcon","options","viewBox","pathDefinition","displayName","defaultProps","path","Children","Comp","withProvider","withContext","useFieldStyles","useClassNames","createSlotRecipeContext","Field.Root","Field.Label","Field.HelperText","Field.ErrorText","FieldRequiredIndicator","fallback","children","restProps","classNames","optionalTextSizeMap","withFormControl","Component","WithFormControl","errorText","formControlStyle","fullWidth","helperText","inlineField","invalidIconColor","label","labelPosition","labelStyle","onContrast","showOptionalElement","size","useInvalidIcon","useInvalidText","labelComponent","jsxs","fontSizes","e","Box","Field.RequiredIndicator","Text","Fragment","Flex"],"mappings":"s3BAOMA,EAAiBC,EAAU,WAAC,CAACC,EAAOC,IAAQ,CAChD,MAAMC,EAAQC,EAAAA,gBAAiB,EACzBC,EAAcC,EAAU,WAACH,EAAM,kBAAiB,E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|
1
1
|
import { j as t } from "./jsx-runtime-C5mzlN2N.js";
|
|
2
|
-
import { W as V } from "./text.component-
|
|
2
|
+
import { W as V } from "./text.component-RbaGyNOr.js";
|
|
3
3
|
import { f as X } from "./typography.records-BEd2lI_g.js";
|
|
4
4
|
import { I as Y } from "./icon.component-PV_nHBId.js";
|
|
5
5
|
import { B as ee } from "./index-9BerxEcw.js";
|
|
@@ -364,4 +364,4 @@ const we = T(function(e, r) {
|
|
|
364
364
|
export {
|
|
365
365
|
Ze as w
|
|
366
366
|
};
|
|
367
|
-
//# sourceMappingURL=withFormControl-
|
|
367
|
+
//# sourceMappingURL=withFormControl-Df9GvsWo.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"withFormControl-DePFf9SY.js","sources":["../../node_modules/@ark-ui/react/dist/components/field/field-error-text.js","../../node_modules/@ark-ui/react/dist/components/field/field-helper-text.js","../../node_modules/@ark-ui/react/dist/components/field/field-label.js","../../node_modules/@ark-ui/react/dist/utils/use-safe-layout-effect.js","../../node_modules/@ark-ui/react/dist/components/fieldset/use-fieldset-context.js","../../node_modules/@ark-ui/react/dist/components/field/use-field.js","../../node_modules/@ark-ui/react/dist/components/field/field-root.js","../../node_modules/@chakra-ui/react/dist/esm/components/icon/icon.js","../../node_modules/@chakra-ui/react/dist/esm/components/icon/create-icon.js","../../node_modules/@chakra-ui/react/dist/esm/components/field/field.js","../../src/hocs/withFormControl/withFormControl.records.ts","../../src/hocs/withFormControl/withFormControl.tsx"],"sourcesContent":["'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from './use-field-context.js';\n\nconst FieldErrorText = forwardRef((props, ref) => {\n const field = useFieldContext();\n const mergedProps = mergeProps(field.getErrorTextProps(), props);\n if (field?.invalid) {\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n }\n return null;\n});\nFieldErrorText.displayName = \"FieldErrorText\";\n\nexport { FieldErrorText };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from './use-field-context.js';\n\nconst FieldHelperText = forwardRef((props, ref) => {\n const field = useFieldContext();\n const mergedProps = mergeProps(field?.getHelperTextProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nFieldHelperText.displayName = \"FieldHelperText\";\n\nexport { FieldHelperText };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from './use-field-context.js';\n\nconst FieldLabel = forwardRef((props, ref) => {\n const field = useFieldContext();\n const mergedProps = mergeProps(field?.getLabelProps(), props);\n return /* @__PURE__ */ jsx(ark.label, { ...mergedProps, ref });\n});\nFieldLabel.displayName = \"FieldLabel\";\n\nexport { FieldLabel };\n","'use client';\nimport { useLayoutEffect, useEffect } from 'react';\n\nconst useSafeLayoutEffect = typeof window !== \"undefined\" ? useLayoutEffect : useEffect;\n\nexport { useSafeLayoutEffect };\n","'use client';\nimport { createContext } from '../../utils/create-context.js';\n\nconst [FieldsetProvider, useFieldsetContext] = createContext({\n name: \"FieldsetContext\",\n hookName: \"useFieldsetContext\",\n providerName: \"<FieldsetProvider />\",\n strict: false\n});\n\nexport { FieldsetProvider, useFieldsetContext };\n","'use client';\nimport { dataAttr, ariaAttr } from '@zag-js/dom-query';\nimport { useState, useId, useRef, useMemo } from 'react';\nimport { useEnvironmentContext } from '../../providers/environment/use-environment-context.js';\nimport { useSafeLayoutEffect } from '../../utils/use-safe-layout-effect.js';\nimport { useFieldsetContext } from '../fieldset/use-fieldset-context.js';\nimport { parts } from './field.anatomy.js';\n\nconst useField = (props = {}) => {\n const fieldset = useFieldsetContext();\n const env = useEnvironmentContext();\n const { ids, disabled = Boolean(fieldset?.disabled), invalid = false, readOnly = false, required = false } = props;\n const [hasErrorText, setHasErrorText] = useState(false);\n const [hasHelperText, setHasHelperText] = useState(false);\n const uid = useId();\n const id = props.id ?? uid;\n const rootRef = useRef(null);\n const rootId = ids?.control ?? `field::${id}`;\n const errorTextId = ids?.errorText ?? `field::${id}::error-text`;\n const helperTextId = ids?.helperText ?? `field::${id}::helper-text`;\n const labelId = ids?.label ?? `field::${id}::label`;\n useSafeLayoutEffect(() => {\n const rootNode = rootRef.current;\n if (!rootNode) return;\n const checkTextElements = () => {\n const docOrShadowRoot = env.getRootNode();\n setHasErrorText(!!docOrShadowRoot.getElementById(errorTextId));\n setHasHelperText(!!docOrShadowRoot.getElementById(helperTextId));\n };\n checkTextElements();\n const win = env.getWindow();\n const observer = new win.MutationObserver(checkTextElements);\n observer.observe(rootNode, { childList: true, subtree: true });\n return () => observer.disconnect();\n }, [env, errorTextId, helperTextId]);\n const labelIds = useMemo(() => {\n const ids2 = [];\n if (hasErrorText && invalid) ids2.push(errorTextId);\n if (hasHelperText) ids2.push(helperTextId);\n return ids2.join(\" \") || void 0;\n }, [invalid, errorTextId, helperTextId, hasErrorText, hasHelperText]);\n const getRootProps = useMemo(\n () => () => ({\n ...parts.root.attrs,\n id: rootId,\n ref: rootRef,\n role: \"group\",\n \"data-disabled\": dataAttr(disabled),\n \"data-invalid\": dataAttr(invalid),\n \"data-readonly\": dataAttr(readOnly)\n }),\n [disabled, invalid, readOnly, rootId]\n );\n const getLabelProps = useMemo(\n () => () => ({\n ...parts.label.attrs,\n id: labelId,\n \"data-disabled\": dataAttr(disabled),\n \"data-invalid\": dataAttr(invalid),\n \"data-readonly\": dataAttr(readOnly),\n htmlFor: id\n }),\n [disabled, invalid, readOnly, id, labelId]\n );\n const getControlProps = useMemo(\n () => () => ({\n \"aria-describedby\": labelIds,\n \"aria-invalid\": ariaAttr(invalid),\n \"data-invalid\": dataAttr(invalid),\n \"data-required\": dataAttr(required),\n \"data-readonly\": dataAttr(readOnly),\n id,\n required,\n disabled,\n readOnly\n }),\n [labelIds, invalid, required, readOnly, id, disabled]\n );\n const getInputProps = useMemo(\n () => () => ({\n ...getControlProps(),\n ...parts.input.attrs\n }),\n [getControlProps]\n );\n const getTextareaProps = useMemo(\n () => () => ({\n ...getControlProps(),\n ...parts.textarea.attrs\n }),\n [getControlProps]\n );\n const getSelectProps = useMemo(\n () => () => ({\n ...getControlProps(),\n ...parts.select.attrs\n }),\n [getControlProps]\n );\n const getHelperTextProps = useMemo(\n () => () => ({\n id: helperTextId,\n ...parts.helperText.attrs,\n \"data-disabled\": dataAttr(disabled)\n }),\n [disabled, helperTextId]\n );\n const getErrorTextProps = useMemo(\n () => () => ({\n id: errorTextId,\n ...parts.errorText.attrs,\n \"aria-live\": \"polite\"\n }),\n [errorTextId]\n );\n const getRequiredIndicatorProps = useMemo(\n () => () => ({\n \"aria-hidden\": true,\n ...parts.requiredIndicator.attrs\n }),\n []\n );\n return {\n ariaDescribedby: labelIds,\n ids: {\n root: rootId,\n control: id,\n label: labelId,\n errorText: errorTextId,\n helperText: helperTextId\n },\n refs: {\n rootRef\n },\n disabled,\n invalid,\n readOnly,\n required,\n getLabelProps,\n getRootProps,\n getInputProps,\n getTextareaProps,\n getSelectProps,\n getHelperTextProps,\n getErrorTextProps,\n getRequiredIndicatorProps\n };\n};\n\nexport { useField };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { composeRefs } from '../../utils/compose-refs.js';\nimport { createSplitProps } from '../../utils/create-split-props.js';\nimport { ark } from '../factory.js';\nimport { useField } from './use-field.js';\nimport { FieldProvider } from './use-field-context.js';\n\nconst FieldRoot = forwardRef((props, ref) => {\n const [useFieldProps, localProps] = createSplitProps()(props, [\n \"id\",\n \"ids\",\n \"disabled\",\n \"invalid\",\n \"readOnly\",\n \"required\"\n ]);\n const field = useField(useFieldProps);\n const mergedProps = mergeProps(field.getRootProps(), localProps);\n return /* @__PURE__ */ jsx(FieldProvider, { value: field, children: /* @__PURE__ */ jsx(ark.div, { ...mergedProps, ref: composeRefs(ref, field.refs.rootRef) }) });\n});\nFieldRoot.displayName = \"FieldRoot\";\n\nexport { FieldRoot };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport * as React from 'react';\nimport { cx } from '../../utils/cx.js';\nimport { createRecipeContext } from '../../styled-system/create-recipe-context.js';\nimport { chakra } from '../../styled-system/factory.js';\n\nconst { useRecipeResult, PropsProvider } = createRecipeContext({ key: \"icon\" });\nconst Icon = React.forwardRef(\n function Icon2(props, ref) {\n const {\n styles,\n className,\n props: otherProps\n } = useRecipeResult({ asChild: !props.as, ...props });\n return /* @__PURE__ */ jsx(\n chakra.svg,\n {\n ref,\n focusable: false,\n \"aria-hidden\": \"true\",\n ...otherProps,\n css: [styles, props.css],\n className: cx(className, props.className)\n }\n );\n }\n);\nconst IconPropsProvider = PropsProvider;\n\nexport { Icon, IconPropsProvider };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { Children, forwardRef } from 'react';\nimport { Icon } from './icon.js';\n\nfunction createIcon(options) {\n const {\n viewBox = \"0 0 24 24\",\n d: pathDefinition,\n displayName,\n defaultProps = {}\n } = options;\n const path = Children.toArray(options.path);\n const Comp = forwardRef((props, ref) => /* @__PURE__ */ jsx(\n Icon,\n {\n ref,\n asChild: false,\n viewBox,\n ...defaultProps,\n ...props,\n children: path.length ? path : /* @__PURE__ */ jsx(\"path\", { fill: \"currentColor\", d: pathDefinition })\n }\n ));\n Comp.displayName = displayName;\n return Comp;\n}\n\nexport { createIcon };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { Field, useFieldContext } from '@ark-ui/react/field';\nimport { forwardRef } from 'react';\nimport { cx } from '../../utils/cx.js';\nimport { createSlotRecipeContext } from '../../styled-system/create-slot-recipe-context.js';\nimport { chakra } from '../../styled-system/factory.js';\nimport { createIcon } from '../icon/create-icon.js';\n\nconst {\n withProvider,\n withContext,\n useStyles: useFieldStyles,\n useClassNames,\n PropsProvider\n} = createSlotRecipeContext({ key: \"field\" });\nconst FieldRoot = withProvider(\n Field.Root,\n \"root\",\n { forwardAsChild: true }\n);\nconst FieldPropsProvider = PropsProvider;\nconst FieldLabel = withContext(\n Field.Label,\n \"label\",\n { forwardAsChild: true }\n);\nconst FieldHelperText = withContext(Field.HelperText, \"helperText\", { forwardAsChild: true });\nconst FieldErrorText = withContext(\n Field.ErrorText,\n \"errorText\",\n { forwardAsChild: true }\n);\nconst FieldErrorIcon = createIcon({\n d: \"M11.983,0a12.206,12.206,0,0,0-8.51,3.653A11.8,11.8,0,0,0,0,12.207,11.779,11.779,0,0,0,11.8,24h.214A12.111,12.111,0,0,0,24,11.791h0A11.766,11.766,0,0,0,11.983,0ZM10.5,16.542a1.476,1.476,0,0,1,1.449-1.53h.027a1.527,1.527,0,0,1,1.523,1.47,1.475,1.475,0,0,1-1.449,1.53h-.027A1.529,1.529,0,0,1,10.5,16.542ZM11,12.5v-6a1,1,0,0,1,2,0v6a1,1,0,1,1-2,0Z\"\n});\nconst FieldRequiredIndicator = forwardRef(function RequiredIndicator(props, ref) {\n const { fallback, children = \"*\", ...restProps } = props;\n const field = useFieldContext();\n const classNames = useClassNames();\n const styles = useFieldStyles();\n if (!field?.required) {\n return fallback;\n }\n return /* @__PURE__ */ jsx(\n chakra.span,\n {\n ref,\n \"aria-hidden\": \"true\",\n ...restProps,\n className: cx(classNames.requiredIndicator, props.className),\n css: [styles.requiredIndicator, props.css],\n children\n }\n );\n});\n\nexport { FieldErrorIcon, FieldErrorText, FieldHelperText, FieldLabel, FieldPropsProvider, FieldRequiredIndicator, FieldRoot, useFieldStyles };\n","import { FormControlSize } from './withFormControl.types';\n\nexport const optionalTextSizeMap: Record<FormControlSize, number> = {\n sm: 10,\n md: 12,\n lg: 14,\n};\n","import React from 'react';\nimport { Field } from '@chakra-ui/react/field';\nimport { FormControlLabelPosition, FormControlSize } from './withFormControl.types';\nimport { SystemStyleObject } from '@chakra-ui/react/styled-system';\nimport { TypographyVariant } from 'shared/types/typography';\nimport { Text } from 'components/Text/text.component';\nimport { optionalTextSizeMap } from './withFormControl.records';\nimport { fontSizes } from 'theme/tokens/typography/typography.records';\nimport { Flex } from '@chakra-ui/react/flex';\nimport { Icon } from 'components/Icon/icon.component';\nimport { Box } from '@chakra-ui/react/box';\n\nexport interface WithFormControlProps {\n /** If true, the form control will be disabled.\n * @default false\n */\n disabled?: boolean;\n /** The error text to be displayed when the form control is invalid.\n * @default Field is invalid\n */\n errorText?: string;\n /** Props to customize the form control. */\n formControlStyle?: SystemStyleObject;\n /** If true, the form control will take the full width of its container.\n * @default true\n */\n fullWidth?: boolean;\n /** The helper text to be displayed below the form control. */\n helperText?: string;\n /** If true, the form control will be displayed inline with the label. */\n inlineField?: boolean;\n /** If true, the form control will be invalid.\n * @default false\n */\n invalid?: boolean;\n /** The variant of the invalid icon.\n * @default danger\n */\n invalidIconColor?: TypographyVariant;\n /** The label to be displayed above the form control. */\n label?: string | React.ReactNode;\n /** The position of the label relative to the form control.\n * @default start\n */\n labelPosition?: FormControlLabelPosition;\n /** Props to customize the label. */\n labelStyle?: SystemStyleObject;\n /** If true, the form control will be styled for contrast mode.\n * @default false\n */\n onContrast?: boolean;\n /** If true, the form element will be read only.\n * @default false\n */\n readOnly?: boolean;\n /** If true, the form control will be required.\n * @default false\n */\n required?: boolean;\n /** If true, the form control will show an optional text.\n * @default false\n */\n showOptionalElement?: boolean;\n /** The size of the form control.\n * @default md\n */\n size?: FormControlSize;\n /** If true, the form control will show an invalid icon.\n * @default false\n */\n useInvalidIcon?: boolean;\n /** If true, the form control will show an invalid text.\n * @default true\n */\n useInvalidText?: boolean;\n}\n\nexport const withFormControl = <P extends WithFormControlProps>(Component: React.ComponentType<P>): React.FC<P> => {\n const WithFormControl = ({\n disabled = false,\n errorText = 'Field is invalid',\n formControlStyle,\n fullWidth = true,\n helperText,\n inlineField = false,\n invalid = false,\n invalidIconColor = 'danger',\n label,\n labelPosition = 'start',\n labelStyle,\n onContrast = false,\n readOnly = false,\n required = false,\n showOptionalElement = false,\n size = 'md',\n useInvalidIcon = false,\n useInvalidText = true,\n ...props\n }: WithFormControlProps): React.JSX.Element => {\n const labelComponent = (\n <Field.Label\n className=\"FormControl__Label\"\n color={onContrast ? 'text.contrast' : 'text'}\n display=\"flex\"\n flexDirection=\"row\"\n gap={1}\n fontSize={fontSizes[size]}\n fontWeight=\"semibold\"\n {...labelStyle}\n onClick={(e) => {\n e.stopPropagation();\n }}\n >\n <Box as=\"span\">{label}</Box>\n <Field.RequiredIndicator\n className=\"FormControl__RequiredIndicator\"\n color={onContrast ? 'text.danger.contrast' : 'text.danger'}\n {...(!required && {\n fallback: showOptionalElement ? (\n <Text\n as=\"span\"\n variant={onContrast ? 'subtleOnContrast' : 'subtle'}\n fontSize={optionalTextSizeMap[size]}\n display=\"contents\"\n ml={1}\n >\n (Optional)\n </Text>\n ) : (\n <></>\n ),\n })}\n />\n </Field.Label>\n );\n\n return (\n <Field.Root\n className=\"FormControl group\"\n disabled={disabled}\n invalid={invalid}\n readOnly={readOnly}\n required={required}\n width={fullWidth ? '100%' : 'auto'}\n {...formControlStyle}\n >\n <Flex\n className=\"FormControl__Container\"\n flexDirection={inlineField ? 'row' : 'column'}\n w={inlineField ? 'max-content' : '100%'}\n gap={2}\n alignItems={inlineField ? 'center' : 'flex-start'}\n >\n {label && labelPosition === 'start' && labelComponent}\n <Flex className=\"FormControl__Content\" alignItems=\"center\" gap={2} w={inlineField ? 'max-content' : '100%'}>\n <Component\n disabled={disabled}\n invalid={invalid}\n onContrast={onContrast}\n readOnly={readOnly}\n required={required}\n size={size}\n {...(props as P)}\n />\n {useInvalidIcon && invalid && (\n <Icon className=\"FormControl__InvalidIcon\" name=\"warningSign\" variant={invalidIconColor} size={size} />\n )}\n </Flex>\n {label && labelPosition === 'end' && labelComponent}\n </Flex>\n {useInvalidText && invalid && (\n <Field.ErrorText\n className=\"FormControl__ErrorText\"\n fontSize=\"xs\"\n color={onContrast ? 'text.danger.contrast' : 'text.danger'}\n >\n {errorText}\n </Field.ErrorText>\n )}\n {helperText && (\n <Field.HelperText\n className=\"FormControl__HelperText\"\n fontSize=\"xs\"\n color={onContrast ? 'text.subtle.contrast' : 'text.subtle'}\n >\n {helperText}\n </Field.HelperText>\n )}\n </Field.Root>\n );\n };\n\n WithFormControl.displayName = `withFormControl(${Component.displayName || Component.name}`;\n return WithFormControl;\n};\n"],"names":["FieldErrorText","forwardRef","props","ref","field","useFieldContext","mergedProps","mergeProps","jsx","ark","FieldHelperText","FieldLabel","useSafeLayoutEffect","useLayoutEffect","useEffect","FieldsetProvider","useFieldsetContext","createContext","useField","fieldset","env","useEnvironmentContext","ids","disabled","invalid","readOnly","required","hasErrorText","setHasErrorText","useState","hasHelperText","setHasHelperText","uid","useId","id","rootRef","useRef","rootId","errorTextId","helperTextId","labelId","rootNode","checkTextElements","docOrShadowRoot","win","observer","labelIds","useMemo","ids2","getRootProps","parts","dataAttr","getLabelProps","getControlProps","ariaAttr","getInputProps","getTextareaProps","getSelectProps","getHelperTextProps","getErrorTextProps","getRequiredIndicatorProps","FieldRoot","useFieldProps","localProps","createSplitProps","FieldProvider","composeRefs","useRecipeResult","createRecipeContext","Icon","React","styles","className","otherProps","chakra","cx","createIcon","options","viewBox","pathDefinition","displayName","defaultProps","path","Children","Comp","withProvider","withContext","useFieldStyles","useClassNames","createSlotRecipeContext","Field.Root","Field.Label","Field.HelperText","Field.ErrorText","FieldRequiredIndicator","fallback","children","restProps","classNames","optionalTextSizeMap","withFormControl","Component","WithFormControl","errorText","formControlStyle","fullWidth","helperText","inlineField","invalidIconColor","label","labelPosition","labelStyle","onContrast","showOptionalElement","size","useInvalidIcon","useInvalidText","labelComponent","jsxs","fontSizes","e","Box","Field.RequiredIndicator","Text","Fragment","Flex"],"mappings":";;;;;;;;;;;;;;;AAOA,MAAMA,IAAiBC,EAAW,CAACC,GAAOC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AA,UAAA;AAAA,QACH;AAAA,MAAA;AAAA,IAEJ;AAAA,EAEJ;AAEA,SAAAJ,EAAgB,cAAc,mBAAmBD,EAAU,eAAeA,EAAU,IAAI,IACjFC;AACT;","x_google_ignoreList":[0,1,2,3,4,5,6,7,8,9]}
|
|
1
|
+
{"version":3,"file":"withFormControl-Df9GvsWo.js","sources":["../../node_modules/@ark-ui/react/dist/components/field/field-error-text.js","../../node_modules/@ark-ui/react/dist/components/field/field-helper-text.js","../../node_modules/@ark-ui/react/dist/components/field/field-label.js","../../node_modules/@ark-ui/react/dist/utils/use-safe-layout-effect.js","../../node_modules/@ark-ui/react/dist/components/fieldset/use-fieldset-context.js","../../node_modules/@ark-ui/react/dist/components/field/use-field.js","../../node_modules/@ark-ui/react/dist/components/field/field-root.js","../../node_modules/@chakra-ui/react/dist/esm/components/icon/icon.js","../../node_modules/@chakra-ui/react/dist/esm/components/icon/create-icon.js","../../node_modules/@chakra-ui/react/dist/esm/components/field/field.js","../../src/hocs/withFormControl/withFormControl.records.ts","../../src/hocs/withFormControl/withFormControl.tsx"],"sourcesContent":["'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from './use-field-context.js';\n\nconst FieldErrorText = forwardRef((props, ref) => {\n const field = useFieldContext();\n const mergedProps = mergeProps(field.getErrorTextProps(), props);\n if (field?.invalid) {\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n }\n return null;\n});\nFieldErrorText.displayName = \"FieldErrorText\";\n\nexport { FieldErrorText };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from './use-field-context.js';\n\nconst FieldHelperText = forwardRef((props, ref) => {\n const field = useFieldContext();\n const mergedProps = mergeProps(field?.getHelperTextProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nFieldHelperText.displayName = \"FieldHelperText\";\n\nexport { FieldHelperText };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from './use-field-context.js';\n\nconst FieldLabel = forwardRef((props, ref) => {\n const field = useFieldContext();\n const mergedProps = mergeProps(field?.getLabelProps(), props);\n return /* @__PURE__ */ jsx(ark.label, { ...mergedProps, ref });\n});\nFieldLabel.displayName = \"FieldLabel\";\n\nexport { FieldLabel };\n","'use client';\nimport { useLayoutEffect, useEffect } from 'react';\n\nconst useSafeLayoutEffect = typeof window !== \"undefined\" ? useLayoutEffect : useEffect;\n\nexport { useSafeLayoutEffect };\n","'use client';\nimport { createContext } from '../../utils/create-context.js';\n\nconst [FieldsetProvider, useFieldsetContext] = createContext({\n name: \"FieldsetContext\",\n hookName: \"useFieldsetContext\",\n providerName: \"<FieldsetProvider />\",\n strict: false\n});\n\nexport { FieldsetProvider, useFieldsetContext };\n","'use client';\nimport { dataAttr, ariaAttr } from '@zag-js/dom-query';\nimport { useState, useId, useRef, useMemo } from 'react';\nimport { useEnvironmentContext } from '../../providers/environment/use-environment-context.js';\nimport { useSafeLayoutEffect } from '../../utils/use-safe-layout-effect.js';\nimport { useFieldsetContext } from '../fieldset/use-fieldset-context.js';\nimport { parts } from './field.anatomy.js';\n\nconst useField = (props = {}) => {\n const fieldset = useFieldsetContext();\n const env = useEnvironmentContext();\n const { ids, disabled = Boolean(fieldset?.disabled), invalid = false, readOnly = false, required = false } = props;\n const [hasErrorText, setHasErrorText] = useState(false);\n const [hasHelperText, setHasHelperText] = useState(false);\n const uid = useId();\n const id = props.id ?? uid;\n const rootRef = useRef(null);\n const rootId = ids?.control ?? `field::${id}`;\n const errorTextId = ids?.errorText ?? `field::${id}::error-text`;\n const helperTextId = ids?.helperText ?? `field::${id}::helper-text`;\n const labelId = ids?.label ?? `field::${id}::label`;\n useSafeLayoutEffect(() => {\n const rootNode = rootRef.current;\n if (!rootNode) return;\n const checkTextElements = () => {\n const docOrShadowRoot = env.getRootNode();\n setHasErrorText(!!docOrShadowRoot.getElementById(errorTextId));\n setHasHelperText(!!docOrShadowRoot.getElementById(helperTextId));\n };\n checkTextElements();\n const win = env.getWindow();\n const observer = new win.MutationObserver(checkTextElements);\n observer.observe(rootNode, { childList: true, subtree: true });\n return () => observer.disconnect();\n }, [env, errorTextId, helperTextId]);\n const labelIds = useMemo(() => {\n const ids2 = [];\n if (hasErrorText && invalid) ids2.push(errorTextId);\n if (hasHelperText) ids2.push(helperTextId);\n return ids2.join(\" \") || void 0;\n }, [invalid, errorTextId, helperTextId, hasErrorText, hasHelperText]);\n const getRootProps = useMemo(\n () => () => ({\n ...parts.root.attrs,\n id: rootId,\n ref: rootRef,\n role: \"group\",\n \"data-disabled\": dataAttr(disabled),\n \"data-invalid\": dataAttr(invalid),\n \"data-readonly\": dataAttr(readOnly)\n }),\n [disabled, invalid, readOnly, rootId]\n );\n const getLabelProps = useMemo(\n () => () => ({\n ...parts.label.attrs,\n id: labelId,\n \"data-disabled\": dataAttr(disabled),\n \"data-invalid\": dataAttr(invalid),\n \"data-readonly\": dataAttr(readOnly),\n htmlFor: id\n }),\n [disabled, invalid, readOnly, id, labelId]\n );\n const getControlProps = useMemo(\n () => () => ({\n \"aria-describedby\": labelIds,\n \"aria-invalid\": ariaAttr(invalid),\n \"data-invalid\": dataAttr(invalid),\n \"data-required\": dataAttr(required),\n \"data-readonly\": dataAttr(readOnly),\n id,\n required,\n disabled,\n readOnly\n }),\n [labelIds, invalid, required, readOnly, id, disabled]\n );\n const getInputProps = useMemo(\n () => () => ({\n ...getControlProps(),\n ...parts.input.attrs\n }),\n [getControlProps]\n );\n const getTextareaProps = useMemo(\n () => () => ({\n ...getControlProps(),\n ...parts.textarea.attrs\n }),\n [getControlProps]\n );\n const getSelectProps = useMemo(\n () => () => ({\n ...getControlProps(),\n ...parts.select.attrs\n }),\n [getControlProps]\n );\n const getHelperTextProps = useMemo(\n () => () => ({\n id: helperTextId,\n ...parts.helperText.attrs,\n \"data-disabled\": dataAttr(disabled)\n }),\n [disabled, helperTextId]\n );\n const getErrorTextProps = useMemo(\n () => () => ({\n id: errorTextId,\n ...parts.errorText.attrs,\n \"aria-live\": \"polite\"\n }),\n [errorTextId]\n );\n const getRequiredIndicatorProps = useMemo(\n () => () => ({\n \"aria-hidden\": true,\n ...parts.requiredIndicator.attrs\n }),\n []\n );\n return {\n ariaDescribedby: labelIds,\n ids: {\n root: rootId,\n control: id,\n label: labelId,\n errorText: errorTextId,\n helperText: helperTextId\n },\n refs: {\n rootRef\n },\n disabled,\n invalid,\n readOnly,\n required,\n getLabelProps,\n getRootProps,\n getInputProps,\n getTextareaProps,\n getSelectProps,\n getHelperTextProps,\n getErrorTextProps,\n getRequiredIndicatorProps\n };\n};\n\nexport { useField };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { composeRefs } from '../../utils/compose-refs.js';\nimport { createSplitProps } from '../../utils/create-split-props.js';\nimport { ark } from '../factory.js';\nimport { useField } from './use-field.js';\nimport { FieldProvider } from './use-field-context.js';\n\nconst FieldRoot = forwardRef((props, ref) => {\n const [useFieldProps, localProps] = createSplitProps()(props, [\n \"id\",\n \"ids\",\n \"disabled\",\n \"invalid\",\n \"readOnly\",\n \"required\"\n ]);\n const field = useField(useFieldProps);\n const mergedProps = mergeProps(field.getRootProps(), localProps);\n return /* @__PURE__ */ jsx(FieldProvider, { value: field, children: /* @__PURE__ */ jsx(ark.div, { ...mergedProps, ref: composeRefs(ref, field.refs.rootRef) }) });\n});\nFieldRoot.displayName = \"FieldRoot\";\n\nexport { FieldRoot };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport * as React from 'react';\nimport { cx } from '../../utils/cx.js';\nimport { createRecipeContext } from '../../styled-system/create-recipe-context.js';\nimport { chakra } from '../../styled-system/factory.js';\n\nconst { useRecipeResult, PropsProvider } = createRecipeContext({ key: \"icon\" });\nconst Icon = React.forwardRef(\n function Icon2(props, ref) {\n const {\n styles,\n className,\n props: otherProps\n } = useRecipeResult({ asChild: !props.as, ...props });\n return /* @__PURE__ */ jsx(\n chakra.svg,\n {\n ref,\n focusable: false,\n \"aria-hidden\": \"true\",\n ...otherProps,\n css: [styles, props.css],\n className: cx(className, props.className)\n }\n );\n }\n);\nconst IconPropsProvider = PropsProvider;\n\nexport { Icon, IconPropsProvider };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { Children, forwardRef } from 'react';\nimport { Icon } from './icon.js';\n\nfunction createIcon(options) {\n const {\n viewBox = \"0 0 24 24\",\n d: pathDefinition,\n displayName,\n defaultProps = {}\n } = options;\n const path = Children.toArray(options.path);\n const Comp = forwardRef((props, ref) => /* @__PURE__ */ jsx(\n Icon,\n {\n ref,\n asChild: false,\n viewBox,\n ...defaultProps,\n ...props,\n children: path.length ? path : /* @__PURE__ */ jsx(\"path\", { fill: \"currentColor\", d: pathDefinition })\n }\n ));\n Comp.displayName = displayName;\n return Comp;\n}\n\nexport { createIcon };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { Field, useFieldContext } from '@ark-ui/react/field';\nimport { forwardRef } from 'react';\nimport { cx } from '../../utils/cx.js';\nimport { createSlotRecipeContext } from '../../styled-system/create-slot-recipe-context.js';\nimport { chakra } from '../../styled-system/factory.js';\nimport { createIcon } from '../icon/create-icon.js';\n\nconst {\n withProvider,\n withContext,\n useStyles: useFieldStyles,\n useClassNames,\n PropsProvider\n} = createSlotRecipeContext({ key: \"field\" });\nconst FieldRoot = withProvider(\n Field.Root,\n \"root\",\n { forwardAsChild: true }\n);\nconst FieldPropsProvider = PropsProvider;\nconst FieldLabel = withContext(\n Field.Label,\n \"label\",\n { forwardAsChild: true }\n);\nconst FieldHelperText = withContext(Field.HelperText, \"helperText\", { forwardAsChild: true });\nconst FieldErrorText = withContext(\n Field.ErrorText,\n \"errorText\",\n { forwardAsChild: true }\n);\nconst FieldErrorIcon = createIcon({\n d: \"M11.983,0a12.206,12.206,0,0,0-8.51,3.653A11.8,11.8,0,0,0,0,12.207,11.779,11.779,0,0,0,11.8,24h.214A12.111,12.111,0,0,0,24,11.791h0A11.766,11.766,0,0,0,11.983,0ZM10.5,16.542a1.476,1.476,0,0,1,1.449-1.53h.027a1.527,1.527,0,0,1,1.523,1.47,1.475,1.475,0,0,1-1.449,1.53h-.027A1.529,1.529,0,0,1,10.5,16.542ZM11,12.5v-6a1,1,0,0,1,2,0v6a1,1,0,1,1-2,0Z\"\n});\nconst FieldRequiredIndicator = forwardRef(function RequiredIndicator(props, ref) {\n const { fallback, children = \"*\", ...restProps } = props;\n const field = useFieldContext();\n const classNames = useClassNames();\n const styles = useFieldStyles();\n if (!field?.required) {\n return fallback;\n }\n return /* @__PURE__ */ jsx(\n chakra.span,\n {\n ref,\n \"aria-hidden\": \"true\",\n ...restProps,\n className: cx(classNames.requiredIndicator, props.className),\n css: [styles.requiredIndicator, props.css],\n children\n }\n );\n});\n\nexport { FieldErrorIcon, FieldErrorText, FieldHelperText, FieldLabel, FieldPropsProvider, FieldRequiredIndicator, FieldRoot, useFieldStyles };\n","import { FormControlSize } from './withFormControl.types';\n\nexport const optionalTextSizeMap: Record<FormControlSize, number> = {\n sm: 10,\n md: 12,\n lg: 14,\n};\n","import React from 'react';\nimport { Field } from '@chakra-ui/react/field';\nimport { FormControlLabelPosition, FormControlSize } from './withFormControl.types';\nimport { SystemStyleObject } from '@chakra-ui/react/styled-system';\nimport { TypographyVariant } from 'shared/types/typography';\nimport { Text } from 'components/Text/text.component';\nimport { optionalTextSizeMap } from './withFormControl.records';\nimport { fontSizes } from 'theme/tokens/typography/typography.records';\nimport { Flex } from '@chakra-ui/react/flex';\nimport { Icon } from 'components/Icon/icon.component';\nimport { Box } from '@chakra-ui/react/box';\n\nexport interface WithFormControlProps {\n /** If true, the form control will be disabled.\n * @default false\n */\n disabled?: boolean;\n /** The error text to be displayed when the form control is invalid.\n * @default Field is invalid\n */\n errorText?: string;\n /** Props to customize the form control. */\n formControlStyle?: SystemStyleObject;\n /** If true, the form control will take the full width of its container.\n * @default true\n */\n fullWidth?: boolean;\n /** The helper text to be displayed below the form control. */\n helperText?: string;\n /** If true, the form control will be displayed inline with the label. */\n inlineField?: boolean;\n /** If true, the form control will be invalid.\n * @default false\n */\n invalid?: boolean;\n /** The variant of the invalid icon.\n * @default danger\n */\n invalidIconColor?: TypographyVariant;\n /** The label to be displayed above the form control. */\n label?: string | React.ReactNode;\n /** The position of the label relative to the form control.\n * @default start\n */\n labelPosition?: FormControlLabelPosition;\n /** Props to customize the label. */\n labelStyle?: SystemStyleObject;\n /** If true, the form control will be styled for contrast mode.\n * @default false\n */\n onContrast?: boolean;\n /** If true, the form element will be read only.\n * @default false\n */\n readOnly?: boolean;\n /** If true, the form control will be required.\n * @default false\n */\n required?: boolean;\n /** If true, the form control will show an optional text.\n * @default false\n */\n showOptionalElement?: boolean;\n /** The size of the form control.\n * @default md\n */\n size?: FormControlSize;\n /** If true, the form control will show an invalid icon.\n * @default false\n */\n useInvalidIcon?: boolean;\n /** If true, the form control will show an invalid text.\n * @default true\n */\n useInvalidText?: boolean;\n}\n\nexport const withFormControl = <P extends WithFormControlProps>(Component: React.ComponentType<P>): React.FC<P> => {\n const WithFormControl = ({\n disabled = false,\n errorText = 'Field is invalid',\n formControlStyle,\n fullWidth = true,\n helperText,\n inlineField = false,\n invalid = false,\n invalidIconColor = 'danger',\n label,\n labelPosition = 'start',\n labelStyle,\n onContrast = false,\n readOnly = false,\n required = false,\n showOptionalElement = false,\n size = 'md',\n useInvalidIcon = false,\n useInvalidText = true,\n ...props\n }: WithFormControlProps): React.JSX.Element => {\n const labelComponent = (\n <Field.Label\n className=\"FormControl__Label\"\n color={onContrast ? 'text.contrast' : 'text'}\n display=\"flex\"\n flexDirection=\"row\"\n gap={1}\n fontSize={fontSizes[size]}\n fontWeight=\"semibold\"\n {...labelStyle}\n onClick={(e) => {\n e.stopPropagation();\n }}\n >\n <Box as=\"span\">{label}</Box>\n <Field.RequiredIndicator\n className=\"FormControl__RequiredIndicator\"\n color={onContrast ? 'text.danger.contrast' : 'text.danger'}\n {...(!required && {\n fallback: showOptionalElement ? (\n <Text\n as=\"span\"\n variant={onContrast ? 'subtleOnContrast' : 'subtle'}\n fontSize={optionalTextSizeMap[size]}\n display=\"contents\"\n ml={1}\n >\n (Optional)\n </Text>\n ) : (\n <></>\n ),\n })}\n />\n </Field.Label>\n );\n\n return (\n <Field.Root\n className=\"FormControl group\"\n disabled={disabled}\n invalid={invalid}\n readOnly={readOnly}\n required={required}\n width={fullWidth ? '100%' : 'auto'}\n {...formControlStyle}\n >\n <Flex\n className=\"FormControl__Container\"\n flexDirection={inlineField ? 'row' : 'column'}\n w={inlineField ? 'max-content' : '100%'}\n gap={2}\n alignItems={inlineField ? 'center' : 'flex-start'}\n >\n {label && labelPosition === 'start' && labelComponent}\n <Flex className=\"FormControl__Content\" alignItems=\"center\" gap={2} w={inlineField ? 'max-content' : '100%'}>\n <Component\n disabled={disabled}\n invalid={invalid}\n onContrast={onContrast}\n readOnly={readOnly}\n required={required}\n size={size}\n {...(props as P)}\n />\n {useInvalidIcon && invalid && (\n <Icon className=\"FormControl__InvalidIcon\" name=\"warningSign\" variant={invalidIconColor} size={size} />\n )}\n </Flex>\n {label && labelPosition === 'end' && labelComponent}\n </Flex>\n {useInvalidText && invalid && (\n <Field.ErrorText\n className=\"FormControl__ErrorText\"\n fontSize=\"xs\"\n color={onContrast ? 'text.danger.contrast' : 'text.danger'}\n >\n {errorText}\n </Field.ErrorText>\n )}\n {helperText && (\n <Field.HelperText\n className=\"FormControl__HelperText\"\n fontSize=\"xs\"\n color={onContrast ? 'text.subtle.contrast' : 'text.subtle'}\n >\n {helperText}\n </Field.HelperText>\n )}\n </Field.Root>\n );\n };\n\n WithFormControl.displayName = `withFormControl(${Component.displayName || Component.name}`;\n return WithFormControl;\n};\n"],"names":["FieldErrorText","forwardRef","props","ref","field","useFieldContext","mergedProps","mergeProps","jsx","ark","FieldHelperText","FieldLabel","useSafeLayoutEffect","useLayoutEffect","useEffect","FieldsetProvider","useFieldsetContext","createContext","useField","fieldset","env","useEnvironmentContext","ids","disabled","invalid","readOnly","required","hasErrorText","setHasErrorText","useState","hasHelperText","setHasHelperText","uid","useId","id","rootRef","useRef","rootId","errorTextId","helperTextId","labelId","rootNode","checkTextElements","docOrShadowRoot","win","observer","labelIds","useMemo","ids2","getRootProps","parts","dataAttr","getLabelProps","getControlProps","ariaAttr","getInputProps","getTextareaProps","getSelectProps","getHelperTextProps","getErrorTextProps","getRequiredIndicatorProps","FieldRoot","useFieldProps","localProps","createSplitProps","FieldProvider","composeRefs","useRecipeResult","createRecipeContext","Icon","React","styles","className","otherProps","chakra","cx","createIcon","options","viewBox","pathDefinition","displayName","defaultProps","path","Children","Comp","withProvider","withContext","useFieldStyles","useClassNames","createSlotRecipeContext","Field.Root","Field.Label","Field.HelperText","Field.ErrorText","FieldRequiredIndicator","fallback","children","restProps","classNames","optionalTextSizeMap","withFormControl","Component","WithFormControl","errorText","formControlStyle","fullWidth","helperText","inlineField","invalidIconColor","label","labelPosition","labelStyle","onContrast","showOptionalElement","size","useInvalidIcon","useInvalidText","labelComponent","jsxs","fontSizes","e","Box","Field.RequiredIndicator","Text","Fragment","Flex"],"mappings":";;;;;;;;;;;;;;;AAOA,MAAMA,IAAiBC,EAAW,CAACC,GAAOC,MAAQ;AAChD,QAAMC,IAAQC,EAAiB,GACzBC,IAAcC,EAAWH,EAAM,kBAAiB,GAAIF,CAAK;AAC/D,SAAIE,GAAO,UACcI,gBAAAA,EAAAA,IAAIC,EAAI,MAAM,EAAE,GAAGH,GAAa,KAAAH,GAAK,IAEvD;AACT,CAAC;AACDH,EAAe,cAAc;ACR7B,MAAMU,IAAkBT,EAAW,CAACC,GAAOC,MAA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("./index-BQRnVsAg.js"),_=require("./tooltip.component-
|
|
2
|
-
//# sourceMappingURL=withTruncation-
|
|
1
|
+
"use strict";const c=require("./jsx-runtime-BjDatQAs.js"),r=require("react"),j=require("./index-BQRnVsAg.js"),_=require("./tooltip.component-CIWQSrgZ.js"),g=e=>e&&e.__esModule?e:{default:e},k=g(r),d=e=>{if(typeof e=="string")return e;if(typeof e=="number"||typeof e=="boolean")return String(e);if(k.default.isValidElement(e)){const n=e;if(n.props.children)return d(n.props.children)}return Array.isArray(e)?e.map(d).join(" "):""},y=e=>{function n({truncated:l=!1,noOfLines:m=1,children:i,tooltipProps:a,["data-testid"]:o="kibble-truncated-text",...w}){const[p,b]=r.useState(!1),s=r.useRef(null),T=r.useRef(null),u=r.useRef(null),f=r.useCallback(()=>{if(!s.current)return;const t=s.current.children[0];if(!t)return;T.current=t;const x=t.scrollHeight>t.clientHeight;b(x)},[]);r.useEffect(()=>{if(!l)return;let t;const x=()=>{window.clearTimeout(t),t=window.setTimeout(f,100)},v=window.setTimeout(f,50);return s.current&&(u.current=new ResizeObserver(()=>{x()}),u.current.observe(s.current)),()=>{window.clearTimeout(t),window.clearTimeout(v),u.current&&u.current.disconnect()}},[l,f,i,m]);const R=r.useMemo(()=>a?.label||d(i),[i,a?.label]);return l?c.jsxRuntimeExports.jsx(_.Tooltip,{...a,label:R,disabled:!p,"data-testid":`${o}-tooltip`,children:c.jsxRuntimeExports.jsx(j.Box,{ref:s,width:"100%",minWidth:0,overflow:"hidden",flex:"1 1 auto",className:"TruncatedText__Wrapper","data-testid":`${o}-wrapper`,children:c.jsxRuntimeExports.jsx(e,{className:"TruncatedText__TextContent","data-testid":`${o}-content`,css:{display:"-webkit-box",WebkitBoxOrient:"vertical",WebkitLineClamp:m,overflow:"hidden",textOverflow:"ellipsis"},...w,children:i})})}):c.jsxRuntimeExports.jsx(e,{...w,"data-testid":o,children:i})}return n.displayName=`withTruncation(${e.displayName||e.name})`,n};exports.withTruncation=y;
|
|
2
|
+
//# sourceMappingURL=withTruncation-5g3W1Yem.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"withTruncation-
|
|
1
|
+
{"version":3,"file":"withTruncation-5g3W1Yem.js","sources":["../../src/hocs/withTruncation.tsx"],"sourcesContent":["import React, { ReactNode, useCallback, useEffect, useMemo, useRef, useState } from 'react';\nimport { Box } from '@chakra-ui/react/box';\nimport { Tooltip, TooltipProps } from 'components/Tooltip';\n\nexport interface WithTruncationProps {\n /** If true, the text will be truncated. */\n truncated?: boolean;\n /** The number of lines to truncate the text to. */\n noOfLines?: number;\n /** Props to customize the tooltip. See `Tooltip` for more information. */\n tooltipProps?: Omit<TooltipProps, 'disabled'>;\n /** The children to be displayed inside the truncated text. */\n children?: ReactNode | string;\n /** Data test id for the truncated text.\n * @default kibble-truncated-text\n */\n 'data-testid'?: string;\n}\n\n/**\n * Helper function to extract text content from ReactNode\n */\nconst getTextFromChildren = (children: ReactNode | string): string => {\n if (typeof children === 'string') {\n return children;\n }\n if (typeof children === 'number' || typeof children === 'boolean') {\n return String(children);\n }\n if (React.isValidElement(children)) {\n const element = children as React.ReactElement<{ children?: ReactNode }>;\n if (element.props.children) {\n return getTextFromChildren(element.props.children);\n }\n }\n if (Array.isArray(children)) {\n return children.map(getTextFromChildren).join(' ');\n }\n return '';\n};\n\nexport const withTruncation = <P extends WithTruncationProps>(Component: React.ComponentType<P>): React.FC<P> => {\n function WithTruncation({\n truncated = false,\n noOfLines = 1,\n children,\n tooltipProps,\n ['data-testid']: dataTestId = 'kibble-truncated-text',\n ...rest\n }: WithTruncationProps): React.JSX.Element {\n const [isTextOverFlowing, setIsTextOverFlowing] = useState<boolean>(false);\n const containerRef = useRef<HTMLDivElement>(null);\n const textElementRef = useRef<HTMLElement | null>(null);\n const resizeObserverRef = useRef<ResizeObserver | null>(null);\n\n const checkOverflow = useCallback(() => {\n if (!containerRef.current) return;\n\n // Get the actual text element (first child)\n const textElement = containerRef.current.children[0] as HTMLElement;\n if (!textElement) return;\n\n textElementRef.current = textElement;\n\n // Check if text is overflowing\n const isOverflowing = textElement.scrollHeight > textElement.clientHeight;\n setIsTextOverFlowing(isOverflowing);\n }, []);\n\n useEffect(() => {\n if (!truncated) return;\n\n let timeoutId: number;\n\n const debouncedCheck = (): void => {\n window.clearTimeout(timeoutId);\n timeoutId = window.setTimeout(checkOverflow, 100);\n };\n\n // Initial check with a slight delay to ensure rendering is complete\n const initialCheckTimeout = window.setTimeout(checkOverflow, 50);\n\n // Observe the container for resize events\n if (containerRef.current) {\n resizeObserverRef.current = new ResizeObserver(() => {\n debouncedCheck();\n });\n resizeObserverRef.current.observe(containerRef.current);\n }\n\n return (): void => {\n window.clearTimeout(timeoutId);\n window.clearTimeout(initialCheckTimeout);\n if (resizeObserverRef.current) {\n resizeObserverRef.current.disconnect();\n }\n };\n }, [truncated, checkOverflow, children, noOfLines]);\n\n const tooltipLabel = useMemo(\n () => tooltipProps?.label || getTextFromChildren(children),\n [children, tooltipProps?.label],\n );\n\n if (!truncated) {\n return (\n <Component {...(rest as P)} data-testid={dataTestId}>\n {children}\n </Component>\n );\n }\n\n return (\n <Tooltip\n {...tooltipProps}\n label={tooltipLabel}\n disabled={!isTextOverFlowing}\n data-testid={`${dataTestId}-tooltip`}\n >\n <Box\n ref={containerRef}\n width=\"100%\"\n minWidth={0}\n overflow=\"hidden\"\n flex=\"1 1 auto\"\n className=\"TruncatedText__Wrapper\"\n data-testid={`${dataTestId}-wrapper`}\n >\n <Component\n className=\"TruncatedText__TextContent\"\n data-testid={`${dataTestId}-content`}\n css={{\n display: '-webkit-box',\n WebkitBoxOrient: 'vertical',\n WebkitLineClamp: noOfLines,\n overflow: 'hidden',\n textOverflow: 'ellipsis',\n }}\n {...(rest as P)}\n >\n {children}\n </Component>\n </Box>\n </Tooltip>\n );\n }\n\n WithTruncation.displayName = `withTruncation(${Component.displayName || Component.name})`;\n return WithTruncation;\n};\n"],"names":["getTextFromChildren","children","React","element","withTruncation","Component","WithTruncation","truncated","noOfLines","tooltipProps","dataTestId","rest","isTextOverFlowing","setIsTextOverFlowing","useState","containerRef","useRef","textElementRef","resizeObserverRef","checkOverflow","useCallback","textElement","isOverflowing","useEffect","timeoutId","debouncedCheck","initialCheckTimeout","tooltipLabel","useMemo","jsx","Tooltip","Box"],"mappings":"qMAsBMA,EAAuBC,GAAyC,CAChE,GAAA,OAAOA,GAAa,SACf,OAAAA,EAET,GAAI,OAAOA,GAAa,UAAY,OAAOA,GAAa,UACtD,OAAO,OAAOA,CAAQ,EAEpB,GAAAC,EAAA,QAAM,eAAeD,CAAQ,EAAG,CAClC,MAAME,EAAUF,EACZ,GAAAE,EAAQ,MAAM,SACT,OAAAH,EAAoBG,EAAQ,MAAM,QAAQ,CACnD,CAEE,OAAA,MAAM,QAAQF,CAAQ,EACjBA,EAAS,IAAID,CAAmB,EAAE,KAAK,GAAG,EAE5C,EACT,EAEaI,EAAiDC,GAAmD,CAC/G,SAASC,EAAe,CACtB,UAAAC,EAAY,GACZ,UAAAC,EAAY,EACZ,SAAAP,EACA,aAAAQ,EACA,CAAC,aAAa,EAAGC,EAAa,wBAC9B,GAAGC,CAAA,EACsC,CACzC,KAAM,CAACC,EAAmBC,CAAoB,EAAIC,EAAAA,SAAkB,EAAK,EACnEC,EAAeC,SAAuB,IAAI,EAC1CC,EAAiBD,SAA2B,IAAI,EAChDE,EAAoBF,SAA8B,IAAI,EAEtDG,EAAgBC,EAAAA,YAAY,IAAM,CAClC,GAAA,CAACL,EAAa,QAAS,OAG3B,MAAMM,EAAcN,EAAa,QAAQ,SAAS,CAAC,EACnD,GAAI,CAACM,EAAa,OAElBJ,EAAe,QAAUI,EAGnB,MAAAC,EAAgBD,EAAY,aAAeA,EAAY,aAC7DR,EAAqBS,CAAa,CACpC,EAAG,EAAE,EAELC,EAAAA,UAAU,IAAM,CACd,GAAI,CAAChB,EAAW,OAEZ,IAAAiB,EAEJ,MAAMC,EAAiB,IAAY,CACjC,OAAO,aAAaD,CAAS,EACjBA,EAAA,OAAO,WAAWL,EAAe,GAAG,CAClD,EAGMO,EAAsB,OAAO,WAAWP,EAAe,EAAE,EAG/D,OAAIJ,EAAa,UACGG,EAAA,QAAU,IAAI,eAAe,IAAM,CACpCO,EAAA,CAAA,CAChB,EACiBP,EAAA,QAAQ,QAAQH,EAAa,OAAO,GAGjD,IAAY,CACjB,OAAO,aAAaS,CAAS,EAC7B,OAAO,aAAaE,CAAmB,EACnCR,EAAkB,SACpBA,EAAkB,QAAQ,WAAW,CAEzC,GACC,CAACX,EAAWY,EAAelB,EAAUO,CAAS,CAAC,EAElD,MAAMmB,EAAeC,EAAA,QACnB,IAAMnB,GAAc,OAAST,EAAoBC,CAAQ,EACzD,CAACA,EAAUQ,GAAc,KAAK,CAChC,EAEA,OAAKF,EASHsB,EAAA,kBAAA,IAACC,EAAA,QAAA,CACE,GAAGrB,EACJ,MAAOkB,EACP,SAAU,CAACf,EACX,cAAa,GAAGF,CAAU,WAE1B,SAAAmB,EAAA,kBAAA,IAACE,EAAA,IAAA,CACC,IAAKhB,EACL,MAAM,OACN,SAAU,EACV,SAAS,SACT,KAAK,WACL,UAAU,yBACV,cAAa,GAAGL,CAAU,WAE1B,SAAAmB,EAAA,kBAAA,IAACxB,EAAA,CACC,UAAU,6BACV,cAAa,GAAGK,CAAU,WAC1B,IAAK,CACH,QAAS,cACT,gBAAiB,WACjB,gBAAiBF,EACjB,SAAU,SACV,aAAc,UAChB,EACC,GAAIG,EAEJ,SAAAV,CAAA,CAAA,CACH,CAAA,CACF,CACF,0BArCGI,EAAW,CAAA,GAAIM,EAAY,cAAaD,EACtC,SAAAT,EACH,CAmCF,CAIJ,OAAAK,EAAe,YAAc,kBAAkBD,EAAU,aAAeA,EAAU,IAAI,IAC/EC,CACT"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { j as a } from "./jsx-runtime-C5mzlN2N.js";
|
|
2
2
|
import k, { useState as y, useRef as m, useCallback as j, useEffect as O, useMemo as R } from "react";
|
|
3
3
|
import { B as h } from "./index-9BerxEcw.js";
|
|
4
|
-
import { T as _ } from "./tooltip.component-
|
|
4
|
+
import { T as _ } from "./tooltip.component-B2kgm41E.js";
|
|
5
5
|
const w = (e) => {
|
|
6
6
|
if (typeof e == "string")
|
|
7
7
|
return e;
|
|
@@ -89,4 +89,4 @@ const w = (e) => {
|
|
|
89
89
|
export {
|
|
90
90
|
B as w
|
|
91
91
|
};
|
|
92
|
-
//# sourceMappingURL=withTruncation-
|
|
92
|
+
//# sourceMappingURL=withTruncation-B-Li8sxr.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"withTruncation-
|
|
1
|
+
{"version":3,"file":"withTruncation-B-Li8sxr.js","sources":["../../src/hocs/withTruncation.tsx"],"sourcesContent":["import React, { ReactNode, useCallback, useEffect, useMemo, useRef, useState } from 'react';\nimport { Box } from '@chakra-ui/react/box';\nimport { Tooltip, TooltipProps } from 'components/Tooltip';\n\nexport interface WithTruncationProps {\n /** If true, the text will be truncated. */\n truncated?: boolean;\n /** The number of lines to truncate the text to. */\n noOfLines?: number;\n /** Props to customize the tooltip. See `Tooltip` for more information. */\n tooltipProps?: Omit<TooltipProps, 'disabled'>;\n /** The children to be displayed inside the truncated text. */\n children?: ReactNode | string;\n /** Data test id for the truncated text.\n * @default kibble-truncated-text\n */\n 'data-testid'?: string;\n}\n\n/**\n * Helper function to extract text content from ReactNode\n */\nconst getTextFromChildren = (children: ReactNode | string): string => {\n if (typeof children === 'string') {\n return children;\n }\n if (typeof children === 'number' || typeof children === 'boolean') {\n return String(children);\n }\n if (React.isValidElement(children)) {\n const element = children as React.ReactElement<{ children?: ReactNode }>;\n if (element.props.children) {\n return getTextFromChildren(element.props.children);\n }\n }\n if (Array.isArray(children)) {\n return children.map(getTextFromChildren).join(' ');\n }\n return '';\n};\n\nexport const withTruncation = <P extends WithTruncationProps>(Component: React.ComponentType<P>): React.FC<P> => {\n function WithTruncation({\n truncated = false,\n noOfLines = 1,\n children,\n tooltipProps,\n ['data-testid']: dataTestId = 'kibble-truncated-text',\n ...rest\n }: WithTruncationProps): React.JSX.Element {\n const [isTextOverFlowing, setIsTextOverFlowing] = useState<boolean>(false);\n const containerRef = useRef<HTMLDivElement>(null);\n const textElementRef = useRef<HTMLElement | null>(null);\n const resizeObserverRef = useRef<ResizeObserver | null>(null);\n\n const checkOverflow = useCallback(() => {\n if (!containerRef.current) return;\n\n // Get the actual text element (first child)\n const textElement = containerRef.current.children[0] as HTMLElement;\n if (!textElement) return;\n\n textElementRef.current = textElement;\n\n // Check if text is overflowing\n const isOverflowing = textElement.scrollHeight > textElement.clientHeight;\n setIsTextOverFlowing(isOverflowing);\n }, []);\n\n useEffect(() => {\n if (!truncated) return;\n\n let timeoutId: number;\n\n const debouncedCheck = (): void => {\n window.clearTimeout(timeoutId);\n timeoutId = window.setTimeout(checkOverflow, 100);\n };\n\n // Initial check with a slight delay to ensure rendering is complete\n const initialCheckTimeout = window.setTimeout(checkOverflow, 50);\n\n // Observe the container for resize events\n if (containerRef.current) {\n resizeObserverRef.current = new ResizeObserver(() => {\n debouncedCheck();\n });\n resizeObserverRef.current.observe(containerRef.current);\n }\n\n return (): void => {\n window.clearTimeout(timeoutId);\n window.clearTimeout(initialCheckTimeout);\n if (resizeObserverRef.current) {\n resizeObserverRef.current.disconnect();\n }\n };\n }, [truncated, checkOverflow, children, noOfLines]);\n\n const tooltipLabel = useMemo(\n () => tooltipProps?.label || getTextFromChildren(children),\n [children, tooltipProps?.label],\n );\n\n if (!truncated) {\n return (\n <Component {...(rest as P)} data-testid={dataTestId}>\n {children}\n </Component>\n );\n }\n\n return (\n <Tooltip\n {...tooltipProps}\n label={tooltipLabel}\n disabled={!isTextOverFlowing}\n data-testid={`${dataTestId}-tooltip`}\n >\n <Box\n ref={containerRef}\n width=\"100%\"\n minWidth={0}\n overflow=\"hidden\"\n flex=\"1 1 auto\"\n className=\"TruncatedText__Wrapper\"\n data-testid={`${dataTestId}-wrapper`}\n >\n <Component\n className=\"TruncatedText__TextContent\"\n data-testid={`${dataTestId}-content`}\n css={{\n display: '-webkit-box',\n WebkitBoxOrient: 'vertical',\n WebkitLineClamp: noOfLines,\n overflow: 'hidden',\n textOverflow: 'ellipsis',\n }}\n {...(rest as P)}\n >\n {children}\n </Component>\n </Box>\n </Tooltip>\n );\n }\n\n WithTruncation.displayName = `withTruncation(${Component.displayName || Component.name})`;\n return WithTruncation;\n};\n"],"names":["getTextFromChildren","children","React","element","withTruncation","Component","WithTruncation","truncated","noOfLines","tooltipProps","dataTestId","rest","isTextOverFlowing","setIsTextOverFlowing","useState","containerRef","useRef","textElementRef","resizeObserverRef","checkOverflow","useCallback","textElement","isOverflowing","useEffect","timeoutId","debouncedCheck","initialCheckTimeout","tooltipLabel","useMemo","jsx","Tooltip","Box"],"mappings":";;;;AAsBA,MAAMA,IAAsB,CAACC,MAAyC;AAChE,MAAA,OAAOA,KAAa;AACf,WAAAA;AAET,MAAI,OAAOA,KAAa,YAAY,OAAOA,KAAa;AACtD,WAAO,OAAOA,CAAQ;AAEpB,MAAAC,EAAM,eAAeD,CAAQ,GAAG;AAClC,UAAME,IAAUF;AACZ,QAAAE,EAAQ,MAAM;AACT,aAAAH,EAAoBG,EAAQ,MAAM,QAAQ;AAAA,EACnD;AAEE,SAAA,MAAM,QAAQF,CAAQ,IACjBA,EAAS,IAAID,CAAmB,EAAE,KAAK,GAAG,IAE5C;AACT,GAEaI,IAAiB,CAAgCC,MAAmD;AAC/G,WAASC,EAAe;AAAA,IACtB,WAAAC,IAAY;AAAA,IACZ,WAAAC,IAAY;AAAA,IACZ,UAAAP;AAAA,IACA,cAAAQ;AAAA,IACA,CAAC,aAAa,GAAGC,IAAa;AAAA,IAC9B,GAAGC;AAAA,EAAA,GACsC;AACzC,UAAM,CAACC,GAAmBC,CAAoB,IAAIC,EAAkB,EAAK,GACnEC,IAAeC,EAAuB,IAAI,GAC1CC,IAAiBD,EAA2B,IAAI,GAChDE,IAAoBF,EAA8B,IAAI,GAEt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A,YAE1B,UAAAmB,gBAAAA,EAAA;AAAA,cAACxB;AAAA,cAAA;AAAA,gBACC,WAAU;AAAA,gBACV,eAAa,GAAGK,CAAU;AAAA,gBAC1B,KAAK;AAAA,kBACH,SAAS;AAAA,kBACT,iBAAiB;AAAA,kBACjB,iBAAiBF;AAAA,kBACjB,UAAU;AAAA,kBACV,cAAc;AAAA,gBAChB;AAAA,gBACC,GAAIG;AAAA,gBAEJ,UAAAV;AAAA,cAAA;AAAA,YAAA;AAAA,UACH;AAAA,QAAA;AAAA,MACF;AAAA,IACF,0BArCGI,GAAW,EAAA,GAAIM,GAAY,eAAaD,GACtC,UAAAT,GACH;AAAA,EAmCF;AAIJ,SAAAK,EAAe,cAAc,kBAAkBD,EAAU,eAAeA,EAAU,IAAI,KAC/EC;AACT;"}
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../../../chunks/alert.types-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../../../chunks/alert.types-CoNGMaZH.js");exports.Alert=t.Alert;exports.alertButtonPositions=t.alertButtonPositions;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../../../chunks/avatar.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../../../chunks/avatar.component-jnCAquFm.js"),a=require("../../../chunks/avatar.types-Bmt5Uhfb.js");exports.Avatar=t.Avatar;exports.avatarSizes=a.avatarSizes;exports.avatarVariants=a.avatarVariants;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../../../chunks/avatarGroup.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("../../../chunks/avatarGroup.component-CDfF7iXF.js");exports.AvatarGroup=r.AvatarGroup;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../../../chunks/buttonGroup.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../../../chunks/buttonGroup.component-QIrJOCDP.js");exports.ButtonGroup=t.ButtonGroup;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/calendar.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/calendar.component-CRXFd2qS.js");exports.Calendar=e.Calendar;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/characterCounter.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/characterCounter.component-Bx1KJdtW.js");exports.CharacterCounter=e.CharacterCounter;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/checkbox.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/checkbox.component-BxH9UuK7.js");exports.Checkbox=e.WrappedCheckbox;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/checkboxGroup.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/checkboxGroup.component-xqwBFmT_.js");exports.CheckboxGroup=e.WrappedCheckboxGroup;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/conversationCard.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/conversationCard.component-DuPS_G4j.js");exports.ConversationCard=e.ConversationCard;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/datePicker.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/datePicker.component-txR_j1pV.js"),t=require("../../../chunks/datePicker.provider-WuyAKvhT.js");exports.DatePicker=e.DatePicker;exports.DateFormats=t.DateFormats;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/dateTimePicker.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/dateTimePicker.component-XY7Hjy5a.js");exports.DateTimePicker=e.DateTimePicker;exports.DateTimePickerDefaultOptionValue=e.DateTimePickerDefaultOptionValue;exports.calendarViews=e.calendarViews;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/heading.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/heading.component-CuqmU4-A.js");exports.Heading=e.WrappedHeading;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/menu.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/menu.component-Ca7XKva4.js");exports.Menu=e.Menu;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../../chunks/modal.types-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../../chunks/modal.types-CC5_2AVY.js");exports.Modal=o.Modal;exports.modalMotionPresets=o.modalMotionPresets;exports.modalPlacements=o.modalPlacements;exports.modalScrollBehaviors=o.modalScrollBehaviors;exports.modalSizes=o.modalSizes;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("../../../chunks/notificationCounter.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const i=require("../../../chunks/notificationCounter.component-iPVVGxGV.js"),t=require("../../../chunks/notificationCounter.types-B_-siNfi.js");exports.NotificationCounter=i.NotificationCounter;exports.notificationCounterSizes=t.notificationCounterSizes;exports.notificationCounterVariants=t.notificationCounterVariants;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/numberInput.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/numberInput.component-DO9D-2yL.js");exports.NumberInput=e.WrappedNumberInput;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("../../../chunks/pinInput.types-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const p=require("../../../chunks/pinInput.types-Cg82OPA7.js");exports.PinInput=p.WrappedPinInput;exports.pinInputTypes=p.pinInputTypes;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../../chunks/popover.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const o=require("../../../chunks/popover.component-BsAhqfsU.js"),e=require("../../../chunks/popover.types-ChA9ccQ2.js");exports.Popover=o.Popover;exports.popoverSizes=e.popoverSizes;exports.popoverTriggerTypes=e.popoverTriggerTypes;exports.popoverVariants=e.popoverVariants;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/radioGroup.types-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/radioGroup.types-F8vVdEOh.js");exports.RadioGroup=e.WrappedRadioGroup;exports.radioAlignments=e.radioAlignments;exports.radioTypes=e.radioTypes;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/rating.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/rating.component-CQD7qSs1.js");exports.Rating=e.WrappedRating;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../../../chunks/ratingDots.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../../../chunks/ratingDots.component-Da9isjMP.js");exports.RatingDots=t.WrappedRatingDots;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/select.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("../../../chunks/select.component-HZ3Lf1R2.js");exports.Select=e.WrappedSelect;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../../../chunks/sortableList.component-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const t=require("../../../chunks/sortableList.component-BuPCQuzG.js");exports.SortableList=t.SortableList;
|
|
2
2
|
//# sourceMappingURL=index.cjs.map
|