@overmap-ai/forms 1.0.36 → 1.0.37-condition-serialize-improvements.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/forms.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
var ws = Object.defineProperty;
|
|
2
2
|
var Cs = (r, e, t) => e in r ? ws(r, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : r[e] = t;
|
|
3
3
|
var b = (r, e, t) => Cs(r, typeof e != "symbol" ? e + "" : e, t);
|
|
4
|
-
import { jsxs as _, jsx as p, Fragment as
|
|
4
|
+
import { jsxs as _, jsx as p, Fragment as Qe } from "react/jsx-runtime";
|
|
5
5
|
import { Card as dt, LuIcon as R, Text as Ve, Spinner as Ba, Overlay as pt, ButtonGroup as he, Tooltip as er, IconButton as ae, Separator as mr, Input as Te, Badge as Ee, Checkbox as $r, CheckboxGroup as Tn, Popover as Ne, Button as U, DayPicker as ka, Menu as M, OneTimePasswordField as Dn, stopPropagation as rn, RadioGroup as tr, TextArea as ar, Rating as Bi, Heading as As, toast as Be, ToggleGroup as Rn, useAlertDialog as _s } from "@overmap-ai/blocks";
|
|
6
6
|
import { cx as wr } from "class-variance-authority";
|
|
7
7
|
import { forwardRef as Rr, createElement as Xn, memo as G, createContext as Mr, useContext as Es, useState as ge, useEffect as Pe, useCallback as T, useMemo as oe, Fragment as La, useRef as nn, use as lt, useLayoutEffect as za, useId as Ss } from "react";
|
|
@@ -161,7 +161,7 @@ const el = [
|
|
|
161
161
|
* This source code is licensed under the ISC license.
|
|
162
162
|
* See the LICENSE file in the root directory of this source tree.
|
|
163
163
|
*/
|
|
164
|
-
const rl = [["path", { d: "M20 6 9 17l-5-5", key: "1gmf2c" }]],
|
|
164
|
+
const rl = [["path", { d: "M20 6 9 17l-5-5", key: "1gmf2c" }]], Je = W("check", rl);
|
|
165
165
|
/**
|
|
166
166
|
* @license lucide-react v0.542.0 - ISC
|
|
167
167
|
*
|
|
@@ -807,10 +807,10 @@ const Xe = G((r) => {
|
|
|
807
807
|
a,
|
|
808
808
|
!!n && /* @__PURE__ */ p(Ve, { accentColor: "danger", size: c, children: n })
|
|
809
809
|
] });
|
|
810
|
-
}),
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
810
|
+
}), b0 = (r, e) => oe(() => !e || !r ? null : r.render(e), [r, e]), Zr = (r, e) => /* @__PURE__ */ p("div", { className: "flex flex-col gap-4", children: r.map((t, n) => /* @__PURE__ */ p(La, { children: t.render({
|
|
811
|
+
index: n,
|
|
812
|
+
...e
|
|
813
|
+
}) }, t.identifier)) }), We = (r) => {
|
|
814
814
|
const { field: e, size: t, showInputOnly: n, onValuesChange: i, ...a } = r, [o, s, l] = Vs(e.identifier), { touched: c } = s, u = s.error ?? "", f = e.identifier, d = `${f}-label`, h = e.required ? `${e.label} *` : e.label, v = e.description ?? "", g = oe(() => ({
|
|
815
815
|
...o,
|
|
816
816
|
// name and value not being overridden
|
|
@@ -1129,7 +1129,7 @@ const oo = G((r) => {
|
|
|
1129
1129
|
accentColor: "base",
|
|
1130
1130
|
variant: "surface",
|
|
1131
1131
|
disabled: u,
|
|
1132
|
-
children: /* @__PURE__ */ p($r.Indicator, { children: /* @__PURE__ */ p(R, { icon:
|
|
1132
|
+
children: /* @__PURE__ */ p($r.Indicator, { children: /* @__PURE__ */ p(R, { icon: Je }) })
|
|
1133
1133
|
}
|
|
1134
1134
|
)
|
|
1135
1135
|
}
|
|
@@ -1230,7 +1230,7 @@ const so = G((r) => {
|
|
|
1230
1230
|
type: "number",
|
|
1231
1231
|
min: a.minimum,
|
|
1232
1232
|
max: a.maximum,
|
|
1233
|
-
step: a.integers ? 1 :
|
|
1233
|
+
step: a.integers ? 1 : "any",
|
|
1234
1234
|
placeholder: a.placeholder ?? "Enter a number",
|
|
1235
1235
|
disabled: d,
|
|
1236
1236
|
onKeyDown: S
|
|
@@ -1491,7 +1491,7 @@ const co = G((r) => {
|
|
|
1491
1491
|
onValuesChange: m,
|
|
1492
1492
|
disabled: u,
|
|
1493
1493
|
children: i.options.map((w, x) => /* @__PURE__ */ _("label", { className: "flex gap-2 items-center min-w-0", children: [
|
|
1494
|
-
/* @__PURE__ */ p(Tn.Item, { value: w.value, children: /* @__PURE__ */ p(Tn.ItemIndicator, { children: /* @__PURE__ */ p(R, { icon:
|
|
1494
|
+
/* @__PURE__ */ p(Tn.Item, { value: w.value, children: /* @__PURE__ */ p(Tn.ItemIndicator, { children: /* @__PURE__ */ p(R, { icon: Je }) }) }),
|
|
1495
1495
|
/* @__PURE__ */ p(Ve, { size: n, accentColor: "base", className: "truncate", children: w.label })
|
|
1496
1496
|
] }, `${e}-${w.value}-${x}`))
|
|
1497
1497
|
}
|
|
@@ -1711,11 +1711,11 @@ const fo = G((r) => {
|
|
|
1711
1711
|
) }),
|
|
1712
1712
|
/* @__PURE__ */ p(M.Content, { size: n, children: /* @__PURE__ */ p(M.Scroll, { children: /* @__PURE__ */ _(M.MultiSelectGroup, { values: f, onValuesChange: m, children: [
|
|
1713
1713
|
/* @__PURE__ */ _(M.SelectAllItem, { children: [
|
|
1714
|
-
/* @__PURE__ */ p(M.CheckboxItemIndicator, { children: (x) => x ? /* @__PURE__ */ p(R, { icon: jr }) : /* @__PURE__ */ p(R, { icon:
|
|
1714
|
+
/* @__PURE__ */ p(M.CheckboxItemIndicator, { children: (x) => x ? /* @__PURE__ */ p(R, { icon: jr }) : /* @__PURE__ */ p(R, { icon: Je }) }),
|
|
1715
1715
|
"Select all"
|
|
1716
1716
|
] }),
|
|
1717
1717
|
a.options.map((x, C) => /* @__PURE__ */ _(M.MultiSelectItem, { value: x.value, children: [
|
|
1718
|
-
/* @__PURE__ */ p(M.SelectedIndicator, { children: /* @__PURE__ */ p(R, { icon:
|
|
1718
|
+
/* @__PURE__ */ p(M.SelectedIndicator, { children: /* @__PURE__ */ p(R, { icon: Je }) }),
|
|
1719
1719
|
x.label
|
|
1720
1720
|
] }, `${e}-${x.value}-${C}`))
|
|
1721
1721
|
] }) }) })
|
|
@@ -1824,7 +1824,7 @@ const ho = G((r) => {
|
|
|
1824
1824
|
}
|
|
1825
1825
|
) }),
|
|
1826
1826
|
/* @__PURE__ */ p(M.Content, { size: n, children: /* @__PURE__ */ p(M.Scroll, { children: /* @__PURE__ */ p(M.SelectGroup, { required: !1, value: v ?? void 0, onValueChange: m, children: a.options.map((x, C) => /* @__PURE__ */ _(M.SelectItem, { value: x.value, children: [
|
|
1827
|
-
/* @__PURE__ */ p(M.SelectedIndicator, { children: /* @__PURE__ */ p(R, { icon:
|
|
1827
|
+
/* @__PURE__ */ p(M.SelectedIndicator, { children: /* @__PURE__ */ p(R, { icon: Je }) }),
|
|
1828
1828
|
x.label
|
|
1829
1829
|
] }, `${e}-${x.value}-${C}`)) }) }) })
|
|
1830
1830
|
] })
|
|
@@ -2201,7 +2201,7 @@ const dc = G(
|
|
|
2201
2201
|
/* @__PURE__ */ p(R, { icon: Ya }),
|
|
2202
2202
|
" Download"
|
|
2203
2203
|
] }),
|
|
2204
|
-
n ? null : /* @__PURE__ */ _(
|
|
2204
|
+
n ? null : /* @__PURE__ */ _(Qe, { children: [
|
|
2205
2205
|
/* @__PURE__ */ p(M.Separator, {}),
|
|
2206
2206
|
/* @__PURE__ */ _(M.Item, { onSelect: t, children: [
|
|
2207
2207
|
/* @__PURE__ */ p(R, { icon: Pt }),
|
|
@@ -2337,7 +2337,7 @@ const vo = G((r) => {
|
|
|
2337
2337
|
})
|
|
2338
2338
|
}
|
|
2339
2339
|
),
|
|
2340
|
-
S && /* @__PURE__ */ _(
|
|
2340
|
+
S && /* @__PURE__ */ _(Qe, { children: [
|
|
2341
2341
|
/* @__PURE__ */ p("div", { children: /* @__PURE__ */ p(
|
|
2342
2342
|
ar,
|
|
2343
2343
|
{
|
|
@@ -2774,7 +2774,7 @@ b(Yt, "fieldTypeName", "Rating"), b(Yt, "fieldTypeDescription", "Allows users to
|
|
|
2774
2774
|
let Or = Yt;
|
|
2775
2775
|
const mo = Mr(() => {
|
|
2776
2776
|
throw new Error("No ScannerProvider found");
|
|
2777
|
-
}),
|
|
2777
|
+
}), I0 = () => lt(mo);
|
|
2778
2778
|
function mc(r, e) {
|
|
2779
2779
|
var t = Object.setPrototypeOf;
|
|
2780
2780
|
t ? t(r, e) : r.__proto__ = e;
|
|
@@ -3411,7 +3411,7 @@ var Ce = (
|
|
|
3411
3411
|
}
|
|
3412
3412
|
return e.kind = "UnsupportedOperationException", e;
|
|
3413
3413
|
}(Ke)
|
|
3414
|
-
),
|
|
3414
|
+
), rt = (
|
|
3415
3415
|
/** @class */
|
|
3416
3416
|
function() {
|
|
3417
3417
|
function r() {
|
|
@@ -3458,7 +3458,7 @@ var Ce = (
|
|
|
3458
3458
|
return r.castAsNonUtf8Char = function(e, t) {
|
|
3459
3459
|
t === void 0 && (t = null);
|
|
3460
3460
|
var n = t ? t.getName() : this.ISO88591;
|
|
3461
|
-
return
|
|
3461
|
+
return rt.decode(new Uint8Array([e]), n);
|
|
3462
3462
|
}, r.guessEncoding = function(e, t) {
|
|
3463
3463
|
if (t != null && t.get(ve.CHARACTER_SET) !== void 0)
|
|
3464
3464
|
return t.get(ve.CHARACTER_SET).toString();
|
|
@@ -3512,7 +3512,7 @@ var Ce = (
|
|
|
3512
3512
|
var o = /%(-)?(0?[0-9]+)?([.][0-9]+)?([#][0-9]+)?([scfpexd%])/g;
|
|
3513
3513
|
return e.replace(o, a);
|
|
3514
3514
|
}, r.getBytes = function(e, t) {
|
|
3515
|
-
return
|
|
3515
|
+
return rt.encode(e, t);
|
|
3516
3516
|
}, r.getCharCode = function(e, t) {
|
|
3517
3517
|
return t === void 0 && (t = 0), e.charCodeAt(t);
|
|
3518
3518
|
}, r.getCharAt = function(e) {
|
|
@@ -10401,7 +10401,7 @@ var nf = (
|
|
|
10401
10401
|
}
|
|
10402
10402
|
n.push(s);
|
|
10403
10403
|
try {
|
|
10404
|
-
t.append(
|
|
10404
|
+
t.append(rt.decode(s, Q.ISO88591));
|
|
10405
10405
|
} catch (c) {
|
|
10406
10406
|
throw new Pr("Platform does not support required encoding: " + c.message);
|
|
10407
10407
|
}
|
|
@@ -11283,10 +11283,10 @@ var ia = (
|
|
|
11283
11283
|
return this.codewords;
|
|
11284
11284
|
}, r;
|
|
11285
11285
|
}()
|
|
11286
|
-
),
|
|
11286
|
+
), et;
|
|
11287
11287
|
(function(r) {
|
|
11288
11288
|
r[r.TERMINATOR = 0] = "TERMINATOR", r[r.NUMERIC = 1] = "NUMERIC", r[r.ALPHANUMERIC = 2] = "ALPHANUMERIC", r[r.STRUCTURED_APPEND = 3] = "STRUCTURED_APPEND", r[r.BYTE = 4] = "BYTE", r[r.ECI = 5] = "ECI", r[r.KANJI = 6] = "KANJI", r[r.FNC1_FIRST_POSITION = 7] = "FNC1_FIRST_POSITION", r[r.FNC1_SECOND_POSITION = 8] = "FNC1_SECOND_POSITION", r[r.HANZI = 9] = "HANZI";
|
|
11289
|
-
})(
|
|
11289
|
+
})(et || (et = {}));
|
|
11290
11290
|
var de = (
|
|
11291
11291
|
/** @class */
|
|
11292
11292
|
function() {
|
|
@@ -11312,7 +11312,7 @@ var de = (
|
|
|
11312
11312
|
return this.value === t.value;
|
|
11313
11313
|
}, r.prototype.toString = function() {
|
|
11314
11314
|
return this.stringValue;
|
|
11315
|
-
}, r.FOR_BITS = /* @__PURE__ */ new Map(), r.FOR_VALUE = /* @__PURE__ */ new Map(), r.TERMINATOR = new r(
|
|
11315
|
+
}, r.FOR_BITS = /* @__PURE__ */ new Map(), r.FOR_VALUE = /* @__PURE__ */ new Map(), r.TERMINATOR = new r(et.TERMINATOR, "TERMINATOR", Int32Array.from([0, 0, 0]), 0), r.NUMERIC = new r(et.NUMERIC, "NUMERIC", Int32Array.from([10, 12, 14]), 1), r.ALPHANUMERIC = new r(et.ALPHANUMERIC, "ALPHANUMERIC", Int32Array.from([9, 11, 13]), 2), r.STRUCTURED_APPEND = new r(et.STRUCTURED_APPEND, "STRUCTURED_APPEND", Int32Array.from([0, 0, 0]), 3), r.BYTE = new r(et.BYTE, "BYTE", Int32Array.from([8, 16, 16]), 4), r.ECI = new r(et.ECI, "ECI", Int32Array.from([0, 0, 0]), 7), r.KANJI = new r(et.KANJI, "KANJI", Int32Array.from([8, 10, 12]), 8), r.FNC1_FIRST_POSITION = new r(et.FNC1_FIRST_POSITION, "FNC1_FIRST_POSITION", Int32Array.from([0, 0, 0]), 5), r.FNC1_SECOND_POSITION = new r(et.FNC1_SECOND_POSITION, "FNC1_SECOND_POSITION", Int32Array.from([0, 0, 0]), 9), r.HANZI = new r(et.HANZI, "HANZI", Int32Array.from([8, 10, 12]), 13), r;
|
|
11316
11316
|
}()
|
|
11317
11317
|
), vf = (
|
|
11318
11318
|
/** @class */
|
|
@@ -11386,7 +11386,7 @@ var de = (
|
|
|
11386
11386
|
s & 255, a += 2, n--;
|
|
11387
11387
|
}
|
|
11388
11388
|
try {
|
|
11389
|
-
t.append(
|
|
11389
|
+
t.append(rt.decode(i, Q.GB2312));
|
|
11390
11390
|
} catch (l) {
|
|
11391
11391
|
throw new V(l);
|
|
11392
11392
|
}
|
|
@@ -11400,7 +11400,7 @@ var de = (
|
|
|
11400
11400
|
s, a += 2, n--;
|
|
11401
11401
|
}
|
|
11402
11402
|
try {
|
|
11403
|
-
t.append(
|
|
11403
|
+
t.append(rt.decode(i, Q.SHIFT_JIS));
|
|
11404
11404
|
} catch (l) {
|
|
11405
11405
|
throw new V(l);
|
|
11406
11406
|
}
|
|
@@ -11413,7 +11413,7 @@ var de = (
|
|
|
11413
11413
|
var c;
|
|
11414
11414
|
i === null ? c = Q.guessEncoding(s, o) : c = i.getName();
|
|
11415
11415
|
try {
|
|
11416
|
-
t.append(
|
|
11416
|
+
t.append(rt.decode(s, c));
|
|
11417
11417
|
} catch (u) {
|
|
11418
11418
|
throw new V(u);
|
|
11419
11419
|
}
|
|
@@ -19553,7 +19553,7 @@ var ed = (
|
|
|
19553
19553
|
}
|
|
19554
19554
|
break;
|
|
19555
19555
|
}
|
|
19556
|
-
return a.append(
|
|
19556
|
+
return a.append(rt.decode(o.toByteArray(), n)), i;
|
|
19557
19557
|
}, r.numericCompaction = function(e, t, n) {
|
|
19558
19558
|
for (var i = 0, a = !1, o = new Int32Array(r.MAX_NUMERIC_CODEWORDS); t < e[0] && !a; ) {
|
|
19559
19559
|
var s = e[t++];
|
|
@@ -20662,7 +20662,7 @@ var To = (
|
|
|
20662
20662
|
}, r.isOnlyDoubleByteKanji = function(e) {
|
|
20663
20663
|
var t;
|
|
20664
20664
|
try {
|
|
20665
|
-
t =
|
|
20665
|
+
t = rt.encode(e, Ce.SJIS);
|
|
20666
20666
|
} catch {
|
|
20667
20667
|
return !1;
|
|
20668
20668
|
}
|
|
@@ -20829,7 +20829,7 @@ var To = (
|
|
|
20829
20829
|
}, r.append8BitBytes = function(e, t, n) {
|
|
20830
20830
|
var i;
|
|
20831
20831
|
try {
|
|
20832
|
-
i =
|
|
20832
|
+
i = rt.encode(e, n);
|
|
20833
20833
|
} catch (l) {
|
|
20834
20834
|
throw new fe(l);
|
|
20835
20835
|
}
|
|
@@ -20840,7 +20840,7 @@ var To = (
|
|
|
20840
20840
|
}, r.appendKanjiBytes = function(e, t) {
|
|
20841
20841
|
var n;
|
|
20842
20842
|
try {
|
|
20843
|
-
n =
|
|
20843
|
+
n = rt.encode(e, Ce.SJIS);
|
|
20844
20844
|
} catch (f) {
|
|
20845
20845
|
throw new fe(f);
|
|
20846
20846
|
}
|
|
@@ -21830,7 +21830,7 @@ var pa = 129, Do = 230, md = 231, wd = 235, Cd = 236, Ad = 237, _d = 238, Ed = 2
|
|
|
21830
21830
|
}
|
|
21831
21831
|
return r.prototype.canEncode = function(e) {
|
|
21832
21832
|
try {
|
|
21833
|
-
return
|
|
21833
|
+
return rt.encode(e, this.charset) != null;
|
|
21834
21834
|
} catch {
|
|
21835
21835
|
return !1;
|
|
21836
21836
|
}
|
|
@@ -21957,7 +21957,7 @@ var pa = 129, Do = 230, md = 231, wd = 235, Cd = 236, Ad = 237, _d = 238, Ed = 2
|
|
|
21957
21957
|
}, r.prototype.encode = function(e, t) {
|
|
21958
21958
|
if (!(t < this.length()))
|
|
21959
21959
|
throw new Error("index must be less than length");
|
|
21960
|
-
return
|
|
21960
|
+
return rt.encode(Q.getCharAt(e), this.encoders[t].name);
|
|
21961
21961
|
}, r;
|
|
21962
21962
|
}()
|
|
21963
21963
|
), zd = 3, Ud = (
|
|
@@ -22222,7 +22222,7 @@ var Yd = [
|
|
|
22222
22222
|
"DIGIT",
|
|
22223
22223
|
"MIXED",
|
|
22224
22224
|
"PUNCT"
|
|
22225
|
-
], At = 0, Jr = 1,
|
|
22225
|
+
], At = 0, Jr = 1, tt = 2, Ro = 3, ft = 4, Zd = new wi(null, 0, 0), Un = [
|
|
22226
22226
|
Int32Array.from([
|
|
22227
22227
|
0,
|
|
22228
22228
|
(5 << 16) + 28,
|
|
@@ -22288,7 +22288,7 @@ function Qd(r) {
|
|
|
22288
22288
|
if (e) throw e.error;
|
|
22289
22289
|
}
|
|
22290
22290
|
}
|
|
22291
|
-
return r[At][ft] = 0, r[Jr][ft] = 0, r[Jr][At] = 28, r[Ro][ft] = 0, r[
|
|
22291
|
+
return r[At][ft] = 0, r[Jr][ft] = 0, r[Jr][At] = 28, r[Ro][ft] = 0, r[tt][ft] = 0, r[tt][At] = 15, r;
|
|
22292
22292
|
}
|
|
22293
22293
|
var Mo = Qd(Ae.createInt32Array(6, 6)), Jd = function(r) {
|
|
22294
22294
|
var e = typeof Symbol == "function" && Symbol.iterator, t = e && r[e], n = 0;
|
|
@@ -22319,14 +22319,14 @@ var Mo = Qd(Ae.createInt32Array(6, 6)), Jd = function(r) {
|
|
|
22319
22319
|
var a = Un[this.mode][e];
|
|
22320
22320
|
i = dr(i, a & 65535, a >> 16), n += a >> 16;
|
|
22321
22321
|
}
|
|
22322
|
-
var o = e ===
|
|
22322
|
+
var o = e === tt ? 4 : 5;
|
|
22323
22323
|
return i = dr(i, t, o), new r(i, e, 0, n + o);
|
|
22324
22324
|
}, r.prototype.shiftAndAppend = function(e, t) {
|
|
22325
|
-
var n = this.token, i = this.mode ===
|
|
22325
|
+
var n = this.token, i = this.mode === tt ? 4 : 5;
|
|
22326
22326
|
return n = dr(n, Mo[this.mode][e], i), n = dr(n, t, 5), new r(n, this.mode, 0, this.bitCount + i + 5);
|
|
22327
22327
|
}, r.prototype.addBinaryShiftChar = function(e) {
|
|
22328
22328
|
var t = this.token, n = this.mode, i = this.bitCount;
|
|
22329
|
-
if (this.mode === ft || this.mode ===
|
|
22329
|
+
if (this.mode === ft || this.mode === tt) {
|
|
22330
22330
|
var a = Un[n][At];
|
|
22331
22331
|
t = dr(t, a & 65535, a >> 16), i += a >> 16, n = At;
|
|
22332
22332
|
}
|
|
@@ -22374,10 +22374,10 @@ function t1(r) {
|
|
|
22374
22374
|
r[Jr][e] = 1;
|
|
22375
22375
|
for (var s = Q.getCharCode("z"), l = Q.getCharCode("a"), o = l; o <= s; o++)
|
|
22376
22376
|
r[Jr][o] = o - l + 2;
|
|
22377
|
-
r[
|
|
22377
|
+
r[tt][e] = 1;
|
|
22378
22378
|
for (var c = Q.getCharCode("9"), u = Q.getCharCode("0"), o = u; o <= c; o++)
|
|
22379
|
-
r[
|
|
22380
|
-
r[
|
|
22379
|
+
r[tt][o] = o - u + 2;
|
|
22380
|
+
r[tt][n] = 12, r[tt][t] = 13;
|
|
22381
22381
|
for (var f = [
|
|
22382
22382
|
"\0",
|
|
22383
22383
|
" ",
|
|
@@ -22508,7 +22508,7 @@ var Hn = t1(Ae.createInt32Array(5, 256)), Hr = function(r) {
|
|
|
22508
22508
|
for (var i = this.text[t] & 255, a = Hn[e.getMode()][i] > 0, o = null, s = 0; s <= ft; s++) {
|
|
22509
22509
|
var l = Hn[s][i];
|
|
22510
22510
|
if (l > 0) {
|
|
22511
|
-
if (o == null && (o = e.endBinaryShift(t)), !a || s === e.getMode() || s ===
|
|
22511
|
+
if (o == null && (o = e.endBinaryShift(t)), !a || s === e.getMode() || s === tt) {
|
|
22512
22512
|
var c = o.latchAndAppend(s, l);
|
|
22513
22513
|
n.push(c);
|
|
22514
22514
|
}
|
|
@@ -22542,7 +22542,7 @@ var Hn = t1(Ae.createInt32Array(5, 256)), Hr = function(r) {
|
|
|
22542
22542
|
}, r.updateStateForPair = function(e, t, n, i) {
|
|
22543
22543
|
var a = e.endBinaryShift(t);
|
|
22544
22544
|
if (i.push(a.latchAndAppend(ft, n)), e.getMode() !== ft && i.push(a.shiftAndAppend(ft, n)), n === 3 || n === 4) {
|
|
22545
|
-
var o = a.latchAndAppend(
|
|
22545
|
+
var o = a.latchAndAppend(tt, 16 - n).latchAndAppend(tt, 1);
|
|
22546
22546
|
i.push(o);
|
|
22547
22547
|
}
|
|
22548
22548
|
if (e.getBinaryShiftByteCount() > 0) {
|
|
@@ -23722,36 +23722,36 @@ class qe extends on {
|
|
|
23722
23722
|
}
|
|
23723
23723
|
const Zo = G, Mt = Zo(function(r) {
|
|
23724
23724
|
const { ref: e, children: t, ...n } = r, i = T(
|
|
23725
|
-
(a) => typeof t == "function" ? /* @__PURE__ */ _(
|
|
23725
|
+
(a) => typeof t == "function" ? /* @__PURE__ */ _(Qe, { children: [
|
|
23726
23726
|
t(a),
|
|
23727
|
-
/* @__PURE__ */ p(M.SelectedIndicator, { className: "ml-[auto]", children: /* @__PURE__ */ p(R, { icon:
|
|
23728
|
-
] }) : /* @__PURE__ */ _(
|
|
23727
|
+
/* @__PURE__ */ p(M.SelectedIndicator, { className: "ml-[auto]", children: /* @__PURE__ */ p(R, { icon: Je }) })
|
|
23728
|
+
] }) : /* @__PURE__ */ _(Qe, { children: [
|
|
23729
23729
|
t,
|
|
23730
|
-
/* @__PURE__ */ p(M.SelectedIndicator, { className: "ml-[auto]", children: /* @__PURE__ */ p(R, { icon:
|
|
23730
|
+
/* @__PURE__ */ p(M.SelectedIndicator, { className: "ml-[auto]", children: /* @__PURE__ */ p(R, { icon: Je }) })
|
|
23731
23731
|
] }),
|
|
23732
23732
|
[t]
|
|
23733
23733
|
);
|
|
23734
23734
|
return /* @__PURE__ */ p(M.SelectItem, { ref: e, ...n, children: i });
|
|
23735
23735
|
}), Ko = Zo(function(r) {
|
|
23736
23736
|
const { ref: e, children: t, ...n } = r, i = T(
|
|
23737
|
-
(a) => typeof t == "function" ? /* @__PURE__ */ _(
|
|
23737
|
+
(a) => typeof t == "function" ? /* @__PURE__ */ _(Qe, { children: [
|
|
23738
23738
|
t(a),
|
|
23739
|
-
/* @__PURE__ */ p(M.SelectedIndicator, { className: "ml-auto", children: /* @__PURE__ */ p(R, { icon:
|
|
23740
|
-
] }) : /* @__PURE__ */ _(
|
|
23739
|
+
/* @__PURE__ */ p(M.SelectedIndicator, { className: "ml-auto", children: /* @__PURE__ */ p(R, { icon: Je }) })
|
|
23740
|
+
] }) : /* @__PURE__ */ _(Qe, { children: [
|
|
23741
23741
|
t,
|
|
23742
|
-
/* @__PURE__ */ p(M.SelectedIndicator, { className: "ml-auto", children: /* @__PURE__ */ p(R, { icon:
|
|
23742
|
+
/* @__PURE__ */ p(M.SelectedIndicator, { className: "ml-auto", children: /* @__PURE__ */ p(R, { icon: Je }) })
|
|
23743
23743
|
] }),
|
|
23744
23744
|
[t]
|
|
23745
23745
|
);
|
|
23746
23746
|
return /* @__PURE__ */ p(M.MultiSelectItem, { ref: e, ...n, children: i });
|
|
23747
23747
|
}), Oi = G((r) => {
|
|
23748
23748
|
const { ref: e, children: t, ...n } = r, i = T(
|
|
23749
|
-
(a) => typeof t == "function" ? /* @__PURE__ */ _(
|
|
23749
|
+
(a) => typeof t == "function" ? /* @__PURE__ */ _(Qe, { children: [
|
|
23750
23750
|
t(a),
|
|
23751
|
-
/* @__PURE__ */ p(M.CheckboxItemIndicator, { className: "ml-[auto]", children: (o) => o ? /* @__PURE__ */ p(R, { icon: jr }) : /* @__PURE__ */ p(R, { icon:
|
|
23752
|
-
] }) : /* @__PURE__ */ _(
|
|
23751
|
+
/* @__PURE__ */ p(M.CheckboxItemIndicator, { className: "ml-[auto]", children: (o) => o ? /* @__PURE__ */ p(R, { icon: jr }) : /* @__PURE__ */ p(R, { icon: Je }) })
|
|
23752
|
+
] }) : /* @__PURE__ */ _(Qe, { children: [
|
|
23753
23753
|
t,
|
|
23754
|
-
/* @__PURE__ */ p(M.CheckboxItemIndicator, { className: "ml-[auto]", children: (o) => o ? /* @__PURE__ */ p(R, { icon: jr }) : /* @__PURE__ */ p(R, { icon:
|
|
23754
|
+
/* @__PURE__ */ p(M.CheckboxItemIndicator, { className: "ml-[auto]", children: (o) => o ? /* @__PURE__ */ p(R, { icon: jr }) : /* @__PURE__ */ p(R, { icon: Je }) })
|
|
23755
23755
|
] }),
|
|
23756
23756
|
[t]
|
|
23757
23757
|
);
|
|
@@ -24150,7 +24150,7 @@ class Ti extends on {
|
|
|
24150
24150
|
return this.conditions.length === 0 ? !0 : this.conditions.map((i) => [i.getApplyFn(), i.accessorFn]).every(([i, a]) => i(a(t)));
|
|
24151
24151
|
}
|
|
24152
24152
|
}
|
|
24153
|
-
const
|
|
24153
|
+
const O0 = (r, e) => oe(() => {
|
|
24154
24154
|
const t = new Ti(r);
|
|
24155
24155
|
return t.observe((n) => e(n.getConditions())), t;
|
|
24156
24156
|
}, [r, e]), E1 = (r) => {
|
|
@@ -24441,7 +24441,7 @@ const I1 = (r) => {
|
|
|
24441
24441
|
case "inRange":
|
|
24442
24442
|
case "notInRange": {
|
|
24443
24443
|
const s = e.modifiers.inRange, l = i !== void 0 && s.isConditionValueValid(i) ? i : void 0;
|
|
24444
|
-
return /* @__PURE__ */ _(
|
|
24444
|
+
return /* @__PURE__ */ _(Qe, { children: [
|
|
24445
24445
|
/* @__PURE__ */ p(
|
|
24446
24446
|
Tt,
|
|
24447
24447
|
{
|
|
@@ -24837,7 +24837,7 @@ const D1 = (r) => {
|
|
|
24837
24837
|
case "inRange":
|
|
24838
24838
|
case "notInRange": {
|
|
24839
24839
|
const s = e.modifiers.inRange, l = i !== void 0 && s.isConditionValueValid(i) ? i : void 0;
|
|
24840
|
-
return /* @__PURE__ */ _(
|
|
24840
|
+
return /* @__PURE__ */ _(Qe, { children: [
|
|
24841
24841
|
/* @__PURE__ */ p(
|
|
24842
24842
|
Tt,
|
|
24843
24843
|
{
|
|
@@ -25329,21 +25329,27 @@ const B1 = {
|
|
|
25329
25329
|
throw new Error(`field and condition type mismatch ${r.type} !== ${e.type}`);
|
|
25330
25330
|
return B1[e.type].deserialize(e, r);
|
|
25331
25331
|
}, Jo = (r, e) => {
|
|
25332
|
-
const t = {};
|
|
25333
|
-
for (const
|
|
25334
|
-
|
|
25335
|
-
return
|
|
25336
|
-
(
|
|
25332
|
+
const t = z1(r, e), n = {};
|
|
25333
|
+
for (const i of r)
|
|
25334
|
+
n[i.identifier] = i;
|
|
25335
|
+
return t.map(
|
|
25336
|
+
(i) => k1(n[i.fieldId], i)
|
|
25337
25337
|
);
|
|
25338
|
+
}, L1 = (r, e) => U1(r, e).map((n) => n.serialize()), z1 = (r, e) => {
|
|
25339
|
+
const t = new Set(r.map((n) => n.identifier));
|
|
25340
|
+
return e.filter((n) => t.has(n.fieldId));
|
|
25341
|
+
}, U1 = (r, e) => {
|
|
25342
|
+
const t = new Set(r.map((n) => n.identifier));
|
|
25343
|
+
return e.filter((n) => t.has(n.field.identifier));
|
|
25338
25344
|
}, Ri = (r) => Ai[r.type].deserialize(r);
|
|
25339
|
-
function
|
|
25340
|
-
return r.map(
|
|
25345
|
+
function N0(r) {
|
|
25346
|
+
return r.map(H1);
|
|
25341
25347
|
}
|
|
25342
|
-
const
|
|
25343
|
-
function
|
|
25348
|
+
const H1 = (r) => r.type === "section" ? nt.deserialize(r) : Ri(r);
|
|
25349
|
+
function T0(r) {
|
|
25344
25350
|
return r.map(Ri);
|
|
25345
25351
|
}
|
|
25346
|
-
function
|
|
25352
|
+
function G1(r) {
|
|
25347
25353
|
const e = [];
|
|
25348
25354
|
for (const t of r)
|
|
25349
25355
|
if (t instanceof nt)
|
|
@@ -25353,13 +25359,13 @@ function z1(r) {
|
|
|
25353
25359
|
e.push(t);
|
|
25354
25360
|
return e;
|
|
25355
25361
|
}
|
|
25356
|
-
function
|
|
25362
|
+
function X1(r) {
|
|
25357
25363
|
const e = {};
|
|
25358
25364
|
for (const t of r)
|
|
25359
25365
|
e[t.identifier] = t;
|
|
25360
25366
|
return e;
|
|
25361
25367
|
}
|
|
25362
|
-
function
|
|
25368
|
+
function W1(r, e, t = !0) {
|
|
25363
25369
|
const n = t ? Mi(r, e) : e, i = {};
|
|
25364
25370
|
for (const a of r) {
|
|
25365
25371
|
if (!(a.identifier in n)) continue;
|
|
@@ -25368,7 +25374,7 @@ function H1(r, e, t = !0) {
|
|
|
25368
25374
|
}
|
|
25369
25375
|
return i;
|
|
25370
25376
|
}
|
|
25371
|
-
function
|
|
25377
|
+
function q1(r, e, t = !0) {
|
|
25372
25378
|
const n = t ? es(r, e) : e, i = {};
|
|
25373
25379
|
for (const a of r) {
|
|
25374
25380
|
if (!(a.identifier in n)) continue;
|
|
@@ -25395,7 +25401,7 @@ function es(r, e) {
|
|
|
25395
25401
|
}
|
|
25396
25402
|
return t;
|
|
25397
25403
|
}
|
|
25398
|
-
function
|
|
25404
|
+
function $1(r, e) {
|
|
25399
25405
|
const t = Mi(r, e), n = {}, i = {};
|
|
25400
25406
|
for (const a of r) {
|
|
25401
25407
|
if (!(a.identifier in t)) continue;
|
|
@@ -25418,7 +25424,7 @@ function X1(r, e) {
|
|
|
25418
25424
|
}
|
|
25419
25425
|
return [n, i];
|
|
25420
25426
|
}
|
|
25421
|
-
function
|
|
25427
|
+
function j1(r, e, t) {
|
|
25422
25428
|
const n = {};
|
|
25423
25429
|
for (const i of r) {
|
|
25424
25430
|
if (!(i.identifier in e)) continue;
|
|
@@ -25442,21 +25448,21 @@ function W1(r, e, t) {
|
|
|
25442
25448
|
}
|
|
25443
25449
|
return n;
|
|
25444
25450
|
}
|
|
25445
|
-
const
|
|
25451
|
+
const Y1 = (r, e) => {
|
|
25446
25452
|
const t = {};
|
|
25447
25453
|
for (const n of r) {
|
|
25448
25454
|
const i = e[n.identifier];
|
|
25449
25455
|
t[n.identifier] = i !== void 0 ? i : n.blankValue();
|
|
25450
25456
|
}
|
|
25451
25457
|
return t;
|
|
25452
|
-
},
|
|
25458
|
+
}, Z1 = (r, e, t) => {
|
|
25453
25459
|
const n = {};
|
|
25454
25460
|
for (const i of r) {
|
|
25455
25461
|
const a = e[i.identifier], o = t[i.identifier];
|
|
25456
25462
|
i.areValuesEqual(a, o) || (n[i.identifier] = o);
|
|
25457
25463
|
}
|
|
25458
25464
|
return n;
|
|
25459
|
-
},
|
|
25465
|
+
}, K1 = (r, e, t) => {
|
|
25460
25466
|
const n = {};
|
|
25461
25467
|
for (const i of r) {
|
|
25462
25468
|
const a = e[i.identifier], o = t[i.identifier];
|
|
@@ -25471,7 +25477,7 @@ const q1 = (r, e) => {
|
|
|
25471
25477
|
for (const t of r)
|
|
25472
25478
|
e[t.identifier] = t.blankValue();
|
|
25473
25479
|
return e;
|
|
25474
|
-
},
|
|
25480
|
+
}, Q1 = (r, e) => ts(r, e, rs(r)), J1 = (r, e, t = {}) => {
|
|
25475
25481
|
const { conditions: n = !1 } = t, i = r.get(e.identifier);
|
|
25476
25482
|
if (!i)
|
|
25477
25483
|
throw new Error(
|
|
@@ -25504,11 +25510,11 @@ const q1 = (r, e) => {
|
|
|
25504
25510
|
conditions: s,
|
|
25505
25511
|
fields: o
|
|
25506
25512
|
};
|
|
25507
|
-
},
|
|
25513
|
+
}, e0 = (r, e = {}) => {
|
|
25508
25514
|
const t = new Map(
|
|
25509
25515
|
r.map((n) => [n.identifier, X()])
|
|
25510
25516
|
);
|
|
25511
|
-
return r.map((n) =>
|
|
25517
|
+
return r.map((n) => J1(t, n, e));
|
|
25512
25518
|
}, ns = (r, e) => {
|
|
25513
25519
|
const t = {}, n = r.filter((i) => i instanceof nt);
|
|
25514
25520
|
for (const i of r)
|
|
@@ -25528,7 +25534,7 @@ const q1 = (r, e) => {
|
|
|
25528
25534
|
o && Hs(t, a, o);
|
|
25529
25535
|
}
|
|
25530
25536
|
if (Object.keys(t).length > 0) return t;
|
|
25531
|
-
},
|
|
25537
|
+
}, D0 = async (r) => {
|
|
25532
25538
|
const e = {}, t = [];
|
|
25533
25539
|
for (const n of r) {
|
|
25534
25540
|
const { fields: i } = n, a = [];
|
|
@@ -25550,7 +25556,7 @@ const q1 = (r, e) => {
|
|
|
25550
25556
|
}
|
|
25551
25557
|
return { fields: t, images: e };
|
|
25552
25558
|
};
|
|
25553
|
-
async function
|
|
25559
|
+
async function R0(r) {
|
|
25554
25560
|
const e = {};
|
|
25555
25561
|
for (const [t, n] of Object.entries(r))
|
|
25556
25562
|
e[t] = await Promise.all(n);
|
|
@@ -25577,7 +25583,7 @@ class Vt extends on {
|
|
|
25577
25583
|
return new Vt(t.map(nt.deserialize));
|
|
25578
25584
|
}
|
|
25579
25585
|
static reseedFieldSections(t, n) {
|
|
25580
|
-
return
|
|
25586
|
+
return e0(t, n);
|
|
25581
25587
|
}
|
|
25582
25588
|
getFields() {
|
|
25583
25589
|
return this.fieldSections.flatMap((t) => t.getFields());
|
|
@@ -25627,13 +25633,13 @@ class Vt extends on {
|
|
|
25627
25633
|
return es(this.getFields(), t);
|
|
25628
25634
|
}
|
|
25629
25635
|
deserializeValues(t, n) {
|
|
25630
|
-
return
|
|
25636
|
+
return q1(this.getFields(), t, n);
|
|
25631
25637
|
}
|
|
25632
25638
|
serializeValues(t, n) {
|
|
25633
|
-
return
|
|
25639
|
+
return W1(this.getFields(), t, n);
|
|
25634
25640
|
}
|
|
25635
25641
|
initializeValues(t) {
|
|
25636
|
-
return
|
|
25642
|
+
return Y1(this.getFields(), t);
|
|
25637
25643
|
}
|
|
25638
25644
|
validateValues(t) {
|
|
25639
25645
|
return ns(this.getFieldSections(), t);
|
|
@@ -25641,39 +25647,45 @@ class Vt extends on {
|
|
|
25641
25647
|
deserializeConditions(t) {
|
|
25642
25648
|
return Jo(this.getFields(), t);
|
|
25643
25649
|
}
|
|
25650
|
+
serializeConditions(t) {
|
|
25651
|
+
return L1(this.getFields(), t);
|
|
25652
|
+
}
|
|
25644
25653
|
changedFieldValues(t, n) {
|
|
25645
|
-
return
|
|
25654
|
+
return Z1(this.getFields(), t, n);
|
|
25646
25655
|
}
|
|
25647
25656
|
unchangedFieldValues(t, n) {
|
|
25648
|
-
return
|
|
25657
|
+
return K1(this.getFields(), t, n);
|
|
25649
25658
|
}
|
|
25650
25659
|
areValuesEqual(t, n) {
|
|
25651
25660
|
return ts(this.getFields(), t, n);
|
|
25652
25661
|
}
|
|
25653
25662
|
areValuesBlank(t) {
|
|
25654
|
-
return
|
|
25663
|
+
return Q1(this.getFields(), t);
|
|
25655
25664
|
}
|
|
25656
25665
|
blankValues() {
|
|
25657
25666
|
return rs(this.getFields());
|
|
25658
25667
|
}
|
|
25659
25668
|
extractFilesAndPromisesFromFieldValues(t) {
|
|
25660
|
-
return
|
|
25669
|
+
return $1(this.getFields(), t);
|
|
25661
25670
|
}
|
|
25662
25671
|
insertFilesAndPromisesToFieldValues(t, n) {
|
|
25663
|
-
return
|
|
25672
|
+
return j1(this.getFields(), t, n);
|
|
25664
25673
|
}
|
|
25665
25674
|
}
|
|
25666
25675
|
const is = Mr({}), as = G((r) => {
|
|
25667
|
-
const { fieldSection: e, size: t,
|
|
25668
|
-
const
|
|
25669
|
-
return new Ti(
|
|
25670
|
-
}), [
|
|
25671
|
-
return
|
|
25672
|
-
|
|
25673
|
-
|
|
25674
|
-
a && /* @__PURE__ */ p(
|
|
25675
|
-
|
|
25676
|
-
|
|
25676
|
+
const { fieldSection: e, size: t, index: n, ...i } = r, { label: a, description: o } = e, { values: s } = an(), { fieldSchema: l } = lt(is), c = oe(() => l.getFieldSections(), [l]), u = oe(() => c.filter((h) => e.identifier in h.conditions), [c, e.identifier]), f = oe(() => u.length === 0 ? !0 : u.some((h) => {
|
|
25677
|
+
const v = h.getConditions(e.identifier);
|
|
25678
|
+
return new Ti(v).applyConditions(s);
|
|
25679
|
+
}), [u, e, s]), d = Zr(e.fields, { size: t, ...i });
|
|
25680
|
+
return f ? /* @__PURE__ */ _(Qe, { children: [
|
|
25681
|
+
n !== 0 ? /* @__PURE__ */ p(mr, { size: "full" }) : null,
|
|
25682
|
+
/* @__PURE__ */ _("div", { className: "flex flex-col gap-4", children: [
|
|
25683
|
+
(a || o) && /* @__PURE__ */ p(Qe, { children: /* @__PURE__ */ _("div", { className: "flex flex-col gap-1", children: [
|
|
25684
|
+
/* @__PURE__ */ p(As, { size: t, children: a }),
|
|
25685
|
+
o && /* @__PURE__ */ p(Ve, { accentColor: "base", size: t, children: o })
|
|
25686
|
+
] }) }),
|
|
25687
|
+
d
|
|
25688
|
+
] })
|
|
25677
25689
|
] }) : null;
|
|
25678
25690
|
});
|
|
25679
25691
|
as.displayName = "FieldSectionLayout";
|
|
@@ -25816,7 +25828,7 @@ b(It, "fieldTypeName", "Section"), b(It, "fieldTypeDescription", "Sections can b
|
|
|
25816
25828
|
return new It({ ...t, fields: n, conditions: i });
|
|
25817
25829
|
});
|
|
25818
25830
|
let nt = It;
|
|
25819
|
-
const Ft = Mr(new Vt([])), tn = "form-builder", On = Mr({}),
|
|
25831
|
+
const Ft = Mr(new Vt([])), tn = "form-builder", On = Mr({}), t0 = (r = () => null) => oe(() => Object.entries(Ai).map(([t, n]) => ({
|
|
25820
25832
|
children: n.fieldTypeName,
|
|
25821
25833
|
icon: /* @__PURE__ */ p(R, { icon: xe[t] }),
|
|
25822
25834
|
value: t,
|
|
@@ -25824,7 +25836,7 @@ const Ft = Mr(new Vt([])), tn = "form-builder", On = Mr({}), Q1 = (r = () => nul
|
|
|
25824
25836
|
r(t);
|
|
25825
25837
|
}
|
|
25826
25838
|
})), [r]), Nn = G((r) => {
|
|
25827
|
-
const { children: e, variant: t, size: n, accentColor: i, onSelectFieldType: a, ...o } = r, s =
|
|
25839
|
+
const { children: e, variant: t, size: n, accentColor: i, onSelectFieldType: a, ...o } = r, s = t0(a);
|
|
25828
25840
|
return /* @__PURE__ */ _(M.Root, { ...o, children: [
|
|
25829
25841
|
/* @__PURE__ */ p(M.ClickTrigger, { children: e }),
|
|
25830
25842
|
/* @__PURE__ */ p(M.Content, { variant: t, size: n, accentColor: i, children: /* @__PURE__ */ p(M.Scroll, { children: s.flat().map((l) => /* @__PURE__ */ _(M.Item, { onSelect: l.onSelect, children: [
|
|
@@ -26064,7 +26076,7 @@ const Vi = (r) => {
|
|
|
26064
26076
|
default:
|
|
26065
26077
|
return;
|
|
26066
26078
|
}
|
|
26067
|
-
},
|
|
26079
|
+
}, r0 = {
|
|
26068
26080
|
danger: "danger",
|
|
26069
26081
|
warning: "warning",
|
|
26070
26082
|
info: "base",
|
|
@@ -26080,7 +26092,7 @@ const Vi = (r) => {
|
|
|
26080
26092
|
size: "sm",
|
|
26081
26093
|
"aria-label": "settings",
|
|
26082
26094
|
accentColor: "base",
|
|
26083
|
-
...t && { color:
|
|
26095
|
+
...t && { color: r0.danger },
|
|
26084
26096
|
children: [
|
|
26085
26097
|
/* @__PURE__ */ p(R, { icon: Ql }),
|
|
26086
26098
|
"Settings"
|
|
@@ -26134,7 +26146,7 @@ const cs = G((r) => {
|
|
|
26134
26146
|
checked: n.required,
|
|
26135
26147
|
onCheckedChange: (C) => n.setOptions({ required: !!C }),
|
|
26136
26148
|
size: "sm",
|
|
26137
|
-
children: /* @__PURE__ */ p($r.Indicator, { children: /* @__PURE__ */ p(R, { icon:
|
|
26149
|
+
children: /* @__PURE__ */ p($r.Indicator, { children: /* @__PURE__ */ p(R, { icon: Je }) })
|
|
26138
26150
|
}
|
|
26139
26151
|
),
|
|
26140
26152
|
/* @__PURE__ */ p(Ve, { size: "sm", accentColor: "base", children: "Required" })
|
|
@@ -26293,7 +26305,7 @@ const fs = G((r) => {
|
|
|
26293
26305
|
targetY: a,
|
|
26294
26306
|
targetPosition: f === "LR" ? vt.Left : vt.Top
|
|
26295
26307
|
});
|
|
26296
|
-
return /* @__PURE__ */ _(
|
|
26308
|
+
return /* @__PURE__ */ _(Qe, { children: [
|
|
26297
26309
|
/* @__PURE__ */ p(Is, { id: e, path: m, style: o, markerEnd: s, labelX: w, labelY: x }),
|
|
26298
26310
|
/* @__PURE__ */ p(Os, { children: /* @__PURE__ */ _(
|
|
26299
26311
|
dt,
|
|
@@ -26455,11 +26467,11 @@ const ds = G((r) => {
|
|
|
26455
26467
|
);
|
|
26456
26468
|
});
|
|
26457
26469
|
ds.displayName = "CustomNode";
|
|
26458
|
-
const
|
|
26470
|
+
const n0 = {
|
|
26459
26471
|
fieldSection: ds
|
|
26460
|
-
},
|
|
26472
|
+
}, i0 = {
|
|
26461
26473
|
fieldSectionCondition: fs
|
|
26462
|
-
},
|
|
26474
|
+
}, a0 = (r, e, t) => {
|
|
26463
26475
|
const n = new Li.graphlib.Graph().setDefaultEdgeLabel(() => ({}));
|
|
26464
26476
|
return n.setGraph({ rankdir: t, nodesep: 200, edgesep: 500, ranksep: 500 }), e.forEach(
|
|
26465
26477
|
(i) => n.setEdge(i.source, i.target, {
|
|
@@ -26485,7 +26497,7 @@ const e0 = {
|
|
|
26485
26497
|
}),
|
|
26486
26498
|
e
|
|
26487
26499
|
];
|
|
26488
|
-
},
|
|
26500
|
+
}, o0 = {
|
|
26489
26501
|
hideAttribution: !0
|
|
26490
26502
|
}, hs = G(() => {
|
|
26491
26503
|
const { handleSubmit: r, errors: e } = an(), { onCancel: t } = lt(On), n = lt(Ft), i = nn(null), [a, o] = ge(), [s, l] = ge("TB");
|
|
@@ -26534,7 +26546,7 @@ const e0 = {
|
|
|
26534
26546
|
}, [c, d]), Pe(() => {
|
|
26535
26547
|
g(u);
|
|
26536
26548
|
}, [u, g]);
|
|
26537
|
-
const [w, x] = oe(() =>
|
|
26549
|
+
const [w, x] = oe(() => a0(f, v, s), [v, s, f]), C = T(() => {
|
|
26538
26550
|
n.addFieldSection(new nt({ identifier: X(), fields: [] }));
|
|
26539
26551
|
}, [n]), A = T(
|
|
26540
26552
|
(I) => {
|
|
@@ -26565,14 +26577,14 @@ const e0 = {
|
|
|
26565
26577
|
onNodesChange: h,
|
|
26566
26578
|
edges: x,
|
|
26567
26579
|
onEdgesChange: m,
|
|
26568
|
-
nodeTypes:
|
|
26569
|
-
edgeTypes:
|
|
26580
|
+
nodeTypes: n0,
|
|
26581
|
+
edgeTypes: i0,
|
|
26570
26582
|
onConnect: A,
|
|
26571
26583
|
attributionPosition: "bottom-left",
|
|
26572
26584
|
fitView: !0,
|
|
26573
26585
|
minZoom: 0,
|
|
26574
26586
|
isValidConnection: S,
|
|
26575
|
-
proOptions:
|
|
26587
|
+
proOptions: o0
|
|
26576
26588
|
}
|
|
26577
26589
|
),
|
|
26578
26590
|
/* @__PURE__ */ p(Mn, { position: "top-left", children: /* @__PURE__ */ p(he, { className: "flex items-center justify-end gap-2", size: "sm", children: /* @__PURE__ */ _(U, { type: "button", variant: "surface", onClick: C, children: [
|
|
@@ -26945,7 +26957,7 @@ const xs = G(() => {
|
|
|
26945
26957
|
] });
|
|
26946
26958
|
});
|
|
26947
26959
|
xs.displayName = "FormBuilderListBuilder";
|
|
26948
|
-
const
|
|
26960
|
+
const s0 = G(
|
|
26949
26961
|
Rr((r, e) => {
|
|
26950
26962
|
const {
|
|
26951
26963
|
readonly: t = !1,
|
|
@@ -26986,7 +26998,7 @@ const i0 = G(
|
|
|
26986
26998
|
}, [m, A]);
|
|
26987
26999
|
const { dirty: N } = I, D = T(
|
|
26988
27000
|
(ne, $) => {
|
|
26989
|
-
|
|
27001
|
+
X1(G1(n.getFieldSections()))[ne].areValuesEqual(A[ne], $) || a == null || a({ ...I.values, [ne]: $ }, { [ne]: $ });
|
|
26990
27002
|
},
|
|
26991
27003
|
[I.values, A, a, n]
|
|
26992
27004
|
), P = oe(
|
|
@@ -27033,7 +27045,7 @@ const i0 = G(
|
|
|
27033
27045
|
}
|
|
27034
27046
|
) : null,
|
|
27035
27047
|
q ? /* @__PURE__ */ _(U, { ...g, type: "submit", accentColor: "primary", variant: "surface", children: [
|
|
27036
|
-
/* @__PURE__ */ p(R, { icon:
|
|
27048
|
+
/* @__PURE__ */ p(R, { icon: Je }),
|
|
27037
27049
|
s
|
|
27038
27050
|
] }) : null
|
|
27039
27051
|
] }) : null
|
|
@@ -27043,7 +27055,7 @@ const i0 = G(
|
|
|
27043
27055
|
})
|
|
27044
27056
|
), ys = G(() => {
|
|
27045
27057
|
const r = lt(Ft);
|
|
27046
|
-
return /* @__PURE__ */ p(
|
|
27058
|
+
return /* @__PURE__ */ p(s0, { fieldSchema: r, readonly: !1 });
|
|
27047
27059
|
});
|
|
27048
27060
|
ys.displayName = "FormBuilderPreview";
|
|
27049
27061
|
const ms = G((r) => {
|
|
@@ -27102,7 +27114,7 @@ const ms = G((r) => {
|
|
|
27102
27114
|
return /* @__PURE__ */ p(On, { value: d, children: /* @__PURE__ */ p(Ft, { value: f, children: /* @__PURE__ */ p(Ha, { value: c, children: e }) }) });
|
|
27103
27115
|
});
|
|
27104
27116
|
ms.displayName = "FormBuilderRoot";
|
|
27105
|
-
const
|
|
27117
|
+
const M0 = {
|
|
27106
27118
|
Root: ms,
|
|
27107
27119
|
FlowBuilder: hs,
|
|
27108
27120
|
ListBuilder: xs,
|
|
@@ -27140,9 +27152,9 @@ export {
|
|
|
27140
27152
|
nt as FieldSection,
|
|
27141
27153
|
as as FieldSectionLayout,
|
|
27142
27154
|
Ai as FieldTypeToClsMapping,
|
|
27143
|
-
|
|
27155
|
+
s0 as FieldsRenderer,
|
|
27144
27156
|
to as FileCard,
|
|
27145
|
-
|
|
27157
|
+
M0 as FormBuilder,
|
|
27146
27158
|
g1 as HasFilesConditionModifier,
|
|
27147
27159
|
dc as ImageCard,
|
|
27148
27160
|
ui as ImageFile,
|
|
@@ -27191,7 +27203,7 @@ export {
|
|
|
27191
27203
|
An as RatingFieldCondition,
|
|
27192
27204
|
D1 as RatingFieldConditionCell,
|
|
27193
27205
|
yo as RatingFieldInput,
|
|
27194
|
-
|
|
27206
|
+
r0 as SEVERITY_COLOR_MAPPING,
|
|
27195
27207
|
Gn as SHORT_TEXT_FIELD_MAX_LENGTH,
|
|
27196
27208
|
en as ScanField,
|
|
27197
27209
|
_n as ScanFieldCondition,
|
|
@@ -27230,33 +27242,35 @@ export {
|
|
|
27230
27242
|
In as UploadFieldCondition,
|
|
27231
27243
|
F1 as UploadFieldConditionCell,
|
|
27232
27244
|
ko as UploadFieldInput,
|
|
27233
|
-
|
|
27245
|
+
Q1 as areFieldValuesBlank,
|
|
27234
27246
|
ts as areFieldValuesEqual,
|
|
27235
27247
|
fi as areFileAndPromiseArraysEqual,
|
|
27236
27248
|
xc as arePassFieldValuesEqual,
|
|
27237
27249
|
yc as areSerializedPassFailFieldValuesEqual,
|
|
27238
|
-
|
|
27250
|
+
R0 as awaitFilesAndPromises,
|
|
27239
27251
|
rs as blankFieldValues,
|
|
27240
|
-
|
|
27252
|
+
Z1 as changedFieldValues,
|
|
27253
|
+
U1 as cleanConditions,
|
|
27241
27254
|
Mi as cleanFieldValues,
|
|
27255
|
+
z1 as cleanSerializedConditions,
|
|
27242
27256
|
es as cleanSerializedFieldValues,
|
|
27243
27257
|
os as createCondition,
|
|
27244
27258
|
B as createConditionModifierConfig,
|
|
27245
27259
|
Vi as createField,
|
|
27246
|
-
|
|
27260
|
+
H1 as deserialize,
|
|
27247
27261
|
k1 as deserializeCondition,
|
|
27248
27262
|
Jo as deserializeConditions,
|
|
27249
27263
|
Ri as deserializeField,
|
|
27250
|
-
|
|
27251
|
-
|
|
27252
|
-
|
|
27264
|
+
q1 as deserializeFieldValues,
|
|
27265
|
+
N0 as deserializeFields,
|
|
27266
|
+
T0 as deserializeOnlyFields,
|
|
27253
27267
|
gc as deserializePassFailFieldValue,
|
|
27254
|
-
|
|
27268
|
+
$1 as extractFilesAndPromisesFromFieldValues,
|
|
27255
27269
|
xe as fieldIcons,
|
|
27256
|
-
|
|
27257
|
-
|
|
27258
|
-
|
|
27259
|
-
|
|
27270
|
+
G1 as flattenFields,
|
|
27271
|
+
X1 as getFieldsMapping,
|
|
27272
|
+
Y1 as initializeFieldValues,
|
|
27273
|
+
j1 as insertFilesAndPromisesToFieldValues,
|
|
27260
27274
|
fc as isFileAndPromiseArray,
|
|
27261
27275
|
go as isPassFailFieldStatus,
|
|
27262
27276
|
pc as isPassFailFieldValue,
|
|
@@ -27267,16 +27281,17 @@ export {
|
|
|
27267
27281
|
yr as maxFileSizeMB,
|
|
27268
27282
|
rr as passFailFieldStatusMapping,
|
|
27269
27283
|
Sr as passFailFieldStatuses,
|
|
27270
|
-
|
|
27271
|
-
|
|
27284
|
+
D0 as separateImagesFromFields,
|
|
27285
|
+
L1 as serializeConditions,
|
|
27286
|
+
W1 as serializeFieldValues,
|
|
27272
27287
|
vc as serializePassFailFieldValue,
|
|
27273
|
-
|
|
27274
|
-
|
|
27275
|
-
|
|
27288
|
+
K1 as unchangedFieldValues,
|
|
27289
|
+
O0 as useConditionManager,
|
|
27290
|
+
b0 as useFieldInput,
|
|
27276
27291
|
Zr as useFieldInputs,
|
|
27277
27292
|
We as useFormikInput,
|
|
27278
27293
|
ci as useImageViewer,
|
|
27279
27294
|
cc as useObjectUrl,
|
|
27280
|
-
|
|
27295
|
+
I0 as useScanner,
|
|
27281
27296
|
ns as validateFields
|
|
27282
27297
|
};
|