vlite3 1.0.10 → 1.1.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.
Files changed (113) hide show
  1. package/README.md +4 -1
  2. package/components/AttachmentsList/AttachmentsList.vue.d.ts +1 -16
  3. package/components/AttachmentsList/AttachmentsList.vue.js +191 -167
  4. package/components/AvatarGroup/AvatarGroup.vue.d.ts +24 -0
  5. package/components/AvatarGroup/AvatarGroup.vue.js +91 -0
  6. package/components/AvatarGroup/AvatarGroup.vue2.js +4 -0
  7. package/components/AvatarGroup/index.d.ts +2 -0
  8. package/components/AvatarUploader/AvatarUploader.vue.d.ts +1 -1
  9. package/components/Barcode/Barcode.vue.js +6 -5
  10. package/components/Button.vue.d.ts +1 -1
  11. package/components/Calendar/Calendar.vue.d.ts +229 -0
  12. package/components/Calendar/Calendar.vue.js +7 -0
  13. package/components/Calendar/Calendar.vue2.js +186 -0
  14. package/components/Calendar/CalendarEventItem.vue.d.ts +17 -0
  15. package/components/Calendar/CalendarEventItem.vue.js +111 -0
  16. package/components/Calendar/CalendarEventItem.vue2.js +4 -0
  17. package/components/Calendar/index.d.ts +2 -0
  18. package/components/Carousel/Carousel.vue.d.ts +2 -2
  19. package/components/CategoryManager/CategoryManager.vue.d.ts +2 -1
  20. package/components/CategoryManager/CategoryManager.vue.js +322 -0
  21. package/components/CategoryManager/CategoryManager.vue2.js +4 -0
  22. package/components/CategoryManager/CategoryNode.vue.js +224 -0
  23. package/components/CategoryManager/CategoryNode.vue2.js +4 -0
  24. package/components/CategoryManager/types.d.ts +14 -0
  25. package/components/Chip/Chip.vue.d.ts +2 -2
  26. package/components/ColorPicker/ColorIro.vue3.js +2 -2
  27. package/components/ColorPicker/ColorPicker.vue.js +2 -2
  28. package/components/CommandPalette/CommandPaletteContent.vue.js +1 -1
  29. package/components/CommandPalette/CommandPaletteContent.vue2.js +7 -7
  30. package/components/CommandPalette/{CommandPaletteItem.vue2.js → CommandPaletteItem.vue.js} +1 -1
  31. package/components/ConfirmationModal.vue.d.ts +2 -2
  32. package/components/CustomFieldsDisplay/CustomFieldsDisplay.vue.d.ts +48 -0
  33. package/components/CustomFieldsDisplay/CustomFieldsDisplay.vue.js +97 -0
  34. package/components/CustomFieldsDisplay/CustomFieldsDisplay.vue2.js +4 -0
  35. package/components/CustomFieldsDisplay/index.d.ts +2 -0
  36. package/components/CustomFieldsDisplay/types.d.ts +18 -0
  37. package/components/DataTable/DataTable.vue.d.ts +3 -3
  38. package/components/DateTime/DateTime.vue.d.ts +2 -0
  39. package/components/DateTime/DateTime.vue.js +9 -23
  40. package/components/Dropdown/Dropdown.vue.d.ts +3 -3
  41. package/components/Dropdown/DropdownGroupedLayout.vue.d.ts +1 -1
  42. package/components/Dropdown/DropdownMenu.vue.d.ts +2 -2
  43. package/components/Dropdown/DropdownTrigger.vue.d.ts +1 -1
  44. package/components/FilePicker/FilePicker.vue.d.ts +1 -1
  45. package/components/Form/CustomFields.vue.d.ts +1 -1
  46. package/components/Form/Form.vue.js +2 -2
  47. package/components/Form/Form.vue2.js +230 -241
  48. package/components/Form/FormField.vue.d.ts +1 -1
  49. package/components/Form/composables/useForm.d.ts +2 -0
  50. package/components/Form/composables/useForm.js +76 -69
  51. package/components/Form/utils/form.utils.js +66 -66
  52. package/components/ImportData/ImportData.vue.js +48 -48
  53. package/components/ImportData/ImportStep2.vue.js +116 -5
  54. package/components/ImportData/ImportStep2.vue2.js +2 -105
  55. package/components/Input.vue.d.ts +3 -3
  56. package/components/Invoice/Invoice.vue.d.ts +3 -0
  57. package/components/Invoice/Invoice.vue.js +38 -0
  58. package/components/Invoice/Invoice.vue2.js +4 -0
  59. package/components/Invoice/InvoiceVariant1.vue.d.ts +13 -0
  60. package/components/Invoice/InvoiceVariant1.vue.js +360 -0
  61. package/components/Invoice/InvoiceVariant1.vue2.js +4 -0
  62. package/components/Invoice/InvoiceVariant2.vue.d.ts +13 -0
  63. package/components/Invoice/InvoiceVariant2.vue.js +226 -0
  64. package/components/Invoice/InvoiceVariant2.vue2.js +4 -0
  65. package/components/Invoice/InvoiceVariant3.vue.d.ts +13 -0
  66. package/components/Invoice/InvoiceVariant3.vue.js +292 -0
  67. package/components/Invoice/InvoiceVariant3.vue2.js +4 -0
  68. package/components/Invoice/InvoiceVariant4.vue.d.ts +13 -0
  69. package/components/Invoice/InvoiceVariant4.vue.js +343 -0
  70. package/components/Invoice/InvoiceVariant4.vue2.js +4 -0
  71. package/components/Invoice/index.d.ts +2 -0
  72. package/components/Invoice/types.d.ts +97 -0
  73. package/components/List/List.vue.d.ts +1 -9
  74. package/components/List/List.vue.js +166 -165
  75. package/components/List/ListFieldRow.vue.d.ts +10 -2
  76. package/components/List/ListFieldRow.vue.js +80 -78
  77. package/components/List/utils.d.ts +2 -1
  78. package/components/List/utils.js +8 -39
  79. package/components/MultiSelect/MultiSelect.vue.d.ts +1 -1
  80. package/components/Navbar/NavbarItem.vue.d.ts +1 -1
  81. package/components/Navbar/NavbarTabs.vue.js +2 -2
  82. package/components/NavbarCommandPalette.vue.js +1 -1
  83. package/components/NumberInput.vue.d.ts +2 -2
  84. package/components/NumberInput.vue.js +2 -2
  85. package/components/NumberInput.vue2.js +38 -38
  86. package/components/OTPInput/OTPInput.vue.d.ts +1 -1
  87. package/components/PricingPlan/PricingPlan.vue.d.ts +1 -1
  88. package/components/Screen/ScreenFilter.vue.js +22 -21
  89. package/components/Screen/components/ScreenQuickFilters.vue.js +6 -5
  90. package/components/SidebarMenu/SidebarMenu.vue.d.ts +1 -1
  91. package/components/Stats/Stats.vue.d.ts +1 -1
  92. package/components/StatusChip/status-map.js +27 -7
  93. package/components/Tabes/Tabes.vue.d.ts +1 -0
  94. package/components/Tabes/Tabes.vue.js +2 -2
  95. package/components/Tabes/Tabes.vue2.js +33 -32
  96. package/components/ThumbnailSelector/ThumbnailSelector.vue.d.ts +2 -2
  97. package/components/ThumbnailSelector/ThumbnailSelector.vue.js +2 -2
  98. package/components/ThumbnailSelector/ThumbnailSelector.vue2.js +141 -115
  99. package/components/Workbook/Workbook.vue.d.ts +3 -3
  100. package/core/config.d.ts +76 -0
  101. package/core/index.js +17 -5
  102. package/index.d.ts +6 -1
  103. package/index.js +271 -256
  104. package/package.json +2 -1
  105. package/style.css +5 -3
  106. package/types/config.type.d.ts +6 -0
  107. package/types/list.type.d.ts +6 -0
  108. package/utils/configUtils.d.ts +9 -0
  109. package/utils/configUtils.js +7 -0
  110. package/utils/index.d.ts +1 -0
  111. package/utils/status.d.ts +5 -0
  112. package/utils/status.js +33 -0
  113. /package/components/ColorPicker/{ColorIro.vue.js → ColorIro.vue2.js} +0 -0
