vlite3 0.4.8 → 0.5.2
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/README.md +201 -100
- package/_virtual/Barcode.js +4 -0
- package/_virtual/CODE128.js +4 -0
- package/_virtual/CODE128A.js +4 -0
- package/_virtual/CODE128B.js +4 -0
- package/_virtual/CODE128C.js +4 -0
- package/_virtual/CODE128_AUTO.js +4 -0
- package/_virtual/CODE93.js +4 -0
- package/_virtual/CODE93FullASCII.js +4 -0
- package/_virtual/EAN.js +4 -0
- package/_virtual/EAN13.js +4 -0
- package/_virtual/EAN2.js +4 -0
- package/_virtual/EAN5.js +4 -0
- package/_virtual/EAN8.js +4 -0
- package/_virtual/ErrorHandler.js +4 -0
- package/_virtual/FileSaver.min.js +5 -0
- package/_virtual/FileSaver.min2.js +4 -0
- package/_virtual/ITF.js +4 -0
- package/_virtual/ITF14.js +4 -0
- package/_virtual/JsBarcode.js +7 -0
- package/_virtual/MSI.js +4 -0
- package/_virtual/MSI10.js +4 -0
- package/_virtual/MSI1010.js +4 -0
- package/_virtual/MSI11.js +4 -0
- package/_virtual/MSI1110.js +4 -0
- package/_virtual/UPC.js +4 -0
- package/_virtual/UPCE.js +4 -0
- package/_virtual/_commonjsHelpers.js +8 -0
- package/_virtual/alignment-pattern.js +4 -0
- package/_virtual/auto.js +4 -0
- package/_virtual/browser.js +7 -0
- package/_virtual/browser2.js +4 -0
- package/_virtual/canvas.js +4 -0
- package/_virtual/canvas2.js +4 -0
- package/_virtual/checksums.js +4 -0
- package/_virtual/constants.js +4 -0
- package/_virtual/constants2.js +4 -0
- package/_virtual/constants3.js +4 -0
- package/_virtual/constants4.js +4 -0
- package/_virtual/defaults.js +4 -0
- package/_virtual/dijkstra.js +4 -0
- package/_virtual/encoder.js +4 -0
- package/_virtual/error-correction-code.js +4 -0
- package/_virtual/error-correction-level.js +4 -0
- package/_virtual/exceptions.js +4 -0
- package/_virtual/finder-pattern.js +4 -0
- package/_virtual/fixOptions.js +4 -0
- package/_virtual/format-info.js +4 -0
- package/_virtual/galois-field.js +4 -0
- package/_virtual/getOptionsFromElement.js +4 -0
- package/_virtual/getRenderProperties.js +4 -0
- package/_virtual/index.js +4 -0
- package/_virtual/index10.js +4 -0
- package/_virtual/index11.js +4 -0
- package/_virtual/index2.js +4 -0
- package/_virtual/index3.js +4 -0
- package/_virtual/index4.js +4 -0
- package/_virtual/index5.js +4 -0
- package/_virtual/index6.js +4 -0
- package/_virtual/index7.js +4 -0
- package/_virtual/index8.js +4 -0
- package/_virtual/index9.js +4 -0
- package/_virtual/linearizeEncodings.js +4 -0
- package/_virtual/mask-pattern.js +4 -0
- package/_virtual/merge.js +4 -0
- package/_virtual/mode.js +4 -0
- package/_virtual/object.js +4 -0
- package/_virtual/optionsFromStrings.js +4 -0
- package/_virtual/papaparse.min.js +7 -0
- package/_virtual/papaparse.min2.js +4 -0
- package/_virtual/polynomial.js +4 -0
- package/_virtual/qrcode.js +4 -0
- package/_virtual/regex.js +4 -0
- package/_virtual/segments.js +4 -0
- package/_virtual/shared.js +4 -0
- package/_virtual/svg-tag.js +4 -0
- package/_virtual/svg.js +4 -0
- package/_virtual/utils.js +4 -0
- package/_virtual/utils2.js +4 -0
- package/_virtual/version-check.js +4 -0
- package/_virtual/version.js +4 -0
- package/components/Accordion/Accordion.vue.d.ts +7 -7
- package/components/Accordion/AccordionItem.vue.d.ts +4 -4
- package/components/Accordion/AccordionTrigger.vue.d.ts +2 -2
- package/components/Alert.vue.d.ts +1 -1
- package/components/Avatar.vue.d.ts +2 -2
- package/components/Avatar.vue.js +2 -2
- package/components/AvatarUploader/AvatarUploader.vue.d.ts +5 -5
- package/components/Badge.vue.d.ts +1 -1
- package/components/Barcode/Barcode.vue.d.ts +22 -0
- package/components/Barcode/Barcode.vue.js +58 -0
- package/components/Barcode/Barcode.vue2.js +4 -0
- package/components/Barcode/index.d.ts +2 -0
- package/components/Barcode/types.d.ts +5 -0
- package/components/Barcode/types.js +15 -0
- package/components/Breadcrumb/Breadcrumb.vue.d.ts +23 -0
- package/components/Breadcrumb/Breadcrumb.vue.js +7 -0
- package/components/Breadcrumb/Breadcrumb.vue2.js +84 -0
- package/components/Breadcrumb/BreadcrumbItem.vue.d.ts +27 -0
- package/components/Breadcrumb/BreadcrumbItem.vue.js +7 -0
- package/components/Breadcrumb/BreadcrumbItem.vue2.js +50 -0
- package/components/Breadcrumb/index.d.ts +3 -0
- package/components/Breadcrumb/types.d.ts +19 -0
- package/components/Button.vue.d.ts +4 -4
- package/components/Button.vue.js +32 -29
- package/components/ButtonGroup.vue.d.ts +1 -1
- package/components/Carousel/Carousel.vue.d.ts +58 -58
- package/components/CheckBox.vue.d.ts +2 -2
- package/components/Chip/Chip.vue.d.ts +3 -3
- package/components/ChoiceBox/ChoiceBox.vue.d.ts +4 -4
- package/components/ColorPicker/ColorPicker.vue.d.ts +3 -3
- package/components/ColorPicker/index.d.ts +1 -0
- package/components/CommandPaletteContent.vue.d.ts +15 -0
- package/components/CommandPaletteContent.vue.js +7 -0
- package/components/CommandPaletteContent.vue2.js +287 -0
- package/components/ConfirmationModal.vue.js +12 -10
- package/components/DataList/DataList.vue.d.ts +2 -2
- package/components/DataTable/DataTable.vue.d.ts +6 -6
- package/components/DataTable/DataTableRow.vue.d.ts +3 -3
- package/components/DatePicker.vue.d.ts +2 -2
- package/components/DatePicker.vue.js +7 -7
- package/components/DateRangePicker.vue.d.ts +29 -0
- package/components/DateRangePicker.vue.js +231 -0
- package/components/DateRangePicker.vue2.js +4 -0
- package/components/Dropdown/Dropdown.vue.d.ts +11 -6
- package/components/Dropdown/Dropdown.vue.js +147 -109
- package/components/Dropdown/DropdownBooleanItem.vue.js +9 -8
- package/components/Dropdown/DropdownGroupedLayout.vue.d.ts +1 -1
- package/components/Dropdown/DropdownGroupedLayout.vue.js +35 -34
- package/components/Dropdown/DropdownItem.vue.js +11 -10
- package/components/Dropdown/DropdownMenu.vue.d.ts +5 -3
- package/components/Dropdown/DropdownMenu.vue.js +114 -111
- package/components/Dropdown/DropdownTrigger.vue.d.ts +2 -0
- package/components/Dropdown/DropdownTrigger.vue.js +9 -7
- package/components/ExportData/ExportData.vue.d.ts +16 -0
- package/components/ExportData/ExportData.vue.js +135 -0
- package/components/ExportData/ExportData.vue2.js +4 -0
- package/components/ExportData/index.d.ts +2 -0
- package/components/ExportData/types.d.ts +17 -0
- package/components/FilePicker/FilePicker.vue.d.ts +5 -5
- package/components/Form/CustomFields.vue.d.ts +6 -6
- package/components/Form/CustomFields.vue.js +1 -1
- package/components/Form/Form.vue.d.ts +4 -5
- package/components/Form/Form.vue.js +2 -2
- package/components/Form/Form.vue2.js +221 -178
- package/components/Form/FormField.vue.d.ts +4 -3
- package/components/Form/FormField.vue.js +70 -62
- package/components/Form/FormFields.vue.d.ts +3 -1
- package/components/Form/FormFields.vue.js +2 -2
- package/components/Form/FormFields.vue2.js +105 -59
- package/components/GoogleLogin.vue.d.ts +2 -2
- package/components/Icon.vue.d.ts +2 -0
- package/components/Icon.vue.js +12 -11
- package/components/ImportData/ImportData.vue.d.ts +31 -0
- package/components/ImportData/ImportData.vue.js +242 -0
- package/components/ImportData/ImportData.vue2.js +4 -0
- package/components/ImportData/ImportStep1.vue.d.ts +23 -0
- package/components/ImportData/ImportStep1.vue.js +162 -0
- package/components/ImportData/ImportStep1.vue2.js +4 -0
- package/components/ImportData/ImportStep2.vue.d.ts +20 -0
- package/components/ImportData/ImportStep2.vue.js +98 -0
- package/components/ImportData/ImportStep2.vue2.js +4 -0
- package/components/ImportData/ImportStep3.vue.d.ts +6 -0
- package/components/ImportData/ImportStep3.vue.js +98 -0
- package/components/ImportData/ImportStep3.vue2.js +4 -0
- package/components/ImportData/ImportStep4.vue.d.ts +6 -0
- package/components/ImportData/ImportStep4.vue.js +139 -0
- package/components/ImportData/ImportStep4.vue2.js +4 -0
- package/components/ImportData/index.d.ts +2 -0
- package/components/ImportData/types.d.ts +51 -0
- package/components/Input.vue.d.ts +9 -9
- package/components/Input.vue.js +137 -120
- package/components/List/List.vue.d.ts +18 -0
- package/components/List/List.vue.js +189 -0
- package/components/List/List.vue2.js +4 -0
- package/components/List/ListFieldRow.vue.d.ts +35 -0
- package/components/List/ListFieldRow.vue.js +119 -0
- package/components/List/ListFieldRow.vue2.js +4 -0
- package/components/List/index.d.ts +4 -0
- package/components/List/types.d.ts +1 -0
- package/components/List/utils.d.ts +9 -0
- package/components/List/utils.js +64 -0
- package/components/Masonry/Masonry.vue.d.ts +2 -2
- package/components/Modal.vue.js +5 -122
- package/components/Modal.vue2.js +133 -2
- package/components/MultiSelect/MultiSelect.vue.d.ts +12 -9
- package/components/MultiSelect/MultiSelect.vue.js +101 -64
- package/components/Navbar/Navbar.vue.d.ts +48 -9
- package/components/Navbar/Navbar.vue.js +418 -146
- package/components/Navbar/NavbarItem.vue.d.ts +2 -2
- package/components/Navbar/NavbarTabs.vue.d.ts +21 -0
- package/components/Navbar/NavbarTabs.vue.js +179 -0
- package/components/Navbar/NavbarTabs.vue3.js +5 -0
- package/components/Navbar/index.d.ts +3 -0
- package/components/NavbarCommandPalette.vue.d.ts +48 -0
- package/components/NumberInput.vue.d.ts +8 -8
- package/components/OTPInput/OTPInput.vue.d.ts +7 -7
- package/components/Pagination/Pagination.vue.d.ts +1 -1
- package/components/PermissionMatrix/PermissionEditor.vue.d.ts +36 -0
- package/components/PermissionMatrix/PermissionEditor.vue.js +323 -0
- package/components/PermissionMatrix/PermissionEditor.vue2.js +4 -0
- package/components/PermissionMatrix/PermissionMatrix.vue.d.ts +15 -0
- package/components/PermissionMatrix/PermissionMatrix.vue.js +7 -0
- package/components/PermissionMatrix/PermissionMatrix.vue2.js +245 -0
- package/components/PermissionMatrix/index.d.ts +3 -0
- package/components/PermissionMatrix/types.d.ts +59 -0
- package/components/PricingPlan/PricingPlan.vue.d.ts +3 -3
- package/components/ProgressBar/ProgressBar.vue.d.ts +3 -3
- package/components/QRCode/QRCode.vue.d.ts +15 -0
- package/components/QRCode/QRCode.vue.js +38 -0
- package/components/QRCode/QRCode.vue2.js +4 -0
- package/components/QRCode/index.d.ts +1 -0
- package/components/Screen/Screen.vue.d.ts +232 -5
- package/components/Screen/Screen.vue.js +423 -271
- package/components/Screen/ScreenFilter.vue.d.ts +2 -2
- package/components/Screen/ScreenFilter.vue.js +9 -9
- package/components/Screen/types.d.ts +12 -0
- package/components/SidePanel.vue.d.ts +2 -2
- package/components/SidebarMenu/SidebarMenu.vue.d.ts +15 -2
- package/components/SidebarMenu/SidebarMenu.vue.js +117 -47
- package/components/SidebarMenu/SidebarMenuItem.vue.d.ts +2 -0
- package/components/SidebarMenu/SidebarMenuItem.vue.js +192 -175
- package/components/SidebarMenu/types.d.ts +32 -5
- package/components/Slider.vue.d.ts +2 -2
- package/components/Spinner/Spinner.vue.d.ts +2 -2
- package/components/Stats/Stats.vue.d.ts +14 -0
- package/components/Stats/Stats.vue.js +307 -0
- package/components/Stats/Stats.vue2.js +4 -0
- package/components/Stats/index.d.ts +2 -0
- package/components/Stats/types.d.ts +32 -0
- package/components/Switch.vue.d.ts +2 -1
- package/components/Switch.vue.js +4 -2
- package/components/Tabes/Tabes.vue.d.ts +3 -3
- package/components/Tabes/Tabes.vue.js +60 -57
- package/components/Tabes/types.d.ts +5 -0
- package/components/Textarea.vue.d.ts +3 -3
- package/components/{Timeline.vue.d.ts → Timeline/Timeline.vue.d.ts} +23 -2
- package/components/Timeline/Timeline.vue.js +92 -0
- package/components/Timeline/TimelineIndicator.vue.d.ts +9 -0
- package/components/Timeline/TimelineIndicator.vue.js +68 -0
- package/components/Timeline/TimelineIndicator.vue2.js +4 -0
- package/components/Timeline/TimelineItem.vue.d.ts +56 -0
- package/components/Timeline/TimelineItem.vue.js +173 -0
- package/components/Timeline/TimelineItem.vue2.js +4 -0
- package/components/Timeline/index.d.ts +3 -0
- package/components/Tooltip.vue.d.ts +2 -2
- package/components/Workbook/Sheet.vue.d.ts +2 -2
- package/components/Workbook/Workbook.vue.d.ts +3 -3
- package/components/index.d.ts +62 -0
- package/composables/useBreadcrumb.d.ts +17 -0
- package/composables/useBreadcrumb.js +27 -0
- package/core/config.d.ts +34 -0
- package/core/config.js +10 -7
- package/core/index.js +15 -8
- package/index.d.ts +55 -44
- package/index.js +243 -200
- package/package.json +12 -2
- package/router.d.ts +2 -0
- package/style.css +7 -5
- package/types/button.d.ts +1 -1
- package/types/config.type.d.ts +35 -0
- package/types/form.type.d.ts +3 -1
- package/types/index.d.ts +2 -1
- package/types/list.type.d.ts +57 -0
- package/types/navbar.type.d.ts +38 -1
- package/types/timeline.type.d.ts +14 -4
- package/components/Timeline.vue.js +0 -160
- /package/components/{Timeline.vue2.js → Timeline/Timeline.vue2.js} +0 -0
|
@@ -1,145 +1,165 @@
|
|
|
1
|
-
import { defineComponent as
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import
|
|
6
|
-
|
|
1
|
+
import { defineComponent as X, inject as Y, computed as s, resolveComponent as Z, openBlock as r, createElementBlock as v, normalizeClass as u, createBlock as p, unref as a, withCtx as h, createElementVNode as f, normalizeStyle as $, createCommentVNode as d, toDisplayString as y, createVNode as C, resolveDynamicComponent as B, mergeProps as D, createTextVNode as ee, Fragment as V, withKeys as te, withModifiers as ae, Transition as ne, renderList as ie } from "vue";
|
|
2
|
+
import { useRouter as oe } from "vue-router";
|
|
3
|
+
import w from "../Icon.vue.js";
|
|
4
|
+
import _ from "../Tooltip.vue.js";
|
|
5
|
+
import le from "../Dropdown/Dropdown.vue.js";
|
|
6
|
+
import { $t as K } from "../../utils/i18n.js";
|
|
7
|
+
const re = {
|
|
7
8
|
key: 0,
|
|
8
9
|
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"
|
|
9
|
-
},
|
|
10
|
+
}, ce = { class: "w-full" }, se = { class: "flex items-center w-full gap-2 text-sm" }, ue = { class: "truncate flex-1 font-medium" }, de = ["onKeydown"], me = {
|
|
10
11
|
key: 0,
|
|
11
12
|
class: "overflow-hidden transition-all duration-300 ease-in-out relative"
|
|
12
|
-
},
|
|
13
|
+
}, ve = { class: "mt-0.5 space-y-0.5" }, xe = /* @__PURE__ */ X({
|
|
13
14
|
__name: "SidebarMenuItem",
|
|
14
15
|
props: {
|
|
15
16
|
item: {},
|
|
16
|
-
depth: { default: 0 }
|
|
17
|
+
depth: { default: 0 },
|
|
18
|
+
menuOffset: {},
|
|
19
|
+
itemClass: {}
|
|
17
20
|
},
|
|
18
|
-
setup(
|
|
19
|
-
const t =
|
|
21
|
+
setup(c) {
|
|
22
|
+
const t = c, e = Y("sidebar-menu-ctx"), O = oe();
|
|
20
23
|
if (!e)
|
|
21
24
|
throw new Error("SidebarMenuItem must be used within a SidebarMenu");
|
|
22
|
-
const
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
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";
|
|
31
|
-
let f = "";
|
|
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,
|
|
35
|
-
value: a.id || a.label,
|
|
36
|
-
icon: a.icon,
|
|
37
|
-
disabled: a.disabled,
|
|
38
|
-
children: a.children ? a.children.map(B) : void 0,
|
|
39
|
-
data: a
|
|
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 : "");
|
|
45
|
-
f && e.setActive(f);
|
|
25
|
+
const n = s(() => e.currentOrientation === "horizontal" && t.depth === 0), b = s(() => !!t.item.children?.length), R = s(() => n.value && b.value || e.compact && b.value ? "popover" : t.item.renderMode || e.renderMode || "tree"), S = s(() => e.renderNestedTabs && t.depth === 0 ? !1 : R.value === "popover" && b.value), g = s(() => t.item.id ? t.item.id : t.item.to && typeof t.item.to == "string" ? t.item.to : t.item.label), M = s(() => S.value || e.renderNestedTabs && t.depth === 0 ? !1 : e.expandedItems.includes(g.value)), E = s(() => !(!b.value || e.renderNestedTabs && t.depth === 0)), I = s(() => e.activeItem === g.value), j = (o) => {
|
|
26
|
+
if (!t.item.disabled) {
|
|
27
|
+
if (e.renderNestedTabs && t.depth === 0) {
|
|
28
|
+
t.item.action && t.item.action(t.item), e.setActive(g.value);
|
|
29
|
+
return;
|
|
30
|
+
}
|
|
31
|
+
b.value && !t.item.to && !t.item.href && (S.value || e.toggleExpand(g.value)), t.item.action && t.item.action(t.item), (!b.value || t.item.to) && e.setActive(g.value);
|
|
46
32
|
}
|
|
47
|
-
},
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
},
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
},
|
|
57
|
-
const n =
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
33
|
+
}, L = (o) => {
|
|
34
|
+
if (o.stopPropagation(), e.renderNestedTabs && t.depth === 0) {
|
|
35
|
+
t.item.action && t.item.action(t.item), e.setActive(g.value);
|
|
36
|
+
return;
|
|
37
|
+
}
|
|
38
|
+
S.value || e.toggleExpand(g.value);
|
|
39
|
+
}, z = s(() => e.indentSize || 12), N = s(() => n.value ? {} : e.compact ? { width: "100%" } : {
|
|
40
|
+
marginLeft: `${t.depth * z.value}px`,
|
|
41
|
+
width: `calc(100% - ${t.depth * z.value}px)`
|
|
42
|
+
}), T = s(() => {
|
|
43
|
+
const i = `group flex items-center justify-between 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 ${n.value ? "w-auto" : "w-full"} ${t?.itemClass || ""} ${e.labelClass}`, x = e.compact ? `justify-center ${e.compactItemPadding}` : `justify-between ${e.itemPadding}`;
|
|
44
|
+
let l = "";
|
|
45
|
+
return I.value ? l = "bg-primary-light text-primary-fg-light" : l = "text-muted hover:bg-accent/80 hover:text-foreground", t.item.disabled && (l = "opacity-50 cursor-not-allowed pointer-events-none"), `${i} ${x} ${l} ${t.item.class || ""}`;
|
|
46
|
+
}), m = s(() => e.compact && e.showCompactLabels), k = s(
|
|
47
|
+
() => t.item.labelI18n ? K(t.item.labelI18n) : t.item.label
|
|
48
|
+
), A = (o) => ({
|
|
49
|
+
label: o.labelI18n ? K(o.labelI18n) : o.label,
|
|
50
|
+
value: o.id || o.label,
|
|
51
|
+
icon: o.icon,
|
|
52
|
+
disabled: o.disabled,
|
|
53
|
+
children: o.children ? o.children.map(A) : void 0,
|
|
54
|
+
data: o
|
|
55
|
+
}), F = s(() => t.item.children ? t.item.children.map(A) : []), W = (o) => {
|
|
56
|
+
const i = o.data;
|
|
57
|
+
if (i) {
|
|
58
|
+
i.action && i.action(i);
|
|
59
|
+
const x = i.id || i.label || (typeof i.to == "string" ? i.to : "");
|
|
60
|
+
x && e.setActive(x), i.to ? O.push(i.to).catch(() => {
|
|
61
|
+
}) : i.href && window.open(i.href, "_blank");
|
|
62
|
+
}
|
|
63
|
+
}, q = (o) => {
|
|
64
|
+
const i = o;
|
|
65
|
+
i.style.height = "0", i.style.opacity = "0";
|
|
66
|
+
}, G = (o) => {
|
|
67
|
+
const i = o;
|
|
68
|
+
i.style.height = i.scrollHeight + "px", i.style.opacity = "1";
|
|
69
|
+
}, J = (o) => {
|
|
70
|
+
const i = o;
|
|
71
|
+
i.style.height = "auto", i.style.overflow = "visible";
|
|
72
|
+
}, Q = (o) => {
|
|
73
|
+
const i = o;
|
|
74
|
+
i.style.height = i.scrollHeight + "px", i.style.overflow = "hidden", i.style.opacity = "1";
|
|
75
|
+
}, U = (o) => {
|
|
76
|
+
const i = o;
|
|
77
|
+
i.style.height = "0", i.style.opacity = "0";
|
|
78
|
+
}, H = s(() => t.item.to ? "router-link" : t.item.href ? "a" : "button"), P = s(() => t.item.to ? { to: t.item.to } : t.item.href ? {
|
|
63
79
|
href: t.item.href,
|
|
64
80
|
target: "_blank",
|
|
65
81
|
rel: "noopener noreferrer"
|
|
66
82
|
} : { type: "button" });
|
|
67
|
-
return (
|
|
68
|
-
const
|
|
69
|
-
return
|
|
70
|
-
|
|
83
|
+
return (o, i) => {
|
|
84
|
+
const x = Z("SidebarMenuItem", !0);
|
|
85
|
+
return r(), v("div", {
|
|
86
|
+
class: u(["relative sidebar-manu-item", n.value ? "w-auto" : "w-full"])
|
|
87
|
+
}, [
|
|
88
|
+
S.value ? (r(), p(a(le), {
|
|
71
89
|
key: 0,
|
|
72
|
-
position: "right-start",
|
|
73
|
-
offset:
|
|
74
|
-
class: "w-full",
|
|
90
|
+
position: n.value ? "bottom-start" : "right-start",
|
|
91
|
+
offset: c.menuOffset,
|
|
92
|
+
class: "w-full block",
|
|
75
93
|
searchable: !1,
|
|
76
|
-
width:
|
|
77
|
-
|
|
78
|
-
|
|
94
|
+
width: a(e).nestedMenuWidth,
|
|
95
|
+
maxHeight: a(e).nestedMenuMaxHeight,
|
|
96
|
+
options: F.value,
|
|
97
|
+
onOnSelect: W
|
|
79
98
|
}, {
|
|
80
99
|
header: h(() => [
|
|
81
|
-
|
|
82
|
-
|
|
100
|
+
a(e).compact && !n.value ? (r(), v("div", re, [
|
|
101
|
+
c.item.icon ? (r(), p(w, {
|
|
83
102
|
key: 0,
|
|
84
|
-
icon:
|
|
103
|
+
icon: c.item.icon,
|
|
85
104
|
class: "shrink-0 transition-colors opacity-80 group-hover:opacity-100"
|
|
86
105
|
}, null, 8, ["icon"])) : d("", !0),
|
|
87
|
-
|
|
106
|
+
ee(" " + y(k.value), 1)
|
|
88
107
|
])) : d("", !0)
|
|
89
108
|
]),
|
|
90
|
-
trigger: h(({ isOpen:
|
|
91
|
-
|
|
92
|
-
content:
|
|
93
|
-
placement: "right",
|
|
109
|
+
trigger: h(({ isOpen: l }) => [
|
|
110
|
+
C(_, {
|
|
111
|
+
content: k.value,
|
|
112
|
+
placement: n.value ? "bottom" : "right",
|
|
94
113
|
className: "sidebar-menu-tooltip",
|
|
95
|
-
disabled: !
|
|
114
|
+
disabled: !a(e).showTooltip || !a(e).compact && !n.value || l,
|
|
96
115
|
class: "w-full block"
|
|
97
116
|
}, {
|
|
98
117
|
default: h(() => [
|
|
99
|
-
|
|
100
|
-
(
|
|
101
|
-
class: [
|
|
102
|
-
style:
|
|
118
|
+
f("div", ce, [
|
|
119
|
+
(r(), p(B(H.value), D(P.value, {
|
|
120
|
+
class: [T.value, l ? "bg-muted text-foreground" : ""],
|
|
121
|
+
style: N.value,
|
|
103
122
|
"aria-haspopup": !0,
|
|
104
|
-
"aria-expanded":
|
|
123
|
+
"aria-expanded": l,
|
|
105
124
|
onClick: j
|
|
106
125
|
}), {
|
|
107
126
|
default: h(() => [
|
|
108
|
-
|
|
109
|
-
class:
|
|
110
|
-
|
|
127
|
+
f("div", {
|
|
128
|
+
class: u(["min-w-0 flex-1 flex", [
|
|
129
|
+
m.value && !n.value ? "flex-col items-center justify-center gap-1" : a(e).compact && !n.value ? "justify-center" : "items-center gap-2.5"
|
|
111
130
|
]])
|
|
112
131
|
}, [
|
|
113
|
-
|
|
132
|
+
c.item.icon ? (r(), p(w, {
|
|
114
133
|
key: 0,
|
|
115
|
-
icon:
|
|
116
|
-
class:
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
134
|
+
icon: c.item.icon,
|
|
135
|
+
class: u(["shrink-0 transition-colors opacity-80 group-hover:opacity-100", [I.value || l ? "opacity-100" : ""]]),
|
|
136
|
+
style: $({
|
|
137
|
+
width: a(e).compact && !n.value ? a(e).compactIconSize : a(e).iconSize,
|
|
138
|
+
height: a(e).compact && !n.value ? a(e).compactIconSize : a(e).iconSize
|
|
139
|
+
})
|
|
140
|
+
}, null, 8, ["icon", "class", "style"])) : d("", !0),
|
|
141
|
+
f("span", {
|
|
142
|
+
class: u(["truncate leading-none pt-0.5", {
|
|
143
|
+
[a(e).compactLabelClass]: m.value && !n.value,
|
|
144
|
+
hidden: a(e).compact && !m.value && !n.value,
|
|
145
|
+
"md:hidden": a(e).compact && !m.value && !n.value
|
|
126
146
|
}])
|
|
127
|
-
}, y(
|
|
128
|
-
|
|
147
|
+
}, y(k.value), 3),
|
|
148
|
+
c.item.badge && (!a(e).compact || !m.value || n.value) ? (r(), v("span", {
|
|
129
149
|
key: 1,
|
|
130
|
-
class:
|
|
131
|
-
|
|
132
|
-
{ "md:hidden":
|
|
150
|
+
class: u(["ml-auto inline-flex items-center px-1.5 py-0.5 rounded text-[10px] font-medium", [
|
|
151
|
+
c.item.badgeClass || "bg-muted text-muted-foreground",
|
|
152
|
+
{ "md:hidden": a(e).compact && !n.value }
|
|
133
153
|
]])
|
|
134
|
-
}, y(
|
|
154
|
+
}, y(c.item.badge), 3)) : d("", !0)
|
|
135
155
|
], 2),
|
|
136
|
-
|
|
137
|
-
class:
|
|
156
|
+
f("div", {
|
|
157
|
+
class: u(["ml-1.5 flex h-4 w-4 shrink-0 items-center justify-center text-muted-foreground", { "md:hidden": a(e).compact && !n.value }])
|
|
138
158
|
}, [
|
|
139
|
-
|
|
140
|
-
icon: "lucide:chevron-right",
|
|
159
|
+
C(w, {
|
|
160
|
+
icon: n.value ? "lucide:chevron-down" : "lucide:chevron-right",
|
|
141
161
|
class: "h-3 w-3"
|
|
142
|
-
})
|
|
162
|
+
}, null, 8, ["icon"])
|
|
143
163
|
], 2)
|
|
144
164
|
]),
|
|
145
165
|
_: 2
|
|
@@ -147,113 +167,110 @@ const ae = { class: "w-full relative sidebar-manu-item" }, ie = {
|
|
|
147
167
|
])
|
|
148
168
|
]),
|
|
149
169
|
_: 2
|
|
150
|
-
}, 1032, ["content", "disabled"])
|
|
170
|
+
}, 1032, ["content", "placement", "disabled"])
|
|
151
171
|
]),
|
|
152
|
-
item: h(({ option:
|
|
153
|
-
(
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
i.data?.badge ? (o(), m("span", {
|
|
167
|
-
key: 1,
|
|
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)
|
|
170
|
-
]),
|
|
171
|
-
_: 2
|
|
172
|
-
}, 1032, ["to", "href"]))
|
|
172
|
+
item: h(({ option: l }) => [
|
|
173
|
+
f("div", se, [
|
|
174
|
+
l.icon ? (r(), p(w, {
|
|
175
|
+
key: 0,
|
|
176
|
+
icon: l.icon,
|
|
177
|
+
class: "shrink-0 opacity-80",
|
|
178
|
+
style: $({ width: a(e).iconSize, height: a(e).iconSize })
|
|
179
|
+
}, null, 8, ["icon", "style"])) : d("", !0),
|
|
180
|
+
f("span", ue, y(l.label), 1),
|
|
181
|
+
l.data?.badge ? (r(), v("span", {
|
|
182
|
+
key: 1,
|
|
183
|
+
class: u(["ml-auto inline-flex items-center px-1.5 py-0.5 rounded text-[10px] font-medium", l.data?.badgeClass || "bg-muted text-muted-foreground"])
|
|
184
|
+
}, y(l.data.badge), 3)) : d("", !0)
|
|
185
|
+
])
|
|
173
186
|
]),
|
|
174
187
|
_: 1
|
|
175
|
-
}, 8, ["options"])) : (
|
|
176
|
-
|
|
177
|
-
content:
|
|
178
|
-
placement: "right",
|
|
179
|
-
disabled: !
|
|
188
|
+
}, 8, ["position", "offset", "width", "maxHeight", "options"])) : (r(), v(V, { key: 1 }, [
|
|
189
|
+
C(_, {
|
|
190
|
+
content: k.value,
|
|
191
|
+
placement: n.value ? "bottom" : "right",
|
|
192
|
+
disabled: !a(e).showTooltip || !a(e).compact && !n.value,
|
|
180
193
|
class: "w-full block"
|
|
181
194
|
}, {
|
|
182
195
|
default: h(() => [
|
|
183
|
-
(
|
|
184
|
-
class:
|
|
185
|
-
style:
|
|
186
|
-
"aria-expanded":
|
|
196
|
+
(r(), p(B(H.value), D(P.value, {
|
|
197
|
+
class: T.value,
|
|
198
|
+
style: N.value,
|
|
199
|
+
"aria-expanded": E.value ? M.value : void 0,
|
|
187
200
|
"aria-current": I.value ? "page" : void 0,
|
|
188
201
|
onClick: j
|
|
189
202
|
}), {
|
|
190
203
|
default: h(() => [
|
|
191
|
-
|
|
192
|
-
class:
|
|
193
|
-
|
|
204
|
+
f("div", {
|
|
205
|
+
class: u(["min-w-0 flex-1 flex", [
|
|
206
|
+
m.value && !n.value ? "flex-col items-center justify-center gap-1" : a(e).compact && !n.value ? "justify-center" : "items-center gap-2.5"
|
|
194
207
|
]])
|
|
195
208
|
}, [
|
|
196
|
-
|
|
209
|
+
c.item.icon ? (r(), p(w, {
|
|
197
210
|
key: 0,
|
|
198
|
-
icon:
|
|
199
|
-
class:
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
211
|
+
icon: c.item.icon,
|
|
212
|
+
class: u(["shrink-0 transition-colors opacity-80 group-hover:opacity-100", [I.value ? "opacity-100" : ""]]),
|
|
213
|
+
style: $({
|
|
214
|
+
width: a(e).compact && !n.value ? a(e).compactIconSize : a(e).iconSize,
|
|
215
|
+
height: a(e).compact && !n.value ? a(e).compactIconSize : a(e).iconSize
|
|
216
|
+
})
|
|
217
|
+
}, null, 8, ["icon", "class", "style"])) : d("", !0),
|
|
218
|
+
f("span", {
|
|
219
|
+
class: u(["truncate leading-none pt-0.5 wrap-break-word flex-wrap text-wrap", {
|
|
220
|
+
[a(e).compactLabelClass]: m.value && !n.value,
|
|
221
|
+
hidden: a(e).compact && !m.value && !n.value,
|
|
222
|
+
"md:hidden": a(e).compact && !m.value && !n.value
|
|
206
223
|
}])
|
|
207
|
-
}, y(
|
|
208
|
-
|
|
224
|
+
}, y(k.value), 3),
|
|
225
|
+
c.item.badge && (!a(e).compact || !m.value || n.value) ? (r(), v("span", {
|
|
209
226
|
key: 1,
|
|
210
|
-
class:
|
|
211
|
-
|
|
212
|
-
{ "md:hidden":
|
|
227
|
+
class: u(["ml-auto inline-flex items-center px-1.5 py-0.5 rounded text-[10px] font-medium", [
|
|
228
|
+
c.item.badgeClass || "bg-muted text-muted-foreground",
|
|
229
|
+
{ "md:hidden": a(e).compact && !n.value }
|
|
213
230
|
]])
|
|
214
|
-
}, y(
|
|
231
|
+
}, y(c.item.badge), 3)) : d("", !0)
|
|
215
232
|
], 2),
|
|
216
|
-
|
|
233
|
+
E.value ? (r(), v("div", {
|
|
217
234
|
key: 0,
|
|
218
235
|
role: "button",
|
|
219
236
|
tabindex: "0",
|
|
220
|
-
class:
|
|
221
|
-
onClick:
|
|
222
|
-
onKeydown:
|
|
237
|
+
class: u(["ml-1.5 flex shrink-0 items-center justify-center rounded-sm text-muted-foreground hover:bg-accent/50 hover:text-foreground transition-all", { "md:hidden": a(e).compact && !n.value }]),
|
|
238
|
+
onClick: L,
|
|
239
|
+
onKeydown: te(ae(L, ["prevent"]), ["enter", "space"])
|
|
223
240
|
}, [
|
|
224
|
-
|
|
241
|
+
C(w, {
|
|
225
242
|
icon: "lucide:chevron-down",
|
|
226
|
-
class:
|
|
243
|
+
class: u(["h-3 w-3 transition-transform duration-200", { "rotate-180": M.value && !n.value }])
|
|
227
244
|
}, null, 8, ["class"])
|
|
228
|
-
], 42,
|
|
245
|
+
], 42, de)) : d("", !0)
|
|
229
246
|
]),
|
|
230
247
|
_: 1
|
|
231
248
|
}, 16, ["class", "style", "aria-expanded", "aria-current"]))
|
|
232
249
|
]),
|
|
233
250
|
_: 1
|
|
234
|
-
}, 8, ["content", "disabled"]),
|
|
235
|
-
|
|
251
|
+
}, 8, ["content", "placement", "disabled"]),
|
|
252
|
+
C(ne, {
|
|
236
253
|
name: "sidebar-slide",
|
|
237
|
-
onBeforeEnter:
|
|
238
|
-
onEnter:
|
|
239
|
-
onAfterEnter:
|
|
240
|
-
onBeforeLeave:
|
|
241
|
-
onLeave:
|
|
254
|
+
onBeforeEnter: q,
|
|
255
|
+
onEnter: G,
|
|
256
|
+
onAfterEnter: J,
|
|
257
|
+
onBeforeLeave: Q,
|
|
258
|
+
onLeave: U
|
|
242
259
|
}, {
|
|
243
260
|
default: h(() => [
|
|
244
|
-
b.value &&
|
|
245
|
-
|
|
261
|
+
b.value && M.value && !n.value ? (r(), v("div", me, [
|
|
262
|
+
a(e).variant === "default" ? (r(), v("div", {
|
|
246
263
|
key: 0,
|
|
247
264
|
class: "absolute top-0 bottom-2 w-px bg-border",
|
|
248
|
-
style:
|
|
249
|
-
left: `${(
|
|
265
|
+
style: $({
|
|
266
|
+
left: `${(c.depth + 1) * z.value - z.value / 2}px`
|
|
250
267
|
})
|
|
251
268
|
}, null, 4)) : d("", !0),
|
|
252
|
-
|
|
253
|
-
(
|
|
254
|
-
key:
|
|
255
|
-
item:
|
|
256
|
-
depth:
|
|
269
|
+
f("div", ve, [
|
|
270
|
+
(r(!0), v(V, null, ie(c.item.children, (l) => (r(), p(x, {
|
|
271
|
+
key: l.id || l.label,
|
|
272
|
+
item: l,
|
|
273
|
+
depth: c.depth + 1
|
|
257
274
|
}, null, 8, ["item", "depth"]))), 128))
|
|
258
275
|
])
|
|
259
276
|
])) : d("", !0)
|
|
@@ -261,10 +278,10 @@ const ae = { class: "w-full relative sidebar-manu-item" }, ie = {
|
|
|
261
278
|
_: 1
|
|
262
279
|
})
|
|
263
280
|
], 64))
|
|
264
|
-
]);
|
|
281
|
+
], 2);
|
|
265
282
|
};
|
|
266
283
|
}
|
|
267
284
|
});
|
|
268
285
|
export {
|
|
269
|
-
|
|
286
|
+
xe as default
|
|
270
287
|
};
|
|
@@ -3,25 +3,41 @@ export interface SidebarMenuItemSchema {
|
|
|
3
3
|
label: string;
|
|
4
4
|
labelI18n?: string;
|
|
5
5
|
icon?: string;
|
|
6
|
-
to?: string |
|
|
6
|
+
to?: string | {
|
|
7
|
+
path: string;
|
|
8
|
+
[key: string]: any;
|
|
9
|
+
};
|
|
7
10
|
href?: string;
|
|
8
11
|
children?: SidebarMenuItemSchema[];
|
|
9
12
|
badge?: string | number;
|
|
10
13
|
badgeClass?: string;
|
|
11
14
|
disabled?: boolean;
|
|
12
|
-
class?: string;
|
|
13
|
-
action?: (item: SidebarMenuItemSchema) => void;
|
|
14
15
|
renderMode?: 'tree' | 'popover';
|
|
16
|
+
action?: (item: SidebarMenuItemSchema) => void;
|
|
17
|
+
class?: string;
|
|
15
18
|
}
|
|
16
19
|
export interface SidebarMenuProps {
|
|
17
|
-
items
|
|
20
|
+
items?: SidebarMenuItemSchema[];
|
|
18
21
|
allowMultiple?: boolean;
|
|
19
22
|
indentSize?: number;
|
|
20
23
|
variant?: 'default' | 'ghost';
|
|
21
24
|
defaultExpanded?: string[];
|
|
22
25
|
compact?: boolean;
|
|
23
|
-
renderMode?: 'tree' | 'popover';
|
|
24
26
|
showCompactLabels?: boolean;
|
|
27
|
+
renderMode?: 'tree' | 'popover';
|
|
28
|
+
iconSize?: string;
|
|
29
|
+
compactIconSize?: string;
|
|
30
|
+
labelClass?: string;
|
|
31
|
+
compactLabelClass?: string;
|
|
32
|
+
itemPadding?: string;
|
|
33
|
+
compactItemPadding?: string;
|
|
34
|
+
nestedMenuWidth?: string;
|
|
35
|
+
nestedMenuMaxHeight?: string;
|
|
36
|
+
itemClass?: string;
|
|
37
|
+
menuOffset?: [number, number];
|
|
38
|
+
orientation?: 'vertical' | 'horizontal';
|
|
39
|
+
mobileBreakpoint?: 'sm' | 'md' | 'lg' | 'xl' | 'none';
|
|
40
|
+
showTooltip?: boolean;
|
|
25
41
|
}
|
|
26
42
|
export interface SidebarMenuContext {
|
|
27
43
|
activeItem: string | null;
|
|
@@ -31,6 +47,17 @@ export interface SidebarMenuContext {
|
|
|
31
47
|
indentSize: number;
|
|
32
48
|
variant: 'default' | 'ghost';
|
|
33
49
|
renderMode: 'tree' | 'popover';
|
|
50
|
+
renderNestedTabs: boolean;
|
|
34
51
|
compact: boolean;
|
|
35
52
|
showCompactLabels: boolean;
|
|
53
|
+
iconSize: string;
|
|
54
|
+
compactIconSize: string;
|
|
55
|
+
labelClass: string;
|
|
56
|
+
compactLabelClass: string;
|
|
57
|
+
itemPadding: string;
|
|
58
|
+
compactItemPadding: string;
|
|
59
|
+
nestedMenuWidth: string;
|
|
60
|
+
nestedMenuMaxHeight: string;
|
|
61
|
+
currentOrientation: 'vertical' | 'horizontal';
|
|
62
|
+
showTooltip: boolean;
|
|
36
63
|
}
|
|
@@ -13,12 +13,12 @@ type __VLS_Props = {
|
|
|
13
13
|
size?: 'xs' | 'sm' | 'md' | 'lg';
|
|
14
14
|
};
|
|
15
15
|
declare const _default: import('vue').DefineComponent<__VLS_Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {
|
|
16
|
-
"update:modelValue": (value: number) => any;
|
|
17
16
|
change: (value: number) => any;
|
|
17
|
+
"update:modelValue": (value: number) => any;
|
|
18
18
|
iconClick: () => any;
|
|
19
19
|
}, string, import('vue').PublicProps, Readonly<__VLS_Props> & Readonly<{
|
|
20
|
-
"onUpdate:modelValue"?: (value: number) => any;
|
|
21
20
|
onChange?: (value: number) => any;
|
|
21
|
+
"onUpdate:modelValue"?: (value: number) => any;
|
|
22
22
|
onIconClick?: () => any;
|
|
23
23
|
}>, {
|
|
24
24
|
size: "xs" | "sm" | "md" | "lg";
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { SpinnerProps, SpinnerSize, SpinnerColor, SpinnerVariant } from './types';
|
|
2
2
|
declare const _default: import('vue').DefineComponent<SpinnerProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<SpinnerProps> & Readonly<{}>, {
|
|
3
|
+
variant: SpinnerVariant;
|
|
4
|
+
size: SpinnerSize;
|
|
3
5
|
class: string;
|
|
4
6
|
color: SpinnerColor;
|
|
5
|
-
size: SpinnerSize;
|
|
6
|
-
variant: SpinnerVariant;
|
|
7
7
|
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, HTMLSpanElement>;
|
|
8
8
|
export default _default;
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
import { StatsProps } from './types';
|
|
2
|
+
declare const _default: import('vue').DefineComponent<StatsProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<StatsProps> & Readonly<{}>, {
|
|
3
|
+
variant: import('./types').StatsVariant;
|
|
4
|
+
class: string;
|
|
5
|
+
columns: number | string;
|
|
6
|
+
layout: import('./types').StatsLayout;
|
|
7
|
+
attached: boolean;
|
|
8
|
+
titleSize: string;
|
|
9
|
+
valueSize: string;
|
|
10
|
+
iconSize: string;
|
|
11
|
+
iconBoxShape: import('./types').IconBoxShape;
|
|
12
|
+
iconBoxStyle: import('./types').IconBoxStyle;
|
|
13
|
+
}, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
|
|
14
|
+
export default _default;
|