@ark-ui/solid 4.10.1 → 5.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (255) hide show
  1. package/README.md +6 -9
  2. package/dist/chunk/{E72NMPSK.jsx → 2FYSIKNK.jsx} +5 -13
  3. package/dist/chunk/{2ILK4IFM.jsx → 2TEQVFZN.jsx} +16 -28
  4. package/dist/chunk/{2H4WHODR.js → 3CUJRNYI.js} +7 -10
  5. package/dist/chunk/{MRQ2UYM4.jsx → 3VB4UGEY.jsx} +8 -10
  6. package/dist/chunk/{ATMUKDFF.js → 44YJVOL2.js} +8 -10
  7. package/dist/chunk/{RVUYRERH.jsx → 4D76BVTD.jsx} +35 -17
  8. package/dist/chunk/{VARNCRUN.js → 4E5OPUFZ.js} +16 -18
  9. package/dist/chunk/{5JS7LFUQ.js → 4GOBFWQB.js} +9 -8
  10. package/dist/chunk/{RAEDLHD3.js → 55NHLACH.js} +11 -14
  11. package/dist/chunk/{2HTNQLGP.jsx → 676ULDTZ.jsx} +9 -13
  12. package/dist/chunk/{U7SPBSDD.jsx → 6AKFQH4M.jsx} +8 -13
  13. package/dist/chunk/{QODB3C3M.js → 6MQ6S5JP.js} +8 -5
  14. package/dist/chunk/{CIPYIXIW.js → 6NMPU3T3.js} +8 -10
  15. package/dist/chunk/{FNEB2RAF.js → 6VITT55B.js} +9 -10
  16. package/dist/chunk/{SBPY26HV.jsx → 7AJYNPOZ.jsx} +8 -11
  17. package/dist/chunk/{EHJDQTTW.jsx → 7IAJIOJR.jsx} +3 -16
  18. package/dist/chunk/{UGKLUHKU.js → A4HLKXDW.js} +8 -11
  19. package/dist/chunk/{3LRXHWW2.js → A6LAAZDX.js} +32 -27
  20. package/dist/chunk/{LVPQ6GR4.js → AIQ2GVFX.js} +6 -7
  21. package/dist/chunk/{JVXNYKNA.js → ANDTZLCB.js} +8 -10
  22. package/dist/chunk/{5O4RWSWO.jsx → BPYAMTER.jsx} +6 -4
  23. package/dist/chunk/{AIQFNVCU.jsx → BTPWLTJU.jsx} +9 -18
  24. package/dist/chunk/{22UQ4DZC.js → C4WAO4VB.js} +9 -10
  25. package/dist/chunk/{2W32Z6JZ.js → DBAO7VQW.js} +9 -10
  26. package/dist/chunk/{5SRZ3YYC.js → DEA5DIWS.js} +7 -8
  27. package/dist/chunk/{SUVE6C6L.jsx → DH5DKFFF.jsx} +17 -35
  28. package/dist/chunk/{TMUQ6SLE.jsx → DS2MX7YY.jsx} +8 -11
  29. package/dist/chunk/{34OZO53S.js → DVI7TRLG.js} +9 -12
  30. package/dist/chunk/{AWO62YTJ.js → E2TLJMGI.js} +15 -17
  31. package/dist/chunk/{H4RSHLA7.jsx → EH5LPBSV.jsx} +9 -13
  32. package/dist/chunk/{F3QPTRGW.jsx → EIGYBOW2.jsx} +27 -34
  33. package/dist/chunk/{HU7FZMJI.jsx → ENXUS2WG.jsx} +9 -14
  34. package/dist/chunk/{NDY7YFV2.js → EUXWRO3A.js} +16 -17
  35. package/dist/chunk/{K54W24N6.jsx → FHWNUAQM.jsx} +10 -15
  36. package/dist/chunk/{MJNR43Q5.js → FX6TOMB3.js} +14 -25
  37. package/dist/chunk/{DUYGPLFV.js → GUQTNAZU.js} +9 -10
  38. package/dist/chunk/{B7LE23PE.jsx → H5QZC4VW.jsx} +9 -13
  39. package/dist/chunk/{NK4T7LIZ.jsx → H7SWP54F.jsx} +7 -11
  40. package/dist/chunk/{M2FICVVI.js → HQEG6EKY.js} +9 -11
  41. package/dist/chunk/{U3XJZI3X.jsx → I4VF53LH.jsx} +15 -25
  42. package/dist/chunk/{FDN5MSFM.js → JOWPVE6E.js} +8 -9
  43. package/dist/chunk/{SN5TXTB6.jsx → JZ7ZQZT4.jsx} +17 -54
  44. package/dist/chunk/{632HFNZF.js → KMFRZGLF.js} +36 -15
  45. package/dist/chunk/{GZVCPLKK.jsx → KQ4BIFPS.jsx} +9 -10
  46. package/dist/chunk/{XCNALQF7.js → LFWIA7VB.js} +11 -14
  47. package/dist/chunk/{7BGOIKYK.jsx → LKOJO4VB.jsx} +17 -31
  48. package/dist/chunk/{5XD5ZSBX.js → M2C67TPA.js} +13 -17
  49. package/dist/chunk/{2GATVLPK.js → M63JXHU4.js} +7 -8
  50. package/dist/chunk/MOG4V2NQ.jsx +15 -0
  51. package/dist/chunk/{XUVXUPEH.js → MZD7ZKWI.js} +2 -7
  52. package/dist/chunk/{YCYZZGN2.jsx → NCURFCYQ.jsx} +9 -8
  53. package/dist/chunk/{5ONYCKM3.jsx → NEBB7COJ.jsx} +1 -1
  54. package/dist/chunk/{Q7NPTAJI.js → NNZQ2FQW.js} +8 -9
  55. package/dist/chunk/{FS3LMJ37.jsx → O5AHG7DQ.jsx} +16 -19
  56. package/dist/chunk/{6YQ3EF2J.js → O62NKGT4.js} +9 -11
  57. package/dist/chunk/{2J42A7KM.js → OA5UZFKE.js} +2 -2
  58. package/dist/chunk/{CPMYIT5J.jsx → OAH52ZNM.jsx} +11 -12
  59. package/dist/chunk/OAPCRIL5.js +8 -0
  60. package/dist/chunk/{T4NRAKVA.jsx → OEZAIQU2.jsx} +9 -10
  61. package/dist/chunk/{YV5BACLX.js → OIGKROX4.js} +9 -9
  62. package/dist/chunk/{IQJBNZOX.jsx → PES3MXH3.jsx} +8 -6
  63. package/dist/chunk/{3V3HI6QW.js → PJNGX4UT.js} +9 -8
  64. package/dist/chunk/{3HMZSTYX.js → PL4PGQFF.js} +8 -10
  65. package/dist/chunk/{RH2PDRKN.jsx → POFK2TVP.jsx} +8 -9
  66. package/dist/chunk/{HWL7X2QR.jsx → PVOFTEOB.jsx} +21 -40
  67. package/dist/chunk/{HPDOBQ3V.js → QEMQBM6W.js} +1 -1
  68. package/dist/chunk/{L7OSYHVR.js → QFAL6GWC.js} +1 -1
  69. package/dist/chunk/{QA6ZMN5Y.js → QKFZ3XTM.js} +14 -28
  70. package/dist/chunk/{IZC6PKGT.jsx → QZQUUXCF.jsx} +10 -14
  71. package/dist/chunk/{DUDD2T7G.js → R6Q7TUSQ.js} +8 -11
  72. package/dist/chunk/{3QQZKR3F.jsx → RCXMZN3G.jsx} +1 -1
  73. package/dist/chunk/{N73ADPX5.jsx → RG3IJESS.jsx} +46 -78
  74. package/dist/chunk/{SWUA2VFC.js → SAI3RCJY.js} +7 -10
  75. package/dist/chunk/{ZC6KWJ4T.jsx → SBKJA5N2.jsx} +7 -12
  76. package/dist/chunk/{RZBYC7DR.jsx → SBLZHOW2.jsx} +3 -12
  77. package/dist/chunk/SDD2HKR3.js +71 -0
  78. package/dist/chunk/{WIVXL7HJ.jsx → SL2ZPLSH.jsx} +9 -13
  79. package/dist/chunk/{XTV6ZFAA.js → SRPSYZUL.js} +7 -8
  80. package/dist/chunk/{DOPROT6M.jsx → SWZSXMPJ.jsx} +10 -8
  81. package/dist/chunk/{BY62F4IV.jsx → TEZHN26Z.jsx} +8 -11
  82. package/dist/chunk/{5EVN6V64.js → TMTD3AUG.js} +12 -15
  83. package/dist/chunk/{I5UG2QUO.js → TROPIN4C.js} +1 -7
  84. package/dist/chunk/{NMGUCD2L.jsx → TVCIHLER.jsx} +2 -11
  85. package/dist/chunk/{5CYHETDY.js → UIAQFG6P.js} +7 -7
  86. package/dist/chunk/{2NEVBQW4.jsx → USV2CYTP.jsx} +9 -9
  87. package/dist/chunk/{GXWVYON6.js → V2YBSJKS.js} +8 -10
  88. package/dist/chunk/{WQQVH7YG.jsx → VLUE7XIS.jsx} +34 -19
  89. package/dist/chunk/{TC2QHQ47.jsx → WPEIDU6T.jsx} +17 -42
  90. package/dist/chunk/{LCESUDZB.js → WRLQ7Y6E.js} +5 -13
  91. package/dist/chunk/{7KPVYYFT.js → WT3OTYHP.js} +27 -11
  92. package/dist/chunk/{IOTZAUDA.jsx → WUTUKX4C.jsx} +1 -1
  93. package/dist/chunk/{34JAVC2R.jsx → WZ7FNJXM.jsx} +11 -15
  94. package/dist/chunk/X34KVQNW.js +1 -1
  95. package/dist/chunk/{MSHQY44G.jsx → XHA6B6L2.jsx} +23 -23
  96. package/dist/chunk/{CQN5S4C3.jsx → XNZ7GOP4.jsx} +15 -24
  97. package/dist/chunk/{MYMGOYXH.js → XR4WJDUT.js} +2 -2
  98. package/dist/chunk/{SJSLQDBZ.jsx → YE6V66JY.jsx} +10 -18
  99. package/dist/chunk/{W43X4SNE.js → YS6KIHEB.js} +6 -6
  100. package/dist/chunk/{FVMQXW27.jsx → ZOMTU4P2.jsx} +12 -22
  101. package/dist/components/accordion/index.d.ts +2 -7
  102. package/dist/components/accordion/index.js +1 -1
  103. package/dist/components/accordion/index.jsx +7 -8
  104. package/dist/components/avatar/index.d.ts +2 -2
  105. package/dist/components/avatar/index.js +1 -1
  106. package/dist/components/avatar/index.jsx +5 -6
  107. package/dist/components/carousel/index.d.ts +3 -8
  108. package/dist/components/carousel/index.js +1 -1
  109. package/dist/components/carousel/index.jsx +5 -6
  110. package/dist/components/checkbox/index.d.ts +3 -8
  111. package/dist/components/checkbox/index.js +1 -1
  112. package/dist/components/checkbox/index.jsx +8 -9
  113. package/dist/components/clipboard/index.d.ts +2 -2
  114. package/dist/components/clipboard/index.js +1 -1
  115. package/dist/components/clipboard/index.jsx +5 -6
  116. package/dist/components/collapsible/index.d.ts +2 -7
  117. package/dist/components/collapsible/index.js +1 -1
  118. package/dist/components/collapsible/index.jsx +6 -7
  119. package/dist/components/collection.d.ts +3 -3
  120. package/dist/components/collection.js +1 -1
  121. package/dist/components/collection.jsx +1 -1
  122. package/dist/components/color-picker/index.d.ts +4 -14
  123. package/dist/components/color-picker/index.js +1 -1
  124. package/dist/components/color-picker/index.jsx +10 -10
  125. package/dist/components/combobox/index.d.ts +3 -13
  126. package/dist/components/combobox/index.js +2 -2
  127. package/dist/components/combobox/index.jsx +12 -12
  128. package/dist/components/date-picker/index.d.ts +8 -20
  129. package/dist/components/date-picker/index.js +1 -1
  130. package/dist/components/date-picker/index.jsx +7 -8
  131. package/dist/components/dialog/index.d.ts +3 -8
  132. package/dist/components/dialog/index.js +1 -1
  133. package/dist/components/dialog/index.jsx +7 -8
  134. package/dist/components/editable/index.d.ts +2 -12
  135. package/dist/components/editable/index.js +1 -1
  136. package/dist/components/editable/index.jsx +8 -8
  137. package/dist/components/field/index.d.ts +3 -2
  138. package/dist/components/field/index.js +1 -1
  139. package/dist/components/field/index.jsx +4 -3
  140. package/dist/components/fieldset/index.d.ts +2 -2
  141. package/dist/components/fieldset/index.js +1 -1
  142. package/dist/components/fieldset/index.jsx +2 -2
  143. package/dist/components/file-upload/index.d.ts +6 -6
  144. package/dist/components/file-upload/index.js +1 -1
  145. package/dist/components/file-upload/index.jsx +8 -8
  146. package/dist/components/focus-trap/index.d.ts +1 -1
  147. package/dist/components/format/index.js +1 -1
  148. package/dist/components/format/index.jsx +4 -5
  149. package/dist/components/frame/index.js +1 -1
  150. package/dist/components/frame/index.jsx +4 -5
  151. package/dist/components/hover-card/index.d.ts +3 -8
  152. package/dist/components/hover-card/index.js +1 -1
  153. package/dist/components/hover-card/index.jsx +7 -8
  154. package/dist/components/index.d.ts +2 -1
  155. package/dist/components/index.js +45 -45
  156. package/dist/components/index.jsx +325 -327
  157. package/dist/components/menu/index.d.ts +4 -9
  158. package/dist/components/menu/index.js +1 -1
  159. package/dist/components/menu/index.jsx +7 -8
  160. package/dist/components/number-input/index.d.ts +2 -7
  161. package/dist/components/number-input/index.js +1 -1
  162. package/dist/components/number-input/index.jsx +8 -8
  163. package/dist/components/pagination/index.d.ts +2 -7
  164. package/dist/components/pagination/index.js +1 -1
  165. package/dist/components/pagination/index.jsx +5 -6
  166. package/dist/components/pin-input/index.d.ts +2 -7
  167. package/dist/components/pin-input/index.js +1 -1
  168. package/dist/components/pin-input/index.jsx +8 -8
  169. package/dist/components/popover/index.d.ts +3 -8
  170. package/dist/components/popover/index.js +1 -1
  171. package/dist/components/popover/index.jsx +7 -8
  172. package/dist/components/presence/index.d.ts +2 -2
  173. package/dist/components/presence/index.js +1 -1
  174. package/dist/components/presence/index.jsx +3 -3
  175. package/dist/components/progress/index.d.ts +2 -7
  176. package/dist/components/progress/index.js +1 -1
  177. package/dist/components/progress/index.jsx +5 -6
  178. package/dist/components/qr-code/index.d.ts +2 -7
  179. package/dist/components/qr-code/index.js +1 -1
  180. package/dist/components/qr-code/index.jsx +5 -6
  181. package/dist/components/radio-group/index.d.ts +2 -7
  182. package/dist/components/radio-group/index.js +1 -1
  183. package/dist/components/radio-group/index.jsx +5 -6
  184. package/dist/components/rating-group/index.d.ts +5 -10
  185. package/dist/components/rating-group/index.js +1 -1
  186. package/dist/components/rating-group/index.jsx +8 -8
  187. package/dist/components/segment-group/index.d.ts +3 -8
  188. package/dist/components/segment-group/index.js +1 -1
  189. package/dist/components/segment-group/index.jsx +5 -6
  190. package/dist/components/select/index.d.ts +3 -13
  191. package/dist/components/select/index.js +2 -2
  192. package/dist/components/select/index.jsx +12 -12
  193. package/dist/components/signature-pad/index.d.ts +2 -2
  194. package/dist/components/signature-pad/index.js +1 -1
  195. package/dist/components/signature-pad/index.jsx +8 -8
  196. package/dist/components/slider/index.d.ts +3 -8
  197. package/dist/components/slider/index.js +1 -1
  198. package/dist/components/slider/index.jsx +5 -6
  199. package/dist/components/splitter/index.d.ts +3 -8
  200. package/dist/components/splitter/index.js +1 -1
  201. package/dist/components/splitter/index.jsx +5 -6
  202. package/dist/components/steps/index.d.ts +6 -10
  203. package/dist/components/steps/index.js +1 -1
  204. package/dist/components/steps/index.jsx +5 -6
  205. package/dist/components/switch/index.d.ts +2 -7
  206. package/dist/components/switch/index.js +1 -1
  207. package/dist/components/switch/index.jsx +8 -8
  208. package/dist/components/tabs/index.d.ts +2 -7
  209. package/dist/components/tabs/index.js +1 -1
  210. package/dist/components/tabs/index.jsx +7 -8
  211. package/dist/components/tags-input/index.d.ts +2 -7
  212. package/dist/components/tags-input/index.js +1 -1
  213. package/dist/components/tags-input/index.jsx +8 -8
  214. package/dist/components/time-picker/index.d.ts +3 -13
  215. package/dist/components/time-picker/index.js +1 -1
  216. package/dist/components/time-picker/index.jsx +7 -8
  217. package/dist/components/timer/index.d.ts +2 -2
  218. package/dist/components/timer/index.js +1 -1
  219. package/dist/components/timer/index.jsx +5 -6
  220. package/dist/components/toast/index.d.ts +6 -7
  221. package/dist/components/toast/index.js +1 -1
  222. package/dist/components/toast/index.jsx +5 -2
  223. package/dist/components/toggle/index.d.ts +5 -34
  224. package/dist/components/toggle/index.js +1 -1
  225. package/dist/components/toggle/index.jsx +2 -4
  226. package/dist/components/toggle-group/index.d.ts +3 -8
  227. package/dist/components/toggle-group/index.js +1 -1
  228. package/dist/components/toggle-group/index.jsx +5 -6
  229. package/dist/components/tooltip/index.d.ts +3 -8
  230. package/dist/components/tooltip/index.js +1 -1
  231. package/dist/components/tooltip/index.jsx +7 -8
  232. package/dist/components/tour/index.d.ts +6 -6
  233. package/dist/components/tour/index.js +1 -1
  234. package/dist/components/tour/index.jsx +7 -8
  235. package/dist/components/tree-view/index.d.ts +6 -16
  236. package/dist/components/tree-view/index.js +2 -2
  237. package/dist/components/tree-view/index.jsx +9 -10
  238. package/dist/index.d.ts +2 -1
  239. package/dist/index.js +47 -47
  240. package/dist/index.jsx +325 -327
  241. package/dist/providers/environment/index.js +1 -1
  242. package/dist/providers/environment/index.jsx +2 -3
  243. package/dist/providers/index.js +2 -2
  244. package/dist/providers/index.jsx +3 -4
  245. package/dist/providers/locale/index.js +1 -1
  246. package/dist/providers/locale/index.jsx +2 -2
  247. package/dist/{use-presence-Ct1onT3-.d.ts → use-presence-C07V_WCb.d.ts} +1 -1
  248. package/package.json +76 -83
  249. package/dist/chunk/52WUF3CY.jsx +0 -26
  250. package/dist/chunk/BSPFGETO.js +0 -21
  251. package/dist/chunk/CTTG4GSG.js +0 -30
  252. package/dist/chunk/DT73WLR4.js +0 -5
  253. package/dist/chunk/JHG4EID2.jsx +0 -233
  254. package/dist/chunk/KGOB2IMX.jsx +0 -7
  255. package/dist/chunk/MV3KTL7M.js +0 -107
