vlite3 0.4.4 → 0.4.7

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 (109) hide show
  1. package/components/Accordion/AccordionItem.vue.js +33 -32
  2. package/components/Accordion/types.d.ts +2 -0
  3. package/components/Alert.vue.d.ts +2 -0
  4. package/components/Alert.vue.js +38 -36
  5. package/components/AvatarUploader/AvatarUploader.vue.d.ts +1 -1
  6. package/components/AvatarUploader/AvatarUploader.vue.js +25 -24
  7. package/components/Button.vue.d.ts +1 -1
  8. package/components/Button.vue.js +37 -35
  9. package/components/CheckBox.vue.d.ts +1 -0
  10. package/components/CheckBox.vue.js +40 -40
  11. package/components/Chip/Chip.vue.js +55 -55
  12. package/components/Chip/types.d.ts +1 -0
  13. package/components/ChoiceBox/ChoiceBox.vue.d.ts +5 -0
  14. package/components/ChoiceBox/ChoiceBox.vue.js +61 -58
  15. package/components/ColorPicker/ColorPicker.vue.js +3 -2
  16. package/components/ConfirmationModal.vue.d.ts +4 -2
  17. package/components/ConfirmationModal.vue.js +48 -33
  18. package/components/DataList/DataList.vue.d.ts +0 -2
  19. package/components/DataList/DataList.vue.js +39 -35
  20. package/components/DataList/types.d.ts +2 -0
  21. package/components/DataTable/DataTable.vue.d.ts +0 -5
  22. package/components/DataTable/DataTable.vue.js +177 -158
  23. package/components/DataTable/DataTableHeader.vue.js +15 -14
  24. package/components/DataTable/DataTableToolbar.vue.d.ts +1 -1
  25. package/components/DataTable/DataTableToolbar.vue.js +30 -23
  26. package/components/DataTable/types.d.ts +4 -0
  27. package/components/DatePicker.vue.d.ts +1 -0
  28. package/components/DatePicker.vue.js +32 -25
  29. package/components/Dropdown/DropdownBooleanItem.vue.js +18 -17
  30. package/components/Dropdown/DropdownGroupedLayout.vue.js +28 -27
  31. package/components/Dropdown/DropdownItem.vue.js +24 -23
  32. package/components/Dropdown/DropdownMenu.vue.js +100 -91
  33. package/components/Dropdown/composables/useDropdownNavigation.js +24 -23
  34. package/components/Dropdown/composables/useDropdownSelection.js +19 -17
  35. package/components/Empty/Empty.vue.d.ts +2 -2
  36. package/components/Empty/Empty.vue.js +32 -18
  37. package/components/FilePicker/FilePicker.vue.d.ts +3 -1
  38. package/components/FilePicker/FilePicker.vue.js +140 -127
  39. package/components/FileTree/FileTree.vue.js +68 -58
  40. package/components/FileTree/FileTreeNode.vue.js +35 -34
  41. package/components/FileTree/types.d.ts +3 -0
  42. package/components/Form/CustomFields.vue.d.ts +3 -1
  43. package/components/Form/CustomFields.vue.js +2 -2
  44. package/components/Form/CustomFields.vue2.js +92 -80
  45. package/components/Form/Form.vue.d.ts +1 -1
  46. package/components/Form/FormField.vue.d.ts +1 -1
  47. package/components/Form/FormField.vue.js +60 -59
  48. package/components/Form/FormFields.vue.js +2 -2
  49. package/components/Form/FormFields.vue2.js +58 -57
  50. package/components/Form/composables/useForm.js +91 -88
  51. package/components/Form/types.d.ts +4 -0
  52. package/components/Form/utils/form.utils.js +104 -98
  53. package/components/GoogleLogin.vue.d.ts +1 -1
  54. package/components/GoogleLogin.vue.js +39 -32
  55. package/components/Heatmap/Heatmap.vue2.js +3 -2
  56. package/components/IconPicker.vue.d.ts +2 -0
  57. package/components/IconPicker.vue.js +37 -29
  58. package/components/Input.vue.d.ts +1 -1
  59. package/components/Input.vue.js +96 -98
  60. package/components/Kanban/KanbanBoard.vue.js +1 -1
  61. package/components/Kanban/KanbanBoard.vue2.js +55 -54
  62. package/components/Kanban/types.d.ts +1 -0
  63. package/components/Masonry/Masonry.vue2.js +3 -2
  64. package/components/Modal.vue.d.ts +2 -0
  65. package/components/Modal.vue.js +62 -57
  66. package/components/MultiSelect/MultiSelect.vue.d.ts +1 -1
  67. package/components/MultiSelect/MultiSelect.vue.js +61 -54
  68. package/components/Navbar/Navbar.vue.js +46 -46
  69. package/components/Pagination/Pagination.vue.js +116 -97
  70. package/components/PricingPlan/PricingPlanItem.vue.js +60 -47
  71. package/components/PricingPlan/types.d.ts +5 -0
  72. package/components/Screen/Screen.vue.d.ts +0 -4
  73. package/components/Screen/Screen.vue.js +231 -189
  74. package/components/Screen/ScreenFilter.vue.js +73 -63
  75. package/components/Screen/types.d.ts +5 -0
  76. package/components/SidePanel.vue.d.ts +2 -0
  77. package/components/SidePanel.vue.js +140 -5
  78. package/components/SidePanel.vue2.js +2 -135
  79. package/components/SidebarMenu/SidebarMenuItem.vue.js +131 -130
  80. package/components/SidebarMenu/types.d.ts +1 -0
  81. package/components/Slider.vue.d.ts +1 -0
  82. package/components/Slider.vue.js +71 -69
  83. package/components/Switch.vue.d.ts +1 -0
  84. package/components/Switch.vue.js +23 -18
  85. package/components/Tabes/Tabes.vue.js +20 -19
  86. package/components/Tabes/types.d.ts +1 -0
  87. package/components/Textarea.vue.d.ts +1 -0
  88. package/components/Textarea.vue.js +18 -16
  89. package/components/ThemeToggle.vue.js +24 -14
  90. package/components/Timeline.vue.js +68 -82
  91. package/components/ToastNotification.vue.js +2 -2
  92. package/components/Tooltip.vue.d.ts +4 -3
  93. package/components/Tooltip.vue.js +17 -15
  94. package/components/Workbook/Sheet.vue.js +80 -71
  95. package/components/Workbook/WorkbookAddButton.vue.js +14 -10
  96. package/components/Workbook/types.d.ts +1 -0
  97. package/core/config.d.ts +2 -0
  98. package/index.d.ts +1 -0
  99. package/index.js +28 -26
  100. package/package.json +1 -1
  101. package/style.css +1 -2
  102. package/types/button.d.ts +1 -0
  103. package/types/config.type.d.ts +10 -0
  104. package/types/form.type.d.ts +2 -0
  105. package/types/styles.d.ts +3 -0
  106. package/types/timeline.type.d.ts +2 -0
  107. package/utils/i18n.d.ts +8 -0
  108. package/utils/i18n.js +5 -0
  109. package/utils/index.d.ts +1 -0
