treege 3.0.0-beta.70 → 3.0.0-beta.71

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,13 +1,13 @@
1
- import { A as e, D as t, E as n, I as r, R as i, S as a, T as o, _ as s, a as c, b as l, c as u, h as d, i as f, j as p, m, n as h, o as g, p as _, r as v, s as y, t as b, v as x } from "./ThemeContext-CdHMLHiw.js";
2
- import { a as S, c as C, i as w, l as T, n as E, o as D, r as ee, s as O, t as k } from "./useRenderNode-DJGmt663.js";
3
- import { useCallback as te, useEffect as A, useMemo as j, useRef as M, useState as N } from "react";
4
- import { Fragment as ne, jsx as P, jsxs as F } from "react/jsx-runtime";
5
- import { ActivityIndicator as re, Alert as ie, Animated as I, FlatList as ae, Image as L, Modal as oe, ScrollView as R, StyleSheet as z, Switch as se, Text as B, TextInput as ce, TouchableOpacity as V, View as H } from "react-native";
1
+ import { C as e, D as t, E as n, L as r, M as i, O as a, a as o, c as s, g as c, h as l, i as u, j as d, l as f, m as p, n as m, o as h, r as g, s as _, t as v, v as y, x as b, y as x, z as S } from "./ThemeContext-BGeTYtnw.js";
2
+ import { a as C, c as w, i as T, l as E, n as D, o as O, r as k, s as A, t as ee } from "./useRenderNode-eqCek6JX.js";
3
+ import { useCallback as te, useEffect as j, useMemo as ne, useRef as M, useState as N } from "react";
4
+ import { Fragment as re, jsx as P, jsxs as F } from "react/jsx-runtime";
5
+ import { ActivityIndicator as ie, Alert as ae, Animated as I, FlatList as oe, Image as L, Modal as se, ScrollView as R, StyleSheet as z, Switch as ce, Text as B, TextInput as le, TouchableOpacity as V, View as H } from "react-native";
6
6
  //#region src/renderer/features/TreegeRenderer/native/components/DefaultFormWrapper.tsx
