dgz-ui-shared 1.2.24 → 1.2.26

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.
Files changed (41) hide show
  1. package/dist/chunks/MyInput-5ir4eN2m.cjs.js +2 -0
  2. package/dist/chunks/MyInput-5ir4eN2m.cjs.js.map +1 -0
  3. package/dist/chunks/MyInput-Cb0FlVxQ.es.js +53 -0
  4. package/dist/chunks/MyInput-Cb0FlVxQ.es.js.map +1 -0
  5. package/dist/chunks/MySelect-5DHBVlKZ.es.js +58 -0
  6. package/dist/chunks/{MySelect-CUgwH6oV.es.js.map → MySelect-5DHBVlKZ.es.js.map} +1 -1
  7. package/dist/chunks/MySelect-Dl3jKf5s.cjs.js +2 -0
  8. package/dist/chunks/{MySelect-DrHeuMYE.cjs.js.map → MySelect-Dl3jKf5s.cjs.js.map} +1 -1
  9. package/dist/chunks/{PasswordConfirm-B6kl3v24.es.js → PasswordConfirm-Dj97U7O9.es.js} +2 -2
  10. package/dist/chunks/{PasswordConfirm-B6kl3v24.es.js.map → PasswordConfirm-Dj97U7O9.es.js.map} +1 -1
  11. package/dist/chunks/{PasswordConfirm-CtbStDkd.cjs.js → PasswordConfirm-Uc4pncGw.cjs.js} +2 -2
  12. package/dist/chunks/{PasswordConfirm-CtbStDkd.cjs.js.map → PasswordConfirm-Uc4pncGw.cjs.js.map} +1 -1
  13. package/dist/chunks/{Search-CO-HJ0n9.cjs.js → Search-CV30eaCb.cjs.js} +2 -2
  14. package/dist/chunks/{Search-CO-HJ0n9.cjs.js.map → Search-CV30eaCb.cjs.js.map} +1 -1
  15. package/dist/chunks/{Search-DVIxJaym.es.js → Search-RNMpIN4r.es.js} +3 -3
  16. package/dist/chunks/{Search-DVIxJaym.es.js.map → Search-RNMpIN4r.es.js.map} +1 -1
  17. package/dist/components/confirm/index.cjs.js +1 -1
  18. package/dist/components/confirm/index.es.js +1 -1
  19. package/dist/components/datatable/index.cjs.js +1 -1
  20. package/dist/components/datatable/index.es.js +1 -1
  21. package/dist/components/filters/index.cjs.js +1 -1
  22. package/dist/components/filters/index.es.js +1 -1
  23. package/dist/components/form/index.cjs.js +1 -1
  24. package/dist/components/form/index.cjs.js.map +1 -1
  25. package/dist/components/form/index.es.js +263 -252
  26. package/dist/components/form/index.es.js.map +1 -1
  27. package/dist/hooks/index.cjs.js +1 -1
  28. package/dist/hooks/index.es.js +1 -1
  29. package/dist/types/App.d.ts.map +1 -1
  30. package/dist/types/components/form/MyDatePicker.d.ts.map +1 -1
  31. package/dist/types/components/form/MyDateRangePicker.d.ts.map +1 -1
  32. package/dist/types/components/form/MyHtmlEditor.d.ts +1 -1
  33. package/dist/types/components/form/MyHtmlEditor.d.ts.map +1 -1
  34. package/dist/types/components/form/MyTimePicker.d.ts.map +1 -1
  35. package/package.json +1 -1
  36. package/dist/chunks/MyInput-BXVrCIS_.cjs.js +0 -2
  37. package/dist/chunks/MyInput-BXVrCIS_.cjs.js.map +0 -1
  38. package/dist/chunks/MyInput-y2xZ3Bb9.es.js +0 -51
  39. package/dist/chunks/MyInput-y2xZ3Bb9.es.js.map +0 -1
  40. package/dist/chunks/MySelect-CUgwH6oV.es.js +0 -56
  41. package/dist/chunks/MySelect-DrHeuMYE.cjs.js +0 -2
