@sprawlify/primitives 0.0.52 → 0.0.54

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 (222) hide show
  1. package/dist/{aria-hidden-CEBzyx-2.mjs → aria-hidden-CVIz-P9c.mjs} +1 -1
  2. package/dist/{aria-hidden-CZ_i-44_.cjs → aria-hidden-kcYiyWLo.cjs} +1 -1
  3. package/dist/aria-hidden.cjs +2 -2
  4. package/dist/aria-hidden.mjs +2 -2
  5. package/dist/{auto-resize-CzaVlUmQ.cjs → auto-resize-C55IrFLZ.cjs} +1 -1
  6. package/dist/{auto-resize-BVL59TP4.mjs → auto-resize-R0jCGBHZ.mjs} +1 -1
  7. package/dist/auto-resize.cjs +2 -2
  8. package/dist/auto-resize.mjs +2 -2
  9. package/dist/{core-NCx2blZX.cjs → core-CsVTCpQ_.cjs} +1 -1
  10. package/dist/{core-BjksCLhs.mjs → core-CujC6Y2H.mjs} +1 -1
  11. package/dist/core.cjs +2 -2
  12. package/dist/core.mjs +2 -2
  13. package/dist/date-utils.d.mts +1 -1
  14. package/dist/{dismissable-B3hx8STR.mjs → dismissable-CtFpYFBY.mjs} +2 -2
  15. package/dist/{dismissable-BADVbumR.cjs → dismissable-DWJdIOtX.cjs} +2 -2
  16. package/dist/dismissable.cjs +3 -3
  17. package/dist/dismissable.mjs +3 -3
  18. package/dist/{dom-query-BwpPRIas.mjs → dom-query-CUb85Z22.mjs} +5 -5
  19. package/dist/{dom-query-ClqjTSZC.cjs → dom-query-xZuxOsD4.cjs} +5 -5
  20. package/dist/dom-query.cjs +1 -1
  21. package/dist/dom-query.mjs +1 -1
  22. package/dist/{focus-trap-CH_5ucTD.cjs → focus-trap-DcDcihd5.cjs} +1 -1
  23. package/dist/{focus-trap-CbwLeNp4.mjs → focus-trap-KZbY4M-m.mjs} +1 -1
  24. package/dist/focus-trap.cjs +2 -2
  25. package/dist/focus-trap.mjs +2 -2
  26. package/dist/{focus-visible-3pja4Mga.mjs → focus-visible-Bm2uoacD.mjs} +1 -1
  27. package/dist/{focus-visible-BbOZu8QU.cjs → focus-visible-Ddho9PEA.cjs} +1 -1
  28. package/dist/focus-visible.cjs +2 -2
  29. package/dist/focus-visible.mjs +2 -2
  30. package/dist/{i18n-utils-CSCl08Vd.mjs → i18n-utils-85PCPQ3H.mjs} +1 -1
  31. package/dist/{i18n-utils-D9RUw2tK.cjs → i18n-utils-B3KjZ58Q.cjs} +1 -1
  32. package/dist/i18n-utils.cjs +2 -2
  33. package/dist/i18n-utils.mjs +2 -2
  34. package/dist/{index-BTi1wETB.d.mts → index-60_Ru8qp.d.mts} +1 -1
  35. package/dist/{index-ExuT65LJ.d.mts → index-BqhWpjZh.d.mts} +5 -5
  36. package/dist/{interact-outside-D28zeFXP.cjs → interact-outside-xGMuVVaa.cjs} +1 -1
  37. package/dist/{interact-outside-C0yB--HG.mjs → interact-outside-xKQjln5u.mjs} +1 -1
  38. package/dist/interact-outside.cjs +2 -2
  39. package/dist/interact-outside.mjs +2 -2
  40. package/dist/machines/accordion/index.cjs +2 -2
  41. package/dist/machines/accordion/index.mjs +2 -2
  42. package/dist/machines/angle-slider/index.cjs +2 -2
  43. package/dist/machines/angle-slider/index.d.cts +1 -1
  44. package/dist/machines/angle-slider/index.d.mts +1 -1
  45. package/dist/machines/angle-slider/index.mjs +2 -2
  46. package/dist/machines/async-list/index.cjs +2 -2
  47. package/dist/machines/async-list/index.mjs +2 -2
  48. package/dist/machines/avatar/index.cjs +2 -2
  49. package/dist/machines/avatar/index.mjs +2 -2
  50. package/dist/machines/bottom-sheet/index.cjs +7 -7
  51. package/dist/machines/bottom-sheet/index.d.cts +1 -1
  52. package/dist/machines/bottom-sheet/index.d.mts +1 -1
  53. package/dist/machines/bottom-sheet/index.mjs +7 -7
  54. package/dist/machines/carousel/index.cjs +3 -3
  55. package/dist/machines/carousel/index.d.cts +1 -1
  56. package/dist/machines/carousel/index.d.mts +1 -1
  57. package/dist/machines/carousel/index.mjs +3 -3
  58. package/dist/machines/checkbox/index.cjs +3 -3
  59. package/dist/machines/checkbox/index.d.cts +1 -1
  60. package/dist/machines/checkbox/index.d.mts +1 -1
  61. package/dist/machines/checkbox/index.mjs +3 -3
  62. package/dist/machines/clipboard/index.cjs +2 -2
  63. package/dist/machines/clipboard/index.d.cts +1 -1
  64. package/dist/machines/clipboard/index.d.mts +1 -1
  65. package/dist/machines/clipboard/index.mjs +2 -2
  66. package/dist/machines/collapsible/index.cjs +2 -2
  67. package/dist/machines/collapsible/index.d.cts +1 -1
  68. package/dist/machines/collapsible/index.d.mts +1 -1
  69. package/dist/machines/collapsible/index.mjs +2 -2
  70. package/dist/machines/color-picker/index.cjs +5 -5
  71. package/dist/machines/color-picker/index.d.cts +1 -1
  72. package/dist/machines/color-picker/index.d.mts +2 -2
  73. package/dist/machines/color-picker/index.mjs +5 -5
  74. package/dist/machines/combobox/index.cjs +5 -5
  75. package/dist/machines/combobox/index.d.cts +1 -1
  76. package/dist/machines/combobox/index.d.mts +2 -2
  77. package/dist/machines/combobox/index.mjs +5 -5
  78. package/dist/machines/date-picker/index.cjs +5 -5
  79. package/dist/machines/date-picker/index.d.cts +1 -1
  80. package/dist/machines/date-picker/index.d.mts +3 -3
  81. package/dist/machines/date-picker/index.mjs +5 -5
  82. package/dist/machines/dialog/index.cjs +7 -7
  83. package/dist/machines/dialog/index.d.cts +1 -1
  84. package/dist/machines/dialog/index.d.mts +1 -1
  85. package/dist/machines/dialog/index.mjs +7 -7
  86. package/dist/machines/editable/index.cjs +3 -3
  87. package/dist/machines/editable/index.mjs +3 -3
  88. package/dist/machines/file-upload/index.cjs +3 -3
  89. package/dist/machines/file-upload/index.d.cts +1 -1
  90. package/dist/machines/file-upload/index.d.mts +1 -1
  91. package/dist/machines/file-upload/index.mjs +3 -3
  92. package/dist/machines/floating-panel/index.cjs +2 -2
  93. package/dist/machines/floating-panel/index.d.cts +1 -1
  94. package/dist/machines/floating-panel/index.d.mts +1 -1
  95. package/dist/machines/floating-panel/index.mjs +2 -2
  96. package/dist/machines/hover-card/index.cjs +5 -5
  97. package/dist/machines/hover-card/index.d.cts +1 -1
  98. package/dist/machines/hover-card/index.d.mts +2 -2
  99. package/dist/machines/hover-card/index.mjs +5 -5
  100. package/dist/machines/image-cropper/index.cjs +2 -2
  101. package/dist/machines/image-cropper/index.mjs +2 -2
  102. package/dist/machines/listbox/index.cjs +3 -3
  103. package/dist/machines/listbox/index.d.cts +1 -1
  104. package/dist/machines/listbox/index.d.mts +1 -1
  105. package/dist/machines/listbox/index.mjs +3 -3
  106. package/dist/machines/marquee/index.cjs +2 -2
  107. package/dist/machines/marquee/index.d.cts +3 -3
  108. package/dist/machines/marquee/index.d.mts +3 -3
  109. package/dist/machines/marquee/index.mjs +2 -2
  110. package/dist/machines/menu/index.cjs +5 -5
  111. package/dist/machines/menu/index.d.cts +1 -1
  112. package/dist/machines/menu/index.d.mts +2 -2
  113. package/dist/machines/menu/index.mjs +5 -5
  114. package/dist/machines/navigation-menu/index.cjs +4 -4
  115. package/dist/machines/navigation-menu/index.d.cts +1 -1
  116. package/dist/machines/navigation-menu/index.d.mts +1 -1
  117. package/dist/machines/navigation-menu/index.mjs +4 -4
  118. package/dist/machines/number-input/index.cjs +17 -9
  119. package/dist/machines/number-input/index.d.cts +1 -1
  120. package/dist/machines/number-input/index.d.mts +1 -1
  121. package/dist/machines/number-input/index.mjs +17 -9
  122. package/dist/machines/pagination/index.cjs +2 -2
  123. package/dist/machines/pagination/index.d.cts +1 -1
  124. package/dist/machines/pagination/index.d.mts +1 -1
  125. package/dist/machines/pagination/index.mjs +2 -2
  126. package/dist/machines/password-input/index.cjs +2 -2
  127. package/dist/machines/password-input/index.d.cts +1 -1
  128. package/dist/machines/password-input/index.d.mts +1 -1
  129. package/dist/machines/password-input/index.mjs +2 -2
  130. package/dist/machines/pin-input/index.cjs +2 -2
  131. package/dist/machines/pin-input/index.mjs +2 -2
  132. package/dist/machines/popover/index.cjs +8 -8
  133. package/dist/machines/popover/index.d.cts +1 -1
  134. package/dist/machines/popover/index.d.mts +2 -2
  135. package/dist/machines/popover/index.mjs +8 -8
  136. package/dist/machines/presence/index.cjs +2 -2
  137. package/dist/machines/presence/index.mjs +2 -2
  138. package/dist/machines/progress/index.cjs +2 -2
  139. package/dist/machines/progress/index.d.cts +1 -1
  140. package/dist/machines/progress/index.d.mts +1 -1
  141. package/dist/machines/progress/index.mjs +2 -2
  142. package/dist/machines/qr-code/index.cjs +2 -2
  143. package/dist/machines/qr-code/index.mjs +2 -2
  144. package/dist/machines/radio-group/index.cjs +3 -3
  145. package/dist/machines/radio-group/index.d.cts +1 -1
  146. package/dist/machines/radio-group/index.d.mts +1 -1
  147. package/dist/machines/radio-group/index.mjs +3 -3
  148. package/dist/machines/rating-group/index.cjs +2 -2
  149. package/dist/machines/rating-group/index.mjs +2 -2
  150. package/dist/machines/scroll-area/index.cjs +2 -2
  151. package/dist/machines/scroll-area/index.d.cts +1 -1
  152. package/dist/machines/scroll-area/index.d.mts +1 -1
  153. package/dist/machines/scroll-area/index.mjs +2 -2
  154. package/dist/machines/select/index.cjs +5 -5
  155. package/dist/machines/select/index.d.cts +1 -1
  156. package/dist/machines/select/index.d.mts +2 -2
  157. package/dist/machines/select/index.mjs +5 -5
  158. package/dist/machines/signature-pad/index.cjs +2 -2
  159. package/dist/machines/signature-pad/index.d.cts +1 -1
  160. package/dist/machines/signature-pad/index.d.mts +1 -1
  161. package/dist/machines/signature-pad/index.mjs +2 -2
  162. package/dist/machines/slider/index.cjs +2 -2
  163. package/dist/machines/slider/index.d.cts +1 -1
  164. package/dist/machines/slider/index.d.mts +1 -1
  165. package/dist/machines/slider/index.mjs +2 -2
  166. package/dist/machines/splitter/index.cjs +2 -2
  167. package/dist/machines/splitter/index.d.cts +1 -1
  168. package/dist/machines/splitter/index.d.mts +1 -1
  169. package/dist/machines/splitter/index.mjs +2 -2
  170. package/dist/machines/steps/index.cjs +71 -25
  171. package/dist/machines/steps/index.d.cts +14 -2
  172. package/dist/machines/steps/index.d.mts +14 -2
  173. package/dist/machines/steps/index.mjs +71 -25
  174. package/dist/machines/switch/index.cjs +3 -3
  175. package/dist/machines/switch/index.d.cts +1 -1
  176. package/dist/machines/switch/index.d.mts +1 -1
  177. package/dist/machines/switch/index.mjs +3 -3
  178. package/dist/machines/tabs/index.cjs +2 -2
  179. package/dist/machines/tabs/index.d.cts +1 -1
  180. package/dist/machines/tabs/index.d.mts +1 -1
  181. package/dist/machines/tabs/index.mjs +2 -2
  182. package/dist/machines/tags-input/index.cjs +4 -4
  183. package/dist/machines/tags-input/index.d.cts +1 -1
  184. package/dist/machines/tags-input/index.d.mts +1 -1
  185. package/dist/machines/tags-input/index.mjs +4 -4
  186. package/dist/machines/timer/index.cjs +2 -2
  187. package/dist/machines/timer/index.d.cts +1 -1
  188. package/dist/machines/timer/index.d.mts +1 -1
  189. package/dist/machines/timer/index.mjs +2 -2
  190. package/dist/machines/toast/index.cjs +4 -4
  191. package/dist/machines/toast/index.d.cts +1 -1
  192. package/dist/machines/toast/index.d.mts +1 -1
  193. package/dist/machines/toast/index.mjs +4 -4
  194. package/dist/machines/toggle/index.cjs +2 -2
  195. package/dist/machines/toggle/index.mjs +2 -2
  196. package/dist/machines/toggle-group/index.cjs +2 -2
  197. package/dist/machines/toggle-group/index.mjs +2 -2
  198. package/dist/machines/tooltip/index.cjs +4 -4
  199. package/dist/machines/tooltip/index.d.cts +1 -1
  200. package/dist/machines/tooltip/index.d.mts +2 -2
  201. package/dist/machines/tooltip/index.mjs +4 -4
  202. package/dist/machines/tour/index.cjs +6 -6
  203. package/dist/machines/tour/index.d.cts +1 -1
  204. package/dist/machines/tour/index.d.mts +2 -2
  205. package/dist/machines/tour/index.mjs +6 -6
  206. package/dist/machines/tree-view/index.cjs +2 -2
  207. package/dist/machines/tree-view/index.d.cts +1 -1
  208. package/dist/machines/tree-view/index.d.mts +1 -1
  209. package/dist/machines/tree-view/index.mjs +2 -2
  210. package/dist/{popper-C6DOG0y6.mjs → popper-DbfXVgrC.mjs} +1 -1
  211. package/dist/{popper-BwFBqHeN.cjs → popper-TNUpC0Kp.cjs} +1 -1
  212. package/dist/popper.cjs +2 -2
  213. package/dist/popper.d.cts +1 -1
  214. package/dist/popper.d.mts +1 -1
  215. package/dist/popper.mjs +2 -2
  216. package/dist/{remove-scroll-w6rI9a_g.cjs → remove-scroll-D5aUrYvL.cjs} +1 -1
  217. package/dist/{remove-scroll-Dj2rN8ST.mjs → remove-scroll-DNoftRvo.mjs} +1 -1
  218. package/dist/{scroll-snap-D2Ao0kC_.cjs → scroll-snap-DhVLyRe-.cjs} +1 -1
  219. package/dist/{scroll-snap-qgiu8AOd.mjs → scroll-snap-tDsdAemJ.mjs} +1 -1
  220. package/dist/scroll-snap.cjs +2 -2
  221. package/dist/scroll-snap.mjs +2 -2
  222. package/package.json +1 -1
