vlite3 1.3.11 → 1.4.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/components/Accordion/Accordion.vue.d.ts +2 -2
- package/components/Accordion/AccordionItem.vue.d.ts +1 -1
- package/components/Accordion/AccordionItem.vue.js +11 -7
- package/components/Accordion/AccordionTrigger.vue.d.ts +1 -1
- package/components/AppShell/AppShell.vue.d.ts +1 -0
- package/components/AppShell/AppShell.vue.js +33 -26
- package/components/AppShell/AppShellLayoutStorefront.vue.d.ts +54 -0
- package/components/AppShell/AppShellLayoutStorefront.vue.js +222 -0
- package/components/AppShell/AppShellLayoutStorefront.vue2.js +4 -0
- package/components/AsyncSelect/createAsyncSelect.js +3 -2
- package/components/CategoryManager/CategoryManager.vue2.js +36 -31
- package/components/CategoryMenu/CategoryMenu.vue.d.ts +22 -0
- package/components/CategoryMenu/CategoryMenu.vue.js +106 -0
- package/components/CategoryMenu/CategoryMenu.vue2.js +4 -0
- package/components/CategoryMenu/CategoryMenuVariant1.vue.d.ts +17 -0
- package/components/CategoryMenu/CategoryMenuVariant1.vue.js +146 -0
- package/components/CategoryMenu/CategoryMenuVariant1.vue2.js +4 -0
- package/components/CategoryMenu/CategoryMenuVariant2.vue.d.ts +18 -0
- package/components/CategoryMenu/CategoryMenuVariant2.vue.js +162 -0
- package/components/CategoryMenu/CategoryMenuVariant2.vue2.js +4 -0
- package/components/CategoryMenu/index.d.ts +2 -0
- package/components/CategoryMenu/types.d.ts +32 -0
- package/components/CategoryMenu/utils.d.ts +16 -0
- package/components/CategoryMenu/utils.js +45 -0
- package/components/ColorPicker/ColorPicker.vue.d.ts +7 -3
- package/components/ColorPicker/ColorPicker.vue.js +59 -45
- package/components/DatePicker.vue.js +5 -4
- package/components/DateRangePicker.vue.js +3 -2
- package/components/Dropdown/Dropdown.vue.d.ts +4 -1
- package/components/Dropdown/Dropdown.vue.js +8 -7
- package/components/Dropdown/DropdownGroupedLayout.vue2.js +5 -2
- package/components/Dropdown/DropdownGroupedLayout.vue3.js +111 -0
- package/components/Dropdown/DropdownItem.vue.d.ts +2 -2
- package/components/Dropdown/DropdownItem.vue.js +66 -49
- package/components/Dropdown/DropdownMenu.vue.js +1 -1
- package/components/Dropdown/{DropdownMenu.vue2.js → DropdownMenu.vue3.js} +40 -40
- package/components/Dropdown/composables/useDropdownHydration.d.ts +4 -0
- package/components/Dropdown/composables/useDropdownNavigation.js +30 -18
- package/components/Form/Form.vue.d.ts +13 -1
- package/components/Form/Form.vue.js +2 -2
- package/components/Form/Form.vue2.js +313 -275
- package/components/Form/FormField.vue.js +103 -74
- package/components/Form/FormFields.vue.js +2 -2
- package/components/Form/FormFields.vue2.js +7 -6
- package/components/Form/composables/useForm.js +71 -67
- package/components/Form/types.d.ts +21 -1
- package/components/IconPicker.vue.js +3 -2
- package/components/ImportData/ImportStep2.vue.js +3 -2
- package/components/MultiSelect/composables/useMultiSelectHydration.d.ts +4 -0
- package/components/NavbarCommandPalette.vue.d.ts +1 -1
- package/components/PermissionMatrix/PermissionTopBar.vue.js +3 -2
- package/components/RichTextEditor/RichTextEditor.vue.js +43 -48
- package/components/RichTextEditor/RichTextLinkPopover.vue3.js +2 -2
- package/components/RichTextEditor/RichTextToolbar.vue.d.ts +12 -3
- package/components/RichTextEditor/{RichTextToolbar.vue.js → RichTextToolbar.vue2.js} +157 -121
- package/components/RichTextEditor/RichTextToolbar.vue3.js +2 -2
- package/components/RichTextEditor/index.d.ts +2 -0
- package/components/RichTextEditor/types.d.ts +38 -0
- package/components/RichTextEditor/types.js +52 -0
- package/components/Screen/ScreenFilter.vue.js +26 -21
- package/components/SidebarMenu/SidebarMenu.vue.d.ts +2 -2
- package/components/SidebarMenu/SidebarMenuItem.vue.js +3 -2
- package/components/Switch.vue.js +8 -8
- package/components/Tooltip.vue.js +1 -0
- package/components/Workbook/Sheet.vue.d.ts +1 -1
- package/components/Workbook/Sheet.vue.js +14 -13
- package/components/index.d.ts +1 -0
- package/index.d.ts +1 -0
- package/index.js +306 -301
- package/package.json +2 -2
- package/style.css +2 -2
- package/types/appshell.type.d.ts +2 -1
- package/types/styles.d.ts +2 -0
- package/components/Dropdown/DropdownGroupedLayout.vue.js +0 -75
- /package/components/RichTextEditor/{RichTextLinkPopover.vue.js → RichTextLinkPopover.vue2.js} +0 -0
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { defineComponent as
|
|
1
|
+
import { defineComponent as E, computed as s, markRaw as M, openBlock as c, createBlock as m, mergeProps as p, toHandlers as L, createSlots as q, unref as P, withCtx as u, createVNode as N, createTextVNode as b, toDisplayString as y, createCommentVNode as B, resolveDynamicComponent as G } from "vue";
|
|
2
2
|
import { resolveFieldType as J, isComponent as R, isAddonObject as x } from "./utils/form.utils.js";
|
|
3
3
|
import K from "../NumberInput.vue.js";
|
|
4
4
|
import z from "../Button.vue.js";
|
|
@@ -16,10 +16,12 @@ import ae from "../MultiSelect/MultiSelect.vue.js";
|
|
|
16
16
|
import le from "../DatePicker.vue.js";
|
|
17
17
|
import ie from "../DateRangePicker.vue.js";
|
|
18
18
|
import te from "../ColorPicker/ColorPicker.vue.js";
|
|
19
|
-
import
|
|
20
|
-
import
|
|
19
|
+
import re from "../IconPicker.vue.js";
|
|
20
|
+
import ne from "./CustomFields.vue.js";
|
|
21
21
|
import de from "../ChoiceBox/ChoiceBox.vue.js";
|
|
22
|
-
|
|
22
|
+
import oe from "../RichTextEditor/RichTextEditor.vue.js";
|
|
23
|
+
/* empty css */
|
|
24
|
+
const Be = /* @__PURE__ */ E({
|
|
23
25
|
__name: "FormField",
|
|
24
26
|
props: {
|
|
25
27
|
field: {},
|
|
@@ -38,19 +40,19 @@ const Le = /* @__PURE__ */ H({
|
|
|
38
40
|
loading: { type: Boolean, default: !1 }
|
|
39
41
|
},
|
|
40
42
|
emits: ["change", "addonChange", "addonAction"],
|
|
41
|
-
setup(i, { emit:
|
|
42
|
-
const e = i, v =
|
|
43
|
+
setup(i, { emit: T }) {
|
|
44
|
+
const e = i, v = T, d = (a, l) => {
|
|
43
45
|
v("change", { value: a, data: l });
|
|
44
46
|
}, S = (a) => {
|
|
45
47
|
v("change", { value: a });
|
|
46
|
-
},
|
|
48
|
+
}, f = s(() => J(e.field, {
|
|
47
49
|
values: e.values,
|
|
48
50
|
globalValues: e.values,
|
|
49
51
|
isUpdate: e.isUpdate
|
|
50
|
-
})), k =
|
|
51
|
-
() =>
|
|
52
|
-
),
|
|
53
|
-
const a =
|
|
52
|
+
})), k = s(
|
|
53
|
+
() => f.value === "number" && e.field.isSensitiveField === !0
|
|
54
|
+
), U = s(() => {
|
|
55
|
+
const a = f.value;
|
|
54
56
|
if (R(a))
|
|
55
57
|
return M(a);
|
|
56
58
|
switch (a) {
|
|
@@ -87,31 +89,33 @@ const Le = /* @__PURE__ */ H({
|
|
|
87
89
|
case "color":
|
|
88
90
|
return te;
|
|
89
91
|
case "iconPicker":
|
|
90
|
-
return ne;
|
|
91
|
-
case "customFields":
|
|
92
92
|
return re;
|
|
93
|
+
case "customFields":
|
|
94
|
+
return ne;
|
|
93
95
|
case "thumbnailSelector":
|
|
94
96
|
return _;
|
|
95
97
|
case "tags":
|
|
96
98
|
return ee;
|
|
99
|
+
case "richTextEditor":
|
|
100
|
+
return oe;
|
|
97
101
|
default:
|
|
98
102
|
return V;
|
|
99
103
|
}
|
|
100
|
-
}), A =
|
|
101
|
-
const a =
|
|
104
|
+
}), A = s(() => {
|
|
105
|
+
const a = f.value, { disabled: l, readonly: r, ...g } = e.field, t = {
|
|
102
106
|
...g,
|
|
103
107
|
disabled: e.disabled || l === !0,
|
|
104
|
-
readonly: e.readonly ||
|
|
108
|
+
readonly: e.readonly || r === !0,
|
|
105
109
|
...e.field.props || {},
|
|
106
110
|
label: "",
|
|
107
111
|
labelI18n: ""
|
|
108
|
-
}, h = e.field.placeholderI18n ? Q(e.field.placeholderI18n) : e.field.placeholder, I = e.variant === "floating" && e.label && !e.floatingActive,
|
|
112
|
+
}, h = e.field.placeholderI18n ? Q(e.field.placeholderI18n) : e.field.placeholder, I = e.variant === "floating" && e.label && !e.floatingActive, o = I ? "" : h;
|
|
109
113
|
if (a === "text" || a === "email" || a === "password" || a === "tel" || a === "url" || a === "search" || a === "textarea" || !a)
|
|
110
114
|
return {
|
|
111
115
|
...t,
|
|
112
116
|
modelValue: e.value ?? "",
|
|
113
117
|
type: a || "text",
|
|
114
|
-
placeholder:
|
|
118
|
+
placeholder: o,
|
|
115
119
|
label: e.label,
|
|
116
120
|
icon: e.field.icon,
|
|
117
121
|
iconRight: e.field.iconRight,
|
|
@@ -134,7 +138,7 @@ const Le = /* @__PURE__ */ H({
|
|
|
134
138
|
modelValue: e.value !== void 0 && e.value !== null ? String(e.value) : "",
|
|
135
139
|
// 'password' activates the eye-toggle inside Input.vue
|
|
136
140
|
type: "password",
|
|
137
|
-
placeholder:
|
|
141
|
+
placeholder: o,
|
|
138
142
|
label: e.label,
|
|
139
143
|
variant: e.variant,
|
|
140
144
|
size: e.size,
|
|
@@ -155,13 +159,19 @@ const Le = /* @__PURE__ */ H({
|
|
|
155
159
|
mode: e.field.props?.mode ?? (e.variant === "transparent" ? "ghost" : "outline"),
|
|
156
160
|
size: e.size,
|
|
157
161
|
rounded: e.rounded,
|
|
158
|
-
placeholder:
|
|
162
|
+
placeholder: o,
|
|
159
163
|
class: e.field.className
|
|
160
164
|
};
|
|
161
165
|
if (a === "switch") {
|
|
162
|
-
const {
|
|
166
|
+
const {
|
|
167
|
+
variant: n,
|
|
168
|
+
rounded: se,
|
|
169
|
+
error: ue,
|
|
170
|
+
switchVariant: fe,
|
|
171
|
+
...D
|
|
172
|
+
} = t;
|
|
163
173
|
return {
|
|
164
|
-
...
|
|
174
|
+
...D,
|
|
165
175
|
modelValue: !!e.value,
|
|
166
176
|
label: e.field.label,
|
|
167
177
|
labelI18n: e.field.labelI18n,
|
|
@@ -184,7 +194,7 @@ const Le = /* @__PURE__ */ H({
|
|
|
184
194
|
...t,
|
|
185
195
|
modelValue: e.value,
|
|
186
196
|
options: e.field.options || [],
|
|
187
|
-
placeholder:
|
|
197
|
+
placeholder: o,
|
|
188
198
|
selectable: !0,
|
|
189
199
|
closeOnSelect: !0,
|
|
190
200
|
triggerProps: {
|
|
@@ -211,17 +221,17 @@ const Le = /* @__PURE__ */ H({
|
|
|
211
221
|
titleI18n: e.field.labelI18n,
|
|
212
222
|
description: e.field.props?.description,
|
|
213
223
|
descriptionI18n: e.field.props?.descriptionI18n,
|
|
214
|
-
options: (e.field.options || []).map((
|
|
215
|
-
id:
|
|
216
|
-
title:
|
|
217
|
-
titleI18n:
|
|
218
|
-
description:
|
|
219
|
-
descriptionI18n:
|
|
220
|
-
icon:
|
|
221
|
-
disabled:
|
|
222
|
-
badge:
|
|
223
|
-
badgeI18n:
|
|
224
|
-
data:
|
|
224
|
+
options: (e.field.options || []).map((n) => ({
|
|
225
|
+
id: n.value ?? n.label,
|
|
226
|
+
title: n.label,
|
|
227
|
+
titleI18n: n.labelI18n,
|
|
228
|
+
description: n.description || n.subtitle,
|
|
229
|
+
descriptionI18n: n.descriptionI18n || n.subtitleI18n,
|
|
230
|
+
icon: n.icon,
|
|
231
|
+
disabled: n.disabled,
|
|
232
|
+
badge: n.badge || n.data?.badge,
|
|
233
|
+
badgeI18n: n.badgeI18n || n.data?.badgeI18n,
|
|
234
|
+
data: n.data
|
|
225
235
|
})),
|
|
226
236
|
multiple: e.field.props?.multiple || !1,
|
|
227
237
|
grid: e.field.props?.grid || 1,
|
|
@@ -233,7 +243,7 @@ const Le = /* @__PURE__ */ H({
|
|
|
233
243
|
...t,
|
|
234
244
|
modelValue: e.value,
|
|
235
245
|
mode: a === "time" ? "time" : "date",
|
|
236
|
-
placeholder:
|
|
246
|
+
placeholder: o,
|
|
237
247
|
btnProps: {
|
|
238
248
|
variant: e.variant === "floating" ? "outline-floating" : e.variant || "outline",
|
|
239
249
|
size: e.size,
|
|
@@ -257,7 +267,7 @@ const Le = /* @__PURE__ */ H({
|
|
|
257
267
|
fileTypes: e.field.props?.accept ? e.field.props.accept.split(",") : [],
|
|
258
268
|
returnFormat: "base64",
|
|
259
269
|
variant: a === "file" ? "input" : "dropzone",
|
|
260
|
-
placeholder:
|
|
270
|
+
placeholder: o,
|
|
261
271
|
size: e.size,
|
|
262
272
|
rounded: e.rounded,
|
|
263
273
|
maxSize: e.field.maxFileSize ? e.field.maxFileSize * 1024 * 1024 : void 0,
|
|
@@ -277,17 +287,32 @@ const Le = /* @__PURE__ */ H({
|
|
|
277
287
|
return {
|
|
278
288
|
...t,
|
|
279
289
|
modelValue: Array.isArray(e.value) ? e.value : [],
|
|
280
|
-
placeholder:
|
|
290
|
+
placeholder: o,
|
|
281
291
|
variant: e.variant,
|
|
282
292
|
size: e.size,
|
|
283
293
|
rounded: e.rounded,
|
|
284
294
|
maxTags: e.field.props?.maxTags,
|
|
285
295
|
class: e.field.className
|
|
286
296
|
};
|
|
297
|
+
if (a === "richTextEditor")
|
|
298
|
+
return {
|
|
299
|
+
...t,
|
|
300
|
+
modelValue: e.value ?? "",
|
|
301
|
+
placeholder: o,
|
|
302
|
+
label: void 0,
|
|
303
|
+
error: e.error,
|
|
304
|
+
minHeight: e.field.props?.minHeight || "140px",
|
|
305
|
+
maxHeight: e.field.props?.maxHeight || "220px",
|
|
306
|
+
tools: e.field.props?.tools,
|
|
307
|
+
class: e.field.className
|
|
308
|
+
};
|
|
287
309
|
if (a === "color")
|
|
288
310
|
return {
|
|
289
311
|
...t,
|
|
290
|
-
modelValue: e.value || "#000000"
|
|
312
|
+
modelValue: e.value || "#000000",
|
|
313
|
+
variant: e.variant,
|
|
314
|
+
size: e.size,
|
|
315
|
+
rounded: e.rounded
|
|
291
316
|
};
|
|
292
317
|
if (a === "iconPicker")
|
|
293
318
|
return {
|
|
@@ -312,11 +337,11 @@ const Le = /* @__PURE__ */ H({
|
|
|
312
337
|
isUpdate: e.isUpdate
|
|
313
338
|
};
|
|
314
339
|
if (a === "thumbnailSelector") {
|
|
315
|
-
const
|
|
340
|
+
const n = e.value && typeof e.value == "object" ? e.value : { images: [], thumbnail: null };
|
|
316
341
|
return {
|
|
317
342
|
...t,
|
|
318
|
-
images: Array.isArray(
|
|
319
|
-
thumbnail:
|
|
343
|
+
images: Array.isArray(n.images) ? n.images : [],
|
|
344
|
+
thumbnail: n.thumbnail ?? null,
|
|
320
345
|
disabled: e.disabled || l === !0,
|
|
321
346
|
loading: e.loading,
|
|
322
347
|
maxSize: e.field.maxFileSize,
|
|
@@ -328,14 +353,14 @@ const Le = /* @__PURE__ */ H({
|
|
|
328
353
|
value: e.field.props?.multiple && (e.value === null || e.value === void 0) ? [] : e.value,
|
|
329
354
|
values: e.values
|
|
330
355
|
} : t;
|
|
331
|
-
}),
|
|
332
|
-
const a =
|
|
356
|
+
}), $ = s(() => {
|
|
357
|
+
const a = f.value;
|
|
333
358
|
return a === "text" || a === "email" || a === "password" || a === "tel" || a === "url" || a === "search" || a === "textarea" || a === "switch" || a === "check" || !a ? {
|
|
334
359
|
"update:modelValue": S
|
|
335
360
|
} : a === "number" && k.value ? {
|
|
336
361
|
"update:modelValue": (l) => {
|
|
337
|
-
const
|
|
338
|
-
v("change", { value: isNaN(
|
|
362
|
+
const r = l === "" ? void 0 : Number(l);
|
|
363
|
+
v("change", { value: isNaN(r) ? void 0 : r });
|
|
339
364
|
}
|
|
340
365
|
} : a === "number" ? {
|
|
341
366
|
"update:modelValue": S
|
|
@@ -347,9 +372,11 @@ const Le = /* @__PURE__ */ H({
|
|
|
347
372
|
change: (l) => d(l)
|
|
348
373
|
} : a === "choiceBox" ? {
|
|
349
374
|
change: (l) => {
|
|
350
|
-
const
|
|
375
|
+
const r = e.field.props?.multiple;
|
|
351
376
|
let g = null;
|
|
352
|
-
|
|
377
|
+
r && Array.isArray(l) ? g = l.map(
|
|
378
|
+
(t) => e.field.options?.find((h) => (h.value ?? h.label) === t)?.data
|
|
379
|
+
) : g = e.field.options?.find((t) => (t.value ?? t.label) === l)?.data, d(l, g);
|
|
353
380
|
}
|
|
354
381
|
} : a === "date" || a === "time" || a === "dateRangePicker" ? {
|
|
355
382
|
change: (l) => d(l)
|
|
@@ -370,6 +397,8 @@ const Le = /* @__PURE__ */ H({
|
|
|
370
397
|
} : a === "tags" ? {
|
|
371
398
|
"update:modelValue": S,
|
|
372
399
|
change: (l) => d(l)
|
|
400
|
+
} : a === "richTextEditor" ? {
|
|
401
|
+
"update:modelValue": (l) => d(l)
|
|
373
402
|
} : a === "color" ? {
|
|
374
403
|
change: (l) => d(l)
|
|
375
404
|
} : a === "iconPicker" ? {
|
|
@@ -381,44 +410,44 @@ const Le = /* @__PURE__ */ H({
|
|
|
381
410
|
d(l);
|
|
382
411
|
},
|
|
383
412
|
"update:images": (l) => {
|
|
384
|
-
const
|
|
385
|
-
d({ ...
|
|
413
|
+
const r = e.value && typeof e.value == "object" ? e.value : { images: [], thumbnail: null };
|
|
414
|
+
d({ ...r, images: l });
|
|
386
415
|
},
|
|
387
416
|
"update:thumbnail": (l) => {
|
|
388
|
-
const
|
|
389
|
-
d({ ...
|
|
417
|
+
const r = e.value && typeof e.value == "object" ? e.value : { images: [], thumbnail: null };
|
|
418
|
+
d({ ...r, thumbnail: l });
|
|
390
419
|
}
|
|
391
420
|
} : R(a) ? {
|
|
392
421
|
onChange: (l) => {
|
|
393
422
|
d(l.value, l.data);
|
|
394
423
|
}
|
|
395
424
|
} : {};
|
|
396
|
-
}), j =
|
|
397
|
-
const a =
|
|
425
|
+
}), j = s(() => x(e.field.addonLeft) || x(e.field.addonRight)), H = s(() => {
|
|
426
|
+
const a = f.value;
|
|
398
427
|
return a === "text" || a === "email" || a === "password" || a === "tel" || a === "url" || a === "search" || !a;
|
|
399
|
-
}),
|
|
428
|
+
}), O = s(() => j.value && H.value), F = (a, l) => {
|
|
400
429
|
v("addonChange", a.name, { value: l.value });
|
|
401
430
|
}, C = (a) => {
|
|
402
431
|
a.action && v("addonAction", a.action);
|
|
403
432
|
};
|
|
404
|
-
return (a, l) =>
|
|
433
|
+
return (a, l) => O.value ? (c(), m(V, p({ key: 0 }, {
|
|
405
434
|
...A.value,
|
|
406
435
|
...i.field?.props || {}
|
|
407
|
-
}, L(
|
|
436
|
+
}, L($.value)), q({ _: 2 }, [
|
|
408
437
|
P(x)(i.field.addonLeft) ? {
|
|
409
438
|
name: "addon-left",
|
|
410
|
-
fn:
|
|
439
|
+
fn: u(() => [
|
|
411
440
|
i.field.addonLeft.type === "select" ? (c(), m(w, p({
|
|
412
441
|
key: 0,
|
|
413
442
|
modelValue: i.field.addonLeft.name ? i.values[i.field.addonLeft.name] : void 0,
|
|
414
443
|
options: i.field.addonLeft.options || []
|
|
415
444
|
}, i.field.addonLeft.props || {}, {
|
|
416
|
-
onOnSelect: l[0] || (l[0] = (
|
|
445
|
+
onOnSelect: l[0] || (l[0] = (r) => F(i.field.addonLeft, r))
|
|
417
446
|
}), {
|
|
418
|
-
trigger:
|
|
447
|
+
trigger: u(({ selectedLabel: r }) => [
|
|
419
448
|
N(z, { variant: "outline" }, {
|
|
420
|
-
default:
|
|
421
|
-
b(y(
|
|
449
|
+
default: u(() => [
|
|
450
|
+
b(y(r), 1)
|
|
422
451
|
]),
|
|
423
452
|
_: 2
|
|
424
453
|
}, 1024)
|
|
@@ -428,9 +457,9 @@ const Le = /* @__PURE__ */ H({
|
|
|
428
457
|
key: 1,
|
|
429
458
|
variant: "outline"
|
|
430
459
|
}, i.field.addonLeft.props || {}, {
|
|
431
|
-
onClick: l[1] || (l[1] = (
|
|
460
|
+
onClick: l[1] || (l[1] = (r) => C(i.field.addonLeft))
|
|
432
461
|
}), {
|
|
433
|
-
default:
|
|
462
|
+
default: u(() => [
|
|
434
463
|
b(y(i.field.addonLeft.text), 1)
|
|
435
464
|
]),
|
|
436
465
|
_: 1
|
|
@@ -440,18 +469,18 @@ const Le = /* @__PURE__ */ H({
|
|
|
440
469
|
} : void 0,
|
|
441
470
|
P(x)(i.field.addonRight) ? {
|
|
442
471
|
name: "addon-right",
|
|
443
|
-
fn:
|
|
472
|
+
fn: u(() => [
|
|
444
473
|
i.field.addonRight.type === "select" ? (c(), m(w, p({
|
|
445
474
|
key: 0,
|
|
446
475
|
modelValue: i.field.addonRight.name ? i.values[i.field.addonRight.name] : void 0,
|
|
447
476
|
options: i.field.addonRight.options || []
|
|
448
477
|
}, i.field.addonRight.props || {}, {
|
|
449
|
-
onOnSelect: l[2] || (l[2] = (
|
|
478
|
+
onOnSelect: l[2] || (l[2] = (r) => F(i.field.addonRight, r))
|
|
450
479
|
}), {
|
|
451
|
-
trigger:
|
|
480
|
+
trigger: u(({ selectedLabel: r }) => [
|
|
452
481
|
N(z, { variant: "outline" }, {
|
|
453
|
-
default:
|
|
454
|
-
b(y(
|
|
482
|
+
default: u(() => [
|
|
483
|
+
b(y(r), 1)
|
|
455
484
|
]),
|
|
456
485
|
_: 2
|
|
457
486
|
}, 1024)
|
|
@@ -461,9 +490,9 @@ const Le = /* @__PURE__ */ H({
|
|
|
461
490
|
key: 1,
|
|
462
491
|
variant: "outline"
|
|
463
492
|
}, i.field.addonRight.props || {}, {
|
|
464
|
-
onClick: l[3] || (l[3] = (
|
|
493
|
+
onClick: l[3] || (l[3] = (r) => C(i.field.addonRight))
|
|
465
494
|
}), {
|
|
466
|
-
default:
|
|
495
|
+
default: u(() => [
|
|
467
496
|
b(y(i.field.addonRight.text), 1)
|
|
468
497
|
]),
|
|
469
498
|
_: 1
|
|
@@ -471,15 +500,15 @@ const Le = /* @__PURE__ */ H({
|
|
|
471
500
|
]),
|
|
472
501
|
key: "1"
|
|
473
502
|
} : void 0
|
|
474
|
-
]), 1040)) : (c(), m(G(
|
|
503
|
+
]), 1040)) : (c(), m(G(U.value), p({
|
|
475
504
|
key: 1,
|
|
476
|
-
class:
|
|
505
|
+
class: f.value === "check" || f.value === "switch" && i.field.props?.switchVariant === "basic" ? "" : "w-full"
|
|
477
506
|
}, {
|
|
478
507
|
...A.value,
|
|
479
508
|
...i.field?.props || {}
|
|
480
|
-
}, L(
|
|
509
|
+
}, L($.value)), null, 16, ["class"]));
|
|
481
510
|
}
|
|
482
511
|
});
|
|
483
512
|
export {
|
|
484
|
-
|
|
513
|
+
Be as default
|
|
485
514
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./FormFields.vue2.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import r from "../../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const
|
|
4
|
+
const d = /* @__PURE__ */ r(o, [["__scopeId", "data-v-ed7f8d6a"]]);
|
|
5
5
|
export {
|
|
6
|
-
|
|
6
|
+
d as default
|
|
7
7
|
};
|
|
@@ -59,8 +59,8 @@ const se = {
|
|
|
59
59
|
}, L = (t) => {
|
|
60
60
|
const a = F(t), e = s(t);
|
|
61
61
|
let i = a != null && a !== "" && !(Array.isArray(a) && a.length === 0);
|
|
62
|
-
const
|
|
63
|
-
return e === "dateRangePicker" && a && typeof a == "object" && (i = !!(a.startDate || a.endDate || a.start || a.end)), f(t) || e === "number" ? y.value[t.name] || i ||
|
|
62
|
+
const z = typeof a == "number" && !isNaN(a);
|
|
63
|
+
return e === "dateRangePicker" && a && typeof a == "object" && (i = !!(a.startDate || a.endDate || a.start || a.end)), f(t) || e === "number" ? y.value[t.name] || i || z : i || z;
|
|
64
64
|
}, f = (t) => {
|
|
65
65
|
const a = s(t) || "text";
|
|
66
66
|
return ["text", "email", "password", "tel", "url", "search", "textarea"].includes(a);
|
|
@@ -77,9 +77,10 @@ const se = {
|
|
|
77
77
|
"avatarUpload",
|
|
78
78
|
"fileUploader",
|
|
79
79
|
"file",
|
|
80
|
-
"choiceBox"
|
|
80
|
+
"choiceBox",
|
|
81
|
+
"richTextEditor"
|
|
81
82
|
].includes(a);
|
|
82
|
-
},
|
|
83
|
+
}, T = (t) => {
|
|
83
84
|
const a = l(t);
|
|
84
85
|
if (!(!a || v(a)))
|
|
85
86
|
return a;
|
|
@@ -141,7 +142,7 @@ const se = {
|
|
|
141
142
|
onFocusin: (i) => M(e.name),
|
|
142
143
|
onFocusout: (i) => O(e.name)
|
|
143
144
|
}, [
|
|
144
|
-
w(e) &&
|
|
145
|
+
w(e) && T(e) && !f(e) ? (o(), u("label", {
|
|
145
146
|
key: 0,
|
|
146
147
|
for: e.name,
|
|
147
148
|
class: d([
|
|
@@ -163,7 +164,7 @@ const se = {
|
|
|
163
164
|
} : { ...e, props: { ...e.props || {}, id: e.name } },
|
|
164
165
|
value: F(e),
|
|
165
166
|
floatingActive: L(e),
|
|
166
|
-
label: s(e) === "customFields" ? void 0 : w(e) ?
|
|
167
|
+
label: s(e) === "customFields" ? void 0 : w(e) ? T(e) : void 0,
|
|
167
168
|
values: n.values,
|
|
168
169
|
errors: n.errors,
|
|
169
170
|
variant: n.variant,
|