@commercetools/nimbus 3.3.0 → 3.4.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.
Files changed (648) hide show
  1. package/dist/chunks/{Button-FcraQeen.esm.js → Button-B5g2BgY8.esm.js} +2 -2
  2. package/dist/chunks/{Button-FcraQeen.esm.js.map → Button-B5g2BgY8.esm.js.map} +1 -1
  3. package/dist/chunks/{Button-z5JjDtpy.cjs → Button-CZDjIKB1.cjs} +2 -2
  4. package/dist/chunks/{Button-z5JjDtpy.cjs.map → Button-CZDjIKB1.cjs.map} +1 -1
  5. package/dist/chunks/{Calendar-1qYv3Pn9.cjs → Calendar-B-gzTAl8.cjs} +2 -2
  6. package/dist/chunks/{Calendar-1qYv3Pn9.cjs.map → Calendar-B-gzTAl8.cjs.map} +1 -1
  7. package/dist/chunks/{Calendar-oiqHeWzY.esm.js → Calendar-B6F41FfL.esm.js} +2 -2
  8. package/dist/chunks/{Calendar-oiqHeWzY.esm.js.map → Calendar-B6F41FfL.esm.js.map} +1 -1
  9. package/dist/chunks/Collection-CgMG1nwQ.esm.js +53 -0
  10. package/dist/chunks/Collection-CgMG1nwQ.esm.js.map +1 -0
  11. package/dist/chunks/Collection-yMt_pwdK.cjs +2 -0
  12. package/dist/chunks/Collection-yMt_pwdK.cjs.map +1 -0
  13. package/dist/chunks/DateField-CHfV6zH4.cjs +2 -0
  14. package/dist/chunks/{DateField-DI1RhZqo.cjs.map → DateField-CHfV6zH4.cjs.map} +1 -1
  15. package/dist/chunks/{DateField-DUetJOyf.esm.js → DateField-C_r7fpt5.esm.js} +49 -48
  16. package/dist/chunks/{DateField-DUetJOyf.esm.js.map → DateField-C_r7fpt5.esm.js.map} +1 -1
  17. package/dist/chunks/{DatePicker-DRwvjTID.cjs → DatePicker--pX-2Qq-.cjs} +2 -2
  18. package/dist/chunks/{DatePicker-DRwvjTID.cjs.map → DatePicker--pX-2Qq-.cjs.map} +1 -1
  19. package/dist/chunks/{DatePicker-DeVufONT.esm.js → DatePicker-xQCOjOZ5.esm.js} +6 -6
  20. package/dist/chunks/{DatePicker-DeVufONT.esm.js.map → DatePicker-xQCOjOZ5.esm.js.map} +1 -1
  21. package/dist/chunks/{Dialog-tQOfG_On.esm.js → Dialog-Dy3vyR1i.esm.js} +488 -487
  22. package/dist/chunks/{Dialog-tQOfG_On.esm.js.map → Dialog-Dy3vyR1i.esm.js.map} +1 -1
  23. package/dist/chunks/Dialog-UjK50qiN.cjs +6 -0
  24. package/dist/chunks/{Dialog-s5tFTj72.cjs.map → Dialog-UjK50qiN.cjs.map} +1 -1
  25. package/dist/chunks/{Header-Cmmm6XZs.cjs → Header-Bp89-vFq.cjs} +2 -2
  26. package/dist/chunks/{Header-Cmmm6XZs.cjs.map → Header-Bp89-vFq.cjs.map} +1 -1
  27. package/dist/chunks/{Header-CdFIlJp5.esm.js → Header-CwBpRO8i.esm.js} +2 -2
  28. package/dist/chunks/{Header-CdFIlJp5.esm.js.map → Header-CwBpRO8i.esm.js.map} +1 -1
  29. package/dist/chunks/Link-BmoXcCA3.cjs +2 -0
  30. package/dist/chunks/Link-BmoXcCA3.cjs.map +1 -0
  31. package/dist/chunks/Link-D_CNmmCC.esm.js +41 -0
  32. package/dist/chunks/Link-D_CNmmCC.esm.js.map +1 -0
  33. package/dist/chunks/{ListBox-DlI6zwM7.esm.js → ListBox-B8JwiURT.esm.js} +62 -61
  34. package/dist/chunks/{ListBox-DlI6zwM7.esm.js.map → ListBox-B8JwiURT.esm.js.map} +1 -1
  35. package/dist/chunks/ListBox-Ccgvv13w.cjs +2 -0
  36. package/dist/chunks/{ListBox-CXgfDQSn.cjs.map → ListBox-Ccgvv13w.cjs.map} +1 -1
  37. package/dist/chunks/{Modal-BG58sEN8.esm.js → Modal-B0a1NTkk.esm.js} +3 -3
  38. package/dist/chunks/{Modal-BG58sEN8.esm.js.map → Modal-B0a1NTkk.esm.js.map} +1 -1
  39. package/dist/chunks/{Modal-B5d_4wBp.cjs → Modal-BhGqV2ga.cjs} +2 -2
  40. package/dist/chunks/{Modal-B5d_4wBp.cjs.map → Modal-BhGqV2ga.cjs.map} +1 -1
  41. package/dist/chunks/{ProgressBar-BleovkZ3.esm.js → ProgressBar-6_KRPPYN.esm.js} +2 -2
  42. package/dist/chunks/{ProgressBar-BleovkZ3.esm.js.map → ProgressBar-6_KRPPYN.esm.js.map} +1 -1
  43. package/dist/chunks/{ProgressBar-DAbyWfVX.cjs → ProgressBar-nd1ahEJC.cjs} +2 -2
  44. package/dist/chunks/{ProgressBar-DAbyWfVX.cjs.map → ProgressBar-nd1ahEJC.cjs.map} +1 -1
  45. package/dist/chunks/{accordion-BYfM5qEG.cjs → accordion-BJQKQHIG.cjs} +2 -2
  46. package/dist/chunks/{accordion-BYfM5qEG.cjs.map → accordion-BJQKQHIG.cjs.map} +1 -1
  47. package/dist/chunks/{accordion-BqlBCwmN.esm.js → accordion-DPnhySdl.esm.js} +2 -2
  48. package/dist/chunks/{accordion-BqlBCwmN.esm.js.map → accordion-DPnhySdl.esm.js.map} +1 -1
  49. package/dist/chunks/{alert-C4J2fv__.esm.js → alert-Coz95VgD.esm.js} +2 -2
  50. package/dist/chunks/{alert-C4J2fv__.esm.js.map → alert-Coz95VgD.esm.js.map} +1 -1
  51. package/dist/chunks/{alert-BeQzAjMf.cjs → alert-GP75E0QV.cjs} +2 -2
  52. package/dist/chunks/{alert-BeQzAjMf.cjs.map → alert-GP75E0QV.cjs.map} +1 -1
  53. package/dist/chunks/breadcrumbs-1MAxlCTS.esm.js +322 -0
  54. package/dist/chunks/breadcrumbs-1MAxlCTS.esm.js.map +1 -0
  55. package/dist/chunks/breadcrumbs-TP5PrTuN.cjs +2 -0
  56. package/dist/chunks/breadcrumbs-TP5PrTuN.cjs.map +1 -0
  57. package/dist/chunks/{button-Dc_J_PNN.cjs → button-D6f5OX0h.cjs} +2 -2
  58. package/dist/chunks/{button-Dc_J_PNN.cjs.map → button-D6f5OX0h.cjs.map} +1 -1
  59. package/dist/chunks/{button-BhvlZrT2.esm.js → button-DyM-iqBq.esm.js} +3 -3
  60. package/dist/chunks/{button-BhvlZrT2.esm.js.map → button-DyM-iqBq.esm.js.map} +1 -1
  61. package/dist/chunks/{calendar-DS0rNrhj.cjs → calendar-YtVTt0Tm.cjs} +2 -2
  62. package/dist/chunks/{calendar-DS0rNrhj.cjs.map → calendar-YtVTt0Tm.cjs.map} +1 -1
  63. package/dist/chunks/{calendar-C5GZoGge.esm.js → calendar-bydCjK4Q.esm.js} +5 -5
  64. package/dist/chunks/{calendar-C5GZoGge.esm.js.map → calendar-bydCjK4Q.esm.js.map} +1 -1
  65. package/dist/chunks/{chat-message-DW8IO5YJ.cjs → chat-message-BcuYfXqe.cjs} +2 -2
  66. package/dist/chunks/{chat-message-DW8IO5YJ.cjs.map → chat-message-BcuYfXqe.cjs.map} +1 -1
  67. package/dist/chunks/{chat-message-CDLvkgaw.esm.js → chat-message-D9947sio.esm.js} +2 -2
  68. package/dist/chunks/{chat-message-CDLvkgaw.esm.js.map → chat-message-D9947sio.esm.js.map} +1 -1
  69. package/dist/chunks/chat-message-list-BEQEQzhV.cjs +2 -0
  70. package/dist/chunks/chat-message-list-BEQEQzhV.cjs.map +1 -0
  71. package/dist/chunks/{chat-message-list-BhWZEg4l.esm.js → chat-message-list-D_4ZLopT.esm.js} +10 -10
  72. package/dist/chunks/chat-message-list-D_4ZLopT.esm.js.map +1 -0
  73. package/dist/chunks/{checkbox-CZCLSrFV.cjs → checkbox-DCVW3K9i.cjs} +2 -2
  74. package/dist/chunks/{checkbox-CZCLSrFV.cjs.map → checkbox-DCVW3K9i.cjs.map} +1 -1
  75. package/dist/chunks/{checkbox-Bto3lCdU.esm.js → checkbox-dSuozQvl.esm.js} +4 -4
  76. package/dist/chunks/{checkbox-Bto3lCdU.esm.js.map → checkbox-dSuozQvl.esm.js.map} +1 -1
  77. package/dist/chunks/{collapsible-motion-C5-B_qO-.cjs → collapsible-motion-BW3mF74f.cjs} +2 -2
  78. package/dist/chunks/{collapsible-motion-C5-B_qO-.cjs.map → collapsible-motion-BW3mF74f.cjs.map} +1 -1
  79. package/dist/chunks/{collapsible-motion-5Y-srpM4.esm.js → collapsible-motion-CKrXIpgY.esm.js} +3 -3
  80. package/dist/chunks/{collapsible-motion-5Y-srpM4.esm.js.map → collapsible-motion-CKrXIpgY.esm.js.map} +1 -1
  81. package/dist/chunks/{combobox-ot7fVTI7.cjs → combobox-3_YvuwlN.cjs} +2 -2
  82. package/dist/chunks/{combobox-ot7fVTI7.cjs.map → combobox-3_YvuwlN.cjs.map} +1 -1
  83. package/dist/chunks/{combobox-BW_VrIHV.esm.js → combobox-C9gMnokj.esm.js} +11 -11
  84. package/dist/chunks/{combobox-BW_VrIHV.esm.js.map → combobox-C9gMnokj.esm.js.map} +1 -1
  85. package/dist/chunks/{components-BaZ6iHgw.esm.js → components-DJj34Iqi.esm.js} +3 -3
  86. package/dist/chunks/{components-BaZ6iHgw.esm.js.map → components-DJj34Iqi.esm.js.map} +1 -1
  87. package/dist/chunks/{components-DHYEVZM_.cjs → components-tMYnGsnG.cjs} +2 -2
  88. package/dist/chunks/{components-DHYEVZM_.cjs.map → components-tMYnGsnG.cjs.map} +1 -1
  89. package/dist/chunks/{confirmation-dialog-JqWYM_7U.cjs → confirmation-dialog-DGV0mgM8.cjs} +2 -2
  90. package/dist/chunks/{confirmation-dialog-JqWYM_7U.cjs.map → confirmation-dialog-DGV0mgM8.cjs.map} +1 -1
  91. package/dist/chunks/{confirmation-dialog-CHUQLqNJ.esm.js → confirmation-dialog-EiNUlhQA.esm.js} +4 -4
  92. package/dist/chunks/{confirmation-dialog-CHUQLqNJ.esm.js.map → confirmation-dialog-EiNUlhQA.esm.js.map} +1 -1
  93. package/dist/chunks/{data-table-LoaR2VL5.esm.js → data-table-BjU1lBAt.esm.js} +715 -714
  94. package/dist/chunks/{data-table-LoaR2VL5.esm.js.map → data-table-BjU1lBAt.esm.js.map} +1 -1
  95. package/dist/chunks/data-table-DnlEkUhO.cjs +2 -0
  96. package/dist/chunks/{data-table-CHpJecej.cjs.map → data-table-DnlEkUhO.cjs.map} +1 -1
  97. package/dist/chunks/{date-input-BfCEzDBX.esm.js → date-input-BIMZk2u6.esm.js} +4 -4
  98. package/dist/chunks/{date-input-BfCEzDBX.esm.js.map → date-input-BIMZk2u6.esm.js.map} +1 -1
  99. package/dist/chunks/{date-input-B5yBTSm8.cjs → date-input-DbikA3Az.cjs} +2 -2
  100. package/dist/chunks/{date-input-B5yBTSm8.cjs.map → date-input-DbikA3Az.cjs.map} +1 -1
  101. package/dist/chunks/{date-picker-CcmAJYux.esm.js → date-picker--voC39id.esm.js} +11 -11
  102. package/dist/chunks/{date-picker-CcmAJYux.esm.js.map → date-picker--voC39id.esm.js.map} +1 -1
  103. package/dist/chunks/{date-picker-BYUOjbCN.cjs → date-picker-Dhb3cRFN.cjs} +2 -2
  104. package/dist/chunks/{date-picker-BYUOjbCN.cjs.map → date-picker-Dhb3cRFN.cjs.map} +1 -1
  105. package/dist/chunks/{date-range-picker-CD6CmAlq.esm.js → date-range-picker-B02yjYC_.esm.js} +11 -11
  106. package/dist/chunks/{date-range-picker-CD6CmAlq.esm.js.map → date-range-picker-B02yjYC_.esm.js.map} +1 -1
  107. package/dist/chunks/{date-range-picker-BladYzh3.cjs → date-range-picker-oFS0SF97.cjs} +2 -2
  108. package/dist/chunks/{date-range-picker-BladYzh3.cjs.map → date-range-picker-oFS0SF97.cjs.map} +1 -1
  109. package/dist/chunks/{default-page-B5bFn9gJ.cjs → default-page-BW66R099.cjs} +2 -2
  110. package/dist/chunks/{default-page-B5bFn9gJ.cjs.map → default-page-BW66R099.cjs.map} +1 -1
  111. package/dist/chunks/{default-page-De3ZyX7n.esm.js → default-page-oB4oiflC.esm.js} +2 -2
  112. package/dist/chunks/{default-page-De3ZyX7n.esm.js.map → default-page-oB4oiflC.esm.js.map} +1 -1
  113. package/dist/chunks/{dialog-Y4HKBxUr.cjs → dialog-CwCG4NKh.cjs} +2 -2
  114. package/dist/chunks/{dialog-Y4HKBxUr.cjs.map → dialog-CwCG4NKh.cjs.map} +1 -1
  115. package/dist/chunks/{dialog-XeM4qOa_.esm.js → dialog-lxgomHvu.esm.js} +6 -6
  116. package/dist/chunks/{dialog-XeM4qOa_.esm.js.map → dialog-lxgomHvu.esm.js.map} +1 -1
  117. package/dist/chunks/draggable-list-CAGO6acz.cjs +2 -0
  118. package/dist/chunks/{draggable-list-CKKl6A_a.cjs.map → draggable-list-CAGO6acz.cjs.map} +1 -1
  119. package/dist/chunks/{draggable-list-C5aulsay.esm.js → draggable-list-DKGfS4ob.esm.js} +243 -243
  120. package/dist/chunks/{draggable-list-C5aulsay.esm.js.map → draggable-list-DKGfS4ob.esm.js.map} +1 -1
  121. package/dist/chunks/{drawer-BKPP4f5K.cjs → drawer-Cj7eGaLQ.cjs} +2 -2
  122. package/dist/chunks/{drawer-BKPP4f5K.cjs.map → drawer-Cj7eGaLQ.cjs.map} +1 -1
  123. package/dist/chunks/{drawer-I6J9g1l4.esm.js → drawer-Dsnrsu2k.esm.js} +7 -7
  124. package/dist/chunks/{drawer-I6J9g1l4.esm.js.map → drawer-Dsnrsu2k.esm.js.map} +1 -1
  125. package/dist/chunks/{drop-zone-vRl7IFzc.esm.js → drop-zone-BKJQrFGG.esm.js} +6 -6
  126. package/dist/chunks/{drop-zone-vRl7IFzc.esm.js.map → drop-zone-BKJQrFGG.esm.js.map} +1 -1
  127. package/dist/chunks/{drop-zone-Dr4VzY5B.cjs → drop-zone-N7k0XExn.cjs} +2 -2
  128. package/dist/chunks/{drop-zone-Dr4VzY5B.cjs.map → drop-zone-N7k0XExn.cjs.map} +1 -1
  129. package/dist/chunks/{extract-style-props-BPnHKmWR.esm.js → extract-style-props-D519tVOc.esm.js} +2 -2
  130. package/dist/chunks/{extract-style-props-BPnHKmWR.esm.js.map → extract-style-props-D519tVOc.esm.js.map} +1 -1
  131. package/dist/chunks/{extract-style-props-CA1O0IF2.cjs → extract-style-props-WNdpT-ME.cjs} +2 -2
  132. package/dist/chunks/{extract-style-props-CA1O0IF2.cjs.map → extract-style-props-WNdpT-ME.cjs.map} +1 -1
  133. package/dist/chunks/{form-action-bar-C8wkuLiF.esm.js → form-action-bar-CfJjVyeS.esm.js} +3 -3
  134. package/dist/chunks/{form-action-bar-C8wkuLiF.esm.js.map → form-action-bar-CfJjVyeS.esm.js.map} +1 -1
  135. package/dist/chunks/{form-action-bar-C_pQubyB.cjs → form-action-bar-DhmjijBw.cjs} +2 -2
  136. package/dist/chunks/{form-action-bar-C_pQubyB.cjs.map → form-action-bar-DhmjijBw.cjs.map} +1 -1
  137. package/dist/chunks/{form-dialog-D14UuUnS.cjs → form-dialog-CLrL718p.cjs} +2 -2
  138. package/dist/chunks/{form-dialog-D14UuUnS.cjs.map → form-dialog-CLrL718p.cjs.map} +1 -1
  139. package/dist/chunks/{form-dialog-BaD03TZo.esm.js → form-dialog-D86jNeIZ.esm.js} +4 -4
  140. package/dist/chunks/{form-dialog-BaD03TZo.esm.js.map → form-dialog-D86jNeIZ.esm.js.map} +1 -1
  141. package/dist/chunks/{form-field-DRhB7O5k.esm.js → form-field-B5H98u7s.esm.js} +3 -3
  142. package/dist/chunks/{form-field-DRhB7O5k.esm.js.map → form-field-B5H98u7s.esm.js.map} +1 -1
  143. package/dist/chunks/{form-field-CrSE8x3q.cjs → form-field-CaTJgt57.cjs} +2 -2
  144. package/dist/chunks/{form-field-CrSE8x3q.cjs.map → form-field-CaTJgt57.cjs.map} +1 -1
  145. package/dist/chunks/{icon-button-CSlFdpjB.cjs → icon-button-BG5cQycc.cjs} +2 -2
  146. package/dist/chunks/{icon-button-CSlFdpjB.cjs.map → icon-button-BG5cQycc.cjs.map} +1 -1
  147. package/dist/chunks/{icon-button-6dtfz6Yf.esm.js → icon-button-CyhrlrIv.esm.js} +2 -2
  148. package/dist/chunks/{icon-button-6dtfz6Yf.esm.js.map → icon-button-CyhrlrIv.esm.js.map} +1 -1
  149. package/dist/chunks/{icon-toggle-button-DJbu9dBg.cjs → icon-toggle-button-CH90F1eK.cjs} +2 -2
  150. package/dist/chunks/{icon-toggle-button-DJbu9dBg.cjs.map → icon-toggle-button-CH90F1eK.cjs.map} +1 -1
  151. package/dist/chunks/{icon-toggle-button-Cesx6J1H.esm.js → icon-toggle-button-DzYb5JyL.esm.js} +2 -2
  152. package/dist/chunks/{icon-toggle-button-Cesx6J1H.esm.js.map → icon-toggle-button-DzYb5JyL.esm.js.map} +1 -1
  153. package/dist/chunks/item-DW8Z2EjT.cjs +2 -0
  154. package/dist/chunks/item-DW8Z2EjT.cjs.map +1 -0
  155. package/dist/chunks/item-YJDIjMGY.esm.js +132 -0
  156. package/dist/chunks/item-YJDIjMGY.esm.js.map +1 -0
  157. package/dist/chunks/item-group-BA2CvxjT.cjs +2 -0
  158. package/dist/chunks/item-group-BA2CvxjT.cjs.map +1 -0
  159. package/dist/chunks/item-group-Bu78JFep.esm.js +35 -0
  160. package/dist/chunks/item-group-Bu78JFep.esm.js.map +1 -0
  161. package/dist/chunks/{list-DpS1s3Ww.cjs → list-ClGk4Q7n.cjs} +2 -2
  162. package/dist/chunks/{list-DpS1s3Ww.cjs.map → list-ClGk4Q7n.cjs.map} +1 -1
  163. package/dist/chunks/{list-CuA_gr8m.esm.js → list-CvVw2FgQ.esm.js} +2 -2
  164. package/dist/chunks/{list-CuA_gr8m.esm.js.map → list-CvVw2FgQ.esm.js.map} +1 -1
  165. package/dist/chunks/{loading-spinner-CTPm1sYC.esm.js → loading-spinner-DZoySVDH.esm.js} +2 -2
  166. package/dist/chunks/{loading-spinner-CTPm1sYC.esm.js.map → loading-spinner-DZoySVDH.esm.js.map} +1 -1
  167. package/dist/chunks/{loading-spinner-DAZGwhe6.cjs → loading-spinner-p_cYuGNg.cjs} +2 -2
  168. package/dist/chunks/{loading-spinner-DAZGwhe6.cjs.map → loading-spinner-p_cYuGNg.cjs.map} +1 -1
  169. package/dist/chunks/{localized-field-tpT6376o.cjs → localized-field-CQ8GkZKo.cjs} +2 -2
  170. package/dist/chunks/{localized-field-tpT6376o.cjs.map → localized-field-CQ8GkZKo.cjs.map} +1 -1
  171. package/dist/chunks/{localized-field-rPZczTNY.esm.js → localized-field-edbtofV6.esm.js} +10 -10
  172. package/dist/chunks/{localized-field-rPZczTNY.esm.js.map → localized-field-edbtofV6.esm.js.map} +1 -1
  173. package/dist/chunks/{markdown-CxE72YNo.esm.js → markdown-C1aT-ZDT.esm.js} +34 -34
  174. package/dist/chunks/{markdown-CxE72YNo.esm.js.map → markdown-C1aT-ZDT.esm.js.map} +1 -1
  175. package/dist/chunks/{markdown-Dvf4iLu2.cjs → markdown-RayGWo-B.cjs} +2 -2
  176. package/dist/chunks/{markdown-Dvf4iLu2.cjs.map → markdown-RayGWo-B.cjs.map} +1 -1
  177. package/dist/chunks/{menu-tAepHyH2.esm.js → menu-C2ZLfnJM.esm.js} +5 -5
  178. package/dist/chunks/{menu-tAepHyH2.esm.js.map → menu-C2ZLfnJM.esm.js.map} +1 -1
  179. package/dist/chunks/{menu-WFLbN6in.cjs → menu-sokBButj.cjs} +2 -2
  180. package/dist/chunks/{menu-WFLbN6in.cjs.map → menu-sokBButj.cjs.map} +1 -1
  181. package/dist/chunks/{modal-page-BRDY8JIO.cjs → modal-page-BGs7DHvn.cjs} +2 -2
  182. package/dist/chunks/{modal-page-BRDY8JIO.cjs.map → modal-page-BGs7DHvn.cjs.map} +1 -1
  183. package/dist/chunks/{modal-page-CH6Dlz-D.esm.js → modal-page-BZGoeMPR.esm.js} +3 -3
  184. package/dist/chunks/{modal-page-CH6Dlz-D.esm.js.map → modal-page-BZGoeMPR.esm.js.map} +1 -1
  185. package/dist/chunks/{money-input-D-h6tlpV.cjs → money-input-3_CQxVa3.cjs} +2 -2
  186. package/dist/chunks/{money-input-D-h6tlpV.cjs.map → money-input-3_CQxVa3.cjs.map} +1 -1
  187. package/dist/chunks/{money-input-field-Dy6VCxeQ.esm.js → money-input-field-DMZMbP9B.esm.js} +3 -3
  188. package/dist/chunks/{money-input-field-Dy6VCxeQ.esm.js.map → money-input-field-DMZMbP9B.esm.js.map} +1 -1
  189. package/dist/chunks/{money-input-field-DeajMPme.cjs → money-input-field-Deavtpts.cjs} +2 -2
  190. package/dist/chunks/{money-input-field-DeajMPme.cjs.map → money-input-field-Deavtpts.cjs.map} +1 -1
  191. package/dist/chunks/{money-input-CKNrFSKT.esm.js → money-input-hdeI43mM.esm.js} +5 -5
  192. package/dist/chunks/{money-input-CKNrFSKT.esm.js.map → money-input-hdeI43mM.esm.js.map} +1 -1
  193. package/dist/chunks/{multiline-text-input-BZU8t53J.esm.js → multiline-text-input-BlQChE3E.esm.js} +4 -4
  194. package/dist/chunks/{multiline-text-input-BZU8t53J.esm.js.map → multiline-text-input-BlQChE3E.esm.js.map} +1 -1
  195. package/dist/chunks/{multiline-text-input-ipy-1vwz.cjs → multiline-text-input-BnbYMYjn.cjs} +2 -2
  196. package/dist/chunks/{multiline-text-input-ipy-1vwz.cjs.map → multiline-text-input-BnbYMYjn.cjs.map} +1 -1
  197. package/dist/chunks/{multiline-text-input-field-DDzHc9t0.cjs → multiline-text-input-field-Dmrep7c1.cjs} +2 -2
  198. package/dist/chunks/{multiline-text-input-field-DDzHc9t0.cjs.map → multiline-text-input-field-Dmrep7c1.cjs.map} +1 -1
  199. package/dist/chunks/{multiline-text-input-field-Dj3yuO2D.esm.js → multiline-text-input-field-DtKT6KA3.esm.js} +3 -3
  200. package/dist/chunks/{multiline-text-input-field-Dj3yuO2D.esm.js.map → multiline-text-input-field-DtKT6KA3.esm.js.map} +1 -1
  201. package/dist/chunks/{nimbus-provider-DcYjdMwh.cjs → nimbus-provider-DyiUPBgB.cjs} +2 -2
  202. package/dist/chunks/{nimbus-provider-DcYjdMwh.cjs.map → nimbus-provider-DyiUPBgB.cjs.map} +1 -1
  203. package/dist/chunks/{nimbus-provider-qYnfenns.esm.js → nimbus-provider-TxuMyLri.esm.js} +3 -3
  204. package/dist/chunks/{nimbus-provider-qYnfenns.esm.js.map → nimbus-provider-TxuMyLri.esm.js.map} +1 -1
  205. package/dist/chunks/number-input-DTS_KQVk.cjs +2 -0
  206. package/dist/chunks/{number-input-DU3522fK.cjs.map → number-input-DTS_KQVk.cjs.map} +1 -1
  207. package/dist/chunks/{number-input-D5jL0iW-.esm.js → number-input-Gpg_2UbB.esm.js} +23 -22
  208. package/dist/chunks/{number-input-D5jL0iW-.esm.js.map → number-input-Gpg_2UbB.esm.js.map} +1 -1
  209. package/dist/chunks/{number-input-field-C5DhaRwc.cjs → number-input-field-C0XJ94dJ.cjs} +2 -2
  210. package/dist/chunks/{number-input-field-C5DhaRwc.cjs.map → number-input-field-C0XJ94dJ.cjs.map} +1 -1
  211. package/dist/chunks/{number-input-field-BKAb5VQ2.esm.js → number-input-field-Da0Hux_Q.esm.js} +3 -3
  212. package/dist/chunks/{number-input-field-BKAb5VQ2.esm.js.map → number-input-field-Da0Hux_Q.esm.js.map} +1 -1
  213. package/dist/chunks/{pagination-ZSf9r9bz.esm.js → pagination-FtHeZ5vD.esm.js} +4 -4
  214. package/dist/chunks/{pagination-ZSf9r9bz.esm.js.map → pagination-FtHeZ5vD.esm.js.map} +1 -1
  215. package/dist/chunks/{pagination-CmXQNDbp.cjs → pagination-Teyq3Fc-.cjs} +2 -2
  216. package/dist/chunks/{pagination-CmXQNDbp.cjs.map → pagination-Teyq3Fc-.cjs.map} +1 -1
  217. package/dist/chunks/{password-input-DMJGpUt6.cjs → password-input-B6xQTVt3.cjs} +2 -2
  218. package/dist/chunks/{password-input-DMJGpUt6.cjs.map → password-input-B6xQTVt3.cjs.map} +1 -1
  219. package/dist/chunks/{password-input-B2OHc-gn.esm.js → password-input-ZHMvWFue.esm.js} +3 -3
  220. package/dist/chunks/{password-input-B2OHc-gn.esm.js.map → password-input-ZHMvWFue.esm.js.map} +1 -1
  221. package/dist/chunks/{password-input-field-BFj95JMU.esm.js → password-input-field-B6I17gLd.esm.js} +3 -3
  222. package/dist/chunks/{password-input-field-BFj95JMU.esm.js.map → password-input-field-B6I17gLd.esm.js.map} +1 -1
  223. package/dist/chunks/{password-input-field-Cf-zBu2O.cjs → password-input-field-Bh-LmgfF.cjs} +2 -2
  224. package/dist/chunks/{password-input-field-Cf-zBu2O.cjs.map → password-input-field-Bh-LmgfF.cjs.map} +1 -1
  225. package/dist/chunks/{popover-eUvkAe8L.cjs → popover-B4aHN9qY.cjs} +2 -2
  226. package/dist/chunks/{popover-eUvkAe8L.cjs.map → popover-B4aHN9qY.cjs.map} +1 -1
  227. package/dist/chunks/{popover-CwdOyGHr.esm.js → popover-biPpujsV.esm.js} +2 -2
  228. package/dist/chunks/{popover-CwdOyGHr.esm.js.map → popover-biPpujsV.esm.js.map} +1 -1
  229. package/dist/chunks/{progress-bar-DhZVJqY_.cjs → progress-bar-D_PAUwhj.cjs} +2 -2
  230. package/dist/chunks/{progress-bar-DhZVJqY_.cjs.map → progress-bar-D_PAUwhj.cjs.map} +1 -1
  231. package/dist/chunks/{progress-bar-Be7o97DL.esm.js → progress-bar-PjyuiZvS.esm.js} +3 -3
  232. package/dist/chunks/{progress-bar-Be7o97DL.esm.js.map → progress-bar-PjyuiZvS.esm.js.map} +1 -1
  233. package/dist/chunks/{radio-input-Cj03oX72.esm.js → radio-input-CZNQh41n.esm.js} +10 -9
  234. package/dist/chunks/{radio-input-Cj03oX72.esm.js.map → radio-input-CZNQh41n.esm.js.map} +1 -1
  235. package/dist/chunks/radio-input-FRyDwoTk.cjs +2 -0
  236. package/dist/chunks/{radio-input-_eEv0K2W.cjs.map → radio-input-FRyDwoTk.cjs.map} +1 -1
  237. package/dist/chunks/{range-calendar-B0U51wMd.cjs → range-calendar-D1yls6jq.cjs} +2 -2
  238. package/dist/chunks/{range-calendar-B0U51wMd.cjs.map → range-calendar-D1yls6jq.cjs.map} +1 -1
  239. package/dist/chunks/{range-calendar-DA5hJpYL.esm.js → range-calendar-DhgT-Y8T.esm.js} +6 -6
  240. package/dist/chunks/{range-calendar-DA5hJpYL.esm.js.map → range-calendar-DhgT-Y8T.esm.js.map} +1 -1
  241. package/dist/chunks/range-slider-Ch4kXVc3.cjs +2 -0
  242. package/dist/chunks/range-slider-Ch4kXVc3.cjs.map +1 -0
  243. package/dist/chunks/range-slider-CiNJCiKg.esm.js +600 -0
  244. package/dist/chunks/range-slider-CiNJCiKg.esm.js.map +1 -0
  245. package/dist/chunks/{rich-text-input-PYMjw5DQ.esm.js → rich-text-input-CLwl2b63.esm.js} +8 -8
  246. package/dist/chunks/{rich-text-input-PYMjw5DQ.esm.js.map → rich-text-input-CLwl2b63.esm.js.map} +1 -1
  247. package/dist/chunks/{rich-text-input-C0UU1Uoq.cjs → rich-text-input-D9MMIdJJ.cjs} +3 -3
  248. package/dist/chunks/{rich-text-input-C0UU1Uoq.cjs.map → rich-text-input-D9MMIdJJ.cjs.map} +1 -1
  249. package/dist/chunks/{scoped-search-input-D80PFOdN.esm.js → scoped-search-input-BzTmH7Ms.esm.js} +5 -5
  250. package/dist/chunks/{scoped-search-input-D80PFOdN.esm.js.map → scoped-search-input-BzTmH7Ms.esm.js.map} +1 -1
  251. package/dist/chunks/{scoped-search-input-Kj-JJpvo.cjs → scoped-search-input-C9PJWoSh.cjs} +2 -2
  252. package/dist/chunks/{scoped-search-input-Kj-JJpvo.cjs.map → scoped-search-input-C9PJWoSh.cjs.map} +1 -1
  253. package/dist/chunks/{search-input-yUmma36U.cjs → search-input-Cocic3Im.cjs} +2 -2
  254. package/dist/chunks/{search-input-yUmma36U.cjs.map → search-input-Cocic3Im.cjs.map} +1 -1
  255. package/dist/chunks/{search-input-BMq6pRov.esm.js → search-input-DLixG2wL.esm.js} +6 -6
  256. package/dist/chunks/{search-input-BMq6pRov.esm.js.map → search-input-DLixG2wL.esm.js.map} +1 -1
  257. package/dist/chunks/{select-D39rm0xA.esm.js → select-CZzyQOhP.esm.js} +17 -16
  258. package/dist/chunks/{select-D39rm0xA.esm.js.map → select-CZzyQOhP.esm.js.map} +1 -1
  259. package/dist/chunks/select-g5OICT61.cjs +2 -0
  260. package/dist/chunks/{select-DdeLYdJ3.cjs.map → select-g5OICT61.cjs.map} +1 -1
  261. package/dist/chunks/{separator-CRFMcKYe.cjs → separator-DW1Lj5oz.cjs} +2 -2
  262. package/dist/chunks/{separator-CRFMcKYe.cjs.map → separator-DW1Lj5oz.cjs.map} +1 -1
  263. package/dist/chunks/{separator-AUEVwjXs.esm.js → separator-DYgOOvtr.esm.js} +3 -3
  264. package/dist/chunks/{separator-AUEVwjXs.esm.js.map → separator-DYgOOvtr.esm.js.map} +1 -1
  265. package/dist/chunks/skeleton-C-MXf-Vh.esm.js +16 -0
  266. package/dist/chunks/skeleton-C-MXf-Vh.esm.js.map +1 -0
  267. package/dist/chunks/skeleton-SWjnk1LM.cjs +2 -0
  268. package/dist/chunks/skeleton-SWjnk1LM.cjs.map +1 -0
  269. package/dist/chunks/skeleton-circle-C5RFsv29.esm.js +18 -0
  270. package/dist/chunks/skeleton-circle-C5RFsv29.esm.js.map +1 -0
  271. package/dist/chunks/skeleton-circle-CbqEiVJ8.cjs +2 -0
  272. package/dist/chunks/skeleton-circle-CbqEiVJ8.cjs.map +1 -0
  273. package/dist/chunks/skeleton-text-B-r_Iovw.esm.js +33 -0
  274. package/dist/chunks/skeleton-text-B-r_Iovw.esm.js.map +1 -0
  275. package/dist/chunks/skeleton-text-CEr3QStr.cjs +2 -0
  276. package/dist/chunks/skeleton-text-CEr3QStr.cjs.map +1 -0
  277. package/dist/chunks/slider-CE2eEViT.esm.js +9 -0
  278. package/dist/chunks/slider-CE2eEViT.esm.js.map +1 -0
  279. package/dist/chunks/slider-CxvxZzOB.cjs +2 -0
  280. package/dist/chunks/slider-CxvxZzOB.cjs.map +1 -0
  281. package/dist/chunks/{split-button-DelUgBth.cjs → split-button-Dr_RsxyR.cjs} +2 -2
  282. package/dist/chunks/{split-button-DelUgBth.cjs.map → split-button-Dr_RsxyR.cjs.map} +1 -1
  283. package/dist/chunks/{split-button-C9MIlSe4.esm.js → split-button-lLEz3Ddi.esm.js} +4 -4
  284. package/dist/chunks/{split-button-C9MIlSe4.esm.js.map → split-button-lLEz3Ddi.esm.js.map} +1 -1
  285. package/dist/chunks/{steps-BLrpE2PL.cjs → steps-BvqxvDfJ.cjs} +2 -2
  286. package/dist/chunks/{steps-BLrpE2PL.cjs.map → steps-BvqxvDfJ.cjs.map} +1 -1
  287. package/dist/chunks/{steps-OnZi-T9x.esm.js → steps-DIRtxFO6.esm.js} +2 -2
  288. package/dist/chunks/{steps-OnZi-T9x.esm.js.map → steps-DIRtxFO6.esm.js.map} +1 -1
  289. package/dist/chunks/{switch-D1rdYruG.esm.js → switch-B351GNnT.esm.js} +4 -4
  290. package/dist/chunks/{switch-D1rdYruG.esm.js.map → switch-B351GNnT.esm.js.map} +1 -1
  291. package/dist/chunks/{switch-BPk30JYZ.cjs → switch-BSws2Bn9.cjs} +2 -2
  292. package/dist/chunks/{switch-BPk30JYZ.cjs.map → switch-BSws2Bn9.cjs.map} +1 -1
  293. package/dist/chunks/tab-nav-BMNdumQw.esm.js +66 -0
  294. package/dist/chunks/tab-nav-BMNdumQw.esm.js.map +1 -0
  295. package/dist/chunks/tab-nav-Dy6pg3Cf.cjs +2 -0
  296. package/dist/chunks/tab-nav-Dy6pg3Cf.cjs.map +1 -0
  297. package/dist/chunks/{table-DEKXq5nE.cjs → table-BF5v-4YU.cjs} +2 -2
  298. package/dist/chunks/{table-DEKXq5nE.cjs.map → table-BF5v-4YU.cjs.map} +1 -1
  299. package/dist/chunks/{table-O8T8871k.esm.js → table-OZDDVGWu.esm.js} +2 -2
  300. package/dist/chunks/{table-O8T8871k.esm.js.map → table-OZDDVGWu.esm.js.map} +1 -1
  301. package/dist/chunks/{tabs-IjuTjmW5.esm.js → tabs-C7zLoP1D.esm.js} +101 -100
  302. package/dist/chunks/{tabs-IjuTjmW5.esm.js.map → tabs-C7zLoP1D.esm.js.map} +1 -1
  303. package/dist/chunks/tabs-DLr47HN_.cjs +2 -0
  304. package/dist/chunks/{tabs-BbC8to5L.cjs.map → tabs-DLr47HN_.cjs.map} +1 -1
  305. package/dist/chunks/{tag-group-DJ2Eyzr6.esm.js → tag-group-DKiwZtum.esm.js} +160 -160
  306. package/dist/chunks/{tag-group-DJ2Eyzr6.esm.js.map → tag-group-DKiwZtum.esm.js.map} +1 -1
  307. package/dist/chunks/tag-group-JEE8r8Jl.cjs +2 -0
  308. package/dist/chunks/{tag-group-t9CCZs9w.cjs.map → tag-group-JEE8r8Jl.cjs.map} +1 -1
  309. package/dist/chunks/{text-input-DzHnlufM.esm.js → text-input-4YjslLxr.esm.js} +4 -4
  310. package/dist/chunks/{text-input-DzHnlufM.esm.js.map → text-input-4YjslLxr.esm.js.map} +1 -1
  311. package/dist/chunks/{text-input-Bc2XftOM.cjs → text-input-BttCyWCt.cjs} +2 -2
  312. package/dist/chunks/{text-input-Bc2XftOM.cjs.map → text-input-BttCyWCt.cjs.map} +1 -1
  313. package/dist/chunks/{theme-BR3bc6tH.esm.js → theme-CFqa_6UM.esm.js} +710 -195
  314. package/dist/chunks/theme-CFqa_6UM.esm.js.map +1 -0
  315. package/dist/chunks/theme-DA63MDZQ.cjs +34 -0
  316. package/dist/chunks/theme-DA63MDZQ.cjs.map +1 -0
  317. package/dist/chunks/{time-input--A7teyZm.esm.js → time-input-CJcXuGHH.esm.js} +4 -4
  318. package/dist/chunks/{time-input--A7teyZm.esm.js.map → time-input-CJcXuGHH.esm.js.map} +1 -1
  319. package/dist/chunks/{time-input-CnqA54LG.cjs → time-input-Cv-8dl-n.cjs} +2 -2
  320. package/dist/chunks/{time-input-CnqA54LG.cjs.map → time-input-Cv-8dl-n.cjs.map} +1 -1
  321. package/dist/chunks/{toast.outlet-CiElRAMb.cjs → toast.outlet-BGy4NZoL.cjs} +2 -2
  322. package/dist/chunks/{toast.outlet-CiElRAMb.cjs.map → toast.outlet-BGy4NZoL.cjs.map} +1 -1
  323. package/dist/chunks/{toast.outlet-DfFHdsij.esm.js → toast.outlet-DQ7Z1sG7.esm.js} +4 -4
  324. package/dist/chunks/{toast.outlet-DfFHdsij.esm.js.map → toast.outlet-DQ7Z1sG7.esm.js.map} +1 -1
  325. package/dist/chunks/{toggle-button-szYkDbB4.cjs → toggle-button-B9m2DON6.cjs} +2 -2
  326. package/dist/chunks/{toggle-button-szYkDbB4.cjs.map → toggle-button-B9m2DON6.cjs.map} +1 -1
  327. package/dist/chunks/{toggle-button-DnjpkkaG.esm.js → toggle-button-D3UZNm_4.esm.js} +3 -3
  328. package/dist/chunks/{toggle-button-DnjpkkaG.esm.js.map → toggle-button-D3UZNm_4.esm.js.map} +1 -1
  329. package/dist/chunks/{toolbar-BTl4PMN6.esm.js → toolbar-BUb2xcXt.esm.js} +3 -3
  330. package/dist/chunks/{toolbar-BTl4PMN6.esm.js.map → toolbar-BUb2xcXt.esm.js.map} +1 -1
  331. package/dist/chunks/{toolbar-CDuqJw86.cjs → toolbar-CxYGox-m.cjs} +2 -2
  332. package/dist/chunks/{toolbar-CDuqJw86.cjs.map → toolbar-CxYGox-m.cjs.map} +1 -1
  333. package/dist/chunks/{use-responsive-splitter-sizes-CO-POrVJ.esm.js → use-responsive-splitter-sizes-BgEYraHy.esm.js} +2 -2
  334. package/dist/chunks/{use-responsive-splitter-sizes-CO-POrVJ.esm.js.map → use-responsive-splitter-sizes-BgEYraHy.esm.js.map} +1 -1
  335. package/dist/chunks/{use-responsive-splitter-sizes-DApY1vey.cjs → use-responsive-splitter-sizes-CzfdjEjf.cjs} +2 -2
  336. package/dist/chunks/{use-responsive-splitter-sizes-DApY1vey.cjs.map → use-responsive-splitter-sizes-CzfdjEjf.cjs.map} +1 -1
  337. package/dist/chunks/{use-tree-wsHR3c7J.esm.js → use-tree-BFKFaiiu.esm.js} +147 -147
  338. package/dist/chunks/{use-tree-wsHR3c7J.esm.js.map → use-tree-BFKFaiiu.esm.js.map} +1 -1
  339. package/dist/chunks/use-tree-NiiqPu0M.cjs +2 -0
  340. package/dist/chunks/{use-tree-CrwSJhB8.cjs.map → use-tree-NiiqPu0M.cjs.map} +1 -1
  341. package/dist/chunks/{useCollection-CGf4ZguH.esm.js → useCollection-BCbt2V3u.esm.js} +258 -307
  342. package/dist/chunks/useCollection-BCbt2V3u.esm.js.map +1 -0
  343. package/dist/chunks/useCollection-BjHtDvt-.cjs +2 -0
  344. package/dist/chunks/useCollection-BjHtDvt-.cjs.map +1 -0
  345. package/dist/chunks/{useDragAndDrop-CoNOA7E9.cjs → useDragAndDrop-B8UfdCMX.cjs} +2 -2
  346. package/dist/chunks/{useDragAndDrop-CoNOA7E9.cjs.map → useDragAndDrop-B8UfdCMX.cjs.map} +1 -1
  347. package/dist/chunks/{useDragAndDrop-D_i3CWeg.esm.js → useDragAndDrop-BAyAtCYg.esm.js} +2 -2
  348. package/dist/chunks/{useDragAndDrop-D_i3CWeg.esm.js.map → useDragAndDrop-BAyAtCYg.esm.js.map} +1 -1
  349. package/dist/chunks/useFormReset-C6H3spHM.cjs +2 -0
  350. package/dist/chunks/useFormReset-C6H3spHM.cjs.map +1 -0
  351. package/dist/chunks/useFormReset-CAZratNG.esm.js +18 -0
  352. package/dist/chunks/useFormReset-CAZratNG.esm.js.map +1 -0
  353. package/dist/chunks/useFormValidationState-CMK07tQk.cjs +2 -0
  354. package/dist/chunks/useFormValidationState-CMK07tQk.cjs.map +1 -0
  355. package/dist/chunks/{useFormValidationState-rjMRhdnd.esm.js → useFormValidationState-hfa069v5.esm.js} +40 -53
  356. package/dist/chunks/useFormValidationState-hfa069v5.esm.js.map +1 -0
  357. package/dist/chunks/{useGridListItem-DVNb2d76.esm.js → useGridListItem-C6LMK1Mv.esm.js} +3 -3
  358. package/dist/chunks/{useGridListItem-DVNb2d76.esm.js.map → useGridListItem-C6LMK1Mv.esm.js.map} +1 -1
  359. package/dist/chunks/{useGridListItem-d-i-pqAt.cjs → useGridListItem-CmLWoZGe.cjs} +2 -2
  360. package/dist/chunks/{useGridListItem-d-i-pqAt.cjs.map → useGridListItem-CmLWoZGe.cjs.map} +1 -1
  361. package/dist/chunks/{useListState-6F4go-kc.cjs → useListState-BBQE4IFG.cjs} +2 -2
  362. package/dist/chunks/{useListState-6F4go-kc.cjs.map → useListState-BBQE4IFG.cjs.map} +1 -1
  363. package/dist/chunks/{useListState-BiT-W669.esm.js → useListState-TSrPXjzi.esm.js} +2 -2
  364. package/dist/chunks/{useListState-BiT-W669.esm.js.map → useListState-TSrPXjzi.esm.js.map} +1 -1
  365. package/dist/chunks/useNumberFormatter-Drsf_lwe.cjs +2 -0
  366. package/dist/chunks/useNumberFormatter-Drsf_lwe.cjs.map +1 -0
  367. package/dist/chunks/useNumberFormatter-L64UBjdR.esm.js +12 -0
  368. package/dist/chunks/useNumberFormatter-L64UBjdR.esm.js.map +1 -0
  369. package/dist/chunks/useProgressBar-C-UZQWBC.cjs +2 -0
  370. package/dist/chunks/useProgressBar-C-UZQWBC.cjs.map +1 -0
  371. package/dist/chunks/useProgressBar-DVPx9_dg.esm.js +33 -0
  372. package/dist/chunks/useProgressBar-DVPx9_dg.esm.js.map +1 -0
  373. package/dist/chunks/{useSelectableList-DDytBtRR.cjs → useSelectableList-Bgv2nxTX.cjs} +2 -2
  374. package/dist/chunks/{useSelectableList-DDytBtRR.cjs.map → useSelectableList-Bgv2nxTX.cjs.map} +1 -1
  375. package/dist/chunks/{useSelectableList-umEtkxYN.esm.js → useSelectableList-gohzq7dg.esm.js} +2 -2
  376. package/dist/chunks/{useSelectableList-umEtkxYN.esm.js.map → useSelectableList-gohzq7dg.esm.js.map} +1 -1
  377. package/dist/chunks/useTextField-ABtLd27L.cjs +2 -0
  378. package/dist/chunks/{useTextField-CzF6gZ6-.cjs.map → useTextField-ABtLd27L.cjs.map} +1 -1
  379. package/dist/chunks/{useTextField-CdCrgSsV.esm.js → useTextField-FAMJ18ah.esm.js} +5 -4
  380. package/dist/chunks/{useTextField-CdCrgSsV.esm.js.map → useTextField-FAMJ18ah.esm.js.map} +1 -1
  381. package/dist/chunks/{useToggle-oUUHIEEp.esm.js → useToggle-B9oH7p52.esm.js} +7 -6
  382. package/dist/chunks/{useToggle-oUUHIEEp.esm.js.map → useToggle-B9oH7p52.esm.js.map} +1 -1
  383. package/dist/chunks/useToggle-WawJgKE5.cjs +2 -0
  384. package/dist/chunks/{useToggle-DOG2OJN_.cjs.map → useToggle-WawJgKE5.cjs.map} +1 -1
  385. package/dist/chunks/{useTreeState-Bi7rvUKr.cjs → useTreeState-C5z4FPeF.cjs} +2 -2
  386. package/dist/chunks/{useTreeState-Bi7rvUKr.cjs.map → useTreeState-C5z4FPeF.cjs.map} +1 -1
  387. package/dist/chunks/{useTreeState-BlJtuLmC.esm.js → useTreeState-DuW0JMo8.esm.js} +2 -2
  388. package/dist/chunks/{useTreeState-BlJtuLmC.esm.js.map → useTreeState-DuW0JMo8.esm.js.map} +1 -1
  389. package/dist/components/accordion.cjs +1 -1
  390. package/dist/components/accordion.es.js +2 -2
  391. package/dist/components/actions.cjs +1 -1
  392. package/dist/components/actions.es.js +1 -1
  393. package/dist/components/alert.cjs +1 -1
  394. package/dist/components/alert.es.js +1 -1
  395. package/dist/components/breadcrumbs/breadcrumbs.d.ts +71 -0
  396. package/dist/components/breadcrumbs/breadcrumbs.recipe.d.ts +31 -0
  397. package/dist/components/breadcrumbs/breadcrumbs.slots.d.ts +27 -0
  398. package/dist/components/breadcrumbs/breadcrumbs.types.d.ts +142 -0
  399. package/dist/components/breadcrumbs/components/breadcrumbs.context.d.ts +13 -0
  400. package/dist/components/breadcrumbs/components/breadcrumbs.item.d.ts +20 -0
  401. package/dist/components/breadcrumbs/components/breadcrumbs.root.d.ts +19 -0
  402. package/dist/components/breadcrumbs/components/index.d.ts +2 -0
  403. package/dist/components/breadcrumbs/index.d.ts +2 -0
  404. package/dist/components/breadcrumbs.cjs +1 -0
  405. package/dist/components/breadcrumbs.es.js +2 -0
  406. package/dist/components/button.cjs +1 -1
  407. package/dist/components/button.es.js +1 -1
  408. package/dist/components/calendar.cjs +1 -1
  409. package/dist/components/calendar.es.js +1 -1
  410. package/dist/components/chat-message-list.cjs +1 -1
  411. package/dist/components/chat-message-list.es.js +1 -1
  412. package/dist/components/chat-message.cjs +1 -1
  413. package/dist/components/chat-message.es.js +1 -1
  414. package/dist/components/checkbox.cjs +1 -1
  415. package/dist/components/checkbox.es.js +1 -1
  416. package/dist/components/collapsible-motion.cjs +1 -1
  417. package/dist/components/collapsible-motion.es.js +1 -1
  418. package/dist/components/combobox.cjs +1 -1
  419. package/dist/components/combobox.es.js +1 -1
  420. package/dist/components/components.cjs +1 -1
  421. package/dist/components/components.es.js +1 -1
  422. package/dist/components/confirmation-dialog.cjs +1 -1
  423. package/dist/components/confirmation-dialog.es.js +1 -1
  424. package/dist/components/data-table.cjs +1 -1
  425. package/dist/components/data-table.es.js +1 -1
  426. package/dist/components/date-input.cjs +1 -1
  427. package/dist/components/date-input.es.js +1 -1
  428. package/dist/components/date-picker.cjs +1 -1
  429. package/dist/components/date-picker.es.js +1 -1
  430. package/dist/components/date-range-picker-field.cjs +1 -1
  431. package/dist/components/date-range-picker-field.es.js +2 -2
  432. package/dist/components/date-range-picker.cjs +1 -1
  433. package/dist/components/date-range-picker.es.js +1 -1
  434. package/dist/components/default-page.cjs +1 -1
  435. package/dist/components/default-page.es.js +1 -1
  436. package/dist/components/dialog.cjs +1 -1
  437. package/dist/components/dialog.es.js +1 -1
  438. package/dist/components/dialogs.cjs +1 -1
  439. package/dist/components/dialogs.es.js +2 -2
  440. package/dist/components/draggable-list.cjs +1 -1
  441. package/dist/components/draggable-list.es.js +1 -1
  442. package/dist/components/drawer.cjs +1 -1
  443. package/dist/components/drawer.es.js +1 -1
  444. package/dist/components/drop-zone.cjs +1 -1
  445. package/dist/components/drop-zone.es.js +1 -1
  446. package/dist/components/fields.cjs +1 -1
  447. package/dist/components/fields.es.js +4 -4
  448. package/dist/components/floating-action-button.cjs +1 -1
  449. package/dist/components/floating-action-button.es.js +1 -1
  450. package/dist/components/form-action-bar.cjs +1 -1
  451. package/dist/components/form-action-bar.es.js +1 -1
  452. package/dist/components/form-dialog.cjs +1 -1
  453. package/dist/components/form-dialog.es.js +1 -1
  454. package/dist/components/form-field.cjs +1 -1
  455. package/dist/components/form-field.es.js +1 -1
  456. package/dist/components/icon-button.cjs +1 -1
  457. package/dist/components/icon-button.es.js +1 -1
  458. package/dist/components/icon-toggle-button.cjs +1 -1
  459. package/dist/components/icon-toggle-button.es.js +1 -1
  460. package/dist/components/index.d.ts +5 -0
  461. package/dist/components/info-dialog.cjs +1 -1
  462. package/dist/components/info-dialog.es.js +1 -1
  463. package/dist/components/item/components/index.d.ts +8 -0
  464. package/dist/components/item/components/item.actions.d.ts +14 -0
  465. package/dist/components/item/components/item.content.d.ts +11 -0
  466. package/dist/components/item/components/item.description.d.ts +10 -0
  467. package/dist/components/item/components/item.footer.d.ts +10 -0
  468. package/dist/components/item/components/item.header.d.ts +10 -0
  469. package/dist/components/item/components/item.media.d.ts +18 -0
  470. package/dist/components/item/components/item.root.d.ts +16 -0
  471. package/dist/components/item/components/item.title.d.ts +10 -0
  472. package/dist/components/item/index.d.ts +2 -0
  473. package/dist/components/item/item.d.ts +177 -0
  474. package/dist/components/item/item.recipe.d.ts +52 -0
  475. package/dist/components/item/item.slots.d.ts +15 -0
  476. package/dist/components/item/item.types.d.ts +81 -0
  477. package/dist/components/item-group/components/index.d.ts +2 -0
  478. package/dist/components/item-group/components/item-group.root.d.ts +22 -0
  479. package/dist/components/item-group/components/item-group.separator.d.ts +11 -0
  480. package/dist/components/item-group/index.d.ts +2 -0
  481. package/dist/components/item-group/item-group.d.ts +62 -0
  482. package/dist/components/item-group/item-group.recipe.d.ts +11 -0
  483. package/dist/components/item-group/item-group.slots.d.ts +11 -0
  484. package/dist/components/item-group/item-group.types.d.ts +14 -0
  485. package/dist/components/item-group.cjs +1 -0
  486. package/dist/components/item-group.es.js +2 -0
  487. package/dist/components/item.cjs +1 -0
  488. package/dist/components/item.es.js +2 -0
  489. package/dist/components/list.cjs +1 -1
  490. package/dist/components/list.es.js +1 -1
  491. package/dist/components/loading-spinner.cjs +1 -1
  492. package/dist/components/loading-spinner.es.js +1 -1
  493. package/dist/components/localized-field.cjs +1 -1
  494. package/dist/components/localized-field.es.js +1 -1
  495. package/dist/components/markdown.cjs +1 -1
  496. package/dist/components/markdown.es.js +1 -1
  497. package/dist/components/modal-page.cjs +1 -1
  498. package/dist/components/modal-page.es.js +1 -1
  499. package/dist/components/money-input-field.cjs +1 -1
  500. package/dist/components/money-input-field.es.js +1 -1
  501. package/dist/components/money-input.cjs +1 -1
  502. package/dist/components/money-input.es.js +1 -1
  503. package/dist/components/multiline-text-input-field.cjs +1 -1
  504. package/dist/components/multiline-text-input-field.es.js +1 -1
  505. package/dist/components/multiline-text-input.cjs +1 -1
  506. package/dist/components/multiline-text-input.es.js +1 -1
  507. package/dist/components/nimbus-provider.cjs +1 -1
  508. package/dist/components/nimbus-provider.es.js +1 -1
  509. package/dist/components/number-input-field.cjs +1 -1
  510. package/dist/components/number-input-field.es.js +1 -1
  511. package/dist/components/number-input.cjs +1 -1
  512. package/dist/components/number-input.es.js +1 -1
  513. package/dist/components/pagination.cjs +1 -1
  514. package/dist/components/pagination.es.js +1 -1
  515. package/dist/components/password-input-field.cjs +1 -1
  516. package/dist/components/password-input-field.es.js +1 -1
  517. package/dist/components/password-input.cjs +1 -1
  518. package/dist/components/password-input.es.js +1 -1
  519. package/dist/components/patterns.cjs +1 -1
  520. package/dist/components/patterns.es.js +7 -7
  521. package/dist/components/popover.cjs +1 -1
  522. package/dist/components/popover.es.js +1 -1
  523. package/dist/components/progress-bar.cjs +1 -1
  524. package/dist/components/progress-bar.es.js +1 -1
  525. package/dist/components/radio-input.cjs +1 -1
  526. package/dist/components/radio-input.es.js +1 -1
  527. package/dist/components/range-calendar.cjs +1 -1
  528. package/dist/components/range-calendar.es.js +1 -1
  529. package/dist/components/range-slider.cjs +1 -0
  530. package/dist/components/range-slider.es.js +2 -0
  531. package/dist/components/rich-text-input.cjs +1 -1
  532. package/dist/components/rich-text-input.es.js +1 -1
  533. package/dist/components/scoped-search-input.cjs +1 -1
  534. package/dist/components/scoped-search-input.es.js +1 -1
  535. package/dist/components/search-input-field.cjs +1 -1
  536. package/dist/components/search-input-field.es.js +2 -2
  537. package/dist/components/search-input.cjs +1 -1
  538. package/dist/components/search-input.es.js +1 -1
  539. package/dist/components/select.cjs +1 -1
  540. package/dist/components/select.es.js +1 -1
  541. package/dist/components/separator.cjs +1 -1
  542. package/dist/components/separator.es.js +1 -1
  543. package/dist/components/skeleton/derivatives/skeleton-circle/index.d.ts +2 -0
  544. package/dist/components/skeleton/derivatives/skeleton-circle/skeleton-circle.d.ts +17 -0
  545. package/dist/components/skeleton/derivatives/skeleton-circle/skeleton-circle.types.d.ts +21 -0
  546. package/dist/components/skeleton/derivatives/skeleton-text/index.d.ts +2 -0
  547. package/dist/components/skeleton/derivatives/skeleton-text/skeleton-text.d.ts +16 -0
  548. package/dist/components/skeleton/derivatives/skeleton-text/skeleton-text.types.d.ts +45 -0
  549. package/dist/components/skeleton/index.d.ts +6 -0
  550. package/dist/components/skeleton/skeleton.d.ts +20 -0
  551. package/dist/components/skeleton/skeleton.recipe.d.ts +59 -0
  552. package/dist/components/skeleton/skeleton.slots.d.ts +7 -0
  553. package/dist/components/skeleton/skeleton.types.d.ts +50 -0
  554. package/dist/components/skeleton-circle.cjs +1 -0
  555. package/dist/components/skeleton-circle.es.js +2 -0
  556. package/dist/components/skeleton-text.cjs +1 -0
  557. package/dist/components/skeleton-text.es.js +2 -0
  558. package/dist/components/skeleton.cjs +1 -0
  559. package/dist/components/skeleton.es.js +6 -0
  560. package/dist/components/slider/derivatives/range-slider/index.d.ts +2 -0
  561. package/dist/components/slider/derivatives/range-slider/range-slider.d.ts +20 -0
  562. package/dist/components/slider/derivatives/range-slider/range-slider.types.d.ts +13 -0
  563. package/dist/components/slider/index.d.ts +4 -0
  564. package/dist/components/slider/intl/de.d.ts +10 -0
  565. package/dist/components/slider/intl/en.d.ts +10 -0
  566. package/dist/components/slider/intl/es.d.ts +10 -0
  567. package/dist/components/slider/intl/fr-FR.d.ts +10 -0
  568. package/dist/components/slider/intl/pt-BR.d.ts +10 -0
  569. package/dist/components/slider/slider-base.d.ts +10 -0
  570. package/dist/components/slider/slider.d.ts +13 -0
  571. package/dist/components/slider/slider.i18n.d.ts +12 -0
  572. package/dist/components/slider/slider.messages.d.ts +6 -0
  573. package/dist/components/slider/slider.recipe.d.ts +138 -0
  574. package/dist/components/slider/slider.slots.d.ts +9 -0
  575. package/dist/components/slider/slider.types.d.ts +57 -0
  576. package/dist/components/slider.cjs +1 -0
  577. package/dist/components/slider.es.js +4 -0
  578. package/dist/components/split-button.cjs +1 -1
  579. package/dist/components/split-button.es.js +1 -1
  580. package/dist/components/splitter.cjs +1 -1
  581. package/dist/components/splitter.es.js +1 -1
  582. package/dist/components/steps.cjs +1 -1
  583. package/dist/components/steps.es.js +1 -1
  584. package/dist/components/switch.cjs +1 -1
  585. package/dist/components/switch.es.js +1 -1
  586. package/dist/components/tab-nav.cjs +1 -1
  587. package/dist/components/tab-nav.es.js +1 -1
  588. package/dist/components/table.cjs +1 -1
  589. package/dist/components/table.es.js +1 -1
  590. package/dist/components/tabs.cjs +1 -1
  591. package/dist/components/tabs.es.js +1 -1
  592. package/dist/components/tag-group.cjs +1 -1
  593. package/dist/components/tag-group.es.js +1 -1
  594. package/dist/components/text-input-field.cjs +1 -1
  595. package/dist/components/text-input-field.es.js +2 -2
  596. package/dist/components/text-input.cjs +1 -1
  597. package/dist/components/text-input.es.js +1 -1
  598. package/dist/components/time-input.cjs +1 -1
  599. package/dist/components/time-input.es.js +1 -1
  600. package/dist/components/toast.cjs +1 -1
  601. package/dist/components/toast.es.js +1 -1
  602. package/dist/components/toggle-button.cjs +1 -1
  603. package/dist/components/toggle-button.es.js +1 -1
  604. package/dist/components/toolbar.cjs +1 -1
  605. package/dist/components/toolbar.es.js +1 -1
  606. package/dist/components/tree.cjs +1 -1
  607. package/dist/components/tree.es.js +1 -1
  608. package/dist/index.cjs +2 -2
  609. package/dist/index.cjs.map +1 -1
  610. package/dist/index.es.js +170 -162
  611. package/dist/index.es.js.map +1 -1
  612. package/dist/theme/keyframes.d.ts +11 -0
  613. package/dist/theme/recipes/index.d.ts +46 -0
  614. package/dist/theme/slot-recipes/index.d.ts +193 -0
  615. package/package.json +6 -6
  616. package/dist/chunks/DateField-DI1RhZqo.cjs +0 -2
  617. package/dist/chunks/Dialog-s5tFTj72.cjs +0 -6
  618. package/dist/chunks/ListBox-CXgfDQSn.cjs +0 -2
  619. package/dist/chunks/chat-message-list-BhWZEg4l.esm.js.map +0 -1
  620. package/dist/chunks/chat-message-list-BvzHnJHs.cjs +0 -2
  621. package/dist/chunks/chat-message-list-BvzHnJHs.cjs.map +0 -1
  622. package/dist/chunks/data-table-CHpJecej.cjs +0 -2
  623. package/dist/chunks/draggable-list-CKKl6A_a.cjs +0 -2
  624. package/dist/chunks/number-input-DU3522fK.cjs +0 -2
  625. package/dist/chunks/radio-input-_eEv0K2W.cjs +0 -2
  626. package/dist/chunks/select-DdeLYdJ3.cjs +0 -2
  627. package/dist/chunks/tab-nav-CunrpVeV.cjs +0 -2
  628. package/dist/chunks/tab-nav-CunrpVeV.cjs.map +0 -1
  629. package/dist/chunks/tab-nav-EHnsfeUM.esm.js +0 -99
  630. package/dist/chunks/tab-nav-EHnsfeUM.esm.js.map +0 -1
  631. package/dist/chunks/tabs-BbC8to5L.cjs +0 -2
  632. package/dist/chunks/tag-group-t9CCZs9w.cjs +0 -2
  633. package/dist/chunks/theme-BR3bc6tH.esm.js.map +0 -1
  634. package/dist/chunks/theme-tOoHVZZ6.cjs +0 -34
  635. package/dist/chunks/theme-tOoHVZZ6.cjs.map +0 -1
  636. package/dist/chunks/use-tree-CrwSJhB8.cjs +0 -2
  637. package/dist/chunks/useCollection-C04LezXC.cjs +0 -2
  638. package/dist/chunks/useCollection-C04LezXC.cjs.map +0 -1
  639. package/dist/chunks/useCollection-CGf4ZguH.esm.js.map +0 -1
  640. package/dist/chunks/useFormValidationState-B5e8EeJ8.cjs +0 -2
  641. package/dist/chunks/useFormValidationState-B5e8EeJ8.cjs.map +0 -1
  642. package/dist/chunks/useFormValidationState-rjMRhdnd.esm.js.map +0 -1
  643. package/dist/chunks/useProgressBar-DDrlZQv4.cjs +0 -2
  644. package/dist/chunks/useProgressBar-DDrlZQv4.cjs.map +0 -1
  645. package/dist/chunks/useProgressBar-DmcvqOjq.esm.js +0 -41
  646. package/dist/chunks/useProgressBar-DmcvqOjq.esm.js.map +0 -1
  647. package/dist/chunks/useTextField-CzF6gZ6-.cjs +0 -2
  648. package/dist/chunks/useToggle-DOG2OJN_.cjs +0 -2