@@ -1,362 +1,373 @@
1
- import { FormField as g, FormLabel as N, FormItem as k, FormControl as p, Checkbox as I, Input as w, FormMessage as x, HtmlEditor as M, MaskInput as T, RadioGroupItem as D, Switch as R, Textarea as E } from "dgz-ui/form";
1
+ import { FormField as m, FormLabel as u, FormItem as N, FormControl as g, Checkbox as P, Input as I, FormMessage as k, HtmlEditor as w, MaskInput as S, RadioGroupItem as T, Switch as D, Textarea as R } from "dgz-ui/form";
2
2
  export * from "dgz-ui/form";
3
- import { jsx as e, jsxs as i } from "react/jsx-runtime";
3
+ import { jsx as e, jsxs as t } from "react/jsx-runtime";
4
4
  import { useId as y } from "react";
5
- import { DATE as $, Calendar as j, TimePicker as f } from "dgz-ui/calendar";
6
- import { Popover as S, PopoverTrigger as z, PopoverContent as A } from "dgz-ui/popover";
7
- import { cn as u, dayjs as H } from "dgz-ui/utils";
8
- import { l as m } from "../../chunks/lodash-CRDOWzbs.es.js";
5
+ import { DATE as E, Calendar as $, TimePicker as C } from "dgz-ui/calendar";
6
+ import { Popover as j, PopoverTrigger as z, PopoverContent as A } from "dgz-ui/popover";
7
+ import { cn as h, dayjs as H } from "dgz-ui/utils";
8
+ import { l as x } from "../../chunks/lodash-CRDOWzbs.es.js";
9
9
  import { Calendar1 as G } from "lucide-react";
10
10
  import { D as L } from "../../chunks/DateRangePicker-DeoV3xqL.es.js";
