vlite3 1.0.8 → 1.0.10

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 (57) hide show
  1. package/components/Accordion/Accordion.vue.d.ts +1 -1
  2. package/components/Chat/ChatBubble.vue.js +22 -22
  3. package/components/Chat/ChatInterface.vue.js +35 -34
  4. package/components/ColorPicker/ColorIro.vue3.js +2 -2
  5. package/components/ColorPicker/ColorPicker.vue.js +2 -2
  6. package/components/CommandPalette/CommandPaletteContent.vue2.js +1 -1
  7. package/components/CommandPalette/{CommandPaletteItem.vue.js → CommandPaletteItem.vue2.js} +1 -1
  8. package/components/FilePicker/FilePicker.vue.js +133 -140
  9. package/components/Form/Form.vue.d.ts +2 -0
  10. package/components/Form/Form.vue.js +2 -2
  11. package/components/Form/Form.vue2.js +288 -234
  12. package/components/Form/FormField.vue.js +281 -226
  13. package/components/Form/FormFields.vue.d.ts +8 -0
  14. package/components/Form/FormFields.vue.js +1 -1
  15. package/components/Form/FormFields.vue2.js +73 -68
  16. package/components/Form/FormSkeleton.vue.d.ts +9 -0
  17. package/components/Form/FormSkeleton.vue.js +50 -0
  18. package/components/Form/FormSkeleton.vue2.js +4 -0
  19. package/components/Form/composables/useForm.js +174 -150
  20. package/components/Form/index.d.ts +1 -0
  21. package/components/Form/types.d.ts +3 -1
  22. package/components/Form/utils/form.utils.d.ts +6 -1
  23. package/components/Form/utils/form.utils.js +73 -61
  24. package/components/List/ListFieldRow.vue.js +144 -173
  25. package/components/List/utils.d.ts +0 -2
  26. package/components/List/utils.js +22 -43
  27. package/components/NavbarCommandPalette.vue.js +1 -1
  28. package/components/NumberInput.vue.js +1 -1
  29. package/components/NumberInput.vue2.js +87 -81
  30. package/components/Screen/ScreenFilter.vue.js +18 -17
  31. package/components/SidePanel.vue.js +2 -2
  32. package/components/SidePanel.vue2.js +1 -1
  33. package/components/SidebarMenu/SidebarMenu.vue.d.ts +1 -1
  34. package/components/Slider.vue.js +54 -54
  35. package/components/Stats/StatItem.vue.d.ts +25 -0
  36. package/components/Stats/StatItem.vue.js +251 -0
  37. package/components/Stats/StatItem.vue2.js +4 -0
  38. package/components/Stats/Stats.vue.d.ts +3 -3
  39. package/components/Stats/Stats.vue.js +32 -351
  40. package/components/Stats/components/StatIconBox.vue.d.ts +13 -0
  41. package/components/Stats/components/StatIconBox.vue.js +82 -0
  42. package/components/Stats/components/StatIconBox.vue2.js +4 -0
  43. package/components/Stats/components/StatTrend.vue.d.ts +7 -0
  44. package/components/Stats/components/StatTrend.vue.js +48 -0
  45. package/components/Stats/components/StatTrend.vue2.js +4 -0
  46. package/components/StatusChip/status-map.js +36 -0
  47. package/components/ThumbnailSelector/ThumbnailSelector.vue.d.ts +35 -0
  48. package/components/ThumbnailSelector/ThumbnailSelector.vue.js +7 -0
  49. package/components/ThumbnailSelector/ThumbnailSelector.vue2.js +158 -0
  50. package/components/ThumbnailSelector/index.d.ts +2 -0
  51. package/index.d.ts +1 -0
  52. package/index.js +284 -265
  53. package/package.json +1 -1
  54. package/style.css +6 -6
  55. package/utils/functions.d.ts +59 -1
  56. package/utils/functions.js +157 -81
  57. /package/components/ColorPicker/{ColorIro.vue2.js → ColorIro.vue.js} +0 -0
@@ -29,8 +29,8 @@ declare const __VLS_component: import('vue').DefineComponent<AccordionProps, {},
29
29
  variant: import('./types').AccordionVariant;
30
30
  size: import('./types').AccordionSize;
31
31
  disabled: boolean;