@@ -1 +1 @@
1
- {"version":3,"file":"form-action-bar-C_pQubyB.cjs.js","names":[],"sources":["../../src/patterns/actions/form-action-bar/intl/en.ts","../../src/patterns/actions/form-action-bar/intl/de.ts","../../src/patterns/actions/form-action-bar/intl/es.ts","../../src/patterns/actions/form-action-bar/intl/fr-FR.ts","../../src/patterns/actions/form-action-bar/intl/pt-BR.ts","../../src/patterns/actions/form-action-bar/form-action-bar.messages.ts","../../src/patterns/actions/form-action-bar/form-action-bar.tsx"],"sourcesContent":["/**\n * Pre-compiled en messages for FormActionBar\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default {\n ariaLabel: `Form actions`,\n cancel: `Cancel`,\n delete: `Delete`,\n save: `Save`,\n};\n","/**\n * Pre-compiled de messages for FormActionBar\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default {\n ariaLabel: `Formular-Aktionen`,\n cancel: `Abbrechen`,\n delete: `Löschen`,\n save: `Speichern`,\n};\n","/**\n * Pre-compiled es messages for FormActionBar\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default {\n ariaLabel: `Crear acciones`,\n cancel: `Cancelar`,\n delete: `Eliminar`,\n save: `Guardar`,\n};\n","/**\n * Pre-compiled fr-FR messages for FormActionBar\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default {\n ariaLabel: `Actions du formulaire`,\n cancel: `Annuler`,\n delete: `Supprimer`,\n save: `Enregistrer`,\n};\n","/**\n * Pre-compiled pt-BR messages for FormActionBar\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default {\n ariaLabel: `Ações de formulários`,\n cancel: `Cancelar`,\n delete: `Excluir`,\n save: `Salvar`,\n};\n","/**\n * Pre-compiled localized messages for FormActionBar component\n *\n * Generated by scripts/generate-dictionaries.ts\n * DO NOT EDIT MANUALLY\n *\n * @see https://react-spectrum.adobe.com/react-aria/internationalization.html\n */\n\nimport {\n type LocalizedString,\n type LocalizedStrings,\n} from \"@internationalized/string\";\nimport { normalizeMessages } from \"../../../utils/normalize-messages\";\n\n// Pre-compiled message functions\nimport formActionBarMessages_en from \"./intl/en\";\nimport formActionBarMessages_de from \"./intl/de\";\nimport formActionBarMessages_es from \"./intl/es\";\nimport formActionBarMessages_fr from \"./intl/fr-FR\";\nimport formActionBarMessages_pt from \"./intl/pt-BR\";\n\n// Raw LocalizedStrings object for use with useLocalizedStringFormatter hook\nexport const formActionBarMessagesStrings: LocalizedStrings<\n string,\n LocalizedString\n> = {\n en: normalizeMessages(formActionBarMessages_en),\n de: normalizeMessages(formActionBarMessages_de),\n es: normalizeMessages(formActionBarMessages_es),\n \"fr-FR\": normalizeMessages(formActionBarMessages_fr),\n \"pt-BR\": normalizeMessages(formActionBarMessages_pt),\n} as LocalizedStrings<string, LocalizedString>;\n\n/**\n * Available message keys for FormActionBar component\n */\nexport type FormActionBarMessageKey =\n \"ariaLabel\" | \"cancel\" | \"delete\" | \"save\";\n","import { Button } from \"@/components/button/button\";\nimport { Group } from \"@/components/group/group\";\nimport { LoadingSpinner } from \"@/components/loading-spinner/loading-spinner\";\nimport { useLocalizedStringFormatter } from \"@/hooks\";\nimport { formActionBarMessagesStrings } from \"./form-action-bar.messages\";\nimport type { FormActionBarProps } from \"./form-action-bar.types\";\n\n/**\n * # FormActionBar\n *\n * A pattern providing save / cancel / optional delete buttons for form footers.\n *\n * Works inside any footer slot: `DefaultPage.Footer`, `ModalPage.Footer`,\n * `Drawer.Footer`, `Dialog.Footer`. Replaces separate form-page wrappers.\n *\n * @example\n * ```tsx\n * <FormActionBar\n * onSave={handleSave}\n * onCancel={handleCancel}\n * onDelete={handleDelete}\n * isSaveDisabled={!isDirty}\n * isSaveLoading={isSaving}\n * />\n * ```\n */\nexport const FormActionBar = ({\n onSave,\n onCancel,\n onDelete,\n saveLabel,\n cancelLabel,\n deleteLabel,\n isSaveDisabled = false,\n isSaveLoading = false,\n isDeleteLoading = false,\n \"aria-label\": ariaLabel,\n cancelSlot,\n buttonSize,\n}: FormActionBarProps) => {\n const msg = useLocalizedStringFormatter(formActionBarMessagesStrings);\n const isBusy = isSaveLoading || isDeleteLoading;\n\n const resolvedSaveLabel = saveLabel ?? msg.format(\"save\");\n const resolvedCancelLabel = cancelLabel ?? msg.format(\"cancel\");\n const resolvedDeleteLabel = deleteLabel ?? msg.format(\"delete\");\n const resolvedAriaLabel = ariaLabel ?? msg.format(\"ariaLabel\");\n\n return (\n <Group aria-label={resolvedAriaLabel} gap=\"300\">\n {onDelete && (\n <Button\n variant=\"solid\"\n colorPalette=\"critical\"\n size={buttonSize}\n isDisabled={isBusy}\n onPress={onDelete}\n data-slot=\"delete\"\n >\n {resolvedDeleteLabel}\n {isDeleteLoading && <LoadingSpinner ml=\"100\" size=\"2xs\" />}\n </Button>\n )}\n <Button\n variant=\"outline\"\n size={buttonSize}\n isDisabled={isBusy}\n onPress={onCancel}\n slot={cancelSlot}\n data-slot=\"cancel\"\n >\n {resolvedCancelLabel}\n </Button>\n <Button\n variant=\"solid\"\n colorPalette=\"primary\"\n size={buttonSize}\n isDisabled={isSaveDisabled || isBusy}\n onPress={onSave}\n data-slot=\"save\"\n >\n {resolvedSaveLabel}\n {isSaveLoading && <LoadingSpinner ml=\"100\" size=\"2xs\" />}\n </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Y,EACZ,QAAS,EACT,KAAM,EACN,YAAU,kBAET,CACK,CAAA,GACR,EAAA,EAAA,KAAA,CAAC,EAAA,EAAD,CACE,QAAQ,QACR,aAAa,UACb,KAAM,EACN,WAAY,GAAkB,EAC9B,QAAS,EACT,YAAU,gBANZ,CAQG,EACA,IAAiB,EAAA,EAAA,IAAA,CAAC,EAAA,EAAD,CAAgB,GAAG,MAAM,KAAK,KAAO,CAAA,CACjD,GACH,GAEX,EAEA,EAAc,YAAc"}
1
+ {"version":3,"file":"form-action-bar-DhmjijBw.cjs.js","names":[],"sources":["../../src/patterns/actions/form-action-bar/intl/en.ts","../../src/patterns/actions/form-action-bar/intl/de.ts","../../src/patterns/actions/form-action-bar/intl/es.ts","../../src/patterns/actions/form-action-bar/intl/fr-FR.ts","../../src/patterns/actions/form-action-bar/intl/pt-BR.ts","../../src/patterns/actions/form-action-bar/form-action-bar.messages.ts","../../src/patterns/actions/form-action-bar/form-action-bar.tsx"],"sourcesContent":["/**\n * Pre-compiled en messages for FormActionBar\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default {\n ariaLabel: `Form actions`,\n cancel: `Cancel`,\n delete: `Delete`,\n save: `Save`,\n};\n","/**\n * Pre-compiled de messages for FormActionBar\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default {\n ariaLabel: `Formular-Aktionen`,\n cancel: `Abbrechen`,\n delete: `Löschen`,\n save: `Speichern`,\n};\n","/**\n * Pre-compiled es messages for FormActionBar\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default {\n ariaLabel: `Crear acciones`,\n cancel: `Cancelar`,\n delete: `Eliminar`,\n save: `Guardar`,\n};\n","/**\n * Pre-compiled fr-FR messages for FormActionBar\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default {\n ariaLabel: `Actions du formulaire`,\n cancel: `Annuler`,\n delete: `Supprimer`,\n save: `Enregistrer`,\n};\n","/**\n * Pre-compiled pt-BR messages for FormActionBar\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default {\n ariaLabel: `Ações de formulários`,\n cancel: `Cancelar`,\n delete: `Excluir`,\n save: `Salvar`,\n};\n","/**\n * Pre-compiled localized messages for FormActionBar component\n *\n * Generated by scripts/generate-dictionaries.ts\n * DO NOT EDIT MANUALLY\n *\n * @see https://react-spectrum.adobe.com/react-aria/internationalization.html\n */\n\nimport {\n type LocalizedString,\n type LocalizedStrings,\n} from \"@internationalized/string\";\nimport { normalizeMessages } from \"../../../utils/normalize-messages\";\n\n// Pre-compiled message functions\nimport formActionBarMessages_en from \"./intl/en\";\nimport formActionBarMessages_de from \"./intl/de\";\nimport formActionBarMessages_es from \"./intl/es\";\nimport formActionBarMessages_fr from \"./intl/fr-FR\";\nimport formActionBarMessages_pt from \"./intl/pt-BR\";\n\n// Raw LocalizedStrings object for use with useLocalizedStringFormatter hook\nexport const formActionBarMessagesStrings: LocalizedStrings<\n string,\n LocalizedString\n> = {\n en: normalizeMessages(formActionBarMessages_en),\n de: normalizeMessages(formActionBarMessages_de),\n es: normalizeMessages(formActionBarMessages_es),\n \"fr-FR\": normalizeMessages(formActionBarMessages_fr),\n \"pt-BR\": normalizeMessages(formActionBarMessages_pt),\n} as LocalizedStrings<string, LocalizedString>;\n\n/**\n * Available message keys for FormActionBar component\n */\nexport type FormActionBarMessageKey =\n \"ariaLabel\" | \"cancel\" | \"delete\" | \"save\";\n","import { Button } from \"@/components/button/button\";\nimport { Group } from \"@/components/group/group\";\nimport { LoadingSpinner } from \"@/components/loading-spinner/loading-spinner\";\nimport { useLocalizedStringFormatter } from \"@/hooks\";\nimport { formActionBarMessagesStrings } from \"./form-action-bar.messages\";\nimport type { FormActionBarProps } from \"./form-action-bar.types\";\n\n/**\n * # FormActionBar\n *\n * A pattern providing save / cancel / optional delete buttons for form footers.\n *\n * Works inside any footer slot: `DefaultPage.Footer`, `ModalPage.Footer`,\n * `Drawer.Footer`, `Dialog.Footer`. Replaces separate form-page wrappers.\n *\n * @example\n * ```tsx\n * <FormActionBar\n * onSave={handleSave}\n * onCancel={handleCancel}\n * onDelete={handleDelete}\n * isSaveDisabled={!isDirty}\n * isSaveLoading={isSaving}\n * />\n * ```\n */\nexport const FormActionBar = ({\n onSave,\n onCancel,\n onDelete,\n saveLabel,\n cancelLabel,\n deleteLabel,\n isSaveDisabled = false,\n isSaveLoading = false,\n isDeleteLoading = false,\n \"aria-label\": ariaLabel,\n cancelSlot,\n buttonSize,\n}: FormActionBarProps) => {\n const msg = useLocalizedStringFormatter(formActionBarMessagesStrings);\n const isBusy = isSaveLoading || isDeleteLoading;\n\n const resolvedSaveLabel = saveLabel ?? msg.format(\"save\");\n const resolvedCancelLabel = cancelLabel ?? msg.format(\"cancel\");\n const resolvedDeleteLabel = deleteLabel ?? msg.format(\"delete\");\n const resolvedAriaLabel = ariaLabel ?? msg.format(\"ariaLabel\");\n\n return (\n <Group aria-label={resolvedAriaLabel} gap=\"300\">\n {onDelete && (\n <Button\n variant=\"solid\"\n colorPalette=\"critical\"\n size={buttonSize}\n isDisabled={isBusy}\n onPress={onDelete}\n data-slot=\"delete\"\n >\n {resolvedDeleteLabel}\n {isDeleteLoading && <LoadingSpinner ml=\"100\" size=\"2xs\" />}\n </Button>\n )}\n <Button\n variant=\"outline\"\n size={buttonSize}\n isDisabled={isBusy}\n onPress={onCancel}\n slot={cancelSlot}\n data-slot=\"cancel\"\n >\n {resolvedCancelLabel}\n </Button>\n <Button\n variant=\"solid\"\n colorPalette=\"primary\"\n size={buttonSize}\n isDisabled={isSaveDisabled || isBusy}\n onPress={onSave}\n data-slot=\"save\"\n >\n {resolvedSaveLabel}\n {isSaveLoading && <LoadingSpinner ml=\"100\" size=\"2xs\" />}\n </Button>\n </Group>\n );\n};\n\nFormActionBar.displayName = \"FormActionBar\";\n"],"mappings":"qNKuBA,IAAa,EAGT,CACF,GAAI,EAAA,EAAkB,CLpBtB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AAa,UACb,KAAM,EACN,WAAY,GAAkB,EAC9B,QAAS,EACT,YAAU,gBANZ,CAQG,EACA,IAAiB,EAAA,EAAA,IAAA,CAAC,EAAA,EAAD,CAAgB,GAAG,MAAM,KAAK,KAAO,CAAA,CACjD,GACH,GAEX,EAEA,EAAc,YAAc"}
@@ -1,2 +1,2 @@
1
- const e=require("./useControlledState-C-8MHM79.cjs.js"),t=require("./loading-spinner-DAZGwhe6.cjs.js"),n=require("./normalize-messages-BMq9y_ae.cjs.js"),r=require("./dialog-Y4HKBxUr.cjs.js"),i=require("./button-Dc_J_PNN.cjs.js");let a=require("react/jsx-runtime");var o={en:n.t({cancel:`Cancel`,save:`Save`}),de:n.t({cancel:`Abbrechen`,save:`Speichern`}),es:n.t({cancel:`Cancelar`,save:`Guardar`}),"fr-FR":n.t({cancel:`Annuler`,save:`Enregistrer`}),"pt-BR":n.t({cancel:`Cancelar`,save:`Salvar`})},s=({title:s,children:c,onSave:l,onCancel:u,isOpen:d,defaultOpen:f,onOpenChange:p,saveLabel:m,cancelLabel:h,isSaveDisabled:g=!1,isSaveLoading:_=!1,"aria-label":v})=>{let y=n.n(o),[b,x]=e.t(d,f??!1,p),S=m??y.format(`save`),C=h??y.format(`cancel`);return(0,a.jsx)(r.t.Root,{isOpen:b,onOpenChange:e=>{e||u(),x(e)},"aria-label":v,isDismissable:!_,isKeyboardDismissDisabled:_,scrollBehavior:`inside`,children:(0,a.jsxs)(r.t.Content,{children:[(0,a.jsxs)(r.t.Header,{children:[(0,a.jsx)(r.t.Title,{children:s}),(0,a.jsx)(r.t.CloseTrigger,{isDisabled:_})]}),(0,a.jsx)(r.t.Body,{children:c}),(0,a.jsxs)(r.t.Footer,{children:[(0,a.jsx)(i.t,{variant:`outline`,isDisabled:_,onPress:()=>{u(),x(!1)},children:C}),(0,a.jsxs)(i.t,{variant:`solid`,colorPalette:`primary`,isDisabled:g||_,onPress:async()=>{let e=l();if(e instanceof Promise)try{await e,x(!1)}catch{}else x(!1)},children:[S,_&&(0,a.jsx)(t.t,{ml:`100`,size:`2xs`})]})]})]})})};s.displayName=`FormDialog`,Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return s}});
2
- //# sourceMappingURL=form-dialog-D14UuUnS.cjs.js.map
1
+ const e=require("./useControlledState-C-8MHM79.cjs.js"),t=require("./loading-spinner-p_cYuGNg.cjs.js"),n=require("./normalize-messages-BMq9y_ae.cjs.js"),r=require("./dialog-CwCG4NKh.cjs.js"),i=require("./button-D6f5OX0h.cjs.js");let a=require("react/jsx-runtime");var o={en:n.t({cancel:`Cancel`,save:`Save`}),de:n.t({cancel:`Abbrechen`,save:`Speichern`}),es:n.t({cancel:`Cancelar`,save:`Guardar`}),"fr-FR":n.t({cancel:`Annuler`,save:`Enregistrer`}),"pt-BR":n.t({cancel:`Cancelar`,save:`Salvar`})},s=({title:s,children:c,onSave:l,onCancel:u,isOpen:d,defaultOpen:f,onOpenChange:p,saveLabel:m,cancelLabel:h,isSaveDisabled:g=!1,isSaveLoading:_=!1,"aria-label":v})=>{let y=n.n(o),[b,x]=e.t(d,f??!1,p),S=m??y.format(`save`),C=h??y.format(`cancel`);return(0,a.jsx)(r.t.Root,{isOpen:b,onOpenChange:e=>{e||u(),x(e)},"aria-label":v,isDismissable:!_,isKeyboardDismissDisabled:_,scrollBehavior:`inside`,children:(0,a.jsxs)(r.t.Content,{children:[(0,a.jsxs)(r.t.Header,{children:[(0,a.jsx)(r.t.Title,{children:s}),(0,a.jsx)(r.t.CloseTrigger,{isDisabled:_})]}),(0,a.jsx)(r.t.Body,{children:c}),(0,a.jsxs)(r.t.Footer,{children:[(0,a.jsx)(i.t,{variant:`outline`,isDisabled:_,onPress:()=>{u(),x(!1)},children:C}),(0,a.jsxs)(i.t,{variant:`solid`,colorPalette:`primary`,isDisabled:g||_,onPress:async()=>{let e=l();if(e instanceof Promise)try{await e,x(!1)}catch{}else x(!1)},children:[S,_&&(0,a.jsx)(t.t,{ml:`100`,size:`2xs`})]})]})]})})};s.displayName=`FormDialog`,Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return s}});
2
+ //# sourceMappingURL=form-dialog-CLrL718p.cjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"form-dialog-D14UuUnS.cjs.js","names":[],"sources":["../../src/patterns/dialogs/form-dialog/intl/en.ts","../../src/patterns/dialogs/form-dialog/intl/de.ts","../../src/patterns/dialogs/form-dialog/intl/es.ts","../../src/patterns/dialogs/form-dialog/intl/fr-FR.ts","../../src/patterns/dialogs/form-dialog/intl/pt-BR.ts","../../src/patterns/dialogs/form-dialog/form-dialog.messages.ts","../../src/patterns/dialogs/form-dialog/form-dialog.tsx"],"sourcesContent":["/**\n * Pre-compiled en messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Cancel`, save: `Save` };\n","/**\n * Pre-compiled de messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Abbrechen`, save: `Speichern` };\n","/**\n * Pre-compiled es messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Cancelar`, save: `Guardar` };\n","/**\n * Pre-compiled fr-FR messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Annuler`, save: `Enregistrer` };\n","/**\n * Pre-compiled pt-BR messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Cancelar`, save: `Salvar` };\n","/**\n * Pre-compiled localized messages for FormDialog component\n *\n * Generated by scripts/generate-dictionaries.ts\n * DO NOT EDIT MANUALLY\n *\n * @see https://react-spectrum.adobe.com/react-aria/internationalization.html\n */\n\nimport {\n type LocalizedString,\n type LocalizedStrings,\n} from \"@internationalized/string\";\nimport { normalizeMessages } from \"../../../utils/normalize-messages\";\n\n// Pre-compiled message functions\nimport formDialogMessages_en from \"./intl/en\";\nimport formDialogMessages_de from \"./intl/de\";\nimport formDialogMessages_es from \"./intl/es\";\nimport formDialogMessages_fr from \"./intl/fr-FR\";\nimport formDialogMessages_pt from \"./intl/pt-BR\";\n\n// Raw LocalizedStrings object for use with useLocalizedStringFormatter hook\nexport const formDialogMessagesStrings: LocalizedStrings<\n string,\n LocalizedString\n> = {\n en: normalizeMessages(formDialogMessages_en),\n de: normalizeMessages(formDialogMessages_de),\n es: normalizeMessages(formDialogMessages_es),\n \"fr-FR\": normalizeMessages(formDialogMessages_fr),\n \"pt-BR\": normalizeMessages(formDialogMessages_pt),\n} as LocalizedStrings<string, LocalizedString>;\n\n/**\n * Available message keys for FormDialog component\n */\nexport type FormDialogMessageKey = \"cancel\" | \"save\";\n","import { useControlledState } from \"react-stately/useControlledState\";\nimport { Button } from \"@/components/button/button\";\nimport { Dialog } from \"@/components/dialog/dialog\";\nimport { LoadingSpinner } from \"@/components/loading-spinner/loading-spinner\";\nimport { useLocalizedStringFormatter } from \"@/hooks\";\nimport { formDialogMessagesStrings } from \"./form-dialog.messages\";\nimport type { FormDialogProps } from \"./form-dialog.types\";\n\n/**\n * # FormDialog\n *\n * A pre-composed save/cancel dialog pattern built on top of the Nimbus\n * `Dialog` and `Button` primitives, shaped for hosting an editable form\n * in the body. Exposes a flat API (`title`, `children`, `onSave`,\n * `onCancel`, plus optional state, label, and accessibility props) for\n * the common case of editing data inside a modal.\n *\n * Close affordances: clicking the cancel button, the X button in the\n * header, pressing Escape, or clicking the overlay all invoke\n * `onCancel` and `onOpenChange(false)`. Clicking the save button\n * invokes `onSave` and then closes — synchronously for `void` returns,\n * or after the returned `Promise` fulfills for async saves; rejected\n * promises leave the dialog open so the consumer can surface\n * validation errors. The save path never fires `onCancel`.\n *\n * When `isSaveLoading` is `true` the entire dialog is locked: the save\n * button shows a spinner and is disabled, the cancel button is\n * disabled, and Escape / overlay click / close-button click are all\n * suppressed.\n *\n * The pattern does not wrap `children` in a native `<form>` element.\n * Consumers wanting Enter-to-submit semantics or browser-native\n * validation should wrap their fields in\n * `<form onSubmit={handleSubmit}>` inside `children` and call `onSave`\n * from `handleSubmit`.\n *\n * @example\n * ```tsx\n * const [isOpen, setIsOpen] = useState(false);\n *\n * <FormDialog\n * title=\"Edit profile\"\n * isOpen={isOpen}\n * onOpenChange={setIsOpen}\n * onSave={handleSave}\n * onCancel={() => setIsOpen(false)}\n * isSaveDisabled={!isDirty}\n * >\n * <TextInput label=\"Display name\" value={name} onChange={setName} />\n * </FormDialog>\n * ```\n */\nexport const FormDialog = ({\n title,\n children,\n onSave,\n onCancel,\n isOpen,\n defaultOpen,\n onOpenChange,\n saveLabel,\n cancelLabel,\n isSaveDisabled = false,\n isSaveLoading = false,\n \"aria-label\": ariaLabel,\n}: FormDialogProps) => {\n const msg = useLocalizedStringFormatter(formDialogMessagesStrings);\n\n // Internalize open state so we can close the dialog from our cancel\n // and save buttons without relying on `slot=\"close\"` (which races\n // its `onOpenChange` notification against the button's `onPress`\n // handler and double-fires the cancel callback).\n const [open, setOpen] = useControlledState<boolean>(\n isOpen,\n defaultOpen ?? false,\n onOpenChange\n );\n\n const resolvedSaveLabel = saveLabel ?? msg.format(\"save\");\n const resolvedCancelLabel = cancelLabel ?? msg.format(\"cancel\");\n\n const handleSave = async () => {\n const result = onSave();\n // If the consumer returns a Promise, wait for it to settle before\n // closing — otherwise the dialog vanishes synchronously and the\n // consumer's `isSaveLoading` lockout never paints. On rejection we\n // stay open so the consumer can surface validation errors and let\n // the user retry.\n if (result instanceof Promise) {\n try {\n await result;\n setOpen(false);\n } catch {\n // intentional: stay open on rejection\n }\n } else {\n setOpen(false);\n }\n };\n\n const handleCancelButton = () => {\n onCancel();\n setOpen(false);\n };\n\n // `Dialog.Root` invokes its `onOpenChange` for dismiss paths not\n // driven by an explicit `onPress` in this component — Escape,\n // overlay click, and the close-button X. Our cancel and save buttons\n // close via `setOpen(false)` directly and do NOT route through this\n // callback. The X close button is owned by the pattern via\n // `isDisabled={isSaveLoading}`, so this handler does not need to\n // re-check the loading flag for it.\n const handleAmbientOpenChange = (newOpen: boolean) => {\n if (!newOpen) {\n onCancel();\n }\n setOpen(newOpen);\n };\n\n return (\n <Dialog.Root\n isOpen={open}\n onOpenChange={handleAmbientOpenChange}\n aria-label={ariaLabel}\n isDismissable={!isSaveLoading}\n isKeyboardDismissDisabled={isSaveLoading}\n scrollBehavior=\"inside\"\n >\n <Dialog.Content>\n <Dialog.Header>\n <Dialog.Title>{title}</Dialog.Title>\n <Dialog.CloseTrigger isDisabled={isSaveLoading} />\n </Dialog.Header>\n <Dialog.Body>{children}</Dialog.Body>\n <Dialog.Footer>\n <Button\n variant=\"outline\"\n isDisabled={isSaveLoading}\n onPress={handleCancelButton}\n >\n {resolvedCancelLabel}\n </Button>\n <Button\n variant=\"solid\"\n colorPalette=\"primary\"\n isDisabled={isSaveDisabled || isSaveLoading}\n onPress={handleSave}\n >\n {resolvedSaveLabel}\n {isSaveLoading && <LoadingSpinner ml=\"100\" size=\"2xs\" />}\n </Button>\n </Dialog.Footer>\n </Dialog.Content>\n </Dialog.Root>\n );\n};\n\nFormDialog.displayName = \"FormDialog\";\n"],"mappings":"wQKuBA,IAAa,EAGT,CACF,GAAI,EAAA,EAAkB,CLrBP,OAAQ,SAAU,KAAM,MKqBjB,CAAqB,EAC3C,GAAI,EAAA,EAAkB,CJtBP,OAAQ,YAAa,KAAM,WIsBpB,CAAqB,EAC3C,GAAI,EAAA,EAAkB,CHvBP,OAAQ,WAAY,KAAM,SGuBnB,CAAqB,EAC3C,QAAS,EAAA,EAAkB,CFxBZ,OAAQ,UAAW,KAAM,aEwBb,CAAqB,EAChD,QAAS,EAAA,EAAkB,CDzBZ,OAAQ,WAAY,KAAM,QCyBd,CAAqB,CAClD,ECoBa,GAAc,CACzB,QACA,WACA,SACA,WACA,SACA,cACA,eACA,YACA,cACA,iBAAiB,GACjB,gBAAgB,GAChB,aAAc,KACO,CACrB,IAAM,EAAM,EAAA,EAA4B,CAAyB,EA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A,CACL,CAAA,CAEjB,EAEA,EAAW,YAAc"}
1
+ {"version":3,"file":"form-dialog-CLrL718p.cjs.js","names":[],"sources":["../../src/patterns/dialogs/form-dialog/intl/en.ts","../../src/patterns/dialogs/form-dialog/intl/de.ts","../../src/patterns/dialogs/form-dialog/intl/es.ts","../../src/patterns/dialogs/form-dialog/intl/fr-FR.ts","../../src/patterns/dialogs/form-dialog/intl/pt-BR.ts","../../src/patterns/dialogs/form-dialog/form-dialog.messages.ts","../../src/patterns/dialogs/form-dialog/form-dialog.tsx"],"sourcesContent":["/**\n * Pre-compiled en messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Cancel`, save: `Save` };\n","/**\n * Pre-compiled de messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Abbrechen`, save: `Speichern` };\n","/**\n * Pre-compiled es messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Cancelar`, save: `Guardar` };\n","/**\n * Pre-compiled fr-FR messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Annuler`, save: `Enregistrer` };\n","/**\n * Pre-compiled pt-BR messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Cancelar`, save: `Salvar` };\n","/**\n * Pre-compiled localized messages for FormDialog component\n *\n * Generated by scripts/generate-dictionaries.ts\n * DO NOT EDIT MANUALLY\n *\n * @see https://react-spectrum.adobe.com/react-aria/internationalization.html\n */\n\nimport {\n type LocalizedString,\n type LocalizedStrings,\n} from \"@internationalized/string\";\nimport { normalizeMessages } from \"../../../utils/normalize-messages\";\n\n// Pre-compiled message functions\nimport formDialogMessages_en from \"./intl/en\";\nimport formDialogMessages_de from \"./intl/de\";\nimport formDialogMessages_es from \"./intl/es\";\nimport formDialogMessages_fr from \"./intl/fr-FR\";\nimport formDialogMessages_pt from \"./intl/pt-BR\";\n\n// Raw LocalizedStrings object for use with useLocalizedStringFormatter hook\nexport const formDialogMessagesStrings: LocalizedStrings<\n string,\n LocalizedString\n> = {\n en: normalizeMessages(formDialogMessages_en),\n de: normalizeMessages(formDialogMessages_de),\n es: normalizeMessages(formDialogMessages_es),\n \"fr-FR\": normalizeMessages(formDialogMessages_fr),\n \"pt-BR\": normalizeMessages(formDialogMessages_pt),\n} as LocalizedStrings<string, LocalizedString>;\n\n/**\n * Available message keys for FormDialog component\n */\nexport type FormDialogMessageKey = \"cancel\" | \"save\";\n","import { useControlledState } from \"react-stately/useControlledState\";\nimport { Button } from \"@/components/button/button\";\nimport { Dialog } from \"@/components/dialog/dialog\";\nimport { LoadingSpinner } from \"@/components/loading-spinner/loading-spinner\";\nimport { useLocalizedStringFormatter } from \"@/hooks\";\nimport { formDialogMessagesStrings } from \"./form-dialog.messages\";\nimport type { FormDialogProps } from \"./form-dialog.types\";\n\n/**\n * # FormDialog\n *\n * A pre-composed save/cancel dialog pattern built on top of the Nimbus\n * `Dialog` and `Button` primitives, shaped for hosting an editable form\n * in the body. Exposes a flat API (`title`, `children`, `onSave`,\n * `onCancel`, plus optional state, label, and accessibility props) for\n * the common case of editing data inside a modal.\n *\n * Close affordances: clicking the cancel button, the X button in the\n * header, pressing Escape, or clicking the overlay all invoke\n * `onCancel` and `onOpenChange(false)`. Clicking the save button\n * invokes `onSave` and then closes — synchronously for `void` returns,\n * or after the returned `Promise` fulfills for async saves; rejected\n * promises leave the dialog open so the consumer can surface\n * validation errors. The save path never fires `onCancel`.\n *\n * When `isSaveLoading` is `true` the entire dialog is locked: the save\n * button shows a spinner and is disabled, the cancel button is\n * disabled, and Escape / overlay click / close-button click are all\n * suppressed.\n *\n * The pattern does not wrap `children` in a native `<form>` element.\n * Consumers wanting Enter-to-submit semantics or browser-native\n * validation should wrap their fields in\n * `<form onSubmit={handleSubmit}>` inside `children` and call `onSave`\n * from `handleSubmit`.\n *\n * @example\n * ```tsx\n * const [isOpen, setIsOpen] = useState(false);\n *\n * <FormDialog\n * title=\"Edit profile\"\n * isOpen={isOpen}\n * onOpenChange={setIsOpen}\n * onSave={handleSave}\n * onCancel={() => setIsOpen(false)}\n * isSaveDisabled={!isDirty}\n * >\n * <TextInput label=\"Display name\" value={name} onChange={setName} />\n * </FormDialog>\n * ```\n */\nexport const FormDialog = ({\n title,\n children,\n onSave,\n onCancel,\n isOpen,\n defaultOpen,\n onOpenChange,\n saveLabel,\n cancelLabel,\n isSaveDisabled = false,\n isSaveLoading = false,\n \"aria-label\": ariaLabel,\n}: FormDialogProps) => {\n const msg = useLocalizedStringFormatter(formDialogMessagesStrings);\n\n // Internalize open state so we can close the dialog from our cancel\n // and save buttons without relying on `slot=\"close\"` (which races\n // its `onOpenChange` notification against the button's `onPress`\n // handler and double-fires the cancel callback).\n const [open, setOpen] = useControlledState<boolean>(\n isOpen,\n defaultOpen ?? false,\n onOpenChange\n );\n\n const resolvedSaveLabel = saveLabel ?? msg.format(\"save\");\n const resolvedCancelLabel = cancelLabel ?? msg.format(\"cancel\");\n\n const handleSave = async () => {\n const result = onSave();\n // If the consumer returns a Promise, wait for it to settle before\n // closing — otherwise the dialog vanishes synchronously and the\n // consumer's `isSaveLoading` lockout never paints. On rejection we\n // stay open so the consumer can surface validation errors and let\n // the user retry.\n if (result instanceof Promise) {\n try {\n await result;\n setOpen(false);\n } catch {\n // intentional: stay open on rejection\n }\n } else {\n setOpen(false);\n }\n };\n\n const handleCancelButton = () => {\n onCancel();\n setOpen(false);\n };\n\n // `Dialog.Root` invokes its `onOpenChange` for dismiss paths not\n // driven by an explicit `onPress` in this component — Escape,\n // overlay click, and the close-button X. Our cancel and save buttons\n // close via `setOpen(false)` directly and do NOT route through this\n // callback. The X close button is owned by the pattern via\n // `isDisabled={isSaveLoading}`, so this handler does not need to\n // re-check the loading flag for it.\n const handleAmbientOpenChange = (newOpen: boolean) => {\n if (!newOpen) {\n onCancel();\n }\n setOpen(newOpen);\n };\n\n return (\n <Dialog.Root\n isOpen={open}\n onOpenChange={handleAmbientOpenChange}\n aria-label={ariaLabel}\n isDismissable={!isSaveLoading}\n isKeyboardDismissDisabled={isSaveLoading}\n scrollBehavior=\"inside\"\n >\n <Dialog.Content>\n <Dialog.Header>\n <Dialog.Title>{title}</Dialog.Title>\n <Dialog.CloseTrigger isDisabled={isSaveLoading} />\n </Dialog.Header>\n <Dialog.Body>{children}</Dialog.Body>\n <Dialog.Footer>\n <Button\n variant=\"outline\"\n isDisabled={isSaveLoading}\n onPress={handleCancelButton}\n >\n {resolvedCancelLabel}\n </Button>\n <Button\n variant=\"solid\"\n colorPalette=\"primary\"\n isDisabled={isSaveDisabled || isSaveLoading}\n onPress={handleSave}\n >\n {resolvedSaveLabel}\n {isSaveLoading && <LoadingSpinner ml=\"100\" size=\"2xs\" />}\n </Button>\n </Dialog.Footer>\n </Dialog.Content>\n </Dialog.Root>\n );\n};\n\nFormDialog.displayName = \"FormDialog\";\n"],"mappings":"wQKuBA,IAAa,EAGT,CACF,GAAI,EAAA,EAAkB,CLrBP,OAAQ,SAAU,KAAM,MKqBjB,CAAqB,EAC3C,GAAI,EAAA,EAAkB,CJtBP,OAAQ,YAAa,KAAM,WIsBpB,CAAqB,EAC3C,GAAI,EAAA,EAAkB,CHvBP,OAAQ,WAAY,KAAM,SGuBnB,CAAqB,EAC3C,QAAS,EAAA,EAAkB,CFxBZ,OAAQ,UAAW,KAAM,aEwBb,CAAqB,EAChD,QAAS,EAAA,EAAkB,CDzBZ,OAAQ,WAAY,KAAM,QCyBd,CAAqB,CAClD,ECoBa,GAAc,CACzB,QACA,WACA,SACA,WACA,SACA,cACA,eACA,YACA,cACA,iBAAiB,GACjB,gBAAgB,GAChB,aAAc,KACO,CACrB,IAAM,EAAM,EAAA,EAA4B,CAAyB,EAM3D,CAAC,EAAM,GAAW,EAAA,EACtB,EACA,GAAe,GACf,CACF,EAEM,EAAoB,GAA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} from "./useControlledState-DH1pZlhP.esm.js";
2
- import { t } from "./loading-spinner-CTPm1sYC.esm.js";
2
+ import { t } from "./loading-spinner-DZoySVDH.esm.js";
3
3
  import { n, t as r } from "./normalize-messages-B_f-0I5n.esm.js";
4
- import { t as i } from "./dialog-XeM4qOa_.esm.js";
5
- import { t as a } from "./button-BhvlZrT2.esm.js";
4
+ import { t as i } from "./dialog-lxgomHvu.esm.js";
5
+ import { t as a } from "./button-DyM-iqBq.esm.js";
6
6
  import { jsx as o, jsxs as s } from "react/jsx-runtime";
7
7
  //#endregion
8
8
  //#region src/patterns/dialogs/form-dialog/form-dialog.messages.ts
@@ -71,4 +71,4 @@ l.displayName = "FormDialog";
71
71
  //#endregion
72
72
  export { l as t };
73
73
 
74
- //# sourceMappingURL=form-dialog-BaD03TZo.esm.js.map
74
+ //# sourceMappingURL=form-dialog-D86jNeIZ.esm.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"form-dialog-BaD03TZo.esm.js","names":[],"sources":["../../src/patterns/dialogs/form-dialog/intl/en.ts","../../src/patterns/dialogs/form-dialog/intl/de.ts","../../src/patterns/dialogs/form-dialog/intl/es.ts","../../src/patterns/dialogs/form-dialog/intl/fr-FR.ts","../../src/patterns/dialogs/form-dialog/intl/pt-BR.ts","../../src/patterns/dialogs/form-dialog/form-dialog.messages.ts","../../src/patterns/dialogs/form-dialog/form-dialog.tsx"],"sourcesContent":["/**\n * Pre-compiled en messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Cancel`, save: `Save` };\n","/**\n * Pre-compiled de messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Abbrechen`, save: `Speichern` };\n","/**\n * Pre-compiled es messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Cancelar`, save: `Guardar` };\n","/**\n * Pre-compiled fr-FR messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Annuler`, save: `Enregistrer` };\n","/**\n * Pre-compiled pt-BR messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Cancelar`, save: `Salvar` };\n","/**\n * Pre-compiled localized messages for FormDialog component\n *\n * Generated by scripts/generate-dictionaries.ts\n * DO NOT EDIT MANUALLY\n *\n * @see https://react-spectrum.adobe.com/react-aria/internationalization.html\n */\n\nimport {\n type LocalizedString,\n type LocalizedStrings,\n} from \"@internationalized/string\";\nimport { normalizeMessages } from \"../../../utils/normalize-messages\";\n\n// Pre-compiled message functions\nimport formDialogMessages_en from \"./intl/en\";\nimport formDialogMessages_de from \"./intl/de\";\nimport formDialogMessages_es from \"./intl/es\";\nimport formDialogMessages_fr from \"./intl/fr-FR\";\nimport formDialogMessages_pt from \"./intl/pt-BR\";\n\n// Raw LocalizedStrings object for use with useLocalizedStringFormatter hook\nexport const formDialogMessagesStrings: LocalizedStrings<\n string,\n LocalizedString\n> = {\n en: normalizeMessages(formDialogMessages_en),\n de: normalizeMessages(formDialogMessages_de),\n es: normalizeMessages(formDialogMessages_es),\n \"fr-FR\": normalizeMessages(formDialogMessages_fr),\n \"pt-BR\": normalizeMessages(formDialogMessages_pt),\n} as LocalizedStrings<string, LocalizedString>;\n\n/**\n * Available message keys for FormDialog component\n */\nexport type FormDialogMessageKey = \"cancel\" | \"save\";\n","import { useControlledState } from \"react-stately/useControlledState\";\nimport { Button } from \"@/components/button/button\";\nimport { Dialog } from \"@/components/dialog/dialog\";\nimport { LoadingSpinner } from \"@/components/loading-spinner/loading-spinner\";\nimport { useLocalizedStringFormatter } from \"@/hooks\";\nimport { formDialogMessagesStrings } from \"./form-dialog.messages\";\nimport type { FormDialogProps } from \"./form-dialog.types\";\n\n/**\n * # FormDialog\n *\n * A pre-composed save/cancel dialog pattern built on top of the Nimbus\n * `Dialog` and `Button` primitives, shaped for hosting an editable form\n * in the body. Exposes a flat API (`title`, `children`, `onSave`,\n * `onCancel`, plus optional state, label, and accessibility props) for\n * the common case of editing data inside a modal.\n *\n * Close affordances: clicking the cancel button, the X button in the\n * header, pressing Escape, or clicking the overlay all invoke\n * `onCancel` and `onOpenChange(false)`. Clicking the save button\n * invokes `onSave` and then closes — synchronously for `void` returns,\n * or after the returned `Promise` fulfills for async saves; rejected\n * promises leave the dialog open so the consumer can surface\n * validation errors. The save path never fires `onCancel`.\n *\n * When `isSaveLoading` is `true` the entire dialog is locked: the save\n * button shows a spinner and is disabled, the cancel button is\n * disabled, and Escape / overlay click / close-button click are all\n * suppressed.\n *\n * The pattern does not wrap `children` in a native `<form>` element.\n * Consumers wanting Enter-to-submit semantics or browser-native\n * validation should wrap their fields in\n * `<form onSubmit={handleSubmit}>` inside `children` and call `onSave`\n * from `handleSubmit`.\n *\n * @example\n * ```tsx\n * const [isOpen, setIsOpen] = useState(false);\n *\n * <FormDialog\n * title=\"Edit profile\"\n * isOpen={isOpen}\n * onOpenChange={setIsOpen}\n * onSave={handleSave}\n * onCancel={() => setIsOpen(false)}\n * isSaveDisabled={!isDirty}\n * >\n * <TextInput label=\"Display name\" value={name} onChange={setName} />\n * </FormDialog>\n * ```\n */\nexport const FormDialog = ({\n title,\n children,\n onSave,\n onCancel,\n isOpen,\n defaultOpen,\n onOpenChange,\n saveLabel,\n cancelLabel,\n isSaveDisabled = false,\n isSaveLoading = false,\n \"aria-label\": ariaLabel,\n}: FormDialogProps) => {\n const msg = useLocalizedStringFormatter(formDialogMessagesStrings);\n\n // Internalize open state so we can close the dialog from our cancel\n // and save buttons without relying on `slot=\"close\"` (which races\n // its `onOpenChange` notification against the button's `onPress`\n // handler and double-fires the cancel callback).\n const [open, setOpen] = useControlledState<boolean>(\n isOpen,\n defaultOpen ?? false,\n onOpenChange\n );\n\n const resolvedSaveLabel = saveLabel ?? msg.format(\"save\");\n const resolvedCancelLabel = cancelLabel ?? msg.format(\"cancel\");\n\n const handleSave = async () => {\n const result = onSave();\n // If the consumer returns a Promise, wait for it to settle before\n // closing — otherwise the dialog vanishes synchronously and the\n // consumer's `isSaveLoading` lockout never paints. On rejection we\n // stay open so the consumer can surface validation errors and let\n // the user retry.\n if (result instanceof Promise) {\n try {\n await result;\n setOpen(false);\n } catch {\n // intentional: stay open on rejection\n }\n } else {\n setOpen(false);\n }\n };\n\n const handleCancelButton = () => {\n onCancel();\n setOpen(false);\n };\n\n // `Dialog.Root` invokes its `onOpenChange` for dismiss paths not\n // driven by an explicit `onPress` in this component — Escape,\n // overlay click, and the close-button X. Our cancel and save buttons\n // close via `setOpen(false)` directly and do NOT route through this\n // callback. The X close button is owned by the pattern via\n // `isDisabled={isSaveLoading}`, so this handler does not need to\n // re-check the loading flag for it.\n const handleAmbientOpenChange = (newOpen: boolean) => {\n if (!newOpen) {\n onCancel();\n }\n setOpen(newOpen);\n };\n\n return (\n <Dialog.Root\n isOpen={open}\n onOpenChange={handleAmbientOpenChange}\n aria-label={ariaLabel}\n isDismissable={!isSaveLoading}\n isKeyboardDismissDisabled={isSaveLoading}\n scrollBehavior=\"inside\"\n >\n <Dialog.Content>\n <Dialog.Header>\n <Dialog.Title>{title}</Dialog.Title>\n <Dialog.CloseTrigger isDisabled={isSaveLoading} />\n </Dialog.Header>\n <Dialog.Body>{children}</Dialog.Body>\n <Dialog.Footer>\n <Button\n variant=\"outline\"\n isDisabled={isSaveLoading}\n onPress={handleCancelButton}\n >\n {resolvedCancelLabel}\n </Button>\n <Button\n variant=\"solid\"\n colorPalette=\"primary\"\n isDisabled={isSaveDisabled || isSaveLoading}\n onPress={handleSave}\n >\n {resolvedSaveLabel}\n {isSaveLoading && <LoadingSpinner ml=\"100\" size=\"2xs\" />}\n </Button>\n </Dialog.Footer>\n </Dialog.Content>\n </Dialog.Root>\n );\n};\n\nFormDialog.displayName = \"FormDialog\";\n"],"mappings":";;;;;;;;AKuBA,IAAa,IAGT;CACF,IAAI,EAAkB;ELrBP,QA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AAkB,SACpB,IAAI;MAEF,AADA,MAAM,GACN,EAAQ,EAAK;KACf,QAAQ,CAER;UAEA,EAAQ,EAAK;IAEjB;cA4CQ,CAMG,GACA,KAAiB,kBAAC,GAAD;KAAgB,IAAG;KAAM,MAAK;IAAO,CAAA,CACjD;KACK,EAAA,CAAA;EACD,EAAA,CAAA;CACL,CAAA;AAEjB;AAEA,EAAW,cAAc"}
1
+ {"version":3,"file":"form-dialog-D86jNeIZ.esm.js","names":[],"sources":["../../src/patterns/dialogs/form-dialog/intl/en.ts","../../src/patterns/dialogs/form-dialog/intl/de.ts","../../src/patterns/dialogs/form-dialog/intl/es.ts","../../src/patterns/dialogs/form-dialog/intl/fr-FR.ts","../../src/patterns/dialogs/form-dialog/intl/pt-BR.ts","../../src/patterns/dialogs/form-dialog/form-dialog.messages.ts","../../src/patterns/dialogs/form-dialog/form-dialog.tsx"],"sourcesContent":["/**\n * Pre-compiled en messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Cancel`, save: `Save` };\n","/**\n * Pre-compiled de messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Abbrechen`, save: `Speichern` };\n","/**\n * Pre-compiled es messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Cancelar`, save: `Guardar` };\n","/**\n * Pre-compiled fr-FR messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Annuler`, save: `Enregistrer` };\n","/**\n * Pre-compiled pt-BR messages for FormDialog\n * Generated by @internationalized/string-compiler\n * DO NOT EDIT MANUALLY\n */\n\nexport default { cancel: `Cancelar`, save: `Salvar` };\n","/**\n * Pre-compiled localized messages for FormDialog component\n *\n * Generated by scripts/generate-dictionaries.ts\n * DO NOT EDIT MANUALLY\n *\n * @see https://react-spectrum.adobe.com/react-aria/internationalization.html\n */\n\nimport {\n type LocalizedString,\n type LocalizedStrings,\n} from \"@internationalized/string\";\nimport { normalizeMessages } from \"../../../utils/normalize-messages\";\n\n// Pre-compiled message functions\nimport formDialogMessages_en from \"./intl/en\";\nimport formDialogMessages_de from \"./intl/de\";\nimport formDialogMessages_es from \"./intl/es\";\nimport formDialogMessages_fr from \"./intl/fr-FR\";\nimport formDialogMessages_pt from \"./intl/pt-BR\";\n\n// Raw LocalizedStrings object for use with useLocalizedStringFormatter hook\nexport const formDialogMessagesStrings: LocalizedStrings<\n string,\n LocalizedString\n> = {\n en: normalizeMessages(formDialogMessages_en),\n de: normalizeMessages(formDialogMessages_de),\n es: normalizeMessages(formDialogMessages_es),\n \"fr-FR\": normalizeMessages(formDialogMessages_fr),\n \"pt-BR\": normalizeMessages(formDialogMessages_pt),\n} as LocalizedStrings<string, LocalizedString>;\n\n/**\n * Available message keys for FormDialog component\n */\nexport type FormDialogMessageKey = \"cancel\" | \"save\";\n","import { useControlledState } from \"react-stately/useControlledState\";\nimport { Button } from \"@/components/button/button\";\nimport { Dialog } from \"@/components/dialog/dialog\";\nimport { LoadingSpinner } from \"@/components/loading-spinner/loading-spinner\";\nimport { useLocalizedStringFormatter } from \"@/hooks\";\nimport { formDialogMessagesStrings } from \"./form-dialog.messages\";\nimport type { FormDialogProps } from \"./form-dialog.types\";\n\n/**\n * # FormDialog\n *\n * A pre-composed save/cancel dialog pattern built on top of the Nimbus\n * `Dialog` and `Button` primitives, shaped for hosting an editable form\n * in the body. Exposes a flat API (`title`, `children`, `onSave`,\n * `onCancel`, plus optional state, label, and accessibility props) for\n * the common case of editing data inside a modal.\n *\n * Close affordances: clicking the cancel button, the X button in the\n * header, pressing Escape, or clicking the overlay all invoke\n * `onCancel` and `onOpenChange(false)`. Clicking the save button\n * invokes `onSave` and then closes — synchronously for `void` returns,\n * or after the returned `Promise` fulfills for async saves; rejected\n * promises leave the dialog open so the consumer can surface\n * validation errors. The save path never fires `onCancel`.\n *\n * When `isSaveLoading` is `true` the entire dialog is locked: the save\n * button shows a spinner and is disabled, the cancel button is\n * disabled, and Escape / overlay click / close-button click are all\n * suppressed.\n *\n * The pattern does not wrap `children` in a native `<form>` element.\n * Consumers wanting Enter-to-submit semantics or browser-native\n * validation should wrap their fields in\n * `<form onSubmit={handleSubmit}>` inside `children` and call `onSave`\n * from `handleSubmit`.\n *\n * @example\n * ```tsx\n * const [isOpen, setIsOpen] = useState(false);\n *\n * <FormDialog\n * title=\"Edit profile\"\n * isOpen={isOpen}\n * onOpenChange={setIsOpen}\n * onSave={handleSave}\n * onCancel={() => setIsOpen(false)}\n * isSaveDisabled={!isDirty}\n * >\n * <TextInput label=\"Display name\" value={name} onChange={setName} />\n * </FormDialog>\n * ```\n */\nexport const FormDialog = ({\n title,\n children,\n onSave,\n onCancel,\n isOpen,\n defaultOpen,\n onOpenChange,\n saveLabel,\n cancelLabel,\n isSaveDisabled = false,\n isSaveLoading = false,\n \"aria-label\": ariaLabel,\n}: FormDialogProps) => {\n const msg = useLocalizedStringFormatter(formDialogMessagesStrings);\n\n // Internalize open state so we can close the dialog from our cancel\n // and save buttons without relying on `slot=\"close\"` (which races\n // its `onOpenChange` notification against the button's `onPress`\n // handler and double-fires the cancel callback).\n const [open, setOpen] = useControlledState<boolean>(\n isOpen,\n defaultOpen ?? false,\n onOpenChange\n );\n\n const resolvedSaveLabel = saveLabel ?? msg.format(\"save\");\n const resolvedCancelLabel = cancelLabel ?? msg.format(\"cancel\");\n\n const handleSave = async () => {\n const result = onSave();\n // If the consumer returns a Promise, wait for it to settle before\n // closing — otherwise the dialog vanishes synchronously and the\n // consumer's `isSaveLoading` lockout never paints. On rejection we\n // stay open so the consumer can surface validation errors and let\n // the user retry.\n if (result instanceof Promise) {\n try {\n await result;\n setOpen(false);\n } catch {\n // intentional: stay open on rejection\n }\n } else {\n setOpen(false);\n }\n };\n\n const handleCancelButton = () => {\n onCancel();\n setOpen(false);\n };\n\n // `Dialog.Root` invokes its `onOpenChange` for dismiss paths not\n // driven by an explicit `onPress` in this component — Escape,\n // overlay click, and the close-button X. Our cancel and save buttons\n // close via `setOpen(false)` directly and do NOT route through this\n // callback. The X close button is owned by the pattern via\n // `isDisabled={isSaveLoading}`, so this handler does not need to\n // re-check the loading flag for it.\n const handleAmbientOpenChange = (newOpen: boolean) => {\n if (!newOpen) {\n onCancel();\n }\n setOpen(newOpen);\n };\n\n return (\n <Dialog.Root\n isOpen={open}\n onOpenChange={handleAmbientOpenChange}\n aria-label={ariaLabel}\n isDismissable={!isSaveLoading}\n isKeyboardDismissDisabled={isSaveLoading}\n scrollBehavior=\"inside\"\n >\n <Dialog.Content>\n <Dialog.Header>\n <Dialog.Title>{title}</Dialog.Title>\n <Dialog.CloseTrigger isDisabled={isSaveLoading} />\n </Dialog.Header>\n <Dialog.Body>{children}</Dialog.Body>\n <Dialog.Footer>\n <Button\n variant=\"outline\"\n isDisabled={isSaveLoading}\n onPress={handleCancelButton}\n >\n {resolvedCancelLabel}\n </Button>\n <Button\n variant=\"solid\"\n colorPalette=\"primary\"\n isDisabled={isSaveDisabled || isSaveLoading}\n onPress={handleSave}\n >\n {resolvedSaveLabel}\n {isSaveLoading && <LoadingSpinner ml=\"100\" size=\"2xs\" />}\n </Button>\n </Dialog.Footer>\n </Dialog.Content>\n </Dialog.Root>\n );\n};\n\nFormDialog.displayName = \"FormDialog\";\n"],"mappings":";;;;;;;;AKuBA,IAAa,IAGT;CACF,IAAI,EAAkB;ELrBP,QAAQ;EAAU,MAAM;CKqBjB,CAAqB;CAC3C,IAAI,EAAkB;EJtBP,QAAQ;EAAa,MAAM;CIsBpB,CAAqB;CAC3C,IAAI,EAAkB;EHvBP,QAAQ;EAAY,MAAM;CGuBnB,CAAqB;CAC3C,SAAS,EAAkB;EFxBZ,QAAQ;EAAW,MAAM;CEwBb,CAAqB;CAChD,SAAS,EAAkB;EDzBZ,QAAQ;EAAY,MAAM;CCyBd,CAAqB;AAClD,GCoBa,KAAc,EACzB,UACA,aAC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
2
2
  import { t } from "./useField-BODQaE6H.esm.js";
3
- import { n, t as r, u as i } from "./Dialog-tQOfG_On.esm.js";
4
- import { t as a } from "./icon-button-6dtfz6Yf.esm.js";
3
+ import { n, t as r, u as i } from "./Dialog-Dy3vyR1i.esm.js";
4
+ import { t as a } from "./icon-button-CyhrlrIv.esm.js";
5
5
  import { t as o } from "./box-CZyqYgLL.esm.js";
6
6
  import { t as s } from "./merge-refs-C1GcH9iY.esm.js";
7
7
  import { Children as c, cloneElement as l, createContext as u, isValidElement as d, useContext as f, useEffect as p, useMemo as m, useRef as h, useState as g } from "react";
@@ -228,4 +228,4 @@ var L = {
228
228
  //#endregion
229
229
  export { N as a, P as i, I as n, M as o, F as r, j as s, L as t };
230
230
 
231
- //# sourceMappingURL=form-field-DRhB7O5k.esm.js.map
231
+ //# sourceMappingURL=form-field-B5H98u7s.esm.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"form-field-DRhB7O5k.esm.js","names":[],"sources":["../../src/components/form-field/components/form-field.context.tsx","../../src/components/form-field/form-field.slots.tsx","../../src/components/form-field/components/form-field.root.tsx","../../src/components/form-field/components/form-field.label.tsx","../../src/components/form-field/components/form-field.input.tsx","../../src/components/form-field/components/form-field.description.tsx","../../src/components/form-field/components/form-field.error.tsx","../../src/components/form-field/components/form-field.info-box.tsx","../../src/components/form-field/form-field.tsx"],"sourcesContent":["import { createContext, type ReactNode } from \"react\";\nimport type {\n FormFieldDescriptionSlotProps,\n FormFieldErrorSlotProps,\n FormFieldLabelSlotProps,\n} from \"../form-field.types\";\n\nexport type FormFieldInputProps = Record<string, unknown>;\n\nexport type FormFieldContextPayloadType = {\n label: ReactNode;\n labelSlotProps?: FormFieldLabelSlotProps;\n description: ReactNode;\n descriptionSlotProps?: FormFieldDescriptionSlotProps;\n error: ReactNode;\n errorSlotProps?: FormFieldErrorSlotProps;\n info: ReactNode;\n isInvalid?: boolean;\n isRequired?: boolean;\n isDisabled?: boolean;\n isReadOnly?: boolean;\n};\n\nexport type FormFieldContextType = {\n context: FormFieldContextPayloadType;\n setContext: React.Dispatch<React.SetStateAction<FormFieldContextPayloadType>>;\n inputProps: FormFieldInputProps;\n};\n\nexport const FormFieldContext = createContext<FormFieldContextType>({\n context: {\n label: null,\n description: null,\n error: null,\n info: null,\n },\n setContext: () => {},\n inputProps: {},\n});\n","import { createSlotRecipeContext } from \"@chakra-ui/react/styled-system\";\nimport type {\n FormFieldRootSlotProps,\n FormFieldLabelSlotProps,\n FormFieldInputSlotProps,\n FormFieldDescriptionSlotProps,\n FormFieldErrorSlotProps,\n FormFieldPopoverSlotProps,\n} from \"./form-field.types\";\n\nconst { withProvider, withContext } = createSlotRecipeContext({\n key: \"nimbusFormField\",\n});\n\n// Root slot\nexport const FormFieldRootSlot = withProvider<\n HTMLDivElement,\n FormFieldRootSlotProps\n>(\"div\", \"root\");\n\n// Label Slot\nexport const FormFieldLabelSlot = withContext<\n HTMLDivElement,\n FormFieldLabelSlotProps\n>(\"div\", \"label\");\n\n// Input Slot\nexport const FormFieldInputSlot = withContext<\n HTMLDivElement,\n FormFieldInputSlotProps\n>(\"div\", \"input\");\n\n// Description Slot\nexport const FormFieldDescriptionSlot = withContext<\n HTMLDivElement,\n FormFieldDescriptionSlotProps\n>(\"div\", \"description\");\n\n// Error Slot\nexport const FormFieldErrorSlot = withContext<\n HTMLDivElement,\n FormFieldErrorSlotProps\n>(\"div\", \"error\");\n\n// Error Slot\nexport const FormFieldPopoverSlot = withContext<\n HTMLDivElement,\n FormFieldPopoverSlotProps\n>(\"div\", \"popover\");\n","import { useEffect, useMemo, useState, useRef } from \"react\";\nimport type { FormFieldProps } from \"../form-field.types\";\nimport { useField, useObjectRef } from \"react-aria\";\nimport { mergeRefs } from \"@/utils\";\nimport {\n FormFieldContext,\n type FormFieldContextPayloadType,\n} from \"./form-field.context\";\nimport {\n FormFieldDescriptionSlot,\n FormFieldErrorSlot,\n FormFieldLabelSlot,\n FormFieldPopoverSlot,\n FormFieldRootSlot,\n} from \"../form-field.slots\";\nimport { Dialog, DialogTrigger, Popover } from \"react-aria-components\";\nimport { Box, IconButton } from \"@/components\";\nimport { ErrorOutline, HelpOutline } from \"@commercetools/nimbus-icons\";\n\n/**\n * # FormField.Root\n *\n * displays miscellaneous inputs in a FormField context\n *\n * @supportsStyleProps\n */\nexport const FormFieldRoot = function FormFieldRoot({\n ref: forwardedRef,\n id,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n children,\n ...props\n}: FormFieldProps) {\n const localRef = useRef<HTMLDivElement>(null);\n const ref = useObjectRef(mergeRefs(localRef, forwardedRef));\n const [context, setContext] = useState<FormFieldContextPayloadType>({\n label: null,\n description: null,\n error: null,\n info: null,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n });\n\n const useFieldArgs: Parameters<typeof useField>[0] = useMemo(() => {\n const args: Parameters<typeof useField>[0] = {\n id,\n description: context.description,\n errorMessage: context.error,\n };\n\n if (context.label) {\n args.label = context.label;\n } else {\n // Context will always start out null, so we need to stub out some aria attributes\n // FIXME: This is a hack to get the form field to work, but it's not the best solution\n // FIXME: We should find a better way to handle this by redesigning the FormField component's structure\n args[\"aria-label\"] = \"empty-label\";\n args[\"aria-labelledby\"] = \"empty-label\";\n }\n\n return args;\n }, [id, context.description, context.error, context.label]);\n\n const { labelProps, fieldProps, descriptionProps, errorMessageProps } =\n useField(useFieldArgs);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n }));\n }, [isInvalid, isRequired, isDisabled, isReadOnly]);\n\n const inputProps = useMemo(\n () => ({\n ...fieldProps,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n }),\n [fieldProps, isInvalid, isRequired, isDisabled, isReadOnly]\n );\n\n const contextValue = useMemo(\n () => ({ context, setContext, inputProps }),\n [context, inputProps]\n );\n\n return (\n <FormFieldContext.Provider value={contextValue}>\n <FormFieldRootSlot ref={ref} {...props}>\n {context.label && (\n <FormFieldLabelSlot {...context.labelSlotProps}>\n <label {...labelProps} data-required={isRequired}>\n {context.label}\n {isRequired && <sup aria-hidden=\"true\">*</sup>}\n </label>\n {context.info && (\n <DialogTrigger>\n <Box\n as=\"span\"\n display=\"inline-block\"\n position=\"relative\"\n width=\"1ch\"\n height=\"1ch\"\n ml=\"200\"\n >\n <Box\n as=\"span\"\n display=\"inline-flex\"\n position=\"absolute\"\n top=\"50%\"\n right=\"50%\"\n transform=\"translate(50%, -50%)\"\n >\n <IconButton\n aria-label=\"__MORE INFO\"\n size=\"2xs\"\n colorPalette=\"info\"\n variant=\"link\"\n >\n <HelpOutline />\n </IconButton>\n </Box>\n </Box>\n <Popover>\n <FormFieldPopoverSlot asChild>\n <Dialog>\n <Box p=\"300\">{context.info}</Box>\n </Dialog>\n </FormFieldPopoverSlot>\n </Popover>\n </DialogTrigger>\n )}\n </FormFieldLabelSlot>\n )}\n {context.description && (\n <FormFieldDescriptionSlot\n {...descriptionProps}\n {...context.descriptionSlotProps}\n >\n {context.description}\n </FormFieldDescriptionSlot>\n )}\n {isInvalid && context.error && (\n <FormFieldErrorSlot\n {...errorMessageProps}\n {...context.errorSlotProps}\n >\n <Box\n as={ErrorOutline}\n display=\"inline-flex\"\n boxSize=\"400\"\n flexShrink=\"0\"\n mt=\"50\"\n />\n {context.error}\n </FormFieldErrorSlot>\n )}\n {children}\n </FormFieldRootSlot>\n </FormFieldContext.Provider>\n );\n};\n\nFormFieldRoot.displayName = \"FormField.Root\";\n","import { useContext, useEffect } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldLabelSlotProps } from \"../form-field.types\";\n\n/**\n * FormField.Label - The label element for the form field\n *\n * @supportsStyleProps\n */\n// TODO: should this be wrapped in react-aria's `LabelContext` provider?, e.g. https://react-spectrum.adobe.com/react-aria/TextField.html#custom-children\nexport const FormFieldLabel = ({\n children,\n ...labelSlotProps\n}: FormFieldLabelSlotProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n label: children,\n labelSlotProps,\n }));\n\n // Cleanup: clear label when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n label: null,\n labelSlotProps: undefined,\n }));\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldLabel.displayName = \"FormField.Label\";\n","import { Children, cloneElement, isValidElement, useContext } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldInputSlotProps } from \"../form-field.types\";\nimport { FormFieldInputSlot } from \"../form-field.slots\";\n\n/**\n * FormField.Input - The input wrapper element for the form field\n *\n * Renders children directly (with injected field props) to avoid\n * the state-based indirection that causes cursor position issues\n * on controlled inputs.\n *\n * @supportsStyleProps\n */\nexport const FormFieldInput = ({\n children,\n ...inputSlotProps\n}: FormFieldInputSlotProps) => {\n const { inputProps } = useContext(FormFieldContext);\n\n return (\n <FormFieldInputSlot {...inputSlotProps}>\n {Children.map(children, (child) => {\n if (isValidElement(child)) {\n return cloneElement(child, inputProps);\n }\n return child;\n })}\n </FormFieldInputSlot>\n );\n};\n\nFormFieldInput.displayName = \"FormField.Input\";\n","import { useContext, useEffect } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldDescriptionSlotProps } from \"../form-field.types\";\n\n/**\n * FormField.Description - The description element for the form field\n *\n * @supportsStyleProps\n */\nexport const FormFieldDescription = ({\n children,\n ...descriptionSlotProps\n}: FormFieldDescriptionSlotProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n description: children,\n descriptionSlotProps,\n }));\n\n // Cleanup: clear description when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n description: null,\n descriptionSlotProps: undefined,\n }));\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldDescription.displayName = \"FormField.Description\";\n","import { useContext, useEffect } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldErrorSlotProps } from \"../form-field.types\";\n\n/**\n * FormField.Error - The error message element for the form field\n *\n * @supportsStyleProps\n */\nexport const FormFieldError = ({\n children,\n ...errorSlotProps\n}: FormFieldErrorSlotProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n error: children,\n errorSlotProps,\n }));\n\n // Cleanup: clear error when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n error: null,\n errorSlotProps: undefined,\n }));\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldError.displayName = \"FormField.Error\";\n","import { useContext, useEffect, type ReactNode } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\n\ntype FormFieldInfoBoxProps = {\n /**\n * The content to display in the InfoBox\n */\n children: ReactNode;\n};\n\n/**\n * FormField.InfoBox - The info box popover content for the form field\n *\n * @supportsStyleProps\n */\nexport const FormFieldInfoBox = ({ children }: FormFieldInfoBoxProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n info: children,\n }));\n\n // Cleanup: clear info when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n info: null,\n }));\n };\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldInfoBox.displayName = \"FormField.InfoBox\";\n","import {\n FormFieldRoot,\n FormFieldLabel,\n FormFieldInput,\n FormFieldDescription,\n FormFieldError,\n FormFieldInfoBox,\n} from \"./components\";\n\nexport const FormField = {\n /**\n * # FormField.Root\n *\n * The root container for the form field that provides context and state management\n * for all child components. Handles React Aria integration for accessibility,\n * manages field state (required, invalid, disabled, readonly), and coordinates\n * rendering of label, input, description, and error elements.\n *\n * @example\n * ```tsx\n * <FormField.Root isRequired isInvalid>\n * <FormField.Label>Username</FormField.Label>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * <FormField.Description>Enter your username</FormField.Description>\n * <FormField.Error>Username is required</FormField.Error>\n * </FormField.Root>\n * ```\n */\n Root: FormFieldRoot,\n\n /**\n * # FormField.Label\n *\n * The label element for the form field. Automatically associates with the input\n * via React Aria and displays a required indicator when the field is required.\n * Supports an optional info box trigger for additional field information.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>Email Address</FormField.Label>\n * <FormField.InfoBox>\n * Your email will be used for account notifications\n * </FormField.InfoBox>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * </FormField.Root>\n * ```\n */\n Label: FormFieldLabel,\n\n /**\n * # FormField.Input\n *\n * The input wrapper element that receives and displays the actual input component.\n * Automatically clones children and passes accessibility props, validation state,\n * and field attributes from React Aria.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>Password</FormField.Label>\n * <FormField.Input>\n * <PasswordInput />\n * </FormField.Input>\n * </FormField.Root>\n * ```\n */\n Input: FormFieldInput,\n\n /**\n * # FormField.Description\n *\n * The description element that provides helpful information about the field.\n * Automatically associates with the input via `aria-describedby` for screen readers.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>Username</FormField.Label>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * <FormField.Description>\n * Must be 3-20 characters, letters and numbers only\n * </FormField.Description>\n * </FormField.Root>\n * ```\n */\n Description: FormFieldDescription,\n\n /**\n * # FormField.Error\n *\n * The error message element that displays validation errors. Only visible when\n * the field is invalid. Automatically associates with the input via\n * `aria-errormessage` and includes an error icon.\n *\n * @example\n * ```tsx\n * <FormField.Root isInvalid>\n * <FormField.Label>Email</FormField.Label>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * <FormField.Error>Please enter a valid email address</FormField.Error>\n * </FormField.Root>\n * ```\n */\n Error: FormFieldError,\n\n /**\n * # FormField.InfoBox\n *\n * The info box content that appears in a popover when the help icon next to\n * the label is clicked. Use for additional context or instructions that don't\n * need to be visible by default.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>API Key</FormField.Label>\n * <FormField.InfoBox>\n * Your API key can be found in your account settings.\n * Keep it secure and never share it publicly.\n * </FormField.InfoBox>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * </FormField.Root>\n * ```\n */\n InfoBox: FormFieldInfoBox,\n};\n\nexport {\n FormFieldRoot as _FormFieldRoot,\n FormFieldLabel as _FormFieldLabel,\n FormFieldInput as _FormFieldInput,\n FormFieldDescription as _FormFieldDescription,\n FormFieldError as _FormFieldError,\n FormFieldInfoBox as _FormFieldInfoBox,\n};\n"],"mappings":";;;;;;;;;;;AA6BA,IAAa,IAAmB,EAAoC;CAClE,SAAS;EACP,OAAO;EACP,aAAa;EACb,OAAO;EACP,MAAM;CACR;CACA,kBAAkB,CAAC;CACnB,YAAY,CAAC;AACf,CAAC,GC5BK,EAAE,iBAAc,mBAAgB,EAAwB,EAC5D,KAAK,kBACP,CAAC,GAGY,IAAoB,EAG/B,OAAO,MAAM,GAGF,IAAqB,EAGhC,OAAO,OAAO,GAGH,IAAqB,EAGhC,OAAO,OAAO,GAGH,IAA2B,EAGtC,OAAO,aAAa,GAGT,IAAqB,EAGhC,OAAO,OAAO,GAGH,IAAuB,EAGlC,OAAO,SAAS,GCtBL,IAAgB,SAAuB,EAClD,KAAK,GACL,OACA,cACA,eACA,eACA,eACA,aACA,GAAG,KACc;CAEjB,IAAM,IAAM,EAAa,EADR,EAAuB,IACL,GAAU,CAAY,CAAC,GACpD,CAAC,GAAS,KAAc,EAAsC;EAClE,OAAO;EACP,aAAa;EACb,OAAO;EACP,MAAM;EACN;EACA;EACA;EACA;CACF,CAAC,GAsBK,EAAE,eAAY,eAAY,qBAAkB,yBAChD,EArBmD,QAAc;EACjE,IAAM,IAAuC;GAC3C;GACA,aAAa,EAAQ;GACrB,cAAc,EAAQ;EACxB;EAYA,OAVI,EAAQ,QACV,EAAK,QAAQ,EAA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;CAC7B,IAAM,EAAE,kBAAe,EAAW,CAAgB;CAoBlD,OAlBA,SACE,GAAY,OAAiB;EAC3B,GAAG;EACH,OAAO;EACP;CACF,EAAE,SAGW;EACX,GAAY,OAAiB;GAC3B,GAAG;GACH,OAAO;GACP,gBAAgB,KAAA;EAClB,EAAE;CACJ,IAEC,CAAC,GAAU,CAAU,CAAC,GAElB;AACT;AAEA,EAAe,cAAc;;;ACrB7B,IAAa,KAAoB,EAAE,kBAAsC;CACvE,IAAM,EAAE,kBAAe,EAAW,CAAgB;CAiBlD,OAfA,SACE,GAAY,OAAiB;EAC3B,GAAG;EACH,MAAM;CACR,EAAE,SAGW;EACX,GAAY,OAAiB;GAC3B,GAAG;GACH,MAAM;EACR,EAAE;CACJ,IACC,CAAC,GAAU,CAAU,CAAC,GAElB;AACT;AAEA,EAAiB,cAAc;;;AC3B/B,IAAa,IAAY;CAqBvB,MAAM;CAsBN,OAAO;CAmBP,OAAO;CAqBP,aAAa;CAoBb,OAAO;CAuBP,SAAS;AACX"}
1
+ {"version":3,"file":"form-field-B5H98u7s.esm.js","names":[],"sources":["../../src/components/form-field/components/form-field.context.tsx","../../src/components/form-field/form-field.slots.tsx","../../src/components/form-field/components/form-field.root.tsx","../../src/components/form-field/components/form-field.label.tsx","../../src/components/form-field/components/form-field.input.tsx","../../src/components/form-field/components/form-field.description.tsx","../../src/components/form-field/components/form-field.error.tsx","../../src/components/form-field/components/form-field.info-box.tsx","../../src/components/form-field/form-field.tsx"],"sourcesContent":["import { createContext, type ReactNode } from \"react\";\nimport type {\n FormFieldDescriptionSlotProps,\n FormFieldErrorSlotProps,\n FormFieldLabelSlotProps,\n} from \"../form-field.types\";\n\nexport type FormFieldInputProps = Record<string, unknown>;\n\nexport type FormFieldContextPayloadType = {\n label: ReactNode;\n labelSlotProps?: FormFieldLabelSlotProps;\n description: ReactNode;\n descriptionSlotProps?: FormFieldDescriptionSlotProps;\n error: ReactNode;\n errorSlotProps?: FormFieldErrorSlotProps;\n info: ReactNode;\n isInvalid?: boolean;\n isRequired?: boolean;\n isDisabled?: boolean;\n isReadOnly?: boolean;\n};\n\nexport type FormFieldContextType = {\n context: FormFieldContextPayloadType;\n setContext: React.Dispatch<React.SetStateAction<FormFieldContextPayloadType>>;\n inputProps: FormFieldInputProps;\n};\n\nexport const FormFieldContext = createContext<FormFieldContextType>({\n context: {\n label: null,\n description: null,\n error: null,\n info: null,\n },\n setContext: () => {},\n inputProps: {},\n});\n","import { createSlotRecipeContext } from \"@chakra-ui/react/styled-system\";\nimport type {\n FormFieldRootSlotProps,\n FormFieldLabelSlotProps,\n FormFieldInputSlotProps,\n FormFieldDescriptionSlotProps,\n FormFieldErrorSlotProps,\n FormFieldPopoverSlotProps,\n} from \"./form-field.types\";\n\nconst { withProvider, withContext } = createSlotRecipeContext({\n key: \"nimbusFormField\",\n});\n\n// Root slot\nexport const FormFieldRootSlot = withProvider<\n HTMLDivElement,\n FormFieldRootSlotProps\n>(\"div\", \"root\");\n\n// Label Slot\nexport const FormFieldLabelSlot = withContext<\n HTMLDivElement,\n FormFieldLabelSlotProps\n>(\"div\", \"label\");\n\n// Input Slot\nexport const FormFieldInputSlot = withContext<\n HTMLDivElement,\n FormFieldInputSlotProps\n>(\"div\", \"input\");\n\n// Description Slot\nexport const FormFieldDescriptionSlot = withContext<\n HTMLDivElement,\n FormFieldDescriptionSlotProps\n>(\"div\", \"description\");\n\n// Error Slot\nexport const FormFieldErrorSlot = withContext<\n HTMLDivElement,\n FormFieldErrorSlotProps\n>(\"div\", \"error\");\n\n// Error Slot\nexport const FormFieldPopoverSlot = withContext<\n HTMLDivElement,\n FormFieldPopoverSlotProps\n>(\"div\", \"popover\");\n","import { useEffect, useMemo, useState, useRef } from \"react\";\nimport type { FormFieldProps } from \"../form-field.types\";\nimport { useField, useObjectRef } from \"react-aria\";\nimport { mergeRefs } from \"@/utils\";\nimport {\n FormFieldContext,\n type FormFieldContextPayloadType,\n} from \"./form-field.context\";\nimport {\n FormFieldDescriptionSlot,\n FormFieldErrorSlot,\n FormFieldLabelSlot,\n FormFieldPopoverSlot,\n FormFieldRootSlot,\n} from \"../form-field.slots\";\nimport { Dialog, DialogTrigger, Popover } from \"react-aria-components\";\nimport { Box, IconButton } from \"@/components\";\nimport { ErrorOutline, HelpOutline } from \"@commercetools/nimbus-icons\";\n\n/**\n * # FormField.Root\n *\n * displays miscellaneous inputs in a FormField context\n *\n * @supportsStyleProps\n */\nexport const FormFieldRoot = function FormFieldRoot({\n ref: forwardedRef,\n id,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n children,\n ...props\n}: FormFieldProps) {\n const localRef = useRef<HTMLDivElement>(null);\n const ref = useObjectRef(mergeRefs(localRef, forwardedRef));\n const [context, setContext] = useState<FormFieldContextPayloadType>({\n label: null,\n description: null,\n error: null,\n info: null,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n });\n\n const useFieldArgs: Parameters<typeof useField>[0] = useMemo(() => {\n const args: Parameters<typeof useField>[0] = {\n id,\n description: context.description,\n errorMessage: context.error,\n };\n\n if (context.label) {\n args.label = context.label;\n } else {\n // Context will always start out null, so we need to stub out some aria attributes\n // FIXME: This is a hack to get the form field to work, but it's not the best solution\n // FIXME: We should find a better way to handle this by redesigning the FormField component's structure\n args[\"aria-label\"] = \"empty-label\";\n args[\"aria-labelledby\"] = \"empty-label\";\n }\n\n return args;\n }, [id, context.description, context.error, context.label]);\n\n const { labelProps, fieldProps, descriptionProps, errorMessageProps } =\n useField(useFieldArgs);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n }));\n }, [isInvalid, isRequired, isDisabled, isReadOnly]);\n\n const inputProps = useMemo(\n () => ({\n ...fieldProps,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n }),\n [fieldProps, isInvalid, isRequired, isDisabled, isReadOnly]\n );\n\n const contextValue = useMemo(\n () => ({ context, setContext, inputProps }),\n [context, inputProps]\n );\n\n return (\n <FormFieldContext.Provider value={contextValue}>\n <FormFieldRootSlot ref={ref} {...props}>\n {context.label && (\n <FormFieldLabelSlot {...context.labelSlotProps}>\n <label {...labelProps} data-required={isRequired}>\n {context.label}\n {isRequired && <sup aria-hidden=\"true\">*</sup>}\n </label>\n {context.info && (\n <DialogTrigger>\n <Box\n as=\"span\"\n display=\"inline-block\"\n position=\"relative\"\n width=\"1ch\"\n height=\"1ch\"\n ml=\"200\"\n >\n <Box\n as=\"span\"\n display=\"inline-flex\"\n position=\"absolute\"\n top=\"50%\"\n right=\"50%\"\n transform=\"translate(50%, -50%)\"\n >\n <IconButton\n aria-label=\"__MORE INFO\"\n size=\"2xs\"\n colorPalette=\"info\"\n variant=\"link\"\n >\n <HelpOutline />\n </IconButton>\n </Box>\n </Box>\n <Popover>\n <FormFieldPopoverSlot asChild>\n <Dialog>\n <Box p=\"300\">{context.info}</Box>\n </Dialog>\n </FormFieldPopoverSlot>\n </Popover>\n </DialogTrigger>\n )}\n </FormFieldLabelSlot>\n )}\n {context.description && (\n <FormFieldDescriptionSlot\n {...descriptionProps}\n {...context.descriptionSlotProps}\n >\n {context.description}\n </FormFieldDescriptionSlot>\n )}\n {isInvalid && context.error && (\n <FormFieldErrorSlot\n {...errorMessageProps}\n {...context.errorSlotProps}\n >\n <Box\n as={ErrorOutline}\n display=\"inline-flex\"\n boxSize=\"400\"\n flexShrink=\"0\"\n mt=\"50\"\n />\n {context.error}\n </FormFieldErrorSlot>\n )}\n {children}\n </FormFieldRootSlot>\n </FormFieldContext.Provider>\n );\n};\n\nFormFieldRoot.displayName = \"FormField.Root\";\n","import { useContext, useEffect } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldLabelSlotProps } from \"../form-field.types\";\n\n/**\n * FormField.Label - The label element for the form field\n *\n * @supportsStyleProps\n */\n// TODO: should this be wrapped in react-aria's `LabelContext` provider?, e.g. https://react-spectrum.adobe.com/react-aria/TextField.html#custom-children\nexport const FormFieldLabel = ({\n children,\n ...labelSlotProps\n}: FormFieldLabelSlotProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n label: children,\n labelSlotProps,\n }));\n\n // Cleanup: clear label when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n label: null,\n labelSlotProps: undefined,\n }));\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldLabel.displayName = \"FormField.Label\";\n","import { Children, cloneElement, isValidElement, useContext } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldInputSlotProps } from \"../form-field.types\";\nimport { FormFieldInputSlot } from \"../form-field.slots\";\n\n/**\n * FormField.Input - The input wrapper element for the form field\n *\n * Renders children directly (with injected field props) to avoid\n * the state-based indirection that causes cursor position issues\n * on controlled inputs.\n *\n * @supportsStyleProps\n */\nexport const FormFieldInput = ({\n children,\n ...inputSlotProps\n}: FormFieldInputSlotProps) => {\n const { inputProps } = useContext(FormFieldContext);\n\n return (\n <FormFieldInputSlot {...inputSlotProps}>\n {Children.map(children, (child) => {\n if (isValidElement(child)) {\n return cloneElement(child, inputProps);\n }\n return child;\n })}\n </FormFieldInputSlot>\n );\n};\n\nFormFieldInput.displayName = \"FormField.Input\";\n","import { useContext, useEffect } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldDescriptionSlotProps } from \"../form-field.types\";\n\n/**\n * FormField.Description - The description element for the form field\n *\n * @supportsStyleProps\n */\nexport const FormFieldDescription = ({\n children,\n ...descriptionSlotProps\n}: FormFieldDescriptionSlotProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n description: children,\n descriptionSlotProps,\n }));\n\n // Cleanup: clear description when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n description: null,\n descriptionSlotProps: undefined,\n }));\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldDescription.displayName = \"FormField.Description\";\n","import { useContext, useEffect } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldErrorSlotProps } from \"../form-field.types\";\n\n/**\n * FormField.Error - The error message element for the form field\n *\n * @supportsStyleProps\n */\nexport const FormFieldError = ({\n children,\n ...errorSlotProps\n}: FormFieldErrorSlotProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n error: children,\n errorSlotProps,\n }));\n\n // Cleanup: clear error when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n error: null,\n errorSlotProps: undefined,\n }));\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldError.displayName = \"FormField.Error\";\n","import { useContext, useEffect, type ReactNode } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\n\ntype FormFieldInfoBoxProps = {\n /**\n * The content to display in the InfoBox\n */\n children: ReactNode;\n};\n\n/**\n * FormField.InfoBox - The info box popover content for the form field\n *\n * @supportsStyleProps\n */\nexport const FormFieldInfoBox = ({ children }: FormFieldInfoBoxProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n info: children,\n }));\n\n // Cleanup: clear info when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n info: null,\n }));\n };\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldInfoBox.displayName = \"FormField.InfoBox\";\n","import {\n FormFieldRoot,\n FormFieldLabel,\n FormFieldInput,\n FormFieldDescription,\n FormFieldError,\n FormFieldInfoBox,\n} from \"./components\";\n\nexport const FormField = {\n /**\n * # FormField.Root\n *\n * The root container for the form field that provides context and state management\n * for all child components. Handles React Aria integration for accessibility,\n * manages field state (required, invalid, disabled, readonly), and coordinates\n * rendering of label, input, description, and error elements.\n *\n * @example\n * ```tsx\n * <FormField.Root isRequired isInvalid>\n * <FormField.Label>Username</FormField.Label>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * <FormField.Description>Enter your username</FormField.Description>\n * <FormField.Error>Username is required</FormField.Error>\n * </FormField.Root>\n * ```\n */\n Root: FormFieldRoot,\n\n /**\n * # FormField.Label\n *\n * The label element for the form field. Automatically associates with the input\n * via React Aria and displays a required indicator when the field is required.\n * Supports an optional info box trigger for additional field information.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>Email Address</FormField.Label>\n * <FormField.InfoBox>\n * Your email will be used for account notifications\n * </FormField.InfoBox>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * </FormField.Root>\n * ```\n */\n Label: FormFieldLabel,\n\n /**\n * # FormField.Input\n *\n * The input wrapper element that receives and displays the actual input component.\n * Automatically clones children and passes accessibility props, validation state,\n * and field attributes from React Aria.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>Password</FormField.Label>\n * <FormField.Input>\n * <PasswordInput />\n * </FormField.Input>\n * </FormField.Root>\n * ```\n */\n Input: FormFieldInput,\n\n /**\n * # FormField.Description\n *\n * The description element that provides helpful information about the field.\n * Automatically associates with the input via `aria-describedby` for screen readers.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>Username</FormField.Label>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * <FormField.Description>\n * Must be 3-20 characters, letters and numbers only\n * </FormField.Description>\n * </FormField.Root>\n * ```\n */\n Description: FormFieldDescription,\n\n /**\n * # FormField.Error\n *\n * The error message element that displays validation errors. Only visible when\n * the field is invalid. Automatically associates with the input via\n * `aria-errormessage` and includes an error icon.\n *\n * @example\n * ```tsx\n * <FormField.Root isInvalid>\n * <FormField.Label>Email</FormField.Label>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * <FormField.Error>Please enter a valid email address</FormField.Error>\n * </FormField.Root>\n * ```\n */\n Error: FormFieldError,\n\n /**\n * # FormField.InfoBox\n *\n * The info box content that appears in a popover when the help icon next to\n * the label is clicked. Use for additional context or instructions that don't\n * need to be visible by default.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>API Key</FormField.Label>\n * <FormField.InfoBox>\n * Your API key can be found in your account settings.\n * Keep it secure and never share it publicly.\n * </FormField.InfoBox>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * </FormField.Root>\n * ```\n */\n InfoBox: FormFieldInfoBox,\n};\n\nexport {\n FormFieldRoot as _FormFieldRoot,\n FormFieldLabel as _FormFieldLabel,\n FormFieldInput as _FormFieldInput,\n FormFieldDescription as _FormFieldDescription,\n FormFieldError as _FormFieldError,\n FormFieldInfoBox as _FormFieldInfoBox,\n};\n"],"mappings":";;;;;;;;;;;AA6BA,IAAa,IAAmB,EAAoC;CAClE,SAAS;EACP,OAAO;EACP,aAAa;EACb,OAAO;EACP,MAAM;CACR;CACA,kBAAkB,CAAC;CACnB,YAAY,CAAC;AACf,CAAC,GC5BK,EAAE,iBAAc,mBAAgB,EAAwB,EAC5D,KAAK,kBACP,CAAC,GAGY,IAAoB,EAG/B,OAAO,MAAM,GAGF,IAAqB,EAGhC,OAAO,OAAO,GAGH,IAAqB,EAGhC,OAAO,OAAO,GAGH,IAA2B,EAGtC,OAAO,aAAa,GAGT,IAAqB,EAGhC,OAAO,OAAO,GAGH,IAAuB,EAGlC,OAAO,SAAS,GCtBL,IAAgB,SAAuB,EAClD,KAAK,GACL,OACA,cACA,eACA,eACA,eACA,aACA,GAAG,KACc;CAEjB,IAAM,IAAM,EAAa,EADR,EAAuB,IACL,GAAU,CAAY,CAAC,GACpD,CAAC,GAAS,KAAc,EAAsC;EAClE,OAAO;EACP,aAAa;EACb,OAAO;EACP,MAAM;EACN;EACA;EACA;EACA;CACF,CAAC,GAsBK,EAAE,eAAY,eAAY,qBAAkB,yBAChD,EArBmD,QAAc;EACjE,IAAM,IAAuC;GAC3C;GACA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C,GAElB;AACT;AAEA,EAAqB,cAAc;;;AC3BnC,IAAa,KAAkB,EAC7B,aACA,GAAG,QAC0B;CAC7B,IAAM,EAAE,kBAAe,EAAW,CAAgB;CAoBlD,OAlBA,SACE,GAAY,OAAiB;EAC3B,GAAG;EACH,OAAO;EACP;CACF,EAAE,SAGW;EACX,GAAY,OAAiB;GAC3B,GAAG;GACH,OAAO;GACP,gBAAgB,KAAA;EAClB,EAAE;CACJ,IAEC,CAAC,GAAU,CAAU,CAAC,GAElB;AACT;AAEA,EAAe,cAAc;;;ACrB7B,IAAa,KAAoB,EAAE,kBAAsC;CACvE,IAAM,EAAE,kBAAe,EAAW,CAAgB;CAiBlD,OAfA,SACE,GAAY,OAAiB;EAC3B,GAAG;EACH,MAAM;CACR,EAAE,SAGW;EACX,GAAY,OAAiB;GAC3B,GAAG;GACH,MAAM;EACR,EAAE;CACJ,IACC,CAAC,GAAU,CAAU,CAAC,GAElB;AACT;AAEA,EAAiB,cAAc;;;AC3B/B,IAAa,IAAY;CAqBvB,MAAM;CAsBN,OAAO;CAmBP,OAAO;CAqBP,aAAa;CAoBb,OAAO;CAuBP,SAAS;AACX"}
@@ -1,2 +1,2 @@
1
- const e=require("./useObjectRef-B_VeQHvx.cjs.js"),t=require("./useField-dHbFxjk0.cjs.js"),n=require("./Dialog-s5tFTj72.cjs.js"),r=require("./icon-button-CSlFdpjB.cjs.js"),i=require("./box-B6vF0vdN.cjs.js"),a=require("./merge-refs-DjTl2ATo.cjs.js");let o=require("react"),s=require("react/jsx-runtime"),c=require("@commercetools/nimbus-icons"),l=require("@chakra-ui/react/styled-system");var u=(0,o.createContext)({context:{label:null,description:null,error:null,info:null},setContext:()=>{},inputProps:{}}),{withProvider:d,withContext:f}=(0,l.createSlotRecipeContext)({key:`nimbusFormField`}),p=d(`div`,`root`),m=f(`div`,`label`),h=f(`div`,`input`),g=f(`div`,`description`),_=f(`div`,`error`),v=f(`div`,`popover`),y=function({ref:l,id:d,isInvalid:f,isRequired:h,isDisabled:y,isReadOnly:b,children:x,...S}){let C=e.t(a.t((0,o.useRef)(null),l)),[w,T]=(0,o.useState)({label:null,description:null,error:null,info:null,isInvalid:f,isRequired:h,isDisabled:y,isReadOnly:b}),{labelProps:E,fieldProps:D,descriptionProps:O,errorMessageProps:k}=t.t((0,o.useMemo)(()=>{let e={id:d,description:w.description,errorMessage:w.error};return w.label?e.label=w.label:(e[`aria-label`]=`empty-label`,e[`aria-labelledby`]=`empty-label`),e},[d,w.description,w.error,w.label]));(0,o.useEffect)(()=>{T(e=>({...e,isInvalid:f,isRequired:h,isDisabled:y,isReadOnly:b}))},[f,h,y,b]);let A=(0,o.useMemo)(()=>({...D,isInvalid:f,isRequired:h,isDisabled:y,isReadOnly:b}),[D,f,h,y,b]),j=(0,o.useMemo)(()=>({context:w,setContext:T,inputProps:A}),[w,A]);return(0,s.jsx)(u.Provider,{value:j,children:(0,s.jsxs)(p,{ref:C,...S,children:[w.label&&(0,s.jsxs)(m,{...w.labelSlotProps,children:[(0,s.jsxs)(`label`,{...E,"data-required":h,children:[w.label,h&&(0,s.jsx)(`sup`,{"aria-hidden":`true`,children:`*`})]}),w.info&&(0,s.jsxs)(n.t,{children:[(0,s.jsx)(i.t,{as:`span`,display:`inline-block`,position:`relative`,width:`1ch`,height:`1ch`,ml:`200`,children:(0,s.jsx)(i.t,{as:`span`,display:`inline-flex`,position:`absolute`,top:`50%`,right:`50%`,transform:`translate(50%, -50%)`,children:(0,s.jsx)(r.t,{"aria-label":`__MORE INFO`,size:`2xs`,colorPalette:`info`,variant:`link`,children:(0,s.jsx)(c.HelpOutline,{})})})}),(0,s.jsx)(n.u,{children:(0,s.jsx)(v,{asChild:!0,children:(0,s.jsx)(n.n,{children:(0,s.jsx)(i.t,{p:`300`,children:w.info})})})})]})]}),w.description&&(0,s.jsx)(g,{...O,...w.descriptionSlotProps,children:w.description}),f&&w.error&&(0,s.jsxs)(_,{...k,...w.errorSlotProps,children:[(0,s.jsx)(i.t,{as:c.ErrorOutline,display:`inline-flex`,boxSize:`400`,flexShrink:`0`,mt:`50`}),w.error]}),x]})})};y.displayName=`FormField.Root`;var b=({children:e,...t})=>{let{setContext:n}=(0,o.useContext)(u);return(0,o.useEffect)(()=>(n(n=>({...n,label:e,labelSlotProps:t})),()=>{n(e=>({...e,label:null,labelSlotProps:void 0}))}),[e,n]),null};b.displayName=`FormField.Label`;var x=({children:e,...t})=>{let{inputProps:n}=(0,o.useContext)(u);return(0,s.jsx)(h,{...t,children:o.Children.map(e,e=>(0,o.isValidElement)(e)?(0,o.cloneElement)(e,n):e)})};x.displayName=`FormField.Input`;var S=({children:e,...t})=>{let{setContext:n}=(0,o.useContext)(u);return(0,o.useEffect)(()=>(n(n=>({...n,description:e,descriptionSlotProps:t})),()=>{n(e=>({...e,description:null,descriptionSlotProps:void 0}))}),[e,n]),null};S.displayName=`FormField.Description`;var C=({children:e,...t})=>{let{setContext:n}=(0,o.useContext)(u);return(0,o.useEffect)(()=>(n(n=>({...n,error:e,errorSlotProps:t})),()=>{n(e=>({...e,error:null,errorSlotProps:void 0}))}),[e,n]),null};C.displayName=`FormField.Error`;var w=({children:e})=>{let{setContext:t}=(0,o.useContext)(u);return(0,o.useEffect)(()=>(t(t=>({...t,info:e})),()=>{t(e=>({...e,info:null}))}),[e,t]),null};w.displayName=`FormField.InfoBox`;var T={Root:y,Label:b,Input:x,Description:S,Error:C,InfoBox:w};Object.defineProperty(exports,"a",{enumerable:!0,get:function(){return x}}),Object.defineProperty(exports,"i",{enumerable:!0,get:function(){return S}}),Object.defineProperty(exports,"n",{enumerable:!0,get:function(){return w}}),Object.defineProperty(exports,"o",{enumerable:!0,get:function(){return b}}),Object.defineProperty(exports,"r",{enumerable:!0,get:function(){return C}}),Object.defineProperty(exports,"s",{enumerable:!0,get:function(){return y}}),Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return T}});
2
- //# sourceMappingURL=form-field-CrSE8x3q.cjs.js.map
1
+ const e=require("./useObjectRef-B_VeQHvx.cjs.js"),t=require("./useField-dHbFxjk0.cjs.js"),n=require("./Dialog-UjK50qiN.cjs.js"),r=require("./icon-button-BG5cQycc.cjs.js"),i=require("./box-B6vF0vdN.cjs.js"),a=require("./merge-refs-DjTl2ATo.cjs.js");let o=require("react"),s=require("react/jsx-runtime"),c=require("@commercetools/nimbus-icons"),l=require("@chakra-ui/react/styled-system");var u=(0,o.createContext)({context:{label:null,description:null,error:null,info:null},setContext:()=>{},inputProps:{}}),{withProvider:d,withContext:f}=(0,l.createSlotRecipeContext)({key:`nimbusFormField`}),p=d(`div`,`root`),m=f(`div`,`label`),h=f(`div`,`input`),g=f(`div`,`description`),_=f(`div`,`error`),v=f(`div`,`popover`),y=function({ref:l,id:d,isInvalid:f,isRequired:h,isDisabled:y,isReadOnly:b,children:x,...S}){let C=e.t(a.t((0,o.useRef)(null),l)),[w,T]=(0,o.useState)({label:null,description:null,error:null,info:null,isInvalid:f,isRequired:h,isDisabled:y,isReadOnly:b}),{labelProps:E,fieldProps:D,descriptionProps:O,errorMessageProps:k}=t.t((0,o.useMemo)(()=>{let e={id:d,description:w.description,errorMessage:w.error};return w.label?e.label=w.label:(e[`aria-label`]=`empty-label`,e[`aria-labelledby`]=`empty-label`),e},[d,w.description,w.error,w.label]));(0,o.useEffect)(()=>{T(e=>({...e,isInvalid:f,isRequired:h,isDisabled:y,isReadOnly:b}))},[f,h,y,b]);let A=(0,o.useMemo)(()=>({...D,isInvalid:f,isRequired:h,isDisabled:y,isReadOnly:b}),[D,f,h,y,b]),j=(0,o.useMemo)(()=>({context:w,setContext:T,inputProps:A}),[w,A]);return(0,s.jsx)(u.Provider,{value:j,children:(0,s.jsxs)(p,{ref:C,...S,children:[w.label&&(0,s.jsxs)(m,{...w.labelSlotProps,children:[(0,s.jsxs)(`label`,{...E,"data-required":h,children:[w.label,h&&(0,s.jsx)(`sup`,{"aria-hidden":`true`,children:`*`})]}),w.info&&(0,s.jsxs)(n.t,{children:[(0,s.jsx)(i.t,{as:`span`,display:`inline-block`,position:`relative`,width:`1ch`,height:`1ch`,ml:`200`,children:(0,s.jsx)(i.t,{as:`span`,display:`inline-flex`,position:`absolute`,top:`50%`,right:`50%`,transform:`translate(50%, -50%)`,children:(0,s.jsx)(r.t,{"aria-label":`__MORE INFO`,size:`2xs`,colorPalette:`info`,variant:`link`,children:(0,s.jsx)(c.HelpOutline,{})})})}),(0,s.jsx)(n.u,{children:(0,s.jsx)(v,{asChild:!0,children:(0,s.jsx)(n.n,{children:(0,s.jsx)(i.t,{p:`300`,children:w.info})})})})]})]}),w.description&&(0,s.jsx)(g,{...O,...w.descriptionSlotProps,children:w.description}),f&&w.error&&(0,s.jsxs)(_,{...k,...w.errorSlotProps,children:[(0,s.jsx)(i.t,{as:c.ErrorOutline,display:`inline-flex`,boxSize:`400`,flexShrink:`0`,mt:`50`}),w.error]}),x]})})};y.displayName=`FormField.Root`;var b=({children:e,...t})=>{let{setContext:n}=(0,o.useContext)(u);return(0,o.useEffect)(()=>(n(n=>({...n,label:e,labelSlotProps:t})),()=>{n(e=>({...e,label:null,labelSlotProps:void 0}))}),[e,n]),null};b.displayName=`FormField.Label`;var x=({children:e,...t})=>{let{inputProps:n}=(0,o.useContext)(u);return(0,s.jsx)(h,{...t,children:o.Children.map(e,e=>(0,o.isValidElement)(e)?(0,o.cloneElement)(e,n):e)})};x.displayName=`FormField.Input`;var S=({children:e,...t})=>{let{setContext:n}=(0,o.useContext)(u);return(0,o.useEffect)(()=>(n(n=>({...n,description:e,descriptionSlotProps:t})),()=>{n(e=>({...e,description:null,descriptionSlotProps:void 0}))}),[e,n]),null};S.displayName=`FormField.Description`;var C=({children:e,...t})=>{let{setContext:n}=(0,o.useContext)(u);return(0,o.useEffect)(()=>(n(n=>({...n,error:e,errorSlotProps:t})),()=>{n(e=>({...e,error:null,errorSlotProps:void 0}))}),[e,n]),null};C.displayName=`FormField.Error`;var w=({children:e})=>{let{setContext:t}=(0,o.useContext)(u);return(0,o.useEffect)(()=>(t(t=>({...t,info:e})),()=>{t(e=>({...e,info:null}))}),[e,t]),null};w.displayName=`FormField.InfoBox`;var T={Root:y,Label:b,Input:x,Description:S,Error:C,InfoBox:w};Object.defineProperty(exports,"a",{enumerable:!0,get:function(){return x}}),Object.defineProperty(exports,"i",{enumerable:!0,get:function(){return S}}),Object.defineProperty(exports,"n",{enumerable:!0,get:function(){return w}}),Object.defineProperty(exports,"o",{enumerable:!0,get:function(){return b}}),Object.defineProperty(exports,"r",{enumerable:!0,get:function(){return C}}),Object.defineProperty(exports,"s",{enumerable:!0,get:function(){return y}}),Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return T}});
2
+ //# sourceMappingURL=form-field-CaTJgt57.cjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"form-field-CrSE8x3q.cjs.js","names":[],"sources":["../../src/components/form-field/components/form-field.context.tsx","../../src/components/form-field/form-field.slots.tsx","../../src/components/form-field/components/form-field.root.tsx","../../src/components/form-field/components/form-field.label.tsx","../../src/components/form-field/components/form-field.input.tsx","../../src/components/form-field/components/form-field.description.tsx","../../src/components/form-field/components/form-field.error.tsx","../../src/components/form-field/components/form-field.info-box.tsx","../../src/components/form-field/form-field.tsx"],"sourcesContent":["import { createContext, type ReactNode } from \"react\";\nimport type {\n FormFieldDescriptionSlotProps,\n FormFieldErrorSlotProps,\n FormFieldLabelSlotProps,\n} from \"../form-field.types\";\n\nexport type FormFieldInputProps = Record<string, unknown>;\n\nexport type FormFieldContextPayloadType = {\n label: ReactNode;\n labelSlotProps?: FormFieldLabelSlotProps;\n description: ReactNode;\n descriptionSlotProps?: FormFieldDescriptionSlotProps;\n error: ReactNode;\n errorSlotProps?: FormFieldErrorSlotProps;\n info: ReactNode;\n isInvalid?: boolean;\n isRequired?: boolean;\n isDisabled?: boolean;\n isReadOnly?: boolean;\n};\n\nexport type FormFieldContextType = {\n context: FormFieldContextPayloadType;\n setContext: React.Dispatch<React.SetStateAction<FormFieldContextPayloadType>>;\n inputProps: FormFieldInputProps;\n};\n\nexport const FormFieldContext = createContext<FormFieldContextType>({\n context: {\n label: null,\n description: null,\n error: null,\n info: null,\n },\n setContext: () => {},\n inputProps: {},\n});\n","import { createSlotRecipeContext } from \"@chakra-ui/react/styled-system\";\nimport type {\n FormFieldRootSlotProps,\n FormFieldLabelSlotProps,\n FormFieldInputSlotProps,\n FormFieldDescriptionSlotProps,\n FormFieldErrorSlotProps,\n FormFieldPopoverSlotProps,\n} from \"./form-field.types\";\n\nconst { withProvider, withContext } = createSlotRecipeContext({\n key: \"nimbusFormField\",\n});\n\n// Root slot\nexport const FormFieldRootSlot = withProvider<\n HTMLDivElement,\n FormFieldRootSlotProps\n>(\"div\", \"root\");\n\n// Label Slot\nexport const FormFieldLabelSlot = withContext<\n HTMLDivElement,\n FormFieldLabelSlotProps\n>(\"div\", \"label\");\n\n// Input Slot\nexport const FormFieldInputSlot = withContext<\n HTMLDivElement,\n FormFieldInputSlotProps\n>(\"div\", \"input\");\n\n// Description Slot\nexport const FormFieldDescriptionSlot = withContext<\n HTMLDivElement,\n FormFieldDescriptionSlotProps\n>(\"div\", \"description\");\n\n// Error Slot\nexport const FormFieldErrorSlot = withContext<\n HTMLDivElement,\n FormFieldErrorSlotProps\n>(\"div\", \"error\");\n\n// Error Slot\nexport const FormFieldPopoverSlot = withContext<\n HTMLDivElement,\n FormFieldPopoverSlotProps\n>(\"div\", \"popover\");\n","import { useEffect, useMemo, useState, useRef } from \"react\";\nimport type { FormFieldProps } from \"../form-field.types\";\nimport { useField, useObjectRef } from \"react-aria\";\nimport { mergeRefs } from \"@/utils\";\nimport {\n FormFieldContext,\n type FormFieldContextPayloadType,\n} from \"./form-field.context\";\nimport {\n FormFieldDescriptionSlot,\n FormFieldErrorSlot,\n FormFieldLabelSlot,\n FormFieldPopoverSlot,\n FormFieldRootSlot,\n} from \"../form-field.slots\";\nimport { Dialog, DialogTrigger, Popover } from \"react-aria-components\";\nimport { Box, IconButton } from \"@/components\";\nimport { ErrorOutline, HelpOutline } from \"@commercetools/nimbus-icons\";\n\n/**\n * # FormField.Root\n *\n * displays miscellaneous inputs in a FormField context\n *\n * @supportsStyleProps\n */\nexport const FormFieldRoot = function FormFieldRoot({\n ref: forwardedRef,\n id,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n children,\n ...props\n}: FormFieldProps) {\n const localRef = useRef<HTMLDivElement>(null);\n const ref = useObjectRef(mergeRefs(localRef, forwardedRef));\n const [context, setContext] = useState<FormFieldContextPayloadType>({\n label: null,\n description: null,\n error: null,\n info: null,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n });\n\n const useFieldArgs: Parameters<typeof useField>[0] = useMemo(() => {\n const args: Parameters<typeof useField>[0] = {\n id,\n description: context.description,\n errorMessage: context.error,\n };\n\n if (context.label) {\n args.label = context.label;\n } else {\n // Context will always start out null, so we need to stub out some aria attributes\n // FIXME: This is a hack to get the form field to work, but it's not the best solution\n // FIXME: We should find a better way to handle this by redesigning the FormField component's structure\n args[\"aria-label\"] = \"empty-label\";\n args[\"aria-labelledby\"] = \"empty-label\";\n }\n\n return args;\n }, [id, context.description, context.error, context.label]);\n\n const { labelProps, fieldProps, descriptionProps, errorMessageProps } =\n useField(useFieldArgs);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n }));\n }, [isInvalid, isRequired, isDisabled, isReadOnly]);\n\n const inputProps = useMemo(\n () => ({\n ...fieldProps,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n }),\n [fieldProps, isInvalid, isRequired, isDisabled, isReadOnly]\n );\n\n const contextValue = useMemo(\n () => ({ context, setContext, inputProps }),\n [context, inputProps]\n );\n\n return (\n <FormFieldContext.Provider value={contextValue}>\n <FormFieldRootSlot ref={ref} {...props}>\n {context.label && (\n <FormFieldLabelSlot {...context.labelSlotProps}>\n <label {...labelProps} data-required={isRequired}>\n {context.label}\n {isRequired && <sup aria-hidden=\"true\">*</sup>}\n </label>\n {context.info && (\n <DialogTrigger>\n <Box\n as=\"span\"\n display=\"inline-block\"\n position=\"relative\"\n width=\"1ch\"\n height=\"1ch\"\n ml=\"200\"\n >\n <Box\n as=\"span\"\n display=\"inline-flex\"\n position=\"absolute\"\n top=\"50%\"\n right=\"50%\"\n transform=\"translate(50%, -50%)\"\n >\n <IconButton\n aria-label=\"__MORE INFO\"\n size=\"2xs\"\n colorPalette=\"info\"\n variant=\"link\"\n >\n <HelpOutline />\n </IconButton>\n </Box>\n </Box>\n <Popover>\n <FormFieldPopoverSlot asChild>\n <Dialog>\n <Box p=\"300\">{context.info}</Box>\n </Dialog>\n </FormFieldPopoverSlot>\n </Popover>\n </DialogTrigger>\n )}\n </FormFieldLabelSlot>\n )}\n {context.description && (\n <FormFieldDescriptionSlot\n {...descriptionProps}\n {...context.descriptionSlotProps}\n >\n {context.description}\n </FormFieldDescriptionSlot>\n )}\n {isInvalid && context.error && (\n <FormFieldErrorSlot\n {...errorMessageProps}\n {...context.errorSlotProps}\n >\n <Box\n as={ErrorOutline}\n display=\"inline-flex\"\n boxSize=\"400\"\n flexShrink=\"0\"\n mt=\"50\"\n />\n {context.error}\n </FormFieldErrorSlot>\n )}\n {children}\n </FormFieldRootSlot>\n </FormFieldContext.Provider>\n );\n};\n\nFormFieldRoot.displayName = \"FormField.Root\";\n","import { useContext, useEffect } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldLabelSlotProps } from \"../form-field.types\";\n\n/**\n * FormField.Label - The label element for the form field\n *\n * @supportsStyleProps\n */\n// TODO: should this be wrapped in react-aria's `LabelContext` provider?, e.g. https://react-spectrum.adobe.com/react-aria/TextField.html#custom-children\nexport const FormFieldLabel = ({\n children,\n ...labelSlotProps\n}: FormFieldLabelSlotProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n label: children,\n labelSlotProps,\n }));\n\n // Cleanup: clear label when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n label: null,\n labelSlotProps: undefined,\n }));\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldLabel.displayName = \"FormField.Label\";\n","import { Children, cloneElement, isValidElement, useContext } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldInputSlotProps } from \"../form-field.types\";\nimport { FormFieldInputSlot } from \"../form-field.slots\";\n\n/**\n * FormField.Input - The input wrapper element for the form field\n *\n * Renders children directly (with injected field props) to avoid\n * the state-based indirection that causes cursor position issues\n * on controlled inputs.\n *\n * @supportsStyleProps\n */\nexport const FormFieldInput = ({\n children,\n ...inputSlotProps\n}: FormFieldInputSlotProps) => {\n const { inputProps } = useContext(FormFieldContext);\n\n return (\n <FormFieldInputSlot {...inputSlotProps}>\n {Children.map(children, (child) => {\n if (isValidElement(child)) {\n return cloneElement(child, inputProps);\n }\n return child;\n })}\n </FormFieldInputSlot>\n );\n};\n\nFormFieldInput.displayName = \"FormField.Input\";\n","import { useContext, useEffect } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldDescriptionSlotProps } from \"../form-field.types\";\n\n/**\n * FormField.Description - The description element for the form field\n *\n * @supportsStyleProps\n */\nexport const FormFieldDescription = ({\n children,\n ...descriptionSlotProps\n}: FormFieldDescriptionSlotProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n description: children,\n descriptionSlotProps,\n }));\n\n // Cleanup: clear description when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n description: null,\n descriptionSlotProps: undefined,\n }));\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldDescription.displayName = \"FormField.Description\";\n","import { useContext, useEffect } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldErrorSlotProps } from \"../form-field.types\";\n\n/**\n * FormField.Error - The error message element for the form field\n *\n * @supportsStyleProps\n */\nexport const FormFieldError = ({\n children,\n ...errorSlotProps\n}: FormFieldErrorSlotProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n error: children,\n errorSlotProps,\n }));\n\n // Cleanup: clear error when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n error: null,\n errorSlotProps: undefined,\n }));\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldError.displayName = \"FormField.Error\";\n","import { useContext, useEffect, type ReactNode } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\n\ntype FormFieldInfoBoxProps = {\n /**\n * The content to display in the InfoBox\n */\n children: ReactNode;\n};\n\n/**\n * FormField.InfoBox - The info box popover content for the form field\n *\n * @supportsStyleProps\n */\nexport const FormFieldInfoBox = ({ children }: FormFieldInfoBoxProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n info: children,\n }));\n\n // Cleanup: clear info when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n info: null,\n }));\n };\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldInfoBox.displayName = \"FormField.InfoBox\";\n","import {\n FormFieldRoot,\n FormFieldLabel,\n FormFieldInput,\n FormFieldDescription,\n FormFieldError,\n FormFieldInfoBox,\n} from \"./components\";\n\nexport const FormField = {\n /**\n * # FormField.Root\n *\n * The root container for the form field that provides context and state management\n * for all child components. Handles React Aria integration for accessibility,\n * manages field state (required, invalid, disabled, readonly), and coordinates\n * rendering of label, input, description, and error elements.\n *\n * @example\n * ```tsx\n * <FormField.Root isRequired isInvalid>\n * <FormField.Label>Username</FormField.Label>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * <FormField.Description>Enter your username</FormField.Description>\n * <FormField.Error>Username is required</FormField.Error>\n * </FormField.Root>\n * ```\n */\n Root: FormFieldRoot,\n\n /**\n * # FormField.Label\n *\n * The label element for the form field. Automatically associates with the input\n * via React Aria and displays a required indicator when the field is required.\n * Supports an optional info box trigger for additional field information.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>Email Address</FormField.Label>\n * <FormField.InfoBox>\n * Your email will be used for account notifications\n * </FormField.InfoBox>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * </FormField.Root>\n * ```\n */\n Label: FormFieldLabel,\n\n /**\n * # FormField.Input\n *\n * The input wrapper element that receives and displays the actual input component.\n * Automatically clones children and passes accessibility props, validation state,\n * and field attributes from React Aria.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>Password</FormField.Label>\n * <FormField.Input>\n * <PasswordInput />\n * </FormField.Input>\n * </FormField.Root>\n * ```\n */\n Input: FormFieldInput,\n\n /**\n * # FormField.Description\n *\n * The description element that provides helpful information about the field.\n * Automatically associates with the input via `aria-describedby` for screen readers.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>Username</FormField.Label>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * <FormField.Description>\n * Must be 3-20 characters, letters and numbers only\n * </FormField.Description>\n * </FormField.Root>\n * ```\n */\n Description: FormFieldDescription,\n\n /**\n * # FormField.Error\n *\n * The error message element that displays validation errors. Only visible when\n * the field is invalid. Automatically associates with the input via\n * `aria-errormessage` and includes an error icon.\n *\n * @example\n * ```tsx\n * <FormField.Root isInvalid>\n * <FormField.Label>Email</FormField.Label>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * <FormField.Error>Please enter a valid email address</FormField.Error>\n * </FormField.Root>\n * ```\n */\n Error: FormFieldError,\n\n /**\n * # FormField.InfoBox\n *\n * The info box content that appears in a popover when the help icon next to\n * the label is clicked. Use for additional context or instructions that don't\n * need to be visible by default.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>API Key</FormField.Label>\n * <FormField.InfoBox>\n * Your API key can be found in your account settings.\n * Keep it secure and never share it publicly.\n * </FormField.InfoBox>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * </FormField.Root>\n * ```\n */\n InfoBox: FormFieldInfoBox,\n};\n\nexport {\n FormFieldRoot as _FormFieldRoot,\n FormFieldLabel as _FormFieldLabel,\n FormFieldInput as _FormFieldInput,\n FormFieldDescription as _FormFieldDescription,\n FormFieldError as _FormFieldError,\n FormFieldInfoBox as _FormFieldInfoBox,\n};\n"],"mappings":"mYA6BA,IAAa,GAAA,EAAA,EAAA,cAAA,CAAuD,CAClE,QAAS,CACP,MAAO,KACP,YAAa,KACb,MAAO,KACP,KAAM,IACR,EACA,eAAkB,CAAC,EACnB,WAAY,CAAC,CACf,CAAC,EC5BK,CAAE,eAAc,gBAAA,EAAA,EAAA,wBAAA,CAAwC,CAC5D,IAAK,iBACP,CAAC,EAGY,EAAoB,EAG/B,MAAO,MAAM,EAGF,EAAqB,EAGhC,MAAO,OAAO,EAGH,EAAqB,EAGhC,MAAO,OAAO,EAGH,EAA2B,EAGtC,MAAO,aAAa,EAGT,EAAqB,EAGhC,MAAO,OAAO,EAGH,EAAuB,EAGlC,MAAO,SAAS,ECtBL,EAAgB,SAAuB,CAClD,IAAK,EACL,KACA,YACA,aACA,aACA,aACA,WACA,GAAG,GACc,CAEjB,IAAM,EAAM,EAAA,EAAa,EAAA,GAAA,EAAA,EAAA,OAAA,CADe,IACL,EAAU,CAAY,CAAC,EACpD,CAAC,EAAS,IAAA,EAAA,EAAA,SAAA,CAAoD,CAClE,MAAO,KACP,YAAa,KACb,MAAO,KACP,KAAM,KACN,YACA,aACA,aACA,YACF,CAAC,EAsBK,CAAE,aAAY,aAAY,mBAAkB,qBAChD,EAAA,GAAA,EAAA,EAAA,QAAA,KArBiE,CACjE,IAAM,EAAuC,CAC3C,KACA,YAAa,EAAQ,YACrB,aAAc,EAAQ,KACxB,EAYA,OAVI,EAAQ,MACV,EAAK,MAAQ,EAAQ,OAKrB,EAAK,cA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+ {"version":3,"file":"form-field-CaTJgt57.cjs.js","names":[],"sources":["../../src/components/form-field/components/form-field.context.tsx","../../src/components/form-field/form-field.slots.tsx","../../src/components/form-field/components/form-field.root.tsx","../../src/components/form-field/components/form-field.label.tsx","../../src/components/form-field/components/form-field.input.tsx","../../src/components/form-field/components/form-field.description.tsx","../../src/components/form-field/components/form-field.error.tsx","../../src/components/form-field/components/form-field.info-box.tsx","../../src/components/form-field/form-field.tsx"],"sourcesContent":["import { createContext, type ReactNode } from \"react\";\nimport type {\n FormFieldDescriptionSlotProps,\n FormFieldErrorSlotProps,\n FormFieldLabelSlotProps,\n} from \"../form-field.types\";\n\nexport type FormFieldInputProps = Record<string, unknown>;\n\nexport type FormFieldContextPayloadType = {\n label: ReactNode;\n labelSlotProps?: FormFieldLabelSlotProps;\n description: ReactNode;\n descriptionSlotProps?: FormFieldDescriptionSlotProps;\n error: ReactNode;\n errorSlotProps?: FormFieldErrorSlotProps;\n info: ReactNode;\n isInvalid?: boolean;\n isRequired?: boolean;\n isDisabled?: boolean;\n isReadOnly?: boolean;\n};\n\nexport type FormFieldContextType = {\n context: FormFieldContextPayloadType;\n setContext: React.Dispatch<React.SetStateAction<FormFieldContextPayloadType>>;\n inputProps: FormFieldInputProps;\n};\n\nexport const FormFieldContext = createContext<FormFieldContextType>({\n context: {\n label: null,\n description: null,\n error: null,\n info: null,\n },\n setContext: () => {},\n inputProps: {},\n});\n","import { createSlotRecipeContext } from \"@chakra-ui/react/styled-system\";\nimport type {\n FormFieldRootSlotProps,\n FormFieldLabelSlotProps,\n FormFieldInputSlotProps,\n FormFieldDescriptionSlotProps,\n FormFieldErrorSlotProps,\n FormFieldPopoverSlotProps,\n} from \"./form-field.types\";\n\nconst { withProvider, withContext } = createSlotRecipeContext({\n key: \"nimbusFormField\",\n});\n\n// Root slot\nexport const FormFieldRootSlot = withProvider<\n HTMLDivElement,\n FormFieldRootSlotProps\n>(\"div\", \"root\");\n\n// Label Slot\nexport const FormFieldLabelSlot = withContext<\n HTMLDivElement,\n FormFieldLabelSlotProps\n>(\"div\", \"label\");\n\n// Input Slot\nexport const FormFieldInputSlot = withContext<\n HTMLDivElement,\n FormFieldInputSlotProps\n>(\"div\", \"input\");\n\n// Description Slot\nexport const FormFieldDescriptionSlot = withContext<\n HTMLDivElement,\n FormFieldDescriptionSlotProps\n>(\"div\", \"description\");\n\n// Error Slot\nexport const FormFieldErrorSlot = withContext<\n HTMLDivElement,\n FormFieldErrorSlotProps\n>(\"div\", \"error\");\n\n// Error Slot\nexport const FormFieldPopoverSlot = withContext<\n HTMLDivElement,\n FormFieldPopoverSlotProps\n>(\"div\", \"popover\");\n","import { useEffect, useMemo, useState, useRef } from \"react\";\nimport type { FormFieldProps } from \"../form-field.types\";\nimport { useField, useObjectRef } from \"react-aria\";\nimport { mergeRefs } from \"@/utils\";\nimport {\n FormFieldContext,\n type FormFieldContextPayloadType,\n} from \"./form-field.context\";\nimport {\n FormFieldDescriptionSlot,\n FormFieldErrorSlot,\n FormFieldLabelSlot,\n FormFieldPopoverSlot,\n FormFieldRootSlot,\n} from \"../form-field.slots\";\nimport { Dialog, DialogTrigger, Popover } from \"react-aria-components\";\nimport { Box, IconButton } from \"@/components\";\nimport { ErrorOutline, HelpOutline } from \"@commercetools/nimbus-icons\";\n\n/**\n * # FormField.Root\n *\n * displays miscellaneous inputs in a FormField context\n *\n * @supportsStyleProps\n */\nexport const FormFieldRoot = function FormFieldRoot({\n ref: forwardedRef,\n id,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n children,\n ...props\n}: FormFieldProps) {\n const localRef = useRef<HTMLDivElement>(null);\n const ref = useObjectRef(mergeRefs(localRef, forwardedRef));\n const [context, setContext] = useState<FormFieldContextPayloadType>({\n label: null,\n description: null,\n error: null,\n info: null,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n });\n\n const useFieldArgs: Parameters<typeof useField>[0] = useMemo(() => {\n const args: Parameters<typeof useField>[0] = {\n id,\n description: context.description,\n errorMessage: context.error,\n };\n\n if (context.label) {\n args.label = context.label;\n } else {\n // Context will always start out null, so we need to stub out some aria attributes\n // FIXME: This is a hack to get the form field to work, but it's not the best solution\n // FIXME: We should find a better way to handle this by redesigning the FormField component's structure\n args[\"aria-label\"] = \"empty-label\";\n args[\"aria-labelledby\"] = \"empty-label\";\n }\n\n return args;\n }, [id, context.description, context.error, context.label]);\n\n const { labelProps, fieldProps, descriptionProps, errorMessageProps } =\n useField(useFieldArgs);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n }));\n }, [isInvalid, isRequired, isDisabled, isReadOnly]);\n\n const inputProps = useMemo(\n () => ({\n ...fieldProps,\n isInvalid,\n isRequired,\n isDisabled,\n isReadOnly,\n }),\n [fieldProps, isInvalid, isRequired, isDisabled, isReadOnly]\n );\n\n const contextValue = useMemo(\n () => ({ context, setContext, inputProps }),\n [context, inputProps]\n );\n\n return (\n <FormFieldContext.Provider value={contextValue}>\n <FormFieldRootSlot ref={ref} {...props}>\n {context.label && (\n <FormFieldLabelSlot {...context.labelSlotProps}>\n <label {...labelProps} data-required={isRequired}>\n {context.label}\n {isRequired && <sup aria-hidden=\"true\">*</sup>}\n </label>\n {context.info && (\n <DialogTrigger>\n <Box\n as=\"span\"\n display=\"inline-block\"\n position=\"relative\"\n width=\"1ch\"\n height=\"1ch\"\n ml=\"200\"\n >\n <Box\n as=\"span\"\n display=\"inline-flex\"\n position=\"absolute\"\n top=\"50%\"\n right=\"50%\"\n transform=\"translate(50%, -50%)\"\n >\n <IconButton\n aria-label=\"__MORE INFO\"\n size=\"2xs\"\n colorPalette=\"info\"\n variant=\"link\"\n >\n <HelpOutline />\n </IconButton>\n </Box>\n </Box>\n <Popover>\n <FormFieldPopoverSlot asChild>\n <Dialog>\n <Box p=\"300\">{context.info}</Box>\n </Dialog>\n </FormFieldPopoverSlot>\n </Popover>\n </DialogTrigger>\n )}\n </FormFieldLabelSlot>\n )}\n {context.description && (\n <FormFieldDescriptionSlot\n {...descriptionProps}\n {...context.descriptionSlotProps}\n >\n {context.description}\n </FormFieldDescriptionSlot>\n )}\n {isInvalid && context.error && (\n <FormFieldErrorSlot\n {...errorMessageProps}\n {...context.errorSlotProps}\n >\n <Box\n as={ErrorOutline}\n display=\"inline-flex\"\n boxSize=\"400\"\n flexShrink=\"0\"\n mt=\"50\"\n />\n {context.error}\n </FormFieldErrorSlot>\n )}\n {children}\n </FormFieldRootSlot>\n </FormFieldContext.Provider>\n );\n};\n\nFormFieldRoot.displayName = \"FormField.Root\";\n","import { useContext, useEffect } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldLabelSlotProps } from \"../form-field.types\";\n\n/**\n * FormField.Label - The label element for the form field\n *\n * @supportsStyleProps\n */\n// TODO: should this be wrapped in react-aria's `LabelContext` provider?, e.g. https://react-spectrum.adobe.com/react-aria/TextField.html#custom-children\nexport const FormFieldLabel = ({\n children,\n ...labelSlotProps\n}: FormFieldLabelSlotProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n label: children,\n labelSlotProps,\n }));\n\n // Cleanup: clear label when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n label: null,\n labelSlotProps: undefined,\n }));\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldLabel.displayName = \"FormField.Label\";\n","import { Children, cloneElement, isValidElement, useContext } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldInputSlotProps } from \"../form-field.types\";\nimport { FormFieldInputSlot } from \"../form-field.slots\";\n\n/**\n * FormField.Input - The input wrapper element for the form field\n *\n * Renders children directly (with injected field props) to avoid\n * the state-based indirection that causes cursor position issues\n * on controlled inputs.\n *\n * @supportsStyleProps\n */\nexport const FormFieldInput = ({\n children,\n ...inputSlotProps\n}: FormFieldInputSlotProps) => {\n const { inputProps } = useContext(FormFieldContext);\n\n return (\n <FormFieldInputSlot {...inputSlotProps}>\n {Children.map(children, (child) => {\n if (isValidElement(child)) {\n return cloneElement(child, inputProps);\n }\n return child;\n })}\n </FormFieldInputSlot>\n );\n};\n\nFormFieldInput.displayName = \"FormField.Input\";\n","import { useContext, useEffect } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldDescriptionSlotProps } from \"../form-field.types\";\n\n/**\n * FormField.Description - The description element for the form field\n *\n * @supportsStyleProps\n */\nexport const FormFieldDescription = ({\n children,\n ...descriptionSlotProps\n}: FormFieldDescriptionSlotProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n description: children,\n descriptionSlotProps,\n }));\n\n // Cleanup: clear description when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n description: null,\n descriptionSlotProps: undefined,\n }));\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldDescription.displayName = \"FormField.Description\";\n","import { useContext, useEffect } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\nimport type { FormFieldErrorSlotProps } from \"../form-field.types\";\n\n/**\n * FormField.Error - The error message element for the form field\n *\n * @supportsStyleProps\n */\nexport const FormFieldError = ({\n children,\n ...errorSlotProps\n}: FormFieldErrorSlotProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n error: children,\n errorSlotProps,\n }));\n\n // Cleanup: clear error when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n error: null,\n errorSlotProps: undefined,\n }));\n };\n // eslint-disable-next-line react-hooks/exhaustive-deps\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldError.displayName = \"FormField.Error\";\n","import { useContext, useEffect, type ReactNode } from \"react\";\nimport { FormFieldContext } from \"./form-field.context\";\n\ntype FormFieldInfoBoxProps = {\n /**\n * The content to display in the InfoBox\n */\n children: ReactNode;\n};\n\n/**\n * FormField.InfoBox - The info box popover content for the form field\n *\n * @supportsStyleProps\n */\nexport const FormFieldInfoBox = ({ children }: FormFieldInfoBoxProps) => {\n const { setContext } = useContext(FormFieldContext);\n\n useEffect(() => {\n setContext((prevContext) => ({\n ...prevContext,\n info: children,\n }));\n\n // Cleanup: clear info when component unmounts\n return () => {\n setContext((prevContext) => ({\n ...prevContext,\n info: null,\n }));\n };\n }, [children, setContext]);\n\n return null;\n};\n\nFormFieldInfoBox.displayName = \"FormField.InfoBox\";\n","import {\n FormFieldRoot,\n FormFieldLabel,\n FormFieldInput,\n FormFieldDescription,\n FormFieldError,\n FormFieldInfoBox,\n} from \"./components\";\n\nexport const FormField = {\n /**\n * # FormField.Root\n *\n * The root container for the form field that provides context and state management\n * for all child components. Handles React Aria integration for accessibility,\n * manages field state (required, invalid, disabled, readonly), and coordinates\n * rendering of label, input, description, and error elements.\n *\n * @example\n * ```tsx\n * <FormField.Root isRequired isInvalid>\n * <FormField.Label>Username</FormField.Label>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * <FormField.Description>Enter your username</FormField.Description>\n * <FormField.Error>Username is required</FormField.Error>\n * </FormField.Root>\n * ```\n */\n Root: FormFieldRoot,\n\n /**\n * # FormField.Label\n *\n * The label element for the form field. Automatically associates with the input\n * via React Aria and displays a required indicator when the field is required.\n * Supports an optional info box trigger for additional field information.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>Email Address</FormField.Label>\n * <FormField.InfoBox>\n * Your email will be used for account notifications\n * </FormField.InfoBox>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * </FormField.Root>\n * ```\n */\n Label: FormFieldLabel,\n\n /**\n * # FormField.Input\n *\n * The input wrapper element that receives and displays the actual input component.\n * Automatically clones children and passes accessibility props, validation state,\n * and field attributes from React Aria.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>Password</FormField.Label>\n * <FormField.Input>\n * <PasswordInput />\n * </FormField.Input>\n * </FormField.Root>\n * ```\n */\n Input: FormFieldInput,\n\n /**\n * # FormField.Description\n *\n * The description element that provides helpful information about the field.\n * Automatically associates with the input via `aria-describedby` for screen readers.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>Username</FormField.Label>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * <FormField.Description>\n * Must be 3-20 characters, letters and numbers only\n * </FormField.Description>\n * </FormField.Root>\n * ```\n */\n Description: FormFieldDescription,\n\n /**\n * # FormField.Error\n *\n * The error message element that displays validation errors. Only visible when\n * the field is invalid. Automatically associates with the input via\n * `aria-errormessage` and includes an error icon.\n *\n * @example\n * ```tsx\n * <FormField.Root isInvalid>\n * <FormField.Label>Email</FormField.Label>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * <FormField.Error>Please enter a valid email address</FormField.Error>\n * </FormField.Root>\n * ```\n */\n Error: FormFieldError,\n\n /**\n * # FormField.InfoBox\n *\n * The info box content that appears in a popover when the help icon next to\n * the label is clicked. Use for additional context or instructions that don't\n * need to be visible by default.\n *\n * @example\n * ```tsx\n * <FormField.Root>\n * <FormField.Label>API Key</FormField.Label>\n * <FormField.InfoBox>\n * Your API key can be found in your account settings.\n * Keep it secure and never share it publicly.\n * </FormField.InfoBox>\n * <FormField.Input>\n * <TextInput />\n * </FormField.Input>\n * </FormField.Root>\n * ```\n */\n InfoBox: FormFieldInfoBox,\n};\n\nexport {\n FormFieldRoot as _FormFieldRoot,\n FormFieldLabel as _FormFieldLabel,\n FormFieldInput as _FormFieldInput,\n FormFieldDescription as _FormFieldDescription,\n FormFieldError as _FormFieldError,\n FormFieldInfoBox as _FormFieldInfoBox,\n};\n"],"mappings":"mYA6BA,IAAa,GAAA,EAAA,EAAA,cAAA,CAAuD,CAClE,QAAS,CACP,MAAO,KACP,YAAa,KACb,MAAO,KACP,KAAM,IACR,EACA,eAAkB,CAAC,EACnB,WAAY,CAA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EAElB,IACT,EAEA,EAAqB,YAAc,wBC3BnC,IAAa,GAAkB,CAC7B,WACA,GAAG,KAC0B,CAC7B,GAAM,CAAE,eAAA,EAAA,EAAA,WAAA,CAA0B,CAAgB,EAoBlD,OAlBA,EAAA,EAAA,UAAA,MACE,EAAY,IAAiB,CAC3B,GAAG,EACH,MAAO,EACP,gBACF,EAAE,MAGW,CACX,EAAY,IAAiB,CAC3B,GAAG,EACH,MAAO,KACP,eAAgB,IAAA,EAClB,EAAE,CACJ,GAEC,CAAC,EAAU,CAAU,CAAC,EAElB,IACT,EAEA,EAAe,YAAc,kBCrB7B,IAAa,GAAoB,CAAE,cAAsC,CACvE,GAAM,CAAE,eAAA,EAAA,EAAA,WAAA,CAA0B,CAAgB,EAiBlD,OAfA,EAAA,EAAA,UAAA,MACE,EAAY,IAAiB,CAC3B,GAAG,EACH,KAAM,CACR,EAAE,MAGW,CACX,EAAY,IAAiB,CAC3B,GAAG,EACH,KAAM,IACR,EAAE,CACJ,GACC,CAAC,EAAU,CAAU,CAAC,EAElB,IACT,EAEA,EAAiB,YAAc,oBC3B/B,IAAa,EAAY,CAqBvB,KAAM,EAsBN,MAAO,EAmBP,MAAO,EAqBP,YAAa,EAoBb,MAAO,EAuBP,QAAS,CACX"}
@@ -1,2 +1,2 @@
1
- const e=require("./useObjectRef-B_VeQHvx.cjs.js"),t=require("./merge-refs-DjTl2ATo.cjs.js"),n=require("./button-Dc_J_PNN.cjs.js");let r=require("react"),i=require("react/jsx-runtime");var a=a=>{let{children:o,ref:s,"aria-label":c,...l}=a,u=(0,r.useRef)(null),d=e.t(t.t(u,s));return(0,r.useEffect)(()=>{if(typeof process<`u`&&process.env.NODE_ENV!==`production`){let e=setTimeout(()=>{let e=u.current;if(e){let t=e.hasAttribute(`aria-label`)||e.hasAttribute(`aria-labelledby`),n=e.hasAttribute(`slot`);!t&&!n&&console.warn(`Nimbus: IconButton requires an accessible label. Either provide an 'aria-label' prop or use within a component that provides it via context (e.g., slot="clear" in ComboBox).`,e)}},0);return()=>clearTimeout(e)}},[c,l.slot]),(0,i.jsx)(n.t,{px:0,py:0,"aria-label":c,...l,ref:d,children:o})};a.displayName=`IconButton`,Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return a}});
2
- //# sourceMappingURL=icon-button-CSlFdpjB.cjs.js.map
1
+ const e=require("./useObjectRef-B_VeQHvx.cjs.js"),t=require("./merge-refs-DjTl2ATo.cjs.js"),n=require("./button-D6f5OX0h.cjs.js");let r=require("react"),i=require("react/jsx-runtime");var a=a=>{let{children:o,ref:s,"aria-label":c,...l}=a,u=(0,r.useRef)(null),d=e.t(t.t(u,s));return(0,r.useEffect)(()=>{if(typeof process<`u`&&process.env.NODE_ENV!==`production`){let e=setTimeout(()=>{let e=u.current;if(e){let t=e.hasAttribute(`aria-label`)||e.hasAttribute(`aria-labelledby`),n=e.hasAttribute(`slot`);!t&&!n&&console.warn(`Nimbus: IconButton requires an accessible label. Either provide an 'aria-label' prop or use within a component that provides it via context (e.g., slot="clear" in ComboBox).`,e)}},0);return()=>clearTimeout(e)}},[c,l.slot]),(0,i.jsx)(n.t,{px:0,py:0,"aria-label":c,...l,ref:d,children:o})};a.displayName=`IconButton`,Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return a}});
2
+ //# sourceMappingURL=icon-button-BG5cQycc.cjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"icon-button-CSlFdpjB.cjs.js","names":[],"sources":["../../src/components/icon-button/icon-button.tsx"],"sourcesContent":["import { useRef, useEffect } from \"react\";\nimport { useObjectRef } from \"react-aria\";\nimport { mergeRefs } from \"@/utils\";\nimport type { IconButtonProps } from \"./icon-button.types\";\nimport { Button } from \"@/components\";\n\ndeclare const process: { env: Record<string, string | undefined> } | undefined;\n\n/**\n * # IconButton\n *\n * displays a button with an icon only as child\n *\n * @see {@link https://nimbus-documentation.vercel.app/components/inputs/iconbutton}\n */\nexport const IconButton = (props: IconButtonProps) => {\n const {\n children,\n ref: forwardedRef,\n \"aria-label\": ariaLabel,\n ...restProps\n } = props;\n\n // Create a local ref and merge with forwarded ref\n const localRef = useRef<HTMLButtonElement>(null);\n const ref = useObjectRef(mergeRefs(localRef, forwardedRef));\n\n // Runtime accessibility check\n // Use setTimeout to defer check until after React Aria applies context props\n useEffect(() => {\n if (\n typeof process !== \"undefined\" &&\n process.env.NODE_ENV !== \"production\"\n ) {\n const timeoutId = setTimeout(() => {\n const element = localRef.current;\n if (element) {\n const hasAriaLabel =\n element.hasAttribute(\"aria-label\") ||\n element.hasAttribute(\"aria-labelledby\");\n\n // Skip warning if component is using slot-based context (Button will handle it)\n const isUsingSlot = element.hasAttribute(\"slot\");\n\n if (!hasAriaLabel && !isUsingSlot) {\n console.warn(\n \"Nimbus: IconButton requires an accessible label. \" +\n \"Either provide an 'aria-label' prop or use within a component that provides it via context (e.g., slot=\\\"clear\\\" in ComboBox).\",\n element\n );\n }\n }\n }, 0);\n\n return () => clearTimeout(timeoutId);\n }\n }, [ariaLabel, restProps.slot]);\n\n return (\n <Button px={0} py={0} aria-label={ariaLabel} {...restProps} ref={ref}>\n {children}\n </Button>\n );\n};\n\nIconButton.displayName = \"IconButton\";\n"],"mappings":"wLAeA,IAAa,EAAc,GAA2B,CACpD,GAAM,CACJ,WACA,IAAK,EACL,aAAc,EACd,GAAG,GACD,EAGE,GAAA,EAAA,EAAA,OAAA,CAAqC,IAAI,EACzC,EAAM,EAAA,EAAa,EAAA,EAAU,EAAU,CAAY,CAAC,EAiC1D,OA7BA,EAAA,EAAA,UAAA,KAAgB,CACd,GACE,OAAO,QAAY,KAAA,QAAA,IAAA,WACM,aACzB,CACA,IAAM,EAAY,eAAiB,CACjC,IAAM,EAAU,EAAS,QACzB,GAAI,EAAS,CACX,IAAM,EACJ,EAAQ,aAAa,YAAY,GACjC,EAAQ,aAAa,iBAAiB,EAGlC,EAAc,EAAQ,aAAa,MAAM,EAE3C,CAAC,GAAgB,CAAC,GACpB,QAAQ,KACN,gLAEA,CACF,CAEJ,CACF,EAAG,CAAC,EAEJ,UAAa,aAAa,CAAS,CACrC,CACF,EAAG,CAAC,EAAW,EAAU,IAAI,CAAC,GAG5B,EAAA,EAAA,IAAA,CAAC,EAAA,EAAD,CAAQ,GAAI,EAAG,GAAI,EAAG,aAAY,EAAW,GAAI,EAAgB,MAC9D,UACK,CAAA,CAEZ,EAEA,EAAW,YAAc"}
1
+ {"version":3,"file":"icon-button-BG5cQycc.cjs.js","names":[],"sources":["../../src/components/icon-button/icon-button.tsx"],"sourcesContent":["import { useRef, useEffect } from \"react\";\nimport { useObjectRef } from \"react-aria\";\nimport { mergeRefs } from \"@/utils\";\nimport type { IconButtonProps } from \"./icon-button.types\";\nimport { Button } from \"@/components\";\n\ndeclare const process: { env: Record<string, string | undefined> } | undefined;\n\n/**\n * # IconButton\n *\n * displays a button with an icon only as child\n *\n * @see {@link https://nimbus-documentation.vercel.app/components/inputs/iconbutton}\n */\nexport const IconButton = (props: IconButtonProps) => {\n const {\n children,\n ref: forwardedRef,\n \"aria-label\": ariaLabel,\n ...restProps\n } = props;\n\n // Create a local ref and merge with forwarded ref\n const localRef = useRef<HTMLButtonElement>(null);\n const ref = useObjectRef(mergeRefs(localRef, forwardedRef));\n\n // Runtime accessibility check\n // Use setTimeout to defer check until after React Aria applies context props\n useEffect(() => {\n if (\n typeof process !== \"undefined\" &&\n process.env.NODE_ENV !== \"production\"\n ) {\n const timeoutId = setTimeout(() => {\n const element = localRef.current;\n if (element) {\n const hasAriaLabel =\n element.hasAttribute(\"aria-label\") ||\n element.hasAttribute(\"aria-labelledby\");\n\n // Skip warning if component is using slot-based context (Button will handle it)\n const isUsingSlot = element.hasAttribute(\"slot\");\n\n if (!hasAriaLabel && !isUsingSlot) {\n console.warn(\n \"Nimbus: IconButton requires an accessible label. \" +\n \"Either provide an 'aria-label' prop or use within a component that provides it via context (e.g., slot=\\\"clear\\\" in ComboBox).\",\n element\n );\n }\n }\n }, 0);\n\n return () => clearTimeout(timeoutId);\n }\n }, [ariaLabel, restProps.slot]);\n\n return (\n <Button px={0} py={0} aria-label={ariaLabel} {...restProps} ref={ref}>\n {children}\n </Button>\n );\n};\n\nIconButton.displayName = \"IconButton\";\n"],"mappings":"wLAeA,IAAa,EAAc,GAA2B,CACpD,GAAM,CACJ,WACA,IAAK,EACL,aAAc,EACd,GAAG,GACD,EAGE,GAAA,EAAA,EAAA,OAAA,CAAqC,IAAI,EACzC,EAAM,EAAA,EAAa,EAAA,EAAU,EAAU,CAAY,CAAC,EAiC1D,OA7BA,EAAA,EAAA,UAAA,KAAgB,CACd,GACE,OAAO,QAAY,KAAA,QAAA,IAAA,WACM,aACzB,CACA,IAAM,EAAY,eAAiB,CACjC,IAAM,EAAU,EAAS,QACzB,GAAI,EAAS,CACX,IAAM,EACJ,EAAQ,aAAa,YAAY,GACjC,EAAQ,aAAa,iBAAiB,EAGlC,EAAc,EAAQ,aAAa,MAAM,EAE3C,CAAC,GAAgB,CAAC,GACpB,QAAQ,KACN,gLAEA,CACF,CAEJ,CACF,EAAG,CAAC,EAEJ,UAAa,aAAa,CAAS,CACrC,CACF,EAAG,CAAC,EAAW,EAAU,IAAI,CAAC,GAG5B,EAAA,EAAA,IAAA,CAAC,EAAA,EAAD,CAAQ,GAAI,EAAG,GAAI,EAAG,aAAY,EAAW,GAAI,EAAgB,MAC9D,UACK,CAAA,CAEZ,EAEA,EAAW,YAAc"}
@@ -1,6 +1,6 @@
1
1
  import { t as e } from "./useObjectRef-B_3vY5-Q.esm.js";
