vlite3 1.4.40 → 1.4.41
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/AppShell/AppShellLayoutClassic.vue.js +27 -28
- package/components/AppShell/AppShellLayoutDashboard.vue.js +48 -48
- package/components/AppShell/AppShellLayoutDock.vue.js +51 -51
- package/components/AppShell/AppShellLayoutHeaderShell.vue.js +69 -69
- package/components/AppShell/AppShellLayoutSidebarFirst.vue.d.ts +2 -2
- package/components/AppShell/AppShellLayoutSidebarFirst.vue.js +78 -78
- package/components/AppShell/AppShellLayoutStorefront.vue.js +14 -15
- package/components/AppShell/useAppShell.d.ts +4 -0
- package/components/AppShell/useAppShell.js +45 -40
- package/components/AsyncSelect/createAsyncSelect.js +10 -10
- package/components/AttachmentsList/AttachmentsList.vue.d.ts +50 -2
- package/components/AttachmentsList/AttachmentsList.vue.js +289 -272
- package/components/AttachmentsList/types.d.ts +37 -0
- package/components/BackButton.vue.js +2 -2
- package/components/Button.vue.d.ts +1 -0
- package/components/Button.vue.js +5 -241
- package/components/Button.vue2.js +245 -2
- package/components/ButtonGroup.vue.js +2 -2
- package/components/ButtonGroup.vue2.js +4 -1
- package/components/Calendar/Calendar.vue2.js +16 -16
- package/components/Cart/CartCouponInput.vue.js +24 -24
- package/components/Cart/CartEmptyState.vue.js +4 -4
- package/components/Cart/CartLineItem.vue.js +33 -33
- package/components/Cart/CartVariant1.vue.js +3 -3
- package/components/Cart/CartVariant2.vue.js +5 -5
- package/components/Cart/CartVariant3.vue.js +25 -25
- package/components/Cart/CartVariant4.vue.js +9 -9
- package/components/CategoryManager/CategoryManager.vue2.js +19 -19
- package/components/CategoryManager/CategoryNode.vue.js +4 -4
- package/components/CategoryMenu/CategoryMenu.vue.js +3 -2
- package/components/CategoryMenu/CategoryMenuVariant1.vue2.js +3 -2
- package/components/Chat/ChatInterface.vue.js +23 -23
- package/components/Clipboard.vue.d.ts +7 -1
- package/components/Clipboard.vue.js +19 -17
- package/components/ColorPicker/{ColorIro.vue.js → ColorIro.vue2.js} +22 -22
- package/components/ColorPicker/ColorIro.vue3.js +2 -2
- package/components/ColorPicker/ColorPicker.vue.js +8 -8
- package/components/CommandPalette/CommandPaletteContent.vue2.js +1 -1
- package/components/CommandPalette/{CommandPaletteItem.vue.js → CommandPaletteItem.vue2.js} +1 -1
- package/components/Comment/CommentEditor.vue.js +14 -14
- package/components/Comment/CommentItem.vue2.js +6 -6
- package/components/Comment/CommentThread.vue.js +4 -4
- package/components/DataList/DataList.vue.js +7 -7
- package/components/DataTable/DataTable.vue.d.ts +8 -0
- package/components/DataTable/DataTable.vue.js +374 -263
- package/components/DataTable/DataTableRow.vue.d.ts +23 -2
- package/components/DataTable/DataTableRow.vue.js +5 -198
- package/components/DataTable/DataTableRow.vue2.js +360 -2
- package/components/DataTable/dataTableHeaders.d.ts +18 -0
- package/components/DataTable/dataTableHeaders.js +9 -0
- package/components/DataTable/types.d.ts +6 -0
- package/components/DatePicker.vue.js +8 -9
- package/components/DateRangePicker.vue2.js +34 -34
- package/components/Dropdown/Dropdown.vue.d.ts +7 -2
- package/components/Dropdown/Dropdown.vue.js +146 -139
- package/components/Dropdown/DropdownTrigger.vue.js +6 -6
- package/components/ExportData/ExportData.vue.js +15 -15
- package/components/FilePicker/FilePickerDropzone.vue.js +16 -16
- package/components/FilePicker/FilePickerInput.vue.js +3 -2
- package/components/FilePicker/FilePreview.vue.js +3 -3
- package/components/FileTree/FileTree.vue.js +4 -4
- package/components/FileTree/FileTree.vue2.js +9 -9
- package/components/FileTree/FileTreeNode.vue.js +76 -72
- package/components/Footer/Variant1.vue.js +48 -48
- package/components/Footer/Variant2.vue.js +42 -42
- package/components/Form/AccordionView.vue.d.ts +1 -1
- package/components/Form/{AccordionView.vue.js → AccordionView.vue2.js} +3 -3
- package/components/Form/AccordionView.vue3.js +61 -57
- package/components/Form/Form.vue2.js +41 -41
- package/components/Form/TableRow.vue.d.ts +7 -0
- package/components/Form/TableRow.vue.js +187 -41
- package/components/Form/TableView.vue.d.ts +11 -1
- package/components/Form/TableView.vue.js +71 -49
- package/components/Form/composables/useForm.js +146 -142
- package/components/Form/index.vue.d.ts +5 -1
- package/components/Form/index.vue.js +2 -2
- package/components/Form/index.vue2.js +45 -38
- package/components/Form/rowHelpers.d.ts +20 -0
- package/components/Form/rowHelpers.js +76 -28
- package/components/Form/types.d.ts +11 -0
- package/components/GoogleLogin.vue.js +4 -4
- package/components/IconPicker.vue.js +9 -9
- package/components/ImportData/ImportData.vue.js +11 -11
- package/components/ImportData/ImportStep1.vue.js +10 -10
- package/components/ImportData/ImportStep2.vue.js +15 -14
- package/components/Input.vue.js +133 -129
- package/components/Kanban/KanbanBoard.vue.js +1 -1
- package/components/Kanban/KanbanBoard.vue2.js +9 -9
- package/components/MultiSelect/MultiSelect.vue.js +3 -2
- package/components/Navbar/Navbar.vue.js +17 -17
- package/components/Navbar/NavbarGroup.vue.js +8 -7
- package/components/Navbar/NavbarItem.vue.js +40 -39
- package/components/Navbar/NavbarTabs.vue.js +6 -184
- package/components/Navbar/NavbarTabs.vue2.js +204 -0
- package/components/Navbar/useNavbar.js +3 -3
- package/components/NavbarCommandPalette.vue.js +2 -2
- package/components/NumberInput.vue.js +2 -2
- package/components/NumberInput.vue2.js +81 -77
- package/components/OTPInput/OTPInput.vue.js +24 -23
- package/components/Pagination/Pagination.vue.d.ts +1 -1
- package/components/Pagination/Pagination.vue.js +5 -274
- package/components/Pagination/Pagination.vue2.js +283 -2
- package/components/PermissionMatrix/PermissionTopBar.vue.js +19 -18
- package/components/PricingPlan/PricingPlanItem.vue.js +7 -7
- package/components/Screen/Screen.vue.d.ts +1 -1
- package/components/Screen/Screen.vue.js +21 -21
- package/components/Screen/ScreenFilter.vue.js +6 -6
- package/components/Screen/components/ScreenAddAction.vue.js +3 -3
- package/components/Screen/components/ScreenEmptyState.vue.js +10 -10
- package/components/Screen/components/ScreenExportModal.vue.js +12 -12
- package/components/Screen/components/ScreenOptionsDropdown.vue.js +5 -5
- package/components/Screen/components/ScreenToolbar.vue.js +15 -15
- package/components/SidePanel.vue.js +2 -2
- package/components/SidePanel.vue2.js +6 -6
- package/components/SidebarMenu/SidebarMenu.vue.js +77 -72
- package/components/SidebarMenu/SidebarMenuItem.vue.js +172 -168
- package/components/Slider.vue.js +123 -108
- package/components/Tabes/Tabes.vue.d.ts +8 -3
- package/components/Tabes/Tabes.vue.js +2 -2
- package/components/Tabes/Tabes.vue2.js +209 -200
- package/components/Tabes/tabes.utils.d.ts +23 -0
- package/components/Tabes/tabes.utils.js +39 -16
- package/components/Textarea.vue.d.ts +2 -0
- package/components/Textarea.vue.js +19 -16
- package/components/ThemeToggle.vue.js +8 -8
- package/components/ToastNotification.vue2.js +10 -10
- package/components/TreeConnectors/TreeConnectors.vue.d.ts +1 -1
- package/components/TreeConnectors/TreeConnectors.vue.js +13 -8
- package/components/TreeConnectors/geometry.js +77 -69
- package/components/Workbook/WorkbookAddButton.vue.js +2 -2
- package/composables/useRtl.d.ts +14 -0
- package/composables/useRtl.js +33 -0
- package/index.js +470 -471
- package/package.json +1 -1
- package/style.css +86 -1
- package/types/button.d.ts +8 -0
- package/components/Navbar/NavbarTabs.vue3.js +0 -5
|
@@ -2,7 +2,7 @@ import { defineComponent as x, computed as m, markRaw as w, resolveComponent as
|
|
|
2
2
|
import c from "../../Button.vue.js";
|
|
3
3
|
import V from "../../Modal.vue.js";
|
|
4
4
|
import { $t as g } from "../../../utils/i18n.js";
|
|
5
|
-
const
|
|
5
|
+
const D = ["href", "target"], F = /* @__PURE__ */ x({
|
|
6
6
|
__name: "ScreenAddAction",
|
|
7
7
|
props: {
|
|
8
8
|
canAdd: { type: Boolean },
|
|
@@ -84,13 +84,13 @@ const $ = ["href", "target"], F = /* @__PURE__ */ x({
|
|
|
84
84
|
]),
|
|
85
85
|
_: 1
|
|
86
86
|
}, 16, ["icon", "variant"])
|
|
87
|
-
], 8,
|
|
87
|
+
], 8, D)) : (d(), o(c, e({
|
|
88
88
|
key: 3,
|
|
89
89
|
class: "w-full sm:w-auto",
|
|
90
90
|
icon: t.addBtn.icon || "fluent:add-16-filled",
|
|
91
91
|
variant: t.addBtn.variant || "primary"
|
|
92
92
|
}, t.addBtn.buttonProps, {
|
|
93
|
-
onClick: s[0] || (s[0] = (
|
|
93
|
+
onClick: s[0] || (s[0] = (I) => t.addBtn.onClick ? t.addBtn.onClick() : b("add"))
|
|
94
94
|
}), {
|
|
95
95
|
default: n(() => [
|
|
96
96
|
i(r(l.value), 1)
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import { defineComponent as p, computed as m, markRaw as k, resolveComponent as C, openBlock as n, createBlock as a, unref as h, withCtx as d, createElementBlock as o, Fragment as u, resolveDynamicComponent as w, mergeProps as i, createVNode as
|
|
1
|
+
import { defineComponent as p, computed as m, markRaw as k, resolveComponent as C, openBlock as n, createBlock as a, unref as h, withCtx as d, createElementBlock as o, Fragment as u, resolveDynamicComponent as w, mergeProps as i, createVNode as y, createTextVNode as B, toDisplayString as f, createCommentVNode as l } from "vue";
|
|
2
2
|
import x from "../../Empty/Empty.vue.js";
|
|
3
|
-
import
|
|
3
|
+
import s from "../../Button.vue.js";
|
|
4
4
|
import A from "../../Modal.vue.js";
|
|
5
5
|
import { $t as I } from "../../../utils/i18n.js";
|
|
6
|
-
const D = ["href", "target"],
|
|
6
|
+
const D = ["href", "target"], E = /* @__PURE__ */ p({
|
|
7
7
|
__name: "ScreenEmptyState",
|
|
8
8
|
props: {
|
|
9
9
|
emptyTitle: {},
|
|
@@ -46,14 +46,14 @@ const D = ["href", "target"], $ = /* @__PURE__ */ p({
|
|
|
46
46
|
body: b.value
|
|
47
47
|
}, e.addBtn.modalProps), {
|
|
48
48
|
trigger: d(() => [
|
|
49
|
-
|
|
49
|
+
y(s, i({
|
|
50
50
|
icon: e.addBtn.icon || "fluent:add-16-filled",
|
|
51
51
|
variant: "secondary",
|
|
52
52
|
rounded: "full",
|
|
53
53
|
class: "px-6!"
|
|
54
54
|
}, e.addBtn.buttonProps), {
|
|
55
55
|
default: d(() => [
|
|
56
|
-
|
|
56
|
+
B(f(c.value), 1)
|
|
57
57
|
]),
|
|
58
58
|
_: 1
|
|
59
59
|
}, 16, ["icon"])
|
|
@@ -65,12 +65,12 @@ const D = ["href", "target"], $ = /* @__PURE__ */ p({
|
|
|
65
65
|
class: "inline-flex"
|
|
66
66
|
}, {
|
|
67
67
|
default: d(() => [
|
|
68
|
-
|
|
68
|
+
y(s, i({
|
|
69
69
|
icon: e.addBtn.icon || "fluent:add-16-filled",
|
|
70
70
|
variant: "secondary"
|
|
71
71
|
}, e.addBtn.buttonProps), {
|
|
72
72
|
default: d(() => [
|
|
73
|
-
|
|
73
|
+
B(f(c.value), 1)
|
|
74
74
|
]),
|
|
75
75
|
_: 1
|
|
76
76
|
}, 16, ["icon"])
|
|
@@ -82,12 +82,12 @@ const D = ["href", "target"], $ = /* @__PURE__ */ p({
|
|
|
82
82
|
target: e.addBtn.target,
|
|
83
83
|
class: "inline-flex"
|
|
84
84
|
}, [
|
|
85
|
-
|
|
85
|
+
y(s, i({
|
|
86
86
|
icon: e.addBtn.icon || "lucide:plus",
|
|
87
87
|
variant: "secondary"
|
|
88
88
|
}, e.addBtn.buttonProps), {
|
|
89
89
|
default: d(() => [
|
|
90
|
-
|
|
90
|
+
B(f(c.value), 1)
|
|
91
91
|
]),
|
|
92
92
|
_: 1
|
|
93
93
|
}, 16, ["icon"])
|
|
@@ -102,5 +102,5 @@ const D = ["href", "target"], $ = /* @__PURE__ */ p({
|
|
|
102
102
|
}
|
|
103
103
|
});
|
|
104
104
|
export {
|
|
105
|
-
|
|
105
|
+
E as default
|
|
106
106
|
};
|
|
@@ -1,13 +1,13 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as E, ref as b, computed as d, openBlock as i, createBlock as p, withCtx as x, createVNode as f, mergeProps as k, createElementVNode as a, toDisplayString as v, createElementBlock as _, Fragment as g, renderList as F, isMemoSame as S } from "vue";
|
|
2
2
|
import j from "../../Modal.vue.js";
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
3
|
+
import B from "../../ExportData/ExportData.vue.js";
|
|
4
|
+
import C from "../../Button.vue.js";
|
|
5
|
+
import P from "../../Icon.vue.js";
|
|
6
6
|
import { $t as h } from "../../../utils/i18n.js";
|
|
7
|
-
const
|
|
7
|
+
const $ = {
|
|
8
8
|
class: "px-1 py-1 text-sm",
|
|
9
9
|
style: { "will-change": "transform", contain: "layout style" }
|
|
10
|
-
}, M = { class: "font-medium mb-3 text-muted-foreground" }, N = { class: "space-y-3" }, G = /* @__PURE__ */
|
|
10
|
+
}, M = { class: "font-medium mb-3 text-muted-foreground" }, N = { class: "space-y-3" }, G = /* @__PURE__ */ E({
|
|
11
11
|
__name: "ScreenExportModal",
|
|
12
12
|
props: {
|
|
13
13
|
show: { type: Boolean },
|
|
@@ -19,7 +19,7 @@ const P = {
|
|
|
19
19
|
},
|
|
20
20
|
emits: ["update:show"],
|
|
21
21
|
setup(t, { emit: w }) {
|
|
22
|
-
const y = w, n =
|
|
22
|
+
const y = w, n = b(null), c = d(() => {
|
|
23
23
|
const o = h("vlite.screen.exportData");
|
|
24
24
|
return o !== "vlite.screen.exportData" ? o : "Export Data";
|
|
25
25
|
}), D = d(() => {
|
|
@@ -33,7 +33,7 @@ const P = {
|
|
|
33
33
|
"max-width": "sm:max-w-[400px]"
|
|
34
34
|
}, {
|
|
35
35
|
default: x(({ close: r }) => [
|
|
36
|
-
f(
|
|
36
|
+
f(B, k({
|
|
37
37
|
ref_key: "exportDataRef",
|
|
38
38
|
ref: n,
|
|
39
39
|
data: t.data || [],
|
|
@@ -44,24 +44,24 @@ const P = {
|
|
|
44
44
|
title: c.value,
|
|
45
45
|
class: "hidden!"
|
|
46
46
|
}), null, 16, ["data", "fields", "mode", "on-export", "title"]),
|
|
47
|
-
a("div",
|
|
47
|
+
a("div", $, [
|
|
48
48
|
a("h6", M, v(D.value), 1),
|
|
49
49
|
a("div", N, [
|
|
50
|
-
(i(!0),
|
|
50
|
+
(i(!0), _(g, null, F(n.value?.availableFormats || [
|
|
51
51
|
{ value: "excel", label: "Excel (.xlsx)", icon: "lucide:file-spreadsheet" },
|
|
52
52
|
{ value: "csv", label: "CSV (.csv)", icon: "lucide:file-text" },
|
|
53
53
|
{ value: "json", label: "JSON (.json)", icon: "lucide:file-json" }
|
|
54
54
|
], (e, V, R, l) => {
|
|
55
55
|
const m = [e.value, e.label, e.icon];
|
|
56
56
|
if (l && l.key === e.value && S(l, m)) return l;
|
|
57
|
-
const u = (i(), p(
|
|
57
|
+
const u = (i(), p(C, {
|
|
58
58
|
key: e.value,
|
|
59
59
|
variant: "outline",
|
|
60
60
|
class: "w-full flex items-center justify-start gap-3 h-12",
|
|
61
61
|
onClick: (J) => n.value?.exportData(e.value, r)
|
|
62
62
|
}, {
|
|
63
63
|
default: x(() => [
|
|
64
|
-
f(
|
|
64
|
+
f(P, {
|
|
65
65
|
icon: e.icon,
|
|
66
66
|
class: "text-muted-foreground h-5 w-5"
|
|
67
67
|
}, null, 8, ["icon"]),
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as d, computed as o, openBlock as
|
|
1
|
+
import { defineComponent as d, computed as o, openBlock as v, createBlock as f, withCtx as x, createVNode as O, unref as p } from "vue";
|
|
2
2
|
import D from "../../Button.vue.js";
|
|
3
3
|
import _ from "../../Dropdown/Dropdown.vue.js";
|
|
4
4
|
import { $t as e } from "../../../utils/i18n.js";
|
|
@@ -10,7 +10,7 @@ const S = /* @__PURE__ */ d({
|
|
|
10
10
|
},
|
|
11
11
|
emits: ["select"],
|
|
12
12
|
setup(i, { emit: s }) {
|
|
13
|
-
const r = i,
|
|
13
|
+
const r = i, l = s, a = o(() => {
|
|
14
14
|
const t = e("vlite.screen.exportData");
|
|
15
15
|
return t !== "vlite.screen.exportData" ? t : "Export Data";
|
|
16
16
|
}), c = o(() => {
|
|
@@ -18,13 +18,13 @@ const S = /* @__PURE__ */ d({
|
|
|
18
18
|
return t !== "vlite.screen.importData" ? t : "Import Data";
|
|
19
19
|
}), m = o(() => {
|
|
20
20
|
const t = [];
|
|
21
|
-
return r.exportProps !== !1 && t.push({ value: "export", label:
|
|
21
|
+
return r.exportProps !== !1 && t.push({ value: "export", label: a.value, icon: "lucide:download" }), r.importProps !== !1 && t.push({ value: "import", label: c.value, icon: "lucide:upload" }), t;
|
|
22
22
|
});
|
|
23
|
-
return (t, n) => (
|
|
23
|
+
return (t, n) => (v(), f(_, {
|
|
24
24
|
closeOnSelect: "",
|
|
25
25
|
position: "bottom-end",
|
|
26
26
|
options: m.value,
|
|
27
|
-
onOnSelect: n[0] || (n[0] = (u) =>
|
|
27
|
+
onOnSelect: n[0] || (n[0] = (u) => l("select", u))
|
|
28
28
|
}, {
|
|
29
29
|
trigger: x(() => [
|
|
30
30
|
O(D, {
|
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import { defineComponent as h, openBlock as o, createElementBlock as m, createElementVNode as u, createBlock as
|
|
1
|
+
import { defineComponent as h, openBlock as o, createElementBlock as m, createElementVNode as u, createBlock as i, createCommentVNode as d, renderSlot as n, normalizeProps as r, guardReactiveProps as s, createVNode as c } from "vue";
|
|
2
2
|
import f from "../../Button.vue.js";
|
|
3
3
|
import v from "../../Input.vue.js";
|
|
4
4
|
/* empty css */
|
|
5
5
|
import w from "./ScreenViewToggle.vue.js";
|
|
6
6
|
import y from "../ScreenFilter.vue.js";
|
|
7
|
-
import
|
|
8
|
-
import
|
|
7
|
+
import S from "./ScreenAddAction.vue.js";
|
|
8
|
+
import $ from "./ScreenOptionsDropdown.vue.js";
|
|
9
9
|
const g = { class: "flex items-center gap-2 w-full sm:w-auto flex-1 md:flex-none justify-start sm:justify-end" }, B = {
|
|
10
10
|
key: 4,
|
|
11
11
|
class: "w-full md:w-60! max-sm:order-last"
|
|
@@ -42,22 +42,22 @@ const g = { class: "flex items-center gap-2 w-full sm:w-auto flex-1 md:flex-none
|
|
|
42
42
|
setup(e) {
|
|
43
43
|
return (l, t) => (o(), m("div", null, [
|
|
44
44
|
u("div", g, [
|
|
45
|
-
e.selectedRows.length > 0 && !e.hideSelectable && !e.hideDeleteBtn ? (o(),
|
|
45
|
+
e.selectedRows.length > 0 && !e.hideSelectable && !e.hideDeleteBtn ? (o(), i(f, {
|
|
46
46
|
key: 0,
|
|
47
47
|
variant: "outline",
|
|
48
48
|
class: "hover:bg-destructive/10 shrink-0 h-9! w-9!",
|
|
49
49
|
icon: "lucide:trash-2",
|
|
50
50
|
title: e.txtDeleteSelected,
|
|
51
51
|
onClick: t[0] || (t[0] = (a) => l.$emit("delete", e.selectedRows))
|
|
52
|
-
}, null, 8, ["title"])) :
|
|
53
|
-
e.hasMultipleViews ? (o(),
|
|
52
|
+
}, null, 8, ["title"])) : d("", !0),
|
|
53
|
+
e.hasMultipleViews ? (o(), i(w, {
|
|
54
54
|
key: 1,
|
|
55
55
|
"model-value": e.activeView,
|
|
56
56
|
"onUpdate:modelValue": t[1] || (t[1] = (a) => l.$emit("update:activeView", a)),
|
|
57
57
|
views: e.resolvedViews
|
|
58
|
-
}, null, 8, ["model-value", "views"])) :
|
|
58
|
+
}, null, 8, ["model-value", "views"])) : d("", !0),
|
|
59
59
|
n(l.$slots, "before-search", r(s(e.screenState))),
|
|
60
|
-
e.showRefresh ? (o(),
|
|
60
|
+
e.showRefresh ? (o(), i(f, {
|
|
61
61
|
key: 2,
|
|
62
62
|
variant: "outline",
|
|
63
63
|
icon: "lucide:refresh-cw",
|
|
@@ -66,15 +66,15 @@ const g = { class: "flex items-center gap-2 w-full sm:w-auto flex-1 md:flex-none
|
|
|
66
66
|
title: e.txtRefresh,
|
|
67
67
|
disabled: e.loading,
|
|
68
68
|
onClick: t[2] || (t[2] = (a) => l.$emit("refresh"))
|
|
69
|
-
}, null, 8, ["title", "disabled"])) :
|
|
70
|
-
e.filterSchema && e.filterSchema.length > 0 ? (o(),
|
|
69
|
+
}, null, 8, ["title", "disabled"])) : d("", !0),
|
|
70
|
+
e.filterSchema && e.filterSchema.length > 0 ? (o(), i(y, {
|
|
71
71
|
key: 3,
|
|
72
72
|
schema: e.filterSchema,
|
|
73
73
|
type: e.filterType,
|
|
74
74
|
"model-value": e.activeFilters,
|
|
75
75
|
"onUpdate:modelValue": t[3] || (t[3] = (a) => l.$emit("update:activeFilters", a)),
|
|
76
76
|
onChange: t[4] || (t[4] = (a) => l.$emit("refresh"))
|
|
77
|
-
}, null, 8, ["schema", "type", "model-value"])) :
|
|
77
|
+
}, null, 8, ["schema", "type", "model-value"])) : d("", !0),
|
|
78
78
|
e.canSearch ? (o(), m("div", B, [
|
|
79
79
|
c(v, {
|
|
80
80
|
lazy: "",
|
|
@@ -86,11 +86,11 @@ const g = { class: "flex items-center gap-2 w-full sm:w-auto flex-1 md:flex-none
|
|
|
86
86
|
class: "bg-background w-full",
|
|
87
87
|
"show-clear-button": !0
|
|
88
88
|
}, null, 8, ["model-value", "placeholder"])
|
|
89
|
-
])) :
|
|
89
|
+
])) : d("", !0)
|
|
90
90
|
]),
|
|
91
91
|
u("div", k, [
|
|
92
92
|
n(l.$slots, "actions", r(s(e.screenState)), () => [
|
|
93
|
-
c(
|
|
93
|
+
c(S, {
|
|
94
94
|
"can-add": e.canAdd,
|
|
95
95
|
"add-component": e.addComponent,
|
|
96
96
|
"add-btn": e.addBtn,
|
|
@@ -100,12 +100,12 @@ const g = { class: "flex items-center gap-2 w-full sm:w-auto flex-1 md:flex-none
|
|
|
100
100
|
onAdd: t[6] || (t[6] = (a) => l.$emit("add"))
|
|
101
101
|
}, null, 8, ["can-add", "add-component", "add-btn", "loading", "data", "refetch"])
|
|
102
102
|
]),
|
|
103
|
-
e.hasExportOrImport ? (o(),
|
|
103
|
+
e.hasExportOrImport ? (o(), i($, {
|
|
104
104
|
key: 0,
|
|
105
105
|
"export-props": e.exportProps,
|
|
106
106
|
"import-props": e.importProps,
|
|
107
107
|
onSelect: t[7] || (t[7] = (a) => l.$emit("select-dropdown", a))
|
|
108
|
-
}, null, 8, ["export-props", "import-props"])) :
|
|
108
|
+
}, null, 8, ["export-props", "import-props"])) : d("", !0),
|
|
109
109
|
n(l.$slots, "after-add", r(s(e.screenState)))
|
|
110
110
|
])
|
|
111
111
|
]));
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./SidePanel.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const
|
|
4
|
+
const e = /* @__PURE__ */ t(o, [["__scopeId", "data-v-10bfdf18"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
e as default
|
|
7
7
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { defineComponent as E, ref as N, inject as P, computed as f, markRaw as D, watch as h, onMounted as L, onUnmounted as V, openBlock as l, createElementBlock as i, Fragment as j, createElementVNode as p, mergeProps as w, withModifiers as K, renderSlot as c, createCommentVNode as a, createBlock as g, Teleport as M, normalizeClass as m, createVNode as F, Transition as R, withCtx as U, normalizeStyle as q, toDisplayString as
|
|
1
|
+
import { defineComponent as E, ref as N, inject as P, computed as f, markRaw as D, watch as h, onMounted as L, onUnmounted as V, openBlock as l, createElementBlock as i, Fragment as j, createElementVNode as p, mergeProps as w, withModifiers as K, renderSlot as c, createCommentVNode as a, createBlock as g, Teleport as M, normalizeClass as m, createVNode as F, Transition as R, withCtx as U, normalizeStyle as q, toDisplayString as k, resolveDynamicComponent as G } from "vue";
|
|
2
2
|
import H from "./Button.vue.js";
|
|
3
3
|
import { useKeyStroke as J } from "../composables/useKeyStroke.js";
|
|
4
|
-
import { $t as
|
|
4
|
+
import { $t as $ } from "../utils/i18n.js";
|
|
5
5
|
const Q = ["data-testid"], W = ["data-testid"], X = { class: "text-lg font-bold text-foreground" }, Y = {
|
|
6
6
|
key: 0,
|
|
7
7
|
class: "-text-fs-2 text-muted-foreground"
|
|
@@ -62,8 +62,8 @@ const Q = ["data-testid"], W = ["data-testid"], X = { class: "text-lg font-bold
|
|
|
62
62
|
lg: "max-w-lg",
|
|
63
63
|
xl: "max-w-xl",
|
|
64
64
|
full: "max-w-full"
|
|
65
|
-
}, A = f(() => t.position === "left" ? "
|
|
66
|
-
() => t.descriptionI18n ?
|
|
65
|
+
}, A = f(() => t.position === "left" ? "start-0 rounded-e-lg" : "end-0 rounded-s-md"), O = f(() => t.position === "left" ? "slide-left" : "slide-right"), d = f(() => t.titleI18n ? $(t.titleI18n) : t.title), C = f(
|
|
66
|
+
() => t.descriptionI18n ? $(t.descriptionI18n) : t.description
|
|
67
67
|
);
|
|
68
68
|
return (e, y) => (l(), i(j, null, [
|
|
69
69
|
p("span", w({
|
|
@@ -102,8 +102,8 @@ const Q = ["data-testid"], W = ["data-testid"], X = { class: "text-lg font-bold
|
|
|
102
102
|
}, [
|
|
103
103
|
c(e.$slots, "header", {}, () => [
|
|
104
104
|
p("div", null, [
|
|
105
|
-
p("h3", X,
|
|
106
|
-
C.value ? (l(), i("p", Y,
|
|
105
|
+
p("h3", X, k(d.value), 1),
|
|
106
|
+
C.value ? (l(), i("p", Y, k(C.value), 1)) : a("", !0)
|
|
107
107
|
])
|
|
108
108
|
], !0),
|
|
109
109
|
o.hideCloseButton ? a("", !0) : (l(), g(H, {
|
|
@@ -1,16 +1,14 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import { useRoute as
|
|
3
|
-
import { useBreakpoints as
|
|
4
|
-
import
|
|
1
|
+
import { defineComponent as ne, inject as le, computed as r, ref as y, watch as P, reactive as ae, provide as re, openBlock as d, createElementBlock as v, normalizeClass as M, unref as oe, createVNode as H, TransitionGroup as se, withCtx as ie, createBlock as z, createCommentVNode as N, createElementVNode as W, toDisplayString as ue, Fragment as A, renderList as F } from "vue";
|
|
2
|
+
import { useRoute as ce, useRouter as de } from "vue-router";
|
|
3
|
+
import { useBreakpoints as fe, breakpointsTailwind as me } from "@vueuse/core";
|
|
4
|
+
import $ from "./SidebarMenuItem.vue.js";
|
|
5
5
|
/* empty css */
|
|
6
|
-
import
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
class: "w-full sidebar-drilldown-container relative overflow-hidden"
|
|
10
|
-
}, de = { class: "truncate font-semibold text-foreground" }, fe = {
|
|
6
|
+
import j from "../Icon.vue.js";
|
|
7
|
+
import { useRtl as ve } from "../../composables/useRtl.js";
|
|
8
|
+
const pe = { class: "truncate font-semibold text-foreground" }, he = {
|
|
11
9
|
key: 1,
|
|
12
10
|
class: "h-px bg-border/60 mx-1 mb-1.5"
|
|
13
|
-
},
|
|
11
|
+
}, Me = /* @__PURE__ */ ne({
|
|
14
12
|
__name: "SidebarMenu",
|
|
15
13
|
props: {
|
|
16
14
|
items: { default: () => [] },
|
|
@@ -37,27 +35,31 @@ const ce = {
|
|
|
37
35
|
forceTreeView: { type: Boolean, default: !1 }
|
|
38
36
|
},
|
|
39
37
|
setup(p) {
|
|
40
|
-
const b =
|
|
41
|
-
|
|
42
|
-
const
|
|
38
|
+
const b = le("navbar-context", null), n = p, h = ce();
|
|
39
|
+
de();
|
|
40
|
+
const q = fe(me), T = ve(), G = r(
|
|
41
|
+
() => T.value ? "lucide:chevron-right" : "lucide:chevron-left"
|
|
42
|
+
), J = r(
|
|
43
|
+
() => T.value ? "group-hover:translate-x-0.5" : "group-hover:-translate-x-0.5"
|
|
44
|
+
), c = y([...n.defaultExpanded]), I = y(null), o = y([]), g = y("forward"), x = r(() => o.value.length > 0), B = r(() => o.value.length === 0 ? n.items : o.value[o.value.length - 1].items), K = r(() => o.value.length === 0 ? "" : o.value[o.value.length - 1].label), E = r(() => {
|
|
43
45
|
if (o.value.length !== 0)
|
|
44
46
|
return o.value[o.value.length - 1].icon;
|
|
45
|
-
}),
|
|
47
|
+
}), Q = (e) => {
|
|
46
48
|
e.children?.length && (g.value = "forward", o.value = [
|
|
47
49
|
...o.value,
|
|
48
50
|
{ items: e.children, label: e.label, icon: e.icon }
|
|
49
51
|
]);
|
|
50
|
-
},
|
|
52
|
+
}, O = () => {
|
|
51
53
|
o.value.length !== 0 && (g.value = "backward", o.value = o.value.slice(0, -1));
|
|
52
|
-
},
|
|
54
|
+
}, U = r(() => !n.mobileBreakpoint || n.mobileBreakpoint === "none" ? !0 : q.greaterOrEqual(n.mobileBreakpoint).value), k = r(() => U.value && n.orientation || "vertical"), S = r(() => n.forceTreeView ? !1 : !!b?.renderNestedTabs?.value), w = (e) => e.id || (typeof e.to == "string" ? e.to : null) || e.label, X = r(() => {
|
|
53
55
|
const e = /* @__PURE__ */ new Map(), l = (t, a = []) => {
|
|
54
56
|
const i = [];
|
|
55
57
|
return t.forEach((u) => {
|
|
56
|
-
const s = w(u), f = [...a, s],
|
|
58
|
+
const s = w(u), f = [...a, s], C = u.children?.length ? l(u.children, f) : [];
|
|
57
59
|
e.set(s, {
|
|
58
60
|
ancestors: a,
|
|
59
|
-
descendants:
|
|
60
|
-
}), i.push(s, ...
|
|
61
|
+
descendants: C
|
|
62
|
+
}), i.push(s, ...C);
|
|
61
63
|
}), i;
|
|
62
64
|
};
|
|
63
65
|
return l(n.items), e;
|
|
@@ -71,11 +73,11 @@ const ce = {
|
|
|
71
73
|
return !a || a === "/" || a === "?";
|
|
72
74
|
}
|
|
73
75
|
return !1;
|
|
74
|
-
},
|
|
76
|
+
}, L = (e, l, t = []) => {
|
|
75
77
|
for (const a of e) {
|
|
76
78
|
const i = w(a);
|
|
77
79
|
if (a.children?.length) {
|
|
78
|
-
const u =
|
|
80
|
+
const u = L(a.children, l, [...t, i]);
|
|
79
81
|
if (u !== null)
|
|
80
82
|
return c.value.includes(i) || c.value.push(i), u;
|
|
81
83
|
}
|
|
@@ -85,7 +87,7 @@ const ce = {
|
|
|
85
87
|
}), i;
|
|
86
88
|
}
|
|
87
89
|
return null;
|
|
88
|
-
},
|
|
90
|
+
}, R = (e, l) => {
|
|
89
91
|
for (const t of n.items) {
|
|
90
92
|
if (!t.children?.length || !(m(t, e) || t.children.some(
|
|
91
93
|
(s) => m(s, e) || s.children?.some((f) => m(f, e))
|
|
@@ -106,7 +108,7 @@ const ce = {
|
|
|
106
108
|
u = s.value;
|
|
107
109
|
else {
|
|
108
110
|
const f = t.children.find(
|
|
109
|
-
(
|
|
111
|
+
(C) => C.children?.some((te) => w(te) === l)
|
|
110
112
|
);
|
|
111
113
|
f && (u = w(f));
|
|
112
114
|
}
|
|
@@ -114,38 +116,38 @@ const ce = {
|
|
|
114
116
|
return { tabs: i, activeTab: u };
|
|
115
117
|
}
|
|
116
118
|
return null;
|
|
117
|
-
},
|
|
118
|
-
const l =
|
|
119
|
-
if (
|
|
120
|
-
const t =
|
|
119
|
+
}, V = (e) => {
|
|
120
|
+
const l = L(n.items, e);
|
|
121
|
+
if (I.value = l, !S.value) return;
|
|
122
|
+
const t = R(e, l);
|
|
121
123
|
t ? b.setNestedTabs(t.tabs, t.activeTab) : b.setNestedTabs([], "");
|
|
122
124
|
};
|
|
123
|
-
|
|
125
|
+
P(
|
|
124
126
|
() => h?.path,
|
|
125
127
|
(e) => {
|
|
126
|
-
e &&
|
|
128
|
+
e && V(e);
|
|
127
129
|
},
|
|
128
130
|
{ immediate: !0 }
|
|
129
|
-
),
|
|
131
|
+
), P(
|
|
130
132
|
() => n.items,
|
|
131
133
|
() => {
|
|
132
|
-
h?.path &&
|
|
134
|
+
h?.path && V(h.path);
|
|
133
135
|
},
|
|
134
136
|
{ deep: !0 }
|
|
135
137
|
);
|
|
136
|
-
const
|
|
137
|
-
const l = c.value.includes(e), t =
|
|
138
|
+
const Y = (e) => {
|
|
139
|
+
const l = c.value.includes(e), t = X.value.get(e);
|
|
138
140
|
if (l) {
|
|
139
141
|
const a = /* @__PURE__ */ new Set([e, ...t?.descendants || []]);
|
|
140
142
|
c.value = c.value.filter((i) => !a.has(i));
|
|
141
143
|
} else
|
|
142
144
|
n.allowMultiple ? c.value.push(e) : c.value = [...t?.ancestors || [], e];
|
|
143
|
-
},
|
|
144
|
-
if (
|
|
145
|
-
const l =
|
|
145
|
+
}, Z = (e) => {
|
|
146
|
+
if (I.value = e, S.value && h?.path) {
|
|
147
|
+
const l = R(h.path, e);
|
|
146
148
|
l ? b.setNestedTabs(l.tabs, l.activeTab) : b.setNestedTabs([], "");
|
|
147
149
|
}
|
|
148
|
-
},
|
|
150
|
+
}, D = (e, l, t = []) => {
|
|
149
151
|
for (const a of e) {
|
|
150
152
|
if (t.length === 0 && m(a, l)) return null;
|
|
151
153
|
if (a.children?.length) {
|
|
@@ -155,40 +157,40 @@ const ce = {
|
|
|
155
157
|
];
|
|
156
158
|
for (const s of a.children)
|
|
157
159
|
if (m(s, l)) return i;
|
|
158
|
-
const u =
|
|
160
|
+
const u = D(a.children, l, i);
|
|
159
161
|
if (u) return u;
|
|
160
162
|
}
|
|
161
163
|
}
|
|
162
164
|
return null;
|
|
163
|
-
},
|
|
165
|
+
}, _ = (e, l) => {
|
|
164
166
|
for (const t of e)
|
|
165
167
|
if (m(t, l)) return !0;
|
|
166
168
|
return !1;
|
|
167
169
|
};
|
|
168
|
-
|
|
170
|
+
P(
|
|
169
171
|
() => h?.path,
|
|
170
172
|
(e) => {
|
|
171
173
|
if (!e || (n.renderMode || "tree") !== "drilldown") return;
|
|
172
|
-
const t =
|
|
173
|
-
if (
|
|
174
|
-
if (
|
|
174
|
+
const t = B.value;
|
|
175
|
+
if (_(t, e)) return;
|
|
176
|
+
if (_(n.items, e)) {
|
|
175
177
|
o.value.length > 0 && (g.value = "backward", o.value = []);
|
|
176
178
|
return;
|
|
177
179
|
}
|
|
178
|
-
const a =
|
|
180
|
+
const a = D(n.items, e);
|
|
179
181
|
a && a.length > 0 && (g.value = "forward", o.value = a);
|
|
180
182
|
}
|
|
181
183
|
);
|
|
182
|
-
const
|
|
183
|
-
activeItem:
|
|
184
|
+
const ee = ae({
|
|
185
|
+
activeItem: I,
|
|
184
186
|
expandedItems: c,
|
|
185
|
-
toggleExpand:
|
|
186
|
-
setActive:
|
|
187
|
+
toggleExpand: Y,
|
|
188
|
+
setActive: Z,
|
|
187
189
|
indentSize: r(() => n.indentSize),
|
|
188
190
|
variant: r(() => n.variant),
|
|
189
191
|
renderMode: r(() => n.renderMode || "tree"),
|
|
190
192
|
// Expose the effective value so SidebarMenuItem respects forceTreeView
|
|
191
|
-
renderNestedTabs:
|
|
193
|
+
renderNestedTabs: S,
|
|
192
194
|
compact: r(() => n.compact),
|
|
193
195
|
showCompactLabels: r(() => n.showCompactLabels),
|
|
194
196
|
iconSize: r(() => n.iconSize),
|
|
@@ -202,26 +204,29 @@ const ce = {
|
|
|
202
204
|
currentOrientation: k,
|
|
203
205
|
showTooltip: r(() => n.showTooltip),
|
|
204
206
|
drilldownStack: o,
|
|
205
|
-
drillInto:
|
|
206
|
-
drillBack:
|
|
207
|
-
drilldownItems:
|
|
207
|
+
drillInto: Q,
|
|
208
|
+
drillBack: O,
|
|
209
|
+
drilldownItems: B,
|
|
208
210
|
isDrilldown: x
|
|
209
211
|
});
|
|
210
|
-
return
|
|
211
|
-
class:
|
|
212
|
+
return re("sidebar-menu-ctx", ee), (e, l) => (d(), v("nav", {
|
|
213
|
+
class: M(["flex w-full transition-all duration-300", [
|
|
212
214
|
k.value === "horizontal" ? "flex-row flex-wrap gap-2 items-center" : "flex-col",
|
|
213
215
|
k.value === "vertical" && !n.compact ? "space-y-1" : ""
|
|
214
216
|
]]),
|
|
215
217
|
role: "tree",
|
|
216
218
|
"aria-label": "Sidebar Menu"
|
|
217
219
|
}, [
|
|
218
|
-
(n.renderMode || "tree") === "drilldown" && k.value === "vertical" ? (d(), v("div",
|
|
219
|
-
|
|
220
|
+
(n.renderMode || "tree") === "drilldown" && k.value === "vertical" ? (d(), v("div", {
|
|
221
|
+
key: 0,
|
|
222
|
+
class: M(["w-full sidebar-drilldown-container relative overflow-hidden", { "sidebar-drilldown--rtl": oe(T) }])
|
|
223
|
+
}, [
|
|
224
|
+
H(se, {
|
|
220
225
|
name: g.value === "forward" ? "drill-forward" : "drill-backward",
|
|
221
226
|
tag: "div",
|
|
222
227
|
class: "relative w-full"
|
|
223
228
|
}, {
|
|
224
|
-
default:
|
|
229
|
+
default: ie(() => [
|
|
225
230
|
(d(), v("div", {
|
|
226
231
|
key: o.value.length,
|
|
227
232
|
class: "w-full"
|
|
@@ -230,24 +235,24 @@ const ce = {
|
|
|
230
235
|
key: 0,
|
|
231
236
|
type: "button",
|
|
232
237
|
class: "flex items-center gap-2 w-full px-2 py-2.5 mb-1 text-sm font-medium text-muted-foreground hover:text-foreground hover:bg-accent/60 rounded-md transition-all duration-150 group cursor-pointer",
|
|
233
|
-
onClick:
|
|
238
|
+
onClick: O
|
|
234
239
|
}, [
|
|
235
|
-
|
|
236
|
-
icon:
|
|
237
|
-
class: "w-4 h-4 shrink-0 transition-transform duration-200
|
|
238
|
-
}),
|
|
239
|
-
|
|
240
|
+
H(j, {
|
|
241
|
+
icon: G.value,
|
|
242
|
+
class: M(["w-4 h-4 shrink-0 transition-transform duration-200", J.value])
|
|
243
|
+
}, null, 8, ["icon", "class"]),
|
|
244
|
+
E.value ? (d(), z(j, {
|
|
240
245
|
key: 0,
|
|
241
|
-
icon:
|
|
246
|
+
icon: E.value,
|
|
242
247
|
class: "w-4 h-4 shrink-0 opacity-70"
|
|
243
|
-
}, null, 8, ["icon"])) :
|
|
244
|
-
W("span",
|
|
245
|
-
])) :
|
|
246
|
-
x.value ? (d(), v("div",
|
|
248
|
+
}, null, 8, ["icon"])) : N("", !0),
|
|
249
|
+
W("span", pe, ue(K.value), 1)
|
|
250
|
+
])) : N("", !0),
|
|
251
|
+
x.value ? (d(), v("div", he)) : N("", !0),
|
|
247
252
|
W("div", {
|
|
248
|
-
class:
|
|
253
|
+
class: M(x.value ? "space-y-0.5" : "space-y-1")
|
|
249
254
|
}, [
|
|
250
|
-
(d(!0), v(
|
|
255
|
+
(d(!0), v(A, null, F(B.value, (t) => (d(), z($, {
|
|
251
256
|
key: t.id || t.label,
|
|
252
257
|
item: t,
|
|
253
258
|
itemClass: p.itemClass,
|
|
@@ -258,7 +263,7 @@ const ce = {
|
|
|
258
263
|
]),
|
|
259
264
|
_: 1
|
|
260
265
|
}, 8, ["name"])
|
|
261
|
-
])) : (d(!0), v(
|
|
266
|
+
], 2)) : (d(!0), v(A, { key: 1 }, F(p.items, (t) => (d(), z($, {
|
|
262
267
|
key: t.id || t.label,
|
|
263
268
|
item: t,
|
|
264
269
|
itemClass: p.itemClass,
|
|
@@ -268,5 +273,5 @@ const ce = {
|
|
|
268
273
|
}
|
|
269
274
|
});
|
|
270
275
|
export {
|
|
271
|
-
|
|
276
|
+
Me as default
|
|
272
277
|
};
|