@3squared/forge-ui-3 0.14.0 → 0.16.0
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/dist/esm/forge-ui-3.js +611 -596
- package/dist/esm/style.css +1 -1
- package/dist/src/components/ForgeActionButton.vue.d.ts +4 -4
- package/dist/src/components/ForgeAlert.vue.d.ts +4 -4
- package/dist/src/components/ForgeCheckbox.vue.d.ts +4 -4
- package/dist/src/components/ForgeChips.vue.d.ts +4 -4
- package/dist/src/components/ForgeDatepicker.vue.d.ts +4 -4
- package/dist/src/components/ForgeForm.vue.d.ts +4 -4
- package/dist/src/components/ForgeFormField.vue.d.ts +14 -4
- package/dist/src/components/ForgeInlineEditor.vue.d.ts +4 -4
- package/dist/src/components/ForgeLink.vue.d.ts +1 -1
- package/dist/src/components/ForgeLoader.vue.d.ts +4 -4
- package/dist/src/components/ForgeModal.vue.d.ts +5 -5
- package/dist/src/components/ForgeMultiSelect.vue.d.ts +5 -5
- package/dist/src/components/ForgeMultiSelectPreview.vue.d.ts +4 -4
- package/dist/src/components/ForgeNavbar.vue.d.ts +5 -5
- package/dist/src/components/ForgePageHeader.vue.d.ts +1 -1
- package/dist/src/components/ForgeProgressBar.vue.d.ts +4 -4
- package/dist/src/components/ForgeRemainingCharacters.vue.d.ts +4 -4
- package/dist/src/components/ForgeStatWidget.vue.d.ts +4 -4
- package/dist/src/components/ForgeStepper.vue.d.ts +5 -5
- package/dist/src/components/ForgeTile.vue.d.ts +4 -4
- package/dist/src/components/file-uploader/ForgeFileUploader.vue.d.ts +4 -4
- package/dist/src/components/file-uploader/components/DragDropArea.vue.d.ts +3 -3
- package/dist/src/components/file-uploader/components/FileInfo.vue.d.ts +4 -4
- package/dist/src/components/file-uploader/components/MaxFileSize.vue.d.ts +1 -1
- package/dist/src/components/file-uploader/components/UploadButton.vue.d.ts +3 -3
- package/dist/src/components/file-uploader/components/UploadStatus.vue.d.ts +1 -1
- package/dist/src/components/table/ForgeFilterHeader.vue.d.ts +3 -3
- package/dist/src/components/table/ForgePaginationHeader.vue.d.ts +5 -5
- package/dist/src/components/table/ForgeTable.vue.d.ts +5 -5
- package/dist/src/passthroughs/Button.pt.d.ts +64 -8
- package/dist/src/passthroughs/Column.pt.d.ts +8 -2
- package/dist/src/passthroughs/Dropdown.pt.d.ts +2 -3
- package/package.json +7 -7
- package/src/styles/components/_file-uploader.scss +2 -1
- package/src/styles/utilities/_variables.scss +18 -0
package/dist/esm/forge-ui-3.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import be from "primevue/message";
|
|
2
|
-
import { defineComponent as F, openBlock as i, createBlock as w, normalizeProps as Q, guardReactiveProps as ee, withCtx as g, createElementVNode as c, normalizeClass as B, unref as m, createCommentVNode as S, createVNode as f, renderSlot as $, ref as I, createElementBlock as v, Fragment as L, mergeProps as _, mergeModels as E, useModel as A, computed as
|
|
2
|
+
import { defineComponent as F, openBlock as i, createBlock as w, normalizeProps as Q, guardReactiveProps as ee, withCtx as g, createElementVNode as c, normalizeClass as B, unref as m, createCommentVNode as S, createVNode as f, renderSlot as $, ref as I, createElementBlock as v, Fragment as L, mergeProps as _, mergeModels as E, useModel as A, computed as k, createTextVNode as O, toDisplayString as h, withDirectives as j, vShow as H, createSlots as te, renderList as Y, onMounted as ne, isRef as se, withKeys as J, useAttrs as fe, withModifiers as q, normalizeStyle as ge, watch as de } from "vue";
|
|
3
3
|
import { Icon as V } from "@iconify/vue";
|
|
4
4
|
import R from "primevue/button";
|
|
5
5
|
import he from "primevue/toast";
|
|
@@ -12,14 +12,14 @@ import { vOnClickOutside as $e } from "@vueuse/components";
|
|
|
12
12
|
import Be from "primevue/menubar";
|
|
13
13
|
import Fe from "vue-multiselect";
|
|
14
14
|
import _e from "primevue/calendar";
|
|
15
|
-
import
|
|
15
|
+
import le from "primevue/dropdown";
|
|
16
16
|
import Se from "primevue/inputmask";
|
|
17
17
|
import Ve from "primevue/textarea";
|
|
18
18
|
import ue from "primevue/inputnumber";
|
|
19
19
|
import Ce from "primevue/chips";
|
|
20
20
|
import Te from "primevue/progressbar";
|
|
21
|
-
import
|
|
22
|
-
import
|
|
21
|
+
import Pe from "primevue/divider";
|
|
22
|
+
import Me from "primevue/steps";
|
|
23
23
|
import Ie from "primevue/datatable";
|
|
24
24
|
import ze from "primevue/multiselect";
|
|
25
25
|
import { BlockBlobClient as ce } from "@azure/storage-blob";
|
|
@@ -33,47 +33,54 @@ const De = {
|
|
|
33
33
|
{
|
|
34
34
|
"btn-brand": e.severity === "brand" && !e.outlined && !e.link && !e.text,
|
|
35
35
|
"btn-outline-brand": e.severity === "brand" && e.outlined,
|
|
36
|
-
"text-brand fw-bold btn-text-brand": e.severity === "brand" && e.text
|
|
36
|
+
"text-brand fw-bold btn-text-brand": e.severity === "brand" && e.text,
|
|
37
|
+
"link-brand text-decoration-underline link-underline-brand": e.severity === "brand" && e.link
|
|
37
38
|
},
|
|
38
39
|
// Primary
|
|
39
40
|
{
|
|
40
41
|
"btn-primary": (e.severity === null || e.severity === "primary") && !e.outlined && !e.link && !e.text,
|
|
41
42
|
"btn-outline-primary": (e.severity === null || e.severity === "primary") && e.outlined,
|
|
42
|
-
"text-primary fw-bold btn-text-primary": (e.severity === null || e.severity === "primary") && e.text
|
|
43
|
+
"text-primary fw-bold btn-text-primary": (e.severity === null || e.severity === "primary") && e.text,
|
|
44
|
+
"link-primary text-decoration-underline link-underline-primary": (e.severity === null || e.severity === "primary") && e.link
|
|
43
45
|
},
|
|
44
46
|
// Secondary
|
|
45
47
|
{
|
|
46
48
|
"btn-secondary": e.severity === "secondary" && !e.outlined && !e.link && !e.text,
|
|
47
49
|
"btn-outline-secondary": e.severity === "secondary" && e.outlined,
|
|
48
|
-
"text-secondary fw-bold btn-text-secondary": e.severity === "secondary" && e.text
|
|
50
|
+
"text-secondary fw-bold btn-text-secondary": e.severity === "secondary" && e.text,
|
|
51
|
+
"link-secondary text-decoration-underline link-underline-secondary": e.severity === "secondary" && e.link
|
|
49
52
|
},
|
|
50
53
|
// Success
|
|
51
54
|
{
|
|
52
55
|
"btn-success text-white": e.severity === "success" && !e.outlined && !e.link && !e.text,
|
|
53
56
|
"btn-outline-success": e.severity === "success" && e.outlined,
|
|
54
|
-
"text-success fw-bold btn-text-success": e.severity === "success" && e.text
|
|
57
|
+
"text-success fw-bold btn-text-success": e.severity === "success" && e.text,
|
|
58
|
+
"link-success text-decoration-underline link-underline-success": e.severity === "success" && e.link
|
|
55
59
|
},
|
|
56
60
|
// Warning
|
|
57
61
|
{
|
|
58
62
|
"btn-warning text-white": e.severity === "warning" && !e.outlined && !e.link && !e.text,
|
|
59
63
|
"btn-outline-warning": e.severity === "warning" && e.outlined,
|
|
60
|
-
"text-warning fw-bold btn-text-warning": e.severity === "warning" && e.text
|
|
64
|
+
"text-warning fw-bold btn-text-warning": e.severity === "warning" && e.text,
|
|
65
|
+
"link-warning text-decoration-underline link-underline-warning": e.severity === "warning" && e.link
|
|
61
66
|
},
|
|
62
67
|
// Danger
|
|
63
68
|
{
|
|
64
69
|
"btn-danger text-white": e.severity === "danger" && !e.outlined && !e.link && !e.text,
|
|
65
70
|
"btn-outline-danger": e.severity === "danger" && e.outlined,
|
|
66
|
-
"text-danger fw-bold btn-text-danger": e.severity === "danger" && e.text
|
|
71
|
+
"text-danger fw-bold btn-text-danger": e.severity === "danger" && e.text,
|
|
72
|
+
"link-danger text-decoration-underline link-underline-danger": e.severity === "danger" && e.link
|
|
67
73
|
},
|
|
68
74
|
// Info
|
|
69
75
|
{
|
|
70
76
|
"btn-info text-white": e.severity === "info" && !e.outlined && !e.link && !e.text,
|
|
71
77
|
"btn-outline-info": e.severity === "info" && e.outlined,
|
|
72
|
-
"text-info fw-bold btn-text-info": e.severity === "info" && e.text
|
|
78
|
+
"text-info fw-bold btn-text-info": e.severity === "info" && e.text,
|
|
79
|
+
"link-info text-decoration-underline link-underline-info": e.severity === "info" && e.link
|
|
73
80
|
},
|
|
74
81
|
// Misc
|
|
75
82
|
{
|
|
76
|
-
"
|
|
83
|
+
"p-0 border-0": e.link,
|
|
77
84
|
shadow: e.raised,
|
|
78
85
|
"rounded-pill": e.rounded,
|
|
79
86
|
"btn-lg": e.size == "large",
|
|
@@ -136,12 +143,11 @@ const De = {
|
|
|
136
143
|
}
|
|
137
144
|
]
|
|
138
145
|
}),
|
|
139
|
-
trigger: (e) => ({
|
|
146
|
+
trigger: ({ state: e }) => ({
|
|
140
147
|
class: [
|
|
141
|
-
"my-auto",
|
|
148
|
+
"my-auto ms-2",
|
|
142
149
|
{
|
|
143
|
-
"
|
|
144
|
-
"ms-2": e.props.showClear
|
|
150
|
+
"rotate-180": e.overlayVisible
|
|
145
151
|
}
|
|
146
152
|
]
|
|
147
153
|
}),
|
|
@@ -198,13 +204,13 @@ const De = {
|
|
|
198
204
|
column: {
|
|
199
205
|
sortBadge: "ms-2 my-auto cursor-pointer",
|
|
200
206
|
headerCell: (e) => {
|
|
201
|
-
var t,
|
|
207
|
+
var t, l, o, a;
|
|
202
208
|
return {
|
|
203
209
|
class: [
|
|
204
210
|
{
|
|
205
211
|
"cursor-move": e.props.reorderableColumns,
|
|
206
|
-
"position-sticky": ((t = e.column) == null ? void 0 : t.context.frozen) !== void 0 || ((
|
|
207
|
-
"overflow-hidden position-relative bg-clip-padding": (
|
|
212
|
+
"position-sticky": ((t = e.column) == null ? void 0 : t.context.frozen) !== void 0 || ((l = e.column) == null ? void 0 : l.context.frozen) || ((o = e.column) == null ? void 0 : o.context.frozen) === "",
|
|
213
|
+
"overflow-hidden position-relative bg-clip-padding": (a = e.column) == null ? void 0 : a.context.resizable
|
|
208
214
|
}
|
|
209
215
|
]
|
|
210
216
|
};
|
|
@@ -236,9 +242,12 @@ const De = {
|
|
|
236
242
|
}
|
|
237
243
|
]
|
|
238
244
|
}),
|
|
239
|
-
headerFilterClearButton: () => ({
|
|
245
|
+
headerFilterClearButton: ({ props: e }) => (console.log(), {
|
|
240
246
|
class: [
|
|
241
|
-
"btn"
|
|
247
|
+
"btn",
|
|
248
|
+
{
|
|
249
|
+
"d-none": e.filters[e.field].value === null
|
|
250
|
+
}
|
|
242
251
|
]
|
|
243
252
|
}),
|
|
244
253
|
filterOverlay: {
|
|
@@ -293,13 +302,13 @@ const De = {
|
|
|
293
302
|
}, Ee = {
|
|
294
303
|
inputtext: {
|
|
295
304
|
root: (e) => {
|
|
296
|
-
var t,
|
|
305
|
+
var t, l;
|
|
297
306
|
return {
|
|
298
307
|
class: [
|
|
299
308
|
"form-control",
|
|
300
309
|
{
|
|
301
310
|
"form-control-lg": ((t = e.props.size) == null ? void 0 : t.toLowerCase()) == "large",
|
|
302
|
-
"form-control-sm": ((
|
|
311
|
+
"form-control-sm": ((l = e.props.size) == null ? void 0 : l.toLowerCase()) == "small"
|
|
303
312
|
}
|
|
304
313
|
]
|
|
305
314
|
};
|
|
@@ -549,7 +558,7 @@ const De = {
|
|
|
549
558
|
list: "list-unstyled mb-0",
|
|
550
559
|
item: "dropdown-item d-flex cursor-pointer",
|
|
551
560
|
header: "d-flex",
|
|
552
|
-
labelContainer: "w-100",
|
|
561
|
+
labelContainer: "w-100 me-2",
|
|
553
562
|
label: "w-100",
|
|
554
563
|
filterContainer: "d-flex w-100",
|
|
555
564
|
filterIcon: "d-none",
|
|
@@ -730,7 +739,7 @@ const De = {
|
|
|
730
739
|
]
|
|
731
740
|
})
|
|
732
741
|
}
|
|
733
|
-
},
|
|
742
|
+
}, lt = {
|
|
734
743
|
tooltip: {
|
|
735
744
|
root: ({ context: e }) => ({
|
|
736
745
|
class: [
|
|
@@ -752,7 +761,7 @@ const De = {
|
|
|
752
761
|
class: ["tooltip-inner"]
|
|
753
762
|
}
|
|
754
763
|
}
|
|
755
|
-
},
|
|
764
|
+
}, at = {
|
|
756
765
|
selectbutton: {
|
|
757
766
|
root: () => ({
|
|
758
767
|
class: ["btn-group"]
|
|
@@ -812,7 +821,7 @@ const De = {
|
|
|
812
821
|
button: "preview-button",
|
|
813
822
|
mask: "position-fixed top-0 start-0 w-100 h-100 d-flex align-items-center justify-content-center mask",
|
|
814
823
|
preview: "preview",
|
|
815
|
-
toolbar: "position-absolute top-0 end-0 d-flex p-3",
|
|
824
|
+
toolbar: "position-absolute top-0 end-0 d-flex p-3 z-3",
|
|
816
825
|
rotaterightbutton: "btn text-white",
|
|
817
826
|
rotateleftbutton: "btn text-white",
|
|
818
827
|
zoomoutbutton: "btn text-white",
|
|
@@ -843,21 +852,21 @@ const De = {
|
|
|
843
852
|
class: ["ps-1"]
|
|
844
853
|
}),
|
|
845
854
|
icon: ({ props: e }) => {
|
|
846
|
-
var t,
|
|
855
|
+
var t, l, o, a;
|
|
847
856
|
return {
|
|
848
857
|
class: [
|
|
849
858
|
"toast-icon",
|
|
850
859
|
{
|
|
851
860
|
"text-primary": ((t = e.message) == null ? void 0 : t.severity) === "info",
|
|
852
|
-
"text-success": ((
|
|
861
|
+
"text-success": ((l = e.message) == null ? void 0 : l.severity) === "success",
|
|
853
862
|
"text-danger": ((o = e.message) == null ? void 0 : o.severity) === "error",
|
|
854
|
-
"text-warning": ((
|
|
863
|
+
"text-warning": ((a = e.message) == null ? void 0 : a.severity) === "warn"
|
|
855
864
|
}
|
|
856
865
|
]
|
|
857
866
|
};
|
|
858
867
|
}
|
|
859
868
|
}
|
|
860
|
-
},
|
|
869
|
+
}, ca = {
|
|
861
870
|
...et,
|
|
862
871
|
...De,
|
|
863
872
|
...nt,
|
|
@@ -878,16 +887,16 @@ const De = {
|
|
|
878
887
|
...Ye,
|
|
879
888
|
...Xe,
|
|
880
889
|
...ot,
|
|
881
|
-
...
|
|
890
|
+
...at,
|
|
882
891
|
...Ke,
|
|
883
892
|
...Qe,
|
|
884
893
|
...We,
|
|
885
894
|
...rt,
|
|
886
895
|
...je,
|
|
887
896
|
directives: {
|
|
888
|
-
...
|
|
897
|
+
...lt
|
|
889
898
|
}
|
|
890
|
-
},
|
|
899
|
+
}, ae = /* @__PURE__ */ F({
|
|
891
900
|
__name: "ForgeAlert",
|
|
892
901
|
props: {
|
|
893
902
|
severity: { default: "primary" },
|
|
@@ -903,9 +912,9 @@ const De = {
|
|
|
903
912
|
},
|
|
904
913
|
setup(e) {
|
|
905
914
|
const t = e;
|
|
906
|
-
return (
|
|
907
|
-
const
|
|
908
|
-
return i(), w(
|
|
915
|
+
return (l, o) => {
|
|
916
|
+
const a = be;
|
|
917
|
+
return i(), w(a, Q(ee({ ...l.$attrs, ...t })), {
|
|
909
918
|
messageicon: g(() => [
|
|
910
919
|
c("div", {
|
|
911
920
|
class: B(t.icon ? "me-2 pe-1" : "")
|
|
@@ -923,13 +932,13 @@ const De = {
|
|
|
923
932
|
f(m(V), { icon: "bi:x" })
|
|
924
933
|
]),
|
|
925
934
|
default: g(() => [
|
|
926
|
-
$(
|
|
935
|
+
$(l.$slots, "default")
|
|
927
936
|
]),
|
|
928
937
|
_: 3
|
|
929
938
|
}, 16);
|
|
930
939
|
};
|
|
931
940
|
}
|
|
932
|
-
}),
|
|
941
|
+
}), ma = /* @__PURE__ */ F({
|
|
933
942
|
__name: "ForgeActionButton",
|
|
934
943
|
props: {
|
|
935
944
|
action: {},
|
|
@@ -938,21 +947,21 @@ const De = {
|
|
|
938
947
|
params: { default: Array }
|
|
939
948
|
},
|
|
940
949
|
setup(e) {
|
|
941
|
-
const t = I(!1),
|
|
950
|
+
const t = I(!1), l = e, o = async () => {
|
|
942
951
|
t.value = !0;
|
|
943
952
|
try {
|
|
944
|
-
await
|
|
945
|
-
} catch (
|
|
946
|
-
await
|
|
953
|
+
await l.action.apply(this, l.params);
|
|
954
|
+
} catch (a) {
|
|
955
|
+
await l.errorAction.apply(this, l.errorParams ? [...l.errorParams, a] : [a]);
|
|
947
956
|
}
|
|
948
957
|
t.value = !1;
|
|
949
958
|
};
|
|
950
|
-
return (
|
|
951
|
-
const
|
|
959
|
+
return (a, n) => {
|
|
960
|
+
const d = R;
|
|
952
961
|
return i(), v(L, null, [
|
|
953
|
-
f(
|
|
962
|
+
f(d, _({ ...l, ...a.$attrs }, {
|
|
954
963
|
loading: t.value,
|
|
955
|
-
disabled: t.value ||
|
|
964
|
+
disabled: t.value || l.disabled,
|
|
956
965
|
onClick: o
|
|
957
966
|
}), null, 16, ["loading", "disabled"]),
|
|
958
967
|
f(m(he))
|
|
@@ -989,33 +998,33 @@ const De = {
|
|
|
989
998
|
}),
|
|
990
999
|
emits: ["update:modelValue"],
|
|
991
1000
|
setup(e) {
|
|
992
|
-
const t = e,
|
|
1001
|
+
const t = e, l = A(e, "modelValue"), {
|
|
993
1002
|
handleChange: o,
|
|
994
|
-
errors:
|
|
1003
|
+
errors: a,
|
|
995
1004
|
errorMessage: n
|
|
996
1005
|
} = K(() => t.name ?? "", void 0, {
|
|
997
1006
|
type: "checkbox",
|
|
998
|
-
checkedValue:
|
|
999
|
-
}),
|
|
1000
|
-
return (r,
|
|
1007
|
+
checkedValue: l.value
|
|
1008
|
+
}), d = k(() => a.value.length > 0);
|
|
1009
|
+
return (r, u) => {
|
|
1001
1010
|
const p = we;
|
|
1002
1011
|
return i(), v("div", dt, [
|
|
1003
1012
|
c("div", _({
|
|
1004
1013
|
class: "d-flex cursor-pointer",
|
|
1005
1014
|
"data-cy": "checkbox-container",
|
|
1006
|
-
onClick:
|
|
1015
|
+
onClick: u[2] || (u[2] = (y) => m(o)(l.value))
|
|
1007
1016
|
}, { ...r.$attrs }), [
|
|
1008
1017
|
f(p, _({ ...t }, {
|
|
1009
1018
|
binary: "",
|
|
1010
|
-
modelValue:
|
|
1011
|
-
"onUpdate:modelValue":
|
|
1019
|
+
modelValue: l.value,
|
|
1020
|
+
"onUpdate:modelValue": u[0] || (u[0] = (y) => l.value = y),
|
|
1012
1021
|
"input-id": t.name,
|
|
1013
|
-
"input-class": { "is-invalid":
|
|
1022
|
+
"input-class": { "is-invalid": d.value }
|
|
1014
1023
|
}), null, 16, ["modelValue", "input-id", "input-class"]),
|
|
1015
1024
|
c("label", {
|
|
1016
1025
|
for: t.name,
|
|
1017
|
-
onClick:
|
|
1018
|
-
class: B([`${t.disabled ? "opacity-50" : "cursor-pointer"} ${
|
|
1026
|
+
onClick: u[1] || (u[1] = (y) => m(o)(l.value)),
|
|
1027
|
+
class: B([`${t.disabled ? "opacity-50" : "cursor-pointer"} ${d.value ? "text-danger-dark" : ""}`, "w-100 my-auto"])
|
|
1019
1028
|
}, [
|
|
1020
1029
|
$(r.$slots, "default", {}, () => [
|
|
1021
1030
|
O(h(t.label), 1)
|
|
@@ -1026,7 +1035,7 @@ const De = {
|
|
|
1026
1035
|
"data-cy": "error",
|
|
1027
1036
|
class: "text-invalid"
|
|
1028
1037
|
}, h(m(n)), 513), [
|
|
1029
|
-
[H,
|
|
1038
|
+
[H, d.value]
|
|
1030
1039
|
])
|
|
1031
1040
|
]);
|
|
1032
1041
|
};
|
|
@@ -1038,17 +1047,17 @@ const De = {
|
|
|
1038
1047
|
},
|
|
1039
1048
|
setup(e) {
|
|
1040
1049
|
const t = e;
|
|
1041
|
-
return (
|
|
1042
|
-
const
|
|
1050
|
+
return (l, o) => {
|
|
1051
|
+
const a = xe;
|
|
1043
1052
|
return i(), v("div", mt, [
|
|
1044
|
-
f(
|
|
1053
|
+
f(a, {
|
|
1045
1054
|
"animation-duration": ".75",
|
|
1046
1055
|
class: B(`text-${t.severity === void 0 ? "primary" : t.severity}`)
|
|
1047
1056
|
}, null, 8, ["class"])
|
|
1048
1057
|
]);
|
|
1049
1058
|
};
|
|
1050
1059
|
}
|
|
1051
|
-
}), pt = ["href", "target"],
|
|
1060
|
+
}), pt = ["href", "target"], pa = /* @__PURE__ */ F({
|
|
1052
1061
|
__name: "ForgeLink",
|
|
1053
1062
|
props: {
|
|
1054
1063
|
url: {},
|
|
@@ -1066,7 +1075,7 @@ const De = {
|
|
|
1066
1075
|
iconName: {}
|
|
1067
1076
|
},
|
|
1068
1077
|
setup(e) {
|
|
1069
|
-
const t =
|
|
1078
|
+
const t = k(() => ({
|
|
1070
1079
|
[`link-${e.severity}`]: e.severity,
|
|
1071
1080
|
[`link-underline-${e.underlineSeverity}`]: e.underlineSeverity,
|
|
1072
1081
|
[`link-opacity-${e.opacity}`]: e.opacity,
|
|
@@ -1075,14 +1084,14 @@ const De = {
|
|
|
1075
1084
|
[`link-underline-opacity-${e.underlineHoverOpacity ?? e.hoverOpacity}-hover`]: e.underlineHoverOpacity || e.hoverOpacity,
|
|
1076
1085
|
[`link-offset-${e.underlineOffset}`]: e.underlineOffset,
|
|
1077
1086
|
"icon-link icon-link-hover": e.animateIconOnHover
|
|
1078
|
-
})),
|
|
1087
|
+
})), l = k(() => ({
|
|
1079
1088
|
"order-2": e.positionIconEnd,
|
|
1080
1089
|
"me-1": !e.positionIconEnd && !e.animateIconOnHover,
|
|
1081
1090
|
"ms-1": e.positionIconEnd && !e.animateIconOnHover,
|
|
1082
1091
|
"ms-0": e.positionIconEnd && e.animateIconOnHover,
|
|
1083
1092
|
"me-0": e.animateIconOnHover
|
|
1084
1093
|
}));
|
|
1085
|
-
return (o,
|
|
1094
|
+
return (o, a) => (i(), v("a", {
|
|
1086
1095
|
id: "link",
|
|
1087
1096
|
class: B(["cursor-pointer d-flex", t.value]),
|
|
1088
1097
|
href: o.url,
|
|
@@ -1093,7 +1102,7 @@ const De = {
|
|
|
1093
1102
|
key: 0,
|
|
1094
1103
|
id: "link-icon",
|
|
1095
1104
|
icon: o.iconName,
|
|
1096
|
-
class: B(["bi my-auto",
|
|
1105
|
+
class: B(["bi my-auto", l.value])
|
|
1097
1106
|
}, null, 8, ["icon", "class"])) : S("", !0),
|
|
1098
1107
|
O(" " + h(o.label), 1)
|
|
1099
1108
|
])
|
|
@@ -1106,21 +1115,21 @@ function yt(e) {
|
|
|
1106
1115
|
errorDetails: []
|
|
1107
1116
|
};
|
|
1108
1117
|
if (e.exception && (t.errorMessage = e.exception), e.message && (Array.isArray(e.message) ? t.errorDetails = e.message : t.errorMessage = e.message), e.response) {
|
|
1109
|
-
const
|
|
1110
|
-
|
|
1118
|
+
const l = JSON.parse(e.response);
|
|
1119
|
+
l.errors && (t.errorDetails = Object.values(l.errors).flat()), l.message && (t.errorDetails = l.message);
|
|
1111
1120
|
}
|
|
1112
1121
|
return t.errorMessage === "" && t.errorDetails.length === 0 && (t.errorMessage = e), t;
|
|
1113
1122
|
}
|
|
1114
|
-
function
|
|
1115
|
-
return e.map((
|
|
1123
|
+
function ya(e, t) {
|
|
1124
|
+
return e.map((l) => ({ id: l, label: t ? t(l) : `${l}` }));
|
|
1116
1125
|
}
|
|
1117
|
-
function
|
|
1118
|
-
return { id: e, label: t ?? e.toString(), shortLabel:
|
|
1126
|
+
function va(e, t, l) {
|
|
1127
|
+
return { id: e, label: t ?? e.toString(), shortLabel: l };
|
|
1119
1128
|
}
|
|
1120
1129
|
const vt = { key: 0 }, bt = {
|
|
1121
1130
|
class: "d-flex w-100",
|
|
1122
1131
|
"data-cy": "footer"
|
|
1123
|
-
},
|
|
1132
|
+
}, ba = /* @__PURE__ */ F({
|
|
1124
1133
|
__name: "ForgeModal",
|
|
1125
1134
|
props: /* @__PURE__ */ E({
|
|
1126
1135
|
cancelText: { default: "Cancel" },
|
|
@@ -1166,34 +1175,34 @@ const vt = { key: 0 }, bt = {
|
|
|
1166
1175
|
}),
|
|
1167
1176
|
emits: ["update:visible"],
|
|
1168
1177
|
setup(e) {
|
|
1169
|
-
const t = A(e, "visible"),
|
|
1178
|
+
const t = A(e, "visible"), l = I(!1), o = e, a = I(!1), n = I({
|
|
1170
1179
|
hasError: !1,
|
|
1171
1180
|
header: "",
|
|
1172
1181
|
message: []
|
|
1173
|
-
}),
|
|
1174
|
-
|
|
1182
|
+
}), d = () => {
|
|
1183
|
+
l.value = !1;
|
|
1175
1184
|
}, r = () => {
|
|
1176
|
-
|
|
1177
|
-
},
|
|
1185
|
+
l.value = !0;
|
|
1186
|
+
}, u = () => {
|
|
1178
1187
|
t.value = !1;
|
|
1179
1188
|
}, p = async () => {
|
|
1180
1189
|
if (o.onConfirm) {
|
|
1181
|
-
|
|
1190
|
+
a.value = !0, n.value.hasError = !1;
|
|
1182
1191
|
try {
|
|
1183
1192
|
const s = await o.onConfirm();
|
|
1184
|
-
(s || s == null) &&
|
|
1193
|
+
(s || s == null) && u();
|
|
1185
1194
|
} catch (s) {
|
|
1186
1195
|
n.value.hasError = !0;
|
|
1187
1196
|
const T = yt(s);
|
|
1188
1197
|
n.value.header = T.errorMessage, n.value.message = T.errorDetails;
|
|
1189
1198
|
}
|
|
1190
|
-
|
|
1199
|
+
a.value = !1;
|
|
1191
1200
|
}
|
|
1192
|
-
}, y =
|
|
1201
|
+
}, y = k(() => ({
|
|
1193
1202
|
root: [
|
|
1194
1203
|
"modal modal-dialog modal-content h-auto m-0",
|
|
1195
1204
|
{
|
|
1196
|
-
"mw-100 vh-100 vw-100 top-0 start-0":
|
|
1205
|
+
"mw-100 vh-100 vw-100 top-0 start-0": l.value,
|
|
1197
1206
|
"modal-sm": o.size === "sm",
|
|
1198
1207
|
"modal-lg": o.size === "lg",
|
|
1199
1208
|
"modal-xl": o.size === "xl"
|
|
@@ -1201,10 +1210,10 @@ const vt = { key: 0 }, bt = {
|
|
|
1201
1210
|
]
|
|
1202
1211
|
}));
|
|
1203
1212
|
return (s, T) => {
|
|
1204
|
-
const C = R,
|
|
1205
|
-
return i(), w(
|
|
1213
|
+
const C = R, P = ke;
|
|
1214
|
+
return i(), w(P, _(o, {
|
|
1206
1215
|
onMaximize: r,
|
|
1207
|
-
onUnmaximize:
|
|
1216
|
+
onUnmaximize: d,
|
|
1208
1217
|
pt: y.value
|
|
1209
1218
|
}), te({
|
|
1210
1219
|
closeicon: g(() => [
|
|
@@ -1213,23 +1222,23 @@ const vt = { key: 0 }, bt = {
|
|
|
1213
1222
|
icon: "bi:x-lg",
|
|
1214
1223
|
width: "18",
|
|
1215
1224
|
height: "18",
|
|
1216
|
-
onClick:
|
|
1225
|
+
onClick: u
|
|
1217
1226
|
})
|
|
1218
1227
|
]),
|
|
1219
1228
|
maximizeicon: g(() => [
|
|
1220
1229
|
f(m(V), {
|
|
1221
1230
|
"data-cy": "maximisable-icon",
|
|
1222
|
-
icon:
|
|
1231
|
+
icon: l.value ? "bi:arrows-angle-contract" : "bi:arrows-angle-expand",
|
|
1223
1232
|
width: "16",
|
|
1224
1233
|
height: "16"
|
|
1225
1234
|
}, null, 8, ["icon"])
|
|
1226
1235
|
]),
|
|
1227
1236
|
_: 2
|
|
1228
1237
|
}, [
|
|
1229
|
-
Y(s.$slots, (
|
|
1238
|
+
Y(s.$slots, (M, z) => ({
|
|
1230
1239
|
name: z,
|
|
1231
1240
|
fn: g((b) => [
|
|
1232
|
-
n.value.hasError ? (i(), w(
|
|
1241
|
+
n.value.hasError ? (i(), w(ae, {
|
|
1233
1242
|
key: 0,
|
|
1234
1243
|
severity: "danger",
|
|
1235
1244
|
"data-cy": "error"
|
|
@@ -1239,13 +1248,13 @@ const vt = { key: 0 }, bt = {
|
|
|
1239
1248
|
class: B(n.value.message.length > 0 ? "my-auto" : "mb-0")
|
|
1240
1249
|
}, h(n.value.header), 3),
|
|
1241
1250
|
n.value.message.length > 0 ? (i(), v("ul", vt, [
|
|
1242
|
-
(i(!0), v(L, null, Y(n.value.message, (
|
|
1251
|
+
(i(!0), v(L, null, Y(n.value.message, (x) => (i(), v("li", { key: x }, h(x), 1))), 128))
|
|
1243
1252
|
])) : S("", !0)
|
|
1244
1253
|
]),
|
|
1245
1254
|
_: 1
|
|
1246
1255
|
})) : S("", !0),
|
|
1247
1256
|
$(s.$slots, z, Q(ee(b || {}))),
|
|
1248
|
-
|
|
1257
|
+
a.value ? $(s.$slots, "loader", { key: 1 }, () => [
|
|
1249
1258
|
f(me, { "data-cy": "loader" })
|
|
1250
1259
|
]) : S("", !0)
|
|
1251
1260
|
])
|
|
@@ -1258,7 +1267,7 @@ const vt = { key: 0 }, bt = {
|
|
|
1258
1267
|
label: s.cancelText,
|
|
1259
1268
|
class: B(o.cancelClass),
|
|
1260
1269
|
outlined: "",
|
|
1261
|
-
onClick:
|
|
1270
|
+
onClick: u,
|
|
1262
1271
|
id: "cancel-button",
|
|
1263
1272
|
type: o.cancelButtonType
|
|
1264
1273
|
}, null, 8, ["label", "class", "type"]),
|
|
@@ -1291,13 +1300,13 @@ const vt = { key: 0 }, bt = {
|
|
|
1291
1300
|
}),
|
|
1292
1301
|
emits: ["update:modelValue"],
|
|
1293
1302
|
setup(e) {
|
|
1294
|
-
const t = e,
|
|
1303
|
+
const t = e, l = A(e, "modelValue"), o = I(!1), a = I(), n = () => {
|
|
1295
1304
|
var C;
|
|
1296
|
-
o.value = !o.value, (C =
|
|
1297
|
-
},
|
|
1305
|
+
o.value = !o.value, (C = a.value) == null || C.focus();
|
|
1306
|
+
}, d = async () => {
|
|
1298
1307
|
if (T.value)
|
|
1299
1308
|
return !1;
|
|
1300
|
-
if (
|
|
1309
|
+
if (l.value = s.value, t.completeAction)
|
|
1301
1310
|
try {
|
|
1302
1311
|
await t.completeAction.apply(this, t.params), o.value = !o.value;
|
|
1303
1312
|
} catch {
|
|
@@ -1307,17 +1316,17 @@ const vt = { key: 0 }, bt = {
|
|
|
1307
1316
|
o.value = !o.value;
|
|
1308
1317
|
}, r = () => {
|
|
1309
1318
|
o.value = !o.value;
|
|
1310
|
-
},
|
|
1319
|
+
}, u = () => {
|
|
1311
1320
|
s.value = null;
|
|
1312
1321
|
}, { errorMessage: p, errors: y, value: s } = K(() => t.name, void 0, {
|
|
1313
|
-
initialValue:
|
|
1322
|
+
initialValue: l.value
|
|
1314
1323
|
});
|
|
1315
1324
|
ne(() => {
|
|
1316
|
-
s.value =
|
|
1325
|
+
s.value = l.value;
|
|
1317
1326
|
});
|
|
1318
|
-
const T =
|
|
1319
|
-
return (C,
|
|
1320
|
-
const
|
|
1327
|
+
const T = k(() => y.value.length > 0);
|
|
1328
|
+
return (C, P) => {
|
|
1329
|
+
const M = ie, z = R;
|
|
1321
1330
|
return i(), v("div", {
|
|
1322
1331
|
id: t.name
|
|
1323
1332
|
}, [
|
|
@@ -1330,20 +1339,20 @@ const vt = { key: 0 }, bt = {
|
|
|
1330
1339
|
j((i(), v("div", wt, [
|
|
1331
1340
|
$(C.$slots, "editor", {
|
|
1332
1341
|
class: B({ "is-invalid": T.value }),
|
|
1333
|
-
editFinished:
|
|
1342
|
+
editFinished: d,
|
|
1334
1343
|
cancel: r,
|
|
1335
1344
|
val: m(s)
|
|
1336
1345
|
}, () => [
|
|
1337
|
-
f(
|
|
1346
|
+
f(M, {
|
|
1338
1347
|
"data-cy": "input",
|
|
1339
1348
|
ref_key: "input",
|
|
1340
|
-
ref:
|
|
1349
|
+
ref: a,
|
|
1341
1350
|
modelValue: m(s),
|
|
1342
|
-
"onUpdate:modelValue":
|
|
1351
|
+
"onUpdate:modelValue": P[0] || (P[0] = (b) => se(s) ? s.value = b : null),
|
|
1343
1352
|
modelModifiers: { trim: !0 },
|
|
1344
1353
|
class: B({ "is-invalid": T.value }),
|
|
1345
1354
|
onKeydown: [
|
|
1346
|
-
J(
|
|
1355
|
+
J(d, ["enter"]),
|
|
1347
1356
|
J(r, ["esc"])
|
|
1348
1357
|
]
|
|
1349
1358
|
}, null, 8, ["modelValue", "class"])
|
|
@@ -1351,12 +1360,12 @@ const vt = { key: 0 }, bt = {
|
|
|
1351
1360
|
f(m(V), {
|
|
1352
1361
|
icon: "bi:x-circle",
|
|
1353
1362
|
class: "mx-2 cursor-pointer",
|
|
1354
|
-
onClick:
|
|
1355
|
-
onKeydown: J(
|
|
1363
|
+
onClick: u,
|
|
1364
|
+
onKeydown: J(u, ["enter"]),
|
|
1356
1365
|
"data-cy": "clear-icon"
|
|
1357
1366
|
})
|
|
1358
1367
|
])), [
|
|
1359
|
-
[m($e),
|
|
1368
|
+
[m($e), d]
|
|
1360
1369
|
])
|
|
1361
1370
|
])) : (i(), v("div", {
|
|
1362
1371
|
key: 1,
|
|
@@ -1395,7 +1404,7 @@ const vt = { key: 0 }, bt = {
|
|
|
1395
1404
|
], 8, ft);
|
|
1396
1405
|
};
|
|
1397
1406
|
}
|
|
1398
|
-
}), Bt = ["href"],
|
|
1407
|
+
}), Bt = ["href"], fa = /* @__PURE__ */ F({
|
|
1399
1408
|
__name: "ForgeNavbar",
|
|
1400
1409
|
props: {
|
|
1401
1410
|
severity: { default: "light" },
|
|
@@ -1412,7 +1421,7 @@ const vt = { key: 0 }, bt = {
|
|
|
1412
1421
|
unstyled: { type: Boolean }
|
|
1413
1422
|
},
|
|
1414
1423
|
setup(e) {
|
|
1415
|
-
const t = e,
|
|
1424
|
+
const t = e, l = k(() => ({
|
|
1416
1425
|
root: () => ({
|
|
1417
1426
|
class: [
|
|
1418
1427
|
"navbar container-fluid navbar-expand-lg",
|
|
@@ -1439,10 +1448,10 @@ const vt = { key: 0 }, bt = {
|
|
|
1439
1448
|
]
|
|
1440
1449
|
})
|
|
1441
1450
|
}));
|
|
1442
|
-
return (o,
|
|
1451
|
+
return (o, a) => {
|
|
1443
1452
|
const n = Be;
|
|
1444
1453
|
return i(), w(n, _({ ...t, ...o.$attrs }, {
|
|
1445
|
-
pt:
|
|
1454
|
+
pt: l.value,
|
|
1446
1455
|
"data-cy": "navbar"
|
|
1447
1456
|
}), te({
|
|
1448
1457
|
start: g(() => [
|
|
@@ -1452,7 +1461,7 @@ const vt = { key: 0 }, bt = {
|
|
|
1452
1461
|
"data-cy": "logo"
|
|
1453
1462
|
}, [
|
|
1454
1463
|
$(o.$slots, "logo", {}, () => [
|
|
1455
|
-
O(" Logo ")
|
|
1464
|
+
a[0] || (a[0] = O(" Logo "))
|
|
1456
1465
|
])
|
|
1457
1466
|
], 8, Bt)
|
|
1458
1467
|
]),
|
|
@@ -1468,16 +1477,16 @@ const vt = { key: 0 }, bt = {
|
|
|
1468
1477
|
]),
|
|
1469
1478
|
_: 2
|
|
1470
1479
|
}, [
|
|
1471
|
-
Y(o.$slots, (
|
|
1480
|
+
Y(o.$slots, (d, r) => ({
|
|
1472
1481
|
name: r,
|
|
1473
|
-
fn: g((
|
|
1474
|
-
$(o.$slots, r, Q(ee(
|
|
1482
|
+
fn: g((u) => [
|
|
1483
|
+
$(o.$slots, r, Q(ee(u)))
|
|
1475
1484
|
])
|
|
1476
1485
|
}))
|
|
1477
1486
|
]), 1040, ["pt"]);
|
|
1478
1487
|
};
|
|
1479
1488
|
}
|
|
1480
|
-
}), Ft = { class: "multiselect__caret" }, _t = ["checked"], St =
|
|
1489
|
+
}), Ft = { class: "multiselect__caret" }, _t = ["checked"], St = ["data-cy"], Vt = ["checked"], Ct = { class: "my-auto ms-1" }, Tt = { class: "multiselect__tag d-inline-flex" }, Pt = { class: "my-auto" }, pe = /* @__PURE__ */ F({
|
|
1481
1490
|
__name: "ForgeMultiSelect",
|
|
1482
1491
|
props: {
|
|
1483
1492
|
severity: { default: "primary" },
|
|
@@ -1489,37 +1498,37 @@ const vt = { key: 0 }, bt = {
|
|
|
1489
1498
|
},
|
|
1490
1499
|
emits: ["update:modelValue"],
|
|
1491
1500
|
setup(e, { emit: t }) {
|
|
1492
|
-
const
|
|
1501
|
+
const l = e, o = (N, D) => {
|
|
1493
1502
|
const U = {
|
|
1494
1503
|
...D,
|
|
1495
1504
|
$isDisabled: D.$isDisabled ?? !1
|
|
1496
1505
|
};
|
|
1497
1506
|
N(U);
|
|
1498
|
-
},
|
|
1499
|
-
initialValue:
|
|
1500
|
-
}), p = I(!1), y =
|
|
1507
|
+
}, a = fe(), n = t, { errors: d, value: r, errorMessage: u } = K(() => l.name, void 0, {
|
|
1508
|
+
initialValue: a.modelValue
|
|
1509
|
+
}), p = I(!1), y = k(() => ({
|
|
1501
1510
|
multiple: !0,
|
|
1502
1511
|
label: "label",
|
|
1503
1512
|
trackBy: "id",
|
|
1504
1513
|
showPointer: !p.value,
|
|
1505
|
-
placeholder:
|
|
1514
|
+
placeholder: a.searchable === null || a.searchable ? "Search" : "Select",
|
|
1506
1515
|
allowEmpty: !0,
|
|
1507
1516
|
selectValue: "",
|
|
1508
|
-
closeOnSelect: !!(
|
|
1509
|
-
clearOnSelect: !!(
|
|
1510
|
-
searchable: !!(
|
|
1517
|
+
closeOnSelect: !!(a.multiple === null || a.multiple),
|
|
1518
|
+
clearOnSelect: !!(a.multiple === null || a.multiple),
|
|
1519
|
+
searchable: !!(a.searchable === null || a.searchable) && a.modelValue.length === a.options.length,
|
|
1511
1520
|
async: !1,
|
|
1512
|
-
...
|
|
1513
|
-
})), s =
|
|
1521
|
+
...a
|
|
1522
|
+
})), s = k(() => `forge-multiselect-${l.severity}`), T = k(() => `multiselect__option ${p.value ? " multiselect__option--highlight" : ""} ${C.value ? " multiselect__option--selected" : ""}`), C = k(() => y.value && !(y.value.multiple || !l.showSelectAll || y.value.async) ? !1 : a.modelValue.length === a.options.length), P = k(() => d.value.length > 0), M = k(() => !!((a.allowEmpty == null || a.allowEmpty) && l.showClearSelection && (y.value.multiple ? a.modelValue.length > 0 : a.modelValue))), z = () => p.value = !0, b = () => p.value = !1, x = () => {
|
|
1514
1523
|
r.value = y.value.multiple ? [] : null, n("update:modelValue", r.value);
|
|
1515
1524
|
}, G = (N) => {
|
|
1516
|
-
n("update:modelValue",
|
|
1517
|
-
}, Z = (N) =>
|
|
1518
|
-
C.value ?
|
|
1525
|
+
n("update:modelValue", l.selectValue ? N.map((D) => D[l.selectValue]) : N);
|
|
1526
|
+
}, Z = (N) => a.modelValue !== null ? a.modelValue.some((D) => y.value.selectValue ? N[l.selectValue] === D : N.id === D.id && N.label === D.label) : !1, oe = () => {
|
|
1527
|
+
C.value ? x() : (r.value = [...a.options], n("update:modelValue", [...a.options]));
|
|
1519
1528
|
};
|
|
1520
1529
|
return (N, D) => (i(), v(L, null, [
|
|
1521
1530
|
f(m(Fe), _(y.value, {
|
|
1522
|
-
class: [s.value,
|
|
1531
|
+
class: [s.value, P.value ? "is-invalid" : ""],
|
|
1523
1532
|
"data-cy": "multiselect",
|
|
1524
1533
|
"onUpdate:modelValue": [
|
|
1525
1534
|
G,
|
|
@@ -1529,11 +1538,11 @@ const vt = { key: 0 }, bt = {
|
|
|
1529
1538
|
}), te({
|
|
1530
1539
|
caret: g(({ toggle: U }) => [
|
|
1531
1540
|
c("div", Ft, [
|
|
1532
|
-
|
|
1541
|
+
M.value ? (i(), w(m(V), {
|
|
1533
1542
|
key: 0,
|
|
1534
1543
|
icon: "bi:x",
|
|
1535
1544
|
class: "my-auto text-black multiselect__clear",
|
|
1536
|
-
onMousedown: D[0] || (D[0] = q((W) =>
|
|
1545
|
+
onMousedown: D[0] || (D[0] = q((W) => x(), ["prevent", "stop"])),
|
|
1537
1546
|
"data-cy": "clear",
|
|
1538
1547
|
height: "18px",
|
|
1539
1548
|
width: "18px"
|
|
@@ -1546,12 +1555,12 @@ const vt = { key: 0 }, bt = {
|
|
|
1546
1555
|
])
|
|
1547
1556
|
]),
|
|
1548
1557
|
tag: g(({ option: U, remove: W }) => [
|
|
1549
|
-
c("div",
|
|
1558
|
+
c("div", Tt, [
|
|
1550
1559
|
c("div", Pt, h(U.label), 1),
|
|
1551
1560
|
f(m(V), {
|
|
1552
1561
|
icon: "bi:x",
|
|
1553
1562
|
class: "my-auto multiselect__tag-icon",
|
|
1554
|
-
onMousedown: q((
|
|
1563
|
+
onMousedown: q((Al) => o(W, U), ["prevent", "stop"]),
|
|
1555
1564
|
height: "18px",
|
|
1556
1565
|
width: "18px"
|
|
1557
1566
|
}, null, 8, ["onMousedown"])
|
|
@@ -1581,7 +1590,7 @@ const vt = { key: 0 }, bt = {
|
|
|
1581
1590
|
type: "checkbox",
|
|
1582
1591
|
class: "form-check-input px-2 py-2 rounded ms-2 cursor-pointer"
|
|
1583
1592
|
}, null, 8, _t),
|
|
1584
|
-
|
|
1593
|
+
D[2] || (D[2] = c("div", { class: "my-auto ms-1" }, "Toggle all", -1))
|
|
1585
1594
|
], 2)
|
|
1586
1595
|
], 32)
|
|
1587
1596
|
]),
|
|
@@ -1599,9 +1608,9 @@ const vt = { key: 0 }, bt = {
|
|
|
1599
1608
|
name: "selected",
|
|
1600
1609
|
type: "checkbox",
|
|
1601
1610
|
class: "form-check-input px-2 py-2 rounded ms-2 cursor-pointer"
|
|
1602
|
-
}, null, 8,
|
|
1603
|
-
c("div",
|
|
1604
|
-
], 8,
|
|
1611
|
+
}, null, 8, Vt),
|
|
1612
|
+
c("div", Ct, h(U[y.value.label]), 1)
|
|
1613
|
+
], 8, St)
|
|
1605
1614
|
]),
|
|
1606
1615
|
key: "1"
|
|
1607
1616
|
} : void 0
|
|
@@ -1609,22 +1618,22 @@ const vt = { key: 0 }, bt = {
|
|
|
1609
1618
|
j(c("small", {
|
|
1610
1619
|
"data-cy": "error",
|
|
1611
1620
|
class: "invalid-feedback"
|
|
1612
|
-
}, h(m(
|
|
1613
|
-
[H,
|
|
1621
|
+
}, h(m(u)), 513), [
|
|
1622
|
+
[H, P.value]
|
|
1614
1623
|
])
|
|
1615
1624
|
], 64));
|
|
1616
1625
|
}
|
|
1617
|
-
}),
|
|
1626
|
+
}), Mt = {
|
|
1618
1627
|
key: 0,
|
|
1619
1628
|
class: "pl-1"
|
|
1620
|
-
},
|
|
1629
|
+
}, It = { class: "border alternating-item-list" }, zt = {
|
|
1621
1630
|
key: 0,
|
|
1622
1631
|
class: "p-2 border-top border-bottom",
|
|
1623
1632
|
"data-cy": "title"
|
|
1624
|
-
},
|
|
1633
|
+
}, Ot = { class: "d-inline-block" }, Dt = {
|
|
1625
1634
|
key: 1,
|
|
1626
1635
|
class: "p-2 item d-flex justify-content-between align-items-center"
|
|
1627
|
-
},
|
|
1636
|
+
}, ga = /* @__PURE__ */ F({
|
|
1628
1637
|
__name: "ForgeMultiSelectPreview",
|
|
1629
1638
|
props: /* @__PURE__ */ E({
|
|
1630
1639
|
title: { default: "Selected Items" },
|
|
@@ -1639,60 +1648,60 @@ const vt = { key: 0 }, bt = {
|
|
|
1639
1648
|
}),
|
|
1640
1649
|
emits: ["update:modelValue"],
|
|
1641
1650
|
setup(e) {
|
|
1642
|
-
const t = e,
|
|
1643
|
-
|
|
1651
|
+
const t = e, l = A(e, "modelValue"), o = (a) => {
|
|
1652
|
+
l.value = l.value.filter((n) => n.id !== a);
|
|
1644
1653
|
};
|
|
1645
|
-
return (
|
|
1646
|
-
const
|
|
1654
|
+
return (a, n) => {
|
|
1655
|
+
const d = R;
|
|
1647
1656
|
return i(), v("div", {
|
|
1648
|
-
class: B(
|
|
1657
|
+
class: B(a.orientation === "column" ? "row" : ""),
|
|
1649
1658
|
"data-cy": "multiselect-preview"
|
|
1650
1659
|
}, [
|
|
1651
1660
|
c("div", {
|
|
1652
|
-
class: B(
|
|
1661
|
+
class: B(a.orientation === "row" ? "col-12 mb-1" : "col"),
|
|
1653
1662
|
"data-cy": "multiselect-container"
|
|
1654
1663
|
}, [
|
|
1655
1664
|
f(pe, _({
|
|
1656
|
-
modelValue:
|
|
1657
|
-
"onUpdate:modelValue": n[0] || (n[0] = (r) =>
|
|
1658
|
-
"limit-text": () => `${
|
|
1665
|
+
modelValue: l.value,
|
|
1666
|
+
"onUpdate:modelValue": n[0] || (n[0] = (r) => l.value = r),
|
|
1667
|
+
"limit-text": () => `${l.value.length} selected`,
|
|
1659
1668
|
options: t.options
|
|
1660
|
-
}, { ...
|
|
1661
|
-
tag: g(() => [
|
|
1669
|
+
}, { ...a.$attrs }), {
|
|
1670
|
+
tag: g(() => n[1] || (n[1] = [
|
|
1662
1671
|
O(h(""))
|
|
1663
|
-
]),
|
|
1672
|
+
])),
|
|
1664
1673
|
selection: g(() => [
|
|
1665
|
-
|
|
1674
|
+
l.value.length > 0 ? (i(), v("span", Mt, h(l.value.length) + " items selected", 1)) : S("", !0)
|
|
1666
1675
|
]),
|
|
1667
1676
|
default: g(() => [
|
|
1668
|
-
(i(!0), v(L, null, Y(
|
|
1677
|
+
(i(!0), v(L, null, Y(a.$slots, (r, u) => $(a.$slots, u, { slot: u })), 256))
|
|
1669
1678
|
]),
|
|
1670
1679
|
_: 3
|
|
1671
1680
|
}, 16, ["modelValue", "limit-text", "options"]),
|
|
1672
|
-
$(
|
|
1681
|
+
$(a.$slots, "after-multi-select")
|
|
1673
1682
|
], 2),
|
|
1674
1683
|
c("div", {
|
|
1675
|
-
class: B(
|
|
1684
|
+
class: B(a.orientation === "row" ? "col-12" : "col"),
|
|
1676
1685
|
"data-cy": "options-preview"
|
|
1677
1686
|
}, [
|
|
1678
1687
|
c("div", {
|
|
1679
|
-
style: ge({ height:
|
|
1688
|
+
style: ge({ height: a.height }),
|
|
1680
1689
|
class: "overflow-auto"
|
|
1681
1690
|
}, [
|
|
1682
|
-
c("div",
|
|
1683
|
-
|
|
1684
|
-
(i(!0), v(L, null, Y(
|
|
1691
|
+
c("div", It, [
|
|
1692
|
+
a.title ? (i(), v("div", zt, h(a.title), 1)) : S("", !0),
|
|
1693
|
+
(i(!0), v(L, null, Y(l.value, (r) => (i(), v("div", {
|
|
1685
1694
|
key: r.id,
|
|
1686
1695
|
class: "p-2 item d-flex justify-content-between align-items-center"
|
|
1687
1696
|
}, [
|
|
1688
|
-
$(
|
|
1689
|
-
c("span",
|
|
1697
|
+
$(a.$slots, "list-item", { item: r }, () => [
|
|
1698
|
+
c("span", Ot, h(r.shortLabel ? r.shortLabel : r.label), 1)
|
|
1690
1699
|
]),
|
|
1691
|
-
|
|
1700
|
+
a.canRemoveItemFromPreview ? (i(), w(d, {
|
|
1692
1701
|
key: 0,
|
|
1693
1702
|
link: "",
|
|
1694
1703
|
class: "m-0 p-0 d-flex align-items-center",
|
|
1695
|
-
onClick: (
|
|
1704
|
+
onClick: (u) => o(r.id)
|
|
1696
1705
|
}, {
|
|
1697
1706
|
default: g(() => [
|
|
1698
1707
|
f(m(V), {
|
|
@@ -1704,34 +1713,34 @@ const vt = { key: 0 }, bt = {
|
|
|
1704
1713
|
_: 2
|
|
1705
1714
|
}, 1032, ["onClick"])) : S("", !0)
|
|
1706
1715
|
]))), 128)),
|
|
1707
|
-
|
|
1716
|
+
l.value.length === 0 ? (i(), v("div", Dt, h(t.optionsPreviewEmptyText), 1)) : S("", !0)
|
|
1708
1717
|
])
|
|
1709
1718
|
], 4)
|
|
1710
1719
|
], 2)
|
|
1711
1720
|
], 2);
|
|
1712
1721
|
};
|
|
1713
1722
|
}
|
|
1714
|
-
}),
|
|
1723
|
+
}), Ut = { class: "d-flex justify-content-between pb-2" }, At = {
|
|
1715
1724
|
"data-cy": "title",
|
|
1716
1725
|
class: "my-auto"
|
|
1717
|
-
},
|
|
1726
|
+
}, Nt = {
|
|
1718
1727
|
"data-cy": "slot",
|
|
1719
1728
|
class: "d-flex align-items-center"
|
|
1720
|
-
},
|
|
1729
|
+
}, ha = /* @__PURE__ */ F({
|
|
1721
1730
|
__name: "ForgePageHeader",
|
|
1722
1731
|
props: {
|
|
1723
1732
|
title: {}
|
|
1724
1733
|
},
|
|
1725
1734
|
setup(e) {
|
|
1726
1735
|
const t = e;
|
|
1727
|
-
return (
|
|
1728
|
-
c("h3",
|
|
1729
|
-
c("div",
|
|
1730
|
-
$(
|
|
1736
|
+
return (l, o) => (i(), v("div", Ut, [
|
|
1737
|
+
c("h3", At, h(t.title), 1),
|
|
1738
|
+
c("div", Nt, [
|
|
1739
|
+
$(l.$slots, "default")
|
|
1731
1740
|
])
|
|
1732
1741
|
]));
|
|
1733
1742
|
}
|
|
1734
|
-
}),
|
|
1743
|
+
}), Et = { class: "d-flex" }, Lt = { "data-cy": "before-slot" }, Rt = { class: "position-relative w-100" }, jt = { "data-cy": "after-slot" }, ye = /* @__PURE__ */ F({
|
|
1735
1744
|
__name: "ForgeDatepicker",
|
|
1736
1745
|
props: /* @__PURE__ */ E({
|
|
1737
1746
|
severity: { default: "primary" },
|
|
@@ -1804,11 +1813,11 @@ const vt = { key: 0 }, bt = {
|
|
|
1804
1813
|
}),
|
|
1805
1814
|
emits: ["update:modelValue"],
|
|
1806
1815
|
setup(e) {
|
|
1807
|
-
const t = e,
|
|
1808
|
-
initialValue:
|
|
1809
|
-
}),
|
|
1810
|
-
r(null),
|
|
1811
|
-
}, p =
|
|
1816
|
+
const t = e, l = A(e, "modelValue"), { errors: o, errorMessage: a, handleChange: n, handleBlur: d, setValue: r } = K(() => t.name, void 0, {
|
|
1817
|
+
initialValue: l.value
|
|
1818
|
+
}), u = () => {
|
|
1819
|
+
r(null), l.value = null;
|
|
1820
|
+
}, p = k(() => o.value.length > 0), y = k(() => ({
|
|
1812
1821
|
day: ({ context: s }) => ({
|
|
1813
1822
|
class: [
|
|
1814
1823
|
`text-center date-${t.severity === void 0 ? "primary" : t.severity}`,
|
|
@@ -1902,19 +1911,19 @@ const vt = { key: 0 }, bt = {
|
|
|
1902
1911
|
return (s, T) => {
|
|
1903
1912
|
const C = _e;
|
|
1904
1913
|
return i(), v(L, null, [
|
|
1905
|
-
c("div",
|
|
1906
|
-
c("span",
|
|
1914
|
+
c("div", Et, [
|
|
1915
|
+
c("span", Lt, [
|
|
1907
1916
|
$(s.$slots, "before")
|
|
1908
1917
|
]),
|
|
1909
|
-
c("div",
|
|
1918
|
+
c("div", Rt, [
|
|
1910
1919
|
f(C, _({ ...t, ...s.$attrs }, {
|
|
1911
1920
|
pt: y.value,
|
|
1912
|
-
modelValue:
|
|
1921
|
+
modelValue: l.value,
|
|
1913
1922
|
"onUpdate:modelValue": [
|
|
1914
|
-
T[0] || (T[0] = (
|
|
1923
|
+
T[0] || (T[0] = (P) => l.value = P),
|
|
1915
1924
|
m(n)
|
|
1916
1925
|
],
|
|
1917
|
-
onBlur: m(
|
|
1926
|
+
onBlur: m(d),
|
|
1918
1927
|
"input-class": { "is-invalid": p.value }
|
|
1919
1928
|
}), null, 16, ["pt", "modelValue", "onUpdate:modelValue", "onBlur", "input-class"]),
|
|
1920
1929
|
j(f(m(V), {
|
|
@@ -1927,38 +1936,38 @@ const vt = { key: 0 }, bt = {
|
|
|
1927
1936
|
j(f(m(V), {
|
|
1928
1937
|
"data-cy": "icon",
|
|
1929
1938
|
icon: "bi:x",
|
|
1930
|
-
onClick:
|
|
1939
|
+
onClick: u,
|
|
1931
1940
|
class: B(["position-absolute end-0 top-50 bottom-50 my-auto text-muted cursor-pointer bg-white", t.showIcon ? "datepicker-close-icon" : "me-2"])
|
|
1932
1941
|
}, null, 8, ["class"]), [
|
|
1933
1942
|
[H, t.modelValue]
|
|
1934
1943
|
])
|
|
1935
1944
|
]),
|
|
1936
|
-
c("span",
|
|
1945
|
+
c("span", jt, [
|
|
1937
1946
|
$(s.$slots, "after")
|
|
1938
1947
|
])
|
|
1939
1948
|
]),
|
|
1940
1949
|
j(c("small", {
|
|
1941
1950
|
"data-cy": "error",
|
|
1942
1951
|
class: "text-invalid"
|
|
1943
|
-
}, h(m(
|
|
1952
|
+
}, h(m(a)), 513), [
|
|
1944
1953
|
[H, p.value]
|
|
1945
1954
|
])
|
|
1946
1955
|
], 64);
|
|
1947
1956
|
};
|
|
1948
1957
|
}
|
|
1949
|
-
}),
|
|
1958
|
+
}), wa = /* @__PURE__ */ F({
|
|
1950
1959
|
__name: "ForgeRemainingCharacters",
|
|
1951
1960
|
props: {
|
|
1952
1961
|
maxCount: { default: 300 },
|
|
1953
1962
|
currentCount: {}
|
|
1954
1963
|
},
|
|
1955
1964
|
setup(e) {
|
|
1956
|
-
const t = e,
|
|
1957
|
-
return (o,
|
|
1958
|
-
class: B(
|
|
1959
|
-
}, "Remaining characters: " + h(
|
|
1965
|
+
const t = e, l = k(() => t.maxCount - t.currentCount);
|
|
1966
|
+
return (o, a) => (i(), v("div", {
|
|
1967
|
+
class: B(l.value < 0 ? "text-danger" : "")
|
|
1968
|
+
}, "Remaining characters: " + h(l.value), 3));
|
|
1960
1969
|
}
|
|
1961
|
-
}),
|
|
1970
|
+
}), Ht = { class: "d-flex justify-content-between" }, xa = /* @__PURE__ */ F({
|
|
1962
1971
|
__name: "ForgeForm",
|
|
1963
1972
|
props: {
|
|
1964
1973
|
onSubmit: {},
|
|
@@ -1970,25 +1979,25 @@ const vt = { key: 0 }, bt = {
|
|
|
1970
1979
|
hideCancel: { type: Boolean, default: !1 }
|
|
1971
1980
|
},
|
|
1972
1981
|
setup(e) {
|
|
1973
|
-
const t = e,
|
|
1982
|
+
const t = e, l = I(!1), o = I({
|
|
1974
1983
|
hasError: !1,
|
|
1975
1984
|
message: ""
|
|
1976
1985
|
});
|
|
1977
|
-
async function
|
|
1978
|
-
|
|
1986
|
+
async function a() {
|
|
1987
|
+
l.value = !0, o.value.hasError = !1;
|
|
1979
1988
|
try {
|
|
1980
1989
|
await t.onSubmit();
|
|
1981
1990
|
} catch (n) {
|
|
1982
1991
|
o.value.hasError = !0, n.message && (o.value.message = n.message);
|
|
1983
1992
|
}
|
|
1984
|
-
|
|
1993
|
+
l.value = !1;
|
|
1985
1994
|
}
|
|
1986
|
-
return (n,
|
|
1995
|
+
return (n, d) => {
|
|
1987
1996
|
const r = R;
|
|
1988
1997
|
return i(), v("form", _(n.$attrs, {
|
|
1989
1998
|
novalidate: "",
|
|
1990
1999
|
class: "position-relative shadow-sm border p-4 bg-white",
|
|
1991
|
-
onSubmit: q(
|
|
2000
|
+
onSubmit: q(a, ["prevent"])
|
|
1992
2001
|
}), [
|
|
1993
2002
|
n.hideTitle ? S("", !0) : (i(), v(L, { key: 0 }, [
|
|
1994
2003
|
$(n.$slots, "title", {}, () => [
|
|
@@ -1997,9 +2006,9 @@ const vt = { key: 0 }, bt = {
|
|
|
1997
2006
|
"data-cy": "form-title"
|
|
1998
2007
|
}, h(n.title), 3)
|
|
1999
2008
|
]),
|
|
2000
|
-
|
|
2009
|
+
d[1] || (d[1] = c("hr", null, null, -1))
|
|
2001
2010
|
], 64)),
|
|
2002
|
-
o.value.hasError ? (i(), w(
|
|
2011
|
+
o.value.hasError ? (i(), w(ae, {
|
|
2003
2012
|
key: 1,
|
|
2004
2013
|
severity: "danger",
|
|
2005
2014
|
"data-cy": "error"
|
|
@@ -2014,7 +2023,7 @@ const vt = { key: 0 }, bt = {
|
|
|
2014
2023
|
_: 3
|
|
2015
2024
|
})) : S("", !0),
|
|
2016
2025
|
$(n.$slots, "default"),
|
|
2017
|
-
c("div",
|
|
2026
|
+
c("div", Ht, [
|
|
2018
2027
|
$(n.$slots, "cancel", {}, () => [
|
|
2019
2028
|
n.hideCancel ? S("", !0) : (i(), w(r, {
|
|
2020
2029
|
key: 0,
|
|
@@ -2022,7 +2031,7 @@ const vt = { key: 0 }, bt = {
|
|
|
2022
2031
|
type: "reset",
|
|
2023
2032
|
severity: "secondary",
|
|
2024
2033
|
outlined: "",
|
|
2025
|
-
onClick:
|
|
2034
|
+
onClick: d[0] || (d[0] = (u) => n.$emit("cancel"))
|
|
2026
2035
|
}, {
|
|
2027
2036
|
default: g(() => [
|
|
2028
2037
|
O(h(n.cancelText), 1)
|
|
@@ -2030,7 +2039,7 @@ const vt = { key: 0 }, bt = {
|
|
|
2030
2039
|
_: 1
|
|
2031
2040
|
}))
|
|
2032
2041
|
]),
|
|
2033
|
-
$(n.$slots, "submit", { submit:
|
|
2042
|
+
$(n.$slots, "submit", { submit: a }, () => [
|
|
2034
2043
|
f(r, {
|
|
2035
2044
|
"data-cy": "submit-btn",
|
|
2036
2045
|
type: "submit",
|
|
@@ -2044,20 +2053,21 @@ const vt = { key: 0 }, bt = {
|
|
|
2044
2053
|
})
|
|
2045
2054
|
])
|
|
2046
2055
|
]),
|
|
2047
|
-
|
|
2056
|
+
l.value ? (i(), w(me, {
|
|
2048
2057
|
key: 2,
|
|
2049
2058
|
"data-cy": "loading-spinner"
|
|
2050
2059
|
})) : S("", !0)
|
|
2051
2060
|
], 16);
|
|
2052
2061
|
};
|
|
2053
2062
|
}
|
|
2054
|
-
}),
|
|
2063
|
+
}), qt = {
|
|
2055
2064
|
key: 1,
|
|
2056
2065
|
class: "d-flex flex-column w-100"
|
|
2057
|
-
},
|
|
2066
|
+
}, Yt = ["for"], ka = /* @__PURE__ */ F({
|
|
2058
2067
|
__name: "ForgeFormField",
|
|
2059
2068
|
props: /* @__PURE__ */ E({
|
|
2060
2069
|
name: {},
|
|
2070
|
+
fieldLabelPosition: { default: "top" },
|
|
2061
2071
|
fieldLabel: {},
|
|
2062
2072
|
type: { default: "text" },
|
|
2063
2073
|
mask: { default: "" },
|
|
@@ -2068,92 +2078,97 @@ const vt = { key: 0 }, bt = {
|
|
|
2068
2078
|
}),
|
|
2069
2079
|
emits: ["update:modelValue"],
|
|
2070
2080
|
setup(e) {
|
|
2071
|
-
const t = A(e, "modelValue"),
|
|
2072
|
-
|
|
2073
|
-
}, { errors:
|
|
2081
|
+
const t = A(e, "modelValue"), l = e, o = (y) => {
|
|
2082
|
+
l.type == "number" ? r(y.value) : r(y);
|
|
2083
|
+
}, { errors: a, value: n, errorMessage: d, handleChange: r, handleBlur: u } = K(() => l.name, void 0, {
|
|
2074
2084
|
initialValue: t.value
|
|
2075
|
-
}), p =
|
|
2085
|
+
}), p = k(() => a.value.length > 0);
|
|
2076
2086
|
return de(() => n.value, (y) => {
|
|
2077
2087
|
t.value = y;
|
|
2078
2088
|
}, { immediate: !0 }), (y, s) => {
|
|
2079
|
-
const T = Ve, C = Se,
|
|
2080
|
-
return
|
|
2089
|
+
const T = Ve, C = Se, P = ie, M = le, z = pe, b = ye;
|
|
2090
|
+
return l.type === "checkbox" ? (i(), w(ct, _({
|
|
2081
2091
|
key: 0,
|
|
2082
|
-
id:
|
|
2083
|
-
label:
|
|
2092
|
+
id: l.name,
|
|
2093
|
+
label: l.fieldLabel
|
|
2084
2094
|
}, y.$attrs, {
|
|
2085
|
-
name:
|
|
2095
|
+
name: l.name,
|
|
2086
2096
|
modelValue: t.value,
|
|
2087
|
-
"onUpdate:modelValue": s[0] || (s[0] = (
|
|
2088
|
-
}), null, 16, ["id", "label", "name", "modelValue"])) : (i(), v("div",
|
|
2089
|
-
c("
|
|
2090
|
-
|
|
2091
|
-
class: "
|
|
2092
|
-
},
|
|
2093
|
-
|
|
2094
|
-
|
|
2095
|
-
|
|
2096
|
-
|
|
2097
|
-
|
|
2098
|
-
|
|
2099
|
-
|
|
2100
|
-
|
|
2101
|
-
|
|
2102
|
-
|
|
2103
|
-
|
|
2104
|
-
|
|
2105
|
-
|
|
2106
|
-
|
|
2107
|
-
placeholder:
|
|
2108
|
-
|
|
2109
|
-
|
|
2110
|
-
|
|
2111
|
-
|
|
2112
|
-
|
|
2113
|
-
|
|
2114
|
-
|
|
2115
|
-
|
|
2116
|
-
|
|
2117
|
-
placeholder:
|
|
2118
|
-
|
|
2119
|
-
|
|
2120
|
-
|
|
2121
|
-
|
|
2122
|
-
|
|
2123
|
-
|
|
2124
|
-
|
|
2125
|
-
|
|
2126
|
-
|
|
2127
|
-
|
|
2128
|
-
placeholder:
|
|
2129
|
-
|
|
2130
|
-
|
|
2131
|
-
|
|
2132
|
-
|
|
2133
|
-
|
|
2134
|
-
|
|
2135
|
-
|
|
2136
|
-
|
|
2137
|
-
|
|
2138
|
-
|
|
2139
|
-
|
|
2140
|
-
|
|
2141
|
-
|
|
2142
|
-
|
|
2143
|
-
|
|
2144
|
-
|
|
2145
|
-
|
|
2146
|
-
|
|
2097
|
+
"onUpdate:modelValue": s[0] || (s[0] = (x) => t.value = x)
|
|
2098
|
+
}), null, 16, ["id", "label", "name", "modelValue"])) : (i(), v("div", qt, [
|
|
2099
|
+
c("div", {
|
|
2100
|
+
"data-cy": "input-wrapper",
|
|
2101
|
+
class: B(["d-flex", l.fieldLabelPosition === "top" ? "flex-column" : "flex-row"])
|
|
2102
|
+
}, [
|
|
2103
|
+
c("label", {
|
|
2104
|
+
for: l.name,
|
|
2105
|
+
class: B(l.fieldLabelPosition === "top" ? "mb-1" : "me-2")
|
|
2106
|
+
}, h(l.fieldLabel), 11, Yt),
|
|
2107
|
+
l.type === "number" ? (i(), w(m(ue), _({
|
|
2108
|
+
key: 0,
|
|
2109
|
+
id: l.name
|
|
2110
|
+
}, y.$attrs, {
|
|
2111
|
+
placeholder: l.placeholder,
|
|
2112
|
+
"input-class": { "is-invalid": p.value },
|
|
2113
|
+
class: { "is-invalid": p.value },
|
|
2114
|
+
modelValue: t.value,
|
|
2115
|
+
"onUpdate:modelValue": s[1] || (s[1] = (x) => t.value = x),
|
|
2116
|
+
onInput: o
|
|
2117
|
+
}), null, 16, ["id", "placeholder", "input-class", "class", "modelValue"])) : l.type === "textarea" ? (i(), w(T, _({
|
|
2118
|
+
key: 1,
|
|
2119
|
+
id: l.name
|
|
2120
|
+
}, y.$attrs, {
|
|
2121
|
+
placeholder: l.placeholder,
|
|
2122
|
+
class: { "is-invalid": p.value },
|
|
2123
|
+
modelValue: t.value,
|
|
2124
|
+
"onUpdate:modelValue": s[2] || (s[2] = (x) => t.value = x),
|
|
2125
|
+
onInput: o,
|
|
2126
|
+
onBlur: m(u)
|
|
2127
|
+
}), null, 16, ["id", "placeholder", "class", "modelValue", "onBlur"])) : l.type === "mask" ? (i(), w(C, _({
|
|
2128
|
+
key: 2,
|
|
2129
|
+
id: l.name
|
|
2130
|
+
}, y.$attrs, {
|
|
2131
|
+
placeholder: l.placeholder,
|
|
2132
|
+
mask: l.mask,
|
|
2133
|
+
class: { "is-invalid": p.value },
|
|
2134
|
+
modelValue: t.value,
|
|
2135
|
+
"onUpdate:modelValue": s[3] || (s[3] = (x) => t.value = x),
|
|
2136
|
+
onComplete: o,
|
|
2137
|
+
onBlur: m(u)
|
|
2138
|
+
}), null, 16, ["id", "placeholder", "mask", "class", "modelValue", "onBlur"])) : l.type === "text" ? (i(), w(P, _({
|
|
2139
|
+
key: 3,
|
|
2140
|
+
id: l.name
|
|
2141
|
+
}, y.$attrs, {
|
|
2142
|
+
placeholder: l.placeholder,
|
|
2143
|
+
class: { "is-invalid": p.value },
|
|
2144
|
+
modelValue: t.value,
|
|
2145
|
+
"onUpdate:modelValue": s[4] || (s[4] = (x) => t.value = x),
|
|
2146
|
+
onInput: o,
|
|
2147
|
+
onBlur: m(u)
|
|
2148
|
+
}), null, 16, ["id", "placeholder", "class", "modelValue", "onBlur"])) : l.type === "select" ? (i(), w(M, _({ key: 4 }, { ...l, ...y.$attrs }, {
|
|
2149
|
+
modelValue: t.value,
|
|
2150
|
+
"onUpdate:modelValue": s[5] || (s[5] = (x) => t.value = x),
|
|
2151
|
+
class: { "is-invalid": p.value }
|
|
2152
|
+
}), null, 16, ["modelValue", "class"])) : l.type === "multiselect" ? (i(), w(z, _({ key: 5 }, { ...l, ...y.$attrs }, {
|
|
2153
|
+
modelValue: t.value,
|
|
2154
|
+
"onUpdate:modelValue": s[6] || (s[6] = (x) => t.value = x),
|
|
2155
|
+
class: { "is-invalid": p.value }
|
|
2156
|
+
}), null, 16, ["modelValue", "class"])) : l.type === "datepicker" ? (i(), w(b, _({ key: 6 }, { ...l, ...y.$attrs }, {
|
|
2157
|
+
modelValue: t.value,
|
|
2158
|
+
"onUpdate:modelValue": s[7] || (s[7] = (x) => t.value = x),
|
|
2159
|
+
class: { "is-invalid": p.value }
|
|
2160
|
+
}), null, 16, ["modelValue", "class"])) : S("", !0)
|
|
2161
|
+
], 2),
|
|
2147
2162
|
j(c("small", {
|
|
2148
2163
|
"data-cy": "error",
|
|
2149
2164
|
class: "invalid-feedback"
|
|
2150
|
-
}, h(m(
|
|
2151
|
-
[H, p.value &&
|
|
2165
|
+
}, h(m(d)), 513), [
|
|
2166
|
+
[H, p.value && l.type !== "multiselect" && l.type !== "datepicker"]
|
|
2152
2167
|
])
|
|
2153
2168
|
]));
|
|
2154
2169
|
};
|
|
2155
2170
|
}
|
|
2156
|
-
}),
|
|
2171
|
+
}), $a = /* @__PURE__ */ F({
|
|
2157
2172
|
__name: "ForgeChips",
|
|
2158
2173
|
props: {
|
|
2159
2174
|
chipSeverity: { default: "primary" },
|
|
@@ -2180,9 +2195,9 @@ const vt = { key: 0 }, bt = {
|
|
|
2180
2195
|
unstyled: { type: Boolean }
|
|
2181
2196
|
},
|
|
2182
2197
|
setup(e) {
|
|
2183
|
-
const t = e, { errors:
|
|
2198
|
+
const t = e, { errors: l, value: o, errorMessage: a } = K(() => t.name, void 0, {
|
|
2184
2199
|
initialValue: t.modelValue
|
|
2185
|
-
}), n =
|
|
2200
|
+
}), n = k(() => l.value.length > 0), d = k(() => ({
|
|
2186
2201
|
inputtoken: "list-unstyled",
|
|
2187
2202
|
input: "border-0",
|
|
2188
2203
|
container: ({ props: r }) => ({
|
|
@@ -2213,13 +2228,13 @@ const vt = { key: 0 }, bt = {
|
|
|
2213
2228
|
]
|
|
2214
2229
|
}
|
|
2215
2230
|
}));
|
|
2216
|
-
return (r,
|
|
2231
|
+
return (r, u) => {
|
|
2217
2232
|
const p = Ce;
|
|
2218
2233
|
return i(), v(L, null, [
|
|
2219
2234
|
f(p, _({ ...t, ...r.$attrs }, {
|
|
2220
|
-
pt:
|
|
2235
|
+
pt: d.value,
|
|
2221
2236
|
"model-value": m(o),
|
|
2222
|
-
"onUpdate:modelValue":
|
|
2237
|
+
"onUpdate:modelValue": u[0] || (u[0] = (y) => se(o) ? o.value = y : null)
|
|
2223
2238
|
}), {
|
|
2224
2239
|
removetokenicon: g(({ removeCallback: y }) => [
|
|
2225
2240
|
j(f(m(V), {
|
|
@@ -2235,13 +2250,13 @@ const vt = { key: 0 }, bt = {
|
|
|
2235
2250
|
j(c("small", {
|
|
2236
2251
|
"data-cy": "error",
|
|
2237
2252
|
class: "text-invalid"
|
|
2238
|
-
}, h(m(
|
|
2253
|
+
}, h(m(a)), 513), [
|
|
2239
2254
|
[H, n.value]
|
|
2240
2255
|
])
|
|
2241
2256
|
], 64);
|
|
2242
2257
|
};
|
|
2243
2258
|
}
|
|
2244
|
-
}),
|
|
2259
|
+
}), Gt = /* @__PURE__ */ F({
|
|
2245
2260
|
__name: "ForgeProgressBar",
|
|
2246
2261
|
props: {
|
|
2247
2262
|
severity: { default: "primary" },
|
|
@@ -2256,7 +2271,7 @@ const vt = { key: 0 }, bt = {
|
|
|
2256
2271
|
unstyled: { type: Boolean }
|
|
2257
2272
|
},
|
|
2258
2273
|
setup(e) {
|
|
2259
|
-
const t = e,
|
|
2274
|
+
const t = e, l = k(() => t.striped ? "progress-bar-striped" : null), o = k(() => t.animate ? "progress-bar-animated" : null), a = k(() => {
|
|
2260
2275
|
switch (t.severity) {
|
|
2261
2276
|
case "brand":
|
|
2262
2277
|
return "bg-brand";
|
|
@@ -2275,25 +2290,25 @@ const vt = { key: 0 }, bt = {
|
|
|
2275
2290
|
default:
|
|
2276
2291
|
return "bg-primary";
|
|
2277
2292
|
}
|
|
2278
|
-
}), n =
|
|
2293
|
+
}), n = k(() => ({
|
|
2279
2294
|
root: {
|
|
2280
2295
|
style: t.pixelWidth ? `width: ${t.pixelWidth}px` : ""
|
|
2281
2296
|
},
|
|
2282
2297
|
value: {
|
|
2283
|
-
class: [
|
|
2298
|
+
class: [a.value, l.value, o.value]
|
|
2284
2299
|
}
|
|
2285
2300
|
}));
|
|
2286
|
-
return (
|
|
2287
|
-
const
|
|
2288
|
-
return i(), w(
|
|
2301
|
+
return (d, r) => {
|
|
2302
|
+
const u = Te;
|
|
2303
|
+
return i(), w(u, _({ ...d.$attrs, ...t }, { pt: n.value }), {
|
|
2289
2304
|
default: g(() => [
|
|
2290
|
-
$(
|
|
2305
|
+
$(d.$slots, "default")
|
|
2291
2306
|
]),
|
|
2292
2307
|
_: 3
|
|
2293
2308
|
}, 16, ["pt"]);
|
|
2294
2309
|
};
|
|
2295
2310
|
}
|
|
2296
|
-
}),
|
|
2311
|
+
}), Kt = { class: "value text-white w-100 text-center" }, Ba = /* @__PURE__ */ F({
|
|
2297
2312
|
__name: "ForgeStatWidget",
|
|
2298
2313
|
props: {
|
|
2299
2314
|
size: { default: "md" },
|
|
@@ -2301,18 +2316,18 @@ const vt = { key: 0 }, bt = {
|
|
|
2301
2316
|
},
|
|
2302
2317
|
setup(e) {
|
|
2303
2318
|
const t = e;
|
|
2304
|
-
return (
|
|
2319
|
+
return (l, o) => (i(), v("div", _(l.$attrs, {
|
|
2305
2320
|
class: `d-flex shadow m-2 align-items-center widget--${t.size} bg-${t.severity}`
|
|
2306
2321
|
}), [
|
|
2307
|
-
c("span",
|
|
2308
|
-
$(
|
|
2322
|
+
c("span", Kt, [
|
|
2323
|
+
$(l.$slots, "default")
|
|
2309
2324
|
])
|
|
2310
2325
|
], 16));
|
|
2311
2326
|
}
|
|
2312
|
-
}),
|
|
2327
|
+
}), Wt = {
|
|
2313
2328
|
class: "d-flex flex-column align-items-center",
|
|
2314
2329
|
"data-cy": "stepper"
|
|
2315
|
-
},
|
|
2330
|
+
}, Zt = { class: "d-flex align-items-center justify-content-center w-100" }, Fa = /* @__PURE__ */ F({
|
|
2316
2331
|
__name: "ForgeStepper",
|
|
2317
2332
|
props: {
|
|
2318
2333
|
currentStep: { default: 0 },
|
|
@@ -2328,21 +2343,21 @@ const vt = { key: 0 }, bt = {
|
|
|
2328
2343
|
},
|
|
2329
2344
|
emits: ["update:currentStep"],
|
|
2330
2345
|
setup(e, { emit: t }) {
|
|
2331
|
-
const
|
|
2346
|
+
const l = t, o = e, a = I(o.currentStep), n = () => {
|
|
2332
2347
|
do
|
|
2333
|
-
|
|
2334
|
-
while (o.model[
|
|
2335
|
-
|
|
2336
|
-
},
|
|
2337
|
-
if (
|
|
2348
|
+
a.value--;
|
|
2349
|
+
while (o.model[a.value].disabled);
|
|
2350
|
+
l("update:currentStep", a.value);
|
|
2351
|
+
}, d = () => {
|
|
2352
|
+
if (a.value < o.model.length - 1)
|
|
2338
2353
|
do
|
|
2339
|
-
|
|
2340
|
-
while (o.model[
|
|
2341
|
-
|
|
2342
|
-
}, r =
|
|
2354
|
+
a.value++;
|
|
2355
|
+
while (o.model[a.value].disabled);
|
|
2356
|
+
l("update:currentStep", a.value);
|
|
2357
|
+
}, r = k(() => {
|
|
2343
2358
|
const p = o.model.findIndex((y) => !y.disabled);
|
|
2344
|
-
return !(p <
|
|
2345
|
-
}),
|
|
2359
|
+
return !(p < a.value && p > -1);
|
|
2360
|
+
}), u = k(() => ({
|
|
2346
2361
|
menuitem: (p) => ({
|
|
2347
2362
|
class: [{
|
|
2348
2363
|
"cursor-pointer": !p.context.disabled
|
|
@@ -2353,13 +2368,13 @@ const vt = { key: 0 }, bt = {
|
|
|
2353
2368
|
"d-flex align-items-center justify-content-center mb-2 step",
|
|
2354
2369
|
{
|
|
2355
2370
|
inactive: p.context.disabled,
|
|
2356
|
-
"bg-primary text-white": p.context.index ===
|
|
2357
|
-
"bg-brand text-white": p.context.index ===
|
|
2358
|
-
"bg-secondary text-white": p.context.index ===
|
|
2359
|
-
"bg-success text-white": p.context.index ===
|
|
2360
|
-
"bg-warning text-white": p.context.index ===
|
|
2361
|
-
"bg-danger text-white": p.context.index ===
|
|
2362
|
-
"bg-info text-white": p.context.index ===
|
|
2371
|
+
"bg-primary text-white": p.context.index === a.value && (o.severity === void 0 || o.severity === "primary"),
|
|
2372
|
+
"bg-brand text-white": p.context.index === a.value && o.severity === "brand",
|
|
2373
|
+
"bg-secondary text-white": p.context.index === a.value && o.severity === "secondary",
|
|
2374
|
+
"bg-success text-white": p.context.index === a.value && o.severity === "success",
|
|
2375
|
+
"bg-warning text-white": p.context.index === a.value && o.severity === "warning",
|
|
2376
|
+
"bg-danger text-white": p.context.index === a.value && o.severity === "danger",
|
|
2377
|
+
"bg-info text-white": p.context.index === a.value && o.severity === "info"
|
|
2363
2378
|
}
|
|
2364
2379
|
]
|
|
2365
2380
|
}),
|
|
@@ -2367,21 +2382,21 @@ const vt = { key: 0 }, bt = {
|
|
|
2367
2382
|
class: [
|
|
2368
2383
|
"h5",
|
|
2369
2384
|
{
|
|
2370
|
-
"border-bottom border-2 border-primary": p.context.index ===
|
|
2371
|
-
"border-bottom border-2 border-brand": p.context.index ===
|
|
2372
|
-
"border-bottom border-2 border-secondary": p.context.index ===
|
|
2373
|
-
"border-bottom border-2 border-success": p.context.index ===
|
|
2374
|
-
"border-bottom border-2 border-warning": p.context.index ===
|
|
2375
|
-
"border-bottom border-2 border-danger": p.context.index ===
|
|
2376
|
-
"border-bottom border-2 border-info": p.context.index ===
|
|
2385
|
+
"border-bottom border-2 border-primary": p.context.index === a.value && (o.severity === void 0 || o.severity === "primary"),
|
|
2386
|
+
"border-bottom border-2 border-brand": p.context.index === a.value && o.severity === "brand",
|
|
2387
|
+
"border-bottom border-2 border-secondary": p.context.index === a.value && o.severity === "secondary",
|
|
2388
|
+
"border-bottom border-2 border-success": p.context.index === a.value && o.severity === "success",
|
|
2389
|
+
"border-bottom border-2 border-warning": p.context.index === a.value && o.severity === "warning",
|
|
2390
|
+
"border-bottom border-2 border-danger": p.context.index === a.value && o.severity === "danger",
|
|
2391
|
+
"border-bottom border-2 border-info": p.context.index === a.value && o.severity === "info"
|
|
2377
2392
|
}
|
|
2378
2393
|
]
|
|
2379
2394
|
})
|
|
2380
2395
|
}));
|
|
2381
2396
|
return (p, y) => {
|
|
2382
|
-
const s = R, T =
|
|
2383
|
-
return i(), v("div",
|
|
2384
|
-
c("div",
|
|
2397
|
+
const s = R, T = Me, C = Pe;
|
|
2398
|
+
return i(), v("div", Wt, [
|
|
2399
|
+
c("div", Zt, [
|
|
2385
2400
|
f(s, {
|
|
2386
2401
|
severity: o.severity,
|
|
2387
2402
|
disabled: r.value,
|
|
@@ -2398,33 +2413,33 @@ const vt = { key: 0 }, bt = {
|
|
|
2398
2413
|
_: 1
|
|
2399
2414
|
}, 8, ["severity", "disabled"]),
|
|
2400
2415
|
f(T, {
|
|
2401
|
-
"active-step":
|
|
2402
|
-
"onUpdate:activeStep": y[0] || (y[0] = (
|
|
2416
|
+
"active-step": a.value,
|
|
2417
|
+
"onUpdate:activeStep": y[0] || (y[0] = (P) => a.value = P),
|
|
2403
2418
|
model: o.model,
|
|
2404
|
-
pt:
|
|
2419
|
+
pt: u.value,
|
|
2405
2420
|
readonly: !1
|
|
2406
2421
|
}, null, 8, ["active-step", "model", "pt"])
|
|
2407
2422
|
]),
|
|
2408
2423
|
f(C, { class: "m-4" }),
|
|
2409
|
-
(i(!0), v(L, null, Y(o.model, (
|
|
2410
|
-
key:
|
|
2424
|
+
(i(!0), v(L, null, Y(o.model, (P, M) => (i(), v("div", {
|
|
2425
|
+
key: M,
|
|
2411
2426
|
class: "w-100"
|
|
2412
2427
|
}, [
|
|
2413
|
-
|
|
2428
|
+
M === a.value ? $(p.$slots, P.key ?? P.label, {
|
|
2414
2429
|
key: 0,
|
|
2415
|
-
nextStep:
|
|
2430
|
+
nextStep: d,
|
|
2416
2431
|
previousStep: n
|
|
2417
2432
|
}, () => [
|
|
2418
|
-
f(
|
|
2433
|
+
f(ae, {
|
|
2419
2434
|
severity: "info",
|
|
2420
2435
|
"data-cy": "alert"
|
|
2421
2436
|
}, {
|
|
2422
2437
|
default: g(() => [
|
|
2423
|
-
O(" Please add Slot Content for the key " + h(
|
|
2438
|
+
O(" Please add Slot Content for the key " + h(P.key ?? P.label) + " ", 1),
|
|
2424
2439
|
f(s, {
|
|
2425
2440
|
severity: "primary",
|
|
2426
2441
|
label: "Next",
|
|
2427
|
-
onClick:
|
|
2442
|
+
onClick: d,
|
|
2428
2443
|
class: "ms-2"
|
|
2429
2444
|
})
|
|
2430
2445
|
]),
|
|
@@ -2435,7 +2450,7 @@ const vt = { key: 0 }, bt = {
|
|
|
2435
2450
|
]);
|
|
2436
2451
|
};
|
|
2437
2452
|
}
|
|
2438
|
-
}),
|
|
2453
|
+
}), Jt = { class: "p-4 text-wrap w-100" }, Xt = { class: "p-4 text-wrap w-100" }, _a = /* @__PURE__ */ F({
|
|
2439
2454
|
__name: "ForgeTile",
|
|
2440
2455
|
props: {
|
|
2441
2456
|
severity: { default: "primary" },
|
|
@@ -2444,20 +2459,20 @@ const vt = { key: 0 }, bt = {
|
|
|
2444
2459
|
selected: { type: Boolean, default: !1 }
|
|
2445
2460
|
},
|
|
2446
2461
|
setup(e) {
|
|
2447
|
-
const t = e,
|
|
2448
|
-
return (
|
|
2449
|
-
const
|
|
2450
|
-
return t.clickable ? (i(), w(
|
|
2462
|
+
const t = e, l = k(() => `${t.severity === void 0 ? "tile-primary" : `tile-${t.severity}`} ${t.barPosition === "none" ? "" : `tile-bar-${t.barPosition}`} ${t.selected ? "selected" : ""}`), o = k(() => `${t.severity === void 0 ? "tile-primary border-primary" : `tile-${t.severity} border-${t.severity}`} ${t.barPosition === "none" ? "" : `tile-bar-${t.barPosition}`} ${t.selected ? "selected" : ""}`);
|
|
2463
|
+
return (a, n) => {
|
|
2464
|
+
const d = R;
|
|
2465
|
+
return t.clickable ? (i(), w(d, {
|
|
2451
2466
|
key: 0,
|
|
2452
|
-
class: B(["d-flex w-100 p-0 text-body",
|
|
2467
|
+
class: B(["d-flex w-100 p-0 text-body", l.value]),
|
|
2453
2468
|
severity: t.severity,
|
|
2454
2469
|
unstyled: "",
|
|
2455
2470
|
"data-cy": "button-tile"
|
|
2456
2471
|
}, {
|
|
2457
2472
|
default: g(() => [
|
|
2458
|
-
c("div",
|
|
2459
|
-
$(
|
|
2460
|
-
O("Tile Content")
|
|
2473
|
+
c("div", Jt, [
|
|
2474
|
+
$(a.$slots, "default", {}, () => [
|
|
2475
|
+
n[0] || (n[0] = O("Tile Content"))
|
|
2461
2476
|
])
|
|
2462
2477
|
])
|
|
2463
2478
|
]),
|
|
@@ -2467,9 +2482,9 @@ const vt = { key: 0 }, bt = {
|
|
|
2467
2482
|
class: B(["d-flex w-100", o.value]),
|
|
2468
2483
|
"data-cy": "tile"
|
|
2469
2484
|
}, [
|
|
2470
|
-
c("div",
|
|
2471
|
-
$(
|
|
2472
|
-
O("Tile Content")
|
|
2485
|
+
c("div", Xt, [
|
|
2486
|
+
$(a.$slots, "default", {}, () => [
|
|
2487
|
+
n[1] || (n[1] = O("Tile Content"))
|
|
2473
2488
|
])
|
|
2474
2489
|
])
|
|
2475
2490
|
], 2));
|
|
@@ -2479,13 +2494,13 @@ const vt = { key: 0 }, bt = {
|
|
|
2479
2494
|
function X(e, t) {
|
|
2480
2495
|
return e > 1 ? `${t}s` : t;
|
|
2481
2496
|
}
|
|
2482
|
-
const
|
|
2497
|
+
const Qt = {
|
|
2483
2498
|
class: "d-flex justify-content-start align-items-baseline",
|
|
2484
2499
|
"data-cy": "pagination-header"
|
|
2485
|
-
},
|
|
2500
|
+
}, el = { class: "ms-2" }, tl = { key: 0 }, ll = {
|
|
2486
2501
|
class: "w-auto",
|
|
2487
2502
|
"data-cy": "total"
|
|
2488
|
-
},
|
|
2503
|
+
}, al = /* @__PURE__ */ F({
|
|
2489
2504
|
__name: "ForgePaginationHeader",
|
|
2490
2505
|
props: {
|
|
2491
2506
|
total: {},
|
|
@@ -2494,31 +2509,31 @@ const ta = {
|
|
|
2494
2509
|
},
|
|
2495
2510
|
emits: ["update:perPage"],
|
|
2496
2511
|
setup(e, { emit: t }) {
|
|
2497
|
-
const
|
|
2498
|
-
|
|
2499
|
-
}, n =
|
|
2500
|
-
const
|
|
2501
|
-
return `${
|
|
2512
|
+
const l = t, o = e, a = (d) => {
|
|
2513
|
+
l("update:perPage", d.value);
|
|
2514
|
+
}, n = k(() => {
|
|
2515
|
+
const d = Math.ceil(o.total / o.perPage);
|
|
2516
|
+
return `${d} ${X(d, "page")}`;
|
|
2502
2517
|
});
|
|
2503
|
-
return (
|
|
2504
|
-
O(" Number of results per page "),
|
|
2505
|
-
c("div",
|
|
2506
|
-
f(m(
|
|
2518
|
+
return (d, r) => (i(), v("div", Qt, [
|
|
2519
|
+
r[2] || (r[2] = O(" Number of results per page ")),
|
|
2520
|
+
c("div", el, [
|
|
2521
|
+
f(m(le), {
|
|
2507
2522
|
options: o.pageSizes,
|
|
2508
2523
|
"model-value": o.perPage,
|
|
2509
|
-
onChange: r[0] || (r[0] = (
|
|
2524
|
+
onChange: r[0] || (r[0] = (u) => a(u))
|
|
2510
2525
|
}, null, 8, ["options", "model-value"])
|
|
2511
2526
|
]),
|
|
2512
|
-
o.total ? (i(), v("div",
|
|
2513
|
-
|
|
2514
|
-
c("span",
|
|
2527
|
+
o.total ? (i(), v("div", tl, [
|
|
2528
|
+
r[1] || (r[1] = c("span", { class: "mx-2" }, "|", -1)),
|
|
2529
|
+
c("span", ll, h(o.total) + " " + h(m(X)(o.total, "result")) + " across " + h(n.value), 1)
|
|
2515
2530
|
])) : S("", !0)
|
|
2516
2531
|
]));
|
|
2517
2532
|
}
|
|
2518
|
-
}),
|
|
2533
|
+
}), ol = { class: "position-relative" }, nl = { "data-cy": "above-table-slot" }, sl = { class: "d-flex w-100" }, il = {
|
|
2519
2534
|
class: "mx-auto",
|
|
2520
2535
|
"data-cy": "empty-message"
|
|
2521
|
-
},
|
|
2536
|
+
}, rl = { class: "d-flex" }, dl = { class: "d-flex align-items-end mb-2" }, ul = { key: 0 }, cl = { class: "ms-auto" }, Sa = /* @__PURE__ */ F({
|
|
2522
2537
|
__name: "ForgeTable",
|
|
2523
2538
|
props: {
|
|
2524
2539
|
value: {},
|
|
@@ -2600,17 +2615,17 @@ const ta = {
|
|
|
2600
2615
|
},
|
|
2601
2616
|
emits: ["update:filters", "update:tableContext", "sort", "page"],
|
|
2602
2617
|
setup(e, { emit: t }) {
|
|
2603
|
-
const
|
|
2618
|
+
const l = t, o = e, a = I(), n = I([10, 20, 50, 100]), d = I(20), r = I({
|
|
2604
2619
|
filters: o.filters,
|
|
2605
|
-
perPage:
|
|
2620
|
+
perPage: d.value,
|
|
2606
2621
|
page: 0,
|
|
2607
2622
|
sortDirection: "None",
|
|
2608
2623
|
sortField: "",
|
|
2609
2624
|
total: o.totalRecords ?? o.value.length
|
|
2610
|
-
}),
|
|
2611
|
-
const b = Math.ceil(
|
|
2625
|
+
}), u = k(() => o.totalRecords ?? o.value.length), p = k(() => {
|
|
2626
|
+
const b = Math.ceil(u.value / d.value);
|
|
2612
2627
|
return `${b} ${X(b, "page")}`;
|
|
2613
|
-
}), y =
|
|
2628
|
+
}), y = k(() => ({
|
|
2614
2629
|
thead: () => ({
|
|
2615
2630
|
class: [
|
|
2616
2631
|
{
|
|
@@ -2638,63 +2653,63 @@ const ta = {
|
|
|
2638
2653
|
else
|
|
2639
2654
|
for (const b in o.filters)
|
|
2640
2655
|
typeof o.filters[b] == "string" ? o.filters[b] = "" : o.filters[b].value = null;
|
|
2641
|
-
|
|
2656
|
+
P(o.filters);
|
|
2642
2657
|
}, T = () => {
|
|
2643
|
-
|
|
2658
|
+
a.value.exportCSV();
|
|
2644
2659
|
}, C = (b) => {
|
|
2645
|
-
var
|
|
2646
|
-
r.value.sortDirection = b.sortOrder === 1 ? "Asc" : b.sortOrder === -1 ? "Desc" : "None", r.value.sortField = ((
|
|
2647
|
-
}, M = (b) => {
|
|
2648
|
-
r.value.filters = b, a("update:tableContext", r.value), a("update:filters", b);
|
|
2660
|
+
var x;
|
|
2661
|
+
r.value.sortDirection = b.sortOrder === 1 ? "Asc" : b.sortOrder === -1 ? "Desc" : "None", r.value.sortField = ((x = b.sortField) == null ? void 0 : x.toString()) ?? "", l("update:tableContext", r.value), l("sort", b);
|
|
2649
2662
|
}, P = (b) => {
|
|
2650
|
-
r.value.
|
|
2663
|
+
r.value.filters = b, l("update:tableContext", r.value), l("update:filters", b);
|
|
2664
|
+
}, M = (b) => {
|
|
2665
|
+
r.value.page = b.page, l("update:tableContext", r.value), l("page", b);
|
|
2651
2666
|
}, z = () => {
|
|
2652
|
-
r.value.perPage =
|
|
2667
|
+
r.value.perPage = d.value, l("update:tableContext", r.value);
|
|
2653
2668
|
};
|
|
2654
2669
|
return de(() => o.filters, (b) => {
|
|
2655
|
-
r.value.filters = b,
|
|
2656
|
-
}, { deep: !0 }), ne(() =>
|
|
2657
|
-
c("span",
|
|
2670
|
+
r.value.filters = b, l("update:tableContext", r.value);
|
|
2671
|
+
}, { deep: !0 }), ne(() => l("update:tableContext", r.value)), (b, x) => (i(), v("div", ol, [
|
|
2672
|
+
c("span", nl, [
|
|
2658
2673
|
$(b.$slots, "above-table")
|
|
2659
2674
|
]),
|
|
2660
2675
|
f(m(Ie), _({
|
|
2661
2676
|
class: ["w-100", `${o.severity ? `forge-table-${o.severity}` : ""}`]
|
|
2662
2677
|
}, { ...o, ...b.$attrs }, {
|
|
2663
2678
|
pt: y.value,
|
|
2664
|
-
rows:
|
|
2665
|
-
"total-records":
|
|
2679
|
+
rows: d.value,
|
|
2680
|
+
"total-records": u.value,
|
|
2666
2681
|
"filter-display": o.filters ? "row" : void 0,
|
|
2667
2682
|
ref_key: "forgeTable",
|
|
2668
|
-
ref:
|
|
2683
|
+
ref: a,
|
|
2669
2684
|
"data-cy": "table",
|
|
2670
|
-
"onUpdate:filters":
|
|
2685
|
+
"onUpdate:filters": P,
|
|
2671
2686
|
onSort: C,
|
|
2672
|
-
onPage:
|
|
2687
|
+
onPage: M
|
|
2673
2688
|
}), te({
|
|
2674
2689
|
empty: g(() => [
|
|
2675
|
-
c("div",
|
|
2676
|
-
c("h5",
|
|
2690
|
+
c("div", sl, [
|
|
2691
|
+
c("h5", il, h(b.emptyMessage ?? "No items Found."), 1)
|
|
2677
2692
|
])
|
|
2678
2693
|
]),
|
|
2679
2694
|
header: g(() => [
|
|
2680
2695
|
c("div", {
|
|
2681
2696
|
class: B(o.loading ? "opacity-50" : "")
|
|
2682
2697
|
}, [
|
|
2683
|
-
c("div",
|
|
2684
|
-
c("div",
|
|
2685
|
-
b.paginator && !b.legacyPaginationFooter ? (i(), v("span",
|
|
2686
|
-
f(
|
|
2687
|
-
total:
|
|
2698
|
+
c("div", rl, [
|
|
2699
|
+
c("div", dl, [
|
|
2700
|
+
b.paginator && !b.legacyPaginationFooter ? (i(), v("span", ul, [
|
|
2701
|
+
f(al, {
|
|
2702
|
+
total: u.value,
|
|
2688
2703
|
"page-sizes": n.value,
|
|
2689
|
-
"per-page":
|
|
2704
|
+
"per-page": d.value,
|
|
2690
2705
|
"onUpdate:perPage": [
|
|
2691
|
-
|
|
2706
|
+
x[0] || (x[0] = (G) => d.value = G),
|
|
2692
2707
|
z
|
|
2693
2708
|
]
|
|
2694
2709
|
}, null, 8, ["total", "page-sizes", "per-page"])
|
|
2695
2710
|
])) : S("", !0)
|
|
2696
2711
|
]),
|
|
2697
|
-
c("div",
|
|
2712
|
+
c("div", cl, [
|
|
2698
2713
|
b.showClearButton ? (i(), w(m(R), {
|
|
2699
2714
|
key: 0,
|
|
2700
2715
|
outlined: "",
|
|
@@ -2708,7 +2723,7 @@ const ta = {
|
|
|
2708
2723
|
width: "24",
|
|
2709
2724
|
height: "24"
|
|
2710
2725
|
}),
|
|
2711
|
-
O(" Clear ")
|
|
2726
|
+
x[2] || (x[2] = O(" Clear "))
|
|
2712
2727
|
]),
|
|
2713
2728
|
_: 1
|
|
2714
2729
|
}, 8, ["class"])) : S("", !0),
|
|
@@ -2724,7 +2739,7 @@ const ta = {
|
|
|
2724
2739
|
width: "24",
|
|
2725
2740
|
height: "24"
|
|
2726
2741
|
}),
|
|
2727
|
-
O(" Export ")
|
|
2742
|
+
x[3] || (x[3] = O(" Export "))
|
|
2728
2743
|
]),
|
|
2729
2744
|
_: 1
|
|
2730
2745
|
})) : S("", !0)
|
|
@@ -2750,11 +2765,11 @@ const ta = {
|
|
|
2750
2765
|
class: B(["d-flex", o.loading ? "opacity-50" : ""]),
|
|
2751
2766
|
"data-cy": "legacy-page-size"
|
|
2752
2767
|
}, [
|
|
2753
|
-
|
|
2754
|
-
f(m(
|
|
2768
|
+
x[4] || (x[4] = c("span", { class: "me-2 my-auto text-nowrap" }, "Page Size:", -1)),
|
|
2769
|
+
f(m(le), {
|
|
2755
2770
|
options: n.value,
|
|
2756
|
-
modelValue:
|
|
2757
|
-
"onUpdate:modelValue":
|
|
2771
|
+
modelValue: d.value,
|
|
2772
|
+
"onUpdate:modelValue": x[1] || (x[1] = (G) => d.value = G),
|
|
2758
2773
|
class: "ms-2",
|
|
2759
2774
|
onClick: z
|
|
2760
2775
|
}, null, 8, ["options", "modelValue"])
|
|
@@ -2768,14 +2783,14 @@ const ta = {
|
|
|
2768
2783
|
c("span", {
|
|
2769
2784
|
"data-cy": "legacy-total",
|
|
2770
2785
|
class: B(o.loading ? "opacity-50" : "")
|
|
2771
|
-
}, h(
|
|
2786
|
+
}, h(u.value) + " " + h(m(X)(u.value, "result")) + " across " + h(p.value), 3)
|
|
2772
2787
|
]),
|
|
2773
2788
|
key: "1"
|
|
2774
2789
|
} : void 0
|
|
2775
2790
|
]), 1040, ["class", "pt", "rows", "total-records", "filter-display"])
|
|
2776
2791
|
]));
|
|
2777
2792
|
}
|
|
2778
|
-
}),
|
|
2793
|
+
}), ml = { class: "d-flex position-relative" }, pl = { class: "d-flex w-100" }, yl = { class: "d-flex w-100" }, Va = /* @__PURE__ */ F({
|
|
2779
2794
|
__name: "ForgeFilterHeader",
|
|
2780
2795
|
props: /* @__PURE__ */ E({
|
|
2781
2796
|
dataType: {},
|
|
@@ -2790,49 +2805,49 @@ const ta = {
|
|
|
2790
2805
|
}),
|
|
2791
2806
|
emits: ["update:modelValue"],
|
|
2792
2807
|
setup(e) {
|
|
2793
|
-
const t = A(e, "modelValue"),
|
|
2794
|
-
if (!
|
|
2808
|
+
const t = A(e, "modelValue"), l = (a, n) => {
|
|
2809
|
+
if (!a || Array.isArray(a) && a.length === 0)
|
|
2795
2810
|
return n;
|
|
2796
|
-
const
|
|
2811
|
+
const d = (r) => {
|
|
2797
2812
|
var p;
|
|
2798
|
-
const
|
|
2813
|
+
const u = (p = e.dropdownOptions) == null ? void 0 : p.find(
|
|
2799
2814
|
(y) => e.optionValue ? y[e.optionValue] === r : Object.keys(y).every((s) => r.hasOwnProperty(s) && y[s] === r[s])
|
|
2800
2815
|
);
|
|
2801
|
-
return e.optionLabel ?
|
|
2816
|
+
return e.optionLabel ? u[e.optionLabel] : u;
|
|
2802
2817
|
};
|
|
2803
|
-
return Array.isArray(
|
|
2818
|
+
return Array.isArray(a) ? a.map(d).join(", ") : d(a);
|
|
2804
2819
|
}, o = () => {
|
|
2805
2820
|
e.clearFilter ? e.clearFilter() : t.value = null;
|
|
2806
2821
|
};
|
|
2807
|
-
return (
|
|
2808
|
-
const
|
|
2809
|
-
return i(), v("div",
|
|
2810
|
-
|
|
2822
|
+
return (a, n) => {
|
|
2823
|
+
const d = ue, r = R;
|
|
2824
|
+
return i(), v("div", ml, [
|
|
2825
|
+
a.dataType === "numeric" ? (i(), w(d, _({
|
|
2811
2826
|
key: 0,
|
|
2812
2827
|
modelValue: t.value,
|
|
2813
|
-
"onUpdate:modelValue": n[0] || (n[0] = (
|
|
2814
|
-
},
|
|
2828
|
+
"onUpdate:modelValue": n[0] || (n[0] = (u) => t.value = u)
|
|
2829
|
+
}, a.$attrs), null, 16, ["modelValue"])) : a.dataType === "date" ? (i(), w(ye, _({
|
|
2815
2830
|
key: 1,
|
|
2816
2831
|
modelValue: t.value,
|
|
2817
|
-
"onUpdate:modelValue": n[1] || (n[1] = (
|
|
2818
|
-
},
|
|
2832
|
+
"onUpdate:modelValue": n[1] || (n[1] = (u) => t.value = u)
|
|
2833
|
+
}, a.$attrs, {
|
|
2819
2834
|
"show-icon": !1,
|
|
2820
2835
|
"show-on-focus": !0
|
|
2821
|
-
}), null, 16, ["modelValue"])) :
|
|
2836
|
+
}), null, 16, ["modelValue"])) : a.dataType === "select" ? (i(), w(m(le), _({
|
|
2822
2837
|
key: 2,
|
|
2823
2838
|
modelValue: t.value,
|
|
2824
|
-
"onUpdate:modelValue": n[2] || (n[2] = (
|
|
2825
|
-
},
|
|
2826
|
-
options:
|
|
2827
|
-
"option-value":
|
|
2828
|
-
"option-label":
|
|
2839
|
+
"onUpdate:modelValue": n[2] || (n[2] = (u) => t.value = u)
|
|
2840
|
+
}, a.$attrs, {
|
|
2841
|
+
options: a.dropdownOptions,
|
|
2842
|
+
"option-value": a.optionValue,
|
|
2843
|
+
"option-label": a.optionLabel
|
|
2829
2844
|
}), {
|
|
2830
|
-
value: g(({ value:
|
|
2831
|
-
c("div",
|
|
2845
|
+
value: g(({ value: u, placeholder: p }) => [
|
|
2846
|
+
c("div", pl, [
|
|
2832
2847
|
c("span", {
|
|
2833
|
-
class: B({ "filter-placeholder":
|
|
2834
|
-
}, h(
|
|
2835
|
-
|
|
2848
|
+
class: B({ "filter-placeholder": u === null })
|
|
2849
|
+
}, h(l(u, p)), 3),
|
|
2850
|
+
a.showClearButton && t.value !== null ? (i(), w(r, {
|
|
2836
2851
|
key: 0,
|
|
2837
2852
|
onClick: q(o, ["prevent"]),
|
|
2838
2853
|
size: "small",
|
|
@@ -2851,23 +2866,23 @@ const ta = {
|
|
|
2851
2866
|
])
|
|
2852
2867
|
]),
|
|
2853
2868
|
_: 1
|
|
2854
|
-
}, 16, ["modelValue", "options", "option-value", "option-label"])) :
|
|
2869
|
+
}, 16, ["modelValue", "options", "option-value", "option-label"])) : a.dataType === "multiselect" ? (i(), w(m(ze), _({
|
|
2855
2870
|
key: 3,
|
|
2856
2871
|
modelValue: t.value,
|
|
2857
|
-
"onUpdate:modelValue": n[3] || (n[3] = (
|
|
2858
|
-
},
|
|
2859
|
-
options:
|
|
2872
|
+
"onUpdate:modelValue": n[3] || (n[3] = (u) => t.value = u)
|
|
2873
|
+
}, a.$attrs, {
|
|
2874
|
+
options: a.dropdownOptions,
|
|
2860
2875
|
showToggleAll: !1,
|
|
2861
|
-
"option-label":
|
|
2862
|
-
"option-value":
|
|
2876
|
+
"option-label": a.optionLabel,
|
|
2877
|
+
"option-value": a.optionValue,
|
|
2863
2878
|
filter: ""
|
|
2864
2879
|
}), {
|
|
2865
|
-
value: g(({ value:
|
|
2866
|
-
c("div",
|
|
2880
|
+
value: g(({ value: u, placeholder: p }) => [
|
|
2881
|
+
c("div", yl, [
|
|
2867
2882
|
c("span", {
|
|
2868
|
-
class: B({ "filter-placeholder": (
|
|
2869
|
-
}, h(
|
|
2870
|
-
|
|
2883
|
+
class: B({ "filter-placeholder": (u == null ? void 0 : u.length) === 0 || u === null })
|
|
2884
|
+
}, h(l(u, p)), 3),
|
|
2885
|
+
a.showClearButton && (u == null ? void 0 : u.length) > 0 ? (i(), w(r, {
|
|
2871
2886
|
key: 0,
|
|
2872
2887
|
onClick: q(o, ["prevent"]),
|
|
2873
2888
|
size: "small",
|
|
@@ -2889,9 +2904,9 @@ const ta = {
|
|
|
2889
2904
|
}, 16, ["modelValue", "options", "option-label", "option-value"])) : (i(), w(m(ie), _({
|
|
2890
2905
|
key: 4,
|
|
2891
2906
|
modelValue: t.value,
|
|
2892
|
-
"onUpdate:modelValue": n[4] || (n[4] = (
|
|
2893
|
-
},
|
|
2894
|
-
|
|
2907
|
+
"onUpdate:modelValue": n[4] || (n[4] = (u) => t.value = u)
|
|
2908
|
+
}, a.$attrs), null, 16, ["modelValue"])),
|
|
2909
|
+
a.showClearButton && t.value !== null && a.dataType !== "select" && a.dataType !== "multiselect" && a.dataType !== "date" ? (i(), w(r, {
|
|
2895
2910
|
key: 5,
|
|
2896
2911
|
onClick: q(o, ["prevent"]),
|
|
2897
2912
|
size: "small",
|
|
@@ -2911,48 +2926,48 @@ const ta = {
|
|
|
2911
2926
|
};
|
|
2912
2927
|
}
|
|
2913
2928
|
});
|
|
2914
|
-
function ve(e, t,
|
|
2915
|
-
const
|
|
2929
|
+
function ve(e, t, l, o) {
|
|
2930
|
+
const a = t.flatMap((n) => n.file);
|
|
2916
2931
|
return t = t.map((n) => ({ ...n, status: n.status == "Duplicate" ? "Not Uploaded" : n.status })), e.forEach((n) => {
|
|
2917
|
-
const
|
|
2932
|
+
const d = a.findIndex((u) => u.name === n.name);
|
|
2918
2933
|
let r = "Not Uploaded";
|
|
2919
|
-
|
|
2934
|
+
d === -1 ? ((!l.includes(n.type) || !(n.size <= o)) && (r = l.includes(n.type) ? "InvalidFileSize" : "InvalidFileType"), t.unshift({
|
|
2920
2935
|
file: n,
|
|
2921
2936
|
status: r,
|
|
2922
2937
|
blobFileName: null
|
|
2923
|
-
})) : t[
|
|
2938
|
+
})) : t[d].status = "Duplicate";
|
|
2924
2939
|
}), t;
|
|
2925
2940
|
}
|
|
2926
|
-
async function
|
|
2941
|
+
async function vl(e, t) {
|
|
2927
2942
|
if (e === "Uploaded" && t !== null)
|
|
2928
2943
|
try {
|
|
2929
2944
|
await new ce(t).delete();
|
|
2930
|
-
} catch (
|
|
2931
|
-
if (
|
|
2945
|
+
} catch (l) {
|
|
2946
|
+
if (l !== "BlobNotFound") {
|
|
2932
2947
|
e = "DeleteFileFailed";
|
|
2933
2948
|
return;
|
|
2934
2949
|
}
|
|
2935
2950
|
}
|
|
2936
2951
|
}
|
|
2937
|
-
function re(e, t = !0,
|
|
2952
|
+
function re(e, t = !0, l = 1) {
|
|
2938
2953
|
const o = t ? 1e3 : 1024;
|
|
2939
2954
|
if (Math.abs(e) < o)
|
|
2940
2955
|
return e + " B";
|
|
2941
|
-
const
|
|
2956
|
+
const a = t ? ["kB", "MB", "GB", "TB", "PB", "EB", "ZB", "YB"] : ["KiB", "MiB", "GiB", "TiB", "PiB", "EiB", "ZiB", "YiB"];
|
|
2942
2957
|
let n = -1;
|
|
2943
|
-
const
|
|
2958
|
+
const d = 10 ** l;
|
|
2944
2959
|
do
|
|
2945
2960
|
e /= o, ++n;
|
|
2946
|
-
while (Math.round(Math.abs(e) *
|
|
2947
|
-
return e.toFixed(
|
|
2961
|
+
while (Math.round(Math.abs(e) * d) / d >= o && n < a.length - 1);
|
|
2962
|
+
return e.toFixed(l) + " " + a[n];
|
|
2948
2963
|
}
|
|
2949
|
-
function
|
|
2964
|
+
function bl(e) {
|
|
2950
2965
|
return ["image/gif", "image/png", "image/jpeg", "image/svg"].includes(e);
|
|
2951
2966
|
}
|
|
2952
|
-
function
|
|
2967
|
+
function fl(e) {
|
|
2953
2968
|
return URL.createObjectURL(e);
|
|
2954
2969
|
}
|
|
2955
|
-
const
|
|
2970
|
+
const gl = { class: "d-flex justify-content-between" }, hl = ["accept", "disabled", "multiple"], wl = /* @__PURE__ */ F({
|
|
2956
2971
|
__name: "UploadButton",
|
|
2957
2972
|
props: /* @__PURE__ */ E({
|
|
2958
2973
|
acceptedFileTypes: {},
|
|
@@ -2964,52 +2979,52 @@ const ka = { class: "d-flex justify-content-between" }, $a = ["accept", "disable
|
|
|
2964
2979
|
}),
|
|
2965
2980
|
emits: ["update:modelValue"],
|
|
2966
2981
|
setup(e) {
|
|
2967
|
-
const t = A(e, "modelValue"),
|
|
2968
|
-
t.value = ve(
|
|
2982
|
+
const t = A(e, "modelValue"), l = k(() => e.maxFileInput <= t.value.length), o = (a) => {
|
|
2983
|
+
t.value = ve(a, t.value, e.acceptedFileTypes, e.maxFileInput);
|
|
2969
2984
|
};
|
|
2970
|
-
return (
|
|
2971
|
-
$(
|
|
2985
|
+
return (a, n) => (i(), v("div", gl, [
|
|
2986
|
+
$(a.$slots, "message"),
|
|
2972
2987
|
c("div", null, [
|
|
2973
2988
|
c("input", {
|
|
2974
2989
|
id: "file-input",
|
|
2975
2990
|
type: "file",
|
|
2976
2991
|
class: "d-none",
|
|
2977
|
-
accept:
|
|
2978
|
-
disabled:
|
|
2979
|
-
multiple:
|
|
2980
|
-
onInput: n[0] || (n[0] = (
|
|
2981
|
-
}, null, 40,
|
|
2992
|
+
accept: a.acceptedFileTypes.join(", "),
|
|
2993
|
+
disabled: l.value,
|
|
2994
|
+
multiple: a.maxFileInput > 1,
|
|
2995
|
+
onInput: n[0] || (n[0] = (d) => o([...d.target.files]))
|
|
2996
|
+
}, null, 40, hl),
|
|
2982
2997
|
c("label", {
|
|
2983
|
-
class: B([{ disabled:
|
|
2998
|
+
class: B([{ disabled: l.value }, "btn btn-primary"]),
|
|
2984
2999
|
id: "file-input-button",
|
|
2985
3000
|
for: "file-input"
|
|
2986
3001
|
}, [
|
|
2987
|
-
$(
|
|
3002
|
+
$(a.$slots, "button-content", {}, () => [
|
|
2988
3003
|
f(m(V), {
|
|
2989
3004
|
icon: "bi:upload",
|
|
2990
3005
|
class: "me-2",
|
|
2991
3006
|
height: "20px",
|
|
2992
3007
|
width: "20px"
|
|
2993
3008
|
}),
|
|
2994
|
-
O(" Browse your computer ")
|
|
3009
|
+
n[1] || (n[1] = O(" Browse your computer "))
|
|
2995
3010
|
])
|
|
2996
3011
|
], 2)
|
|
2997
3012
|
]),
|
|
2998
|
-
|
|
3013
|
+
a.showDragDropArea ? (i(), v("div", {
|
|
2999
3014
|
class: "ms-auto",
|
|
3000
|
-
key:
|
|
3015
|
+
key: a.acceptedFileTypes.length,
|
|
3001
3016
|
id: "accepted-file-types"
|
|
3002
|
-
}, "Accepted File Types: " + h(
|
|
3017
|
+
}, "Accepted File Types: " + h(a.acceptedFileTypes.map((d) => d.split("/").pop()).join(", ")), 1)) : S("", !0)
|
|
3003
3018
|
]));
|
|
3004
3019
|
}
|
|
3005
|
-
}),
|
|
3020
|
+
}), xl = {
|
|
3006
3021
|
key: 0,
|
|
3007
3022
|
class: "py-4 px-3",
|
|
3008
3023
|
id: "placeholder-message"
|
|
3009
|
-
},
|
|
3024
|
+
}, kl = {
|
|
3010
3025
|
key: 1,
|
|
3011
3026
|
class: "d-flex flex-column"
|
|
3012
|
-
},
|
|
3027
|
+
}, $l = /* @__PURE__ */ F({
|
|
3013
3028
|
__name: "DragDropArea",
|
|
3014
3029
|
props: /* @__PURE__ */ E({
|
|
3015
3030
|
maxFileInput: {},
|
|
@@ -3021,30 +3036,30 @@ const ka = { class: "d-flex justify-content-between" }, $a = ["accept", "disable
|
|
|
3021
3036
|
}),
|
|
3022
3037
|
emits: ["update:modelValue"],
|
|
3023
3038
|
setup(e) {
|
|
3024
|
-
const t = A(e, "modelValue"),
|
|
3025
|
-
|
|
3039
|
+
const t = A(e, "modelValue"), l = I(!1), o = k(() => e.maxFileInput <= t.value.length), a = (n) => {
|
|
3040
|
+
l.value = !1, n.dataTransfer.files.length > e.maxFileInput || o.value ? n.preventDefault() : t.value = ve([...n.dataTransfer.files], t.value, e.acceptedFileTypes, e.maxFileSize);
|
|
3026
3041
|
};
|
|
3027
|
-
return (n,
|
|
3042
|
+
return (n, d) => (i(), v("div", {
|
|
3028
3043
|
id: "drag-drop-area",
|
|
3029
|
-
class: B(`${
|
|
3030
|
-
onDragleave:
|
|
3031
|
-
onDragover:
|
|
3032
|
-
onDrop: q(
|
|
3044
|
+
class: B(`${l.value ? "border-2 border-primary bg-body-tertiary" : ""} mt-3 file-container border-dashed border-2`),
|
|
3045
|
+
onDragleave: d[0] || (d[0] = q((r) => l.value = !1, ["prevent"])),
|
|
3046
|
+
onDragover: d[1] || (d[1] = q((r) => l.value = !0, ["prevent"])),
|
|
3047
|
+
onDrop: q(a, ["prevent"])
|
|
3033
3048
|
}, [
|
|
3034
|
-
t.value.length === 0 ? (i(), v("div",
|
|
3049
|
+
t.value.length === 0 ? (i(), v("div", xl, [
|
|
3035
3050
|
f(m(V), {
|
|
3036
3051
|
icon: "bi:upload",
|
|
3037
3052
|
class: "me-2",
|
|
3038
3053
|
height: "20px",
|
|
3039
3054
|
width: "20px"
|
|
3040
3055
|
}),
|
|
3041
|
-
O(" Drag and drop files here ")
|
|
3042
|
-
])) : (i(), v("div",
|
|
3056
|
+
d[2] || (d[2] = O(" Drag and drop files here "))
|
|
3057
|
+
])) : (i(), v("div", kl, [
|
|
3043
3058
|
$(n.$slots, "default")
|
|
3044
3059
|
]))
|
|
3045
3060
|
], 34));
|
|
3046
3061
|
}
|
|
3047
|
-
}),
|
|
3062
|
+
}), Bl = { class: "d-flex align-items-center me-2" }, Fl = /* @__PURE__ */ F({
|
|
3048
3063
|
__name: "UploadStatus",
|
|
3049
3064
|
props: {
|
|
3050
3065
|
fileSize: {},
|
|
@@ -3053,7 +3068,7 @@ const ka = { class: "d-flex justify-content-between" }, $a = ["accept", "disable
|
|
|
3053
3068
|
uploadStatus: {}
|
|
3054
3069
|
},
|
|
3055
3070
|
setup(e) {
|
|
3056
|
-
const t =
|
|
3071
|
+
const t = k(() => e.uploadStatus === "Failed" || e.uploadStatus === "InvalidFileType" || e.uploadStatus === "InvalidFileSize" ? "danger" : "warning"), l = k(() => {
|
|
3057
3072
|
switch (e.uploadStatus) {
|
|
3058
3073
|
case "InvalidFileType":
|
|
3059
3074
|
return "Upload Failed: File type is not accepted.";
|
|
@@ -3069,8 +3084,8 @@ const ka = { class: "d-flex justify-content-between" }, $a = ["accept", "disable
|
|
|
3069
3084
|
return "Upload Failed: Connection error, please try again.";
|
|
3070
3085
|
}
|
|
3071
3086
|
});
|
|
3072
|
-
return (o,
|
|
3073
|
-
o.uploadStatus === "Uploading" ? (i(), w(
|
|
3087
|
+
return (o, a) => (i(), v("div", Bl, [
|
|
3088
|
+
o.uploadStatus === "Uploading" ? (i(), w(Gt, {
|
|
3074
3089
|
key: 0,
|
|
3075
3090
|
pixelWidth: 200,
|
|
3076
3091
|
animate: "",
|
|
@@ -3081,29 +3096,29 @@ const ka = { class: "d-flex justify-content-between" }, $a = ["accept", "disable
|
|
|
3081
3096
|
]),
|
|
3082
3097
|
_: 1
|
|
3083
3098
|
})) : S("", !0),
|
|
3084
|
-
o.uploadStatus !== "Uploading" && o.uploadStatus !== "Not Uploaded" && o.uploadStatus !== "Uploaded" && o.uploadStatus !== "Preparing" ? (i(), w(
|
|
3099
|
+
o.uploadStatus !== "Uploading" && o.uploadStatus !== "Not Uploaded" && o.uploadStatus !== "Uploaded" && o.uploadStatus !== "Preparing" ? (i(), w(ae, {
|
|
3085
3100
|
key: 1,
|
|
3086
3101
|
id: "upload-status-alert",
|
|
3087
3102
|
severity: t.value,
|
|
3088
3103
|
class: "mb-0 w-75 ms-auto"
|
|
3089
3104
|
}, {
|
|
3090
3105
|
default: g(() => [
|
|
3091
|
-
O(h(
|
|
3106
|
+
O(h(l.value), 1)
|
|
3092
3107
|
]),
|
|
3093
3108
|
_: 1
|
|
3094
3109
|
}, 8, ["severity"])) : S("", !0)
|
|
3095
3110
|
]));
|
|
3096
3111
|
}
|
|
3097
|
-
}),
|
|
3112
|
+
}), _l = ["data-cy"], Sl = { class: "ms-3 d-flex flex-column" }, Vl = {
|
|
3098
3113
|
key: 1,
|
|
3099
3114
|
id: "file-name"
|
|
3100
|
-
},
|
|
3115
|
+
}, Cl = {
|
|
3101
3116
|
class: "text-black-50",
|
|
3102
3117
|
id: "file-type"
|
|
3103
|
-
},
|
|
3118
|
+
}, Tl = {
|
|
3104
3119
|
class: "text-black-50",
|
|
3105
3120
|
id: "file-size"
|
|
3106
|
-
},
|
|
3121
|
+
}, Pl = { class: "ms-auto my-auto d-flex" }, Ml = /* @__PURE__ */ F({
|
|
3107
3122
|
__name: "FileInfo",
|
|
3108
3123
|
props: /* @__PURE__ */ E({
|
|
3109
3124
|
editableFileName: { type: Boolean },
|
|
@@ -3122,52 +3137,52 @@ const ka = { class: "d-flex justify-content-between" }, $a = ["accept", "disable
|
|
|
3122
3137
|
}),
|
|
3123
3138
|
emits: /* @__PURE__ */ E(["deleted"], ["update:file", "update:blobFileName", "update:uploadStatus"]),
|
|
3124
3139
|
setup(e, { emit: t }) {
|
|
3125
|
-
const
|
|
3126
|
-
|
|
3140
|
+
const l = A(e, "file"), o = A(e, "blobFileName"), a = A(e, "uploadStatus"), n = t, d = I(l.value.name), r = I(""), u = I(0), p = I(), y = k(() => e.acceptedFileTypes.includes(l.value.type)), s = k(() => l.value.size <= e.maxFileSize), T = () => {
|
|
3141
|
+
l.value = new File([l.value], d.value, { type: l.value.type, lastModified: (/* @__PURE__ */ new Date()).valueOf() });
|
|
3127
3142
|
}, C = async () => {
|
|
3128
3143
|
if (!y.value || !s.value) {
|
|
3129
|
-
|
|
3144
|
+
a.value = y.value ? "InvalidFileSize" : "InvalidFileType";
|
|
3130
3145
|
return;
|
|
3131
3146
|
}
|
|
3132
|
-
|
|
3133
|
-
const [
|
|
3134
|
-
if (!
|
|
3135
|
-
|
|
3147
|
+
a.value = "Preparing", p.value = new AbortController();
|
|
3148
|
+
const [M, z] = await e.getFileUrlAction(l.value.name);
|
|
3149
|
+
if (!M) {
|
|
3150
|
+
a.value = "Failed";
|
|
3136
3151
|
return;
|
|
3137
3152
|
}
|
|
3138
3153
|
try {
|
|
3139
|
-
|
|
3140
|
-
const b = new ce(
|
|
3154
|
+
a.value = "Uploading";
|
|
3155
|
+
const b = new ce(M), x = {
|
|
3141
3156
|
abortSignal: p.value.signal,
|
|
3142
|
-
onProgress: (G) =>
|
|
3157
|
+
onProgress: (G) => u.value = G.loadedBytes,
|
|
3143
3158
|
tags: { temp: "true" }
|
|
3144
3159
|
};
|
|
3145
|
-
await b.uploadData(
|
|
3160
|
+
await b.uploadData(l.value, x), r.value = M, a.value = "Uploaded", o.value = z;
|
|
3146
3161
|
} catch (b) {
|
|
3147
3162
|
if (b.name === "AbortError") {
|
|
3148
|
-
|
|
3163
|
+
a.value = "Aborted";
|
|
3149
3164
|
return;
|
|
3150
3165
|
}
|
|
3151
|
-
|
|
3166
|
+
a.value = "Failed";
|
|
3152
3167
|
}
|
|
3153
|
-
},
|
|
3154
|
-
await
|
|
3168
|
+
}, P = async () => {
|
|
3169
|
+
await vl(a.value, r.value), n("deleted", l.value);
|
|
3155
3170
|
};
|
|
3156
3171
|
return ne(() => {
|
|
3157
3172
|
e.autoUploadToBlob && C();
|
|
3158
|
-
}), (
|
|
3173
|
+
}), (M, z) => {
|
|
3159
3174
|
const b = R;
|
|
3160
3175
|
return i(), v("div", {
|
|
3161
3176
|
class: "py-4 px-3 d-flex",
|
|
3162
|
-
"data-cy": `file-info-${
|
|
3177
|
+
"data-cy": `file-info-${l.value.name}`
|
|
3163
3178
|
}, [
|
|
3164
3179
|
c("div", null, [
|
|
3165
|
-
m(
|
|
3180
|
+
m(bl)(l.value.type) ? (i(), w(m(Oe), {
|
|
3166
3181
|
key: 0,
|
|
3167
3182
|
id: "thumbnail-image",
|
|
3168
3183
|
"image-class": "image-file-thumbnail border",
|
|
3169
|
-
src: m(
|
|
3170
|
-
alt:
|
|
3184
|
+
src: m(fl)(l.value),
|
|
3185
|
+
alt: l.value.name,
|
|
3171
3186
|
width: "75px",
|
|
3172
3187
|
preview: ""
|
|
3173
3188
|
}, null, 8, ["src", "alt"])) : (i(), w(m(V), {
|
|
@@ -3178,45 +3193,45 @@ const ka = { class: "d-flex justify-content-between" }, $a = ["accept", "disable
|
|
|
3178
3193
|
width: "75px"
|
|
3179
3194
|
}))
|
|
3180
3195
|
]),
|
|
3181
|
-
c("div",
|
|
3196
|
+
c("div", Sl, [
|
|
3182
3197
|
c("div", null, [
|
|
3183
|
-
|
|
3198
|
+
M.editableFileName ? (i(), w($t, {
|
|
3184
3199
|
key: 0,
|
|
3185
3200
|
id: "edit-file-name",
|
|
3186
|
-
modelValue:
|
|
3187
|
-
"onUpdate:modelValue": z[0] || (z[0] = (
|
|
3188
|
-
rules:
|
|
3189
|
-
name:
|
|
3201
|
+
modelValue: d.value,
|
|
3202
|
+
"onUpdate:modelValue": z[0] || (z[0] = (x) => d.value = x),
|
|
3203
|
+
rules: M.customFileNameRules,
|
|
3204
|
+
name: l.value.name,
|
|
3190
3205
|
"complete-action": T
|
|
3191
|
-
}, null, 8, ["modelValue", "rules", "name"])) : (i(), v("span",
|
|
3206
|
+
}, null, 8, ["modelValue", "rules", "name"])) : (i(), v("span", Vl, h(l.value.name), 1))
|
|
3192
3207
|
]),
|
|
3193
|
-
c("span",
|
|
3194
|
-
c("span",
|
|
3208
|
+
c("span", Cl, "File type: " + h(l.value.type.split("/").pop()), 1),
|
|
3209
|
+
c("span", Tl, "File size: " + h(m(re)(l.value.size)), 1)
|
|
3195
3210
|
]),
|
|
3196
|
-
c("div",
|
|
3197
|
-
(i(), w(
|
|
3198
|
-
key:
|
|
3199
|
-
"file-size":
|
|
3200
|
-
"upload-status":
|
|
3201
|
-
"bytes-uploaded":
|
|
3202
|
-
"max-file-size":
|
|
3211
|
+
c("div", Pl, [
|
|
3212
|
+
(i(), w(Fl, {
|
|
3213
|
+
key: a.value,
|
|
3214
|
+
"file-size": l.value.size,
|
|
3215
|
+
"upload-status": a.value,
|
|
3216
|
+
"bytes-uploaded": u.value,
|
|
3217
|
+
"max-file-size": M.maxFileSize
|
|
3203
3218
|
}, null, 8, ["file-size", "upload-status", "bytes-uploaded", "max-file-size"])),
|
|
3204
|
-
|
|
3219
|
+
a.value === "Not Uploaded" || a.value === "Failed" || a.value === "Duplicate" || a.value === "Aborted" ? (i(), w(b, {
|
|
3205
3220
|
key: 0,
|
|
3206
3221
|
link: "",
|
|
3207
3222
|
onClick: C
|
|
3208
3223
|
}, {
|
|
3209
3224
|
default: g(() => [
|
|
3210
3225
|
f(m(V), {
|
|
3211
|
-
icon:
|
|
3226
|
+
icon: a.value === "Not Uploaded" || a.value === "Duplicate" ? "bi:upload" : "bi:arrow-clockwise"
|
|
3212
3227
|
}, null, 8, ["icon"])
|
|
3213
3228
|
]),
|
|
3214
3229
|
_: 1
|
|
3215
3230
|
})) : S("", !0),
|
|
3216
|
-
|
|
3231
|
+
a.value === "Uploading" ? (i(), w(b, {
|
|
3217
3232
|
key: 1,
|
|
3218
3233
|
link: "",
|
|
3219
|
-
onClick: z[1] || (z[1] = (
|
|
3234
|
+
onClick: z[1] || (z[1] = (x) => p.value.value.abort())
|
|
3220
3235
|
}, {
|
|
3221
3236
|
default: g(() => [
|
|
3222
3237
|
f(m(V), { icon: "bi:x-circle-fill" })
|
|
@@ -3225,7 +3240,7 @@ const ka = { class: "d-flex justify-content-between" }, $a = ["accept", "disable
|
|
|
3225
3240
|
})) : (i(), w(b, {
|
|
3226
3241
|
key: 2,
|
|
3227
3242
|
link: "",
|
|
3228
|
-
onClick:
|
|
3243
|
+
onClick: P,
|
|
3229
3244
|
id: "delete-button"
|
|
3230
3245
|
}, {
|
|
3231
3246
|
default: g(() => [
|
|
@@ -3234,20 +3249,20 @@ const ka = { class: "d-flex justify-content-between" }, $a = ["accept", "disable
|
|
|
3234
3249
|
_: 1
|
|
3235
3250
|
}))
|
|
3236
3251
|
])
|
|
3237
|
-
], 8,
|
|
3252
|
+
], 8, _l);
|
|
3238
3253
|
};
|
|
3239
3254
|
}
|
|
3240
|
-
}),
|
|
3255
|
+
}), Il = { class: "d-flex justify-content-end mt-1" }, zl = { id: "max-file-size" }, Ol = /* @__PURE__ */ F({
|
|
3241
3256
|
__name: "MaxFileSize",
|
|
3242
3257
|
props: {
|
|
3243
3258
|
maxFileSize: {}
|
|
3244
3259
|
},
|
|
3245
3260
|
setup(e) {
|
|
3246
|
-
return (t,
|
|
3247
|
-
c("div",
|
|
3261
|
+
return (t, l) => (i(), v("div", Il, [
|
|
3262
|
+
c("div", zl, "Max file size: " + h(m(re)(t.maxFileSize)), 1)
|
|
3248
3263
|
]));
|
|
3249
3264
|
}
|
|
3250
|
-
}),
|
|
3265
|
+
}), Dl = { "data-cy": "file-uploader" }, Ul = { key: 0 }, Ca = /* @__PURE__ */ F({
|
|
3251
3266
|
__name: "ForgeFileUploader",
|
|
3252
3267
|
props: /* @__PURE__ */ E({
|
|
3253
3268
|
acceptedFileTypes: {},
|
|
@@ -3264,72 +3279,72 @@ const ka = { class: "d-flex justify-content-between" }, $a = ["accept", "disable
|
|
|
3264
3279
|
}),
|
|
3265
3280
|
emits: ["update:modelValue"],
|
|
3266
3281
|
setup(e) {
|
|
3267
|
-
const t = A(e, "modelValue"),
|
|
3268
|
-
t.value = t.value.filter((n) => n.file !=
|
|
3282
|
+
const t = A(e, "modelValue"), l = e, o = (a) => {
|
|
3283
|
+
t.value = t.value.filter((n) => n.file != a);
|
|
3269
3284
|
};
|
|
3270
|
-
return (
|
|
3271
|
-
f(
|
|
3285
|
+
return (a, n) => (i(), v("div", Dl, [
|
|
3286
|
+
f(wl, _(l, {
|
|
3272
3287
|
modelValue: t.value,
|
|
3273
|
-
"onUpdate:modelValue": n[0] || (n[0] = (
|
|
3288
|
+
"onUpdate:modelValue": n[0] || (n[0] = (d) => t.value = d)
|
|
3274
3289
|
}), null, 16, ["modelValue"]),
|
|
3275
|
-
|
|
3276
|
-
f(
|
|
3277
|
-
"max-file-input":
|
|
3278
|
-
"max-file-size":
|
|
3279
|
-
"accepted-file-types":
|
|
3290
|
+
a.showDragDropArea ? (i(), v("div", Ul, [
|
|
3291
|
+
f($l, {
|
|
3292
|
+
"max-file-input": l.maxFileInput,
|
|
3293
|
+
"max-file-size": l.maxFileSize,
|
|
3294
|
+
"accepted-file-types": l.acceptedFileTypes,
|
|
3280
3295
|
modelValue: t.value,
|
|
3281
|
-
"onUpdate:modelValue": n[1] || (n[1] = (
|
|
3296
|
+
"onUpdate:modelValue": n[1] || (n[1] = (d) => t.value = d)
|
|
3282
3297
|
}, {
|
|
3283
3298
|
default: g(() => [
|
|
3284
|
-
(i(!0), v(L, null, Y(t.value, ({ file:
|
|
3285
|
-
(i(), w(
|
|
3286
|
-
key:
|
|
3299
|
+
(i(!0), v(L, null, Y(t.value, ({ file: d }, r) => (i(), v("span", null, [
|
|
3300
|
+
(i(), w(Ml, _({
|
|
3301
|
+
key: d.name,
|
|
3287
3302
|
class: r === t.value.length - 1 || t.value.length == 1 ? "" : "border-bottom",
|
|
3288
3303
|
file: t.value[r].file,
|
|
3289
|
-
"onUpdate:file": (
|
|
3304
|
+
"onUpdate:file": (u) => t.value[r].file = u,
|
|
3290
3305
|
"blob-file-name": t.value[r].blobFileName,
|
|
3291
|
-
"onUpdate:blobFileName": (
|
|
3306
|
+
"onUpdate:blobFileName": (u) => t.value[r].blobFileName = u,
|
|
3292
3307
|
"upload-status": t.value[r].status,
|
|
3293
|
-
"onUpdate:uploadStatus": (
|
|
3308
|
+
"onUpdate:uploadStatus": (u) => t.value[r].status = u,
|
|
3294
3309
|
ref_for: !0
|
|
3295
|
-
},
|
|
3310
|
+
}, l, { onDeleted: o }), null, 16, ["class", "file", "onUpdate:file", "blob-file-name", "onUpdate:blobFileName", "upload-status", "onUpdate:uploadStatus"]))
|
|
3296
3311
|
]))), 256))
|
|
3297
3312
|
]),
|
|
3298
3313
|
_: 1
|
|
3299
3314
|
}, 8, ["max-file-input", "max-file-size", "accepted-file-types", "modelValue"]),
|
|
3300
|
-
f(
|
|
3301
|
-
"max-file-size":
|
|
3315
|
+
f(Ol, {
|
|
3316
|
+
"max-file-size": l.maxFileSize
|
|
3302
3317
|
}, null, 8, ["max-file-size"])
|
|
3303
3318
|
])) : S("", !0)
|
|
3304
3319
|
]));
|
|
3305
3320
|
}
|
|
3306
3321
|
});
|
|
3307
3322
|
export {
|
|
3308
|
-
|
|
3309
|
-
|
|
3310
|
-
|
|
3323
|
+
ca as Bootstrap_PT,
|
|
3324
|
+
ma as ForgeActionButton,
|
|
3325
|
+
ae as ForgeAlert,
|
|
3311
3326
|
ct as ForgeCheckbox,
|
|
3312
|
-
|
|
3327
|
+
$a as ForgeChips,
|
|
3313
3328
|
ye as ForgeDatepicker,
|
|
3314
|
-
|
|
3315
|
-
|
|
3316
|
-
|
|
3317
|
-
|
|
3329
|
+
Ca as ForgeFileUploader,
|
|
3330
|
+
Va as ForgeFilterHeader,
|
|
3331
|
+
xa as ForgeForm,
|
|
3332
|
+
ka as ForgeFormField,
|
|
3318
3333
|
$t as ForgeInlineEditor,
|
|
3319
|
-
|
|
3334
|
+
pa as ForgeLink,
|
|
3320
3335
|
me as ForgeLoader,
|
|
3321
|
-
|
|
3336
|
+
ba as ForgeModal,
|
|
3322
3337
|
pe as ForgeMultiSelect,
|
|
3323
|
-
|
|
3324
|
-
|
|
3325
|
-
|
|
3326
|
-
|
|
3327
|
-
|
|
3328
|
-
|
|
3329
|
-
|
|
3330
|
-
|
|
3331
|
-
|
|
3332
|
-
|
|
3333
|
-
|
|
3338
|
+
ga as ForgeMultiSelectPreview,
|
|
3339
|
+
fa as ForgeNavbar,
|
|
3340
|
+
ha as ForgePageHeader,
|
|
3341
|
+
Gt as ForgeProgressBar,
|
|
3342
|
+
wa as ForgeRemainingCharacters,
|
|
3343
|
+
Ba as ForgeStatWidget,
|
|
3344
|
+
Fa as ForgeStepper,
|
|
3345
|
+
Sa as ForgeTable,
|
|
3346
|
+
_a as ForgeTile,
|
|
3347
|
+
va as convertToMultiSelectOption,
|
|
3348
|
+
ya as enumToMultiSelectList,
|
|
3334
3349
|
yt as parseError
|
|
3335
3350
|
};
|