@sfperusacdev/sf-ui 0.2.7 → 0.2.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/sf-ui.js CHANGED
@@ -9878,9 +9878,9 @@ var jr = (e) => {
9878
9878
  comfortable: "mb-2",
9879
9879
  compact: "mb-1"
9880
9880
  }, As = ({ label: e, value: t, sublabel: n, icon: r, iconClassName: i, trend: a, trendLabel: o, trendDirection: s = "up-good", accentTone: c, progress: l, valueFormat: u, formatOptions: d, sparkline: f, layout: p = "stacked", variant: m = "default", size: h = "md", density: g = "comfortable", accentBar: _, iconStyle: b = "solid", labelWrap: x = !1, className: S, onClick: C, selected: w = !1, showChevron: T = !0 }) => {
9881
- let E = a != null, D = E && a >= 0, O = E ? s === "neutral" ? null : s === "down-good" ? !D : D : null, k = l ? Ss(l.value, l.max) : null, A = l?.label ?? (k === null ? void 0 : `${Math.round(k)}%`), j = _ ?? p === "stacked", M = (e) => typeof e == "number" ? xs(u, d)(e) : e, N = !l && f && f.data.length > 0, P = (e) => {
9881
+ let E = a != null, D = E && a >= 0, O = E ? s === "neutral" ? null : s === "down-good" ? !D : D : null, k = l ? Ss(l.value, l.max) : null, A = l?.label ?? (k === null ? void 0 : `${Math.round(k)}%`), j = _ ?? p === "stacked", M = (e) => typeof e == "number" ? xs(u, d)(e) : e, N = String(M(t)), P = !l && f && f.data.length > 0, F = (e) => {
9882
9882
  C && (e.key === "Enter" || e.key === " ") && (e.preventDefault(), C());
9883
- }, F = k !== null && /* @__PURE__ */ y("div", {
9883
+ }, I = k !== null && /* @__PURE__ */ y("div", {
9884
9884
  className: "mt-2 flex items-center gap-2",
9885
9885
  role: "progressbar",
9886
9886
  "aria-valuenow": Math.round(k),
@@ -9899,7 +9899,7 @@ var jr = (e) => {
9899
9899
  className: "shrink-0 text-xs font-semibold tabular-nums sf-card-muted",
9900
9900
  children: A
9901
9901
  })]
9902
- }), I = N && /* @__PURE__ */ v("div", {
9902
+ }), L = P && /* @__PURE__ */ v("div", {
9903
9903
  className: "mt-2",
9904
9904
  children: /* @__PURE__ */ v(_s, {
9905
9905
  data: f.data,
@@ -9909,39 +9909,41 @@ var jr = (e) => {
9909
9909
  })
9910
9910
  });
9911
9911
  if (p === "leading-icon") {
9912
- let a = c ? ys[c] : "var(--sf-kpi-accent-slate)", o = b === "soft" ? {
9913
- background: `color-mix(in srgb, ${a} 14%, var(--sf-surface))`,
9914
- color: a
9915
- } : { background: a };
9912
+ let t = c ? ys[c] : "var(--sf-kpi-accent-slate)", a = b === "soft" ? {
9913
+ background: `color-mix(in srgb, ${t} 14%, var(--sf-surface))`,
9914
+ color: t
9915
+ } : { background: t };
9916
9916
  return /* @__PURE__ */ y("div", {
9917
- className: (0, X.default)("sf-card flex items-center gap-3", ws[h], m === "filled" ? "sf-kpi-card--filled" : c && j && "sf-kpi-card", m !== "filled" && c && j && vs[c], C && "sf-card--interactive", w && "sf-kpi-card--selected", S),
9917
+ className: (0, X.default)("sf-card sf-kpi-card--leading flex items-center gap-3", ws[h], m === "filled" ? "sf-kpi-card--filled" : c && j && "sf-kpi-card", m !== "filled" && c && j && vs[c], C && "sf-card--interactive", w && "sf-kpi-card--selected", S),
9918
9918
  onClick: C,
9919
- onKeyDown: P,
9919
+ onKeyDown: F,
9920
9920
  role: C ? "button" : void 0,
9921
9921
  tabIndex: C ? 0 : void 0,
9922
9922
  "aria-pressed": C ? w : void 0,
9923
9923
  children: [
9924
9924
  r && /* @__PURE__ */ v("span", {
9925
9925
  className: (0, X.default)("sf-kpi-tile", Ds[h], b === "soft" && "sf-kpi-tile--soft", i),
9926
- style: o,
9926
+ style: a,
9927
9927
  "aria-hidden": "true",
9928
9928
  children: r
9929
9929
  }),
9930
9930
  /* @__PURE__ */ y("div", {
9931
- className: "min-w-0 flex-1",
9931
+ className: "sf-kpi-card__body min-w-0 flex-1",
9932
9932
  children: [
9933
9933
  /* @__PURE__ */ v("p", {
9934
9934
  className: (0, X.default)(x ? "sf-kpi-card__label--wrap" : "truncate", "text-sm font-medium sf-card-subtitle"),
9935
9935
  children: e
9936
9936
  }),
9937
9937
  /* @__PURE__ */ v("p", {
9938
- className: (0, X.default)(Es[h], "font-bold tabular-nums sf-card-title"),
9939
- children: M(t)
9938
+ className: (0, X.default)(Es[h], "sf-kpi-card__value--fit", `sf-kpi-card__value--${h}`, "font-bold tabular-nums sf-card-title"),
9939
+ style: { "--sf-kpi-value-chars": N.length },
9940
+ title: N,
9941
+ children: N
9940
9942
  }),
9941
- k === null ? N ? I : n && /* @__PURE__ */ v("p", {
9943
+ k === null ? P ? L : n && /* @__PURE__ */ v("p", {
9942
9944
  className: "mt-1 text-xs sf-card-muted",
9943
9945
  children: n
9944
- }) : F,
9946
+ }) : I,
9945
9947
  w && /* @__PURE__ */ y("p", {
9946
9948
  className: "sf-kpi-card__selected-hint",
9947
9949
  children: [/* @__PURE__ */ v(St, { "aria-hidden": "true" }), "Seleccionado"]
@@ -9959,7 +9961,7 @@ var jr = (e) => {
9959
9961
  return /* @__PURE__ */ y("div", {
9960
9962
  className: (0, X.default)("sf-card", Cs[h], m === "filled" ? "sf-kpi-card--filled" : c && j && "sf-kpi-card", m !== "filled" && c && j && vs[c], C && "sf-card--interactive", S),
9961
9963
  onClick: C,
9962
- onKeyDown: P,
9964
+ onKeyDown: F,
9963
9965
  role: C ? "button" : void 0,
9964
9966
  tabIndex: C ? 0 : void 0,
9965
9967
  children: [
@@ -9988,7 +9990,7 @@ var jr = (e) => {
9988
9990
  title: typeof t == "string" ? t : void 0,
9989
9991
  children: M(t)
9990
9992
  }),
9991
- k === null ? N && I : F,
9993
+ k === null ? P && L : I,
9992
9994
  (n || o) && /* @__PURE__ */ y("div", {
9993
9995
  className: (0, X.default)("flex items-center justify-between gap-2", Os[g]),
9994
9996
  children: [n && /* @__PURE__ */ v("span", {
@@ -10622,27 +10624,32 @@ var jr = (e) => {
10622
10624
  xs: 56,
10623
10625
  sm: 80,
10624
10626
  md: 110,
10625
- lg: 150
10627
+ lg: 150,
10628
+ xl: 285
10626
10629
  }, yc = {
10627
10630
  xs: 13,
10628
10631
  sm: 18,
10629
10632
  md: 24,
10630
- lg: 34
10633
+ lg: 34,
10634
+ xl: 64
10631
10635
  }, bc = {
10632
10636
  xs: 8,
10633
10637
  sm: 10,
10634
10638
  md: 11,
10635
- lg: 13
10639
+ lg: 13,
10640
+ xl: 24
10636
10641
  }, xc = {
10637
10642
  xs: 7,
10638
10643
  sm: 9,
10639
10644
  md: 10,
10640
- lg: 12
10645
+ lg: 12,
10646
+ xl: 22
10641
10647
  }, Sc = {
10642
10648
  xs: 6,
10643
10649
  sm: 8,
10644
10650
  md: 10,
10645
- lg: 13
10651
+ lg: 13,
10652
+ xl: 25
10646
10653
  }, Cc = "var(--sf-success)", wc = "var(--sf-warning)", Tc = "var(--sf-danger)", Ec = (e, t, n) => {
10647
10654
  let { warning: r, critical: i } = n;
10648
10655
  return t ? e >= i ? Cc : e >= r ? wc : Tc : e < r ? Cc : e < i ? wc : Tc;
@@ -10719,132 +10726,160 @@ var jr = (e) => {
10719
10726
  ...e,
10720
10727
  size: e.size ?? t
10721
10728
  }, n))
10722
- }), kc = {
10729
+ }), kc = (e) => `${Math.round(e * 100)}%`, Ac = {
10723
10730
  xs: 56,
10724
10731
  sm: 80,
10725
10732
  md: 110,
10726
- lg: 150
10727
- }, Ac = {
10733
+ lg: 150,
10734
+ xl: 285
10735
+ }, jc = {
10728
10736
  xs: 6,
10729
10737
  sm: 8,
10730
10738
  md: 10,
10731
- lg: 13
10732
- }, jc = {
10739
+ lg: 13,
10740
+ xl: 25
10741
+ }, Mc = {
10733
10742
  xs: 13,
10734
10743
  sm: 18,
10735
10744
  md: 24,
10736
- lg: 34
10737
- }, Mc = {
10745
+ lg: 34,
10746
+ xl: 64
10747
+ }, Nc = {
10738
10748
  xs: 8,
10739
10749
  sm: 10,
10740
10750
  md: 11,
10741
- lg: 13
10742
- }, Nc = [
10751
+ lg: 13,
10752
+ xl: 24
10753
+ }, Pc = [
10743
10754
  "var(--sf-primary)",
10744
10755
  "var(--sf-info)",
10745
10756
  "var(--sf-warning)",
10746
10757
  "var(--sf-accent)"
10747
- ], Pc = ({ segments: e, centerValue: t, centerLabel: n, size: r = "md", strokeWidth: i, showLegend: a = !0, className: o }) => {
10748
- let s = e.reduce((e, t) => e + Math.max(0, t.value), 0), c = kc[r], l = i ?? Ac[r], u = (c - l) / 2, d = c / 2, f = 2 * Math.PI * u, p = 0, m = e.map((e, t) => {
10749
- let n = Math.max(0, e.value), r = s > 0 ? n / s : 0, i = f * r, a = f * (1 - p);
10750
- return p += r, {
10758
+ ], Fc = ({ segments: e, centerValue: t, centerLabel: n, size: r = "md", strokeWidth: i, showLegend: a = !0, legendVariant: o = "list", formatPct: s = kc, className: c }) => {
10759
+ let l = e.reduce((e, t) => e + Math.max(0, t.value), 0), u = Ac[r], d = i ?? jc[r], f = (u - d) / 2, p = u / 2, m = 2 * Math.PI * f, h = e.map((e) => l > 0 ? Math.max(0, e.value) / l : 0), g = e.map((e, t) => {
10760
+ let n = h[t], r = m * n, i = h.slice(0, t).reduce((e, t) => e + t, 0), a = m * (1 - i);
10761
+ return {
10751
10762
  ...e,
10752
- pct: r,
10753
- color: e.color ?? Nc[t % Nc.length],
10754
- dasharray: `${i} ${f - i}`,
10763
+ pct: n,
10764
+ color: e.color ?? Pc[t % Pc.length],
10765
+ dasharray: `${r} ${m - r}`,
10755
10766
  dashoffset: a
10756
10767
  };
10757
10768
  });
10758
10769
  return /* @__PURE__ */ y("div", {
10759
- className: (0, X.default)("sf-donut-breakdown", o),
10760
- children: [/* @__PURE__ */ y("div", {
10761
- className: "relative",
10762
- style: {
10763
- width: c,
10764
- height: c
10765
- },
10766
- children: [/* @__PURE__ */ v("svg", {
10767
- width: c,
10768
- height: c,
10769
- viewBox: `0 0 ${c} ${c}`,
10770
- style: { transform: "rotate(-90deg)" },
10771
- "aria-hidden": "true",
10772
- children: s <= 0 ? /* @__PURE__ */ v("circle", {
10773
- cx: d,
10774
- cy: d,
10775
- r: u,
10776
- fill: "none",
10777
- stroke: "var(--sf-gauge-track)",
10778
- strokeWidth: l
10779
- }) : m.map((e, t) => /* @__PURE__ */ v("circle", {
10780
- cx: d,
10781
- cy: d,
10782
- r: u,
10783
- fill: "none",
10784
- stroke: e.color,
10785
- strokeWidth: l,
10786
- strokeDasharray: e.dasharray,
10787
- strokeDashoffset: e.dashoffset
10788
- }, `${e.label}-${t}`))
10789
- }), /* @__PURE__ */ y("div", {
10790
- className: "absolute inset-0 flex flex-col items-center justify-center",
10791
- children: [/* @__PURE__ */ v("span", {
10792
- className: "sf-donut-breakdown__value",
10793
- style: { fontSize: jc[r] },
10794
- children: t ?? s.toLocaleString("es-PE")
10795
- }), n && /* @__PURE__ */ v("span", {
10796
- className: "sf-donut-breakdown__label",
10797
- style: { fontSize: Mc[r] },
10798
- children: n
10770
+ className: (0, X.default)("sf-donut-breakdown", o === "stat" && "sf-donut-breakdown--stat", c),
10771
+ children: [
10772
+ /* @__PURE__ */ y("div", {
10773
+ className: "relative",
10774
+ style: {
10775
+ width: u,
10776
+ height: u
10777
+ },
10778
+ children: [/* @__PURE__ */ v("svg", {
10779
+ width: u,
10780
+ height: u,
10781
+ viewBox: `0 0 ${u} ${u}`,
10782
+ style: { transform: "rotate(-90deg)" },
10783
+ "aria-hidden": "true",
10784
+ children: l <= 0 ? /* @__PURE__ */ v("circle", {
10785
+ cx: p,
10786
+ cy: p,
10787
+ r: f,
10788
+ fill: "none",
10789
+ stroke: "var(--sf-gauge-track)",
10790
+ strokeWidth: d
10791
+ }) : g.map((e, t) => /* @__PURE__ */ v("circle", {
10792
+ cx: p,
10793
+ cy: p,
10794
+ r: f,
10795
+ fill: "none",
10796
+ stroke: e.color,
10797
+ strokeWidth: d,
10798
+ strokeDasharray: e.dasharray,
10799
+ strokeDashoffset: e.dashoffset
10800
+ }, `${e.label}-${t}`))
10801
+ }), /* @__PURE__ */ y("div", {
10802
+ className: "absolute inset-0 flex flex-col items-center justify-center",
10803
+ children: [/* @__PURE__ */ v("span", {
10804
+ className: "sf-donut-breakdown__value",
10805
+ style: { fontSize: Mc[r] },
10806
+ children: t ?? l.toLocaleString("es-PE")
10807
+ }), n && /* @__PURE__ */ v("span", {
10808
+ className: "sf-donut-breakdown__label",
10809
+ style: { fontSize: Nc[r] },
10810
+ children: n
10811
+ })]
10799
10812
  })]
10800
- })]
10801
- }), a && /* @__PURE__ */ v("ul", {
10802
- className: "sf-donut-breakdown__legend",
10803
- children: m.map((e, t) => /* @__PURE__ */ y("li", {
10804
- className: "sf-donut-breakdown__legend-item",
10805
- children: [
10806
- /* @__PURE__ */ v("span", {
10807
- className: "sf-donut-breakdown__legend-dot",
10813
+ }),
10814
+ a && o === "stat" && /* @__PURE__ */ v("ul", {
10815
+ className: "sf-donut-breakdown__stats",
10816
+ children: g.map((e, t) => /* @__PURE__ */ y("li", {
10817
+ className: "sf-donut-breakdown__stat",
10818
+ children: [/* @__PURE__ */ v("span", {
10819
+ className: "sf-donut-breakdown__stat-dot",
10808
10820
  style: { backgroundColor: e.color },
10809
10821
  "aria-hidden": "true"
10810
- }),
10811
- /* @__PURE__ */ v("span", {
10812
- className: "sf-donut-breakdown__legend-label",
10813
- children: e.label
10814
- }),
10815
- /* @__PURE__ */ v("span", {
10816
- className: "sf-donut-breakdown__legend-value",
10822
+ }), /* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("div", {
10823
+ className: "sf-donut-breakdown__stat-value",
10817
10824
  children: e.value.toLocaleString("es-PE")
10818
- }),
10819
- /* @__PURE__ */ y("span", {
10820
- className: "sf-donut-breakdown__legend-pct",
10821
- children: [Math.round(e.pct * 100), "%"]
10822
- })
10823
- ]
10824
- }, `${e.label}-${t}`))
10825
- })]
10825
+ }), /* @__PURE__ */ y("div", {
10826
+ className: "sf-donut-breakdown__stat-text",
10827
+ children: [
10828
+ e.label,
10829
+ " · ",
10830
+ s(e.pct)
10831
+ ]
10832
+ })] })]
10833
+ }, `${e.label}-${t}`))
10834
+ }),
10835
+ a && o === "list" && /* @__PURE__ */ v("ul", {
10836
+ className: "sf-donut-breakdown__legend",
10837
+ children: g.map((e, t) => /* @__PURE__ */ y("li", {
10838
+ className: "sf-donut-breakdown__legend-item",
10839
+ children: [
10840
+ /* @__PURE__ */ v("span", {
10841
+ className: "sf-donut-breakdown__legend-dot",
10842
+ style: { backgroundColor: e.color },
10843
+ "aria-hidden": "true"
10844
+ }),
10845
+ /* @__PURE__ */ v("span", {
10846
+ className: "sf-donut-breakdown__legend-label",
10847
+ children: e.label
10848
+ }),
10849
+ /* @__PURE__ */ v("span", {
10850
+ className: "sf-donut-breakdown__legend-value",
10851
+ children: e.value.toLocaleString("es-PE")
10852
+ }),
10853
+ /* @__PURE__ */ v("span", {
10854
+ className: "sf-donut-breakdown__legend-pct",
10855
+ children: s(e.pct)
10856
+ })
10857
+ ]
10858
+ }, `${e.label}-${t}`))
10859
+ })
10860
+ ]
10826
10861
  });
10827
- }, Fc = {
10862
+ }, Ic = {
10828
10863
  success: "sf-event-log__dot--success",
10829
10864
  warning: "sf-event-log__dot--warning",
10830
10865
  danger: "sf-event-log__dot--danger",
10831
10866
  info: "sf-event-log__dot--info",
10832
10867
  default: "sf-event-log__dot--default"
10833
- }, Ic = {
10868
+ }, Lc = {
10834
10869
  success: "sf-event-log__icon-wrap--success",
10835
10870
  warning: "sf-event-log__icon-wrap--warning",
10836
10871
  danger: "sf-event-log__icon-wrap--danger",
10837
10872
  info: "sf-event-log__icon-wrap--info",
10838
10873
  default: "sf-event-log__icon-wrap--default"
10839
- }, Lc = {
10874
+ }, Rc = {
10840
10875
  success: "sf-alert-row-list__meta--success",
10841
10876
  warning: "sf-alert-row-list__meta--warning",
10842
10877
  danger: "sf-alert-row-list__meta--danger",
10843
10878
  info: "sf-alert-row-list__meta--info",
10844
10879
  default: "sf-alert-row-list__meta--default"
10845
- }, Rc = (e, t) => {
10880
+ }, zc = (e, t) => {
10846
10881
  t && (e.key === "Enter" || e.key === " ") && (e.preventDefault(), t());
10847
- }, zc = ({ events: e, title: t, maxHeight: n, compact: r = !1, showTimeline: i = !0, viewAllLabel: a, onViewAll: o, className: s }) => {
10882
+ }, Bc = ({ events: e, title: t, maxHeight: n, compact: r = !1, showTimeline: i = !0, viewAllLabel: a, onViewAll: o, className: s }) => {
10848
10883
  let c = r ? "text-[11px]" : "text-xs", l = r ? "text-[10px]" : "text-[11px]", u = r ? "text-[9px]" : "text-[10px]", d = r ? "py-1.5" : "py-2.5";
10849
10884
  return /* @__PURE__ */ y("div", {
10850
10885
  className: (0, X.default)("sf-event-log", s),
@@ -10885,11 +10920,11 @@ var jr = (e) => {
10885
10920
  /* @__PURE__ */ v("div", {
10886
10921
  className: "mt-0.5 shrink-0",
10887
10922
  children: t.icon ? /* @__PURE__ */ v("div", {
10888
- className: (0, X.default)("sf-event-log__icon-wrap", Ic[r]),
10923
+ className: (0, X.default)("sf-event-log__icon-wrap", Lc[r]),
10889
10924
  "aria-hidden": "true",
10890
10925
  children: t.icon
10891
10926
  }) : /* @__PURE__ */ v("div", {
10892
- className: (0, X.default)("sf-event-log__dot", Fc[r]),
10927
+ className: (0, X.default)("sf-event-log__dot", Ic[r]),
10893
10928
  "aria-hidden": "true"
10894
10929
  })
10895
10930
  }),
@@ -10923,16 +10958,16 @@ var jr = (e) => {
10923
10958
  })]
10924
10959
  })]
10925
10960
  });
10926
- }, Bc = {
10961
+ }, Vc = {
10927
10962
  time: "Hora",
10928
10963
  vehicle: "Vehículo",
10929
10964
  description: "Descripción"
10930
- }, Vc = {
10965
+ }, Hc = {
10931
10966
  critical: "sf-alert-row-list__severity--critical",
10932
10967
  warning: "sf-alert-row-list__severity--warning",
10933
10968
  info: !1
10934
- }, Hc = ({ severity: e }) => {
10935
- let t = Vc[e];
10969
+ }, Uc = ({ severity: e }) => {
10970
+ let t = Hc[e];
10936
10971
  return t ? /* @__PURE__ */ v("span", {
10937
10972
  className: (0, X.default)("sf-alert-row-list__severity", t),
10938
10973
  "aria-hidden": "true",
@@ -10967,7 +11002,7 @@ var jr = (e) => {
10967
11002
  })] })
10968
11003
  })
10969
11004
  }) : null;
10970
- }, Uc = ({ actions: e }) => /* @__PURE__ */ v("span", {
11005
+ }, Wc = ({ actions: e }) => /* @__PURE__ */ v("span", {
10971
11006
  className: "sf-alert-row-list__actions",
10972
11007
  children: e.map((e, t) => /* @__PURE__ */ v("button", {
10973
11008
  type: "button",
@@ -10977,9 +11012,9 @@ var jr = (e) => {
10977
11012
  },
10978
11013
  children: e.label
10979
11014
  }, t))
10980
- }), Wc = ({ items: e, maxHeight: t, className: n, columns: r = !1, headerLabels: i, density: a = "comfortable", emptyMessage: o = "Sin alertas" }) => {
11015
+ }), Gc = ({ items: e, maxHeight: t, className: n, columns: r = !1, headerLabels: i, density: a = "comfortable", emptyMessage: o = "Sin alertas" }) => {
10981
11016
  let s = {
10982
- ...Bc,
11017
+ ...Vc,
10983
11018
  ...i
10984
11019
  };
10985
11020
  return /* @__PURE__ */ y("div", {
@@ -11013,13 +11048,13 @@ var jr = (e) => {
11013
11048
  role: a ? "button" : "listitem",
11014
11049
  tabIndex: a ? 0 : void 0,
11015
11050
  onClick: a ? e.onClick : void 0,
11016
- onKeyDown: a ? (t) => Rc(t, e.onClick) : void 0
11051
+ onKeyDown: a ? (t) => zc(t, e.onClick) : void 0
11017
11052
  };
11018
11053
  return r ? /* @__PURE__ */ y("div", {
11019
11054
  ...o,
11020
11055
  children: [
11021
11056
  /* @__PURE__ */ v("span", {
11022
- className: (0, X.default)("sf-event-log__dot", Fc[n]),
11057
+ className: (0, X.default)("sf-event-log__dot", Ic[n]),
11023
11058
  "aria-hidden": "true"
11024
11059
  }),
11025
11060
  /* @__PURE__ */ v("span", {
@@ -11028,7 +11063,7 @@ var jr = (e) => {
11028
11063
  }),
11029
11064
  /* @__PURE__ */ y("span", {
11030
11065
  className: "sf-alert-row-list__vehicle",
11031
- children: [e.severity && /* @__PURE__ */ v(Hc, { severity: e.severity }), e.vehicle]
11066
+ children: [e.severity && /* @__PURE__ */ v(Uc, { severity: e.severity }), e.vehicle]
11032
11067
  }),
11033
11068
  /* @__PURE__ */ y("span", {
11034
11069
  className: "sf-alert-row-list__description",
@@ -11039,17 +11074,17 @@ var jr = (e) => {
11039
11074
  children: e.icon
11040
11075
  }), e.label]
11041
11076
  }), e.meta && /* @__PURE__ */ v("span", {
11042
- className: (0, X.default)("sf-alert-row-list__meta", Lc[n]),
11077
+ className: (0, X.default)("sf-alert-row-list__meta", Rc[n]),
11043
11078
  children: e.meta
11044
11079
  })]
11045
11080
  }),
11046
- i && /* @__PURE__ */ v(Uc, { actions: e.actions })
11081
+ i && /* @__PURE__ */ v(Wc, { actions: e.actions })
11047
11082
  ]
11048
11083
  }, t) : /* @__PURE__ */ y("div", {
11049
11084
  ...o,
11050
11085
  children: [
11051
11086
  /* @__PURE__ */ v("span", {
11052
- className: (0, X.default)("sf-event-log__dot", Fc[n]),
11087
+ className: (0, X.default)("sf-event-log__dot", Ic[n]),
11053
11088
  "aria-hidden": "true"
11054
11089
  }),
11055
11090
  /* @__PURE__ */ y("span", {
@@ -11060,20 +11095,20 @@ var jr = (e) => {
11060
11095
  }), e.label]
11061
11096
  }),
11062
11097
  e.meta && /* @__PURE__ */ v("span", {
11063
- className: (0, X.default)("sf-alert-row-list__meta", Lc[n]),
11098
+ className: (0, X.default)("sf-alert-row-list__meta", Rc[n]),
11064
11099
  children: e.meta
11065
11100
  }),
11066
11101
  e.time && /* @__PURE__ */ v("span", {
11067
11102
  className: "sf-alert-row-list__time",
11068
11103
  children: e.time
11069
11104
  }),
11070
- i && /* @__PURE__ */ v(Uc, { actions: e.actions })
11105
+ i && /* @__PURE__ */ v(Wc, { actions: e.actions })
11071
11106
  ]
11072
11107
  }, t);
11073
11108
  })
11074
11109
  ]
11075
11110
  });
11076
- }, Gc = {
11111
+ }, Kc = {
11077
11112
  success: {
11078
11113
  color: "#1F8A4C",
11079
11114
  halo: "#EAF5EE"
@@ -11094,17 +11129,17 @@ var jr = (e) => {
11094
11129
  color: "var(--sf-text-subtle, #5C7180)",
11095
11130
  halo: "var(--sf-surface-alt, #EEF0F2)"
11096
11131
  }
11097
- }, Kc = {
11132
+ }, qc = {
11098
11133
  display: "flex",
11099
11134
  gap: 12,
11100
11135
  flexWrap: "wrap"
11101
- }, qc = ({ items: e, className: t }) => /* @__PURE__ */ v("div", {
11136
+ }, Jc = ({ items: e, className: t }) => /* @__PURE__ */ v("div", {
11102
11137
  className: (0, X.default)("sf-alert-lane", t),
11103
- style: Kc,
11138
+ style: qc,
11104
11139
  role: "list",
11105
11140
  "aria-label": "Alertas",
11106
11141
  children: e.map((e, t) => {
11107
- let n = Gc[e.status ?? "default"], r = e.color ?? n.color, i = e.halo ?? n.halo;
11142
+ let n = Kc[e.status ?? "default"], r = e.color ?? n.color, i = e.halo ?? n.halo;
11108
11143
  return /* @__PURE__ */ y("div", {
11109
11144
  role: "listitem",
11110
11145
  style: {
@@ -11175,7 +11210,7 @@ var jr = (e) => {
11175
11210
  ]
11176
11211
  }, e.id ?? t);
11177
11212
  })
11178
- }), Jc = ({ tone: e = "default" }) => /* @__PURE__ */ v("span", {
11213
+ }), Yc = ({ tone: e = "default" }) => /* @__PURE__ */ v("span", {
11179
11214
  className: (0, X.default)("sf-alert-summary-row__icon", `sf-alert-summary-row__icon--${e}`),
11180
11215
  "aria-hidden": "true",
11181
11216
  children: /* @__PURE__ */ y("svg", {
@@ -11212,7 +11247,7 @@ var jr = (e) => {
11212
11247
  y2: "4.71"
11213
11248
  })] })]
11214
11249
  })