@@ -1,141 +1,142 @@
1
- import { defineComponent as J, inject as Q, computed as c, resolveComponent as U, openBlock as l, createElementBlock as m, createBlock as h, unref as r, withCtx as p, resolveDynamicComponent as j, createCommentVNode as d, createElementVNode as v, toDisplayString as y, normalizeClass as s, createVNode as w, mergeProps as A, createTextVNode as W, Fragment as D, withKeys as X, withModifiers as Y, Transition as Z, normalizeStyle as O, renderList as _ } from "vue";
1
+ import { defineComponent as Q, inject as U, computed as c, resolveComponent as W, openBlock as o, createElementBlock as m, createBlock as p, unref as l, withCtx as h, resolveDynamicComponent as $, createCommentVNode as d, createElementVNode as v, toDisplayString as y, normalizeClass as s, createVNode as k, mergeProps as A, createTextVNode as X, Fragment as D, withKeys as Y, withModifiers as Z, Transition as O, normalizeStyle as ee, renderList as te } from "vue";
2
2
  import g from "../Icon.vue.js";
3
3
  import P from "../Tooltip.vue.js";
4
- import ee from "../Dropdown/Dropdown.vue.js";
5
- const te = { class: "w-full relative sidebar-manu-item" }, ne = {
4
+ import ne from "../Dropdown/Dropdown.vue.js";
5
+ import { $t as V } from "../../utils/i18n.js";
6
+ const ae = { class: "w-full relative sidebar-manu-item" }, ie = {
6
7
  key: 0,
7
8
  class: "px-3 py-1.5 text-sm flex items-center gap-2 font-medium border-b bg-muted-light rounded-t-md text-center truncate"
8
- }, ae = { class: "w-full" }, ie = { class: "truncate flex-1" }, oe = ["onKeydown"], le = {
9
+ }, oe = { class: "w-full" }, le = { class: "truncate flex-1" }, re = ["onKeydown"], ce = {
9
10
  key: 0,
10
11
  class: "overflow-hidden transition-all duration-300 ease-in-out relative"
11
- }, re = { class: "mt-0.5 space-y-0.5" }, me = /* @__PURE__ */ J({
12
+ }, se = { class: "mt-0.5 space-y-0.5" }, he = /* @__PURE__ */ Q({
12
13
  __name: "SidebarMenuItem",
13
14
  props: {
14
15
  item: {},
15
16
  depth: { default: 0 }
16
17
  },
17
- setup(i) {
18
- const n = i, e = Q("sidebar-menu-ctx");
18
+ setup(r) {
19
+ const t = r, e = U("sidebar-menu-ctx");
19
20
  if (!e)
20
21
  throw new Error("SidebarMenuItem must be used within a SidebarMenu");
21
- const V = c(() => e.compact && b.value ? "popover" : n.item.renderMode || e.renderMode || "tree"), k = c(() => V.value === "popover" && b.value), x = c(() => n.item.id ? n.item.id : n.item.to && typeof n.item.to == "string" ? n.item.to : n.item.label), b = c(() => !!n.item.children?.length), E = c(() => k.value ? !1 : e.expandedItems.includes(x.value)), C = c(() => e.activeItem === x.value), $ = (a) => {
22
- n.item.disabled || (b.value && !n.item.to && !n.item.href && (k.value || e.toggleExpand(x.value)), n.item.action && n.item.action(n.item), (!b.value || n.item.to) && e.setActive(x.value));
23
- }, I = (a) => {
24
- a.stopPropagation(), k.value || e.toggleExpand(x.value);
25
- }, S = c(() => e.indentSize || 12), M = c(() => e.compact ? { width: "100%" } : {
26
- marginLeft: `${n.depth * S.value}px`,
27
- width: `calc(100% - ${n.depth * S.value}px)`
28
- }), L = c(() => {
29
- const a = "group flex items-center justify-between text-sm font-medium rounded-md transition-all duration-200 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-primary/50 relative border border-transparent select-none cursor-pointer w-full", t = e.compact ? "justify-center py-2 px-1" : "justify-between py-2 px-2";
22
+ const K = c(() => e.compact && b.value ? "popover" : t.item.renderMode || e.renderMode || "tree"), C = c(() => K.value === "popover" && b.value), x = c(() => t.item.id ? t.item.id : t.item.to && typeof t.item.to == "string" ? t.item.to : t.item.label), b = c(() => !!t.item.children?.length), E = c(() => C.value ? !1 : e.expandedItems.includes(x.value)), I = c(() => e.activeItem === x.value), j = (a) => {
23
+ t.item.disabled || (b.value && !t.item.to && !t.item.href && (C.value || e.toggleExpand(x.value)), t.item.action && t.item.action(t.item), (!b.value || t.item.to) && e.setActive(x.value));
24
+ }, M = (a) => {
25
+ a.stopPropagation(), C.value || e.toggleExpand(x.value);
26
+ }, S = c(() => e.indentSize || 12), L = c(() => e.compact ? { width: "100%" } : {
27
+ marginLeft: `${t.depth * S.value}px`,
28
+ width: `calc(100% - ${t.depth * S.value}px)`
29
+ }), _ = c(() => {
30
+ const a = "group flex items-center justify-between text-sm font-medium rounded-md transition-all duration-200 focus-visible:outline-none focus-visible:ring-1 focus-visible:ring-primary/50 relative border border-transparent select-none cursor-pointer w-full", n = e.compact ? "justify-center py-2 px-1" : "justify-between py-2 px-2";
30
31
  let f = "";
31
- return C.value ? f = "bg-primary-light text-primary-fg-light" : f = "text-muted hover:bg-accent/80 hover:text-foreground", n.item.disabled && (f = "opacity-50 cursor-not-allowed pointer-events-none"), `${a} ${t} ${f} ${n.item.class || ""}`;
32
- }), u = c(() => e.compact && e.showCompactLabels), B = (a) => ({
33
- label: a.label,
32
+ return I.value ? f = "bg-primary-light text-primary-fg-light" : f = "text-muted hover:bg-accent/80 hover:text-foreground", t.item.disabled && (f = "opacity-50 cursor-not-allowed pointer-events-none"), `${a} ${n} ${f} ${t.item.class || ""}`;
33
+ }), u = c(() => e.compact && e.showCompactLabels), w = c(() => t.item.labelI18n ? V(t.item.labelI18n) : t.item.label), B = (a) => ({
34
+ label: a.labelI18n ? V(a.labelI18n) : a.label,
34
35
  value: a.id || a.label,
35
36
  icon: a.icon,
36
37
  disabled: a.disabled,
37
38
  children: a.children ? a.children.map(B) : void 0,
38
39
  data: a
39
- }), K = c(() => n.item.children ? n.item.children.map(B) : []), T = (a) => {
40
- const t = a.data;
41
- if (t) {
42
- t.action && t.action(t);
43
- const f = t.id || t.label || (typeof t.to == "string" ? t.to : "");
40
+ }), T = c(() => t.item.children ? t.item.children.map(B) : []), H = (a) => {
41
+ const n = a.data;
42
+ if (n) {
43
+ n.action && n.action(n);
44
+ const f = n.id || n.label || (typeof n.to == "string" ? n.to : "");
44
45
  f && e.setActive(f);
45
46
  }
46
- }, H = (a) => {
47
- const t = a;
48
- t.style.height = "0", t.style.opacity = "0";
49
47
  }, F = (a) => {
50
- const t = a;
51
- t.style.height = t.scrollHeight + "px", t.style.opacity = "1";
48
+ const n = a;
49
+ n.style.height = "0", n.style.opacity = "0";
52
50
  }, R = (a) => {
53
- const t = a;
54
- t.style.height = "auto", t.style.overflow = "visible";
51
+ const n = a;
52
+ n.style.height = n.scrollHeight + "px", n.style.opacity = "1";
55
53
  }, q = (a) => {
56
- const t = a;
57
- t.style.height = t.scrollHeight + "px", t.style.overflow = "hidden", t.style.opacity = "1";
54
+ const n = a;
55
+ n.style.height = "auto", n.style.overflow = "visible";
58
56
  }, G = (a) => {
59
- const t = a;
60
- t.style.height = "0", t.style.opacity = "0";
61
- }, N = c(() => n.item.to ? "router-link" : n.item.href ? "a" : "button"), z = c(() => n.item.to ? { to: n.item.to } : n.item.href ? {
62
- href: n.item.href,
57
+ const n = a;
58
+ n.style.height = n.scrollHeight + "px", n.style.overflow = "hidden", n.style.opacity = "1";
59
+ }, J = (a) => {
60
+ const n = a;
61
+ n.style.height = "0", n.style.opacity = "0";
62
+ }, N = c(() => t.item.to ? "router-link" : t.item.href ? "a" : "button"), z = c(() => t.item.to ? { to: t.item.to } : t.item.href ? {
63
+ href: t.item.href,
63
64
  target: "_blank",
64
65
  rel: "noopener noreferrer"
65
66
  } : { type: "button" });
66
- return (a, t) => {
67
- const f = U("SidebarMenuItem", !0);
68
- return l(), m("div", te, [
69
- k.value ? (l(), h(r(ee), {
67
+ return (a, n) => {
68
+ const f = W("SidebarMenuItem", !0);
69
+ return o(), m("div", ae, [
70
+ C.value ? (o(), p(l(ne), {
70
71
  key: 0,
71
72
  position: "right-start",
72
73
  offset: [0, 10],
73
74
  class: "w-full",
74
75
  searchable: !1,
75
76
  width: "220px",
76
- options: K.value,
77
- onOnSelect: T
77
+ options: T.value,
78
+ onOnSelect: H
78
79
  }, {
79
- header: p(() => [
80
- r(e).compact ? (l(), m("div", ne, [
81
- i.item.icon ? (l(), h(g, {
80
+ header: h(() => [
81
+ l(e).compact ? (o(), m("div", ie, [
82
+ r.item.icon ? (o(), p(g, {
82
83
  key: 0,
83
- icon: i.item.icon,
84
+ icon: r.item.icon,
84
85
  class: "shrink-0 transition-colors opacity-80 group-hover:opacity-100"
85
86
  }, null, 8, ["icon"])) : d("", !0),
86
- W(" " + y(i.item.label), 1)
87
+ X(" " + y(w.value), 1)
87
88
  ])) : d("", !0)
88
89
  ]),
89
- trigger: p(({ isOpen: o }) => [
90
- w(P, {
91
- content: i.item.label,
90
+ trigger: h(({ isOpen: i }) => [
91
+ k(P, {
92
+ content: w.value,
92
93
  placement: "right",
93
94
  className: "sidebar-menu-tooltip",
94
- disabled: !r(e).compact || o,
95
+ disabled: !l(e).compact || i,
95
96
  class: "w-full block"
96
97
  }, {
97
- default: p(() => [
98
- v("div", ae, [
99
- (l(), h(j(N.value), A(z.value, {
100
- class: [L.value, o ? "bg-muted text-foreground" : ""],
101
- style: M.value,
98
+ default: h(() => [
99
+ v("div", oe, [
100
+ (o(), p($(N.value), A(z.value, {
101
+ class: [_.value, i ? "bg-muted text-foreground" : ""],
102
+ style: L.value,
102
103
  "aria-haspopup": !0,
103
- "aria-expanded": o,
104
- onClick: $
104
+ "aria-expanded": i,
105
+ onClick: j
105
106
  }), {
106
- default: p(() => [
107
+ default: h(() => [
107
108
  v("div", {
108
109
  class: s(["min-w-0 flex-1 flex", [
109
- u.value ? "flex-col items-center justify-center gap-1" : r(e).compact ? "justify-center" : "items-center gap-2.5"
110
+ u.value ? "flex-col items-center justify-center gap-1" : l(e).compact ? "justify-center" : "items-center gap-2.5"
110
111
  ]])
111
112
  }, [
112
- i.item.icon ? (l(), h(g, {
113
+ r.item.icon ? (o(), p(g, {
113
114
  key: 0,
114
- icon: i.item.icon,
115
+ icon: r.item.icon,
115
116
  class: s(["shrink-0 transition-colors opacity-70 group-hover:opacity-100", [
116
- C.value || o ? "opacity-100" : "",
117
- r(e).compact ? "h-5 w-5" : "h-4 w-4"
117
+ I.value || i ? "opacity-100" : "",
118
+ l(e).compact ? "h-5 w-5" : "h-4 w-4"
118
119
  ]])
119
120
  }, null, 8, ["icon", "class"])) : d("", !0),
120
121
  v("span", {
121
122
  class: s(["truncate leading-none pt-0.5", {
122
123
  "text-[10px]": u.value,
123
- hidden: r(e).compact && !u.value,
124
- "md:hidden": r(e).compact && !u.value
124
+ hidden: l(e).compact && !u.value,
125
+ "md:hidden": l(e).compact && !u.value
125
126
  }])
126
- }, y(i.item.label), 3),
127
- i.item.badge && (!r(e).compact || !u.value) ? (l(), m("span", {
127
+ }, y(w.value), 3),
128
+ r.item.badge && (!l(e).compact || !u.value) ? (o(), m("span", {
128
129
  key: 1,
129
130
  class: s(["ml-auto inline-flex items-center px-1.5 py-0.5 rounded text-[10px] font-medium", [
130
- i.item.badgeClass || "bg-muted text-muted-foreground",
131
- { "md:hidden": r(e).compact }
131
+ r.item.badgeClass || "bg-muted text-muted-foreground",
132
+ { "md:hidden": l(e).compact }
132
133
  ]])
133
- }, y(i.item.badge), 3)) : d("", !0)
134
+ }, y(r.item.badge), 3)) : d("", !0)
134
135
  ], 2),
135
136
  v("div", {
136
- class: s(["ml-1.5 flex h-4 w-4 shrink-0 items-center justify-center text-muted-foreground", { "md:hidden": r(e).compact }])
137
+ class: s(["ml-1.5 flex h-4 w-4 shrink-0 items-center justify-center text-muted-foreground", { "md:hidden": l(e).compact }])
137
138
  }, [
138
- w(g, {
139
+ k(g, {
139
140
  icon: "lucide:chevron-right",
140
141
  class: "h-3 w-3"
141
142
  })
@@ -148,111 +149,111 @@ const te = { class: "w-full relative sidebar-manu-item" }, ne = {
148
149
  _: 2
149
150
  }, 1032, ["content", "disabled"])
150
151
  ]),
151
- item: p(({ option: o }) => [
152
- (l(), h(j(o.data?.to ? "router-link" : o.data?.href ? "a" : "div"), {
153
- to: o.data?.to,
154
- href: o.data?.href,
152
+ item: h(({ option: i }) => [
153
+ (o(), p($(i.data?.to ? "router-link" : i.data?.href ? "a" : "div"), {
154
+ to: i.data?.to,
155
+ href: i.data?.href,
155
156
  target: "option.data?.href ? '_blank' : undefined",
156
157
  class: "flex items-center w-full gap-2 text-sm"
157
158
  }, {
158
- default: p(() => [
159
- o.icon ? (l(), h(g, {
159
+ default: h(() => [
160
+ i.icon ? (o(), p(g, {
160
161
  key: 0,
161
- icon: o.icon,
162
+ icon: i.icon,
162
163
  class: "h-4 w-4 shrink-0 opacity-70"
163
164
  }, null, 8, ["icon"])) : d("", !0),
164
- v("span", ie, y(o.label), 1),
165
- o.data?.badge ? (l(), m("span", {
165
+ v("span", le, y(i.label), 1),
166
+ i.data?.badge ? (o(), m("span", {
166
167
  key: 1,
167
- class: s(["ml-auto inline-flex items-center px-1.5 py-0.5 rounded text-[10px] font-medium", o.data?.badgeClass || "bg-muted text-muted-foreground"])
168
- }, y(o.data.badge), 3)) : d("", !0)
168
+ class: s(["ml-auto inline-flex items-center px-1.5 py-0.5 rounded text-[10px] font-medium", i.data?.badgeClass || "bg-muted text-muted-foreground"])
169
+ }, y(i.data.badge), 3)) : d("", !0)
169
170
  ]),
170
171
  _: 2
171
172
  }, 1032, ["to", "href"]))
172
173
  ]),
173
174
  _: 1
174
- }, 8, ["options"])) : (l(), m(D, { key: 1 }, [
175
- w(P, {
176
- content: i.item.label,
175
+ }, 8, ["options"])) : (o(), m(D, { key: 1 }, [
176
+ k(P, {
177
+ content: w.value,
177
178
  placement: "right",
178
- disabled: !r(e).compact,
179
+ disabled: !l(e).compact,
179
180
  class: "w-full block"
180
181
  }, {
181
- default: p(() => [
182
- (l(), h(j(N.value), A(z.value, {
183
- class: L.value,
184
- style: M.value,
182
+ default: h(() => [
183
+ (o(), p($(N.value), A(z.value, {
184
+ class: _.value,
185
+ style: L.value,
185
186
  "aria-expanded": b.value ? E.value : void 0,
186
- "aria-current": C.value ? "page" : void 0,
187
- onClick: $
187
+ "aria-current": I.value ? "page" : void 0,
188
+ onClick: j
188
189
  }), {
189
- default: p(() => [
190
+ default: h(() => [
190
191
  v("div", {
191
192
  class: s(["min-w-0 flex-1 flex", [
192
- u.value ? "flex-col items-center justify-center gap-1" : r(e).compact ? "justify-center" : "items-center gap-2.5"
193
+ u.value ? "flex-col items-center justify-center gap-1" : l(e).compact ? "justify-center" : "items-center gap-2.5"
193
194
  ]])
194
195
  }, [
195
- i.item.icon ? (l(), h(g, {
196
+ r.item.icon ? (o(), p(g, {
196
197
  key: 0,
197
- icon: i.item.icon,
198
- class: s(["shrink-0 transition-colors opacity-70 group-hover:opacity-100", [C.value ? "opacity-100" : "", r(e).compact ? "h-5 w-5" : "h-4 w-4"]])
198
+ icon: r.item.icon,
199
+ class: s(["shrink-0 transition-colors opacity-70 group-hover:opacity-100", [I.value ? "opacity-100" : "", l(e).compact ? "h-5 w-5" : "h-4 w-4"]])
199
200
  }, null, 8, ["icon", "class"])) : d("", !0),
200
201
  v("span", {
201
202
  class: s(["truncate leading-none pt-0.5", {
202
203
  "text-[10px]": u.value,
203
- hidden: r(e).compact && !u.value,
204
- "md:hidden": r(e).compact && !u.value
204
+ hidden: l(e).compact && !u.value,
205
+ "md:hidden": l(e).compact && !u.value
205
206
  }])
206
- }, y(i.item.label), 3),
207
- i.item.badge && (!r(e).compact || !u.value) ? (l(), m("span", {
207
+ }, y(w.value), 3),
208
+ r.item.badge && (!l(e).compact || !u.value) ? (o(), m("span", {
208
209
  key: 1,
209
210
  class: s(["ml-auto inline-flex items-center px-1.5 py-0.5 rounded text-[10px] font-medium", [
210
- i.item.badgeClass || "bg-muted text-muted-foreground",
211
- { "md:hidden": r(e).compact }
211
+ r.item.badgeClass || "bg-muted text-muted-foreground",
212
+ { "md:hidden": l(e).compact }
212
213
  ]])
213
- }, y(i.item.badge), 3)) : d("", !0)
214
+ }, y(r.item.badge), 3)) : d("", !0)
214
215
  ], 2),
215
- b.value ? (l(), m("div", {
216
+ b.value ? (o(), m("div", {
216
217
  key: 0,
217
218
  role: "button",
218
219
  tabindex: "0",
219
- class: s(["ml-1.5 flex h-4 w-4 shrink-0 items-center justify-center rounded-sm text-muted-foreground hover:bg-accent/50 hover:text-foreground transition-all", { "md:hidden": r(e).compact }]),
220
- onClick: I,
221
- onKeydown: X(Y(I, ["prevent"]), ["enter", "space"])
220
+ class: s(["ml-1.5 flex h-4 w-4 shrink-0 items-center justify-center rounded-sm text-muted-foreground hover:bg-accent/50 hover:text-foreground transition-all", { "md:hidden": l(e).compact }]),
221
+ onClick: M,
222
+ onKeydown: Y(Z(M, ["prevent"]), ["enter", "space"])
222
223
  }, [
223
- w(g, {
224
+ k(g, {
224
225
  icon: "lucide:chevron-down",
225
226
  class: s(["h-3 w-3 transition-transform duration-200", { "rotate-180": E.value }])
226
227
  }, null, 8, ["class"])
227
- ], 42, oe)) : d("", !0)
228
+ ], 42, re)) : d("", !0)
228
229
  ]),
229
230
  _: 1
230
231
  }, 16, ["class", "style", "aria-expanded", "aria-current"]))
231
232
  ]),
232
233
  _: 1
233
234
  }, 8, ["content", "disabled"]),
234
- w(Z, {
235
+ k(O, {
235
236
  name: "sidebar-slide",
236
- onBeforeEnter: H,
237
- onEnter: F,
238
- onAfterEnter: R,
239
- onBeforeLeave: q,
240
- onLeave: G
237
+ onBeforeEnter: F,
238
+ onEnter: R,
239
+ onAfterEnter: q,
240
+ onBeforeLeave: G,
241
+ onLeave: J
241
242
  }, {
242
- default: p(() => [
243
- b.value && E.value ? (l(), m("div", le, [
244
- r(e).variant === "default" ? (l(), m("div", {
243
+ default: h(() => [
244
+ b.value && E.value ? (o(), m("div", ce, [
245
+ l(e).variant === "default" ? (o(), m("div", {
245
246
  key: 0,
246
247
  class: "absolute top-0 bottom-2 w-px bg-border",
247
- style: O({
248
- left: `${(i.depth + 1) * S.value - S.value / 2}px`
248
+ style: ee({
249
+ left: `${(r.depth + 1) * S.value - S.value / 2}px`
249
250
  })
250
251
  }, null, 4)) : d("", !0),
251
- v("div", re, [
252
- (l(!0), m(D, null, _(i.item.children, (o) => (l(), h(f, {
253
- key: o.id || o.label,
254
- item: o,
255
- depth: i.depth + 1
252
+ v("div", se, [
253
+ (o(!0), m(D, null, te(r.item.children, (i) => (o(), p(f, {
254
+ key: i.id || i.label,
255
+ item: i,
256
+ depth: r.depth + 1
256
257
  }, null, 8, ["item", "depth"]))), 128))
257
258
  ])
258
259
  ])) : d("", !0)
@@ -265,5 +266,5 @@ const te = { class: "w-full relative sidebar-manu-item" }, ne = {
265
266
  }
266
267
  });
267
268
  export {
268
- me as default
269
+ he as default
269
270
  };
@@ -1,6 +1,7 @@
1
1
  export interface SidebarMenuItemSchema {
2
2
  id?: string;
3
3
  label: string;
4
+ labelI18n?: string;
4
5
  icon?: string;
5
6
  to?: string | Record<string, any>;
6
7
  href?: string;
@@ -3,6 +3,7 @@ type __VLS_Props = {
3
3
  max?: number;
4
4
  step?: number;
5
5
  label?: string;
6
+ labelI18n?: string;
6
7
  icon?: string;
7
8
  disabled?: boolean;
8
9
  showValue?: boolean;