@televet/kibble-ui 4.0.0-beta.61 → 4.0.0-beta.63

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 (376) hide show
  1. package/dist/chunks/{alert.types-Drmhsarm.js → alert.types-D-Oi8lzU.js} +2 -2
  2. package/dist/chunks/{alert.types-Drmhsarm.js.map → alert.types-D-Oi8lzU.js.map} +1 -1
  3. package/dist/chunks/{alert.types-DzQFs0lR.js → alert.types-QjdV89J8.js} +3 -3
  4. package/dist/chunks/{alert.types-DzQFs0lR.js.map → alert.types-QjdV89J8.js.map} +1 -1
  5. package/dist/chunks/avatar.component-Bx-G6wRN.js +2 -0
  6. package/dist/chunks/{avatar.component-BsLD7swi.js.map → avatar.component-Bx-G6wRN.js.map} +1 -1
  7. package/dist/chunks/{avatar.component-BvnohMit.js → avatar.component-DhnsK_Su.js} +14 -14
  8. package/dist/chunks/{avatar.component-BvnohMit.js.map → avatar.component-DhnsK_Su.js.map} +1 -1
  9. package/dist/chunks/{avatarGroup.component-BlBlSEzG.js → avatarGroup.component-BuIOss-r.js} +2 -2
  10. package/dist/chunks/{avatarGroup.component-BlBlSEzG.js.map → avatarGroup.component-BuIOss-r.js.map} +1 -1
  11. package/dist/chunks/{avatarGroup.component-DIFhg6s2.js → avatarGroup.component-DQ-llmL4.js} +2 -2
  12. package/dist/chunks/{avatarGroup.component-DIFhg6s2.js.map → avatarGroup.component-DQ-llmL4.js.map} +1 -1
  13. package/dist/chunks/{buttonGroup.component-JGTE03ym.js → buttonGroup.component-BniN5aY0.js} +2 -2
  14. package/dist/chunks/{buttonGroup.component-JGTE03ym.js.map → buttonGroup.component-BniN5aY0.js.map} +1 -1
  15. package/dist/chunks/{buttonGroup.component-C7fLZ6bu.js → buttonGroup.component-CUgf40bo.js} +2 -2
  16. package/dist/chunks/{buttonGroup.component-C7fLZ6bu.js.map → buttonGroup.component-CUgf40bo.js.map} +1 -1
  17. package/dist/chunks/{characterCounter.component-Bw5t3Lme.js → characterCounter.component-0krhcDgO.js} +3 -3
  18. package/dist/chunks/{characterCounter.component-Bw5t3Lme.js.map → characterCounter.component-0krhcDgO.js.map} +1 -1
  19. package/dist/chunks/{characterCounter.component-TfF2D3d5.js → characterCounter.component-C5Ju67wX.js} +2 -2
  20. package/dist/chunks/{characterCounter.component-TfF2D3d5.js.map → characterCounter.component-C5Ju67wX.js.map} +1 -1
  21. package/dist/chunks/checkbox.component-CanZsQHo.js +2 -0
  22. package/dist/chunks/{checkbox.component-CcG-gktf.js.map → checkbox.component-CanZsQHo.js.map} +1 -1
  23. package/dist/chunks/{checkbox.component-BkZ5Vryu.js → checkbox.component-D1hf8o_B.js} +10 -10
  24. package/dist/chunks/{checkbox.component-BkZ5Vryu.js.map → checkbox.component-D1hf8o_B.js.map} +1 -1
  25. package/dist/chunks/{checkbox.records-CIoa-J68.js → checkbox.records-BtLBaHBy.js} +12 -12
  26. package/dist/chunks/{checkbox.records-CIoa-J68.js.map → checkbox.records-BtLBaHBy.js.map} +1 -1
  27. package/dist/chunks/checkbox.records-wbkLltak.js +2 -0
  28. package/dist/chunks/{checkbox.records-FPSZIvGa.js.map → checkbox.records-wbkLltak.js.map} +1 -1
  29. package/dist/chunks/{checkboxGroup.component-DlhqnGf3.js → checkboxGroup.component-CfynWbnU.js} +2 -2
  30. package/dist/chunks/{checkboxGroup.component-DlhqnGf3.js.map → checkboxGroup.component-CfynWbnU.js.map} +1 -1
  31. package/dist/chunks/{checkboxGroup.component-B6mGFJjN.js → checkboxGroup.component-yDUy5BQi.js} +3 -3
  32. package/dist/chunks/{checkboxGroup.component-B6mGFJjN.js.map → checkboxGroup.component-yDUy5BQi.js.map} +1 -1
  33. package/dist/chunks/{config-DlTdf-Yt.js → config-B1FINd7s.js} +3 -3
  34. package/dist/chunks/{config-DlTdf-Yt.js.map → config-B1FINd7s.js.map} +1 -1
  35. package/dist/chunks/conversationCard.component-C5lvyhtU.js +2 -0
  36. package/dist/chunks/{conversationCard.component-BpJWXB1C.js.map → conversationCard.component-C5lvyhtU.js.map} +1 -1
  37. package/dist/chunks/{conversationCard.component-CLDj5iM-.js → conversationCard.component-E9e_Kl-G.js} +17 -18
  38. package/dist/chunks/{conversationCard.component-CLDj5iM-.js.map → conversationCard.component-E9e_Kl-G.js.map} +1 -1
  39. package/dist/chunks/{datePicker.component-C7nA5KqB.js → datePicker.component-Cv88ibpq.js} +8 -8
  40. package/dist/chunks/{datePicker.component-C7nA5KqB.js.map → datePicker.component-Cv88ibpq.js.map} +1 -1
  41. package/dist/chunks/datePicker.component-DabILO51.js +15 -0
  42. package/dist/chunks/{datePicker.component-B_LcrVdQ.js.map → datePicker.component-DabILO51.js.map} +1 -1
  43. package/dist/chunks/dialog-trigger-BCeZGpGO.js +2 -0
  44. package/dist/chunks/{dialog-trigger-B5NK0lr-.js.map → dialog-trigger-BCeZGpGO.js.map} +1 -1
  45. package/dist/chunks/{dialog-trigger-BPlPzPU-.js → dialog-trigger-D2uDgMJr.js} +9 -9
  46. package/dist/chunks/{dialog-trigger-BPlPzPU-.js.map → dialog-trigger-D2uDgMJr.js.map} +1 -1
  47. package/dist/chunks/{heading.component-Dbv1l38e.js → heading.component-CcrIqjxB.js} +2 -2
  48. package/dist/chunks/{heading.component-Dbv1l38e.js.map → heading.component-CcrIqjxB.js.map} +1 -1
  49. package/dist/chunks/{heading.component-CSfaj4T8.js → heading.component-DZ7kmGcE.js} +2 -2
  50. package/dist/chunks/{heading.component-CSfaj4T8.js.map → heading.component-DZ7kmGcE.js.map} +1 -1
  51. package/dist/chunks/index-5cRW642o.js +2 -0
  52. package/dist/chunks/{index-DTJtldfK.js.map → index-5cRW642o.js.map} +1 -1
  53. package/dist/chunks/index-B4fjIWcA.js +2 -0
  54. package/dist/chunks/{index-CZz7hHWb.js.map → index-B4fjIWcA.js.map} +1 -1
  55. package/dist/chunks/index-BfD9Ne2e.js +2 -0
  56. package/dist/chunks/{index-BYf7SZUC.js.map → index-BfD9Ne2e.js.map} +1 -1
  57. package/dist/chunks/index-BlGAWSIX.js +3 -0
  58. package/dist/chunks/index-BlGAWSIX.js.map +1 -0
  59. package/dist/chunks/index-BmcSWiFh.js +2 -0
  60. package/dist/chunks/{index-ZaGEDS_0.js.map → index-BmcSWiFh.js.map} +1 -1
  61. package/dist/chunks/index-C323eOJV.js +1328 -0
  62. package/dist/chunks/index-C323eOJV.js.map +1 -0
  63. package/dist/chunks/{index-BNYygzo-.js → index-CBh9RZVL.js} +17 -18
  64. package/dist/chunks/{index-BNYygzo-.js.map → index-CBh9RZVL.js.map} +1 -1
  65. package/dist/chunks/index-CEYJbpt4.js +2 -0
  66. package/dist/chunks/{index-BDnnTdaJ.js.map → index-CEYJbpt4.js.map} +1 -1
  67. package/dist/chunks/index-CFnNmQf0.js +2 -0
  68. package/dist/chunks/{index-MlhL0PDC.js.map → index-CFnNmQf0.js.map} +1 -1
  69. package/dist/chunks/{index-Co91SHhW.js → index-CZPHIn6T.js} +3 -3
  70. package/dist/chunks/{index-Co91SHhW.js.map → index-CZPHIn6T.js.map} +1 -1
  71. package/dist/chunks/index-CedYIQt5.js +8 -0
  72. package/dist/chunks/{index-UWtj4ULm.js.map → index-CedYIQt5.js.map} +1 -1
  73. package/dist/chunks/{index-CjNAJEk5.js → index-Cqwkg1hU.js} +105 -106
  74. package/dist/chunks/{index-CjNAJEk5.js.map → index-Cqwkg1hU.js.map} +1 -1
  75. package/dist/chunks/{index-C2kxTsiE.js → index-Cuu1x05z.js} +16 -17
  76. package/dist/chunks/{index-C2kxTsiE.js.map → index-Cuu1x05z.js.map} +1 -1
  77. package/dist/chunks/{index-D9DU-5GF.js → index-D5Dscg8T.js} +48 -49
  78. package/dist/chunks/{index-D9DU-5GF.js.map → index-D5Dscg8T.js.map} +1 -1
  79. package/dist/chunks/{index-DkJX2kvl.js → index-DMSZTX7A.js} +9 -9
  80. package/dist/chunks/{index-DkJX2kvl.js.map → index-DMSZTX7A.js.map} +1 -1
  81. package/dist/chunks/{index-BBZxmcrY.js → index-DZGYG5M4.js} +2 -2
  82. package/dist/chunks/{index-BBZxmcrY.js.map → index-DZGYG5M4.js.map} +1 -1
  83. package/dist/chunks/{index-S1uNQPZj.js → index-Dq91nN6-.js} +3 -3
  84. package/dist/chunks/{index-S1uNQPZj.js.map → index-Dq91nN6-.js.map} +1 -1
  85. package/dist/chunks/{index-DcJZ8q0f.js → index-Dx94WMw1.js} +43 -44
  86. package/dist/chunks/{index-DcJZ8q0f.js.map → index-Dx94WMw1.js.map} +1 -1
  87. package/dist/chunks/index-Fztcdoo_.js +2 -0
  88. package/dist/chunks/index-Fztcdoo_.js.map +1 -0
  89. package/dist/chunks/index-WyVSig7F.js +70 -0
  90. package/dist/chunks/index-WyVSig7F.js.map +1 -0
  91. package/dist/chunks/{index-DUHFrLMI.js → index-f4Ba8Pq7.js} +15 -15
  92. package/dist/chunks/{index-DUHFrLMI.js.map → index-f4Ba8Pq7.js.map} +1 -1
  93. package/dist/chunks/index-hGlTuPbK.js +2 -0
  94. package/dist/chunks/{index-COoMV9Mh.js.map → index-hGlTuPbK.js.map} +1 -1
  95. package/dist/chunks/{logo.types-By8TqyNf.js → logo.types-CXQsathd.js} +2 -2
  96. package/dist/chunks/{logo.types-By8TqyNf.js.map → logo.types-CXQsathd.js.map} +1 -1
  97. package/dist/chunks/menu.component-BsIFHOah.js +2 -0
  98. package/dist/chunks/{menu.component-CDC_QKyu.js.map → menu.component-BsIFHOah.js.map} +1 -1
  99. package/dist/chunks/{menu.component-DRvQQe9M.js → menu.component-bdDcCEay.js} +26 -26
  100. package/dist/chunks/{menu.component-DRvQQe9M.js.map → menu.component-bdDcCEay.js.map} +1 -1
  101. package/dist/chunks/modal.context-DSKLfsJK.js +12 -0
  102. package/dist/chunks/modal.context-DSKLfsJK.js.map +1 -0
  103. package/dist/chunks/modal.context-EJ67QNzq.js +2 -0
  104. package/dist/chunks/modal.context-EJ67QNzq.js.map +1 -0
  105. package/dist/chunks/modal.types-DYw_hPtT.js +2 -0
  106. package/dist/chunks/{modal.types-Ctu6GZqZ.js.map → modal.types-DYw_hPtT.js.map} +1 -1
  107. package/dist/chunks/{modal.types-BXVbMaDF.js → modal.types-vrGXh5fF.js} +5 -5
  108. package/dist/chunks/{modal.types-BXVbMaDF.js.map → modal.types-vrGXh5fF.js.map} +1 -1
  109. package/dist/chunks/{notificationCounter.component-Bei8mHSZ.js → notificationCounter.component-DMr4Mlm9.js} +2 -2
  110. package/dist/chunks/{notificationCounter.component-Bei8mHSZ.js.map → notificationCounter.component-DMr4Mlm9.js.map} +1 -1
  111. package/dist/chunks/pinInput.types-DHBICngh.js +2 -0
  112. package/dist/chunks/{pinInput.types-BrSgAnPk.js.map → pinInput.types-DHBICngh.js.map} +1 -1
  113. package/dist/chunks/{pinInput.types-D8WW9fg2.js → pinInput.types-jvCDRIOC.js} +8 -8
  114. package/dist/chunks/{pinInput.types-D8WW9fg2.js.map → pinInput.types-jvCDRIOC.js.map} +1 -1
  115. package/dist/chunks/{popover-B9rNOU0g.js → popover-D0QoPsrG.js} +26 -26
  116. package/dist/chunks/{popover-B9rNOU0g.js.map → popover-D0QoPsrG.js.map} +1 -1
  117. package/dist/chunks/popover-DPEovmxh.js +2 -0
  118. package/dist/chunks/{popover-80QH8HEJ.js.map → popover-DPEovmxh.js.map} +1 -1
  119. package/dist/chunks/popover-root-provider-BYJE5I-P.js +2 -0
  120. package/dist/chunks/{popover-root-provider-DAMDDAHQ.js.map → popover-root-provider-BYJE5I-P.js.map} +1 -1
  121. package/dist/chunks/{popover-root-provider-CeLLpesI.js → popover-root-provider-Dt02njg5.js} +8 -8
  122. package/dist/chunks/{popover-root-provider-CeLLpesI.js.map → popover-root-provider-Dt02njg5.js.map} +1 -1
  123. package/dist/chunks/popover.component-BmB0qwpj.js +264 -0
  124. package/dist/chunks/popover.component-BmB0qwpj.js.map +1 -0
  125. package/dist/chunks/popover.component-DUX4fJNk.js +2 -0
  126. package/dist/chunks/popover.component-DUX4fJNk.js.map +1 -0
  127. package/dist/chunks/popover.recipe-BLsWPsAa.js +124 -0
  128. package/dist/chunks/popover.recipe-BLsWPsAa.js.map +1 -0
  129. package/dist/chunks/popover.recipe-av5Jdn1r.js +2 -0
  130. package/dist/chunks/popover.recipe-av5Jdn1r.js.map +1 -0
  131. package/dist/chunks/{use-locale-context-D-agiW5E.js → portal-D2KZrSzZ.js} +242 -242
  132. package/dist/chunks/portal-D2KZrSzZ.js.map +1 -0
  133. package/dist/chunks/portal-TWtD47zg.js +22 -0
  134. package/dist/chunks/portal-TWtD47zg.js.map +1 -0
  135. package/dist/chunks/radio.records-CEgwvLIL.js +2 -0
  136. package/dist/chunks/{radio.records-Bl1r1zAL.js.map → radio.records-CEgwvLIL.js.map} +1 -1
  137. package/dist/chunks/{radio.records-ASPGnfUI.js → radio.records-CzNYznSb.js} +16 -16
  138. package/dist/chunks/{radio.records-ASPGnfUI.js.map → radio.records-CzNYznSb.js.map} +1 -1
  139. package/dist/chunks/radioGroup.component-BhR1aKj7.js +2 -0
  140. package/dist/chunks/{radioGroup.component-PJdM56Ps.js.map → radioGroup.component-BhR1aKj7.js.map} +1 -1
  141. package/dist/chunks/{radioGroup.component-DYEA8yt6.js → radioGroup.component-CyJiJHx5.js} +20 -19
  142. package/dist/chunks/{radioGroup.component-DYEA8yt6.js.map → radioGroup.component-CyJiJHx5.js.map} +1 -1
  143. package/dist/chunks/{ratingDots.component-C29qdjq4.js → ratingDots.component-BKUKL6Mz.js} +2 -2
  144. package/dist/chunks/{ratingDots.component-C29qdjq4.js.map → ratingDots.component-BKUKL6Mz.js.map} +1 -1
  145. package/dist/chunks/{ratingDots.component-DMpVMl56.js → ratingDots.component-HUIKoSFb.js} +4 -4
  146. package/dist/chunks/{ratingDots.component-DMpVMl56.js.map → ratingDots.component-HUIKoSFb.js.map} +1 -1
  147. package/dist/chunks/render-strategy-CdSSbgPU.js +2 -0
  148. package/dist/chunks/{render-strategy-BmWbSgqh.js.map → render-strategy-CdSSbgPU.js.map} +1 -1
  149. package/dist/chunks/{render-strategy-C8hwN3bm.js → render-strategy-ql9Qx5Cz.js} +2 -2
  150. package/dist/chunks/{render-strategy-C8hwN3bm.js.map → render-strategy-ql9Qx5Cz.js.map} +1 -1
  151. package/dist/chunks/select.component-8ukrnBdk.js +2 -0
  152. package/dist/chunks/{select.component-BW4T3WXu.js.map → select.component-8ukrnBdk.js.map} +1 -1
  153. package/dist/chunks/{select.component-BgBg4Lti.js → select.component-DLt_2xlg.js} +44 -44
  154. package/dist/chunks/{select.component-BgBg4Lti.js.map → select.component-DLt_2xlg.js.map} +1 -1
  155. package/dist/chunks/{sortableList.component-CsJc009c.js → sortableList.component-B_7TyrzG.js} +3 -3
  156. package/dist/chunks/{sortableList.component-CsJc009c.js.map → sortableList.component-B_7TyrzG.js.map} +1 -1
  157. package/dist/chunks/{sortableList.component-B4oyHvop.js → sortableList.component-CR53llzt.js} +3 -3
  158. package/dist/chunks/{sortableList.component-B4oyHvop.js.map → sortableList.component-CR53llzt.js.map} +1 -1
  159. package/dist/chunks/{spinner.component-BIk6KPaO.js → spinner.component-Bir81DbZ.js} +3 -3
  160. package/dist/chunks/{spinner.component-BIk6KPaO.js.map → spinner.component-Bir81DbZ.js.map} +1 -1
  161. package/dist/chunks/{spinner.component-CxRLUzju.js → spinner.component-DIyDNcWp.js} +2 -2
  162. package/dist/chunks/{spinner.component-CxRLUzju.js.map → spinner.component-DIyDNcWp.js.map} +1 -1
  163. package/dist/chunks/{styledAvatar.types-D9gs5qgU.js → styledAvatar.types-BjuO516j.js} +2 -2
  164. package/dist/chunks/{styledAvatar.types-D9gs5qgU.js.map → styledAvatar.types-BjuO516j.js.map} +1 -1
  165. package/dist/chunks/{styledAvatar.types-2wZJjpPn.js → styledAvatar.types-CbfoVHIB.js} +2 -2
  166. package/dist/chunks/{styledAvatar.types-2wZJjpPn.js.map → styledAvatar.types-CbfoVHIB.js.map} +1 -1
  167. package/dist/chunks/{swatch.types-DbgA3RWc.js → swatch.types-B8OSJZ-a.js} +2 -2
  168. package/dist/chunks/{swatch.types-DbgA3RWc.js.map → swatch.types-B8OSJZ-a.js.map} +1 -1
  169. package/dist/chunks/switch.component-CPhSaMqG.js +2 -0
  170. package/dist/chunks/{switch.component-eY_h1Ybs.js.map → switch.component-CPhSaMqG.js.map} +1 -1
  171. package/dist/chunks/{switch.component-CfVjV1Ue.js → switch.component-Dpu_wRns.js} +11 -11
  172. package/dist/chunks/{switch.component-CfVjV1Ue.js.map → switch.component-Dpu_wRns.js.map} +1 -1
  173. package/dist/chunks/{tabs.component-CMIwLzI3.js → tabs.component-BHGBxzEH.js} +48 -48
  174. package/dist/chunks/{tabs.component-CMIwLzI3.js.map → tabs.component-BHGBxzEH.js.map} +1 -1
  175. package/dist/chunks/tabs.component-CY9u7o56.js +2 -0
  176. package/dist/chunks/{tabs.component-CzR7A6PQ.js.map → tabs.component-CY9u7o56.js.map} +1 -1
  177. package/dist/chunks/{tagBlock.component-B5nam_ih.js → tagBlock.component-3imRPwFH.js} +5 -5
  178. package/dist/chunks/{tagBlock.component-B5nam_ih.js.map → tagBlock.component-3imRPwFH.js.map} +1 -1
  179. package/dist/chunks/{tagBlock.component-xYSTqOZ3.js → tagBlock.component-LnQADvWP.js} +2 -2
  180. package/dist/chunks/{tagBlock.component-xYSTqOZ3.js.map → tagBlock.component-LnQADvWP.js.map} +1 -1
  181. package/dist/chunks/{textInput.component-BS85e6rj.js → textInput.component-4YWnSJOZ.js} +12 -12
  182. package/dist/chunks/{textInput.component-BS85e6rj.js.map → textInput.component-4YWnSJOZ.js.map} +1 -1
  183. package/dist/chunks/textInput.component-BJ3ija0b.js +2 -0
  184. package/dist/chunks/{textInput.component-Cyu1zXr7.js.map → textInput.component-BJ3ija0b.js.map} +1 -1
  185. package/dist/chunks/{textarea.component-Bv4aHURS.js → textarea.component-GhlEwhHu.js} +7 -7
  186. package/dist/chunks/{textarea.component-Bv4aHURS.js.map → textarea.component-GhlEwhHu.js.map} +1 -1
  187. package/dist/chunks/textarea.component-zej8Yk62.js +2 -0
  188. package/dist/chunks/{textarea.component-BxuJw-8y.js.map → textarea.component-zej8Yk62.js.map} +1 -1
  189. package/dist/chunks/theme.provider-CkBtkwtf.js +26 -0
  190. package/dist/chunks/theme.provider-CkBtkwtf.js.map +1 -0
  191. package/dist/chunks/{theme.provider-BsXpkFEI.js → theme.provider-D_vTiS-g.js} +1833 -1699
  192. package/dist/chunks/theme.provider-D_vTiS-g.js.map +1 -0
  193. package/dist/chunks/{timePicker.component-OiS6NoVE.js → timePicker.component-C7StGDmo.js} +2 -2
  194. package/dist/chunks/{timePicker.component-OiS6NoVE.js.map → timePicker.component-C7StGDmo.js.map} +1 -1
  195. package/dist/chunks/{timePicker.component-Dhvin2SE.js → timePicker.component-DBzIM9G4.js} +4 -4
  196. package/dist/chunks/{timePicker.component-Dhvin2SE.js.map → timePicker.component-DBzIM9G4.js.map} +1 -1
  197. package/dist/chunks/{timeRange.component-BKCL9z1j.js → timeRange.component-BceK2COI.js} +2 -2
  198. package/dist/chunks/{timeRange.component-BKCL9z1j.js.map → timeRange.component-BceK2COI.js.map} +1 -1
  199. package/dist/chunks/{timeRange.component-cN_7CZt6.js → timeRange.component-CNLSxsSZ.js} +2 -2
  200. package/dist/chunks/{timeRange.component-cN_7CZt6.js.map → timeRange.component-CNLSxsSZ.js.map} +1 -1
  201. package/dist/chunks/timestamp.component-CbhzpqAt.js +53 -0
  202. package/dist/chunks/{timestamp.component-DH5g5v08.js.map → timestamp.component-CbhzpqAt.js.map} +1 -1
  203. package/dist/chunks/timestamp.component-DWGPmV_e.js +2 -0
  204. package/dist/chunks/{timestamp.component-BQO8617_.js.map → timestamp.component-DWGPmV_e.js.map} +1 -1
  205. package/dist/chunks/toaster.records-CGym-iT-.js +2 -0
  206. package/dist/chunks/{toaster.records-BJo0j1IZ.js.map → toaster.records-CGym-iT-.js.map} +1 -1
  207. package/dist/chunks/{toaster.records-BGfpUOVt.js → toaster.records-Cf8bpHo8.js} +21 -22
  208. package/dist/chunks/{toaster.records-BGfpUOVt.js.map → toaster.records-Cf8bpHo8.js.map} +1 -1
  209. package/dist/chunks/{typography.records-C6G_65b4.js → typography.records-BeoK0Uyj.js} +2 -2
  210. package/dist/chunks/{typography.records-C6G_65b4.js.map → typography.records-BeoK0Uyj.js.map} +1 -1
  211. package/dist/chunks/{typography.records-jnjWfTLS.js → typography.records-Xg59taw9.js} +2 -2
  212. package/dist/chunks/{typography.records-jnjWfTLS.js.map → typography.records-Xg59taw9.js.map} +1 -1
  213. package/dist/chunks/{use-field-context-B_G7Yziz.js → use-field-context-C4IwmN39.js} +2 -2
  214. package/dist/chunks/{use-field-context-B_G7Yziz.js.map → use-field-context-C4IwmN39.js.map} +1 -1
  215. package/dist/chunks/use-field-context-xBX4EpFz.js +2 -0
  216. package/dist/chunks/{use-field-context--wBJQY1R.js.map → use-field-context-xBX4EpFz.js.map} +1 -1
  217. package/dist/chunks/withFormControl-BI8pqhZl.js +2 -0
  218. package/dist/chunks/{withFormControl-BI5J885a.js.map → withFormControl-BI8pqhZl.js.map} +1 -1
  219. package/dist/chunks/{withFormControl-TnKXd5oM.js → withFormControl-Cb632r_x.js} +49 -49
  220. package/dist/chunks/{withFormControl-TnKXd5oM.js.map → withFormControl-Cb632r_x.js.map} +1 -1
  221. package/dist/chunks/withTruncation-CDgWfFpO.js +562 -0
  222. package/dist/chunks/withTruncation-CDgWfFpO.js.map +1 -0
  223. package/dist/chunks/withTruncation-XdRr8uDJ.js +2 -0
  224. package/dist/chunks/withTruncation-XdRr8uDJ.js.map +1 -0
  225. package/dist/chunks/{wrap-B8tBNeBY.js → wrap-CYgSj8wY.js} +2 -2
  226. package/dist/chunks/{wrap-B8tBNeBY.js.map → wrap-CYgSj8wY.js.map} +1 -1
  227. package/dist/cjs/chakra/index.cjs +1 -1
  228. package/dist/cjs/chakra/index.cjs.map +1 -1
  229. package/dist/cjs/components/Alert/index.cjs +1 -1
  230. package/dist/cjs/components/Avatar/index.cjs +1 -1
  231. package/dist/cjs/components/AvatarGroup/index.cjs +1 -1
  232. package/dist/cjs/components/ButtonGroup/index.cjs +1 -1
  233. package/dist/cjs/components/CharacterCounter/index.cjs +1 -1
  234. package/dist/cjs/components/Checkbox/index.cjs +1 -1
  235. package/dist/cjs/components/CheckboxGroup/index.cjs +1 -1
  236. package/dist/cjs/components/ConversationCard/index.cjs +1 -1
  237. package/dist/cjs/components/DatePicker/index.cjs +1 -1
  238. package/dist/cjs/components/Heading/index.cjs +1 -1
  239. package/dist/cjs/components/Menu/index.cjs +1 -1
  240. package/dist/cjs/components/Modal/index.cjs +1 -1
  241. package/dist/cjs/components/PinInput/index.cjs +1 -1
  242. package/dist/cjs/components/Popover/index.cjs +1 -1
  243. package/dist/cjs/components/RadioGroup/index.cjs +1 -1
  244. package/dist/cjs/components/RatingDots/index.cjs +1 -1
  245. package/dist/cjs/components/Select/index.cjs +1 -1
  246. package/dist/cjs/components/SortableList/index.cjs +1 -1
  247. package/dist/cjs/components/Spinner/index.cjs +1 -1
  248. package/dist/cjs/components/StyledAvatar/index.cjs +1 -1
  249. package/dist/cjs/components/Switch/index.cjs +1 -1
  250. package/dist/cjs/components/Tabs/index.cjs +1 -1
  251. package/dist/cjs/components/TagBlock/index.cjs +1 -1
  252. package/dist/cjs/components/Text/index.cjs +1 -1
  253. package/dist/cjs/components/TextInput/index.cjs +1 -1
  254. package/dist/cjs/components/Textarea/index.cjs +1 -1
  255. package/dist/cjs/components/TimePicker/index.cjs +1 -1
  256. package/dist/cjs/components/TimeRange/index.cjs +1 -1
  257. package/dist/cjs/components/Timestamp/index.cjs +1 -1
  258. package/dist/cjs/components/Toast/index.cjs +1 -1
  259. package/dist/cjs/components/Tooltip/index.cjs +1 -1
  260. package/dist/cjs/components/index.cjs +1 -1
  261. package/dist/cjs/index.cjs +1 -1
  262. package/dist/cjs/theme/index.cjs +1 -1
  263. package/dist/esm/chakra/index.js +69 -69
  264. package/dist/esm/components/Alert/index.js +1 -1
  265. package/dist/esm/components/Avatar/index.js +1 -1
  266. package/dist/esm/components/AvatarGroup/index.js +1 -1
  267. package/dist/esm/components/ButtonGroup/index.js +1 -1
  268. package/dist/esm/components/CharacterCounter/index.js +1 -1
  269. package/dist/esm/components/Checkbox/index.js +1 -1
  270. package/dist/esm/components/CheckboxGroup/index.js +1 -1
  271. package/dist/esm/components/ConversationCard/index.js +1 -1
  272. package/dist/esm/components/DatePicker/index.js +1 -1
  273. package/dist/esm/components/Heading/index.js +1 -1
  274. package/dist/esm/components/Logo/index.js +1 -1
  275. package/dist/esm/components/Menu/index.js +1 -1
  276. package/dist/esm/components/Modal/index.js +1 -1
  277. package/dist/esm/components/NotificationCounter/index.js +1 -1
  278. package/dist/esm/components/PinInput/index.js +1 -1
  279. package/dist/esm/components/Popover/index.js +1 -1
  280. package/dist/esm/components/RadioGroup/index.js +1 -1
  281. package/dist/esm/components/RatingDots/index.js +1 -1
  282. package/dist/esm/components/Select/index.js +1 -1
  283. package/dist/esm/components/SortableList/index.js +1 -1
  284. package/dist/esm/components/Spinner/index.js +1 -1
  285. package/dist/esm/components/StyledAvatar/index.js +1 -1
  286. package/dist/esm/components/Swatch/index.js +1 -1
  287. package/dist/esm/components/Switch/index.js +1 -1
  288. package/dist/esm/components/Tabs/index.js +1 -1
  289. package/dist/esm/components/TagBlock/index.js +1 -1
  290. package/dist/esm/components/Text/index.js +1 -1
  291. package/dist/esm/components/TextInput/index.js +1 -1
  292. package/dist/esm/components/Textarea/index.js +1 -1
  293. package/dist/esm/components/TimePicker/index.js +1 -1
  294. package/dist/esm/components/TimeRange/index.js +1 -1
  295. package/dist/esm/components/Timestamp/index.js +1 -1
  296. package/dist/esm/components/Toast/index.js +1 -1
  297. package/dist/esm/components/Tooltip/index.js +1 -1
  298. package/dist/esm/components/index.js +41 -42
  299. package/dist/esm/components/index.js.map +1 -1
  300. package/dist/esm/index.js +60 -61
  301. package/dist/esm/index.js.map +1 -1
  302. package/dist/esm/theme/index.js +1 -1
  303. package/dist/types/components/Menu/menu.recipe.d.ts +1 -1
  304. package/dist/types/components/Modal/modal.recipe.d.ts +1 -1
  305. package/dist/types/components/TimePicker/timePicker.recipe.d.ts +1 -1
  306. package/dist/types/components/Tooltip/tooltip.component.d.ts +4 -2
  307. package/dist/types/theme/tokens/shadows/shadows.config.d.ts +3 -3
  308. package/dist/types/theme/tokens/sizes/sizes.config.d.ts +3 -3
  309. package/dist/types/theme/tokens/zIndices/zIndices.config.d.ts +10 -10
  310. package/package.json +1 -1
  311. package/dist/chunks/avatar.component-BsLD7swi.js +0 -2
  312. package/dist/chunks/checkbox.component-CcG-gktf.js +0 -2
  313. package/dist/chunks/checkbox.records-FPSZIvGa.js +0 -2
  314. package/dist/chunks/conversationCard.component-BpJWXB1C.js +0 -2
  315. package/dist/chunks/datePicker.component-B_LcrVdQ.js +0 -15
  316. package/dist/chunks/dialog-trigger-B5NK0lr-.js +0 -2
  317. package/dist/chunks/index-BDnnTdaJ.js +0 -2
  318. package/dist/chunks/index-BGwwyukg.js +0 -2
  319. package/dist/chunks/index-BGwwyukg.js.map +0 -1
  320. package/dist/chunks/index-BYf7SZUC.js +0 -2
  321. package/dist/chunks/index-COoMV9Mh.js +0 -2
  322. package/dist/chunks/index-CYk-7wwG.js +0 -1018
  323. package/dist/chunks/index-CYk-7wwG.js.map +0 -1
  324. package/dist/chunks/index-CZ42b9rT.js +0 -3
  325. package/dist/chunks/index-CZ42b9rT.js.map +0 -1
  326. package/dist/chunks/index-CZz7hHWb.js +0 -2
  327. package/dist/chunks/index-DTJtldfK.js +0 -2
  328. package/dist/chunks/index-MlhL0PDC.js +0 -2
  329. package/dist/chunks/index-UWtj4ULm.js +0 -8
  330. package/dist/chunks/index-ZaGEDS_0.js +0 -2
  331. package/dist/chunks/index-j7W9Hyzx.js +0 -322
  332. package/dist/chunks/index-j7W9Hyzx.js.map +0 -1
  333. package/dist/chunks/menu.component-CDC_QKyu.js +0 -2
  334. package/dist/chunks/modal.types-Ctu6GZqZ.js +0 -2
  335. package/dist/chunks/pinInput.types-BrSgAnPk.js +0 -2
  336. package/dist/chunks/popover-80QH8HEJ.js +0 -2
  337. package/dist/chunks/popover-root-provider-DAMDDAHQ.js +0 -2
  338. package/dist/chunks/popover.component-BSIk0lQx.js +0 -2
  339. package/dist/chunks/popover.component-BSIk0lQx.js.map +0 -1
  340. package/dist/chunks/popover.component-CUecFqu0.js +0 -322
  341. package/dist/chunks/popover.component-CUecFqu0.js.map +0 -1
  342. package/dist/chunks/popover.recipe--gMRcQTS.js +0 -479
  343. package/dist/chunks/popover.recipe--gMRcQTS.js.map +0 -1
  344. package/dist/chunks/popover.recipe-DLeyokHo.js +0 -2
  345. package/dist/chunks/popover.recipe-DLeyokHo.js.map +0 -1
  346. package/dist/chunks/radio.records-Bl1r1zAL.js +0 -2
  347. package/dist/chunks/radioGroup.component-PJdM56Ps.js +0 -2
  348. package/dist/chunks/render-strategy-BmWbSgqh.js +0 -2
  349. package/dist/chunks/select.component-BW4T3WXu.js +0 -2
  350. package/dist/chunks/switch.component-eY_h1Ybs.js +0 -2
  351. package/dist/chunks/tabs.component-CzR7A6PQ.js +0 -2
  352. package/dist/chunks/text.component--epnA3h2.js +0 -2
  353. package/dist/chunks/text.component--epnA3h2.js.map +0 -1
  354. package/dist/chunks/text.component-Ci1Zx-Vb.js +0 -12
  355. package/dist/chunks/text.component-Ci1Zx-Vb.js.map +0 -1
  356. package/dist/chunks/textInput.component-Cyu1zXr7.js +0 -2
  357. package/dist/chunks/textarea.component-BxuJw-8y.js +0 -2
  358. package/dist/chunks/theme.provider-BsXpkFEI.js.map +0 -1
  359. package/dist/chunks/theme.provider-CK-Af5GU.js +0 -26
  360. package/dist/chunks/theme.provider-CK-Af5GU.js.map +0 -1
  361. package/dist/chunks/timestamp.component-BQO8617_.js +0 -2
  362. package/dist/chunks/timestamp.component-DH5g5v08.js +0 -54
  363. package/dist/chunks/toaster.records-BJo0j1IZ.js +0 -2
  364. package/dist/chunks/tooltip.component-Yu5bnnPc.js +0 -2
  365. package/dist/chunks/tooltip.component-Yu5bnnPc.js.map +0 -1
  366. package/dist/chunks/tooltip.component-oofe83RC.js +0 -761
  367. package/dist/chunks/tooltip.component-oofe83RC.js.map +0 -1
  368. package/dist/chunks/use-field-context--wBJQY1R.js +0 -2
  369. package/dist/chunks/use-locale-context-BdqHZ8L8.js +0 -22
  370. package/dist/chunks/use-locale-context-BdqHZ8L8.js.map +0 -1
  371. package/dist/chunks/use-locale-context-D-agiW5E.js.map +0 -1
  372. package/dist/chunks/withFormControl-BI5J885a.js +0 -2
  373. package/dist/chunks/withTruncation-D0L2lj30.js +0 -67
  374. package/dist/chunks/withTruncation-D0L2lj30.js.map +0 -1
  375. package/dist/chunks/withTruncation-DdNEpmRa.js +0 -2
  376. package/dist/chunks/withTruncation-DdNEpmRa.js.map +0 -1
