@vuetify/v0 0.1.10 → 0.1.11

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 (107) hide show
  1. package/dist/{adapter-CqP9Z4JU.d.mts → adapter-Dv4TFNh9.d.mts} +7 -7
  2. package/dist/browser/index.js +1125 -162
  3. package/dist/components/index.d.mts +2 -2
  4. package/dist/components/index.mjs +19 -19
  5. package/dist/{components-TiigKVsl.mjs → components-Cxi4P1uo.mjs} +1028 -285
  6. package/dist/composables/index.d.mts +12 -12
  7. package/dist/composables/index.mjs +17 -17
  8. package/dist/{consola-C1OjyZVf.d.mts → consola-mE3TUsie.d.mts} +1 -1
  9. package/dist/constants/index.d.mts +1 -1
  10. package/dist/constants/index.mjs +1 -1
  11. package/dist/{createDataTable-DoqbfLt0.mjs → createDataTable-DnaaoU_Q.mjs} +2 -2
  12. package/dist/{createGroup-DpbGTwFy.mjs → createGroup-BgDjEOXE.mjs} +1 -1
  13. package/dist/{createSelection-B6bQNyuF.mjs → createSelection-I3pID-Mh.mjs} +1 -1
  14. package/dist/{createSingle-fWHREEJO.mjs → createSingle-CqX-KXFr.mjs} +1 -1
  15. package/dist/{createTokens-N8QIWw_D.mjs → createTokens-vyh3quuB.mjs} +1 -1
  16. package/dist/data-table/adapters/client/index.mjs +1 -1
  17. package/dist/data-table/adapters/index.mjs +1 -1
  18. package/dist/data-table/adapters/server/index.mjs +1 -1
  19. package/dist/data-table/adapters/virtual/index.mjs +1 -1
  20. package/dist/data-table/index.d.mts +1 -1
  21. package/dist/data-table/index.mjs +10 -10
  22. package/dist/date/index.d.mts +9 -6
  23. package/dist/date/index.mjs +22 -15
  24. package/dist/features/adapters/flagsmith/index.d.mts +1 -13
  25. package/dist/features/adapters/launchdarkly/index.d.mts +1 -12
  26. package/dist/features/adapters/posthog/index.d.mts +1 -12
  27. package/dist/features/adapters/posthog/index.mjs +2 -2
  28. package/dist/features/index.d.mts +2 -2
  29. package/dist/features/index.mjs +8 -8
  30. package/dist/{globals-F7fiJVG1.mjs → globals-TLLuB8XQ.mjs} +1 -1
  31. package/dist/index-BTG8veDR.d.mts +13 -0
  32. package/dist/{index-DXdQb5BV.d.mts → index-Bz8iXBEX.d.mts} +1387 -372
  33. package/dist/index-CDGG7lCB.d.mts +1 -0
  34. package/dist/index-CrqJIYCP.d.mts +13 -0
  35. package/dist/index-D9G_YWS_.d.mts +14 -0
  36. package/dist/{index-Cv1XUHyA.d.mts → index-Dlz-FzrC.d.mts} +20 -1
  37. package/dist/index-LhFpnU-f.d.mts +1 -0
  38. package/dist/{index-Dfa5Wb4T.d.mts → index-bMdAIUKN.d.mts} +44 -11
  39. package/dist/index.d.mts +16 -16
  40. package/dist/index.mjs +20 -20
  41. package/dist/json/attributes.json +193 -1
  42. package/dist/json/importMap.json +52 -0
  43. package/dist/json/tags.json +108 -0
  44. package/dist/json/web-types.json +621 -3
  45. package/dist/locale/adapters/index.d.mts +2 -2
  46. package/dist/locale/adapters/index.mjs +2 -2
  47. package/dist/locale/adapters/v0/index.d.mts +1 -1
  48. package/dist/locale/adapters/v0/index.mjs +2 -2
  49. package/dist/locale/adapters/vue-i18n/index.d.mts +1 -1
  50. package/dist/locale/adapters/vue-i18n/index.mjs +1 -1
  51. package/dist/locale/index.d.mts +3 -3
  52. package/dist/locale/index.mjs +8 -8
  53. package/dist/logger/adapters/consola/index.d.mts +1 -1
  54. package/dist/logger/adapters/index.d.mts +4 -4
  55. package/dist/logger/adapters/index.mjs +2 -2
  56. package/dist/logger/adapters/pino/index.d.mts +1 -1
  57. package/dist/logger/adapters/pino/index.mjs +1 -1
  58. package/dist/logger/adapters/v0/index.d.mts +1 -1
  59. package/dist/logger/adapters/v0/index.mjs +2 -2
  60. package/dist/logger/index.d.mts +5 -5
  61. package/dist/logger/index.mjs +3 -3
  62. package/dist/notifications/index.d.mts +1 -2
  63. package/dist/notifications/index.mjs +1 -1
  64. package/dist/palettes/index.d.mts +1 -2
  65. package/dist/permissions/adapters/index.d.mts +1 -2
  66. package/dist/permissions/adapters/index.mjs +1 -1
  67. package/dist/permissions/adapters/v0/index.d.mts +1 -1
  68. package/dist/permissions/adapters/v0/index.mjs +1 -1
  69. package/dist/permissions/index.d.mts +1 -1
  70. package/dist/permissions/index.mjs +5 -5
  71. package/dist/{pino-CM1iLXmi.d.mts → pino-DUx_ooLa.d.mts} +1 -1
  72. package/dist/{posthog-CdcdfMYS.mjs → posthog-0A_Ageii.mjs} +1 -1
  73. package/dist/rules/index.d.mts +1 -1
  74. package/dist/rules/index.mjs +9 -9
  75. package/dist/storage/adapters/index.d.mts +2 -2
  76. package/dist/storage/adapters/memory/index.d.mts +1 -1
  77. package/dist/storage/index.d.mts +3 -3
  78. package/dist/storage/index.mjs +17 -17
  79. package/dist/theme/adapters/index.d.mts +1 -1
  80. package/dist/theme/adapters/index.mjs +2 -2
  81. package/dist/theme/adapters/v0/index.d.mts +1 -1
  82. package/dist/theme/adapters/v0/index.mjs +2 -2
  83. package/dist/theme/index.d.mts +1 -1
  84. package/dist/theme/index.mjs +8 -8
  85. package/dist/{useClickOutside-DNuJQ9EG.mjs → useClickOutside-R0S58NVr.mjs} +135 -24
  86. package/dist/{useFeatures-CWNXTIXk.mjs → useFeatures-Bn16wSHD.mjs} +3 -3
  87. package/dist/{useLocale-Dzl6lCCF.mjs → useLocale-B8NaQT2b.mjs} +4 -4
  88. package/dist/{useLogger-Bw836Jbg.mjs → useLogger-xp_tiLJ5.mjs} +2 -2
  89. package/dist/{usePermissions-DrRVDeVy.mjs → usePermissions-nkU9OBB8.mjs} +2 -2
  90. package/dist/{useRules-TMGuA8al.mjs → useRules-RkVMgycJ.mjs} +2 -2
  91. package/dist/{useTheme-qMpg3Ti6.mjs → useTheme-QFLbV6tH.mjs} +14 -7
  92. package/dist/utilities/index.d.mts +2 -2
  93. package/dist/utilities/index.mjs +120 -21
  94. package/dist/{v0-CIEQpOK2.mjs → v0-AoEx-7U5.mjs} +8 -3
  95. package/dist/{v0-JPf99NKg.d.mts → v0-BdhPBG_p.d.mts} +1 -1
  96. package/dist/{v0-3zDdS4II.d.mts → v0-CItl0K-e.d.mts} +1 -1
  97. package/dist/{v0-DgaVf3xM.mjs → v0-CkxwC3wm.mjs} +1 -1
  98. package/dist/{v0-BsuBuBSa.mjs → v0-Di7YUWAH.mjs} +1 -1
  99. package/package.json +1 -1
  100. package/dist/v0-BBRwZ3at.d.mts +0 -10
  101. /package/dist/{adapter-D3dUnE__.d.mts → adapter-CN3E66HY.d.mts} +0 -0
  102. /package/dist/{adapter-CJQav2JB.d.mts → adapter-DcJbLnTC.d.mts} +0 -0
  103. /package/dist/{index-BvTD7kU8.d.mts → index-BAHMiB95.d.mts} +0 -0
  104. /package/dist/{index-dJKXAO5D.d.mts → index-BC1S8-8J.d.mts} +0 -0
  105. /package/dist/{index-CLDBngUs.d.mts → index-B_fIwnhR.d.mts} +0 -0
  106. /package/dist/{index-DSao7i57.d.mts → index-DiLStryt.d.mts} +0 -0
  107. /package/dist/{memory-DyBabFV1.d.mts → memory-CDrksYgA.d.mts} +0 -0