11215
- }), Yc = ({ items: e, className: t, density: n = "comfortable", emptyMessage: r = "Sin alertas", showIcon: i = !1, showChevron: a = !1 }) => /* @__PURE__ */ y("div", {
11250
+ }), Xc = ({ items: e, className: t, density: n = "comfortable", emptyMessage: r = "Sin alertas", showIcon: i = !1, showChevron: a = !1 }) => /* @__PURE__ */ y("div", {
11216
11251
  className: (0, X.default)("sf-alert-summary-list", t),
11217
11252
  children: [e.length === 0 && /* @__PURE__ */ v("p", {
11218
11253
  className: "sf-alert-summary-list__empty",
@@ -11230,7 +11265,7 @@ var jr = (e) => {
11230
11265
  } : void 0,
11231
11266
  children: [/* @__PURE__ */ y("div", {
11232
11267
  className: "flex min-w-0 items-start gap-2",
11233
- children: [i && (e.icon ?? /* @__PURE__ */ v(Jc, { tone: e.tone })), /* @__PURE__ */ y("div", {
11268
+ children: [i && (e.icon ?? /* @__PURE__ */ v(Yc, { tone: e.tone })), /* @__PURE__ */ y("div", {
11234
11269
  className: "min-w-0",
11235
11270
  children: [/* @__PURE__ */ v("p", {
11236
11271
  className: "sf-alert-summary-row__label",
@@ -11267,7 +11302,7 @@ var jr = (e) => {
11267
11302
  })]
11268
11303
  }, `${e.label}-${t}`);
11269
11304
  })]
11270
- }), Xc = ({ items: e, confidence: t, updatedAt: n, className: r }) => {
11305
+ }), Zc = ({ items: e, confidence: t, updatedAt: n, className: r }) => {
11271
11306
  let i = [
11272
11307
  ...e.map((e, t) => /* @__PURE__ */ y("span", {
11273
11308
  className: "sf-evidence-footnote__item",
@@ -11304,7 +11339,7 @@ var jr = (e) => {
11304
11339
  }), e]
11305
11340
  }, t))
11306
11341
  });
11307
- }, Zc = (e) => e.toLocaleString("es-PE"), Qc = ({ rows: e, planLabel: t = "Plan", realLabel: n = "Real", className: r }) => /* @__PURE__ */ y("table", {
11342
+ }, Qc = (e) => e.toLocaleString("es-PE"), $c = ({ rows: e, planLabel: t = "Plan", realLabel: n = "Real", className: r }) => /* @__PURE__ */ y("table", {
11308
11343
  className: (0, X.default)("sf-comparison-table", r),
11309
11344
  children: [/* @__PURE__ */ v("thead", { children: /* @__PURE__ */ y("tr", { children: [
11310
11345
  /* @__PURE__ */ v("th", { className: "sf-comparison-table__th sf-comparison-table__th--label" }),
@@ -11321,7 +11356,7 @@ var jr = (e) => {
11321
11356
  children: "Desviación"
11322
11357
  })
11323
11358
  ] }) }), /* @__PURE__ */ v("tbody", { children: e.map((e) => {
11324
- let t = e.valueFormat ?? Zc, n = e.direction ?? "up-good", r = e.real - e.plan, i = e.plan === 0 ? 0 : r / Math.abs(e.plan) * 100, a = n === "neutral" ? null : n === "up-good" ? r >= 0 : r <= 0;
11359
+ let t = e.valueFormat ?? Qc, n = e.direction ?? "up-good", r = e.real - e.plan, i = e.plan === 0 ? 0 : r / Math.abs(e.plan) * 100, a = n === "neutral" ? null : n === "up-good" ? r >= 0 : r <= 0;
11325
11360
  return /* @__PURE__ */ y("tr", {
11326
11361
  className: "sf-comparison-table__row",
11327
11362
  children: [
@@ -11352,40 +11387,40 @@ var jr = (e) => {
11352
11387
  ]
11353
11388
  }, e.key);
11354
11389
  }) })]
11355
- }), $c = {
11390
+ }), el = {
11356
11391
  default: "",
11357
11392
  accent: "sf-card--accent",
11358
11393
  critical: "sf-card--critical",
11359
11394
  warning: "sf-card--warning",
11360
11395
  success: "sf-card--success"
11361
- }, el = {
11396
+ }, tl = {
11362
11397
  1: "col-span-1",
11363
11398
  2: "col-span-1 sm:col-span-2",
11364
11399
  3: "col-span-1 sm:col-span-2 lg:col-span-3",
11365
11400
  4: "col-span-1 sm:col-span-2 lg:col-span-4",
11366
11401
  5: "col-span-1 sm:col-span-2 lg:col-span-5",
11367
11402
  6: "col-span-1 sm:col-span-2 lg:col-span-6"
11368
- }, tl = {
11403
+ }, nl = {
11369
11404
  none: "",
11370
11405
  sm: "p-3",
11371
11406
  md: "p-4",
11372
11407
  lg: "p-5"
11373
- }, nl = {
11408
+ }, rl = {
11374
11409
  visible: "",
11375
11410
  auto: "overflow-auto",
11376
11411
  hidden: "overflow-hidden"
11377
- }, rl = () => /* @__PURE__ */ v("div", {
11412
+ }, il = () => /* @__PURE__ */ v("div", {
11378
11413
  className: "sf-card-state__spinner",
11379
11414
  role: "status",
11380
11415
  "aria-label": "Cargando",
11381
11416
  children: /* @__PURE__ */ v("span", { className: "sf-card-state__spinner-ring" })
11382
- }), il = ({ title: e, subtitle: t, icon: n, headerAction: r, variant: i = "default", span: a = 1, padding: o = "md", look: s = "default", headerSize: c = s === "board" ? "md" : "sm", headerWrap: l = s === "board", headerDivider: u = s !== "board", footer: d, state: f = "idle", loadingMessage: p = "Cargando…", errorMessage: m = "No se pudo cargar la información.", emptyMessage: h = "Sin datos para mostrar.", onRetry: g, retryLabel: b = "Reintentar", minHeight: x, bodyOverflow: S = "visible", className: C, children: w }) => {
11417
+ }), al = ({ title: e, subtitle: t, icon: n, headerAction: r, variant: i = "default", span: a = 1, padding: o = "md", look: s = "default", headerSize: c = s === "board" ? "md" : "sm", headerWrap: l = s === "board", headerDivider: u = s !== "board", footer: d, state: f = "idle", loadingMessage: p = "Cargando…", errorMessage: m = "No se pudo cargar la información.", emptyMessage: h = "Sin datos para mostrar.", onRetry: g, retryLabel: b = "Reintentar", minHeight: x, bodyOverflow: S = "visible", className: C, children: w }) => {
11383
11418
  let T = x === void 0 ? void 0 : { minHeight: x }, E = f !== "idle" && /* @__PURE__ */ y("div", {
11384
11419
  className: "sf-card-state",
11385
11420
  style: T,
11386
11421
  role: f === "error" ? "alert" : f === "empty" ? "status" : void 0,
11387
11422
  children: [
11388
- f === "loading" && /* @__PURE__ */ y(_, { children: [/* @__PURE__ */ v(rl, {}), p && /* @__PURE__ */ v("p", {
11423
+ f === "loading" && /* @__PURE__ */ y(_, { children: [/* @__PURE__ */ v(il, {}), p && /* @__PURE__ */ v("p", {
11389
11424
  className: "sf-card-state__message",
11390
11425
  children: p
11391
11426
  })] }),
@@ -11407,7 +11442,7 @@ var jr = (e) => {
11407
11442
  return /* @__PURE__ */ y("div", {
11408
11443
  role: e ? "region" : void 0,
11409
11444
  "aria-label": e,
11410
- className: (0, X.default)("sf-card flex flex-col overflow-hidden", $c[i], el[a], C),
11445
+ className: (0, X.default)("sf-card flex flex-col overflow-hidden", el[i], tl[a], C),
11411
11446
  children: [
11412
11447
  (e || n || r) && /* @__PURE__ */ y("div", {
11413
11448
  className: (0, X.default)("sf-card-header", c === "md" && "sf-card-header--md", l && "sf-card-header--wrap", !u && "sf-card-header--no-divider"),
@@ -11438,7 +11473,7 @@ var jr = (e) => {
11438
11473
  ]
11439
11474
  }),
11440
11475
  /* @__PURE__ */ v("div", {
11441
- className: (0, X.default)("flex-1", tl[o], nl[S]),
11476
+ className: (0, X.default)("flex-1", nl[o], rl[S]),
11442
11477
  style: f === "idle" ? T : void 0,
11443
11478
  children: f === "idle" ? w : E
11444
11479
  }),
@@ -11448,24 +11483,24 @@ var jr = (e) => {
11448
11483
  })
11449
11484
  ]
11450
11485
  });
11451
- }, al = {
11486
+ }, ol = {
11452
11487
  2: "grid-cols-1 sm:grid-cols-2",
11453
11488
  3: "grid-cols-1 sm:grid-cols-2 lg:grid-cols-3",
11454
11489
  4: "grid-cols-1 sm:grid-cols-2 lg:grid-cols-4",
11455
11490
  5: "grid-cols-2 sm:grid-cols-3 lg:grid-cols-5",
11456
11491
  6: "grid-cols-2 sm:grid-cols-3 lg:grid-cols-6"
11457
- }, ol = {
11492
+ }, sl = {
11458
11493
  sm: "gap-2",
11459
11494
  md: "gap-3",
11460
11495
  lg: "gap-5"
11461
- }, sl = {
11496
+ }, cl = {
11462
11497
  stretch: "items-stretch",
11463
11498
  start: "items-start"
11464
- }, cl = ({ cols: e = 4, gap: t = "md", alignItems: n = "stretch", minColWidth: r, className: i, children: a }) => /* @__PURE__ */ v("div", {
11465
- className: (0, X.default)("grid", !r && al[e], ol[t], sl[n], i),
11499
+ }, ll = ({ cols: e = 4, gap: t = "md", alignItems: n = "stretch", minColWidth: r, className: i, children: a }) => /* @__PURE__ */ v("div", {
11500
+ className: (0, X.default)("grid", !r && ol[e], sl[t], cl[n], i),
11466
11501
  style: r ? { gridTemplateColumns: `repeat(auto-fit, minmax(${r}, 1fr))` } : void 0,
11467
11502
  children: a
11468
- }), ll = ({ title: e, subtitle: t, action: n, icon: r, iconSize: i = "md", variant: a = "plain", className: o, children: s }) => /* @__PURE__ */ y("section", {
11503
+ }), ul = ({ title: e, subtitle: t, action: n, icon: r, iconSize: i = "md", variant: a = "plain", className: o, children: s }) => /* @__PURE__ */ y("section", {
11469
11504
  className: (0, X.default)("flex flex-col gap-3", a === "panel" && "sf-section--panel", o),
11470
11505
  "aria-label": e,
11471
11506
  children: [/* @__PURE__ */ y("div", {
@@ -11488,13 +11523,13 @@ var jr = (e) => {
11488
11523
  children: n
11489
11524
  })]
11490
11525
  }), s]
11491
- }), ul = {
11526
+ }), dl = {
11492
11527
  slate: "sf-stat-tone--slate",
11493
11528
  emerald: "sf-stat-tone--emerald",
11494
11529
  amber: "sf-stat-tone--amber",
11495
11530
  red: "sf-stat-tone--red",
11496
11531
  blue: "sf-stat-tone--blue"
11497
- }, dl = ({ items: e, className: t }) => /* @__PURE__ */ v("div", {
11532
+ }, fl = ({ items: e, className: t }) => /* @__PURE__ */ v("div", {
11498
11533
  role: "list",
11499
11534
  "aria-label": "Resumen de métricas",
11500
11535
  className: (0, X.default)("flex flex-wrap items-center gap-5 border-t border-[var(--sf-border)] bg-[var(--sf-card-bg)] px-4 py-2", t),
@@ -11503,7 +11538,7 @@ var jr = (e) => {
11503
11538
  role: "listitem",
11504
11539
  children: [
11505
11540
  e.tone && /* @__PURE__ */ v("span", {
11506
- className: (0, X.default)("h-1.5 w-1.5 shrink-0 rounded-full", ul[e.tone]),
11541
+ className: (0, X.default)("h-1.5 w-1.5 shrink-0 rounded-full", dl[e.tone]),
11507
11542
  "aria-hidden": "true"
11508
11543
  }),
11509
11544
  /* @__PURE__ */ y("span", {
@@ -11516,7 +11551,7 @@ var jr = (e) => {
11516
11551
  })
11517
11552
  ]
11518
11553
  }, t))
11519
- }), fl = ({ header: e, sidebar: t, statBar: n, className: r, children: i }) => /* @__PURE__ */ y("div", {
11554
+ }), pl = ({ header: e, sidebar: t, statBar: n, className: r, children: i }) => /* @__PURE__ */ y("div", {
11520
11555
  className: "sf-card flex min-h-[480px] flex-col overflow-hidden bg-[var(--sf-page-bg)]",
11521
11556
  role: "region",
11522
11557
  "aria-label": "Dashboard",
@@ -11541,7 +11576,7 @@ var jr = (e) => {
11541
11576
  children: n
11542
11577
  })
11543
11578
  ]
11544
- }), pl = ({ title: e, onClose: t, headerAction: n, icon: r, iconSize: i = "sm", heading: a, badge: o, rows: s = [], align: c = "stack", actions: l, sectionTitle: u, items: d = [], width: f = 320, className: p }) => {
11579
+ }), ml = ({ title: e, onClose: t, headerAction: n, icon: r, iconSize: i = "sm", heading: a, badge: o, rows: s = [], align: c = "stack", actions: l, sectionTitle: u, items: d = [], width: f = 320, className: p }) => {
11545
11580
  let m = typeof f == "number" ? `${f}px` : f;
11546
11581
  return /* @__PURE__ */ y("aside", {
11547
11582
  className: (0, X.default)("sf-detail-side-panel", p),
@@ -11634,17 +11669,17 @@ var jr = (e) => {
11634
11669
  })
11635
11670
  ]
11636
11671
  });
11637
- }, ml = ({ text: e, tone: t = "info", className: n }) => /* @__PURE__ */ y("div", {
11672
+ }, hl = ({ text: e, tone: t = "info", className: n }) => /* @__PURE__ */ y("div", {
11638
11673
  className: (0, X.default)("sf-card-note", t === "warning" && "sf-card-note--warning", n),
11639
11674
  role: "note",
11640
11675
  children: [/* @__PURE__ */ v(ut, {
11641
11676
  className: "sf-card-note__icon",
11642
11677
  "aria-hidden": "true"
11643
11678
  }), /* @__PURE__ */ v("span", { children: e })]
11644
- }), hl = (e) => e >= 5 ? 5 : e === 4 ? 4 : 3, gl = ({ block: e }) => e.left && e.right ? /* @__PURE__ */ y("div", {
11679
+ }), gl = (e) => e >= 5 ? 5 : e === 4 ? 4 : 3, _l = ({ block: e }) => e.left && e.right ? /* @__PURE__ */ y("div", {
11645
11680
  className: "sf-board__split",
11646
11681
  children: [e.left, e.right]
11647
- }) : /* @__PURE__ */ v(_, { children: e.left ?? e.right }), _l = ({ kpis: e = [], notes: t = [], hidden: n = [], hiddenTitle: r = (e) => `${e} indicador(es) no aplican a esta empresa`, detail: i, primary: a, secondary: o }) => {
11682
+ }) : /* @__PURE__ */ v(_, { children: e.left ?? e.right }), vl = ({ kpis: e = [], notes: t = [], hidden: n = [], hiddenTitle: r = (e) => `${e} indicador(es) no aplican a esta empresa`, detail: i, primary: a, secondary: o }) => {
11648
11683
  let s = e.filter((e) => e != null && e !== !1);
11649
11684
  return /* @__PURE__ */ y(_, { children: [
11650
11685
  (n.length > 0 || t.length > 0) && /* @__PURE__ */ y("div", {
@@ -11666,31 +11701,34 @@ var jr = (e) => {
11666
11701
  })]
11667
11702
  }),
11668
11703
  s.length > 0 && /* @__PURE__ */ v("div", {
11669
- className: (0, X.default)("sf-board__kpis", `sf-board__kpis--${hl(s.length)}`),
11670
- children: s
11704
+ className: "sf-board__kpis-area",
11705
+ children: /* @__PURE__ */ v("div", {
11706
+ className: (0, X.default)("sf-board__kpis", `sf-board__kpis--${gl(s.length)}`),
11707
+ children: s
11708
+ })
11671
11709
  }),
11672
11710
  i,
11673
- a && /* @__PURE__ */ v(gl, { block: a }),
11674
- o && /* @__PURE__ */ v(gl, { block: o })
11711
+ a && /* @__PURE__ */ v(_l, { block: a }),
11712
+ o && /* @__PURE__ */ v(_l, { block: o })
11675
11713
  ] });
11676
- }, vl = ({ children: e, className: t }) => {
11714
+ }, yl = ({ children: e, className: t }) => {
11677
11715
  let n = e.filter(Boolean), r = n.length >= 3 ? 3 : 2;
11678
11716
  return /* @__PURE__ */ v("div", {
11679
11717
  className: (0, X.default)("sf-card-row", `sf-card-row--${r}`, t),
11680
11718
  children: n
11681
11719
  });
11682
- }, yl = (e) => {
11720
+ }, bl = (e) => {
11683
11721
  let [t, n] = h(0), [r, i] = h(e);
11684
11722
  return r !== e && (i(e), n(0)), u(() => {
11685
11723
  if (!e) return;
11686
11724
  let t = Date.now(), r = window.setInterval(() => n(Math.floor((Date.now() - t) / 1e3)), 1e3);
11687
11725
  return () => window.clearInterval(r);
11688
11726
  }, [e]), t;
11689
- }, bl = (e) => new Date(e).toLocaleTimeString("es-PE", {
11727
+ }, xl = (e) => new Date(e).toLocaleTimeString("es-PE", {
11690
11728
  hour: "2-digit",
11691
11729
  minute: "2-digit"
11692
- }), xl = ({ loading: e, updatedAt: t, live: n, cutoffLabel: r, onRefresh: i, refreshLabel: a, slowAfterSeconds: o }) => {
11693
- let s = yl(!!e), c = t ? bl(t) : null, l = c ? `datos de las ${c}` : "";
11730
+ }), Sl = ({ loading: e, updatedAt: t, live: n, cutoffLabel: r, onRefresh: i, refreshLabel: a, slowAfterSeconds: o }) => {
11731
+ let s = bl(!!e), c = t ? xl(t) : null, l = c ? `datos de las ${c}` : "";
11694
11732
  return e ? l = s >= o ? `calculando… ${s} s` : "calculando…" : n && c && (l = `datos en vivo · ${c}`), /* @__PURE__ */ y("div", {
11695
11733
  className: "sf-page-frame__status",
11696
11734
  "aria-live": "polite",
@@ -11714,15 +11752,15 @@ var jr = (e) => {
11714
11752
  })
11715
11753
  ]
11716
11754
  });
11717
- }, Sl = ({ title: e, subtitle: t, mode: n = "range", range: r, onApply: i, fromLabel: a = "Desde", toLabel: o = "Hasta", dayLabel: s = "Día de corte", compareFieldLabel: c = n === "day" ? "Nota" : "Comparar", validate: l, error: u = null, loading: d = !1, updatedAt: f = null, live: p = !1, cutoffLabel: m, onRefresh: g, refreshLabel: b = "Actualizar", compareLabel: x = n === "day" ? "" : "con el período anterior de igual duración", pendingLabel: S = n === "day" ? "Pulsa «Aplicar» para consultar el nuevo día" : "Pulsa «Aplicar» para consultar el nuevo rango", applyLabel: C = "Aplicar", filterAriaLabel: w = "Filtro del tablero", slowAfterSeconds: T = 3, className: E, children: D }) => {
11718
- let [O, k] = h(null), A = O && O.base.from === r.from && O.base.to === r.to ? O : null, j = A?.draft ?? r, M = A?.error ?? null, N = (e) => k({
11755
+ }, Cl = ({ title: e, subtitle: t, mode: n = "range", range: r, onApply: i, fromLabel: a = "Desde", toLabel: o = "Hasta", dayLabel: s = "Día de corte", compareFieldLabel: c = n === "day" ? "Nota" : "Comparar", validate: l, error: u = null, loading: d = !1, stale: f = !1, updatedAt: p = null, live: m = !1, cutoffLabel: g, onRefresh: b, refreshLabel: x = "Actualizar", compareLabel: S = n === "day" ? "" : "con el período anterior de igual duración", pendingLabel: C = n === "day" ? "Pulsa «Aplicar» para consultar el nuevo día" : "Pulsa «Aplicar» para consultar el nuevo rango", applyLabel: w = "Aplicar", filterAriaLabel: T = "Filtro del tablero", slowAfterSeconds: E = 3, className: D, children: O }) => {
11756
+ let [k, A] = h(null), j = k && k.base.from === r.from && k.base.to === r.to ? k : null, M = j?.draft ?? r, N = j?.error ?? null, P = (e) => A({
11719
11757
  base: r,
11720
11758
  draft: e,
11721
11759
  error: null
11722
- }), P = j.from !== r.from || j.to !== r.to;
11760
+ }), F = M.from !== r.from || M.to !== r.to;
11723
11761
  return /* @__PURE__ */ v("div", {
11724
- className: E,
11725
- children: /* @__PURE__ */ y(fl, {
11762
+ className: D,
11763
+ children: /* @__PURE__ */ y(pl, {
11726
11764
  header: /* @__PURE__ */ y("div", {
11727
11765
  className: "sf-page-frame__header",
11728
11766
  children: [/* @__PURE__ */ y("div", { children: [/* @__PURE__ */ v("h1", {
@@ -11731,85 +11769,90 @@ var jr = (e) => {
11731
11769
  }), t && /* @__PURE__ */ v("p", {
11732
11770
  className: "sf-page-frame__subtitle",
11733
11771
  children: t
11734
- })] }), /* @__PURE__ */ v(xl, {
11772
+ })] }), /* @__PURE__ */ v(Sl, {
11735
11773
  loading: d,
11736
- updatedAt: f,
11737
- live: p,
11738
- cutoffLabel: m,
11739
- onRefresh: g,
11740
- refreshLabel: b,
11741
- slowAfterSeconds: T
11774
+ updatedAt: p,
11775
+ live: m,
11776
+ cutoffLabel: g,
11777
+ onRefresh: b,
11778
+ refreshLabel: x,
11779
+ slowAfterSeconds: E
11742
11780
  })]
11743
11781
  }),
11744
11782
  children: [
11745
11783
  /* @__PURE__ */ y(Aa, {
11746
- ariaLabel: w,
11784
+ ariaLabel: T,
11747
11785
  onApply: () => {
11748
- let e = l ? l(j) : null;
11749
- k({
11786
+ let e = l ? l(M) : null;
11787
+ A({
11750
11788
  base: r,
11751
- draft: j,
11789
+ draft: M,
11752
11790
  error: e
11753
- }), e || i(j);
11791
+ }), e || i(M);
11754
11792
  },
11755
- applyLabel: C,
11756
- applyLoading: d && !P,
11793
+ applyLabel: w,
11794
+ applyLoading: d && !F,
11757
11795
  children: [n === "day" ? /* @__PURE__ */ v(ja, {
11758
11796
  label: s,
11759
11797
  className: "sf-page-frame__day",
11760
11798
  children: /* @__PURE__ */ v(Ma, {
11761
- value: j.to,
11762
- onChange: (e) => N({
11763
- ...j,
11799
+ value: M.to,
11800
+ onChange: (e) => P({
11801
+ ...M,
11764
11802
  to: e
11765
11803
  })
11766
11804
  })
11767
11805
  }) : /* @__PURE__ */ y(_, { children: [/* @__PURE__ */ v(ja, {
11768
11806
  label: a,
11769
11807
  children: /* @__PURE__ */ v(Ma, {
11770
- value: j.from,
11771
- onChange: (e) => N({
11772
- ...j,
11808
+ value: M.from,
11809
+ onChange: (e) => P({
11810
+ ...M,
11773
11811
  from: e
11774
11812
  })
11775
11813
  })
11776
11814
  }), /* @__PURE__ */ v(ja, {
11777
11815
  label: o,
11778
11816
  children: /* @__PURE__ */ v(Ma, {
11779
- value: j.to,
11780
- onChange: (e) => N({
11781
- ...j,
11817
+ value: M.to,
11818
+ onChange: (e) => P({
11819
+ ...M,
11782
11820
  to: e
11783
11821
  })
11784
11822
  })
11785
- })] }), (P ? S : x) && /* @__PURE__ */ v(ja, {
11823
+ })] }), (F ? C : S) && /* @__PURE__ */ v(ja, {
11786
11824
  label: c,
11787
11825
  children: /* @__PURE__ */ v("span", {
11788
11826
  className: "sf-page-frame__compare",
11789
- children: P ? S : x
11827
+ children: F ? C : S
11790
11828
  })
11791
11829
  })]
11792
11830
  }),
11793
- (M || u) && /* @__PURE__ */ v(ni, {
11831
+ (N || u) && /* @__PURE__ */ v(ni, {
11794
11832
  variant: "warning",
11795
11833
  title: "Rango no válido",
11796
- message: M ?? u
11834
+ message: N ?? u
11797
11835
  }),
11798
- u ? null : D
11836
+ u ? null : /* @__PURE__ */ v("div", {
11837
+ className: "sf-page-frame__content",
11838
+ "data-stale": f ? "" : void 0,
11839
+ "aria-busy": f || void 0,
11840
+ children: O
11841
+ })
11799
11842
  ]
11800
11843
  })
11801
11844
  });
11802
- }, Cl = [
11845
+ }, wl = [
11803
11846
  70,
11804
11847
  55,
11805
11848
  40,
11806
11849
  25
11807
- ], wl = ({ shape: e }) => e === "chart" ? /* @__PURE__ */ v(fi, {
11850
+ ], Tl = ({ shape: e }) => e === "chart" ? /* @__PURE__ */ v(fi, {
11808
11851
  variant: "block",
11809
11852
  height: 220
11810
11853
  }) : /* @__PURE__ */ v("div", {
11811
11854
  className: "sf-placeholder__rows",
11812
- children: Cl.map((t) => /* @__PURE__ */ y("div", {
11855
+ children: wl.map((t) => /* @__PURE__ */ y("div", {
11813
11856
  className: "sf-placeholder__row",
11814
11857
  children: [/* @__PURE__ */ v(fi, {
11815
11858
  variant: "text",
@@ -11820,7 +11863,7 @@ var jr = (e) => {
11820
11863
  width: `${t}%`
11821
11864
  })]
11822
11865
  }, t))
11823
- }), Tl = ({ title: e, shape: t = "kpi", state: n = "loading", errorMessage: r = "No se pudo obtener este dato. Vuelve a intentarlo en unos minutos.", onRetry: i, className: a }) => n === "error" ? /* @__PURE__ */ v(il, {
11866
+ }), El = ({ title: e, shape: t = "kpi", state: n = "loading", errorMessage: r = "No se pudo obtener este dato. Vuelve a intentarlo en unos minutos.", onRetry: i, className: a }) => n === "error" ? /* @__PURE__ */ v(al, {
11824
11867
  title: e,
11825
11868
  headerSize: "md",
11826
11869
  headerDivider: !1,
@@ -11828,7 +11871,7 @@ var jr = (e) => {
11828
11871
  errorMessage: r,
11829
11872
  onRetry: i,
11830
11873
  className: a
11831
- }) : t === "kpi" ? /* @__PURE__ */ v(il, {
11874
+ }) : t === "kpi" ? /* @__PURE__ */ v(al, {
11832
11875
  padding: "lg",
11833
11876
  className: a,
11834
11877
  children: /* @__PURE__ */ y("div", {
@@ -11858,7 +11901,7 @@ var jr = (e) => {
11858
11901
  ]
11859
11902
  })]
11860
11903
  })
11861
- }) : /* @__PURE__ */ v(il, {
11904
+ }) : /* @__PURE__ */ v(al, {
11862
11905
  title: e,
11863
11906
  headerSize: "md",
11864
11907
  headerWrap: !0,
@@ -11867,14 +11910,14 @@ var jr = (e) => {
11867
11910
  children: /* @__PURE__ */ v("div", {
11868
11911
  role: "status",
11869
11912
  "aria-label": `Cargando ${e}`,
11870
- children: /* @__PURE__ */ v(wl, { shape: t })
11913
+ children: /* @__PURE__ */ v(Tl, { shape: t })
11871
11914
  })
11872
- }), El = (e) => {
11915
+ }), Dl = (e) => {
11873
11916
  let t = String(e ?? ""), n = 0;
11874
11917
  for (; n < t.length && t.charCodeAt(n) <= 32;) n += 1;
11875
11918
  let r = t.slice(n);
11876
11919
  return /^[=+\-@]/.test(r) ? `'${t}` : t;
11877
- }, Dl = (e) => El(e).replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;"), Ol = (e) => typeof e == "number" && Number.isFinite(e) ? "Number" : "String", kl = (e, t) => {
11920
+ }, Ol = (e) => Dl(e).replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;"), kl = (e) => typeof e == "number" && Number.isFinite(e) ? "Number" : "String", Al = (e, t) => {
11878
11921
  if (typeof document > "u") return;
11879
11922
  let { columns: n, filename: r = "export.xls" } = t, i = `<?xml version="1.0"?>
11880
11923
  <?mso-application progid="Excel.Sheet"?>
@@ -11887,30 +11930,30 @@ var jr = (e) => {
11887
11930
  </Styles>
11888
11931
  <Worksheet ss:Name="Export">
11889
11932
  <Table>
11890
- <Row>${n.map((e) => `<Cell ss:StyleID="Header"><Data ss:Type="String">${Dl(e.header)}</Data></Cell>`).join("")}</Row>
11933
+ <Row>${n.map((e) => `<Cell ss:StyleID="Header"><Data ss:Type="String">${Ol(e.header)}</Data></Cell>`).join("")}</Row>
11891
11934
  ${e.map((e) => `<Row>${n.map((t) => {
11892
- let n = t.getValue(e), r = Ol(n);
11893
- return `<Cell><Data ss:Type="${r}">${r === "Number" ? String(n) : Dl(n)}</Data></Cell>`;
11935
+ let n = t.getValue(e), r = kl(n);
11936
+ return `<Cell><Data ss:Type="${r}">${r === "Number" ? String(n) : Ol(n)}</Data></Cell>`;
11894
11937
  }).join("")}</Row>`).join("")}
11895
11938
  </Table>
11896
11939
  </Worksheet>
11897
11940
  </Workbook>`, a = new Blob([i], { type: "application/vnd.ms-excel" }), o = URL.createObjectURL(a), s = document.createElement("a");
11898
11941
  s.href = o, s.download = r.endsWith(".xls") || r.endsWith(".xlsx") ? r : `${r}.xls`, s.click(), URL.revokeObjectURL(o);
11899
- }, Al = () => {
11942
+ }, jl = () => {
11900
11943
  let [e, t] = h(null);
11901
11944
  return {
11902
11945
  open: e,
11903
11946
  toggle: (e) => t((t) => t?.id === e.id ? null : e),
11904
11947
  close: () => t(null)
11905
11948
  };
11906
- }, jl = (e, t) => `Mostrando ${e} de ${t} — exporta a Excel para ver la lista completa.`, Ml = (e) => `${e} registro${e === 1 ? "" : "s"}.`, Nl = ({ detail: e, rowMapper: t = (e) => e, subtitle: n = "Registros detrás de la cifra", countLabel: r = (e) => `${e} registros`, previewRows: i = 10, previewNote: a = jl, totalNote: o = Ml, emptyMessage: s = "Sin registros en este caso", closeLabel: c = "Cerrar detalle", exportLabel: l = "Exportar Excel", exportFilename: u = (e, t) => t ? `${e.id}-${t}` : e.id, actions: d }) => {
11949
+ }, Ml = (e, t) => `Mostrando ${e} de ${t} — exporta a Excel para ver la lista completa.`, Nl = (e) => `${e} registro${e === 1 ? "" : "s"}.`, Pl = ({ detail: e, rowMapper: t = (e) => e, subtitle: n = "Registros detrás de la cifra", countLabel: r = (e) => `${e} registros`, previewRows: i = 10, previewNote: a = Ml, totalNote: o = Nl, emptyMessage: s = "Sin registros en este caso", closeLabel: c = "Cerrar detalle", exportLabel: l = "Exportar Excel", exportFilename: u = (e, t) => t ? `${e.id}-${t}` : e.id, actions: d }) => {
11907
11950
  let f = e.open, [p, m] = h(null);
11908
11951
  if (!f) return null;
11909
11952
  let g = p?.specId === f.id ? p.groupId : null, _ = f.groups?.find((e) => e.id === g) ?? f.groups?.[0] ?? null, b = _ ? _.rows : f.rows, x = b.map(t), S = f.columns.map((e) => ({
11910
11953
  accessorKey: e.key,
11911
11954
  header: e.header
11912
11955
  })), C = f.groups ? f.groups.reduce((e, t) => e + t.rows.length, 0) : f.rows.length;
11913
- return /* @__PURE__ */ y(il, {
11956
+ return /* @__PURE__ */ y(al, {
11914
11957
  title: f.title,
11915
11958
  subtitle: n,
11916
11959
  headerAction: /* @__PURE__ */ y("div", {
@@ -11945,20 +11988,23 @@ ${e.map((e) => `<Row>${n.map((t) => {
11945
11988
  label: e.title,
11946
11989
  count: e.rows.length
11947
11990
  }))
11948
- }), _.note && /* @__PURE__ */ v(ml, {
11991
+ }), _.note && /* @__PURE__ */ v(hl, {
11949
11992
  text: _.note,
11950
11993
  className: "sf-detail-panel__group-note"
11951
11994
  })]
11952
11995
  }),
11953
- /* @__PURE__ */ v(kr, {
11954
- data: x.slice(0, i),
11955
- columns: S,
11956
- title: "",
11957
- enableRowSelection: !1,
11958
- enableSorting: !1,
11959
- enableFiltering: !1,
11960
- enablePagination: !1,
11961
- emptyMessage: s
11996
+ /* @__PURE__ */ v("div", {
11997
+ className: "sf-detail-panel__table",
11998
+ children: /* @__PURE__ */ v(kr, {
11999
+ data: x.slice(0, i),
12000
+ columns: S,
12001
+ title: "",
12002
+ enableRowSelection: !1,
12003
+ enableSorting: !1,
12004
+ enableFiltering: !1,
12005
+ enablePagination: !1,
12006
+ emptyMessage: s
12007
+ })
11962
12008
  }),
11963
12009
  /* @__PURE__ */ y("div", {
11964
12010
  className: "sf-detail-panel__footer",
@@ -11977,12 +12023,12 @@ ${e.map((e) => `<Row>${n.map((t) => {
11977
12023
  size: "sm",
11978
12024
  icon: /* @__PURE__ */ v(mt, {}),
11979
12025
  disabled: b.length === 0,
11980
- onClick: () => kl(x, {
12026
+ onClick: () => Al(x, {
11981
12027
  filename: `${u(f, _?.id ?? null)}.xls`,
11982
12028
  columns: f.columns.map((e) => ({
11983
12029
  id: e.key,
11984
12030
  header: e.header,
11985
- getValue: (t) => String(t[e.key] ?? "")
12031
+ getValue: (t) => String(t[e.exportKey ?? e.key] ?? "")
11986
12032
  }))
11987
12033
  }),
11988
12034
  children: l
@@ -11991,8 +12037,8 @@ ${e.map((e) => `<Row>${n.map((t) => {
11991
12037
  })
11992
12038
  ]
11993
12039
  });
11994
- }, Pl = (e) => e != null && (e.rows.length > 0 || (e.groups ?? []).some((e) => e.rows.length > 0)), Fl = ({ label: e, value: t, sublabel: n, icon: r, accentTone: i, primary: a = !1, trend: o = null, trendDirection: s = "neutral", trendLabel: c = "vs. período anterior", detail: l, spec: u }) => {
11995
- let d = Pl(u);
12040
+ }, Fl = (e) => e != null && (e.rows.length > 0 || (e.groups ?? []).some((e) => e.rows.length > 0)), Il = ({ label: e, value: t, sublabel: n, icon: r, accentTone: i, primary: a = !1, trend: o = null, trendDirection: s = "neutral", trendLabel: c = "vs. período anterior", detail: l, spec: u }) => {
12041
+ let d = Fl(u);
11996
12042
  return /* @__PURE__ */ v(As, {
11997
12043
  layout: "leading-icon",
11998
12044
  size: "lg",
@@ -12010,21 +12056,21 @@ ${e.map((e) => `<Row>${n.map((t) => {
12010
12056
  selected: u != null && l.open?.id === u.id,
12011
12057
  onClick: d ? () => l.toggle(u) : void 0
12012
12058
  });
12013
- }, Il = ({ items: e, detail: t, zeroTone: n = "success", emptyMessage: r = "Nada pendiente" }) => {
12059
+ }, Ll = ({ items: e, detail: t, zeroTone: n = "success", emptyMessage: r = "Nada pendiente" }) => {
12014
12060
  let i = e.map((e) => ({
12015
12061
  label: e.label,
12016
12062
  description: e.description,
12017
12063
  value: e.value,
12018
12064
  tone: e.count > 0 ? e.tone : n,
12019
- onClick: Pl(e.spec) ? () => t.toggle(e.spec) : void 0
12065
+ onClick: Fl(e.spec) ? () => t.toggle(e.spec) : void 0
12020
12066
  }));
12021
- return /* @__PURE__ */ v(il, { children: /* @__PURE__ */ v(Yc, {
12067
+ return /* @__PURE__ */ v(al, { children: /* @__PURE__ */ v(Xc, {
12022
12068
  items: i,
12023
12069
  showIcon: !0,
12024
12070
  showChevron: !0,
12025
12071
  emptyMessage: r
12026
12072
  }) });
12027
- }, Ll = ({ items: e, total: t, totalLabel: n, unit: r = "registros", previewCount: i = 5, emptyText: a, onOpen: o, openLabel: s = "Ver detalle" }) => {
12073
+ }, Rl = ({ items: e, total: t, totalLabel: n, unit: r = "registros", previewCount: i = 5, emptyText: a, onOpen: o, openLabel: s = "Ver detalle" }) => {
12028
12074
  if (t === 0) return /* @__PURE__ */ v("p", {
12029
12075
  className: "sf-detail-preview__empty",
12030
12076
  children: a
@@ -12072,7 +12118,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12072
12118
  }) })
12073
12119
  ]
12074
12120
  });
12075
- }, Rl = ({ title: e, icon: t, tone: n = "default", rows: r = [], children: i, className: a, density: o = "md" }) => {
12121
+ }, zl = ({ title: e, icon: t, tone: n = "default", rows: r = [], children: i, className: a, density: o = "md" }) => {
12076
12122
  let s = r.length > 0 || !!i;
12077
12123
  return /* @__PURE__ */ y("section", {
12078
12124
  className: (0, X.default)("sf-detail-section", n !== "default" && `sf-detail-section--${n}`, o === "sm" && "sf-detail-section--sm", a),
@@ -12113,15 +12159,15 @@ ${e.map((e) => `<Row>${n.map((t) => {
12113
12159
  })]
12114
12160
  })]
12115
12161
  });
12116
- }, zl = ({ small: e, error: t }) => (0, X.default)("sf-input", "sf-input--otp", e && "sf-input--sm", t && "sf-input--error"), Bl = (e, t) => {
12162
+ }, Bl = ({ small: e, error: t }) => (0, X.default)("sf-input", "sf-input--otp", e && "sf-input--sm", t && "sf-input--error"), Vl = (e, t) => {
12117
12163
  let n = ln(String(e ?? ""), t);
12118
12164
  return Array.from({ length: t }, (e, t) => n[t] ?? "");
12119
- }, Vl = ({ form: e, name: t, label: n, info: r, required: i, disabled: a, small: o, className: s, length: c = 6, onChange: l }) => {
12165
+ }, Hl = ({ form: e, name: t, label: n, info: r, required: i, disabled: a, small: o, className: s, length: c = 6, onChange: l }) => {
12120
12166
  let u = b({
12121
12167
  name: t,
12122
12168
  control: e.control
12123
- }), d = m([]), [f, p] = h(() => Bl(u.field.value, c)), [g, _] = h(u.field.value);
12124
- u.field.value !== g && (_(u.field.value), p(Bl(u.field.value, c)));
12169
+ }), d = m([]), [f, p] = h(() => Vl(u.field.value, c)), [g, _] = h(u.field.value);
12170
+ u.field.value !== g && (_(u.field.value), p(Vl(u.field.value, c)));
12125
12171
  let y = String(t), x = u.fieldState.error?.message ? String(u.fieldState.error.message) : void 0, S = (e) => {
12126
12172
  p(e);
12127
12173
  let t = e.join("");
@@ -12165,7 +12211,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12165
12211
  onBlur: () => u.field.onBlur(),
12166
12212
  onChange: (e) => C(t, e.target.value),
12167
12213
  onKeyDown: (e) => w(t, e),
12168
- className: zl({
12214
+ className: Bl({
12169
12215
  small: o,
12170
12216
  error: !!x,
12171
12217
  disabled: a
@@ -12173,15 +12219,15 @@ ${e.map((e) => `<Row>${n.map((t) => {
12173
12219
  }, t))
12174
12220
  })
12175
12221
  });
12176
- }, Hl = (e) => {
12222
+ }, Ul = (e) => {
12177
12223
  let [t, n] = e.slice(0, 10).split("-").map(Number), r = new Date(t, n, 0).getDate();
12178
12224
  return `${t}-${String(n).padStart(2, "0")}-${String(r).padStart(2, "0")}`;
12179
- }, Ul = ({ form: e, startName: t, endName: n, startLabel: r = "Desde", endLabel: i = "Hasta", required: a, endRequired: o, small: s, readOnlyEnd: c, adjustEnd: l = "start", onEndAdjusted: u, className: d }) => {
12225
+ }, Wl = ({ form: e, startName: t, endName: n, startLabel: r = "Desde", endLabel: i = "Hasta", required: a, endRequired: o, small: s, readOnlyEnd: c, adjustEnd: l = "start", onEndAdjusted: u, className: d }) => {
12180
12226
  let f = String(e.watch(t) ?? ""), p = (t, r) => {
12181
12227
  if (l === "none") return;
12182
12228
  let i = t.slice(0, 10), a = r.slice(0, 10);
12183
12229
  if (!Mn(i) || !Mn(a) || a >= i) return;
12184
- let o = l === "month-end" ? Hl(i) : i;
12230
+ let o = l === "month-end" ? Ul(i) : i;
12185
12231
  e.setValue(n, o, { shouldValidate: !1 }), u?.(o);
12186
12232
  };
12187
12233
  return /* @__PURE__ */ y("div", {
@@ -12206,16 +12252,16 @@ ${e.map((e) => `<Row>${n.map((t) => {
12206
12252
  onChange: (n) => p(String(e.getValues(t) ?? ""), n)
12207
12253
  })]
12208
12254
  });
12209
- }, Wl = (e) => /* @__PURE__ */ v(Rn, {
12255
+ }, Gl = (e) => /* @__PURE__ */ v(Rn, {
12210
12256
  ...e,
12211
12257
  utc: !0
12212
- }), Gl = () => ({
12258
+ }), Kl = () => ({
12213
12259
  start: "",
12214
12260
  end: ""
12215
- }), Kl = () => ({
12261
+ }), ql = () => ({
12216
12262
  start: "",
12217
12263
  end: ""
12218
- }), ql = 0, Jl = () => (ql += 1, `photo_${Date.now()}_${ql}`), Yl = (e, t) => {
12264
+ }), Jl = 0, Yl = () => (Jl += 1, `photo_${Date.now()}_${Jl}`), Xl = (e, t) => {
12219
12265
  if (!t || t === "*") return !0;
12220
12266
  let n = t.replace(/\s/g, "").split(","), r = `.${e.name.split(".").pop()?.toLowerCase() ?? ""}`, i = e.type.toLowerCase();
12221
12267
  return n.some((e) => {
@@ -12227,20 +12273,20 @@ ${e.map((e) => `<Row>${n.map((t) => {
12227
12273
  }
12228
12274
  return i === t;
12229
12275
  });
12230
- }, Xl = (e, t = !1) => new Promise((n) => {
12276
+ }, Zl = (e, t = !1) => new Promise((n) => {
12231
12277
  let r = document.createElement("input");
12232
12278
  r.type = "file", r.accept = e, r.multiple = t, r.style.display = "none", r.onchange = () => {
12233
12279
  n(Array.from(r.files ?? [])), r.remove();
12234
12280
  }, document.body.appendChild(r), r.click();
12235
- }), Zl = (e) => ({
12236
- id: Jl(),
12281
+ }), Ql = (e) => ({
12282
+ id: Yl(),
12237
12283
  preview: URL.createObjectURL(e),
12238
12284
  file: e
12239
- }), Ql = (e) => {
12285
+ }), $l = (e) => {
12240
12286
  URL.revokeObjectURL(e.preview);
12241
- }, $l = (e) => {
12242
- e.forEach(Ql);
12243
- }, eu = (e) => Array.isArray(e) ? e.filter((e) => typeof e == "object" && !!e && typeof e.id == "string" && typeof e.preview == "string" && e.file instanceof File) : [], tu = (e, t = .92) => new Promise((n, r) => {
12287
+ }, eu = (e) => {
12288
+ e.forEach($l);
12289
+ }, tu = (e) => Array.isArray(e) ? e.filter((e) => typeof e == "object" && !!e && typeof e.id == "string" && typeof e.preview == "string" && e.file instanceof File) : [], nu = (e, t = .92) => new Promise((n, r) => {
12244
12290
  let i = URL.createObjectURL(e), a = new Image();
12245
12291
  a.onload = () => {
12246
12292
  let o = Math.min(a.width, a.height), s = (a.width - o) / 2, c = (a.height - o) / 2, l = document.createElement("canvas");
@@ -12263,7 +12309,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12263
12309
  }, a.onerror = () => {
12264
12310
  URL.revokeObjectURL(i), r(/* @__PURE__ */ Error("Imagen inválida"));
12265
12311
  }, a.src = i;
12266
- }), nu = (e) => e.length === 0 ? "Arrastra archivos o haz clic" : e.length === 1 ? e[0].name : `${e.length} archivos seleccionados`, ru = (e) => `${e.name}-${e.lastModified}-${e.size}`, iu = ({ form: e, name: t, label: n, info: r, required: i, accept: a = "*", multiple: o = !1, maxSizeMb: s = 10, dropLabel: c, readOnly: l, disabled: u, small: d, className: f, onChange: p, onUpload: g, onRefresh: _ }) => {
12312
+ }), ru = (e) => e.length === 0 ? "Arrastra archivos o haz clic" : e.length === 1 ? e[0].name : `${e.length} archivos seleccionados`, iu = (e) => `${e.name}-${e.lastModified}-${e.size}`, au = ({ form: e, name: t, label: n, info: r, required: i, accept: a = "*", multiple: o = !1, maxSizeMb: s = 10, dropLabel: c, readOnly: l, disabled: u, small: d, className: f, onChange: p, onUpload: g, onRefresh: _ }) => {
12267
12313
  let x = m(null), S = b({
12268
12314
  name: t,
12269
12315
  control: e.control
@@ -12272,7 +12318,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12272
12318
  return e ? Array.isArray(e) ? e : [e] : [];
12273
12319
  })(), L = async (e) => {
12274
12320
  if (g) for (let t of e) {
12275
- let e = ru(t);
12321
+ let e = iu(t);
12276
12322
  O((t) => new Set(t).add(e)), E((t) => ({
12277
12323
  ...t,
12278
12324
  [e]: 0
@@ -12297,7 +12343,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12297
12343
  }
12298
12344
  }
12299
12345
  }, R = (e) => {
12300
- let t = s * 1024 * 1024, n = e.filter((e) => e.size <= t && Yl(e, a)), r = e.length - n.length;
12346
+ let t = s * 1024 * 1024, n = e.filter((e) => e.size <= t && Xl(e, a)), r = e.length - n.length;
12301
12347
  if (A(r > 0 ? `${r} archivo(s) no cumplen tipo o tamaño máximo.` : null), o) {
12302
12348
  let e = [...I, ...n];
12303
12349
  S.field.onChange(e), p?.(e), L(n);
@@ -12351,7 +12397,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12351
12397
  className: (0, X.default)("sf-file-drop", C && "sf-file-drop--dragging", !P && "sf-file-drop--interactive", P && "sf-file-drop--disabled", d ? "sf-file-drop--sm" : "sf-file-drop--md", N && "sf-file-drop--error"),
12352
12398
  children: [/* @__PURE__ */ v("span", {
12353
12399
  className: "sf-file-drop__title",
12354
- children: C ? "Suelta aquí" : c ?? nu(I)
12400
+ children: C ? "Suelta aquí" : c ?? ru(I)
12355
12401
  }), /* @__PURE__ */ y("span", {
12356
12402
  className: "sf-file-drop__hint",
12357
12403
  children: [
@@ -12366,7 +12412,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12366
12412
  className: "sf-file-list",
12367
12413
  "aria-label": "Archivos seleccionados",
12368
12414
  children: I.map((e) => {
12369
- let t = ru(e), n = T[t], r = D.has(t);
12415
+ let t = iu(e), n = T[t], r = D.has(t);
12370
12416
  return /* @__PURE__ */ y("li", {
12371
12417
  className: "sf-file-list__item",
12372
12418
  children: [/* @__PURE__ */ y("span", {
@@ -12395,7 +12441,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12395
12441
  ]
12396
12442
  })
12397
12443
  });
12398
- }, au = ({ form: e, name: t, label: n, info: r, required: i, capture: a, maxSizeMb: o = 5, readOnly: c, disabled: l, small: d, className: f, onChange: g, onRefresh: _ }) => {
12444
+ }, ou = ({ form: e, name: t, label: n, info: r, required: i, capture: a, maxSizeMb: o = 5, readOnly: c, disabled: l, small: d, className: f, onChange: g, onRefresh: _ }) => {
12399
12445
  let x = m(null), S = b({
12400
12446
  name: t,
12401
12447
  control: e.control
@@ -12485,7 +12531,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12485
12531
  ]
12486
12532
  })
12487
12533
  });
12488
- }, ou = ({ form: e, name: t, label: n, info: r, required: i, width: a = 400, height: o = 160, readOnly: c, disabled: l, className: d, onChange: f, onRefresh: p }) => {
12534
+ }, su = ({ form: e, name: t, label: n, info: r, required: i, width: a = 400, height: o = 160, readOnly: c, disabled: l, className: d, onChange: f, onRefresh: p }) => {
12489
12535
  let g = m(null), _ = m(!1), x = m(null), S = m(void 0), C = b({
12490
12536
  name: t,
12491
12537
  control: e.control
@@ -12577,11 +12623,11 @@ ${e.map((e) => `<Row>${n.map((t) => {
12577
12623
  })]
12578
12624
  })
12579
12625
  });
12580
- }, su = ({ form: e, name: t, label: n, info: r, required: i, max: a = 10, maxSizeMb: o = 5, camera: c = !1, readOnly: l, disabled: d, small: f, className: g, onChange: _, onRefresh: x }) => {
12626
+ }, cu = ({ form: e, name: t, label: n, info: r, required: i, max: a = 10, maxSizeMb: o = 5, camera: c = !1, readOnly: l, disabled: d, small: f, className: g, onChange: _, onRefresh: x }) => {
12581
12627
  let S = m(null), C = b({
12582
12628
  name: t,
12583
12629
  control: e.control
12584
- }), w = String(t), T = C.fieldState.error?.message ? String(C.fieldState.error.message) : void 0, [E, D] = h(null), O = T ?? E ?? void 0, k = l || d, A = p(() => eu(C.field.value), [C.field.value]), j = p(() => !k && A.length < a, [
12630
+ }), w = String(t), T = C.fieldState.error?.message ? String(C.fieldState.error.message) : void 0, [E, D] = h(null), O = T ?? E ?? void 0, k = l || d, A = p(() => tu(C.field.value), [C.field.value]), j = p(() => !k && A.length < a, [
12585
12631
  k,
12586
12632
  a,
12587
12633
  A.length
@@ -12589,7 +12635,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12589
12635
  u(() => {
12590
12636
  N.current = A;
12591
12637
  }, [A]), u(() => () => {
12592
- for (let e of N.current) Ql(e);
12638
+ for (let e of N.current) $l(e);
12593
12639
  }, []);
12594
12640
  let P = s((e) => {
12595
12641
  C.field.onChange(e), _?.(e);
@@ -12604,7 +12650,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12604
12650
  D(`Hay imágenes que superan ${o} MB.`);
12605
12651
  return;
12606
12652
  }
12607
- let r = a - A.length, i = n.slice(0, r).map((e) => Zl(e));
12653
+ let r = a - A.length, i = n.slice(0, r).map((e) => Ql(e));
12608
12654
  if (n.length > r) {
12609
12655
  D(`Solo puedes agregar ${r} imagen(es) más.`);
12610
12656
  return;
@@ -12617,7 +12663,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12617
12663
  A
12618
12664
  ]), I = s((e) => {
12619
12665
  let t = A.find((t) => t.id === e);
12620
- t && Ql(t), P(A.filter((t) => t.id !== e));
12666
+ t && $l(t), P(A.filter((t) => t.id !== e));
12621
12667
  }, [P, A]);
12622
12668
  return /* @__PURE__ */ v(Z, {
12623
12669
  id: w,
@@ -12689,19 +12735,19 @@ ${e.map((e) => `<Row>${n.map((t) => {
12689
12735
  ]
12690
12736
  })
12691
12737
  });
12692
- }, cu = (e) => {
12738
+ }, lu = (e) => {
12693
12739
  switch (e.kind) {
12694
- case "photo": return /* @__PURE__ */ v(au, { ...e });
12695
- case "multiPhoto": return /* @__PURE__ */ v(su, { ...e });
12696
- case "signature": return /* @__PURE__ */ v(ou, { ...e });
12740
+ case "photo": return /* @__PURE__ */ v(ou, { ...e });
12741
+ case "multiPhoto": return /* @__PURE__ */ v(cu, { ...e });
12742
+ case "signature": return /* @__PURE__ */ v(su, { ...e });
12697
12743
  case "file": return /* @__PURE__ */ v(Un, { ...e });
12698
12744
  default: return null;
12699
12745
  }
12700
- }, lu = (e) => new Promise((t, n) => {
12746
+ }, uu = (e) => new Promise((t, n) => {
12701
12747
  let r = new Image();
12702
12748
  r.addEventListener("load", () => t(r)), r.addEventListener("error", () => n(/* @__PURE__ */ Error("No se pudo cargar la imagen"))), r.setAttribute("crossOrigin", "anonymous"), r.src = e;
12703
- }), uu = async (e, t, n, r = "image/jpeg") => {
12704
- let i = await lu(e), a = document.createElement("canvas");
12749
+ }), du = async (e, t, n, r = "image/jpeg") => {
12750
+ let i = await uu(e), a = document.createElement("canvas");
12705
12751
  a.width = t.width, a.height = t.height;
12706
12752
  let o = a.getContext("2d");
12707
12753
  if (!o) throw Error("Canvas no disponible");
@@ -12714,7 +12760,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12714
12760
  e(new File([i], n, { type: r }));
12715
12761
  }, r, .92);
12716
12762
  });
12717
- }, du = ({ imageUrl: e, fileName: t, aspect: n = 1, onCancel: r, onConfirm: i, className: a }) => {
12763
+ }, fu = ({ imageUrl: e, fileName: t, aspect: n = 1, onCancel: r, onConfirm: i, className: a }) => {
12718
12764
  let [o, c] = h({
12719
12765
  x: 0,
12720
12766
  y: 0
@@ -12725,7 +12771,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12725
12771
  m(!0);
12726
12772
  try {
12727
12773
  let n = t.toLowerCase().endsWith(".png") ? "image/png" : "image/jpeg";
12728
- i(await uu(e, d, t, n));
12774
+ i(await du(e, d, t, n));
12729
12775
  } finally {
12730
12776
  m(!1);
12731
12777
  }
@@ -12776,7 +12822,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12776
12822
  })
12777
12823
  ]
12778
12824
  });
12779
- }, fu = ({ form: e, name: t, label: n, info: r, required: i, maxSizeMb: a = 5, interactive: o = !0, aspect: c = 1, readOnly: l, disabled: d, small: f, className: g, onChange: _, onRefresh: x }) => {
12825
+ }, pu = ({ form: e, name: t, label: n, info: r, required: i, maxSizeMb: a = 5, interactive: o = !0, aspect: c = 1, readOnly: l, disabled: d, small: f, className: g, onChange: _, onRefresh: x }) => {
12780
12826
  let S = m(null), C = b({
12781
12827
  name: t,
12782
12828
  control: e.control
@@ -12805,7 +12851,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12805
12851
  }
12806
12852
  T(!0);
12807
12853
  try {
12808
- let t = await tu(e);
12854
+ let t = await nu(e);
12809
12855
  I(t);
12810
12856
  } finally {
12811
12857
  T(!1);
@@ -12897,7 +12943,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12897
12943
  role: "dialog",
12898
12944
  "aria-modal": "true",
12899
12945
  "aria-label": "Editor de recorte",
12900
- children: /* @__PURE__ */ v(du, {
12946
+ children: /* @__PURE__ */ v(fu, {
12901
12947
  imageUrl: E.url,
12902
12948
  fileName: E.fileName,
12903
12949
  aspect: c,
@@ -12909,7 +12955,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12909
12955
  })]
12910
12956
  })]
12911
12957
  });
12912
- }, pu = () => [], mu = ({ title: e, description: t, className: n, children: r }) => /* @__PURE__ */ y("section", {
12958
+ }, mu = () => [], hu = ({ title: e, description: t, className: n, children: r }) => /* @__PURE__ */ y("section", {
12913
12959
  className: (0, X.default)("sf-neutral-map-frame", n),
12914
12960
  children: [(e || t) && /* @__PURE__ */ y("div", {
12915
12961
  className: "sf-neutral-map-frame__header",
@@ -12921,11 +12967,11 @@ ${e.map((e) => `<Row>${n.map((t) => {
12921
12967
  children: t
12922
12968
  })]
12923
12969
  }), r]
12924
- }), hu = ({ tone: e = "info", children: t }) => /* @__PURE__ */ v("p", {
12970
+ }), gu = ({ tone: e = "info", children: t }) => /* @__PURE__ */ v("p", {
12925
12971
  className: (0, X.default)("sf-neutral-map-status", `sf-neutral-map-status--${e}`),
12926
12972
  role: e === "error" ? "alert" : "status",
12927
12973
  children: t
12928
- }), gu = ({ items: e, className: t }) => /* @__PURE__ */ v("div", {
12974
+ }), _u = ({ items: e, className: t }) => /* @__PURE__ */ v("div", {
12929
12975
  className: (0, X.default)("sf-map-legend", t),
12930
12976
  role: "list",
12931
12977
  "aria-label": "Leyenda del mapa",
@@ -12952,7 +12998,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12952
12998
  })
12953
12999
  ]
12954
13000
  }, t))
12955
- }), _u = ({ mapType: e, onMapTypeChange: t, onFullscreen: n, onLayers: r, className: i }) => /* @__PURE__ */ y("div", {
13001
+ }), vu = ({ mapType: e, onMapTypeChange: t, onFullscreen: n, onLayers: r, className: i }) => /* @__PURE__ */ y("div", {
12956
13002
  className: (0, X.default)("sf-map-toolbar", i),
12957
13003
  children: [
12958
13004
  /* @__PURE__ */ y("div", {
@@ -12990,7 +13036,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
12990
13036
  children: /* @__PURE__ */ v(lt, { "aria-hidden": "true" })
12991
13037
  })
12992
13038
  ]
12993
- }), vu = ({ title: e, subtitle: t, statusLabel: n, statusColor: r, speedKmh: i, onClick: a, className: o }) => /* @__PURE__ */ y("div", {
13039
+ }), yu = ({ title: e, subtitle: t, statusLabel: n, statusColor: r, speedKmh: i, onClick: a, className: o }) => /* @__PURE__ */ y("div", {
12994
13040
  className: (0, X.default)("sf-map-vehicle-popup", a && "sf-map-vehicle-popup--interactive", o),
12995
13041
  onClick: a,
12996
13042
  onKeyDown: (e) => {
@@ -13030,7 +13076,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
13030
13076
  ]
13031
13077
  })
13032
13078
  ]
13033
- }), yu = ({ title: e = "Lo que encontré aquí", items: t, loading: n, error: r, warning: i, onClose: a, className: o }) => {
13079
+ }), bu = ({ title: e = "Lo que encontré aquí", items: t, loading: n, error: r, warning: i, onClose: a, className: o }) => {
13034
13080
  let s = t.filter((e) => e.value !== void 0 && e.value !== null && e.value !== "");
13035
13081
  return /* @__PURE__ */ y("section", {
13036
13082
  className: (0, X.default)("sf-map-point-card", o),
@@ -13084,51 +13130,51 @@ ${e.map((e) => `<Row>${n.map((t) => {
13084
13130
  })
13085
13131
  ]
13086
13132
  });
13087
- }, bu = "Maps config not found. Wrap your app with <SfProvider maps={...}>.", xu = {
13133
+ }, xu = "Maps config not found. Wrap your app with <SfProvider maps={...}>.", Su = {
13088
13134
  lat: -12.0464,
13089
13135
  lng: -77.0428
13090
- }, Su = 13, Cu = "https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png", wu = "&copy; <a href=\"https://www.openstreetmap.org/copyright\" target=\"_blank\" rel=\"noreferrer\">OpenStreetMap</a>", Tu = "https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}", Eu = "Imagen &copy; <a href=\"https://www.esri.com\" target=\"_blank\" rel=\"noreferrer\">Esri</a>, Maxar, Earthstar Geographics", Du = {
13136
+ }, Cu = 13, wu = "https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png", Tu = "&copy; <a href=\"https://www.openstreetmap.org/copyright\" target=\"_blank\" rel=\"noreferrer\">OpenStreetMap</a>", Eu = "https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}", Du = "Imagen &copy; <a href=\"https://www.esri.com\" target=\"_blank\" rel=\"noreferrer\">Esri</a>, Maxar, Earthstar Geographics", Ou = {
13091
13137
  drawing: "basic",
13092
13138
  streetView: "none",
13093
13139
  clustering: "none",
13094
13140
  heatmap: "none"
13095
- }, Ou = {
13141
+ }, ku = {
13096
13142
  drawing: "basic",
13097
13143
  streetView: "interactive",
13098
13144
  clustering: "client",
13099
13145
  heatmap: "weighted"
13100
- }, ku = "sf-google-maps-script", Au = ({ apiKey: e, language: t = "es", region: n = "PE", libraries: r = [] }) => {
13146
+ }, Au = "sf-google-maps-script", ju = ({ apiKey: e, language: t = "es", region: n = "PE", libraries: r = [] }) => {
13101
13147
  let i = new URLSearchParams({
13102
13148
  key: e,
13103
13149
  language: t,
13104
13150
  region: n
13105
13151
  });
13106
13152
  return r.length > 0 && i.set("libraries", r.join(",")), `https://maps.googleapis.com/maps/api/js?${i.toString()}`;
13107
- }, ju = (e) => {
13153
+ }, Mu = (e) => {
13108
13154
  let t = window;
13109
13155
  return t.google?.maps ? Promise.resolve(t.google) : (t.__sfGoogleMapsPromise ||= new Promise((n, r) => {
13110
- let i = document.getElementById(ku);
13156
+ let i = document.getElementById(Au);
13111
13157
  if (i) {
13112
13158
  i.addEventListener("load", () => n(t.google ?? {})), i.addEventListener("error", () => r(/* @__PURE__ */ Error("No se pudo cargar Google Maps.")));
13113
13159
  return;
13114
13160
  }
13115
13161
  let a = document.createElement("script");
13116
- a.id = ku, a.src = Au(e), a.async = !0, a.defer = !0, a.addEventListener("load", () => n(t.google ?? {})), a.addEventListener("error", () => r(/* @__PURE__ */ Error("No se pudo cargar Google Maps."))), document.head.appendChild(a);
13162
+ a.id = Au, a.src = ju(e), a.async = !0, a.defer = !0, a.addEventListener("load", () => n(t.google ?? {})), a.addEventListener("error", () => r(/* @__PURE__ */ Error("No se pudo cargar Google Maps."))), document.head.appendChild(a);
13117
13163
  }), t.__sfGoogleMapsPromise);
13118
- }, Mu = (e, t = "") => {
13164
+ }, Nu = (e, t = "") => {
13119
13165
  let n = e.match(/^var\((--[^,)]+)\)$/);
13120
13166
  return !n || typeof document > "u" ? t || e : getComputedStyle(document.documentElement).getPropertyValue(n[1]).trim() || t || e;
13121
- }, Nu = 111320, Pu = (e) => ({
13122
- dLat: e.radiusM / Nu,
13123
- dLng: e.radiusM / (Nu * Math.cos(e.center.lat * Math.PI / 180))
13124
- }), Fu = (e) => {
13125
- let { dLat: t, dLng: n } = Pu(e);
13167
+ }, Pu = 111320, Fu = (e) => ({
13168
+ dLat: e.radiusM / Pu,
13169
+ dLng: e.radiusM / (Pu * Math.cos(e.center.lat * Math.PI / 180))
13170
+ }), Iu = (e) => {
13171
+ let { dLat: t, dLng: n } = Fu(e);
13126
13172
  return {
13127
13173
  lat: e.center.lat - t * .62,
13128
13174
  lng: e.center.lng + n * .62
13129
13175
  };
13130
- }, Iu = (e, t = 72) => {
13131
- let { dLat: n, dLng: r } = Pu(e);
13176
+ }, Lu = (e, t = 72) => {
13177
+ let { dLat: n, dLng: r } = Fu(e);
13132
13178
  return Array.from({ length: t + 1 }, (i, a) => {
13133
13179
  let o = a / t * 2 * Math.PI;
13134
13180
  return {
@@ -13136,42 +13182,42 @@ ${e.map((e) => `<Row>${n.map((t) => {
13136
13182
  lng: e.center.lng + r * Math.cos(o)
13137
13183
  };
13138
13184
  });
13139
- }, Lu = (e, t) => ({
13185
+ }, Ru = (e, t) => ({
13140
13186
  map: t,
13141
13187
  paths: e.points,
13142
- strokeColor: e.color ?? Mu("var(--sf-map-area-stroke)"),
13143
- fillColor: e.fillColor ?? e.color ?? Mu("var(--sf-map-area-fill)"),
13188
+ strokeColor: e.color ?? Nu("var(--sf-map-area-stroke)"),
13189
+ fillColor: e.fillColor ?? e.color ?? Nu("var(--sf-map-area-fill)"),
13144
13190
  fillOpacity: .14,
13145
13191
  strokeWeight: 2.5
13146
- }), Ru = (e, t) => ({
13192
+ }), zu = (e, t) => ({
13147
13193
  map: t,
13148
13194
  path: e.points,
13149
- strokeColor: e.color ?? Mu("var(--sf-map-route-stroke)"),
13195
+ strokeColor: e.color ?? Nu("var(--sf-map-route-stroke)"),
13150
13196
  strokeWeight: 3.5
13151
- }), zu = (e, t) => ({
13197
+ }), Bu = (e, t) => ({
13152
13198
  map: t,
13153
13199
  center: e.center,
13154
13200
  radius: e.radiusM,
13155
- strokeColor: e.color ?? Mu("var(--sf-map-circle-stroke)"),
13156
- fillColor: e.fillColor ?? e.color ?? Mu("var(--sf-map-circle-fill)"),
13201
+ strokeColor: e.color ?? Nu("var(--sf-map-circle-stroke)"),
13202
+ fillColor: e.fillColor ?? e.color ?? Nu("var(--sf-map-circle-fill)"),
13157
13203
  fillOpacity: .16,
13158
13204
  strokeWeight: 2,
13159
13205
  clickable: !1
13160
- }), Bu = (e) => `data:image/svg+xml;charset=UTF-8,${encodeURIComponent(e)}`, Vu = (e) => Bu(`<svg xmlns="http://www.w3.org/2000/svg" width="30" height="40" viewBox="0 0 24 32"><path fill="${e}" d="M12 0C5.4 0 0 5.3 0 11.9 0 20.8 12 32 12 32s12-11.2 12-20.1C24 5.3 18.6 0 12 0z"/><circle cx="12" cy="12" r="4.6" fill="#fff"/></svg>`), Hu = (e) => e.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;"), Uu = (e, t) => {
13161
- let n = t ? 26 : 14, r = n / 2 - 1.5, i = t ? `<text x="${n / 2}" y="${n / 2}" dy=".35em" text-anchor="middle" font-family="system-ui,Segoe UI,sans-serif" font-size="12" font-weight="700" fill="#fff">${Hu(t)}</text>` : "";
13206
+ }), Vu = (e) => `data:image/svg+xml;charset=UTF-8,${encodeURIComponent(e)}`, Hu = (e) => Vu(`<svg xmlns="http://www.w3.org/2000/svg" width="30" height="40" viewBox="0 0 24 32"><path fill="${e}" d="M12 0C5.4 0 0 5.3 0 11.9 0 20.8 12 32 12 32s12-11.2 12-20.1C24 5.3 18.6 0 12 0z"/><circle cx="12" cy="12" r="4.6" fill="#fff"/></svg>`), Uu = (e) => e.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;"), Wu = (e, t) => {
13207
+ let n = t ? 26 : 14, r = n / 2 - 1.5, i = t ? `<text x="${n / 2}" y="${n / 2}" dy=".35em" text-anchor="middle" font-family="system-ui,Segoe UI,sans-serif" font-size="12" font-weight="700" fill="#fff">${Uu(t)}</text>` : "";
13162
13208
  return {
13163
13209
  size: n,
13164
- url: Bu(`<svg xmlns="http://www.w3.org/2000/svg" width="${n}" height="${n}"><circle cx="${n / 2}" cy="${n / 2}" r="${r}" fill="${e}" stroke="#fff" stroke-width="2"/>${i}</svg>`)
13210
+ url: Vu(`<svg xmlns="http://www.w3.org/2000/svg" width="${n}" height="${n}"><circle cx="${n / 2}" cy="${n / 2}" r="${r}" fill="${e}" stroke="#fff" stroke-width="2"/>${i}</svg>`)
13165
13211
  };
13166
- }, Wu = Bu("<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"1\" height=\"1\"/>"), Gu = (e, t, n, r) => {
13167
- let i = e.options?.variant === "pin" && r?.Point && r?.Size, a = e.options?.variant === "badge" && r?.Point && r?.Size, o = e.options?.showLabel && e.label, s = a ? Uu(e.color ?? (Mu("var(--sf-map-pin-bg)") || "#16a34a"), e.options?.text) : null;
13212
+ }, Gu = Vu("<svg xmlns=\"http://www.w3.org/2000/svg\" width=\"1\" height=\"1\"/>"), Ku = (e, t, n, r) => {
13213
+ let i = e.options?.variant === "pin" && r?.Point && r?.Size, a = e.options?.variant === "badge" && r?.Point && r?.Size, o = e.options?.showLabel && e.label, s = a ? Wu(e.color ?? (Nu("var(--sf-map-pin-bg)") || "#16a34a"), e.options?.text) : null;
13168
13214
  return {
13169
13215
  map: t,
13170
13216
  position: e.position,
13171
13217
  title: e.title ?? e.label,
13172
13218
  draggable: !n && e.options?.draggable,
13173
13219
  icon: i ? {
13174
- url: Vu(e.color ?? (Mu("var(--sf-map-pin-bg)") || "#16a34a")),
13220
+ url: Hu(e.color ?? (Nu("var(--sf-map-pin-bg)") || "#16a34a")),
13175
13221
  scaledSize: new r.Size(30, 40),
13176
13222
  anchor: new r.Point(15, 40),
13177
13223
  labelOrigin: new r.Point(15, -14)
@@ -13189,7 +13235,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
13189
13235
  fontWeight: "600"
13190
13236
  } : i || s || !e.label ? void 0 : e.label.slice(0, 1).toUpperCase()
13191
13237
  };
13192
- }, Ku = ({ config: e, center: t = xu, zoom: n = 13, markers: r = [], routes: i = [], areas: a = [], circles: o = [], mapType: s = "roadmap", view: c, onViewChange: l, zoomControl: d = !0, height: f = 320, className: p, readOnly: g, onClick: _, onMarkerClick: y, onMarkerDoubleClick: b, onMarkerDrag: x, onMarkerDragEnd: S }) => {
13238
+ }, qu = ({ config: e, center: t = Su, zoom: n = 13, markers: r = [], routes: i = [], areas: a = [], circles: o = [], mapType: s = "roadmap", view: c, onViewChange: l, zoomControl: d = !0, height: f = 320, className: p, readOnly: g, onClick: _, onMarkerClick: y, onMarkerDoubleClick: b, onMarkerDrag: x, onMarkerDragEnd: S }) => {
13193
13239
  let C = m(null), w = m(null), T = m(/* @__PURE__ */ new Map()), E = m(/* @__PURE__ */ new Map()), D = m(/* @__PURE__ */ new Map()), O = m(/* @__PURE__ */ new Map()), k = m(l);
13194
13240
  u(() => {
13195
13241
  k.current = l;
@@ -13226,9 +13272,9 @@ ${e.map((e) => `<Row>${n.map((t) => {
13226
13272
  return;
13227
13273
  }
13228
13274
  let t = !1;
13229
- return P("loading"), ju(e).then((n) => {
13275
+ return P("loading"), Mu(e).then((n) => {
13230
13276
  t || !C.current || !n.maps?.Map || (w.current = new n.maps.Map(C.current, {
13231
- center: xu,
13277
+ center: Su,
13232
13278
  zoom: 13,
13233
13279
  mapId: e.mapId,
13234
13280
  disableDefaultUI: g,
@@ -13270,16 +13316,16 @@ ${e.map((e) => `<Row>${n.map((t) => {
13270
13316
  }, [N]), u(() => {
13271
13317
  if (N !== "ready" || !e?.apiKey || !w.current) return;
13272
13318
  let t = !1;
13273
- return ju(e).then((e) => {
13319
+ return Mu(e).then((e) => {
13274
13320
  let n = e.maps;
13275
13321
  t || !n?.Circle || (O.current.forEach((e) => e.forEach((e) => e.setMap?.(null))), O.current.clear(), o.forEach((e) => {
13276
- let t = w.current, r = e.color ?? Mu("var(--sf-map-circle-stroke)"), i = [new n.Circle({
13277
- ...zu(e, t),
13322
+ let t = w.current, r = e.color ?? Nu("var(--sf-map-circle-stroke)"), i = [new n.Circle({
13323
+ ...Bu(e, t),
13278
13324
  strokeOpacity: +!e.dashed
13279
13325
  })];
13280
13326
  e.dashed && i.push(new n.Polyline({
13281
13327
  map: t,
13282
- path: Iu(e),
13328
+ path: Lu(e),
13283
13329
  clickable: !1,
13284
13330
  strokeOpacity: 0,
13285
13331
  icons: [{
@@ -13295,11 +13341,11 @@ ${e.map((e) => `<Row>${n.map((t) => {
13295
13341
  }]
13296
13342
  })), e.label && n.Point && i.push(new n.Marker({
13297
13343
  map: t,
13298
- position: Fu(e),
13344
+ position: Iu(e),
13299
13345
  clickable: !1,
13300
13346
  zIndex: 5,
13301
13347
  icon: {
13302
- url: Wu,
13348
+ url: Gu,
13303
13349
  labelOrigin: new n.Point(0, 0)
13304
13350
  },
13305
13351
  label: {
@@ -13327,7 +13373,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
13327
13373
  }, []), u(() => {
13328
13374
  if (N !== "ready" || !e?.apiKey || !w.current) return;
13329
13375
  let t = !1;
13330
- return ju(e).then((e) => {
13376
+ return Mu(e).then((e) => {
13331
13377
  if (t || !e.maps?.Marker) return;
13332
13378
  let n = new Set(r.map((e) => e.id));
13333
13379
  T.current.forEach((e, t) => {
@@ -13336,10 +13382,10 @@ ${e.map((e) => `<Row>${n.map((t) => {
13336
13382
  E.current.set(t.id, t);
13337
13383
  let n = T.current.get(t.id);
13338
13384
  if (n) {
13339
- n.marker.setPosition?.(t.position), n.marker.setOptions?.(Gu(t, w.current, g, e.maps));
13385
+ n.marker.setPosition?.(t.position), n.marker.setOptions?.(Ku(t, w.current, g, e.maps));
13340
13386
  return;
13341
13387
  }
13342
- let r = new e.maps.Marker(Gu(t, w.current, g, e.maps)), i = () => E.current.get(t.id) ?? t, a = [
13388
+ let r = new e.maps.Marker(Ku(t, w.current, g, e.maps)), i = () => E.current.get(t.id) ?? t, a = [
13343
13389
  r.addListener?.("click", () => {
13344
13390
  A.current.onMarkerClick?.({ marker: i() });
13345
13391
  }),
@@ -13383,7 +13429,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
13383
13429
  ]), u(() => {
13384
13430
  if (N !== "ready" || !e?.apiKey || !w.current) return;
13385
13431
  let t = !1;
13386
- return ju(e).then((e) => {
13432
+ return Mu(e).then((e) => {
13387
13433
  if (t || !e.maps?.Polyline || !e.maps.Polygon) return;
13388
13434
  let n = /* @__PURE__ */ new Set([...a.map((e) => `area:${e.id}`), ...i.map((e) => `route:${e.id}`)]);
13389
13435
  D.current.forEach((e, t) => {
@@ -13391,22 +13437,22 @@ ${e.map((e) => `<Row>${n.map((t) => {
13391
13437
  }), a.forEach((t) => {
13392
13438
  let n = `area:${t.id}`, r = D.current.get(n);
13393
13439
  if (r?.kind === "area") {
13394
- r.shape.setPaths?.(t.points), r.shape.setOptions?.(Lu(t, w.current));
13440
+ r.shape.setPaths?.(t.points), r.shape.setOptions?.(Ru(t, w.current));
13395
13441
  return;
13396
13442
  }
13397
13443
  r?.shape.setMap?.(null), D.current.set(n, {
13398
13444
  kind: "area",
13399
- shape: new e.maps.Polygon(Lu(t, w.current))
13445
+ shape: new e.maps.Polygon(Ru(t, w.current))
13400
13446
  });
13401
13447
  }), i.forEach((t) => {
13402
13448
  let n = `route:${t.id}`, r = D.current.get(n);
13403
13449
  if (r?.kind === "route") {
13404
- r.shape.setPath?.(t.points), r.shape.setOptions?.(Ru(t, w.current));
13450
+ r.shape.setPath?.(t.points), r.shape.setOptions?.(zu(t, w.current));
13405
13451
  return;
13406
13452
  }
13407
13453
  r?.shape.setMap?.(null), D.current.set(n, {
13408
13454
  kind: "route",
13409
- shape: new e.maps.Polyline(Ru(t, w.current))
13455
+ shape: new e.maps.Polyline(zu(t, w.current))
13410
13456
  });
13411
13457
  });
13412
13458
  }), () => {
@@ -13420,7 +13466,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
13420
13466
  ]), u(() => {
13421
13467
  if (N !== "ready" || !e?.apiKey || !w.current || !_ || g) return;
13422
13468
  let t = !1, n;
13423
- return ju(e).then(() => {
13469
+ return Mu(e).then(() => {
13424
13470
  let e = w.current;
13425
13471
  t || !e?.addListener || (n = e.addListener("click", (e) => {
13426
13472
  e.latLng && (e.placeId && e.stop?.(), _({
@@ -13452,25 +13498,25 @@ ${e.map((e) => `<Row>${n.map((t) => {
13452
13498
  "aria-busy": N !== "ready" || void 0
13453
13499
  })
13454
13500
  });
13455
- }, qu = (e) => ({
13501
+ }, Ju = (e) => ({
13456
13502
  id: "google",
13457
- capabilities: Ou,
13458
- createRenderer: () => (t) => /* @__PURE__ */ v(Ku, {
13503
+ capabilities: ku,
13504
+ createRenderer: () => (t) => /* @__PURE__ */ v(qu, {
13459
13505
  ...t,
13460
13506
  config: e
13461
13507
  })
13462
- }), Ju = (e) => [e.lat, e.lng], Yu = (e) => oe.divIcon({
13508
+ }), Yu = (e) => [e.lat, e.lng], Xu = (e) => oe.divIcon({
13463
13509
  className: "",
13464
13510
  html: `<div class="sf-neutral-map-marker" style="${e ? `--sf-neutral-map-marker-bg:${e};` : ""}"></div>`,
13465
13511
  iconSize: [18, 18],
13466
13512
  iconAnchor: [9, 9]
13467
- }), Xu = (e) => oe.divIcon({
13513
+ }), Zu = (e) => oe.divIcon({
13468
13514
  className: "",
13469
13515
  html: `<div class="sf-map-pin" style="${e ? `--sf-map-pin-bg:${e};` : ""}"><svg viewBox="0 0 24 32" aria-hidden="true"><path d="M12 0C5.4 0 0 5.3 0 11.9 0 20.8 12 32 12 32s12-11.2 12-20.1C24 5.3 18.6 0 12 0z"/><circle cx="12" cy="12" r="4.6"/></svg></div>`,
13470
13516
  iconSize: [30, 40],
13471
13517
  iconAnchor: [15, 40],
13472
13518
  tooltipAnchor: [0, -40]
13473
- }), Zu = (e, t) => {
13519
+ }), Qu = (e, t) => {
13474
13520
  let n = t ? 26 : 14;
13475
13521
  return oe.divIcon({
13476
13522
  className: "",
@@ -13479,12 +13525,12 @@ ${e.map((e) => `<Row>${n.map((t) => {
13479
13525
  iconAnchor: [n / 2, n / 2],
13480
13526
  tooltipAnchor: [0, -n / 2]
13481
13527
  });
13482
- }, Qu = (e) => e.options?.variant === "pin" ? Xu(e.color) : e.options?.variant === "badge" ? Zu(e.color, e.options.text) : Yu(e.color), $u = (e) => oe.divIcon({
13528
+ }, $u = (e) => e.options?.variant === "pin" ? Zu(e.color) : e.options?.variant === "badge" ? Qu(e.color, e.options.text) : Xu(e.color), ed = (e) => oe.divIcon({
13483
13529
  className: "",
13484
13530
  html: `<span class="sf-map-circle-label">${e.replace(/</g, "&lt;")}</span>`,
13485
13531
  iconSize: void 0,
13486
13532
  iconAnchor: [0, 0]
13487
- }), ed = ({ readOnly: e, onClick: t, onViewChange: n }) => (ae({
13533
+ }), td = ({ readOnly: e, onClick: t, onViewChange: n }) => (ae({
13488
13534
  click(n) {
13489
13535
  e || t?.({ location: {
13490
13536
  lat: n.latlng.lat,
@@ -13502,23 +13548,23 @@ ${e.map((e) => `<Row>${n.map((t) => {
13502
13548
  zoom: t.getZoom()
13503
13549
  });
13504
13550
  }
13505
- }), null), td = (e, t) => {
13551
+ }), null), nd = (e, t) => {
13506
13552
  let n = e.getCenter();
13507
13553
  return e.getZoom() === t.zoom && Math.abs(n.lat - t.center.lat) < 1e-7 && Math.abs(n.lng - t.center.lng) < 1e-7;
13508
- }, nd = ({ view: e }) => {
13554
+ }, rd = ({ view: e }) => {
13509
13555
  let t = U();
13510
13556
  return u(() => {
13511
- !e || td(t, e) || t.setView(Ju(e.center), e.zoom);
13557
+ !e || nd(t, e) || t.setView(Yu(e.center), e.zoom);
13512
13558
  }, [t, e]), null;
13513
- }, rd = () => {
13559
+ }, id = () => {
13514
13560
  let e = U();
13515
13561
  return u(() => {
13516
13562
  if (typeof ResizeObserver > "u") return;
13517
13563
  let t = new ResizeObserver(() => e.invalidateSize());
13518
13564
  return t.observe(e.getContainer()), () => t.disconnect();
13519
13565
  }, [e]), null;
13520
- }, id = ({ center: e = xu, zoom: t = 13, markers: n = [], routes: r = [], areas: i = [], circles: a = [], mapType: o = "roadmap", view: s, onViewChange: c, zoomControl: l = !0, height: u = 320, className: d, readOnly: f, tileUrl: m = Cu, attribution: h = wu, onClick: g, onMarkerClick: _, onMarkerDoubleClick: b, onMarkerDrag: x, onMarkerDragEnd: S }) => {
13521
- let C = Lo(), w = p(() => Ju(s?.center ?? e), [s?.center, e]), T = typeof u == "number" ? { height: `${u}px` } : { height: u }, E = o === "satellite";
13566
+ }, ad = ({ center: e = Su, zoom: t = 13, markers: n = [], routes: r = [], areas: i = [], circles: a = [], mapType: o = "roadmap", view: s, onViewChange: c, zoomControl: l = !0, height: u = 320, className: d, readOnly: f, tileUrl: m = wu, attribution: h = Tu, onClick: g, onMarkerClick: _, onMarkerDoubleClick: b, onMarkerDrag: x, onMarkerDragEnd: S }) => {
13567
+ let C = Lo(), w = p(() => Yu(s?.center ?? e), [s?.center, e]), T = typeof u == "number" ? { height: `${u}px` } : { height: u }, E = o === "satellite";
13522
13568
  return C ? /* @__PURE__ */ v("div", {
13523
13569
  className: d,
13524
13570
  style: T,
@@ -13531,53 +13577,53 @@ ${e.map((e) => `<Row>${n.map((t) => {
13531
13577
  className: "sf-map-frame",
13532
13578
  children: [
13533
13579
  /* @__PURE__ */ v(H, {
13534
- attribution: E ? Eu : h,
13535
- url: E ? Tu : m
13580
+ attribution: E ? Du : h,
13581
+ url: E ? Eu : m
13536
13582
  }, E ? "satellite" : "roadmap"),
13537
- /* @__PURE__ */ v(ed, {
13583
+ /* @__PURE__ */ v(td, {
13538
13584
  readOnly: f,
13539
13585
  onClick: g,
13540
13586
  onViewChange: c
13541
13587
  }),
13542
- /* @__PURE__ */ v(nd, { view: s }),
13543
- /* @__PURE__ */ v(rd, {}),
13588
+ /* @__PURE__ */ v(rd, { view: s }),
13589
+ /* @__PURE__ */ v(id, {}),
13544
13590
  i.map((e) => /* @__PURE__ */ v(ne, {
13545
- positions: e.points.map(Ju),
13591
+ positions: e.points.map(Yu),
13546
13592
  pathOptions: {
13547
- color: e.color ?? Mu("var(--sf-map-area-stroke)"),
13548
- fillColor: e.fillColor ?? e.color ?? Mu("var(--sf-map-area-fill)"),
13593
+ color: e.color ?? Nu("var(--sf-map-area-stroke)"),
13594
+ fillColor: e.fillColor ?? e.color ?? Nu("var(--sf-map-area-fill)"),
13549
13595
  fillOpacity: .14,
13550
13596
  weight: 2.5
13551
13597
  }
13552
13598
  }, e.id)),
13553
13599
  a.map((e) => /* @__PURE__ */ v(ee, {
13554
- center: Ju(e.center),
13600
+ center: Yu(e.center),
13555
13601
  radius: e.radiusM,
13556
13602
  bubblingMouseEvents: !1,
13557
13603
  pathOptions: {
13558
- color: e.color ?? Mu("var(--sf-map-circle-stroke)"),
13559
- fillColor: e.fillColor ?? e.color ?? Mu("var(--sf-map-circle-fill)"),
13604
+ color: e.color ?? Nu("var(--sf-map-circle-stroke)"),
13605
+ fillColor: e.fillColor ?? e.color ?? Nu("var(--sf-map-circle-fill)"),
13560
13606
  fillOpacity: .16,
13561
13607
  weight: 2,
13562
13608
  dashArray: e.dashed ? "6 6" : void 0
13563
13609
  }
13564
13610
  }, e.id)),
13565
13611
  a.filter((e) => e.label).map((e) => /* @__PURE__ */ v(te, {
13566
- position: Ju(Fu(e)),
13567
- icon: $u(e.label ?? ""),
13612
+ position: Yu(Iu(e)),
13613
+ icon: ed(e.label ?? ""),
13568
13614
  interactive: !1,
13569
13615
  keyboard: !1
13570
13616
  }, `${e.id}-label`)),
13571
13617
  r.map((e) => /* @__PURE__ */ v(re, {
13572
- positions: e.points.map(Ju),
13618
+ positions: e.points.map(Yu),
13573
13619
  pathOptions: {
13574
- color: e.color ?? Mu("var(--sf-map-route-stroke)"),
13620
+ color: e.color ?? Nu("var(--sf-map-route-stroke)"),
13575
13621
  weight: 3.5
13576
13622
  }
13577
13623
  }, e.id)),
13578
13624
  n.map((e) => /* @__PURE__ */ v(te, {
13579
- position: Ju(e.position),
13580
- icon: Qu(e),
13625
+ position: Yu(e.position),
13626
+ icon: $u(e),
13581
13627
  title: e.title ?? e.label,
13582
13628
  draggable: !f && e.options?.draggable,
13583
13629
  bubblingMouseEvents: !1,
@@ -13620,18 +13666,18 @@ ${e.map((e) => `<Row>${n.map((t) => {
13620
13666
  style: T,
13621
13667
  children: "Cargando mapa…"
13622
13668
  });
13623
- }, ad = (e) => ({
13669
+ }, od = (e) => ({
13624
13670
  id: "leaflet",
13625
- capabilities: Du,
13626
- createRenderer: () => (t) => /* @__PURE__ */ v(id, {
13671
+ capabilities: Ou,
13672
+ createRenderer: () => (t) => /* @__PURE__ */ v(ad, {
13627
13673
  ...t,
13628
13674
  tileUrl: e?.tileUrl,
13629
13675
  attribution: e?.attribution
13630
13676
  })
13631
- }), od = 6371e3, sd = (e) => e * Math.PI / 180, cd = (e, t) => {
13632
- let n = sd(t.lat - e.lat), r = sd(t.lng - e.lng), i = sd(e.lat), a = sd(t.lat), o = Math.sin(n / 2) ** 2 + Math.sin(r / 2) ** 2 * Math.cos(i) * Math.cos(a);
13633
- return 2 * od * Math.atan2(Math.sqrt(o), Math.sqrt(1 - o));
13634
- }, ld = () => ({
13677
+ }), sd = 6371e3, cd = (e) => e * Math.PI / 180, ld = (e, t) => {
13678
+ let n = cd(t.lat - e.lat), r = cd(t.lng - e.lng), i = cd(e.lat), a = cd(t.lat), o = Math.sin(n / 2) ** 2 + Math.sin(r / 2) ** 2 * Math.cos(i) * Math.cos(a);
13679
+ return 2 * sd * Math.atan2(Math.sqrt(o), Math.sqrt(1 - o));
13680
+ }, ud = () => ({
13635
13681
  id: "basic",
13636
13682
  capabilities: {
13637
13683
  distance: "point-to-point",
@@ -13639,62 +13685,62 @@ ${e.map((e) => `<Row>${n.map((t) => {
13639
13685
  },
13640
13686
  async calculateDistance(e) {
13641
13687
  let t = e.origins[0], n = e.destinations[0];
13642
- return { distanceMeters: t && n ? cd(t, n) : 0 };
13688
+ return { distanceMeters: t && n ? ld(t, n) : 0 };
13643
13689
  }
13644
- }), ud = (e) => ({
13690
+ }), dd = (e) => ({
13645
13691
  lat: e.lat(),
13646
13692
  lng: e.lng()
13647
- }), dd = /^unnamed road$/i, fd = /^distrito de\s+/i, pd = /^[23456789CFGHJMPQRVWX]{4,8}\+[23456789CFGHJMPQRVWX]{0,3},?\s*/i, md = (e) => e?.replace(/^unnamed road,\s*/i, "").replace(pd, "").trim() || void 0, hd = (e, ...t) => {
13693
+ }), fd = /^unnamed road$/i, pd = /^distrito de\s+/i, md = /^[23456789CFGHJMPQRVWX]{4,8}\+[23456789CFGHJMPQRVWX]{0,3},?\s*/i, hd = (e) => e?.replace(/^unnamed road,\s*/i, "").replace(md, "").trim() || void 0, gd = (e, ...t) => {
13648
13694
  for (let n of t) {
13649
13695
  let t = e.address_components?.find((e) => e.types?.includes(n))?.long_name?.trim();
13650
- if (t && !(n === "route" && dd.test(t))) return t;
13696
+ if (t && !(n === "route" && fd.test(t))) return t;
13651
13697
  }
13652
- }, gd = (e, t = e.find((e) => hd(e, "route"))) => {
13698
+ }, _d = (e, t = e.find((e) => gd(e, "route"))) => {
13653
13699
  let n = (...t) => {
13654
13700
  for (let n of e) {
13655
- let e = hd(n, ...t);
13701
+ let e = gd(n, ...t);
13656
13702
  if (e) return e;
13657
13703
  }
13658
- }, r = t ? hd(t, "route") : void 0, i = t ? hd(t, "street_number") : void 0, a = e.flatMap((e) => [
13704
+ }, r = t ? gd(t, "route") : void 0, i = t ? gd(t, "street_number") : void 0, a = e.flatMap((e) => [
13659
13705
  "sublocality_level_1",
13660
13706
  "sublocality",
13661
13707
  "neighborhood"
13662
- ].map((t) => hd(e, t)).filter(Boolean)), o = a.find((e) => fd.test(e))?.replace(fd, "");
13708
+ ].map((t) => gd(e, t)).filter(Boolean)), o = a.find((e) => pd.test(e))?.replace(pd, "");
13663
13709
  return {
13664
13710
  street: r,
13665
13711
  number: i,
13666
13712
  line: r ? [r, i].filter(Boolean).join(" ") : void 0,
13667
- neighborhood: a.find((e) => !fd.test(e)),
13713
+ neighborhood: a.find((e) => !pd.test(e)),
13668
13714
  locality: n("locality"),
13669
- district: o || n("administrative_area_level_3", "locality")?.replace(fd, ""),
13715
+ district: o || n("administrative_area_level_3", "locality")?.replace(pd, ""),
13670
13716
  province: n("administrative_area_level_2"),
13671
13717
  department: n("administrative_area_level_1"),
13672
13718
  country: n("country"),
13673
13719
  postalCode: n("postal_code")
13674
13720
  };
13675
- }, _d = (e) => {
13721
+ }, vd = (e) => {
13676
13722
  let t = e.geometry?.location;
13677
13723
  if (!t) return null;
13678
- let n = md(e.formatted_address), r = n ?? e.place_id ?? "Ubicación Google Maps";
13724
+ let n = hd(e.formatted_address), r = n ?? e.place_id ?? "Ubicación Google Maps";
13679
13725
  return {
13680
13726
  id: e.place_id ?? r,
13681
13727
  label: r,
13682
13728
  address: n,
13683
- location: ud(t),
13729
+ location: dd(t),
13684
13730
  provider: "google",
13685
- parts: e.address_components ? gd([e]) : void 0,
13731
+ parts: e.address_components ? _d([e]) : void 0,
13686
13732
  raw: e
13687
13733
  };
13688
- }, vd = (e, t) => {
13734
+ }, yd = (e, t) => {
13689
13735
  let n = (e) => e * Math.PI / 180, r = Math.sin(n(t.lat - e.lat) / 2) ** 2 + Math.cos(n(e.lat)) * Math.cos(n(t.lat)) * Math.sin(n(t.lng - e.lng) / 2) ** 2;
13690
13736
  return 12742e3 * Math.asin(Math.sqrt(r));
13691
- }, yd = /* @__PURE__ */ new Set(["ROOFTOP", "RANGE_INTERPOLATED"]), bd = (e, t) => {
13737
+ }, bd = /* @__PURE__ */ new Set(["ROOFTOP", "RANGE_INTERPOLATED"]), xd = (e, t) => {
13692
13738
  if (t.length === 0) return null;
13693
- let n = t.filter((e) => hd(e, "route") && e.geometry?.location).map((t) => ({
13739
+ let n = t.filter((e) => gd(e, "route") && e.geometry?.location).map((t) => ({
13694
13740
  result: t,
13695
- punto: yd.has(t.geometry?.location_type ?? ""),
13696
- distancia: vd(e, ud(t.geometry.location))
13697
- })).sort((e, t) => Number(t.punto) - Number(e.punto) || e.distancia - t.distancia)[0], r = n?.result ?? t[0], i = md(r.formatted_address), a = i ?? `${e.lat.toFixed(6)}, ${e.lng.toFixed(6)}`, o = gd(t, n?.result);
13741
+ punto: bd.has(t.geometry?.location_type ?? ""),
13742
+ distancia: yd(e, dd(t.geometry.location))
13743
+ })).sort((e, t) => Number(t.punto) - Number(e.punto) || e.distancia - t.distancia)[0], r = n?.result ?? t[0], i = hd(r.formatted_address), a = i ?? `${e.lat.toFixed(6)}, ${e.lng.toFixed(6)}`, o = _d(t, n?.result);
13698
13744
  return {
13699
13745
  id: r.place_id ?? a,
13700
13746
  label: a,
@@ -13707,27 +13753,27 @@ ${e.map((e) => `<Row>${n.map((t) => {
13707
13753
  } : o,
13708
13754
  raw: r
13709
13755
  };
13710
- }, xd = (e) => ({
13756
+ }, Sd = (e) => ({
13711
13757
  id: "google",
13712
13758
  capabilities: { geocoding: "full" },
13713
13759
  async geocode(t) {
13714
- let n = (await ju(e)).maps?.Geocoder;
13760
+ let n = (await Mu(e)).maps?.Geocoder;
13715
13761
  return n ? new Promise((e) => {
13716
13762
  new n().geocode({ address: t }, (t) => {
13717
- e((t ?? []).map((e) => _d(e)).filter((e) => !!e));
13763
+ e((t ?? []).map((e) => vd(e)).filter((e) => !!e));
13718
13764
  });
13719
13765
  }) : [];
13720
13766
  },
13721
13767
  async reverseGeocode(t) {
13722
- let n = (await ju(e)).maps?.Geocoder;
13768
+ let n = (await Mu(e)).maps?.Geocoder;
13723
13769
  return n ? new Promise((e) => {
13724
13770
  new n().geocode({ location: t }, (n) => {
13725
- e(bd(t, n ?? []));
13771
+ e(xd(t, n ?? []));
13726
13772
  });
13727
13773
  }) : null;
13728
13774
  },
13729
13775
  async placeDetails(t) {
13730
- let n = (await ju(e)).maps;
13776
+ let n = (await Mu(e)).maps;
13731
13777
  if (!n) return null;
13732
13778
  !n.places?.PlacesService && n.importLibrary && await n.importLibrary("places").catch(() => void 0);
13733
13779
  let r = n.places?.PlacesService;
@@ -13746,34 +13792,34 @@ ${e.map((e) => `<Row>${n.map((t) => {
13746
13792
  e(null);
13747
13793
  return;
13748
13794
  }
13749
- let a = _d({
13795
+ let a = vd({
13750
13796
  ...i,
13751
13797
  place_id: i.place_id ?? t
13752
13798
  });
13753
13799
  e(a && {
13754
13800
  ...a,
13755
13801
  name: i.name?.trim() || void 0,
13756
- parts: i.address_components ? gd([i]) : void 0
13802
+ parts: i.address_components ? _d([i]) : void 0
13757
13803
  });
13758
13804
  });
13759
13805
  }) : null;
13760
13806
  }
13761
- }), Sd = (e) => e.toFixed(6), Cd = (e, t, n) => Math.min(Math.max(e, t), n), wd = (e) => Cd(e, -90, 90), Td = (e) => Cd(e, -180, 180), Ed = (e, t = 0) => {
13807
+ }), Cd = (e) => e.toFixed(6), wd = (e, t, n) => Math.min(Math.max(e, t), n), Td = (e) => wd(e, -90, 90), Ed = (e) => wd(e, -180, 180), Dd = (e, t = 0) => {
13762
13808
  if (typeof e == "number") return Number.isFinite(e) ? e : t;
13763
13809
  let n = Number.parseFloat(e.trim().replace(",", "."));
13764
13810
  return Number.isFinite(n) ? n : t;
13765
- }, Dd = (e) => `${Sd(e.lat)}, ${Sd(e.lng)}`, Od = (e, t) => {
13811
+ }, Od = (e) => `${Cd(e.lat)}, ${Cd(e.lng)}`, kd = (e, t) => {
13766
13812
  if (!e || typeof e != "object" || !("lat" in e) || !("lng" in e)) return t;
13767
- let n = Ed(e.lat, t.lat), r = Ed(e.lng, t.lng);
13813
+ let n = Dd(e.lat, t.lat), r = Dd(e.lng, t.lng);
13768
13814
  return {
13769
- lat: wd(n),
13770
- lng: Td(r)
13815
+ lat: Td(n),
13816
+ lng: Ed(r)
13771
13817
  };
13772
- }, kd = (e, t = "Ubicación") => ({
13818
+ }, Ad = (e, t = "Ubicación") => ({
13773
13819
  id: `${e.lat}:${e.lng}`,
13774
13820
  position: e,
13775
13821
  label: t
13776
- }), Ad = (e) => {
13822
+ }), jd = (e) => {
13777
13823
  let t = e.road, n = e.house_number;
13778
13824
  return {
13779
13825
  street: t,
@@ -13787,7 +13833,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
13787
13833
  country: e.country,
13788
13834
  postalCode: e.postcode
13789
13835
  };
13790
- }, jd = () => ({
13836
+ }, Md = () => ({
13791
13837
  id: "nominatim",
13792
13838
  capabilities: { geocoding: "basic" },
13793
13839
  async geocode(e) {
@@ -13819,20 +13865,20 @@ ${e.map((e) => `<Row>${n.map((t) => {
13819
13865
  label: Go(r.display_name),
13820
13866
  address: r.display_name,
13821
13867
  name: r.name?.trim() || void 0,
13822
- parts: Ad(r.address ?? {}),
13868
+ parts: jd(r.address ?? {}),
13823
13869
  raw: r
13824
13870
  } : t;
13825
13871
  } catch {
13826
13872
  return t;
13827
13873
  }
13828
13874
  }
13829
- }), Md = (e) => ({
13875
+ }), Nd = (e) => ({
13830
13876
  id: e.id,
13831
13877
  capabilities: { places: e.capabilities.geocoding === "none" ? "none" : "basic" },
13832
13878
  searchPlaces(t) {
13833
13879
  return e.geocode(t);
13834
13880
  }
13835
- }), Nd = () => ({
13881
+ }), Pd = () => ({
13836
13882
  id: "basic",
13837
13883
  capabilities: {
13838
13884
  routing: "basic",
@@ -13850,31 +13896,31 @@ ${e.map((e) => `<Row>${n.map((t) => {
13850
13896
  ]
13851
13897
  };
13852
13898
  }
13853
- }), Pd = i({}), Fd = (e) => {
13899
+ }), Fd = i({}), Id = (e) => {
13854
13900
  let t = e.services?.geocoding ?? e.defaultEngine, n = e.engines.google;
13855
- return t === "google" && n ? xd(n) : jd();
13856
- }, Id = (e) => {
13857
- let t = e.defaultEngine === "google" ? qu(e.engines.google) : ad(e.engines.leaflet), n = Fd(e);
13901
+ return t === "google" && n ? Sd(n) : Md();
13902
+ }, Ld = (e) => {
13903
+ let t = e.defaultEngine === "google" ? Ju(e.engines.google) : od(e.engines.leaflet), n = Id(e);
13858
13904
  return {
13859
13905
  config: e,
13860
13906
  engine: t,
13861
13907
  geocodingService: n,
13862
- placesService: Md(n),
13863
- routingService: Nd(),
13864
- distanceService: ld()
13908
+ placesService: Nd(n),
13909
+ routingService: Pd(),
13910
+ distanceService: ud()
13865
13911
  };
13866
- }, Ld = ({ maps: e, children: t }) => {
13867
- let n = p(() => ({ maps: e ? Id(e) : void 0 }), [e]);
13868
- return /* @__PURE__ */ v(Pd.Provider, {
13912
+ }, Rd = ({ maps: e, children: t }) => {
13913
+ let n = p(() => ({ maps: e ? Ld(e) : void 0 }), [e]);
13914
+ return /* @__PURE__ */ v(Fd.Provider, {
13869
13915
  value: n,
13870
13916
  children: t
13871
13917
  });
13872
- }, Rd = () => c(Pd), zd = () => {
13873
- let e = Rd();
13874
- if (!e.maps) throw Error(bu);
13918
+ }, zd = () => c(Fd), Bd = () => {
13919
+ let e = zd();
13920
+ if (!e.maps) throw Error(xu);
13875
13921
  return e.maps;
13876
- }, Bd = () => {
13877
- let e = zd(), [t, n] = h(!1), [r, i] = h([]), [a, o] = h(null), c = m(0);
13922
+ }, Vd = () => {
13923
+ let e = Bd(), [t, n] = h(!1), [r, i] = h([]), [a, o] = h(null), c = m(0);
13878
13924
  return {
13879
13925
  loading: t,
13880
13926
  results: r,
@@ -13898,15 +13944,15 @@ ${e.map((e) => `<Row>${n.map((t) => {
13898
13944
  }
13899
13945
  }, [e.geocodingService])
13900
13946
  };
13901
- }, Vd = () => {
13902
- let e = zd();
13947
+ }, Hd = () => {
13948
+ let e = Bd();
13903
13949
  return p(() => ({
13904
13950
  id: e.engine.id,
13905
13951
  capabilities: e.engine.capabilities,
13906
13952
  renderer: e.engine.createRenderer()
13907
13953
  }), [e.engine]);
13908
- }, Hd = () => zd().config, Ud = () => {
13909
- let e = zd(), [t, n] = h(!1), [r, i] = h(null), [a, o] = h(null), c = m(0), l = s(async (t, r) => {
13954
+ }, Ud = () => Bd().config, Wd = () => {
13955
+ let e = Bd(), [t, n] = h(!1), [r, i] = h(null), [a, o] = h(null), c = m(0), l = s(async (t, r) => {
13910
13956
  c.current += 1;
13911
13957
  let a = c.current;
13912
13958
  n(!0), o(null);
@@ -13920,7 +13966,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
13920
13966
  address: l?.address ?? s?.address,
13921
13967
  parts: {
13922
13968
  ...s?.parts,
13923
- ...Wd(l?.parts),
13969
+ ...Gd(l?.parts),
13924
13970
  ...l?.parts?.line ? { lineDistanceM: void 0 } : {}
13925
13971
  }
13926
13972
  };
@@ -13941,11 +13987,11 @@ ${e.map((e) => `<Row>${n.map((t) => {
13941
13987
  show: u,
13942
13988
  clear: s(() => u(null), [u])
13943
13989
  };
13944
- }, Wd = (e) => Object.fromEntries(Object.entries(e ?? {}).filter(([, e]) => e !== void 0 && e !== "")), Gd = (e) => e && typeof e == "object" && "label" in e ? String(e.label ?? "") : "", Kd = ({ form: e, name: t, label: n, info: r, required: i, placeholder: a = "Buscar dirección", readOnly: o, disabled: s, className: c, onChange: l, onRefresh: u }) => {
13990
+ }, Gd = (e) => Object.fromEntries(Object.entries(e ?? {}).filter(([, e]) => e !== void 0 && e !== "")), Kd = (e) => e && typeof e == "object" && "label" in e ? String(e.label ?? "") : "", qd = ({ form: e, name: t, label: n, info: r, required: i, placeholder: a = "Buscar dirección", readOnly: o, disabled: s, className: c, onChange: l, onRefresh: u }) => {
13945
13991
  let d = b({
13946
13992
  name: t,
13947
13993
  control: e.control
13948
- }), { loading: f, results: p, error: m, search: g } = Bd(), [_, x] = h(() => Gd(d.field.value)), [S, C] = h(!1), w = String(t), T = d.fieldState.error?.message ? String(d.fieldState.error.message) : void 0, E = o || s, D = !E && !f && _.trim().length >= 3, O = () => {
13994
+ }), { loading: f, results: p, error: m, search: g } = Vd(), [_, x] = h(() => Kd(d.field.value)), [S, C] = h(!1), w = String(t), T = d.fieldState.error?.message ? String(d.fieldState.error.message) : void 0, E = o || s, D = !E && !f && _.trim().length >= 3, O = () => {
13949
13995
  D && (C(!0), g(_));
13950
13996
  }, k = (e) => {
13951
13997
  d.field.onChange(e), l?.(e);
@@ -14025,8 +14071,8 @@ ${e.map((e) => `<Row>${n.map((t) => {
14025
14071
  ]
14026
14072
  })
14027
14073
  });
14028
- }, qd = 19, Jd = 3, Yd = (e, t) => e.zoom === t.zoom && Math.abs(e.center.lat - t.center.lat) < 1e-7 && Math.abs(e.center.lng - t.center.lng) < 1e-7, Xd = ({ title: e, description: t, center: n = xu, zoom: r = 13, markers: i = [], routes: a = [], areas: o = [], circles: s = [], mapType: c = "roadmap", onMapTypeChange: l, showControls: u, recenterTo: d, focus: f, focusZoom: m = 16, legend: g, panel: _, height: b = 360, className: x, readOnly: S, onClick: C, onMarkerClick: w, onMarkerDoubleClick: T, onMarkerDrag: E, onMarkerDragEnd: D }) => {
14029
- let O = Vd(), k = p(() => O.renderer, [O.renderer]), A = !!u || f !== void 0, j = f ? `${f.lat},${f.lng}` : "", [M, N] = h({
14074
+ }, Jd = 19, Yd = 3, Xd = (e, t) => e.zoom === t.zoom && Math.abs(e.center.lat - t.center.lat) < 1e-7 && Math.abs(e.center.lng - t.center.lng) < 1e-7, Zd = ({ title: e, description: t, center: n = Su, zoom: r = 13, markers: i = [], routes: a = [], areas: o = [], circles: s = [], mapType: c = "roadmap", onMapTypeChange: l, showControls: u, recenterTo: d, focus: f, focusZoom: m = 16, legend: g, panel: _, height: b = 360, className: x, readOnly: S, onClick: C, onMarkerClick: w, onMarkerDoubleClick: T, onMarkerDrag: E, onMarkerDragEnd: D }) => {
14075
+ let O = Hd(), k = p(() => O.renderer, [O.renderer]), A = !!u || f !== void 0, j = f ? `${f.lat},${f.lng}` : "", [M, N] = h({
14030
14076
  vista: {
14031
14077
  center: n,
14032
14078
  zoom: r
@@ -14048,7 +14094,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14048
14094
  };
14049
14095
  }), I = (e) => F((t) => ({
14050
14096
  ...t,
14051
- zoom: Math.min(qd, Math.max(Jd, t.zoom + e))
14097
+ zoom: Math.min(Jd, Math.max(Yd, t.zoom + e))
14052
14098
  })), L = k({
14053
14099
  center: n,
14054
14100
  zoom: r,
@@ -14060,7 +14106,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14060
14106
  height: b,
14061
14107
  readOnly: S,
14062
14108
  view: A ? P : void 0,
14063
- onViewChange: A ? (e) => F((t) => Yd(t, e) ? t : e) : void 0,
14109
+ onViewChange: A ? (e) => F((t) => Xd(t, e) ? t : e) : void 0,
14064
14110
  zoomControl: !u,
14065
14111
  onClick: C,
14066
14112
  onMarkerClick: w,
@@ -14068,7 +14114,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14068
14114
  onMarkerDrag: E,
14069
14115
  onMarkerDragEnd: D
14070
14116
  }), R = !!l;
14071
- return /* @__PURE__ */ v(mu, {
14117
+ return /* @__PURE__ */ v(hu, {
14072
14118
  title: e,
14073
14119
  description: t,
14074
14120
  className: x,
@@ -14144,16 +14190,16 @@ ${e.map((e) => `<Row>${n.map((t) => {
14144
14190
  ]
14145
14191
  })
14146
14192
  });
14147
- }, Zd = ({ form: e, name: t, label: n, info: r, required: i, zoom: a = 13, readOnly: o, disabled: s, className: c, onChange: l, onRefresh: u }) => {
14193
+ }, Qd = ({ form: e, name: t, label: n, info: r, required: i, zoom: a = 13, readOnly: o, disabled: s, className: c, onChange: l, onRefresh: u }) => {
14148
14194
  let [d, f] = h(!1), [p, m] = h(null), g = b({
14149
14195
  name: t,
14150
14196
  control: e.control
14151
- }), _ = String(t), x = g.fieldState.error?.message ? String(g.fieldState.error.message) : void 0, S = o || s, C = Od(g.field.value, xu), w = (e) => {
14197
+ }), _ = String(t), x = g.fieldState.error?.message ? String(g.fieldState.error.message) : void 0, S = o || s, C = kd(g.field.value, Su), w = (e) => {
14152
14198
  g.field.onChange(e), l?.(e);
14153
14199
  }, T = (e, t) => {
14154
14200
  w({
14155
14201
  ...C,
14156
- [e]: Ed(t, C[e])
14202
+ [e]: Dd(t, C[e])
14157
14203
  });
14158
14204
  };
14159
14205
  return /* @__PURE__ */ v(Z, {
@@ -14176,7 +14222,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14176
14222
  id: `${_}-lat`,
14177
14223
  type: "text",
14178
14224
  inputMode: "decimal",
14179
- value: Sd(C.lat),
14225
+ value: Cd(C.lat),
14180
14226
  readOnly: S,
14181
14227
  disabled: s,
14182
14228
  "aria-invalid": !!x || void 0,
@@ -14196,7 +14242,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14196
14242
  id: `${_}-lng`,
14197
14243
  type: "text",
14198
14244
  inputMode: "decimal",
14199
- value: Sd(C.lng),
14245
+ value: Cd(C.lng),
14200
14246
  readOnly: S,
14201
14247
  disabled: s,
14202
14248
  "aria-invalid": !!x || void 0,
@@ -14215,8 +14261,8 @@ ${e.map((e) => `<Row>${n.map((t) => {
14215
14261
  onClick: () => {
14216
14262
  !navigator.geolocation || d || S || (f(!0), m(null), navigator.geolocation.getCurrentPosition((e) => {
14217
14263
  let t = {
14218
- lat: Number(Sd(e.coords.latitude)),
14219
- lng: Number(Sd(e.coords.longitude))
14264
+ lat: Number(Cd(e.coords.latitude)),
14265
+ lng: Number(Cd(e.coords.longitude))
14220
14266
  };
14221
14267
  w(t), m(e.coords.accuracy > 200 ? `Precisión aproximada: ${Math.round(e.coords.accuracy)} m.` : null), f(!1);
14222
14268
  }, () => {
@@ -14237,7 +14283,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14237
14283
  role: "status",
14238
14284
  children: p
14239
14285
  }),
14240
- /* @__PURE__ */ v(Xd, {
14286
+ /* @__PURE__ */ v(Zd, {
14241
14287
  center: C,
14242
14288
  zoom: a,
14243
14289
  height: 220,
@@ -14249,8 +14295,8 @@ ${e.map((e) => `<Row>${n.map((t) => {
14249
14295
  }],
14250
14296
  onClick: (e) => {
14251
14297
  w({
14252
- lat: Number(Sd(e.location.lat)),
14253
- lng: Number(Sd(e.location.lng))
14298
+ lat: Number(Cd(e.location.lat)),
14299
+ lng: Number(Cd(e.location.lng))
14254
14300
  }), g.field.onBlur();
14255
14301
  }
14256
14302
  }),
@@ -14261,19 +14307,19 @@ ${e.map((e) => `<Row>${n.map((t) => {
14261
14307
  ]
14262
14308
  })
14263
14309
  });
14264
- }, Qd = (e) => /* @__PURE__ */ v(Zd, { ...e }), $d = (e) => Array.isArray(e) ? e.map((e) => Od(e, xu)) : [], ef = (e) => e.length === 0 ? "Sin puntos" : e.length === 1 ? "1 punto" : `${e.length} puntos`, tf = "var(--sf-map-area-stroke)", nf = "var(--sf-map-area-fill)", rf = "var(--sf-map-route-stroke)", af = ({ form: e, name: t, mode: n, label: r, info: i, required: a = !0, zoom: o = 13, readOnly: s, disabled: c, className: l, onChange: u, onRefresh: d }) => {
14310
+ }, $d = (e) => /* @__PURE__ */ v(Qd, { ...e }), ef = (e) => Array.isArray(e) ? e.map((e) => kd(e, Su)) : [], tf = (e) => e.length === 0 ? "Sin puntos" : e.length === 1 ? "1 punto" : `${e.length} puntos`, nf = "var(--sf-map-area-stroke)", rf = "var(--sf-map-area-fill)", af = "var(--sf-map-route-stroke)", of = ({ form: e, name: t, mode: n, label: r, info: i, required: a = !0, zoom: o = 13, readOnly: s, disabled: c, className: l, onChange: u, onRefresh: d }) => {
14265
14311
  let f = n === "area" ? 3 : 2, p = `Dibuja al menos ${f} puntos para ${n === "area" ? "un área" : "una ruta"}.`, m = b({
14266
14312
  name: t,
14267
14313
  control: e.control,
14268
14314
  rules: { validate: (e) => {
14269
- let t = $d(e).length;
14315
+ let t = ef(e).length;
14270
14316
  return t === 0 && !a ? !0 : t < f ? p : !0;
14271
14317
  } }
14272
- }), h = String(t), g = m.fieldState.error?.message ? String(m.fieldState.error.message) : void 0, _ = s || c, x = $d(m.field.value), S = x.at(-1) ?? xu, C = {
14318
+ }), h = String(t), g = m.fieldState.error?.message ? String(m.fieldState.error.message) : void 0, _ = s || c, x = ef(m.field.value), S = x.at(-1) ?? Su, C = {
14273
14319
  id: `${h}-${n}`,
14274
14320
  points: x,
14275
- color: n === "area" ? tf : rf,
14276
- fillColor: n === "area" ? nf : void 0
14321
+ color: n === "area" ? nf : af,
14322
+ fillColor: n === "area" ? rf : void 0
14277
14323
  }, w = (e) => {
14278
14324
  m.field.onChange(e), u?.(e);
14279
14325
  }, T = () => w(x.slice(0, -1)), E = () => w([]), D = (e, t, n) => e.map((e, r) => r === t ? n : e), O = (e) => {
@@ -14306,7 +14352,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14306
14352
  children: "Limpiar"
14307
14353
  })]
14308
14354
  }),
14309
- /* @__PURE__ */ v(Xd, {
14355
+ /* @__PURE__ */ v(Zd, {
14310
14356
  center: S,
14311
14357
  zoom: o,
14312
14358
  height: 260,
@@ -14315,7 +14361,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14315
14361
  id: `${h}-point-${t}`,
14316
14362
  position: e,
14317
14363
  label: String(t + 1),
14318
- color: n === "area" ? tf : rf,
14364
+ color: n === "area" ? nf : af,
14319
14365
  options: { draggable: !_ }
14320
14366
  })),
14321
14367
  areas: n === "area" && x.length >= 3 ? [C] : [],
@@ -14338,7 +14384,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14338
14384
  className: "sf-map-hint",
14339
14385
  "aria-live": "polite",
14340
14386
  children: [
14341
- ef(x),
14387
+ tf(x),
14342
14388
  " · Clic para añadir. Arrastra un punto para moverlo. Doble clic para eliminar.",
14343
14389
  " ",
14344
14390
  /* @__PURE__ */ v("span", {
@@ -14350,38 +14396,38 @@ ${e.map((e) => `<Row>${n.map((t) => {
14350
14396
  ]
14351
14397
  })
14352
14398
  });
14353
- }, of = (e) => /* @__PURE__ */ v(af, {
14399
+ }, sf = (e) => /* @__PURE__ */ v(of, {
14354
14400
  ...e,
14355
14401
  mode: "area"
14356
- }), sf = (e) => /* @__PURE__ */ v(af, {
14402
+ }), cf = (e) => /* @__PURE__ */ v(of, {
14357
14403
  ...e,
14358
14404
  mode: "route"
14359
- }), cf = (e) => {
14405
+ }), lf = (e) => {
14360
14406
  switch (e.kind) {
14361
- case "coordinates": return /* @__PURE__ */ v(Qd, { ...e });
14362
- case "location": return /* @__PURE__ */ v(Zd, { ...e });
14363
- case "address": return /* @__PURE__ */ v(Kd, { ...e });
14364
- case "area": return /* @__PURE__ */ v(of, { ...e });
14365
- case "route": return /* @__PURE__ */ v(sf, { ...e });
14407
+ case "coordinates": return /* @__PURE__ */ v($d, { ...e });
14408
+ case "location": return /* @__PURE__ */ v(Qd, { ...e });
14409
+ case "address": return /* @__PURE__ */ v(qd, { ...e });
14410
+ case "area": return /* @__PURE__ */ v(sf, { ...e });
14411
+ case "route": return /* @__PURE__ */ v(cf, { ...e });
14366
14412
  default: return null;
14367
14413
  }
14368
- }, lf = /^#[0-9a-fA-F]{6}$/, uf = "#".padEnd(7, "0"), df = () => {
14414
+ }, uf = /^#[0-9a-fA-F]{6}$/, df = "#".padEnd(7, "0"), ff = () => {
14369
14415
  if (typeof document > "u") return "";
14370
14416
  let e = getComputedStyle(document.documentElement).getPropertyValue("--sf-primary").trim();
14371
- return lf.test(e) ? e.toLowerCase() : "";
14372
- }, ff = (e, t, n) => Math.min(n, Math.max(t, e)), pf = (e, t) => t?.formatValue ? t.formatValue(e) : t?.suffix ? `${e} ${t.suffix}` : String(e), mf = () => [], hf = (e) => Array.isArray(e) ? e.map((e) => String(e ?? "").trim()).filter(Boolean) : [], gf = () => [], _f = (e) => Array.isArray(e) ? e.map((e) => {
14417
+ return uf.test(e) ? e.toLowerCase() : "";
14418
+ }, pf = (e, t, n) => Math.min(n, Math.max(t, e)), mf = (e, t) => t?.formatValue ? t.formatValue(e) : t?.suffix ? `${e} ${t.suffix}` : String(e), hf = () => [], gf = (e) => Array.isArray(e) ? e.map((e) => String(e ?? "").trim()).filter(Boolean) : [], _f = () => [], vf = (e) => Array.isArray(e) ? e.map((e) => {
14373
14419
  if (typeof e != "object" || !e) return null;
14374
14420
  let t = e;
14375
14421
  return {
14376
14422
  key: String(t.key ?? ""),
14377
14423
  value: String(t.value ?? "")
14378
14424
  };
14379
- }).filter((e) => e != null) : [], vf = (e = 0, t = 100) => ({
14425
+ }).filter((e) => e != null) : [], yf = (e = 0, t = 100) => ({
14380
14426
  start: e,
14381
14427
  end: t
14382
- }), yf = (e, t = 0, n = 100) => {
14428
+ }), bf = (e, t = 0, n = 100) => {
14383
14429
  if (e && typeof e == "object" && "start" in e && "end" in e) {
14384
- let r = e, i = ff(Number(r.start), t, n), a = ff(Number(r.end), t, n);
14430
+ let r = e, i = pf(Number(r.start), t, n), a = pf(Number(r.end), t, n);
14385
14431
  return i <= a ? {
14386
14432
  start: i,
14387
14433
  end: a
@@ -14390,15 +14436,15 @@ ${e.map((e) => `<Row>${n.map((t) => {
14390
14436
  end: i
14391
14437
  };
14392
14438
  }
14393
- return vf(t, n);
14394
- }, bf = (e, t) => {
14395
- let n = df(), r = String(t ?? (n || uf)).trim(), i = lf.test(r) ? r.toLowerCase() : uf, a = String(e ?? i).trim();
14396
- return lf.test(a) ? a.toLowerCase() : i;
14397
- }, xf = (e, t, n) => n <= t ? 0 : Math.round((ff(e, t, n) - t) / (n - t) * 100), Sf = (e) => (0, X.default)("sf-range-input", e && "pointer-events-none"), Cf = ({ form: e, name: t, label: n, info: r, required: i, min: a = 0, max: o = 100, step: s = 1, suffix: c, readOnly: l, disabled: u, className: d, formatValue: f, onChange: p, onRefresh: m }) => {
14439
+ return yf(t, n);
14440
+ }, xf = (e, t) => {
14441
+ let n = ff(), r = String(t ?? (n || df)).trim(), i = uf.test(r) ? r.toLowerCase() : df, a = String(e ?? i).trim();
14442
+ return uf.test(a) ? a.toLowerCase() : i;
14443
+ }, Sf = (e, t, n) => n <= t ? 0 : Math.round((pf(e, t, n) - t) / (n - t) * 100), Cf = (e) => (0, X.default)("sf-range-input", e && "pointer-events-none"), wf = ({ form: e, name: t, label: n, info: r, required: i, min: a = 0, max: o = 100, step: s = 1, suffix: c, readOnly: l, disabled: u, className: d, formatValue: f, onChange: p, onRefresh: m }) => {
14398
14444
  let h = b({
14399
14445
  name: t,
14400
14446
  control: e.control
14401
- }), g = String(t), _ = h.fieldState.error?.message ? String(h.fieldState.error.message) : void 0, x = l || u, S = ff(Number(h.field.value ?? a), a, o), C = (e) => {
14447
+ }), g = String(t), _ = h.fieldState.error?.message ? String(h.fieldState.error.message) : void 0, x = l || u, S = pf(Number(h.field.value ?? a), a, o), C = (e) => {
14402
14448
  h.field.onChange(e), p?.(e);
14403
14449
  };
14404
14450
  return /* @__PURE__ */ v(Z, {
@@ -14422,17 +14468,17 @@ ${e.map((e) => `<Row>${n.map((t) => {
14422
14468
  "aria-invalid": !!_ || void 0,
14423
14469
  onBlur: () => h.field.onBlur(),
14424
14470
  onChange: (e) => C(Number(e.target.value)),
14425
- className: Sf(x)
14471
+ className: Cf(x)
14426
14472
  }), /* @__PURE__ */ v("span", {
14427
14473
  className: "sf-slider__value",
14428
- children: pf(S, {
14474
+ children: mf(S, {
14429
14475
  suffix: c,
14430
14476
  formatValue: f
14431
14477
  })
14432
14478
  })]
14433
14479
  })
14434
14480
  });
14435
- }, wf = {
14481
+ }, Tf = {
14436
14482
  slate: {
14437
14483
  wrap: "border-slate-300 bg-white",
14438
14484
  button: "bg-slate-50 text-slate-600 hover:bg-slate-100",
@@ -14453,7 +14499,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14453
14499
  button: "bg-blue-50 text-blue-700 hover:bg-blue-100",
14454
14500
  value: "text-blue-700"
14455
14501
  }
14456
- }, Tf = {
14502
+ }, Ef = {
14457
14503
  sm: {
14458
14504
  button: "h-6 w-6",
14459
14505
  icon: "h-3 w-3",
@@ -14464,13 +14510,13 @@ ${e.map((e) => `<Row>${n.map((t) => {
14464
14510
  icon: "h-3.5 w-3.5",
14465
14511
  value: "min-w-[2.5rem] px-1.5 text-sm"
14466
14512
  }
14467
- }, Ef = (e, t) => {
14513
+ }, Df = (e, t) => {
14468
14514
  let n = (String(t).split(".")[1] ?? "").length;
14469
14515
  return Number(e.toFixed(n));
14470
- }, Df = ({ value: e, onChange: t, min: n = 0, max: r = Infinity, step: i = 1, tone: a = "slate", size: o = "md", disabled: s = !1, readOnly: c = !1, ariaLabel: l, formatValue: u, className: d }) => {
14471
- let f = wf[a], p = Tf[o], m = s || c, h = (a) => {
14516
+ }, Of = ({ value: e, onChange: t, min: n = 0, max: r = Infinity, step: i = 1, tone: a = "slate", size: o = "md", disabled: s = !1, readOnly: c = !1, ariaLabel: l, formatValue: u, className: d }) => {
14517
+ let f = Tf[a], p = Ef[o], m = s || c, h = (a) => {
14472
14518
  if (m) return;
14473
- let o = Math.min(r, Math.max(n, Ef(a, i)));
14519
+ let o = Math.min(r, Math.max(n, Df(a, i)));
14474
14520
  o !== e && t(o);
14475
14521
  }, g = e <= n, _ = e >= r, b = u ? u(e) : String(e), x = (0, X.default)("flex items-center justify-center font-bold leading-none transition-colors disabled:cursor-not-allowed disabled:opacity-40", f.button, p.button);
14476
14522
  return /* @__PURE__ */ y("div", {
@@ -14506,11 +14552,11 @@ ${e.map((e) => `<Row>${n.map((t) => {
14506
14552
  })
14507
14553
  ]
14508
14554
  });
14509
- }, Of = (e) => (0, X.default)("sf-range-input", e && "pointer-events-none"), kf = ({ form: e, name: t, label: n, info: r, required: i, min: a = 0, max: o = 100, step: s = 1, suffix: c, readOnly: l, disabled: u, className: d, formatValue: f, onChange: p, onRefresh: m }) => {
14555
+ }, kf = (e) => (0, X.default)("sf-range-input", e && "pointer-events-none"), Af = ({ form: e, name: t, label: n, info: r, required: i, min: a = 0, max: o = 100, step: s = 1, suffix: c, readOnly: l, disabled: u, className: d, formatValue: f, onChange: p, onRefresh: m }) => {
14510
14556
  let h = b({
14511
14557
  name: t,
14512
14558
  control: e.control
14513
- }), g = String(t), _ = h.fieldState.error?.message ? String(h.fieldState.error.message) : void 0, x = l || u, S = yf(h.field.value, a, o), C = (e) => {
14559
+ }), g = String(t), _ = h.fieldState.error?.message ? String(h.fieldState.error.message) : void 0, x = l || u, S = bf(h.field.value, a, o), C = (e) => {
14514
14560
  h.field.onChange(e), p?.(e);
14515
14561
  }, w = {
14516
14562
  suffix: c,
@@ -14528,7 +14574,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14528
14574
  children: [
14529
14575
  /* @__PURE__ */ v("span", {
14530
14576
  className: "sf-slider__value sf-slider__value--sm",
14531
- children: pf(S.start, w)
14577
+ children: mf(S.start, w)
14532
14578
  }),
14533
14579
  /* @__PURE__ */ y("div", {
14534
14580
  className: "grid flex-1 gap-2",
@@ -14550,7 +14596,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14550
14596
  end: Math.max(t, S.end)
14551
14597
  });
14552
14598
  },
14553
- className: Of(x)
14599
+ className: kf(x)
14554
14600
  }), /* @__PURE__ */ v("input", {
14555
14601
  id: `${g}-end`,
14556
14602
  type: "range",
@@ -14569,21 +14615,21 @@ ${e.map((e) => `<Row>${n.map((t) => {
14569
14615
  end: t
14570
14616
  });
14571
14617
  },
14572
- className: Of(x)
14618
+ className: kf(x)
14573
14619
  })]
14574
14620
  }),
14575
14621
  /* @__PURE__ */ v("span", {
14576
14622
  className: "sf-slider__value sf-slider__value--sm",
14577
- children: pf(S.end, w)
14623
+ children: mf(S.end, w)
14578
14624
  })
14579
14625
  ]
14580
14626
  })
14581
14627
  });
14582
- }, Af = ({ form: e, name: t, label: n, info: r, required: i, min: a = 0, max: o = 100, suffix: s, className: c, formatValue: l, onRefresh: u }) => {
14628
+ }, jf = ({ form: e, name: t, label: n, info: r, required: i, min: a = 0, max: o = 100, suffix: s, className: c, formatValue: l, onRefresh: u }) => {
14583
14629
  let d = b({
14584
14630
  name: t,
14585
14631
  control: e.control
14586
- }), f = String(t), p = d.fieldState.error?.message ? String(d.fieldState.error.message) : void 0, m = ff(Number(d.field.value ?? a), a, o), h = xf(m, a, o);
14632
+ }), f = String(t), p = d.fieldState.error?.message ? String(d.fieldState.error.message) : void 0, m = pf(Number(d.field.value ?? a), a, o), h = Sf(m, a, o);
14587
14633
  return /* @__PURE__ */ v(Z, {
14588
14634
  id: f,
14589
14635
  label: n,
@@ -14606,21 +14652,21 @@ ${e.map((e) => `<Row>${n.map((t) => {
14606
14652
  })
14607
14653
  }), /* @__PURE__ */ v("span", {
14608
14654
  className: "sf-progress-bar__value",
14609
- children: pf(m, {
14655
+ children: mf(m, {
14610
14656
  suffix: s,
14611
14657
  formatValue: l
14612
14658
  })
14613
14659
  })]
14614
14660
  })
14615
14661
  });
14616
- }, jf = {
14662
+ }, Mf = {
14617
14663
  default: "sf-progress-bar-readonly__fill--default",
14618
14664
  success: "sf-progress-bar-readonly__fill--success",
14619
14665
  warning: "sf-progress-bar-readonly__fill--warning",
14620
14666
  danger: "sf-progress-bar-readonly__fill--danger",
14621
14667
  info: "sf-progress-bar-readonly__fill--info"
14622
- }, Mf = ({ value: e, min: t = 0, max: n = 100, label: r, showValue: i = !0, suffix: a, formatValue: o, tone: s = "default", size: c = "md", className: l }) => {
14623
- let u = ff(e, t, n), d = xf(u, t, n), f = pf(u, {
14668
+ }, Nf = ({ value: e, min: t = 0, max: n = 100, label: r, showValue: i = !0, suffix: a, formatValue: o, tone: s = "default", size: c = "md", className: l }) => {
14669
+ let u = pf(e, t, n), d = Sf(u, t, n), f = mf(u, {
14624
14670
  suffix: a,
14625
14671
  formatValue: o
14626
14672
  });
@@ -14634,7 +14680,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14634
14680
  /* @__PURE__ */ v("div", {
14635
14681
  className: "sf-progress-bar-readonly__track",
14636
14682
  children: /* @__PURE__ */ v("div", {
14637
- className: (0, X.default)("sf-progress-bar-readonly__fill", jf[s]),
14683
+ className: (0, X.default)("sf-progress-bar-readonly__fill", Mf[s]),
14638
14684
  style: { width: `${d}%` },
14639
14685
  role: "progressbar",
14640
14686
  "aria-label": r ?? "Progreso",
@@ -14649,11 +14695,11 @@ ${e.map((e) => `<Row>${n.map((t) => {
14649
14695
  })
14650
14696
  ]
14651
14697
  });
14652
- }, Nf = ({ form: e, name: t, label: n, info: r, required: i, stars: a = 5, readOnly: o, disabled: s, small: c, className: l, onChange: u, onRefresh: d }) => {
14698
+ }, Pf = ({ form: e, name: t, label: n, info: r, required: i, stars: a = 5, readOnly: o, disabled: s, small: c, className: l, onChange: u, onRefresh: d }) => {
14653
14699
  let [f, p] = h(0), m = b({
14654
14700
  name: t,
14655
14701
  control: e.control
14656
- }), g = String(t), _ = m.fieldState.error?.message ? String(m.fieldState.error.message) : void 0, y = o || s, x = Pf(Number(m.field.value ?? 0), a), S = f || x, C = (e) => {
14702
+ }), g = String(t), _ = m.fieldState.error?.message ? String(m.fieldState.error.message) : void 0, y = o || s, x = Ff(Number(m.field.value ?? 0), a), S = f || x, C = (e) => {
14657
14703
  m.field.onChange(e), u?.(e), m.field.onBlur();
14658
14704
  }, w = (e, t) => {
14659
14705
  if (y) return;
@@ -14693,12 +14739,12 @@ ${e.map((e) => `<Row>${n.map((t) => {
14693
14739
  }, e))
14694
14740
  })
14695
14741
  });
14696
- }, Pf = (e, t) => !Number.isFinite(e) || e < 0 ? 0 : Math.min(t, Math.round(e)), Ff = ({ form: e, name: t, label: n, info: r, required: i, readOnly: a, disabled: o, small: s, className: c, onChange: l, onRefresh: u }) => {
14742
+ }, Ff = (e, t) => !Number.isFinite(e) || e < 0 ? 0 : Math.min(t, Math.round(e)), If = ({ form: e, name: t, label: n, info: r, required: i, readOnly: a, disabled: o, small: s, className: c, onChange: l, onRefresh: u }) => {
14697
14743
  let d = b({
14698
14744
  name: t,
14699
14745
  control: e.control
14700
- }), f = String(t), p = d.fieldState.error?.message ? String(d.fieldState.error.message) : void 0, m = a || o, h = bf(d.field.value), g = (e) => {
14701
- let t = bf(e, h);
14746
+ }), f = String(t), p = d.fieldState.error?.message ? String(d.fieldState.error.message) : void 0, m = a || o, h = xf(d.field.value), g = (e) => {
14747
+ let t = xf(e, h);
14702
14748
  d.field.onChange(t), l?.(t);
14703
14749
  };
14704
14750
  return /* @__PURE__ */ v(Z, {
@@ -14741,11 +14787,11 @@ ${e.map((e) => `<Row>${n.map((t) => {
14741
14787
  })]
14742
14788
  })
14743
14789
  });
14744
- }, If = ({ form: e, name: t, label: n, info: r, required: i, placeholder: a = "Escribe y presiona Enter", maxItems: o, readOnly: s, disabled: c, className: l, onChange: u, onRefresh: d }) => {
14790
+ }, Lf = ({ form: e, name: t, label: n, info: r, required: i, placeholder: a = "Escribe y presiona Enter", maxItems: o, readOnly: s, disabled: c, className: l, onChange: u, onRefresh: d }) => {
14745
14791
  let [f, p] = h(""), m = b({
14746
14792
  name: t,
14747
14793
  control: e.control
14748
- }), g = String(t), _ = m.fieldState.error?.message ? String(m.fieldState.error.message) : void 0, x = s || c, S = hf(m.field.value), C = o != null && S.length >= o, w = (e) => {
14794
+ }), g = String(t), _ = m.fieldState.error?.message ? String(m.fieldState.error.message) : void 0, x = s || c, S = gf(m.field.value), C = o != null && S.length >= o, w = (e) => {
14749
14795
  m.field.onChange(e), u?.(e);
14750
14796
  }, T = () => {
14751
14797
  let e = f.trim();
@@ -14797,11 +14843,11 @@ ${e.map((e) => `<Row>${n.map((t) => {
14797
14843
  })]
14798
14844
  })
14799
14845
  });
14800
- }, Lf = ({ form: e, name: t, label: n, info: r, required: i, readOnly: a, disabled: o, small: s, className: c, onChange: l, onRefresh: u }) => {
14846
+ }, Rf = ({ form: e, name: t, label: n, info: r, required: i, readOnly: a, disabled: o, small: s, className: c, onChange: l, onRefresh: u }) => {
14801
14847
  let d = b({
14802
14848
  name: t,
14803
14849
  control: e.control
14804
- }), f = String(t), p = d.fieldState.error?.message ? String(d.fieldState.error.message) : void 0, m = a || o, h = _f(d.field.value), g = (e) => {
14850
+ }), f = String(t), p = d.fieldState.error?.message ? String(d.fieldState.error.message) : void 0, m = a || o, h = vf(d.field.value), g = (e) => {
14805
14851
  d.field.onChange(e), l?.(e);
14806
14852
  }, _ = (e, t, n) => {
14807
14853
  g(h.map((r, i) => i === e ? {
@@ -14886,7 +14932,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14886
14932
  })]
14887
14933
  })
14888
14934
  });
14889
- }, Rf = ({ items: e, onReorder: t, className: n }) => {
14935
+ }, zf = ({ items: e, onReorder: t, className: n }) => {
14890
14936
  let [r, i] = h(null), a = (n) => (a) => {
14891
14937
  if (a.preventDefault(), !r) return;
14892
14938
  let o = e.findIndex((e) => e.id === r);
@@ -14912,7 +14958,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14912
14958
  })]
14913
14959
  }, e.id))
14914
14960
  });
14915
- }, zf = ({ value: e, onChange: t, options: n, name: r = "card-radio-group", className: i, ariaLabel: a = "Opciones" }) => /* @__PURE__ */ v("div", {
14961
+ }, Bf = ({ value: e, onChange: t, options: n, name: r = "card-radio-group", className: i, ariaLabel: a = "Opciones" }) => /* @__PURE__ */ v("div", {
14916
14962
  className: (0, X.default)("sf-card-radio-group", i),
14917
14963
  role: "radiogroup",
14918
14964
  "aria-label": a,
@@ -14957,7 +15003,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
14957
15003
  ]
14958
15004
  }, n.value);
14959
15005
  })
14960
- }), Bf = ({ value: e, onChange: t, zones: n, label: r, disabled: i, className: a }) => {
15006
+ }), Vf = ({ value: e, onChange: t, zones: n, label: r, disabled: i, className: a }) => {
14961
15007
  let o = Math.max(0, n.findIndex((t) => t.value === e)), s = n[o], c = n.length > 1 ? o / (n.length - 1) * 100 : 0;
14962
15008
  return /* @__PURE__ */ y("div", {
14963
15009
  className: (0, X.default)("sf-semantic-slider", a),
@@ -14988,19 +15034,19 @@ ${e.map((e) => `<Row>${n.map((t) => {
14988
15034
  })
14989
15035
  ]
14990
15036
  });
14991
- }, Vf = {
15037
+ }, Hf = {
14992
15038
  slate: "var(--sf-metric-tone-slate)",
14993
15039
  emerald: "var(--sf-metric-tone-emerald)",
14994
15040
  amber: "var(--sf-metric-tone-amber)",
14995
15041
  red: "var(--sf-metric-tone-red)",
14996
15042
  blue: "var(--sf-metric-tone-blue)"
14997
- }, Hf = [
15043
+ }, Uf = [
14998
15044
  "slate",
14999
15045
  "blue",
15000
15046
  "amber",
15001
15047
  "emerald",
15002
15048
  "red"
15003
- ], Uf = ({ segments: e, onChange: t, unit: n, valueFormat: r, className: i }) => {
15049
+ ], Wf = ({ segments: e, onChange: t, unit: n, valueFormat: r, className: i }) => {
15004
15050
  let a = m(null), o = m(null), [s, c] = h(null), l = e.reduce((e, t) => e + t.value, 0), u = r ?? ((e) => `${e.toLocaleString("es-PE")}${n ? ` ${n}` : ""}`), d = (n, r, i) => {
15005
15051
  t && t(e.map((e, t) => t === n ? {
15006
15052
  ...e,
@@ -15042,14 +15088,14 @@ ${e.map((e) => `<Row>${n.map((t) => {
15042
15088
  ref: a,
15043
15089
  className: "sf-allocation-bar__track",
15044
15090
  children: e.map((n, r) => {
15045
- let i = l > 0 ? n.value / l * 100 : 0, a = b[r], o = n.tone ?? Hf[r % Hf.length], c = r === e.length - 1, d = c ? 0 : n.value + e[r + 1].value, m = d > 0 ? Math.round(n.value / d * 100) : 50;
15091
+ let i = l > 0 ? n.value / l * 100 : 0, a = b[r], o = n.tone ?? Uf[r % Uf.length], c = r === e.length - 1, d = c ? 0 : n.value + e[r + 1].value, m = d > 0 ? Math.round(n.value / d * 100) : 50;
15046
15092
  return /* @__PURE__ */ y("div", {
15047
15093
  className: "contents",
15048
15094
  children: [/* @__PURE__ */ v("div", {
15049
15095
  className: "sf-allocation-bar__seg",
15050
15096
  style: {
15051
15097
  width: `${i}%`,
15052
- backgroundColor: Vf[o]
15098
+ backgroundColor: Hf[o]
15053
15099
  },
15054
15100
  title: `${n.label} · ${u(n.value)} (${Math.round(i)}%)`
15055
15101
  }), !c && t && /* @__PURE__ */ v("div", {
@@ -15079,7 +15125,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15079
15125
  children: [
15080
15126
  /* @__PURE__ */ v("span", {
15081
15127
  className: "sf-allocation-bar__label-dot",
15082
- style: { backgroundColor: Vf[t.tone ?? Hf[e.indexOf(t) % Hf.length]] },
15128
+ style: { backgroundColor: Hf[t.tone ?? Uf[e.indexOf(t) % Uf.length]] },
15083
15129
  "aria-hidden": "true"
15084
15130
  }),
15085
15131
  t.label,
@@ -15093,11 +15139,11 @@ ${e.map((e) => `<Row>${n.map((t) => {
15093
15139
  })
15094
15140
  })]
15095
15141
  });
15096
- }, Wf = (e) => new Date(e).toLocaleTimeString("es-PE", {
15142
+ }, Gf = (e) => new Date(e).toLocaleTimeString("es-PE", {
15097
15143
  hour: "2-digit",
15098
15144
  minute: "2-digit"
15099
- }), Gf = ({ value: e, onChange: t, min: n, max: r, step: i, marks: a, formatValue: o, label: s, disabled: c, className: l }) => {
15100
- let u = o ?? Wf, d = r > n ? Math.min(100, Math.max(0, (e - n) / (r - n) * 100)) : 0, f = i ?? Math.max(1, Math.round((r - n) / 200));
15145
+ }), Kf = ({ value: e, onChange: t, min: n, max: r, step: i, marks: a, formatValue: o, label: s, disabled: c, className: l }) => {
15146
+ let u = o ?? Gf, d = r > n ? Math.min(100, Math.max(0, (e - n) / (r - n) * 100)) : 0, f = i ?? Math.max(1, Math.round((r - n) / 200));
15101
15147
  return /* @__PURE__ */ y("div", {
15102
15148
  className: (0, X.default)("sf-temporal-scrub", l),
15103
15149
  children: [s && /* @__PURE__ */ v("p", {
@@ -15139,7 +15185,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15139
15185
  ]
15140
15186
  })]
15141
15187
  });
15142
- }, Kf = {
15188
+ }, qf = {
15143
15189
  group: {
15144
15190
  label: "Grupo / Entidad",
15145
15191
  labelShort: "GRP",
@@ -15158,7 +15204,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15158
15204
  rowClass: "sf-org-tree-row--role",
15159
15205
  barClass: "sf-org-tree-bar--role"
15160
15206
  }
15161
- }, qf = (e) => {
15207
+ }, Jf = (e) => {
15162
15208
  let t = /* @__PURE__ */ new Map(), n = new Set(e.map((e) => e.id));
15163
15209
  for (let n of e) {
15164
15210
  let e = n.parentId == null || n.parentId === "" ? null : n.parentId, r = t.get(e) ?? [];
@@ -15185,16 +15231,16 @@ ${e.map((e) => `<Row>${n.map((t) => {
15185
15231
  hasChildren: !1
15186
15232
  });
15187
15233
  return r;
15188
- }, Jf = (e, t = Kf) => t[e] ?? Kf[e] ?? null, Yf = (e) => e.length, Xf = (e) => {
15234
+ }, Yf = (e, t = qf) => t[e] ?? qf[e] ?? null, Xf = (e) => e.length, Zf = (e) => {
15189
15235
  let t = new Set(e.map((e) => e.id));
15190
15236
  return e.filter((e) => {
15191
15237
  let n = e.parentId == null || e.parentId === "" ? null : e.parentId;
15192
15238
  return n == null || !t.has(n);
15193
15239
  });
15194
- }, Zf = ({ type: e, className: t }) => v(e === "group" ? wt : e === "role" ? Ze : Xe, {
15240
+ }, Qf = ({ type: e, className: t }) => v(e === "group" ? wt : e === "role" ? Ze : Xe, {
15195
15241
  className: t,
15196
15242
  "aria-hidden": "true"
15197
- }), Qf = ({ nodes: e, title: t = "Estructura", subtitle: n, loading: r = !1, error: i = null, onRefresh: a, canEdit: o = !1, onAddNode: c, onEditNode: l, onDeleteNode: d, showLegend: f = !1, themes: g = Kf, onRenderNode: _, maxHeight: b = 480, className: x }) => {
15243
+ }), $f = ({ nodes: e, title: t = "Estructura", subtitle: n, loading: r = !1, error: i = null, onRefresh: a, canEdit: o = !1, onAddNode: c, onEditNode: l, onDeleteNode: d, showLegend: f = !1, themes: g = qf, onRenderNode: _, maxHeight: b = 480, className: x }) => {
15198
15244
  let [S, C] = h(/* @__PURE__ */ new Set()), [w, T] = h({
15199
15245
  visible: !1,
15200
15246
  x: 0,
@@ -15217,7 +15263,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15217
15263
  window.removeEventListener("mousedown", e), window.removeEventListener("keydown", t);
15218
15264
  };
15219
15265
  }, [w.visible]);
15220
- let D = p(() => qf(e), [e]), O = s((e) => {
15266
+ let D = p(() => Jf(e), [e]), O = s((e) => {
15221
15267
  let t = e.parentId == null || e.parentId === "" ? null : e.parentId;
15222
15268
  for (; t != null;) {
15223
15269
  if (S.has(t)) return !0;
@@ -15304,7 +15350,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15304
15350
  className: "sf-org-tree__empty",
15305
15351
  children: "Sin nodos"
15306
15352
  }), k.map((e) => {
15307
- let t = Jf(e.type, g);
15353
+ let t = Yf(e.type, g);
15308
15354
  return /* @__PURE__ */ v("li", {
15309
15355
  role: "treeitem",
15310
15356
  "aria-level": e.depth + 1,
@@ -15324,7 +15370,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15324
15370
  tabIndex: e.hasChildren ? 0 : -1,
15325
15371
  children: S.has(e.id) ? /* @__PURE__ */ v(vt, { className: "h-4 w-4" }) : /* @__PURE__ */ v(bt, { className: "h-4 w-4" })
15326
15372
  }),
15327
- /* @__PURE__ */ v(Zf, {
15373
+ /* @__PURE__ */ v(Qf, {
15328
15374
  type: e.type,
15329
15375
  className: "h-4 w-4 shrink-0 opacity-70"
15330
15376
  }),
@@ -15409,7 +15455,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15409
15455
  })
15410
15456
  ]
15411
15457
  });
15412
- }, $f = {
15458
+ }, ep = {
15413
15459
  street: {
15414
15460
  url: "https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png",
15415
15461
  attribution: "&copy; <a href=\"https://www.openstreetmap.org/copyright\" target=\"_blank\" rel=\"noreferrer\">OpenStreetMap</a>"
@@ -15418,27 +15464,27 @@ ${e.map((e) => `<Row>${n.map((t) => {
15418
15464
  url: "https://server.arcgisonline.com/ArcGIS/rest/services/World_Imagery/MapServer/tile/{z}/{y}/{x}",
15419
15465
  attribution: "Tiles &copy; Esri — Source: Esri, Maxar, Earthstar Geographics, and the GIS User Community"
15420
15466
  }
15421
- }, ep = {
15467
+ }, tp = {
15422
15468
  default: "Nodo",
15423
15469
  nap: "NAP",
15424
15470
  olt: "OLT",
15425
15471
  splitter: "Splitter"
15426
- }, tp = {
15472
+ }, np = {
15427
15473
  default: "var(--sf-accent)",
15428
15474
  nap: "var(--sf-network-kind-nap)",
15429
15475
  olt: "var(--sf-network-kind-olt)",
15430
15476
  splitter: "var(--sf-network-kind-splitter)"
15431
- }, np = {
15477
+ }, rp = {
15432
15478
  normal: "var(--sf-network-status-normal)",
15433
15479
  warning: "var(--sf-network-status-warning)",
15434
15480
  critical: "var(--sf-network-status-critical)",
15435
15481
  maintenance: "var(--sf-network-status-maintenance)"
15436
- }, rp = {
15482
+ }, ip = {
15437
15483
  normal: "Normal",
15438
15484
  warning: "Advertencia",
15439
15485
  critical: "Crítico",
15440
15486
  maintenance: "Mantenimiento"
15441
- }, ip = {
15487
+ }, ap = {
15442
15488
  backbone: {
15443
15489
  color: "var(--sf-network-edge-backbone)",
15444
15490
  weight: 2.5
@@ -15452,7 +15498,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15452
15498
  weight: 1.5,
15453
15499
  dashArray: "6 4"
15454
15500
  }
15455
- }, ap = Mu, op = (e) => {
15501
+ }, op = Nu, sp = (e) => {
15456
15502
  if (!Array.isArray(e)) return [];
15457
15503
  let t = [];
15458
15504
  for (let n of e) {
@@ -15461,24 +15507,24 @@ ${e.map((e) => `<Row>${n.map((t) => {
15461
15507
  if (!r) continue;
15462
15508
  let i = Number(e.lat), a = Number(e.lng);
15463
15509
  if (!Number.isFinite(i) || !Number.isFinite(a)) continue;
15464
- let o = String(e.status ?? "normal"), s = o in np ? o : "normal", c = {
15510
+ let o = String(e.status ?? "normal"), s = o in rp ? o : "normal", c = {
15465
15511
  id: r,
15466
15512
  label: String(e.label ?? ""),
15467
15513
  lat: i,
15468
15514
  lng: a,
15469
15515
  status: s
15470
15516
  }, l = e.kind == null ? r.startsWith("nap:") ? "nap" : "default" : String(e.kind);
15471
- l in ep && (c.kind = l), e.value != null && Number.isFinite(Number(e.value)) && (c.value = Number(e.value)), e.icon != null && (c.icon = String(e.icon)), t.push(c);
15517
+ l in tp && (c.kind = l), e.value != null && Number.isFinite(Number(e.value)) && (c.value = Number(e.value)), e.icon != null && (c.icon = String(e.icon)), t.push(c);
15472
15518
  }
15473
15519
  return t;
15474
- }, sp = (e) => {
15520
+ }, cp = (e) => {
15475
15521
  if (!Array.isArray(e)) return [];
15476
15522
  let t = [];
15477
15523
  for (let n of e) {
15478
15524
  if (typeof n != "object" || !n) continue;
15479
15525
  let e = n, r = String(e.from ?? ""), i = String(e.to ?? "");
15480
15526
  if (!r || !i) continue;
15481
- let a = String(e.type ?? "backbone"), o = a in ip ? a : "backbone";
15527
+ let a = String(e.type ?? "backbone"), o = a in ap ? a : "backbone";
15482
15528
  t.push({
15483
15529
  from: r,
15484
15530
  to: i,
@@ -15486,7 +15532,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15486
15532
  });
15487
15533
  }
15488
15534
  return t;
15489
- }, cp = (e) => {
15535
+ }, lp = (e) => {
15490
15536
  let t = {
15491
15537
  normal: 0,
15492
15538
  warning: 0,
@@ -15495,18 +15541,18 @@ ${e.map((e) => `<Row>${n.map((t) => {
15495
15541
  };
15496
15542
  for (let n of e) t[n.status] += 1;
15497
15543
  return t;
15498
- }, lp = (e) => {
15544
+ }, up = (e) => {
15499
15545
  if (e.length === 0) return null;
15500
15546
  let t = e.map((e) => e.lat), n = e.map((e) => e.lng);
15501
15547
  return [[Math.min(...t), Math.min(...n)], [Math.max(...t), Math.max(...n)]];
15502
- }, up = (e) => Object.fromEntries(e.map((e) => [e.id, [e.lat, e.lng]])), dp = (e, t) => e.flatMap((e) => {
15548
+ }, dp = (e) => Object.fromEntries(e.map((e) => [e.id, [e.lat, e.lng]])), fp = (e, t) => e.flatMap((e) => {
15503
15549
  let n = t[e.from], r = t[e.to];
15504
15550
  return !n || !r ? [] : [{
15505
15551
  edge: e,
15506
15552
  line: [n, r]
15507
15553
  }];
15508
- }), fp = ({ nodes: e, edges: t = [], placement: n = "bottom-left", className: r }) => {
15509
- let i = cp(e), a = Array.from(new Set(t.map((e) => e.type ?? "backbone")));
15554
+ }), pp = ({ nodes: e, edges: t = [], placement: n = "bottom-left", className: r }) => {
15555
+ let i = lp(e), a = Array.from(new Set(t.map((e) => e.type ?? "backbone")));
15510
15556
  return /* @__PURE__ */ y("div", {
15511
15557
  className: (0, X.default)("sf-network-legend", n === "bottom-right" ? "sf-network-legend--right" : "sf-network-legend--left", r),
15512
15558
  role: "region",
@@ -15518,15 +15564,15 @@ ${e.map((e) => `<Row>${n.map((t) => {
15518
15564
  }),
15519
15565
  /* @__PURE__ */ v("ul", {
15520
15566
  className: "space-y-1",
15521
- children: Object.keys(rp).map((e) => /* @__PURE__ */ y("li", {
15567
+ children: Object.keys(ip).map((e) => /* @__PURE__ */ y("li", {
15522
15568
  className: "sf-network-legend__item",
15523
15569
  children: [/* @__PURE__ */ y("span", {
15524
15570
  className: "flex items-center gap-2",
15525
15571
  children: [/* @__PURE__ */ v("span", {
15526
15572
  className: "inline-block h-2.5 w-2.5 rounded-full",
15527
- style: { background: np[e] },
15573
+ style: { background: rp[e] },
15528
15574
  "aria-hidden": "true"
15529
- }), rp[e]]
15575
+ }), ip[e]]
15530
15576
  }), /* @__PURE__ */ v("span", {
15531
15577
  className: "sf-network-legend__count",
15532
15578
  children: i[e]
@@ -15539,7 +15585,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15539
15585
  }), /* @__PURE__ */ v("ul", {
15540
15586
  className: "space-y-1",
15541
15587
  children: a.map((e) => {
15542
- let t = ip[e ?? "backbone"];
15588
+ let t = ap[e ?? "backbone"];
15543
15589
  return /* @__PURE__ */ y("li", {
15544
15590
  className: "sf-network-legend__item sf-network-legend__item--edge",
15545
15591
  children: [/* @__PURE__ */ v("span", {
@@ -15559,19 +15605,19 @@ ${e.map((e) => `<Row>${n.map((t) => {
15559
15605
  })
15560
15606
  ]
15561
15607
  });
15562
- }, pp = [-12.0464, -77.0428], mp = (e) => e.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;"), hp = (e, t) => {
15563
- let n = e.status, r = e.kind ?? "default", i = r === "nap" ? "NAP" : e.value == null ? e.icon ?? ep[r].slice(0, 3).toUpperCase() : `${e.value}%`, a = mp(e.label.length > 40 ? `${e.label.slice(0, 37)}…` : e.label), o = t ? " sf-network-marker--selected" : "";
15608
+ }, mp = [-12.0464, -77.0428], hp = (e) => e.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;"), gp = (e, t) => {
15609
+ let n = e.status, r = e.kind ?? "default", i = r === "nap" ? "NAP" : e.value == null ? e.icon ?? tp[r].slice(0, 3).toUpperCase() : `${e.value}%`, a = hp(e.label.length > 40 ? `${e.label.slice(0, 37)}…` : e.label), o = t ? " sf-network-marker--selected" : "";
15564
15610
  return oe.divIcon({
15565
15611
  className: "sf-network-marker-root",
15566
15612
  iconAnchor: [24, 42],
15567
15613
  iconSize: [48, 48],
15568
15614
  html: `<div class="sf-network-marker${o}">
15569
15615
  <div class="sf-network-marker__label">${a}</div>
15570
- <div class="sf-network-marker__dot sf-network-marker__dot--status-${n} sf-network-marker__dot--kind-${r}">${mp(String(i))}</div>
15616
+ <div class="sf-network-marker__dot sf-network-marker__dot--status-${n} sf-network-marker__dot--kind-${r}">${hp(String(i))}</div>
15571
15617
  </div>`
15572
15618
  });
15573
- }, gp = ({ nodes: e }) => {
15574
- let t = U(), n = lp(e);
15619
+ }, _p = ({ nodes: e }) => {
15620
+ let t = U(), n = up(e);
15575
15621
  return u(() => {
15576
15622
  n && t.fitBounds(n, {
15577
15623
  padding: [32, 32],
@@ -15582,8 +15628,8 @@ ${e.map((e) => `<Row>${n.map((t) => {
15582
15628
  t,
15583
15629
  e
15584
15630
  ]), null;
15585
- }, _p = ({ nodes: e, edges: t = [], center: n = pp, zoom: r = 12, height: i = 420, selectedNodeId: a, onNodeClick: o, showLegend: s = !0, fitBoundsToNodes: c = !0, basemap: l, onBasemapChange: u, showBasemapSwitcher: d = !1, ariaLabel: f = "Mapa de red", className: m }) => {
15586
- let g = Lo(), [_, b] = h("street"), x = l ?? _, S = $f[x], C = p(() => up(e), [e]), w = p(() => dp(t, C), [t, C]), T = (e) => {
15631
+ }, vp = ({ nodes: e, edges: t = [], center: n = mp, zoom: r = 12, height: i = 420, selectedNodeId: a, onNodeClick: o, showLegend: s = !0, fitBoundsToNodes: c = !0, basemap: l, onBasemapChange: u, showBasemapSwitcher: d = !1, ariaLabel: f = "Mapa de red", className: m }) => {
15632
+ let g = Lo(), [_, b] = h("street"), x = l ?? _, S = ep[x], C = p(() => dp(e), [e]), w = p(() => fp(t, C), [t, C]), T = (e) => {
15587
15633
  l === void 0 && b(e), u?.(e);
15588
15634
  };
15589
15635
  return /* @__PURE__ */ y("div", {
@@ -15602,13 +15648,13 @@ ${e.map((e) => `<Row>${n.map((t) => {
15602
15648
  attribution: S.attribution,
15603
15649
  url: S.url
15604
15650
  }),
15605
- c && e.length > 0 && /* @__PURE__ */ v(gp, { nodes: e }),
15651
+ c && e.length > 0 && /* @__PURE__ */ v(_p, { nodes: e }),
15606
15652
  w.map(({ edge: e, line: t }) => {
15607
- let n = ip[e.type ?? "backbone"];
15653
+ let n = ap[e.type ?? "backbone"];
15608
15654
  return /* @__PURE__ */ v(re, {
15609
15655
  positions: t,
15610
15656
  pathOptions: {
15611
- color: ap(n.color),
15657
+ color: op(n.color),
15612
15658
  weight: n.weight,
15613
15659
  dashArray: n.dashArray
15614
15660
  }
@@ -15616,7 +15662,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15616
15662
  }),
15617
15663
  e.map((e) => /* @__PURE__ */ v(te, {
15618
15664
  position: C[e.id],
15619
- icon: hp(e, e.id === a),
15665
+ icon: gp(e, e.id === a),
15620
15666
  title: e.label,
15621
15667
  alt: `${e.label}, estado ${e.status}`,
15622
15668
  keyboard: !!o,
@@ -15640,17 +15686,17 @@ ${e.map((e) => `<Row>${n.map((t) => {
15640
15686
  children: e === "street" ? "Mapa" : "Satélite"
15641
15687
  }, e))
15642
15688
  }),
15643
- s && e.length > 0 && /* @__PURE__ */ v(fp, {
15689
+ s && e.length > 0 && /* @__PURE__ */ v(pp, {
15644
15690
  nodes: e,
15645
15691
  edges: t
15646
15692
  })
15647
15693
  ]
15648
15694
  });
15649
- }, vp = {
15695
+ }, yp = {
15650
15696
  edit: "sf-audit-timeline__icon-wrap--edit",
15651
15697
  sync: "sf-audit-timeline__icon-wrap--sync",
15652
15698
  create: "sf-audit-timeline__icon-wrap--create"
15653
- }, yp = ({ items: e, sectionTitle: t = "Historial de movimientos", eventCountLabel: n, ariaLabel: r = "Historial de movimientos", emptyMessage: i = "Sin eventos", className: a }) => {
15699
+ }, bp = ({ items: e, sectionTitle: t = "Historial de movimientos", eventCountLabel: n, ariaLabel: r = "Historial de movimientos", emptyMessage: i = "Sin eventos", className: a }) => {
15654
15700
  let o = n ?? `${e.length} evento${e.length === 1 ? "" : "s"}`;
15655
15701
  return /* @__PURE__ */ y("section", {
15656
15702
  className: (0, X.default)("sf-audit-timeline", a),
@@ -15689,11 +15735,11 @@ ${e.map((e) => `<Row>${n.map((t) => {
15689
15735
  /* @__PURE__ */ v("div", {
15690
15736
  className: "sf-audit-timeline__marker",
15691
15737
  children: t.icon ? /* @__PURE__ */ v("span", {
15692
- className: (0, X.default)("sf-audit-timeline__icon-wrap", vp[r]),
15738
+ className: (0, X.default)("sf-audit-timeline__icon-wrap", yp[r]),
15693
15739
  "aria-hidden": "true",
15694
15740
  children: t.icon
15695
15741
  }) : /* @__PURE__ */ v("span", {
15696
- className: (0, X.default)("sf-audit-timeline__icon-wrap", vp[r]),
15742
+ className: (0, X.default)("sf-audit-timeline__icon-wrap", yp[r]),
15697
15743
  "aria-hidden": "true"
15698
15744
  })
15699
15745
  }),
@@ -15729,16 +15775,16 @@ ${e.map((e) => `<Row>${n.map((t) => {
15729
15775
  })]
15730
15776
  })]
15731
15777
  });
15732
- }, bp = {
15778
+ }, xp = {
15733
15779
  info: "sf-record-list__icon--info",
15734
15780
  warning: "sf-record-list__icon--warning",
15735
15781
  success: "sf-record-list__icon--success",
15736
15782
  neutral: "sf-record-list__icon--neutral"
15737
- }, xp = ({ icon: e, iconTone: t = "info", title: n, subtitle: r, badge: i, actions: a, className: o }) => /* @__PURE__ */ y("article", {
15783
+ }, Sp = ({ icon: e, iconTone: t = "info", title: n, subtitle: r, badge: i, actions: a, className: o }) => /* @__PURE__ */ y("article", {
15738
15784
  className: (0, X.default)("sf-record-list__item", o),
15739
15785
  children: [
15740
15786
  e && /* @__PURE__ */ v("span", {
15741
- className: (0, X.default)("sf-record-list__icon", bp[t]),
15787
+ className: (0, X.default)("sf-record-list__icon", xp[t]),
15742
15788
  "aria-hidden": "true",
15743
15789
  children: e
15744
15790
  }),
@@ -15763,7 +15809,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15763
15809
  children: a
15764
15810
  })
15765
15811
  ]
15766
- }), Sp = ({ title: e, action: t, items: n, className: r, ariaLabel: i }) => /* @__PURE__ */ y("section", {
15812
+ }), Cp = ({ title: e, action: t, items: n, className: r, ariaLabel: i }) => /* @__PURE__ */ y("section", {
15767
15813
  className: (0, X.default)("sf-record-list", r),
15768
15814
  "aria-label": i ?? (typeof e == "string" ? e : void 0),
15769
15815
  children: [(e || t) && /* @__PURE__ */ y("div", {
@@ -15777,9 +15823,9 @@ ${e.map((e) => `<Row>${n.map((t) => {
15777
15823
  })]
15778
15824
  }), /* @__PURE__ */ v("div", {
15779
15825
  className: "sf-record-list__items",
15780
- children: n.map((e, t) => /* @__PURE__ */ v(xp, { ...e }, e.id ?? t))
15826
+ children: n.map((e, t) => /* @__PURE__ */ v(Sp, { ...e }, e.id ?? t))
15781
15827
  })]
15782
- }), Cp = ({ label: e, pulse: t = !0, className: n }) => /* @__PURE__ */ y("span", {
15828
+ }), wp = ({ label: e, pulse: t = !0, className: n }) => /* @__PURE__ */ y("span", {
15783
15829
  className: (0, X.default)("sf-live-chip", n),
15784
15830
  children: [/* @__PURE__ */ v("span", {
15785
15831
  className: (0, X.default)("sf-live-chip__dot", t && "sf-live-chip__dot--pulse"),
@@ -15788,12 +15834,12 @@ ${e.map((e) => `<Row>${n.map((t) => {
15788
15834
  className: "sf-live-chip__label",
15789
15835
  children: e
15790
15836
  })]
15791
- }), wp = {
15837
+ }), Tp = {
15792
15838
  default: "var(--sf-text, #1B2A38)",
15793
15839
  success: "#1F8A4C",
15794
15840
  warning: "#C76A12",
15795
15841
  danger: "#C0392B"
15796
- }, Tp = {
15842
+ }, Ep = {
15797
15843
  display: "flex",
15798
15844
  alignItems: "center",
15799
15845
  justifyContent: "space-between",
@@ -15804,110 +15850,110 @@ ${e.map((e) => `<Row>${n.map((t) => {
15804
15850
  border: "1px solid var(--sf-border, #E2E8EC)",
15805
15851
  borderRadius: 13,
15806
15852
  boxShadow: "0 1px 3px rgba(12,33,49,.06), 0 1px 2px rgba(12,33,49,.04)"
15807
- }, Ep = {
15853
+ }, Dp = {
15808
15854
  display: "flex",
15809
15855
  alignItems: "center",
15810
15856
  gap: 14,
15811
15857
  flexWrap: "wrap"
15812
- }, Dp = {
15858
+ }, Op = {
15813
15859
  width: 1,
15814
15860
  height: 20,
15815
15861
  background: "var(--sf-border, #DCE3E7)"
15816
- }, Op = {
15862
+ }, kp = {
15817
15863
  fontSize: 13,
15818
15864
  fontWeight: 600,
15819
15865
  color: "var(--sf-text-subtle, #8A98A4)"
15820
- }, kp = {
15866
+ }, Ap = {
15821
15867
  fontSize: 15,
15822
15868
  fontWeight: 800,
15823
15869
  color: "var(--sf-text, #1B2A38)",
15824
15870
  fontVariantNumeric: "tabular-nums"
15825
- }, Ap = {
15871
+ }, jp = {
15826
15872
  fontSize: 12.5,
15827
15873
  fontWeight: 800,
15828
15874
  color: "#C76A12"
15829
- }, jp = {
15875
+ }, Mp = {
15830
15876
  fontSize: 13,
15831
15877
  fontWeight: 700,
15832
15878
  color: "var(--sf-text-subtle, #5C7180)"
15833
- }, Mp = {
15879
+ }, Np = {
15834
15880
  display: "flex",
15835
15881
  alignItems: "center",
15836
15882
  gap: 22,
15837
15883
  margin: 0
15838
- }, Np = {
15884
+ }, Pp = {
15839
15885
  display: "flex",
15840
15886
  alignItems: "baseline",
15841
15887
  gap: 6
15842
- }, Pp = {
15888
+ }, Fp = {
15843
15889
  fontSize: 10.5,
15844
15890
  fontWeight: 700,
15845
15891
  letterSpacing: ".05em",
15846
15892
  textTransform: "uppercase",
15847
15893
  color: "var(--sf-text-subtle, #8A98A4)"
15848
- }, Fp = ({ liveLabel: e, metrics: t, nextDeparture: n, className: r, ariaLabel: i = "Estado en vivo" }) => /* @__PURE__ */ y("section", {
15894
+ }, Ip = ({ liveLabel: e, metrics: t, nextDeparture: n, className: r, ariaLabel: i = "Estado en vivo" }) => /* @__PURE__ */ y("section", {
15849
15895
  className: (0, X.default)("sf-live-status-bar", r),
15850
15896
  "aria-label": i,
15851
- style: Tp,
15897
+ style: Ep,
15852
15898
  children: [/* @__PURE__ */ y("div", {
15853
- style: Ep,
15899
+ style: Dp,
15854
15900
  children: [
15855
- /* @__PURE__ */ v(Cp, { label: "En vivo" }),
15901
+ /* @__PURE__ */ v(wp, { label: "En vivo" }),
15856
15902
  /* @__PURE__ */ v("span", {
15857
- style: jp,
15903
+ style: Mp,
15858
15904
  children: e
15859
15905
  }),
15860
15906
  n && /* @__PURE__ */ y(_, { children: [
15861
15907
  /* @__PURE__ */ v("span", {
15862
- style: Dp,
15908
+ style: Op,
15863
15909
  "aria-hidden": "true"
15864
15910
  }),
15865
15911
  /* @__PURE__ */ v("span", {
15866
- style: Op,
15912
+ style: kp,
15867
15913
  children: n.label ?? "Próxima salida"
15868
15914
  }),
15869
15915
  /* @__PURE__ */ v("span", {
15870
- style: kp,
15916
+ style: Ap,
15871
15917
  children: n.time
15872
15918
  }),
15873
15919
  n.countdown != null && /* @__PURE__ */ v("span", {
15874
- style: Ap,
15920
+ style: jp,
15875
15921
  children: n.countdown
15876
15922
  })
15877
15923
  ] })
15878
15924
  ]
15879
15925
  }), /* @__PURE__ */ v("dl", {
15880
- style: Mp,
15926
+ style: Np,
15881
15927
  children: t.map((e, t) => /* @__PURE__ */ y("div", {
15882
- style: Np,
15928
+ style: Pp,
15883
15929
  children: [/* @__PURE__ */ v("dd", {
15884
15930
  style: {
15885
15931
  margin: 0,
15886
15932
  fontSize: 20,
15887
15933
  fontWeight: 800,
15888
15934
  fontVariantNumeric: "tabular-nums",
15889
- color: wp[e.accent ?? "default"]
15935
+ color: Tp[e.accent ?? "default"]
15890
15936
  },
15891
15937
  children: e.value
15892
15938
  }), /* @__PURE__ */ v("dt", {
15893
- style: Pp,
15939
+ style: Fp,
15894
15940
  children: e.label
15895
15941
  })]
15896
15942
  }, e.id ?? `${e.label}-${t}`))
15897
15943
  })]
15898
- }), Ip = {
15944
+ }), Lp = {
15899
15945
  success: "sf-timeline__dot--success",
15900
15946
  warning: "sf-timeline__dot--warning",
15901
15947
  danger: "sf-timeline__dot--danger",
15902
15948
  info: "sf-timeline__dot--info",
15903
15949
  default: "sf-timeline__dot--default"
15904
- }, Lp = {
15950
+ }, Rp = {
15905
15951
  success: "sf-timeline__icon-wrap--success",
15906
15952
  warning: "sf-timeline__icon-wrap--warning",
15907
15953
  danger: "sf-timeline__icon-wrap--danger",
15908
15954
  info: "sf-timeline__icon-wrap--info",
15909
15955
  default: "sf-timeline__icon-wrap--default"
15910
- }, Rp = ({ items: e, ariaLabel: t = "Línea de tiempo", emptyMessage: n = "Sin eventos", className: r }) => /* @__PURE__ */ y("ol", {
15956
+ }, zp = ({ items: e, ariaLabel: t = "Línea de tiempo", emptyMessage: n = "Sin eventos", className: r }) => /* @__PURE__ */ y("ol", {
15911
15957
  className: (0, X.default)("sf-timeline", r),
15912
15958
  "aria-label": t,
15913
15959
  children: [e.length === 0 && /* @__PURE__ */ v("li", {
@@ -15926,11 +15972,11 @@ ${e.map((e) => `<Row>${n.map((t) => {
15926
15972
  /* @__PURE__ */ v("div", {
15927
15973
  className: "sf-timeline__marker",
15928
15974
  children: t.icon ? /* @__PURE__ */ v("span", {
15929
- className: (0, X.default)("sf-timeline__icon-wrap", Lp[r]),
15975
+ className: (0, X.default)("sf-timeline__icon-wrap", Rp[r]),
15930
15976
  "aria-hidden": "true",
15931
15977
  children: t.icon
15932
15978
  }) : /* @__PURE__ */ v("span", {
15933
- className: (0, X.default)("sf-timeline__dot", Ip[r]),
15979
+ className: (0, X.default)("sf-timeline__dot", Lp[r]),
15934
15980
  "aria-hidden": "true"
15935
15981
  })
15936
15982
  }),
@@ -15953,7 +15999,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
15953
15999
  ]
15954
16000
  }, t.id ?? n);
15955
16001
  })]
15956
- }), zp = ({ items: e, autoPlay: t = !1, intervalMs: n = 4e3, showDots: r = !0, showArrows: i = !0, className: a }) => {
16002
+ }), Bp = ({ items: e, autoPlay: t = !1, intervalMs: n = 4e3, showDots: r = !0, showArrows: i = !0, className: a }) => {
15957
16003
  let o = m(null), [c, l] = h(0), d = s((t) => {
15958
16004
  let n = o.current;
15959
16005
  if (!n || e.length === 0) return;
@@ -16015,7 +16061,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
16015
16061
  })
16016
16062
  ]
16017
16063
  });
16018
- }, Bp = ({ src: e, alt: t, aspectRatio: n = "16/9", fit: r = "cover", overlay: i = "none", children: a, rounded: o = !0, loading: s = "lazy", fallback: c, className: l, imgProps: u }) => {
16064
+ }, Vp = ({ src: e, alt: t, aspectRatio: n = "16/9", fit: r = "cover", overlay: i = "none", children: a, rounded: o = !0, loading: s = "lazy", fallback: c, className: l, imgProps: u }) => {
16019
16065
  let [d, f] = h(!1), p = !!e && !d;
16020
16066
  return /* @__PURE__ */ y("div", {
16021
16067
  className: (0, X.default)("sf-media-panel", o && "sf-media-panel--rounded", l),
@@ -16042,19 +16088,19 @@ ${e.map((e) => `<Row>${n.map((t) => {
16042
16088
  })
16043
16089
  ]
16044
16090
  });
16045
- }, Vp = {
16091
+ }, Hp = {
16046
16092
  top: 8,
16047
16093
  right: 8,
16048
16094
  left: 0,
16049
16095
  bottom: 0
16050
- }, Hp = {
16096
+ }, Up = {
16051
16097
  top: 20,
16052
16098
  right: 8,
16053
16099
  left: 0,
16054
16100
  bottom: 0
16055
- }, Up = (e, t) => {
16101
+ }, Wp = (e, t) => {
16056
16102
  if (t !== "none") return e.stackId ?? "sf-stack";
16057
- }, Wp = (e) => e?.map((e, t) => {
16103
+ }, Gp = (e) => e?.map((e, t) => {
16058
16104
  let n = e.color ?? "var(--sf-chart-reference)", r = {
16059
16105
  stroke: n,
16060
16106
  strokeDasharray: e.strokeDasharray ?? "4 4",
@@ -16085,7 +16131,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
16085
16131
  }
16086
16132
  })
16087
16133
  }, `ref-${t}`);
16088
- }), Gp = ({ type: e, data: t, xKey: n, series: r, height: i = 280, ariaLabel: a, emptyMessage: o = "Sin datos para mostrar", className: s, showGrid: c = !0, showTooltip: l = !0, showLegend: u = r.length > 1, orientation: d = "vertical", stacking: f = "none", unit: m, yDomain: h, xAxisFormat: g, yAxisFormat: b, tooltipFormat: x, valueLabelFormat: S, showValueLabels: C = !1, referenceLines: w, onDataPointClick: T }) => {
16134
+ }), Kp = ({ type: e, data: t, xKey: n, series: r, height: i = 280, ariaLabel: a, emptyMessage: o = "Sin datos para mostrar", className: s, showGrid: c = !0, showTooltip: l = !0, showLegend: u = r.length > 1, orientation: d = "vertical", stacking: f = "none", unit: m, yDomain: h, xAxisFormat: g, yAxisFormat: b, tooltipFormat: x, valueLabelFormat: S, showValueLabels: C = !1, referenceLines: w, onDataPointClick: T }) => {
16089
16135
  let E = e === "bar" && d === "horizontal", D = e === "line" ? "none" : f, O = D === "stacked-100", k = p(() => O ? gs(t, r) : t, [
16090
16136
  t,
16091
16137
  r,
@@ -16120,7 +16166,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
16120
16166
  0,
16121
16167
  0
16122
16168
  ],
16123
- stackId: Up(e, D),
16169
+ stackId: Wp(e, D),
16124
16170
  maxBarSize: D === "none" ? 48 : void 0,
16125
16171
  children: z(e.key)
16126
16172
  }, e.key))
@@ -16156,7 +16202,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
16156
16202
  fill: n,
16157
16203
  fillOpacity: .15,
16158
16204
  strokeWidth: 2,
16159
- stackId: Up(e, D),
16205
+ stackId: Wp(e, D),
16160
16206
  children: z(e.key)
16161
16207
  }, e.key);
16162
16208
  })
@@ -16173,7 +16219,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
16173
16219
  children: /* @__PURE__ */ y(B, {
16174
16220
  data: k,
16175
16221
  layout: E ? "vertical" : "horizontal",
16176
- margin: C ? Hp : Vp,
16222
+ margin: C ? Up : Hp,
16177
16223
  onClick: R,
16178
16224
  children: [
16179
16225
  c && /* @__PURE__ */ v(ue, {
@@ -16211,7 +16257,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
16211
16257
  formatter: L
16212
16258
  }),
16213
16259
  u && /* @__PURE__ */ v(pe, { wrapperStyle: ds }),
16214
- Wp(w),
16260
+ Gp(w),
16215
16261
  ee()
16216
16262
  ]
16217
16263
  })
@@ -16221,7 +16267,17 @@ ${e.map((e) => `<Row>${n.map((t) => {
16221
16267
  children: o
16222
16268
  })
16223
16269
  });
16224
- }, Kp = ({ x: e, y: t, payload: n, data: r, showValues: i, format: a, color: o }) => {
16270
+ }, qp = ({ items: e, className: t }) => /* @__PURE__ */ v("ul", {
16271
+ className: (0, X.default)("sf-chart-legend", t),
16272
+ children: e.map((e) => /* @__PURE__ */ y("li", {
16273
+ className: "sf-chart-legend__item",
16274
+ children: [/* @__PURE__ */ v("span", {
16275
+ className: "sf-chart-legend__swatch",
16276
+ style: { backgroundColor: e.color },
16277
+ "aria-hidden": "true"
16278
+ }), e.label]
16279
+ }, e.label))
16280
+ }), Jp = ({ x: e, y: t, payload: n, data: r, showValues: i, format: a, color: o }) => {
16225
16281
  let s = r.find((e) => e.label === n.value);
16226
16282
  return /* @__PURE__ */ y("g", { children: [/* @__PURE__ */ v("text", {
16227
16283
  x: e,
@@ -16242,7 +16298,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
16242
16298
  },
16243
16299
  children: a(s.value, s.key)
16244
16300
  })] });
16245
- }, qp = ({ data: e, max: t = 100, color: n, height: r = 280, ariaLabel: i = "Diagnóstico", emptyMessage: a = "Sin datos para mostrar", className: o, showTooltip: s = !0, showLegend: c = !1, showValues: l = !1, valueFormat: u }) => {
16301
+ }, Yp = ({ data: e, max: t = 100, color: n, height: r = 280, ariaLabel: i = "Diagnóstico", emptyMessage: a = "Sin datos para mostrar", className: o, showTooltip: s = !0, showLegend: c = !1, showValues: l = !1, valueFormat: u }) => {
16246
16302
  let d = e.length > 0, f = cs({ color: n }, 0), p = u ?? ps();
16247
16303
  return /* @__PURE__ */ v("div", {
16248
16304
  className: (0, X.default)("sf-chart", o),
@@ -16259,7 +16315,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
16259
16315
  /* @__PURE__ */ v(_e, { stroke: "var(--sf-chart-grid)" }),
16260
16316
  /* @__PURE__ */ v(ge, {
16261
16317
  dataKey: "label",
16262
- tick: /* @__PURE__ */ v(Kp, {
16318
+ tick: /* @__PURE__ */ v(Jp, {
16263
16319
  x: 0,
16264
16320
  y: 0,
16265
16321
  payload: { value: "" },
@@ -16297,8 +16353,8 @@ ${e.map((e) => `<Row>${n.map((t) => {
16297
16353
  children: a
16298
16354
  })
16299
16355
  });
16300
- }, Jp = (e) => Math.min(100, Math.max(0, e)), Yp = ({ value: e, average: t, min: n, max: r, unit: i, label: a, valueFormat: o, direction: s = "down-good", className: c }) => {
16301
- let l = o ?? ps(i), u = Math.abs(e - t) || Math.abs(t) * .1 || 1, d = n ?? Math.min(e, t) - u * .5, f = r ?? Math.max(e, t) + u * .5, p = (e) => f > d ? Jp((e - d) / (f - d) * 100) : 50, m = p(e), h = p(t), g = t === 0 ? 0 : (e - t) / Math.abs(t) * 100, _ = s === "neutral" ? null : s === "down-good" ? g <= 0 : g >= 0, b = Math.abs(g) >= .5;
16356
+ }, Xp = (e) => Math.min(100, Math.max(0, e)), Zp = ({ value: e, average: t, min: n, max: r, unit: i, label: a, valueFormat: o, direction: s = "down-good", className: c }) => {
16357
+ let l = o ?? ps(i), u = Math.abs(e - t) || Math.abs(t) * .1 || 1, d = n ?? Math.min(e, t) - u * .5, f = r ?? Math.max(e, t) + u * .5, p = (e) => f > d ? Xp((e - d) / (f - d) * 100) : 50, m = p(e), h = p(t), g = t === 0 ? 0 : (e - t) / Math.abs(t) * 100, _ = s === "neutral" ? null : s === "down-good" ? g <= 0 : g >= 0, b = Math.abs(g) >= .5;
16302
16358
  return /* @__PURE__ */ y("div", {
16303
16359
  className: (0, X.default)("sf-deviation-band", c),
16304
16360
  children: [
@@ -16338,7 +16394,7 @@ ${e.map((e) => `<Row>${n.map((t) => {
16338
16394
  })
16339
16395
  ]
16340
16396
  });
16341
- }, Xp = (e, { initialPageSize: t = 10 } = {}) => {
16397
+ }, Qp = (e, { initialPageSize: t = 10 } = {}) => {
16342
16398
  let [n, r] = h(""), [i, a] = h(0), [o, s] = h(t), c = p(() => {
16343
16399
  let t = n.trim().toLowerCase();
16344
16400
  return t ? e.filter((e) => Object.values(e).some((e) => String(e ?? "").toLowerCase().includes(t))) : e;
@@ -16365,37 +16421,37 @@ ${e.map((e) => `<Row>${n.map((t) => {
16365
16421
  ]),
16366
16422
  totalItems: l
16367
16423
  };
16368
- }, Zp = (e) => String(e ?? "").normalize("NFD").replace(/[\u0300-\u036f]/g, "").toLowerCase().trim(), Qp = (e) => typeof e == "string" || typeof e == "number", $p = (e, t) => {
16369
- let n = Zp(t);
16424
+ }, $p = (e) => String(e ?? "").normalize("NFD").replace(/[\u0300-\u036f]/g, "").toLowerCase().trim(), em = (e) => typeof e == "string" || typeof e == "number", tm = (e, t) => {
16425
+ let n = $p(t);
16370
16426
  return typeof t == "number" && (n = `#${n}`), e.toLowerCase().endsWith("codigo") && !n.startsWith("#") && (n = `.${n}`), n;
16371
- }, em = (e, t, n) => {
16427
+ }, nm = (e, t, n) => {
16372
16428
  if (t?.length) return [...t];
16373
16429
  let r = new Set(n), i = [];
16374
- for (let t in e) r.has(t) || Qp(e[t]) && i.push(t);
16430
+ for (let t in e) r.has(t) || em(e[t]) && i.push(t);
16375
16431
  return i;
16376
- }, tm = (e, t, n) => {
16377
- let r = "", i = em(e, t, n);
16432
+ }, rm = (e, t, n) => {
16433
+ let r = "", i = nm(e, t, n);
16378
16434
  for (let t of i) {
16379
16435
  let n = e[t];
16380
- if (!Qp(n)) continue;
16381
- let i = $p(t, n);
16436
+ if (!em(n)) continue;
16437
+ let i = tm(t, n);
16382
16438
  i && (r += `${i} `);
16383
16439
  }
16384
16440
  return r;
16385
- }, nm = (e) => {
16441
+ }, im = (e) => {
16386
16442
  let t = e.split(";"), n = [];
16387
16443
  for (let e of t) {
16388
- let t = Zp(e);
16444
+ let t = $p(e);
16389
16445
  t.length >= 2 && n.push(t);
16390
16446
  }
16391
16447
  return n;
16392
- }, rm = (e, t) => {
16393
- let [n, r] = h(""), i = l(n), a = t?.filters, o = t?.searchableKeys, s = t?.ignoredKeys, c = p(() => nm(i), [i]), u = p(() => {
16448
+ }, am = (e, t) => {
16449
+ let [n, r] = h(""), i = l(n), a = t?.filters, o = t?.searchableKeys, s = t?.ignoredKeys, c = p(() => im(i), [i]), u = p(() => {
16394
16450
  if (!e?.length) return [];
16395
16451
  let t = [];
16396
16452
  for (let n of e) t.push({
16397
16453
  item: n,
16398
- searchIndex: tm(n, o, s)
16454
+ searchIndex: rm(n, o, s)
16399
16455
  });
16400
16456
  return t;
16401
16457
  }, [
@@ -16437,15 +16493,15 @@ ${e.map((e) => `<Row>${n.map((t) => {
16437
16493
  };
16438
16494
  //#endregion
16439
16495
  //#region src/hooks/useArrayPaginator.ts
16440
- function im(e, t, n) {
16496
+ function om(e, t, n) {
16441
16497
  if (t <= 0) return [];
16442
16498
  let r = Math.max(0, n);
16443
16499
  return r >= e.length ? [] : e.slice(r, r + t);
16444
16500
  }
16445
- var am = (e, t, n) => {
16501
+ var sm = (e, t, n) => {
16446
16502
  let r = e?.[n], i = t?.[n];
16447
16503
  return r == null && i == null ? 0 : r == null ? -1 : i == null ? 1 : typeof r == "boolean" && typeof i == "boolean" ? Number(r) - Number(i) : typeof r == "number" && typeof i == "number" ? r - i : r instanceof Date && i instanceof Date ? r.getTime() - i.getTime() : typeof r == "string" && typeof i == "string" ? r.localeCompare(i, void 0, { sensitivity: "base" }) : String(r).localeCompare(String(i), void 0, { sensitivity: "base" });
16448
- }, om = (e, t) => {
16504
+ }, cm = (e, t) => {
16449
16505
  let [n, r] = h([]), [i, a] = h(() => ({
16450
16506
  limit: Math.max(1, t?.limit ?? 100),
16451
16507
  offset: 0
@@ -16458,7 +16514,7 @@ var am = (e, t, n) => {
16458
16514
  if (e.length === 0) return [];
16459
16515
  let r = [...e];
16460
16516
  if (n.length > 0) {
16461
- let e = t?.onSortFunc ?? am, i = t?.strictSort ?? !1;
16517
+ let e = t?.onSortFunc ?? sm, i = t?.strictSort ?? !1;
16462
16518
  r.sort((t, r) => {
16463
16519
  for (let { id: a, desc: o } of n) {
16464
16520
  if (i && (!(typeof t == "object" && t) || !(typeof r == "object" && r) || !(a in t) || !(a in r))) continue;
@@ -16468,7 +16524,7 @@ var am = (e, t, n) => {
16468
16524
  return 0;
16469
16525
  });
16470
16526
  }
16471
- return im(r, o, c);
16527
+ return om(r, o, c);
16472
16528
  }, [
16473
16529
  e,
16474
16530
  o,
@@ -16487,7 +16543,7 @@ var am = (e, t, n) => {
16487
16543
  onSortChange: r,
16488
16544
  pageData: u
16489
16545
  };
16490
- }, sm = (e, t) => {
16546
+ }, lm = (e, t) => {
16491
16547
  if (typeof window > "u") return t;
16492
16548
  try {
16493
16549
  let n = window.localStorage.getItem(e);
@@ -16495,8 +16551,8 @@ var am = (e, t, n) => {
16495
16551
  } catch {
16496
16552
  return t;
16497
16553
  }
16498
- }, cm = (e, t) => {
16499
- let [n, r] = h(() => sm(e, t));
16554
+ }, um = (e, t) => {
16555
+ let [n, r] = h(() => lm(e, t));
16500
16556
  return [n, (t) => {
16501
16557
  r((n) => {
16502
16558
  let r = typeof t == "function" ? t(n) : t;
@@ -16506,82 +16562,82 @@ var am = (e, t, n) => {
16506
16562
  return r;
16507
16563
  });
16508
16564
  }];
16509
- }, lm = (e) => typeof window > "u" ? null : new URL(window.location.href).searchParams.get(e), um = (e, t) => {
16565
+ }, dm = (e) => typeof window > "u" ? null : new URL(window.location.href).searchParams.get(e), fm = (e, t) => {
16510
16566
  if (typeof window > "u") return;
16511
16567
  let n = new URL(window.location.href);
16512
16568
  t != null && t !== "" ? n.searchParams.set(e, t) : n.searchParams.delete(e), window.history.replaceState(null, "", n.toString());
16513
- }, dm = (e) => {
16514
- um(e, null);
16515
- }, fm = (e, t) => {
16569
+ }, pm = (e) => {
16570
+ fm(e, null);
16571
+ }, mm = (e, t) => {
16516
16572
  let [n, r] = h(() => {
16517
16573
  let n = typeof e == "function" ? e() : e;
16518
16574
  if (!t) return n;
16519
- let r = lm(t);
16520
- return r == null || r === "" ? (um(t, n), n) : r;
16575
+ let r = dm(t);
16576
+ return r == null || r === "" ? (fm(t, n), n) : r;
16521
16577
  });
16522
16578
  return [n, (e) => {
16523
16579
  r((n) => {
16524
16580
  let r = typeof e == "function" ? e(n) : e;
16525
- return t && um(t, r), r;
16581
+ return t && fm(t, r), r;
16526
16582
  });
16527
16583
  }];
16528
- }, pm = () => {
16584
+ }, hm = () => {
16529
16585
  let e = globalThis.process?.env?.NODE_ENV;
16530
16586
  return e != null && e === "development";
16531
- }, mm = (e, t) => {
16587
+ }, gm = (e, t) => {
16532
16588
  let n = x({
16533
16589
  resolver: De(e),
16534
16590
  defaultValues: t?.defaultValues
16535
16591
  }), r = (e, t) => n.handleSubmit(e, (e, n) => {
16536
- pm() && console.log(e), t?.(e, n);
16592
+ hm() && console.log(e), t?.(e, n);
16537
16593
  });
16538
16594
  return {
16539
16595
  ...n,
16540
16596
  handleSubmit: r
16541
16597
  };
16542
- }, hm = (e) => {
16543
- let t = El(e);
16598
+ }, _m = (e) => {
16599
+ let t = Dl(e);
16544
16600
  return /[",\n\r]/.test(t) ? `"${t.replace(/"/g, "\"\"")}"` : t;
16545
- }, gm = (e, t) => {
16601
+ }, vm = (e, t) => {
16546
16602
  if (typeof document > "u") return;
16547
- let n = `\uFEFF${[t.columns.map((e) => hm(e.header)).join(","), ...e.map((e) => t.columns.map((t) => hm(t.getValue(e))).join(","))].join("\n")}`, r = new Blob([n], { type: "text/csv;charset=utf-8" }), i = URL.createObjectURL(r), a = document.createElement("a");
16603
+ let n = `\uFEFF${[t.columns.map((e) => _m(e.header)).join(","), ...e.map((e) => t.columns.map((t) => _m(t.getValue(e))).join(","))].join("\n")}`, r = new Blob([n], { type: "text/csv;charset=utf-8" }), i = URL.createObjectURL(r), a = document.createElement("a");
16548
16604
  a.href = i, a.download = t.filename ?? "export.csv", a.click(), URL.revokeObjectURL(i);
16549
- }, _m = "Este campo es requerido", vm = "Introduce una dirección de correo electrónico válida", ym = "El correo electrónico es obligatorio", bm = "El valor de este campo es inválido", xm = "Introduce un número de celular válido", Sm = (e) => e == null ? null : typeof e == "string" ? e.trim() === "" ? null : e.trim() : e, Cm = (e = _m) => G.string().transform(Sm).required(e), wm = () => G.string().transform(Sm).default(null).nullable(), Tm = (e = ym) => G.string().transform(Sm).email(vm).required(e), Em = (e = vm) => G.string().transform(Sm).test("emailTest", e, (e) => e == null || e === "" || G.string().email().isValidSync(e)).default(null).nullable(), Dm = (e, t = bm, n = _m) => G.string().transform(Sm).trim().test("rgxValidation", t, (t) => t == null || t === "" || t.match(e) != null).required(n), Om = (e, t = bm) => G.string().transform(Sm).test("rgxValidation", t, (t) => t == null || t === "" || t.match(e) != null).default(null).nullable(), km = (e) => {
16605
+ }, ym = "Este campo es requerido", bm = "Introduce una dirección de correo electrónico válida", xm = "El correo electrónico es obligatorio", Sm = "El valor de este campo es inválido", Cm = "Introduce un número de celular válido", wm = (e) => e == null ? null : typeof e == "string" ? e.trim() === "" ? null : e.trim() : e, Tm = (e = ym) => G.string().transform(wm).required(e), Em = () => G.string().transform(wm).default(null).nullable(), Dm = (e = xm) => G.string().transform(wm).email(bm).required(e), Om = (e = bm) => G.string().transform(wm).test("emailTest", e, (e) => e == null || e === "" || G.string().email().isValidSync(e)).default(null).nullable(), km = (e, t = Sm, n = ym) => G.string().transform(wm).trim().test("rgxValidation", t, (t) => t == null || t === "" || t.match(e) != null).required(n), Am = (e, t = Sm) => G.string().transform(wm).test("rgxValidation", t, (t) => t == null || t === "" || t.match(e) != null).default(null).nullable(), jm = (e) => {
16550
16606
  let t = e?.minLength == null ? void 0 : Math.max(1, e.minLength);
16551
16607
  return {
16552
16608
  minLength: t,
16553
16609
  maxLength: e?.maxLength == null ? void 0 : Math.max(t ?? 1, e.maxLength)
16554
16610
  };
16555
- }, Am = (e) => {
16556
- let { minLength: t, maxLength: n } = km(e), r = /^[0-9]+$/, i = G.string().transform(Sm).test("rgxValidation", (e, t) => e == null || e === "" || e.match(r) != null || t.createError({ message: "El campo debe contener solo caracteres numéricos" }));
16611
+ }, Mm = (e) => {
16612
+ let { minLength: t, maxLength: n } = jm(e), r = /^[0-9]+$/, i = G.string().transform(wm).test("rgxValidation", (e, t) => e == null || e === "" || e.match(r) != null || t.createError({ message: "El campo debe contener solo caracteres numéricos" }));
16557
16613
  return t != null && (i = i.min(t, `El campo debe tener al menos ${t} caracteres`)), n != null && (i = i.max(n, `La longitud máxima permitida es de ${n} caracteres`)), i;
16558
- }, jm = (e) => Am(e).required(_m), Mm = (e) => Am(e).default(null).nullable(), Nm = (e = _m) => G.boolean().typeError("El tipo de dato debe ser booleano").required(e), Pm = () => G.boolean().typeError("El tipo de dato debe ser booleano").default(null).nullable(), Fm = (e, t) => t == null || t === "" ? null : Number.isNaN(e) ? void 0 : e, Im = (e = _m) => G.number().transform(Fm).typeError("Debe ser numérico").required(e), Lm = () => G.number().transform(Fm).typeError("Debe ser numérico").default(null).nullable().notRequired(), Rm = (e = _m) => G.number().transform(Fm).typeError("Este campo debe ser un valor número").min(0, "Este campo debe ser un valor número positivo").required(e), zm = (e = _m) => Rm(e).integer("Este campo debe ser un número entero"), Bm = () => G.number().transform(Fm).typeError("Este campo debe ser un valor número").min(0, "Este campo debe ser un valor número positivo").default(null).nullable(), Vm = () => Bm().integer("Este campo debe ser un número entero"), Hm = (e) => {
16614
+ }, Nm = (e) => Mm(e).required(ym), Pm = (e) => Mm(e).default(null).nullable(), Fm = (e = ym) => G.boolean().typeError("El tipo de dato debe ser booleano").required(e), Im = () => G.boolean().typeError("El tipo de dato debe ser booleano").default(null).nullable(), Lm = (e, t) => t == null || t === "" ? null : Number.isNaN(e) ? void 0 : e, Rm = (e = ym) => G.number().transform(Lm).typeError("Debe ser numérico").required(e), zm = () => G.number().transform(Lm).typeError("Debe ser numérico").default(null).nullable().notRequired(), Bm = (e = ym) => G.number().transform(Lm).typeError("Este campo debe ser un valor número").min(0, "Este campo debe ser un valor número positivo").required(e), Vm = (e = ym) => Bm(e).integer("Este campo debe ser un número entero"), Hm = () => G.number().transform(Lm).typeError("Este campo debe ser un valor número").min(0, "Este campo debe ser un valor número positivo").default(null).nullable(), Um = () => Hm().integer("Este campo debe ser un número entero"), Wm = (e) => {
16559
16615
  let t = /^(?:\+51)\s?[0-9]{3}\s?[0-9]{3}\s?[0-9]{3}$/;
16560
16616
  return G.string().transform((e) => e == null ? null : typeof e == "string" ? e.trim() === "" ? null : e.trim().startsWith("+") ? e.trim() : `+51 ${e.trim()}` : e).test("rgxValidation", e, (e) => e == null || e === "" || e.match(t) != null).default(null);
16561
- }, Um = (e = xm) => Hm(e).nullable(), Wm = (e = xm) => Hm(e).required(_m), Gm = (e = _m) => G.array().of(Cm()).min(1, "Debe contener al menos un elemento").required(e), Km = () => G.array().of(wm()).default(null).nullable(), qm = {
16562
- transformNullIfEmpty: Sm,
16563
- requiredString: Cm,
16564
- nullableString: wm,
16565
- requiredEmail: Tm,
16566
- nullableEmail: Em,
16567
- requiredMatchString: Dm,
16568
- nullableOrMatchString: Om,
16569
- requiredStringNumbersOnly: jm,
16570
- nullableStringNumbersOnly: Mm,
16571
- requiredBoolean: Nm,
16572
- nullableBoolean: Pm,
16573
- requiredNumber: Im,
16574
- nullableNumber: Lm,
16575
- requiredPositiveNumber: Rm,
16576
- requiredPositiveInteger: zm,
16577
- nullablePositiveNumber: Bm,
16578
- nullablePositiveInteger: Vm,
16579
- nullableCelular: Um,
16580
- requiredCelular: Wm,
16581
- requiredStringArray: Gm,
16582
- nullableStringArray: Km
16583
- }, Jm = (e) => G.object().shape(e(qm));
16617
+ }, Gm = (e = Cm) => Wm(e).nullable(), Km = (e = Cm) => Wm(e).required(ym), qm = (e = ym) => G.array().of(Tm()).min(1, "Debe contener al menos un elemento").required(e), Jm = () => G.array().of(Em()).default(null).nullable(), Ym = {
16618
+ transformNullIfEmpty: wm,
16619
+ requiredString: Tm,
16620
+ nullableString: Em,
16621
+ requiredEmail: Dm,
16622
+ nullableEmail: Om,
16623
+ requiredMatchString: km,
16624
+ nullableOrMatchString: Am,
16625
+ requiredStringNumbersOnly: Nm,
16626
+ nullableStringNumbersOnly: Pm,
16627
+ requiredBoolean: Fm,
16628
+ nullableBoolean: Im,
16629
+ requiredNumber: Rm,
16630
+ nullableNumber: zm,
16631
+ requiredPositiveNumber: Bm,
16632
+ requiredPositiveInteger: Vm,
16633
+ nullablePositiveNumber: Hm,
16634
+ nullablePositiveInteger: Um,
16635
+ nullableCelular: Gm,
16636
+ requiredCelular: Km,
16637
+ requiredStringArray: qm,
16638
+ nullableStringArray: Jm
16639
+ }, Xm = (e) => G.object().shape(e(Ym));
16584
16640
  //#endregion
16585
- export { ui as AccessDenied, ha as Accordion, ei as ActionButton, zr as ActiveFiltersBar, Kd as AddressSearchInput, ni as Alert, qc as AlertLane, Wc as AlertRowList, Yc as AlertSummaryList, Uf as AllocationBar, Oo as AppBarContainer, Do as AppShell, Co as AppsGridIcon, of as AreaInput, En as AsyncCardSelect, Ar as AsyncCustomTable, wn as AsyncSearchSelect, kn as AsyncSearchTableSelect, yp as AuditTimeline, za as Avatar, Ba as AvatarGroup, Ua as Badge, an as BooleanCheckbox, pa as Breadcrumb, $ as Button, Yr as ButtonGroup, ss as CHART_SERIES_COLORS, cn as COUNTRY_DIAL_CODES, sn as CURRENCY_SYMBOLS, _c as Calendar, ml as CardNote, zf as CardRadioGroup, Tn as CardSelect, zp as Carousel, Gp as Chart, $t as Checkbox, en as CheckboxGroup, Vo as CodeEditor, Ff as ColorInput, Ji as CommandPalette, Qc as ComparisonTable, Ci as ConfirmDialog, Ii as ContextMenuProvider, Qd as CoordinatesInput, _n as CurrencyInput, kr as CustomTable, lr as DEFAULT_PAGE_SIZE_OPTIONS, _l as DashboardBoard, il as DashboardCard, vl as DashboardCardRow, cl as DashboardGrid, fl as DashboardLayout, Sl as DashboardPageFrame, Tl as DashboardPlaceholder, ll as DashboardSection, dl as DashboardStatBar, Lt as DateInput, Ht as DatePicker, Ul as DateRangeFields, Rn as DateRangeInput, Wl as DateRangeUtcInput, yo as DateWeekStrip, Nl as DetailPanel, Ll as DetailPreviewList, Rl as DetailSection, pl as DetailSidePanel, Yp as DeviationBand, qp as DiagnosticRadar, Gn as DisplayField, fn as DniInput, Pc as DonutBreakdown, Dc as DonutGauge, Oc as DonutGaugeRow, Wi as Drawer, Il as DrilldownAlertList, Fl as DrilldownKPICard, Oi as DropdownMenu, ki as DropdownMenuItem, Gr as EditableDataGrid, ri as EmptyState, Zs as EntityCard, $s as EntityCardGrid, ai as ErrorView, zc as EventLog, Xc as EvidenceFootnote, Jr as ExpandableTableSection, Z as FieldLayout, iu as FileDropInput, Un as FileInput, Aa as FilterBar, Ma as FilterBarDate, ja as FilterBarField, Na as FilterBarSelect, Pa as FilterBarText, Qr as FormActions, Da as FormWizard, ca as HeightProvider, Pt as Input, La as ItineraryEditor, As as KPICard, Ms as KPIGrid, Lf as KeyValueInput, Cp as LiveChip, lo as LiveRouteBoard, Fp as LiveStatusBar, ci as LoadingView, Zd as LocationPicker, Uo as MIN_MAP_GEOCODER_QUERY_LENGTH, uc as MONTH_NAMES, Fa as MaestroLayout, mu as MapFrame, gu as MapLegend, os as MapPicker, yu as MapPointCard, hu as MapStatus, _u as MapToolbar, vu as MapVehiclePopup, Xd as MapView, ka as MasterDetailLayout, Oa as MasterDetailListItem, Bp as MediaPanel, Ti as MessageDialog, Vs as MetricBarList, Bs as MetricBarRow, xi as Modal, ac as ModuleCard, oc as ModuleCardGrid, su as MultiPhotoInput, $f as NETWORK_BASEMAPS, ip as NETWORK_EDGE_STYLES, tp as NETWORK_KIND_COLORS, ep as NETWORK_KIND_LABELS, np as NETWORK_STATUS_COLORS, rp as NETWORK_STATUS_LABELS, mr as NUMBER_FILTER_OPS, fp as NetworkLegend, _p as NetworkMap, Vi as NotificationBell, It as NumberInput, Df as NumberStepper, Kf as ORG_TREE_DEFAULT_THEMES, Ai as OptionItem, Qf as OrgTree, Vl as OtpInput, Zi as PageContainer, $i as PageHeader, fr as Pagination, ar as PaginationRangeInput, Za as PassengerBoardCard, Wt as PasswordInput, hn as PhoneInput, fu as PhotoCropInput, au as PhotoInput, Rt as Popover, Xi as ProductTour, Af as ProgressBar, Mf as ProgressBarReadonly, zi as QRView, Ls as QuickActionGrid, Is as QuickActionTile, tn as RadioGroup, kf as RangeSliderInput, Nf as RatingInput, nc as RecommendationCard, Sp as RecordList, xp as RecordListItem, li as RetryBlock, Fo as RichTextEditor, sf as RouteInput, Zr as RowActions, pn as RucInput, xu as SF_DEFAULT_MAP_CENTER, Su as SF_DEFAULT_MAP_ZOOM, Ou as SF_GOOGLE_ENGINE_CAPABILITIES, Du as SF_LEAFLET_ENGINE_CAPABILITIES, bu as SF_MAPS_CONFIG_ERROR, wu as SF_OSM_ATTRIBUTION, Cu as SF_OSM_TILE_URL, Eu as SF_SATELLITE_ATTRIBUTION, Tu as SF_SATELLITE_TILE_URL, pr as STRING_FILTER_OPS, ga as ScrollArea, Sn as SearchSelect, On as SearchTableSelect, Qt as Select, Bf as SemanticSlider, fa as Separator, Ld as SfProvider, Gi as Sheet, ea as SidePanel, oa as SidePanelContainer, ou as SignaturePad, fi as Skeleton, Cf as SliderInput, Bn as SmartDateInput, vn as SmartInput, cf as SmartMapInput, cu as SmartMediaInput, An as SmartSelect, Rf as SortableList, _s as Sparkline, si as Spinner, Fs as SplitBar, lc as StatCard, wa as Stepper, _a as SummaryItem, wo as SyncIcon, ji as TabMenuOption, Rr as TableColumnSettings, vr as TableFiltersPanel, Qi as TablePageLayout, yr as TableSortingPanel, ta as Tabs, If as TagsInput, Gf as TemporalScrub, Ft as TextArea, zn as TimeRangeInput, Rp as Timeline, vi as ToastProvider, nn as Toggle, rn as ToggleCard, Xr as ToolbarButton, Hi as Tooltip, sc as TramoCard, Zt as Transfer, Yt as TreeSelect, uo as UnitSelector, ua as Visibility, da as Visivility, dc as WEEKDAY_LABELS, So as WeekdayToggleStrip, on as YesNoSelect, Va as badgeClassName, Ha as badgeDotClassName, Hr as buildActiveFilterChips, ps as buildDefaultFormatter, mc as buildMonthGrid, qf as buildOrgTreeRows, Xt as buttonClassName, Ln as calcTimeDuration, ff as clampNumber, Ro as codeEditorClassName, _r as columnFilterFn, cp as countNetworkStatus, Yf as countOrgTreeNodes, Jm as createFormSchema, er as createLocalStorageAsyncStateStore, Zl as createPhotoItem, tu as cropImageToSquare, am as defaultOnSortFunc, Pl as detailHasRows, Gl as emptyDateRange, gf as emptyKeyValuePairs, vf as emptyNumberRange, pu as emptyPhotoItems, mf as emptyTags, Kl as emptyTimeRange, gm as exportTableCsv, kl as exportTableXlsx, Q as fieldClassName, Vr as formatColumnFilterValue, Go as formatMapGeocoderLabel, pf as formatSliderLabel, Pn as fromUtcDateIso, gr as inferInitialFilterValue, jt as inputFocusTransition, Wr as isBlankRow, hr as isColumnFilterValue, Mn as isValidDateString, Yl as isValidFileType, dp as networkEdgeLines, lp as networkMapBounds, up as networkNodePositions, Jl as nextPhotoId, Fn as normalizeDateRange, bf as normalizeHexColor, _f as normalizeKeyValuePairs, sp as normalizeNetworkEdges, op as normalizeNetworkNodes, yf as normalizeNumberRange, eu as normalizePhotoItems, hf as normalizeTags, In as normalizeTimeRange, Pm as nullableBoolean, Um as nullableCelular, Em as nullableEmail, Lm as nullableNumber, Om as nullableOrMatchString, Vm as nullablePositiveInteger, Bm as nullablePositiveNumber, wm as nullableString, Km as nullableStringArray, Mm as nullableStringNumbersOnly, Xf as orgTreeRootNodes, pc as parseYMD, xf as progressPercent, hs as rawValueKey, lm as readQueryValue, dm as removeQueryValue, Nm as requiredBoolean, Wm as requiredCelular, Tm as requiredEmail, Dm as requiredMatchString, Im as requiredNumber, zm as requiredPositiveInteger, Rm as requiredPositiveNumber, Cm as requiredString, Gm as requiredStringArray, jm as requiredStringNumbersOnly, Jf as resolveOrgTreeTheme, cs as resolveSeriesColor, Ql as revokePhotoPreview, $l as revokePhotoPreviews, ln as sanitizeDigits, Wo as searchMapAddresses, wd as sfClampLatitude, Td as sfClampLongitude, Sd as sfFormatCoordinate, Dd as sfLatLngToString, kd as sfMarkerFromLatLng, Od as sfNormalizeLatLng, Ed as sfParseCoordinate, Xl as showFilePicker, Mt as textareaClassName, mo as toIsoDate, jn as toLocalDateYMD, fc as toLocalYMD, gs as toStacked100Data, Jt as toStringArray, Nn as toUtcDateIso, Sm as transformNullIfEmpty, um as updateQueryValue, Bd as useAddressSearch, om as useArrayPaginator, Cn as useAsyncOptions, Mi as useClickAway, la as useContainerHeight, Ri as useContextMenu, mm as useCustomForm, jr as useCustomTableController, Al as useDetailPanel, Di as useDropdownClose, rm as useFilterData, Ea as useFormWizard, Lo as useIsClient, Xp as useMaestroFilter, Vd as useMapEngine, Hd as useMapsConfig, Si as useModal, fm as useQueryStringState, Ud as useReverseGeocode, Rd as useSf, zd as useSfMaps, ia as useSidePanelContainer, na as useSidePanelHandle, cm as useStoredState, Ir as useTableColumnSettings, yi as useToast, dn as validateDni, un as validateRuc, qm as validators };
16641
+ export { ui as AccessDenied, ha as Accordion, ei as ActionButton, zr as ActiveFiltersBar, qd as AddressSearchInput, ni as Alert, Jc as AlertLane, Gc as AlertRowList, Xc as AlertSummaryList, Wf as AllocationBar, Oo as AppBarContainer, Do as AppShell, Co as AppsGridIcon, sf as AreaInput, En as AsyncCardSelect, Ar as AsyncCustomTable, wn as AsyncSearchSelect, kn as AsyncSearchTableSelect, bp as AuditTimeline, za as Avatar, Ba as AvatarGroup, Ua as Badge, an as BooleanCheckbox, pa as Breadcrumb, $ as Button, Yr as ButtonGroup, ss as CHART_SERIES_COLORS, cn as COUNTRY_DIAL_CODES, sn as CURRENCY_SYMBOLS, _c as Calendar, hl as CardNote, Bf as CardRadioGroup, Tn as CardSelect, Bp as Carousel, Kp as Chart, qp as ChartLegend, $t as Checkbox, en as CheckboxGroup, Vo as CodeEditor, If as ColorInput, Ji as CommandPalette, $c as ComparisonTable, Ci as ConfirmDialog, Ii as ContextMenuProvider, $d as CoordinatesInput, _n as CurrencyInput, kr as CustomTable, lr as DEFAULT_PAGE_SIZE_OPTIONS, vl as DashboardBoard, al as DashboardCard, yl as DashboardCardRow, ll as DashboardGrid, pl as DashboardLayout, Cl as DashboardPageFrame, El as DashboardPlaceholder, ul as DashboardSection, fl as DashboardStatBar, Lt as DateInput, Ht as DatePicker, Wl as DateRangeFields, Rn as DateRangeInput, Gl as DateRangeUtcInput, yo as DateWeekStrip, Pl as DetailPanel, Rl as DetailPreviewList, zl as DetailSection, ml as DetailSidePanel, Zp as DeviationBand, Yp as DiagnosticRadar, Gn as DisplayField, fn as DniInput, Fc as DonutBreakdown, Dc as DonutGauge, Oc as DonutGaugeRow, Wi as Drawer, Ll as DrilldownAlertList, Il as DrilldownKPICard, Oi as DropdownMenu, ki as DropdownMenuItem, Gr as EditableDataGrid, ri as EmptyState, Zs as EntityCard, $s as EntityCardGrid, ai as ErrorView, Bc as EventLog, Zc as EvidenceFootnote, Jr as ExpandableTableSection, Z as FieldLayout, au as FileDropInput, Un as FileInput, Aa as FilterBar, Ma as FilterBarDate, ja as FilterBarField, Na as FilterBarSelect, Pa as FilterBarText, Qr as FormActions, Da as FormWizard, ca as HeightProvider, Pt as Input, La as ItineraryEditor, As as KPICard, Ms as KPIGrid, Rf as KeyValueInput, wp as LiveChip, lo as LiveRouteBoard, Ip as LiveStatusBar, ci as LoadingView, Qd as LocationPicker, Uo as MIN_MAP_GEOCODER_QUERY_LENGTH, uc as MONTH_NAMES, Fa as MaestroLayout, hu as MapFrame, _u as MapLegend, os as MapPicker, bu as MapPointCard, gu as MapStatus, vu as MapToolbar, yu as MapVehiclePopup, Zd as MapView, ka as MasterDetailLayout, Oa as MasterDetailListItem, Vp as MediaPanel, Ti as MessageDialog, Vs as MetricBarList, Bs as MetricBarRow, xi as Modal, ac as ModuleCard, oc as ModuleCardGrid, cu as MultiPhotoInput, ep as NETWORK_BASEMAPS, ap as NETWORK_EDGE_STYLES, np as NETWORK_KIND_COLORS, tp as NETWORK_KIND_LABELS, rp as NETWORK_STATUS_COLORS, ip as NETWORK_STATUS_LABELS, mr as NUMBER_FILTER_OPS, pp as NetworkLegend, vp as NetworkMap, Vi as NotificationBell, It as NumberInput, Of as NumberStepper, qf as ORG_TREE_DEFAULT_THEMES, Ai as OptionItem, $f as OrgTree, Hl as OtpInput, Zi as PageContainer, $i as PageHeader, fr as Pagination, ar as PaginationRangeInput, Za as PassengerBoardCard, Wt as PasswordInput, hn as PhoneInput, pu as PhotoCropInput, ou as PhotoInput, Rt as Popover, Xi as ProductTour, jf as ProgressBar, Nf as ProgressBarReadonly, zi as QRView, Ls as QuickActionGrid, Is as QuickActionTile, tn as RadioGroup, Af as RangeSliderInput, Pf as RatingInput, nc as RecommendationCard, Cp as RecordList, Sp as RecordListItem, li as RetryBlock, Fo as RichTextEditor, cf as RouteInput, Zr as RowActions, pn as RucInput, Su as SF_DEFAULT_MAP_CENTER, Cu as SF_DEFAULT_MAP_ZOOM, ku as SF_GOOGLE_ENGINE_CAPABILITIES, Ou as SF_LEAFLET_ENGINE_CAPABILITIES, xu as SF_MAPS_CONFIG_ERROR, Tu as SF_OSM_ATTRIBUTION, wu as SF_OSM_TILE_URL, Du as SF_SATELLITE_ATTRIBUTION, Eu as SF_SATELLITE_TILE_URL, pr as STRING_FILTER_OPS, ga as ScrollArea, Sn as SearchSelect, On as SearchTableSelect, Qt as Select, Vf as SemanticSlider, fa as Separator, Rd as SfProvider, Gi as Sheet, ea as SidePanel, oa as SidePanelContainer, su as SignaturePad, fi as Skeleton, wf as SliderInput, Bn as SmartDateInput, vn as SmartInput, lf as SmartMapInput, lu as SmartMediaInput, An as SmartSelect, zf as SortableList, _s as Sparkline, si as Spinner, Fs as SplitBar, lc as StatCard, wa as Stepper, _a as SummaryItem, wo as SyncIcon, ji as TabMenuOption, Rr as TableColumnSettings, vr as TableFiltersPanel, Qi as TablePageLayout, yr as TableSortingPanel, ta as Tabs, Lf as TagsInput, Kf as TemporalScrub, Ft as TextArea, zn as TimeRangeInput, zp as Timeline, vi as ToastProvider, nn as Toggle, rn as ToggleCard, Xr as ToolbarButton, Hi as Tooltip, sc as TramoCard, Zt as Transfer, Yt as TreeSelect, uo as UnitSelector, ua as Visibility, da as Visivility, dc as WEEKDAY_LABELS, So as WeekdayToggleStrip, on as YesNoSelect, Va as badgeClassName, Ha as badgeDotClassName, Hr as buildActiveFilterChips, ps as buildDefaultFormatter, mc as buildMonthGrid, Jf as buildOrgTreeRows, Xt as buttonClassName, Ln as calcTimeDuration, pf as clampNumber, Ro as codeEditorClassName, _r as columnFilterFn, lp as countNetworkStatus, Xf as countOrgTreeNodes, Xm as createFormSchema, er as createLocalStorageAsyncStateStore, Ql as createPhotoItem, nu as cropImageToSquare, sm as defaultOnSortFunc, Fl as detailHasRows, Kl as emptyDateRange, _f as emptyKeyValuePairs, yf as emptyNumberRange, mu as emptyPhotoItems, hf as emptyTags, ql as emptyTimeRange, vm as exportTableCsv, Al as exportTableXlsx, Q as fieldClassName, Vr as formatColumnFilterValue, Go as formatMapGeocoderLabel, mf as formatSliderLabel, Pn as fromUtcDateIso, gr as inferInitialFilterValue, jt as inputFocusTransition, Wr as isBlankRow, hr as isColumnFilterValue, Mn as isValidDateString, Xl as isValidFileType, fp as networkEdgeLines, up as networkMapBounds, dp as networkNodePositions, Yl as nextPhotoId, Fn as normalizeDateRange, xf as normalizeHexColor, vf as normalizeKeyValuePairs, cp as normalizeNetworkEdges, sp as normalizeNetworkNodes, bf as normalizeNumberRange, tu as normalizePhotoItems, gf as normalizeTags, In as normalizeTimeRange, Im as nullableBoolean, Gm as nullableCelular, Om as nullableEmail, zm as nullableNumber, Am as nullableOrMatchString, Um as nullablePositiveInteger, Hm as nullablePositiveNumber, Em as nullableString, Jm as nullableStringArray, Pm as nullableStringNumbersOnly, Zf as orgTreeRootNodes, pc as parseYMD, Sf as progressPercent, hs as rawValueKey, dm as readQueryValue, pm as removeQueryValue, Fm as requiredBoolean, Km as requiredCelular, Dm as requiredEmail, km as requiredMatchString, Rm as requiredNumber, Vm as requiredPositiveInteger, Bm as requiredPositiveNumber, Tm as requiredString, qm as requiredStringArray, Nm as requiredStringNumbersOnly, Yf as resolveOrgTreeTheme, cs as resolveSeriesColor, $l as revokePhotoPreview, eu as revokePhotoPreviews, ln as sanitizeDigits, Wo as searchMapAddresses, Td as sfClampLatitude, Ed as sfClampLongitude, Cd as sfFormatCoordinate, Od as sfLatLngToString, Ad as sfMarkerFromLatLng, kd as sfNormalizeLatLng, Dd as sfParseCoordinate, Zl as showFilePicker, Mt as textareaClassName, mo as toIsoDate, jn as toLocalDateYMD, fc as toLocalYMD, gs as toStacked100Data, Jt as toStringArray, Nn as toUtcDateIso, wm as transformNullIfEmpty, fm as updateQueryValue, Vd as useAddressSearch, cm as useArrayPaginator, Cn as useAsyncOptions, Mi as useClickAway, la as useContainerHeight, Ri as useContextMenu, gm as useCustomForm, jr as useCustomTableController, jl as useDetailPanel, Di as useDropdownClose, am as useFilterData, Ea as useFormWizard, Lo as useIsClient, Qp as useMaestroFilter, Hd as useMapEngine, Ud as useMapsConfig, Si as useModal, mm as useQueryStringState, Wd as useReverseGeocode, zd as useSf, Bd as useSfMaps, ia as useSidePanelContainer, na as useSidePanelHandle, um as useStoredState, Ir as useTableColumnSettings, yi as useToast, dn as validateDni, un as validateRuc, Ym as validators };
16586
16642
 
16587
16643
  //# sourceMappingURL=sf-ui.js.map