@dynamicforms/vue-forms 0.2.4 → 0.2.6
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.
|
@@ -1,64 +1,64 @@
|
|
|
1
|
-
var
|
|
2
|
-
var
|
|
3
|
-
var R = Object.getOwnPropertySymbols,
|
|
4
|
-
var
|
|
1
|
+
var bt = Object.defineProperty, pt = Object.defineProperties;
|
|
2
|
+
var yt = Object.getOwnPropertyDescriptors;
|
|
3
|
+
var R = Object.getOwnPropertySymbols, mt = Object.getPrototypeOf, it = Object.prototype.hasOwnProperty, st = Object.prototype.propertyIsEnumerable, vt = Reflect.get;
|
|
4
|
+
var W = (s, i, t) => i in s ? bt(s, i, { enumerable: !0, configurable: !0, writable: !0, value: t }) : s[i] = t, A = (s, i) => {
|
|
5
5
|
for (var t in i || (i = {}))
|
|
6
|
-
|
|
6
|
+
it.call(i, t) && W(s, t, i[t]);
|
|
7
7
|
if (R)
|
|
8
8
|
for (var t of R(i))
|
|
9
|
-
|
|
10
|
-
return
|
|
11
|
-
},
|
|
12
|
-
var N = (
|
|
9
|
+
st.call(i, t) && W(s, t, i[t]);
|
|
10
|
+
return s;
|
|
11
|
+
}, F = (s, i) => pt(s, yt(i));
|
|
12
|
+
var N = (s, i) => {
|
|
13
13
|
var t = {};
|
|
14
|
-
for (var e in
|
|
15
|
-
|
|
16
|
-
if (
|
|
17
|
-
for (var e of R(
|
|
18
|
-
i.indexOf(e) < 0 &&
|
|
14
|
+
for (var e in s)
|
|
15
|
+
it.call(s, e) && i.indexOf(e) < 0 && (t[e] = s[e]);
|
|
16
|
+
if (s != null && R)
|
|
17
|
+
for (var e of R(s))
|
|
18
|
+
i.indexOf(e) < 0 && st.call(s, e) && (t[e] = s[e]);
|
|
19
19
|
return t;
|
|
20
20
|
};
|
|
21
|
-
var h = (
|
|
22
|
-
var
|
|
23
|
-
var u = (
|
|
21
|
+
var h = (s, i, t) => W(s, typeof i != "symbol" ? i + "" : i, t);
|
|
22
|
+
var v = (s, i, t) => vt(mt(s), t, i);
|
|
23
|
+
var u = (s, i, t) => new Promise((e, n) => {
|
|
24
24
|
var r = (c) => {
|
|
25
25
|
try {
|
|
26
26
|
l(t.next(c));
|
|
27
27
|
} catch (o) {
|
|
28
|
-
|
|
28
|
+
n(o);
|
|
29
29
|
}
|
|
30
30
|
}, a = (c) => {
|
|
31
31
|
try {
|
|
32
32
|
l(t.throw(c));
|
|
33
33
|
} catch (o) {
|
|
34
|
-
|
|
34
|
+
n(o);
|
|
35
35
|
}
|
|
36
36
|
}, l = (c) => c.done ? e(c.value) : Promise.resolve(c.value).then(r, a);
|
|
37
|
-
l((t = t.apply(
|
|
37
|
+
l((t = t.apply(s, i)).next());
|
|
38
38
|
});
|
|
39
|
-
import {
|
|
40
|
-
import {
|
|
41
|
-
var
|
|
42
|
-
const
|
|
43
|
-
((
|
|
44
|
-
function i(
|
|
45
|
-
return
|
|
46
|
-
}
|
|
47
|
-
|
|
48
|
-
function t(
|
|
49
|
-
const r = typeof
|
|
50
|
-
return Object.values(
|
|
51
|
-
}
|
|
52
|
-
|
|
53
|
-
function e(
|
|
54
|
-
const r = typeof
|
|
55
|
-
return Object.values(
|
|
56
|
-
}
|
|
57
|
-
|
|
58
|
-
})(
|
|
59
|
-
Object.freeze(
|
|
60
|
-
const
|
|
61
|
-
class
|
|
39
|
+
import { isEqual as B, isBoolean as nt, isString as C, isEmpty as J, truncate as xt, isArray as lt, isObject as ct } from "lodash-es";
|
|
40
|
+
import { unref as g, computed as ot, reactive as D } from "vue";
|
|
41
|
+
var T = /* @__PURE__ */ ((s) => (s[s.SUPPRESS = 1] = "SUPPRESS", s[s.HIDDEN = 5] = "HIDDEN", s[s.INVISIBLE = 8] = "INVISIBLE", s[s.FULL = 10] = "FULL", s))(T || {});
|
|
42
|
+
const rt = 10;
|
|
43
|
+
((s) => {
|
|
44
|
+
function i(n) {
|
|
45
|
+
return n.toUpperCase() === "SUPPRESS" ? 1 : n.toUpperCase() === "HIDDEN" ? 5 : n.toUpperCase() === "INVISIBLE" ? 8 : rt;
|
|
46
|
+
}
|
|
47
|
+
s.fromString = i;
|
|
48
|
+
function t(n) {
|
|
49
|
+
const r = typeof n == "number" ? n : s.fromString(n);
|
|
50
|
+
return Object.values(s).includes(r) ? r : rt;
|
|
51
|
+
}
|
|
52
|
+
s.fromAny = t;
|
|
53
|
+
function e(n) {
|
|
54
|
+
const r = typeof n == "number" ? n : s.fromString(n);
|
|
55
|
+
return Object.values(s).includes(r);
|
|
56
|
+
}
|
|
57
|
+
s.isDefined = e;
|
|
58
|
+
})(T || (T = {}));
|
|
59
|
+
Object.freeze(T);
|
|
60
|
+
const I = T;
|
|
61
|
+
class p {
|
|
62
62
|
constructor(i) {
|
|
63
63
|
h(this, "executorFn");
|
|
64
64
|
this.executorFn = i;
|
|
@@ -81,87 +81,216 @@ class b {
|
|
|
81
81
|
// eslint-disable-next-line @typescript-eslint/no-unused-vars, class-methods-use-this
|
|
82
82
|
boundToField(i) {
|
|
83
83
|
}
|
|
84
|
+
// eslint-disable-next-line @typescript-eslint/no-unused-vars, class-methods-use-this
|
|
85
|
+
unregister() {
|
|
86
|
+
}
|
|
84
87
|
}
|
|
85
|
-
class
|
|
88
|
+
class K extends Error {
|
|
86
89
|
}
|
|
87
|
-
const
|
|
88
|
-
class
|
|
90
|
+
const ut = Symbol("ValueChangedAction");
|
|
91
|
+
class d extends p {
|
|
89
92
|
// eslint-disable-next-line @typescript-eslint/no-useless-constructor
|
|
90
93
|
constructor(i) {
|
|
91
94
|
super(i);
|
|
92
95
|
}
|
|
93
96
|
// eslint-disable-next-line class-methods-use-this
|
|
94
97
|
static get classIdentifier() {
|
|
95
|
-
return
|
|
98
|
+
return ut;
|
|
96
99
|
}
|
|
97
|
-
execute(i, t, e,
|
|
100
|
+
execute(i, t, e, n) {
|
|
98
101
|
return u(this, null, function* () {
|
|
99
|
-
return
|
|
102
|
+
return v(d.prototype, this, "execute").call(this, i, t, e, n);
|
|
100
103
|
});
|
|
101
104
|
}
|
|
102
105
|
}
|
|
103
|
-
class
|
|
106
|
+
class L extends String {
|
|
107
|
+
}
|
|
108
|
+
function Y(s) {
|
|
109
|
+
const i = g(s);
|
|
110
|
+
return typeof i == "object" && "componentName" in i;
|
|
111
|
+
}
|
|
112
|
+
class Z {
|
|
113
|
+
get componentName() {
|
|
114
|
+
return "Comment";
|
|
115
|
+
}
|
|
116
|
+
// eslint-disable-line class-methods-use-this
|
|
117
|
+
get componentBindings() {
|
|
118
|
+
return {};
|
|
119
|
+
}
|
|
120
|
+
// eslint-disable-line class-methods-use-this
|
|
121
|
+
get componentBody() {
|
|
122
|
+
return "";
|
|
123
|
+
}
|
|
124
|
+
// eslint-disable-line class-methods-use-this
|
|
125
|
+
}
|
|
126
|
+
class Et extends Z {
|
|
127
|
+
constructor(t) {
|
|
128
|
+
super();
|
|
129
|
+
h(this, "text");
|
|
130
|
+
this.text = t;
|
|
131
|
+
}
|
|
132
|
+
get componentName() {
|
|
133
|
+
return "template";
|
|
134
|
+
}
|
|
135
|
+
// eslint-disable-line class-methods-use-this
|
|
136
|
+
get componentBody() {
|
|
137
|
+
return this.text;
|
|
138
|
+
}
|
|
139
|
+
}
|
|
140
|
+
class y extends Z {
|
|
141
|
+
constructor(t) {
|
|
142
|
+
super();
|
|
143
|
+
h(this, "text");
|
|
144
|
+
h(this, "textType");
|
|
145
|
+
this.text = t, this.textType = ot(() => this.getTextType);
|
|
146
|
+
}
|
|
147
|
+
get getTextType() {
|
|
148
|
+
const t = g(this.text);
|
|
149
|
+
return t ? t instanceof L ? "md" : Y(t) ? "component" : "string" : "string";
|
|
150
|
+
}
|
|
151
|
+
get componentName() {
|
|
152
|
+
switch (g(this.textType)) {
|
|
153
|
+
case "string":
|
|
154
|
+
return "template";
|
|
155
|
+
case "md":
|
|
156
|
+
return "vue-markdown";
|
|
157
|
+
case "component":
|
|
158
|
+
return g(this.text).componentName;
|
|
159
|
+
default:
|
|
160
|
+
return "template";
|
|
161
|
+
}
|
|
162
|
+
}
|
|
163
|
+
get componentBindings() {
|
|
164
|
+
switch (g(this.textType)) {
|
|
165
|
+
case "string":
|
|
166
|
+
return {};
|
|
167
|
+
case "md":
|
|
168
|
+
return { source: this.text.toString() };
|
|
169
|
+
case "component":
|
|
170
|
+
return g(this.text).componentProps;
|
|
171
|
+
default:
|
|
172
|
+
return {};
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
get componentBody() {
|
|
176
|
+
switch (g(this.textType)) {
|
|
177
|
+
case "string":
|
|
178
|
+
return g(this.text);
|
|
179
|
+
default:
|
|
180
|
+
return "";
|
|
181
|
+
}
|
|
182
|
+
}
|
|
183
|
+
}
|
|
184
|
+
const It = Symbol("Validator");
|
|
185
|
+
class b extends d {
|
|
186
|
+
/**
|
|
187
|
+
* Creates a new validator
|
|
188
|
+
* @param validationFn Function that validates the field value and returns errors or null
|
|
189
|
+
*/
|
|
190
|
+
constructor(t) {
|
|
191
|
+
super((n, r, a, l) => u(this, null, function* () {
|
|
192
|
+
const c = t(a, l, n) || [];
|
|
193
|
+
c.forEach(
|
|
194
|
+
(o) => Object.defineProperty(o, "source", { value: this.source, enumerable: !1, configurable: !1 })
|
|
195
|
+
);
|
|
196
|
+
for (let o = n.errors.length - 1; o >= 0; o--) {
|
|
197
|
+
const m = n.errors[o];
|
|
198
|
+
if (m.source === this.source) {
|
|
199
|
+
const S = c.findIndex((G) => B(G, m));
|
|
200
|
+
S >= 0 ? c.splice(S, 1) : n.errors.splice(o, 1);
|
|
201
|
+
}
|
|
202
|
+
}
|
|
203
|
+
return c.length > 0 && n.errors.push(...c), n.validate(), r(n, a, l);
|
|
204
|
+
}));
|
|
205
|
+
h(this, "source");
|
|
206
|
+
this.source = Symbol(this.constructor.name);
|
|
207
|
+
}
|
|
208
|
+
// eslint-disable-next-line class-methods-use-this
|
|
209
|
+
static get classIdentifier() {
|
|
210
|
+
return It;
|
|
211
|
+
}
|
|
212
|
+
// eslint-disable-next-line class-methods-use-this
|
|
213
|
+
get eager() {
|
|
214
|
+
return !0;
|
|
215
|
+
}
|
|
216
|
+
// eslint-disable-next-line class-methods-use-this
|
|
217
|
+
replacePlaceholders(t, e) {
|
|
218
|
+
if (Y(t)) return t;
|
|
219
|
+
let n = t;
|
|
220
|
+
return Object.keys(e).forEach((r) => {
|
|
221
|
+
n = n.replaceAll(`{${r}}`, e[r]);
|
|
222
|
+
}), t instanceof L ? new L(n) : n;
|
|
223
|
+
}
|
|
224
|
+
}
|
|
225
|
+
class k extends Map {
|
|
104
226
|
constructor() {
|
|
105
227
|
super(...arguments);
|
|
106
228
|
h(this, "eagerActions", /* @__PURE__ */ new Set());
|
|
229
|
+
h(this, "registeredActions", []);
|
|
107
230
|
}
|
|
108
231
|
register(t) {
|
|
109
|
-
if (!(t instanceof
|
|
110
|
-
|
|
111
|
-
const e = t.classIdentifier,
|
|
232
|
+
if (!(t instanceof p)) throw new Error("Invalid action type");
|
|
233
|
+
this.registeredActions.push(t);
|
|
234
|
+
const e = t.classIdentifier, n = this.get(e) || (() => null);
|
|
112
235
|
function r(a, ...l) {
|
|
113
|
-
return t.execute(a,
|
|
236
|
+
return t.execute(a, n, ...l);
|
|
114
237
|
}
|
|
115
238
|
this.set(e, r), t.eager && this.eagerActions.add(t.classIdentifier);
|
|
116
239
|
}
|
|
117
|
-
trigger(t, e, ...
|
|
240
|
+
trigger(t, e, ...n) {
|
|
118
241
|
return u(this, null, function* () {
|
|
119
242
|
const r = t.classIdentifier;
|
|
120
|
-
r ===
|
|
243
|
+
r === ut && (yield this.triggerEager(e, ...n));
|
|
121
244
|
const a = this.get(r);
|
|
122
245
|
try {
|
|
123
|
-
if (a) return yield a(e, ...
|
|
246
|
+
if (a) return yield a(e, ...n);
|
|
124
247
|
} catch (l) {
|
|
125
|
-
if (!(l instanceof
|
|
248
|
+
if (!(l instanceof K)) throw l;
|
|
126
249
|
}
|
|
127
250
|
return null;
|
|
128
251
|
});
|
|
129
252
|
}
|
|
130
253
|
triggerEager(t, ...e) {
|
|
131
254
|
return u(this, null, function* () {
|
|
132
|
-
for (const
|
|
133
|
-
const r = this.get(
|
|
255
|
+
for (const n of this.eagerActions) {
|
|
256
|
+
const r = this.get(n);
|
|
134
257
|
try {
|
|
135
258
|
r && (yield r(t, ...e));
|
|
136
259
|
} catch (a) {
|
|
137
|
-
if (!(a instanceof
|
|
260
|
+
if (!(a instanceof K)) throw a;
|
|
138
261
|
}
|
|
139
262
|
}
|
|
140
263
|
});
|
|
141
264
|
}
|
|
265
|
+
cloneWithoutValidators() {
|
|
266
|
+
const t = new k();
|
|
267
|
+
return this.registeredActions.forEach((e) => {
|
|
268
|
+
e instanceof b ? e.unregister() : t.register(e);
|
|
269
|
+
}), t;
|
|
270
|
+
}
|
|
142
271
|
}
|
|
143
|
-
const
|
|
144
|
-
class
|
|
272
|
+
const _t = Symbol("ConditionalStatementAction");
|
|
273
|
+
class q extends d {
|
|
145
274
|
constructor(t, e) {
|
|
146
|
-
const
|
|
275
|
+
const n = (r, a, l, c) => u(this, null, function* () {
|
|
147
276
|
const o = t.evaluate();
|
|
148
277
|
if (o !== this.lastResult) {
|
|
149
|
-
for (const
|
|
150
|
-
yield e(
|
|
278
|
+
for (const m of this.boundFields)
|
|
279
|
+
yield e(m, o, this.lastResult);
|
|
151
280
|
this.lastResult = o;
|
|
152
281
|
}
|
|
153
282
|
return a(r, l, c);
|
|
154
283
|
});
|
|
155
|
-
super(
|
|
284
|
+
super(n);
|
|
156
285
|
h(this, "lastResult");
|
|
157
286
|
// boundField tracks the fields this action is bound to. so that it may perform the executorFn on them and not on the
|
|
158
287
|
// ValueChangedAction fields that will call the actionExecutor
|
|
159
288
|
h(this, "boundFields", /* @__PURE__ */ new Set());
|
|
160
|
-
t.collectFields().forEach((r) => r.registerAction(new
|
|
289
|
+
t.collectFields().forEach((r) => r.registerAction(new d(n)));
|
|
161
290
|
}
|
|
162
291
|
// eslint-disable-next-line class-methods-use-this
|
|
163
292
|
static get classIdentifier() {
|
|
164
|
-
return
|
|
293
|
+
return _t;
|
|
165
294
|
}
|
|
166
295
|
// eslint-disable-next-line class-methods-use-this
|
|
167
296
|
get eager() {
|
|
@@ -171,29 +300,29 @@ class k extends g {
|
|
|
171
300
|
this.boundFields.add(t);
|
|
172
301
|
}
|
|
173
302
|
}
|
|
174
|
-
class
|
|
303
|
+
class St extends q {
|
|
175
304
|
constructor(i) {
|
|
176
305
|
super(i, (t, e) => u(this, null, function* () {
|
|
177
|
-
yield t.setVisibility(e ?
|
|
306
|
+
yield t.setVisibility(e ? I.FULL : I.SUPPRESS);
|
|
178
307
|
}));
|
|
179
308
|
}
|
|
180
309
|
}
|
|
181
|
-
class
|
|
310
|
+
class Ct extends q {
|
|
182
311
|
constructor(i) {
|
|
183
312
|
super(i, (t, e) => u(this, null, function* () {
|
|
184
313
|
yield t.setEnabled(e);
|
|
185
314
|
}));
|
|
186
315
|
}
|
|
187
316
|
}
|
|
188
|
-
class
|
|
317
|
+
class Vt extends q {
|
|
189
318
|
constructor(i, t) {
|
|
190
|
-
super(i, (e,
|
|
191
|
-
|
|
319
|
+
super(i, (e, n) => u(this, null, function* () {
|
|
320
|
+
n && (yield e.setValue(t));
|
|
192
321
|
}));
|
|
193
322
|
}
|
|
194
323
|
}
|
|
195
|
-
var
|
|
196
|
-
((
|
|
324
|
+
var w = /* @__PURE__ */ ((s) => (s[s.NOT = 0] = "NOT", s[s.OR = 1] = "OR", s[s.AND = 2] = "AND", s[s.XOR = 3] = "XOR", s[s.NAND = 4] = "NAND", s[s.NOR = 5] = "NOR", s[s.EQUALS = -1] = "EQUALS", s[s.NOT_EQUALS = -2] = "NOT_EQUALS", s[s.GT = -3] = "GT", s[s.LT = -4] = "LT", s[s.GE = -5] = "GE", s[s.LE = -6] = "LE", s[s.IN = -7] = "IN", s[s.NOT_IN = -8] = "NOT_IN", s[s.INCLUDES = -9] = "INCLUDES", s[s.NOT_INCLUDES = -10] = "NOT_INCLUDES", s))(w || {});
|
|
325
|
+
((s) => {
|
|
197
326
|
function i(r) {
|
|
198
327
|
const a = r.toLowerCase();
|
|
199
328
|
if (a === "not") return 0;
|
|
@@ -214,115 +343,115 @@ var T = /* @__PURE__ */ ((n) => (n[n.NOT = 0] = "NOT", n[n.OR = 1] = "OR", n[n.A
|
|
|
214
343
|
if (["not_includes", "not-includes", "not includes"].includes(a)) return -10;
|
|
215
344
|
throw new Error(`Unrecognised operator ${a}`);
|
|
216
345
|
}
|
|
217
|
-
|
|
346
|
+
s.fromString = i;
|
|
218
347
|
function t(r) {
|
|
219
|
-
const a = typeof r == "number" ? r :
|
|
220
|
-
if (Object.values(
|
|
348
|
+
const a = typeof r == "number" ? r : s.fromString(r);
|
|
349
|
+
if (Object.values(s).includes(a)) return a;
|
|
221
350
|
throw new Error(`Unrecognised operator ${r}`);
|
|
222
351
|
}
|
|
223
|
-
|
|
352
|
+
s.fromAny = t;
|
|
224
353
|
function e(r) {
|
|
225
|
-
const a = typeof r == "number" ? r :
|
|
226
|
-
return Object.values(
|
|
354
|
+
const a = typeof r == "number" ? r : s.fromString(r);
|
|
355
|
+
return Object.values(s).includes(a);
|
|
227
356
|
}
|
|
228
|
-
|
|
229
|
-
function
|
|
357
|
+
s.isDefined = e;
|
|
358
|
+
function n(r) {
|
|
230
359
|
return r >= 0;
|
|
231
360
|
}
|
|
232
|
-
|
|
233
|
-
})(
|
|
234
|
-
Object.freeze(
|
|
235
|
-
const f =
|
|
236
|
-
class
|
|
361
|
+
s.isLogicOperator = n;
|
|
362
|
+
})(w || (w = {}));
|
|
363
|
+
Object.freeze(w);
|
|
364
|
+
const f = w, At = Symbol("EnabledChangingAction");
|
|
365
|
+
class M extends p {
|
|
237
366
|
// eslint-disable-next-line @typescript-eslint/no-useless-constructor
|
|
238
367
|
constructor(i) {
|
|
239
368
|
super(i);
|
|
240
369
|
}
|
|
241
370
|
// eslint-disable-next-line class-methods-use-this
|
|
242
371
|
static get classIdentifier() {
|
|
243
|
-
return
|
|
372
|
+
return At;
|
|
244
373
|
}
|
|
245
|
-
execute(i, t, e,
|
|
374
|
+
execute(i, t, e, n) {
|
|
246
375
|
return u(this, null, function* () {
|
|
247
|
-
return
|
|
376
|
+
return v(M.prototype, this, "execute").call(this, i, t, e, n);
|
|
248
377
|
});
|
|
249
378
|
}
|
|
250
379
|
}
|
|
251
|
-
const
|
|
252
|
-
class
|
|
380
|
+
const Ft = Symbol("EnabledChangedAction");
|
|
381
|
+
class P extends p {
|
|
253
382
|
// eslint-disable-next-line @typescript-eslint/no-useless-constructor
|
|
254
383
|
constructor(i) {
|
|
255
384
|
super(i);
|
|
256
385
|
}
|
|
257
386
|
// eslint-disable-next-line class-methods-use-this
|
|
258
387
|
static get classIdentifier() {
|
|
259
|
-
return
|
|
388
|
+
return Ft;
|
|
260
389
|
}
|
|
261
|
-
execute(i, t, e,
|
|
390
|
+
execute(i, t, e, n) {
|
|
262
391
|
return u(this, null, function* () {
|
|
263
|
-
return
|
|
392
|
+
return v(P.prototype, this, "execute").call(this, i, t, e, n);
|
|
264
393
|
});
|
|
265
394
|
}
|
|
266
395
|
}
|
|
267
|
-
const
|
|
268
|
-
class
|
|
396
|
+
const Nt = Symbol("ValidChangedAction");
|
|
397
|
+
class Q extends p {
|
|
269
398
|
// eslint-disable-next-line @typescript-eslint/no-useless-constructor
|
|
270
399
|
constructor(i) {
|
|
271
400
|
super(i);
|
|
272
401
|
}
|
|
273
402
|
// eslint-disable-next-line class-methods-use-this
|
|
274
403
|
static get classIdentifier() {
|
|
275
|
-
return
|
|
404
|
+
return Nt;
|
|
276
405
|
}
|
|
277
|
-
execute(i, t, e,
|
|
406
|
+
execute(i, t, e, n) {
|
|
278
407
|
return u(this, null, function* () {
|
|
279
|
-
return
|
|
408
|
+
return v(Q.prototype, this, "execute").call(this, i, t, e, n);
|
|
280
409
|
});
|
|
281
410
|
}
|
|
282
411
|
}
|
|
283
|
-
const
|
|
284
|
-
class
|
|
412
|
+
const jt = Symbol("VisibilityChangingAction");
|
|
413
|
+
class z extends p {
|
|
285
414
|
// eslint-disable-next-line @typescript-eslint/no-useless-constructor
|
|
286
415
|
constructor(i) {
|
|
287
416
|
super(i);
|
|
288
417
|
}
|
|
289
418
|
// eslint-disable-next-line class-methods-use-this
|
|
290
419
|
static get classIdentifier() {
|
|
291
|
-
return
|
|
420
|
+
return jt;
|
|
292
421
|
}
|
|
293
|
-
execute(i, t, e,
|
|
422
|
+
execute(i, t, e, n) {
|
|
294
423
|
return u(this, null, function* () {
|
|
295
|
-
return
|
|
424
|
+
return v(z.prototype, this, "execute").call(this, i, t, e, n);
|
|
296
425
|
});
|
|
297
426
|
}
|
|
298
427
|
}
|
|
299
|
-
const
|
|
300
|
-
class
|
|
428
|
+
const Tt = Symbol("VisibilityChangedAction");
|
|
429
|
+
class O extends p {
|
|
301
430
|
// eslint-disable-next-line @typescript-eslint/no-useless-constructor
|
|
302
431
|
constructor(i) {
|
|
303
432
|
super(i);
|
|
304
433
|
}
|
|
305
434
|
// eslint-disable-next-line class-methods-use-this
|
|
306
435
|
static get classIdentifier() {
|
|
307
|
-
return
|
|
436
|
+
return Tt;
|
|
308
437
|
}
|
|
309
|
-
execute(i, t, e,
|
|
438
|
+
execute(i, t, e, n) {
|
|
310
439
|
return u(this, null, function* () {
|
|
311
|
-
return
|
|
440
|
+
return v(O.prototype, this, "execute").call(this, i, t, e, n);
|
|
312
441
|
});
|
|
313
442
|
}
|
|
314
443
|
}
|
|
315
|
-
class
|
|
444
|
+
class x {
|
|
316
445
|
constructor() {
|
|
317
|
-
h(this, "reactiveValue",
|
|
446
|
+
h(this, "reactiveValue", ot(() => this.value));
|
|
318
447
|
// contains original field value as was provided at creation
|
|
319
448
|
h(this, "valid", !0);
|
|
320
449
|
// is current value valid as per FE and BE validators?
|
|
321
450
|
h(this, "errors", []);
|
|
322
451
|
// when member of a Group, fieldName specifies the name of this field
|
|
323
|
-
h(this, "actions", new
|
|
452
|
+
h(this, "actions", new k());
|
|
324
453
|
// default property handlers
|
|
325
|
-
h(this, "_visibility",
|
|
454
|
+
h(this, "_visibility", I.FULL);
|
|
326
455
|
h(this, "_enabled", !0);
|
|
327
456
|
}
|
|
328
457
|
get visibility() {
|
|
@@ -330,14 +459,14 @@ class y {
|
|
|
330
459
|
}
|
|
331
460
|
set visibility(i) {
|
|
332
461
|
const t = this._visibility;
|
|
333
|
-
if (!
|
|
334
|
-
this._visibility =
|
|
462
|
+
if (!I.isDefined(i)) throw new Error("visibility must be a DisplayMode constant");
|
|
463
|
+
this._visibility = I.fromAny(i), this.actions.trigger(O, this, this._visibility, t);
|
|
335
464
|
}
|
|
336
465
|
setVisibility(i) {
|
|
337
466
|
return u(this, null, function* () {
|
|
338
|
-
const t = this._visibility, e = yield this.actions.trigger(
|
|
339
|
-
if (!
|
|
340
|
-
this._visibility =
|
|
467
|
+
const t = this._visibility, e = yield this.actions.trigger(z, this, i, t);
|
|
468
|
+
if (!I.isDefined(e != null ? e : i)) throw new Error("visibility must be a DisplayMode constant");
|
|
469
|
+
this._visibility = I.fromAny(e != null ? e : i), yield this.actions.trigger(O, this, this._visibility, t);
|
|
341
470
|
});
|
|
342
471
|
}
|
|
343
472
|
get enabled() {
|
|
@@ -345,25 +474,25 @@ class y {
|
|
|
345
474
|
}
|
|
346
475
|
set enabled(i) {
|
|
347
476
|
const t = this._enabled;
|
|
348
|
-
if (!
|
|
349
|
-
this._enabled = i, this.actions.trigger(
|
|
477
|
+
if (!nt(i)) throw new Error("Enabled value must be boolean");
|
|
478
|
+
this._enabled = i, this.actions.trigger(P, this, this._enabled, t);
|
|
350
479
|
}
|
|
351
480
|
setEnabled(i) {
|
|
352
481
|
return u(this, null, function* () {
|
|
353
|
-
const t = this._enabled, e = yield this.actions.trigger(
|
|
354
|
-
if (!
|
|
355
|
-
this._enabled = e != null ? e : i, yield this.actions.trigger(
|
|
482
|
+
const t = this._enabled, e = yield this.actions.trigger(M, this, i, t);
|
|
483
|
+
if (!nt(e != null ? e : i)) throw new Error("Enabled value must be boolean");
|
|
484
|
+
this._enabled = e != null ? e : i, yield this.actions.trigger(P, this, this._enabled, t);
|
|
356
485
|
});
|
|
357
486
|
}
|
|
358
487
|
validate() {
|
|
359
488
|
const i = this.valid;
|
|
360
|
-
this.valid = this.errors.length === 0, this.valid !== i && this.actions.trigger(
|
|
489
|
+
this.valid = this.errors.length === 0, this.valid !== i && this.actions.trigger(Q, this, this.valid, i);
|
|
361
490
|
}
|
|
362
491
|
get fullValue() {
|
|
363
492
|
return this.value;
|
|
364
493
|
}
|
|
365
494
|
get isChanged() {
|
|
366
|
-
return
|
|
495
|
+
return !B(this.value, this.originalValue);
|
|
367
496
|
}
|
|
368
497
|
registerAction(i) {
|
|
369
498
|
const t = i;
|
|
@@ -372,9 +501,12 @@ class y {
|
|
|
372
501
|
triggerAction(i, ...t) {
|
|
373
502
|
return this.actions.trigger(i, this, ...t);
|
|
374
503
|
}
|
|
504
|
+
clearValidators() {
|
|
505
|
+
this.actions = this.actions.cloneWithoutValidators(), this.errors = [], this.valid = !0;
|
|
506
|
+
}
|
|
375
507
|
}
|
|
376
|
-
function
|
|
377
|
-
return
|
|
508
|
+
function Lt(s, i) {
|
|
509
|
+
return s ? !i : i;
|
|
378
510
|
}
|
|
379
511
|
class j {
|
|
380
512
|
constructor(i, t, e) {
|
|
@@ -384,13 +516,13 @@ class j {
|
|
|
384
516
|
this.operand1 = i, this.operator = t, this.operand2 = e;
|
|
385
517
|
}
|
|
386
518
|
get operand1Value() {
|
|
387
|
-
return this.operand1 instanceof j ? this.operand1.evaluate() : this.operand1 instanceof
|
|
519
|
+
return this.operand1 instanceof j ? this.operand1.evaluate() : this.operand1 instanceof x ? g(this.operand1.value) : this.operand1;
|
|
388
520
|
}
|
|
389
521
|
get operand2Value() {
|
|
390
|
-
return this.operand2 instanceof j ? this.operand2.evaluate() : this.operand2 instanceof
|
|
522
|
+
return this.operand2 instanceof j ? this.operand2.evaluate() : this.operand2 instanceof x ? g(this.operand2.value) : this.operand2;
|
|
391
523
|
}
|
|
392
524
|
evaluate() {
|
|
393
|
-
var e,
|
|
525
|
+
var e, n, r, a;
|
|
394
526
|
const i = this.operand1Value, t = this.operand2Value;
|
|
395
527
|
switch (this.operator) {
|
|
396
528
|
case f.AND:
|
|
@@ -402,7 +534,7 @@ class j {
|
|
|
402
534
|
case f.NOR:
|
|
403
535
|
return !(i || t);
|
|
404
536
|
case f.XOR:
|
|
405
|
-
return
|
|
537
|
+
return Lt(i, t);
|
|
406
538
|
case f.NOT:
|
|
407
539
|
return !i;
|
|
408
540
|
case f.EQUALS:
|
|
@@ -418,13 +550,13 @@ class j {
|
|
|
418
550
|
case f.GT:
|
|
419
551
|
return i > t;
|
|
420
552
|
case f.IN:
|
|
421
|
-
return (
|
|
553
|
+
return (n = (e = t == null ? void 0 : t.includes) == null ? void 0 : e.call(t, i)) != null ? n : !1;
|
|
422
554
|
case f.NOT_IN:
|
|
423
555
|
return !((a = (r = t == null ? void 0 : t.includes) == null ? void 0 : r.call(t, i)) == null || a);
|
|
424
556
|
case f.INCLUDES:
|
|
425
|
-
return
|
|
557
|
+
return C(i) && C(t) && i.indexOf(t) >= 0;
|
|
426
558
|
case f.NOT_INCLUDES:
|
|
427
|
-
return !(
|
|
559
|
+
return !(C(i) && C(t) && i.indexOf(t) >= 0);
|
|
428
560
|
default:
|
|
429
561
|
throw new Error(`Operator not implemented ${this.operator}`);
|
|
430
562
|
}
|
|
@@ -436,77 +568,77 @@ class j {
|
|
|
436
568
|
collectFields() {
|
|
437
569
|
const i = /* @__PURE__ */ new Set();
|
|
438
570
|
function t(e) {
|
|
439
|
-
e instanceof
|
|
571
|
+
e instanceof x ? i.add(e) : e instanceof j && e.collectFields().forEach((r) => i.add(r));
|
|
440
572
|
}
|
|
441
573
|
return t(this.operand1), t(this.operand2), i;
|
|
442
574
|
}
|
|
443
575
|
}
|
|
444
|
-
const
|
|
445
|
-
class
|
|
576
|
+
const wt = Symbol("ExecuteAction");
|
|
577
|
+
class H extends p {
|
|
446
578
|
// eslint-disable-next-line @typescript-eslint/no-useless-constructor
|
|
447
579
|
constructor(i) {
|
|
448
580
|
super(i);
|
|
449
581
|
}
|
|
450
582
|
// eslint-disable-next-line class-methods-use-this
|
|
451
583
|
static get classIdentifier() {
|
|
452
|
-
return
|
|
584
|
+
return wt;
|
|
453
585
|
}
|
|
454
586
|
execute(i, t, e) {
|
|
455
587
|
return u(this, null, function* () {
|
|
456
|
-
return
|
|
588
|
+
return v(H.prototype, this, "execute").call(this, i, t, e);
|
|
457
589
|
});
|
|
458
590
|
}
|
|
459
591
|
}
|
|
460
|
-
const
|
|
461
|
-
class
|
|
592
|
+
const Pt = Symbol("ListItemAddedAction");
|
|
593
|
+
class U extends p {
|
|
462
594
|
// eslint-disable-next-line @typescript-eslint/no-useless-constructor
|
|
463
595
|
constructor(i) {
|
|
464
596
|
super(i);
|
|
465
597
|
}
|
|
466
598
|
// eslint-disable-next-line class-methods-use-this
|
|
467
599
|
static get classIdentifier() {
|
|
468
|
-
return
|
|
600
|
+
return Pt;
|
|
469
601
|
}
|
|
470
|
-
execute(i, t, e,
|
|
602
|
+
execute(i, t, e, n) {
|
|
471
603
|
return u(this, null, function* () {
|
|
472
|
-
return
|
|
604
|
+
return v(U.prototype, this, "execute").call(this, i, t, e, n);
|
|
473
605
|
});
|
|
474
606
|
}
|
|
475
607
|
}
|
|
476
|
-
const
|
|
477
|
-
class
|
|
608
|
+
const Ot = Symbol("ListItemRemovedAction");
|
|
609
|
+
class X extends p {
|
|
478
610
|
// eslint-disable-next-line @typescript-eslint/no-useless-constructor
|
|
479
611
|
constructor(i) {
|
|
480
612
|
super(i);
|
|
481
613
|
}
|
|
482
614
|
// eslint-disable-next-line class-methods-use-this
|
|
483
615
|
static get classIdentifier() {
|
|
484
|
-
return
|
|
616
|
+
return Ot;
|
|
485
617
|
}
|
|
486
|
-
execute(i, t, e,
|
|
618
|
+
execute(i, t, e, n) {
|
|
487
619
|
return u(this, null, function* () {
|
|
488
|
-
return
|
|
620
|
+
return v(X.prototype, this, "execute").call(this, i, t, e, n);
|
|
489
621
|
});
|
|
490
622
|
}
|
|
491
623
|
}
|
|
492
|
-
function
|
|
493
|
-
return (
|
|
624
|
+
function at(s, i) {
|
|
625
|
+
return (s == null ? void 0 : s.label) == null && (s == null ? void 0 : s.icon) == null ? i : s;
|
|
494
626
|
}
|
|
495
|
-
class
|
|
627
|
+
class $ extends x {
|
|
496
628
|
constructor(t) {
|
|
497
629
|
super();
|
|
498
630
|
h(this, "_value");
|
|
499
631
|
if (t) {
|
|
500
|
-
const e = t, { value:
|
|
501
|
-
[...a || [], ...l || []].forEach((
|
|
502
|
-
const o = { label:
|
|
503
|
-
this._value = D(
|
|
632
|
+
const e = t, { value: n, originalValue: r, validators: a, actions: l } = e, c = N(e, ["value", "originalValue", "validators", "actions"]);
|
|
633
|
+
[...a || [], ...l || []].forEach((S) => this.registerAction(S)), Object.assign(this, c);
|
|
634
|
+
const o = { label: n == null ? void 0 : n.label, icon: n == null ? void 0 : n.icon }, m = Object.freeze({ label: r == null ? void 0 : r.label, icon: r == null ? void 0 : r.icon });
|
|
635
|
+
this._value = D(at(o, m)), this.originalValue = at(m, o);
|
|
504
636
|
} else
|
|
505
637
|
this._value = D({ label: void 0, icon: void 0 });
|
|
506
638
|
this.actions.triggerEager(this, this.value, this.originalValue);
|
|
507
639
|
}
|
|
508
640
|
static create(t) {
|
|
509
|
-
return D(new
|
|
641
|
+
return D(new $(t));
|
|
510
642
|
}
|
|
511
643
|
get value() {
|
|
512
644
|
return this._value;
|
|
@@ -514,13 +646,13 @@ class B extends y {
|
|
|
514
646
|
set value(t) {
|
|
515
647
|
if (!this.enabled) return;
|
|
516
648
|
const e = this._value;
|
|
517
|
-
this._value.icon = t == null ? void 0 : t.icon, this._value.label = t == null ? void 0 : t.label, this.actions.trigger(
|
|
649
|
+
this._value.icon = t == null ? void 0 : t.icon, this._value.label = t == null ? void 0 : t.label, this.actions.trigger(d, this, t, e), this.parent && this.parent.notifyValueChanged(), this.validate();
|
|
518
650
|
}
|
|
519
651
|
setValue(t) {
|
|
520
652
|
return u(this, null, function* () {
|
|
521
653
|
if (!this.enabled) return;
|
|
522
654
|
const e = this._value;
|
|
523
|
-
this._value.icon = t == null ? void 0 : t.icon, this._value.label = t == null ? void 0 : t.label, yield this.actions.trigger(
|
|
655
|
+
this._value.icon = t == null ? void 0 : t.icon, this._value.label = t == null ? void 0 : t.label, yield this.actions.trigger(d, this, t, e), this.parent && (yield this.parent.notifyValueChanged()), this.validate();
|
|
524
656
|
});
|
|
525
657
|
}
|
|
526
658
|
get icon() {
|
|
@@ -536,26 +668,26 @@ class B extends y {
|
|
|
536
668
|
this.value = { label: t, icon: this.value.icon };
|
|
537
669
|
}
|
|
538
670
|
clone(t) {
|
|
539
|
-
var e,
|
|
540
|
-
return
|
|
671
|
+
var e, n, r, a;
|
|
672
|
+
return $.create(F(A({
|
|
541
673
|
value: (e = t == null ? void 0 : t.value) != null ? e : this.value
|
|
542
674
|
}, t && "originalValue" in t ? { originalValue: t.originalValue } : {}), {
|
|
543
|
-
errors: [...(
|
|
675
|
+
errors: [...(n = t == null ? void 0 : t.errors) != null ? n : this.errors],
|
|
544
676
|
enabled: (r = t == null ? void 0 : t.enabled) != null ? r : this.enabled,
|
|
545
677
|
visibility: (a = t == null ? void 0 : t.visibility) != null ? a : this.visibility
|
|
546
678
|
}));
|
|
547
679
|
}
|
|
548
680
|
execute(t) {
|
|
549
|
-
this.actions.trigger(
|
|
681
|
+
this.actions.trigger(H, this, t);
|
|
550
682
|
}
|
|
551
683
|
}
|
|
552
|
-
class
|
|
684
|
+
class V extends x {
|
|
553
685
|
constructor(t) {
|
|
554
686
|
super();
|
|
555
687
|
h(this, "_value");
|
|
556
688
|
if (t) {
|
|
557
|
-
const e = t, { value:
|
|
558
|
-
[...r || [], ...a || []].forEach((c) => this.registerAction(c)), Object.assign(this, l), this._value =
|
|
689
|
+
const e = t, { value: n, validators: r, actions: a } = e, l = N(e, ["value", "validators", "actions"]);
|
|
690
|
+
[...r || [], ...a || []].forEach((c) => this.registerAction(c)), Object.assign(this, l), this._value = n != null ? n : this.originalValue, this.originalValue === void 0 && (this.originalValue = this._value);
|
|
559
691
|
}
|
|
560
692
|
this.actions.triggerEager(this, this.value, this.originalValue);
|
|
561
693
|
}
|
|
@@ -565,70 +697,73 @@ class C extends y {
|
|
|
565
697
|
* @returns Reactive Field instance
|
|
566
698
|
*/
|
|
567
699
|
static create(t) {
|
|
568
|
-
return D(new
|
|
700
|
+
return D(new V(t));
|
|
569
701
|
}
|
|
570
702
|
get value() {
|
|
571
|
-
return this._value;
|
|
703
|
+
return g(this._value);
|
|
572
704
|
}
|
|
573
705
|
set value(t) {
|
|
574
706
|
const e = this._value;
|
|
575
|
-
!this.enabled || e === t || (this._value = t, this.actions.trigger(
|
|
707
|
+
!this.enabled || e === t || (this._value = t, this.actions.trigger(d, this, t, e), this.parent && this.parent.notifyValueChanged(), this.validate());
|
|
576
708
|
}
|
|
577
709
|
setValue(t) {
|
|
578
710
|
return u(this, null, function* () {
|
|
579
711
|
const e = this._value;
|
|
580
|
-
!this.enabled || e === t || (this._value = t, yield this.actions.trigger(
|
|
712
|
+
!this.enabled || e === t || (this._value = t, yield this.actions.trigger(d, this, t, e), this.parent && (yield this.parent.notifyValueChanged()), this.validate());
|
|
581
713
|
});
|
|
582
714
|
}
|
|
583
715
|
clone(t) {
|
|
584
|
-
var e,
|
|
585
|
-
return
|
|
716
|
+
var e, n, r, a;
|
|
717
|
+
return V.create(F(A({
|
|
586
718
|
value: (e = t == null ? void 0 : t.value) != null ? e : this.value
|
|
587
719
|
}, t && "originalValue" in t ? { originalValue: t.originalValue } : {}), {
|
|
588
|
-
errors: [...(
|
|
720
|
+
errors: [...(n = t == null ? void 0 : t.errors) != null ? n : this.errors],
|
|
589
721
|
enabled: (r = t == null ? void 0 : t.enabled) != null ? r : this.enabled,
|
|
590
722
|
visibility: (a = t == null ? void 0 : t.visibility) != null ? a : this.visibility
|
|
591
723
|
}));
|
|
592
724
|
}
|
|
593
725
|
}
|
|
594
|
-
const
|
|
726
|
+
const Ut = V.create({ value: "EmptyField" }).registerAction(new d(
|
|
595
727
|
() => u(void 0, null, function* () {
|
|
596
728
|
console.warn("Working with EmptyField! This should not happen");
|
|
597
729
|
})
|
|
598
730
|
));
|
|
599
|
-
class
|
|
731
|
+
class _ extends x {
|
|
600
732
|
constructor(t, e) {
|
|
601
733
|
super();
|
|
602
734
|
h(this, "_fields");
|
|
603
735
|
h(this, "_value", null);
|
|
604
736
|
h(this, "suppressNotifyValueChanged", !1);
|
|
605
|
-
if (!
|
|
606
|
-
if (this._fields = {}, Object.entries(t).forEach(([r, a]) => {
|
|
607
|
-
|
|
608
|
-
this._fields,
|
|
609
|
-
r,
|
|
610
|
-
{ get() {
|
|
611
|
-
return a;
|
|
612
|
-
}, configurable: !1, enumerable: !0 }
|
|
613
|
-
);
|
|
614
|
-
}), e) {
|
|
615
|
-
const s = e, { value: r, validators: a, actions: l } = s, c = N(s, ["value", "validators", "actions"]);
|
|
737
|
+
if (!_.isValidFields(t)) throw new Error("Invalid fields object provided");
|
|
738
|
+
if (this._fields = {}, Object.entries(t).forEach(([r, a]) => this.addField(r, a)), e) {
|
|
739
|
+
const n = e, { value: r, validators: a, actions: l } = n, c = N(n, ["value", "validators", "actions"]);
|
|
616
740
|
[...a || [], ...l || []].forEach((o) => this.registerAction(o)), Object.assign(this, c), this.value = r != null ? r : this.originalValue;
|
|
617
741
|
}
|
|
618
742
|
this.originalValue === void 0 && (this.originalValue = this.value), this.actions.triggerEager(this, this.value, this.originalValue);
|
|
619
743
|
}
|
|
744
|
+
addField(t, e) {
|
|
745
|
+
if (this.fields[t] !== void 0)
|
|
746
|
+
throw new Error(`Field ${t} is already in this form`);
|
|
747
|
+
Object.defineProperty(e, "parent", { get: () => this, configurable: !1, enumerable: !1 }), Object.defineProperty(e, "fieldName", { get: () => t, configurable: !1, enumerable: !1 }), Object.defineProperty(
|
|
748
|
+
this._fields,
|
|
749
|
+
t,
|
|
750
|
+
{ get() {
|
|
751
|
+
return e;
|
|
752
|
+
}, configurable: !1, enumerable: !0 }
|
|
753
|
+
);
|
|
754
|
+
}
|
|
620
755
|
static isValidFields(t) {
|
|
621
|
-
function e(
|
|
622
|
-
return
|
|
756
|
+
function e(n) {
|
|
757
|
+
return n instanceof x;
|
|
623
758
|
}
|
|
624
|
-
return typeof t == "object" && t !== null && Object.entries(t).every(([,
|
|
759
|
+
return typeof t == "object" && t !== null && Object.entries(t).every(([, n]) => e(n));
|
|
625
760
|
}
|
|
626
761
|
static createFromFormData(t) {
|
|
627
|
-
if (t instanceof
|
|
762
|
+
if (t instanceof x)
|
|
628
763
|
throw new Error("data is already a Form structure, should be a simple object");
|
|
629
|
-
return new
|
|
764
|
+
return new _(
|
|
630
765
|
t == null ? {} : Object.fromEntries(
|
|
631
|
-
Object.entries(t).map(([e,
|
|
766
|
+
Object.entries(t).map(([e, n]) => [e, V.create({ value: n })])
|
|
632
767
|
)
|
|
633
768
|
);
|
|
634
769
|
}
|
|
@@ -641,16 +776,16 @@ class I extends y {
|
|
|
641
776
|
}
|
|
642
777
|
get value() {
|
|
643
778
|
const t = {};
|
|
644
|
-
return Object.entries(this._fields).forEach(([e,
|
|
645
|
-
const r =
|
|
646
|
-
(
|
|
647
|
-
}),
|
|
779
|
+
return Object.entries(this._fields).forEach(([e, n]) => {
|
|
780
|
+
const r = n.value;
|
|
781
|
+
(n.enabled || n instanceof _ && !J(r)) && (t[e] = r);
|
|
782
|
+
}), J(t) ? null : t;
|
|
648
783
|
}
|
|
649
784
|
set value(t) {
|
|
650
785
|
this.suppressNotifyValueChanged = !0;
|
|
651
786
|
try {
|
|
652
|
-
Object.entries(this._fields).forEach(([e,
|
|
653
|
-
(t == null || e in t) && (
|
|
787
|
+
Object.entries(this._fields).forEach(([e, n]) => {
|
|
788
|
+
(t == null || e in t) && (n.value = t == null ? null : t[e]);
|
|
654
789
|
});
|
|
655
790
|
} finally {
|
|
656
791
|
this.suppressNotifyValueChanged = !1;
|
|
@@ -660,14 +795,14 @@ class I extends y {
|
|
|
660
795
|
setValue(t) {
|
|
661
796
|
return u(this, null, function* () {
|
|
662
797
|
this.suppressNotifyValueChanged = !0;
|
|
663
|
-
function e(
|
|
798
|
+
function e(n, r) {
|
|
664
799
|
return u(this, null, function* () {
|
|
665
|
-
(t == null ||
|
|
800
|
+
(t == null || n in t) && (yield r.setValue(t == null ? null : t[n]));
|
|
666
801
|
});
|
|
667
802
|
}
|
|
668
803
|
try {
|
|
669
|
-
for (const [
|
|
670
|
-
yield e(
|
|
804
|
+
for (const [n, r] of Object.entries(this._fields))
|
|
805
|
+
yield e(n, r);
|
|
671
806
|
} finally {
|
|
672
807
|
this.suppressNotifyValueChanged = !1;
|
|
673
808
|
}
|
|
@@ -676,27 +811,27 @@ class I extends y {
|
|
|
676
811
|
}
|
|
677
812
|
get fullValue() {
|
|
678
813
|
const t = {};
|
|
679
|
-
return Object.entries(this._fields).forEach(([e,
|
|
680
|
-
t[e] =
|
|
814
|
+
return Object.entries(this._fields).forEach(([e, n]) => {
|
|
815
|
+
t[e] = n.fullValue;
|
|
681
816
|
}), t;
|
|
682
817
|
}
|
|
683
818
|
notifyValueChanged() {
|
|
684
819
|
return u(this, null, function* () {
|
|
685
820
|
if (this.suppressNotifyValueChanged) return;
|
|
686
821
|
const t = this.value;
|
|
687
|
-
if (
|
|
822
|
+
if (!B(t, this._value)) {
|
|
688
823
|
const e = this._value;
|
|
689
|
-
this._value = t, yield this.actions.trigger(
|
|
824
|
+
this._value = t, yield this.actions.trigger(d, this, t, e), this.parent && (yield this.parent.notifyValueChanged());
|
|
690
825
|
}
|
|
691
826
|
});
|
|
692
827
|
}
|
|
693
828
|
clone(t) {
|
|
694
|
-
var
|
|
829
|
+
var n, r, a, l;
|
|
695
830
|
const e = {};
|
|
696
831
|
return Object.entries(this._fields).forEach(([c, o]) => {
|
|
697
832
|
e[c] = o.clone();
|
|
698
|
-
}), new
|
|
699
|
-
value: (
|
|
833
|
+
}), new _(e, F(A({
|
|
834
|
+
value: (n = t == null ? void 0 : t.value) != null ? n : this.value
|
|
700
835
|
}, t && "originalValue" in t ? { originalValue: t.originalValue } : {}), {
|
|
701
836
|
errors: [...(r = t == null ? void 0 : t.errors) != null ? r : []],
|
|
702
837
|
enabled: (a = t == null ? void 0 : t.enabled) != null ? a : this.enabled,
|
|
@@ -704,44 +839,44 @@ class I extends y {
|
|
|
704
839
|
}));
|
|
705
840
|
}
|
|
706
841
|
}
|
|
707
|
-
class
|
|
842
|
+
class tt extends x {
|
|
708
843
|
constructor(t, e) {
|
|
709
844
|
super();
|
|
710
845
|
h(this, "_value", null);
|
|
711
846
|
h(this, "_itemTemplate");
|
|
712
847
|
h(this, "_previousValue");
|
|
713
848
|
if (this._itemTemplate = t, e) {
|
|
714
|
-
const
|
|
849
|
+
const n = e, { value: r, validators: a, actions: l } = n, c = N(n, ["value", "validators", "actions"]);
|
|
715
850
|
[...a || [], ...l || []].forEach((o) => this.registerAction(o)), Object.assign(this, c), r && this.setValueInternal(r);
|
|
716
851
|
}
|
|
717
852
|
this.originalValue === void 0 && (this.originalValue = this.value), this._previousValue = this.value, this.actions.triggerEager(this, this.value, this.originalValue);
|
|
718
853
|
}
|
|
719
854
|
processSetValueItem(t) {
|
|
720
855
|
let e;
|
|
721
|
-
return t instanceof
|
|
856
|
+
return t instanceof _ ? e = t : this._itemTemplate ? e = this._itemTemplate.clone({ value: t }) : e = _.createFromFormData(t), Object.defineProperty(e, "parent", { get: () => this, configurable: !1, enumerable: !1 }), e;
|
|
722
857
|
}
|
|
723
858
|
setValueInternal(t) {
|
|
724
859
|
Array.isArray(t) && (this._value = t.map((e) => this.processSetValueItem(e)));
|
|
725
860
|
}
|
|
726
861
|
get value() {
|
|
727
862
|
var e;
|
|
728
|
-
const t = (e = this._value) == null ? void 0 : e.map((
|
|
729
|
-
return
|
|
863
|
+
const t = (e = this._value) == null ? void 0 : e.map((n) => n.value);
|
|
864
|
+
return J(t) ? null : t;
|
|
730
865
|
}
|
|
731
866
|
set value(t) {
|
|
732
867
|
const e = this.value;
|
|
733
|
-
this.setValueInternal(t), this.actions.trigger(
|
|
868
|
+
this.setValueInternal(t), this.actions.trigger(d, this, this.value, e), this.parent && this.parent.notifyValueChanged();
|
|
734
869
|
}
|
|
735
870
|
setValue(t) {
|
|
736
871
|
return u(this, null, function* () {
|
|
737
872
|
const e = this.value;
|
|
738
|
-
this.setValueInternal(t), yield this.actions.trigger(
|
|
873
|
+
this.setValueInternal(t), yield this.actions.trigger(d, this, this.value, e), this.parent && (yield this.parent.notifyValueChanged());
|
|
739
874
|
});
|
|
740
875
|
}
|
|
741
876
|
clone(t) {
|
|
742
|
-
var e,
|
|
743
|
-
return new
|
|
744
|
-
value: [...(
|
|
877
|
+
var e, n, r, a, l;
|
|
878
|
+
return new tt((e = this._itemTemplate) == null ? void 0 : e.clone(), F(A({
|
|
879
|
+
value: [...(n = t == null ? void 0 : t.value) != null ? n : this.value]
|
|
745
880
|
}, t && "originalValue" in t ? { originalValue: t.originalValue } : {}), {
|
|
746
881
|
errors: [...(r = t == null ? void 0 : t.errors) != null ? r : []],
|
|
747
882
|
enabled: (a = t == null ? void 0 : t.enabled) != null ? a : this.enabled,
|
|
@@ -750,351 +885,252 @@ class J extends y {
|
|
|
750
885
|
}
|
|
751
886
|
notifyValueChanged() {
|
|
752
887
|
const t = this.value;
|
|
753
|
-
if (
|
|
888
|
+
if (!B(t, this._previousValue)) {
|
|
754
889
|
const e = this._previousValue;
|
|
755
|
-
this._previousValue = t, this.actions.trigger(
|
|
890
|
+
this._previousValue = t, this.actions.trigger(d, this, t, e), this.parent && this.parent.notifyValueChanged();
|
|
756
891
|
}
|
|
757
892
|
}
|
|
758
893
|
get(t) {
|
|
759
894
|
return this._value != null ? this._value[t] : void 0;
|
|
760
895
|
}
|
|
761
896
|
push(t) {
|
|
762
|
-
var e,
|
|
763
|
-
return this.insert(t, (
|
|
897
|
+
var e, n;
|
|
898
|
+
return this.insert(t, (n = (e = this._value) == null ? void 0 : e.length) != null ? n : 0) + 1;
|
|
764
899
|
}
|
|
765
900
|
pop() {
|
|
766
901
|
var t, e;
|
|
767
902
|
return this.remove(((e = (t = this._value) == null ? void 0 : t.length) != null ? e : 0) - 1);
|
|
768
903
|
}
|
|
769
904
|
remove(t) {
|
|
770
|
-
var
|
|
905
|
+
var n;
|
|
771
906
|
if (this._value == null || t < 0 || this._value.length <= t) return;
|
|
772
|
-
let e = (
|
|
773
|
-
return e && (e = e.clone(), this.actions.trigger(
|
|
907
|
+
let e = (n = this._value.splice(t, 1)) == null ? void 0 : n[0];
|
|
908
|
+
return e && (e = e.clone(), this.actions.trigger(X, this, e, t), this.notifyValueChanged()), e;
|
|
774
909
|
}
|
|
775
910
|
insert(t, e) {
|
|
776
911
|
for (this._value == null && (this._value = []); this._value.length < e; ) {
|
|
777
912
|
const r = this.processSetValueItem(null), a = this._value.push(r);
|
|
778
|
-
this.actions.trigger(
|
|
913
|
+
this.actions.trigger(U, this, r, a);
|
|
779
914
|
}
|
|
780
|
-
const
|
|
781
|
-
return this._value.splice(e, 0,
|
|
915
|
+
const n = this.processSetValueItem(t);
|
|
916
|
+
return this._value.splice(e, 0, n), this.actions.trigger(U, this, n, e), this.notifyValueChanged(), e;
|
|
782
917
|
}
|
|
783
918
|
clear() {
|
|
784
919
|
this._value = null, this.notifyValueChanged();
|
|
785
920
|
}
|
|
786
921
|
}
|
|
787
|
-
const
|
|
788
|
-
function
|
|
789
|
-
return
|
|
922
|
+
const ht = { useMarkdownInValidators: !0 };
|
|
923
|
+
function Rt() {
|
|
924
|
+
return ht;
|
|
790
925
|
}
|
|
791
|
-
function
|
|
792
|
-
Object.assign(
|
|
926
|
+
function Dt(s) {
|
|
927
|
+
Object.assign(ht, s);
|
|
793
928
|
}
|
|
794
|
-
const
|
|
795
|
-
install(
|
|
796
|
-
i &&
|
|
929
|
+
const te = {
|
|
930
|
+
install(s, i) {
|
|
931
|
+
i && Dt(i);
|
|
797
932
|
}
|
|
798
933
|
};
|
|
799
|
-
|
|
800
|
-
}
|
|
801
|
-
function K(n) {
|
|
802
|
-
const i = d(n);
|
|
803
|
-
return typeof i == "object" && "componentName" in i;
|
|
804
|
-
}
|
|
805
|
-
class Y {
|
|
806
|
-
get componentName() {
|
|
807
|
-
return "Comment";
|
|
808
|
-
}
|
|
809
|
-
// eslint-disable-line class-methods-use-this
|
|
810
|
-
get componentBindings() {
|
|
811
|
-
return {};
|
|
812
|
-
}
|
|
813
|
-
// eslint-disable-line class-methods-use-this
|
|
814
|
-
get componentBody() {
|
|
815
|
-
return "";
|
|
816
|
-
}
|
|
817
|
-
// eslint-disable-line class-methods-use-this
|
|
818
|
-
}
|
|
819
|
-
class Ot extends Y {
|
|
820
|
-
constructor(t) {
|
|
821
|
-
super();
|
|
822
|
-
h(this, "text");
|
|
823
|
-
this.text = t;
|
|
824
|
-
}
|
|
825
|
-
get componentName() {
|
|
826
|
-
return "template";
|
|
827
|
-
}
|
|
828
|
-
// eslint-disable-line class-methods-use-this
|
|
829
|
-
get componentBody() {
|
|
830
|
-
return this.text;
|
|
831
|
-
}
|
|
832
|
-
}
|
|
833
|
-
class m extends Y {
|
|
834
|
-
constructor(t) {
|
|
835
|
-
super();
|
|
836
|
-
h(this, "text");
|
|
837
|
-
h(this, "textType");
|
|
838
|
-
this.text = t, this.textType = lt(() => this.getTextType);
|
|
839
|
-
}
|
|
840
|
-
get getTextType() {
|
|
841
|
-
const t = d(this.text);
|
|
842
|
-
return t ? t instanceof P ? "md" : K(t) ? "component" : "string" : "string";
|
|
843
|
-
}
|
|
844
|
-
get componentName() {
|
|
845
|
-
switch (d(this.textType)) {
|
|
846
|
-
case "string":
|
|
847
|
-
return "template";
|
|
848
|
-
case "md":
|
|
849
|
-
return "vue-markdown";
|
|
850
|
-
case "component":
|
|
851
|
-
return d(this.text).componentName;
|
|
852
|
-
default:
|
|
853
|
-
return "template";
|
|
854
|
-
}
|
|
855
|
-
}
|
|
856
|
-
get componentBindings() {
|
|
857
|
-
switch (d(this.textType)) {
|
|
858
|
-
case "string":
|
|
859
|
-
return {};
|
|
860
|
-
case "md":
|
|
861
|
-
return { source: this.text.toString() };
|
|
862
|
-
case "component":
|
|
863
|
-
return d(this.text).componentProps;
|
|
864
|
-
default:
|
|
865
|
-
return {};
|
|
866
|
-
}
|
|
867
|
-
}
|
|
868
|
-
get componentBody() {
|
|
869
|
-
switch (d(this.textType)) {
|
|
870
|
-
case "string":
|
|
871
|
-
return d(this.text);
|
|
872
|
-
default:
|
|
873
|
-
return "";
|
|
874
|
-
}
|
|
875
|
-
}
|
|
876
|
-
}
|
|
877
|
-
function v(n) {
|
|
878
|
-
return Ft().useMarkdownInValidators ? new P(n) : n.replace(/[*_~`]/g, "").replace(/\[.*?\]\((.*?)\)/g, "$1").replace(/!\[.*?\]\((.*?)\)/g, "").replace(/#+\s?/g, "").replace(/>\s?/g, "").replace(/(\*|-|\d+\.)\s+/g, "").replace(/`{3}[\s\S]*?`{3}/g, "").replace(/`([^`]+)`/g, "$1").replace(/\n{2,}/g, `
|
|
934
|
+
function E(s) {
|
|
935
|
+
return Rt().useMarkdownInValidators ? new L(s) : s.replace(/[*_~`]/g, "").replace(/\[.*?\]\((.*?)\)/g, "$1").replace(/!\[.*?\]\((.*?)\)/g, "").replace(/#+\s?/g, "").replace(/>\s?/g, "").replace(/(\*|-|\d+\.)\s+/g, "").replace(/`{3}[\s\S]*?`{3}/g, "").replace(/`([^`]+)`/g, "$1").replace(/\n{2,}/g, `
|
|
879
936
|
`);
|
|
880
937
|
}
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
885
|
-
|
|
886
|
-
|
|
887
|
-
|
|
888
|
-
|
|
889
|
-
|
|
890
|
-
|
|
891
|
-
|
|
892
|
-
|
|
893
|
-
|
|
894
|
-
|
|
895
|
-
if (_.source === this.source) {
|
|
896
|
-
const U = c.findIndex((ht) => $(ht, _));
|
|
897
|
-
U >= 0 ? c.splice(U, 1) : s.errors.splice(o, 1);
|
|
898
|
-
}
|
|
899
|
-
}
|
|
900
|
-
return c.length > 0 && s.errors.push(...c), s.validate(), r(s, a, l);
|
|
901
|
-
}));
|
|
902
|
-
h(this, "source");
|
|
903
|
-
this.source = Symbol(this.constructor.name);
|
|
904
|
-
}
|
|
905
|
-
// eslint-disable-next-line class-methods-use-this
|
|
906
|
-
static get classIdentifier() {
|
|
907
|
-
return Pt;
|
|
908
|
-
}
|
|
909
|
-
// eslint-disable-next-line class-methods-use-this
|
|
910
|
-
get eager() {
|
|
911
|
-
return !0;
|
|
938
|
+
class $t extends b {
|
|
939
|
+
constructor(t, e, n) {
|
|
940
|
+
let r = !1, a, l;
|
|
941
|
+
super((o, m, S) => (a = o, l = m, r || (r = !0, this.otherField.registerAction(new d((G, ft, gt, dt) => u(this, null, function* () {
|
|
942
|
+
yield ft(G, gt, dt), this.unregistered || (yield this.execute(S, () => u(this, null, function* () {
|
|
943
|
+
return null;
|
|
944
|
+
}), a, l));
|
|
945
|
+
})))), this.isValidComparison(g(o), g(this.otherField.value)) ? null : [
|
|
946
|
+
new y(
|
|
947
|
+
this.replacePlaceholders(n, { newValue: o, oldValue: m, field: S, otherField: this.otherField })
|
|
948
|
+
)
|
|
949
|
+
]));
|
|
950
|
+
h(this, "unregistered", !1);
|
|
951
|
+
this.otherField = t, this.isValidComparison = e;
|
|
912
952
|
}
|
|
913
|
-
|
|
914
|
-
|
|
915
|
-
if (K(t)) return t;
|
|
916
|
-
let s = t;
|
|
917
|
-
return Object.keys(e).forEach((r) => {
|
|
918
|
-
s = s.replaceAll(`{${r}}`, e[r]);
|
|
919
|
-
}), t instanceof P ? new P(s) : s;
|
|
953
|
+
unregister() {
|
|
954
|
+
this.unregistered = !0;
|
|
920
955
|
}
|
|
921
956
|
}
|
|
922
|
-
class
|
|
957
|
+
class Bt extends b {
|
|
923
958
|
constructor(i, t) {
|
|
924
|
-
const e = t ||
|
|
925
|
-
let
|
|
926
|
-
|
|
959
|
+
const e = t || E("Must be one of [**{allowedAsText}**]");
|
|
960
|
+
let n = i.join(", ");
|
|
961
|
+
n.length > 60 && (n = xt(n, {
|
|
927
962
|
length: 40,
|
|
928
963
|
separator: ", ",
|
|
929
964
|
omission: `... (${i.length} items total)`
|
|
930
965
|
}));
|
|
931
|
-
const r = (a, l, c) => i.includes(
|
|
932
|
-
new
|
|
933
|
-
this.replacePlaceholders(e, { newValue: a, oldValue: l, field: c, allowedValues: i, allowedAsText:
|
|
966
|
+
const r = (a, l, c) => i.includes(g(a)) ? null : [
|
|
967
|
+
new y(
|
|
968
|
+
this.replacePlaceholders(e, { newValue: a, oldValue: l, field: c, allowedValues: i, allowedAsText: n })
|
|
934
969
|
)
|
|
935
970
|
];
|
|
936
971
|
super(r);
|
|
937
972
|
}
|
|
938
973
|
}
|
|
939
|
-
function
|
|
940
|
-
return
|
|
974
|
+
function kt(s) {
|
|
975
|
+
return s == null ? 0 : lt(s) || C(s) ? s.length : ct(s) && Object.getPrototypeOf(s) === Object.prototype ? Object.keys(s).length : String(s).length;
|
|
941
976
|
}
|
|
942
|
-
class
|
|
977
|
+
class qt extends b {
|
|
943
978
|
constructor(i) {
|
|
944
|
-
const t = i ||
|
|
945
|
-
this.replacePlaceholders(t, { newValue:
|
|
979
|
+
const t = i || E("Please enter a value"), e = (n, r, a) => kt(g(n)) === 0 ? [new y(
|
|
980
|
+
this.replacePlaceholders(t, { newValue: n, oldValue: r, field: a })
|
|
946
981
|
)] : null;
|
|
947
982
|
super(e);
|
|
948
983
|
}
|
|
949
984
|
}
|
|
950
|
-
class
|
|
985
|
+
class Mt extends b {
|
|
951
986
|
constructor(i, t) {
|
|
952
|
-
const e = t ||
|
|
953
|
-
new
|
|
987
|
+
const e = t || E("Value must be larger or equal to **{minValue}**"), n = (r, a, l) => r < i || r === void 0 ? [
|
|
988
|
+
new y(this.replacePlaceholders(e, { newValue: r, oldValue: a, field: l, minValue: i }))
|
|
954
989
|
] : null;
|
|
955
|
-
super(
|
|
990
|
+
super(n);
|
|
956
991
|
}
|
|
957
992
|
}
|
|
958
|
-
class
|
|
993
|
+
class Qt extends b {
|
|
959
994
|
constructor(i, t) {
|
|
960
|
-
const e = t ||
|
|
961
|
-
new
|
|
995
|
+
const e = t || E("Value must be less than or equal to **{maxValue}**"), n = (r, a, l) => r > i || r === void 0 ? [
|
|
996
|
+
new y(this.replacePlaceholders(e, { newValue: r, oldValue: a, field: l, maxValue: i }))
|
|
962
997
|
] : null;
|
|
963
|
-
super(
|
|
998
|
+
super(n);
|
|
964
999
|
}
|
|
965
1000
|
}
|
|
966
|
-
class
|
|
1001
|
+
class zt extends b {
|
|
967
1002
|
constructor(i, t, e) {
|
|
968
|
-
const
|
|
969
|
-
new
|
|
970
|
-
this.replacePlaceholders(
|
|
1003
|
+
const n = e || E("Value must be between **{minValue}** and **{maxValue}**"), r = (a, l, c) => a < i || a > t || a === void 0 ? [
|
|
1004
|
+
new y(
|
|
1005
|
+
this.replacePlaceholders(n, { newValue: a, oldValue: l, field: c, minValue: i, maxValue: t })
|
|
971
1006
|
)
|
|
972
1007
|
] : null;
|
|
973
1008
|
super(r);
|
|
974
1009
|
}
|
|
975
1010
|
}
|
|
976
|
-
function
|
|
977
|
-
return
|
|
1011
|
+
function et(s) {
|
|
1012
|
+
return s == null ? 0 : lt(s) || C(s) ? s.length : ct(s) && Object.getPrototypeOf(s) === Object.prototype ? Object.keys(s).length : String(s).length;
|
|
978
1013
|
}
|
|
979
|
-
class
|
|
1014
|
+
class Ht extends b {
|
|
980
1015
|
constructor(i, t) {
|
|
981
|
-
const e = t ||
|
|
982
|
-
new
|
|
1016
|
+
const e = t || E("Length must be larger or equal to **{minLength}**"), n = (r, a, l) => et(r) < i ? [
|
|
1017
|
+
new y(this.replacePlaceholders(e, { newValue: r, oldValue: a, field: l, minLength: i }))
|
|
983
1018
|
] : null;
|
|
984
|
-
super(
|
|
1019
|
+
super(n);
|
|
985
1020
|
}
|
|
986
1021
|
}
|
|
987
|
-
class
|
|
1022
|
+
class Xt extends b {
|
|
988
1023
|
constructor(i, t) {
|
|
989
|
-
const e = t ||
|
|
990
|
-
new
|
|
1024
|
+
const e = t || E("Length must be less than or equal to **{maxLength}**"), n = (r, a, l) => et(r) > i ? [
|
|
1025
|
+
new y(this.replacePlaceholders(e, { newValue: r, oldValue: a, field: l, maxLength: i }))
|
|
991
1026
|
] : null;
|
|
992
|
-
super(
|
|
1027
|
+
super(n);
|
|
993
1028
|
}
|
|
994
1029
|
}
|
|
995
|
-
class
|
|
1030
|
+
class Gt extends b {
|
|
996
1031
|
constructor(i, t, e) {
|
|
997
|
-
const
|
|
998
|
-
const o =
|
|
1032
|
+
const n = e || E("Length must be between **{minLength}** and **{maxLength}**"), r = (a, l, c) => {
|
|
1033
|
+
const o = et(a);
|
|
999
1034
|
return o < i || o > t ? [
|
|
1000
|
-
new
|
|
1001
|
-
this.replacePlaceholders(
|
|
1035
|
+
new y(
|
|
1036
|
+
this.replacePlaceholders(n, { newValue: a, oldValue: l, field: c, minLength: i, maxLength: t })
|
|
1002
1037
|
)
|
|
1003
1038
|
] : null;
|
|
1004
1039
|
};
|
|
1005
1040
|
super(r);
|
|
1006
1041
|
}
|
|
1007
1042
|
}
|
|
1008
|
-
class
|
|
1043
|
+
class Wt extends b {
|
|
1009
1044
|
constructor(i, t) {
|
|
1010
|
-
const e = t ||
|
|
1011
|
-
new
|
|
1045
|
+
const e = t || E('Value must match pattern "**{pattern}**"'), n = (r, a, l) => i.test(String(g(r))) ? null : [
|
|
1046
|
+
new y(this.replacePlaceholders(e, { newValue: r, oldValue: a, field: l, pattern: i }))
|
|
1012
1047
|
];
|
|
1013
|
-
super(
|
|
1048
|
+
super(n);
|
|
1014
1049
|
}
|
|
1015
1050
|
}
|
|
1016
|
-
const
|
|
1051
|
+
const Jt = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1017
1052
|
__proto__: null,
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1024
|
-
|
|
1025
|
-
|
|
1026
|
-
|
|
1027
|
-
|
|
1053
|
+
CompareTo: $t,
|
|
1054
|
+
InAllowedValues: Bt,
|
|
1055
|
+
LengthInRange: Gt,
|
|
1056
|
+
MaxLength: Xt,
|
|
1057
|
+
MaxValue: Qt,
|
|
1058
|
+
MinLength: Ht,
|
|
1059
|
+
MinValue: Mt,
|
|
1060
|
+
Pattern: Wt,
|
|
1061
|
+
Required: qt,
|
|
1062
|
+
ValueInRange: zt
|
|
1063
|
+
}, Symbol.toStringTag, { value: "Module" })), ee = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1028
1064
|
__proto__: null,
|
|
1029
|
-
AbortEventHandlingException:
|
|
1030
|
-
Action:
|
|
1031
|
-
ActionsMap:
|
|
1032
|
-
ConditionalEnabledAction:
|
|
1033
|
-
ConditionalStatementAction:
|
|
1034
|
-
ConditionalValueAction:
|
|
1035
|
-
ConditionalVisibilityAction:
|
|
1036
|
-
DisplayMode:
|
|
1037
|
-
EmptyField:
|
|
1038
|
-
EnabledChangedAction:
|
|
1039
|
-
EnabledChangingAction:
|
|
1040
|
-
ExecuteAction:
|
|
1041
|
-
Field:
|
|
1042
|
-
FieldActionBase:
|
|
1043
|
-
FieldBase:
|
|
1044
|
-
Group:
|
|
1045
|
-
List:
|
|
1046
|
-
ListItemAddedAction:
|
|
1047
|
-
ListItemRemovedAction:
|
|
1048
|
-
MdString:
|
|
1065
|
+
AbortEventHandlingException: K,
|
|
1066
|
+
Action: $,
|
|
1067
|
+
ActionsMap: k,
|
|
1068
|
+
ConditionalEnabledAction: Ct,
|
|
1069
|
+
ConditionalStatementAction: q,
|
|
1070
|
+
ConditionalValueAction: Vt,
|
|
1071
|
+
ConditionalVisibilityAction: St,
|
|
1072
|
+
DisplayMode: I,
|
|
1073
|
+
EmptyField: Ut,
|
|
1074
|
+
EnabledChangedAction: P,
|
|
1075
|
+
EnabledChangingAction: M,
|
|
1076
|
+
ExecuteAction: H,
|
|
1077
|
+
Field: V,
|
|
1078
|
+
FieldActionBase: p,
|
|
1079
|
+
FieldBase: x,
|
|
1080
|
+
Group: _,
|
|
1081
|
+
List: tt,
|
|
1082
|
+
ListItemAddedAction: U,
|
|
1083
|
+
ListItemRemovedAction: X,
|
|
1084
|
+
MdString: L,
|
|
1049
1085
|
Operator: f,
|
|
1050
1086
|
Statement: j,
|
|
1051
|
-
ValidChangedAction:
|
|
1052
|
-
ValidationError:
|
|
1053
|
-
ValidationErrorRenderContent:
|
|
1054
|
-
ValidationErrorText:
|
|
1055
|
-
Validator:
|
|
1056
|
-
Validators:
|
|
1057
|
-
ValueChangedAction:
|
|
1058
|
-
VisibilityChangedAction:
|
|
1059
|
-
VisibilityChangingAction:
|
|
1060
|
-
buildErrorMessage:
|
|
1061
|
-
isCustomModalContentComponentDef:
|
|
1087
|
+
ValidChangedAction: Q,
|
|
1088
|
+
ValidationError: Z,
|
|
1089
|
+
ValidationErrorRenderContent: y,
|
|
1090
|
+
ValidationErrorText: Et,
|
|
1091
|
+
Validator: b,
|
|
1092
|
+
Validators: Jt,
|
|
1093
|
+
ValueChangedAction: d,
|
|
1094
|
+
VisibilityChangedAction: O,
|
|
1095
|
+
VisibilityChangingAction: z,
|
|
1096
|
+
buildErrorMessage: E,
|
|
1097
|
+
isCustomModalContentComponentDef: Y
|
|
1062
1098
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
1063
1099
|
export {
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1100
|
+
K as AbortEventHandlingException,
|
|
1101
|
+
$ as Action,
|
|
1102
|
+
k as ActionsMap,
|
|
1103
|
+
Ct as ConditionalEnabledAction,
|
|
1104
|
+
q as ConditionalStatementAction,
|
|
1105
|
+
Vt as ConditionalValueAction,
|
|
1106
|
+
St as ConditionalVisibilityAction,
|
|
1107
|
+
I as DisplayMode,
|
|
1108
|
+
Ut as EmptyField,
|
|
1109
|
+
P as EnabledChangedAction,
|
|
1110
|
+
M as EnabledChangingAction,
|
|
1111
|
+
H as ExecuteAction,
|
|
1112
|
+
V as Field,
|
|
1113
|
+
p as FieldActionBase,
|
|
1114
|
+
x as FieldBase,
|
|
1115
|
+
_ as Group,
|
|
1116
|
+
tt as List,
|
|
1117
|
+
U as ListItemAddedAction,
|
|
1118
|
+
X as ListItemRemovedAction,
|
|
1119
|
+
L as MdString,
|
|
1084
1120
|
f as Operator,
|
|
1085
1121
|
j as Statement,
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1122
|
+
Q as ValidChangedAction,
|
|
1123
|
+
Z as ValidationError,
|
|
1124
|
+
y as ValidationErrorRenderContent,
|
|
1125
|
+
Et as ValidationErrorText,
|
|
1126
|
+
b as Validator,
|
|
1127
|
+
Jt as Validators,
|
|
1128
|
+
d as ValueChangedAction,
|
|
1129
|
+
O as VisibilityChangedAction,
|
|
1130
|
+
z as VisibilityChangingAction,
|
|
1131
|
+
E as buildErrorMessage,
|
|
1132
|
+
ee as default,
|
|
1133
|
+
te as forms,
|
|
1134
|
+
Y as isCustomModalContentComponentDef
|
|
1099
1135
|
};
|
|
1100
1136
|
//# sourceMappingURL=dynamicforms-vue-forms.js.map
|