2
2
  import { t } from "./merge-refs-C1GcH9iY.esm.js";
3
- import { t as n } from "./button-BhvlZrT2.esm.js";
3
+ import { t as n } from "./button-DyM-iqBq.esm.js";
4
4
  import { useEffect as r, useRef as i } from "react";
5
5
  import { jsx as a } from "react/jsx-runtime";
6
6
  //#region src/components/icon-button/icon-button.tsx
@@ -30,4 +30,4 @@ o.displayName = "IconButton";
30
30
  //#endregion
31
31
  export { o as t };
32
32
 
33
- //# sourceMappingURL=icon-button-6dtfz6Yf.esm.js.map
33
+ //# sourceMappingURL=icon-button-CyhrlrIv.esm.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"icon-button-6dtfz6Yf.esm.js","names":[],"sources":["../../src/components/icon-button/icon-button.tsx"],"sourcesContent":["import { useRef, useEffect } from \"react\";\nimport { useObjectRef } from \"react-aria\";\nimport { mergeRefs } from \"@/utils\";\nimport type { IconButtonProps } from \"./icon-button.types\";\nimport { Button } from \"@/components\";\n\ndeclare const process: { env: Record<string, string | undefined> } | undefined;\n\n/**\n * # IconButton\n *\n * displays a button with an icon only as child\n *\n * @see {@link https://nimbus-documentation.vercel.app/components/inputs/iconbutton}\n */\nexport const IconButton = (props: IconButtonProps) => {\n const {\n children,\n ref: forwardedRef,\n \"aria-label\": ariaLabel,\n ...restProps\n } = props;\n\n // Create a local ref and merge with forwarded ref\n const localRef = useRef<HTMLButtonElement>(null);\n const ref = useObjectRef(mergeRefs(localRef, forwardedRef));\n\n // Runtime accessibility check\n // Use setTimeout to defer check until after React Aria applies context props\n useEffect(() => {\n if (\n typeof process !== \"undefined\" &&\n process.env.NODE_ENV !== \"production\"\n ) {\n const timeoutId = setTimeout(() => {\n const element = localRef.current;\n if (element) {\n const hasAriaLabel =\n element.hasAttribute(\"aria-label\") ||\n element.hasAttribute(\"aria-labelledby\");\n\n // Skip warning if component is using slot-based context (Button will handle it)\n const isUsingSlot = element.hasAttribute(\"slot\");\n\n if (!hasAriaLabel && !isUsingSlot) {\n console.warn(\n \"Nimbus: IconButton requires an accessible label. \" +\n \"Either provide an 'aria-label' prop or use within a component that provides it via context (e.g., slot=\\\"clear\\\" in ComboBox).\",\n element\n );\n }\n }\n }, 0);\n\n return () => clearTimeout(timeoutId);\n }\n }, [ariaLabel, restProps.slot]);\n\n return (\n <Button px={0} py={0} aria-label={ariaLabel} {...restProps} ref={ref}>\n {children}\n </Button>\n );\n};\n\nIconButton.displayName = \"IconButton\";\n"],"mappings":";;;;;;AAeA,IAAa,KAAc,MAA2B;CACpD,IAAM,EACJ,aACA,KAAK,GACL,cAAc,GACd,GAAG,MACD,GAGE,IAAW,EAA0B,IAAI,GACzC,IAAM,EAAa,EAAU,GAAU,CAAY,CAAC;CAiC1D,OA7BA,QAAgB;EACd,IACE,OAAO,UAAY,OAAA,QAAA,IAAA,aACM,cACzB;GACA,IAAM,IAAY,iBAAiB;IACjC,IAAM,IAAU,EAAS;IACzB,IAAI,GAAS;KACX,IAAM,IACJ,EAAQ,aAAa,YAAY,KACjC,EAAQ,aAAa,iBAAiB,GAGlC,IAAc,EAAQ,aAAa,MAAM;KAE/C,AAAI,CAAC,KAAgB,CAAC,KACpB,QAAQ,KACN,mLAEA,CACF;IAEJ;GACF,GAAG,CAAC;GAEJ,aAAa,aAAa,CAAS;EACrC;CACF,GAAG,CAAC,GAAW,EAAU,IAAI,CAAC,GAG5B,kBAAC,GAAD;EAAQ,IAAI;EAAG,IAAI;EAAG,cAAY;EAAW,GAAI;EAAgB;EAC9D;CACK,CAAA;AAEZ;AAEA,EAAW,cAAc"}
1
+ {"version":3,"file":"icon-button-CyhrlrIv.esm.js","names":[],"sources":["../../src/components/icon-button/icon-button.tsx"],"sourcesContent":["import { useRef, useEffect } from \"react\";\nimport { useObjectRef } from \"react-aria\";\nimport { mergeRefs } from \"@/utils\";\nimport type { IconButtonProps } from \"./icon-button.types\";\nimport { Button } from \"@/components\";\n\ndeclare const process: { env: Record<string, string | undefined> } | undefined;\n\n/**\n * # IconButton\n *\n * displays a button with an icon only as child\n *\n * @see {@link https://nimbus-documentation.vercel.app/components/inputs/iconbutton}\n */\nexport const IconButton = (props: IconButtonProps) => {\n const {\n children,\n ref: forwardedRef,\n \"aria-label\": ariaLabel,\n ...restProps\n } = props;\n\n // Create a local ref and merge with forwarded ref\n const localRef = useRef<HTMLButtonElement>(null);\n const ref = useObjectRef(mergeRefs(localRef, forwardedRef));\n\n // Runtime accessibility check\n // Use setTimeout to defer check until after React Aria applies context props\n useEffect(() => {\n if (\n typeof process !== \"undefined\" &&\n process.env.NODE_ENV !== \"production\"\n ) {\n const timeoutId = setTimeout(() => {\n const element = localRef.current;\n if (element) {\n const hasAriaLabel =\n element.hasAttribute(\"aria-label\") ||\n element.hasAttribute(\"aria-labelledby\");\n\n // Skip warning if component is using slot-based context (Button will handle it)\n const isUsingSlot = element.hasAttribute(\"slot\");\n\n if (!hasAriaLabel && !isUsingSlot) {\n console.warn(\n \"Nimbus: IconButton requires an accessible label. \" +\n \"Either provide an 'aria-label' prop or use within a component that provides it via context (e.g., slot=\\\"clear\\\" in ComboBox).\",\n element\n );\n }\n }\n }, 0);\n\n return () => clearTimeout(timeoutId);\n }\n }, [ariaLabel, restProps.slot]);\n\n return (\n <Button px={0} py={0} aria-label={ariaLabel} {...restProps} ref={ref}>\n {children}\n </Button>\n );\n};\n\nIconButton.displayName = \"IconButton\";\n"],"mappings":";;;;;;AAeA,IAAa,KAAc,MAA2B;CACpD,IAAM,EACJ,aACA,KAAK,GACL,cAAc,GACd,GAAG,MACD,GAGE,IAAW,EAA0B,IAAI,GACzC,IAAM,EAAa,EAAU,GAAU,CAAY,CAAC;CAiC1D,OA7BA,QAAgB;EACd,IACE,OAAO,UAAY,OAAA,QAAA,IAAA,aACM,cACzB;GACA,IAAM,IAAY,iBAAiB;IACjC,IAAM,IAAU,EAAS;IACzB,IAAI,GAAS;KACX,IAAM,IACJ,EAAQ,aAAa,YAAY,KACjC,EAAQ,aAAa,iBAAiB,GAGlC,IAAc,EAAQ,aAAa,MAAM;KAE/C,AAAI,CAAC,KAAgB,CAAC,KACpB,QAAQ,KACN,mLAEA,CACF;IAEJ;GACF,GAAG,CAAC;GAEJ,aAAa,aAAa,CAAS;EACrC;CACF,GAAG,CAAC,GAAW,EAAU,IAAI,CAAC,GAG5B,kBAAC,GAAD;EAAQ,IAAI;EAAG,IAAI;EAAG,cAAY;EAAW,GAAI;EAAgB;EAC9D;CACK,CAAA;AAEZ;AAEA,EAAW,cAAc"}
@@ -1,2 +1,2 @@
1
- const e=require("./toggle-button-szYkDbB4.cjs.js");let t=require("react/jsx-runtime");var n=({"aria-label":n,children:r,ref:i,...a})=>(0,t.jsx)(e.t,{ref:i,"aria-label":n,px:0,py:0,...a,children:r});n.displayName=`IconToggleButton`,Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return n}});
2
- //# sourceMappingURL=icon-toggle-button-DJbu9dBg.cjs.js.map
1
+ const e=require("./toggle-button-B9m2DON6.cjs.js");let t=require("react/jsx-runtime");var n=({"aria-label":n,children:r,ref:i,...a})=>(0,t.jsx)(e.t,{ref:i,"aria-label":n,px:0,py:0,...a,children:r});n.displayName=`IconToggleButton`,Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return n}});
2
+ //# sourceMappingURL=icon-toggle-button-CH90F1eK.cjs.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"icon-toggle-button-DJbu9dBg.cjs.js","names":[],"sources":["../../src/components/icon-toggle-button/icon-toggle-button.tsx"],"sourcesContent":["import { ToggleButton } from \"@/components/toggle-button/toggle-button\";\nimport type { IconToggleButtonProps } from \"./icon-toggle-button.types\";\n\n/**\n * # IconToggleButton\n * ============================================================\n * A toggle button with only an icon as child. It is based\n * on the regular `ToggleButton` component, but with a few adjustments.\n *\n */\nexport const IconToggleButton = ({\n \"aria-label\": ariaLabel,\n children,\n ref,\n ...props\n}: IconToggleButtonProps) => {\n return (\n <ToggleButton ref={ref} aria-label={ariaLabel} px={0} py={0} {...props}>\n {children}\n </ToggleButton>\n );\n};\n\nIconToggleButton.displayName = \"IconToggleButton\";\n"],"mappings":"sFAUA,IAAa,GAAoB,CAC/B,aAAc,EACd,WACA,MACA,GAAG,MAGD,EAAA,EAAA,IAAA,CAAC,EAAA,EAAD,CAAmB,MAAK,aAAY,EAAW,GAAI,EAAG,GAAI,EAAG,GAAI,EAC9D,UACW,CAAA,EAIlB,EAAiB,YAAc"}
1
+ {"version":3,"file":"icon-toggle-button-CH90F1eK.cjs.js","names":[],"sources":["../../src/components/icon-toggle-button/icon-toggle-button.tsx"],"sourcesContent":["import { ToggleButton } from \"@/components/toggle-button/toggle-button\";\nimport type { IconToggleButtonProps } from \"./icon-toggle-button.types\";\n\n/**\n * # IconToggleButton\n * ============================================================\n * A toggle button with only an icon as child. It is based\n * on the regular `ToggleButton` component, but with a few adjustments.\n *\n */\nexport const IconToggleButton = ({\n \"aria-label\": ariaLabel,\n children,\n ref,\n ...props\n}: IconToggleButtonProps) => {\n return (\n <ToggleButton ref={ref} aria-label={ariaLabel} px={0} py={0} {...props}>\n {children}\n </ToggleButton>\n );\n};\n\nIconToggleButton.displayName = \"IconToggleButton\";\n"],"mappings":"sFAUA,IAAa,GAAoB,CAC/B,aAAc,EACd,WACA,MACA,GAAG,MAGD,EAAA,EAAA,IAAA,CAAC,EAAA,EAAD,CAAmB,MAAK,aAAY,EAAW,GAAI,EAAG,GAAI,EAAG,GAAI,EAC9D,UACW,CAAA,EAIlB,EAAiB,YAAc"}
@@ -1,4 +1,4 @@
1
- import { t as e } from "./toggle-button-DnjpkkaG.esm.js";
1
+ import { t as e } from "./toggle-button-D3UZNm_4.esm.js";
2
2
  import { jsx as t } from "react/jsx-runtime";