package/README.md CHANGED
@@ -88,7 +88,7 @@ const vlite = createVLite({
88
88
  *
89
89
  * This function will be called automatically by:
90
90
  * - useFileUpload() composable
91
- * - Form components (when using 'file', 'fileUploader', or 'avatarUpload' types)
91
+ * - Form components (when using 'file', 'fileUploader', 'ThumbnailSelector', or 'avatarUpload' types)
92
92
  *
93
93
  * @param file - The File object to upload
94
94
  * @param folderId - (Optional) Folder ID passed from component props
@@ -419,9 +419,11 @@ Follow these rules strictly to ensure visual consistency and predictable styling
419
419
  - [x] **NumberInput**
420
420
  - [x] **DatePicker**
421
421
  - [x] **DateRangePicker**
422
+ - [x] **Calendar**
422
423
  - [x] **ColorPicker**
423
424
  - [x] **FilePicker**
424
425
  - [x] **AvatarUploader**
426
+ - [x] **ThumbnailSelector**
425
427
  - [x] **IconPicker**
426
428
  - [x] **MultiSelect**
427
429
  - [x] **Forms**
@@ -448,6 +450,7 @@ Follow these rules strictly to ensure visual consistency and predictable styling
448
450
  - [x] **Stats**
449
451
  - [x] **Price**
450
452
  - [x] **Date**
453
+ - [x] **Invoice**
451
454
 
452
455
  ### Feedback & Overlays
453
456
 
@@ -1,23 +1,8 @@
1
1
  import { AttachmentsListProps } from './';
2
2
  declare const _default: import('vue').DefineComponent<AttachmentsListProps, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<AttachmentsListProps> & Readonly<{}>, {
3
- variant: "default" | "list" | "inline" | "card";
4
- size: "sm" | "md" | "lg";
5
- itemClass: string;
6
- gridClass: string;
7
- canDownload: boolean;
8
3
  canView: boolean;
4
+ canDownload: boolean;
9
5
  clickToPreview: boolean;
10
6
  showDownloadInList: boolean;
11
- rootClass: string;
12
- cardClass: string;
13
- cardThumbnailClass: string;
14
- cardInfoClass: string;
15
- cardActionsClass: string;
16
- listClass: string;
17
- itemIconBoxClass: string;
18
- itemNameClass: string;
19
- itemSizeClass: string;
20
- itemActionsClass: string;
21
- emptyClass: string;
22
7
  }, {}, {}, {}, string, import('vue').ComponentProvideOptions, true, {}, any>;
23
8
  export default _default;
@@ -1,48 +1,65 @@
1
- import { defineComponent as S, ref as L, computed as f, openBlock as a, createElementBlock as o, normalizeClass as l, Fragment as v, renderList as U, createElementVNode as d, createBlock as u, unref as i, withCtx as T, createVNode as p, createCommentVNode as m, withModifiers as j, toDisplayString as y } from "vue";
2
- import x from "../Modal.vue.js";
3
- import P from "../Icon.vue.js";
4
- import N from "../Button.vue.js";
5
- import { $t as w } from "../../utils/i18n.js";
6
- import { downloadFile as E } from "../../utils/functions.js";
7
- import b from "../FilePreview/FilePreview.vue.js";
8
- import { getFileTypeIcon as F } from "./fileTypeIcon.js";
9
- const G = ["onClick"], K = ["src"], W = ["title"], q = { class: "vl-attachments-list__item-size text-xs text-muted-foreground mt-0.5" }, H = ["onClick"], J = { class: "flex items-center gap-3 overflow-hidden min-w-0 flex-1" }, O = ["src"], Q = { class: "flex flex-col overflow-hidden leading-tight min-w-0" }, R = ["title"], X = ["aria-label"], Y = ["aria-label", "onClick"], ie = /* @__PURE__ */ S({
1
+ import { defineComponent as ne, computed as a, ref as ie, openBlock as t, createElementBlock as l, normalizeClass as n, Fragment as x, renderList as $, createElementVNode as B, createBlock as u, unref as c, withCtx as j, createVNode as I, createCommentVNode as r, withModifiers as G, toDisplayString as b } from "vue";
2
+ import C from "../Modal.vue.js";
3
+ import D from "../Icon.vue.js";
4
+ import A from "../Button.vue.js";
5
+ import { $t as v } from "../../utils/i18n.js";
6
+ import { downloadFile as re } from "../../utils/functions.js";
7
+ import { getComponentConfig as ce } from "../../utils/configUtils.js";
8
+ import k from "../FilePreview/FilePreview.vue.js";
9
+ import { getFileTypeIcon as K } from "./fileTypeIcon.js";
10
+ const de = ["onClick"], me = ["src"], ue = ["title"], ve = {
11
+ key: 1,
12
+ class: "vl-attachments-list__item-size text-xs text-muted-foreground mt-0.5"
13
+ }, pe = ["onClick"], he = { class: "flex items-center gap-3 overflow-hidden min-w-0 flex-1" }, we = ["src"], ye = {
14
+ key: 0,
15
+ class: "flex flex-col overflow-hidden leading-tight min-w-0"
16
+ }, xe = ["title"], ge = ["aria-label"], fe = ["aria-label", "onClick"], De = /* @__PURE__ */ ne({
10
17
  __name: "AttachmentsList",
11
18
  props: {
12
19
  attachments: {},
13
- canView: { type: Boolean, default: !0 },
14
- canDownload: { type: Boolean, default: !0 },
15
- variant: { default: "default" },
16
- size: { default: "md" },
17
- clickToPreview: { type: Boolean, default: !1 },
18
- showDownloadInList: { type: Boolean, default: !0 },
19
- rootClass: { default: "" },
20
- gridClass: { default: "" },
21
- cardClass: { default: "" },
22
- cardThumbnailClass: { default: "" },
23
- cardInfoClass: { default: "" },
24
- cardActionsClass: { default: "" },
25
- listClass: { default: "" },
26
- itemClass: { default: "" },
27
- itemIconBoxClass: { default: "" },
28
- itemNameClass: { default: "" },
29
- itemSizeClass: { default: "" },
30
- itemActionsClass: { default: "" },
31
- emptyClass: { default: "" }
20
+ canView: { type: Boolean, default: void 0 },
21
+ canDownload: { type: Boolean, default: void 0 },
22
+ variant: {},
23
+ size: {},
24
+ clickToPreview: { type: Boolean, default: void 0 },
25
+ showDownloadInList: { type: Boolean, default: void 0 },
26
+ rootClass: {},
27
+ gridClass: {},
28
+ cardClass: {},
29
+ cardThumbnailClass: {},
30
+ cardInfoClass: {},
31
+ cardActionsClass: {},
32
+ listClass: {},
33
+ itemClass: {},
34
+ itemIconBoxClass: {},
35
+ itemNameClass: {},
36
+ itemSizeClass: {},
37
+ itemActionsClass: {},
38
+ emptyClass: {}
32
39
  },
33
- setup(t) {
34
- const c = t, g = L(null), k = f(() => c.attachments ? Array.isArray(c.attachments) ? c.attachments : [c.attachments] : []), I = (n) => {
35
- if (!n) return "0 Bytes";
36
- const h = 1024, e = ["Bytes", "KB", "MB", "GB"], s = Math.floor(Math.log(n) / Math.log(h));
37
- return parseFloat((n / Math.pow(h, s)).toFixed(2)) + " " + e[s];
38
- }, D = async (n) => {
39
- n.fileUrl && n.fileUrl !== "#" && await E(n.fileUrl, n.fileName || "attachment");
40
- }, A = (n) => n.fileType && n.fileType.startsWith("image/") ? !0 : /\.(jpg|jpeg|png|gif|webp|svg|bmp)(\?.*)?$/i.test(n.fileUrl || ""), V = (n) => {
41
- c.clickToPreview && c.canView && (g.value = n);
42
- }, $ = () => {
43
- g.value = null;
44
- }, r = f(() => {
45
- switch (c.size) {
40
+ setup(W) {
41
+ const s = W, i = ce("attachmentsList") || {}, p = a(() => s.canView ?? i.canView ?? !0), h = a(() => s.canDownload ?? i.canDownload ?? !0), w = a(() => s.variant ?? i.variant ?? "default"), L = a(() => s.size ?? i.size ?? "md"), y = a(() => s.clickToPreview ?? i.clickToPreview ?? !1), q = a(
42
+ () => s.showDownloadInList ?? i.showDownloadInList ?? !0
43
+ ), H = a(() => s.rootClass ?? i.rootClass ?? ""), J = a(() => s.gridClass ?? i.gridClass ?? ""), O = a(() => s.cardClass ?? i.cardClass ?? ""), Q = a(
44
+ () => s.cardThumbnailClass ?? i.cardThumbnailClass ?? ""
45
+ ), R = a(() => s.cardInfoClass ?? i.cardInfoClass ?? ""), X = a(
46
+ () => s.cardActionsClass ?? i.cardActionsClass ?? ""
47
+ ), Y = a(() => s.listClass ?? i.listClass ?? ""), Z = a(() => s.itemClass ?? i.itemClass ?? ""), ee = a(
48
+ () => s.itemIconBoxClass ?? i.itemIconBoxClass ?? ""
49
+ ), te = a(() => s.itemNameClass ?? i.itemNameClass ?? ""), ae = a(() => s.itemSizeClass ?? i.itemSizeClass ?? ""), se = a(
50
+ () => s.itemActionsClass ?? i.itemActionsClass ?? ""
51
+ ), oe = a(() => s.emptyClass ?? i.emptyClass ?? ""), N = ie(null), z = a(() => s.attachments ? Array.isArray(s.attachments) ? s.attachments : [s.attachments] : []), V = (o) => {
52
+ if (!o) return "0 Bytes";
53
+ const _ = 1024, e = ["Bytes", "KB", "MB", "GB"], d = Math.floor(Math.log(o) / Math.log(_));
54
+ return parseFloat((o / Math.pow(_, d)).toFixed(2)) + " " + e[d];
55
+ }, U = async (o) => {
56
+ o.fileUrl && o.fileUrl !== "#" && await re(o.fileUrl, o.fileName || "attachment");
57
+ }, F = (o) => o.fileType && o.fileType.startsWith("image/") ? !0 : /\.(jpg|jpeg|png|gif|webp|svg|bmp)(\?.*)?$/i.test(o.fileUrl || ""), g = (o) => o.fileName !== void 0 && o.fileName !== null && String(o.fileName).trim() !== "", f = (o) => o.fileSize !== void 0 && o.fileSize !== null && String(o.fileSize).trim() !== "", M = (o) => {
58
+ y.value && p.value && (N.value = o);
59
+ }, E = () => {
60
+ N.value = null;
61
+ }, m = a(() => {
62
+ switch (L.value) {
46
63
  case "sm":
47
64
  return {
48
65
  item: "pl-2 pr-2.5 py-1.5 gap-1.5",
@@ -74,45 +91,48 @@ const G = ["onClick"], K = ["src"], W = ["title"], q = { class: "vl-attachments-
74
91
  actionIcon: "w-4 h-4"
75
92
  };
76
93
  }
77
- }), z = f(() => c.canView && !c.clickToPreview), B = f(() => c.canDownload && c.showDownloadInList), M = f(() => z.value || B.value);
78
- return (n, h) => (a(), o("div", {
79
- class: l(["vl-attachments-list w-full", t.rootClass])
94
+ }), S = a(() => p.value && !y.value), T = a(() => h.value && q.value), le = a(() => S.value || T.value);
95
+ return (o, _) => (t(), l("div", {
96
+ class: n(["vl-attachments-list w-full", H.value])
80
97
  }, [
81
- k.value.length > 0 ? (a(), o(v, { key: 0 }, [
82
- t.variant === "card" ? (a(), o("div", {
98
+ z.value.length > 0 ? (t(), l(x, { key: 0 }, [
99
+ w.value === "card" ? (t(), l("div", {
83
100
  key: 0,
84
- class: l(["vl-attachments-list__grid grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4 gap-4", t.gridClass])
101
+ class: n(["vl-attachments-list__grid grid grid-cols-1 sm:grid-cols-2 md:grid-cols-3 lg:grid-cols-4 gap-4", J.value])
85
102
  }, [
86
- (a(!0), o(v, null, U(k.value, (e, s) => (a(), o("div", {
87
- key: s,
88
- class: l(["vl-attachments-list__card relative group rounded-xl border border-border bg-body overflow-hidden hover:shadow-md transition-all flex flex-col", [{ "cursor-pointer": t.clickToPreview && t.canView }, t.cardClass]]),
89
- onClick: (C) => V(s)
103
+ (t(!0), l(x, null, $(z.value, (e, d) => (t(), l("div", {
104
+ key: d,
105
+ class: n(["vl-attachments-list__card relative group rounded-xl border border-border bg-body overflow-hidden hover:shadow-md transition-all flex flex-col", [{ "cursor-pointer": y.value && p.value }, O.value]]),
106
+ onClick: (P) => M(d)
90
107
  }, [
91
- d("div", {
92
- class: l(["vl-attachments-list__card-thumbnail h-40 w-full bg-muted/30 flex items-center justify-center overflow-hidden relative border-b border-border", t.cardThumbnailClass])
108
+ B("div", {
109
+ class: n(["vl-attachments-list__card-thumbnail h-40 w-full bg-muted/30 flex items-center justify-center overflow-hidden relative", [
110
+ Q.value,
111
+ g(e) || f(e) ? "border-b border-border" : ""
112
+ ]])
93
113
  }, [
94
- A(e) ? (a(), o("img", {
114
+ F(e) ? (t(), l("img", {
95
115
  key: 0,
96
116
  src: e.thumbnailUrl || e.fileUrl,
97
117
  class: "w-full h-full object-cover transition-transform group-hover:scale-105"
98
- }, null, 8, K)) : (a(), u(P, {
118
+ }, null, 8, me)) : (t(), u(D, {
99
119
  key: 1,
100
- icon: i(F)(e.fileName, e.fileUrl, e.fileType),
120
+ icon: c(K)(e.fileName, e.fileUrl, e.fileType),
101
121
  class: "w-12 h-12 text-muted-foreground/40 transition-transform group-hover:scale-110"
102
122
  }, null, 8, ["icon"])),
103
- t.clickToPreview ? m("", !0) : (a(), o("div", {
123
+ y.value ? r("", !0) : (t(), l("div", {
104
124
  key: 2,
105
- class: l(["vl-attachments-list__card-actions absolute top-2 right-2 flex items-center gap-1 opacity-0 group-hover:opacity-100 transition-opacity", t.cardActionsClass])
125
+ class: n(["vl-attachments-list__card-actions absolute top-2 right-2 flex items-center gap-1 opacity-0 group-hover:opacity-100 transition-opacity", X.value])
106
126
  }, [
107
- t.canView ? (a(), u(x, {
127
+ p.value ? (t(), u(C, {
108
128
  key: 0,
109
- title: e.fileName || i(w)("common.words.preview", "Preview"),
129
+ title: e.fileName || c(v)("common.words.preview", "Preview"),
110
130
  "max-width": "max-w-3xl",
111
- body: i(b),
112
- bodyProps: { url: e.fileUrl, name: e.fileName, canDownload: t.canDownload }
131
+ body: c(k),
132
+ bodyProps: { url: e.fileUrl, name: e.fileName, canDownload: h.value }
113
133
  }, {
114
- trigger: T(() => [
115
- p(N, {
134
+ trigger: j(() => [
135
+ I(A, {
116
136
  variant: "secondary",
117
137
  size: "xs",
118
138
  icon: "lucide:eye",
@@ -120,172 +140,176 @@ const G = ["onClick"], K = ["src"], W = ["title"], q = { class: "vl-attachments-
120
140
  })
121
141
  ]),
122
142
  _: 1
123
- }, 8, ["title", "body", "bodyProps"])) : m("", !0),
124
- t.canDownload ? (a(), u(N, {
143
+ }, 8, ["title", "body", "bodyProps"])) : r("", !0),
144
+ h.value ? (t(), u(A, {
125
145
  key: 1,
126
146
  variant: "secondary",
127
147
  size: "xs",
128
148
  icon: "lucide:download",
129
149
  class: "h-7 w-7 px-0 rounded-md shadow-sm",
130
- onClick: j((C) => D(e), ["stop"])
131
- }, null, 8, ["onClick"])) : m("", !0)
150
+ onClick: G((P) => U(e), ["stop"])
151
+ }, null, 8, ["onClick"])) : r("", !0)
132
152
  ], 2))
133
153
  ], 2),
134
- d("div", {
135
- class: l(["vl-attachments-list__card-info p-3 flex flex-col min-w-0", t.cardInfoClass])
154
+ g(e) || f(e) ? (t(), l("div", {
155
+ key: 0,
156
+ class: n(["vl-attachments-list__card-info p-3 flex flex-col min-w-0", R.value])
136
157
  }, [
137
- d("span", {
158
+ g(e) ? (t(), l("span", {
159
+ key: 0,
138
160
  class: "vl-attachments-list__item-name text-sm font-medium truncate",
139
161
  title: e.fileName
140
- }, y(e.fileName || "Unnamed File"), 9, W),
141
- d("span", q, y(I(e.fileSize)), 1)
142
- ], 2),
143
- t.clickToPreview && t.canView ? (a(), u(x, {
144
- key: 0,
145
- show: g.value === s,
146
- title: e.fileName || i(w)("common.words.preview", "Preview"),
162
+ }, b(e.fileName), 9, ue)) : r("", !0),
163
+ f(e) ? (t(), l("span", ve, b(V(e.fileSize)), 1)) : r("", !0)
164
+ ], 2)) : r("", !0),
165
+ y.value && p.value ? (t(), u(C, {
166
+ key: 1,
167
+ show: N.value === d,
168
+ title: e.fileName || c(v)("common.words.preview", "Preview"),
147
169
  "max-width": "max-w-3xl",
148
- body: i(b),
149
- bodyProps: { url: e.fileUrl, name: e.fileName, canDownload: t.canDownload },
150
- onClose: $
151
- }, null, 8, ["show", "title", "body", "bodyProps"])) : m("", !0)
152
- ], 10, G))), 128))
153
- ], 2)) : (a(), o("div", {
170
+ body: c(k),
171
+ bodyProps: { url: e.fileUrl, name: e.fileName, canDownload: h.value },
172
+ onClose: E
173
+ }, null, 8, ["show", "title", "body", "bodyProps"])) : r("", !0)
174
+ ], 10, de))), 128))
175
+ ], 2)) : (t(), l("div", {
154
176
  key: 1,
155
- class: l(["vl-attachments-list__list flex flex-col gap-1.5", t.listClass])
177
+ class: n(["vl-attachments-list__list flex flex-col gap-1.5", Y.value])
156
178
  }, [
157
- (a(!0), o(v, null, U(k.value, (e, s) => (a(), o("div", {
158
- key: s,
159
- class: l(["vl-attachments-list__item flex items-center justify-between transition-colors rounded-lg", [
160
- t.variant === "inline" ? "bg-[#79797924] hover:bg-[#7979793f]" : "border border-border bg-muted/20 hover:bg-muted/40",
161
- r.value.item,
162
- t.clickToPreview && t.canView ? "cursor-pointer select-none" : "",
163
- t.itemClass
179
+ (t(!0), l(x, null, $(z.value, (e, d) => (t(), l("div", {
180
+ key: d,
181
+ class: n(["vl-attachments-list__item flex items-center justify-between transition-colors rounded-lg", [
182
+ w.value === "inline" ? "bg-[#79797924] hover:bg-[#7979793f]" : "border border-border bg-muted/20 hover:bg-muted/40",
183
+ m.value.item,
184
+ y.value && p.value ? "cursor-pointer select-none" : "",
185
+ Z.value
164
186
  ]]),
165
- onClick: (C) => V(s)
187
+ onClick: (P) => M(d)
166
188
  }, [
167
- d("div", J, [
168
- d("div", {
169
- class: l(["vl-attachments-list__item-icon-box flex items-center justify-center shrink-0 overflow-hidden relative", [
170
- r.value.iconBox,
171
- t.variant === "inline" ? "bg-[#79797924] hover:bg-[#7979793f]" : "bg-primary/10",
172
- t.itemIconBoxClass
189
+ B("div", he, [
190
+ B("div", {
191
+ class: n(["vl-attachments-list__item-icon-box flex items-center justify-center shrink-0 overflow-hidden relative", [
192
+ m.value.iconBox,
193
+ w.value === "inline" ? "bg-[#79797924] hover:bg-[#7979793f]" : "bg-primary/10",
194
+ ee.value
173
195
  ]])
174
196
  }, [
175
- A(e) ? (a(), o("img", {
197
+ F(e) ? (t(), l("img", {
176
198
  key: 0,
177
199
  src: e.thumbnailUrl || e.fileUrl,
178
200
  class: "w-full h-full object-cover"
179
- }, null, 8, O)) : (a(), u(P, {
201
+ }, null, 8, we)) : (t(), u(D, {
180
202
  key: 1,
181
- icon: i(F)(e.fileName, e.fileUrl, e.fileType),
182
- class: l([r.value.icon, t.variant === "inline" ? "opacity-75" : "text-primary"])
203
+ icon: c(K)(e.fileName, e.fileUrl, e.fileType),
204
+ class: n([m.value.icon, w.value === "inline" ? "opacity-75" : "text-primary"])
183
205
  }, null, 8, ["icon", "class"]))
184
206
  ], 2),
185
- d("div", Q, [
186
- d("span", {
187
- class: l(["vl-attachments-list__item-name font-medium truncate block", [
188
- r.value.text,
189
- t.variant === "inline" ? "" : "text-foreground",
190
- t.itemNameClass
207
+ g(e) || f(e) ? (t(), l("div", ye, [
208
+ g(e) ? (t(), l("span", {
209
+ key: 0,
210
+ class: n(["vl-attachments-list__item-name font-medium truncate block", [
211
+ m.value.text,
212
+ w.value === "inline" ? "" : "text-foreground",
213
+ te.value
191
214
  ]]),
192
215
  title: e.fileName
193
- }, y(e.fileName || "Unnamed File"), 11, R),
194
- d("span", {
195
- class: l(["vl-attachments-list__item-size mt-0.5", [
196
- r.value.subtext,
197
- t.variant === "inline" ? "opacity-50" : "text-muted-foreground",
198
- t.itemSizeClass
216
+ }, b(e.fileName), 11, xe)) : r("", !0),
217
+ f(e) ? (t(), l("span", {
218
+ key: 1,
219
+ class: n(["vl-attachments-list__item-size mt-0.5", [
220
+ m.value.subtext,
221
+ w.value === "inline" ? "opacity-50" : "text-muted-foreground",
222
+ ae.value
199
223
  ]])
200
- }, y(I(e.fileSize)), 3)
201
- ])
224
+ }, b(V(e.fileSize)), 3)) : r("", !0)
225
+ ])) : r("", !0)
202
226
  ]),
203
- M.value ? (a(), o("div", {
227
+ le.value ? (t(), l("div", {
204
228
  key: 0,
205
- class: l(["vl-attachments-list__item-actions flex items-center shrink-0 ml-2", [t.size !== "lg" ? "gap-0.5" : "gap-0", t.itemActionsClass]]),
206
- onClick: h[0] || (h[0] = j(() => {
229
+ class: n(["vl-attachments-list__item-actions flex items-center shrink-0 ml-2", [L.value !== "lg" ? "gap-0.5" : "gap-0", se.value]]),
230
+ onClick: _[0] || (_[0] = G(() => {
207
231
  }, ["stop"]))
208
232
  }, [
209
- t.variant === "inline" ? (a(), o(v, { key: 0 }, [
210
- z.value ? (a(), u(x, {
233
+ w.value === "inline" ? (t(), l(x, { key: 0 }, [
234
+ S.value ? (t(), u(C, {
211
235
  key: 0,
212
- title: e.fileName || i(w)("common.words.preview", "Preview"),
236
+ title: e.fileName || c(v)("common.words.preview", "Preview"),
213
237
  "max-width": "max-w-3xl",
214
- body: i(b),
215
- bodyProps: { url: e.fileUrl, name: e.fileName, canDownload: t.canDownload }
238
+ body: c(k),
239
+ bodyProps: { url: e.fileUrl, name: e.fileName, canDownload: h.value }
216
240
  }, {
217
- trigger: T(() => [
218
- d("button", {
241
+ trigger: j(() => [
242
+ B("button", {
219
243
  type: "button",
220
- class: l(["inline-flex items-center justify-center rounded opacity-60 hover:opacity-100 bg-transparent! transition-all", r.value.actions]),
221
- "aria-label": i(w)("common.words.preview", "Preview")
244
+ class: n(["inline-flex items-center justify-center rounded opacity-60 hover:opacity-100 bg-transparent! transition-all", m.value.actions]),
245
+ "aria-label": c(v)("common.words.preview", "Preview")
222
246
  }, [
223
- p(P, {
247
+ I(D, {
224
248
  icon: "lucide:eye",
225
- class: l(r.value.actionIcon)
249
+ class: n(m.value.actionIcon)
226
250
  }, null, 8, ["class"])
227
- ], 10, X)
251
+ ], 10, ge)
228
252
  ]),
229
253
  _: 1
230
- }, 8, ["title", "body", "bodyProps"])) : m("", !0),
231
- B.value ? (a(), o("button", {
254
+ }, 8, ["title", "body", "bodyProps"])) : r("", !0),
255
+ T.value ? (t(), l("button", {
232
256
  key: 1,
233
257
  type: "button",
234
- class: l(["inline-flex items-center justify-center rounded opacity-60 hover:opacity-100 bg-transparent! transition-all", r.value.actions]),
235
- "aria-label": i(w)("common.words.download", "Download"),
236
- onClick: (C) => D(e)
258
+ class: n(["inline-flex items-center justify-center rounded opacity-60 hover:opacity-100 bg-transparent! transition-all", m.value.actions]),
259
+ "aria-label": c(v)("common.words.download", "Download"),
260
+ onClick: (P) => U(e)
237
261
  }, [
238
- p(P, {
262
+ I(D, {
239
263
  icon: "lucide:download",
240
- class: l(r.value.actionIcon)
264
+ class: n(m.value.actionIcon)
241
265
  }, null, 8, ["class"])
242
- ], 10, Y)) : m("", !0)
243
- ], 64)) : (a(), o(v, { key: 1 }, [
244
- z.value ? (a(), u(x, {
266
+ ], 10, fe)) : r("", !0)
267
+ ], 64)) : (t(), l(x, { key: 1 }, [
268
+ S.value ? (t(), u(C, {
245
269
  key: 0,
246
- title: e.fileName || i(w)("common.words.preview", "Preview"),
270
+ title: e.fileName || c(v)("common.words.preview", "Preview"),
247
271
  "max-width": "max-w-3xl",
248
- body: i(b),
249
- bodyProps: { url: e.fileUrl, name: e.fileName, canDownload: t.canDownload }
272
+ body: c(k),
273
+ bodyProps: { url: e.fileUrl, name: e.fileName, canDownload: h.value }
250
274
  }, {
251
- trigger: T(() => [
252
- p(N, {
275
+ trigger: j(() => [
276
+ I(A, {
253
277
  variant: "ghost",
254
278
  size: "xs",
255
- class: l([r.value.actions, "px-0"]),
279
+ class: n([m.value.actions, "px-0"]),
256
280
  icon: "lucide:eye"
257
281
  }, null, 8, ["class"])
258
282
  ]),
259
283
  _: 1
260
- }, 8, ["title", "body", "bodyProps"])) : m("", !0),
261
- B.value ? (a(), u(N, {
284
+ }, 8, ["title", "body", "bodyProps"])) : r("", !0),
285
+ T.value ? (t(), u(A, {
262
286
  key: 1,
263
287
  variant: "ghost",
264
288
  size: "xs",
265
- class: l([r.value.actions, "px-0"]),
289
+ class: n([m.value.actions, "px-0"]),
266
290
  icon: "lucide:download",
267
- onClick: (C) => D(e)
268
- }, null, 8, ["class", "onClick"])) : m("", !0)
291
+ onClick: (P) => U(e)
292
+ }, null, 8, ["class", "onClick"])) : r("", !0)
269
293
  ], 64))
270
- ], 2)) : m("", !0)
271
- ], 10, H))), 128)),
272
- t.clickToPreview && t.canView ? (a(!0), o(v, { key: 0 }, U(k.value, (e, s) => (a(), u(x, {
273
- key: `preview-${s}`,
274
- show: g.value === s,
275
- title: e.fileName || i(w)("common.words.preview", "Preview"),
294
+ ], 2)) : r("", !0)
295
+ ], 10, pe))), 128)),
296
+ y.value && p.value ? (t(!0), l(x, { key: 0 }, $(z.value, (e, d) => (t(), u(C, {
297
+ key: `preview-${d}`,
298
+ show: N.value === d,
299
+ title: e.fileName || c(v)("common.words.preview", "Preview"),
276
300
  "max-width": "max-w-3xl",
277
- body: i(b),
278
- bodyProps: { url: e.fileUrl, name: e.fileName, canDownload: t.canDownload },
279
- onClose: $
280
- }, null, 8, ["show", "title", "body", "bodyProps"]))), 128)) : m("", !0)
301
+ body: c(k),
302
+ bodyProps: { url: e.fileUrl, name: e.fileName, canDownload: h.value },
303
+ onClose: E
304
+ }, null, 8, ["show", "title", "body", "bodyProps"]))), 128)) : r("", !0)
281
305
  ], 2))
282
- ], 64)) : (a(), o("div", {
306
+ ], 64)) : (t(), l("div", {
283
307
  key: 1,
284
- class: l(["vl-attachments-list__empty text-sm text-muted-foreground italic bg-muted/10 p-4 rounded-lg border border-dashed border-border text-center", t.emptyClass])
285
- }, y(i(w)("common.words.noAttachments", "No attachments found.")), 3))
308
+ class: n(["vl-attachments-list__empty text-sm text-muted-foreground italic bg-muted/10 p-4 rounded-lg border border-dashed border-border text-center", oe.value])
309
+ }, b(c(v)("common.words.noAttachments", "No attachments found.")), 3))
286
310
  ], 2));
287
311
  }
288
312
  });
289
313
  export {
290
- ie as default
314
+ De as default
291
315
  };
@@ -0,0 +1,24 @@
1
+ import { AvatarSize, AvatarRounded } from '../../types';
2
+ export interface AvatarGroupItem {
3
+ src?: string;
4
+ alt?: string;
5
+ fallback?: string;
6
+ heading?: string;
7
+ text?: string;
8
+ }
9
+ export interface Props {
10
+ items: AvatarGroupItem[];
11
+ max?: number;
12
+ size?: AvatarSize;
13
+ rounded?: AvatarRounded;
14
+ overlap?: 'sm' | 'md' | 'lg';
15
+ class?: string;
16
+ }
17
+ declare const _default: import('vue').DefineComponent<Props, {}, {}, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<Props> & Readonly<{}>, {
18
+ class: string;
19
+ size: AvatarSize;
20
+ rounded: AvatarRounded;
21
+ max: number;
22
+ overlap: "sm" | "md" | "lg";
23
+ }, {}, {}, {}, string, import('vue').ComponentProvideOptions, false, {}, HTMLDivElement>;
24
+ export default _default;