@@ -1,7 +1,7 @@
1
1
  import { j as t } from "./jsx-runtime-C5mzlN2N.js";
2
- import { W as c } from "./text.component-Ci1Zx-Vb.js";
2
+ import { W as c } from "./withTruncation-CDgWfFpO.js";
3
3
  import { t as n } from "./typography-Cqrokog3.js";
4
- import { a as d } from "./config-DlTdf-Yt.js";
4
+ import { d } from "./config-B1FINd7s.js";
5
5
  import { u as b } from "./use-slot-recipe-DhtQ1j_5.js";
6
6
  import { V as m } from "./v-stack-BZT7R_9f.js";
7
7
  import { S as f } from "./spinner-BWqSIW6m.js";
@@ -176,4 +176,4 @@ const S = ["root", "spinner", "label"], u = {
176
176
  export {
177
177
  V as S
178
178
  };
179
- //# sourceMappingURL=spinner.component-BIk6KPaO.js.map
179
+ //# sourceMappingURL=spinner.component-Bir81DbZ.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"spinner.component-BIk6KPaO.js","sources":["../../src/components/Spinner/spinner.recipe.ts","../../src/components/Spinner/spinner.component.tsx"],"sourcesContent":["import {\n defineSlotRecipe,\n SystemStyleObject,\n} from \"@chakra-ui/react/styled-system\";\nimport { SpinnerSize } from \"./spinner.types\";\nimport { TypographyVariant } from \"shared/types\";\nimport { typographyVariantStyles } from \"../../shared/records/typography\";\n\nconst spinnerSlots = [\"root\", \"spinner\", \"label\"] as const;\ntype SpinnerSlot = (typeof spinnerSlots)[number];\ntype SpinnerSlotStyles = {\n [key in SpinnerSlot]?: SystemStyleObject;\n};\n\nconst spinnerSizeStyles: Record<SpinnerSize, SpinnerSlotStyles> = {\n xs: {\n spinner: {\n h: 3,\n w: 3,\n },\n label: {\n fontSize: \"xs\",\n },\n },\n sm: {\n spinner: {\n h: 4,\n w: 4,\n },\n label: {\n fontSize: \"sm\",\n },\n },\n md: {\n spinner: {\n h: 6,\n w: 6,\n \"--spinner-size\": 6,\n },\n label: {\n fontSize: \"md\",\n },\n },\n lg: {\n spinner: {\n h: 8,\n w: 8,\n },\n label: {\n fontSize: \"lg\",\n },\n },\n xl: {\n spinner: {\n h: 12,\n w: 12,\n },\n label: {\n fontSize: \"xl\",\n },\n },\n};\n\nconst spinnerVariantStyles: Record<TypographyVariant, SpinnerSlotStyles> = {\n accent: {\n spinner: typographyVariantStyles.accent,\n },\n accentSubtle: {\n spinner: typographyVariantStyles.accentSubtle,\n },\n brand: {\n spinner: typographyVariantStyles.brand,\n },\n brandOnContrast: {\n spinner: typographyVariantStyles.brandOnContrast,\n },\n danger: {\n spinner: typographyVariantStyles.danger,\n },\n dangerOnContrast: {\n spinner: typographyVariantStyles.dangerOnContrast,\n },\n default: {\n spinner: typographyVariantStyles.default,\n },\n info: {\n spinner: typographyVariantStyles.info,\n },\n interactive: {\n spinner: typographyVariantStyles.interactive,\n },\n interactiveOnContrast: {\n spinner: typographyVariantStyles.interactiveOnContrast,\n },\n onContrast: {\n spinner: typographyVariantStyles.onContrast,\n },\n placeholder: {\n spinner: typographyVariantStyles.placeholder,\n },\n placeholderOnContrast: {\n spinner: typographyVariantStyles.placeholderOnContrast,\n },\n subtle: {\n spinner: typographyVariantStyles.subtle,\n },\n subtleOnContrast: {\n spinner: typographyVariantStyles.subtleOnContrast,\n },\n success: {\n spinner: typographyVariantStyles.success,\n },\n warning: {\n spinner: typographyVariantStyles.warning,\n },\n};\n\nexport const spinnerRecipe = defineSlotRecipe({\n slots: spinnerSlots,\n base: {\n root: {\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n },\n variants: {\n variant: spinnerVariantStyles,\n size: spinnerSizeStyles,\n fullScreen: {\n true: {\n root: {\n h: \"100%\",\n left: 0,\n top: 0,\n position: \"absolute\",\n w: \"100%\",\n zIndex: \"tooltipExtra\",\n },\n },\n false: {\n root: {\n h: \"max-content\",\n w: \"max-content\",\n },\n },\n },\n },\n defaultVariants: {\n fullScreen: false,\n size: \"md\",\n variant: \"brand\",\n },\n});\n","import React from \"react\";\nimport { Spinner as CSpinner } from \"@chakra-ui/react/spinner\";\nimport { VStack } from \"@chakra-ui/react/stack\";\nimport { SpinnerSize } from \"./spinner.types\";\nimport { Text, TextProps } from \"components/Text/text.component\";\nimport { TypographyVariant } from \"shared/types\";\nimport { useSlotRecipe } from \"@chakra-ui/react\";\nimport { spinnerRecipe } from \"./spinner.recipe\";\nimport { SemanticBackgroundColorToken } from \"theme/semanticTokens\";\n\nexport interface SpinnerProps {\n backdropColor?: SemanticBackgroundColorToken;\n fullScreen?: boolean;\n label?: string;\n labelProps?: Omit<TextProps, \"chilren\">;\n showLabel?: boolean;\n size?: SpinnerSize;\n variant?: TypographyVariant;\n}\n\nexport const Spinner = ({\n backdropColor = \"background.alpha.pressed\",\n fullScreen = false,\n label = \"Loading...\",\n labelProps,\n showLabel = false,\n size = \"md\",\n variant = \"accent\",\n}: SpinnerProps): React.JSX.Element => {\n const recipe = useSlotRecipe({ recipe: spinnerRecipe });\n const styles = recipe({ variant, size, fullScreen });\n\n return (\n <VStack\n className=\"Spinner\"\n data-testid=\"kibble-spinner\"\n css={styles.root}\n {...(fullScreen && { bg: backdropColor })}\n >\n <CSpinner css={styles.spinner} />\n {showLabel && (\n <Text\n className=\"Spinner__Label\"\n data-testid=\"kibble-spinner-label\"\n variant=\"subtle\"\n css={styles.label}\n {...labelProps}\n >\n {label}\n </Text>\n )}\n </VStack>\n );\n};\n"],"names":["spinnerSlots","spinnerSizeStyles","spinnerVariantStyles","typographyVariantStyles","spinnerRecipe","defineSlotRecipe","Spinner","backdropColor","fullScreen","label","labelProps","showLabel","size","variant","styles","useSlotRecipe","jsxs","VStack","jsx","CSpinner","Text"],"mappings":";;;;;;;AAQA,MAAMA,IAAe,CAAC,QAAQ,WAAW,OAAO,GAM1CC,IAA4D;AAAA,EAChE,IAAI;AAAA,IACF,SAAS;AAAA,MACP,GAAG;AAAA,MACH,GAAG;AAAA,IACL;AAAA,IACA,OAAO;AAAA,MACL,UAAU;AAAA,IAAA;AAAA,EAEd;AAAA,EACA,IAAI;AAAA,IACF,SAAS;AAAA,MACP,GAAG;AAAA,MACH,GAAG;AAAA,IACL;AAAA,IACA,OAAO;AAAA,MACL,UAAU;AAAA,IAAA;AAAA,EAEd;AAAA,EACA,IAAI;AAAA,IACF,SAAS;AAAA,MACP,GAAG;AAAA,MACH,GAAG;AAAA,MACH,kBAAkB;AAAA,IACpB;AAAA,IACA,OAAO;AAAA,MACL,UAAU;AAAA,IAAA;AAAA,EAEd;AAAA,EACA,IAAI;AAAA,IACF,SAAS;AAAA,MACP,GAAG;AAAA,MACH,GAAG;AAAA,IACL;AAAA,IACA,OAAO;AAAA,MACL,UAAU;AAAA,IAAA;AAAA,EAEd;AAAA,EACA,IAAI;AAAA,IACF,SAAS;AAAA,MACP,GAAG;AAAA,MACH,GAAG;AAAA,IACL;AAAA,IACA,OAAO;AAAA,MACL,UAAU;AAAA,IAAA;AAAA,EACZ;AAEJ,GAEMC,IAAqE;AAAA,EACzE,QAAQ;AAAA,IACN,SAASC,EAAwB;AAAA,EACnC;AAAA,EACA,cAAc;AAAA,IACZ,SAASA,EAAwB;AAAA,EACnC;AAAA,EACA,OAAO;AAAA,IACL,SAASA,EAAwB;AAAA,EACnC;AAAA,EACA,iBAAiB;AAAA,IACf,SAASA,EAAwB;AAAA,EACnC;AAAA,EACA,QAAQ;AAAA,IACN,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,IACN,SAAS;AAAA,EAAA;AAEb,CAAC,GCpIYK,IAAU,CAAC;AAAA,EACtB,eAAAC,IAAgB;AAAA,EAChB,YAAAC,IAAa;AAAA,EACb,OAAAC,IAAQ;AAAA,EACR,YAAAC;AAAA,EACA,WAAAC,IAAY;AAAA,EACZ,MAAAC,IAAO;AAAA,EACP,SAAAC,IAAU;AACZ,MAAuC;AAErC,QAAMC,IADSC,EAAc,EAAE,QAAQX,GAAe,EAChC,EAAE,SAAAS,GAAS,MAAAD,GAAM,YAAAJ,GAAY;AAGjD,SAAAQ,gBAAAA,EAAA;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,WAAU;AAAA,MACV,eAAY;AAAA,MACZ,KAAKH,EAAO;AAAA,MACX,GAAIN,KAAc,EAAE,IAAID,EAAc;AAAA,MAEvC,UAAA;AAAA,QAACW,gBAAAA,EAAAA,IAAAC,GAAA,EAAS,KAAKL,EAAO,QAAS,CAAA;AAAA,QAC9BH,KACCO,gBAAAA,EAAA;AAAA,UAACE;AAAAA,UAAA;AAAA,YACC,WAAU;AAAA,YACV,eAAY;AAAA,YACZ,SAAQ;AAAA,YACR,KAAKN,EAAO;AAAA,YACX,GAAGJ;AAAA,YAEH,UAAAD;AAAA,UAAA;AAAA,QAAA;AAAA,MACH;AAAA,IAAA;AAAA,EAEJ;AAEJ;"}
1
+ {"version":3,"file":"spinner.component-Bir81DbZ.js","sources":["../../src/components/Spinner/spinner.recipe.ts","../../src/components/Spinner/spinner.component.tsx"],"sourcesContent":["import {\n defineSlotRecipe,\n SystemStyleObject,\n} from \"@chakra-ui/react/styled-system\";\nimport { SpinnerSize } from \"./spinner.types\";\nimport { TypographyVariant } from \"shared/types\";\nimport { typographyVariantStyles } from \"../../shared/records/typography\";\n\nconst spinnerSlots = [\"root\", \"spinner\", \"label\"] as const;\ntype SpinnerSlot = (typeof spinnerSlots)[number];\ntype SpinnerSlotStyles = {\n [key in SpinnerSlot]?: SystemStyleObject;\n};\n\nconst spinnerSizeStyles: Record<SpinnerSize, SpinnerSlotStyles> = {\n xs: {\n spinner: {\n h: 3,\n w: 3,\n },\n label: {\n fontSize: \"xs\",\n },\n },\n sm: {\n spinner: {\n h: 4,\n w: 4,\n },\n label: {\n fontSize: \"sm\",\n },\n },\n md: {\n spinner: {\n h: 6,\n w: 6,\n \"--spinner-size\": 6,\n },\n label: {\n fontSize: \"md\",\n },\n },\n lg: {\n spinner: {\n h: 8,\n w: 8,\n },\n label: {\n fontSize: \"lg\",\n },\n },\n xl: {\n spinner: {\n h: 12,\n w: 12,\n },\n label: {\n fontSize: \"xl\",\n },\n },\n};\n\nconst spinnerVariantStyles: Record<TypographyVariant, SpinnerSlotStyles> = {\n accent: {\n spinner: typographyVariantStyles.accent,\n },\n accentSubtle: {\n spinner: typographyVariantStyles.accentSubtle,\n },\n brand: {\n spinner: typographyVariantStyles.brand,\n },\n brandOnContrast: {\n spinner: typographyVariantStyles.brandOnContrast,\n },\n danger: {\n spinner: typographyVariantStyles.danger,\n },\n dangerOnContrast: {\n spinner: typographyVariantStyles.dangerOnContrast,\n },\n default: {\n spinner: typographyVariantStyles.default,\n },\n info: {\n spinner: typographyVariantStyles.info,\n },\n interactive: {\n spinner: typographyVariantStyles.interactive,\n },\n interactiveOnContrast: {\n spinner: typographyVariantStyles.interactiveOnContrast,\n },\n onContrast: {\n spinner: typographyVariantStyles.onContrast,\n },\n placeholder: {\n spinner: typographyVariantStyles.placeholder,\n },\n placeholderOnContrast: {\n spinner: typographyVariantStyles.placeholderOnContrast,\n },\n subtle: {\n spinner: typographyVariantStyles.subtle,\n },\n subtleOnContrast: {\n spinner: typographyVariantStyles.subtleOnContrast,\n },\n success: {\n spinner: typographyVariantStyles.success,\n },\n warning: {\n spinner: typographyVariantStyles.warning,\n },\n};\n\nexport const spinnerRecipe = defineSlotRecipe({\n slots: spinnerSlots,\n base: {\n root: {\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n },\n variants: {\n variant: spinnerVariantStyles,\n size: spinnerSizeStyles,\n fullScreen: {\n true: {\n root: {\n h: \"100%\",\n left: 0,\n top: 0,\n position: \"absolute\",\n w: \"100%\",\n zIndex: \"tooltipExtra\",\n },\n },\n false: {\n root: {\n h: \"max-content\",\n w: \"max-content\",\n },\n },\n },\n },\n defaultVariants: {\n fullScreen: false,\n size: \"md\",\n variant: \"brand\",\n },\n});\n","import React from \"react\";\nimport { Spinner as CSpinner } from \"@chakra-ui/react/spinner\";\nimport { VStack } from \"@chakra-ui/react/stack\";\nimport { SpinnerSize } from \"./spinner.types\";\nimport { Text, TextProps } from \"components/Text/text.component\";\nimport { TypographyVariant } from \"shared/types\";\nimport { useSlotRecipe } from \"@chakra-ui/react\";\nimport { spinnerRecipe } from \"./spinner.recipe\";\nimport { SemanticBackgroundColorToken } from \"theme/semanticTokens\";\n\nexport interface SpinnerProps {\n backdropColor?: SemanticBackgroundColorToken;\n fullScreen?: boolean;\n label?: string;\n labelProps?: Omit<TextProps, \"chilren\">;\n showLabel?: boolean;\n size?: SpinnerSize;\n variant?: TypographyVariant;\n}\n\nexport const Spinner = ({\n backdropColor = \"background.alpha.pressed\",\n fullScreen = false,\n label = \"Loading...\",\n labelProps,\n showLabel = false,\n size = \"md\",\n variant = \"accent\",\n}: SpinnerProps): React.JSX.Element => {\n const recipe = useSlotRecipe({ recipe: spinnerRecipe });\n const styles = recipe({ variant, size, fullScreen });\n\n return (\n <VStack\n className=\"Spinner\"\n data-testid=\"kibble-spinner\"\n css={styles.root}\n {...(fullScreen && { bg: backdropColor })}\n >\n <CSpinner css={styles.spinner} />\n {showLabel && (\n <Text\n className=\"Spinner__Label\"\n data-testid=\"kibble-spinner-label\"\n variant=\"subtle\"\n css={styles.label}\n {...labelProps}\n >\n {label}\n </Text>\n )}\n </VStack>\n );\n};\n"],"names":["spinnerSlots","spinnerSizeStyles","spinnerVariantStyles","typographyVariantStyles","spinnerRecipe","defineSlotRecipe","Spinner","backdropColor","fullScreen","label","labelProps","showLabel","size","variant","styles","useSlotRecipe","jsx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AAAC,IAAY;AAAA,EACZ,MAAAC,IAAO;AAAA,EACP,SAAAC,IAAU;AACZ,MAAuC;AAErC,QAAMC,IADSC,EAAc,EAAE,QAAQX,GAAe,EAChC,EAAE,SAAAS,GAAS,MAAAD,GAAM,YAAAJ,GAAY;AAGjD,SAAAQ,gBAAAA,EAAA;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,WAAU;AAAA,MACV,eAAY;AAAA,MACZ,KAAKH,EAAO;AAAA,MACX,GAAIN,KAAc,EAAE,IAAID,EAAc;AAAA,MAEvC,UAAA;AAAA,QAACW,gBAAAA,EAAAA,IAAAC,GAAA,EAAS,KAAKL,EAAO,QAAS,CAAA;AAAA,QAC9BH,KACCO,gBAAAA,EAAA;AAAA,UAACE;AAAAA,UAAA;AAAA,YACC,WAAU;AAAA,YACV,eAAY;AAAA,YACZ,SAAQ;AAAA,YACR,KAAKN,EAAO;AAAA,YACX,GAAGJ;AAAA,YAEH,UAAAD;AAAA,UAAA;AAAA,QAAA;AAAA,MACH;AAAA,IAAA;AAAA,EAEJ;AAEJ;"}
@@ -1,2 +1,2 @@
1
- "use strict";const t=require("./jsx-runtime-BjDatQAs.js"),c=require("./text.component--epnA3h2.js"),n=require("./typography-CtiaGoJG.js"),y=require("./config-BFcXpdZo.js"),S=require("./use-slot-recipe-8liupslO.js"),d=require("./v-stack-DxjgpeJ0.js"),h=require("./spinner-BnpL14kK.js"),u=["root","spinner","label"],g={xs:{spinner:{h:3,w:3},label:{fontSize:"xs"}},sm:{spinner:{h:4,w:4},label:{fontSize:"sm"}},md:{spinner:{h:6,w:6,"--spinner-size":6},label:{fontSize:"md"}},lg:{spinner:{h:8,w:8},label:{fontSize:"lg"}},xl:{spinner:{h:12,w:12},label:{fontSize:"xl"}}},b={accent:{spinner:n.typographyVariantStyles.accent},accentSubtle:{spinner:n.typographyVariantStyles.accentSubtle},brand:{spinner:n.typographyVariantStyles.brand},brandOnContrast:{spinner:n.typographyVariantStyles.brandOnContrast},danger:{spinner:n.typographyVariantStyles.danger},dangerOnContrast:{spinner:n.typographyVariantStyles.dangerOnContrast},default:{spinner:n.typographyVariantStyles.default},info:{spinner:n.typographyVariantStyles.info},interactive:{spinner:n.typographyVariantStyles.interactive},interactiveOnContrast:{spinner:n.typographyVariantStyles.interactiveOnContrast},onContrast:{spinner:n.typographyVariantStyles.onContrast},placeholder:{spinner:n.typographyVariantStyles.placeholder},placeholderOnContrast:{spinner:n.typographyVariantStyles.placeholderOnContrast},subtle:{spinner:n.typographyVariantStyles.subtle},subtleOnContrast:{spinner:n.typographyVariantStyles.subtleOnContrast},success:{spinner:n.typographyVariantStyles.success},warning:{spinner:n.typographyVariantStyles.warning}},x=y.defineSlotRecipe({slots:u,base:{root:{alignItems:"center",justifyContent:"center"}},variants:{variant:b,size:g,fullScreen:{true:{root:{h:"100%",left:0,top:0,position:"absolute",w:"100%",zIndex:"tooltipExtra"}},false:{root:{h:"max-content",w:"max-content"}}}},defaultVariants:{fullScreen:!1,size:"md",variant:"brand"}}),V=({backdropColor:s="background.alpha.pressed",fullScreen:r=!1,label:a="Loading...",labelProps:i,showLabel:p=!1,size:o="md",variant:l="accent"})=>{const e=S.useSlotRecipe({recipe:x})({variant:l,size:o,fullScreen:r});return t.jsxRuntimeExports.jsxs(d.VStack,{className:"Spinner","data-testid":"kibble-spinner",css:e.root,...r&&{bg:s},children:[t.jsxRuntimeExports.jsx(h.Spinner,{css:e.spinner}),p&&t.jsxRuntimeExports.jsx(c.WrappedText,{className:"Spinner__Label","data-testid":"kibble-spinner-label",variant:"subtle",css:e.label,...i,children:a})]})};exports.Spinner=V;
2
- //# sourceMappingURL=spinner.component-CxRLUzju.js.map
1
+ "use strict";const t=require("./jsx-runtime-BjDatQAs.js"),c=require("./withTruncation-XdRr8uDJ.js"),n=require("./typography-CtiaGoJG.js"),y=require("./config-BFcXpdZo.js"),S=require("./use-slot-recipe-8liupslO.js"),h=require("./v-stack-DxjgpeJ0.js"),u=require("./spinner-BnpL14kK.js"),d=["root","spinner","label"],g={xs:{spinner:{h:3,w:3},label:{fontSize:"xs"}},sm:{spinner:{h:4,w:4},label:{fontSize:"sm"}},md:{spinner:{h:6,w:6,"--spinner-size":6},label:{fontSize:"md"}},lg:{spinner:{h:8,w:8},label:{fontSize:"lg"}},xl:{spinner:{h:12,w:12},label:{fontSize:"xl"}}},b={accent:{spinner:n.typographyVariantStyles.accent},accentSubtle:{spinner:n.typographyVariantStyles.accentSubtle},brand:{spinner:n.typographyVariantStyles.brand},brandOnContrast:{spinner:n.typographyVariantStyles.brandOnContrast},danger:{spinner:n.typographyVariantStyles.danger},dangerOnContrast:{spinner:n.typographyVariantStyles.dangerOnContrast},default:{spinner:n.typographyVariantStyles.default},info:{spinner:n.typographyVariantStyles.info},interactive:{spinner:n.typographyVariantStyles.interactive},interactiveOnContrast:{spinner:n.typographyVariantStyles.interactiveOnContrast},onContrast:{spinner:n.typographyVariantStyles.onContrast},placeholder:{spinner:n.typographyVariantStyles.placeholder},placeholderOnContrast:{spinner:n.typographyVariantStyles.placeholderOnContrast},subtle:{spinner:n.typographyVariantStyles.subtle},subtleOnContrast:{spinner:n.typographyVariantStyles.subtleOnContrast},success:{spinner:n.typographyVariantStyles.success},warning:{spinner:n.typographyVariantStyles.warning}},V=y.defineSlotRecipe({slots:d,base:{root:{alignItems:"center",justifyContent:"center"}},variants:{variant:b,size:g,fullScreen:{true:{root:{h:"100%",left:0,top:0,position:"absolute",w:"100%",zIndex:"tooltipExtra"}},false:{root:{h:"max-content",w:"max-content"}}}},defaultVariants:{fullScreen:!1,size:"md",variant:"brand"}}),f=({backdropColor:s="background.alpha.pressed",fullScreen:r=!1,label:a="Loading...",labelProps:i,showLabel:p=!1,size:o="md",variant:l="accent"})=>{const e=S.useSlotRecipe({recipe:V})({variant:l,size:o,fullScreen:r});return t.jsxRuntimeExports.jsxs(h.VStack,{className:"Spinner","data-testid":"kibble-spinner",css:e.root,...r&&{bg:s},children:[t.jsxRuntimeExports.jsx(u.Spinner,{css:e.spinner}),p&&t.jsxRuntimeExports.jsx(c.WrappedText,{className:"Spinner__Label","data-testid":"kibble-spinner-label",variant:"subtle",css:e.label,...i,children:a})]})};exports.Spinner=f;
2
+ //# sourceMappingURL=spinner.component-DIyDNcWp.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"spinner.component-CxRLUzju.js","sources":["../../src/components/Spinner/spinner.recipe.ts","../../src/components/Spinner/spinner.component.tsx"],"sourcesContent":["import {\n defineSlotRecipe,\n SystemStyleObject,\n} from \"@chakra-ui/react/styled-system\";\nimport { SpinnerSize } from \"./spinner.types\";\nimport { TypographyVariant } from \"shared/types\";\nimport { typographyVariantStyles } from \"../../shared/records/typography\";\n\nconst spinnerSlots = [\"root\", \"spinner\", \"label\"] as const;\ntype SpinnerSlot = (typeof spinnerSlots)[number];\ntype SpinnerSlotStyles = {\n [key in SpinnerSlot]?: SystemStyleObject;\n};\n\nconst spinnerSizeStyles: Record<SpinnerSize, SpinnerSlotStyles> = {\n xs: {\n spinner: {\n h: 3,\n w: 3,\n },\n label: {\n fontSize: \"xs\",\n },\n },\n sm: {\n spinner: {\n h: 4,\n w: 4,\n },\n label: {\n fontSize: \"sm\",\n },\n },\n md: {\n spinner: {\n h: 6,\n w: 6,\n \"--spinner-size\": 6,\n },\n label: {\n fontSize: \"md\",\n },\n },\n lg: {\n spinner: {\n h: 8,\n w: 8,\n },\n label: {\n fontSize: \"lg\",\n },\n },\n xl: {\n spinner: {\n h: 12,\n w: 12,\n },\n label: {\n fontSize: \"xl\",\n },\n },\n};\n\nconst spinnerVariantStyles: Record<TypographyVariant, SpinnerSlotStyles> = {\n accent: {\n spinner: typographyVariantStyles.accent,\n },\n accentSubtle: {\n spinner: typographyVariantStyles.accentSubtle,\n },\n brand: {\n spinner: typographyVariantStyles.brand,\n },\n brandOnContrast: {\n spinner: typographyVariantStyles.brandOnContrast,\n },\n danger: {\n spinner: typographyVariantStyles.danger,\n },\n dangerOnContrast: {\n spinner: typographyVariantStyles.dangerOnContrast,\n },\n default: {\n spinner: typographyVariantStyles.default,\n },\n info: {\n spinner: typographyVariantStyles.info,\n },\n interactive: {\n spinner: typographyVariantStyles.interactive,\n },\n interactiveOnContrast: {\n spinner: typographyVariantStyles.interactiveOnContrast,\n },\n onContrast: {\n spinner: typographyVariantStyles.onContrast,\n },\n placeholder: {\n spinner: typographyVariantStyles.placeholder,\n },\n placeholderOnContrast: {\n spinner: typographyVariantStyles.placeholderOnContrast,\n },\n subtle: {\n spinner: typographyVariantStyles.subtle,\n },\n subtleOnContrast: {\n spinner: typographyVariantStyles.subtleOnContrast,\n },\n success: {\n spinner: typographyVariantStyles.success,\n },\n warning: {\n spinner: typographyVariantStyles.warning,\n },\n};\n\nexport const spinnerRecipe = defineSlotRecipe({\n slots: spinnerSlots,\n base: {\n root: {\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n },\n variants: {\n variant: spinnerVariantStyles,\n size: spinnerSizeStyles,\n fullScreen: {\n true: {\n root: {\n h: \"100%\",\n left: 0,\n top: 0,\n position: \"absolute\",\n w: \"100%\",\n zIndex: \"tooltipExtra\",\n },\n },\n false: {\n root: {\n h: \"max-content\",\n w: \"max-content\",\n },\n },\n },\n },\n defaultVariants: {\n fullScreen: false,\n size: \"md\",\n variant: \"brand\",\n },\n});\n","import React from \"react\";\nimport { Spinner as CSpinner } from \"@chakra-ui/react/spinner\";\nimport { VStack } from \"@chakra-ui/react/stack\";\nimport { SpinnerSize } from \"./spinner.types\";\nimport { Text, TextProps } from \"components/Text/text.component\";\nimport { TypographyVariant } from \"shared/types\";\nimport { useSlotRecipe } from \"@chakra-ui/react\";\nimport { spinnerRecipe } from \"./spinner.recipe\";\nimport { SemanticBackgroundColorToken } from \"theme/semanticTokens\";\n\nexport interface SpinnerProps {\n backdropColor?: SemanticBackgroundColorToken;\n fullScreen?: boolean;\n label?: string;\n labelProps?: Omit<TextProps, \"chilren\">;\n showLabel?: boolean;\n size?: SpinnerSize;\n variant?: TypographyVariant;\n}\n\nexport const Spinner = ({\n backdropColor = \"background.alpha.pressed\",\n fullScreen = false,\n label = \"Loading...\",\n labelProps,\n showLabel = false,\n size = \"md\",\n variant = \"accent\",\n}: SpinnerProps): React.JSX.Element => {\n const recipe = useSlotRecipe({ recipe: spinnerRecipe });\n const styles = recipe({ variant, size, fullScreen });\n\n return (\n <VStack\n className=\"Spinner\"\n data-testid=\"kibble-spinner\"\n css={styles.root}\n {...(fullScreen && { bg: backdropColor })}\n >\n <CSpinner css={styles.spinner} />\n {showLabel && (\n <Text\n className=\"Spinner__Label\"\n data-testid=\"kibble-spinner-label\"\n variant=\"subtle\"\n css={styles.label}\n {...labelProps}\n >\n {label}\n </Text>\n )}\n </VStack>\n );\n};\n"],"names":["spinnerSlots","spinnerSizeStyles","spinnerVariantStyles","typographyVariantStyles","spinnerRecipe","defineSlotRecipe","Spinner","backdropColor","fullScreen","label","labelProps","showLabel","size","variant","styles","useSlotRecipe","jsxs","VStack","jsx","CSpinner","Text"],"mappings":"6RAQMA,EAAe,CAAC,OAAQ,UAAW,OAAO,EAM1CC,EAA4D,CAChE,GAAI,CACF,QAAS,CACP,EAAG,EACH,EAAG,CACL,EACA,MAAO,CACL,SAAU,IAAA,CAEd,EACA,GAAI,CACF,QAAS,CACP,EAAG,EACH,EAAG,CACL,EACA,MAAO,CACL,SAAU,IAAA,CAEd,EACA,GAAI,CACF,QAAS,CACP,EAAG,EACH,EAAG,EACH,iBAAkB,CACpB,EACA,MAAO,CACL,SAAU,IAAA,CAEd,EACA,GAAI,CACF,QAAS,CACP,EAAG,EACH,EAAG,CACL,EACA,MAAO,CACL,SAAU,IAAA,CAEd,EACA,GAAI,CACF,QAAS,CACP,EAAG,GACH,EAAG,EACL,EACA,MAAO,CACL,SAAU,IAAA,CACZ,CAEJ,EAEMC,EAAqE,CACzE,OAAQ,CACN,QAASC,EAAAA,wBAAwB,MACnC,EACA,aAAc,CACZ,QAASA,EAAAA,wBAAwB,YACnC,EACA,MAAO,CACL,QAASA,EAAAA,wBAAwB,K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QX,EAAe,EAChC,CAAE,QAAAS,EAAS,KAAAD,EAAM,WAAAJ,EAAY,EAGjD,OAAAQ,EAAA,kBAAA,KAACC,EAAA,OAAA,CACC,UAAU,UACV,cAAY,iBACZ,IAAKH,EAAO,KACX,GAAIN,GAAc,CAAE,GAAID,CAAc,EAEvC,SAAA,CAACW,EAAAA,kBAAAA,IAAAC,EAAAA,QAAA,CAAS,IAAKL,EAAO,OAAS,CAAA,EAC9BH,GACCO,EAAA,kBAAA,IAACE,EAAA,YAAA,CACC,UAAU,iBACV,cAAY,uBACZ,QAAQ,SACR,IAAKN,EAAO,MACX,GAAGJ,EAEH,SAAAD,CAAA,CAAA,CACH,CAAA,CAEJ,CAEJ"}
1
+ {"version":3,"file":"spinner.component-DIyDNcWp.js","sources":["../../src/components/Spinner/spinner.recipe.ts","../../src/components/Spinner/spinner.component.tsx"],"sourcesContent":["import {\n defineSlotRecipe,\n SystemStyleObject,\n} from \"@chakra-ui/react/styled-system\";\nimport { SpinnerSize } from \"./spinner.types\";\nimport { TypographyVariant } from \"shared/types\";\nimport { typographyVariantStyles } from \"../../shared/records/typography\";\n\nconst spinnerSlots = [\"root\", \"spinner\", \"label\"] as const;\ntype SpinnerSlot = (typeof spinnerSlots)[number];\ntype SpinnerSlotStyles = {\n [key in SpinnerSlot]?: SystemStyleObject;\n};\n\nconst spinnerSizeStyles: Record<SpinnerSize, SpinnerSlotStyles> = {\n xs: {\n spinner: {\n h: 3,\n w: 3,\n },\n label: {\n fontSize: \"xs\",\n },\n },\n sm: {\n spinner: {\n h: 4,\n w: 4,\n },\n label: {\n fontSize: \"sm\",\n },\n },\n md: {\n spinner: {\n h: 6,\n w: 6,\n \"--spinner-size\": 6,\n },\n label: {\n fontSize: \"md\",\n },\n },\n lg: {\n spinner: {\n h: 8,\n w: 8,\n },\n label: {\n fontSize: \"lg\",\n },\n },\n xl: {\n spinner: {\n h: 12,\n w: 12,\n },\n label: {\n fontSize: \"xl\",\n },\n },\n};\n\nconst spinnerVariantStyles: Record<TypographyVariant, SpinnerSlotStyles> = {\n accent: {\n spinner: typographyVariantStyles.accent,\n },\n accentSubtle: {\n spinner: typographyVariantStyles.accentSubtle,\n },\n brand: {\n spinner: typographyVariantStyles.brand,\n },\n brandOnContrast: {\n spinner: typographyVariantStyles.brandOnContrast,\n },\n danger: {\n spinner: typographyVariantStyles.danger,\n },\n dangerOnContrast: {\n spinner: typographyVariantStyles.dangerOnContrast,\n },\n default: {\n spinner: typographyVariantStyles.default,\n },\n info: {\n spinner: typographyVariantStyles.info,\n },\n interactive: {\n spinner: typographyVariantStyles.interactive,\n },\n interactiveOnContrast: {\n spinner: typographyVariantStyles.interactiveOnContrast,\n },\n onContrast: {\n spinner: typographyVariantStyles.onContrast,\n },\n placeholder: {\n spinner: typographyVariantStyles.placeholder,\n },\n placeholderOnContrast: {\n spinner: typographyVariantStyles.placeholderOnContrast,\n },\n subtle: {\n spinner: typographyVariantStyles.subtle,\n },\n subtleOnContrast: {\n spinner: typographyVariantStyles.subtleOnContrast,\n },\n success: {\n spinner: typographyVariantStyles.success,\n },\n warning: {\n spinner: typographyVariantStyles.warning,\n },\n};\n\nexport const spinnerRecipe = defineSlotRecipe({\n slots: spinnerSlots,\n base: {\n root: {\n alignItems: \"center\",\n justifyContent: \"center\",\n },\n },\n variants: {\n variant: spinnerVariantStyles,\n size: spinnerSizeStyles,\n fullScreen: {\n true: {\n root: {\n h: \"100%\",\n left: 0,\n top: 0,\n position: \"absolute\",\n w: \"100%\",\n zIndex: \"tooltipExtra\",\n },\n },\n false: {\n root: {\n h: \"max-content\",\n w: \"max-content\",\n },\n },\n },\n },\n defaultVariants: {\n fullScreen: false,\n size: \"md\",\n variant: \"brand\",\n },\n});\n","import React from \"react\";\nimport { Spinner as CSpinner } from \"@chakra-ui/react/spinner\";\nimport { VStack } from \"@chakra-ui/react/stack\";\nimport { SpinnerSize } from \"./spinner.types\";\nimport { Text, TextProps } from \"components/Text/text.component\";\nimport { TypographyVariant } from \"shared/types\";\nimport { useSlotRecipe } from \"@chakra-ui/react\";\nimport { spinnerRecipe } from \"./spinner.recipe\";\nimport { SemanticBackgroundColorToken } from \"theme/semanticTokens\";\n\nexport interface SpinnerProps {\n backdropColor?: SemanticBackgroundColorToken;\n fullScreen?: boolean;\n label?: string;\n labelProps?: Omit<TextProps, \"chilren\">;\n showLabel?: boolean;\n size?: SpinnerSize;\n variant?: TypographyVariant;\n}\n\nexport const Spinner = ({\n backdropColor = \"background.alpha.pressed\",\n fullScreen = false,\n label = \"Loading...\",\n labelProps,\n showLabel = false,\n size = \"md\",\n variant = \"accent\",\n}: SpinnerProps): React.JSX.Element => {\n const recipe = useSlotRecipe({ recipe: spinnerRecipe });\n const styles = recipe({ variant, size, fullScreen });\n\n return (\n <VStack\n className=\"Spinner\"\n data-testid=\"kibble-spinner\"\n css={styles.root}\n {...(fullScreen && { bg: backdropColor })}\n >\n <CSpinner css={styles.spinner} />\n {showLabel && (\n <Text\n className=\"Spinner__Label\"\n data-testid=\"kibble-spinner-label\"\n variant=\"subtle\"\n css={styles.label}\n {...labelProps}\n >\n {label}\n </Text>\n )}\n </VStack>\n );\n};\n"],"names":["spinnerSlots","spinnerSizeStyles","spinnerVariantStyles","typographyVariantStyles","spinnerRecipe","defineSlotRecipe","Spinner","backdropColor","fullScreen","label","labelProps","showLabel","size","variant","styles","useSlotRecipe","jsxs","VStack","jsx","CSpinner","Text"],"mappings":"6RAQMA,EAAe,CAAC,OAAQ,UAAW,OAAO,EAM1CC,EAA4D,CAChE,GAAI,CACF,QAAS,CACP,EAAG,EACH,EAAG,CACL,EACA,MAAO,CACL,SAAU,IAAA,CAEd,EACA,GAAI,CACF,QAAS,CACP,EAAG,EACH,EAAG,CACL,EACA,MAAO,CACL,SAAU,IAAA,CAEd,EACA,GAAI,CACF,QAAS,CACP,EAAG,EACH,EAAG,EACH,iBAAkB,CACpB,EACA,MAAO,CACL,SAAU,IAAA,CAEd,EACA,GAAI,CACF,QAAS,CACP,EAAG,EACH,EA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CAEJ,EACA,gBAAiB,CACf,WAAY,GACZ,KAAM,KACN,QAAS,OAAA,CAEb,CAAC,ECpIYK,EAAU,CAAC,CACtB,cAAAC,EAAgB,2BAChB,WAAAC,EAAa,GACb,MAAAC,EAAQ,aACR,WAAAC,EACA,UAAAC,EAAY,GACZ,KAAAC,EAAO,KACP,QAAAC,EAAU,QACZ,IAAuC,CAErC,MAAMC,EADSC,EAAA,cAAc,CAAE,OAAQX,EAAe,EAChC,CAAE,QAAAS,EAAS,KAAAD,EAAM,WAAAJ,EAAY,EAGjD,OAAAQ,EAAA,kBAAA,KAACC,EAAA,OAAA,CACC,UAAU,UACV,cAAY,iBACZ,IAAKH,EAAO,KACX,GAAIN,GAAc,CAAE,GAAID,CAAc,EAEvC,SAAA,CAACW,EAAAA,kBAAAA,IAAAC,EAAAA,QAAA,CAAS,IAAKL,EAAO,OAAS,CAAA,EAC9BH,GACCO,EAAA,kBAAA,IAACE,EAAA,YAAA,CACC,UAAU,iBACV,cAAY,uBACZ,QAAQ,SACR,IAAKN,EAAO,MACX,GAAGJ,EAEH,SAAAD,CAAA,CAAA,CACH,CAAA,CAEJ,CAEJ"}
@@ -1,2 +1,2 @@
1
- "use strict";const c=require("./jsx-runtime-BjDatQAs.js"),p=require("./avatar.component-BsLD7swi.js"),m=({type:l="Client",...e})=>{const{name:o,tooltipProps:t={placement:"top",...e.tooltipProps},onClick:s}=e,n={variant:"outlineYellow",tooltipProps:{...t,label:t?.label||`${o} (Test Client)`}},r={iconName:"cellphone",tooltipProps:{...t,label:t?.label||`Text messages sent from ${o||"unknown number"}`}},i={Automated:{iconName:"robot",backgroundColor:"background.primary",hideBorder:!0,color:"text.contrast",size:"sm",showTooltip:!1,cursor:"default"},Client:{},Clinic:{variant:"outlineAccent",name:o||"Sys"},SMS:r,TestClient:n};return c.jsxRuntimeExports.jsx(p.Avatar,{className:"StyledAvatar","data-testid":`kibble-styled-avatar-${l}`,onClick:a=>{a.stopPropagation(),s&&s(a)},...e,...i[l]})},u=["Client","SMS","TestClient","Automated","Clinic"];exports.StyledAvatar=m;exports.styledAvatarTypes=u;
2
- //# sourceMappingURL=styledAvatar.types-D9gs5qgU.js.map
1
+ "use strict";const c=require("./jsx-runtime-BjDatQAs.js"),p=require("./avatar.component-Bx-G6wRN.js"),m=({type:l="Client",...e})=>{const{name:o,tooltipProps:t={placement:"top",...e.tooltipProps},onClick:s}=e,n={variant:"outlineYellow",tooltipProps:{...t,label:t?.label||`${o} (Test Client)`}},r={iconName:"cellphone",tooltipProps:{...t,label:t?.label||`Text messages sent from ${o||"unknown number"}`}},i={Automated:{iconName:"robot",backgroundColor:"background.primary",hideBorder:!0,color:"text.contrast",size:"sm",showTooltip:!1,cursor:"default"},Client:{},Clinic:{variant:"outlineAccent",name:o||"Sys"},SMS:r,TestClient:n};return c.jsxRuntimeExports.jsx(p.Avatar,{className:"StyledAvatar","data-testid":`kibble-styled-avatar-${l}`,onClick:a=>{a.stopPropagation(),s&&s(a)},...e,...i[l]})},u=["Client","SMS","TestClient","Automated","Clinic"];exports.StyledAvatar=m;exports.styledAvatarTypes=u;
2
+ //# sourceMappingURL=styledAvatar.types-BjuO516j.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"styledAvatar.types-D9gs5qgU.js","sources":["../../src/components/StyledAvatar/styledAvatar.component.tsx","../../src/components/StyledAvatar/styledAvatar.types.ts"],"sourcesContent":["import React from \"react\";\nimport { Avatar, AvatarProps } from \"components/Avatar/avatar.component\";\nimport { StyledAvatarType } from \"./styledAvatar.types\";\n\nexport interface StyledAvatarProps extends AvatarProps {\n type?: StyledAvatarType;\n}\n\nexport const StyledAvatar = ({\n type = \"Client\",\n ...rest\n}: StyledAvatarProps): React.JSX.Element => {\n const {\n name,\n tooltipProps = { placement: \"top\", ...rest.tooltipProps },\n onClick,\n } = rest;\n\n const testClientStyleProps: Partial<AvatarProps> = {\n variant: \"outlineYellow\",\n tooltipProps: {\n ...tooltipProps,\n label: tooltipProps?.label || `${name} (Test Client)`,\n },\n };\n\n const smsStyleProps: Partial<AvatarProps> = {\n iconName: \"cellphone\",\n tooltipProps: {\n ...tooltipProps,\n label:\n tooltipProps?.label ||\n `Text messages sent from ${name || \"unknown number\"}`,\n },\n };\n\n const automatedStyleProps: Partial<AvatarProps> = {\n iconName: \"robot\",\n backgroundColor: \"background.primary\",\n hideBorder: true,\n color: \"text.contrast\",\n size: \"sm\",\n showTooltip: false,\n cursor: \"default\",\n };\n\n const clinicStyleProps: Partial<AvatarProps> = {\n variant: \"outlineAccent\",\n name: name || \"Sys\",\n };\n\n const styleProps: Record<StyledAvatarType, Partial<AvatarProps>> = {\n Automated: automatedStyleProps,\n Client: {},\n Clinic: clinicStyleProps,\n SMS: smsStyleProps,\n TestClient: testClientStyleProps,\n };\n\n return (\n <Avatar\n className=\"StyledAvatar\"\n data-testid={`kibble-styled-avatar-${type}`}\n onClick={(e): void => {\n e.stopPropagation();\n if (onClick) {\n onClick(e);\n }\n }}\n {...rest}\n {...styleProps[type]}\n />\n );\n};\n","export const styledAvatarTypes = [\n \"Client\",\n \"SMS\",\n \"TestClient\",\n \"Automated\",\n \"Clinic\",\n] as const;\nexport type StyledAvatarType = (typeof styledAvatarTypes)[number];\n"],"names":["StyledAvatar","type","rest","name","tooltipProps","onClick","testClientStyleProps","smsStyleProps","styleProps","jsx","Avatar","e","styledAvatarTypes"],"mappings":"sGAQaA,EAAe,CAAC,CAC3B,KAAAC,EAAO,SACP,GAAGC,CACL,IAA4C,CACpC,KAAA,CACJ,KAAAC,EACA,aAAAC,EAAe,CAAE,UAAW,MAAO,GAAGF,EAAK,YAAa,EACxD,QAAAG,CAAA,EACEH,EAEEI,EAA6C,CACjD,QAAS,gBACT,aAAc,CACZ,GAAGF,EACH,MAAOA,GAAc,OAAS,GAAGD,CAAI,gBAAA,CAEzC,EAEMI,EAAsC,CAC1C,SAAU,YACV,aAAc,CACZ,GAAGH,EACH,MACEA,GAAc,OACd,2BAA2BD,GAAQ,gBAAgB,EAAA,CAEzD,EAiBMK,EAA6D,CACjE,UAhBgD,CAChD,SAAU,QACV,gBAAiB,qBACjB,WAAY,GACZ,MAAO,gBACP,KAAM,KACN,YAAa,GACb,OAAQ,SACV,EASE,OAAQ,CAAC,EACT,OAR6C,CAC7C,QAAS,gBACT,KAAML,GAAQ,KAChB,EAME,IAAKI,EACL,WAAYD,CACd,EAGE,OAAAG,EAAA,kBAAA,IAACC,EAAA,OAAA,CACC,UAAU,eACV,cAAa,wBAAwBT,CAAI,GACzC,QAAUU,GAAY,CACpBA,EAAE,gBAAgB,EACdN,GACFA,EAAQM,CAAC,CAEb,EACC,GAAGT,EACH,GAAGM,EAAWP,CAAI,CAAA,CACrB,CAEJ,ECzEaW,EAAoB,CAC/B,SACA,MACA,aACA,YACA,QACF"}
1
+ {"version":3,"file":"styledAvatar.types-BjuO516j.js","sources":["../../src/components/StyledAvatar/styledAvatar.component.tsx","../../src/components/StyledAvatar/styledAvatar.types.ts"],"sourcesContent":["import React from \"react\";\nimport { Avatar, AvatarProps } from \"components/Avatar/avatar.component\";\nimport { StyledAvatarType } from \"./styledAvatar.types\";\n\nexport interface StyledAvatarProps extends AvatarProps {\n type?: StyledAvatarType;\n}\n\nexport const StyledAvatar = ({\n type = \"Client\",\n ...rest\n}: StyledAvatarProps): React.JSX.Element => {\n const {\n name,\n tooltipProps = { placement: \"top\", ...rest.tooltipProps },\n onClick,\n } = rest;\n\n const testClientStyleProps: Partial<AvatarProps> = {\n variant: \"outlineYellow\",\n tooltipProps: {\n ...tooltipProps,\n label: tooltipProps?.label || `${name} (Test Client)`,\n },\n };\n\n const smsStyleProps: Partial<AvatarProps> = {\n iconName: \"cellphone\",\n tooltipProps: {\n ...tooltipProps,\n label:\n tooltipProps?.label ||\n `Text messages sent from ${name || \"unknown number\"}`,\n },\n };\n\n const automatedStyleProps: Partial<AvatarProps> = {\n iconName: \"robot\",\n backgroundColor: \"background.primary\",\n hideBorder: true,\n color: \"text.contrast\",\n size: \"sm\",\n showTooltip: false,\n cursor: \"default\",\n };\n\n const clinicStyleProps: Partial<AvatarProps> = {\n variant: \"outlineAccent\",\n name: name || \"Sys\",\n };\n\n const styleProps: Record<StyledAvatarType, Partial<AvatarProps>> = {\n Automated: automatedStyleProps,\n Client: {},\n Clinic: clinicStyleProps,\n SMS: smsStyleProps,\n TestClient: testClientStyleProps,\n };\n\n return (\n <Avatar\n className=\"StyledAvatar\"\n data-testid={`kibble-styled-avatar-${type}`}\n onClick={(e): void => {\n e.stopPropagation();\n if (onClick) {\n onClick(e);\n }\n }}\n {...rest}\n {...styleProps[type]}\n />\n );\n};\n","export const styledAvatarTypes = [\n \"Client\",\n \"SMS\",\n \"TestClient\",\n \"Automated\",\n \"Clinic\",\n] as const;\nexport type StyledAvatarType = (typeof styledAvatarTypes)[number];\n"],"names":["StyledAvatar","type","rest","name","tooltipProps","onClick","testClientStyleProps","smsStyleProps","styleProps","jsx","Avatar","e","styledAvatarTypes"],"mappings":"sGAQaA,EAAe,CAAC,CAC3B,KAAAC,EAAO,SACP,GAAGC,CACL,IAA4C,CACpC,KAAA,CACJ,KAAAC,EACA,aAAAC,EAAe,CAAE,UAAW,MAAO,GAAGF,EAAK,YAAa,EACxD,QAAAG,CAAA,EACEH,EAEEI,EAA6C,CACjD,QAAS,gBACT,aAAc,CACZ,GAAGF,EACH,MAAOA,GAAc,OAAS,GAAGD,CAAI,gBAAA,CAEzC,EAEMI,EAAsC,CAC1C,SAAU,YACV,aAAc,CACZ,GAAGH,EACH,MACEA,GAAc,OACd,2BAA2BD,GAAQ,gBAAgB,EAAA,CAEzD,EAiBMK,EAA6D,CACjE,UAhBgD,CAChD,SAAU,QACV,gBAAiB,qBACjB,WAAY,GACZ,MAAO,gBACP,KAAM,KACN,YAAa,GACb,OAAQ,SACV,EASE,OAAQ,CAAC,EACT,OAR6C,CAC7C,QAAS,gBACT,KAAML,GAAQ,KAChB,EAME,IAAKI,EACL,WAAYD,CACd,EAGE,OAAAG,EAAA,kBAAA,IAACC,EAAA,OAAA,CACC,UAAU,eACV,cAAa,wBAAwBT,CAAI,GACzC,QAAUU,GAAY,CACpBA,EAAE,gBAAgB,EACdN,GACFA,EAAQM,CAAC,CAEb,EACC,GAAGT,EACH,GAAGM,EAAWP,CAAI,CAAA,CACrB,CAEJ,ECzEaW,EAAoB,CAC/B,SACA,MACA,aACA,YACA,QACF"}
@@ -1,5 +1,5 @@
1
1
  import { j as c } from "./jsx-runtime-C5mzlN2N.js";
2
- import { A as p } from "./avatar.component-BvnohMit.js";
2
+ import { A as p } from "./avatar.component-DhnsK_Su.js";
3
3
  const y = ({
4
4
  type: l = "Client",
5
5
  ...o
@@ -61,4 +61,4 @@ export {
61
61
  y as S,
62
62
  C as s
63
63
  };
64
- //# sourceMappingURL=styledAvatar.types-2wZJjpPn.js.map
64
+ //# sourceMappingURL=styledAvatar.types-CbfoVHIB.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"styledAvatar.types-2wZJjpPn.js","sources":["../../src/components/StyledAvatar/styledAvatar.component.tsx","../../src/components/StyledAvatar/styledAvatar.types.ts"],"sourcesContent":["import React from \"react\";\nimport { Avatar, AvatarProps } from \"components/Avatar/avatar.component\";\nimport { StyledAvatarType } from \"./styledAvatar.types\";\n\nexport interface StyledAvatarProps extends AvatarProps {\n type?: StyledAvatarType;\n}\n\nexport const StyledAvatar = ({\n type = \"Client\",\n ...rest\n}: StyledAvatarProps): React.JSX.Element => {\n const {\n name,\n tooltipProps = { placement: \"top\", ...rest.tooltipProps },\n onClick,\n } = rest;\n\n const testClientStyleProps: Partial<AvatarProps> = {\n variant: \"outlineYellow\",\n tooltipProps: {\n ...tooltipProps,\n label: tooltipProps?.label || `${name} (Test Client)`,\n },\n };\n\n const smsStyleProps: Partial<AvatarProps> = {\n iconName: \"cellphone\",\n tooltipProps: {\n ...tooltipProps,\n label:\n tooltipProps?.label ||\n `Text messages sent from ${name || \"unknown number\"}`,\n },\n };\n\n const automatedStyleProps: Partial<AvatarProps> = {\n iconName: \"robot\",\n backgroundColor: \"background.primary\",\n hideBorder: true,\n color: \"text.contrast\",\n size: \"sm\",\n showTooltip: false,\n cursor: \"default\",\n };\n\n const clinicStyleProps: Partial<AvatarProps> = {\n variant: \"outlineAccent\",\n name: name || \"Sys\",\n };\n\n const styleProps: Record<StyledAvatarType, Partial<AvatarProps>> = {\n Automated: automatedStyleProps,\n Client: {},\n Clinic: clinicStyleProps,\n SMS: smsStyleProps,\n TestClient: testClientStyleProps,\n };\n\n return (\n <Avatar\n className=\"StyledAvatar\"\n data-testid={`kibble-styled-avatar-${type}`}\n onClick={(e): void => {\n e.stopPropagation();\n if (onClick) {\n onClick(e);\n }\n }}\n {...rest}\n {...styleProps[type]}\n />\n );\n};\n","export const styledAvatarTypes = [\n \"Client\",\n \"SMS\",\n \"TestClient\",\n \"Automated\",\n \"Clinic\",\n] as const;\nexport type StyledAvatarType = (typeof styledAvatarTypes)[number];\n"],"names":["StyledAvatar","type","rest","name","tooltipProps","onClick","testClientStyleProps","smsStyleProps","styleProps","jsx","Avatar","e","styledAvatarTypes"],"mappings":";;AAQO,MAAMA,IAAe,CAAC;AAAA,EAC3B,MAAAC,IAAO;AAAA,EACP,GAAGC;AACL,MAA4C;AACpC,QAAA;AAAA,IACJ,MAAAC;AAAA,IACA,cAAAC,IAAe,EAAE,WAAW,OAAO,GAAGF,EAAK,aAAa;AAAA,IACxD,SAAAG;AAAA,EAAA,IACEH,GAEEI,IAA6C;AAAA,IACjD,SAAS;AAAA,IACT,cAAc;AAAA,MACZ,GAAGF;AAAA,MACH,OAAOA,GAAc,SAAS,GAAGD,CAAI;AAAA,IAAA;AAAA,EAEzC,GAEMI,IAAsC;AAAA,IAC1C,UAAU;AAAA,IACV,cAAc;AAAA,MACZ,GAAGH;AAAA,MACH,OACEA,GAAc,SACd,2BAA2BD,KAAQ,gBAAgB;AAAA,IAAA;AAAA,EAEzD,GAiBMK,IAA6D;AAAA,IACjE,WAhBgD;AAAA,MAChD,UAAU;AAAA,MACV,iBAAiB;AAAA,MACjB,YAAY;AAAA,MACZ,OAAO;AAAA,MACP,MAAM;AAAA,MACN,aAAa;AAAA,MACb,QAAQ;AAAA,IACV;AAAA,IASE,QAAQ,CAAC;AAAA,IACT,QAR6C;AAAA,MAC7C,SAAS;AAAA,MACT,MAAML,KAAQ;AAAA,IAChB;AAAA,IAME,KAAKI;AAAA,IACL,YAAYD;AAAA,EACd;AAGE,SAAAG,gBAAAA,EAAA;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,WAAU;AAAA,MACV,eAAa,wBAAwBT,CAAI;AAAA,MACzC,SAAS,CAACU,MAAY;AACpB,QAAAA,EAAE,gBAAgB,GACdN,KACFA,EAAQM,CAAC;AAAA,MAEb;AAAA,MACC,GAAGT;AAAA,MACH,GAAGM,EAAWP,CAAI;AAAA,IAAA;AAAA,EACrB;AAEJ,GCzEaW,IAAoB;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;"}
1
+ {"version":3,"file":"styledAvatar.types-CbfoVHIB.js","sources":["../../src/components/StyledAvatar/styledAvatar.component.tsx","../../src/components/StyledAvatar/styledAvatar.types.ts"],"sourcesContent":["import React from \"react\";\nimport { Avatar, AvatarProps } from \"components/Avatar/avatar.component\";\nimport { StyledAvatarType } from \"./styledAvatar.types\";\n\nexport interface StyledAvatarProps extends AvatarProps {\n type?: StyledAvatarType;\n}\n\nexport const StyledAvatar = ({\n type = \"Client\",\n ...rest\n}: StyledAvatarProps): React.JSX.Element => {\n const {\n name,\n tooltipProps = { placement: \"top\", ...rest.tooltipProps },\n onClick,\n } = rest;\n\n const testClientStyleProps: Partial<AvatarProps> = {\n variant: \"outlineYellow\",\n tooltipProps: {\n ...tooltipProps,\n label: tooltipProps?.label || `${name} (Test Client)`,\n },\n };\n\n const smsStyleProps: Partial<AvatarProps> = {\n iconName: \"cellphone\",\n tooltipProps: {\n ...tooltipProps,\n label:\n tooltipProps?.label ||\n `Text messages sent from ${name || \"unknown number\"}`,\n },\n };\n\n const automatedStyleProps: Partial<AvatarProps> = {\n iconName: \"robot\",\n backgroundColor: \"background.primary\",\n hideBorder: true,\n color: \"text.contrast\",\n size: \"sm\",\n showTooltip: false,\n cursor: \"default\",\n };\n\n const clinicStyleProps: Partial<AvatarProps> = {\n variant: \"outlineAccent\",\n name: name || \"Sys\",\n };\n\n const styleProps: Record<StyledAvatarType, Partial<AvatarProps>> = {\n Automated: automatedStyleProps,\n Client: {},\n Clinic: clinicStyleProps,\n SMS: smsStyleProps,\n TestClient: testClientStyleProps,\n };\n\n return (\n <Avatar\n className=\"StyledAvatar\"\n data-testid={`kibble-styled-avatar-${type}`}\n onClick={(e): void => {\n e.stopPropagation();\n if (onClick) {\n onClick(e);\n }\n }}\n {...rest}\n {...styleProps[type]}\n />\n );\n};\n","export const styledAvatarTypes = [\n \"Client\",\n \"SMS\",\n \"TestClient\",\n \"Automated\",\n \"Clinic\",\n] as const;\nexport type StyledAvatarType = (typeof styledAvatarTypes)[number];\n"],"names":["StyledAvatar","type","rest","name","tooltipProps","onClick","testClientStyleProps","smsStyleProps","styleProps","jsx","Avatar","e","styledAvatarTypes"],"mappings":";;AAQO,MAAMA,IAAe,CAAC;AAAA,EAC3B,MAAAC,IAAO;AAAA,EACP,GAAGC;AACL,MAA4C;AACpC,QAAA;AAAA,IACJ,MAAAC;AAAA,IACA,cAAAC,IAAe,EAAE,WAAW,OAAO,GAAGF,EAAK,aAAa;AAAA,IACxD,SAAAG;AAAA,EAAA,IACEH,GAEEI,IAA6C;AAAA,IACjD,SAAS;AAAA,IACT,cAAc;AAAA,MACZ,GAAGF;AAAA,MACH,OAAOA,GAAc,SAAS,GAAGD,CAAI;AAAA,IAAA;AAAA,EAEzC,GAEMI,IAAsC;AAAA,IAC1C,UAAU;AAAA,IACV,cAAc;AAAA,MACZ,GAAGH;AAAA,MACH,OACEA,GAAc,SACd,2BAA2BD,KAAQ,gBAAgB;AAAA,IAAA;AAAA,EAEzD,GAiBMK,IAA6D;AAAA,IACjE,WAhBgD;AAAA,MAChD,UAAU;AAAA,MACV,iBAAiB;AAAA,MACjB,YAAY;AAAA,MACZ,OAAO;AAAA,MACP,MAAM;AAAA,MACN,aAAa;AAAA,MACb,QAAQ;AAAA,IACV;AAAA,IASE,QAAQ,CAAC;AAAA,IACT,QAR6C;AAAA,MAC7C,SAAS;AAAA,MACT,MAAML,KAAQ;AAAA,IAChB;AAAA,IAME,KAAKI;AAAA,IACL,YAAYD;AAAA,EACd;AAGE,SAAAG,gBAAAA,EAAA;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,WAAU;AAAA,MACV,eAAa,wBAAwBT,CAAI;AAAA,MACzC,SAAS,CAACU,MAAY;AACpB,QAAAA,EAAE,gBAAgB,GACdN,KACFA,EAAQM,CAAC;AAAA,MAEb;AAAA,MACC,GAAGT;AAAA,MACH,GAAGM,EAAWP,CAAI;AAAA,IAAA;AAAA,EACrB;AAEJ,GCzEaW,IAAoB;AAAA,EAC/B;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACF;"}
@@ -1,5 +1,5 @@
1
1
  import { j as d } from "./jsx-runtime-C5mzlN2N.js";
2
- import { b as x } from "./config-DlTdf-Yt.js";
2
+ import { b as x } from "./config-B1FINd7s.js";
3
3
  import { u as c } from "./use-recipe-d63ABaZ3.js";
4
4
  import { B as h } from "./box-Ck9I7FYv.js";
5
5
  const m = {
@@ -64,4 +64,4 @@ export {
64
64
  g as S,
65
65
  f as s
66
66
  };
67
- //# sourceMappingURL=swatch.types-DbgA3RWc.js.map
67
+ //# sourceMappingURL=swatch.types-B8OSJZ-a.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"swatch.types-DbgA3RWc.js","sources":["../../src/components/Swatch/swatch.recipe.ts","../../src/components/Swatch/swatch.component.tsx","../../src/components/Swatch/swatch.types.ts"],"sourcesContent":["import {\n defineRecipe,\n SystemStyleObject,\n} from \"@chakra-ui/react/styled-system\";\nimport { SwatchSize } from \"./swatch.types\";\n\nconst swatchSizeStyles: Record<SwatchSize, SystemStyleObject> = {\n xs: {\n borderRadius: \"xs\",\n height: \"14px\",\n width: \"14px\",\n },\n sm: {\n borderRadius: \"3px\",\n height: \"16px\",\n width: \"16px\",\n },\n md: {\n borderRadius: \"4px\",\n height: \"20px\",\n width: \"20px\",\n },\n lg: {\n borderRadius: \"5px\",\n height: \"24px\",\n width: \"24px\",\n },\n xl: {\n borderRadius: \"sm\",\n height: \"32px\",\n width: \"32px\",\n },\n};\n\nexport const swatchRecipe = defineRecipe({\n base: {\n display: \"inline-block\",\n border: \"1px\",\n },\n variants: {\n size: swatchSizeStyles,\n },\n defaultVariants: {\n size: \"md\",\n },\n});\n","import React from \"react\";\nimport { Box, BoxProps } from \"@chakra-ui/react/box\";\nimport { SwatchSize } from \"./swatch.types\";\nimport { useRecipe } from \"@chakra-ui/react/styled-system\";\nimport { swatchRecipe } from \"./swatch.recipe\";\n\nexport interface BaseSwatchProps {\n size?: SwatchSize;\n}\n\nexport type SwatchProps = BaseSwatchProps & Omit<BoxProps, \"children\">;\n\nexport const Swatch = ({\n size = \"md\",\n color,\n backgroundColor,\n bgColor,\n borderColor,\n ...rest\n}: SwatchProps): React.JSX.Element => {\n const recipe = useRecipe({ recipe: swatchRecipe });\n const styles = recipe({ size });\n const _swatchColor = bgColor || backgroundColor || color || \"transparent\";\n\n return (\n <Box\n className=\"Swatch\"\n data-testid=\"kibble-swatch\"\n css={styles}\n bg={_swatchColor}\n borderColor={borderColor || _swatchColor}\n {...rest}\n />\n );\n};\n","export const swatchSizes = [\"xs\", \"sm\", \"md\", \"lg\", \"xl\"] as const;\nexport type SwatchSize = (typeof swatchSizes)[number];\n"],"names":["swatchSizeStyles","swatchRecipe","defineRecipe","Swatch","size","color","backgroundColor","bgColor","borderColor","rest","styles","useRecipe","_swatchColor","jsx","Box","swatchSizes"],"mappings":";;;;AAMA,MAAMA,IAA0D;AAAA,EAC9D,IAAI;AAAA,IACF,cAAc;AAAA,IACd,QAAQ;AAAA,IACR,OAAO;AAAA,EACT;AAAA,EACA,IAAI;AAAA,IACF,cAAc;AAAA,IACd,QAAQ;AAAA,IACR,OAAO;AAAA,EACT;AAAA,EACA,IAAI;AAAA,IACF,cAAc;AAAA,IACd,QAAQ;AAAA,IACR,OAAO;AAAA,EACT;AAAA,EACA,IAAI;AAAA,IACF,cAAc;AAAA,IACd,QAAQ;AAAA,IACR,OAAO;AAAA,EACT;AAAA,EACA,IAAI;AAAA,IACF,cAAc;AAAA,IACd,QAAQ;AAAA,IACR,OAAO;AAAA,EAAA;AAEX,GAEaC,IAAeC,EAAa;AAAA,EACvC,MAAM;AAAA,IACJ,SAAS;AAAA,IACT,QAAQ;AAAA,EACV;AAAA,EACA,UAAU;AAAA,IACR,MAAMF;AAAA,EACR;AAAA,EACA,iBAAiB;AAAA,IACf,MAAM;AAAA,EAAA;AAEV,CAAC,GCjCYG,IAAS,CAAC;AAAA,EACrB,MAAAC,IAAO;AAAA,EACP,OAAAC;AAAA,EACA,iBAAAC;AAAA,EACA,SAAAC;AAAA,EACA,aAAAC;AAAA,EACA,GAAGC;AACL,MAAsC;AAEpC,QAAMC,IADSC,EAAU,EAAE,QAAQV,GAAc,EAC3B,EAAE,MAAAG,GAAM,GACxBQ,IAAeL,KAAWD,KAAmBD,KAAS;AAG1D,SAAAQ,gBAAAA,EAAA;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,WAAU;AAAA,MACV,eAAY;AAAA,MACZ,KAAKJ;AAAA,MACL,IAAIE;AAAA,MACJ,aAAaJ,KAAeI;AAAA,MAC3B,GAAGH;AAAA,IAAA;AAAA,EACN;AAEJ,GClCaM,IAAc,CAAC,MAAM,MAAM,MAAM,MAAM,IAAI;"}
1
+ {"version":3,"file":"swatch.types-B8OSJZ-a.js","sources":["../../src/components/Swatch/swatch.recipe.ts","../../src/components/Swatch/swatch.component.tsx","../../src/components/Swatch/swatch.types.ts"],"sourcesContent":["import {\n defineRecipe,\n SystemStyleObject,\n} from \"@chakra-ui/react/styled-system\";\nimport { SwatchSize } from \"./swatch.types\";\n\nconst swatchSizeStyles: Record<SwatchSize, SystemStyleObject> = {\n xs: {\n borderRadius: \"xs\",\n height: \"14px\",\n width: \"14px\",\n },\n sm: {\n borderRadius: \"3px\",\n height: \"16px\",\n width: \"16px\",\n },\n md: {\n borderRadius: \"4px\",\n height: \"20px\",\n width: \"20px\",\n },\n lg: {\n borderRadius: \"5px\",\n height: \"24px\",\n width: \"24px\",\n },\n xl: {\n borderRadius: \"sm\",\n height: \"32px\",\n width: \"32px\",\n },\n};\n\nexport const swatchRecipe = defineRecipe({\n base: {\n display: \"inline-block\",\n border: \"1px\",\n },\n variants: {\n size: swatchSizeStyles,\n },\n defaultVariants: {\n size: \"md\",\n },\n});\n","import React from \"react\";\nimport { Box, BoxProps } from \"@chakra-ui/react/box\";\nimport { SwatchSize } from \"./swatch.types\";\nimport { useRecipe } from \"@chakra-ui/react/styled-system\";\nimport { swatchRecipe } from \"./swatch.recipe\";\n\nexport interface BaseSwatchProps {\n size?: SwatchSize;\n}\n\nexport type SwatchProps = BaseSwatchProps & Omit<BoxProps, \"children\">;\n\nexport const Swatch = ({\n size = \"md\",\n color,\n backgroundColor,\n bgColor,\n borderColor,\n ...rest\n}: SwatchProps): React.JSX.Element => {\n const recipe = useRecipe({ recipe: swatchRecipe });\n const styles = recipe({ size });\n const _swatchColor = bgColor || backgroundColor || color || \"transparent\";\n\n return (\n <Box\n className=\"Swatch\"\n data-testid=\"kibble-swatch\"\n css={styles}\n bg={_swatchColor}\n borderColor={borderColor || _swatchColor}\n {...rest}\n />\n );\n};\n","export const swatchSizes = [\"xs\", \"sm\", \"md\", \"lg\", \"xl\"] as const;\nexport type SwatchSize = (typeof swatchSizes)[number];\n"],"names":["swatchSizeStyles","swatchRecipe","defineRecipe","Swatch","size","color","backgroundColor","bgColor","borderColor","rest","styles","useRecipe","_swatchColor","jsx","Box","swatchSizes"],"mappings":";;;;AAMA,MAAMA,IAA0D;AAAA,EAC9D,IAAI;AAAA,IACF,cAAc;AAAA,IACd,QAAQ;AAAA,IACR,OAAO;AAAA,EACT;AAAA,EACA,IAAI;AAAA,IACF,cAAc;AAAA,IACd,QAAQ;AAAA,IACR,OAAO;AAAA,EACT;AAAA,EACA,IAAI;AAAA,IACF,cAAc;AAAA,IACd,QAAQ;AAAA,IACR,OAAO;AAAA,EACT;AAAA,EACA,IAAI;AAAA,IACF,cAAc;AAAA,IACd,QAAQ;AAAA,IACR,OAAO;AAAA,EACT;AAAA,EACA,IAAI;AAAA,IACF,cAAc;AAAA,IACd,QAAQ;AAAA,IACR,OAAO;AAAA,EAAA;AAEX,GAEaC,IAAeC,EAAa;AAAA,EACvC,MAAM;AAAA,IACJ,SAAS;AAAA,IACT,QAAQ;AAAA,EACV;AAAA,EACA,UAAU;AAAA,IACR,MAAMF;AAAA,EACR;AAAA,EACA,iBAAiB;AAAA,IACf,MAAM;AAAA,EAAA;AAEV,CAAC,GCjCYG,IAAS,CAAC;AAAA,EACrB,MAAAC,IAAO;AAAA,EACP,OAAAC;AAAA,EACA,iBAAAC;AAAA,EACA,SAAAC;AAAA,EACA,aAAAC;AAAA,EACA,GAAGC;AACL,MAAsC;AAEpC,QAAMC,IADSC,EAAU,EAAE,QAAQV,GAAc,EAC3B,EAAE,MAAAG,GAAM,GACxBQ,IAAeL,KAAWD,KAAmBD,KAAS;AAG1D,SAAAQ,gBAAAA,EAAA;AAAA,IAACC;AAAA,IAAA;AAAA,MACC,WAAU;AAAA,MACV,eAAY;AAAA,MACZ,KAAKJ;AAAA,MACL,IAAIE;AAAA,MACJ,aAAaJ,KAAeI;AAAA,MAC3B,GAAGH;AAAA,IAAA;AAAA,EACN;AAEJ,GClCaM,IAAc,CAAC,MAAM,MAAM,MAAM,MAAM,IAAI;"}
@@ -0,0 +1,2 @@
1
+ "use strict";const i=require("./jsx-runtime-BjDatQAs.js"),c=require("react"),y=require("./withFormControl-BI8pqhZl.js"),w=require("./attr-BMs6szZx.js"),E=require("./create-slot-recipe-context-IwVIgtBt.js"),m=require("./factory-D6tdBUPG.js"),n=require("./portal-TWtD47zg.js"),f=require("./use-field-context-xBX4EpFz.js"),l=require("./index-BlGAWSIX.js"),x=require("./index-5cRW642o.js"),q=t=>t&&t.__esModule?t:{default:t},N=q(c),[R,u]=n.createContext({name:"SwitchContext",hookName:"useSwitchContext",providerName:"<SwitchProvider />"}),S=c.forwardRef((t,e)=>{const r=u(),s=l.mergeProps(r.getControlProps(),t);return i.jsxRuntimeExports.jsx(n.ark.span,{...s,ref:e})});S.displayName="SwitchControl";const j=c.forwardRef((t,e)=>{const r=u(),s=l.mergeProps(r.getHiddenInputProps(),t),o=f.useFieldContext();return i.jsxRuntimeExports.jsx(n.ark.input,{"aria-describedby":o?.ariaDescribedby,...s,ref:e})});j.displayName="SwitchHiddenInput";const b=c.forwardRef((t,e)=>{const r=u(),s=l.mergeProps(r.getLabelProps(),t);return i.jsxRuntimeExports.jsx(n.ark.span,{...s,ref:e})});b.displayName="SwitchLabel";const I=t=>{const e=c.useId(),{getRootNode:r}=n.useEnvironmentContext(),{dir:s}=n.useLocaleContext(),o=f.useFieldContext(),a={id:e,ids:{label:o?.ids.label,hiddenInput:o?.ids.control},dir:s,disabled:o?.disabled,readOnly:o?.readOnly,invalid:o?.invalid,required:o?.required,getRootNode:r,...t},d=n.useMachine(x.machine,a);return x.connect(d,n.normalizeProps)},C=c.forwardRef((t,e)=>{const[r,s]=n.createSplitProps()(t,["checked","defaultChecked","disabled","form","id","ids","invalid","label","name","onCheckedChange","readOnly","required","value"]),o=I(r),a=l.mergeProps(o.getRootProps(),s);return i.jsxRuntimeExports.jsx(R,{value:o,children:i.jsxRuntimeExports.jsx(n.ark.label,{...a,ref:e})})});C.displayName="SwitchRoot";const P=c.forwardRef((t,e)=>{const[{value:r},s]=n.createSplitProps()(t,["value"]),o=l.mergeProps(r.getRootProps(),s);return i.jsxRuntimeExports.jsx(R,{value:r,children:i.jsxRuntimeExports.jsx(n.ark.label,{...o,ref:e})})});P.displayName="SwitchRootProvider";const k=c.forwardRef((t,e)=>{const r=u(),s=l.mergeProps(r.getThumbProps(),t);return i.jsxRuntimeExports.jsx(n.ark.span,{...s,ref:e})});k.displayName="SwitchThumb";const{withProvider:g,withContext:p,useStyles:_}=E.createSlotRecipeContext({key:"switch"});g(P,"root",{forwardAsChild:!0});const A=g(C,"root",{forwardAsChild:!0}),$=p(b,"label",{forwardAsChild:!0}),F=p(k,"thumb",{forwardAsChild:!0}),L=p(S,"control",{forwardAsChild:!0,defaultProps:{children:i.jsxRuntimeExports.jsx(F,{})}});c.forwardRef(function(e,r){const s=u(),o=_(),{fallback:a,children:d,...h}=e;return i.jsxRuntimeExports.jsx(m.chakra.span,{ref:r,"data-checked":w.dataAttr(s.checked),...h,css:[o.indicator,e.css],children:s.checked?d:a})});c.forwardRef(function(e,r){const s=u(),{fallback:o,children:a,...d}=e;return i.jsxRuntimeExports.jsx(m.chakra.span,{ref:r,"data-checked":w.dataAttr(s.checked),...d,children:s.checked?a:o})});const T=j,H=y.withFormControl(({children:t,indeterminate:e=!1,onContrast:r,label:s,size:o="md",switchRef:a,...d})=>{const h=c.useMemo(()=>e?r?"indeterminateOnContrast":"indeterminate":r?"onContrast":"default",[e,r]);return i.jsxRuntimeExports.jsxs(A,{className:"Switch","data-testid":"kibble-switch",ref:a,size:o,variant:h,...d,children:[i.jsxRuntimeExports.jsx(T,{className:"Switch_Input","data-testid":"kibble-switch-input"}),i.jsxRuntimeExports.jsx(L,{className:"Switch_Control","data-testid":"kibble-switch-control"}),!!t&&i.jsxRuntimeExports.jsx($,{children:t})]})}),v=N.default.forwardRef((t,e)=>i.jsxRuntimeExports.jsx(H,{switchRef:e,...t}));v.displayName="Switch";exports.WrappedSwitch=v;
2
+ //# sourceMappingURL=switch.component-CPhSaMqG.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"switch.component-eY_h1Ybs.js","sources":["../../node_modules/@ark-ui/react/dist/components/switch/use-switch-context.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-control.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-hidden-input.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-label.js","../../node_modules/@ark-ui/react/dist/components/switch/use-switch.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-root.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-root-provider.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-thumb.js","../../node_modules/@chakra-ui/react/dist/esm/components/switch/switch.js","../../src/components/Switch/switch.component.tsx"],"sourcesContent":["'use client';\nimport { createContext } from '../../utils/create-context.js';\n\nconst [SwitchProvider, useSwitchContext] = createContext({\n name: \"SwitchContext\",\n hookName: \"useSwitchContext\",\n providerName: \"<SwitchProvider />\"\n});\n\nexport { SwitchProvider, useSwitchContext };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchControl = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getControlProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nSwitchControl.displayName = \"SwitchControl\";\n\nexport { SwitchControl };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from '../field/use-field-context.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchHiddenInput = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getHiddenInputProps(), props);\n const field = useFieldContext();\n return /* @__PURE__ */ jsx(ark.input, { \"aria-describedby\": field?.ariaDescribedby, ...mergedProps, ref });\n});\nSwitchHiddenInput.displayName = \"SwitchHiddenInput\";\n\nexport { SwitchHiddenInput };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchLabel = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getLabelProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nSwitchLabel.displayName = \"SwitchLabel\";\n\nexport { SwitchLabel };\n","'use client';\nimport { useMachine, normalizeProps } from '@zag-js/react';\nimport * as zagSwitch from '@zag-js/switch';\nimport { useId } from 'react';\nimport { useEnvironmentContext } from '../../providers/environment/use-environment-context.js';\nimport { useLocaleContext } from '../../providers/locale/use-locale-context.js';\nimport { useFieldContext } from '../field/use-field-context.js';\n\nconst useSwitch = (props) => {\n const id = useId();\n const { getRootNode } = useEnvironmentContext();\n const { dir } = useLocaleContext();\n const field = useFieldContext();\n const machineProps = {\n id,\n ids: {\n label: field?.ids.label,\n hiddenInput: field?.ids.control\n },\n dir,\n disabled: field?.disabled,\n readOnly: field?.readOnly,\n invalid: field?.invalid,\n required: field?.required,\n getRootNode,\n ...props\n };\n const service = useMachine(zagSwitch.machine, machineProps);\n return zagSwitch.connect(service, normalizeProps);\n};\n\nexport { useSwitch };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { createSplitProps } from '../../utils/create-split-props.js';\nimport { ark } from '../factory.js';\nimport { useSwitch } from './use-switch.js';\nimport { SwitchProvider } from './use-switch-context.js';\n\nconst SwitchRoot = forwardRef((props, ref) => {\n const [switchProps, localProps] = createSplitProps()(props, [\n \"checked\",\n \"defaultChecked\",\n \"disabled\",\n \"form\",\n \"id\",\n \"ids\",\n \"invalid\",\n \"label\",\n \"name\",\n \"onCheckedChange\",\n \"readOnly\",\n \"required\",\n \"value\"\n ]);\n const switchContext = useSwitch(switchProps);\n const mergedProps = mergeProps(switchContext.getRootProps(), localProps);\n return /* @__PURE__ */ jsx(SwitchProvider, { value: switchContext, children: /* @__PURE__ */ jsx(ark.label, { ...mergedProps, ref }) });\n});\nSwitchRoot.displayName = \"SwitchRoot\";\n\nexport { SwitchRoot };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { createSplitProps } from '../../utils/create-split-props.js';\nimport { ark } from '../factory.js';\nimport { SwitchProvider } from './use-switch-context.js';\n\nconst SwitchRootProvider = forwardRef((props, ref) => {\n const [{ value: api }, localProps] = createSplitProps()(props, [\"value\"]);\n const mergedProps = mergeProps(api.getRootProps(), localProps);\n return /* @__PURE__ */ jsx(SwitchProvider, { value: api, children: /* @__PURE__ */ jsx(ark.label, { ...mergedProps, ref }) });\n});\nSwitchRootProvider.displayName = \"SwitchRootProvider\";\n\nexport { SwitchRootProvider };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchThumb = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getThumbProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nSwitchThumb.displayName = \"SwitchThumb\";\n\nexport { SwitchThumb };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { Switch, useSwitchContext } from '@ark-ui/react/switch';\nimport { forwardRef } from 'react';\nimport { dataAttr } from '../../utils/attr.js';\nimport { createSlotRecipeContext } from '../../styled-system/create-slot-recipe-context.js';\nimport { chakra } from '../../styled-system/factory.js';\n\nconst {\n withProvider,\n withContext,\n useStyles: useSwitchStyles,\n PropsProvider\n} = createSlotRecipeContext({ key: \"switch\" });\nconst SwitchRootProvider = withProvider(Switch.RootProvider, \"root\", { forwardAsChild: true });\nconst SwitchRoot = withProvider(\n Switch.Root,\n \"root\",\n { forwardAsChild: true }\n);\nconst SwitchPropsProvider = PropsProvider;\nconst SwitchLabel = withContext(\n Switch.Label,\n \"label\",\n { forwardAsChild: true }\n);\nconst SwitchThumb = withContext(\n Switch.Thumb,\n \"thumb\",\n { forwardAsChild: true }\n);\nconst SwitchControl = withContext(\n Switch.Control,\n \"control\",\n {\n forwardAsChild: true,\n defaultProps: { children: /* @__PURE__ */ jsx(SwitchThumb, {}) }\n }\n);\nconst SwitchIndicator = forwardRef(function SwitchIndicator2(props, ref) {\n const api = useSwitchContext();\n const styles = useSwitchStyles();\n const { fallback, children, ...rest } = props;\n return /* @__PURE__ */ jsx(\n chakra.span,\n {\n ref,\n \"data-checked\": dataAttr(api.checked),\n ...rest,\n css: [styles.indicator, props.css],\n children: api.checked ? children : fallback\n }\n );\n});\nconst SwitchThumbIndicator = forwardRef(function SwitchThumbIndicator2(props, ref) {\n const api = useSwitchContext();\n const { fallback, children, ...rest } = props;\n return /* @__PURE__ */ jsx(chakra.span, { ref, \"data-checked\": dataAttr(api.checked), ...rest, children: api.checked ? children : fallback });\n});\nconst SwitchContext = Switch.Context;\nconst SwitchHiddenInput = Switch.HiddenInput;\n\nexport { SwitchContext, SwitchControl, SwitchHiddenInput, SwitchIndicator, SwitchLabel, SwitchPropsProvider, SwitchRoot, SwitchRootProvider, SwitchThumb, SwitchThumbIndicator, useSwitchStyles };\n","import React, { ForwardedRef, useMemo } from \"react\";\nimport { Switch as CSwitch } from \"@chakra-ui/react/switch\";\nimport {\n withFormControl,\n WithFormControlProps,\n} from \"hocs/withFormControl/withFormControl\";\nimport { FormControlSize } from \"hocs/withFormControl/withFormControl.types\";\n\nexport interface SwitchProps\n extends WithFormControlProps,\n Omit<CSwitch.RootProps, \"label\" | \"onChange\"> {\n indeterminate?: boolean;\n switchRef?: ForwardedRef<HTMLLabelElement>;\n size?: FormControlSize;\n}\n\nconst Switch = withFormControl(\n ({\n children,\n indeterminate = false,\n onContrast,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n label,\n size = \"md\",\n switchRef,\n ...rest\n }: SwitchProps): React.JSX.Element => {\n const _computedVariant = useMemo(() => {\n if (indeterminate) {\n return onContrast ? \"indeterminateOnContrast\" : \"indeterminate\";\n } else {\n return onContrast ? \"onContrast\" : \"default\";\n }\n }, [indeterminate, onContrast]);\n\n return (\n <CSwitch.Root\n className=\"Switch\"\n data-testid=\"kibble-switch\"\n ref={switchRef}\n size={size}\n variant={_computedVariant}\n {...rest}\n >\n <CSwitch.HiddenInput\n className=\"Switch_Input\"\n data-testid=\"kibble-switch-input\"\n />\n <CSwitch.Control\n className=\"Switch_Control\"\n data-testid=\"kibble-switch-control\"\n />\n {!!children && <CSwitch.Label>{children}</CSwitch.Label>}\n </CSwitch.Root>\n );\n },\n);\n\nconst WrappedSwitch = React.forwardRef(\n (props: SwitchProps, ref: ForwardedRef<HTMLLabelElement>) => (\n <Switch switchRef={ref} {...props} />\n ),\n);\n\nWrappedSwitch.displayName = \"Switch\";\n\nexport { WrappedSwitch as Switch };\n"],"names":["SwitchProvider","useSwitchContext","createContext","SwitchControl","forwardRef","props","ref","switchContext","mergedProps","mergeProps","jsx","ark","SwitchHiddenInput","field","useFieldContext","SwitchLabel","useSwitch","id","useId","getRootNode","useEnvironmentContext","dir","useLocaleContext","machineProps","service","useMachine","zagSwitch.machine","zagSwitch.connect","normalizeProps","SwitchRoot","switchProps","localProps","createSplitProps","SwitchRootProvider","api","SwitchThumb","withProvider","withContext","useSwitchStyles","createSlotRecipeContext","Switch.RootProvider","Switch.Root","Switch.Label","Switch.Thumb","Switch.Control","styles","fallback","children","rest","chakra","dataAttr","Switch.HiddenInput","Switch","withFormControl","indeterminate","onContrast","label","size","switchRef","_computedVariant","useMemo","jsxs","CSwitch.Root","CSwitch.HiddenInput","CSwitch.Control","CSwitch.Label","WrappedSwitch","React"],"mappings":"wbAGM,CAACA,EAAgBC,CAAgB,EAAIC,gBAAc,CACvD,KAAM,gBACN,SAAU,mBACV,aAAc,oBAChB,CAAC,ECAKC,EAAgBC,EAAU,WAAC,CAACC,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AC,EACA,GAAGV,CAAA,IACiC,CAC9B,MAAAW,EAAmBC,EAAAA,QAAQ,IAC3BN,EACKC,EAAa,0BAA4B,gBAEzCA,EAAa,aAAe,UAEpC,CAACD,EAAeC,CAAU,CAAC,EAG5B,OAAAM,EAAA,kBAAA,KAACC,EAAA,CACC,UAAU,SACV,cAAY,gBACZ,IAAKJ,EACL,KAAAD,EACA,QAASE,EACR,GAAGX,EAEJ,SAAA,CAAAtC,EAAA,kBAAA,IAACqD,EAAA,CACC,UAAU,eACV,cAAY,qBAAA,CACd,EACArD,EAAA,kBAAA,IAACsD,EAAA,CACC,UAAU,iBACV,cAAY,uBAAA,CACd,EACC,CAAC,CAACjB,2BAAakB,EAAA,CAAe,SAAAlB,CAAS,CAAA,CAAA,CAAA,CAC1C,CAAA,CAGN,EAEMmB,EAAgBC,EAAM,QAAA,WAC1B,CAAC9D,EAAoBC,IACnBI,wBAAC0C,GAAO,UAAW9C,EAAM,GAAGD,CAAO,CAAA,CAEvC,EAEA6D,EAAc,YAAc","x_google_ignoreList":[0,1,2,3,4,5,6,7,8]}
1
+ {"version":3,"file":"switch.component-CPhSaMqG.js","sources":["../../node_modules/@ark-ui/react/dist/components/switch/use-switch-context.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-control.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-hidden-input.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-label.js","../../node_modules/@ark-ui/react/dist/components/switch/use-switch.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-root.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-root-provider.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-thumb.js","../../node_modules/@chakra-ui/react/dist/esm/components/switch/switch.js","../../src/components/Switch/switch.component.tsx"],"sourcesContent":["'use client';\nimport { createContext } from '../../utils/create-context.js';\n\nconst [SwitchProvider, useSwitchContext] = createContext({\n name: \"SwitchContext\",\n hookName: \"useSwitchContext\",\n providerName: \"<SwitchProvider />\"\n});\n\nexport { SwitchProvider, useSwitchContext };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchControl = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getControlProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nSwitchControl.displayName = \"SwitchControl\";\n\nexport { SwitchControl };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from '../field/use-field-context.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchHiddenInput = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getHiddenInputProps(), props);\n const field = useFieldContext();\n return /* @__PURE__ */ jsx(ark.input, { \"aria-describedby\": field?.ariaDescribedby, ...mergedProps, ref });\n});\nSwitchHiddenInput.displayName = \"SwitchHiddenInput\";\n\nexport { SwitchHiddenInput };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchLabel = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getLabelProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nSwitchLabel.displayName = \"SwitchLabel\";\n\nexport { SwitchLabel };\n","'use client';\nimport { useMachine, normalizeProps } from '@zag-js/react';\nimport * as zagSwitch from '@zag-js/switch';\nimport { useId } from 'react';\nimport { useEnvironmentContext } from '../../providers/environment/use-environment-context.js';\nimport { useLocaleContext } from '../../providers/locale/use-locale-context.js';\nimport { useFieldContext } from '../field/use-field-context.js';\n\nconst useSwitch = (props) => {\n const id = useId();\n const { getRootNode } = useEnvironmentContext();\n const { dir } = useLocaleContext();\n const field = useFieldContext();\n const machineProps = {\n id,\n ids: {\n label: field?.ids.label,\n hiddenInput: field?.ids.control\n },\n dir,\n disabled: field?.disabled,\n readOnly: field?.readOnly,\n invalid: field?.invalid,\n required: field?.required,\n getRootNode,\n ...props\n };\n const service = useMachine(zagSwitch.machine, machineProps);\n return zagSwitch.connect(service, normalizeProps);\n};\n\nexport { useSwitch };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { createSplitProps } from '../../utils/create-split-props.js';\nimport { ark } from '../factory.js';\nimport { useSwitch } from './use-switch.js';\nimport { SwitchProvider } from './use-switch-context.js';\n\nconst SwitchRoot = forwardRef((props, ref) => {\n const [switchProps, localProps] = createSplitProps()(props, [\n \"checked\",\n \"defaultChecked\",\n \"disabled\",\n \"form\",\n \"id\",\n \"ids\",\n \"invalid\",\n \"label\",\n \"name\",\n \"onCheckedChange\",\n \"readOnly\",\n \"required\",\n \"value\"\n ]);\n const switchContext = useSwitch(switchProps);\n const mergedProps = mergeProps(switchContext.getRootProps(), localProps);\n return /* @__PURE__ */ jsx(SwitchProvider, { value: switchContext, children: /* @__PURE__ */ jsx(ark.label, { ...mergedProps, ref }) });\n});\nSwitchRoot.displayName = \"SwitchRoot\";\n\nexport { SwitchRoot };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { createSplitProps } from '../../utils/create-split-props.js';\nimport { ark } from '../factory.js';\nimport { SwitchProvider } from './use-switch-context.js';\n\nconst SwitchRootProvider = forwardRef((props, ref) => {\n const [{ value: api }, localProps] = createSplitProps()(props, [\"value\"]);\n const mergedProps = mergeProps(api.getRootProps(), localProps);\n return /* @__PURE__ */ jsx(SwitchProvider, { value: api, children: /* @__PURE__ */ jsx(ark.label, { ...mergedProps, ref }) });\n});\nSwitchRootProvider.displayName = \"SwitchRootProvider\";\n\nexport { SwitchRootProvider };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchThumb = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getThumbProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nSwitchThumb.displayName = \"SwitchThumb\";\n\nexport { SwitchThumb };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { Switch, useSwitchContext } from '@ark-ui/react/switch';\nimport { forwardRef } from 'react';\nimport { dataAttr } from '../../utils/attr.js';\nimport { createSlotRecipeContext } from '../../styled-system/create-slot-recipe-context.js';\nimport { chakra } from '../../styled-system/factory.js';\n\nconst {\n withProvider,\n withContext,\n useStyles: useSwitchStyles,\n PropsProvider\n} = createSlotRecipeContext({ key: \"switch\" });\nconst SwitchRootProvider = withProvider(Switch.RootProvider, \"root\", { forwardAsChild: true });\nconst SwitchRoot = withProvider(\n Switch.Root,\n \"root\",\n { forwardAsChild: true }\n);\nconst SwitchPropsProvider = PropsProvider;\nconst SwitchLabel = withContext(\n Switch.Label,\n \"label\",\n { forwardAsChild: true }\n);\nconst SwitchThumb = withContext(\n Switch.Thumb,\n \"thumb\",\n { forwardAsChild: true }\n);\nconst SwitchControl = withContext(\n Switch.Control,\n \"control\",\n {\n forwardAsChild: true,\n defaultProps: { children: /* @__PURE__ */ jsx(SwitchThumb, {}) }\n }\n);\nconst SwitchIndicator = forwardRef(function SwitchIndicator2(props, ref) {\n const api = useSwitchContext();\n const styles = useSwitchStyles();\n const { fallback, children, ...rest } = props;\n return /* @__PURE__ */ jsx(\n chakra.span,\n {\n ref,\n \"data-checked\": dataAttr(api.checked),\n ...rest,\n css: [styles.indicator, props.css],\n children: api.checked ? children : fallback\n }\n );\n});\nconst SwitchThumbIndicator = forwardRef(function SwitchThumbIndicator2(props, ref) {\n const api = useSwitchContext();\n const { fallback, children, ...rest } = props;\n return /* @__PURE__ */ jsx(chakra.span, { ref, \"data-checked\": dataAttr(api.checked), ...rest, children: api.checked ? children : fallback });\n});\nconst SwitchContext = Switch.Context;\nconst SwitchHiddenInput = Switch.HiddenInput;\n\nexport { SwitchContext, SwitchControl, SwitchHiddenInput, SwitchIndicator, SwitchLabel, SwitchPropsProvider, SwitchRoot, SwitchRootProvider, SwitchThumb, SwitchThumbIndicator, useSwitchStyles };\n","import React, { ForwardedRef, useMemo } from \"react\";\nimport { Switch as CSwitch } from \"@chakra-ui/react/switch\";\nimport {\n withFormControl,\n WithFormControlProps,\n} from \"hocs/withFormControl/withFormControl\";\nimport { FormControlSize } from \"hocs/withFormControl/withFormControl.types\";\n\nexport interface SwitchProps\n extends WithFormControlProps,\n Omit<CSwitch.RootProps, \"label\" | \"onChange\"> {\n indeterminate?: boolean;\n switchRef?: ForwardedRef<HTMLLabelElement>;\n size?: FormControlSize;\n}\n\nconst Switch = withFormControl(\n ({\n children,\n indeterminate = false,\n onContrast,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n label,\n size = \"md\",\n switchRef,\n ...rest\n }: SwitchProps): React.JSX.Element => {\n const _computedVariant = useMemo(() => {\n if (indeterminate) {\n return onContrast ? \"indeterminateOnContrast\" : \"indeterminate\";\n } else {\n return onContrast ? \"onContrast\" : \"default\";\n }\n }, [indeterminate, onContrast]);\n\n return (\n <CSwitch.Root\n className=\"Switch\"\n data-testid=\"kibble-switch\"\n ref={switchRef}\n size={size}\n variant={_computedVariant}\n {...rest}\n >\n <CSwitch.HiddenInput\n className=\"Switch_Input\"\n data-testid=\"kibble-switch-input\"\n />\n <CSwitch.Control\n className=\"Switch_Control\"\n data-testid=\"kibble-switch-control\"\n />\n {!!children && <CSwitch.Label>{children}</CSwitch.Label>}\n </CSwitch.Root>\n );\n },\n);\n\nconst WrappedSwitch = React.forwardRef(\n (props: SwitchProps, ref: ForwardedRef<HTMLLabelElement>) => (\n <Switch switchRef={ref} {...props} />\n ),\n);\n\nWrappedSwitch.displayName = \"Switch\";\n\nexport { WrappedSwitch as Switch };\n"],"names":["SwitchProvider","useSwitchContext","createContext","SwitchControl","forwardRef","props","ref","switchContext","mergedProps","mergeProps","jsx","ark","SwitchHiddenInput","field","useFieldContext","SwitchLabel","useSwitch","id","useId","getRootNode","useEnvironmentContext","dir","useLocaleContext","machineProps","service","useMachine","zagSwitch.machine","zagSwitch.connect","normalizeProps","SwitchRoot","switchProps","localProps","createSplitProps","SwitchRootProvider","api","SwitchThumb","withProvider","withContext","useSwitchStyles","createSlotRecipeContext","Switch.RootProvider","Switch.Root","Switch.Label","Switch.Thumb","Switch.Control","styles","fallback","children","rest","chakra","dataAttr","Switch.HiddenInput","Switch","withFormControl","indeterminate","onContrast","label","size","switchRef","_computedVariant","useMemo","jsxs","CSwitch.Root","CSwitch.HiddenInput","CSwitch.Control","CSwitch.Label","WrappedSwitch","React"],"mappings":"4aAGM,CAACA,EAAgBC,CAAgB,EAAIC,gBAAc,CACvD,KAAM,gBACN,SAAU,mBACV,aAAc,oBAChB,CAAC,ECAKC,EAAgBC,EAAU,WAAC,CAACC,EAAOC,IAAQ,CAC/C,MAAMC,EAAgBN,EAAkB,EAClCO,EAAcC,EAAU,WAACF,EAAc,gBAAe,EAAIF,CAAK,EACrE,OAAuBK,EAAAA,kBAAAA,IAAIC,EAAAA,IAAI,KAAM,CAAE,GAAGH,EAAa,IAAAF,EAAK,CAC9D,CAAC,EACDH,EAAc,YAAc,gBCJ5B,MAAMS,EAAoBR,EAAU,WAAC,CAACC,EAAOC,IAAQ,CACnD,MAAMC,EAAgBN,EAAkB,EAClCO,EAAcC,EAAU,WAACF,EAAc,oBAAmB,EAAIF,CAAK,EACnEQ,EAAQC,EAAAA,gBAAiB,EAC/B,OAAuBJ,EAAG,kBAAA,IAACC,MAAI,MAAO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AAA,CAAe,SAAAlB,CAAS,CAAA,CAAA,CAAA,CAC1C,CAAA,CAGN,EAEMmB,EAAgBC,EAAM,QAAA,WAC1B,CAAC9D,EAAoBC,IACnBI,wBAAC0C,GAAO,UAAW9C,EAAM,GAAGD,CAAO,CAAA,CAEvC,EAEA6D,EAAc,YAAc","x_google_ignoreList":[0,1,2,3,4,5,6,7,8]}
@@ -1,13 +1,13 @@
1
1
  import { j as c } from "./jsx-runtime-C5mzlN2N.js";
2
2
  import g, { forwardRef as n, useId as R, useMemo as N } from "react";
3
- import { w as I } from "./withFormControl-TnKXd5oM.js";
3
+ import { w as I } from "./withFormControl-Cb632r_x.js";
4
4
  import { d as u } from "./attr-sm10PXOd.js";
5
5
  import { c as A } from "./create-slot-recipe-context-BJmsuxih.js";
6
6
  import { c as w } from "./factory-Ctbv0Ozn.js";
7
- import { c as L, f as d, i as T, j as _, k as $, n as H, a as S } from "./use-locale-context-D-agiW5E.js";
8
- import { u as f } from "./use-field-context-B_G7Yziz.js";
9
- import { Y as l } from "./index-CYk-7wwG.js";
10
- import { m as O, c as q } from "./index-DkJX2kvl.js";
7
+ import { c as L, f as d, i as T, j as _, k as $, n as H, a as S } from "./portal-D2KZrSzZ.js";
8
+ import { u as f } from "./use-field-context-C4IwmN39.js";
9
+ import { a1 as l } from "./index-C323eOJV.js";
10
+ import { m as O, c as q } from "./index-DMSZTX7A.js";
11
11
  const [x, h] = L({
12
12
  name: "SwitchContext",
13
13
  hookName: "useSwitchContext",
@@ -115,7 +115,7 @@ n(function(t, e) {
115
115
  const s = h(), { fallback: r, children: i, ...a } = t;
116
116
  return /* @__PURE__ */ c.jsx(w.span, { ref: e, "data-checked": u(s.checked), ...a, children: s.checked ? i : r });
117
117
  });
118
- const V = C, Y = I(
118
+ const V = C, B = I(
119
119
  ({
120
120
  children: o,
121
121
  indeterminate: t = !1,
@@ -156,11 +156,11 @@ const V = C, Y = I(
156
156
  }
157
157
  );
158
158
  }
159
- ), B = g.forwardRef(
160
- (o, t) => /* @__PURE__ */ c.jsx(Y, { switchRef: t, ...o })
159
+ ), G = g.forwardRef(
160
+ (o, t) => /* @__PURE__ */ c.jsx(B, { switchRef: t, ...o })
161
161
  );
162
- B.displayName = "Switch";
162
+ G.displayName = "Switch";
163
163
  export {
164
- B as W
164
+ G as W
165
165
  };
166
- //# sourceMappingURL=switch.component-CfVjV1Ue.js.map
166
+ //# sourceMappingURL=switch.component-Dpu_wRns.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"switch.component-CfVjV1Ue.js","sources":["../../node_modules/@ark-ui/react/dist/components/switch/use-switch-context.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-control.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-hidden-input.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-label.js","../../node_modules/@ark-ui/react/dist/components/switch/use-switch.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-root.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-root-provider.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-thumb.js","../../node_modules/@chakra-ui/react/dist/esm/components/switch/switch.js","../../src/components/Switch/switch.component.tsx"],"sourcesContent":["'use client';\nimport { createContext } from '../../utils/create-context.js';\n\nconst [SwitchProvider, useSwitchContext] = createContext({\n name: \"SwitchContext\",\n hookName: \"useSwitchContext\",\n providerName: \"<SwitchProvider />\"\n});\n\nexport { SwitchProvider, useSwitchContext };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchControl = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getControlProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nSwitchControl.displayName = \"SwitchControl\";\n\nexport { SwitchControl };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from '../field/use-field-context.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchHiddenInput = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getHiddenInputProps(), props);\n const field = useFieldContext();\n return /* @__PURE__ */ jsx(ark.input, { \"aria-describedby\": field?.ariaDescribedby, ...mergedProps, ref });\n});\nSwitchHiddenInput.displayName = \"SwitchHiddenInput\";\n\nexport { SwitchHiddenInput };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchLabel = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getLabelProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nSwitchLabel.displayName = \"SwitchLabel\";\n\nexport { SwitchLabel };\n","'use client';\nimport { useMachine, normalizeProps } from '@zag-js/react';\nimport * as zagSwitch from '@zag-js/switch';\nimport { useId } from 'react';\nimport { useEnvironmentContext } from '../../providers/environment/use-environment-context.js';\nimport { useLocaleContext } from '../../providers/locale/use-locale-context.js';\nimport { useFieldContext } from '../field/use-field-context.js';\n\nconst useSwitch = (props) => {\n const id = useId();\n const { getRootNode } = useEnvironmentContext();\n const { dir } = useLocaleContext();\n const field = useFieldContext();\n const machineProps = {\n id,\n ids: {\n label: field?.ids.label,\n hiddenInput: field?.ids.control\n },\n dir,\n disabled: field?.disabled,\n readOnly: field?.readOnly,\n invalid: field?.invalid,\n required: field?.required,\n getRootNode,\n ...props\n };\n const service = useMachine(zagSwitch.machine, machineProps);\n return zagSwitch.connect(service, normalizeProps);\n};\n\nexport { useSwitch };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { createSplitProps } from '../../utils/create-split-props.js';\nimport { ark } from '../factory.js';\nimport { useSwitch } from './use-switch.js';\nimport { SwitchProvider } from './use-switch-context.js';\n\nconst SwitchRoot = forwardRef((props, ref) => {\n const [switchProps, localProps] = createSplitProps()(props, [\n \"checked\",\n \"defaultChecked\",\n \"disabled\",\n \"form\",\n \"id\",\n \"ids\",\n \"invalid\",\n \"label\",\n \"name\",\n \"onCheckedChange\",\n \"readOnly\",\n \"required\",\n \"value\"\n ]);\n const switchContext = useSwitch(switchProps);\n const mergedProps = mergeProps(switchContext.getRootProps(), localProps);\n return /* @__PURE__ */ jsx(SwitchProvider, { value: switchContext, children: /* @__PURE__ */ jsx(ark.label, { ...mergedProps, ref }) });\n});\nSwitchRoot.displayName = \"SwitchRoot\";\n\nexport { SwitchRoot };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { createSplitProps } from '../../utils/create-split-props.js';\nimport { ark } from '../factory.js';\nimport { SwitchProvider } from './use-switch-context.js';\n\nconst SwitchRootProvider = forwardRef((props, ref) => {\n const [{ value: api }, localProps] = createSplitProps()(props, [\"value\"]);\n const mergedProps = mergeProps(api.getRootProps(), localProps);\n return /* @__PURE__ */ jsx(SwitchProvider, { value: api, children: /* @__PURE__ */ jsx(ark.label, { ...mergedProps, ref }) });\n});\nSwitchRootProvider.displayName = \"SwitchRootProvider\";\n\nexport { SwitchRootProvider };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchThumb = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getThumbProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nSwitchThumb.displayName = \"SwitchThumb\";\n\nexport { SwitchThumb };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { Switch, useSwitchContext } from '@ark-ui/react/switch';\nimport { forwardRef } from 'react';\nimport { dataAttr } from '../../utils/attr.js';\nimport { createSlotRecipeContext } from '../../styled-system/create-slot-recipe-context.js';\nimport { chakra } from '../../styled-system/factory.js';\n\nconst {\n withProvider,\n withContext,\n useStyles: useSwitchStyles,\n PropsProvider\n} = createSlotRecipeContext({ key: \"switch\" });\nconst SwitchRootProvider = withProvider(Switch.RootProvider, \"root\", { forwardAsChild: true });\nconst SwitchRoot = withProvider(\n Switch.Root,\n \"root\",\n { forwardAsChild: true }\n);\nconst SwitchPropsProvider = PropsProvider;\nconst SwitchLabel = withContext(\n Switch.Label,\n \"label\",\n { forwardAsChild: true }\n);\nconst SwitchThumb = withContext(\n Switch.Thumb,\n \"thumb\",\n { forwardAsChild: true }\n);\nconst SwitchControl = withContext(\n Switch.Control,\n \"control\",\n {\n forwardAsChild: true,\n defaultProps: { children: /* @__PURE__ */ jsx(SwitchThumb, {}) }\n }\n);\nconst SwitchIndicator = forwardRef(function SwitchIndicator2(props, ref) {\n const api = useSwitchContext();\n const styles = useSwitchStyles();\n const { fallback, children, ...rest } = props;\n return /* @__PURE__ */ jsx(\n chakra.span,\n {\n ref,\n \"data-checked\": dataAttr(api.checked),\n ...rest,\n css: [styles.indicator, props.css],\n children: api.checked ? children : fallback\n }\n );\n});\nconst SwitchThumbIndicator = forwardRef(function SwitchThumbIndicator2(props, ref) {\n const api = useSwitchContext();\n const { fallback, children, ...rest } = props;\n return /* @__PURE__ */ jsx(chakra.span, { ref, \"data-checked\": dataAttr(api.checked), ...rest, children: api.checked ? children : fallback });\n});\nconst SwitchContext = Switch.Context;\nconst SwitchHiddenInput = Switch.HiddenInput;\n\nexport { SwitchContext, SwitchControl, SwitchHiddenInput, SwitchIndicator, SwitchLabel, SwitchPropsProvider, SwitchRoot, SwitchRootProvider, SwitchThumb, SwitchThumbIndicator, useSwitchStyles };\n","import React, { ForwardedRef, useMemo } from \"react\";\nimport { Switch as CSwitch } from \"@chakra-ui/react/switch\";\nimport {\n withFormControl,\n WithFormControlProps,\n} from \"hocs/withFormControl/withFormControl\";\nimport { FormControlSize } from \"hocs/withFormControl/withFormControl.types\";\n\nexport interface SwitchProps\n extends WithFormControlProps,\n Omit<CSwitch.RootProps, \"label\" | \"onChange\"> {\n indeterminate?: boolean;\n switchRef?: ForwardedRef<HTMLLabelElement>;\n size?: FormControlSize;\n}\n\nconst Switch = withFormControl(\n ({\n children,\n indeterminate = false,\n onContrast,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n label,\n size = \"md\",\n switchRef,\n ...rest\n }: SwitchProps): React.JSX.Element => {\n const _computedVariant = useMemo(() => {\n if (indeterminate) {\n return onContrast ? \"indeterminateOnContrast\" : \"indeterminate\";\n } else {\n return onContrast ? \"onContrast\" : \"default\";\n }\n }, [indeterminate, onContrast]);\n\n return (\n <CSwitch.Root\n className=\"Switch\"\n data-testid=\"kibble-switch\"\n ref={switchRef}\n size={size}\n variant={_computedVariant}\n {...rest}\n >\n <CSwitch.HiddenInput\n className=\"Switch_Input\"\n data-testid=\"kibble-switch-input\"\n />\n <CSwitch.Control\n className=\"Switch_Control\"\n data-testid=\"kibble-switch-control\"\n />\n {!!children && <CSwitch.Label>{children}</CSwitch.Label>}\n </CSwitch.Root>\n );\n },\n);\n\nconst WrappedSwitch = React.forwardRef(\n (props: SwitchProps, ref: ForwardedRef<HTMLLabelElement>) => (\n <Switch switchRef={ref} {...props} />\n ),\n);\n\nWrappedSwitch.displayName = \"Switch\";\n\nexport { WrappedSwitch as Switch };\n"],"names":["SwitchProvider","useSwitchContext","createContext","SwitchControl","forwardRef","props","ref","switchContext","mergedProps","mergeProps","jsx","ark","SwitchHiddenInput","field","useFieldContext","SwitchLabel","useSwitch","id","useId","getRootNode","useEnvironmentContext","dir","useLocaleContext","machineProps","service","useMachine","zagSwitch.machine","zagSwitch.connect","normalizeProps","SwitchRoot","switchProps","localProps","createSplitProps","SwitchRootProvider","api","SwitchThumb","withProvider","withContext","useSwitchStyles","createSlotRecipeContext","Switch.RootProvider","Switch.Root","Switch.Label","Switch.Thumb","Switch.Control","styles","fallback","children","rest","chakra","dataAttr","Switch.HiddenInput","Switch","withFormControl","indeterminate","onContrast","label","size","switchRef","_computedVariant","useMemo","jsxs","CSwitch.Root","CSwitch.HiddenInput","CSwitch.Control","CSwitch.Label","WrappedSwitch","React"],"mappings":";;;;;;;;;;AAGA,MAAM,CAACA,GAAgBC,CAAgB,IAAIC,EAAc;AAAA,EACvD,MAAM;AAAA,EACN,UAAU;AAAA,EACV,cAAc;AAChB,CAAC,GCAKC,IAAgBC,EAAW,CAACC,GAAOC,MAAQ;AAC/C,QAAMC,IAAgBN,EAAkB,GAClCO,IAAcC,EAAWF,EAAc,gBAAe,GAAIF,CAAK;AACrE,SAAuBK,gBAAAA,EAAAA,IAAIC,EAAI,MAAM,EAAE,GAAGH,GAAa,KAAAF,GAAK;AAC9D,CAAC;AACDH,EAAc,cAAc;ACJ5B,MAAMS,IAAoBR,EAAW,CAACC,GAAOC,MAAQ;AACnD,QAAMC,IAAgBN,EAAkB,GAClCO,IAAcC,EAAWF,EAAc,oBAAmB,GAAIF,CAAK,GACnEQ,IAAQC,EAAiB;AAC/B,SAAuBJ,gBAAAA,EAAG,IAACC,EAAI,OAAO,EAAE,oBAAoBE,GAAO,iBAAiB,GAAGL,GAAa,KAAAF,GAAK;AAC3G,CAAC;AACDM,EAAkB,cAAc;ACPhC,MAAMG,IAAcX,EAAW,CAACC,GAAOC,MAAQ;AAC7C,QAAMC,IAAgBN,EAAkB,GAClCO,IAAcC,EAAWF,EAAc,cAAa,GAAIF,CAAK;AACnE,SAAuBK,gBAAAA,EAAAA,IAAIC,EAAI,MAAM,EAAE,GAAGH,GAAa,KAAAF,GAAK;AAC9D,CAAC;AACDS,EAAY,cAAc;ACJ1B,MAAMC,IAAY,CAACX,MAAU;AAC3B,QAAMY,IAAKC,EAAO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AS,CAAA;AAAA,QAAA;AAAA,MAAA;AAAA,IAC1C;AAAA,EAAA;AAGN,GAEMmB,IAAgBC,EAAM;AAAA,EAC1B,CAAC9D,GAAoBC,MACnBI,gBAAAA,MAAC0C,KAAO,WAAW9C,GAAM,GAAGD,EAAO,CAAA;AAEvC;AAEA6D,EAAc,cAAc;","x_google_ignoreList":[0,1,2,3,4,5,6,7,8]}
1
+ {"version":3,"file":"switch.component-Dpu_wRns.js","sources":["../../node_modules/@ark-ui/react/dist/components/switch/use-switch-context.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-control.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-hidden-input.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-label.js","../../node_modules/@ark-ui/react/dist/components/switch/use-switch.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-root.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-root-provider.js","../../node_modules/@ark-ui/react/dist/components/switch/switch-thumb.js","../../node_modules/@chakra-ui/react/dist/esm/components/switch/switch.js","../../src/components/Switch/switch.component.tsx"],"sourcesContent":["'use client';\nimport { createContext } from '../../utils/create-context.js';\n\nconst [SwitchProvider, useSwitchContext] = createContext({\n name: \"SwitchContext\",\n hookName: \"useSwitchContext\",\n providerName: \"<SwitchProvider />\"\n});\n\nexport { SwitchProvider, useSwitchContext };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchControl = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getControlProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nSwitchControl.displayName = \"SwitchControl\";\n\nexport { SwitchControl };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useFieldContext } from '../field/use-field-context.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchHiddenInput = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getHiddenInputProps(), props);\n const field = useFieldContext();\n return /* @__PURE__ */ jsx(ark.input, { \"aria-describedby\": field?.ariaDescribedby, ...mergedProps, ref });\n});\nSwitchHiddenInput.displayName = \"SwitchHiddenInput\";\n\nexport { SwitchHiddenInput };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchLabel = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getLabelProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nSwitchLabel.displayName = \"SwitchLabel\";\n\nexport { SwitchLabel };\n","'use client';\nimport { useMachine, normalizeProps } from '@zag-js/react';\nimport * as zagSwitch from '@zag-js/switch';\nimport { useId } from 'react';\nimport { useEnvironmentContext } from '../../providers/environment/use-environment-context.js';\nimport { useLocaleContext } from '../../providers/locale/use-locale-context.js';\nimport { useFieldContext } from '../field/use-field-context.js';\n\nconst useSwitch = (props) => {\n const id = useId();\n const { getRootNode } = useEnvironmentContext();\n const { dir } = useLocaleContext();\n const field = useFieldContext();\n const machineProps = {\n id,\n ids: {\n label: field?.ids.label,\n hiddenInput: field?.ids.control\n },\n dir,\n disabled: field?.disabled,\n readOnly: field?.readOnly,\n invalid: field?.invalid,\n required: field?.required,\n getRootNode,\n ...props\n };\n const service = useMachine(zagSwitch.machine, machineProps);\n return zagSwitch.connect(service, normalizeProps);\n};\n\nexport { useSwitch };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { createSplitProps } from '../../utils/create-split-props.js';\nimport { ark } from '../factory.js';\nimport { useSwitch } from './use-switch.js';\nimport { SwitchProvider } from './use-switch-context.js';\n\nconst SwitchRoot = forwardRef((props, ref) => {\n const [switchProps, localProps] = createSplitProps()(props, [\n \"checked\",\n \"defaultChecked\",\n \"disabled\",\n \"form\",\n \"id\",\n \"ids\",\n \"invalid\",\n \"label\",\n \"name\",\n \"onCheckedChange\",\n \"readOnly\",\n \"required\",\n \"value\"\n ]);\n const switchContext = useSwitch(switchProps);\n const mergedProps = mergeProps(switchContext.getRootProps(), localProps);\n return /* @__PURE__ */ jsx(SwitchProvider, { value: switchContext, children: /* @__PURE__ */ jsx(ark.label, { ...mergedProps, ref }) });\n});\nSwitchRoot.displayName = \"SwitchRoot\";\n\nexport { SwitchRoot };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { createSplitProps } from '../../utils/create-split-props.js';\nimport { ark } from '../factory.js';\nimport { SwitchProvider } from './use-switch-context.js';\n\nconst SwitchRootProvider = forwardRef((props, ref) => {\n const [{ value: api }, localProps] = createSplitProps()(props, [\"value\"]);\n const mergedProps = mergeProps(api.getRootProps(), localProps);\n return /* @__PURE__ */ jsx(SwitchProvider, { value: api, children: /* @__PURE__ */ jsx(ark.label, { ...mergedProps, ref }) });\n});\nSwitchRootProvider.displayName = \"SwitchRootProvider\";\n\nexport { SwitchRootProvider };\n","'use client';\nimport { jsx } from 'react/jsx-runtime';\nimport { mergeProps } from '@zag-js/react';\nimport { forwardRef } from 'react';\nimport { ark } from '../factory.js';\nimport { useSwitchContext } from './use-switch-context.js';\n\nconst SwitchThumb = forwardRef((props, ref) => {\n const switchContext = useSwitchContext();\n const mergedProps = mergeProps(switchContext.getThumbProps(), props);\n return /* @__PURE__ */ jsx(ark.span, { ...mergedProps, ref });\n});\nSwitchThumb.displayName = \"SwitchThumb\";\n\nexport { SwitchThumb };\n","\"use strict\";\n\"use client\";\nimport { jsx } from 'react/jsx-runtime';\nimport { Switch, useSwitchContext } from '@ark-ui/react/switch';\nimport { forwardRef } from 'react';\nimport { dataAttr } from '../../utils/attr.js';\nimport { createSlotRecipeContext } from '../../styled-system/create-slot-recipe-context.js';\nimport { chakra } from '../../styled-system/factory.js';\n\nconst {\n withProvider,\n withContext,\n useStyles: useSwitchStyles,\n PropsProvider\n} = createSlotRecipeContext({ key: \"switch\" });\nconst SwitchRootProvider = withProvider(Switch.RootProvider, \"root\", { forwardAsChild: true });\nconst SwitchRoot = withProvider(\n Switch.Root,\n \"root\",\n { forwardAsChild: true }\n);\nconst SwitchPropsProvider = PropsProvider;\nconst SwitchLabel = withContext(\n Switch.Label,\n \"label\",\n { forwardAsChild: true }\n);\nconst SwitchThumb = withContext(\n Switch.Thumb,\n \"thumb\",\n { forwardAsChild: true }\n);\nconst SwitchControl = withContext(\n Switch.Control,\n \"control\",\n {\n forwardAsChild: true,\n defaultProps: { children: /* @__PURE__ */ jsx(SwitchThumb, {}) }\n }\n);\nconst SwitchIndicator = forwardRef(function SwitchIndicator2(props, ref) {\n const api = useSwitchContext();\n const styles = useSwitchStyles();\n const { fallback, children, ...rest } = props;\n return /* @__PURE__ */ jsx(\n chakra.span,\n {\n ref,\n \"data-checked\": dataAttr(api.checked),\n ...rest,\n css: [styles.indicator, props.css],\n children: api.checked ? children : fallback\n }\n );\n});\nconst SwitchThumbIndicator = forwardRef(function SwitchThumbIndicator2(props, ref) {\n const api = useSwitchContext();\n const { fallback, children, ...rest } = props;\n return /* @__PURE__ */ jsx(chakra.span, { ref, \"data-checked\": dataAttr(api.checked), ...rest, children: api.checked ? children : fallback });\n});\nconst SwitchContext = Switch.Context;\nconst SwitchHiddenInput = Switch.HiddenInput;\n\nexport { SwitchContext, SwitchControl, SwitchHiddenInput, SwitchIndicator, SwitchLabel, SwitchPropsProvider, SwitchRoot, SwitchRootProvider, SwitchThumb, SwitchThumbIndicator, useSwitchStyles };\n","import React, { ForwardedRef, useMemo } from \"react\";\nimport { Switch as CSwitch } from \"@chakra-ui/react/switch\";\nimport {\n withFormControl,\n WithFormControlProps,\n} from \"hocs/withFormControl/withFormControl\";\nimport { FormControlSize } from \"hocs/withFormControl/withFormControl.types\";\n\nexport interface SwitchProps\n extends WithFormControlProps,\n Omit<CSwitch.RootProps, \"label\" | \"onChange\"> {\n indeterminate?: boolean;\n switchRef?: ForwardedRef<HTMLLabelElement>;\n size?: FormControlSize;\n}\n\nconst Switch = withFormControl(\n ({\n children,\n indeterminate = false,\n onContrast,\n // eslint-disable-next-line @typescript-eslint/no-unused-vars\n label,\n size = \"md\",\n switchRef,\n ...rest\n }: SwitchProps): React.JSX.Element => {\n const _computedVariant = useMemo(() => {\n if (indeterminate) {\n return onContrast ? \"indeterminateOnContrast\" : \"indeterminate\";\n } else {\n return onContrast ? \"onContrast\" : \"default\";\n }\n }, [indeterminate, onContrast]);\n\n return (\n <CSwitch.Root\n className=\"Switch\"\n data-testid=\"kibble-switch\"\n ref={switchRef}\n size={size}\n variant={_computedVariant}\n {...rest}\n >\n <CSwitch.HiddenInput\n className=\"Switch_Input\"\n data-testid=\"kibble-switch-input\"\n />\n <CSwitch.Control\n className=\"Switch_Control\"\n data-testid=\"kibble-switch-control\"\n />\n {!!children && <CSwitch.Label>{children}</CSwitch.Label>}\n </CSwitch.Root>\n );\n },\n);\n\nconst WrappedSwitch = React.forwardRef(\n (props: SwitchProps, ref: ForwardedRef<HTMLLabelElement>) => (\n <Switch switchRef={ref} {...props} />\n ),\n);\n\nWrappedSwitch.displayName = \"Switch\";\n\nexport { WrappedSwitch as Switch };\n"],"names":["SwitchProvider","useSwitchContext","createContext","SwitchControl","forwardRef","props","ref","switchContext","mergedProps","mergeProps","jsx","ark","SwitchHiddenInput","field","useFieldContext","SwitchLabel","useSwitch","id","useId","getRootNode","useEnvironmentContext","dir","useLocaleContext","machineProps","service","useMachine","zagSwitch.machine","zagSwitch.connect","normalizeProps","SwitchRoot","switchProps","localProps","createSplitProps","SwitchRootProvider","api","SwitchThumb","withProvider","withContext","useSwitchStyles","createSlotRecipeContext","Switch.RootProvider","Switch.Root","Switch.Label","Switch.Thumb","Switch.Control","styles","fallback","children","rest","chakra","dataAttr","Switch.HiddenInput","Switch","withFormControl","indeterminate","onContrast","label","size","switchRef","_computedVariant","useMemo","jsxs","CSwitch.Root","CSwitch.HiddenInput","CSwitch.Control","CSwitch.Label","WrappedSwitch","React"],"mappings":";;;;;;;;;;AAGA,MAAM,CAACA,GAAgBC,CAAgB,IAAIC,EAAc;AAAA,EACvD,MAAM;AAAA,EACN,UAAU;AAAA,EACV,cAAc;AAChB,CAAC,GCAKC,IAAgBC,EAAW,CAACC,GAAOC,MAAQ;AAC/C,QAAMC,IAAgBN,EAAkB,GAClCO,IAAcC,EAAWF,EAAc,gBAAe,GAAIF,CAAK;AACrE,SAAuBK,gBAAAA,EAAAA,IAAIC,EAAI,MAAM,EAAE,GAAGH,GAAa,KAAAF,GAAK;AAC9D,CAAC;AACDH,EAAc,cAAc;ACJ5B,MAAMS,IAAoBR,EAAW,CAACC,GAAOC,MAAQ;AACnD,QAAMC,IAAgBN,EAAkB,GAClCO,IAAcC,EAAWF,EAAc,oBAAmB,GAAIF,CAAK,GACnEQ,IAAQC,EAAiB;AAC/B,SAAuBJ,gBAAAA,EAAG,IAACC,EAAI,OAAO,EAAE,oBAAoBE,GAAO,iBAAiB,GAAGL,GAAa,KAAAF,GAAK;AAC3G,CAAC;AACDM,EAAkB,cAAc;ACPhC,MAAMG,IAAcX,EAAW,CAACC,GAAOC,MAAQ;AAC7C,QAAMC,IAAgBN,EAAkB,GAClCO,IAAcC,EAAWF,EAAc,cAAa,GAAIF,CAAK;AACnE,SAAuBK,gBAAAA,EAAAA,IAAIC,EAAI,MAAM,EAAE,GAAGH,GAAa,KAAAF,GAAK;AAC9D,CAAC;AACDS,EAAY,cAAc;ACJ1B,MAAMC,IAAY,CAACX,MAAU;AAC3B,QAAMY,IAAKC,EAAO,GACZ,EAAE,aAAAC,EAAa,IAAGC,EAAuB,GACzC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