3
3
  //#region src/components/icon-toggle-button/icon-toggle-button.tsx
4
4
  var n = ({ "aria-label": n, children: r, ref: i, ...a }) => /* @__PURE__ */ t(e, {
@@ -13,4 +13,4 @@ n.displayName = "IconToggleButton";
13
13
  //#endregion
14
14
  export { n as t };
15
15
 
16
- //# sourceMappingURL=icon-toggle-button-Cesx6J1H.esm.js.map
16
+ //# sourceMappingURL=icon-toggle-button-DzYb5JyL.esm.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"icon-toggle-button-Cesx6J1H.esm.js","names":[],"sources":["../../src/components/icon-toggle-button/icon-toggle-button.tsx"],"sourcesContent":["import { ToggleButton } from \"@/components/toggle-button/toggle-button\";\nimport type { IconToggleButtonProps } from \"./icon-toggle-button.types\";\n\n/**\n * # IconToggleButton\n * ============================================================\n * A toggle button with only an icon as child. It is based\n * on the regular `ToggleButton` component, but with a few adjustments.\n *\n */\nexport const IconToggleButton = ({\n \"aria-label\": ariaLabel,\n children,\n ref,\n ...props\n}: IconToggleButtonProps) => {\n return (\n <ToggleButton ref={ref} aria-label={ariaLabel} px={0} py={0} {...props}>\n {children}\n </ToggleButton>\n );\n};\n\nIconToggleButton.displayName = \"IconToggleButton\";\n"],"mappings":";;;AAUA,IAAa,KAAoB,EAC/B,cAAc,GACd,aACA,QACA,GAAG,QAGD,kBAAC,GAAD;CAAmB;CAAK,cAAY;CAAW,IAAI;CAAG,IAAI;CAAG,GAAI;CAC9D;AACW,CAAA;AAIlB,EAAiB,cAAc"}
1
+ {"version":3,"file":"icon-toggle-button-DzYb5JyL.esm.js","names":[],"sources":["../../src/components/icon-toggle-button/icon-toggle-button.tsx"],"sourcesContent":["import { ToggleButton } from \"@/components/toggle-button/toggle-button\";\nimport type { IconToggleButtonProps } from \"./icon-toggle-button.types\";\n\n/**\n * # IconToggleButton\n * ============================================================\n * A toggle button with only an icon as child. It is based\n * on the regular `ToggleButton` component, but with a few adjustments.\n *\n */\nexport const IconToggleButton = ({\n \"aria-label\": ariaLabel,\n children,\n ref,\n ...props\n}: IconToggleButtonProps) => {\n return (\n <ToggleButton ref={ref} aria-label={ariaLabel} px={0} py={0} {...props}>\n {children}\n </ToggleButton>\n );\n};\n\nIconToggleButton.displayName = \"IconToggleButton\";\n"],"mappings":";;;AAUA,IAAa,KAAoB,EAC/B,cAAc,GACd,aACA,QACA,GAAG,QAGD,kBAAC,GAAD;CAAmB;CAAK,cAAY;CAAW,IAAI;CAAG,IAAI;CAAG,GAAI;CAC9D;AACW,CAAA;AAIlB,EAAiB,cAAc"}
@@ -0,0 +1,2 @@
1
+ const e=require("./mergeProps-B4zz6EqI.cjs.js"),t=require("./useObjectRef-B_VeQHvx.cjs.js"),n=require("./useLink-CmQ7I9Ho.cjs.js"),r=require("./merge-refs-DjTl2ATo.cjs.js");let i=require("react"),a=require("react/jsx-runtime");var{withProvider:o,withContext:s}=(0,require("@chakra-ui/react/styled-system").createSlotRecipeContext)({key:`nimbusItem`}),c=o(`div`,`root`),l=s(`div`,`header`),u=s(`div`,`media`),d=s(`div`,`content`),f=s(`div`,`title`),p=s(`div`,`description`),m=s(`div`,`actions`),h=s(`div`,`footer`),g=({ref:o,children:s,href:l,target:u,rel:d,download:f,ping:p,referrerPolicy:m,routerOptions:h,onPress:g,..._})=>{let v=t.t(r.t((0,i.useRef)(null),o)),{linkProps:y}=n.t({href:l,target:u,rel:d,download:f,ping:p,referrerPolicy:m,routerOptions:h,onPress:g,elementType:`a`},v);return(0,a.jsx)(c,{as:`a`,ref:v,...e.t(_,y,{onClickCapture:e=>{e.target?.closest?.(`[data-item-actions]`)&&e.preventDefault()}}),children:s})},_=({ref:e,children:t,...n})=>(0,a.jsx)(c,{ref:e,...n,children:t}),v=({href:e,...t})=>e==null?(0,a.jsx)(_,{...t}):(0,a.jsx)(g,{href:e,...t});v.displayName=`Item.Root`;var y=e=>{let{ref:t,children:n,...r}=e;return(0,a.jsx)(l,{ref:t,...r,children:n})};y.displayName=`Item.Header`;var b=e=>{let{ref:t,children:n,variant:r=`default`,...i}=e;return(0,a.jsx)(u,{ref:t,"data-variant":r,...i,children:n})};b.displayName=`Item.Media`;var x=e=>{let{ref:t,children:n,...r}=e;return(0,a.jsx)(d,{ref:t,...r,children:n})};x.displayName=`Item.Content`;var S=e=>{let{ref:t,children:n,...r}=e;return(0,a.jsx)(f,{ref:t,...r,children:n})};S.displayName=`Item.Title`;var C=e=>{let{ref:t,children:n,...r}=e;return(0,a.jsx)(p,{ref:t,...r,children:n})};C.displayName=`Item.Description`;var w=e=>{let{ref:t,children:n,...r}=e;return(0,a.jsx)(m,{ref:t,"data-item-actions":``,...r,children:n})};w.displayName=`Item.Actions`;var T=e=>{let{ref:t,children:n,...r}=e;return(0,a.jsx)(h,{ref:t,...r,children:n})};T.displayName=`Item.Footer`;var E={Root:v,Header:y,Media:b,Content:x,Title:S,Description:C,Actions:w,Footer:T};Object.defineProperty(exports,"a",{enumerable:!0,get:function(){return S}}),Object.defineProperty(exports,"c",{enumerable:!0,get:function(){return y}}),Object.defineProperty(exports,"i",{enumerable:!0,get:function(){return C}}),Object.defineProperty(exports,"l",{enumerable:!0,get:function(){return v}}),Object.defineProperty(exports,"n",{enumerable:!0,get:function(){return T}}),Object.defineProperty(exports,"o",{enumerable:!0,get:function(){return x}}),Object.defineProperty(exports,"r",{enumerable:!0,get:function(){return w}}),Object.defineProperty(exports,"s",{enumerable:!0,get:function(){return b}}),Object.defineProperty(exports,"t",{enumerable:!0,get:function(){return E}});
2
+ //# sourceMappingURL=item-DW8Z2EjT.cjs.js.map