32
- items: import('./types').AccordionItemSchema[];
33
32
  attached: boolean;
33
+ items: import('./types').AccordionItemSchema[];
34
34
  showIndex: boolean;
35
35
  iconVariant: import('./types').IconVariant;
36
36
  allowMultiple: boolean;
@@ -1,4 +1,4 @@
1
- import { defineComponent as S, computed as x, ref as T, openBlock as t, createElementBlock as i, normalizeClass as l, createVNode as f, createCommentVNode as a, createElementVNode as d, toDisplayString as u, unref as B, createBlock as E, withModifiers as C } from "vue";
1
+ import { defineComponent as S, computed as x, ref as T, openBlock as t, createElementBlock as a, normalizeClass as l, createVNode as f, createCommentVNode as i, createElementVNode as d, toDisplayString as u, unref as B, createBlock as E, withModifiers as C } from "vue";
2
2
  import D from "../Avatar.vue.js";
3
3
  import g from "../Button.vue.js";
4
4
  import I from "../AttachmentsList/AttachmentsList.vue.js";
@@ -53,16 +53,16 @@ const z = {
53
53
  }, k = () => {
54
54
  n.value = !1, r && (clearTimeout(r), r = null);
55
55
  };
56
- return (m, o) => (t(), i("div", {
56
+ return (m, o) => (t(), a("div", {
57
57
  class: l(["flex w-full min-w-0 gap-3 group", e.isSender ? "flex-row-reverse" : "flex-row"])
58
58
  }, [
59
- e.showAvatar ? (t(), i("div", z, [
59
+ e.showAvatar ? (t(), a("div", z, [
60
60
  f(D, {
61
61
  src: e.message.avatar,
62
62
  alt: e.message.senderName,
63
63
  size: "sm"
64
64
  }, null, 8, ["src", "alt"])
65
- ])) : a("", !0),
65
+ ])) : i("", !0),
66
66
  d("div", {
67
67
  class: l(["flex flex-col min-w-0 overflow-hidden max-w-[85%]", e.isSender ? "items-end" : "items-start"])
68
68
  }, [
@@ -74,9 +74,9 @@ const z = {
74
74
  e.isSender ? "bg-primary text-primary-foreground rounded-br-sm" : "bg-muted text-foreground rounded-bl-sm"
75
75
  ]])
76
76
  }, [
77
- e.showUserInfo && e.message.senderName && !e.isSender ? (t(), i("div", A, u(e.message.senderName), 1)) : a("", !0),
78
- e.message.text ? (t(), i("p", N, u(e.message.text), 1)) : a("", !0),
79
- e.message.attachments && e.message.attachments.length > 0 ? (t(), i("div", {
77
+ e.showUserInfo && e.message.senderName && !e.isSender ? (t(), a("div", A, u(e.message.senderName), 1)) : i("", !0),
78
+ e.message.text ? (t(), a("p", N, u(e.message.text), 1)) : i("", !0),
79
+ e.message.attachments && e.message.attachments.length > 0 ? (t(), a("div", {
80
80
  key: 2,
81
81
  class: l({ "mt-2": e.message.text || e.showUserInfo && !e.isSender })
82
82
  }, [
@@ -89,27 +89,27 @@ const z = {
89
89
  "click-to-preview": !0,
90
90
  "show-download-in-list": !1
91
91
  }, null, 8, ["attachments"])
92
- ], 2)) : a("", !0),
93
- e.showTimestamp && (e.message.timestamp || e.message.isEdited) ? (t(), i("div", {
92
+ ], 2)) : i("", !0),
93
+ e.showTimestamp && (e.message.timestamp || e.message.isEdited) ? (t(), a("div", {
94
94
  key: 3,
95
95
  class: l(["mt-1 flex items-center gap-1", e.isSender ? "justify-end" : "justify-start"])
96
96
  }, [
97
- e.message.isEdited && e.showEditedStatus !== !1 ? (t(), i("span", {
97
+ e.message.isEdited && e.showEditedStatus !== !1 ? (t(), a("span", {
98
98
  key: 0,
99
99
  class: l(["text-[10px] opacity-60", e.isSender ? "text-primary-foreground" : "text-muted-foreground"])
100
- }, u(y.value), 3)) : a("", !0),
101
- e.message.isEdited && e.showEditedStatus !== !1 && e.message.timestamp ? (t(), i("span", {
100
+ }, u(y.value), 3)) : i("", !0),
101
+ e.message.isEdited && e.showEditedStatus !== !1 && e.message.timestamp ? (t(), a("span", {
102
102
  key: 1,
103
103
  class: l(["text-[10px] opacity-40", e.isSender ? "text-primary-foreground" : "text-muted-foreground"])
104
- }, " · ", 2)) : a("", !0),
105
- e.message.timestamp ? (t(), i("span", {
104
+ }, " · ", 2)) : i("", !0),
105
+ e.message.timestamp ? (t(), a("span", {
106
106
  key: 2,
107
107
  class: l(["text-[10px] opacity-60 tabular-nums", e.isSender ? "text-primary-foreground" : "text-muted-foreground"])
108
- }, u(h.value), 3)) : a("", !0)
109
- ], 2)) : a("", !0)
108
+ }, u(h.value), 3)) : i("", !0)
109
+ ], 2)) : i("", !0)
110
110
  ], 2),
111
111
  d("div", {
112
- class: l(["opacity-0 group-hover/bubble:opacity-100 focus-within:opacity-100 transition-opacity flex gap-0 pointer-events-none group-hover/bubble:pointer-events-auto focus-within:pointer-events-auto z-10", e.isSender ? "right-full pr-1" : "left-full pl-1"])
112
+ class: l(["absolute top-1/2 -translate-y-1/2 opacity-0 group-hover/bubble:opacity-100 focus-within:opacity-100 transition-opacity flex gap-0 pointer-events-none group-hover/bubble:pointer-events-auto focus-within:pointer-events-auto z-10", e.isSender ? "right-full pr-1" : "left-full pl-1"])
113
113
  }, [
114
114
  (e.isSender || e.allowEditAll) && e.message.text?.trim() ? (t(), E(g, {
115
115
  key: 0,
@@ -120,8 +120,8 @@ const z = {
120
120
  class: "text-muted-foreground hover:text-foreground h-7 w-7",
121
121
  onClick: o[0] || (o[0] = ($) => c("edit", e.message)),
122
122
  "aria-label": "Edit message"
123
- })) : a("", !0),
124
- e.isSender || e.allowDeleteAll ? (t(), i("div", j, [
123
+ })) : i("", !0),
124
+ e.isSender || e.allowDeleteAll ? (t(), a("div", j, [
125
125
  f(g, {
126
126
  variant: "ghost",
127
127
  size: "xs",
@@ -131,7 +131,7 @@ const z = {
131
131
  onClick: b,
132
132
  "aria-label": n.value ? "Confirm delete" : "Delete message"
133
133
  }, null, 8, ["icon", "aria-label"]),
134
- n.value ? (t(), i("button", {
134
+ n.value ? (t(), a("button", {
135
135
  key: 0,
136
136
  class: "absolute -top-1.5 -right-1.5 w-3.5 h-3.5 rounded-full bg-muted border border-border flex items-center justify-center text-muted-foreground hover:text-foreground transition-colors",
137
137
  onClick: C(k, ["stop"]),
@@ -160,8 +160,8 @@ const z = {
160
160
  y2: "18"
161
161
  })
162
162
  ], -1)
163
- ])])) : a("", !0)
164
- ])) : a("", !0)
163
+ ])])) : i("", !0)
164
+ ])) : i("", !0)
165
165
  ], 2)
