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.
- package/components/Accordion/AccordionItem.vue.js +33 -32
- package/components/Accordion/types.d.ts +2 -0
- package/components/Alert.vue.d.ts +2 -0
- package/components/Alert.vue.js +38 -36
- package/components/AvatarUploader/AvatarUploader.vue.d.ts +1 -1
- package/components/AvatarUploader/AvatarUploader.vue.js +25 -24
- package/components/Button.vue.d.ts +1 -1
- package/components/Button.vue.js +37 -35
- package/components/CheckBox.vue.d.ts +1 -0
- package/components/CheckBox.vue.js +40 -40
- package/components/Chip/Chip.vue.js +55 -55
- package/components/Chip/types.d.ts +1 -0
- package/components/ChoiceBox/ChoiceBox.vue.d.ts +5 -0
- package/components/ChoiceBox/ChoiceBox.vue.js +61 -58
- package/components/ColorPicker/ColorPicker.vue.js +3 -2
- package/components/ConfirmationModal.vue.d.ts +4 -2
- package/components/ConfirmationModal.vue.js +48 -33
- package/components/DataList/DataList.vue.d.ts +0 -2
- package/components/DataList/DataList.vue.js +39 -35
- package/components/DataList/types.d.ts +2 -0
- package/components/DataTable/DataTable.vue.d.ts +0 -5
- package/components/DataTable/DataTable.vue.js +177 -158
- package/components/DataTable/DataTableHeader.vue.js +15 -14
- package/components/DataTable/DataTableToolbar.vue.d.ts +1 -1
- package/components/DataTable/DataTableToolbar.vue.js +30 -23
- package/components/DataTable/types.d.ts +4 -0
- package/components/DatePicker.vue.d.ts +1 -0
- package/components/DatePicker.vue.js +32 -25
- package/components/Dropdown/DropdownBooleanItem.vue.js +18 -17
- package/components/Dropdown/DropdownGroupedLayout.vue.js +28 -27
- package/components/Dropdown/DropdownItem.vue.js +24 -23
- package/components/Dropdown/DropdownMenu.vue.js +100 -91
- package/components/Dropdown/composables/useDropdownNavigation.js +24 -23
- package/components/Dropdown/composables/useDropdownSelection.js +19 -17
- package/components/Empty/Empty.vue.d.ts +2 -2
- package/components/Empty/Empty.vue.js +32 -18
- package/components/FilePicker/FilePicker.vue.d.ts +3 -1
- package/components/FilePicker/FilePicker.vue.js +140 -127
- package/components/FileTree/FileTree.vue.js +68 -58
- package/components/FileTree/FileTreeNode.vue.js +35 -34
- package/components/FileTree/types.d.ts +3 -0
- package/components/Form/CustomFields.vue.d.ts +3 -1
- package/components/Form/CustomFields.vue.js +2 -2
- package/components/Form/CustomFields.vue2.js +92 -80
- package/components/Form/Form.vue.d.ts +1 -1
- package/components/Form/FormField.vue.d.ts +1 -1
- package/components/Form/FormField.vue.js +60 -59
- package/components/Form/FormFields.vue.js +2 -2
- package/components/Form/FormFields.vue2.js +58 -57
- package/components/Form/composables/useForm.js +91 -88
- package/components/Form/types.d.ts +4 -0
- package/components/Form/utils/form.utils.js +104 -98
- package/components/GoogleLogin.vue.d.ts +1 -1
- package/components/GoogleLogin.vue.js +39 -32
- package/components/Heatmap/Heatmap.vue2.js +3 -2
- package/components/IconPicker.vue.d.ts +2 -0
- package/components/IconPicker.vue.js +37 -29
- package/components/Input.vue.d.ts +1 -1
- package/components/Input.vue.js +96 -98
- package/components/Kanban/KanbanBoard.vue.js +1 -1
- package/components/Kanban/KanbanBoard.vue2.js +55 -54
- package/components/Kanban/types.d.ts +1 -0
- package/components/Masonry/Masonry.vue2.js +3 -2
- package/components/Modal.vue.d.ts +2 -0
- package/components/Modal.vue.js +62 -57
- package/components/MultiSelect/MultiSelect.vue.d.ts +1 -1
- package/components/MultiSelect/MultiSelect.vue.js +61 -54
- package/components/Navbar/Navbar.vue.js +46 -46
- package/components/Pagination/Pagination.vue.js +116 -97
- package/components/PricingPlan/PricingPlanItem.vue.js +60 -47
- package/components/PricingPlan/types.d.ts +5 -0
- package/components/Screen/Screen.vue.d.ts +0 -4
- package/components/Screen/Screen.vue.js +231 -189
- package/components/Screen/ScreenFilter.vue.js +73 -63
- package/components/Screen/types.d.ts +5 -0
- package/components/SidePanel.vue.d.ts +2 -0
- package/components/SidePanel.vue.js +140 -5
- package/components/SidePanel.vue2.js +2 -135
- package/components/SidebarMenu/SidebarMenuItem.vue.js +131 -130
- package/components/SidebarMenu/types.d.ts +1 -0
- package/components/Slider.vue.d.ts +1 -0
- package/components/Slider.vue.js +71 -69
- package/components/Switch.vue.d.ts +1 -0
- package/components/Switch.vue.js +23 -18
- package/components/Tabes/Tabes.vue.js +20 -19
- package/components/Tabes/types.d.ts +1 -0
- package/components/Textarea.vue.d.ts +1 -0
- package/components/Textarea.vue.js +18 -16
- package/components/ThemeToggle.vue.js +24 -14
- package/components/Timeline.vue.js +68 -82
- package/components/ToastNotification.vue.js +2 -2
- package/components/Tooltip.vue.d.ts +4 -3
- package/components/Tooltip.vue.js +17 -15
- package/components/Workbook/Sheet.vue.js +80 -71
- package/components/Workbook/WorkbookAddButton.vue.js +14 -10
- package/components/Workbook/types.d.ts +1 -0
- package/core/config.d.ts +2 -0
- package/index.d.ts +1 -0
- package/index.js +28 -26
- package/package.json +1 -1
- package/style.css +1 -2
- package/types/button.d.ts +1 -0
- package/types/config.type.d.ts +10 -0
- package/types/form.type.d.ts +2 -0
- package/types/styles.d.ts +3 -0
- package/types/timeline.type.d.ts +2 -0
- package/utils/i18n.d.ts +8 -0
- package/utils/i18n.js +5 -0
- package/utils/index.d.ts +1 -0
|
@@ -1,141 +1,142 @@
|
|
|
1
|
-
import { defineComponent as
|
|
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
|
|
5
|
-
|
|
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
|
-
},
|
|
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
|
-
},
|
|
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(
|
|
18
|
-
const
|
|
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
|
|
22
|
-
|
|
23
|
-
},
|
|
24
|
-
a.stopPropagation(),
|
|
25
|
-
}, S = c(() => e.indentSize || 12),
|
|
26
|
-
marginLeft: `${
|
|
27
|
-
width: `calc(100% - ${
|
|
28
|
-
}),
|
|
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",
|
|
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
|
|
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
|
-
}),
|
|
40
|
-
const
|
|
41
|
-
if (
|
|
42
|
-
|
|
43
|
-
const f =
|
|
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
|
|
51
|
-
|
|
48
|
+
const n = a;
|
|
49
|
+
n.style.height = "0", n.style.opacity = "0";
|
|
52
50
|
}, R = (a) => {
|
|
53
|
-
const
|
|
54
|
-
|
|
51
|
+
const n = a;
|
|
52
|
+
n.style.height = n.scrollHeight + "px", n.style.opacity = "1";
|
|
55
53
|
}, q = (a) => {
|
|
56
|
-
const
|
|
57
|
-
|
|
54
|
+
const n = a;
|
|
55
|
+
n.style.height = "auto", n.style.overflow = "visible";
|
|
58
56
|
}, G = (a) => {
|
|
59
|
-
const
|
|
60
|
-
|
|
61
|
-
},
|
|
62
|
-
|
|
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,
|
|
67
|
-
const f =
|
|
68
|
-
return
|
|
69
|
-
|
|
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:
|
|
77
|
-
onOnSelect:
|
|
77
|
+
options: T.value,
|
|
78
|
+
onOnSelect: H
|
|
78
79
|
}, {
|
|
79
|
-
header:
|
|
80
|
-
|
|
81
|
-
|
|
80
|
+
header: h(() => [
|
|
81
|
+
l(e).compact ? (o(), m("div", ie, [
|
|
82
|
+
r.item.icon ? (o(), p(g, {
|
|
82
83
|
key: 0,
|
|
83
|
-
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
|
-
|
|
87
|
+
X(" " + y(w.value), 1)
|
|
87
88
|
])) : d("", !0)
|
|
88
89
|
]),
|
|
89
|
-
trigger:
|
|
90
|
-
|
|
91
|
-
content:
|
|
90
|
+
trigger: h(({ isOpen: i }) => [
|
|
91
|
+
k(P, {
|
|
92
|
+
content: w.value,
|
|
92
93
|
placement: "right",
|
|
93
94
|
className: "sidebar-menu-tooltip",
|
|
94
|
-
disabled: !
|
|
95
|
+
disabled: !l(e).compact || i,
|
|
95
96
|
class: "w-full block"
|
|
96
97
|
}, {
|
|
97
|
-
default:
|
|
98
|
-
v("div",
|
|
99
|
-
(
|
|
100
|
-
class: [
|
|
101
|
-
style:
|
|
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":
|
|
104
|
-
onClick:
|
|
104
|
+
"aria-expanded": i,
|
|
105
|
+
onClick: j
|
|
105
106
|
}), {
|
|
106
|
-
default:
|
|
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" :
|
|
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
|
-
|
|
113
|
+
r.item.icon ? (o(), p(g, {
|
|
113
114
|
key: 0,
|
|
114
|
-
icon:
|
|
115
|
+
icon: r.item.icon,
|
|
115
116
|
class: s(["shrink-0 transition-colors opacity-70 group-hover:opacity-100", [
|
|
116
|
-
|
|
117
|
-
|
|
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:
|
|
124
|
-
"md:hidden":
|
|
124
|
+
hidden: l(e).compact && !u.value,
|
|
125
|
+
"md:hidden": l(e).compact && !u.value
|
|
125
126
|
}])
|
|
126
|
-
}, y(
|
|
127
|
-
|
|
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
|
-
|
|
131
|
-
{ "md:hidden":
|
|
131
|
+
r.item.badgeClass || "bg-muted text-muted-foreground",
|
|
132
|
+
{ "md:hidden": l(e).compact }
|
|
132
133
|
]])
|
|
133
|
-
}, y(
|
|
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":
|
|
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
|
-
|
|
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:
|
|
152
|
-
(
|
|
153
|
-
to:
|
|
154
|
-
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:
|
|
159
|
-
|
|
159
|
+
default: h(() => [
|
|
160
|
+
i.icon ? (o(), p(g, {
|
|
160
161
|
key: 0,
|
|
161
|
-
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",
|
|
165
|
-
|
|
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",
|
|
168
|
-
}, y(
|
|
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"])) : (
|
|
175
|
-
|
|
176
|
-
content:
|
|
175
|
+
}, 8, ["options"])) : (o(), m(D, { key: 1 }, [
|
|
176
|
+
k(P, {
|
|
177
|
+
content: w.value,
|
|
177
178
|
placement: "right",
|
|
178
|
-
disabled: !
|
|
179
|
+
disabled: !l(e).compact,
|
|
179
180
|
class: "w-full block"
|
|
180
181
|
}, {
|
|
181
|
-
default:
|
|
182
|
-
(
|
|
183
|
-
class:
|
|
184
|
-
style:
|
|
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":
|
|
187
|
-
onClick:
|
|
187
|
+
"aria-current": I.value ? "page" : void 0,
|
|
188
|
+
onClick: j
|
|
188
189
|
}), {
|
|
189
|
-
default:
|
|
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" :
|
|
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
|
-
|
|
196
|
+
r.item.icon ? (o(), p(g, {
|
|
196
197
|
key: 0,
|
|
197
|
-
icon:
|
|
198
|
-
class: s(["shrink-0 transition-colors opacity-70 group-hover:opacity-100", [
|
|
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:
|
|
204
|
-
"md:hidden":
|
|
204
|
+
hidden: l(e).compact && !u.value,
|
|
205
|
+
"md:hidden": l(e).compact && !u.value
|
|
205
206
|
}])
|
|
206
|
-
}, y(
|
|
207
|
-
|
|
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
|
-
|
|
211
|
-
{ "md:hidden":
|
|
211
|
+
r.item.badgeClass || "bg-muted text-muted-foreground",
|
|
212
|
+
{ "md:hidden": l(e).compact }
|
|
212
213
|
]])
|
|
213
|
-
}, y(
|
|
214
|
+
}, y(r.item.badge), 3)) : d("", !0)
|
|
214
215
|
], 2),
|
|
215
|
-
b.value ? (
|
|
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":
|
|
220
|
-
onClick:
|
|
221
|
-
onKeydown:
|
|
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
|
-
|
|
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,
|
|
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
|
-
|
|
235
|
+
k(O, {
|
|
235
236
|
name: "sidebar-slide",
|
|
236
|
-
onBeforeEnter:
|
|
237
|
-
onEnter:
|
|
238
|
-
onAfterEnter:
|
|
239
|
-
onBeforeLeave:
|
|
240
|
-
onLeave:
|
|
237
|
+
onBeforeEnter: F,
|
|
238
|
+
onEnter: R,
|
|
239
|
+
onAfterEnter: q,
|
|
240
|
+
onBeforeLeave: G,
|
|
241
|
+
onLeave: J
|
|
241
242
|
}, {
|
|
242
|
-
default:
|
|
243
|
-
b.value && E.value ? (
|
|
244
|
-
|
|
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:
|
|
248
|
-
left: `${(
|
|
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",
|
|
252
|
-
(
|
|
253
|
-
key:
|
|
254
|
-
item:
|
|
255
|
-
depth:
|
|
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
|
-
|
|
269
|
+
he as default
|
|
269
270
|
};
|