asterui 0.12.50 → 0.12.52
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/components/Anchor.js +53 -53
- package/dist/components/Anchor.js.map +1 -1
- package/dist/components/Form.d.ts +8 -2
- package/dist/components/Form.js +158 -155
- package/dist/components/Form.js.map +1 -1
- package/dist/components/Layout.js +66 -66
- package/dist/components/Layout.js.map +1 -1
- package/dist/components/Splitter.js +93 -95
- package/dist/components/Splitter.js.map +1 -1
- package/package.json +1 -1
package/dist/components/Form.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { jsx as t, jsxs as
|
|
2
|
-
import { createContext as
|
|
3
|
-
import { useForm as
|
|
4
|
-
import { useConfig as
|
|
5
|
-
const Ne = "input",
|
|
1
|
+
import { jsx as t, jsxs as C } from "react/jsx-runtime";
|
|
2
|
+
import { createContext as pe, useId as te, useEffect as se, useRef as re, isValidElement as ne, cloneElement as ge, useContext as ve } from "react";
|
|
3
|
+
import { useForm as oe, useFieldArray as xe, useWatch as ye, Controller as be } from "react-hook-form";
|
|
4
|
+
import { useConfig as $e } from "./ConfigProvider.js";
|
|
5
|
+
const Ne = "input", ke = "input-xs", Fe = "input-sm", Ve = "input-md", we = "input-lg", Le = "input-xl", Ce = "floating-label", Ee = "loading", Ae = "loading-spinner", je = "loading-xs", ze = "tooltip", Se = "tooltip-top", J = pe(void 0), X = {
|
|
6
6
|
email: {
|
|
7
7
|
value: /^[A-Z0-9._%+-]+@[A-Z0-9.-]+\.[A-Z]{2,}$/i,
|
|
8
8
|
message: "Please enter a valid email address"
|
|
@@ -16,262 +16,265 @@ const Ne = "input", $e = "input-xs", ke = "input-sm", Fe = "input-md", Ve = "inp
|
|
|
16
16
|
message: "Please enter a valid number"
|
|
17
17
|
}
|
|
18
18
|
};
|
|
19
|
-
function
|
|
20
|
-
const s =
|
|
19
|
+
function K() {
|
|
20
|
+
const s = ve(J);
|
|
21
21
|
if (!s)
|
|
22
22
|
throw new Error("Form compound components must be used within Form");
|
|
23
23
|
return s;
|
|
24
24
|
}
|
|
25
|
-
function
|
|
25
|
+
function Me({
|
|
26
26
|
form: s,
|
|
27
27
|
onFinish: n,
|
|
28
28
|
onFinishFailed: r,
|
|
29
29
|
initialValues: i,
|
|
30
|
-
layout:
|
|
30
|
+
layout: b = "vertical",
|
|
31
31
|
labelWidth: h = 60,
|
|
32
|
-
size:
|
|
33
|
-
disabled:
|
|
34
|
-
children:
|
|
35
|
-
className:
|
|
32
|
+
size: V,
|
|
33
|
+
disabled: v = !1,
|
|
34
|
+
children: l,
|
|
35
|
+
className: c = "",
|
|
36
36
|
noValidate: x = !0,
|
|
37
37
|
...y
|
|
38
38
|
}) {
|
|
39
|
-
const { componentSize:
|
|
39
|
+
const { componentSize: $ } = $e(), d = V ?? $ ?? "md", z = oe({
|
|
40
40
|
defaultValues: i
|
|
41
|
-
}),
|
|
42
|
-
if (
|
|
43
|
-
n && n(
|
|
41
|
+
}), N = s || z, W = async (w) => {
|
|
42
|
+
if (w.preventDefault(), await N.trigger())
|
|
43
|
+
n && n(N.getValues());
|
|
44
44
|
else if (r) {
|
|
45
|
-
const
|
|
46
|
-
for (const
|
|
47
|
-
const
|
|
48
|
-
|
|
45
|
+
const u = N.formState.errors, k = [], S = (M, I = "") => {
|
|
46
|
+
for (const P in M) {
|
|
47
|
+
const R = I ? `${I}.${P}` : P, F = M[P];
|
|
48
|
+
F?.message ? k.push({ name: R, errors: [F.message] }) : typeof F == "object" && F !== null && S(F, R);
|
|
49
49
|
}
|
|
50
50
|
};
|
|
51
|
-
S(
|
|
51
|
+
S(u), r({ values: N.getValues(), errorFields: k });
|
|
52
52
|
}
|
|
53
|
-
},
|
|
54
|
-
|
|
53
|
+
}, j = (w) => {
|
|
54
|
+
w.preventDefault(), N.reset(i);
|
|
55
55
|
};
|
|
56
|
-
return /* @__PURE__ */ t(
|
|
56
|
+
return /* @__PURE__ */ t(J.Provider, { value: { form: N, layout: b, labelWidth: h, size: d, disabled: v }, children: /* @__PURE__ */ t("form", { onSubmit: W, onReset: j, className: c, noValidate: x, ...y, children: l }) });
|
|
57
57
|
}
|
|
58
|
-
function
|
|
58
|
+
function Pe({
|
|
59
59
|
name: s,
|
|
60
60
|
label: n,
|
|
61
61
|
floatingLabel: r,
|
|
62
62
|
help: i,
|
|
63
|
-
required:
|
|
63
|
+
required: b = !1,
|
|
64
64
|
rules: h,
|
|
65
|
-
valuePropName:
|
|
66
|
-
inline:
|
|
67
|
-
className:
|
|
68
|
-
children:
|
|
65
|
+
valuePropName: V = "value",
|
|
66
|
+
inline: v = !1,
|
|
67
|
+
className: l = "",
|
|
68
|
+
children: c,
|
|
69
69
|
tooltip: x,
|
|
70
70
|
extra: y,
|
|
71
|
-
hasFeedback:
|
|
72
|
-
dependencies:
|
|
73
|
-
validateTrigger:
|
|
74
|
-
initialValue:
|
|
75
|
-
hidden:
|
|
76
|
-
addonBefore:
|
|
77
|
-
addonAfter:
|
|
71
|
+
hasFeedback: $ = !1,
|
|
72
|
+
dependencies: d,
|
|
73
|
+
validateTrigger: z = "onChange",
|
|
74
|
+
initialValue: N,
|
|
75
|
+
hidden: W = !1,
|
|
76
|
+
addonBefore: j,
|
|
77
|
+
addonAfter: w,
|
|
78
|
+
"data-testid": m
|
|
78
79
|
}) {
|
|
79
|
-
const { form:
|
|
80
|
+
const { form: u, size: k, listName: S, layout: M, labelWidth: I, disabled: P } = K(), R = te(), F = te();
|
|
80
81
|
if (!s)
|
|
81
|
-
return /* @__PURE__ */ t("div", { className: `${
|
|
82
|
-
let
|
|
83
|
-
Array.isArray(s) ?
|
|
84
|
-
|
|
82
|
+
return /* @__PURE__ */ t("div", { className: `${v ? "w-auto" : "w-full"} ${l}`, style: W ? { display: "none" } : void 0, children: c });
|
|
83
|
+
let p;
|
|
84
|
+
Array.isArray(s) ? p = (S ? [S, ...s] : s).join(".") : p = s, se(() => {
|
|
85
|
+
N !== void 0 && u.getValues(p) === void 0 && u.setValue(p, N);
|
|
85
86
|
}, []);
|
|
86
|
-
const
|
|
87
|
-
control:
|
|
88
|
-
name:
|
|
89
|
-
disabled:
|
|
90
|
-
}),
|
|
91
|
-
|
|
92
|
-
const
|
|
93
|
-
|
|
94
|
-
if (
|
|
95
|
-
if (
|
|
96
|
-
|
|
87
|
+
const Z = ye({
|
|
88
|
+
control: u.control,
|
|
89
|
+
name: d,
|
|
90
|
+
disabled: !d || d.length === 0
|
|
91
|
+
}), H = re(u);
|
|
92
|
+
H.current = u;
|
|
93
|
+
const D = re(void 0);
|
|
94
|
+
se(() => {
|
|
95
|
+
if (!d || d.length === 0) return;
|
|
96
|
+
if (D.current === void 0) {
|
|
97
|
+
D.current = JSON.stringify(Z);
|
|
97
98
|
return;
|
|
98
99
|
}
|
|
99
|
-
const e = JSON.stringify(
|
|
100
|
-
|
|
101
|
-
}, [
|
|
102
|
-
const
|
|
100
|
+
const e = JSON.stringify(Z);
|
|
101
|
+
D.current !== e && (D.current = e, H.current.trigger(p));
|
|
102
|
+
}, [Z, d, p]);
|
|
103
|
+
const B = ((e) => {
|
|
103
104
|
const o = e.split(".");
|
|
104
|
-
let a =
|
|
105
|
-
for (const
|
|
105
|
+
let a = u.formState.errors;
|
|
106
|
+
for (const T of o) {
|
|
106
107
|
if (!a) break;
|
|
107
|
-
a = a[
|
|
108
|
+
a = a[T];
|
|
108
109
|
}
|
|
109
110
|
return a;
|
|
110
|
-
})(
|
|
111
|
-
|
|
112
|
-
for (const e of
|
|
113
|
-
if (e.required && (
|
|
114
|
-
pattern:
|
|
115
|
-
message: e.message ||
|
|
111
|
+
})(p), E = B?.message, ae = h ? Array.isArray(h) ? h : [h] : [], A = {}, q = [], O = [];
|
|
112
|
+
b && (A.required = "This field is required");
|
|
113
|
+
for (const e of ae) {
|
|
114
|
+
if (e.required && (A.required = typeof e.required == "string" ? e.required : e.message || "This field is required"), e.type && X[e.type] && q.push({
|
|
115
|
+
pattern: X[e.type].value,
|
|
116
|
+
message: e.message || X[e.type].message
|
|
116
117
|
}), e.min !== void 0) {
|
|
117
118
|
const o = typeof e.min == "object" ? e.min.value : e.min, a = typeof e.min == "object" ? e.min.message : e.message || `Minimum length is ${o} characters`;
|
|
118
|
-
|
|
119
|
+
A.minLength = { value: o, message: a };
|
|
119
120
|
}
|
|
120
121
|
if (e.max !== void 0) {
|
|
121
122
|
const o = typeof e.max == "object" ? e.max.value : e.max, a = typeof e.max == "object" ? e.max.message : e.message || `Maximum length is ${o} characters`;
|
|
122
|
-
|
|
123
|
+
A.maxLength = { value: o, message: a };
|
|
123
124
|
}
|
|
124
125
|
if (e.pattern) {
|
|
125
126
|
const o = e.pattern instanceof RegExp ? e.pattern : e.pattern.value, a = e.pattern instanceof RegExp ? e.message || "Invalid format" : e.pattern.message;
|
|
126
|
-
|
|
127
|
+
q.push({ pattern: o, message: a });
|
|
127
128
|
}
|
|
128
|
-
e.validate &&
|
|
129
|
+
e.validate && O.push(e.validate);
|
|
129
130
|
}
|
|
130
|
-
(
|
|
131
|
-
if (!e && !
|
|
132
|
-
for (const { pattern: o, message: a } of
|
|
131
|
+
(q.length > 0 || O.length > 0) && (A.validate = async (e) => {
|
|
132
|
+
if (!e && !A.required) return !0;
|
|
133
|
+
for (const { pattern: o, message: a } of q)
|
|
133
134
|
if (e && !o.test(e))
|
|
134
135
|
return a;
|
|
135
|
-
for (const o of
|
|
136
|
+
for (const o of O) {
|
|
136
137
|
const a = await o(e);
|
|
137
138
|
if (a !== !0)
|
|
138
139
|
return a;
|
|
139
140
|
}
|
|
140
141
|
return !0;
|
|
141
142
|
});
|
|
142
|
-
const
|
|
143
|
+
const U = Array.isArray(z) ? z : [z], Y = U.includes("onChange"), ie = U.includes("onBlur"), le = ({ hasError: e, isValidating: o }) => o ? /* @__PURE__ */ t("span", { className: `${Ee} ${Ae} ${je} text-base-content/50` }) : e ? /* @__PURE__ */ t("svg", { className: "w-4 h-4 text-error", fill: "none", viewBox: "0 0 24 24", stroke: "currentColor", children: /* @__PURE__ */ t("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M6 18L18 6M6 6l12 12" }) }) : /* @__PURE__ */ t("svg", { className: "w-4 h-4 text-success", fill: "none", viewBox: "0 0 24 24", stroke: "currentColor", children: /* @__PURE__ */ t("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M5 13l4 4L19 7" }) }), ce = () => /* @__PURE__ */ t("div", { className: `${ze} ${Se} ml-1`, "data-tip": x, children: /* @__PURE__ */ t("svg", { className: "w-4 h-4 text-base-content/50 cursor-help", fill: "none", viewBox: "0 0 24 24", stroke: "currentColor", children: /* @__PURE__ */ t("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" }) }) });
|
|
143
144
|
return /* @__PURE__ */ t(
|
|
144
|
-
|
|
145
|
+
be,
|
|
145
146
|
{
|
|
146
|
-
name:
|
|
147
|
-
control:
|
|
148
|
-
rules:
|
|
147
|
+
name: p,
|
|
148
|
+
control: u.control,
|
|
149
|
+
rules: A,
|
|
149
150
|
render: ({ field: e, fieldState: o }) => {
|
|
150
|
-
const { value: a, onChange:
|
|
151
|
-
id:
|
|
151
|
+
const { value: a, onChange: T, onBlur: de, ref: ue } = e, me = o.isTouched && u.formState.isValidating, g = {
|
|
152
|
+
id: R,
|
|
152
153
|
ref: ue,
|
|
153
|
-
"aria-invalid":
|
|
154
|
-
"aria-describedby":
|
|
154
|
+
"aria-invalid": B ? !0 : void 0,
|
|
155
|
+
"aria-describedby": B ? F : void 0,
|
|
156
|
+
"data-testid": m ? `${m}-input` : void 0
|
|
155
157
|
};
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
},
|
|
159
|
-
|
|
160
|
-
}) : (
|
|
161
|
-
f && f.target !== void 0 ?
|
|
162
|
-
}),
|
|
163
|
-
const
|
|
164
|
-
xs:
|
|
165
|
-
sm:
|
|
166
|
-
md:
|
|
167
|
-
lg:
|
|
168
|
-
xl:
|
|
169
|
-
},
|
|
170
|
-
const f = /* @__PURE__ */
|
|
171
|
-
|
|
172
|
-
|
|
158
|
+
g.onBlur = () => {
|
|
159
|
+
de(), ie && u.trigger(p);
|
|
160
|
+
}, V === "checked" ? (g.checked = a, g.onChange = (f) => {
|
|
161
|
+
T(f.target.checked), Y && u.trigger(p);
|
|
162
|
+
}) : (g.value = a || "", g.onChange = (f) => {
|
|
163
|
+
f && f.target !== void 0 ? T(f.target.value) : T(f), Y && u.trigger(p);
|
|
164
|
+
}), k && ne(c) && (c.props.size || (g.size = k)), B && (g.color = "error", g["aria-invalid"] = !0), P && (g.disabled = !0), (j || w) && (g.unstyled = !0);
|
|
165
|
+
const G = ne(c) ? ge(c, g) : c, L = M === "horizontal", Q = M === "inline", ee = {
|
|
166
|
+
xs: ke,
|
|
167
|
+
sm: Fe,
|
|
168
|
+
md: Ve,
|
|
169
|
+
lg: we,
|
|
170
|
+
xl: Le
|
|
171
|
+
}, fe = () => {
|
|
172
|
+
const f = /* @__PURE__ */ C("div", { className: `${L ? "flex-1" : ""} ${$ ? "relative" : ""}`, children: [
|
|
173
|
+
G,
|
|
174
|
+
$ && o.isTouched && /* @__PURE__ */ t("span", { className: "absolute right-3 top-1/2 -translate-y-1/2 pointer-events-none", children: /* @__PURE__ */ t(le, { hasError: !!B, isValidating: me }) })
|
|
173
175
|
] });
|
|
174
176
|
if (r) {
|
|
175
|
-
const
|
|
176
|
-
|
|
177
|
-
|
|
177
|
+
const _ = [
|
|
178
|
+
Ce,
|
|
179
|
+
k && ee[k]
|
|
178
180
|
].filter(Boolean).join(" ");
|
|
179
|
-
return /* @__PURE__ */
|
|
180
|
-
|
|
181
|
-
/* @__PURE__ */
|
|
181
|
+
return /* @__PURE__ */ C("label", { className: _, children: [
|
|
182
|
+
G,
|
|
183
|
+
/* @__PURE__ */ C("span", { children: [
|
|
182
184
|
r,
|
|
183
|
-
|
|
185
|
+
b && /* @__PURE__ */ t("span", { className: "text-error ml-1", children: "*" })
|
|
184
186
|
] })
|
|
185
187
|
] });
|
|
186
188
|
}
|
|
187
189
|
return f;
|
|
188
|
-
},
|
|
189
|
-
if (!
|
|
190
|
-
const
|
|
190
|
+
}, he = (f) => {
|
|
191
|
+
if (!j && !w) return f;
|
|
192
|
+
const _ = [
|
|
191
193
|
Ne,
|
|
192
194
|
"flex",
|
|
193
195
|
"items-center",
|
|
194
196
|
"gap-2",
|
|
195
|
-
|
|
197
|
+
k && ee[k]
|
|
196
198
|
].filter(Boolean).join(" ");
|
|
197
|
-
return /* @__PURE__ */
|
|
198
|
-
|
|
199
|
+
return /* @__PURE__ */ C("label", { className: _, children: [
|
|
200
|
+
j && /* @__PURE__ */ t("span", { className: "text-base-content/70", children: j }),
|
|
199
201
|
f,
|
|
200
|
-
|
|
202
|
+
w && /* @__PURE__ */ t("span", { className: "text-base-content/70", children: w })
|
|
201
203
|
] });
|
|
202
204
|
};
|
|
203
|
-
return /* @__PURE__ */
|
|
204
|
-
/* @__PURE__ */
|
|
205
|
+
return /* @__PURE__ */ C("div", { className: `${v ? "w-auto" : "w-full"} ${L ? "mb-4" : ""} ${Q ? "inline-flex mr-4" : ""} ${l}`, style: W ? { display: "none" } : void 0, "data-testid": m, children: [
|
|
206
|
+
/* @__PURE__ */ C("div", { className: L ? "flex items-center gap-4" : "", children: [
|
|
205
207
|
n && !r && /* @__PURE__ */ t(
|
|
206
208
|
"label",
|
|
207
209
|
{
|
|
208
|
-
htmlFor:
|
|
209
|
-
className: `block text-sm font-medium ${
|
|
210
|
-
style:
|
|
211
|
-
|
|
210
|
+
htmlFor: R,
|
|
211
|
+
className: `block text-sm font-medium ${L ? "flex-shrink-0 text-right" : ""} ${!L && !Q ? "mb-1" : ""}`,
|
|
212
|
+
style: L ? { width: I } : void 0,
|
|
213
|
+
"data-testid": m ? `${m}-label` : void 0,
|
|
214
|
+
children: /* @__PURE__ */ C("span", { className: "flex items-center", children: [
|
|
212
215
|
n,
|
|
213
|
-
|
|
214
|
-
x && /* @__PURE__ */ t(
|
|
216
|
+
b && /* @__PURE__ */ t("span", { className: "text-error ml-1", children: "*" }),
|
|
217
|
+
x && /* @__PURE__ */ t(ce, {})
|
|
215
218
|
] })
|
|
216
219
|
}
|
|
217
220
|
),
|
|
218
|
-
fe(
|
|
221
|
+
he(fe())
|
|
219
222
|
] }),
|
|
220
|
-
!
|
|
221
|
-
|
|
222
|
-
y && /* @__PURE__ */ t("div", { className: "text-sm text-base-content/60 mt-1", children: y })
|
|
223
|
+
!L && !v && /* @__PURE__ */ t("p", { id: F, className: `validator-hint ${E ? "!visible text-error" : ""} min-h-[1.25rem]`, role: E ? "alert" : void 0, "data-testid": m ? `${m}-error` : void 0, children: E || i && /* @__PURE__ */ t("span", { className: "text-base-content/70", children: i }) || " " }),
|
|
224
|
+
L && (E || i) && /* @__PURE__ */ t("p", { id: F, className: `validator-hint ${E ? "!visible text-error" : ""} min-h-[1.25rem]`, role: E ? "alert" : void 0, "data-testid": m ? `${m}-error` : void 0, children: E || i && /* @__PURE__ */ t("span", { className: "text-base-content/70", children: i }) }),
|
|
225
|
+
y && /* @__PURE__ */ t("div", { className: "text-sm text-base-content/60 mt-1", "data-testid": m ? `${m}-extra` : void 0, children: y })
|
|
223
226
|
] });
|
|
224
227
|
}
|
|
225
228
|
}
|
|
226
229
|
);
|
|
227
230
|
}
|
|
228
|
-
function
|
|
231
|
+
function Re({
|
|
229
232
|
name: s,
|
|
230
233
|
children: n
|
|
231
234
|
}) {
|
|
232
|
-
const { form: r, layout: i, size:
|
|
235
|
+
const { form: r, layout: i, size: b, disabled: h } = K(), { fields: V, append: v, remove: l, move: c } = xe({
|
|
233
236
|
control: r.control,
|
|
234
237
|
name: s
|
|
235
|
-
}), x =
|
|
238
|
+
}), x = V.map((y, $) => ({
|
|
236
239
|
...y,
|
|
237
|
-
name:
|
|
240
|
+
name: $
|
|
238
241
|
}));
|
|
239
|
-
return /* @__PURE__ */ t(
|
|
240
|
-
add:
|
|
241
|
-
remove:
|
|
242
|
-
move:
|
|
242
|
+
return /* @__PURE__ */ t(J.Provider, { value: { form: r, layout: i, size: b, listName: s, disabled: h }, children: n(x, {
|
|
243
|
+
add: v,
|
|
244
|
+
remove: l,
|
|
245
|
+
move: c
|
|
243
246
|
}) });
|
|
244
247
|
}
|
|
245
|
-
function
|
|
246
|
-
const s =
|
|
248
|
+
function Be() {
|
|
249
|
+
const s = oe(), n = s;
|
|
247
250
|
return n.setFieldValue = s.setValue, n.getFieldValue = (r) => s.getValues(r), n.getFieldsValue = s.getValues, n.setFieldsValue = (r) => {
|
|
248
251
|
Object.keys(r).forEach((i) => {
|
|
249
252
|
s.setValue(i, r[i]);
|
|
250
253
|
});
|
|
251
254
|
}, n.validateFields = s.trigger, n.resetFields = s.reset, n.isFieldTouched = (r) => !!s.formState.touchedFields[r], n.getFieldError = (r) => s.formState.errors[r]?.message, n;
|
|
252
255
|
}
|
|
253
|
-
function
|
|
254
|
-
const { form:
|
|
255
|
-
const
|
|
256
|
-
for (const
|
|
257
|
-
const
|
|
258
|
-
d?.message ?
|
|
256
|
+
function Te({ fields: s, className: n = "", "data-testid": r }) {
|
|
257
|
+
const { form: i } = K(), { errors: b } = i.formState, h = (l, c = "") => {
|
|
258
|
+
const x = [];
|
|
259
|
+
for (const y in l) {
|
|
260
|
+
const $ = c ? `${c}.${y}` : y, d = l[y];
|
|
261
|
+
d?.message ? x.push({ field: $, message: d.message }) : typeof d == "object" && d !== null && x.push(...h(d, $));
|
|
259
262
|
}
|
|
260
|
-
return
|
|
261
|
-
},
|
|
262
|
-
return
|
|
263
|
+
return x;
|
|
264
|
+
}, V = h(b), v = s ? V.filter((l) => s.includes(l.field)) : V;
|
|
265
|
+
return v.length === 0 ? null : /* @__PURE__ */ t("ul", { className: `text-error text-sm space-y-1 ${n}`, role: "alert", "data-testid": r, children: v.map((l, c) => /* @__PURE__ */ C("li", { className: "flex items-start gap-2", "data-testid": r ? `${r}-${l.field}` : void 0, children: [
|
|
263
266
|
/* @__PURE__ */ t("svg", { className: "w-4 h-4 mt-0.5 flex-shrink-0", fill: "none", viewBox: "0 0 24 24", stroke: "currentColor", children: /* @__PURE__ */ t("path", { strokeLinecap: "round", strokeLinejoin: "round", strokeWidth: 2, d: "M12 8v4m0 4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z" }) }),
|
|
264
|
-
/* @__PURE__ */ t("span", { children:
|
|
265
|
-
] }, `${
|
|
267
|
+
/* @__PURE__ */ t("span", { children: l.message })
|
|
268
|
+
] }, `${l.field}-${c}`)) });
|
|
266
269
|
}
|
|
267
|
-
const
|
|
268
|
-
Item:
|
|
269
|
-
List:
|
|
270
|
-
ErrorList:
|
|
271
|
-
useForm:
|
|
270
|
+
const _e = Object.assign(Me, {
|
|
271
|
+
Item: Pe,
|
|
272
|
+
List: Re,
|
|
273
|
+
ErrorList: Te,
|
|
274
|
+
useForm: Be
|
|
272
275
|
});
|
|
273
276
|
export {
|
|
274
|
-
|
|
275
|
-
|
|
277
|
+
_e as Form,
|
|
278
|
+
Be as useFormInstance
|
|
276
279
|
};
|
|
277
280
|
//# sourceMappingURL=Form.js.map
|