@@ -1,14 +1,14 @@
1
- import { a as SUPPORTS_OBSERVER, i as SUPPORTS_MUTATION_OBSERVER, n as SUPPORTS_INTERSECTION_OBSERVER, r as SUPPORTS_MATCH_MEDIA, t as IN_BROWSER } from "./globals-F7fiJVG1.mjs";
1
+ import { a as SUPPORTS_OBSERVER, i as SUPPORTS_MUTATION_OBSERVER, n as SUPPORTS_INTERSECTION_OBSERVER, r as SUPPORTS_MATCH_MEDIA, t as IN_BROWSER } from "./globals-TLLuB8XQ.mjs";
2
2
  import { clamp, instanceExists, isElement, isFunction, isNull, isNullOrUndefined, isNumber, isObject, isString, isUndefined, mergeDeep, useId as useId$1 } from "./utilities/index.mjs";
3
3
  import { i as useContext, n as createContext, t as createTrinity } from "./createTrinity-C_c8eedz.mjs";
4
- import { a as createPlugin, i as useLogger, o as createPluginContext } from "./useLogger-Bw836Jbg.mjs";
5
- import { a as createRegistry } from "./createTokens-N8QIWw_D.mjs";
6
- import { i as createModel, t as createSelection } from "./createSelection-B6bQNyuF.mjs";
7
- import { t as createSingle } from "./createSingle-fWHREEJO.mjs";
8
- import { t as createGroup } from "./createGroup-DpbGTwFy.mjs";
4
+ import { a as createPlugin, i as useLogger, o as createPluginContext } from "./useLogger-xp_tiLJ5.mjs";
5
+ import { a as createRegistry } from "./createTokens-vyh3quuB.mjs";
6
+ import { i as createModel, t as createSelection } from "./createSelection-I3pID-Mh.mjs";
7
+ import { t as createSingle } from "./createSingle-CqX-KXFr.mjs";
8
+ import { t as createGroup } from "./createGroup-BgDjEOXE.mjs";
9
9
  import { t as toArray } from "./toArray-VdROPpy-.mjs";
10
- import { a as useLocale } from "./useLocale-Dzl6lCCF.mjs";
11
- import { a as useRules, o as isStandardSchema } from "./useRules-TMGuA8al.mjs";
10
+ import { a as useLocale } from "./useLocale-B8NaQT2b.mjs";
11
+ import { a as useRules, o as isStandardSchema } from "./useRules-RkVMgycJ.mjs";
12
12
  import { t as MemoryAdapter } from "./memory-XCMtkld1.mjs";
13
13
  import { computed, effectScope, isRef, nextTick, onMounted, onScopeDispose, reactive, readonly, ref, shallowReactive, shallowReadonly, shallowRef, toRef, toValue, unref, watch, watchEffect } from "vue";
14
14
  //#region src/composables/createBreadcrumbs/index.ts