7
- var le = ({ children: e }) => /* @__PURE__ */ P(H, {
8
- style: ue.container,
7
+ var ue = ({ children: e }) => /* @__PURE__ */ P(H, {
8
+ style: de.container,
9
9
  children: e
10
- }), ue = z.create({ container: { padding: 16 } }), de = async (e, t) => {
10
+ }), de = z.create({ container: { padding: 16 } }), fe = async (e, t) => {
11
11
  if (!e || e.trim().length < 3) return [];
12
12
  try {
13
13
  let n = await fetch(`https://nominatim.openstreetmap.org/search?q=${encodeURIComponent(e)}&format=jsonv2&addressdetails=1&limit=5`, { headers: {
@@ -22,7 +22,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
22
22
  } catch (e) {
23
23
  return console.error("Nominatim fetch error:", e), [];
24
24
  }
25
- }, fe = async (e, t) => {
25
+ }, pe = async (e, t) => {
26
26
  if (!e || e.trim().length < 3) return [];
27
27
  try {
28
28
  let n = await fetch(`https://maps.googleapis.com/maps/api/place/autocomplete/json?input=${encodeURIComponent(e)}&key=${t}`);
@@ -35,26 +35,26 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
35
35
  } catch (e) {
36
36
  return console.error("Google Places fetch error:", e), [];
37
37
  }
38
- }, pe = ({ field: e, extra: n }) => {
39
- let [r, i] = N(""), [a, o] = N([]), [s, c] = N(!1), [l, u] = N(!1), { value: d, placeholder: f, id: m, name: g } = e, { node: _, setValue: v, error: y, label: b, helperText: x } = n, { language: S, googleApiKey: C } = p(), w = t(), { colors: T } = h(), E = te((e) => {
40
- v(e.value), i(""), c(!1), o([]);
38
+ }, me = ({ field: e, extra: t }) => {
39
+ let [n, r] = N(""), [o, s] = N([]), [c, l] = N(!1), [u, d] = N(!1), { value: f, placeholder: p, id: h, name: g } = e, { node: _, setValue: v, error: y, label: b, helperText: x } = t, { language: S, googleApiKey: C } = i(), w = a(), { colors: T } = m(), E = te((e) => {
40
+ v(e.value), r(""), l(!1), s([]);
41
41
  }, [v]), D = () => {
42
- c(!1);
42
+ l(!1);
43
43
  };
44
- return A(() => {
45
- if (!r || r.trim().length < 3) {
46
- o([]), u(!1);
44
+ return j(() => {
45
+ if (!n || n.trim().length < 3) {
46
+ s([]), d(!1);
47
47
  return;
48
48
  }
49
- u(!0);
49
+ d(!0);
50
50
  let e = setTimeout(async () => {
51
- o(C ? await fe(r, C) : await de(r, S)), u(!1);
51
+ s(C ? await pe(n, C) : await fe(n, S)), d(!1);
52
52
  }, 300);
53
53
  return () => {
54
- clearTimeout(e), u(!1);
54
+ clearTimeout(e), d(!1);
55
55
  };
56
56
  }, [
57
- r,
57
+ n,
58
58
  S,
59
59
  C
60
60
  ]), /* @__PURE__ */ F(H, {
@@ -76,23 +76,23 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
76
76
  },
77
77
  y && { borderColor: T.error }
78
78
  ],
79
- onPress: () => c(!0),
79
+ onPress: () => l(!0),
80
80
  activeOpacity: .7,
81
81
  children: [/* @__PURE__ */ P(B, {
82
82
  style: [
83
83
  U.triggerText,
84
84
  { color: T.text },
85
- !d && { color: T.textMuted }
85
+ !f && { color: T.textMuted }
86
86
  ],
87
87
  numberOfLines: 1,
88
- children: d || f || w("renderer.defaultAddressInput.enterAddress")
88
+ children: f || p || w("renderer.defaultAddressInput.enterAddress")
89
89
  }), /* @__PURE__ */ P(B, {
90
90
  style: U.icon,
91
91
  children: "📍"
92
92
  })]
93
93
  }),
94
- /* @__PURE__ */ P(oe, {
95
- visible: s,
94
+ /* @__PURE__ */ P(se, {
95
+ visible: c,
96
96
  transparent: !0,
97
97
  animationType: "fade",
98
98
  onRequestClose: D,
@@ -120,41 +120,41 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
120
120
  }),
121
121
  /* @__PURE__ */ F(H, {
122
122
  style: U.searchContainer,
123
- children: [/* @__PURE__ */ P(ce, {
123
+ children: [/* @__PURE__ */ P(le, {
124
124
  style: [U.searchInput, {
125
125
  backgroundColor: T.muted,
126
126
  borderColor: T.border,
127
127
  color: T.text
128
128
  }],
129
- placeholder: f || w("renderer.defaultAddressInput.enterAddress"),
129
+ placeholder: p || w("renderer.defaultAddressInput.enterAddress"),
130
130
  placeholderTextColor: T.textMuted,
131
- value: r,
132
- onChangeText: i,
131
+ value: n,
132
+ onChangeText: r,
133
133
  autoFocus: !0,
134
134
  autoCapitalize: "none",
135
135
  autoCorrect: !1
136
- }), l && /* @__PURE__ */ P(re, {
136
+ }), u && /* @__PURE__ */ P(ie, {
137
137
  size: "small",
138
138
  color: T.primary,
139
139
  style: U.searchLoader
140
140
  })]
141
141
  }),
142
- l ? /* @__PURE__ */ F(H, {
142
+ u ? /* @__PURE__ */ F(H, {
143
143
  style: U.loadingContainer,
144
- children: [/* @__PURE__ */ P(re, {
144
+ children: [/* @__PURE__ */ P(ie, {
145
145
  size: "small",
146
146
  color: T.primary
147
147
  }), /* @__PURE__ */ P(B, {
148
148
  style: [U.loadingText, { color: T.textMuted }],
149
149
  children: w("renderer.defaultAddressInput.searching")
150
150
  })]
151
- }) : /* @__PURE__ */ P(ae, {
152
- data: a,
151
+ }) : /* @__PURE__ */ P(oe, {
152
+ data: o,
153
153
  keyExtractor: (e, t) => t.toString(),
154
154
  style: U.suggestionsList,
155
155
  contentContainerStyle: U.suggestionsListContent,
156
156
  keyboardShouldPersistTaps: "handled",
157
- ListEmptyComponent: r.length >= 3 ? /* @__PURE__ */ P(H, {
157
+ ListEmptyComponent: n.length >= 3 ? /* @__PURE__ */ P(H, {
158
158
  style: U.emptyContainer,
159
159
  children: /* @__PURE__ */ P(B, {
160
160
  style: [U.emptyText, { color: T.textMuted }],
@@ -305,25 +305,25 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
305
305
  flex: 1,
306
306
  fontSize: 14
307
307
  }
308
- }), me = ({ label: e, description: t, image: n, disabled: r }) => {
309
- let { colors: i } = h();
308
+ }), he = ({ label: e, description: t, image: n, disabled: r }) => {
309
+ let { colors: i } = m();
310
310
  return /* @__PURE__ */ F(H, {
311
- style: he.content,
311
+ style: ge.content,
312
312
  children: [n ? /* @__PURE__ */ P(L, {
313
313
  source: { uri: n },
314
- style: he.image
314
+ style: ge.image
315
315
  }) : null, /* @__PURE__ */ F(H, {
316
- style: he.textWrapper,
316
+ style: ge.textWrapper,
317
317
  children: [/* @__PURE__ */ P(B, {
318
- style: [he.label, { color: r ? i.textMuted : i.text }],
318
+ style: [ge.label, { color: r ? i.textMuted : i.text }],
319
319
  children: e
320
320
  }), t ? /* @__PURE__ */ P(B, {
321
- style: [he.description, { color: i.textMuted }],
321
+ style: [ge.description, { color: i.textMuted }],
322
322
  children: t
323
323
  }) : null]
324
324
  })]
325
325
  });
326
- }, he = z.create({
326
+ }, ge = z.create({
327
327
  content: {
328
328
  alignItems: "center",
329
329
  flex: 1,
@@ -341,19 +341,19 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
341
341
  },
342
342
  label: { fontSize: 14 },
343
343
  textWrapper: { flex: 1 }
344
- }), ge = ({ field: e, extra: n }) => {
345
- let [r, i] = N(!1), [a, o] = N(""), { value: s, placeholder: c } = e, { node: l, setValue: u, error: d, label: f, helperText: p } = n, m = t(), { colors: g } = h(), _ = l.data.options || [], v = _.find((e) => e.value === s), y = j(() => {
346
- if (!a.trim()) return _;
347
- let e = a.toLowerCase();
348
- return _.filter((t) => m(t.label).toLowerCase().includes(e) || t.value.toLowerCase().includes(e));
344
+ }), _e = ({ field: e, extra: t }) => {
345
+ let [n, r] = N(!1), [i, o] = N(""), { value: s, placeholder: c } = e, { node: l, setValue: u, error: d, label: f, helperText: p } = t, h = a(), { colors: g } = m(), _ = l.data.options || [], v = _.find((e) => e.value === s), y = ne(() => {
346
+ if (!i.trim()) return _;
347
+ let e = i.toLowerCase();
348
+ return _.filter((t) => h(t.label).toLowerCase().includes(e) || t.value.toLowerCase().includes(e));
349
349
  }, [
350
350
  _,
351
- a,
352
- m
351
+ i,
352
+ h
353
353
  ]), b = (e) => {
354
- u(e === s ? "" : e), i(!1), o("");
354
+ u(e === s ? "" : e), r(!1), o("");
355
355
  }, x = () => {
356
- i(!1), o("");
356
+ r(!1), o("");
357
357
  };
358
358
  return /* @__PURE__ */ F(H, {
359
359
  style: W.container,
@@ -374,23 +374,40 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
374
374
  },
375
375
  d && { borderColor: g.error }
376
376
  ],
377
- onPress: () => i(!0),
377
+ onPress: () => r(!0),
378
378
  activeOpacity: .7,
379
- children: [/* @__PURE__ */ P(B, {
380
- style: [
381
- W.triggerText,
382
- { color: g.text },
383
- !s && { color: g.textMuted }
384
- ],
385
- numberOfLines: 1,
386
- children: s && v ? m(v.label) : c || m("renderer.defaultAutocompleteInput.selectOption")
387
- }), /* @__PURE__ */ P(B, {
388
- style: [W.arrow, { color: g.textMuted }],
389
- children: "▼"
390
- })]
379
+ children: [
380
+ /* @__PURE__ */ P(B, {
381
+ style: [
382
+ W.triggerText,
383
+ { color: g.text },
384
+ !s && { color: g.textMuted }
385
+ ],
386
+ numberOfLines: 1,
387
+ children: s && v ? h(v.label) : c || h("renderer.defaultAutocompleteInput.selectOption")
388
+ }),
389
+ s ? /* @__PURE__ */ P(V, {
390
+ onPress: () => u(""),
391
+ hitSlop: {
392
+ bottom: 8,
393
+ left: 8,
394
+ right: 8,
395
+ top: 8
396
+ },
397
+ style: W.clearButton,
398
+ children: /* @__PURE__ */ P(B, {
399
+ style: [W.clearIcon, { color: g.textMuted }],
400
+ children: "✕"
401
+ })
402
+ }) : null,
403
+ /* @__PURE__ */ P(B, {
404
+ style: [W.arrow, { color: g.textMuted }],
405
+ children: "▼"
406
+ })
407
+ ]
391
408
  }),
392
- /* @__PURE__ */ P(oe, {
393
- visible: r,
409
+ /* @__PURE__ */ P(se, {
410
+ visible: n,
394
411
  transparent: !0,
395
412
  animationType: "fade",
396
413
  onRequestClose: x,
@@ -418,22 +435,22 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
418
435
  }),
419
436
  /* @__PURE__ */ P(H, {
420
437
  style: W.searchContainer,
421
- children: /* @__PURE__ */ P(ce, {
438
+ children: /* @__PURE__ */ P(le, {
422
439
  style: [W.searchInput, {
423
440
  backgroundColor: g.muted,
424
441
  borderColor: g.border,
425
442
  color: g.text
426
443
  }],
427
- placeholder: c || m("renderer.defaultAutocompleteInput.search"),
444
+ placeholder: c || h("renderer.defaultAutocompleteInput.search"),
428
445
  placeholderTextColor: g.textMuted,
429
- value: a,
446
+ value: i,
430
447
  onChangeText: o,
431
448
  autoFocus: !0,
432
449
  autoCapitalize: "none",
433
450
  autoCorrect: !1
434
451
  })
435
452
  }),
436
- /* @__PURE__ */ P(ae, {
453
+ /* @__PURE__ */ P(oe, {
437
454
  data: y,
438
455
  keyExtractor: (e) => e.value,
439
456
  style: W.optionsList,
@@ -442,7 +459,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
442
459
  style: W.emptyContainer,
443
460
  children: /* @__PURE__ */ P(B, {
444
461
  style: [W.emptyText, { color: g.textMuted }],
445
- children: m("renderer.defaultAutocompleteInput.noResults")
462
+ children: h("renderer.defaultAutocompleteInput.noResults")
446
463
  })
447
464
  }),
448
465
  renderItem: ({ item: e }) => {
@@ -452,9 +469,9 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
452
469
  onPress: () => b(e.value),
453
470
  disabled: e.disabled,
454
471
  activeOpacity: .7,
455
- children: [/* @__PURE__ */ P(me, {
456
- label: m(e.label) || e.value,
457
- description: m(e.description),
472
+ children: [/* @__PURE__ */ P(he, {
473
+ label: h(e.label) || e.value,
474
+ description: h(e.description),
458
475
  image: e.image,
459
476
  disabled: e.disabled
460
477
  }), t && /* @__PURE__ */ P(B, {
@@ -484,6 +501,11 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
484
501
  fontSize: 18,
485
502
  fontWeight: "700"
486
503
  },
504
+ clearButton: {
505
+ marginRight: 8,
506
+ paddingHorizontal: 2
507
+ },
508
+ clearIcon: { fontSize: 14 },
487
509
  closeButton: {
488
510
  fontSize: 24,
489
511
  fontWeight: "300"
@@ -565,22 +587,22 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
565
587
  flex: 1,
566
588
  fontSize: 14
567
589
  }
568
- }), _e = ({ field: e, extra: n }) => {
569
- let r = t(), { value: i } = e, { node: a, setValue: o, error: s, label: c, helperText: l } = n, { colors: u } = h(), d = a.data.options || [], f = d.length > 0, p = Array.isArray(i) ? i : [], m = typeof i == "boolean" ? i : !1, g = (e) => {
570
- o(f ? p.includes(e) ? p.filter((t) => t !== e) : [...p, e] : !m);
571
- }, _ = (e) => f ? p.includes(e) : m;
590
+ }), ve = ({ field: e, extra: t }) => {
591
+ let n = a(), { value: r } = e, { node: i, setValue: o, error: s, label: c, helperText: l } = t, { colors: u } = m(), d = i.data.options || [], f = d.length > 0, p = Array.isArray(r) ? r : [], h = typeof r == "boolean" ? r : !1, g = (e) => {
592
+ o(f ? p.includes(e) ? p.filter((t) => t !== e) : [...p, e] : !h);
593
+ }, _ = (e) => f ? p.includes(e) : h;
572
594
  return /* @__PURE__ */ F(H, {
573
595
  style: G.container,
574
596
  children: [
575
597
  /* @__PURE__ */ F(B, {
576
598
  style: [G.label, { color: u.textSecondary }],
577
- children: [c || a.data.name, a.data.required && /* @__PURE__ */ P(B, {
599
+ children: [c || i.data.name, i.data.required && /* @__PURE__ */ P(B, {
578
600
  style: { color: u.error },
579
601
  children: "*"
580
602
  })]
581
603
  }),
582
604
  d.length > 0 ? d.map((e) => {
583
- let t = r(e.description);
605
+ let t = n(e.description);
584
606
  return /* @__PURE__ */ F(V, {
585
607
  style: G.option,
586
608
  onPress: () => g(e.value),
@@ -592,7 +614,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
592
614
  checked: _(e.value),
593
615
  disabled: e.disabled
594
616
  },
595
- accessibilityLabel: r(e.label) || e.value,
617
+ accessibilityLabel: n(e.label) || e.value,
596
618
  children: [
597
619
  /* @__PURE__ */ P(H, {
598
620
  style: [
@@ -623,7 +645,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
623
645
  { color: u.textSecondary },
624
646
  e.disabled && { color: u.textMuted }
625
647
  ],
626
- children: r(e.label) || e.value
648
+ children: n(e.label) || e.value
627
649
  }), t && /* @__PURE__ */ P(B, {
628
650
  style: [G.optionDescription, { color: u.textMuted }],
629
651
  children: t
@@ -637,8 +659,8 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
637
659
  activeOpacity: .7,
638
660
  accessible: !0,
639
661
  accessibilityRole: "checkbox",
640
- accessibilityState: { checked: m },
641
- accessibilityLabel: c || a.data.name,
662
+ accessibilityState: { checked: h },
663
+ accessibilityLabel: c || i.data.name,
642
664
  children: [/* @__PURE__ */ P(H, {
643
665
  style: [
644
666
  G.checkbox,
@@ -646,18 +668,18 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
646
668
  backgroundColor: u.input,
647
669
  borderColor: u.border
648
670
  },
649
- m && {
671
+ h && {
650
672
  backgroundColor: u.primary,
651
673
  borderColor: u.primary
652
674
  }
653
675
  ],
654
- children: m && /* @__PURE__ */ P(B, {
676
+ children: h && /* @__PURE__ */ P(B, {
655
677
  style: G.checkmark,
656
678
  children: "✓"
657
679
  })
658
680
  }), /* @__PURE__ */ P(B, {
659
681
  style: [G.optionLabel, { color: u.textSecondary }],
660
- children: c || a.data.name
682
+ children: c || i.data.name
661
683
  })]
662
684
  }),
663
685
  s && /* @__PURE__ */ P(B, {
@@ -716,15 +738,15 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
716
738
  },
717
739
  optionLabel: { fontSize: 14 },
718
740
  optionTextContainer: { flex: 1 }
719
- }), ve = ({ field: e, extra: n }) => {
720
- let [r, i] = N(!1), { value: a, placeholder: o } = e, { node: s, setValue: c, error: l, label: u, helperText: d } = n, { colors: f } = h(), p = t(), m = a ? new Date(a) : void 0, { year: g, month: _, today: v } = j(() => {
721
- let e = m || /* @__PURE__ */ new Date(), t = e.getFullYear(), n = e.getMonth(), r = /* @__PURE__ */ new Date();
741
+ }), ye = ({ field: e, extra: t }) => {
742
+ let [n, r] = N(!1), { value: i, placeholder: o } = e, { node: s, setValue: c, error: l, label: u, helperText: d } = t, { colors: f } = m(), p = a(), h = i ? new Date(i) : void 0, { year: g, month: _, today: v } = ne(() => {
743
+ let e = h || /* @__PURE__ */ new Date(), t = e.getFullYear(), n = e.getMonth(), r = /* @__PURE__ */ new Date();
722
744
  return r.setHours(0, 0, 0, 0), {
723
745
  month: n,
724
746
  today: r,
725
747
  year: t
726
748
  };
727
- }, [m]), [y, b] = N(g), [x, S] = N(_), C = [
749
+ }, [h]), [y, b] = N(g), [x, S] = N(_), C = [
728
750
  "January",
729
751
  "February",
730
752
  "March",
@@ -737,7 +759,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
737
759
  "October",
738
760
  "November",
739
761
  "December"
740
- ], w = j(() => {
762
+ ], w = ne(() => {
741
763
  let e = new Date(y, x, 1).getDay(), t = new Date(y, x + 1, 0).getDate(), n = new Date(y, x, 0).getDate(), r = [];
742
764
  for (let t = e - 1; t >= 0; t--) r.push({
743
765
  date: new Date(y, x - 1, n - t),
@@ -757,7 +779,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
757
779
  });
758
780
  return r;
759
781
  }, [y, x]), T = te((e) => {
760
- s.data.disablePast && e < v || (c(e.toISOString()), i(!1));
782
+ s.data.disablePast && e < v || (c(e.toISOString()), r(!1));
761
783
  }, [
762
784
  s.data.disablePast,
763
785
  v,
@@ -766,7 +788,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
766
788
  x === 0 ? (S(11), b(y - 1)) : S(x - 1);
767
789
  }, D = () => {
768
790
  x === 11 ? (S(0), b(y + 1)) : S(x + 1);
769
- }, ee = () => m ? m.toLocaleDateString() : o || p("renderer.defaultInputs.selectDate"), O = (e) => s.data.disablePast ? e < v : !1, k = (e) => m ? e.getDate() === m.getDate() && e.getMonth() === m.getMonth() && e.getFullYear() === m.getFullYear() : !1;
791
+ }, O = () => h ? h.toLocaleDateString() : o || p("renderer.defaultInputs.selectDate"), k = (e) => s.data.disablePast ? e < v : !1, A = (e) => h ? e.getDate() === h.getDate() && e.getMonth() === h.getMonth() && e.getFullYear() === h.getFullYear() : !1;
770
792
  return /* @__PURE__ */ F(H, {
771
793
  style: K.container,
772
794
  children: [
@@ -786,30 +808,30 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
786
808
  },
787
809
  l && { borderColor: f.error }
788
810
  ],
789
- onPress: () => i(!0),
811
+ onPress: () => r(!0),
790
812
  activeOpacity: .7,
791
813
  children: [/* @__PURE__ */ P(B, {
792
814
  style: [
793
815
  K.triggerText,
794
816
  { color: f.text },
795
- !a && { color: f.textMuted }
817
+ !i && { color: f.textMuted }
796
818
  ],
797
819
  numberOfLines: 1,
798
- children: ee()
820
+ children: O()
799
821
  }), /* @__PURE__ */ P(B, {
800
822
  style: K.icon,
801
823
  children: "📅"
802
824
  })]
803
825
  }),
804
- /* @__PURE__ */ P(oe, {
805
- visible: r,
826
+ /* @__PURE__ */ P(se, {
827
+ visible: n,
806
828
  transparent: !0,
807
829
  animationType: "fade",
808
- onRequestClose: () => i(!1),
830
+ onRequestClose: () => r(!1),
809
831
  children: /* @__PURE__ */ P(V, {
810
832
  style: K.modalOverlay,
811
833
  activeOpacity: 1,
812
- onPress: () => i(!1),
834
+ onPress: () => r(!1),
813
835
  children: /* @__PURE__ */ F(V, {
814
836
  style: [K.modalContent, { backgroundColor: f.card }],
815
837
  activeOpacity: 1,
@@ -821,7 +843,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
821
843
  style: [K.modalTitle, { color: f.text }],
822
844
  children: u || s.data.name
823
845
  }), /* @__PURE__ */ P(V, {
824
- onPress: () => i(!1),
846
+ onPress: () => r(!1),
825
847
  children: /* @__PURE__ */ P(B, {
826
848
  style: [K.closeButton, { color: f.textMuted }],
827
849
  children: "✕"
@@ -872,7 +894,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
872
894
  children: e
873
895
  }, e))
874
896
  }),
875
- /* @__PURE__ */ P(ae, {
897
+ /* @__PURE__ */ P(oe, {
876
898
  data: w,
877
899
  keyExtractor: (e, t) => `${e.date.getTime()}-${t}`,
878
900
  numColumns: 7,
@@ -880,7 +902,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
880
902
  style: K.calendar,
881
903
  contentContainerStyle: K.calendarContent,
882
904
  renderItem: ({ item: e }) => {
883
- let t = O(e.date), n = k(e.date);
905
+ let t = k(e.date), n = A(e.date);
884
906
  return /* @__PURE__ */ P(V, {
885
907
  style: [
886
908
  K.dayCell,
@@ -1024,8 +1046,8 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1024
1046
  flexDirection: "row",
1025
1047
  marginBottom: 8
1026
1048
  }
1027
- }), ye = ({ field: e, extra: n }) => {
1028
- let [r, i] = N(!1), [a, o] = N(!0), { value: s } = e, { node: c, setValue: l, error: u, label: d, helperText: f } = n, p = t(), { colors: m } = h(), g = Array.isArray(s) ? s : [], _ = g[0] ? new Date(g[0]) : void 0, v = g[1] ? new Date(g[1]) : void 0, { year: y, month: b, today: x } = j(() => {
1049
+ }), be = ({ field: e, extra: t }) => {
1050
+ let [n, r] = N(!1), [i, o] = N(!0), { value: s } = e, { node: c, setValue: l, error: u, label: d, helperText: f } = t, p = a(), { colors: h } = m(), g = Array.isArray(s) ? s : [], _ = g[0] ? new Date(g[0]) : void 0, v = g[1] ? new Date(g[1]) : void 0, { year: y, month: b, today: x } = ne(() => {
1029
1051
  let e = _ || /* @__PURE__ */ new Date(), t = e.getFullYear(), n = e.getMonth(), r = /* @__PURE__ */ new Date();
1030
1052
  return r.setHours(0, 0, 0, 0), {
1031
1053
  month: n,
@@ -1045,7 +1067,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1045
1067
  "October",
1046
1068
  "November",
1047
1069
  "December"
1048
- ], D = j(() => {
1070
+ ], D = ne(() => {
1049
1071
  let e = new Date(S, w, 1).getDay(), t = new Date(S, w + 1, 0).getDate(), n = new Date(S, w, 0).getDate(), r = [];
1050
1072
  for (let t = e - 1; t >= 0; t--) r.push({
1051
1073
  date: new Date(S, w - 1, n - t),
@@ -1064,20 +1086,20 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1064
1086
  isCurrentMonth: !1
1065
1087
  });
1066
1088
  return r;
1067
- }, [S, w]), ee = te((e) => {
1068
- c.data.disablePast && e < x || (a ? (l([e.toISOString(), v?.toISOString()]), o(!1)) : (l(_ && e < _ ? [e.toISOString(), _.toISOString()] : [_?.toISOString(), e.toISOString()]), i(!1), o(!0)));
1089
+ }, [S, w]), O = te((e) => {
1090
+ c.data.disablePast && e < x || (i ? (l([e.toISOString(), v?.toISOString()]), o(!1)) : (l(_ && e < _ ? [e.toISOString(), _.toISOString()] : [_?.toISOString(), e.toISOString()]), r(!1), o(!0)));
1069
1091
  }, [
1070
1092
  c.data.disablePast,
1071
1093
  x,
1072
- a,
1094
+ i,
1073
1095
  _,
1074
1096
  v,
1075
1097
  l
1076
- ]), O = () => {
1098
+ ]), k = () => {
1077
1099
  w === 0 ? (T(11), C(S - 1)) : T(w - 1);
1078
- }, k = () => {
1100
+ }, A = () => {
1079
1101
  w === 11 ? (T(0), C(S + 1)) : T(w + 1);
1080
- }, A = () => _ && v ? `${_.toLocaleDateString()} - ${v.toLocaleDateString()}` : _ ? _.toLocaleDateString() : p("renderer.defaultInputs.selectDateRange"), M = (e) => c.data.disablePast ? e < x : !1, ne = (e) => _ && v ? e >= _ && e <= v : !1, re = (e) => {
1102
+ }, ee = () => _ && v ? `${_.toLocaleDateString()} - ${v.toLocaleDateString()}` : _ ? _.toLocaleDateString() : p("renderer.defaultInputs.selectDateRange"), j = (e) => c.data.disablePast ? e < x : !1, M = (e) => _ && v ? e >= _ && e <= v : !1, re = (e) => {
1081
1103
  if (!(_ || v)) return !1;
1082
1104
  let t = _ && e.getDate() === _.getDate() && e.getMonth() === _.getMonth() && e.getFullYear() === _.getFullYear(), n = v && e.getDate() === v.getDate() && e.getMonth() === v.getMonth() && e.getFullYear() === v.getFullYear();
1083
1105
  return t || n;
@@ -1086,9 +1108,9 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1086
1108
  style: q.container,
1087
1109
  children: [
1088
1110
  /* @__PURE__ */ F(B, {
1089
- style: [q.label, { color: m.textSecondary }],
1111
+ style: [q.label, { color: h.textSecondary }],
1090
1112
  children: [d || c.data.name, c.data.required && /* @__PURE__ */ P(B, {
1091
- style: { color: m.error },
1113
+ style: { color: h.error },
1092
1114
  children: "*"
1093
1115
  })]
1094
1116
  }),
@@ -1096,73 +1118,73 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1096
1118
  style: [
1097
1119
  q.trigger,
1098
1120
  {
1099
- backgroundColor: m.input,
1100
- borderColor: m.border
1121
+ backgroundColor: h.input,
1122
+ borderColor: h.border
1101
1123
  },
1102
- u && { borderColor: m.error }
1124
+ u && { borderColor: h.error }
1103
1125
  ],
1104
- onPress: () => i(!0),
1126
+ onPress: () => r(!0),
1105
1127
  activeOpacity: .7,
1106
1128
  children: [/* @__PURE__ */ P(B, {
1107
1129
  style: [
1108
1130
  q.triggerText,
1109
- { color: m.text },
1110
- !_ && { color: m.textMuted }
1131
+ { color: h.text },
1132
+ !_ && { color: h.textMuted }
1111
1133
  ],
1112
1134
  numberOfLines: 1,
1113
- children: A()
1135
+ children: ee()
1114
1136
  }), /* @__PURE__ */ P(B, {
1115
1137
  style: q.icon,
1116
1138
  children: "📅"
1117
1139
  })]
1118
1140
  }),
1119
- /* @__PURE__ */ P(oe, {
1120
- visible: r,
1141
+ /* @__PURE__ */ P(se, {
1142
+ visible: n,
1121
1143
  transparent: !0,
1122
1144
  animationType: "fade",
1123
- onRequestClose: () => i(!1),
1145
+ onRequestClose: () => r(!1),
1124
1146
  children: /* @__PURE__ */ P(V, {
1125
1147
  style: q.modalOverlay,
1126
1148
  activeOpacity: 1,
1127
- onPress: () => i(!1),
1149
+ onPress: () => r(!1),
1128
1150
  children: /* @__PURE__ */ F(V, {
1129
- style: [q.modalContent, { backgroundColor: m.card }],
1151
+ style: [q.modalContent, { backgroundColor: h.card }],
1130
1152
  activeOpacity: 1,
1131
1153
  onPress: () => {},
1132
1154
  children: [
1133
1155
  /* @__PURE__ */ F(H, {
1134
- style: [q.modalHeader, { borderBottomColor: m.separator }],
1156
+ style: [q.modalHeader, { borderBottomColor: h.separator }],
1135
1157
  children: [/* @__PURE__ */ P(B, {
1136
- style: [q.modalTitle, { color: m.text }],
1158
+ style: [q.modalTitle, { color: h.text }],
1137
1159
  children: d || c.data.name
1138
1160
  }), /* @__PURE__ */ P(V, {
1139
- onPress: () => i(!1),
1161
+ onPress: () => r(!1),
1140
1162
  children: /* @__PURE__ */ P(B, {
1141
- style: [q.closeButton, { color: m.textMuted }],
1163
+ style: [q.closeButton, { color: h.textMuted }],
1142
1164
  children: "✕"
1143
1165
  })
1144
1166
  })]
1145
1167
  }),
1146
1168
  /* @__PURE__ */ P(H, {
1147
- style: [q.rangeIndicator, { backgroundColor: m.primaryLight }],
1169
+ style: [q.rangeIndicator, { backgroundColor: h.primaryLight }],
1148
1170
  children: /* @__PURE__ */ P(B, {
1149
- style: [q.rangeIndicatorText, { color: m.primary }],
1150
- children: p(a ? "renderer.defaultInputs.startDate" : "renderer.defaultInputs.endDate")
1171
+ style: [q.rangeIndicatorText, { color: h.primary }],
1172
+ children: p(i ? "renderer.defaultInputs.startDate" : "renderer.defaultInputs.endDate")
1151
1173
  })
1152
1174
  }),
1153
1175
  /* @__PURE__ */ F(H, {
1154
1176
  style: q.calendarHeader,
1155
1177
  children: [
1156
1178
  /* @__PURE__ */ P(V, {
1157
- onPress: O,
1179
+ onPress: k,
1158
1180
  style: q.navButton,
1159
1181
  children: /* @__PURE__ */ P(B, {
1160
- style: [q.navButtonText, { color: m.primary }],
1182
+ style: [q.navButtonText, { color: h.primary }],
1161
1183
  children: "‹"
1162
1184
  })
1163
1185
  }),
1164
1186
  /* @__PURE__ */ F(B, {
1165
- style: [q.monthYear, { color: m.text }],
1187
+ style: [q.monthYear, { color: h.text }],
1166
1188
  children: [
1167
1189
  E[w],
1168
1190
  " ",
@@ -1170,10 +1192,10 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1170
1192
  ]
1171
1193
  }),
1172
1194
  /* @__PURE__ */ P(V, {
1173
- onPress: k,
1195
+ onPress: A,
1174
1196
  style: q.navButton,
1175
1197
  children: /* @__PURE__ */ P(B, {
1176
- style: [q.navButtonText, { color: m.primary }],
1198
+ style: [q.navButtonText, { color: h.primary }],
1177
1199
  children: "›"
1178
1200
  })
1179
1201
  })
@@ -1190,11 +1212,11 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1190
1212
  "Fri",
1191
1213
  "Sat"
1192
1214
  ].map((e) => /* @__PURE__ */ P(B, {
1193
- style: [q.weekDay, { color: m.textMuted }],
1215
+ style: [q.weekDay, { color: h.textMuted }],
1194
1216
  children: e
1195
1217
  }, e))
1196
1218
  }),
1197
- /* @__PURE__ */ P(ae, {
1219
+ /* @__PURE__ */ P(oe, {
1198
1220
  data: D,
1199
1221
  keyExtractor: (e, t) => `${e.date.getTime()}-${t}`,
1200
1222
  numColumns: 7,
@@ -1202,32 +1224,32 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1202
1224
  style: q.calendar,
1203
1225
  contentContainerStyle: q.calendarContent,
1204
1226
  renderItem: ({ item: e }) => {
1205
- let t = M(e.date), n = ne(e.date), r = re(e.date);
1227
+ let t = j(e.date), n = M(e.date), r = re(e.date);
1206
1228
  return /* @__PURE__ */ P(V, {
1207
1229
  style: [
1208
1230
  q.dayCell,
1209
1231
  !e.isCurrentMonth && q.dayCellOtherMonth,
1210
- n && { backgroundColor: m.primaryLight },
1232
+ n && { backgroundColor: h.primaryLight },
1211
1233
  r && {
1212
- backgroundColor: m.primary,
1234
+ backgroundColor: h.primary,
1213
1235
  borderRadius: 20
1214
1236
  },
1215
1237
  t && q.dayCellDisabled
1216
1238
  ],
1217
- onPress: () => ee(e.date),
1239
+ onPress: () => O(e.date),
1218
1240
  disabled: t,
1219
1241
  activeOpacity: .7,
1220
1242
  children: /* @__PURE__ */ P(B, {
1221
1243
  style: [
1222
1244
  q.dayText,
1223
- { color: m.text },
1224
- !e.isCurrentMonth && { color: m.textMuted },
1225
- n && { color: m.primary },
1245
+ { color: h.text },
1246
+ !e.isCurrentMonth && { color: h.textMuted },
1247
+ n && { color: h.primary },
1226
1248
  r && {
1227
- color: m.background,
1249
+ color: h.background,
1228
1250
  fontWeight: "600"
1229
1251
  },
1230
- t && { color: m.textMuted }
1252
+ t && { color: h.textMuted }
1231
1253
  ],
1232
1254
  children: e.day
1233
1255
  })
@@ -1239,11 +1261,11 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1239
1261
  })
1240
1262
  }),
1241
1263
  u && /* @__PURE__ */ P(B, {
1242
- style: [q.error, { color: m.error }],
1264
+ style: [q.error, { color: h.error }],
1243
1265
  children: u
1244
1266
  }),
1245
1267
  f && !u && /* @__PURE__ */ P(B, {
1246
- style: [q.helperText, { color: m.textMuted }],
1268
+ style: [q.helperText, { color: h.textMuted }],
1247
1269
  children: f
1248
1270
  })
1249
1271
  ]
@@ -1358,10 +1380,10 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1358
1380
  flexDirection: "row",
1359
1381
  marginBottom: 8
1360
1382
  }
1361
- }), be = ({ field: e, extra: n }) => {
1362
- let [r, i] = N(null), [a, o] = N(!0), { value: s } = e, { node: c, setValue: l, error: u, label: d, helperText: f } = n, { colors: p } = h(), m = t(), g = Array.isArray(s) ? s : s ? [s] : [], _ = c.data.multiple, v = te(async () => {
1363
- if (r) try {
1364
- let e = (await r({ allowMultiSelection: _ })).map((e) => ({
1383
+ }), xe = ({ field: e, extra: t }) => {
1384
+ let [n, r] = N(null), [i, o] = N(!0), { value: s } = e, { node: c, setValue: l, error: u, label: d, helperText: f } = t, { colors: p } = m(), h = a(), g = Array.isArray(s) ? s : s ? [s] : [], _ = c.data.multiple, v = te(async () => {
1385
+ if (n) try {
1386
+ let e = (await n({ allowMultiSelection: _ })).map((e) => ({
1365
1387
  data: e.uri,
1366
1388
  lastModified: Date.now(),
1367
1389
  name: e.name,
@@ -1370,30 +1392,30 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1370
1392
  }));
1371
1393
  l(_ ? [...g, ...e] : e[0] || null);
1372
1394
  } catch (e) {
1373
- e.code !== "DOCUMENT_PICKER_CANCELED" && ie.alert("Error", m("renderer.defaultInputs.filePickerError"));
1395
+ e.code !== "DOCUMENT_PICKER_CANCELED" && ae.alert("Error", h("renderer.defaultInputs.filePickerError"));
1374
1396
  }
1375
1397
  }, [
1376
- r,
1398
+ n,
1377
1399
  g,
1378
1400
  _,
1379
1401
  l,
1380
- m
1402
+ h
1381
1403
  ]), y = te((e) => {
1382
1404
  let t = g.filter((t, n) => n !== e);
1383
1405
  l(t.length > 0 ? t : null);
1384
1406
  }, [g, l]), b = (e) => e < 1024 ? `${e} B` : e < 1024 * 1024 ? `${(e / 1024).toFixed(1)} KB` : `${(e / (1024 * 1024)).toFixed(1)} MB`;
1385
- return A(() => {
1407
+ return j(() => {
1386
1408
  (async () => {
1387
1409
  try {
1388
1410
  let { pick: e } = await import("react-native-document-picker");
1389
- i(() => e);
1411
+ r(() => e);
1390
1412
  } catch {
1391
- i(null);
1413
+ r(null);
1392
1414
  } finally {
1393
1415
  o(!1);
1394
1416
  }
1395
1417
  })();
1396
- }, []), a ? null : r ? /* @__PURE__ */ F(H, {
1418
+ }, []), i ? null : n ? /* @__PURE__ */ F(H, {
1397
1419
  style: J.container,
1398
1420
  children: [
1399
1421
  /* @__PURE__ */ F(B, {
@@ -1450,7 +1472,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1450
1472
  activeOpacity: .7,
1451
1473
  children: /* @__PURE__ */ P(B, {
1452
1474
  style: [J.pickButtonText, { color: p.textMuted }],
1453
- children: g.length === 0 ? m(_ ? "renderer.defaultInputs.selectFiles" : "renderer.defaultInputs.selectFile") : m(_ ? "renderer.defaultInputs.addMoreFiles" : "renderer.defaultInputs.replaceFile")
1475
+ children: g.length === 0 ? h(_ ? "renderer.defaultInputs.selectFiles" : "renderer.defaultInputs.selectFile") : h(_ ? "renderer.defaultInputs.addMoreFiles" : "renderer.defaultInputs.replaceFile")
1454
1476
  })
1455
1477
  }),
1456
1478
  u && /* @__PURE__ */ P(B, {
@@ -1479,7 +1501,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1479
1501
  }],
1480
1502
  children: /* @__PURE__ */ P(B, {
1481
1503
  style: [J.unavailableText, { color: p.error }],
1482
- children: m("renderer.defaultInputs.filePickerUnavailable")
1504
+ children: h("renderer.defaultInputs.filePickerUnavailable")
1483
1505
  })
1484
1506
  }),
1485
1507
  f && /* @__PURE__ */ P(B, {
@@ -1557,15 +1579,15 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1557
1579
  fontSize: 12,
1558
1580
  textAlign: "center"
1559
1581
  }
1560
- }), xe = (e) => null, Se = ({ missing: e, children: n }) => {
1561
- let r = t(), { colors: i } = h();
1562
- return /* @__PURE__ */ F(ne, { children: [n, e.length > 0 && /* @__PURE__ */ F(H, {
1563
- style: Ce.container,
1582
+ }), Se = (e) => null, Ce = ({ missing: e, children: t }) => {
1583
+ let n = a(), { colors: r } = m();
1584
+ return /* @__PURE__ */ F(re, { children: [t, e.length > 0 && /* @__PURE__ */ F(H, {
1585
+ style: we.container,
1564
1586
  children: [/* @__PURE__ */ P(B, {
1565
- style: [Ce.title, { color: i.textMuted }],
1566
- children: r("renderer.dependencyHint.title")
1587
+ style: [we.title, { color: r.textMuted }],
1588
+ children: n("renderer.dependencyHint.title")
1567
1589
  }), e.map((e) => /* @__PURE__ */ F(B, {
1568
- style: [Ce.item, { color: i.textMuted }],
1590
+ style: [we.item, { color: r.textMuted }],
1569
1591
  children: [
1570
1592
  "•",
1571
1593
  " ",
@@ -1573,7 +1595,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1573
1595
  ]
1574
1596
  }, e.id))]
1575
1597
  })] });
1576
- }, Ce = z.create({
1598
+ }, we = z.create({
1577
1599
  container: {
1578
1600
  gap: 2,
1579
1601
  marginTop: 4
@@ -1583,282 +1605,299 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1583
1605
  fontSize: 12,
1584
1606
  fontWeight: "500"
1585
1607
  }
1586
- }), we = (e) => e.replace(/<[^>]*>/g, ""), Te = (e) => e.replace(/&amp;/g, "&").replace(/&lt;/g, "<").replace(/&gt;/g, ">").replace(/&quot;/g, "\"").replace(/&#x27;/g, "'").replace(/&#x2F;/g, "/"), Ee = (e, t = {}) => e == null || e === "" ? "" : Te(we(String(e))), De = 100, Oe = (e, t = {}, n = 0, r = /* @__PURE__ */ new WeakSet()) => {
1587
- if (n > De) return console.warn(`sanitizeHttpResponse: Maximum depth (${De}) exceeded.`), typeof e == "string" ? Ee(e, t) : "[Max Depth Exceeded]";
1608
+ }), Te = (e) => e.replace(/<[^>]*>/g, ""), Ee = (e) => e.replace(/&amp;/g, "&").replace(/&lt;/g, "<").replace(/&gt;/g, ">").replace(/&quot;/g, "\"").replace(/&#x27;/g, "'").replace(/&#x2F;/g, "/"), De = (e, t = {}) => e == null || e === "" ? "" : Ee(Te(String(e))), Oe = 100, ke = (e, t = {}, n = 0, r = /* @__PURE__ */ new WeakSet()) => {
1609
+ if (n > Oe) return console.warn(`sanitizeHttpResponse: Maximum depth (${Oe}) exceeded.`), typeof e == "string" ? De(e, t) : "[Max Depth Exceeded]";
1588
1610
  if (e == null) return e;
1589
- if (typeof e == "string") return Ee(e, t);
1590
- if (Array.isArray(e)) return e.map((e) => Oe(e, t, n + 1, r));
1611
+ if (typeof e == "string") return De(e, t);
1612
+ if (Array.isArray(e)) return e.map((e) => ke(e, t, n + 1, r));
1591
1613
  if (typeof e == "object") {
1592
1614
  if (r.has(e)) return console.warn("sanitizeHttpResponse: Circular reference detected. Breaking cycle to prevent infinite recursion."), "[Circular Reference]";
1593
1615
  r.add(e);
1594
1616
  let i = {};
1595
- for (let [a, o] of Object.entries(e)) i[a] = Oe(o, t, n + 1, r);
1617
+ for (let [a, o] of Object.entries(e)) i[a] = ke(o, t, n + 1, r);
1596
1618
  return r.delete(e), i;
1597
1619
  }
1598
1620
  return e;
1599
- }, ke = (e) => {
1621
+ }, Ae = (e) => {
1600
1622
  let t = e.matchAll(/{{([\w-]+)}}/g);
1601
1623
  return Array.from(t, (e) => e[1]);
1602
- }, Ae = (e, t) => ke(e).every((e) => {
1624
+ }, je = (e, t) => Ae(e).every((e) => {
1603
1625
  let n = t[e];
1604
1626
  return n != null && n !== "";
1605
- }), je = (e, t, n = !1) => e.replace(/{{([\w-]+)}}/g, (e, r) => {
1627
+ }), Me = (e, t, n = !1) => e.replace(/{{([\w-]+)}}/g, (e, r) => {
1606
1628
  let i = t[r], a = i == null ? "" : String(i);
1607
1629
  return n ? encodeURIComponent(a) : a;
1608
- }), Me = ({ field: e, extra: r }) => {
1609
- let [i, c] = N(!1), [u, d] = N(null), [f, m] = N([]), [g, _] = N(""), [v, b] = N(!1), { value: S, placeholder: C } = e, { node: w, setValue: T, error: E, label: D, helperText: ee, missingDependencies: O } = r, { formValues: k, inputNodes: ne, headers: ie, baseUrl: I } = p(), { colors: L } = h(), { httpConfig: R } = w.data, z = t(), se = M(!1), le = M(!1), ue = M(""), de = M(R), fe = M(k), pe = M(ne), U = M(ie), he = M(I), ge = M(T), W = M(null), _e = M(null), G = j(() => R?.url ? ke(R.url) : [], [R?.url]), ve = G.length > 0, K = j(() => G.map((e) => `${e}:${String(k[e] ?? "")}`).join("|"), [G, k]), ye = j(() => R?.url ? ve ? Ae(R.url, k) : !0 : !1, [
1610
- R?.url,
1611
- ve,
1612
- k
1613
- ]), q = te(async (e) => {
1614
- _e.current && _e.current.abort();
1615
- let t = new AbortController();
1616
- _e.current = t;
1617
- let r = de.current, i = fe.current, u = ge.current;
1618
- if (!r?.url) {
1619
- d(z("renderer.defaultHttpInput.noUrlConfigured")), _e.current = null;
1630
+ }), Ne = ({ field: r, extra: o }) => {
1631
+ let [s, c] = N(!1), [l, u] = N(null), [d, f] = N([]), [p, h] = N(""), [g, v] = N(!1), { value: S, placeholder: C } = r, { node: w, setValue: T, error: E, label: D, helperText: O, missingDependencies: k } = o, { formValues: A, inputNodes: ee, headers: re, baseUrl: ae } = i(), { colors: I } = m(), { httpConfig: L } = w.data, R = a(), z = M(!1), ce = M(!1), ue = M(""), de = M(L), fe = M(A), pe = M(ee), me = M(re), U = M(ae), ge = M(T), _e = M(null), W = M(null), ve = ne(() => L?.url ? Ae(L.url) : [], [L?.url]), G = ve.length > 0, ye = ne(() => ve.map((e) => `${e}:${String(A[e] ?? "")}`).join("|"), [ve, A]), K = ne(() => L?.url ? G ? je(L.url, A) : !0 : !1, [
1632
+ L?.url,
1633
+ G,
1634
+ A
1635
+ ]), be = te(async (r) => {
1636
+ W.current && W.current.abort();
1637
+ let i = new AbortController();
1638
+ W.current = i;
1639
+ let a = de.current, o = fe.current, s = ge.current;
1640
+ if (!a?.url) {
1641
+ u(R("renderer.defaultHttpInput.noUrlConfigured")), W.current = null;
1620
1642
  return;
1621
1643
  }
1622
- if (r.url && !Ae(r.url, i)) {
1623
- _e.current = null;
1644
+ if (a.url && !je(a.url, o)) {
1645
+ W.current = null;
1624
1646
  return;
1625
1647
  }
1626
- c(!0), d(null);
1648
+ c(!0), u(null);
1627
1649
  try {
1628
- let f = n(je(r.url, i, !0), he.current), p = x(r.searchParam && e ? `${f}${f.includes("?") ? "&" : "?"}${r.searchParam}=${encodeURIComponent(e)}` : f, o(r.queryParams, i)), h = a({ "Content-Type": "application/json" }, o(U.current, i), o(r.headers, i)), g = [
1650
+ let l = t(Me(a.url, o, !0), U.current), d = x(a.searchParam && r ? `${l}${l.includes("?") ? "&" : "?"}${a.searchParam}=${encodeURIComponent(r)}` : l, n(a.queryParams, o)), p = e({ "Content-Type": "application/json" }, n(me.current, o), n(a.headers, o)), m = [
1629
1651
  "POST",
1630
1652
  "PUT",
1631
1653
  "PATCH"
1632
- ].includes(r.method || "") ? r.sendAllFormValues ? JSON.stringify(y(i, pe.current)) : s(r.body, i, pe.current) : void 0, _ = setTimeout(() => t.abort(), 3e4), v = await fetch(p, {
1633
- body: g || void 0,
1634
- headers: Object.fromEntries(Object.entries(h).filter(([, e]) => e)),
1635
- method: r.method || "GET",
1636
- signal: t.signal
1654
+ ].includes(a.method || "") ? a.sendAllFormValues ? JSON.stringify(_(o, pe.current)) : y(a.body, o, pe.current) : void 0, h = setTimeout(() => i.abort(), 3e4), g = await fetch(d, {
1655
+ body: m || void 0,
1656
+ headers: Object.fromEntries(Object.entries(p).filter(([, e]) => e)),
1657
+ method: a.method || "GET",
1658
+ signal: i.signal
1637
1659
  });
1638
- if (clearTimeout(_), !v.ok) {
1639
- d(`HTTP Error ${v.status}: ${v.statusText}`), c(!1);
1660
+ if (clearTimeout(h), !g.ok) {
1661
+ u(`HTTP Error ${g.status}: ${g.statusText}`), c(!1);
1640
1662
  return;
1641
1663
  }
1642
- let b = Oe(await v.json()), S = r.responsePath ? l(b, r.responsePath) : b;
1643
- if (r.responseMapping && Array.isArray(S)) {
1644
- let { valueField: e = "value", labelField: t = "label", descriptionField: n, imageField: i } = r.responseMapping;
1645
- m(S.map((r) => {
1646
- let a = n ? l(r, n) : void 0, o = i ? l(r, i) : void 0;
1664
+ let v = ke(await g.json()), S = a.responsePath ? b(v, a.responsePath) : v;
1665
+ if (a.responseMapping && Array.isArray(S)) {
1666
+ let { valueField: e = "value", labelField: t = "label", descriptionField: n, imageField: r } = a.responseMapping;
1667
+ f(S.map((i) => {
1668
+ let a = n ? b(i, n) : void 0, o = r ? b(i, r) : void 0;
1647
1669
  return {
1648
1670
  description: a != null && a !== "" ? String(a) : void 0,
1649
1671
  image: typeof o == "string" && o !== "" ? o : void 0,
1650
- label: String(l(r, t) || ""),
1651
- value: String(l(r, e) || "")
1672
+ label: String(b(i, t) || ""),
1673
+ value: String(b(i, e) || "")
1652
1674
  };
1653
1675
  }));
1654
- } else u(typeof S == "string" ? S : JSON.stringify(S));
1676
+ } else s(typeof S == "string" ? S : JSON.stringify(S));
1655
1677
  } catch (e) {
1656
1678
  if (e instanceof Error && e.name === "AbortError") return;
1657
- d(e instanceof Error ? e.message : z("renderer.defaultHttpInput.fetchFailed")), console.error("HTTP Input fetch error:", e);
1679
+ u(e instanceof Error ? e.message : R("renderer.defaultHttpInput.fetchFailed")), console.error("HTTP Input fetch error:", e);
1658
1680
  } finally {
1659
- c(!1), _e.current = null;
1681
+ c(!1), W.current = null;
1660
1682
  }
1661
- }, [z]);
1662
- if (A(() => {
1663
- de.current = R, fe.current = k, pe.current = ne, U.current = ie, he.current = I, ge.current = T, W.current = q;
1683
+ }, [R]);
1684
+ if (j(() => {
1685
+ de.current = L, fe.current = A, pe.current = ee, me.current = re, U.current = ae, ge.current = T, _e.current = be;
1664
1686
  }, [
1665
- R,
1666
- k,
1667
- ne,
1668
- ie,
1669
- I,
1687
+ L,
1688
+ A,
1689
+ ee,
1690
+ re,
1691
+ ae,
1670
1692
  T,
1671
- q
1672
- ]), A(() => () => {
1673
- _e.current && _e.current.abort(), se.current = !1, le.current = !1;
1674
- }, []), A(() => {
1675
- if (se.current) return;
1676
- se.current = !0;
1677
- let e = de.current, t = fe.current, n = W.current, r = e?.url && Ae(e.url, t);
1678
- e?.fetchOnMount && r && n && (n(), e.url && (ue.current = ke(e.url).map((e) => `${e}:${String(t[e] ?? "")}`).join("|")));
1679
- }, []), A(() => {
1680
- if (!se.current || !ve || ue.current === K || !ye) return;
1693
+ be
1694
+ ]), j(() => () => {
1695
+ W.current && W.current.abort(), z.current = !1, ce.current = !1;
1696
+ }, []), j(() => {
1697
+ if (z.current) return;
1698
+ z.current = !0;
1699
+ let e = de.current, t = fe.current, n = _e.current, r = e?.url && je(e.url, t);
1700
+ e?.fetchOnMount && r && n && (n(), e.url && (ue.current = Ae(e.url).map((e) => `${e}:${String(t[e] ?? "")}`).join("|")));
1701
+ }, []), j(() => {
1702
+ if (!z.current || !G || ue.current === ye || !K) return;
1681
1703
  let e = setTimeout(() => {
1682
- q(), ue.current = K;
1704
+ be(), ue.current = ye;
1683
1705
  }, 500);
1684
1706
  return () => clearTimeout(e);
1685
1707
  }, [
1686
- K,
1687
- ve,
1688
1708
  ye,
1689
- q
1690
- ]), A(() => {
1691
- if (!le.current) {
1692
- le.current = !0;
1709
+ G,
1710
+ K,
1711
+ be
1712
+ ]), j(() => {
1713
+ if (!ce.current) {
1714
+ ce.current = !0;
1693
1715
  return;
1694
1716
  }
1695
- let e = de.current, t = fe.current, n = W.current, r = e?.url && Ae(e.url, t);
1696
- e?.fetchOnMount && r && n && (n(), e.url && (ue.current = ke(e.url).map((e) => `${e}:${String(t[e] ?? "")}`).join("|")));
1697
- }, [j(() => JSON.stringify({
1698
- body: R?.body,
1699
- fetchOnMount: R?.fetchOnMount,
1700
- headers: R?.headers,
1701
- method: R?.method,
1702
- queryParams: R?.queryParams,
1703
- responseMapping: R?.responseMapping,
1704
- responsePath: R?.responsePath,
1705
- searchParam: R?.searchParam,
1706
- sendAllFormValues: R?.sendAllFormValues,
1707
- url: R?.url
1708
- }), [R])]), A(() => {
1709
- if (!(R?.searchParam && g)) return;
1717
+ let e = de.current, t = fe.current, n = _e.current, r = e?.url && je(e.url, t);
1718
+ e?.fetchOnMount && r && n && (n(), e.url && (ue.current = Ae(e.url).map((e) => `${e}:${String(t[e] ?? "")}`).join("|")));
1719
+ }, [ne(() => JSON.stringify({
1720
+ body: L?.body,
1721
+ fetchOnMount: L?.fetchOnMount,
1722
+ headers: L?.headers,
1723
+ method: L?.method,
1724
+ queryParams: L?.queryParams,
1725
+ responseMapping: L?.responseMapping,
1726
+ responsePath: L?.responsePath,
1727
+ searchParam: L?.searchParam,
1728
+ sendAllFormValues: L?.sendAllFormValues,
1729
+ url: L?.url
1730
+ }), [L])]), j(() => {
1731
+ if (!(L?.searchParam && p)) return;
1710
1732
  let e = setTimeout(() => {
1711
- q(g);
1733
+ be(p);
1712
1734
  }, 300);
1713
1735
  return () => clearTimeout(e);
1714
1736
  }, [
1715
- g,
1716
- R?.searchParam,
1717
- q
1718
- ]), R?.responseMapping) {
1719
- let e = Array.isArray(S) ? S[0] : S, t = f.find((t) => t.value === e);
1720
- if (R.searchParam) {
1721
- let n = i && R?.showLoading;
1737
+ p,
1738
+ L?.searchParam,
1739
+ be
1740
+ ]), L?.responseMapping) {
1741
+ let e = Array.isArray(S) ? S[0] : S, t = d.find((t) => t.value === e);
1742
+ if (L.searchParam) {
1743
+ let n = s && L?.showLoading;
1722
1744
  return /* @__PURE__ */ F(H, {
1723
1745
  style: Y.container,
1724
1746
  children: [
1725
1747
  /* @__PURE__ */ F(B, {
1726
- style: [Y.label, { color: L.textSecondary }],
1748
+ style: [Y.label, { color: I.textSecondary }],
1727
1749
  children: [D || w.data.name, w.data.required && /* @__PURE__ */ P(B, {
1728
- style: { color: L.error },
1750
+ style: { color: I.error },
1729
1751
  children: "*"
1730
1752
  })]
1731
1753
  }),
1732
- /* @__PURE__ */ P(Se, {
1733
- missing: O,
1754
+ /* @__PURE__ */ P(Ce, {
1755
+ missing: k,
1734
1756
  children: /* @__PURE__ */ F(V, {
1735
1757
  style: [
1736
1758
  Y.trigger,
1737
1759
  {
1738
- backgroundColor: L.input,
1739
- borderColor: L.border
1760
+ backgroundColor: I.input,
1761
+ borderColor: I.border
1740
1762
  },
1741
- E && { borderColor: L.error },
1742
- O.length > 0 && { backgroundColor: L.muted }
1763
+ E && { borderColor: I.error },
1764
+ k.length > 0 && { backgroundColor: I.muted }
1743
1765
  ],
1744
- onPress: () => b(!0),
1745
- disabled: O.length > 0,
1766
+ onPress: () => v(!0),
1767
+ disabled: k.length > 0,
1746
1768
  activeOpacity: .7,
1747
- children: [n ? /* @__PURE__ */ F(H, {
1748
- style: Y.loadingTrigger,
1749
- children: [/* @__PURE__ */ P(re, {
1750
- size: "small",
1751
- color: L.primary
1752
- }), /* @__PURE__ */ P(B, {
1753
- style: [Y.triggerText, { color: L.textMuted }],
1769
+ children: [
1770
+ n ? /* @__PURE__ */ F(H, {
1771
+ style: Y.loadingTrigger,
1772
+ children: [/* @__PURE__ */ P(ie, {
1773
+ size: "small",
1774
+ color: I.primary
1775
+ }), /* @__PURE__ */ P(B, {
1776
+ style: [Y.triggerText, { color: I.textMuted }],
1777
+ numberOfLines: 1,
1778
+ children: t?.label || C || R("renderer.defaultHttpInput.search")
1779
+ })]
1780
+ }) : /* @__PURE__ */ P(B, {
1781
+ style: [
1782
+ Y.triggerText,
1783
+ { color: I.text },
1784
+ !t && { color: I.textMuted }
1785
+ ],
1754
1786
  numberOfLines: 1,
1755
- children: t?.label || C || z("renderer.defaultHttpInput.search")
1756
- })]
1757
- }) : /* @__PURE__ */ P(B, {
1758
- style: [
1759
- Y.triggerText,
1760
- { color: L.text },
1761
- !t && { color: L.textMuted }
1762
- ],
1763
- numberOfLines: 1,
1764
- children: t?.label || C || z("renderer.defaultHttpInput.search")
1765
- }), /* @__PURE__ */ P(B, {
1766
- style: [Y.arrow, { color: L.textMuted }],
1767
- children: "▼"
1768
- })]
1787
+ children: t?.label || C || R("renderer.defaultHttpInput.search")
1788
+ }),
1789
+ e ? /* @__PURE__ */ P(V, {
1790
+ onPress: () => T(""),
1791
+ hitSlop: {
1792
+ bottom: 8,
1793
+ left: 8,
1794
+ right: 8,
1795
+ top: 8
1796
+ },
1797
+ style: Y.clearButton,
1798
+ children: /* @__PURE__ */ P(B, {
1799
+ style: [Y.clearIcon, { color: I.textMuted }],
1800
+ children: "✕"
1801
+ })
1802
+ }) : null,
1803
+ /* @__PURE__ */ P(B, {
1804
+ style: [Y.arrow, { color: I.textMuted }],
1805
+ children: "▼"
1806
+ })
1807
+ ]
1769
1808
  })
1770
1809
  }),
1771
- /* @__PURE__ */ P(oe, {
1772
- visible: v,
1810
+ /* @__PURE__ */ P(se, {
1811
+ visible: g,
1773
1812
  transparent: !0,
1774
1813
  animationType: "fade",
1775
- onRequestClose: () => b(!1),
1814
+ onRequestClose: () => v(!1),
1776
1815
  children: /* @__PURE__ */ P(V, {
1777
1816
  style: Y.modalOverlay,
1778
1817
  activeOpacity: 1,
1779
- onPress: () => b(!1),
1818
+ onPress: () => v(!1),
1780
1819
  children: /* @__PURE__ */ F(V, {
1781
- style: [Y.modalContent, { backgroundColor: L.card }],
1820
+ style: [Y.modalContent, { backgroundColor: I.card }],
1782
1821
  activeOpacity: 1,
1783
1822
  onPress: () => {},
1784
1823
  children: [
1785
1824
  /* @__PURE__ */ F(H, {
1786
- style: [Y.modalHeader, { borderBottomColor: L.separator }],
1825
+ style: [Y.modalHeader, { borderBottomColor: I.separator }],
1787
1826
  children: [/* @__PURE__ */ P(B, {
1788
- style: [Y.modalTitle, { color: L.text }],
1827
+ style: [Y.modalTitle, { color: I.text }],
1789
1828
  children: D || w.data.name
1790
1829
  }), /* @__PURE__ */ P(V, {
1791
- onPress: () => b(!1),
1830
+ onPress: () => v(!1),
1792
1831
  children: /* @__PURE__ */ P(B, {
1793
- style: [Y.closeButton, { color: L.textMuted }],
1832
+ style: [Y.closeButton, { color: I.textMuted }],
1794
1833
  children: "✕"
1795
1834
  })
1796
1835
  })]
1797
1836
  }),
1798
1837
  /* @__PURE__ */ P(H, {
1799
1838
  style: Y.searchContainer,
1800
- children: /* @__PURE__ */ P(ce, {
1839
+ children: /* @__PURE__ */ P(le, {
1801
1840
  style: [Y.searchInput, {
1802
- backgroundColor: L.muted,
1803
- borderColor: L.border,
1804
- color: L.text
1841
+ backgroundColor: I.muted,
1842
+ borderColor: I.border,
1843
+ color: I.text
1805
1844
  }],
1806
- placeholder: z("renderer.defaultHttpInput.search"),
1807
- placeholderTextColor: L.textMuted,
1808
- value: g,
1845
+ placeholder: R("renderer.defaultHttpInput.search"),
1846
+ placeholderTextColor: I.textMuted,
1847
+ value: p,
1809
1848
  onChangeText: (e) => {
1810
- _(e), d(null);
1849
+ h(e), u(null);
1811
1850
  },
1812
1851
  autoFocus: !0,
1813
1852
  autoCapitalize: "none",
1814
1853
  autoCorrect: !1
1815
1854
  })
1816
1855
  }),
1817
- i ? /* @__PURE__ */ P(H, {
1856
+ s ? /* @__PURE__ */ P(H, {
1818
1857
  style: Y.loadingContainer,
1819
- children: /* @__PURE__ */ P(re, {
1858
+ children: /* @__PURE__ */ P(ie, {
1820
1859
  size: "small",
1821
- color: L.primary
1860
+ color: I.primary
1822
1861
  })
1823
- }) : u ? /* @__PURE__ */ F(H, {
1862
+ }) : l ? /* @__PURE__ */ F(H, {
1824
1863
  style: Y.errorContainer,
1825
1864
  children: [/* @__PURE__ */ P(B, {
1826
- style: [Y.errorText, { color: L.error }],
1827
- children: u
1865
+ style: [Y.errorText, { color: I.error }],
1866
+ children: l
1828
1867
  }), /* @__PURE__ */ P(V, {
1829
- onPress: () => q(g),
1868
+ onPress: () => be(p),
1830
1869
  style: Y.retryButton,
1831
1870
  children: /* @__PURE__ */ P(B, {
1832
- style: [Y.retryButtonText, { color: L.primary }],
1833
- children: z("renderer.defaultHttpInput.retry")
1871
+ style: [Y.retryButtonText, { color: I.primary }],
1872
+ children: R("renderer.defaultHttpInput.retry")
1834
1873
  })
1835
1874
  })]
1836
- }) : /* @__PURE__ */ P(ae, {
1837
- data: f,
1875
+ }) : /* @__PURE__ */ P(oe, {
1876
+ data: d,
1838
1877
  keyExtractor: (e) => e.value,
1839
1878
  style: Y.optionsList,
1840
1879
  contentContainerStyle: Y.optionsListContent,
1841
1880
  ListEmptyComponent: /* @__PURE__ */ P(H, {
1842
1881
  style: Y.emptyContainer,
1843
1882
  children: /* @__PURE__ */ P(B, {
1844
- style: [Y.emptyText, { color: L.textMuted }],
1845
- children: z("renderer.defaultHttpInput.noResults")
1883
+ style: [Y.emptyText, { color: I.textMuted }],
1884
+ children: R("renderer.defaultHttpInput.noResults")
1846
1885
  })
1847
1886
  }),
1848
1887
  renderItem: ({ item: t }) => {
1849
1888
  let n = t.value === e;
1850
1889
  return /* @__PURE__ */ F(V, {
1851
- style: [Y.option, n && { backgroundColor: L.primaryLight }],
1890
+ style: [Y.option, n && { backgroundColor: I.primaryLight }],
1852
1891
  onPress: () => {
1853
- T(t.value), b(!1);
1892
+ T(t.value), v(!1);
1854
1893
  },
1855
1894
  activeOpacity: .7,
1856
- children: [/* @__PURE__ */ P(me, {
1895
+ children: [/* @__PURE__ */ P(he, {
1857
1896
  label: t.label,
1858
1897
  description: t.description,
1859
1898
  image: t.image
1860
1899
  }), n && /* @__PURE__ */ P(B, {
1861
- style: [Y.checkmark, { color: L.primary }],
1900
+ style: [Y.checkmark, { color: I.primary }],
1862
1901
  children: "✓"
1863
1902
  })]
1864
1903
  });
@@ -1869,112 +1908,126 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1869
1908
  })
1870
1909
  }),
1871
1910
  E && /* @__PURE__ */ P(B, {
1872
- style: [Y.error, { color: L.error }],
1911
+ style: [Y.error, { color: I.error }],
1873
1912
  children: E
1874
1913
  }),
1875
- ee && !E && /* @__PURE__ */ P(B, {
1876
- style: [Y.helperText, { color: L.textMuted }],
1877
- children: ee
1914
+ O && !E && /* @__PURE__ */ P(B, {
1915
+ style: [Y.helperText, { color: I.textMuted }],
1916
+ children: O
1878
1917
  })
1879
1918
  ]
1880
1919
  });
1881
1920
  }
1882
- let n = i && R?.showLoading, r = O.length === 0 && f.length === 0 && !n ? u ?? z("renderer.defaultHttpInput.noDataAvailable") : void 0;
1921
+ let n = s && L?.showLoading, r = k.length === 0 && d.length === 0 && !n ? l ?? R("renderer.defaultHttpInput.noDataAvailable") : void 0;
1883
1922
  return /* @__PURE__ */ F(H, {
1884
1923
  style: Y.container,
1885
1924
  children: [
1886
1925
  /* @__PURE__ */ F(B, {
1887
- style: [Y.label, { color: L.textSecondary }],
1926
+ style: [Y.label, { color: I.textSecondary }],
1888
1927
  children: [D || w.data.name, w.data.required && /* @__PURE__ */ P(B, {
1889
- style: { color: L.error },
1928
+ style: { color: I.error },
1890
1929
  children: "*"
1891
1930
  })]
1892
1931
  }),
1893
- /* @__PURE__ */ P(Se, {
1894
- missing: O,
1932
+ /* @__PURE__ */ P(Ce, {
1933
+ missing: k,
1895
1934
  children: /* @__PURE__ */ F(V, {
1896
1935
  style: [
1897
1936
  Y.trigger,
1898
1937
  {
1899
- backgroundColor: L.input,
1900
- borderColor: L.border
1938
+ backgroundColor: I.input,
1939
+ borderColor: I.border
1901
1940
  },
1902
- E && { borderColor: L.error },
1903
- (n || f.length === 0) && { backgroundColor: L.muted }
1941
+ E && { borderColor: I.error },
1942
+ (n || d.length === 0) && { backgroundColor: I.muted }
1904
1943
  ],
1905
- onPress: () => b(!0),
1906
- disabled: n || f.length === 0,
1944
+ onPress: () => v(!0),
1945
+ disabled: n || d.length === 0,
1907
1946
  activeOpacity: .7,
1908
1947
  children: [
1909
- n && /* @__PURE__ */ P(re, {
1948
+ n && /* @__PURE__ */ P(ie, {
1910
1949
  size: "small",
1911
- color: L.primary,
1950
+ color: I.primary,
1912
1951
  style: Y.triggerLoader
1913
1952
  }),
1914
1953
  /* @__PURE__ */ P(B, {
1915
1954
  style: [
1916
1955
  Y.triggerText,
1917
- { color: L.text },
1918
- !t && { color: L.textMuted }
1956
+ { color: I.text },
1957
+ !t && { color: I.textMuted }
1919
1958
  ],
1920
1959
  numberOfLines: 1,
1921
- children: t?.label || C || z("renderer.defaultHttpInput.selectOption")
1960
+ children: t?.label || C || R("renderer.defaultHttpInput.selectOption")
1922
1961
  }),
1962
+ e ? /* @__PURE__ */ P(V, {
1963
+ onPress: () => T(""),
1964
+ hitSlop: {
1965
+ bottom: 8,
1966
+ left: 8,
1967
+ right: 8,
1968
+ top: 8
1969
+ },
1970
+ style: Y.clearButton,
1971
+ children: /* @__PURE__ */ P(B, {
1972
+ style: [Y.clearIcon, { color: I.textMuted }],
1973
+ children: "✕"
1974
+ })
1975
+ }) : null,
1923
1976
  /* @__PURE__ */ P(B, {
1924
- style: [Y.arrow, { color: L.textMuted }],
1977
+ style: [Y.arrow, { color: I.textMuted }],
1925
1978
  children: "▼"
1926
1979
  })
1927
1980
  ]
1928
1981
  })
1929
1982
  }),
1930
1983
  r && /* @__PURE__ */ P(B, {
1931
- style: [Y.disabledMessage, { color: L.error }],
1984
+ style: [Y.disabledMessage, { color: I.error }],
1932
1985
  children: r
1933
1986
  }),
1934
- /* @__PURE__ */ P(oe, {
1935
- visible: v,
1987
+ /* @__PURE__ */ P(se, {
1988
+ visible: g,
1936
1989
  transparent: !0,
1937
1990
  animationType: "fade",
1938
- onRequestClose: () => b(!1),
1991
+ onRequestClose: () => v(!1),
1939
1992
  children: /* @__PURE__ */ P(V, {
1940
1993
  style: Y.modalOverlay,
1941
1994
  activeOpacity: 1,
1942
- onPress: () => b(!1),
1995
+ onPress: () => v(!1),
1943
1996
  children: /* @__PURE__ */ F(V, {
1944
- style: [Y.modalContent, { backgroundColor: L.card }],
1997
+ style: [Y.modalContent, { backgroundColor: I.card }],
1945
1998
  activeOpacity: 1,
1946
1999
  onPress: () => {},
1947
2000
  children: [/* @__PURE__ */ F(H, {
1948
- style: [Y.modalHeader, { borderBottomColor: L.separator }],
2001
+ style: [Y.modalHeader, { borderBottomColor: I.separator }],
1949
2002
  children: [/* @__PURE__ */ P(B, {
1950
- style: [Y.modalTitle, { color: L.text }],
2003
+ style: [Y.modalTitle, { color: I.text }],
1951
2004
  children: D || w.data.name
1952
2005
  }), /* @__PURE__ */ P(V, {
1953
- onPress: () => b(!1),
2006
+ onPress: () => v(!1),
1954
2007
  children: /* @__PURE__ */ P(B, {
1955
- style: [Y.closeButton, { color: L.textMuted }],
2008
+ style: [Y.closeButton, { color: I.textMuted }],
1956
2009
  children: "✕"
1957
2010
  })
1958
2011
  })]
1959
- }), /* @__PURE__ */ P(ae, {
1960
- data: f,
2012
+ }), /* @__PURE__ */ P(oe, {
2013
+ data: d,
1961
2014
  keyExtractor: (e) => e.value,
1962
2015
  style: Y.optionsList,
1963
2016
  contentContainerStyle: Y.optionsListContent,
1964
2017
  renderItem: ({ item: t }) => {
1965
2018
  let n = t.value === e;
1966
2019
  return /* @__PURE__ */ F(V, {
1967
- style: [Y.option, n && { backgroundColor: L.primaryLight }],
2020
+ style: [Y.option, n && { backgroundColor: I.primaryLight }],
1968
2021
  onPress: () => {
1969
- T(t.value), b(!1);
2022
+ T(t.value), v(!1);
1970
2023
  },
1971
2024
  activeOpacity: .7,
1972
- children: [/* @__PURE__ */ P(me, {
2025
+ children: [/* @__PURE__ */ P(he, {
1973
2026
  label: t.label,
1974
2027
  description: t.description,
1975
2028
  image: t.image
1976
2029
  }), n && /* @__PURE__ */ P(B, {
1977
- style: [Y.checkmark, { color: L.primary }],
2030
+ style: [Y.checkmark, { color: I.primary }],
1978
2031
  children: "✓"
1979
2032
  })]
1980
2033
  });
@@ -1984,12 +2037,12 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1984
2037
  })
1985
2038
  }),
1986
2039
  E && /* @__PURE__ */ P(B, {
1987
- style: [Y.error, { color: L.error }],
2040
+ style: [Y.error, { color: I.error }],
1988
2041
  children: E
1989
2042
  }),
1990
- ee && !E && /* @__PURE__ */ P(B, {
1991
- style: [Y.helperText, { color: L.textMuted }],
1992
- children: ee
2043
+ O && !E && /* @__PURE__ */ P(B, {
2044
+ style: [Y.helperText, { color: I.textMuted }],
2045
+ children: O
1993
2046
  })
1994
2047
  ]
1995
2048
  });
@@ -1998,28 +2051,28 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
1998
2051
  style: Y.container,
1999
2052
  children: [
2000
2053
  /* @__PURE__ */ F(B, {
2001
- style: [Y.label, { color: L.textSecondary }],
2054
+ style: [Y.label, { color: I.textSecondary }],
2002
2055
  children: [D || w.data.name, w.data.required && /* @__PURE__ */ P(B, {
2003
- style: { color: L.error },
2056
+ style: { color: I.error },
2004
2057
  children: "*"
2005
2058
  })]
2006
2059
  }),
2007
- /* @__PURE__ */ P(ce, {
2060
+ /* @__PURE__ */ P(le, {
2008
2061
  style: [Y.input, {
2009
- backgroundColor: L.muted,
2010
- borderColor: L.border,
2011
- color: L.textMuted
2062
+ backgroundColor: I.muted,
2063
+ borderColor: I.border,
2064
+ color: I.textMuted
2012
2065
  }],
2013
2066
  value: typeof S == "string" ? S : JSON.stringify(S),
2014
2067
  editable: !1
2015
2068
  }),
2016
2069
  E && /* @__PURE__ */ P(B, {
2017
- style: [Y.error, { color: L.error }],
2070
+ style: [Y.error, { color: I.error }],
2018
2071
  children: E
2019
2072
  }),
2020
- ee && !E && /* @__PURE__ */ P(B, {
2021
- style: [Y.helperText, { color: L.textMuted }],
2022
- children: ee
2073
+ O && !E && /* @__PURE__ */ P(B, {
2074
+ style: [Y.helperText, { color: I.textMuted }],
2075
+ children: O
2023
2076
  })
2024
2077
  ]
2025
2078
  });
@@ -2029,6 +2082,11 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2029
2082
  fontSize: 18,
2030
2083
  fontWeight: "700"
2031
2084
  },
2085
+ clearButton: {
2086
+ marginRight: 8,
2087
+ paddingHorizontal: 2
2088
+ },
2089
+ clearIcon: { fontSize: 14 },
2032
2090
  closeButton: {
2033
2091
  fontSize: 24,
2034
2092
  fontWeight: "300"
@@ -2145,23 +2203,23 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2145
2203
  flex: 1,
2146
2204
  fontSize: 14
2147
2205
  }
2148
- }), Ne = ({ field: e, extra: t }) => {
2149
- let { value: n, placeholder: r, name: i } = e, [a, o] = N(n?.toString() ?? ""), { node: s, setValue: c, error: l, label: u, helperText: d } = t, { colors: f } = h();
2150
- return A(() => {
2206
+ }), Pe = ({ field: e, extra: t }) => {
2207
+ let { value: n, placeholder: r, name: i } = e, [a, o] = N(n?.toString() ?? ""), { node: s, setValue: c, error: l, label: u, helperText: d } = t, { colors: f } = m();
2208
+ return j(() => {
2151
2209
  o(n?.toString() ?? "");
2152
2210
  }, [n]), /* @__PURE__ */ F(H, {
2153
- style: Pe.container,
2211
+ style: Fe.container,
2154
2212
  children: [
2155
2213
  /* @__PURE__ */ F(B, {
2156
- style: [Pe.label, { color: f.textSecondary }],
2214
+ style: [Fe.label, { color: f.textSecondary }],
2157
2215
  children: [u || s.data.name, s.data.required && /* @__PURE__ */ P(B, {
2158
2216
  style: { color: f.error },
2159
2217
  children: "*"
2160
2218
  })]
2161
2219
  }),
2162
- /* @__PURE__ */ P(ce, {
2220
+ /* @__PURE__ */ P(le, {
2163
2221
  style: [
2164
- Pe.input,
2222
+ Fe.input,
2165
2223
  {
2166
2224
  backgroundColor: f.input,
2167
2225
  borderColor: f.border,
@@ -2184,16 +2242,16 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2184
2242
  accessibilityLabel: i
2185
2243
  }),
2186
2244
  l && /* @__PURE__ */ P(B, {
2187
- style: [Pe.error, { color: f.error }],
2245
+ style: [Fe.error, { color: f.error }],
2188
2246
  children: l
2189
2247
  }),
2190
2248
  d && !l && /* @__PURE__ */ P(B, {
2191
- style: [Pe.helperText, { color: f.textMuted }],
2249
+ style: [Fe.helperText, { color: f.textMuted }],
2192
2250
  children: d
2193
2251
  })
2194
2252
  ]
2195
2253
  });
2196
- }, Pe = z.create({
2254
+ }, Fe = z.create({
2197
2255
  container: { marginBottom: 16 },
2198
2256
  error: {
2199
2257
  fontSize: 12,
@@ -2215,23 +2273,23 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2215
2273
  fontWeight: "500",
2216
2274
  marginBottom: 8
2217
2275
  }
2218
- }), Fe = ({ field: e, extra: t }) => {
2219
- let [n, r] = N(!1), { value: i, placeholder: a, name: o } = e, { node: s, setValue: c, error: l, label: u, helperText: d } = t, { colors: f } = h();
2276
+ }), Ie = ({ field: e, extra: t }) => {
2277
+ let [n, r] = N(!1), { value: i, placeholder: a, name: o } = e, { node: s, setValue: c, error: l, label: u, helperText: d } = t, { colors: f } = m();
2220
2278
  return /* @__PURE__ */ F(H, {
2221
- style: Ie.container,
2279
+ style: Le.container,
2222
2280
  children: [
2223
2281
  /* @__PURE__ */ F(B, {
2224
- style: [Ie.label, { color: f.textSecondary }],
2282
+ style: [Le.label, { color: f.textSecondary }],
2225
2283
  children: [u || s.data.name, s.data.required && /* @__PURE__ */ P(B, {
2226
2284
  style: { color: f.error },
2227
2285
  children: "*"
2228
2286
  })]
2229
2287
  }),
2230
2288
  /* @__PURE__ */ F(H, {
2231
- style: Ie.inputWrapper,
2232
- children: [/* @__PURE__ */ P(ce, {
2289
+ style: Le.inputWrapper,
2290
+ children: [/* @__PURE__ */ P(le, {
2233
2291
  style: [
2234
- Ie.input,
2292
+ Le.input,
2235
2293
  {
2236
2294
  backgroundColor: f.input,
2237
2295
  borderColor: f.border,
@@ -2246,26 +2304,26 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2246
2304
  secureTextEntry: !n,
2247
2305
  accessibilityLabel: o
2248
2306
  }), /* @__PURE__ */ P(V, {
2249
- style: Ie.toggleButton,
2307
+ style: Le.toggleButton,
2250
2308
  onPress: () => r(!n),
2251
2309
  activeOpacity: .7,
2252
2310
  children: /* @__PURE__ */ P(B, {
2253
- style: [Ie.toggleText, { color: f.primary }],
2311
+ style: [Le.toggleText, { color: f.primary }],
2254
2312
  children: n ? "Hide" : "Show"
2255
2313
  })
2256
2314
  })]
2257
2315
  }),
2258
2316
  l && /* @__PURE__ */ P(B, {
2259
- style: [Ie.error, { color: f.error }],
2317
+ style: [Le.error, { color: f.error }],
2260
2318
  children: l
2261
2319
  }),
2262
2320
  d && !l && /* @__PURE__ */ P(B, {
2263
- style: [Ie.helperText, { color: f.textMuted }],
2321
+ style: [Le.helperText, { color: f.textMuted }],
2264
2322
  children: d
2265
2323
  })
2266
2324
  ]
2267
2325
  });
2268
- }, Ie = z.create({
2326
+ }, Le = z.create({
2269
2327
  container: { marginBottom: 16 },
2270
2328
  error: {
2271
2329
  fontSize: 12,
@@ -2303,16 +2361,16 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2303
2361
  fontSize: 12,
2304
2362
  fontWeight: "600"
2305
2363
  }
2306
- }), Le = ({ field: e, extra: n }) => {
2307
- let { value: r } = e, { node: i, setValue: a, error: o, label: s, helperText: c } = n, { colors: l } = h(), u = t(), d = i.data.options || [], f = r || "", p = i.data.variant !== "default", m = (e) => {
2308
- a(e);
2364
+ }), Re = ({ field: e, extra: t }) => {
2365
+ let { value: n } = e, { node: r, setValue: i, error: o, label: s, helperText: c } = t, { colors: l } = m(), u = a(), d = r.data.options || [], f = n || "", p = r.data.variant !== "default", h = (e) => {
2366
+ i(e);
2309
2367
  };
2310
2368
  return /* @__PURE__ */ F(H, {
2311
2369
  style: X.container,
2312
2370
  children: [
2313
2371
  /* @__PURE__ */ F(B, {
2314
2372
  style: [X.label, { color: l.textSecondary }],
2315
- children: [s || i.data.name, i.data.required && /* @__PURE__ */ P(B, {
2373
+ children: [s || r.data.name, r.data.required && /* @__PURE__ */ P(B, {
2316
2374
  style: { color: l.error },
2317
2375
  children: "*"
2318
2376
  })]
@@ -2332,7 +2390,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2332
2390
  },
2333
2391
  e.disabled && { opacity: .5 }
2334
2392
  ],
2335
- onPress: () => m(e.value),
2393
+ onPress: () => h(e.value),
2336
2394
  disabled: e.disabled,
2337
2395
  activeOpacity: .7,
2338
2396
  children: [
@@ -2365,7 +2423,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2365
2423
  ]
2366
2424
  }, e.value) : /* @__PURE__ */ F(V, {
2367
2425
  style: X.option,
2368
- onPress: () => m(e.value),
2426
+ onPress: () => h(e.value),
2369
2427
  disabled: e.disabled,
2370
2428
  activeOpacity: .7,
2371
2429
  children: [
@@ -2484,9 +2542,9 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2484
2542
  height: 10,
2485
2543
  width: 10
2486
2544
  }
2487
- }), Re = ({ field: e, extra: n }) => {
2488
- let [r, i] = N(!1), { value: a, placeholder: o } = e, { node: s, setValue: c, error: l, label: u, helperText: d } = n, { colors: f } = h(), p = t(), m = s.data.options || [], g = s.data.multiple, _ = Array.isArray(a) ? a : a ? [a] : [], v = (e) => {
2489
- g ? c(_.includes(e) ? _.filter((t) => t !== e) : [..._, e]) : (c(e), i(!1));
2545
+ }), ze = ({ field: e, extra: t }) => {
2546
+ let [n, r] = N(!1), { value: i, placeholder: o } = e, { node: s, setValue: c, error: l, label: u, helperText: d } = t, { colors: f } = m(), p = a(), h = s.data.options || [], g = s.data.multiple, _ = Array.isArray(i) ? i : i ? [i] : [], v = (e) => {
2547
+ g ? c(_.includes(e) ? _.filter((t) => t !== e) : [..._, e]) : (c(e), r(!1));
2490
2548
  };
2491
2549
  return /* @__PURE__ */ F(H, {
2492
2550
  style: Z.container,
@@ -2507,34 +2565,51 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2507
2565
  },
2508
2566
  l && { borderColor: f.error }
2509
2567
  ],
2510
- onPress: () => i(!0),
2568
+ onPress: () => r(!0),
2511
2569
  activeOpacity: .7,
2512
- children: [/* @__PURE__ */ P(B, {
2513
- style: [
2514
- Z.triggerText,
2515
- { color: f.text },
2516
- _.length === 0 && { color: f.textMuted }
2517
- ],
2518
- children: (() => {
2519
- if (_.length === 0) return o || "Select...";
2520
- if (g) return m.filter((e) => _.includes(e.value)).map((e) => p(e.label) || e.value).join(", ");
2521
- let e = m.find((e) => e.value === _[0]);
2522
- return e ? p(e.label) || e.value : o || "Select...";
2523
- })()
2524
- }), /* @__PURE__ */ P(B, {
2525
- style: [Z.arrow, { color: f.textMuted }],
2526
- children: "▼"
2527
- })]
2570
+ children: [
2571
+ /* @__PURE__ */ P(B, {
2572
+ style: [
2573
+ Z.triggerText,
2574
+ { color: f.text },
2575
+ _.length === 0 && { color: f.textMuted }
2576
+ ],
2577
+ children: (() => {
2578
+ if (_.length === 0) return o || "Select...";
2579
+ if (g) return h.filter((e) => _.includes(e.value)).map((e) => p(e.label) || e.value).join(", ");
2580
+ let e = h.find((e) => e.value === _[0]);
2581
+ return e ? p(e.label) || e.value : o || "Select...";
2582
+ })()
2583
+ }),
2584
+ _.length > 0 && /* @__PURE__ */ P(V, {
2585
+ onPress: () => c(g ? [] : ""),
2586
+ hitSlop: {
2587
+ bottom: 8,
2588
+ left: 8,
2589
+ right: 8,
2590
+ top: 8
2591
+ },
2592
+ style: Z.clearButton,
2593
+ children: /* @__PURE__ */ P(B, {
2594
+ style: [Z.clearIcon, { color: f.textMuted }],
2595
+ children: "✕"
2596
+ })
2597
+ }),
2598
+ /* @__PURE__ */ P(B, {
2599
+ style: [Z.arrow, { color: f.textMuted }],
2600
+ children: "▼"
2601
+ })
2602
+ ]
2528
2603
  }),
2529
- /* @__PURE__ */ P(oe, {
2530
- visible: r,
2604
+ /* @__PURE__ */ P(se, {
2605
+ visible: n,
2531
2606
  transparent: !0,
2532
2607
  animationType: "fade",
2533
- onRequestClose: () => i(!1),
2608
+ onRequestClose: () => r(!1),
2534
2609
  children: /* @__PURE__ */ P(V, {
2535
2610
  style: Z.modalOverlay,
2536
2611
  activeOpacity: 1,
2537
- onPress: () => i(!1),
2612
+ onPress: () => r(!1),
2538
2613
  children: /* @__PURE__ */ F(H, {
2539
2614
  style: [Z.modalContent, { backgroundColor: f.card }],
2540
2615
  onStartShouldSetResponder: () => !0,
@@ -2545,7 +2620,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2545
2620
  style: [Z.modalTitle, { color: f.text }],
2546
2621
  children: u || s.data.name
2547
2622
  }), /* @__PURE__ */ P(V, {
2548
- onPress: () => i(!1),
2623
+ onPress: () => r(!1),
2549
2624
  children: /* @__PURE__ */ P(B, {
2550
2625
  style: [Z.closeButton, { color: f.textMuted }],
2551
2626
  children: "✕"
@@ -2554,14 +2629,14 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2554
2629
  }),
2555
2630
  /* @__PURE__ */ P(R, {
2556
2631
  style: Z.optionsList,
2557
- children: m.map((e) => {
2632
+ children: h.map((e) => {
2558
2633
  let t = _.includes(e.value);
2559
2634
  return /* @__PURE__ */ F(V, {
2560
2635
  style: [Z.option, t && { backgroundColor: `${f.primary}20` }],
2561
2636
  onPress: () => v(e.value),
2562
2637
  disabled: e.disabled,
2563
2638
  activeOpacity: .7,
2564
- children: [/* @__PURE__ */ P(me, {
2639
+ children: [/* @__PURE__ */ P(he, {
2565
2640
  label: p(e.label) || e.value,
2566
2641
  description: p(e.description),
2567
2642
  image: e.image,
@@ -2575,7 +2650,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2575
2650
  }),
2576
2651
  g && /* @__PURE__ */ P(V, {
2577
2652
  style: [Z.doneButton, { backgroundColor: f.primary }],
2578
- onPress: () => i(!1),
2653
+ onPress: () => r(!1),
2579
2654
  children: /* @__PURE__ */ P(B, {
2580
2655
  style: Z.doneButtonText,
2581
2656
  children: "Done"
@@ -2601,6 +2676,11 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2601
2676
  fontSize: 18,
2602
2677
  fontWeight: "700"
2603
2678
  },
2679
+ clearButton: {
2680
+ marginRight: 8,
2681
+ paddingHorizontal: 2
2682
+ },
2683
+ clearIcon: { fontSize: 14 },
2604
2684
  closeButton: {
2605
2685
  fontSize: 24,
2606
2686
  fontWeight: "300"
@@ -2676,23 +2756,23 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2676
2756
  flex: 1,
2677
2757
  fontSize: 14
2678
2758
  }
2679
- }), ze = (e) => null, Be = ({ field: e, extra: t }) => {
2680
- let { value: n } = e, { node: r, setValue: i, error: a, label: o, helperText: s } = t, { colors: c } = h(), l = !!n;
2759
+ }), Be = (e) => null, Ve = ({ field: e, extra: t }) => {
2760
+ let { value: n } = e, { node: r, setValue: i, error: a, label: o, helperText: s } = t, { colors: c } = m(), l = !!n;
2681
2761
  return /* @__PURE__ */ F(H, {
2682
- style: Ve.container,
2762
+ style: He.container,
2683
2763
  children: [
2684
2764
  /* @__PURE__ */ F(H, {
2685
- style: Ve.row,
2765
+ style: He.row,
2686
2766
  children: [/* @__PURE__ */ P(H, {
2687
- style: Ve.labelContainer,
2767
+ style: He.labelContainer,
2688
2768
  children: /* @__PURE__ */ F(B, {
2689
- style: [Ve.label, { color: c.textSecondary }],
2769
+ style: [He.label, { color: c.textSecondary }],
2690
2770
  children: [o || r.data.name, r.data.required && /* @__PURE__ */ P(B, {
2691
2771
  style: { color: c.error },
2692
2772
  children: "*"
2693
2773
  })]
2694
2774
  })
2695
- }), /* @__PURE__ */ P(se, {
2775
+ }), /* @__PURE__ */ P(ce, {
2696
2776
  trackColor: {
2697
2777
  false: c.border,
2698
2778
  true: `${c.primary}80`
@@ -2704,16 +2784,16 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2704
2784
  })]
2705
2785
  }),
2706
2786
  a && /* @__PURE__ */ P(B, {
2707
- style: [Ve.error, { color: c.error }],
2787
+ style: [He.error, { color: c.error }],
2708
2788
  children: a
2709
2789
  }),
2710
2790
  s && !a && /* @__PURE__ */ P(B, {
2711
- style: [Ve.helperText, { color: c.textMuted }],
2791
+ style: [He.helperText, { color: c.textMuted }],
2712
2792
  children: s
2713
2793
  })
2714
2794
  ]
2715
2795
  });
2716
- }, Ve = z.create({
2796
+ }, He = z.create({
2717
2797
  container: { marginBottom: 16 },
2718
2798
  error: {
2719
2799
  fontSize: 12,
@@ -2733,21 +2813,21 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2733
2813
  flexDirection: "row",
2734
2814
  justifyContent: "space-between"
2735
2815
  }
2736
- }), He = ({ field: e, extra: t }) => {
2737
- let { value: n, placeholder: r, name: i } = e, { node: a, setValue: o, error: s, label: c, helperText: l } = t, { colors: u } = h();
2816
+ }), Ue = ({ field: e, extra: t }) => {
2817
+ let { value: n, placeholder: r, name: i } = e, { node: a, setValue: o, error: s, label: c, helperText: l } = t, { colors: u } = m();
2738
2818
  return /* @__PURE__ */ F(H, {
2739
- style: Ue.container,
2819
+ style: We.container,
2740
2820
  children: [
2741
2821
  /* @__PURE__ */ F(B, {
2742
- style: [Ue.label, { color: u.textSecondary }],
2822
+ style: [We.label, { color: u.textSecondary }],
2743
2823
  children: [c || a.data.name, a.data.required && /* @__PURE__ */ P(B, {
2744
2824
  style: { color: u.error },
2745
2825
  children: "*"
2746
2826
  })]
2747
2827
  }),
2748
- /* @__PURE__ */ P(ce, {
2828
+ /* @__PURE__ */ P(le, {
2749
2829
  style: [
2750
- Ue.textarea,
2830
+ We.textarea,
2751
2831
  {
2752
2832
  backgroundColor: u.input,
2753
2833
  borderColor: u.border,
@@ -2765,16 +2845,16 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2765
2845
  accessibilityLabel: i
2766
2846
  }),
2767
2847
  s && /* @__PURE__ */ P(B, {
2768
- style: [Ue.error, { color: u.error }],
2848
+ style: [We.error, { color: u.error }],
2769
2849
  children: s
2770
2850
  }),
2771
2851
  l && !s && /* @__PURE__ */ P(B, {
2772
- style: [Ue.helperText, { color: u.textMuted }],
2852
+ style: [We.helperText, { color: u.textMuted }],
2773
2853
  children: l
2774
2854
  })
2775
2855
  ]
2776
2856
  });
2777
- }, Ue = z.create({
2857
+ }, We = z.create({
2778
2858
  container: { marginBottom: 16 },
2779
2859
  error: {
2780
2860
  fontSize: 12,
@@ -2797,21 +2877,21 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2797
2877
  paddingHorizontal: 12,
2798
2878
  paddingVertical: 8
2799
2879
  }
2800
- }), We = ({ field: e, extra: t }) => {
2801
- let { value: n, placeholder: r, name: i } = e, { node: a, setValue: o, error: s, label: c, helperText: l } = t, { colors: u } = h();
2880
+ }), Ge = ({ field: e, extra: t }) => {
2881
+ let { value: n, placeholder: r, name: i } = e, { node: a, setValue: o, error: s, label: c, helperText: l } = t, { colors: u } = m();
2802
2882
  return /* @__PURE__ */ F(H, {
2803
- style: Ge.container,
2883
+ style: Ke.container,
2804
2884
  children: [
2805
2885
  /* @__PURE__ */ F(B, {
2806
- style: [Ge.label, { color: u.textSecondary }],
2886
+ style: [Ke.label, { color: u.textSecondary }],
2807
2887
  children: [c || a.data.name, a.data.required && /* @__PURE__ */ P(B, {
2808
2888
  style: { color: u.error },
2809
2889
  children: "*"
2810
2890
  })]
2811
2891
  }),
2812
- /* @__PURE__ */ P(ce, {
2892
+ /* @__PURE__ */ P(le, {
2813
2893
  style: [
2814
- Ge.input,
2894
+ Ke.input,
2815
2895
  {
2816
2896
  backgroundColor: u.input,
2817
2897
  borderColor: u.border,
@@ -2826,16 +2906,16 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2826
2906
  accessibilityLabel: i
2827
2907
  }),
2828
2908
  s && /* @__PURE__ */ P(B, {
2829
- style: [Ge.error, { color: u.error }],
2909
+ style: [Ke.error, { color: u.error }],
2830
2910
  children: s
2831
2911
  }),
2832
2912
  l && !s && /* @__PURE__ */ P(B, {
2833
- style: [Ge.helperText, { color: u.textMuted }],
2913
+ style: [Ke.helperText, { color: u.textMuted }],
2834
2914
  children: l
2835
2915
  })
2836
2916
  ]
2837
2917
  });
2838
- }, Ge = z.create({
2918
+ }, Ke = z.create({
2839
2919
  container: { marginBottom: 16 },
2840
2920
  error: {
2841
2921
  fontSize: 12,
@@ -2857,9 +2937,9 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2857
2937
  fontWeight: "500",
2858
2938
  marginBottom: 8
2859
2939
  }
2860
- }), Ke = ({ field: e, extra: t }) => {
2861
- let { value: n, placeholder: r } = e, i = (n || "").split(":"), a = Number.parseInt(i[0], 10), o = Number.parseInt(i[1], 10), s = Number.isNaN(a) ? 0 : a, c = Number.isNaN(o) ? 0 : o, [l, u] = N(s || 0), [d, f] = N(c || 0), [p, m] = N(!1), { node: g, setValue: _, error: v, label: y, helperText: b } = t, { colors: x } = h(), S = M(null), C = M(null), w = Array.from({ length: 24 }, (e, t) => t), T = Array.from({ length: 60 }, (e, t) => t), E = () => n || r || "Select time", D = te(() => {
2862
- _(`${String(l).padStart(2, "0")}:${String(d).padStart(2, "0")}`), m(!1);
2940
+ }), qe = ({ field: e, extra: t }) => {
2941
+ let { value: n, placeholder: r } = e, i = (n || "").split(":"), a = Number.parseInt(i[0], 10), o = Number.parseInt(i[1], 10), s = Number.isNaN(a) ? 0 : a, c = Number.isNaN(o) ? 0 : o, [l, u] = N(s || 0), [d, f] = N(c || 0), [p, h] = N(!1), { node: g, setValue: _, error: v, label: y, helperText: b } = t, { colors: x } = m(), S = M(null), C = M(null), w = Array.from({ length: 24 }, (e, t) => t), T = Array.from({ length: 60 }, (e, t) => t), E = () => n || r || "Select time", D = te(() => {
2942
+ _(`${String(l).padStart(2, "0")}:${String(d).padStart(2, "0")}`), h(!1);
2863
2943
  }, [
2864
2944
  l,
2865
2945
  d,
@@ -2885,7 +2965,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2885
2965
  v && { borderColor: x.error }
2886
2966
  ],
2887
2967
  onPress: () => {
2888
- u(s || 0), f(c || 0), m(!0);
2968
+ u(s || 0), f(c || 0), h(!0);
2889
2969
  },
2890
2970
  activeOpacity: .7,
2891
2971
  children: [/* @__PURE__ */ P(B, {
@@ -2901,15 +2981,15 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2901
2981
  children: "🕐"
2902
2982
  })]
2903
2983
  }),
2904
- /* @__PURE__ */ P(oe, {
2984
+ /* @__PURE__ */ P(se, {
2905
2985
  visible: p,
2906
2986
  transparent: !0,
2907
2987
  animationType: "fade",
2908
- onRequestClose: () => m(!1),
2988
+ onRequestClose: () => h(!1),
2909
2989
  children: /* @__PURE__ */ P(V, {
2910
2990
  style: Q.modalOverlay,
2911
2991
  activeOpacity: 1,
2912
- onPress: () => m(!1),
2992
+ onPress: () => h(!1),
2913
2993
  children: /* @__PURE__ */ F(V, {
2914
2994
  style: [Q.modalContent, { backgroundColor: x.card }],
2915
2995
  activeOpacity: 1,
@@ -2921,7 +3001,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
2921
3001
  style: [Q.modalTitle, { color: x.text }],
2922
3002
  children: y || g.data.name
2923
3003
  }), /* @__PURE__ */ P(V, {
2924
- onPress: () => m(!1),
3004
+ onPress: () => h(!1),
2925
3005
  children: /* @__PURE__ */ P(B, {
2926
3006
  style: [Q.closeButton, { color: x.textMuted }],
2927
3007
  children: "✕"
@@ -3107,18 +3187,18 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3107
3187
  flex: 1,
3108
3188
  fontSize: 14
3109
3189
  }
3110
- }), qe = ({ field: e, extra: n }) => {
3111
- let [r, i] = N(!1), [a, o] = N(!0), { value: s } = e, { node: c, setValue: l, error: u, label: d, helperText: f } = n, { colors: p } = h(), m = t(), g = Array.isArray(s) ? s : [], _ = g[0] || "", v = g[1] || "", y = _.split(":"), b = Number.parseInt(y[0], 10), x = Number.parseInt(y[1], 10), S = Number.isNaN(b) ? 0 : b, C = Number.isNaN(x) ? 0 : x, w = v.split(":"), T = Number.parseInt(w[0], 10), E = Number.parseInt(w[1], 10), D = Number.isNaN(T) ? 0 : T, ee = Number.isNaN(E) ? 0 : E, [O, k] = N(0), [A, j] = N(0), M = Array.from({ length: 24 }, (e, t) => t), ne = Array.from({ length: 60 }, (e, t) => t), re = () => _ && v ? `${_} - ${v}` : _ || m("renderer.defaultInputs.selectDateRange"), ie = te(() => {
3112
- let e = `${String(O).padStart(2, "0")}:${String(A).padStart(2, "0")}`;
3113
- a ? (l([e, v]), o(!1), k(D || 0), j(ee || 0)) : (l([_, e]), i(!1), o(!0));
3190
+ }), Je = ({ field: e, extra: t }) => {
3191
+ let [n, r] = N(!1), [i, o] = N(!0), { value: s } = e, { node: c, setValue: l, error: u, label: d, helperText: f } = t, { colors: p } = m(), h = a(), g = Array.isArray(s) ? s : [], _ = g[0] || "", v = g[1] || "", y = _.split(":"), b = Number.parseInt(y[0], 10), x = Number.parseInt(y[1], 10), S = Number.isNaN(b) ? 0 : b, C = Number.isNaN(x) ? 0 : x, w = v.split(":"), T = Number.parseInt(w[0], 10), E = Number.parseInt(w[1], 10), D = Number.isNaN(T) ? 0 : T, O = Number.isNaN(E) ? 0 : E, [k, A] = N(0), [ee, j] = N(0), ne = Array.from({ length: 24 }, (e, t) => t), M = Array.from({ length: 60 }, (e, t) => t), re = () => _ && v ? `${_} - ${v}` : _ || h("renderer.defaultInputs.selectDateRange"), ie = te(() => {
3192
+ let e = `${String(k).padStart(2, "0")}:${String(ee).padStart(2, "0")}`;
3193
+ i ? (l([e, v]), o(!1), A(D || 0), j(O || 0)) : (l([_, e]), r(!1), o(!0));
3114
3194
  }, [
3115
- a,
3116
- O,
3117
- A,
3195
+ i,
3196
+ k,
3197
+ ee,
3118
3198
  _,
3119
3199
  v,
3120
3200
  D,
3121
- ee,
3201
+ O,
3122
3202
  l
3123
3203
  ]);
3124
3204
  return /* @__PURE__ */ F(H, {
@@ -3141,7 +3221,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3141
3221
  u && { borderColor: p.error }
3142
3222
  ],
3143
3223
  onPress: () => {
3144
- k(S || 0), j(C || 0), o(!0), i(!0);
3224
+ A(S || 0), j(C || 0), o(!0), r(!0);
3145
3225
  },
3146
3226
  activeOpacity: .7,
3147
3227
  children: [/* @__PURE__ */ P(B, {
@@ -3157,15 +3237,15 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3157
3237
  children: "🕐"
3158
3238
  })]
3159
3239
  }),
3160
- /* @__PURE__ */ P(oe, {
3161
- visible: r,
3240
+ /* @__PURE__ */ P(se, {
3241
+ visible: n,
3162
3242
  transparent: !0,
3163
3243
  animationType: "fade",
3164
- onRequestClose: () => i(!1),
3244
+ onRequestClose: () => r(!1),
3165
3245
  children: /* @__PURE__ */ P(V, {
3166
3246
  style: $.modalOverlay,
3167
3247
  activeOpacity: 1,
3168
- onPress: () => i(!1),
3248
+ onPress: () => r(!1),
3169
3249
  children: /* @__PURE__ */ F(V, {
3170
3250
  style: [$.modalContent, { backgroundColor: p.card }],
3171
3251
  activeOpacity: 1,
@@ -3177,7 +3257,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3177
3257
  style: [$.modalTitle, { color: p.text }],
3178
3258
  children: d || c.data.name
3179
3259
  }), /* @__PURE__ */ P(V, {
3180
- onPress: () => i(!1),
3260
+ onPress: () => r(!1),
3181
3261
  children: /* @__PURE__ */ P(B, {
3182
3262
  style: [$.closeButton, { color: p.textMuted }],
3183
3263
  children: "✕"
@@ -3188,7 +3268,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3188
3268
  style: [$.rangeIndicator, { backgroundColor: p.primaryLight }],
3189
3269
  children: /* @__PURE__ */ P(B, {
3190
3270
  style: [$.rangeIndicatorText, { color: p.primary }],
3191
- children: m(a ? "renderer.defaultInputs.startTime" : "renderer.defaultInputs.endTime")
3271
+ children: h(i ? "renderer.defaultInputs.startTime" : "renderer.defaultInputs.endTime")
3192
3272
  })
3193
3273
  }),
3194
3274
  /* @__PURE__ */ F(H, {
@@ -3203,15 +3283,15 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3203
3283
  style: $.picker,
3204
3284
  contentContainerStyle: $.pickerContent,
3205
3285
  showsVerticalScrollIndicator: !1,
3206
- children: M.map((e) => /* @__PURE__ */ P(V, {
3207
- style: [$.pickerItem, O === e && { backgroundColor: p.primary }],
3208
- onPress: () => k(e),
3286
+ children: ne.map((e) => /* @__PURE__ */ P(V, {
3287
+ style: [$.pickerItem, k === e && { backgroundColor: p.primary }],
3288
+ onPress: () => A(e),
3209
3289
  activeOpacity: .7,
3210
3290
  children: /* @__PURE__ */ P(B, {
3211
3291
  style: [
3212
3292
  $.pickerItemText,
3213
3293
  { color: p.text },
3214
- O === e && {
3294
+ k === e && {
3215
3295
  color: p.background,
3216
3296
  fontWeight: "600"
3217
3297
  }
@@ -3234,15 +3314,15 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3234
3314
  style: $.picker,
3235
3315
  contentContainerStyle: $.pickerContent,
3236
3316
  showsVerticalScrollIndicator: !1,
3237
- children: ne.map((e) => /* @__PURE__ */ P(V, {
3238
- style: [$.pickerItem, A === e && { backgroundColor: p.primary }],
3317
+ children: M.map((e) => /* @__PURE__ */ P(V, {
3318
+ style: [$.pickerItem, ee === e && { backgroundColor: p.primary }],
3239
3319
  onPress: () => j(e),
3240
3320
  activeOpacity: .7,
3241
3321
  children: /* @__PURE__ */ P(B, {
3242
3322
  style: [
3243
3323
  $.pickerItemText,
3244
3324
  { color: p.text },
3245
- A === e && {
3325
+ ee === e && {
3246
3326
  color: p.background,
3247
3327
  fontWeight: "600"
3248
3328
  }
@@ -3260,7 +3340,7 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3260
3340
  activeOpacity: .7,
3261
3341
  children: /* @__PURE__ */ P(B, {
3262
3342
  style: [$.confirmButtonText, { color: p.background }],
3263
- children: a ? "Next" : "Confirm"
3343
+ children: i ? "Next" : "Confirm"
3264
3344
  })
3265
3345
  })
3266
3346
  ]
@@ -3378,71 +3458,71 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3378
3458
  flex: 1,
3379
3459
  fontSize: 14
3380
3460
  }
3381
- }), Je = {
3382
- address: pe,
3383
- autocomplete: ge,
3384
- checkbox: _e,
3385
- date: ve,
3386
- daterange: ye,
3387
- file: be,
3388
- hidden: xe,
3389
- http: Me,
3390
- number: Ne,
3391
- password: Fe,
3392
- radio: Le,
3393
- select: Re,
3394
- submit: ze,
3395
- switch: Be,
3396
- text: We,
3397
- textarea: He,
3398
- time: Ke,
3399
- timerange: qe
3400
- }, Ye = ({ step: e, label: n, children: r, canGoBack: a, isLastStep: o, canContinue: s, isSubmitting: c, onBack: l, onContinue: u }) => {
3401
- let { colors: d } = h(), f = t(), p = !s || c, m = e.nodes.find((e) => i(e) && e.data.type === "submit"), g = m && i(m) ? f(m.data.label) : void 0, _ = o ? g || f("renderer.defaultSubmitButton.submit") : f("renderer.step.continue");
3461
+ }), Ye = {
3462
+ address: me,
3463
+ autocomplete: _e,
3464
+ checkbox: ve,
3465
+ date: ye,
3466
+ daterange: be,
3467
+ file: xe,
3468
+ hidden: Se,
3469
+ http: Ne,
3470
+ number: Pe,
3471
+ password: Ie,
3472
+ radio: Re,
3473
+ select: ze,
3474
+ submit: Be,
3475
+ switch: Ve,
3476
+ text: Ge,
3477
+ textarea: Ue,
3478
+ time: qe,
3479
+ timerange: Je
3480
+ }, Xe = ({ step: e, label: t, children: n, canGoBack: r, isLastStep: i, canContinue: o, isSubmitting: s, onBack: c, onContinue: l }) => {
3481
+ let { colors: u } = m(), d = a(), f = !o || s, p = e.nodes.find((e) => S(e) && e.data.type === "submit"), h = p && S(p) ? d(p.data.label) : void 0, g = i ? h || d("renderer.defaultSubmitButton.submit") : d("renderer.step.continue");
3402
3482
  return /* @__PURE__ */ F(H, { children: [
3403
- n ? /* @__PURE__ */ P(B, {
3404
- style: [Xe.label, { color: d.text }],
3405
- children: n
3483
+ t ? /* @__PURE__ */ P(B, {
3484
+ style: [Ze.label, { color: u.text }],
3485
+ children: t
3406
3486
  }) : null,
3407
3487
  /* @__PURE__ */ P(H, {
3408
- style: Xe.content,
3409
- children: r
3488
+ style: Ze.content,
3489
+ children: n
3410
3490
  }),
3411
3491
  /* @__PURE__ */ F(H, {
3412
- style: Xe.actions,
3413
- children: [a ? /* @__PURE__ */ P(V, {
3492
+ style: Ze.actions,
3493
+ children: [r ? /* @__PURE__ */ P(V, {
3414
3494
  style: [
3415
- Xe.backButton,
3416
- { borderColor: d.border },
3417
- c && Xe.disabled
3495
+ Ze.backButton,
3496
+ { borderColor: u.border },
3497
+ s && Ze.disabled
3418
3498
  ],
3419
- onPress: l,
3420
- disabled: c,
3499
+ onPress: c,
3500
+ disabled: s,
3421
3501
  activeOpacity: .7,
3422
3502
  children: /* @__PURE__ */ P(B, {
3423
- style: [Xe.backButtonText, { color: d.text }],
3424
- children: f("renderer.step.back")
3503
+ style: [Ze.backButtonText, { color: u.text }],
3504
+ children: d("renderer.step.back")
3425
3505
  })
3426
3506
  }) : /* @__PURE__ */ P(H, {}), /* @__PURE__ */ P(V, {
3427
3507
  style: [
3428
- Xe.continueButton,
3429
- { backgroundColor: d.primary },
3430
- p && {
3431
- backgroundColor: d.primaryDisabled,
3508
+ Ze.continueButton,
3509
+ { backgroundColor: u.primary },
3510
+ f && {
3511
+ backgroundColor: u.primaryDisabled,
3432
3512
  opacity: .6
3433
3513
  }
3434
3514
  ],
3435
- onPress: u,
3436
- disabled: p,
3515
+ onPress: l,
3516
+ disabled: f,
3437
3517
  activeOpacity: .7,
3438
- children: c ? /* @__PURE__ */ P(re, { color: d.primaryForeground }) : /* @__PURE__ */ P(B, {
3439
- style: [Xe.continueButtonText, { color: d.primaryForeground }],
3440
- children: _
3518
+ children: s ? /* @__PURE__ */ P(ie, { color: u.primaryForeground }) : /* @__PURE__ */ P(B, {
3519
+ style: [Ze.continueButtonText, { color: u.primaryForeground }],
3520
+ children: g
3441
3521
  })
3442
3522
  })]
3443
3523
  })
3444
3524
  ] });
3445
- }, Xe = z.create({
3525
+ }, Ze = z.create({
3446
3526
  actions: {
3447
3527
  alignItems: "center",
3448
3528
  flexDirection: "row",
@@ -3477,11 +3557,11 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3477
3557
  fontWeight: "600",
3478
3558
  marginBottom: 12
3479
3559
  }
3480
- }), Ze = ({ children: e = "Submit", disabled: t, isSubmitting: n, onPress: r }) => {
3481
- let { colors: i } = h();
3560
+ }), Qe = ({ children: e = "Submit", disabled: t, isSubmitting: n, onPress: r }) => {
3561
+ let { colors: i } = m();
3482
3562
  return /* @__PURE__ */ P(V, {
3483
3563
  style: [
3484
- Qe.button,
3564
+ $e.button,
3485
3565
  { backgroundColor: i.primary },
3486
3566
  (t || n) && {
3487
3567
  backgroundColor: i.primaryDisabled,
@@ -3491,12 +3571,12 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3491
3571
  disabled: t || n,
3492
3572
  onPress: r,
3493
3573
  activeOpacity: .7,
3494
- children: n ? /* @__PURE__ */ P(re, { color: i.primaryForeground }) : /* @__PURE__ */ P(B, {
3495
- style: [Qe.buttonText, { color: i.primaryForeground }],
3574
+ children: n ? /* @__PURE__ */ P(ie, { color: i.primaryForeground }) : /* @__PURE__ */ P(B, {
3575
+ style: [$e.buttonText, { color: i.primaryForeground }],
3496
3576
  children: e
3497
3577
  })
3498
3578
  });
3499
- }, Qe = z.create({
3579
+ }, $e = z.create({
3500
3580
  button: {
3501
3581
  alignItems: "center",
3502
3582
  borderRadius: 6,
@@ -3509,16 +3589,16 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3509
3589
  fontSize: 16,
3510
3590
  fontWeight: "600"
3511
3591
  }
3512
- }), $e = ({ children: e }) => e, et = ({ node: e }) => {
3513
- let n = t(), { colors: r } = h(), i = n(e.data?.label);
3592
+ }), et = ({ children: e }) => e, tt = ({ node: e }) => {
3593
+ let t = a(), { colors: n } = m(), r = t(e.data?.label);
3514
3594
  return /* @__PURE__ */ P(B, {
3515
- style: [nt.title, { color: r.text }],
3516
- children: i
3595
+ style: [rt.title, { color: n.text }],
3596
+ children: r
3517
3597
  });
3518
- }, tt = () => {
3519
- let { colors: e } = h();
3520
- return /* @__PURE__ */ P(H, { style: [nt.divider, { backgroundColor: e.separator }] });
3521
- }, nt = z.create({
3598
+ }, nt = () => {
3599
+ let { colors: e } = m();
3600
+ return /* @__PURE__ */ P(H, { style: [rt.divider, { backgroundColor: e.separator }] });
3601
+ }, rt = z.create({
3522
3602
  divider: {
3523
3603
  height: 1,
3524
3604
  marginBottom: 16,
@@ -3529,24 +3609,24 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3529
3609
  fontWeight: "700",
3530
3610
  marginBottom: 16
3531
3611
  }
3532
- }), rt = {
3533
- divider: tt,
3534
- title: et
3535
- }, it = ({ node: e, children: t }) => {
3612
+ }), it = {
3613
+ divider: nt,
3614
+ title: tt
3615
+ }, at = ({ node: e, children: t }) => {
3536
3616
  let { image: n } = e.data;
3537
3617
  return /* @__PURE__ */ F(H, { children: [n && /* @__PURE__ */ P(L, {
3538
3618
  source: { uri: n },
3539
- style: at.image,
3619
+ style: ot.image,
3540
3620
  resizeMode: "cover"
3541
3621
  }), t] });
3542
- }, at = z.create({ image: {
3622
+ }, ot = z.create({ image: {
3543
3623
  borderRadius: 6,
3544
3624
  height: 160,
3545
3625
  marginBottom: 8,
3546
3626
  width: "100%"
3547
- } }), ot = ({ style: e }) => {
3548
- let { colors: t } = h(), n = M(new I.Value(.5)).current;
3549
- return A(() => {
3627
+ } }), st = ({ style: e }) => {
3628
+ let { colors: t } = m(), n = M(new I.Value(.5)).current;
3629
+ return j(() => {
3550
3630
  let e = I.loop(I.sequence([I.timing(n, {
3551
3631
  duration: 600,
3552
3632
  toValue: 1,
@@ -3558,34 +3638,34 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3558
3638
  })]));
3559
3639
  return e.start(), () => e.stop();
3560
3640
  }, [n]), /* @__PURE__ */ P(I.View, { style: [
3561
- ct.bar,
3641
+ lt.bar,
3562
3642
  {
3563
3643
  backgroundColor: t.muted,
3564
3644
  opacity: n
3565
3645
  },
3566
3646
  e
3567
3647
  ] });
3568
- }, st = () => /* @__PURE__ */ F(H, {
3648
+ }, ct = () => /* @__PURE__ */ F(H, {
3569
3649
  accessibilityState: { busy: !0 },
3570
3650
  children: [
3571
- /* @__PURE__ */ P(ot, { style: ct.title }),
3651
+ /* @__PURE__ */ P(st, { style: lt.title }),
3572
3652
  /* @__PURE__ */ P(H, {
3573
- style: ct.fields,
3653
+ style: lt.fields,
3574
3654
  children: [
3575
3655
  0,
3576
3656
  1,
3577
3657
  2
3578
3658
  ].map((e) => /* @__PURE__ */ F(H, {
3579
- style: ct.field,
3580
- children: [/* @__PURE__ */ P(ot, { style: ct.fieldLabel }), /* @__PURE__ */ P(ot, { style: ct.fieldInput })]
3659
+ style: lt.field,
3660
+ children: [/* @__PURE__ */ P(st, { style: lt.fieldLabel }), /* @__PURE__ */ P(st, { style: lt.fieldInput })]
3581
3661
  }, e))
3582
3662
  }),
3583
3663
  /* @__PURE__ */ P(H, {
3584
- style: ct.actions,
3585
- children: /* @__PURE__ */ P(ot, { style: ct.button })
3664
+ style: lt.actions,
3665
+ children: /* @__PURE__ */ P(st, { style: lt.button })
3586
3666
  })
3587
3667
  ]
3588
- }), ct = z.create({
3668
+ }), lt = z.create({
3589
3669
  actions: {
3590
3670
  alignItems: "flex-end",
3591
3671
  marginTop: 24
@@ -3610,117 +3690,117 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3610
3690
  marginBottom: 24,
3611
3691
  width: "33%"
3612
3692
  }
3613
- }), lt = ({ baseUrl: t, components: n, contentContainerStyle: r, flow: i, googleApiKey: a, headers: o, initialValues: s, isLoading: c = !1, isSubmitting: l = !1, language: u, onBack: d, onChange: f, onSubmit: p, showPoweredBy: m, style: g, theme: _, validate: v, validationMode: y }) => {
3614
- let { colors: b } = h(), { canContinueStep: x, canSubmit: S, clearSubmitMessage: C, config: w, currentStep: T, currentStepGroupNode: D, currentStepIndex: ee, formErrors: O, formValues: A, goToNextStep: M, goToPreviousStep: N, handleSubmit: ne, inputNodes: re, isFirstStep: ie, isLastStep: I, isSubmitting: ae, missingRequiredFields: L, setFieldValue: oe, steps: z, submitMessage: se, t: ce } = E({
3615
- baseUrl: t,
3616
- components: n,
3617
- flow: i,
3618
- googleApiKey: a,
3619
- headers: o,
3620
- initialValues: s,
3621
- language: u,
3693
+ }), ut = ({ baseUrl: e, components: t, contentContainerStyle: n, flow: r, googleApiKey: i, headers: a, initialValues: o, isLoading: s = !1, isSubmitting: c = !1, language: l, onBack: u, onChange: f, onSubmit: p, showPoweredBy: h, style: g, theme: _, validate: v, validationMode: y }) => {
3694
+ let { colors: b } = m(), { canContinueStep: x, canSubmit: S, clearSubmitMessage: C, config: w, currentStep: T, currentStepGroupNode: E, currentStepIndex: O, formErrors: k, formValues: A, goToNextStep: j, goToPreviousStep: M, handleSubmit: N, inputNodes: re, isFirstStep: ie, isLastStep: ae, isSubmitting: I, missingRequiredFields: oe, setFieldValue: L, steps: se, submitMessage: z, t: ce } = D({
3695
+ baseUrl: e,
3696
+ components: t,
3697
+ flow: r,
3698
+ googleApiKey: i,
3699
+ headers: a,
3700
+ initialValues: o,
3701
+ language: l,
3622
3702
  onChange: f,
3623
3703
  onSubmit: p,
3624
- showPoweredBy: m,
3704
+ showPoweredBy: h,
3625
3705
  theme: _,
3626
3706
  validate: v,
3627
3707
  validationMode: y
3628
- }), V = l || ae, { FormWrapper: ue, SubmitButtonWrapper: de, renderNode: fe } = k({
3708
+ }), le = c || I, { FormWrapper: V, SubmitButtonWrapper: de, renderNode: fe } = ee({
3629
3709
  config: w,
3630
- DefaultFormWrapper: le,
3631
- DefaultInputWrapper: it,
3632
- DefaultSubmitButton: Ze,
3633
- DefaultSubmitButtonWrapper: $e,
3634
- defaultInputRenderers: Je,
3635
- defaultUI: rt,
3636
- formErrors: O,
3710
+ DefaultFormWrapper: ue,
3711
+ DefaultInputWrapper: at,
3712
+ DefaultSubmitButton: Qe,
3713
+ DefaultSubmitButtonWrapper: et,
3714
+ defaultInputRenderers: Ye,
3715
+ defaultUI: it,
3716
+ formErrors: k,
3637
3717
  formValues: A,
3638
3718
  inputNodes: re,
3639
- isSubmitting: V,
3640
- missingRequiredFields: L,
3641
- setFieldValue: oe
3642
- }), pe = w.components.step ?? Ye, U = w.components.loadingSkeleton ?? st, me = j(() => ce(D?.data?.label), [ce, D]), he = te(() => {
3643
- if (I) {
3644
- ne();
3719
+ isSubmitting: le,
3720
+ missingRequiredFields: oe,
3721
+ setFieldValue: L
3722
+ }), pe = w.components.step ?? Xe, me = w.components.loadingSkeleton ?? ct, U = ne(() => ce(E?.data?.label), [ce, E]), he = te(() => {
3723
+ if (ae) {
3724
+ N();
3645
3725
  return;
3646
3726
  }
3647
- M();
3727
+ j();
3648
3728
  }, [
3649
- I,
3650
- ne,
3651
- M
3729
+ ae,
3730
+ N,
3731
+ j
3652
3732
  ]), ge = te(() => {
3653
3733
  if (ie) {
3654
- d?.();
3734
+ u?.();
3655
3735
  return;
3656
3736
  }
3657
- N();
3737
+ M();
3658
3738
  }, [
3659
3739
  ie,
3660
- d,
3661
- N
3662
- ]), W = !ie || !!d;
3740
+ u,
3741
+ M
3742
+ ]), _e = !ie || !!u;
3663
3743
  return /* @__PURE__ */ P(R, {
3664
3744
  nestedScrollEnabled: !0,
3665
3745
  style: [
3666
- dt.container,
3746
+ ft.container,
3667
3747
  { backgroundColor: b.background },
3668
3748
  g
3669
3749
  ],
3670
- contentContainerStyle: r,
3671
- children: c ? /* @__PURE__ */ P(U, {}) : /* @__PURE__ */ F(e, {
3750
+ contentContainerStyle: n,
3751
+ children: s ? /* @__PURE__ */ P(me, {}) : /* @__PURE__ */ F(d, {
3672
3752
  value: {
3673
3753
  baseUrl: w.baseUrl,
3674
- flow: i,
3675
- formErrors: O,
3754
+ flow: r,
3755
+ formErrors: k,
3676
3756
  formValues: A,
3677
3757
  googleApiKey: w.googleApiKey,
3678
3758
  headers: w.headers,
3679
3759
  inputNodes: re,
3680
3760
  language: w.language,
3681
- setFieldValue: oe
3761
+ setFieldValue: L
3682
3762
  },
3683
- children: [/* @__PURE__ */ F(ue, {
3684
- onSubmit: ne,
3763
+ children: [/* @__PURE__ */ F(V, {
3764
+ onSubmit: N,
3685
3765
  children: [T && /* @__PURE__ */ P(de, {
3686
- missingFields: L,
3766
+ missingFields: oe,
3687
3767
  children: /* @__PURE__ */ P(pe, {
3688
3768
  step: T,
3689
- groupNode: D,
3690
- stepIndex: ee,
3691
- totalSteps: z.length,
3769
+ groupNode: E,
3770
+ stepIndex: O,
3771
+ totalSteps: se.length,
3692
3772
  isFirstStep: ie,
3693
- isLastStep: I,
3694
- canContinue: x && (!I || S),
3695
- canGoBack: W,
3696
- isSubmitting: V,
3773
+ isLastStep: ae,
3774
+ canContinue: x && (!ae || S),
3775
+ canGoBack: _e,
3776
+ isSubmitting: le,
3697
3777
  onBack: ge,
3698
3778
  onContinue: he,
3699
- label: me,
3779
+ label: U,
3700
3780
  children: T.nodes.map((e) => fe(e))
3701
3781
  })
3702
3782
  }), w.showPoweredBy && /* @__PURE__ */ P(B, {
3703
- style: [dt.poweredBy, { color: b.textMuted }],
3783
+ style: [ft.poweredBy, { color: b.textMuted }],
3704
3784
  children: "Powered by Treege"
3705
3785
  })]
3706
- }), se && /* @__PURE__ */ F(H, {
3707
- style: [dt.message, { backgroundColor: se.type === "success" ? b.successBg : b.errorBg }],
3786
+ }), z && /* @__PURE__ */ F(H, {
3787
+ style: [ft.message, { backgroundColor: z.type === "success" ? b.successBg : b.errorBg }],
3708
3788
  children: [/* @__PURE__ */ P(B, {
3709
- style: [dt.messageText, { color: se.type === "success" ? b.success : b.error }],
3710
- children: se.message
3789
+ style: [ft.messageText, { color: z.type === "success" ? b.success : b.error }],
3790
+ children: z.message
3711
3791
  }), /* @__PURE__ */ P(B, {
3712
- style: [dt.messageClose, { color: se.type === "success" ? b.success : b.error }],
3792
+ style: [ft.messageClose, { color: z.type === "success" ? b.success : b.error }],
3713
3793
  onPress: C,
3714
3794
  children: ce("common.close")
3715
3795
  })]
3716
3796
  })]
3717
3797
  })
3718
3798
  });
3719
- }, ut = (e) => /* @__PURE__ */ P(b, {
3799
+ }, dt = (e) => /* @__PURE__ */ P(v, {
3720
3800
  theme: e.theme,
3721
3801
  storageKey: "treege-renderer-theme",
3722
- children: /* @__PURE__ */ P(lt, { ...e })
3723
- }), dt = z.create({
3802
+ children: /* @__PURE__ */ P(ut, { ...e })
3803
+ }), ft = z.create({
3724
3804
  container: { flex: 1 },
3725
3805
  message: {
3726
3806
  borderRadius: 6,
@@ -3743,4 +3823,4 @@ var le = ({ children: e }) => /* @__PURE__ */ P(H, {
3743
3823
  }
3744
3824
  });
3745
3825
  //#endregion
3746
- export { pe as DefaultAddressInput, ge as DefaultAutocompleteInput, _e as DefaultCheckboxInput, ve as DefaultDateInput, ye as DefaultDateRangeInput, tt as DefaultDividerUI, be as DefaultFileInput, xe as DefaultHiddenInput, Me as DefaultHttpInput, Ne as DefaultNumberInput, Fe as DefaultPasswordInput, Le as DefaultRadioInput, Re as DefaultSelectInput, Be as DefaultSwitchInput, We as DefaultTextInput, He as DefaultTextareaInput, Ke as DefaultTimeInput, qe as DefaultTimeRangeInput, et as DefaultTitleUI, ut as TreegeRenderer, C as TreegeRendererProvider, v as applyReferenceTransformation, f as buildInitialFormValues, c as calculateReferenceFieldUpdates, g as checkFormFieldHasValue, y as convertFormValuesToNamedFormat, Je as defaultInputRenderers, rt as defaultUI, D as evaluateCondition, O as evaluateConditions, _ as fileToSerializable, m as filesToSerializable, ee as findStartNode, w as getFlowRenderState, r as getTranslatedText, u as isFieldEmpty, S as isStartNode, Ee as sanitize, Oe as sanitizeHttpResponse, d as serializableToFile, E as useTreegeRenderer, T as useTreegeRendererConfig };
3826
+ export { me as DefaultAddressInput, _e as DefaultAutocompleteInput, ve as DefaultCheckboxInput, ye as DefaultDateInput, be as DefaultDateRangeInput, nt as DefaultDividerUI, xe as DefaultFileInput, Se as DefaultHiddenInput, Ne as DefaultHttpInput, Pe as DefaultNumberInput, Ie as DefaultPasswordInput, Re as DefaultRadioInput, ze as DefaultSelectInput, Ve as DefaultSwitchInput, Ge as DefaultTextInput, Ue as DefaultTextareaInput, qe as DefaultTimeInput, Je as DefaultTimeRangeInput, tt as DefaultTitleUI, dt as TreegeRenderer, w as TreegeRendererProvider, g as applyReferenceTransformation, u as buildInitialFormValues, o as calculateReferenceFieldUpdates, h as checkFormFieldHasValue, _ as convertFormValuesToNamedFormat, Ye as defaultInputRenderers, it as defaultUI, O as evaluateCondition, A as evaluateConditions, p as fileToSerializable, l as filesToSerializable, k as findStartNode, T as getFlowRenderState, r as getTranslatedText, s as isFieldEmpty, C as isStartNode, f as resolveNodeDefaultValue, De as sanitize, ke as sanitizeHttpResponse, c as serializableToFile, D as useTreegeRenderer, E as useTreegeRendererConfig };