@@ -1,7 +1,7 @@
1
1
  const require_create_anatomy = require('../../create-anatomy-CDsIFUXg.cjs');
2
- const require_dom_query = require('../../dom-query-ClqjTSZC.cjs');
2
+ const require_dom_query = require('../../dom-query-xZuxOsD4.cjs');
3
3
  const require_utils = require('../../utils-B4_qn2dt.cjs');
4
- const require_core = require('../../core-NCx2blZX.cjs');
4
+ const require_core = require('../../core-CsVTCpQ_.cjs');
5
5
  const require_create_props = require('../../create-props-l5q5b8Wo.cjs');
6
6
 
7
7
  //#region src/machines/steps/steps.anatomy.ts
@@ -24,6 +24,12 @@ function connect(service, normalize) {
24
24
  const percent = computed("percent");
25
25
  const hasNextStep = computed("hasNextStep");
26
26
  const hasPrevStep = computed("hasPrevStep");
27
+ const isStepValid = (index) => {
28
+ return prop("isStepValid")?.(index) ?? true;
29
+ };
30
+ const isStepSkippable = (index) => {
31
+ return prop("isStepSkippable")?.(index) ?? false;
32
+ };
27
33
  const getItemState = (props$1) => ({
28
34
  triggerId: getTriggerId(scope, props$1.index),
29
35
  contentId: getContentId(scope, props$1.index),
@@ -32,7 +38,9 @@ function connect(service, normalize) {
32
38
  incomplete: props$1.index > step,
33
39
  index: props$1.index,
34
40
  first: props$1.index === 0,
35
- last: props$1.index === count - 1
41
+ last: props$1.index === count - 1,
42
+ skippable: isStepSkippable(props$1.index),
43
+ isValid: () => isStepValid(props$1.index)
36
44
  });
37
45
  const goToNextStep = () => {
38
46
  send({
@@ -66,6 +74,8 @@ function connect(service, normalize) {
66
74
  hasNextStep,
67
75
  hasPrevStep,
68
76
  isCompleted: computed("completed"),
77
+ isStepValid,
78
+ isStepSkippable,
69
79
  goToNextStep,
70
80
  goToPrevStep,
71
81
  resetStep,
@@ -98,7 +108,8 @@ function connect(service, normalize) {
98
108
  ...parts.item.attrs,
99
109
  dir: prop("dir"),
100
110
  "aria-current": itemState.current ? "step" : void 0,
101
- "data-orientation": prop("orientation")
111
+ "data-orientation": prop("orientation"),
112
+ "data-skippable": require_dom_query.dataAttr(itemState.skippable)
102
113
  });
103
114
  },
104
115
  getTriggerProps(props$1) {
@@ -233,34 +244,65 @@ const machine = require_core.createMachine({
233
244
  initialState() {
234
245
  return "idle";
235
246
  },
236
- entry: ["validateStep"],
247
+ entry: ["validateStepIndex"],
237
248
  states: { idle: { on: {
238
- "STEP.SET": { actions: ["setStep"] },
239
- "STEP.NEXT": { actions: ["goToNextStep"] },
249
+ "STEP.SET": [{
250
+ guard: "isValidStepNavigation",
251
+ actions: ["setStep"]
252
+ }, { actions: ["invokeOnStepInvalid"] }],
253
+ "STEP.NEXT": [{
254
+ guard: "isCurrentStepValid",
255
+ actions: ["goToNextStep"]
256
+ }, { actions: ["invokeOnStepInvalid"] }],
240
257
  "STEP.PREV": { actions: ["goToPrevStep"] },
241
258
  "STEP.RESET": { actions: ["resetStep"] }
242
259
  } } },
243
- implementations: { actions: {
244
- goToNextStep({ context, prop }) {
245
- const value = Math.min(context.get("step") + 1, prop("count"));
246
- context.set("step", value);
247
- },
248
- goToPrevStep({ context }) {
249
- const value = Math.max(context.get("step") - 1, 0);
250
- context.set("step", value);
251
- },
252
- resetStep({ context }) {
253
- context.set("step", 0);
254
- },
255
- setStep({ context, event }) {
256
- context.set("step", event.value);
260
+ implementations: {
261
+ guards: {
262
+ isCurrentStepValid({ context, prop }) {
263
+ const current = context.get("step");
264
+ if (prop("isStepSkippable")?.(current)) return true;
265
+ const isStepValid = prop("isStepValid");
266
+ if (!isStepValid) return true;
267
+ return isStepValid(current);
268
+ },
269
+ isValidStepNavigation({ context, event, prop }) {
270
+ const current = context.get("step");
271
+ if (event.value <= current) return true;
272
+ if (prop("isStepSkippable")?.(current)) return true;
273
+ const isStepValid = prop("isStepValid");
274
+ if (!isStepValid) return true;
275
+ return isStepValid(current);
276
+ }
257
277
  },
258
- validateStep({ context, prop }) {
259
- validateStep(prop("count"), context.get("step"));
278
+ actions: {
279
+ goToNextStep({ context, prop }) {
280
+ const count = prop("count");
281
+ context.set("step", Math.min(context.get("step") + 1, count));
282
+ },
283
+ goToPrevStep({ context }) {
284
+ context.set("step", Math.max(context.get("step") - 1, 0));
285
+ },
286
+ resetStep({ context }) {
287
+ context.set("step", 0);
288
+ },
289
+ setStep({ context, event }) {
290
+ context.set("step", event.value);
291
+ },
292
+ validateStepIndex({ context, prop }) {
293
+ validateStepIndex(prop("count"), context.get("step"));
294
+ },
295
+ invokeOnStepInvalid({ context, event, prop }) {
296
+ prop("onStepInvalid")?.({
297
+ step: context.get("step"),
298
+ action: event.type === "STEP.NEXT" ? "next" : "set",
299
+ targetStep: event.value
300
+ });
301
+ }
260
302
  }
261
- } }
303
+ }
262
304
  });
263
- const validateStep = (count, step) => {
305
+ const validateStepIndex = (count, step) => {
264
306
  if (!require_utils.isValueWithinRange(step, 0, count)) throw new RangeError(`[sprawlify-js/steps] step index ${step} is out of bounds`);
265
307
  };
266
308
 
@@ -268,13 +310,17 @@ const validateStep = (count, step) => {
268
310
  //#region src/machines/steps/steps.props.ts
269
311
  const props = require_create_props.createProps()([
270
312
  "count",
313
+ "defaultStep",
271
314
  "dir",
272
315
  "getRootNode",
273
316
  "id",
274
317
  "ids",
318
+ "isStepSkippable",
319
+ "isStepValid",
275
320
  "linear",
276
321
  "onStepChange",
277
322
  "onStepComplete",
323
+ "onStepInvalid",
278
324
  "orientation",
279
325
  "step",
280
326
  "defaultStep"
@@ -3,12 +3,17 @@ import { p as Machine, u as EventObject, y as Service } from "../../types-DejIu6
3
3
  import { b as NormalizeProps, g as RequiredBy, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-Bqw3r34-.cjs";
4
4
 
5
5
  //#region src/machines/steps/steps.anatomy.d.ts
6
- declare const anatomy: AnatomyInstance<"root" | "list" | "trigger" | "content" | "indicator" | "progress" | "item" | "separator" | "prevTrigger" | "nextTrigger">;
6
+ declare const anatomy: AnatomyInstance<"root" | "item" | "indicator" | "nextTrigger" | "prevTrigger" | "progress" | "trigger" | "list" | "content" | "separator">;
7
7
  //#endregion
8
8
  //#region src/machines/steps/steps.types.d.ts
9
9
  interface StepChangeDetails {
10
10
  step: number;
11
11
  }
12
+ interface StepInvalidDetails {
13
+ step: number;
14
+ action: "next" | "set";
15
+ targetStep?: number;
16
+ }
12
17
  interface ElementIds {
13
18
  root?: string | undefined;
14
19
  list?: string | undefined;
@@ -24,6 +29,9 @@ interface StepsProps extends DirectionProperty, CommonProperties {
24
29
  linear?: boolean | undefined;
25
30
  orientation?: "horizontal" | "vertical" | undefined;
26
31
  count?: number | undefined;
32
+ isStepValid?: ((index: number) => boolean) | undefined;
33
+ isStepSkippable?: ((index: number) => boolean) | undefined;
34
+ onStepInvalid?: ((details: StepInvalidDetails) => void) | undefined;
27
35
  }
28
36
  type PropsWithDefault = "orientation" | "linear" | "count";
29
37
  interface PrivateContext {
@@ -59,6 +67,8 @@ interface ItemState {
59
67
  incomplete: boolean;
60
68
  last: boolean;
61
69
  first: boolean;
70
+ skippable: boolean;
71
+ isValid: () => boolean;
62
72
  }
63
73
  interface StepsApi<T extends PropTypes = PropTypes> {
64
74
  value: number;
@@ -67,6 +77,8 @@ interface StepsApi<T extends PropTypes = PropTypes> {
67
77
  hasNextStep: boolean;
68
78
  hasPrevStep: boolean;
69
79
  isCompleted: boolean;
80
+ isStepValid: (index: number) => boolean;
81
+ isStepSkippable: (index: number) => boolean;
70
82
  setStep: (step: number) => void;
71
83
  goToNextStep: VoidFunction;
72
84
  goToPrevStep: VoidFunction;
@@ -94,4 +106,4 @@ declare const machine: Machine<StepsSchema>;
94
106
  declare const props: (keyof StepsProps)[];
95
107
  declare const splitProps: <Props extends Partial<StepsProps>>(props: Props) => [Partial<StepsProps>, Omit<Props, keyof StepsProps>];
96
108
  //#endregion
97
- export { type StepsApi as Api, type ElementIds, type ItemProps, type ItemState, type StepsMachine as Machine, type StepsProps as Props, type StepsService as Service, type StepChangeDetails, anatomy, connect, machine, props, splitProps };
109
+ export { type StepsApi as Api, type ElementIds, type ItemProps, type ItemState, type StepsMachine as Machine, type StepsProps as Props, type StepsService as Service, type StepChangeDetails, type StepInvalidDetails, anatomy, connect, machine, props, splitProps };
@@ -3,12 +3,17 @@ import { p as Machine, u as EventObject, y as Service } from "../../types-DL5AIQ
3
3
  import { b as NormalizeProps, g as RequiredBy, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-BuUzJjaP.mjs";
4
4
 
5
5
  //#region src/machines/steps/steps.anatomy.d.ts
6
- declare const anatomy: AnatomyInstance<"root" | "list" | "trigger" | "content" | "indicator" | "progress" | "item" | "separator" | "prevTrigger" | "nextTrigger">;
6
+ declare const anatomy: AnatomyInstance<"root" | "item" | "indicator" | "nextTrigger" | "prevTrigger" | "progress" | "trigger" | "list" | "content" | "separator">;
7
7
  //#endregion
8
8
  //#region src/machines/steps/steps.types.d.ts
9
9
  interface StepChangeDetails {
10
10
  step: number;
11
11
  }
12
+ interface StepInvalidDetails {
13
+ step: number;
14
+ action: "next" | "set";
15
+ targetStep?: number;
16
+ }
12
17
  interface ElementIds {
13
18
  root?: string | undefined;
14
19
  list?: string | undefined;
@@ -24,6 +29,9 @@ interface StepsProps extends DirectionProperty, CommonProperties {
24
29
  linear?: boolean | undefined;
25
30
  orientation?: "horizontal" | "vertical" | undefined;
26
31
  count?: number | undefined;
32
+ isStepValid?: ((index: number) => boolean) | undefined;
33
+ isStepSkippable?: ((index: number) => boolean) | undefined;
34
+ onStepInvalid?: ((details: StepInvalidDetails) => void) | undefined;
27
35
  }
28
36
  type PropsWithDefault = "orientation" | "linear" | "count";
29
37
  interface PrivateContext {
@@ -59,6 +67,8 @@ interface ItemState {
59
67
  incomplete: boolean;
60
68
  last: boolean;
61
69
  first: boolean;
70
+ skippable: boolean;
71
+ isValid: () => boolean;
62
72
  }
63
73
  interface StepsApi<T extends PropTypes = PropTypes> {
64
74
  value: number;
@@ -67,6 +77,8 @@ interface StepsApi<T extends PropTypes = PropTypes> {
67
77
  hasNextStep: boolean;
68
78
  hasPrevStep: boolean;
69
79
  isCompleted: boolean;
80
+ isStepValid: (index: number) => boolean;
81
+ isStepSkippable: (index: number) => boolean;
70
82
  setStep: (step: number) => void;
71
83
  goToNextStep: VoidFunction;
72
84
  goToPrevStep: VoidFunction;
@@ -94,4 +106,4 @@ declare const machine: Machine<StepsSchema>;
94
106
  declare const props: (keyof StepsProps)[];
95
107
  declare const splitProps: <Props extends Partial<StepsProps>>(props: Props) => [Partial<StepsProps>, Omit<Props, keyof StepsProps>];
96
108
  //#endregion
97
- export { type StepsApi as Api, type ElementIds, type ItemProps, type ItemState, type StepsMachine as Machine, type StepsProps as Props, type StepsService as Service, type StepChangeDetails, anatomy, connect, machine, props, splitProps };
109
+ export { type StepsApi as Api, type ElementIds, type ItemProps, type ItemState, type StepsMachine as Machine, type StepsProps as Props, type StepsService as Service, type StepChangeDetails, type StepInvalidDetails, anatomy, connect, machine, props, splitProps };
@@ -1,7 +1,7 @@
1
1
  import { t as createAnatomy } from "../../create-anatomy-CArN8dVu.mjs";
2
- import { yn as dataAttr } from "../../dom-query-BwpPRIas.mjs";
2
+ import { yn as dataAttr } from "../../dom-query-CUb85Z22.mjs";
3
3
  import { N as isValueWithinRange, bt as fromLength, u as createSplitProps } from "../../utils-DSBXwmDm.mjs";
4
- import { a as createMachine, s as memo } from "../../core-BjksCLhs.mjs";
4
+ import { a as createMachine, s as memo } from "../../core-CujC6Y2H.mjs";
5
5
  import { t as createProps } from "../../create-props-SRSjdUTq.mjs";
6
6
 
7
7
  //#region src/machines/steps/steps.anatomy.ts
@@ -24,6 +24,12 @@ function connect(service, normalize) {
24
24
  const percent = computed("percent");
25
25
  const hasNextStep = computed("hasNextStep");
26
26
  const hasPrevStep = computed("hasPrevStep");
27
+ const isStepValid = (index) => {
28
+ return prop("isStepValid")?.(index) ?? true;
29
+ };
30
+ const isStepSkippable = (index) => {
31
+ return prop("isStepSkippable")?.(index) ?? false;
32
+ };
27
33
  const getItemState = (props$1) => ({
28
34
  triggerId: getTriggerId(scope, props$1.index),
29
35
  contentId: getContentId(scope, props$1.index),
@@ -32,7 +38,9 @@ function connect(service, normalize) {
32
38
  incomplete: props$1.index > step,
33
39
  index: props$1.index,
34
40
  first: props$1.index === 0,
35
- last: props$1.index === count - 1
41
+ last: props$1.index === count - 1,
42
+ skippable: isStepSkippable(props$1.index),
43
+ isValid: () => isStepValid(props$1.index)
36
44
  });
37
45
  const goToNextStep = () => {
38
46
  send({
@@ -66,6 +74,8 @@ function connect(service, normalize) {
66
74
  hasNextStep,
67
75
  hasPrevStep,
68
76
  isCompleted: computed("completed"),
77
+ isStepValid,
78
+ isStepSkippable,
69
79
  goToNextStep,
70
80
  goToPrevStep,
71
81
  resetStep,
@@ -98,7 +108,8 @@ function connect(service, normalize) {
98
108
  ...parts.item.attrs,
99
109
  dir: prop("dir"),
100
110
  "aria-current": itemState.current ? "step" : void 0,
101
- "data-orientation": prop("orientation")
111
+ "data-orientation": prop("orientation"),
112
+ "data-skippable": dataAttr(itemState.skippable)
102
113
  });
103
114
  },
104
115
  getTriggerProps(props$1) {
@@ -233,34 +244,65 @@ const machine = createMachine({
233
244
  initialState() {
234
245
  return "idle";
235
246
  },
236
- entry: ["validateStep"],
247
+ entry: ["validateStepIndex"],
237
248
  states: { idle: { on: {
238
- "STEP.SET": { actions: ["setStep"] },
239
- "STEP.NEXT": { actions: ["goToNextStep"] },
249
+ "STEP.SET": [{
250
+ guard: "isValidStepNavigation",
251
+ actions: ["setStep"]
252
+ }, { actions: ["invokeOnStepInvalid"] }],
253
+ "STEP.NEXT": [{
254
+ guard: "isCurrentStepValid",
255
+ actions: ["goToNextStep"]
256
+ }, { actions: ["invokeOnStepInvalid"] }],
240
257
  "STEP.PREV": { actions: ["goToPrevStep"] },
241
258
  "STEP.RESET": { actions: ["resetStep"] }
242
259
  } } },
243
- implementations: { actions: {
244
- goToNextStep({ context, prop }) {
245
- const value = Math.min(context.get("step") + 1, prop("count"));
246
- context.set("step", value);
247
- },
248
- goToPrevStep({ context }) {
249
- const value = Math.max(context.get("step") - 1, 0);
250
- context.set("step", value);
251
- },
252
- resetStep({ context }) {
253
- context.set("step", 0);
254
- },
255
- setStep({ context, event }) {
256
- context.set("step", event.value);
260
+ implementations: {
261
+ guards: {
262
+ isCurrentStepValid({ context, prop }) {
263
+ const current = context.get("step");
264
+ if (prop("isStepSkippable")?.(current)) return true;
265
+ const isStepValid = prop("isStepValid");
266
+ if (!isStepValid) return true;
267
+ return isStepValid(current);
268
+ },
269
+ isValidStepNavigation({ context, event, prop }) {
270
+ const current = context.get("step");
271
+ if (event.value <= current) return true;
272
+ if (prop("isStepSkippable")?.(current)) return true;
273
+ const isStepValid = prop("isStepValid");
274
+ if (!isStepValid) return true;
275
+ return isStepValid(current);
276
+ }
257
277
  },
258
- validateStep({ context, prop }) {
259
- validateStep(prop("count"), context.get("step"));
278
+ actions: {
279
+ goToNextStep({ context, prop }) {
280
+ const count = prop("count");
281
+ context.set("step", Math.min(context.get("step") + 1, count));
282
+ },
283
+ goToPrevStep({ context }) {
284
+ context.set("step", Math.max(context.get("step") - 1, 0));
285
+ },
286
+ resetStep({ context }) {
287
+ context.set("step", 0);
288
+ },
289
+ setStep({ context, event }) {
290
+ context.set("step", event.value);
291
+ },
292
+ validateStepIndex({ context, prop }) {
293
+ validateStepIndex(prop("count"), context.get("step"));
294
+ },
295
+ invokeOnStepInvalid({ context, event, prop }) {
296
+ prop("onStepInvalid")?.({
297
+ step: context.get("step"),
298
+ action: event.type === "STEP.NEXT" ? "next" : "set",
299
+ targetStep: event.value
300
+ });
301
+ }
260
302
  }
261
- } }
303
+ }
262
304
  });
263
- const validateStep = (count, step) => {
305
+ const validateStepIndex = (count, step) => {
264
306
  if (!isValueWithinRange(step, 0, count)) throw new RangeError(`[sprawlify-js/steps] step index ${step} is out of bounds`);
265
307
  };
266
308
 
@@ -268,13 +310,17 @@ const validateStep = (count, step) => {
268
310
  //#region src/machines/steps/steps.props.ts
269
311
  const props = createProps()([
270
312
  "count",
313
+ "defaultStep",
271
314
  "dir",
272
315
  "getRootNode",
273
316
  "id",
274
317
  "ids",
318
+ "isStepSkippable",
319
+ "isStepValid",
275
320
  "linear",
276
321
  "onStepChange",
277
322
  "onStepComplete",
323
+ "onStepInvalid",
278
324
  "orientation",
279
325
  "step",
280
326
  "defaultStep"
@@ -1,8 +1,8 @@
1
1
  const require_create_anatomy = require('../../create-anatomy-CDsIFUXg.cjs');
2
- const require_dom_query = require('../../dom-query-ClqjTSZC.cjs');
2
+ const require_dom_query = require('../../dom-query-xZuxOsD4.cjs');
3
3
  const require_utils = require('../../utils-B4_qn2dt.cjs');
4
- const require_core = require('../../core-NCx2blZX.cjs');
5
- const require_focus_visible = require('../../focus-visible-BbOZu8QU.cjs');
4
+ const require_core = require('../../core-CsVTCpQ_.cjs');
5
+ const require_focus_visible = require('../../focus-visible-Ddho9PEA.cjs');
6
6
  const require_create_props = require('../../create-props-l5q5b8Wo.cjs');
7
7
 
8
8
  //#region src/machines/switch/switch.anatomy.ts
@@ -3,7 +3,7 @@ import { p as Machine, u as EventObject, y as Service } from "../../types-DejIu6
3
3
  import { b as NormalizeProps, g as RequiredBy, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-Bqw3r34-.cjs";
4
4
 
5
5
  //#region src/machines/switch/switch.anatomy.d.ts
6
- declare const anatomy: AnatomyInstance<"root" | "label" | "thumb" | "control">;
6
+ declare const anatomy: AnatomyInstance<"root" | "label" | "control" | "thumb">;
7
7
  //#endregion
8
8
  //#region src/machines/switch/switch.types.d.ts
9
9
  interface CheckedChangeDetails {
@@ -3,7 +3,7 @@ import { p as Machine, u as EventObject, y as Service } from "../../types-DL5AIQ
3
3
  import { b as NormalizeProps, g as RequiredBy, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-BuUzJjaP.mjs";
4
4
 
5
5
  //#region src/machines/switch/switch.anatomy.d.ts
6
- declare const anatomy: AnatomyInstance<"root" | "label" | "thumb" | "control">;
6
+ declare const anatomy: AnatomyInstance<"root" | "label" | "control" | "thumb">;
7
7
  //#endregion
8
8
  //#region src/machines/switch/switch.types.d.ts
9
9
  interface CheckedChangeDetails {
@@ -1,8 +1,8 @@
1
1
  import { t as createAnatomy } from "../../create-anatomy-CArN8dVu.mjs";
2
- import { T as trackPress, a as visuallyHiddenStyle, at as setElementChecked, pt as getEventTarget, rt as dispatchInputCheckedEvent, st as trackFormControl, yn as dataAttr, zt as isSafari } from "../../dom-query-BwpPRIas.mjs";
2
+ import { T as trackPress, a as visuallyHiddenStyle, at as setElementChecked, pt as getEventTarget, rt as dispatchInputCheckedEvent, st as trackFormControl, yn as dataAttr, zt as isSafari } from "../../dom-query-CUb85Z22.mjs";
3
3
  import { u as createSplitProps } from "../../utils-DSBXwmDm.mjs";
4
- import { a as createMachine, i as createGuards } from "../../core-BjksCLhs.mjs";
5
- import { a as trackFocusVisible, n as isFocusVisible } from "../../focus-visible-3pja4Mga.mjs";
4
+ import { a as createMachine, i as createGuards } from "../../core-CujC6Y2H.mjs";
5
+ import { a as trackFocusVisible, n as isFocusVisible } from "../../focus-visible-Bm2uoacD.mjs";
6
6
  import { t as createProps } from "../../create-props-SRSjdUTq.mjs";
7
7
 
8
8
  //#region src/machines/switch/switch.anatomy.ts
@@ -1,7 +1,7 @@
1
1
  const require_create_anatomy = require('../../create-anatomy-CDsIFUXg.cjs');
2
- const require_dom_query = require('../../dom-query-ClqjTSZC.cjs');
2
+ const require_dom_query = require('../../dom-query-xZuxOsD4.cjs');
3
3
  const require_utils = require('../../utils-B4_qn2dt.cjs');
4
- const require_core = require('../../core-NCx2blZX.cjs');
4
+ const require_core = require('../../core-CsVTCpQ_.cjs');
5
5
  const require_create_props = require('../../create-props-l5q5b8Wo.cjs');
6
6
 
7
7
  //#region src/machines/tabs/tabs.anatomy.ts
@@ -3,7 +3,7 @@ import { p as Machine, u as EventObject, y as Service } from "../../types-DejIu6
3
3
  import { b as NormalizeProps, g as RequiredBy, m as Rect, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-Bqw3r34-.cjs";
4
4
 
5
5
  //#region src/machines/tabs/tabs.anatomy.d.ts
6
- declare const anatomy: AnatomyInstance<"root" | "list" | "trigger" | "content" | "indicator">;
6
+ declare const anatomy: AnatomyInstance<"root" | "indicator" | "trigger" | "list" | "content">;
7
7
  //#endregion
8
8
  //#region src/machines/tabs/tabs.types.d.ts
9
9
  interface ValueChangeDetails {
@@ -3,7 +3,7 @@ import { p as Machine, u as EventObject, y as Service } from "../../types-DL5AIQ
3
3
  import { b as NormalizeProps, g as RequiredBy, m as Rect, r as DirectionProperty, t as CommonProperties, x as PropTypes } from "../../index-BuUzJjaP.mjs";
4
4
 
5
5
  //#region src/machines/tabs/tabs.anatomy.d.ts
6
- declare const anatomy: AnatomyInstance<"root" | "list" | "trigger" | "content" | "indicator">;
6
+ declare const anatomy: AnatomyInstance<"root" | "indicator" | "trigger" | "list" | "content">;
7
7
  //#endregion
8
8
  //#region src/machines/tabs/tabs.types.d.ts
9
9
  interface ValueChangeDetails {
@@ -1,7 +1,7 @@
1
1
  import { t as createAnatomy } from "../../create-anatomy-CArN8dVu.mjs";
2
- import { C as queryAll, L as clickIfLink, St as isOpeningInNewTab, W as raf, Y as getFocusables, Zt as contains, b as nextById, ht as isComposingEvent, m as resizeObserverBorderBox, on as isAnchorElement, pt as getEventTarget, ut as getEventKey, x as prevById, y as itemById, yn as dataAttr, zt as isSafari } from "../../dom-query-BwpPRIas.mjs";
2
+ import { C as queryAll, L as clickIfLink, St as isOpeningInNewTab, W as raf, Y as getFocusables, Zt as contains, b as nextById, ht as isComposingEvent, m as resizeObserverBorderBox, on as isAnchorElement, pt as getEventTarget, ut as getEventKey, x as prevById, y as itemById, yn as dataAttr, zt as isSafari } from "../../dom-query-CUb85Z22.mjs";
3
3
  import { H as toPx, W as callAll, ft as isEqual, u as createSplitProps, vt as first, wt as last } from "../../utils-DSBXwmDm.mjs";
4
- import { o as setup } from "../../core-BjksCLhs.mjs";
4
+ import { o as setup } from "../../core-CujC6Y2H.mjs";
5
5
  import { t as createProps } from "../../create-props-SRSjdUTq.mjs";
6
6
 
7
7
  //#region src/machines/tabs/tabs.anatomy.ts
@@ -1,9 +1,9 @@
1
1
  const require_create_anatomy = require('../../create-anatomy-CDsIFUXg.cjs');
2
- const require_dom_query = require('../../dom-query-ClqjTSZC.cjs');
3
- const require_auto_resize = require('../../auto-resize-CzaVlUmQ.cjs');
2
+ const require_dom_query = require('../../dom-query-xZuxOsD4.cjs');
3
+ const require_auto_resize = require('../../auto-resize-C55IrFLZ.cjs');
4
4
  const require_utils = require('../../utils-B4_qn2dt.cjs');
5
- const require_core = require('../../core-NCx2blZX.cjs');
6
- const require_interact_outside = require('../../interact-outside-D28zeFXP.cjs');
5
+ const require_core = require('../../core-CsVTCpQ_.cjs');
6
+ const require_interact_outside = require('../../interact-outside-xGMuVVaa.cjs');
7
7
  const require_live_region = require('../../live-region-2RiuzOr-.cjs');
8
8
  const require_create_props = require('../../create-props-l5q5b8Wo.cjs');
9
9
 
@@ -5,7 +5,7 @@ import { c as PointerDownOutsideEvent, i as InteractOutsideHandlers, n as FocusO
5
5
  import { t as LiveRegion } from "../../index-Owca7uxB.cjs";
6
6
 
7
7
  //#region src/machines/tags-input/tags-input.anatomy.d.ts
8
- declare const anatomy: AnatomyInstance<"root" | "label" | "control" | "input" | "item" | "itemText" | "clearTrigger" | "itemPreview" | "itemDeleteTrigger" | "itemInput">;
8
+ declare const anatomy: AnatomyInstance<"root" | "label" | "control" | "item" | "itemText" | "input" | "clearTrigger" | "itemPreview" | "itemInput" | "itemDeleteTrigger">;
9
9
  //#endregion
10
10
  //#region src/machines/tags-input/tags-input.types.d.ts
11
11
  interface ValueChangeDetails {
@@ -5,7 +5,7 @@ import { c as PointerDownOutsideEvent, i as InteractOutsideHandlers, n as FocusO
5
5
  import { t as LiveRegion } from "../../index-CygfPLvT.mjs";
6
6
 
7
7
  //#region src/machines/tags-input/tags-input.anatomy.d.ts
8
- declare const anatomy: AnatomyInstance<"root" | "label" | "control" | "input" | "item" | "itemText" | "clearTrigger" | "itemPreview" | "itemDeleteTrigger" | "itemInput">;
8
+ declare const anatomy: AnatomyInstance<"root" | "label" | "control" | "item" | "itemText" | "input" | "clearTrigger" | "itemPreview" | "itemInput" | "itemDeleteTrigger">;
9
9
  //#endregion
10
10
  //#region src/machines/tags-input/tags-input.types.d.ts
11
11
  interface ValueChangeDetails {
@@ -1,9 +1,9 @@
1
1
  import { t as createAnatomy } from "../../create-anatomy-CArN8dVu.mjs";
2
- import { C as queryAll, W as raf, Zt as contains, b as nextById, bn as isCaretAtStart, bt as isLeftClick, ht as isComposingEvent, it as dispatchInputValueEvent, mt as getNativeEvent, ot as setElementValue, st as trackFormControl, ut as getEventKey, v as indexOfId, vn as ariaAttr, x as prevById, yn as dataAttr } from "../../dom-query-BwpPRIas.mjs";
3
- import { n as autoResizeInput } from "../../auto-resize-BVL59TP4.mjs";
2
+ import { C as queryAll, W as raf, Zt as contains, b as nextById, bn as isCaretAtStart, bt as isLeftClick, ht as isComposingEvent, it as dispatchInputValueEvent, mt as getNativeEvent, ot as setElementValue, st as trackFormControl, ut as getEventKey, v as indexOfId, vn as ariaAttr, x as prevById, yn as dataAttr } from "../../dom-query-CUb85Z22.mjs";
3
+ import { n as autoResizeInput } from "../../auto-resize-R0jCGBHZ.mjs";
4
4
  import { Nt as uniq, ft as isEqual, i as warn, jt as removeAt, u as createSplitProps } from "../../utils-DSBXwmDm.mjs";
5
- import { a as createMachine, i as createGuards } from "../../core-BjksCLhs.mjs";
6
- import { t as trackInteractOutside } from "../../interact-outside-C0yB--HG.mjs";
5
+ import { a as createMachine, i as createGuards } from "../../core-CujC6Y2H.mjs";
6
+ import { t as trackInteractOutside } from "../../interact-outside-xKQjln5u.mjs";
7
7
  import { t as createLiveRegion } from "../../live-region-BcSdQIM8.mjs";
8
8
  import { t as createProps } from "../../create-props-SRSjdUTq.mjs";
9
9
 
@@ -1,7 +1,7 @@
1
1
  const require_create_anatomy = require('../../create-anatomy-CDsIFUXg.cjs');
2
- require('../../dom-query-ClqjTSZC.cjs');
2
+ require('../../dom-query-xZuxOsD4.cjs');
3
3
  const require_utils = require('../../utils-B4_qn2dt.cjs');
4
- const require_core = require('../../core-NCx2blZX.cjs');
4
+ const require_core = require('../../core-CsVTCpQ_.cjs');
5
5
  const require_create_props = require('../../create-props-l5q5b8Wo.cjs');
6
6
 
7
7
  //#region src/machines/timer/timer.anatomy.ts
@@ -3,7 +3,7 @@ import { p as Machine, u as EventObject, y as Service } from "../../types-DejIu6
3
3
  import { b as NormalizeProps, g as RequiredBy, t as CommonProperties, x as PropTypes } from "../../index-Bqw3r34-.cjs";
4
4
 
5
5
  //#region src/machines/timer/timer.anatomy.d.ts
6
- declare const anatomy: AnatomyInstance<"root" | "control" | "area" | "item" | "itemLabel" | "itemValue" | "actionTrigger" | "separator">;
6
+ declare const anatomy: AnatomyInstance<"root" | "control" | "item" | "itemLabel" | "area" | "separator" | "actionTrigger" | "itemValue">;
7
7
  //#endregion
8
8
  //#region src/machines/timer/timer.types.d.ts
9
9
  interface Time<T = number> {
@@ -3,7 +3,7 @@ import { p as Machine, u as EventObject, y as Service } from "../../types-DL5AIQ
3
3
  import { b as NormalizeProps, g as RequiredBy, t as CommonProperties, x as PropTypes } from "../../index-BuUzJjaP.mjs";
4
4
 
5
5
  //#region src/machines/timer/timer.anatomy.d.ts
6
- declare const anatomy: AnatomyInstance<"root" | "control" | "area" | "item" | "itemLabel" | "itemValue" | "actionTrigger" | "separator">;
6
+ declare const anatomy: AnatomyInstance<"root" | "control" | "item" | "itemLabel" | "area" | "separator" | "actionTrigger" | "itemValue">;
7
7
  //#endregion
8
8
  //#region src/machines/timer/timer.types.d.ts
9
9
  interface Time<T = number> {
@@ -1,7 +1,7 @@
1
1
  import { t as createAnatomy } from "../../create-anatomy-CArN8dVu.mjs";
2
- import "../../dom-query-BwpPRIas.mjs";
2
+ import "../../dom-query-CUb85Z22.mjs";
3
3
  import { Y as match, ct as isObject, g as clampValue, o as setRafInterval, s as setRafTimeout, u as createSplitProps } from "../../utils-DSBXwmDm.mjs";
4
- import { a as createMachine, s as memo } from "../../core-BjksCLhs.mjs";
4
+ import { a as createMachine, s as memo } from "../../core-CujC6Y2H.mjs";
5
5
  import { t as createProps } from "../../create-props-SRSjdUTq.mjs";
6
6
 
7
7
  //#region src/machines/timer/timer.anatomy.ts
@@ -1,9 +1,9 @@
1
1
  const require_create_anatomy = require('../../create-anatomy-CDsIFUXg.cjs');
2
- const require_dom_query = require('../../dom-query-ClqjTSZC.cjs');
2
+ const require_dom_query = require('../../dom-query-xZuxOsD4.cjs');
3
3
  const require_utils = require('../../utils-B4_qn2dt.cjs');
4
- const require_core = require('../../core-NCx2blZX.cjs');
5
- require('../../interact-outside-D28zeFXP.cjs');
6
- const require_dismissable = require('../../dismissable-BADVbumR.cjs');
4
+ const require_core = require('../../core-CsVTCpQ_.cjs');
5
+ require('../../interact-outside-xGMuVVaa.cjs');
6
+ const require_dismissable = require('../../dismissable-DWJdIOtX.cjs');
7
7
 
8
8
  //#region src/machines/toast/toast.anatomy.ts
9
9
  const anatomy = require_create_anatomy.createAnatomy("toast").parts("group", "root", "title", "description", "actionTrigger", "closeTrigger");
@@ -176,7 +176,7 @@ interface ToastApi<T extends PropTypes = PropTypes, O = any> {
176
176
  declare function groupConnect<T extends PropTypes, O = any>(service: Service<ToastGroupSchema>, normalize: NormalizeProps<T>): ToastGroupApi<T, O>;
177
177
  //#endregion
178
178
  //#region src/machines/toast/toast.anatomy.d.ts
179
- declare const anatomy: AnatomyInstance<"root" | "title" | "actionTrigger" | "group" | "description" | "closeTrigger">;
179
+ declare const anatomy: AnatomyInstance<"root" | "title" | "group" | "description" | "actionTrigger" | "closeTrigger">;
180
180
  //#endregion
181
181
  //#region src/machines/toast/toast.connect.d.ts
182
182
  declare function connect<T extends PropTypes, O>(service: Service<ToastSchema<O>>, normalize: NormalizeProps<T>): ToastApi<T, O>;