@@ -1298,6 +1298,18 @@ const defaultLocales = {
1298
1298
  ar: "ar-SA"
1299
1299
  };
1300
1300
  /**
1301
+ * Derive firstDayOfWeek from an Intl locale string.
1302
+ * Returns 0-6 (0=Sun) or 0 as fallback.
1303
+ */
1304
+ function deriveFirstDayOfWeek(locale) {
1305
+ try {
1306
+ const info = new Intl.Locale(locale).getWeekInfo?.();
1307
+ return info ? info.firstDay % 7 : 0;
1308
+ } catch {
1309
+ return 0;
1310
+ }
1311
+ }
1312
+ /**
1301
1313
  * Creates a new date context.
1302
1314
  *
1303
1315
  * @param options Adapter and locale configuration.
@@ -1322,7 +1334,7 @@ const defaultLocales = {
1322
1334
  * ```
1323
1335
  */
1324
1336
  function createDate(options) {
1325
- const { locales = defaultLocales, adapter, locale: initialLocale } = options;
1337
+ const { locales = defaultLocales, adapter, locale: initialLocale, firstDayOfWeek: explicitFirstDay } = options;
1326
1338
  let selectedId;
1327
1339
  try {
1328
1340
  if (instanceExists()) selectedId = useLocale().selectedId;
@@ -1336,17 +1348,27 @@ function createDate(options) {
1336
1348
  const fallback = initialLocale ?? adapter.locale ?? "en-US";
1337
1349
  return fallback.includes("-") ? fallback : locales[fallback] ?? fallback;
1338
1350
  });
1351
+ const firstDayOfWeek = computed(() => {
1352
+ if (!/* @__PURE__ */ isUndefined(explicitFirstDay)) return explicitFirstDay;
1353
+ const loc = locale.value;
1354
+ return loc ? deriveFirstDayOfWeek(loc) : 0;
1355
+ });
1339
1356
  if (instanceExists()) onScopeDispose(watchEffect(() => {
1340
1357
  const loc = locale.value;
1341
1358
  if (loc && adapter.locale !== loc) adapter.locale = loc;
1359
+ const fdow = firstDayOfWeek.value;
1360
+ if (adapter.firstDayOfWeek !== fdow) adapter.firstDayOfWeek = fdow;
1342
1361
  }));
1343
1362
  else {
1344
1363
  const loc = locale.value;
1345
1364
  if (loc && adapter.locale !== loc) adapter.locale = loc;
1365
+ const fdow = firstDayOfWeek.value;
1366
+ if (adapter.firstDayOfWeek !== fdow) adapter.firstDayOfWeek = fdow;
1346
1367
  }
1347
1368
  return {
1348
1369
  adapter,
1349
- locale
1370
+ locale,
1371
+ firstDayOfWeek
1350
1372
  };
1351
1373
  }
1352
1374
  /**
@@ -2485,7 +2507,8 @@ const multipleOpenStrategy = {
2485
2507
  */
2486
2508
  const singleOpenStrategy = {
2487
2509
  onOpen: (id, context) => {
2488
- for (const openedId of context.openedIds) if (openedId !== id) context.openedIds.delete(openedId);
2510
+ const toClose = [...context.openedIds].filter((openedId) => openedId !== id);
2511
+ for (const openedId of toClose) context.openedIds.delete(openedId);
2489
2512
  },
2490
2513
  onClose: void 0
2491
2514
  };
@@ -2587,8 +2610,13 @@ function createNested(_options = {}) {
2587
2610
  return openedIds.has(id);
2588
2611
  }
