vlite3 1.4.20 → 1.4.21
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/CategoryManager/CategoryManager.vue2.js +1 -1
- package/components/ColorPicker/ColorIro.vue3.js +2 -2
- package/components/ColorPicker/ColorPicker.vue.js +2 -2
- package/components/CommandPalette/CommandPaletteContent.vue2.js +1 -1
- package/components/CommandPalette/{CommandPaletteItem.vue.js → CommandPaletteItem.vue2.js} +1 -1
- package/components/Dropdown/DropdownMenu.vue.js +1 -1
- package/components/Form/FormField.vue.js +91 -91
- package/components/NavbarCommandPalette.vue.js +1 -1
- package/components/Screen/ScreenFilter.vue.js +1 -1
- package/package.json +1 -1
- /package/components/ColorPicker/{ColorIro.vue2.js → ColorIro.vue.js} +0 -0
- /package/components/Dropdown/{DropdownMenu.vue2.js → DropdownMenu.vue3.js} +0 -0
|
@@ -7,8 +7,8 @@ import "../../core/config.js";
|
|
|
7
7
|
/* empty css */
|
|
8
8
|
/* empty css */
|
|
9
9
|
import E from "../Button.vue.js";
|
|
10
|
-
import _ from "./ColorIro.
|
|
11
|
-
/* empty css
|
|
10
|
+
import _ from "./ColorIro.vue.js";
|
|
11
|
+
/* empty css */
|
|
12
12
|
import { useEyeDropper as I } from "@vueuse/core";
|
|
13
13
|
const N = { class: "absolute left-2.5 top-1/2 -translate-y-1/2 flex items-center justify-center z-20 pointer-events-none" }, j = {
|
|
14
14
|
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.
|
|
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/80 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,27 +1,27 @@
|
|
|
1
|
-
import { defineComponent as E, computed as
|
|
2
|
-
import { resolveFieldType as
|
|
3
|
-
import
|
|
1
|
+
import { defineComponent as E, computed as f, markRaw as O, openBlock as c, createBlock as m, mergeProps as p, toHandlers as C, createSlots as M, unref as P, withCtx as u, createVNode as L, createTextVNode as y, toDisplayString as x, createCommentVNode as N, resolveDynamicComponent as q } from "vue";
|
|
2
|
+
import { resolveFieldType as G, isComponent as k, isAddonObject as B } from "./utils/form.utils.js";
|
|
3
|
+
import J from "../NumberInput.vue.js";
|
|
4
4
|
import z from "../Button.vue.js";
|
|
5
|
-
import { $t as
|
|
5
|
+
import { $t as K } from "../../utils/i18n.js";
|
|
6
6
|
import V from "../Input.vue.js";
|
|
7
7
|
/* empty css */
|
|
8
|
-
import
|
|
9
|
-
import
|
|
10
|
-
import
|
|
11
|
-
import
|
|
12
|
-
import
|
|
13
|
-
import
|
|
14
|
-
import
|
|
15
|
-
import
|
|
16
|
-
import
|
|
17
|
-
import
|
|
18
|
-
import
|
|
19
|
-
import
|
|
20
|
-
import
|
|
21
|
-
import
|
|
22
|
-
import
|
|
8
|
+
import Q from "../Switch.vue.js";
|
|
9
|
+
import W from "../CheckBox.vue.js";
|
|
10
|
+
import X from "../FilePicker/index.vue.js";
|
|
11
|
+
import Y from "../AvatarUploader/AvatarUploader.vue.js";
|
|
12
|
+
import Z from "../ThumbnailSelector/ThumbnailSelector.vue.js";
|
|
13
|
+
import _ from "../TagInput/TagInput.vue.js";
|
|
14
|
+
import R from "../Dropdown/Dropdown.vue.js";
|
|
15
|
+
import ee from "../MultiSelect/MultiSelect.vue.js";
|
|
16
|
+
import ae from "../DatePicker.vue.js";
|
|
17
|
+
import le from "../DateRangePicker.vue.js";
|
|
18
|
+
import ie from "../ColorPicker/ColorPicker.vue.js";
|
|
19
|
+
import te from "../IconPicker.vue.js";
|
|
20
|
+
import re from "./index.vue.js";
|
|
21
|
+
import ne from "../ChoiceBox/ChoiceBox.vue.js";
|
|
22
|
+
import de from "../RichTextEditor/RichTextEditor.vue.js";
|
|
23
23
|
/* empty css */
|
|
24
|
-
const
|
|
24
|
+
const Ne = /* @__PURE__ */ E({
|
|
25
25
|
__name: "FormField",
|
|
26
26
|
props: {
|
|
27
27
|
field: {},
|
|
@@ -45,16 +45,16 @@ const Be = /* @__PURE__ */ E({
|
|
|
45
45
|
v("change", { value: a, data: l });
|
|
46
46
|
}, S = (a) => {
|
|
47
47
|
v("change", { value: a });
|
|
48
|
-
},
|
|
48
|
+
}, o = f(() => G(e.field, {
|
|
49
49
|
values: e.values,
|
|
50
50
|
globalValues: e.values,
|
|
51
51
|
isUpdate: e.isUpdate
|
|
52
|
-
})),
|
|
53
|
-
() =>
|
|
54
|
-
), U =
|
|
55
|
-
const a =
|
|
56
|
-
if (
|
|
57
|
-
return
|
|
52
|
+
})), b = f(
|
|
53
|
+
() => o.value === "number" && e.field.isSensitiveField === !0
|
|
54
|
+
), U = f(() => {
|
|
55
|
+
const a = o.value;
|
|
56
|
+
if (k(a))
|
|
57
|
+
return O(a);
|
|
58
58
|
switch (a) {
|
|
59
59
|
case "text":
|
|
60
60
|
case "email":
|
|
@@ -65,57 +65,57 @@ const Be = /* @__PURE__ */ E({
|
|
|
65
65
|
case "textarea":
|
|
66
66
|
return V;
|
|
67
67
|
case "number":
|
|
68
|
-
return
|
|
68
|
+
return b.value ? V : J;
|
|
69
69
|
case "switch":
|
|
70
|
-
return
|
|
70
|
+
return Q;
|
|
71
71
|
case "check":
|
|
72
|
-
return
|
|
72
|
+
return W;
|
|
73
73
|
case "select":
|
|
74
|
-
return
|
|
74
|
+
return R;
|
|
75
75
|
case "multiSelect":
|
|
76
|
-
return
|
|
76
|
+
return ee;
|
|
77
77
|
case "choiceBox":
|
|
78
|
-
return
|
|
78
|
+
return ne;
|
|
79
79
|
case "date":
|
|
80
80
|
case "time":
|
|
81
|
-
return
|
|
81
|
+
return ae;
|
|
82
82
|
case "dateRangePicker":
|
|
83
|
-
return
|
|
83
|
+
return le;
|
|
84
84
|
case "file":
|
|
85
85
|
case "fileUploader":
|
|
86
|
-
return
|
|
86
|
+
return X;
|
|
87
87
|
case "avatarUpload":
|
|
88
|
-
return
|
|
88
|
+
return Y;
|
|
89
89
|
case "color":
|
|
90
|
-
return
|
|
90
|
+
return ie;
|
|
91
91
|
case "iconPicker":
|
|
92
|
-
return
|
|
92
|
+
return te;
|
|
93
93
|
case "customFields":
|
|
94
|
-
return
|
|
94
|
+
return re;
|
|
95
95
|
case "thumbnailSelector":
|
|
96
|
-
return
|
|
96
|
+
return Z;
|
|
97
97
|
case "tags":
|
|
98
|
-
return
|
|
98
|
+
return _;
|
|
99
99
|
case "richTextEditor":
|
|
100
|
-
return
|
|
100
|
+
return de;
|
|
101
101
|
default:
|
|
102
102
|
return V;
|
|
103
103
|
}
|
|
104
|
-
}),
|
|
105
|
-
const a =
|
|
104
|
+
}), w = f(() => {
|
|
105
|
+
const a = o.value, { disabled: l, readonly: r, ...g } = e.field, t = {
|
|
106
106
|
...g,
|
|
107
107
|
disabled: e.disabled || l === !0,
|
|
108
108
|
readonly: e.readonly || r === !0,
|
|
109
109
|
...e.field.props || {},
|
|
110
110
|
label: "",
|
|
111
111
|
labelI18n: ""
|
|
112
|
-
}, h = e.field.placeholderI18n ?
|
|
112
|
+
}, h = e.field.placeholderI18n ? K(e.field.placeholderI18n) : e.field.placeholder, I = e.variant === "floating" && e.label && !e.floatingActive, s = I ? "" : h;
|
|
113
113
|
if (a === "text" || a === "email" || a === "password" || a === "tel" || a === "url" || a === "search" || a === "textarea" || !a)
|
|
114
114
|
return {
|
|
115
115
|
...t,
|
|
116
116
|
modelValue: e.value ?? "",
|
|
117
117
|
type: a || "text",
|
|
118
|
-
placeholder:
|
|
118
|
+
placeholder: s,
|
|
119
119
|
label: e.label,
|
|
120
120
|
icon: e.field.icon,
|
|
121
121
|
iconRight: e.field.iconRight,
|
|
@@ -131,14 +131,14 @@ const Be = /* @__PURE__ */ E({
|
|
|
131
131
|
rows: a === "textarea" ? e.field.props?.rows || 3 : void 0,
|
|
132
132
|
class: `${e.field.className || ""}`
|
|
133
133
|
};
|
|
134
|
-
if (a === "number" &&
|
|
134
|
+
if (a === "number" && b.value)
|
|
135
135
|
return {
|
|
136
136
|
...t,
|
|
137
137
|
// Convert numeric value to string so Input.vue (string-based) displays it correctly
|
|
138
138
|
modelValue: e.value !== void 0 && e.value !== null ? String(e.value) : "",
|
|
139
139
|
// 'password' activates the eye-toggle inside Input.vue
|
|
140
140
|
type: "password",
|
|
141
|
-
placeholder:
|
|
141
|
+
placeholder: s,
|
|
142
142
|
label: e.label,
|
|
143
143
|
variant: e.variant,
|
|
144
144
|
size: e.size,
|
|
@@ -159,15 +159,15 @@ const Be = /* @__PURE__ */ E({
|
|
|
159
159
|
mode: e.field.props?.mode ?? (e.variant === "transparent" ? "ghost" : "outline"),
|
|
160
160
|
size: e.size,
|
|
161
161
|
rounded: e.rounded,
|
|
162
|
-
placeholder:
|
|
162
|
+
placeholder: s,
|
|
163
163
|
class: e.field.className
|
|
164
164
|
};
|
|
165
165
|
if (a === "switch") {
|
|
166
166
|
const {
|
|
167
167
|
variant: n,
|
|
168
|
-
rounded:
|
|
169
|
-
error:
|
|
170
|
-
switchVariant:
|
|
168
|
+
rounded: oe,
|
|
169
|
+
error: se,
|
|
170
|
+
switchVariant: ue,
|
|
171
171
|
...D
|
|
172
172
|
} = t;
|
|
173
173
|
return {
|
|
@@ -194,7 +194,7 @@ const Be = /* @__PURE__ */ E({
|
|
|
194
194
|
...t,
|
|
195
195
|
modelValue: e.value,
|
|
196
196
|
options: e.field.options || [],
|
|
197
|
-
placeholder:
|
|
197
|
+
placeholder: s,
|
|
198
198
|
selectable: !0,
|
|
199
199
|
closeOnSelect: !0,
|
|
200
200
|
triggerProps: {
|
|
@@ -243,7 +243,7 @@ const Be = /* @__PURE__ */ E({
|
|
|
243
243
|
...t,
|
|
244
244
|
modelValue: e.value,
|
|
245
245
|
mode: a === "time" ? "time" : "date",
|
|
246
|
-
placeholder:
|
|
246
|
+
placeholder: s,
|
|
247
247
|
btnProps: {
|
|
248
248
|
variant: e.variant === "floating" ? "outline-floating" : e.variant || "outline",
|
|
249
249
|
size: e.size,
|
|
@@ -267,7 +267,7 @@ const Be = /* @__PURE__ */ E({
|
|
|
267
267
|
fileTypes: e.field.props?.accept ? e.field.props.accept.split(",") : [],
|
|
268
268
|
returnFormat: "base64",
|
|
269
269
|
variant: e.field.props?.variant ?? (a === "file" ? "input" : "dropzone"),
|
|
270
|
-
placeholder:
|
|
270
|
+
placeholder: s,
|
|
271
271
|
size: e.size,
|
|
272
272
|
rounded: e.rounded,
|
|
273
273
|
maxSize: e.field.maxFileSize ? e.field.maxFileSize * 1024 * 1024 : void 0,
|
|
@@ -287,7 +287,7 @@ const Be = /* @__PURE__ */ E({
|
|
|
287
287
|
return {
|
|
288
288
|
...t,
|
|
289
289
|
modelValue: Array.isArray(e.value) ? e.value : [],
|
|
290
|
-
placeholder:
|
|
290
|
+
placeholder: s,
|
|
291
291
|
variant: e.variant,
|
|
292
292
|
size: e.size,
|
|
293
293
|
rounded: e.rounded,
|
|
@@ -298,7 +298,7 @@ const Be = /* @__PURE__ */ E({
|
|
|
298
298
|
return {
|
|
299
299
|
...t,
|
|
300
300
|
modelValue: e.value ?? "",
|
|
301
|
-
placeholder:
|
|
301
|
+
placeholder: s,
|
|
302
302
|
label: void 0,
|
|
303
303
|
error: e.error,
|
|
304
304
|
minHeight: e.field.props?.minHeight || "140px",
|
|
@@ -348,16 +348,16 @@ const Be = /* @__PURE__ */ E({
|
|
|
348
348
|
label: e.field.label
|
|
349
349
|
};
|
|
350
350
|
}
|
|
351
|
-
return
|
|
351
|
+
return k(a) ? {
|
|
352
352
|
...t,
|
|
353
353
|
value: e.field.props?.multiple && (e.value === null || e.value === void 0) ? [] : e.value,
|
|
354
354
|
values: e.values
|
|
355
355
|
} : t;
|
|
356
|
-
}), $ =
|
|
357
|
-
const a =
|
|
356
|
+
}), $ = f(() => {
|
|
357
|
+
const a = o.value;
|
|
358
358
|
return a === "text" || a === "email" || a === "password" || a === "tel" || a === "url" || a === "search" || a === "textarea" || a === "switch" || a === "check" || !a ? {
|
|
359
359
|
"update:modelValue": S
|
|
360
|
-
} : a === "number" &&
|
|
360
|
+
} : a === "number" && b.value ? {
|
|
361
361
|
"update:modelValue": (l) => {
|
|
362
362
|
const r = l === "" ? void 0 : Number(l);
|
|
363
363
|
v("change", { value: isNaN(r) ? void 0 : r });
|
|
@@ -417,37 +417,37 @@ const Be = /* @__PURE__ */ E({
|
|
|
417
417
|
const r = e.value && typeof e.value == "object" ? e.value : { images: [], thumbnail: null };
|
|
418
418
|
d({ ...r, thumbnail: l });
|
|
419
419
|
}
|
|
420
|
-
} :
|
|
420
|
+
} : k(a) ? {
|
|
421
421
|
onChange: (l) => {
|
|
422
422
|
d(l.value, l.data);
|
|
423
423
|
}
|
|
424
424
|
} : {};
|
|
425
|
-
}),
|
|
426
|
-
const a =
|
|
425
|
+
}), H = f(() => {
|
|
426
|
+
const a = o.value;
|
|
427
427
|
return a === "text" || a === "email" || a === "password" || a === "tel" || a === "url" || a === "search" || !a;
|
|
428
|
-
}),
|
|
428
|
+
}), j = f(() => H.value || o.value === "textarea" || b.value), A = (a, l) => {
|
|
429
429
|
v("addonChange", a.name, { value: l.value });
|
|
430
|
-
},
|
|
430
|
+
}, F = (a) => {
|
|
431
431
|
a.action && v("addonAction", a.action);
|
|
432
432
|
};
|
|
433
|
-
return (a, l) =>
|
|
434
|
-
...
|
|
433
|
+
return (a, l) => j.value ? (c(), m(V, p({ key: 0 }, {
|
|
434
|
+
...w.value,
|
|
435
435
|
...i.field?.props || {}
|
|
436
|
-
},
|
|
437
|
-
P(
|
|
436
|
+
}, C($.value)), M({ _: 2 }, [
|
|
437
|
+
P(B)(i.field.addonLeft) ? {
|
|
438
438
|
name: "addon-left",
|
|
439
439
|
fn: u(() => [
|
|
440
|
-
i.field.addonLeft.type === "select" ? (c(), m(
|
|
440
|
+
i.field.addonLeft.type === "select" ? (c(), m(R, p({
|
|
441
441
|
key: 0,
|
|
442
442
|
modelValue: i.field.addonLeft.name ? i.values[i.field.addonLeft.name] : void 0,
|
|
443
443
|
options: i.field.addonLeft.options || []
|
|
444
444
|
}, i.field.addonLeft.props || {}, {
|
|
445
|
-
onOnSelect: l[0] || (l[0] = (r) =>
|
|
445
|
+
onOnSelect: l[0] || (l[0] = (r) => A(i.field.addonLeft, r))
|
|
446
446
|
}), {
|
|
447
447
|
trigger: u(({ selectedLabel: r }) => [
|
|
448
|
-
|
|
448
|
+
L(z, { variant: "outline" }, {
|
|
449
449
|
default: u(() => [
|
|
450
|
-
|
|
450
|
+
y(x(r), 1)
|
|
451
451
|
]),
|
|
452
452
|
_: 2
|
|
453
453
|
}, 1024)
|
|
@@ -457,30 +457,30 @@ const Be = /* @__PURE__ */ E({
|
|
|
457
457
|
key: 1,
|
|
458
458
|
variant: "outline"
|
|
459
459
|
}, i.field.addonLeft.props || {}, {
|
|
460
|
-
onClick: l[1] || (l[1] = (r) =>
|
|
460
|
+
onClick: l[1] || (l[1] = (r) => F(i.field.addonLeft))
|
|
461
461
|
}), {
|
|
462
462
|
default: u(() => [
|
|
463
|
-
|
|
463
|
+
y(x(i.field.addonLeft.text), 1)
|
|
464
464
|
]),
|
|
465
465
|
_: 1
|
|
466
|
-
}, 16)) :
|
|
466
|
+
}, 16)) : N("", !0)
|
|
467
467
|
]),
|
|
468
468
|
key: "0"
|
|
469
469
|
} : void 0,
|
|
470
|
-
P(
|
|
470
|
+
P(B)(i.field.addonRight) ? {
|
|
471
471
|
name: "addon-right",
|
|
472
472
|
fn: u(() => [
|
|
473
|
-
i.field.addonRight.type === "select" ? (c(), m(
|
|
473
|
+
i.field.addonRight.type === "select" ? (c(), m(R, p({
|
|
474
474
|
key: 0,
|
|
475
475
|
modelValue: i.field.addonRight.name ? i.values[i.field.addonRight.name] : void 0,
|
|
476
476
|
options: i.field.addonRight.options || []
|
|
477
477
|
}, i.field.addonRight.props || {}, {
|
|
478
|
-
onOnSelect: l[2] || (l[2] = (r) =>
|
|
478
|
+
onOnSelect: l[2] || (l[2] = (r) => A(i.field.addonRight, r))
|
|
479
479
|
}), {
|
|
480
480
|
trigger: u(({ selectedLabel: r }) => [
|
|
481
|
-
|
|
481
|
+
L(z, { variant: "outline" }, {
|
|
482
482
|
default: u(() => [
|
|
483
|
-
|
|
483
|
+
y(x(r), 1)
|
|
484
484
|
]),
|
|
485
485
|
_: 2
|
|
486
486
|
}, 1024)
|
|
@@ -490,25 +490,25 @@ const Be = /* @__PURE__ */ E({
|
|
|
490
490
|
key: 1,
|
|
491
491
|
variant: "outline"
|
|
492
492
|
}, i.field.addonRight.props || {}, {
|
|
493
|
-
onClick: l[3] || (l[3] = (r) =>
|
|
493
|
+
onClick: l[3] || (l[3] = (r) => F(i.field.addonRight))
|
|
494
494
|
}), {
|
|
495
495
|
default: u(() => [
|
|
496
|
-
|
|
496
|
+
y(x(i.field.addonRight.text), 1)
|
|
497
497
|
]),
|
|
498
498
|
_: 1
|
|
499
|
-
}, 16)) :
|
|
499
|
+
}, 16)) : N("", !0)
|
|
500
500
|
]),
|
|
501
501
|
key: "1"
|
|
502
502
|
} : void 0
|
|
503
|
-
]), 1040)) : (c(), m(
|
|
503
|
+
]), 1040)) : (c(), m(q(U.value), p({
|
|
504
504
|
key: 1,
|
|
505
|
-
class:
|
|
505
|
+
class: o.value === "check" || o.value === "switch" && i.field.props?.switchVariant === "basic" ? "" : "w-full"
|
|
506
506
|
}, {
|
|
507
|
-
...
|
|
507
|
+
...w.value,
|
|
508
508
|
...i.field?.props || {}
|
|
509
|
-
},
|
|
509
|
+
}, C($.value)), null, 16, ["class"]));
|
|
510
510
|
}
|
|
511
511
|
});
|
|
512
512
|
export {
|
|
513
|
-
|
|
513
|
+
Ne as default
|
|
514
514
|
};
|
|
@@ -3,7 +3,7 @@ import L from "./Icon.vue.js";
|
|
|
3
3
|
import v from "./Modal.vue.js";
|
|
4
4
|
import N from "./CommandPalette/CommandPaletteContent.vue.js";
|
|
5
5
|
import { $t as U } from "../utils/i18n.js";
|
|
6
|
-
/* empty css
|
|
6
|
+
/* empty css */
|
|
7
7
|
const V = { class: "block truncate -text-fs-1.5" }, S = { class: "ml-auto inline-flex items-center gap-0.5 px-1.5 py-0.5 rounded text-[10px] font-mono font-medium border border-border/80 bg-background text-muted-foreground ml-1" }, A = /* @__PURE__ */ x({
|
|
8
8
|
__name: "NavbarCommandPalette",
|
|
9
9
|
props: {
|
package/package.json
CHANGED
|
File without changes
|
|
File without changes
|