11
- import { M as oe } from "../../chunks/MyInput-y2xZ3Bb9.es.js";
12
- import { M as de } from "../../chunks/MySelect-CUgwH6oV.es.js";
11
+ import { M as ie } from "../../chunks/MyInput-Cb0FlVxQ.es.js";
12
+ import { M as oe } from "../../chunks/MySelect-5DHBVlKZ.es.js";
13
13
  const W = ({
14
- control: s,
14
+ control: a,
15
15
  name: r,
16
- label: a,
17
- rules: n,
18
- ...t
16
+ label: s,
17
+ rules: i,
18
+ ...c
19
19
  }) => {
20
- const c = y();
21
- return r && s && /* @__PURE__ */ e(
22
- g,
20
+ const l = y();
21
+ return r && a && /* @__PURE__ */ e(
22
+ m,
23
23
  {
24
- control: s,
24
+ control: a,
25
25
  name: r,
26
- rules: n,
27
- render: ({ field: l }) => /* @__PURE__ */ e(N, { className: "block", htmlFor: t.id || c, children: /* @__PURE__ */ i(k, { className: "flex flex-row items-start gap-3", children: [
28
- /* @__PURE__ */ e(p, { children: /* @__PURE__ */ e(
29
- I,
26
+ rules: i,
27
+ render: ({ field: n }) => /* @__PURE__ */ e(u, { className: "block", htmlFor: c.id || l, children: /* @__PURE__ */ t(N, { className: "flex flex-row items-start gap-3", children: [
28
+ /* @__PURE__ */ e(g, { children: /* @__PURE__ */ e(
29
+ P,
30
30
  {
31
- id: t.id || c,
32
- checked: l.value,
33
- onCheckedChange: l.onChange,
34
- ...t
31
+ id: c.id || l,
32
+ checked: n.value,
33
+ onCheckedChange: n.onChange,
34
+ ...c
35
35
  }
36
36
  ) }),
37
- /* @__PURE__ */ e("div", { className: "space-y-1 leading-none", children: a && /* @__PURE__ */ e("div", { children: a }) })
37
+ /* @__PURE__ */ e("div", { className: "space-y-1 leading-none", children: s && /* @__PURE__ */ e("div", { children: s }) })
38
38
  ] }) })
39
39
  }
40
40
  ) || null;
41
41
  }, X = ({
42
- control: s,
42
+ control: a,
43
43
  name: r,
44
- label: a,
45
- required: n,
46
- rules: t,
47
- format: c = $,
48
- floatingError: l,
49
- placeholder: o,
50
- disabled: d,
51
- register: h,
52
- className: b,
53
- inputProps: F,
54
- ...P
55
- }) => r && s && /* @__PURE__ */ e(
56
- g,
44
+ label: s,
45
+ required: i,
46
+ rules: c,
47
+ format: l = E,
48
+ floatingError: n,
49
+ placeholder: d,
50
+ disabled: o,
51
+ register: p,
52
+ className: f,
53
+ inputProps: M,
54
+ ...b
55
+ }) => r && a && /* @__PURE__ */ e(
56
+ m,
57
57
  {
58
- control: s,
58
+ control: a,
59
59
  name: r,
60
- rules: t,
61
- render: ({ field: v, formState: C }) => /* @__PURE__ */ i(k, { children: [
62
- a && /* @__PURE__ */ i(N, { className: "block", children: [
63
- a,
60
+ rules: c,
61
+ render: ({ field: v, formState: F }) => /* @__PURE__ */ t(N, { children: [
62
+ s && /* @__PURE__ */ t(u, { className: "block", children: [
63
+ s,
64
64
  " ",
65
- n && /* @__PURE__ */ e("span", { className: "text-red-600", children: "*" })
65
+ i && /* @__PURE__ */ e("span", { className: "text-red-600", children: "*" })
66
66
  ] }),
67
- /* @__PURE__ */ i(S, { children: [
68
- /* @__PURE__ */ e(z, { asChild: !0, children: /* @__PURE__ */ e(p, { children: /* @__PURE__ */ i("div", { className: "relative", children: [
69
- /* @__PURE__ */ e(
70
- w,
67
+ /* @__PURE__ */ t(j, { children: [
68
+ /* @__PURE__ */ e(z, { asChild: !0, children: /* @__PURE__ */ t("div", { className: "relative", children: [
69
+ /* @__PURE__ */ e(g, { children: /* @__PURE__ */ e(
70
+ I,
71
71
  {
72
- ...F,
73
- variant: m.get(C.errors, `${r}.message`) ? "failure" : "default",
74
- disabled: d,
72
+ ...M,
73
+ variant: x.get(F.errors, `${r}.message`) ? "failure" : "default",
74
+ disabled: o,
75
75
  ...v,
76
76
  readOnly: !0,
77
- placeholder: o || "Pick a date",
78
- value: H(v.value).format(c),
79
- className: u("m-0 text-start", b)
77
+ placeholder: d || "Pick a date",
78
+ value: H(v.value).format(l),
79
+ className: h("m-0 text-start", f)
80
80
  }
81
- ),
81
+ ) }),
82
82
  /* @__PURE__ */ e(
83
83
  G,
84
84
  {
85
- className: u(
85
+ className: h(
86
86
  "text-secondary absolute top-2.5 right-2 size-5",
87
- d && "pointer-events-none opacity-50"
87
+ o && "pointer-events-none opacity-50"
88
88
  )
89
89
  }
90
+ ),
91
+ /* @__PURE__ */ e(
92
+ k,
93
+ {
94
+ className: h(n && "absolute -bottom-5")
95
+ }
90
96
  )
91
- ] }) }) }),
92
- !d && /* @__PURE__ */ e(A, { className: "w-auto p-0", align: "start", children: /* @__PURE__ */ e(
93
- j,
97
+ ] }) }),
98
+ !o && /* @__PURE__ */ e(A, { className: "w-auto p-0", align: "start", children: /* @__PURE__ */ e(
99
+ $,
94
100
  {
95
- ...P,
101
+ ...b,
96
102
  mode: "single",
97
103
  selected: v.value,
98
104
  onSelect: v.onChange
99
105
  }
100
106
  ) })
101
- ] }),
102
- m.get(C.errors, r, "") && /* @__PURE__ */ e(
103
- x,
104
- {
105
- className: u(l && "absolute -bottom-5")
106
- }
107
- )
107
+ ] })
108
108
  ] })
109
109
  }
110
110
  ) || null, Y = ({
111
- control: s,
111
+ control: a,
112
112
  name: r,
113
- label: a,
114
- required: n,
115
- rules: t,
116
- placeholder: c,
117
- floatingError: l,
118
- ...o
119
- }) => r && s && /* @__PURE__ */ e(
120
- g,
113
+ label: s,
114
+ required: i,
115
+ rules: c,
116
+ placeholder: l,
117
+ floatingError: n,
118
+ ...d
119
+ }) => r && a && /* @__PURE__ */ e(
120
+ m,
121
121
  {
122
- control: s,
122
+ control: a,
123
123
  name: r,
124
- rules: t,
125
- render: ({ field: d, formState: h }) => /* @__PURE__ */ i(k, { children: [
126
- a && /* @__PURE__ */ i(N, { className: "block", children: [
127
- a,
124
+ rules: c,
125
+ render: ({ field: o, formState: p }) => /* @__PURE__ */ t(N, { children: [
126
+ s && /* @__PURE__ */ t(u, { className: "block", children: [
127
+ s,
128
128
  " ",
129
- n && /* @__PURE__ */ e("span", { className: "text-red-600", children: "*" })
129
+ i && /* @__PURE__ */ e("span", { className: "text-red-600", children: "*" })
130
130
  ] }),
131
- /* @__PURE__ */ e(p, { children: /* @__PURE__ */ e("div", { children: /* @__PURE__ */ e(
132
- L,
133
- {
134
- ...o,
135
- error: `${m.get(h.errors, r, "")}`,
136
- selected: d.value,
137
- onRangeSelected: d.onChange,
138
- placeholder: c
139
- }
140
- ) }) }),
141
- m.get(h.errors, r, "") && /* @__PURE__ */ e(
142
- x,
143
- {
144
- className: u(l && "absolute -bottom-5")
145
- }
146
- )
131
+ /* @__PURE__ */ t("div", { children: [
132
+ /* @__PURE__ */ e(g, { children: /* @__PURE__ */ e(
133
+ L,
134
+ {
135
+ ...d,
136
+ error: `${x.get(p.errors, r, "")}`,
137
+ selected: o.value,
138
+ onRangeSelected: o.onChange,
139
+ placeholder: l
140
+ }
141
+ ) }),
142
+ /* @__PURE__ */ e(
143
+ k,
144
+ {
145
+ className: h(n && "absolute -bottom-5")
146
+ }
147
+ )
148
+ ] })
147
149
  ] })
148
150
  }
149
151
  ) || null, Z = ({
150
- control: s,
152
+ control: a,
151
153
  name: r,
152
- label: a,
153
- rules: n,
154
- required: t,
155
- floatingError: c,
156
- ...l
157
- }) => r && s ? /* @__PURE__ */ e(
158
- g,
154
+ label: s,
155
+ rules: i,
156
+ required: c,
157
+ floatingError: l,
158
+ ...n
159
+ }) => r && a && /* @__PURE__ */ e(
160
+ m,
159
161
  {
160
- control: s,
162
+ control: a,
161
163
  name: r,
162
- rules: n,
163
- render: ({ field: o }) => /* @__PURE__ */ i(k, { children: [
164
- a && /* @__PURE__ */ i(N, { className: "block", children: [
165
- a,
164
+ rules: i,
165
+ render: ({ field: d }) => /* @__PURE__ */ t(N, { children: [
166
+ s && /* @__PURE__ */ t(u, { className: "block", children: [
167
+ s,
166
168
  " ",
167
- t && /* @__PURE__ */ e("span", { className: "text-red-600", children: "*" })
169
+ c && /* @__PURE__ */ e("span", { className: "text-red-600", children: "*" })
168
170
  ] }),
169
- /* @__PURE__ */ e(p, { children: /* @__PURE__ */ e(M, { ...o, ...l }) }),
170
- m.get(formState.errors, r, "") && /* @__PURE__ */ e(
171
- x,
172
- {
173
- className: u(c && "absolute -bottom-5")
174
- }
175
- )
171
+ /* @__PURE__ */ t("div", { children: [
172
+ /* @__PURE__ */ e(g, { children: /* @__PURE__ */ e(w, { ...d, ...n }) }),
173
+ /* @__PURE__ */ e(
174
+ k,
175
+ {
176
+ className: h(l && "absolute -bottom-5")
177
+ }
178
+ )
179
+ ] })
176
180
  ] })
177
181
  }
178
- ) : /* @__PURE__ */ e(M, { ...l }), ee = ({
179
- control: s,
182
+ ) || null, ee = ({
183
+ control: a,
180
184
  name: r,
181
- label: a,
182
- rules: n,
183
- required: t,
184
- floatingError: c,
185
- ...l
186
- }) => r && s && /* @__PURE__ */ e(
187
- g,
185
+ label: s,
186
+ rules: i,
187
+ required: c,
188
+ floatingError: l,
189
+ ...n
190
+ }) => r && a && /* @__PURE__ */ e(
191
+ m,
188
192
  {
189
- control: s,
193
+ control: a,
190
194
  name: r,
191
- rules: n,
192
- render: ({ field: o, formState: d }) => /* @__PURE__ */ i(k, { children: [
193
- a && /* @__PURE__ */ i(N, { className: "block", children: [
194
- a,
195
+ rules: i,
196
+ render: ({ field: d, formState: o }) => /* @__PURE__ */ t(N, { children: [
197
+ s && /* @__PURE__ */ t(u, { className: "block", children: [
198
+ s,
195
199
  " ",
196
- t && /* @__PURE__ */ e("span", { className: "text-red-600", children: "*" })
200
+ c && /* @__PURE__ */ e("span", { className: "text-red-600", children: "*" })
197
201
  ] }),
198
- /* @__PURE__ */ e(p, { children: /* @__PURE__ */ e(
199
- T,
200
- {
201
- thousandsSeparator: " ",
202
- lazy: !1,
203
- placeholderChar: "_",
204
- unmask: !0,
205
- ...o,
206
- ...l,
207
- variant: m.get(d.errors, `${r}.message`) ? "failure" : "default",
208
- onAccept: (h) => o.onChange(h)
209
- }
210
- ) }),
211
- m.get(d.errors, r, "") && /* @__PURE__ */ e(
212
- x,
213
- {
214
- className: u(c && "absolute -bottom-5")
215
- }
216
- )
202
+ /* @__PURE__ */ t("div", { children: [
203
+ /* @__PURE__ */ e(g, { children: /* @__PURE__ */ e(
204
+ S,
205
+ {
206
+ thousandsSeparator: " ",
207
+ lazy: !1,
208
+ placeholderChar: "_",
209
+ unmask: !0,
210
+ ...d,
211
+ ...n,
212
+ variant: x.get(o.errors, `${r}.message`) ? "failure" : "default",
213
+ onAccept: (p) => d.onChange(p)
214
+ }
215
+ ) }),
216
+ /* @__PURE__ */ e(
217
+ k,
218
+ {
219
+ className: h(l && "absolute -bottom-5")
220
+ }
221
+ )
222
+ ] })
217
223
  ] })
218
224
  }
219
225
  ) || null, re = ({
220
- control: s,
226
+ control: a,
221
227
  name: r,
222
- label: a,
223
- rules: n,
224
- value: t,
225
- ...c
228
+ label: s,
229
+ rules: i,
230
+ value: c,
231
+ ...l
226
232
  }) => {
227
- const l = y();
228
- return r && s && /* @__PURE__ */ e(
229
- g,
233
+ const n = y();
234
+ return r && a && /* @__PURE__ */ e(
235
+ m,
230
236
  {
231
- control: s,
237
+ control: a,
232
238
  name: r,
233
- rules: n,
234
- render: ({ field: o }) => /* @__PURE__ */ e(N, { className: "block", htmlFor: c.id || l, children: /* @__PURE__ */ i(k, { className: "flex flex-row items-start gap-3", children: [
235
- /* @__PURE__ */ e(p, { children: /* @__PURE__ */ e(
236
- D,
239
+ rules: i,
240
+ render: ({ field: d }) => /* @__PURE__ */ e(u, { className: "block", htmlFor: l.id || n, children: /* @__PURE__ */ t(N, { className: "flex flex-row items-start gap-3", children: [
241
+ /* @__PURE__ */ e(g, { children: /* @__PURE__ */ e(
242
+ T,
237
243
  {
238
- id: c.id || l,
239
- value: t,
240
- checked: o.value === t,
244
+ id: l.id || n,
245
+ value: c,
246
+ checked: d.value === c,
241
247
  onClick: () => {
242
- o.value !== t && o.onChange(t);
248
+ d.value !== c && d.onChange(c);
243
249
  },
244
- ...c
250
+ ...l
245
251
  }
246
252
  ) }),
247
- /* @__PURE__ */ e("div", { className: "space-y-1 leading-none", children: a && /* @__PURE__ */ e("div", { children: a }) })
253
+ /* @__PURE__ */ e("div", { className: "space-y-1 leading-none", children: s && /* @__PURE__ */ e("div", { children: s }) })
248
254
  ] }) })
249
255
  }
250
256
  ) || null;
251
- }, se = ({
252
- control: s,
257
+ }, ae = ({
258
+ control: a,
253
259
  name: r,
254
- label: a,
255
- rules: n,
256
- ...t
260
+ label: s,
261
+ rules: i,
262
+ ...c
257
263
  }) => {
258
- const c = y();
259
- return r && s && /* @__PURE__ */ e(
260
- g,
264
+ const l = y();
265
+ return r && a && /* @__PURE__ */ e(
266
+ m,
261
267
  {
262
- control: s,
268
+ control: a,
263
269
  name: r,
264
- rules: n,
265
- render: ({ field: l }) => /* @__PURE__ */ e(N, { className: "block", htmlFor: t.id || c, children: /* @__PURE__ */ i(k, { className: "flex flex-row items-start gap-3", children: [
266
- /* @__PURE__ */ e(p, { children: /* @__PURE__ */ e(
267
- R,
270
+ rules: i,
271
+ render: ({ field: n }) => /* @__PURE__ */ e(u, { className: "block", htmlFor: c.id || l, children: /* @__PURE__ */ t(N, { className: "flex flex-row items-start gap-3", children: [
272
+ /* @__PURE__ */ e(g, { children: /* @__PURE__ */ e(
273
+ D,
268
274
  {
269
- id: t.id || c,
275
+ id: c.id || l,
270
276
  className: "m-0",
271
- checked: l.value,
272
- onCheckedChange: l.onChange,
273
- ...t
277
+ checked: n.value,
278
+ onCheckedChange: n.onChange,
279
+ ...c
274
280
  }
275
281
  ) }),
276
- /* @__PURE__ */ e("div", { className: "space-y-1 leading-none", children: a && /* @__PURE__ */ e("div", { children: a }) })
282
+ /* @__PURE__ */ e("div", { className: "space-y-1 leading-none", children: s && /* @__PURE__ */ e("div", { children: s }) })
277
283
  ] }) })
278
284
  }
279
285
  ) || null;
280
- }, ae = ({
281
- control: s,
286
+ }, se = ({
287
+ control: a,
282
288
  name: r,
283
- label: a,
284
- required: n,
285
- rules: t,
286
- className: c,
287
- floatingError: l,
288
- ...o
289
- }) => r && s && /* @__PURE__ */ e(
290
- g,
289
+ label: s,
290
+ required: i,
291
+ rules: c,
292
+ className: l,
293
+ floatingError: n,
294
+ ...d
295
+ }) => r && a && /* @__PURE__ */ e(
296
+ m,
291
297
  {
292
- control: s,
298
+ control: a,
293
299
  name: r,
294
- rules: t,
295
- render: ({ field: d, formState: h }) => /* @__PURE__ */ i(k, { children: [
296
- a && /* @__PURE__ */ i(N, { className: "block", children: [
297
- a,
300
+ rules: c,
301
+ render: ({ field: o, formState: p }) => /* @__PURE__ */ t(N, { children: [
302
+ s && /* @__PURE__ */ t(u, { className: "block", children: [
303
+ s,
298
304
  " ",
299
- n && /* @__PURE__ */ e("span", { className: "text-red-600", children: "*" })
305
+ i && /* @__PURE__ */ e("span", { className: "text-red-600", children: "*" })
300
306
  ] }),
301
- /* @__PURE__ */ e(p, { children: /* @__PURE__ */ e(
302
- E,
303
- {
304
- variant: m.get(h.errors, `${r}.message`) ? "failure" : "default",
305
- ...o,
306
- ...d,
307
- className: u(c)
308
- }
309
- ) }),
310
- m.get(h.errors, r, "") && /* @__PURE__ */ e(
311
- x,
312
- {
313
- className: u(l && "absolute -bottom-5")
314
- }
315
- )
307
+ /* @__PURE__ */ t("div", { children: [
308
+ /* @__PURE__ */ e(g, { children: /* @__PURE__ */ e(
309
+ R,
310
+ {
311
+ variant: x.get(p.errors, `${r}.message`) ? "failure" : "default",
312
+ ...d,
313
+ ...o,
314
+ className: h(l)
315
+ }
316
+ ) }),
317
+ /* @__PURE__ */ e(
318
+ k,
319
+ {
320
+ className: h(n && "absolute -bottom-5")
321
+ }
322
+ )
323
+ ] })
316
324
  ] })
317
325
  }
318
- ) || null, te = ({
319
- control: s,
326
+ ) || null, ce = ({
327
+ control: a,
320
328
  name: r,
321
- label: a,
322
- required: n,
323
- className: t,
324
- rules: c,
325
- floatingError: l,
326
- ...o
327
- }) => r && s ? /* @__PURE__ */ e(
328
- g,
329
+ label: s,
330
+ required: i,
331
+ className: c,
332
+ rules: l,
333
+ floatingError: n,
334
+ ...d
335
+ }) => r && a ? /* @__PURE__ */ e(
336
+ m,
329
337
  {
330
- control: s,
338
+ control: a,
331
339
  name: r,
332
- rules: c,
333
- render: ({ field: d, formState: h }) => /* @__PURE__ */ i(k, { children: [
334
- a && /* @__PURE__ */ i(N, { className: "block", children: [
335
- a,
340
+ rules: l,
341
+ render: ({ field: o }) => /* @__PURE__ */ t(N, { children: [
342
+ s && /* @__PURE__ */ t(u, { className: "block", children: [
343
+ s,
336
344
  " ",
337
- n && /* @__PURE__ */ e("span", { className: "text-red-600", children: "*" })
345
+ i && /* @__PURE__ */ e("span", { className: "text-red-600", children: "*" })
338
346
  ] }),
339
- /* @__PURE__ */ e(p, { children: /* @__PURE__ */ e(f, { ...d, ...o }) }),
340
- m.get(h.errors, r, "") && /* @__PURE__ */ e(
341
- x,
342
- {
343
- className: u(l && "absolute -bottom-5")
344
- }
345
- )
347
+ " ",
348
+ /* @__PURE__ */ t("div", { children: [
349
+ /* @__PURE__ */ e(g, { children: /* @__PURE__ */ e(C, { ...o, ...d }) }),
350
+ /* @__PURE__ */ e(
351
+ k,
352
+ {
353
+ className: h(n && "absolute -bottom-5")
354
+ }
355
+ )
356
+ ] })
346
357
  ] })
347
358
  }
348
- ) : /* @__PURE__ */ e(f, { className: "mt-2", ...o });
359
+ ) : /* @__PURE__ */ e(C, { className: "mt-2", ...d });
349
360
  export {
350
361
  W as MyCheckbox,
351
362
  X as MyDatePicker,
352
363
  Y as MyDateRangePicker,
353
364
  Z as MyHtmlEditor,
354
- oe as MyInput,
365
+ ie as MyInput,
355
366
  ee as MyMaskInput,
356
367
  re as MyRadio,
357
- de as MySelect,
358
- se as MySwitch,
359
- ae as MyTextarea,
360
- te as MyTimePicker
368
+ oe as MySelect,
369
+ ae as MySwitch,
370
+ se as MyTextarea,
371
+ ce as MyTimePicker
361
372
  };
362
373
  //# sourceMappingURL=index.es.js.map