2589
2612
  function open(ids) {
2613
+ if (toValue(group.disabled)) return;
2590
2614
  for (const id of toArray(ids)) {
2591
2615
  if (!group.has(id)) continue;
2616
+ const item = group.get(id);
2617
+ if (!item || toValue(item.disabled)) continue;
2618
+ openedIds.add(id);
2619
+ resolvedOpenStrategy.onOpen?.(id, context);
2592
2620
  if (revealOnOpen) {
2593
2621
  let parentId = parents.get(id);
2594
2622
  while (!/* @__PURE__ */ isUndefined(parentId)) {
@@ -2596,20 +2624,24 @@ function createNested(_options = {}) {
2596
2624
  parentId = parents.get(parentId);
2597
2625
  }
2598
2626
  }
2599
- openedIds.add(id);
2600
- resolvedOpenStrategy.onOpen?.(id, context);
2601
2627
  }
2602
2628
  }
2603
2629
  function close(ids) {
2630
+ if (toValue(group.disabled)) return;
2604
2631
  for (const id of toArray(ids)) {
2605
2632
  if (!group.has(id)) continue;
2633
+ const item = group.get(id);
2634
+ if (!item || toValue(item.disabled)) continue;
2606
2635
  openedIds.delete(id);
2607
2636
  resolvedOpenStrategy.onClose?.(id, context);
2608
2637
  }
2609
2638
  }
2610
2639
  function flip(ids) {
2640
+ if (toValue(group.disabled)) return;
2611
2641
  for (const id of toArray(ids)) {
2612
2642
  if (!group.has(id)) continue;
2643
+ const item = group.get(id);
2644
+ if (!item || toValue(item.disabled)) continue;
2613
2645
  if (opened(id)) close(id);
2614
2646
  else open(id);
2615
2647
  }
@@ -2649,10 +2681,20 @@ function createNested(_options = {}) {
2649
2681
  }
2650
2682
  }
2651
2683
  function expandAll() {
2652
- for (const [id, childList] of children) if (childList.length > 0) openedIds.add(id);
2684
+ if (toValue(group.disabled)) return;
2685
+ for (const [id, childList] of children) if (childList.length > 0) {
2686
+ const item = group.get(id);
2687
+ if (item && toValue(item.disabled)) continue;
2688
+ openedIds.add(id);
2689
+ }
2653
2690
  }
2654
2691
  function collapseAll() {
2655
- openedIds.clear();
2692
+ if (toValue(group.disabled)) return;
2693
+ const toClose = [...openedIds].filter((id) => {
2694
+ const item = group.get(id);
2695
+ return !item || !toValue(item.disabled);
2696
+ });
2697
+ for (const id of toClose) openedIds.delete(id);
2656
2698
  }
2657
2699
  function activated(id) {
2658
2700
  return activeIds.has(id);
@@ -2733,7 +2775,7 @@ function createNested(_options = {}) {
2733
2775
  function siblings(id) {
2734
2776
  if (!group.has(id)) return [];
2735
2777
  const parentId = parents.get(id);
2736
- if (/* @__PURE__ */ isUndefined(parentId)) return group.values().filter((item) => /* @__PURE__ */ isUndefined(parents.get(item.id))).map((item) => item.id);
2778
+ if (/* @__PURE__ */ isUndefined(parentId)) return Array.from(rootIds);
2737
2779
  return children.get(parentId) ?? [];
2738
2780
  }
2739
2781
  /**
@@ -2744,6 +2786,28 @@ function createNested(_options = {}) {
2744
2786
  const index = siblings(id).indexOf(id);
2745
2787
  return index === -1 ? 0 : index + 1;
2746
2788
  }
2789
+ /**
2790
+ * Returns depth-first traversal of visible (open) nodes.
2791
+ * A node is visible if all its ancestors are open.
2792
+ * Used by useRovingFocus to determine keyboard navigation order.
2793
+ */
2794
+ function visibleItems() {
2795
+ const result = [];
2796
+ const rootItems = Array.from(rootIds);
2797
+ function walk(ids) {
2798
+ for (const id of ids) {
2799
+ const item = group.get(id);
2800
+ if (!item) continue;
2801
+ result.push(item);
2802
+ if (opened(id)) {
2803
+ const childIds = children.get(id);
2804
+ if (childIds?.length) walk(childIds);
2805
+ }
2806
+ }
2807
+ }
2808
+ walk(rootItems);
2809
+ return result;
2810
+ }
2747
2811
  function updateAncestors(id) {
2748
2812
  const { selectedIds, mixedIds } = group;
2749
2813
  let parentId = parents.get(id);
@@ -2770,8 +2834,11 @@ function createNested(_options = {}) {
2770
2834
  return getDescendants(id).filter((did) => isLeaf(did));
2771
2835
  }
2772
2836
  function select(ids) {
2837
+ if (toValue(group.disabled)) return;
2773
2838
  for (const id of toArray(ids)) {
2774
2839
  if (!group.has(id)) continue;
2840
+ const item = group.get(id);
2841
+ if (!item || toValue(item.disabled)) continue;
2775
2842
  if (selectionMode === "independent") group.select(id);
2776
2843
  else if (selectionMode === "leaf") if (isLeaf(id)) group.select(id);
2777
2844
  else for (const lid of getLeafDescendants(id)) group.select(lid);
@@ -2784,6 +2851,8 @@ function createNested(_options = {}) {
2784
2851
  mixedIds.delete(id);
2785
2852
  selectedIds.add(id);
2786
2853
  for (const did of getDescendants(id)) {
2854
+ const desc = group.get(did);
2855
+ if (desc && toValue(desc.disabled)) continue;
2787
2856
  mixedIds.delete(did);
2788
2857
  selectedIds.add(did);
2789
2858
  }
@@ -2792,8 +2861,11 @@ function createNested(_options = {}) {
2792
2861
  }
2793
2862
  }
2794
2863
  function unselect(ids) {
2864
+ if (toValue(group.disabled)) return;
2795
2865
  for (const id of toArray(ids)) {
2796
2866
  if (!group.has(id)) continue;
2867
+ const item = group.get(id);
2868
+ if (!item || toValue(item.disabled)) continue;
2797
2869
  if (selectionMode === "independent") group.unselect(id);
2798
2870
  else if (selectionMode === "leaf") if (isLeaf(id)) group.unselect(id);
2799
2871
  else for (const lid of getLeafDescendants(id)) group.unselect(lid);
@@ -2806,6 +2878,8 @@ function createNested(_options = {}) {
2806
2878
  mixedIds.delete(id);
2807
2879
  selectedIds.delete(id);
2808
2880
  for (const did of getDescendants(id)) {
2881
+ const desc = group.get(did);
2882
+ if (desc && toValue(desc.disabled)) continue;
2809
2883
  mixedIds.delete(did);
2810
2884
  selectedIds.delete(did);
2811
2885
  }
@@ -2814,15 +2888,43 @@ function createNested(_options = {}) {
2814
2888
  }
2815
2889
  }
2816
2890
  function toggle(ids) {
2817
- for (const id of toArray(ids)) if (selectionMode === "independent") group.toggle(id);
2818
- else if (selectionMode === "leaf") if (isLeaf(id)) group.toggle(id);
2819
- else {
2820
- const leafIds = getLeafDescendants(id);
2821
- if (leafIds.every((lid) => group.selected(lid))) for (const lid of leafIds) group.unselect(lid);
2822
- else for (const lid of leafIds) group.select(lid);
2891
+ if (toValue(group.disabled)) return;
2892
+ for (const id of toArray(ids)) {
2893
+ const item = group.get(id);
2894
+ if (!item || toValue(item.disabled)) continue;
2895
+ if (selectionMode === "independent") group.toggle(id);
2896
+ else if (selectionMode === "leaf") if (isLeaf(id)) group.toggle(id);
2897
+ else {
2898
+ const leafIds = getLeafDescendants(id);
2899
+ if (leafIds.every((lid) => group.selected(lid))) for (const lid of leafIds) group.unselect(lid);
2900
+ else for (const lid of leafIds) group.select(lid);
2901
+ }
2902
+ else if (group.selected(id) || group.mixed(id)) unselect(id);
2903
+ else select(id);
2823
2904
  }
2824
- else if (group.selected(id) || group.mixed(id)) unselect(id);
2825
- else select(id);
2905
+ }
2906
+ function selectAll() {
2907
+ if (toValue(group.disabled)) return;
2908
+ const { selectedIds, mixedIds } = group;
2909
+ for (const item of group.values()) {
2910
+ if (toValue(item.disabled)) continue;
2911
+ selectedIds.add(item.id);
2912
+ }
2913
+ mixedIds.clear();
2914
+ }
2915
+ function unselectAll() {
2916
+ if (toValue(group.disabled)) return;
2917
+ const first = group.selectedIds.values().next().value;
2918
+ group.selectedIds.clear();
2919
+ group.mixedIds.clear();
2920
+ if (toValue(mandatoryOption) && first) {
2921
+ group.selectedIds.add(first);
2922
+ updateAncestors(first);
2923
+ }
2924
+ }
2925
+ function toggleAll() {
2926
+ if (group.isAllSelected.value) unselectAll();
2927
+ else selectAll();
2826
2928
  }
2827
2929
  /**
2828
2930
  * Converts the tree to a flat array with parentId references.
@@ -2867,6 +2969,7 @@ function createNested(_options = {}) {
2867
2969
  const item = {
2868
2970
  ...rest,
2869
2971
  id,
2972
+ el: registration.el,
2870
2973
  parentId: batching ? pendingParents.get(id) : parents.get(id),
2871
2974
  isOpen: toRef(() => opened(id)),
2872
2975
  isActive: toRef(() => activated(id)),
@@ -2887,6 +2990,9 @@ function createNested(_options = {}) {
2887
2990
  position: () => position(id)
2888
2991
  };
2889
2992
  const ticket = group.register(item);
2993
+ ticket.select = () => select(id);
2994
+ ticket.unselect = () => unselect(id);
2995
+ ticket.toggle = () => toggle(id);
2890
2996
  if (registration.active) activate(id);
2891
2997
  if (nested?.length) for (const child of nested) register({
2892
2998
  ...child,
@@ -2981,6 +3087,7 @@ function createNested(_options = {}) {
2981
3087
  activeIndexes,
2982
3088
  roots,
2983
3089
  leaves,
3090
+ visibleItems,
2984
3091
  getPath,
2985
3092
  getAncestors,
2986
3093
  getDescendants,
@@ -3004,10 +3111,14 @@ function createNested(_options = {}) {
3004
3111
  activated,
3005
3112
  deactivateAll,
3006
3113
  toFlat,
3114
+ multiple: toValue(multipleOption),
3007
3115
  openStrategy: resolvedOpenStrategy,
3008
3116
  select,
3009
3117
  unselect,
3010
3118
  toggle,
3119
+ selectAll,
3120
+ unselectAll,
3121
+ toggleAll,
3011
3122
  register,
3012
3123
  unregister,
3013
3124
  offboard,
@@ -1,7 +1,7 @@
1
1
  import { isArray, isBoolean, isFunction, isObject } from "./utilities/index.mjs";
2
- import { o as createPluginContext } from "./useLogger-Bw836Jbg.mjs";
3
- import { t as createTokens } from "./createTokens-N8QIWw_D.mjs";
4
- import { t as createGroup } from "./createGroup-DpbGTwFy.mjs";
2
+ import { o as createPluginContext } from "./useLogger-xp_tiLJ5.mjs";
3
+ import { t as createTokens } from "./createTokens-vyh3quuB.mjs";
4
+ import { t as createGroup } from "./createGroup-BgDjEOXE.mjs";
5
5
  //#region src/composables/useFeatures/adapters/generic/index.ts
6
6
  var FeaturesAdapter = class {};
7
7
  //#endregion
@@ -1,7 +1,7 @@
1
- import { o as createPluginContext } from "./useLogger-Bw836Jbg.mjs";
2
- import { r as flatten, t as createTokens } from "./createTokens-N8QIWw_D.mjs";
3
- import { t as createSingle } from "./createSingle-fWHREEJO.mjs";
4
- import { t as Vuetify0LocaleAdapter } from "./v0-DgaVf3xM.mjs";
1
+ import { o as createPluginContext } from "./useLogger-xp_tiLJ5.mjs";
2
+ import { r as flatten, t as createTokens } from "./createTokens-vyh3quuB.mjs";
3
+ import { t as createSingle } from "./createSingle-CqX-KXFr.mjs";
4
+ import { t as Vuetify0LocaleAdapter } from "./v0-CkxwC3wm.mjs";
5
5
  //#region src/composables/useLocale/index.ts
6
6
  /**
7
7
  * @module useLocale
@@ -1,7 +1,7 @@
1
- import { s as __LOGGER_ENABLED__, t as IN_BROWSER } from "./globals-F7fiJVG1.mjs";
1
+ import { s as __LOGGER_ENABLED__, t as IN_BROWSER } from "./globals-TLLuB8XQ.mjs";
2
2
  import { isUndefined } from "./utilities/index.mjs";
3
3
  import { i as useContext, n as createContext, t as createTrinity } from "./createTrinity-C_c8eedz.mjs";
4
- import { t as Vuetify0LoggerAdapter } from "./v0-BsuBuBSa.mjs";
4
+ import { t as Vuetify0LoggerAdapter } from "./v0-Di7YUWAH.mjs";
5
5
  import { hasInjectionContext } from "vue";
6
6
  //#region src/composables/createPlugin/index.ts
7
7
  /**
@@ -1,5 +1,5 @@
1
- import { o as createPluginContext } from "./useLogger-Bw836Jbg.mjs";
2
- import { t as createTokens } from "./createTokens-N8QIWw_D.mjs";
1
+ import { o as createPluginContext } from "./useLogger-xp_tiLJ5.mjs";
2
+ import { t as createTokens } from "./createTokens-vyh3quuB.mjs";
3
3
  import { t as toArray } from "./toArray-VdROPpy-.mjs";
4
4
  import { t as Vuetify0PermissionAdapter } from "./v0-B1QQGE4O.mjs";
5
5
  //#region src/composables/usePermissions/index.ts
@@ -1,6 +1,6 @@
1
1
  import { instanceExists, isFunction, isObject } from "./utilities/index.mjs";
2
- import { o as createPluginContext } from "./useLogger-Bw836Jbg.mjs";
3
- import { a as useLocale } from "./useLocale-Dzl6lCCF.mjs";
2
+ import { o as createPluginContext } from "./useLogger-xp_tiLJ5.mjs";
3
+ import { a as useLocale } from "./useLocale-B8NaQT2b.mjs";
4
4
  //#region src/composables/useRules/adapters/standard.ts
5
5
  /**
6
6
  * Type guard for Standard Schema objects.
@@ -1,7 +1,8 @@
1
- import { o as createPluginContext } from "./useLogger-Bw836Jbg.mjs";
2
- import { r as flatten, t as createTokens } from "./createTokens-N8QIWw_D.mjs";
3
- import { t as createSingle } from "./createSingle-fWHREEJO.mjs";
4
- import { t as Vuetify0ThemeAdapter } from "./v0-CIEQpOK2.mjs";
1
+ import { foreground } from "./utilities/index.mjs";
2
+ import { o as createPluginContext } from "./useLogger-xp_tiLJ5.mjs";
3
+ import { r as flatten, t as createTokens } from "./createTokens-vyh3quuB.mjs";
4
+ import { t as createSingle } from "./createSingle-CqX-KXFr.mjs";
5
+ import { t as Vuetify0ThemeAdapter } from "./v0-AoEx-7U5.mjs";
5
6
  import { computed, shallowRef, toRef } from "vue";
6
7
  //#region src/composables/useTheme/index.ts
7
8
  /**
@@ -57,7 +58,7 @@ import { computed, shallowRef, toRef } from "vue";
57
58
  * ```
58
59
  */
59
60
  function createTheme(_options = {}) {
60
- const { themes = {}, palette = {}, ...options } = _options;
61
+ const { themes = {}, palette = {}, foreground: genForeground, ...options } = _options;
61
62
  const tokens = createTokens({
62
63
  palette,
63
64
  ...themes
@@ -77,7 +78,12 @@ function createTheme(_options = {}) {
77
78
  const resolved = {};
78
79
  for (const theme of registry.values()) {
79
80
  if (theme.lazy && theme.id !== registry.selectedId.value) continue;
80
- resolved[theme.id] = resolve(theme.value);
81
+ const themeColors = resolve(theme.value);
82
+ if (genForeground) for (const [key, value] of Object.entries(themeColors)) {
83
+ const onKey = `on-${key}`;
84
+ if (!key.startsWith("on-") && !(onKey in themeColors)) themeColors[onKey] = foreground(value);
85
+ }
86
+ resolved[theme.id] = themeColors;
81
87
  }
82
88
  return resolved;
83
89
  });
@@ -128,7 +134,8 @@ function createThemeFallback() {
128
134
  }
129
135
  const [createThemeContext, createThemePlugin, useTheme] = createPluginContext("v0:theme", (options) => createTheme(options), {
130
136
  fallback: () => createThemeFallback(),
131
- setup: (context, app, { adapter = new Vuetify0ThemeAdapter(), target }) => {
137
+ setup: (context, app, { adapter = new Vuetify0ThemeAdapter(), target, rgb }) => {
138
+ if (rgb) adapter.rgb = true;
132
139
  adapter.setup(app, context, target);
133
140
  }
134
141
  });
@@ -1,2 +1,2 @@
1
- import { _ as mergeDeep, a as isBoolean, c as isNaN, d as isNumber, f as isObject, g as isUndefined, h as isSymbol, i as isArray, l as isNull, m as isString, n as instanceName, o as isElement, p as isPrimitive, r as clamp, s as isFunction, t as instanceExists, u as isNullOrUndefined, v as range, y as useId } from "../index-Cv1XUHyA.mjs";
2
- export { clamp, instanceExists, instanceName, isArray, isBoolean, isElement, isFunction, isNaN, isNull, isNullOrUndefined, isNumber, isObject, isPrimitive, isString, isSymbol, isUndefined, mergeDeep, range, useId };
1
+ import { C as hexToRgb, S as RGB, _ as mergeDeep, a as isBoolean, b as apca, c as isNaN, d as isNumber, f as isObject, g as isUndefined, h as isSymbol, i as isArray, l as isNull, m as isString, n as instanceName, o as isElement, p as isPrimitive, r as clamp, s as isFunction, t as instanceExists, u as isNullOrUndefined, v as range, w as rgbToHex, x as foreground, y as useId } from "../index-Dlz-FzrC.mjs";
2
+ export { RGB, apca, clamp, foreground, hexToRgb, instanceExists, instanceName, isArray, isBoolean, isElement, isFunction, isNaN, isNull, isNullOrUndefined, isNumber, isObject, isPrimitive, isString, isSymbol, isUndefined, mergeDeep, range, rgbToHex, useId };
@@ -1,6 +1,104 @@
1
- import { t as IN_BROWSER } from "../globals-F7fiJVG1.mjs";
1
+ import { t as IN_BROWSER } from "../globals-TLLuB8XQ.mjs";
2
2
  import * as Vue from "vue";
3
3
  import { useId as useId$1 } from "vue";
4
+ //#region src/utilities/color.ts
5
+ function hexToRgb(hex) {
6
+ const clean = hex.startsWith("#") ? hex.slice(1) : hex;
7
+ if (clean.length === 3 || clean.length === 4) {
8
+ const r = Number.parseInt(clean[0] + clean[0], 16);
9
+ const g = Number.parseInt(clean[1] + clean[1], 16);
10
+ const b = Number.parseInt(clean[2] + clean[2], 16);
11
+ const a = clean.length === 4 ? Number.parseInt(clean[3] + clean[3], 16) : void 0;
12
+ return a === void 0 ? {
13
+ r,
14
+ g,
15
+ b
16
+ } : {
17
+ r,
18
+ g,
19
+ b,
20
+ a
21
+ };
22
+ }
23
+ const r = Number.parseInt(clean.slice(0, 2), 16);
24
+ const g = Number.parseInt(clean.slice(2, 4), 16);
25
+ const b = Number.parseInt(clean.slice(4, 6), 16);
26
+ const a = clean.length === 8 ? Number.parseInt(clean.slice(6, 8), 16) : void 0;
27
+ return a === void 0 ? {
28
+ r,
29
+ g,
30
+ b
31
+ } : {
32
+ r,
33
+ g,
34
+ b,
35
+ a
36
+ };
37
+ }
38
+ function rgbToHex({ r, g, b, a }) {
39
+ const hex = "#" + [
40
+ r,
41
+ g,
42
+ b
43
+ ].map((c) => c.toString(16).padStart(2, "0")).join("");
44
+ if (a !== void 0) return hex + a.toString(16).padStart(2, "0");
45
+ return hex;
46
+ }
47
+ //#endregion
48
+ //#region src/utilities/apca.ts
49
+ const Rco = .2126729;
50
+ const Gco = .7151522;
51
+ const Bco = .072175;
52
+ const normBG = .56;
53
+ const normTXT = .57;
54
+ const revBG = .65;
55
+ const revTXT = .62;
56
+ const blkThrs = .022;
57
+ const blkClmp = 1.414;
58
+ const scaleBoW = 1.14;
59
+ const scaleWoB = 1.14;
60
+ const loBoWoffset = .027;
61
+ const loWoBoffset = .027;
62
+ const deltaYmin = 5e-4;
63
+ function linearize(channel) {
64
+ const val = channel / 255;
65
+ return val <= .04045 ? val / 12.92 : Math.pow((val + .055) / 1.055, 2.4);
66
+ }
67
+ function luminance(rgb) {
68
+ return Rco * linearize(rgb.r) + Gco * linearize(rgb.g) + Bco * linearize(rgb.b);
69
+ }
70
+ function clamp$1(y) {
71
+ return y > blkThrs ? y : y + Math.pow(blkThrs - y, blkClmp);
72
+ }
73
+ function apca(text, background) {
74
+ const txtY = clamp$1(luminance(text));
75
+ const bgY = clamp$1(luminance(background));
76
+ if (Math.abs(bgY - txtY) < deltaYmin) return 0;
77
+ let contrast;
78
+ if (bgY > txtY) {
79
+ contrast = (Math.pow(bgY, normBG) - Math.pow(txtY, normTXT)) * scaleBoW;
80
+ return contrast < loBoWoffset ? 0 : (contrast - loBoWoffset) * 100;
81
+ } else {
82
+ contrast = (Math.pow(bgY, revBG) - Math.pow(txtY, revTXT)) * scaleWoB;
83
+ return contrast > -loWoBoffset ? 0 : (contrast + loWoBoffset) * 100;
84
+ }
85
+ }
86
+ const BLACK = {
87
+ r: 0,
88
+ g: 0,
89
+ b: 0
90
+ };
91
+ const WHITE = {
92
+ r: 255,
93
+ g: 255,
94
+ b: 255
95
+ };
96
+ function foreground(hex) {
97
+ const rgb = hexToRgb(hex);
98
+ const onWhite = Math.abs(apca(WHITE, rgb));
99
+ return Math.abs(apca(BLACK, rgb)) > onWhite ? "#000000" : "#ffffff";
100
+ }
101
+ //#endregion
4
102
  //#region src/utilities/instance.ts
5
103
  /**
6
104
  * Vue 3.6+ exposes `currentInstance` for Vapor mode compatibility.
@@ -282,14 +380,14 @@ function isNaN(item) {
282
380
  return /* @__PURE__ */ isNumber(item) && Number.isNaN(item);
283
381
  }
284
382
  /**
285
- * Deeply merges source objects into a target object
383
+ * Deeply merges source objects into a target object, returning a new object
286
384
  *
287
- * @param target The target object to merge into (will be mutated)
385
+ * @param target The base object to merge into
288
386
  * @param sources One or more source objects to merge from
289
- * @returns The mutated target object
387
+ * @returns A new merged object (inputs are not mutated)
290
388
  *
291
389
  * @remarks
292
- * - Mutates the target object in place
390
+ * - Creates and returns a new object inputs are never mutated
293
391
  * - Nested objects are recursively merged
294
392
  * - Arrays are replaced, not merged
295
393
  * - Primitives from sources overwrite target values
@@ -297,8 +395,9 @@ function isNaN(item) {
297
395
  * @example
298
396
  * ```ts
299
397
  * const target = { a: 1, b: { c: 2 } }
300
- * mergeDeep(target, { b: { d: 3 } })
301
- * // target is now { a: 1, b: { c: 2, d: 3 } }
398
+ * const result = mergeDeep(target, { b: { d: 3 } })
399
+ * // result is { a: 1, b: { c: 2, d: 3 } }
400
+ * // target is unchanged
302
401
  *
303
402
  * // Multiple sources
304
403
  * mergeDeep({}, { a: 1 }, { b: 2 }) // { a: 1, b: 2 }
@@ -314,20 +413,20 @@ const UNSAFE_KEYS = new Set([
314
413
  ]);
315
414
  /* @__NO_SIDE_EFFECTS__ */
316
415
  function mergeDeep(target, ...sources) {
317
- if (sources.length === 0) return target;
318
- const source = sources.shift();
319
- if (/* @__PURE__ */ isObject(target) && /* @__PURE__ */ isObject(source)) for (const key in source) {
320
- if (UNSAFE_KEYS.has(key)) continue;
321
- if (!Object.prototype.hasOwnProperty.call(source, key)) continue;
322
- const sourceValue = source[key];
323
- if (/* @__PURE__ */ isUndefined(sourceValue)) continue;
324
- const targetValue = target[key];
325
- if (/* @__PURE__ */ isObject(sourceValue)) {
326
- if (!/* @__PURE__ */ isObject(targetValue)) Object.assign(target, { [key]: {} });
327
- target[key];
328
- } else Object.assign(target, { [key]: sourceValue });
416
+ const out = {};
417
+ for (const key in target) if (Object.prototype.hasOwnProperty.call(target, key)) out[key] = target[key];
418
+ for (const source of sources) {
419
+ if (!/* @__PURE__ */ isObject(source)) continue;
420
+ for (const key in source) {
421
+ if (UNSAFE_KEYS.has(key)) continue;
422
+ if (!Object.prototype.hasOwnProperty.call(source, key)) continue;
423
+ const sourceValue = source[key];
424
+ if (/* @__PURE__ */ isUndefined(sourceValue)) continue;
425
+ const targetValue = out[key];
426
+ out[key] = /* @__PURE__ */ isObject(sourceValue) && /* @__PURE__ */ isObject(targetValue) ? /* @__PURE__ */ mergeDeep(targetValue, sourceValue) : sourceValue;
427
+ }
329
428
  }
330
- return /* @__PURE__ */ mergeDeep(target, ...sources);
429
+ return out;
331
430
  }
332
431
  let idCounter = 0;
333
432
  /**
@@ -394,4 +493,4 @@ function range(length, start = 0) {
394
493
  return Array.from({ length }, (_, index) => start + index);
395
494
  }
396
495
  //#endregion
397
- export { clamp, instanceExists, instanceName, isArray, isBoolean, isElement, isFunction, isNaN, isNull, isNullOrUndefined, isNumber, isObject, isPrimitive, isString, isSymbol, isUndefined, mergeDeep, range, useId };
496
+ export { apca, clamp, foreground, hexToRgb, instanceExists, instanceName, isArray, isBoolean, isElement, isFunction, isNaN, isNull, isNullOrUndefined, isNumber, isObject, isPrimitive, isString, isSymbol, isUndefined, mergeDeep, range, rgbToHex, useId };
@@ -1,10 +1,11 @@
1
- import { t as IN_BROWSER } from "./globals-F7fiJVG1.mjs";
2
- import { isNull, isString, isUndefined } from "./utilities/index.mjs";
1
+ import { t as IN_BROWSER } from "./globals-TLLuB8XQ.mjs";
2
+ import { hexToRgb, isNull, isString, isUndefined } from "./utilities/index.mjs";
3
3
  import { onScopeDispose, watch } from "vue";
4
4
  //#region src/composables/useTheme/adapters/adapter.ts
5
5
  var ThemeAdapter = class {
6
6
  stylesheetId = "v0-theme-stylesheet";
7
7
  prefix;
8
+ rgb = false;
8
9
  constructor(prefix) {
9
10
  this.prefix = prefix;
10
11
  }
@@ -13,12 +14,16 @@ var ThemeAdapter = class {
13
14
  for (const theme in colors) {
14
15
  const themeColors = colors[theme];
15
16
  if (!themeColors) continue;
16
- const vars = Object.entries(themeColors).map(([key, val]) => ` --${this.prefix}-${key}: ${val};`).join("\n");
17
+ const vars = Object.entries(themeColors).map(([key, val]) => ` --${this.prefix}-${key}: ${this.rgb ? this.decompose(val) : val};`).join("\n");
17
18
  css += `[data-theme="${theme}"] {\n${vars}\n}\n`;
18
19
  }
19
20
  if (!/* @__PURE__ */ isUndefined(isDark)) css += `:root {\n color-scheme: ${isDark ? "dark" : "light"};\n}\n`;
20
21
  return css;
21
22
  }
23
+ decompose(hex) {
24
+ const { r, g, b, a } = hexToRgb(hex);
25
+ return /* @__PURE__ */ isUndefined(a) ? `${r}, ${g}, ${b}` : `${r}, ${g}, ${b}, ${a}`;
26
+ }
22
27
  };
23
28
  //#endregion
24
29
  //#region src/composables/useTheme/adapters/v0.ts
@@ -1,4 +1,4 @@
1
- import { t as LoggerAdapter } from "./adapter-CJQav2JB.mjs";
1
+ import { t as LoggerAdapter } from "./adapter-DcJbLnTC.mjs";
2
2
 
3
3
  //#region src/composables/useLogger/adapters/v0.d.ts
4
4
  /**
@@ -1,4 +1,4 @@
1
- import { n as LocaleAdapterContext, t as LocaleAdapter } from "./adapter-D3dUnE__.mjs";
1
+ import { n as LocaleAdapterContext, t as LocaleAdapter } from "./adapter-CN3E66HY.mjs";
2
2
 
3
3
  //#region src/composables/useLocale/adapters/v0.d.ts
4
4
  /**
@@ -1,4 +1,4 @@
1
- import { t as IN_BROWSER } from "./globals-F7fiJVG1.mjs";
1
+ import { t as IN_BROWSER } from "./globals-TLLuB8XQ.mjs";
2
2
  import { isObject, isString, isUndefined } from "./utilities/index.mjs";
3
3
  //#region src/composables/useLocale/adapters/v0.ts
4
4
  /**
@@ -1,4 +1,4 @@
1
- import { t as IN_BROWSER } from "./globals-F7fiJVG1.mjs";
1
+ import { t as IN_BROWSER } from "./globals-TLLuB8XQ.mjs";
2
2
  import { isFunction } from "./utilities/index.mjs";
3
3
  //#region src/composables/useLogger/adapters/v0.ts
4
4
  /**