@namroodinc/liquid-editorial 0.4.1 → 0.5.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/README.md +13 -5
- package/UPGRADING.md +142 -0
- package/dist/chunks/{Board-BaQ04nWg.cjs → Board-BPA6mVhf.cjs} +2 -2
- package/dist/chunks/{Board-BaQ04nWg.cjs.map → Board-BPA6mVhf.cjs.map} +1 -1
- package/dist/chunks/{Board-CUhF8pTX.js → Board-CcIF7jS0.js} +2 -2
- package/dist/chunks/{Board-CUhF8pTX.js.map → Board-CcIF7jS0.js.map} +1 -1
- package/dist/chunks/{ColourField-CJicr3OT.cjs → ColourField-BQ4a5tAV.cjs} +2 -2
- package/dist/chunks/{ColourField-CJicr3OT.cjs.map → ColourField-BQ4a5tAV.cjs.map} +1 -1
- package/dist/chunks/{ColourField-DjHRiFDU.js → ColourField-Doew1hLw.js} +3 -3
- package/dist/chunks/{ColourField-DjHRiFDU.js.map → ColourField-Doew1hLw.js.map} +1 -1
- package/dist/chunks/{DatePicker-aSlYLjtW.cjs → DatePicker-C0-609Zx.cjs} +2 -2
- package/dist/chunks/{DatePicker-aSlYLjtW.cjs.map → DatePicker-C0-609Zx.cjs.map} +1 -1
- package/dist/chunks/{DatePicker-D_6CQpUd.js → DatePicker-DmeWUsOS.js} +2 -2
- package/dist/chunks/{DatePicker-D_6CQpUd.js.map → DatePicker-DmeWUsOS.js.map} +1 -1
- package/dist/chunks/{FormEditor-CaskinQ1.js → FormEditor-DTnFO4oS.js} +170 -154
- package/dist/chunks/FormEditor-DTnFO4oS.js.map +1 -0
- package/dist/chunks/FormEditor-DfQLJnsO.cjs +2 -0
- package/dist/chunks/FormEditor-DfQLJnsO.cjs.map +1 -0
- package/dist/chunks/Icon-D1kx7-1c.js +81 -0
- package/dist/chunks/Icon-D1kx7-1c.js.map +1 -0
- package/dist/chunks/Icon-D38lQXNe.cjs +2 -0
- package/dist/chunks/Icon-D38lQXNe.cjs.map +1 -0
- package/dist/chunks/RichTextEditor-DEJ-u-ZR.js +483 -0
- package/dist/chunks/RichTextEditor-DEJ-u-ZR.js.map +1 -0
- package/dist/chunks/RichTextEditor-Ddk7qaqg.cjs +2 -0
- package/dist/chunks/RichTextEditor-Ddk7qaqg.cjs.map +1 -0
- package/dist/chunks/movableHost-CajG9_5Z.cjs +2 -0
- package/dist/chunks/movableHost-CajG9_5Z.cjs.map +1 -0
- package/dist/chunks/movableHost-NJj_FsAu.js +23 -0
- package/dist/chunks/movableHost-NJj_FsAu.js.map +1 -0
- package/dist/chunks/portalScope-AzzPM54i.js +105 -0
- package/dist/chunks/portalScope-AzzPM54i.js.map +1 -0
- package/dist/chunks/portalScope-BVA1-Ypu.cjs +2 -0
- package/dist/chunks/portalScope-BVA1-Ypu.cjs.map +1 -0
- package/dist/chunks/useModalDialog-BVaG--b3.js +87 -0
- package/dist/chunks/useModalDialog-BVaG--b3.js.map +1 -0
- package/dist/chunks/useModalDialog-Ctu270Dp.cjs +2 -0
- package/dist/chunks/useModalDialog-Ctu270Dp.cjs.map +1 -0
- package/dist/components/AssetCard/index.cjs +1 -1
- package/dist/components/AssetCard/index.js +1 -1
- package/dist/components/AssetGrid/index.cjs +1 -1
- package/dist/components/AssetGrid/index.js +1 -1
- package/dist/components/Board/index.cjs +1 -1
- package/dist/components/Board/index.js +1 -1
- package/dist/components/Button/index.cjs +1 -1
- package/dist/components/Button/index.js +1 -1
- package/dist/components/ColourField/index.cjs +1 -1
- package/dist/components/ColourField/index.js +1 -1
- package/dist/components/DatePicker/index.cjs +1 -1
- package/dist/components/DatePicker/index.js +1 -1
- package/dist/components/Drawer/index.cjs +1 -1
- package/dist/components/Drawer/index.cjs.map +1 -1
- package/dist/components/Drawer/index.d.cts.map +1 -1
- package/dist/components/Drawer/index.d.ts.map +1 -1
- package/dist/components/Drawer/index.js +59 -75
- package/dist/components/Drawer/index.js.map +1 -1
- package/dist/components/Drawer/style.css +3 -0
- package/dist/components/EditLayout/index.cjs +1 -1
- package/dist/components/EditLayout/index.cjs.map +1 -1
- package/dist/components/EditLayout/index.d.cts.map +1 -1
- package/dist/components/EditLayout/index.d.ts.map +1 -1
- package/dist/components/EditLayout/index.js +107 -121
- package/dist/components/EditLayout/index.js.map +1 -1
- package/dist/components/EntryPicker/index.cjs +1 -1
- package/dist/components/EntryPicker/index.js +1 -1
- package/dist/components/FormEditor/README.md +74 -3
- package/dist/components/FormEditor/control.d.cts.map +1 -1
- package/dist/components/FormEditor/control.d.ts.map +1 -1
- package/dist/components/FormEditor/index.cjs +1 -1
- package/dist/components/FormEditor/index.d.cts.map +1 -1
- package/dist/components/FormEditor/index.d.ts.map +1 -1
- package/dist/components/FormEditor/index.js +2 -1
- package/dist/components/FormEditor/model.d.cts +6 -0
- package/dist/components/FormEditor/model.d.cts.map +1 -1
- package/dist/components/FormEditor/model.d.ts +6 -0
- package/dist/components/FormEditor/model.d.ts.map +1 -1
- package/dist/components/FormEditor/style.css +7 -0
- package/dist/components/Icon/icons.d.cts +2 -0
- package/dist/components/Icon/icons.d.cts.map +1 -1
- package/dist/components/Icon/icons.d.ts +2 -0
- package/dist/components/Icon/icons.d.ts.map +1 -1
- package/dist/components/Icon/index.cjs +1 -1
- package/dist/components/Icon/index.js +1 -1
- package/dist/components/Modal/index.cjs +1 -1
- package/dist/components/Modal/index.cjs.map +1 -1
- package/dist/components/Modal/index.d.cts +9 -1
- package/dist/components/Modal/index.d.cts.map +1 -1
- package/dist/components/Modal/index.d.ts +9 -1
- package/dist/components/Modal/index.d.ts.map +1 -1
- package/dist/components/Modal/index.js +37 -45
- package/dist/components/Modal/index.js.map +1 -1
- package/dist/components/Modal/style.css +8 -1
- package/dist/components/Popover/index.cjs +1 -1
- package/dist/components/Popover/index.cjs.map +1 -1
- package/dist/components/Popover/index.d.cts.map +1 -1
- package/dist/components/Popover/index.d.ts.map +1 -1
- package/dist/components/Popover/index.js +44 -37
- package/dist/components/Popover/index.js.map +1 -1
- package/dist/components/Popover/style.css +3 -0
- package/dist/components/RichTextEditor/expanded-width.d.cts +4 -0
- package/dist/components/RichTextEditor/expanded-width.d.cts.map +1 -0
- package/dist/components/RichTextEditor/expanded-width.d.ts +4 -0
- package/dist/components/RichTextEditor/expanded-width.d.ts.map +1 -0
- package/dist/components/RichTextEditor/expansion.d.cts +28 -0
- package/dist/components/RichTextEditor/expansion.d.cts.map +1 -0
- package/dist/components/RichTextEditor/expansion.d.ts +28 -0
- package/dist/components/RichTextEditor/expansion.d.ts.map +1 -0
- package/dist/components/RichTextEditor/index.cjs +1 -1
- package/dist/components/RichTextEditor/index.d.cts +4 -4
- package/dist/components/RichTextEditor/index.d.cts.map +1 -1
- package/dist/components/RichTextEditor/index.d.ts +4 -4
- package/dist/components/RichTextEditor/index.d.ts.map +1 -1
- package/dist/components/RichTextEditor/index.js +1 -1
- package/dist/components/RichTextEditor/style.css +85 -4
- package/dist/components/SearchField/index.cjs +1 -1
- package/dist/components/SearchField/index.js +1 -1
- package/dist/components/Select/index.cjs +1 -1
- package/dist/components/Select/index.js +1 -1
- package/dist/components/SideNav/index.cjs +1 -1
- package/dist/components/SideNav/index.js +1 -1
- package/dist/components/SortableList/index.cjs +1 -1
- package/dist/components/SortableList/index.js +1 -1
- package/dist/components/Stepper/index.cjs +1 -1
- package/dist/components/Stepper/index.js +1 -1
- package/dist/components/SubNav/index.cjs +1 -1
- package/dist/components/SubNav/index.js +1 -1
- package/dist/components/Table/index.cjs +1 -1
- package/dist/components/Table/index.js +1 -1
- package/dist/components/Toast/index.cjs +1 -1
- package/dist/components/Toast/index.js +1 -1
- package/dist/components/TopNav/index.cjs +1 -1
- package/dist/components/TopNav/index.js +1 -1
- package/dist/index.cjs +1 -1
- package/dist/index.d.cts +1 -1
- package/dist/index.d.cts.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +30 -30
- package/dist/internal/dialogFocus.d.cts +8 -0
- package/dist/internal/dialogFocus.d.cts.map +1 -1
- package/dist/internal/dialogFocus.d.ts +8 -0
- package/dist/internal/dialogFocus.d.ts.map +1 -1
- package/dist/internal/movableHost.d.cts +20 -0
- package/dist/internal/movableHost.d.cts.map +1 -0
- package/dist/internal/movableHost.d.ts +20 -0
- package/dist/internal/movableHost.d.ts.map +1 -0
- package/dist/internal/portalScope.d.cts +23 -0
- package/dist/internal/portalScope.d.cts.map +1 -0
- package/dist/internal/portalScope.d.ts +23 -0
- package/dist/internal/portalScope.d.ts.map +1 -0
- package/dist/internal/useModalDialog.d.cts +22 -0
- package/dist/internal/useModalDialog.d.cts.map +1 -0
- package/dist/internal/useModalDialog.d.ts +22 -0
- package/dist/internal/useModalDialog.d.ts.map +1 -0
- package/package.json +1 -1
- package/dist/chunks/FormEditor-CaskinQ1.js.map +0 -1
- package/dist/chunks/FormEditor-DDylpJ9O.cjs +0 -2
- package/dist/chunks/FormEditor-DDylpJ9O.cjs.map +0 -1
- package/dist/chunks/Icon-BBoWP_Y6.cjs +0 -2
- package/dist/chunks/Icon-BBoWP_Y6.cjs.map +0 -1
- package/dist/chunks/Icon-XNismJDm.js +0 -79
- package/dist/chunks/Icon-XNismJDm.js.map +0 -1
- package/dist/chunks/RichTextEditor-C7nMfDmE.cjs +0 -2
- package/dist/chunks/RichTextEditor-C7nMfDmE.cjs.map +0 -1
- package/dist/chunks/RichTextEditor-DjR10XJ-.js +0 -370
- package/dist/chunks/RichTextEditor-DjR10XJ-.js.map +0 -1
- package/dist/chunks/dialogFocus-B9iqKl3I.cjs +0 -2
- package/dist/chunks/dialogFocus-B9iqKl3I.cjs.map +0 -1
- package/dist/chunks/dialogFocus-BFoyeTpA.js +0 -48
- package/dist/chunks/dialogFocus-BFoyeTpA.js.map +0 -1
- package/dist/chunks/dialogStack-6yv3NXFD.js +0 -43
- package/dist/chunks/dialogStack-6yv3NXFD.js.map +0 -1
- package/dist/chunks/dialogStack-C9SLVu6Q.cjs +0 -2
- package/dist/chunks/dialogStack-C9SLVu6Q.cjs.map +0 -1
|
@@ -1,21 +1,26 @@
|
|
|
1
1
|
import { Button as e } from "../components/Button/index.js";
|
|
2
2
|
import { Field as t } from "../components/Field/index.js";
|
|
3
3
|
import { TextArea as n, TextField as r } from "../components/TextField/index.js";
|
|
4
|
-
import { n as i, r as a, t as o } from "./RichTextEditor-
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
7
|
-
import {
|
|
8
|
-
import {
|
|
9
|
-
import {
|
|
10
|
-
import {
|
|
11
|
-
import { a as
|
|
12
|
-
import {
|
|
13
|
-
import {
|
|
14
|
-
import {
|
|
4
|
+
import { n as i, r as a, t as o } from "./RichTextEditor-DEJ-u-ZR.js";
|
|
5
|
+
import { Container as s } from "../components/Container/index.js";
|
|
6
|
+
import { EntryPicker as c } from "../components/EntryPicker/index.js";
|
|
7
|
+
import { NumberField as l } from "../components/NumberField/index.js";
|
|
8
|
+
import { Select as u } from "../components/Select/index.js";
|
|
9
|
+
import { Switch as d } from "../components/Switch/index.js";
|
|
10
|
+
import { r as f, t as p } from "./ColourField-Doew1hLw.js";
|
|
11
|
+
import { a as m, i as h, n as g, r as _, t as v } from "./Slider-vdMFLX-H.js";
|
|
12
|
+
import { a as y, n as ee } from "./DatePicker-DmeWUsOS.js";
|
|
13
|
+
import { TagsInput as te } from "../components/TagsInput/index.js";
|
|
14
|
+
import { Checkbox as b, ChoiceGroup as x, Radio as S } from "../components/Choice/index.js";
|
|
15
|
+
import { CheckboxCard as C, RadioCard as w, SelectionCardGroup as ne } from "../components/SelectionCard/index.js";
|
|
15
16
|
import { useMemo as T, useState as E } from "react";
|
|
16
17
|
import { Fragment as D, jsx as O, jsxs as k } from "react/jsx-runtime";
|
|
17
|
-
//#region src/components/
|
|
18
|
-
var A =
|
|
18
|
+
//#region src/components/RichTextEditor/expanded-width.ts
|
|
19
|
+
var A = ["wide", "full"], j = [
|
|
20
|
+
"sm",
|
|
21
|
+
"md",
|
|
22
|
+
"lg"
|
|
23
|
+
], M = /* @__PURE__ */ new Set([
|
|
19
24
|
"shortText",
|
|
20
25
|
"longText",
|
|
21
26
|
"richText",
|
|
@@ -34,24 +39,28 @@ var A = /* @__PURE__ */ new Set([
|
|
|
34
39
|
"date",
|
|
35
40
|
"divider"
|
|
36
41
|
]);
|
|
37
|
-
function
|
|
42
|
+
function N(e) {
|
|
38
43
|
let t = /* @__PURE__ */ new Set();
|
|
39
44
|
for (let n of e.fields) {
|
|
40
45
|
if (!n.id?.trim() || t.has(n.id)) throw Error("Form field IDs must be nonempty and unique.");
|
|
41
|
-
if (!
|
|
42
|
-
(n.type === "select" || n.type === "radioGroup" || n.type === "checkboxGroup") &&
|
|
46
|
+
if (!M.has(n.type)) throw Error(`Unsupported form field type: ${n.type}`);
|
|
47
|
+
(n.type === "select" || n.type === "radioGroup" || n.type === "checkboxGroup") && ie(n), (n.type === "slider" || n.type === "rangeSlider") && re(n), n.type !== "divider" && P(n), t.add(n.id);
|
|
43
48
|
}
|
|
44
49
|
}
|
|
45
|
-
function
|
|
46
|
-
|
|
50
|
+
function P(e) {
|
|
51
|
+
if (e.width !== void 0 && !j.includes(e.width)) throw Error(`Field ${e.id} needs a width of sm, md or lg.`);
|
|
52
|
+
if (e.type === "richText" && e.expandedWidth !== void 0 && !A.includes(e.expandedWidth)) throw Error(`Rich text field ${e.id} needs an expandedWidth of wide or full.`);
|
|
53
|
+
}
|
|
54
|
+
function re(e) {
|
|
55
|
+
let { min: t, max: n, step: r } = m(e);
|
|
47
56
|
if (![
|
|
48
57
|
t,
|
|
49
58
|
n,
|
|
50
59
|
r
|
|
51
60
|
].every(Number.isFinite) || t >= n || r <= 0) throw Error(`Slider field ${e.id} needs finite min < max and a positive step.`);
|
|
52
|
-
if (e.type === "rangeSlider" && r >
|
|
61
|
+
if (e.type === "rangeSlider" && r > h(n, -t)) throw Error(`Range slider ${e.id} needs room for at least one step.`);
|
|
53
62
|
}
|
|
54
|
-
function
|
|
63
|
+
function ie(e) {
|
|
55
64
|
if (!Array.isArray(e.options)) {
|
|
56
65
|
let t = e.type === "select" ? "Select" : "Choice";
|
|
57
66
|
throw Error(`${t} field ${e.id} needs an options array.`);
|
|
@@ -60,7 +69,7 @@ function N(e) {
|
|
|
60
69
|
let t = e.options.map((e) => e.value);
|
|
61
70
|
if (t.some((e) => typeof e != "string" || !e.trim()) || new Set(t).size !== t.length) throw Error(`Choice field ${e.id} needs nonempty, unique option values.`);
|
|
62
71
|
}
|
|
63
|
-
var
|
|
72
|
+
var F = {
|
|
64
73
|
asset: {
|
|
65
74
|
key: "assetId",
|
|
66
75
|
itemLabel: "asset",
|
|
@@ -72,11 +81,11 @@ var P = {
|
|
|
72
81
|
itemsLabel: "entries"
|
|
73
82
|
}
|
|
74
83
|
};
|
|
75
|
-
function
|
|
84
|
+
function I(e) {
|
|
76
85
|
return e.type === "asset" || e.type === "reference" ? e.picker?.label ?? e.label : e.label;
|
|
77
86
|
}
|
|
78
|
-
function
|
|
79
|
-
let t =
|
|
87
|
+
function L(e) {
|
|
88
|
+
let t = F[e.type], { addLabel: n = `Choose ${I(e)}`, emptyLabel: r, itemLabel: i = t.itemLabel, itemsLabel: a = t.itemsLabel, max: o, isReorderable: s } = e.picker ?? {};
|
|
80
89
|
return {
|
|
81
90
|
addLabel: n,
|
|
82
91
|
emptyLabel: r,
|
|
@@ -86,70 +95,70 @@ function I(e) {
|
|
|
86
95
|
isReorderable: s
|
|
87
96
|
};
|
|
88
97
|
}
|
|
89
|
-
function
|
|
90
|
-
let { key: n } =
|
|
91
|
-
return (Array.isArray(t) ? t : t === void 0 ? [] : [t]).flatMap((e) =>
|
|
98
|
+
function R(e, t) {
|
|
99
|
+
let { key: n } = F[e.type];
|
|
100
|
+
return (Array.isArray(t) ? t : t === void 0 ? [] : [t]).flatMap((e) => B(e, n) ? [e[n]] : []);
|
|
92
101
|
}
|
|
93
|
-
function
|
|
102
|
+
function z(e) {
|
|
94
103
|
if (typeof e != "string") return;
|
|
95
104
|
let t = /^(\d{4}-\d{2}-\d{2}T\d{2}:\d{2})(?::(\d{2})(?:\.(\d{1,3}))?)?(?:Z|\+00:00)$/.exec(e);
|
|
96
105
|
if (!t) return;
|
|
97
106
|
let n = `${t[1]}:${t[2] ?? "00"}.${(t[3] ?? "").padEnd(3, "0")}Z`, r = new Date(n);
|
|
98
107
|
if (Number.isFinite(r.getTime()) && r.toISOString() === n) return n;
|
|
99
108
|
}
|
|
100
|
-
function
|
|
109
|
+
function B(e, t) {
|
|
101
110
|
return !!e && typeof e == "object" && t in e && typeof e[t] == "string" && e[t].trim().length > 0;
|
|
102
111
|
}
|
|
103
|
-
function
|
|
104
|
-
return !!e.text?.trim() || e.type === "horizontalRule" || !!e.content?.some(
|
|
112
|
+
function V(e) {
|
|
113
|
+
return !!e.text?.trim() || e.type === "horizontalRule" || !!e.content?.some(V);
|
|
105
114
|
}
|
|
106
|
-
function
|
|
107
|
-
return `${
|
|
115
|
+
function H(e) {
|
|
116
|
+
return `${I(e)} is required.`;
|
|
108
117
|
}
|
|
109
|
-
function
|
|
118
|
+
function U(e, t) {
|
|
110
119
|
if (typeof t != "string") return "Enter text.";
|
|
111
|
-
if (e.required && !t.trim()) return
|
|
120
|
+
if (e.required && !t.trim()) return H(e);
|
|
112
121
|
if ((e.type === "shortText" || e.type === "longText") && e.maxLength !== void 0 && t.length > e.maxLength) return `Enter no more than ${e.maxLength} characters.`;
|
|
113
122
|
}
|
|
114
|
-
function
|
|
123
|
+
function W(e, t) {
|
|
115
124
|
let n = i(t);
|
|
116
125
|
if (n) return n;
|
|
117
|
-
if (e.required && !
|
|
126
|
+
if (e.required && !V(t)) return H(e);
|
|
118
127
|
}
|
|
119
|
-
function
|
|
128
|
+
function G(e, t) {
|
|
120
129
|
if (typeof t != "string") return "Choose an available option.";
|
|
121
|
-
if (t === "") return e.required ?
|
|
130
|
+
if (t === "") return e.required ? H(e) : void 0;
|
|
122
131
|
if ((e.type === "select" || e.type === "radioGroup") && e.options.length > 0 && !e.options.some((e) => e.value === t)) return "Choose an available option.";
|
|
123
132
|
}
|
|
124
|
-
function
|
|
133
|
+
function K(e) {
|
|
125
134
|
return Array.isArray(e) ? e.filter((e) => typeof e == "string") : [];
|
|
126
135
|
}
|
|
127
|
-
function
|
|
136
|
+
function q(e, t) {
|
|
128
137
|
if (!Array.isArray(t) || !t.every((e) => typeof e == "string" && e.trim()) || new Set(t).size !== t.length) return "Enter a list of unique, nonempty text values.";
|
|
129
|
-
if (e.required && !t.length) return
|
|
138
|
+
if (e.required && !t.length) return H(e);
|
|
130
139
|
if (e.type === "tags" && e.max !== void 0 && t.length > e.max) return `Enter no more than ${e.max} tags.`;
|
|
131
140
|
if (e.type === "checkboxGroup" && e.options.length && t.some((t) => !e.options.some((e) => e.value === t))) return "Choose available options.";
|
|
132
141
|
}
|
|
133
|
-
function
|
|
142
|
+
function J(e, t) {
|
|
134
143
|
if (typeof t != "number" || !Number.isFinite(t)) return "Enter a finite number.";
|
|
135
|
-
let { min: n, max: r } = e.type === "slider" || e.type === "rangeSlider" ?
|
|
144
|
+
let { min: n, max: r } = e.type === "slider" || e.type === "rangeSlider" ? m(e) : e.type === "number" ? e : {};
|
|
136
145
|
if (n !== void 0 && t < n) return `Enter a number of at least ${n}.`;
|
|
137
146
|
if (r !== void 0 && t > r) return `Enter a number no greater than ${r}.`;
|
|
138
147
|
}
|
|
139
|
-
function
|
|
148
|
+
function Y(e, t) {
|
|
140
149
|
if (typeof t != "string") return "Enter a valid calendar date (YYYY-MM-DD).";
|
|
141
|
-
if (!t) return e.required ?
|
|
142
|
-
if (!
|
|
150
|
+
if (!t) return e.required ? H(e) : void 0;
|
|
151
|
+
if (!y(t)) return "Enter a valid calendar date (YYYY-MM-DD).";
|
|
143
152
|
if (e.type === "date") {
|
|
144
153
|
if (e.min && t < e.min) return `Choose a date on or after ${e.min}.`;
|
|
145
154
|
if (e.max && t > e.max) return `Choose a date on or before ${e.max}.`;
|
|
146
155
|
}
|
|
147
156
|
}
|
|
148
|
-
function
|
|
149
|
-
return typeof e == "number" && Number.isFinite(e) ?
|
|
157
|
+
function X(e, t) {
|
|
158
|
+
return typeof e == "number" && Number.isFinite(e) ? _(e, t) : void 0;
|
|
150
159
|
}
|
|
151
|
-
function
|
|
152
|
-
let n = e, r =
|
|
160
|
+
function Z(e, t) {
|
|
161
|
+
let n = e, r = X(n?.min, t), i = X(n?.max, t);
|
|
153
162
|
if (r === void 0 && i === void 0) return;
|
|
154
163
|
let [a, o] = [r ?? t.min, i ?? t.max].sort((e, t) => e - t);
|
|
155
164
|
return {
|
|
@@ -157,56 +166,56 @@ function Y(e, t) {
|
|
|
157
166
|
max: o
|
|
158
167
|
};
|
|
159
168
|
}
|
|
160
|
-
function
|
|
169
|
+
function ae(e, t) {
|
|
161
170
|
if (!t || typeof t != "object" || Array.isArray(t)) return "Enter a range.";
|
|
162
|
-
let n = t, r = n.min, i = n.max, a =
|
|
171
|
+
let n = t, r = n.min, i = n.max, a = J(e, r) ?? J(e, i);
|
|
163
172
|
if (a) return a;
|
|
164
173
|
if (r > i) return "The start must not be greater than the end.";
|
|
165
|
-
if (e.type === "rangeSlider" &&
|
|
174
|
+
if (e.type === "rangeSlider" && h(i, -r) < m(e).step) return "Keep the range endpoints at least one step apart.";
|
|
166
175
|
}
|
|
167
|
-
function
|
|
168
|
-
return typeof t == "string" ? t.trim() ?
|
|
176
|
+
function oe(e, t) {
|
|
177
|
+
return typeof t == "string" ? t.trim() ? f(t) ? void 0 : "Enter a valid colour." : e.required ? H(e) : void 0 : "Enter a valid colour.";
|
|
169
178
|
}
|
|
170
|
-
function
|
|
179
|
+
function Q(e, t) {
|
|
171
180
|
if (e.type !== "asset" && e.type !== "reference") return;
|
|
172
|
-
let { key: n, itemLabel: r, itemsLabel: i } =
|
|
173
|
-
if (!e.multiple) return
|
|
174
|
-
if (!Array.isArray(t) || !t.every((e) =>
|
|
175
|
-
if (e.required && t.length === 0) return
|
|
181
|
+
let { key: n, itemLabel: r, itemsLabel: i } = F[e.type];
|
|
182
|
+
if (!e.multiple) return B(t, n) ? void 0 : `Choose an ${r}.`;
|
|
183
|
+
if (!Array.isArray(t) || !t.every((e) => B(e, n))) return `Choose a list of ${i}.`;
|
|
184
|
+
if (e.required && t.length === 0) return H(e);
|
|
176
185
|
let a = e.picker?.max;
|
|
177
|
-
if (a !== void 0 && t.length > a) return `Choose no more than ${a} ${
|
|
178
|
-
}
|
|
179
|
-
var
|
|
180
|
-
shortText:
|
|
181
|
-
longText:
|
|
182
|
-
richText:
|
|
183
|
-
number:
|
|
184
|
-
slider:
|
|
185
|
-
rangeSlider:
|
|
186
|
-
date:
|
|
187
|
-
colour:
|
|
188
|
-
radioGroup:
|
|
189
|
-
checkboxGroup:
|
|
190
|
-
tags:
|
|
186
|
+
if (a !== void 0 && t.length > a) return `Choose no more than ${a} ${L(e).itemsLabel}.`;
|
|
187
|
+
}
|
|
188
|
+
var se = {
|
|
189
|
+
shortText: U,
|
|
190
|
+
longText: U,
|
|
191
|
+
richText: W,
|
|
192
|
+
number: J,
|
|
193
|
+
slider: J,
|
|
194
|
+
rangeSlider: ae,
|
|
195
|
+
date: Y,
|
|
196
|
+
colour: oe,
|
|
197
|
+
radioGroup: G,
|
|
198
|
+
checkboxGroup: q,
|
|
199
|
+
tags: q,
|
|
191
200
|
boolean: (e, t) => typeof t == "boolean" ? void 0 : "Choose a boolean value.",
|
|
192
|
-
dateTime: (e, t) =>
|
|
193
|
-
select:
|
|
194
|
-
asset:
|
|
195
|
-
reference:
|
|
201
|
+
dateTime: (e, t) => z(t) ? void 0 : "Enter a valid UTC date and time.",
|
|
202
|
+
select: G,
|
|
203
|
+
asset: Q,
|
|
204
|
+
reference: Q
|
|
196
205
|
};
|
|
197
|
-
function
|
|
198
|
-
return t === void 0 ? e.required ?
|
|
206
|
+
function $(e, t) {
|
|
207
|
+
return t === void 0 ? e.required ? H(e) : void 0 : se[e.type](e, t);
|
|
199
208
|
}
|
|
200
|
-
function
|
|
201
|
-
return
|
|
209
|
+
function ce(e, t) {
|
|
210
|
+
return N(e), Object.fromEntries(e.fields.flatMap((e) => {
|
|
202
211
|
if (e.type === "divider") return [];
|
|
203
|
-
let n =
|
|
212
|
+
let n = $(e, Object.hasOwn(t, e.id) ? t[e.id] : void 0);
|
|
204
213
|
return n ? [[e.id, n]] : [];
|
|
205
214
|
}));
|
|
206
215
|
}
|
|
207
216
|
//#endregion
|
|
208
217
|
//#region src/components/FormEditor/choice-control.tsx
|
|
209
|
-
function
|
|
218
|
+
function le({ field: e, option: t, name: n, checked: r, isDisabled: i, invalid: a, onChange: o }) {
|
|
210
219
|
let s = {
|
|
211
220
|
name: n,
|
|
212
221
|
value: t.value,
|
|
@@ -218,14 +227,14 @@ function oe({ field: e, option: t, name: n, checked: r, isDisabled: i, invalid:
|
|
|
218
227
|
}
|
|
219
228
|
};
|
|
220
229
|
if (e.appearance === "card") {
|
|
221
|
-
let n = e.type === "radioGroup" ?
|
|
230
|
+
let n = e.type === "radioGroup" ? w : C;
|
|
222
231
|
return /* @__PURE__ */ O(n, {
|
|
223
232
|
...s,
|
|
224
233
|
title: t.label,
|
|
225
234
|
description: t.description
|
|
226
235
|
});
|
|
227
236
|
}
|
|
228
|
-
let c = e.type === "radioGroup" ?
|
|
237
|
+
let c = e.type === "radioGroup" ? S : b;
|
|
229
238
|
return /* @__PURE__ */ O(c, {
|
|
230
239
|
...s,
|
|
231
240
|
children: /* @__PURE__ */ k("span", { children: [t.label, t.description && /* @__PURE__ */ O("span", {
|
|
@@ -234,13 +243,13 @@ function oe({ field: e, option: t, name: n, checked: r, isDisabled: i, invalid:
|
|
|
234
243
|
})] })
|
|
235
244
|
});
|
|
236
245
|
}
|
|
237
|
-
function
|
|
238
|
-
let s = t.type === "checkboxGroup", c = s ?
|
|
246
|
+
function ue({ field: t, stored: n, isDisabled: r, required: i, accessibility: a, onChange: o }) {
|
|
247
|
+
let s = t.type === "checkboxGroup", c = s ? K(n) : typeof n == "string" && n ? [n] : [], l = t.appearance === "card" ? ne : x;
|
|
239
248
|
return /* @__PURE__ */ k(D, { children: [/* @__PURE__ */ O(l, {
|
|
240
249
|
...a,
|
|
241
250
|
label: t.label,
|
|
242
251
|
columns: t.columns ?? (t.appearance === "card" ? 2 : 1),
|
|
243
|
-
children: t.options.map((e) => /* @__PURE__ */ O(
|
|
252
|
+
children: t.options.map((e) => /* @__PURE__ */ O(le, {
|
|
244
253
|
field: t,
|
|
245
254
|
option: e,
|
|
246
255
|
name: a.id,
|
|
@@ -261,9 +270,9 @@ function se({ field: t, stored: n, isDisabled: r, required: i, accessibility: a,
|
|
|
261
270
|
}
|
|
262
271
|
//#endregion
|
|
263
272
|
//#region src/components/FormEditor/additional-control.tsx
|
|
264
|
-
function
|
|
265
|
-
let a =
|
|
266
|
-
return /* @__PURE__ */ O(
|
|
273
|
+
function de({ field: e, stored: t, isDisabled: n, accessibility: r, onChange: i }) {
|
|
274
|
+
let a = m(e), o = X(t, a);
|
|
275
|
+
return /* @__PURE__ */ O(g, {
|
|
267
276
|
...r,
|
|
268
277
|
...a,
|
|
269
278
|
prefix: e.prefix,
|
|
@@ -279,9 +288,9 @@ function ce({ field: e, stored: t, isDisabled: n, accessibility: r, onChange: i
|
|
|
279
288
|
}
|
|
280
289
|
});
|
|
281
290
|
}
|
|
282
|
-
function
|
|
283
|
-
let a =
|
|
284
|
-
return /* @__PURE__ */ O(
|
|
291
|
+
function fe({ field: e, stored: t, isDisabled: n, accessibility: r, onChange: i }) {
|
|
292
|
+
let a = m(e), o = Z(t, a);
|
|
293
|
+
return /* @__PURE__ */ O(v, {
|
|
285
294
|
...r,
|
|
286
295
|
...a,
|
|
287
296
|
prefix: e.prefix,
|
|
@@ -302,7 +311,7 @@ function $({ field: e, stored: t, isDisabled: n, accessibility: r, onChange: i }
|
|
|
302
311
|
}
|
|
303
312
|
});
|
|
304
313
|
}
|
|
305
|
-
function
|
|
314
|
+
function pe({ field: e, stored: t, isDisabled: n, required: r, accessibility: i, onChange: a }) {
|
|
306
315
|
let o = {
|
|
307
316
|
stored: t,
|
|
308
317
|
isDisabled: n,
|
|
@@ -312,19 +321,19 @@ function le({ field: e, stored: t, isDisabled: n, required: r, accessibility: i,
|
|
|
312
321
|
};
|
|
313
322
|
switch (e.type) {
|
|
314
323
|
case "radioGroup":
|
|
315
|
-
case "checkboxGroup": return /* @__PURE__ */ O(
|
|
324
|
+
case "checkboxGroup": return /* @__PURE__ */ O(ue, {
|
|
316
325
|
field: e,
|
|
317
326
|
...o
|
|
318
327
|
});
|
|
319
|
-
case "rangeSlider": return /* @__PURE__ */ O(
|
|
328
|
+
case "rangeSlider": return /* @__PURE__ */ O(fe, {
|
|
320
329
|
field: e,
|
|
321
330
|
...o
|
|
322
331
|
});
|
|
323
|
-
case "slider": return /* @__PURE__ */ O(
|
|
332
|
+
case "slider": return /* @__PURE__ */ O(de, {
|
|
324
333
|
field: e,
|
|
325
334
|
...o
|
|
326
335
|
});
|
|
327
|
-
case "colour": return /* @__PURE__ */ O(
|
|
336
|
+
case "colour": return /* @__PURE__ */ O(p, {
|
|
328
337
|
...i,
|
|
329
338
|
required: r,
|
|
330
339
|
placeholder: e.placeholder,
|
|
@@ -338,20 +347,20 @@ function le({ field: e, stored: t, isDisabled: n, required: r, accessibility: i,
|
|
|
338
347
|
value: typeof t == "string" ? t : "",
|
|
339
348
|
onInput: (e) => {
|
|
340
349
|
let t = e.currentTarget.value;
|
|
341
|
-
t.trim() && !
|
|
350
|
+
t.trim() && !f(t) && a(t);
|
|
342
351
|
},
|
|
343
352
|
onValueChange: (e) => a(e === "" ? void 0 : e)
|
|
344
353
|
});
|
|
345
|
-
case "tags": return /* @__PURE__ */ O(
|
|
354
|
+
case "tags": return /* @__PURE__ */ O(te, {
|
|
346
355
|
...i,
|
|
347
356
|
required: r,
|
|
348
357
|
placeholder: e.placeholder,
|
|
349
358
|
max: e.max,
|
|
350
359
|
isDisabled: n,
|
|
351
|
-
value:
|
|
360
|
+
value: K(t),
|
|
352
361
|
onValueChange: a
|
|
353
362
|
});
|
|
354
|
-
case "date": return /* @__PURE__ */ O(
|
|
363
|
+
case "date": return /* @__PURE__ */ O(ee, {
|
|
355
364
|
...i,
|
|
356
365
|
placeholder: e.placeholder,
|
|
357
366
|
min: e.min,
|
|
@@ -367,7 +376,7 @@ function le({ field: e, stored: t, isDisabled: n, required: r, accessibility: i,
|
|
|
367
376
|
}
|
|
368
377
|
//#endregion
|
|
369
378
|
//#region src/components/FormEditor/control.tsx
|
|
370
|
-
function
|
|
379
|
+
function me(e, t) {
|
|
371
380
|
if (e.type === "asset") {
|
|
372
381
|
let n = t.map((e) => ({ assetId: e }));
|
|
373
382
|
return e.multiple ? n : n[0];
|
|
@@ -375,8 +384,8 @@ function ue(e, t) {
|
|
|
375
384
|
let n = t.map((e) => ({ entryId: e }));
|
|
376
385
|
return e.multiple ? n : n[0];
|
|
377
386
|
}
|
|
378
|
-
function
|
|
379
|
-
return /* @__PURE__ */ O(
|
|
387
|
+
function he({ field: e, stored: t, isDisabled: n, required: r, accessibility: i, onChange: a }) {
|
|
388
|
+
return /* @__PURE__ */ O(l, {
|
|
380
389
|
...i,
|
|
381
390
|
required: r,
|
|
382
391
|
isDisabled: n,
|
|
@@ -396,9 +405,9 @@ function de({ field: e, stored: t, isDisabled: n, required: r, accessibility: i,
|
|
|
396
405
|
}
|
|
397
406
|
});
|
|
398
407
|
}
|
|
399
|
-
function
|
|
408
|
+
function ge({ field: e, stored: t, isDisabled: n, required: r, accessibility: i, onChange: a }) {
|
|
400
409
|
let o = !r && !e.options.some((e) => e.value === "");
|
|
401
|
-
return /* @__PURE__ */ O(
|
|
410
|
+
return /* @__PURE__ */ O(u, {
|
|
402
411
|
...i,
|
|
403
412
|
"aria-required": r || void 0,
|
|
404
413
|
isDisabled: n,
|
|
@@ -413,28 +422,28 @@ function fe({ field: e, stored: t, isDisabled: n, required: r, accessibility: i,
|
|
|
413
422
|
onValueChange: (e) => a(e === "" ? void 0 : e)
|
|
414
423
|
});
|
|
415
424
|
}
|
|
416
|
-
function
|
|
417
|
-
return /* @__PURE__ */ O(
|
|
425
|
+
function _e({ field: e, selected: t, items: n, isDisabled: r, accessibility: i, onChange: a }) {
|
|
426
|
+
return /* @__PURE__ */ O(c, {
|
|
418
427
|
...i,
|
|
419
428
|
items: n,
|
|
420
429
|
value: t,
|
|
421
|
-
...
|
|
430
|
+
...L(e),
|
|
422
431
|
mode: e.multiple ? "multiple" : "single",
|
|
423
432
|
isDisabled: r,
|
|
424
|
-
onValueChange: (t) => a(
|
|
433
|
+
onValueChange: (t) => a(me(e, t))
|
|
425
434
|
});
|
|
426
435
|
}
|
|
427
|
-
function
|
|
436
|
+
function ve({ field: e, stored: t, selected: i, items: s, isDisabled: c, accessibility: { required: l, ...u }, onChange: f }) {
|
|
428
437
|
let p = {
|
|
429
438
|
stored: t,
|
|
430
439
|
isDisabled: c,
|
|
431
440
|
required: l,
|
|
432
|
-
accessibility:
|
|
441
|
+
accessibility: u,
|
|
433
442
|
onChange: f
|
|
434
443
|
};
|
|
435
444
|
switch (e.type) {
|
|
436
445
|
case "shortText": return /* @__PURE__ */ O(r, {
|
|
437
|
-
...
|
|
446
|
+
...u,
|
|
438
447
|
required: l,
|
|
439
448
|
disabled: c,
|
|
440
449
|
placeholder: e.placeholder,
|
|
@@ -446,7 +455,7 @@ function me({ field: e, stored: t, selected: i, items: s, isDisabled: c, accessi
|
|
|
446
455
|
onChange: (e) => f(e.target.value)
|
|
447
456
|
});
|
|
448
457
|
case "longText": return /* @__PURE__ */ O(n, {
|
|
449
|
-
...
|
|
458
|
+
...u,
|
|
450
459
|
required: l,
|
|
451
460
|
disabled: c,
|
|
452
461
|
placeholder: e.placeholder,
|
|
@@ -457,29 +466,30 @@ function me({ field: e, stored: t, selected: i, items: s, isDisabled: c, accessi
|
|
|
457
466
|
value: typeof t == "string" ? t : "",
|
|
458
467
|
onChange: (e) => f(e.target.value)
|
|
459
468
|
});
|
|
460
|
-
case "number": return /* @__PURE__ */ O(
|
|
469
|
+
case "number": return /* @__PURE__ */ O(he, {
|
|
461
470
|
field: e,
|
|
462
471
|
...p
|
|
463
472
|
});
|
|
464
|
-
case "boolean": return /* @__PURE__ */ O(
|
|
465
|
-
...
|
|
473
|
+
case "boolean": return /* @__PURE__ */ O(d, {
|
|
474
|
+
...u,
|
|
466
475
|
isDisabled: c,
|
|
467
476
|
autoFocus: e.autoFocus,
|
|
468
477
|
isSelected: t === !0,
|
|
469
478
|
onSelectedChange: f
|
|
470
479
|
});
|
|
471
480
|
case "dateTime": return /* @__PURE__ */ O(r, {
|
|
472
|
-
...
|
|
481
|
+
...u,
|
|
473
482
|
required: l,
|
|
474
483
|
disabled: c,
|
|
475
484
|
type: "datetime-local",
|
|
476
485
|
step: "0.001",
|
|
477
486
|
autoFocus: e.autoFocus,
|
|
478
|
-
value:
|
|
479
|
-
onChange: (e) => f(
|
|
487
|
+
value: z(t)?.slice(0, -1) ?? "",
|
|
488
|
+
onChange: (e) => f(z(`${e.target.value}Z`))
|
|
480
489
|
});
|
|
481
490
|
case "richText": return /* @__PURE__ */ O(o, {
|
|
482
|
-
...
|
|
491
|
+
...u,
|
|
492
|
+
expandedWidth: e.expandedWidth,
|
|
483
493
|
label: e.label,
|
|
484
494
|
isRequired: l,
|
|
485
495
|
isDisabled: c,
|
|
@@ -488,18 +498,18 @@ function me({ field: e, stored: t, selected: i, items: s, isDisabled: c, accessi
|
|
|
488
498
|
value: t === void 0 ? a : t,
|
|
489
499
|
onChange: f
|
|
490
500
|
});
|
|
491
|
-
case "select": return /* @__PURE__ */ O(
|
|
501
|
+
case "select": return /* @__PURE__ */ O(ge, {
|
|
492
502
|
field: e,
|
|
493
503
|
...p
|
|
494
504
|
});
|
|
495
505
|
case "asset":
|
|
496
|
-
case "reference": return /* @__PURE__ */ O(
|
|
506
|
+
case "reference": return /* @__PURE__ */ O(_e, {
|
|
497
507
|
field: e,
|
|
498
508
|
items: s,
|
|
499
509
|
selected: i ?? [],
|
|
500
510
|
...p
|
|
501
511
|
});
|
|
502
|
-
default: return /* @__PURE__ */ O(
|
|
512
|
+
default: return /* @__PURE__ */ O(pe, {
|
|
503
513
|
field: e,
|
|
504
514
|
...p
|
|
505
515
|
});
|
|
@@ -507,44 +517,50 @@ function me({ field: e, stored: t, selected: i, items: s, isDisabled: c, accessi
|
|
|
507
517
|
}
|
|
508
518
|
//#endregion
|
|
509
519
|
//#region src/components/FormEditor/index.tsx
|
|
510
|
-
function
|
|
511
|
-
let
|
|
520
|
+
function ye({ field: e, stored: n, items: r, isDisabled: i, error: a, isErrorVisible: o, onChange: c }) {
|
|
521
|
+
let l = T(() => a === void 0 && o ? $(e, n) : void 0, [
|
|
512
522
|
a,
|
|
513
523
|
o,
|
|
514
524
|
e,
|
|
515
525
|
n
|
|
516
|
-
]),
|
|
517
|
-
return /* @__PURE__ */ O(
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
526
|
+
]), u = T(() => e.type === "asset" || e.type === "reference" ? R(e, n) : void 0, [e, n]);
|
|
527
|
+
return /* @__PURE__ */ O(s, {
|
|
528
|
+
width: e.width,
|
|
529
|
+
padded: !1,
|
|
530
|
+
center: !1,
|
|
531
|
+
className: "ds-form-editor__field",
|
|
532
|
+
children: /* @__PURE__ */ O(t, {
|
|
533
|
+
label: e.type === "dateTime" ? `${e.label} (UTC)` : I(e),
|
|
534
|
+
hint: e.hint,
|
|
535
|
+
error: a ?? l,
|
|
536
|
+
isRequired: e.required,
|
|
537
|
+
count: u?.length ?? (e.type === "checkboxGroup" ? K(n).length : void 0),
|
|
538
|
+
isGroup: u !== void 0 || be.has(e.type),
|
|
539
|
+
children: (t) => /* @__PURE__ */ O(ve, {
|
|
540
|
+
field: e,
|
|
541
|
+
stored: n,
|
|
542
|
+
selected: u,
|
|
543
|
+
items: r,
|
|
544
|
+
isDisabled: i,
|
|
545
|
+
accessibility: t,
|
|
546
|
+
onChange: c
|
|
547
|
+
})
|
|
532
548
|
})
|
|
533
549
|
});
|
|
534
550
|
}
|
|
535
|
-
var
|
|
551
|
+
var be = /* @__PURE__ */ new Set([
|
|
536
552
|
"radioGroup",
|
|
537
553
|
"checkboxGroup",
|
|
538
554
|
"rangeSlider"
|
|
539
|
-
]),
|
|
555
|
+
]), xe = /* @__PURE__ */ new Set([
|
|
540
556
|
"slider",
|
|
541
557
|
"rangeSlider",
|
|
542
558
|
"date",
|
|
543
559
|
"colour"
|
|
544
560
|
]);
|
|
545
|
-
function
|
|
561
|
+
function Se({ schema: e, value: t, defaultValue: n = {}, onValueChange: r, pickerItems: i = {}, errors: a = {}, isDisabled: o = !1, showAllErrors: s = !1, columns: c = 1, minColumnWidth: l = "16rem", className: u, style: d, ...f }) {
|
|
546
562
|
let [p, m] = E(n), [h, g] = E(() => /* @__PURE__ */ new Set()), _ = t ?? p;
|
|
547
|
-
T(() =>
|
|
563
|
+
T(() => N(e), [e]);
|
|
548
564
|
let v = (e, n) => {
|
|
549
565
|
let i = { ..._ };
|
|
550
566
|
n === void 0 ? delete i[e] : i[e] = n, t === void 0 && m(i), g((t) => new Set(t).add(e)), r?.(i, { fieldId: e });
|
|
@@ -565,8 +581,8 @@ function ve({ schema: e, value: t, defaultValue: n = {}, onValueChange: r, picke
|
|
|
565
581
|
...f,
|
|
566
582
|
children: e.fields.map((e) => {
|
|
567
583
|
if (e.type === "divider") return /* @__PURE__ */ O("hr", { className: "ds-form-editor__divider" }, e.id);
|
|
568
|
-
let t = Object.hasOwn(_, e.id) ? _[e.id] : void 0, n = o || !!e.isDisabled, r = n || "readOnly" in e && !!e.readOnly, c = typeof t == "string" ? t.trim() !== "" : t !== void 0, l = s || h.has(e.id) || c &&
|
|
569
|
-
return /* @__PURE__ */ O(
|
|
584
|
+
let t = Object.hasOwn(_, e.id) ? _[e.id] : void 0, n = o || !!e.isDisabled, r = n || "readOnly" in e && !!e.readOnly, c = typeof t == "string" ? t.trim() !== "" : t !== void 0, l = s || h.has(e.id) || c && xe.has(e.type) || e.type === "number" && typeof t == "number";
|
|
585
|
+
return /* @__PURE__ */ O(ye, {
|
|
570
586
|
field: e,
|
|
571
587
|
stored: t,
|
|
572
588
|
items: i[e.id] ?? [],
|
|
@@ -581,6 +597,6 @@ function ve({ schema: e, value: t, defaultValue: n = {}, onValueChange: r, picke
|
|
|
581
597
|
});
|
|
582
598
|
}
|
|
583
599
|
//#endregion
|
|
584
|
-
export {
|
|
600
|
+
export { ce as n, Se as t };
|
|
585
601
|
|
|
586
|
-
//# sourceMappingURL=FormEditor-
|
|
602
|
+
//# sourceMappingURL=FormEditor-DTnFO4oS.js.map
|