@@ -1,14 +1,14 @@
1
- import { useFieldContext } from './632HFNZF.js';
1
+ import { useFieldContext } from './KMFRZGLF.js';
2
2
  import { createSplitProps } from './ZMHI4GDJ.js';
3
3
  import { ark } from './EPLBB4QN.js';
4
- import { useEnvironmentContext } from './QODB3C3M.js';
5
- import { useLocaleContext } from './HPDOBQ3V.js';
6
- import { createContext } from './I5UG2QUO.js';
4
+ import { useEnvironmentContext } from './6MQ6S5JP.js';
5
+ import { useLocaleContext } from './QEMQBM6W.js';
6
+ import { createContext } from './TROPIN4C.js';
7
7
  import { __export } from './ESLJRKWD.js';
8
8
  import { createComponent, mergeProps as mergeProps$1 } from 'solid-js/web';
9
9
  import { mergeProps, useMachine, normalizeProps } from '@zag-js/solid';
10
10
  import { createMemo, createUniqueId } from 'solid-js';
11
- import * as rating from '@zag-js/rating-group';
11
+ import * as ratingGroup from '@zag-js/rating-group';
12
12
  export { anatomy } from '@zag-js/rating-group';
13
13
 
14
14
  // src/components/rating-group/use-rating-group-context.ts