166
166
  ], 2)
167
167
  ], 2)
@@ -1,4 +1,4 @@
1
- import { defineComponent as te, ref as p, computed as w, onMounted as le, onUnmounted as ae, watch as oe, nextTick as U, openBlock as c, createElementBlock as f, createElementVNode as o, createTextVNode as se, toDisplayString as b, createCommentVNode as k, Fragment as _, renderList as N, createBlock as re, createVNode as I, unref as E, withCtx as ne, withDirectives as ie, vModelText as de } from "vue";
1
+ import { defineComponent as te, ref as p, computed as w, onMounted as le, onUnmounted as ae, watch as oe, nextTick as U, openBlock as c, createElementBlock as f, createElementVNode as o, createTextVNode as re, toDisplayString as b, createCommentVNode as k, Fragment as _, renderList as N, createBlock as se, createVNode as I, unref as E, withCtx as ne, withDirectives as ie, vModelText as de } from "vue";
2
2
  import ce from "./ChatBubble.vue.js";
3
3
  import V from "../Button.vue.js";
4
4
  import K from "../Icon.vue.js";
@@ -10,8 +10,8 @@ const me = { class: "flex flex-col w-full h-full flex-1 min-h-0 bg-transparent"
10
10
  class: "py-2 mb-2 text-center text-xs text-muted-foreground flex justify-center items-center gap-2"
11
11
  }, he = {
12
12
  key: 1,
13
- class: "flex items-center justify-center h-full text-muted-foreground text-sm"
14
- }, xe = { class: "flex flex-col gap-2 pb-2" }, ge = {
13
+ class: "flex items-center justify-center flex-1 h-full text-muted-foreground text-sm"
14
+ }, xe = { class: "flex flex-col gap-2 pb-2 mt-auto" }, ge = {
15
15
  key: 0,
16
16
  class: "flex items-center gap-3 py-1 select-none",
17
17
  role: "separator"
@@ -54,8 +54,8 @@ const me = { class: "flex flex-col w-full h-full flex-1 min-h-0 bg-transparent"
54
54
  maxFileSize: {}
55
55
  },
56
56
  emits: ["add", "delete", "edit", "refetch"],
57
- setup(s, { emit: j }) {
58
- const a = s, C = j, v = p(null), B = p(null), i = p(null), h = p(""), F = p(0), M = p(!1), d = p(null), r = p([]), { handleUploadFiles: Y, loading: x } = fe(), P = w(() => {
57
+ setup(r, { emit: j }) {
58
+ const a = r, C = j, v = p(null), B = p(null), i = p(null), h = p(""), F = p(0), M = p(!1), d = p(null), s = p([]), { handleUploadFiles: Y, loading: x } = fe(), P = w(() => {
59
59
  if (a.placeholderI18n) {
60
60
  const t = u(a.placeholderI18n);
61
61
  if (t !== a.placeholderI18n) return t;
@@ -139,22 +139,22 @@ const me = { class: "flex flex-col w-full h-full flex-1 min-h-0 bg-transparent"
139
139
  }, z = () => {
140
140
  d.value = null, h.value = "", i.value && (i.value.style.height = "auto", i.value.focus());
141
141
  }, $ = w(() => {
142
- const e = !!h.value.trim(), t = Array.isArray(r.value) && r.value.length > 0;
142
+ const e = !!h.value.trim(), t = Array.isArray(s.value) && s.value.length > 0;
143
143
  return (e || t) && !x.value;
144
144
  }), X = (e) => {
145
- x.value || Array.isArray(r.value) && (r.value.splice(e, 1), r.value.length === 0 && (r.value = []));
145
+ x.value || Array.isArray(s.value) && (s.value.splice(e, 1), s.value.length === 0 && (s.value = []));
146
146
  }, L = async () => {
147
147
  if (!$.value) return;
148
- const e = h.value.trim(), t = Array.isArray(r.value) && r.value.length > 0, l = !!d.value;
148
+ const e = h.value.trim(), t = Array.isArray(s.value) && s.value.length > 0, l = !!d.value;
149
149
  if (l && d.value)
150
150
  e !== d.value.text && C("edit", { ...d.value, text: e, isEdited: !0 }), d.value = null, h.value = "";
151
151
  else {
152
152
  let n = [];
153
153
  if (t) {
154
- const m = r.value.map((T) => T.file).filter(Boolean);
154
+ const m = s.value.map((T) => T.file).filter(Boolean);
155
155
  if (m.length > 0) {
156
156
  const T = await Y(m, a.folderId);
157
- n = r.value.map((g, y) => ({
157
+ n = s.value.map((g, y) => ({
158
158
  fileUrl: T[y] || "",
159
159
  fileName: g.fileName,
160
160
  fileType: g.fileType,
@@ -162,7 +162,7 @@ const me = { class: "flex flex-col w-full h-full flex-1 min-h-0 bg-transparent"
162
162
  })).filter((g) => g.fileUrl !== null && g.fileUrl !== "");
163
163
  }
164
164
  }
165
- C("add", e, n.length > 0 ? n : void 0), r.value = [], h.value = "";
165
+ C("add", e, n.length > 0 ? n : void 0), s.value = [], h.value = "";
166
166
  }
167
167
  i.value && (i.value.style.height = "auto", i.value.focus()), l || A();
168
168
  }, D = (e) => {
@@ -204,18 +204,19 @@ const me = { class: "flex flex-col w-full h-full flex-1 min-h-0 bg-transparent"
204
204
  o("div", {
205
205
  ref_key: "messageListRef",
206
206
  ref: v,
207
- class: "flex-1 overflow-y-auto px-4 py-4 scrollbar-thin scrollbar-stable",
207
+ class: "flex-1 overflow-y-auto px-4 py-4 scrollbar-thin scrollbar-stable flex flex-col",
208
208
  role: "log",
209
209
  "aria-live": "polite",
210
210
  "aria-label": "Chat messages",
211
- style: { "will-change": "transform", contain: "layout style" }
211
+ style: { "will-change": "transform", contain: "layout style", "overflow-anchor": "auto" }
212
212
  }, [
213
213
  o("div", {
214
214
  ref_key: "observerTargetRef",
215
215
  ref: B,
216
- class: "h-1 w-full shrink-0"
216
+ class: "h-1 w-full shrink-0",
217
+ style: { "overflow-anchor": "none" }
217
218
  }, null, 512),
218
- s.isLoadingMore ? (c(), f("div", ve, [
219
+ r.isLoadingMore ? (c(), f("div", ve, [
219
220
  t[3] || (t[3] = o("svg", {
220
221
  class: "animate-spin h-4 w-4 text-primary",
221
222
  xmlns: "http://www.w3.org/2000/svg",
@@ -236,9 +237,9 @@ const me = { class: "flex flex-col w-full h-full flex-1 min-h-0 bg-transparent"
236
237
  d: "M4 12a8 8 0 018-8V0C5.373 0 0 5.373 0 12h4zm2 5.291A7.962 7.962 0 014 12H0c0 3.042 1.135 5.824 3 7.938l3-2.647z"
237
238
  })
238
239
  ], -1)),
239
- se(" " + b(O.value), 1)
240
+ re(" " + b(O.value), 1)
240
241
  ])) : k("", !0),
241
- !s.data.length && !s.isLoadingMore ? (c(), f("div", he, b(q.value), 1)) : k("", !0),
242
+ !r.data.length && !r.isLoadingMore ? (c(), f("div", he, b(q.value), 1)) : k("", !0),
242
243
  o("div", xe, [
243
244
  (c(!0), f(_, null, N(ee.value, (l) => (c(), f(_, {
244
245
  key: H(l) ? l._key : l.id
@@ -247,19 +248,19 @@ const me = { class: "flex flex-col w-full h-full flex-1 min-h-0 bg-transparent"
247
248
  t[4] || (t[4] = o("div", { class: "flex-1 h-px bg-border/60" }, null, -1)),
248
249
  o("span", pe, b(l.label), 1),
249
250
  t[5] || (t[5] = o("div", { class: "flex-1 h-px bg-border/60" }, null, -1))
250
- ])) : (c(), re(ce, {
251
+ ])) : (c(), se(ce, {
251
252
  key: 1,
252
253
  message: l,
253
- "is-sender": l.senderId === s.currentUserId,
254
- "show-avatar": s.showAvatar,
255
- "show-user-info": s.showUserInfo,
256
- "show-timestamp": s.showTimestamp,
257
- "allow-delete-all": s.allowDeleteAll,
258
- "allow-edit-all": s.allowEditAll,
259
- "confirm-delete": s.confirmDelete,
260
- "show-edited-status": s.showEditedStatus,
261
- "edited-text": s.editedText,
262
- "edited-text-i18n": s.editedTextI18n,
254
+ "is-sender": l.senderId === r.currentUserId,
255
+ "show-avatar": r.showAvatar,
256
+ "show-user-info": r.showUserInfo,
257
+ "show-timestamp": r.showTimestamp,
258
+ "allow-delete-all": r.allowDeleteAll,
259
+ "allow-edit-all": r.allowEditAll,
260
+ "confirm-delete": r.confirmDelete,
261
+ "show-edited-status": r.showEditedStatus,
262
+ "edited-text": r.editedText,
263
+ "edited-text-i18n": r.editedTextI18n,
263
264
  onDelete: t[0] || (t[0] = (n) => e.$emit("delete", n)),
264
265
  onEdit: W
265
266
  }, null, 8, ["message", "is-sender", "show-avatar", "show-user-info", "show-timestamp", "allow-delete-all", "allow-edit-all", "confirm-delete", "show-edited-status", "edited-text", "edited-text-i18n"]))
@@ -317,8 +318,8 @@ const me = { class: "flex flex-col w-full h-full flex-1 min-h-0 bg-transparent"
317
318
  ])
318
319
  ])) : k("", !0),
319
320
  o("div", Ee, [
320
- Array.isArray(r.value) && r.value.length > 0 ? (c(), f("div", Me, [
321
- (c(!0), f(_, null, N(r.value, (l, n) => (c(), f("div", {
321
+ Array.isArray(s.value) && s.value.length > 0 ? (c(), f("div", Me, [
322
+ (c(!0), f(_, null, N(s.value, (l, n) => (c(), f("div", {
322
323
  key: n,
323
324
  class: "relative flex items-center gap-2 bg-background border border-border rounded-md p-1.5 pr-8 max-w-[200px] shadow-sm"
324
325
  }, [
@@ -343,12 +344,12 @@ const me = { class: "flex flex-col w-full h-full flex-1 min-h-0 bg-transparent"
343
344
  ]))), 128))
344
345
  ])) : k("", !0),
345
346
  o("div", Ce, [
346
- s.allowFileUpload ? (c(), f("div", Be, [
347
+ r.allowFileUpload ? (c(), f("div", Be, [
347
348
  I(ue, {
348
- modelValue: r.value,
349
- "onUpdate:modelValue": t[1] || (t[1] = (l) => r.value = l),
349
+ modelValue: s.value,
350
+ "onUpdate:modelValue": t[1] || (t[1] = (l) => s.value = l),
350
351
  "multi-select": !0,
351
- "max-size": s.maxFileSize,
352
+ "max-size": r.maxFileSize,
352
353
  "return-format": "file"
353
354
  }, {
354
355
  trigger: ne(({ trigger: l }) => [
@@ -1,5 +1,5 @@
1
- import o from "./ColorIro.vue2.js";
2
- /* empty css */
1
+ import o from "./ColorIro.vue.js";
2
+ /* empty css */
3
3
  export {
4
4
  o as default
5
5
  };
@@ -6,8 +6,8 @@ import O from "../Input.vue.js";
6
6
  import "../../core/config.js";
7
7
  /* empty css */
8
8
  import y from "../Button.vue.js";
9
- import E from "./ColorIro.vue2.js";
10
- /* empty css */
9
+ import E from "./ColorIro.vue.js";
10
+ /* empty css */
11
11
  import { useEyeDropper as P } from "@vueuse/core";
12
12
  const I = {
13
13
  key: 0,
@@ -4,7 +4,7 @@ import k from "../Icon.vue.js";
4
4
  import { $t as E } from "../../utils/i18n.js";
5
5
  import { useCommandPaletteItems as Y } from "./useCommandPaletteItems.js";
6
6
  import { useCommandPaletteNav as Z } from "./useCommandPaletteNav.js";
7
- import ee from "./CommandPaletteItem.vue.js";
7
+ import ee from "./CommandPaletteItem.vue2.js";
8
8
  const te = { class: "command-palette-content flex flex-col w-full h-full max-h-[70vh]" }, oe = { class: "flex items-center gap-3 px-4 py-3 border-b border-border/60 shrink-0" }, se = ["placeholder"], ne = ["aria-label"], re = {
9
9
  key: 0,
10
10
  class: "flex flex-col items-center justify-center py-14 px-6 text-center select-none",
@@ -1,5 +1,5 @@
1
1
  import t from "./CommandPaletteItem.vue3.js";
2
- /* empty css */
2
+ /* empty css */
3
3
  import o from "../../_virtual/_plugin-vue_export-helper.js";
4
4
  const r = /* @__PURE__ */ o(t, [["__scopeId", "data-v-66b1ae06"]]);
5
5
  export {