@@ -20,13 +20,13 @@ var [RatingGroupProvider, useRatingGroupContext] = createContext({
20
20
  // src/components/rating-group/rating-group-context.tsx
21
21
  var RatingGroupContext = (props) => props.children(useRatingGroupContext());
22
22
  var RatingGroupControl = (props) => {
23
- const ratingGroup = useRatingGroupContext();
24
- const mergedProps = mergeProps(() => ratingGroup().getControlProps(), props);
23
+ const ratingGroup2 = useRatingGroupContext();
24
+ const mergedProps = mergeProps(() => ratingGroup2().getControlProps(), props);
25
25
  return createComponent(ark.div, mergedProps);
26
26
  };
27
27
  var RatingGroupHiddenInput = (props) => {
28
- const ratingGroup = useRatingGroupContext();
29
- const mergedProps = mergeProps(() => ratingGroup().getHiddenInputProps(), props);
28
+ const ratingGroup2 = useRatingGroupContext();
29
+ const mergedProps = mergeProps(() => ratingGroup2().getHiddenInputProps(), props);
30
30
  const field = useFieldContext();
31
31
  return createComponent(ark.input, mergeProps$1({
32
32
  get ["aria-describedby"]() {
@@ -63,11 +63,11 @@ var RatingGroupLabel = (props) => {
63
63
  return createComponent(ark.label, mergedProps);
64
64
  };
65
65
  var useRatingGroup = (props = {}) => {
66
+ const id = createUniqueId();
66
67
  const locale = useLocaleContext();
67
68
  const environment = useEnvironmentContext();
68
- const id = createUniqueId();
69
69
  const field = useFieldContext();
70
- const context = createMemo(() => ({
70
+ const machineProps = createMemo(() => ({
71
71
  id,
72
72
  ids: {
73
73
  label: field?.().ids.label,
@@ -78,11 +78,10 @@ var useRatingGroup = (props = {}) => {
78
78
  required: field?.().required,
79
79
  dir: locale().dir,
80
80
  getRootNode: environment().getRootNode,
81
- value: props.defaultValue,
82
81
  ...props
83
82
  }));
84
- const [state, send] = useMachine(rating.machine(context()), { context });
85
- return createMemo(() => rating.connect(state, send, normalizeProps));
83
+ const service = useMachine(ratingGroup.machine, machineProps);
84
+ return createMemo(() => ratingGroup.connect(service, normalizeProps));
86
85
  };
87
86
 
88
87
  // src/components/rating-group/rating-group-root.tsx
@@ -99,11 +98,11 @@ var RatingGroupRoot = (props) => {
99
98
  };
100
99
  var RatingGroupRootProvider = (props) => {
101
100
  const [{
102
- value: ratingGroup
101
+ value: ratingGroup2
103
102
  }, localProps] = createSplitProps()(props, ["value"]);
104
- const mergedProps = mergeProps(() => ratingGroup().getRootProps(), localProps);
103
+ const mergedProps = mergeProps(() => ratingGroup2().getRootProps(), localProps);
105
104
  return createComponent(RatingGroupProvider, {
106
- value: ratingGroup,
105
+ value: ratingGroup2,
107
106
  get children() {
108
107
  return createComponent(ark.div, mergedProps);
109
108
  }
@@ -3,7 +3,7 @@ import {
3
3
  splitPresenceProps,
4
4
  usePresence,
5
5
  usePresenceContext
6
- } from "./E72NMPSK.jsx";
6
+ } from "./2FYSIKNK.jsx";
7
7
  import {
8
8
  createSplitProps
9
9
  } from "./6WEDGJKQ.jsx";
@@ -12,13 +12,13 @@ import {
12
12
  } from "./UFYZ7HLU.jsx";
13
13
  import {
14
14
  useEnvironmentContext
15
- } from "./5O4RWSWO.jsx";
15
+ } from "./BPYAMTER.jsx";
16
16
  import {
17
17
  useLocaleContext
18
- } from "./3QQZKR3F.jsx";
18
+ } from "./RCXMZN3G.jsx";
19
19
  import {
20
20
  createContext
21
- } from "./NMGUCD2L.jsx";
21
+ } from "./TVCIHLER.jsx";
22
22
  import {
23
23
  __export
24
24
  } from "./7IUG3E2V.jsx";
@@ -138,20 +138,18 @@ import { normalizeProps, useMachine } from "@zag-js/solid";
138
138
  import * as timePicker from "@zag-js/time-picker";
139
139
  import { createMemo, createUniqueId } from "solid-js";
140
140
  var useTimePicker = (props = {}) => {
141
+ const id = createUniqueId();
141
142
  const locale = useLocaleContext();
142
143
  const environment = useEnvironmentContext();
143
- const id = createUniqueId();
144
- const context = createMemo(() => ({
144
+ const machineProps = createMemo(() => ({
145
145
  id,
146
146
  dir: locale().dir,
147
147
  getRootNode: environment().getRootNode,
148
- open: props.defaultOpen,
149
- "open.controlled": props.open !== void 0,
150
- value: props.defaultValue,
148
+ locale: locale().locale,
151
149
  ...props
152
150
  }));
153
- const [state, send] = useMachine(timePicker.machine(context()), { context });
154
- return createMemo(() => timePicker.connect(state, send, normalizeProps));
151
+ const service = useMachine(timePicker.machine, machineProps);
152
+ return createMemo(() => timePicker.connect(service, normalizeProps));
155
153
  };
156
154
 
157
155
  // src/components/time-picker/time-picker-root.tsx
@@ -193,10 +191,7 @@ var TimePickerRoot = (props) => {
193
191
  import { mergeProps as mergeProps10 } from "@zag-js/solid";
194
192
  var TimePickerRootProvider = (props) => {
195
193
  const [presenceProps, timePickerProps] = splitPresenceProps(props);
196
- const [{ value: timePicker2 }, localProps] = createSplitProps()(
197
- timePickerProps,
198
- ["value"]
199
- );
194
+ const [{ value: timePicker2 }, localProps] = createSplitProps()(timePickerProps, ["value"]);
200
195
  const apiPresence = usePresence(mergeProps10(presenceProps, () => ({ present: timePicker2().open })));
201
196
  const mergedProps = mergeProps10(() => timePicker2().getRootProps(), localProps);
202
197
  return <TimePickerProvider value={timePicker2}>
@@ -1,14 +1,14 @@
1
- import { useFieldContext } from './632HFNZF.js';
2
- import { usePresenceContext, splitPresenceProps, usePresence, PresenceProvider } from './LCESUDZB.js';
1
+ import { useFieldContext } from './KMFRZGLF.js';
2
+ import { splitPresenceProps, usePresence, PresenceProvider, usePresenceContext } from './WRLQ7Y6E.js';
3
3
  import { createSplitProps } from './ZMHI4GDJ.js';
4
4
  import { ark } from './EPLBB4QN.js';
5
- import { useEnvironmentContext } from './QODB3C3M.js';
6
- import { useLocaleContext } from './HPDOBQ3V.js';
7
- import { createContext } from './I5UG2QUO.js';
5
+ import { useEnvironmentContext } from './6MQ6S5JP.js';
6
+ import { useLocaleContext } from './QEMQBM6W.js';
7
+ import { createContext } from './TROPIN4C.js';
8
8
  import { __export } from './ESLJRKWD.js';
9
- import { createComponent, mergeProps as mergeProps$1, effect, template } from 'solid-js/web';
9
+ import { createComponent, mergeProps as mergeProps$1, template, insert, effect } from 'solid-js/web';
10
10
  import { mergeProps, useMachine, normalizeProps } from '@zag-js/solid';
11
- import { Show, createMemo, Index, createUniqueId, splitProps, createEffect } from 'solid-js';
11
+ import { Show, createUniqueId, createMemo, Index } from 'solid-js';
12
12
  import * as select from '@zag-js/select';
13
13
  export { anatomy } from '@zag-js/select';
14
14
 
@@ -45,7 +45,7 @@ var SelectControl = (props) => {
45
45
  const mergedProps = mergeProps(() => select2().getControlProps(), props);
46
46
  return createComponent(ark.div, mergedProps);
47
47
  };
48
- var _tmpl$ = /* @__PURE__ */ template(`<option value="">`);
48
+ var _tmpl$ = /* @__PURE__ */ template(`<option value>`);
49
49
  var _tmpl$2 = /* @__PURE__ */ template(`<option>`);
50
50
  var SelectHiddenSelect = (props) => {
51
51
  const select2 = useSelectContext();
@@ -71,6 +71,7 @@ var SelectHiddenSelect = (props) => {
71
71
  },
72
72
  children: (item) => (() => {
73
73
  var _el$2 = _tmpl$2();
74
+ insert(_el$2, () => select2().collection.stringifyItem(item()));
74
75
  effect(() => _el$2.disabled = select2().collection.getItemDisabled(item()));
75
76
  effect(() => _el$2.value = select2().collection.getItemValue(item()) ?? "");
76
77
  return _el$2;
@@ -184,11 +185,11 @@ var SelectPositioner = (props) => {
184
185
  });
185
186
  };
186
187
  var useSelect = (props) => {
188
+ const id = createUniqueId();
187
189
  const locale = useLocaleContext();
188
190
  const environment = useEnvironmentContext();
189
- const id = createUniqueId();
190
191
  const field = useFieldContext();
191
- const initialContext = createMemo(() => ({
192
+ const machineProps = createMemo(() => ({
192
193
  id,
193
194
  ids: {
194
195
  label: field?.().ids.label,
@@ -200,28 +201,16 @@ var useSelect = (props) => {
200
201
  required: field?.().required,
201
202
  dir: locale().dir,
202
203
  getRootNode: environment().getRootNode,
203
- open: props.defaultOpen,
204
- value: props.defaultValue,
205
- "open.controlled": props.open !== void 0,
206
204
  ...props
207
205
  }));
208
- const context = createMemo(() => {
209
- const [, restProps] = splitProps(initialContext(), ["collection"]);
210
- return restProps;
211
- });
212
- const [state, send, service] = useMachine(select.machine(initialContext()), {
213
- context
214
- });
215
- createEffect(() => {
216
- service.setContext({ collection: props.collection });
217
- });
218
- return createMemo(() => select.connect(state, send, normalizeProps));
206
+ const service = useMachine(select.machine, machineProps);
207
+ return createMemo(() => select.connect(service, normalizeProps));
219
208
  };
220
209
 
221
210
  // src/components/select/select-root.tsx
222
211
  var SelectRoot = (props) => {
223
212
  const [presenceProps, selectProps] = splitPresenceProps(props);
224
- const [useSelectProps, localProps] = createSplitProps()(selectProps, ["closeOnSelect", "composite", "collection", "defaultOpen", "defaultValue", "deselectable", "disabled", "form", "highlightedValue", "id", "ids", "invalid", "loopFocus", "multiple", "name", "onFocusOutside", "onHighlightChange", "onInteractOutside", "onOpenChange", "onPointerDownOutside", "onValueChange", "open", "positioning", "readOnly", "required", "scrollToIndexFn", "value"]);
213
+ const [useSelectProps, localProps] = createSplitProps()(selectProps, ["closeOnSelect", "collection", "composite", "defaultHighlightedValue", "defaultOpen", "defaultValue", "deselectable", "disabled", "form", "highlightedValue", "id", "ids", "invalid", "loopFocus", "multiple", "name", "onFocusOutside", "onHighlightChange", "onInteractOutside", "onOpenChange", "onPointerDownOutside", "onValueChange", "open", "positioning", "readOnly", "required", "scrollToIndexFn", "value"]);
225
214
  const select2 = useSelect(useSelectProps);
226
215
  const presenceApi = usePresence(mergeProps(() => ({
227
216
  present: select2().open
@@ -1,9 +1,9 @@
1
- import { useFieldContext } from './632HFNZF.js';
1
+ import { useFieldContext } from './KMFRZGLF.js';
2
2
  import { createSplitProps } from './ZMHI4GDJ.js';
3
3
  import { ark } from './EPLBB4QN.js';
4
- import { useEnvironmentContext } from './QODB3C3M.js';
5
- import { useLocaleContext } from './HPDOBQ3V.js';
6
- import { createContext } from './I5UG2QUO.js';
4
+ import { useEnvironmentContext } from './6MQ6S5JP.js';
5
+ import { useLocaleContext } from './QEMQBM6W.js';
6
+ import { createContext } from './TROPIN4C.js';
7
7
  import { __export } from './ESLJRKWD.js';
8
8
  import { createComponent, mergeProps as mergeProps$1 } from 'solid-js/web';
9
9
  import { mergeProps, useMachine, normalizeProps } from '@zag-js/solid';
@@ -110,11 +110,11 @@ var TagsInputLabel = (props) => {
110
110
  return createComponent(ark.label, mergedProps);
111
111
  };
112
112
  var useTagsInput = (props = {}) => {
113
+ const id = createUniqueId();
113
114
  const locale = useLocaleContext();
114
115
  const environment = useEnvironmentContext();
115
- const id = createUniqueId();
116
116
  const field = useFieldContext();
117
- const context = createMemo(() => ({
117
+ const machineProps = createMemo(() => ({
118
118
  id,
119
119
  ids: {
120
120
  label: field?.().ids.label,
@@ -126,16 +126,15 @@ var useTagsInput = (props = {}) => {
126
126
  readOnly: field?.().readOnly,
127
127
  required: field?.().required,
128
128
  getRootNode: environment().getRootNode,
129
- value: props.defaultValue,
130
129
  ...props
131
130
  }));
132
- const [state, send] = useMachine(tagsInput.machine(context()), { context });
133
- return createMemo(() => tagsInput.connect(state, send, normalizeProps));
131
+ const service = useMachine(tagsInput.machine, machineProps);
132
+ return createMemo(() => tagsInput.connect(service, normalizeProps));
134
133
  };
135
134
 
136
135
  // src/components/tags-input/tags-input-root.tsx
137
136
  var TagsInputRoot = (props) => {
138
- const [useTagsInputProps, localProps] = createSplitProps()(props, ["addOnPaste", "allowOverflow", "autoFocus", "blurBehavior", "delimiter", "defaultValue", "disabled", "editable", "form", "id", "ids", "inputValue", "invalid", "max", "maxLength", "name", "onFocusOutside", "onHighlightChange", "onInputValueChange", "onInteractOutside", "onPointerDownOutside", "onValueChange", "onValueInvalid", "readOnly", "required", "translations", "validate", "value"]);
137
+ const [useTagsInputProps, localProps] = createSplitProps()(props, ["addOnPaste", "allowOverflow", "autoFocus", "blurBehavior", "defaultInputValue", "defaultValue", "delimiter", "disabled", "editable", "form", "id", "ids", "inputValue", "invalid", "max", "maxLength", "name", "onFocusOutside", "onHighlightChange", "onInputValueChange", "onInteractOutside", "onPointerDownOutside", "onValueChange", "onValueInvalid", "readOnly", "required", "translations", "validate", "value"]);
139
138
  const api = useTagsInput(useTagsInputProps);
140
139
  const mergedProps = mergeProps(() => api().getRootProps(), localProps);
141
140
  return createComponent(TagsInputProvider, {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  splitRenderStrategyProps
3
- } from "./5ONYCKM3.jsx";
3
+ } from "./NEBB7COJ.jsx";
4
4
  import {
5
5
  createSplitProps
6
6
  } from "./6WEDGJKQ.jsx";
@@ -9,13 +9,13 @@ import {
9
9
  } from "./UFYZ7HLU.jsx";
10
10
  import {
11
11
  useEnvironmentContext
12
- } from "./5O4RWSWO.jsx";
12
+ } from "./BPYAMTER.jsx";
13
13
  import {
14
14
  useLocaleContext
15
- } from "./3QQZKR3F.jsx";
15
+ } from "./RCXMZN3G.jsx";
16
16
  import {
17
17
  createContext
18
- } from "./NMGUCD2L.jsx";
18
+ } from "./TVCIHLER.jsx";
19
19
  import {
20
20
  __export
21
21
  } from "./7IUG3E2V.jsx";
@@ -50,25 +50,23 @@ import * as collapsible from "@zag-js/collapsible";
50
50
  import { normalizeProps, useMachine } from "@zag-js/solid";
51
51
  import { createEffect, createMemo, createSignal, createUniqueId } from "solid-js";
52
52
  var useCollapsible = (props = {}) => {
53
+ const id = createUniqueId();
53
54
  const locale = useLocaleContext();
54
55
  const environment = useEnvironmentContext();
55
56
  const [renderStrategyProps, collapsibleProps] = splitRenderStrategyProps(props);
56
- const id = createUniqueId();
57
- const context = createMemo(() => ({
57
+ const machineProps = createMemo(() => ({
58
58
  id,
59
59
  dir: locale().dir,
60
60
  getRootNode: environment().getRootNode,
61
- open: props.defaultOpen,
62
- "open.controlled": props.open !== void 0,
63
61
  ...collapsibleProps
64
62
  }));
65
- const [state, send] = useMachine(collapsible.machine(context()), { context });
63
+ const service = useMachine(collapsible.machine, machineProps);
66
64
  const [wasVisible, setWasVisible] = createSignal(false);
67
65
  createEffect(() => {
68
66
  const isPresent = api().visible;
69
67
  if (isPresent) setWasVisible(true);
70
68
  });
71
- const api = createMemo(() => collapsible.connect(state, send, normalizeProps));
69
+ const api = createMemo(() => collapsible.connect(service, normalizeProps));
72
70
  return createMemo(() => ({
73
71
  ...api(),
74
72
  unmounted: !api().visible && !wasVisible() && renderStrategyProps.lazyMount || renderStrategyProps.unmountOnExit && !api().visible && wasVisible()
@@ -98,9 +96,7 @@ var CollapsibleRoot = (props) => {
98
96
  // src/components/collapsible/collapsible-root-provider.tsx
99
97
  import { mergeProps as mergeProps3 } from "@zag-js/solid";
100
98
  var CollapsibleRootProvider = (props) => {
101
- const [{ value: collapsible2 }, localProps] = createSplitProps()(props, [
102
- "value"
103
- ]);
99
+ const [{ value: collapsible2 }, localProps] = createSplitProps()(props, ["value"]);
104
100
  const mergedProps = mergeProps3(() => collapsible2().getRootProps(), localProps);
105
101
  return <CollapsibleProvider value={collapsible2}>
106
102
  <ark.div {...mergedProps} />
@@ -6,13 +6,13 @@ import {
6
6
  } from "./UFYZ7HLU.jsx";
7
7
  import {
8
8
  useEnvironmentContext
9
- } from "./5O4RWSWO.jsx";
9
+ } from "./BPYAMTER.jsx";
10
10
  import {
11
11
  useLocaleContext
12
- } from "./3QQZKR3F.jsx";
12
+ } from "./RCXMZN3G.jsx";
13
13
  import {
14
14
  createContext
15
- } from "./NMGUCD2L.jsx";
15
+ } from "./TVCIHLER.jsx";
16
16
  import {
17
17
  __export
18
18
  } from "./7IUG3E2V.jsx";
@@ -53,23 +53,19 @@ var useAvatar = (props = {}) => {
53
53
  const locale = useLocaleContext();
54
54
  const environment = useEnvironmentContext();
55
55
  const id = createUniqueId();
56
- const context = createMemo(() => ({
56
+ const machineProps = createMemo(() => ({
57
57
  id,
58
58
  dir: locale().dir,
59
59
  getRootNode: environment().getRootNode,
60
60
  ...props
61
61
  }));
62
- const [state, send] = useMachine(avatar.machine(context()), { context });
63
- return createMemo(() => avatar.connect(state, send, normalizeProps));
62
+ const service = useMachine(avatar.machine, machineProps);
63
+ return createMemo(() => avatar.connect(service, normalizeProps));
64
64
  };
65
65
 
66
66
  // src/components/avatar/avatar-root.tsx
67
67
  var AvatarRoot = (props) => {
68
- const [useAvatarProps, localProps] = createSplitProps()(props, [
69
- "id",
70
- "ids",
71
- "onStatusChange"
72
- ]);
68
+ const [useAvatarProps, localProps] = createSplitProps()(props, ["id", "ids", "onStatusChange"]);
73
69
  const context = useAvatar(useAvatarProps);
74
70
  const mergedProps = mergeProps3(() => context().getRootProps(), localProps);
75
71
  return <AvatarProvider value={context}>
@@ -1,9 +1,9 @@
1
- import { usePresenceContext, splitPresenceProps, usePresence, PresenceProvider } from './LCESUDZB.js';
1
+ import { splitPresenceProps, usePresence, PresenceProvider, usePresenceContext } from './WRLQ7Y6E.js';
2
2
  import { createSplitProps } from './ZMHI4GDJ.js';
3
3
  import { ark } from './EPLBB4QN.js';
4
- import { useEnvironmentContext } from './QODB3C3M.js';
5
- import { useLocaleContext } from './HPDOBQ3V.js';
6
- import { createContext } from './I5UG2QUO.js';
4
+ import { useEnvironmentContext } from './6MQ6S5JP.js';
5
+ import { useLocaleContext } from './QEMQBM6W.js';
6
+ import { createContext } from './TROPIN4C.js';
7
7
  import { __export } from './ESLJRKWD.js';
8
8
  export { parseTime } from '@internationalized/date';
9
9
  import { createComponent } from 'solid-js/web';
@@ -99,20 +99,18 @@ var TimePickerPositioner = (props) => {
99
99
  });
100
100
  };
101
101
  var useTimePicker = (props = {}) => {
102
+ const id = createUniqueId();
102
103
  const locale = useLocaleContext();
103
104
  const environment = useEnvironmentContext();
104
- const id = createUniqueId();
105
- const context = createMemo(() => ({
105
+ const machineProps = createMemo(() => ({
106
106
  id,
107
107
  dir: locale().dir,
108
108
  getRootNode: environment().getRootNode,
109
- open: props.defaultOpen,
110
- "open.controlled": props.open !== void 0,
111
- value: props.defaultValue,
109
+ locale: locale().locale,
112
110
  ...props
113
111
  }));
114
- const [state, send] = useMachine(timePicker.machine(context()), { context });
115
- return createMemo(() => timePicker.connect(state, send, normalizeProps));
112
+ const service = useMachine(timePicker.machine, machineProps);
113
+ return createMemo(() => timePicker.connect(service, normalizeProps));
116
114
  };
117
115
 
118
116
  // src/components/time-picker/time-picker-root.tsx
@@ -1,11 +1,11 @@
1
1
  import {
2
2
  collapsible_exports
3
- } from "./B7LE23PE.jsx";
3
+ } from "./H5QZC4VW.jsx";
4
4
  import {
5
5
  RenderStrategyProvider,
6
6
  splitRenderStrategyProps,
7
7
  useRenderStrategyContext
8
- } from "./5ONYCKM3.jsx";
8
+ } from "./NEBB7COJ.jsx";
9
9
  import {
10
10
  createSplitProps
11
11
  } from "./6WEDGJKQ.jsx";
@@ -14,13 +14,13 @@ import {
14
14
  } from "./UFYZ7HLU.jsx";
15
15
  import {
16
16
  useEnvironmentContext
17
- } from "./5O4RWSWO.jsx";
17
+ } from "./BPYAMTER.jsx";
18
18
  import {
19
19
  useLocaleContext
20
- } from "./3QQZKR3F.jsx";
20
+ } from "./RCXMZN3G.jsx";
21
21
  import {
22
22
  createContext
23
- } from "./NMGUCD2L.jsx";
23
+ } from "./TVCIHLER.jsx";
24
24
  import {
25
25
  __export
26
26
  } from "./7IUG3E2V.jsx";
@@ -66,10 +66,7 @@ var TreeViewBranchContent = (props) => {
66
66
  const nodeProps = useTreeViewNodePropsContext();
67
67
  const branchContentProps = createMemo2(() => {
68
68
  const contentProps = treeView2().getBranchContentProps(nodeProps);
69
- const [, ownProps] = splitVisibilityProps(contentProps, [
70
- "hidden",
71
- "data-state"
72
- ]);
69
+ const [, ownProps] = splitVisibilityProps(contentProps, ["hidden", "data-state"]);
73
70
  return ownProps;
74
71
  });
75
72
  const mergedProps = mergeProps2(() => branchContentProps(), props);
@@ -160,12 +157,10 @@ var TreeViewLabel = (props) => {
160
157
  };
161
158
 
162
159
  // src/components/tree-view/use-tree-view-node-context.ts
163
- var [TreeViewNodeProvider, useTreeViewNodeContext] = createContext(
164
- {
165
- hookName: "useTreeViewNodeContext",
166
- providerName: "<TreeViewNodeProvider />"
167
- }
168
- );
160
+ var [TreeViewNodeProvider, useTreeViewNodeContext] = createContext({
161
+ hookName: "useTreeViewNodeContext",
162
+ providerName: "<TreeViewNodeProvider />"
163
+ });
169
164
 
170
165
  // src/components/tree-view/tree-view-node-context.ts
171
166
  var TreeViewNodeContext = (props) => props.children(useTreeViewNodeContext());
@@ -184,19 +179,17 @@ import { normalizeProps, useMachine } from "@zag-js/solid";
184
179
  import * as treeView from "@zag-js/tree-view";
185
180
  import { createMemo as createMemo3, createUniqueId } from "solid-js";
186
181
  var useTreeView = (props) => {
182
+ const id = createUniqueId();
187
183
  const locale = useLocaleContext();
188
184
  const environment = useEnvironmentContext();
189
- const id = createUniqueId();
190
- const context = createMemo3(() => ({
185
+ const machineProps = createMemo3(() => ({
191
186
  id,
192
187
  dir: locale().dir,
193
188
  getRootNode: environment().getRootNode,
194
- selectedValue: props.defaultSelectedValue,
195
- expandedValue: props.defaultExpandedValue,
196
189
  ...props
197
190
  }));
198
- const [state, send] = useMachine(treeView.machine(context()), { context });
199
- return createMemo3(() => treeView.connect(state, send, normalizeProps));
191
+ const service = useMachine(treeView.machine, machineProps);
192
+ return createMemo3(() => treeView.connect(service, normalizeProps));
200
193
  };
201
194
 
202
195
  // src/components/tree-view/tree-view-root.tsx
@@ -231,10 +224,7 @@ var TreeViewRoot = (props) => {
231
224
  import { mergeProps as mergeProps13 } from "@zag-js/solid";
232
225
  var TreeViewRootProvider = (props) => {
233
226
  const [renderStrategyProps, treeViewProps] = splitRenderStrategyProps(props);
234
- const [{ value: treeView2 }, localProps] = createSplitProps()(
235
- treeViewProps,
236
- ["value"]
237
- );
227
+ const [{ value: treeView2 }, localProps] = createSplitProps()(treeViewProps, ["value"]);
238
228
  const mergedProps = mergeProps13(() => treeView2().getRootProps(), localProps);
239
229
  return <TreeViewProvider value={treeView2}>
240
230
  <RenderStrategyProvider value={renderStrategyProps}>
@@ -1,9 +1,9 @@
1
- import { useFieldContext } from './632HFNZF.js';
1
+ import { useFieldContext } from './KMFRZGLF.js';
2
2
  import { createSplitProps } from './ZMHI4GDJ.js';
3
3
  import { ark } from './EPLBB4QN.js';
4
- import { useEnvironmentContext } from './QODB3C3M.js';
5
- import { useLocaleContext } from './HPDOBQ3V.js';
6
- import { createContext } from './I5UG2QUO.js';
4
+ import { useEnvironmentContext } from './6MQ6S5JP.js';
5
+ import { useLocaleContext } from './QEMQBM6W.js';
6
+ import { createContext } from './TROPIN4C.js';
7
7
  import { __export } from './ESLJRKWD.js';
8
8
  import { createComponent, mergeProps as mergeProps$1 } from 'solid-js/web';
9
9
  import { mergeProps, useMachine, normalizeProps } from '@zag-js/solid';
@@ -40,11 +40,11 @@ var SwitchLabel = (props) => {
40
40
  return createComponent(ark.span, mergedProps);
41
41
  };
42
42
  var useSwitch = (props = {}) => {
43
+ const id = createUniqueId();
43
44
  const locale = useLocaleContext();
44
45
  const environment = useEnvironmentContext();
45
- const id = createUniqueId();
46
46
  const field = useFieldContext();
47
- const context = createMemo(() => ({
47
+ const machineProps = createMemo(() => ({
48
48
  id,
49
49
  ids: {
50
50
  label: field?.().ids.label,
@@ -56,11 +56,10 @@ var useSwitch = (props = {}) => {
56
56
  required: field?.().required,
57
57
  dir: locale().dir,
58
58
  getRootNode: environment().getRootNode,
59
- checked: props.defaultChecked,
60
59
  ...props
61
60
  }));
62
- const [state, send] = useMachine(zagSwitch.machine(context()), { context });
63
- return createMemo(() => zagSwitch.connect(state, send, normalizeProps));
61
+ const service = useMachine(zagSwitch.machine, machineProps);
62
+ return createMemo(() => zagSwitch.connect(service, normalizeProps));
64
63
  };
65
64
 
66
65
  // src/components/switch/switch-root.tsx