@starasia/date 5.2.4 → 5.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/date.es.js CHANGED
@@ -1,4 +1,4 @@
1
- import { jsxs as Y, jsx as e, Fragment as en } from "react/jsx-runtime";
1
+ import { jsxs as $, jsx as a, Fragment as en } from "react/jsx-runtime";
2
2
  import { useState as A, useRef as J, useEffect as B, forwardRef as K } from "react";
3
3
  const R = `@import url("https://fonts.googleapis.com/css2?family=Poppins:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;0,900;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800;1,900&display=swap");
4
4
 
@@ -348,6 +348,12 @@ const R = `@import url("https://fonts.googleapis.com/css2?family=Poppins:ital,wg
348
348
  border-style: solid;
349
349
  }
350
350
 
351
+ .sa-calendar-input-container.xs {
352
+ height: var(--sa-h-7, 28px);
353
+ border-radius: var(--sa-radii-sm, 6px);
354
+ font-size: var(--sa-font-size-sm, 12px);
355
+ padding-inline: var(--sa-spacing-2, 8px);
356
+ }
351
357
  .sa-calendar-input-container.sm {
352
358
  height: var(--sa-h-8, 32px);
353
359
  border-radius: var(--sa-radii-sm, 6px);
@@ -501,6 +507,37 @@ const R = `@import url("https://fonts.googleapis.com/css2?family=Poppins:ital,wg
501
507
  height: 38px;
502
508
  }
503
509
 
510
+ /* xs trigger → reuse the compact (sm) calendar panel */
511
+ .sa-calendar.sa-calendar-size-xs {
512
+ padding: 16px 12px;
513
+ gap: 8px;
514
+ }
515
+ .sa-calendar.sa-calendar-size-xs.sa-calendar-no-padding {
516
+ padding: 0;
517
+ }
518
+ .sa-calendar.sa-calendar-size-xs .sa-calendar-days-name-preivew,
519
+ .sa-calendar.sa-calendar-size-xs .sa-calendar-days-number-preivew {
520
+ gap: 4px;
521
+ }
522
+ .sa-calendar.sa-calendar-size-xs .sa-calendar-days-name-preivew p,
523
+ .sa-calendar.sa-calendar-size-xs .sa-calendar-days-number-preivew p {
524
+ font-size: var(--sa-font-size-sm, 12px);
525
+ }
526
+ .sa-calendar.sa-calendar-size-xs .sa-calendar-days-number-preivew p {
527
+ width: 28px;
528
+ height: 26px;
529
+ }
530
+ .sa-calendar.sa-calendar-size-xs .sa-calendar-days-today::before {
531
+ width: 22px;
532
+ height: 22px;
533
+ }
534
+ .sa-calendar.sa-calendar-size-xs .sa-calendar-months-preview p,
535
+ .sa-calendar.sa-calendar-size-xs .sa-calendar-years-preview p {
536
+ font-size: var(--sa-font-size-sm, 12px);
537
+ width: 76px;
538
+ height: 38px;
539
+ }
540
+
504
541
  .sa-calendar.sa-calendar-size-lg {
505
542
  padding: 28px 20px;
506
543
  gap: 16px;
@@ -571,48 +608,50 @@ const R = `@import url("https://fonts.googleapis.com/css2?family=Poppins:ital,wg
571
608
  "Nov",
572
609
  "Dec"
573
610
  ];
574
- function rn(a) {
575
- const [n, t] = A(a), o = J(null), l = (u) => {
611
+ function rn(e) {
612
+ const [n, t] = A(e), o = J(null), l = (u) => {
576
613
  o.current && !o.current.contains(u.target) && t(!1);
577
614
  };
578
615
  return B(() => (document.addEventListener("click", l, !0), () => {
579
616
  document.removeEventListener("click", l, !0);
580
617
  }), []), { ref: o, isComponentVisible: n, setIsComponentVisible: t };
581
618
  }
582
- const Q = "sa-calendar-input-styles", dn = (a) => {
619
+ const Q = "sa-calendar-input-styles", dn = (e) => {
583
620
  if (!document.getElementById(Q)) {
584
621
  const n = document.createElement("style");
585
- n.id = Q, n.textContent = a, document.head.appendChild(n);
622
+ n.id = Q, n.textContent = e, document.head.appendChild(n);
586
623
  }
587
624
  };
588
625
  dn(R);
589
- const O = (a) => {
590
- if (a === "sm")
626
+ const O = (e) => {
627
+ if (e === "xs")
628
+ return 14;
629
+ if (e === "sm")
591
630
  return 16;
592
- if (a === "md")
631
+ if (e === "md")
593
632
  return 16;
594
- if (a === "lg")
633
+ if (e === "lg")
595
634
  return 20;
596
- }, cn = (a) => {
635
+ }, cn = (e) => {
597
636
  const {
598
- size: n = "md",
637
+ size: n = "sm",
599
638
  status: t = "default",
600
639
  variant: o = "outline",
601
640
  clearable: l,
602
641
  onClear: u,
603
642
  ...i
604
- } = a, h = J(null), g = () => {
605
- h.current && i.onClick && (h.current.focus(), i.onClick(""));
606
- }, r = t === "disable" || i.disabled, d = !!i.value, y = l && d && !r, M = (k) => {
643
+ } = e, g = J(null), f = () => {
644
+ g.current && i.onClick && (g.current.focus(), i.onClick(""));
645
+ }, r = t === "disable" || i.disabled, d = !!i.value, w = l && d && !r, M = (k) => {
607
646
  k.stopPropagation(), u == null || u();
608
647
  };
609
- return /* @__PURE__ */ Y(
648
+ return /* @__PURE__ */ $(
610
649
  "div",
611
650
  {
612
651
  className: `sa-calendar-input-container sa-calendar-input-${o} sa-calendar-input-container-${t} ${n} `,
613
- onClick: g,
652
+ onClick: f,
614
653
  children: [
615
- /* @__PURE__ */ e("div", { className: "sa-calendar-input-container-icon-left", children: /* @__PURE__ */ e(
654
+ /* @__PURE__ */ a("div", { className: "sa-calendar-input-container-icon-left", children: /* @__PURE__ */ a(
616
655
  "svg",
617
656
  {
618
657
  xmlns: "http://www.w3.org/2000/svg",
@@ -620,7 +659,7 @@ const O = (a) => {
620
659
  height: O(n),
621
660
  viewBox: "0 0 20 20",
622
661
  fill: "none",
623
- children: /* @__PURE__ */ e(
662
+ children: /* @__PURE__ */ a(
624
663
  "path",
625
664
  {
626
665
  d: "M12.5 2.08301V5.41634M7.50002 2.08301V5.41634M17.0688 9.58301H2.93113M17.0688 9.58301C16.8953 4.82698 15.1284 3.33301 10 3.33301C4.87165 3.33301 3.10469 4.82698 2.93113 9.58301M17.0688 9.58301C17.0786 9.85037 17.0834 10.128 17.0834 10.4163C17.0834 15.833 15.4167 17.4997 10 17.4997C4.58335 17.4997 2.91669 15.833 2.91669 10.4163C2.91669 10.128 2.92138 9.85037 2.93113 9.58301",
@@ -632,24 +671,24 @@ const O = (a) => {
632
671
  )
633
672
  }
634
673
  ) }),
635
- /* @__PURE__ */ e("div", { className: "sa-calendar-input-preview-container", children: /* @__PURE__ */ e(
674
+ /* @__PURE__ */ a("div", { className: "sa-calendar-input-preview-container", children: /* @__PURE__ */ a(
636
675
  "input",
637
676
  {
638
677
  className: "sa-calendar-input",
639
678
  ...i,
640
679
  disabled: r,
641
680
  value: i.value,
642
- ref: h
681
+ ref: g
643
682
  }
644
683
  ) }),
645
- y ? /* @__PURE__ */ e(
684
+ w ? /* @__PURE__ */ a(
646
685
  "button",
647
686
  {
648
687
  type: "button",
649
688
  "aria-label": "Clear date",
650
689
  className: "sa-calendar-input-clear",
651
690
  onClick: M,
652
- children: /* @__PURE__ */ e(
691
+ children: /* @__PURE__ */ a(
653
692
  "svg",
654
693
  {
655
694
  xmlns: "http://www.w3.org/2000/svg",
@@ -657,7 +696,7 @@ const O = (a) => {
657
696
  height: O(n),
658
697
  viewBox: "0 0 20 20",
659
698
  fill: "none",
660
- children: /* @__PURE__ */ e(
699
+ children: /* @__PURE__ */ a(
661
700
  "path",
662
701
  {
663
702
  d: "M5 5L15 15M15 5L5 15",
@@ -670,7 +709,7 @@ const O = (a) => {
670
709
  }
671
710
  )
672
711
  }
673
- ) : /* @__PURE__ */ e("div", { className: "sa-calendar-input-container-icon-right", children: /* @__PURE__ */ e(
712
+ ) : /* @__PURE__ */ a("div", { className: "sa-calendar-input-container-icon-right", children: /* @__PURE__ */ a(
674
713
  "svg",
675
714
  {
676
715
  xmlns: "http://www.w3.org/2000/svg",
@@ -678,7 +717,7 @@ const O = (a) => {
678
717
  height: O(n),
679
718
  viewBox: "0 0 20 20",
680
719
  fill: "none",
681
- children: /* @__PURE__ */ e(
720
+ children: /* @__PURE__ */ a(
682
721
  "path",
683
722
  {
684
723
  d: "M3.33331 7.5L9.99998 14.1667L16.6666 7.5",
@@ -693,122 +732,124 @@ const O = (a) => {
693
732
  ]
694
733
  }
695
734
  );
696
- }, un = ({
697
- date: a,
735
+ }, pn = ({
736
+ date: e,
698
737
  setDate: n,
699
738
  dateRange: t,
700
739
  setDateRange: o,
701
740
  onChange: l,
702
741
  minDate: u,
703
742
  maxDate: i,
704
- input: h
743
+ input: g
705
744
  }) => {
706
- var N, p, w;
707
- const [g, r] = A(null);
708
- let d = new Date(a.getFullYear(), a.getMonth(), 1), y = d.getDay(), M = [];
709
- const k = a.getMonth(), $ = (/* @__PURE__ */ new Date()).toDateString(), m = !!(t.from && !t.to), f = m && g ? g : null;
710
- for (let c = 0; c < 42; c++) {
711
- c === 0 && y === 0 ? d.setDate(d.getDate() - 7) : c === 0 ? d.setDate(
712
- d.getDate() + (c - y)
745
+ var z, c, y;
746
+ const [f, r] = A(null);
747
+ let d = new Date(e.getFullYear(), e.getMonth(), 1), w = d.getDay(), M = [];
748
+ const k = e.getMonth(), N = (/* @__PURE__ */ new Date()).toDateString(), m = !!(t.from && !t.to), h = m && f ? f : null;
749
+ for (let p = 0; p < 42; p++) {
750
+ p === 0 && w === 0 ? d.setDate(d.getDate() - 7) : p === 0 ? d.setDate(
751
+ d.getDate() + (p - w)
713
752
  ) : d.setDate(d.getDate() + 1);
714
- let v = {
753
+ let b = {
715
754
  currentMonth: d.getMonth() === k,
716
755
  date: new Date(d),
717
756
  month: d.getMonth(),
718
757
  number: d.getDate(),
719
- selected: d.toDateString() === ((N = t.from) == null ? void 0 : N.toDateString()) || d.toDateString() === (((p = t.to) == null ? void 0 : p.toDateString()) || ((w = t.from) == null ? void 0 : w.toDateString())),
720
- isToday: d.toDateString() === $,
758
+ selected: d.toDateString() === ((z = t.from) == null ? void 0 : z.toDateString()) || d.toDateString() === (((c = t.to) == null ? void 0 : c.toDateString()) || ((y = t.from) == null ? void 0 : y.toDateString())),
759
+ isToday: d.toDateString() === N,
721
760
  year: d.getFullYear(),
722
761
  isDisabled: u && d < u || i && d > i
723
762
  };
724
- M.push(v);
763
+ M.push(b);
725
764
  }
726
- const s = (c) => {
727
- n(c);
728
- }, x = (c) => {
729
- var z;
730
- let v = { ...t };
731
- if (v.from && v.to)
732
- v = { from: c, to: null };
765
+ const s = (p) => {
766
+ n(p);
767
+ }, x = (p) => {
768
+ let b = { ...t };
769
+ if (b.from && b.to)
770
+ b = { from: p, to: null };
771
+ else if (!b.from)
772
+ b = { from: p, to: null };
733
773
  else {
734
- const S = ((z = v.from) == null ? void 0 : z.getTime()) || 0;
735
- c.getTime() > S ? v = { from: v.from, to: c } : v = { from: c, to: v.from };
774
+ const E = b.from.getTime();
775
+ p.getTime() > E ? b = { from: b.from, to: p } : b = { from: p, to: b.from };
736
776
  }
737
- o(v), l(v);
777
+ o(b), l(b);
738
778
  };
739
- return /* @__PURE__ */ Y(
779
+ return /* @__PURE__ */ $(
740
780
  "div",
741
781
  {
742
782
  className: "sa-calendar-days-preivew",
743
783
  onMouseLeave: () => r(null),
744
784
  children: [
745
- /* @__PURE__ */ e("div", { className: "sa-calendar-days-name-preivew", children: an.map((c, v) => /* @__PURE__ */ e("p", { children: c }, v)) }),
746
- /* @__PURE__ */ e("div", { className: "sa-calendar-days-number-preivew", children: M.map((c, v) => {
747
- const z = t.from && t.to && c.date.getTime() > t.from.getTime() && c.date.getTime() < t.to.getTime(), S = (() => {
748
- if (!f || !t.from)
785
+ /* @__PURE__ */ a("div", { className: "sa-calendar-days-name-preivew", children: an.map((p, b) => /* @__PURE__ */ a("p", { children: p }, b)) }),
786
+ /* @__PURE__ */ a("div", { className: "sa-calendar-days-number-preivew", children: M.map((p, b) => {
787
+ const E = t.from && t.to && p.date.getTime() > t.from.getTime() && p.date.getTime() < t.to.getTime(), S = (() => {
788
+ if (!h || !t.from)
749
789
  return !1;
750
- const F = c.date.getTime(), D = t.from.getTime(), E = f.getTime();
751
- return E > D ? F > D && F < E : F < D && F > E;
752
- })(), C = m && g && c.date.toDateString() === g.toDateString(), L = c.isDisabled, I = () => z || S ? "var(--sa-color-info-alpha-a10, #64b5f61a)" : "", T = () => L ? "var(--sa-color-gray-400, #b7b9be)" : z || S ? "var(--sa-color-gray-500, #8c8f97)" : "";
753
- return /* @__PURE__ */ e(
790
+ const Y = p.date.getTime(), C = t.from.getTime(), L = h.getTime();
791
+ return L > C ? Y > C && Y < L : Y < C && Y > L;
792
+ })(), D = m && f && p.date.toDateString() === f.toDateString(), F = p.isDisabled, I = () => E || S ? "var(--sa-color-info-alpha-a10, #64b5f61a)" : "", T = () => F ? "var(--sa-color-gray-400, #b7b9be)" : E || S ? "var(--sa-color-gray-500, #8c8f97)" : "";
793
+ return /* @__PURE__ */ a(
754
794
  "p",
755
795
  {
756
- className: `${c.currentMonth ? "sa-calendar-days-current" : "sa-calendar-days"} ${c.selected || C ? "sa-calendar-days-active" : ""} ${c.isToday && !c.selected ? "sa-calendar-days-today" : ""}`,
796
+ className: `${p.currentMonth ? "sa-calendar-days-current" : "sa-calendar-days"} ${p.selected || D ? "sa-calendar-days-active" : ""} ${p.isToday && !p.selected ? "sa-calendar-days-today" : ""}`,
757
797
  style: {
758
798
  backgroundColor: I(),
759
- pointerEvents: L ? "none" : void 0,
760
- cursor: L ? "not-allowed" : "pointer",
799
+ pointerEvents: F ? "none" : void 0,
800
+ cursor: F ? "not-allowed" : "pointer",
761
801
  color: T(),
762
- opacity: C && !c.selected ? 0.75 : 1,
763
- ...h ? {} : { width: "100%" }
802
+ opacity: D && !p.selected ? 0.75 : 1,
803
+ ...g ? {} : { width: "100%" }
764
804
  },
765
805
  onClick: () => {
766
- L || (s(c.date), x(c.date));
806
+ F || (s(p.date), x(p.date));
767
807
  },
768
808
  onMouseEnter: () => {
769
- L || r(c.date);
809
+ F || r(p.date);
770
810
  },
771
- children: c.number
811
+ children: p.number
772
812
  },
773
- v
813
+ b
774
814
  );
775
815
  }) })
776
816
  ]
777
817
  }
778
818
  );
779
- }, pn = ({
780
- date: a,
819
+ }, un = ({
820
+ date: e,
781
821
  setDate: n,
782
822
  filter: t,
783
823
  setViews: o,
784
824
  dateRange: l,
785
825
  setDateRange: u,
786
826
  onChange: i,
787
- minDate: h,
788
- maxDate: g,
827
+ minDate: g,
828
+ maxDate: f,
789
829
  input: r
790
830
  }) => {
791
- var $;
792
- const d = ($ = l.from) == null ? void 0 : $.getFullYear(), y = a.getFullYear(), M = (m) => {
831
+ var N;
832
+ const d = (N = l.from) == null ? void 0 : N.getFullYear(), w = e.getFullYear(), M = (m) => {
793
833
  t ? (k(m), n(m)) : (o("days"), n(m));
794
834
  }, k = (m) => {
795
- var s;
796
- let f = { ...l };
797
- if (f.from && f.to)
798
- f = { from: m, to: null };
835
+ let h = { ...l };
836
+ if (h.from && h.to)
837
+ h = { from: m, to: null };
838
+ else if (!h.from)
839
+ h = { from: m, to: null };
799
840
  else {
800
- const x = ((s = f.from) == null ? void 0 : s.getTime()) || 0;
801
- m.getTime() > x ? f = { from: f.from, to: m } : f = { from: m, to: f.from };
841
+ const s = h.from.getTime();
842
+ m.getTime() > s ? h = { from: h.from, to: m } : h = { from: m, to: h.from };
802
843
  }
803
- u(f), i(f);
844
+ u(h), i(h);
804
845
  };
805
- return /* @__PURE__ */ e("div", { className: "sa-calendar-months-preview", children: W.map((m, f) => {
806
- var N, p, w;
807
- const s = l.from != null && new Date(y, f).getTime() > l.from.getTime() && new Date(y, f).getTime() < (((N = l.to) == null ? void 0 : N.getTime()) || l.from.getTime()), x = h && new Date(y, f) < h || g && new Date(y, f) > g;
808
- return /* @__PURE__ */ e(
846
+ return /* @__PURE__ */ a("div", { className: "sa-calendar-months-preview", children: W.map((m, h) => {
847
+ var z, c, y;
848
+ const s = l.from != null && new Date(w, h).getTime() > l.from.getTime() && new Date(w, h).getTime() < (((z = l.to) == null ? void 0 : z.getTime()) || l.from.getTime()), x = g && new Date(w, h) < g || f && new Date(w, h) > f;
849
+ return /* @__PURE__ */ a(
809
850
  "p",
810
851
  {
811
- className: d === y && (f === ((p = l.from) == null ? void 0 : p.getMonth()) || f === ((w = l.to) == null ? void 0 : w.getMonth())) ? "sa-calendar-months-active" : "",
852
+ className: d === w && (h === ((c = l.from) == null ? void 0 : c.getMonth()) || h === ((y = l.to) == null ? void 0 : y.getMonth())) ? "sa-calendar-months-active" : "",
812
853
  style: {
813
854
  backgroundColor: s ? "var(--sa-color-info-alpha-a10, #64b5f61a)" : "",
814
855
  pointerEvents: x ? "none" : void 0,
@@ -817,72 +858,73 @@ const O = (a) => {
817
858
  ...r ? {} : { width: "100%" }
818
859
  },
819
860
  onClick: () => {
820
- x || M(new Date(y, f));
861
+ x || M(new Date(w, h));
821
862
  },
822
863
  children: m.slice(0, 3)
823
864
  },
824
- f
865
+ h
825
866
  );
826
867
  }) });
827
- }, q = (a) => {
828
- const n = Math.floor(a / 10) * 10, t = n + 10;
868
+ }, q = (e) => {
869
+ const n = Math.floor(e / 10) * 10, t = n + 10;
829
870
  return { start: n, end: t };
830
871
  }, hn = ({
831
- date: a,
872
+ date: e,
832
873
  filter: n,
833
874
  setViews: t,
834
875
  setDate: o,
835
876
  dateRange: l,
836
877
  setDateRange: u,
837
878
  onChange: i,
838
- minDate: h,
839
- maxDate: g,
879
+ minDate: g,
880
+ maxDate: f,
840
881
  input: r
841
882
  }) => {
842
- var x, N;
883
+ var x, z;
843
884
  let d = [];
844
- const y = a.getFullYear(), { start: M, end: k } = q(y), $ = (x = l.from) == null ? void 0 : x.getFullYear(), m = (N = l.to) == null ? void 0 : N.getFullYear();
845
- for (let p = M; p < k; p++) {
846
- const w = new Date(p, 0), c = (!h || w >= h) && (!g || w <= g), v = $ != null && p === $ || m != null && p === m, z = l.from != null && l.to != null && w > l.from && w < l.to;
885
+ const w = e.getFullYear(), { start: M, end: k } = q(w), N = (x = l.from) == null ? void 0 : x.getFullYear(), m = (z = l.to) == null ? void 0 : z.getFullYear();
886
+ for (let c = M; c < k; c++) {
887
+ const y = new Date(c, 0), p = (!g || y >= g) && (!f || y <= f), b = N != null && c === N || m != null && c === m, E = l.from != null && l.to != null && y > l.from && y < l.to;
847
888
  d.push({
848
- year: p,
849
- active: v && c,
850
- highlight: z && c,
851
- disabled: !c
889
+ year: c,
890
+ active: b && p,
891
+ highlight: E && p,
892
+ disabled: !p
852
893
  });
853
894
  }
854
- const f = (p) => {
855
- n ? (s(p), o(p)) : (o(p), t("months"));
856
- }, s = (p) => {
857
- var c;
858
- let w = { ...l };
859
- if (w.from && w.to)
860
- w = { from: p, to: null };
895
+ const h = (c) => {
896
+ n ? (s(c), o(c)) : (o(c), t("months"));
897
+ }, s = (c) => {
898
+ let y = { ...l };
899
+ if (y.from && y.to)
900
+ y = { from: c, to: null };
901
+ else if (!y.from)
902
+ y = { from: c, to: null };
861
903
  else {
862
- const v = ((c = w.from) == null ? void 0 : c.getTime()) || 0;
863
- p.getTime() > v ? w = { from: w.from, to: p } : w = { from: p, to: w.from };
904
+ const p = y.from.getTime();
905
+ c.getTime() > p ? y = { from: y.from, to: c } : y = { from: c, to: y.from };
864
906
  }
865
- u(w), i(w);
907
+ u(y), i(y);
866
908
  };
867
- return /* @__PURE__ */ e("div", { className: "sa-calendar-years-preview", children: d.map((p, w) => /* @__PURE__ */ e(
909
+ return /* @__PURE__ */ a("div", { className: "sa-calendar-years-preview", children: d.map((c, y) => /* @__PURE__ */ a(
868
910
  "p",
869
911
  {
870
- className: `${p.active ? "sa-calendar-months-active" : ""} ${p.highlight ? "sa-calendar-months-highlight" : ""} ${p.disabled ? "sa-calendar-disabled" : ""}`,
912
+ className: `${c.active ? "sa-calendar-months-active" : ""} ${c.highlight ? "sa-calendar-months-highlight" : ""} ${c.disabled ? "sa-calendar-disabled" : ""}`,
871
913
  onClick: () => {
872
- p.disabled || f(new Date(p.year, 0));
914
+ c.disabled || h(new Date(c.year, 0));
873
915
  },
874
916
  style: {
875
- backgroundColor: p.highlight ? "var(--sa-color-info-alpha-a10, #64b5f61a)" : "",
876
- color: p.highlight ? "var(--sa-color-gray-500, #8c8f97)" : p.active ? "" : p.disabled ? "var(--sa-color-gray-400, #b7b9be)" : "",
877
- cursor: p.disabled ? "not-allowed" : "pointer",
878
- pointerEvents: p.disbled ? "none" : "all",
917
+ backgroundColor: c.highlight ? "var(--sa-color-info-alpha-a10, #64b5f61a)" : "",
918
+ color: c.highlight ? "var(--sa-color-gray-500, #8c8f97)" : c.active ? "" : c.disabled ? "var(--sa-color-gray-400, #b7b9be)" : "",
919
+ cursor: c.disabled ? "not-allowed" : "pointer",
920
+ pointerEvents: c.disbled ? "none" : "all",
879
921
  ...r ? {} : { width: "100%" }
880
922
  },
881
- children: p.year
923
+ children: c.year
882
924
  },
883
- w
925
+ y
884
926
  )) });
885
- }, tn = ({ ...a }) => /* @__PURE__ */ e(
927
+ }, tn = ({ ...e }) => /* @__PURE__ */ a(
886
928
  "svg",
887
929
  {
888
930
  xmlns: "http://www.w3.org/2000/svg",
@@ -890,8 +932,8 @@ const O = (a) => {
890
932
  height: "20",
891
933
  viewBox: "0 0 20 20",
892
934
  fill: "none",
893
- ...a,
894
- children: /* @__PURE__ */ e(
935
+ ...e,
936
+ children: /* @__PURE__ */ a(
895
937
  "path",
896
938
  {
897
939
  d: "M12.5 3.33334L5.83337 10L12.5 16.6667",
@@ -902,7 +944,7 @@ const O = (a) => {
902
944
  }
903
945
  )
904
946
  }
905
- ), sn = ({ ...a }) => /* @__PURE__ */ e(
947
+ ), sn = ({ ...e }) => /* @__PURE__ */ a(
906
948
  "svg",
907
949
  {
908
950
  xmlns: "http://www.w3.org/2000/svg",
@@ -910,8 +952,8 @@ const O = (a) => {
910
952
  height: "20",
911
953
  viewBox: "0 0 20 20",
912
954
  fill: "none",
913
- ...a,
914
- children: /* @__PURE__ */ e(
955
+ ...e,
956
+ children: /* @__PURE__ */ a(
915
957
  "path",
916
958
  {
917
959
  d: "M7.5 16.6667L14.1667 10L7.5 3.33334",
@@ -923,14 +965,14 @@ const O = (a) => {
923
965
  )
924
966
  }
925
967
  ), gn = ({
926
- setViews: a,
968
+ setViews: e,
927
969
  views: n,
928
970
  filter: t,
929
971
  date: o,
930
972
  setDate: l
931
973
  }) => {
932
974
  const u = () => {
933
- t || a((r) => r === "days" ? "months" : r === "months" ? "years" : "days");
975
+ t || e((r) => r === "days" ? "months" : r === "months" ? "years" : "days");
934
976
  }, i = () => {
935
977
  if (n === "years") {
936
978
  l((r) => new Date(r.getFullYear() + 10, 0));
@@ -941,7 +983,7 @@ const O = (a) => {
941
983
  return;
942
984
  }
943
985
  l((r) => new Date(r.getFullYear(), r.getMonth() + 1));
944
- }, h = () => {
986
+ }, g = () => {
945
987
  if (n === "years") {
946
988
  l((r) => new Date(r.getFullYear() - 10, 0));
947
989
  return;
@@ -957,8 +999,8 @@ const O = (a) => {
957
999
  )
958
1000
  );
959
1001
  };
960
- return /* @__PURE__ */ Y("div", { className: "sa-calendar-header", children: [
961
- /* @__PURE__ */ e("div", { className: "sa-calendar-header-title", onClick: u, children: (() => {
1002
+ return /* @__PURE__ */ $("div", { className: "sa-calendar-header", children: [
1003
+ /* @__PURE__ */ a("div", { className: "sa-calendar-header-title", onClick: u, children: (() => {
962
1004
  if (n === "days")
963
1005
  return `${W[o.getMonth()]} ${o.getFullYear()}`;
964
1006
  if (n === "months")
@@ -966,140 +1008,140 @@ const O = (a) => {
966
1008
  if (n === "years")
967
1009
  return `${q(o.getFullYear()).start} ~ ${q(o.getFullYear()).end}`;
968
1010
  })() }),
969
- /* @__PURE__ */ Y("div", { className: "sa-calendar-header-nav", children: [
970
- /* @__PURE__ */ e("button", { className: "sa-calendar-nav-btn", onClick: h, children: /* @__PURE__ */ e(tn, {}) }),
971
- /* @__PURE__ */ e("button", { className: "sa-calendar-nav-btn", onClick: i, children: /* @__PURE__ */ e(sn, {}) })
1011
+ /* @__PURE__ */ $("div", { className: "sa-calendar-header-nav", children: [
1012
+ /* @__PURE__ */ a("button", { className: "sa-calendar-nav-btn", onClick: g, children: /* @__PURE__ */ a(tn, {}) }),
1013
+ /* @__PURE__ */ a("button", { className: "sa-calendar-nav-btn", onClick: i, children: /* @__PURE__ */ a(sn, {}) })
972
1014
  ] })
973
1015
  ] });
974
1016
  };
975
- function P(a) {
976
- const n = new Date(a), t = n.getFullYear(), o = n.getMonth();
1017
+ function P(e) {
1018
+ const n = new Date(e), t = n.getFullYear(), o = n.getMonth();
977
1019
  return `${n.getDate().toString().padStart(2, "0")} ${ln[o]} ${t}`;
978
1020
  }
979
1021
  const on = ({
980
- label: a,
1022
+ label: e,
981
1023
  labelPosition: n = "outside-top",
982
1024
  required: t,
983
1025
  optional: o,
984
1026
  description: l,
985
1027
  helperText: u,
986
1028
  errorText: i,
987
- fullWidth: h,
988
- children: g
1029
+ fullWidth: g,
1030
+ children: f
989
1031
  }) => {
990
1032
  const r = [
991
1033
  "sa-date-field",
992
- h ? "sa-date-field-fullwidth" : ""
993
- ].filter(Boolean).join(" "), d = a ? /* @__PURE__ */ Y("div", { className: "sa-date-field-label-row", children: [
994
- /* @__PURE__ */ e("span", { className: "sa-date-field-label-text", children: a }),
995
- o && /* @__PURE__ */ e("span", { className: "sa-date-field-optional-badge", children: "Optional" }),
996
- t && /* @__PURE__ */ e("span", { className: "sa-date-field-required", children: "*" })
997
- ] }) : null, y = /* @__PURE__ */ Y(en, { children: [
998
- u && !i && /* @__PURE__ */ e("p", { className: "sa-date-field-helper", children: u }),
999
- i && /* @__PURE__ */ e("p", { className: "sa-date-field-error-msg", children: i })
1034
+ g ? "sa-date-field-fullwidth" : ""
1035
+ ].filter(Boolean).join(" "), d = e ? /* @__PURE__ */ $("div", { className: "sa-date-field-label-row", children: [
1036
+ /* @__PURE__ */ a("span", { className: "sa-date-field-label-text", children: e }),
1037
+ o && /* @__PURE__ */ a("span", { className: "sa-date-field-optional-badge", children: "Optional" }),
1038
+ t && /* @__PURE__ */ a("span", { className: "sa-date-field-required", children: "*" })
1039
+ ] }) : null, w = /* @__PURE__ */ $(en, { children: [
1040
+ u && !i && /* @__PURE__ */ a("p", { className: "sa-date-field-helper", children: u }),
1041
+ i && /* @__PURE__ */ a("p", { className: "sa-date-field-error-msg", children: i })
1000
1042
  ] });
1001
- return a ? n === "outside-left" ? /* @__PURE__ */ Y("div", { className: `${r} sa-date-field-left`, children: [
1002
- /* @__PURE__ */ Y("div", { className: "sa-date-field-left-label", children: [
1043
+ return e ? n === "outside-left" ? /* @__PURE__ */ $("div", { className: `${r} sa-date-field-left`, children: [
1044
+ /* @__PURE__ */ $("div", { className: "sa-date-field-left-label", children: [
1003
1045
  d,
1004
- l && /* @__PURE__ */ e("p", { className: "sa-date-field-helper-top", children: l })
1046
+ l && /* @__PURE__ */ a("p", { className: "sa-date-field-helper-top", children: l })
1005
1047
  ] }),
1006
- /* @__PURE__ */ Y("div", { className: "sa-date-field-input-wrap", children: [
1007
- g,
1008
- y
1048
+ /* @__PURE__ */ $("div", { className: "sa-date-field-input-wrap", children: [
1049
+ f,
1050
+ w
1009
1051
  ] })
1010
- ] }) : /* @__PURE__ */ Y("div", { className: r, children: [
1052
+ ] }) : /* @__PURE__ */ $("div", { className: r, children: [
1011
1053
  d,
1012
- l && /* @__PURE__ */ e("p", { className: "sa-date-field-helper-top", children: l }),
1013
- g,
1014
- y
1015
- ] }) : /* @__PURE__ */ Y("div", { className: r, children: [
1016
- l && /* @__PURE__ */ e("p", { className: "sa-date-field-helper-top", children: l }),
1017
- g,
1018
- y
1054
+ l && /* @__PURE__ */ a("p", { className: "sa-date-field-helper-top", children: l }),
1055
+ f,
1056
+ w
1057
+ ] }) : /* @__PURE__ */ $("div", { className: r, children: [
1058
+ l && /* @__PURE__ */ a("p", { className: "sa-date-field-helper-top", children: l }),
1059
+ f,
1060
+ w
1019
1061
  ] });
1020
- }, X = "sa-calendar-styles", fn = (a) => {
1062
+ }, X = "sa-calendar-styles", fn = (e) => {
1021
1063
  if (!document.getElementById(X)) {
1022
1064
  const n = document.createElement("style");
1023
- n.id = X, n.textContent = a, document.head.appendChild(n);
1065
+ n.id = X, n.textContent = e, document.head.appendChild(n);
1024
1066
  }
1025
1067
  };
1026
1068
  fn(R);
1027
- const bn = K(
1069
+ const mn = K(
1028
1070
  ({
1029
- value: a,
1071
+ value: e,
1030
1072
  onChange: n,
1031
1073
  filter: t,
1032
1074
  input: o = !0,
1033
1075
  disabled: l,
1034
1076
  minDate: u,
1035
1077
  maxDate: i,
1036
- placeholder: h,
1037
- size: g,
1078
+ placeholder: g,
1079
+ size: f = "sm",
1038
1080
  variant: r,
1039
1081
  status: d,
1040
- clearable: y,
1082
+ clearable: w,
1041
1083
  fullWidth: M = !0,
1042
1084
  withPadding: k = !0,
1043
- label: $,
1085
+ label: N,
1044
1086
  labelPosition: m,
1045
- required: f,
1087
+ required: h,
1046
1088
  optional: s,
1047
1089
  description: x,
1048
- helperText: N,
1049
- errorText: p
1050
- }, w) => {
1051
- const c = p ? "error" : d, { ref: v, isComponentVisible: z, setIsComponentVisible: S } = rn(!1), C = J(null), [L, I] = A("days"), [T, F] = A(/* @__PURE__ */ new Date()), [D, E] = A({
1052
- from: (a == null ? void 0 : a.from) ?? null,
1053
- to: (a == null ? void 0 : a.to) ?? null
1090
+ helperText: z,
1091
+ errorText: c
1092
+ }, y) => {
1093
+ const p = c ? "error" : d, { ref: b, isComponentVisible: E, setIsComponentVisible: S } = rn(!1), D = J(null), [F, I] = A("days"), [T, Y] = A(/* @__PURE__ */ new Date()), [C, L] = A({
1094
+ from: (e == null ? void 0 : e.from) ?? null,
1095
+ to: (e == null ? void 0 : e.to) ?? null
1054
1096
  });
1055
1097
  B(() => {
1056
- if (a) {
1057
- const b = a;
1058
- b.from && F(b.from), E(b);
1098
+ if (e) {
1099
+ const v = e;
1100
+ v.from && Y(v.from), L(v);
1059
1101
  } else
1060
- F(/* @__PURE__ */ new Date()), E({ from: null, to: null });
1061
- }, [a]), B(() => {
1102
+ Y(/* @__PURE__ */ new Date()), L({ from: null, to: null });
1103
+ }, [e]), B(() => {
1062
1104
  t && I(t);
1063
1105
  }, [t]), B(() => {
1064
1106
  t || I("days");
1065
- }, [z]), B(() => {
1107
+ }, [E]), B(() => {
1066
1108
  o || S(!0);
1067
1109
  }, [o]);
1068
1110
  const G = () => {
1069
- var b, V;
1070
- if (!a)
1111
+ var v, V;
1112
+ if (!e)
1071
1113
  return "";
1072
1114
  if (t) {
1073
- if (L === "days")
1074
- return `${P(D.from)} ~ ${P(D.to || D.from) || "-"}`;
1075
- if (L === "months")
1076
- return `${W[D.from.getMonth()]} ~ ${D.to ? W[D.to.getMonth()] : "-"}`;
1077
- if (L === "years")
1078
- return `${(b = D.from) == null ? void 0 : b.getFullYear()} ~ ${((V = D.to) == null ? void 0 : V.getFullYear()) || "-"}`;
1115
+ if (F === "days")
1116
+ return `${P(C.from)} ~ ${P(C.to || C.from) || "-"}`;
1117
+ if (F === "months")
1118
+ return `${W[C.from.getMonth()]} ~ ${C.to ? W[C.to.getMonth()] : "-"}`;
1119
+ if (F === "years")
1120
+ return `${(v = C.from) == null ? void 0 : v.getFullYear()} ~ ${((V = C.to) == null ? void 0 : V.getFullYear()) || "-"}`;
1079
1121
  } else
1080
- return `${P(D.from)} ~ ${P(D.to || D.from) || "-"}`;
1122
+ return `${P(C.from)} ~ ${P(C.to || C.from) || "-"}`;
1081
1123
  }, j = () => {
1082
- if (C.current && v.current && o) {
1083
- const b = v.current.getBoundingClientRect(), V = C.current.getBoundingClientRect();
1084
- window.innerWidth < b.left + V.width ? C.current.style.left = `${b.left - V.width + b.width}px` : C.current.style.left = `${b.left}px`, b.top + V.height > window.innerHeight ? C.current.style.top = `${b.y - (b.height + V.height - 28)}px` : C.current.style.top = `${b.y + b.height}px`;
1124
+ if (D.current && b.current && o) {
1125
+ const v = b.current.getBoundingClientRect(), V = D.current.getBoundingClientRect();
1126
+ window.innerWidth < v.left + V.width ? D.current.style.left = `${v.left - V.width + v.width}px` : D.current.style.left = `${v.left}px`, v.top + V.height > window.innerHeight ? D.current.style.top = `${v.y - (v.height + V.height - 28)}px` : D.current.style.top = `${v.y + v.height}px`;
1085
1127
  }
1086
1128
  };
1087
1129
  B(() => {
1088
- C.current && v.current && o && j();
1089
- }, [C, v, z]), B(() => {
1090
- const b = w == null ? void 0 : w.current;
1091
- return b && b.addEventListener("scroll", j), window.addEventListener("scroll", j), () => {
1092
- b && b.removeEventListener("scroll", j), window.removeEventListener("scroll", j);
1130
+ D.current && b.current && o && j();
1131
+ }, [D, b, E]), B(() => {
1132
+ const v = y == null ? void 0 : y.current;
1133
+ return v && v.addEventListener("scroll", j), window.addEventListener("scroll", j), () => {
1134
+ v && v.removeEventListener("scroll", j), window.removeEventListener("scroll", j);
1093
1135
  };
1094
1136
  }, []);
1095
- const U = /* @__PURE__ */ Y(
1137
+ const U = /* @__PURE__ */ $(
1096
1138
  "div",
1097
1139
  {
1098
1140
  className: "sa-calendar-wrapper",
1099
1141
  style: { height: o ? "auto" : "100%" },
1100
- ref: o ? v : null,
1142
+ ref: o ? b : null,
1101
1143
  children: [
1102
- o ? /* @__PURE__ */ e(
1144
+ o ? /* @__PURE__ */ a(
1103
1145
  cn,
1104
1146
  {
1105
1147
  value: G(),
@@ -1110,68 +1152,68 @@ const bn = K(
1110
1152
  onChange: () => {
1111
1153
  },
1112
1154
  disabled: l,
1113
- placeholder: h,
1114
- size: g,
1155
+ placeholder: g,
1156
+ size: f,
1115
1157
  variant: r,
1116
- status: c,
1117
- clearable: y,
1158
+ status: p,
1159
+ clearable: w,
1118
1160
  onClear: () => n(void 0)
1119
1161
  }
1120
1162
  ) : null,
1121
- z ? /* @__PURE__ */ Y(
1163
+ E ? /* @__PURE__ */ $(
1122
1164
  "div",
1123
1165
  {
1124
- className: `sa-calendar sa-calendar-size-${g || "md"} ${o ? "" : "sa-calendar-no-input"} ${k ? "" : "sa-calendar-no-padding"}`,
1166
+ className: `sa-calendar sa-calendar-size-${f || "sm"} ${o ? "" : "sa-calendar-no-input"} ${k ? "" : "sa-calendar-no-padding"}`,
1125
1167
  style: l ? { pointerEvents: "none" } : void 0,
1126
- ref: C,
1168
+ ref: D,
1127
1169
  children: [
1128
- /* @__PURE__ */ e(
1170
+ /* @__PURE__ */ a(
1129
1171
  gn,
1130
1172
  {
1131
1173
  setViews: I,
1132
- views: L,
1174
+ views: F,
1133
1175
  filter: t,
1134
1176
  date: T,
1135
- setDate: F
1177
+ setDate: Y
1136
1178
  }
1137
1179
  ),
1138
- /* @__PURE__ */ e("div", { className: "sa-calendar-body", children: L === "days" ? /* @__PURE__ */ e(
1139
- un,
1180
+ /* @__PURE__ */ a("div", { className: "sa-calendar-body", children: F === "days" ? /* @__PURE__ */ a(
1181
+ pn,
1140
1182
  {
1141
1183
  date: T,
1142
- setDate: F,
1184
+ setDate: Y,
1143
1185
  setIsComponentVisible: S,
1144
- dateRange: D,
1145
- setDateRange: E,
1186
+ dateRange: C,
1187
+ setDateRange: L,
1146
1188
  input: o,
1147
1189
  onChange: n,
1148
1190
  minDate: u,
1149
1191
  maxDate: i
1150
1192
  }
1151
- ) : L === "months" ? /* @__PURE__ */ e(
1152
- pn,
1193
+ ) : F === "months" ? /* @__PURE__ */ a(
1194
+ un,
1153
1195
  {
1154
1196
  date: T,
1155
- setDate: F,
1197
+ setDate: Y,
1156
1198
  filter: t,
1157
1199
  setViews: I,
1158
- dateRange: D,
1159
- setDateRange: E,
1200
+ dateRange: C,
1201
+ setDateRange: L,
1160
1202
  setIsComponentVisible: S,
1161
1203
  input: o,
1162
1204
  onChange: n,
1163
1205
  minDate: u,
1164
1206
  maxDate: i
1165
1207
  }
1166
- ) : /* @__PURE__ */ e(
1208
+ ) : /* @__PURE__ */ a(
1167
1209
  hn,
1168
1210
  {
1169
1211
  date: T,
1170
- setDate: F,
1212
+ setDate: Y,
1171
1213
  filter: t,
1172
1214
  setViews: I,
1173
- dateRange: D,
1174
- setDateRange: E,
1215
+ dateRange: C,
1216
+ setDateRange: L,
1175
1217
  setIsComponentVisible: S,
1176
1218
  input: o,
1177
1219
  onChange: n,
@@ -1185,55 +1227,57 @@ const bn = K(
1185
1227
  ]
1186
1228
  }
1187
1229
  );
1188
- return /* @__PURE__ */ e(
1230
+ return /* @__PURE__ */ a(
1189
1231
  on,
1190
1232
  {
1191
- label: $,
1233
+ label: N,
1192
1234
  labelPosition: m,
1193
- required: f,
1235
+ required: h,
1194
1236
  optional: s,
1195
1237
  description: x,
1196
- helperText: N,
1197
- errorText: p,
1238
+ helperText: z,
1239
+ errorText: c,
1198
1240
  fullWidth: M,
1199
1241
  children: U
1200
1242
  }
1201
1243
  );
1202
1244
  }
1203
- ), _ = "sa-calendar-input-styles", mn = (a) => {
1245
+ ), _ = "sa-calendar-input-styles", bn = (e) => {
1204
1246
  if (!document.getElementById(_)) {
1205
1247
  const n = document.createElement("style");
1206
- n.id = _, n.textContent = a, document.head.appendChild(n);
1248
+ n.id = _, n.textContent = e, document.head.appendChild(n);
1207
1249
  }
1208
1250
  };
1209
- mn(R);
1210
- const H = (a) => {
1211
- if (a === "sm")
1251
+ bn(R);
1252
+ const H = (e) => {
1253
+ if (e === "xs")
1254
+ return 14;
1255
+ if (e === "sm")
1212
1256
  return 16;
1213
- if (a === "md")
1257
+ if (e === "md")
1214
1258
  return 16;
1215
- if (a === "lg")
1259
+ if (e === "lg")
1216
1260
  return 20;
1217
- }, vn = (a) => {
1261
+ }, vn = (e) => {
1218
1262
  const {
1219
- size: n = "md",
1263
+ size: n = "sm",
1220
1264
  status: t = "default",
1221
1265
  variant: o = "outline",
1222
1266
  clearable: l,
1223
1267
  onClear: u,
1224
1268
  ...i
1225
- } = a, h = J(null), g = () => {
1226
- h.current && i.onClick && (h.current.focus(), i.onClick(""));
1227
- }, r = t === "disable" || i.disabled, d = !!i.value, y = l && d && !r, M = (k) => {
1269
+ } = e, g = J(null), f = () => {
1270
+ g.current && i.onClick && (g.current.focus(), i.onClick(""));
1271
+ }, r = t === "disable" || i.disabled, d = !!i.value, w = l && d && !r, M = (k) => {
1228
1272
  k.stopPropagation(), u == null || u();
1229
1273
  };
1230
- return /* @__PURE__ */ Y(
1274
+ return /* @__PURE__ */ $(
1231
1275
  "div",
1232
1276
  {
1233
1277
  className: `sa-calendar-input-container sa-calendar-input-${o} sa-calendar-input-container-${t} ${n} `,
1234
- onClick: g,
1278
+ onClick: f,
1235
1279
  children: [
1236
- /* @__PURE__ */ e("div", { className: "sa-calendar-input-container-icon-left", children: /* @__PURE__ */ e(
1280
+ /* @__PURE__ */ a("div", { className: "sa-calendar-input-container-icon-left", children: /* @__PURE__ */ a(
1237
1281
  "svg",
1238
1282
  {
1239
1283
  xmlns: "http://www.w3.org/2000/svg",
@@ -1241,7 +1285,7 @@ const H = (a) => {
1241
1285
  height: H(n),
1242
1286
  viewBox: "0 0 20 20",
1243
1287
  fill: "none",
1244
- children: /* @__PURE__ */ e(
1288
+ children: /* @__PURE__ */ a(
1245
1289
  "path",
1246
1290
  {
1247
1291
  d: "M12.5 2.08301V5.41634M7.50002 2.08301V5.41634M17.0688 9.58301H2.93113M17.0688 9.58301C16.8953 4.82698 15.1284 3.33301 10 3.33301C4.87165 3.33301 3.10469 4.82698 2.93113 9.58301M17.0688 9.58301C17.0786 9.85037 17.0834 10.128 17.0834 10.4163C17.0834 15.833 15.4167 17.4997 10 17.4997C4.58335 17.4997 2.91669 15.833 2.91669 10.4163C2.91669 10.128 2.92138 9.85037 2.93113 9.58301",
@@ -1253,24 +1297,24 @@ const H = (a) => {
1253
1297
  )
1254
1298
  }
1255
1299
  ) }),
1256
- /* @__PURE__ */ e("div", { className: "sa-calendar-input-preview-container", children: /* @__PURE__ */ e(
1300
+ /* @__PURE__ */ a("div", { className: "sa-calendar-input-preview-container", children: /* @__PURE__ */ a(
1257
1301
  "input",
1258
1302
  {
1259
1303
  className: "sa-calendar-input",
1260
1304
  ...i,
1261
1305
  disabled: r,
1262
1306
  value: i.value,
1263
- ref: h
1307
+ ref: g
1264
1308
  }
1265
1309
  ) }),
1266
- y ? /* @__PURE__ */ e(
1310
+ w ? /* @__PURE__ */ a(
1267
1311
  "button",
1268
1312
  {
1269
1313
  type: "button",
1270
1314
  "aria-label": "Clear date",
1271
1315
  className: "sa-calendar-input-clear",
1272
1316
  onClick: M,
1273
- children: /* @__PURE__ */ e(
1317
+ children: /* @__PURE__ */ a(
1274
1318
  "svg",
1275
1319
  {
1276
1320
  xmlns: "http://www.w3.org/2000/svg",
@@ -1278,7 +1322,7 @@ const H = (a) => {
1278
1322
  height: H(n),
1279
1323
  viewBox: "0 0 20 20",
1280
1324
  fill: "none",
1281
- children: /* @__PURE__ */ e(
1325
+ children: /* @__PURE__ */ a(
1282
1326
  "path",
1283
1327
  {
1284
1328
  d: "M5 5L15 15M15 5L5 15",
@@ -1291,7 +1335,7 @@ const H = (a) => {
1291
1335
  }
1292
1336
  )
1293
1337
  }
1294
- ) : /* @__PURE__ */ e("div", { className: "sa-calendar-input-container-icon-right", children: /* @__PURE__ */ e(
1338
+ ) : /* @__PURE__ */ a("div", { className: "sa-calendar-input-container-icon-right", children: /* @__PURE__ */ a(
1295
1339
  "svg",
1296
1340
  {
1297
1341
  xmlns: "http://www.w3.org/2000/svg",
@@ -1299,7 +1343,7 @@ const H = (a) => {
1299
1343
  height: H(n),
1300
1344
  viewBox: "0 0 20 20",
1301
1345
  fill: "none",
1302
- children: /* @__PURE__ */ e(
1346
+ children: /* @__PURE__ */ a(
1303
1347
  "path",
1304
1348
  {
1305
1349
  d: "M3.33331 7.5L9.99998 14.1667L16.6666 7.5",
@@ -1315,26 +1359,26 @@ const H = (a) => {
1315
1359
  }
1316
1360
  );
1317
1361
  }, yn = ({
1318
- date: a,
1362
+ date: e,
1319
1363
  setDate: n,
1320
1364
  previewDate: t,
1321
1365
  setPreviewDate: o,
1322
1366
  setIsComponentVisible: l,
1323
1367
  minDate: u,
1324
1368
  maxDate: i,
1325
- input: h,
1326
- onChange: g,
1369
+ input: g,
1370
+ onChange: f,
1327
1371
  hasValue: r
1328
1372
  }) => {
1329
1373
  let d = new Date(
1330
1374
  t.getFullYear(),
1331
1375
  t.getMonth(),
1332
1376
  1
1333
- ), y = d.getDay(), M = [];
1334
- const k = a.toDateString(), $ = (/* @__PURE__ */ new Date()).toDateString(), m = t.getMonth();
1377
+ ), w = d.getDay(), M = [];
1378
+ const k = e.toDateString(), N = (/* @__PURE__ */ new Date()).toDateString(), m = t.getMonth();
1335
1379
  for (let s = 0; s < 42; s++) {
1336
- s === 0 && y === 0 ? d.setDate(d.getDate() - 7) : s === 0 ? d.setDate(
1337
- d.getDate() + (s - y)
1380
+ s === 0 && w === 0 ? d.setDate(d.getDate() - 7) : s === 0 ? d.setDate(
1381
+ d.getDate() + (s - w)
1338
1382
  ) : d.setDate(d.getDate() + 1);
1339
1383
  let x = {
1340
1384
  currentMonth: d.getMonth() === m,
@@ -1342,31 +1386,31 @@ const H = (a) => {
1342
1386
  month: d.getMonth(),
1343
1387
  number: d.getDate(),
1344
1388
  selected: r && d.toDateString() === k,
1345
- isToday: d.toDateString() === $,
1389
+ isToday: d.toDateString() === N,
1346
1390
  year: d.getFullYear(),
1347
1391
  isDisabled: u && d < u || i && d > i
1348
1392
  };
1349
1393
  M.push(x);
1350
1394
  }
1351
- const f = (s) => {
1352
- (!u || s >= u) && (!i || s <= i) && (n(s), g(s), o(s), h && l(!1));
1395
+ const h = (s) => {
1396
+ (!u || s >= u) && (!i || s <= i) && (n(s), f(s), o(s), g && l(!1));
1353
1397
  };
1354
- return /* @__PURE__ */ Y("div", { className: "sa-calendar-days-preivew", children: [
1355
- /* @__PURE__ */ e("div", { className: "sa-calendar-days-name-preivew", children: an.map((s, x) => /* @__PURE__ */ e("p", { children: s }, x)) }),
1356
- /* @__PURE__ */ e("div", { className: "sa-calendar-days-number-preivew", children: M.map((s, x) => {
1357
- const N = s.isDisabled;
1358
- return /* @__PURE__ */ e(
1398
+ return /* @__PURE__ */ $("div", { className: "sa-calendar-days-preivew", children: [
1399
+ /* @__PURE__ */ a("div", { className: "sa-calendar-days-name-preivew", children: an.map((s, x) => /* @__PURE__ */ a("p", { children: s }, x)) }),
1400
+ /* @__PURE__ */ a("div", { className: "sa-calendar-days-number-preivew", children: M.map((s, x) => {
1401
+ const z = s.isDisabled;
1402
+ return /* @__PURE__ */ a(
1359
1403
  "p",
1360
1404
  {
1361
1405
  className: `${s.currentMonth ? "sa-calendar-days-current" : "sa-calendar-days"} ${s.selected ? "sa-calendar-days-active" : ""} ${s.isToday && !s.selected ? "sa-calendar-days-today" : ""}`,
1362
1406
  style: {
1363
- color: N ? "#ccc" : void 0,
1364
- pointerEvents: N ? "none" : void 0,
1365
- cursor: N ? "not-allowed" : "pointer",
1366
- ...h ? {} : { width: "100%" }
1407
+ color: z ? "#ccc" : void 0,
1408
+ pointerEvents: z ? "none" : void 0,
1409
+ cursor: z ? "not-allowed" : "pointer",
1410
+ ...g ? {} : { width: "100%" }
1367
1411
  },
1368
1412
  onClick: () => {
1369
- N || f(s.date);
1413
+ z || h(s.date);
1370
1414
  },
1371
1415
  children: s.number
1372
1416
  },
@@ -1375,27 +1419,27 @@ const H = (a) => {
1375
1419
  }) })
1376
1420
  ] });
1377
1421
  }, wn = ({
1378
- date: a,
1422
+ date: e,
1379
1423
  setDate: n,
1380
1424
  filter: t,
1381
1425
  setViews: o,
1382
1426
  onChange: l,
1383
1427
  previewDate: u,
1384
1428
  setPreviewDate: i,
1385
- minDate: h,
1386
- maxDate: g,
1429
+ minDate: g,
1430
+ maxDate: f,
1387
1431
  input: r,
1388
1432
  hasValue: d
1389
1433
  }) => {
1390
- const y = a.getMonth(), M = a.getFullYear(), k = u.getFullYear(), $ = (m) => {
1391
- (!h || m >= h) && (!g || m <= g) && (t ? (l(m), n(m), i(m)) : (o("days"), i(m)));
1434
+ const w = e.getMonth(), M = e.getFullYear(), k = u.getFullYear(), N = (m) => {
1435
+ (!g || m >= g) && (!f || m <= f) && (t ? (l(m), n(m), i(m)) : (o("days"), i(m)));
1392
1436
  };
1393
- return /* @__PURE__ */ e("div", { className: "sa-calendar-months-preview", children: W.map((m, f) => {
1394
- const s = h && new Date(k, f, 1) < h || g && new Date(k, f + 1, 0) > g;
1395
- return /* @__PURE__ */ e(
1437
+ return /* @__PURE__ */ a("div", { className: "sa-calendar-months-preview", children: W.map((m, h) => {
1438
+ const s = g && new Date(k, h, 1) < g || f && new Date(k, h + 1, 0) > f;
1439
+ return /* @__PURE__ */ a(
1396
1440
  "p",
1397
1441
  {
1398
- className: d && f === y && k === M ? "sa-calendar-months-active" : "",
1442
+ className: d && h === w && k === M ? "sa-calendar-months-active" : "",
1399
1443
  style: {
1400
1444
  color: s ? "#ccc" : void 0,
1401
1445
  pointerEvents: s ? "none" : void 0,
@@ -1403,43 +1447,43 @@ const H = (a) => {
1403
1447
  ...r ? {} : { width: "100%" }
1404
1448
  },
1405
1449
  onClick: () => {
1406
- s || $(new Date(k, f));
1450
+ s || N(new Date(k, h));
1407
1451
  },
1408
1452
  children: m.slice(0, 3)
1409
1453
  },
1410
- f
1454
+ h
1411
1455
  );
1412
1456
  }) });
1413
- }, Z = (a) => {
1414
- const n = Math.floor(a / 10) * 10, t = n + 10;
1457
+ }, Z = (e) => {
1458
+ const n = Math.floor(e / 10) * 10, t = n + 10;
1415
1459
  return { start: n, end: t };
1416
1460
  }, xn = ({
1417
- date: a,
1461
+ date: e,
1418
1462
  filter: n,
1419
1463
  setViews: t,
1420
1464
  setDate: o,
1421
1465
  onChange: l,
1422
1466
  previewDate: u,
1423
1467
  setPreviewDate: i,
1424
- minDate: h,
1425
- maxDate: g,
1468
+ minDate: g,
1469
+ maxDate: f,
1426
1470
  input: r,
1427
1471
  hasValue: d
1428
1472
  }) => {
1429
- let y = [];
1430
- const M = u.getFullYear(), { start: k, end: $ } = Z(M), m = a.getFullYear();
1431
- for (let s = k; s < $; s++) {
1432
- let x = h && new Date(s, 0, 1) < h || g && new Date(s, 11, 31) > g;
1433
- y.push({
1473
+ let w = [];
1474
+ const M = u.getFullYear(), { start: k, end: N } = Z(M), m = e.getFullYear();
1475
+ for (let s = k; s < N; s++) {
1476
+ let x = g && new Date(s, 0, 1) < g || f && new Date(s, 11, 31) > f;
1477
+ w.push({
1434
1478
  year: s,
1435
1479
  active: !!d && s === m,
1436
1480
  isDisabled: x
1437
1481
  });
1438
1482
  }
1439
- const f = (s) => {
1440
- (!h || s >= h) && (!g || s <= g) && (n ? (l(s), o(s), i(s)) : (t("months"), i(s)));
1483
+ const h = (s) => {
1484
+ (!g || s >= g) && (!f || s <= f) && (n ? (l(s), o(s), i(s)) : (t("months"), i(s)));
1441
1485
  };
1442
- return /* @__PURE__ */ e("div", { className: "sa-calendar-years-preview", children: y.map((s, x) => /* @__PURE__ */ e(
1486
+ return /* @__PURE__ */ a("div", { className: "sa-calendar-years-preview", children: w.map((s, x) => /* @__PURE__ */ a(
1443
1487
  "p",
1444
1488
  {
1445
1489
  className: s.active ? "sa-calendar-months-active" : "",
@@ -1450,21 +1494,21 @@ const H = (a) => {
1450
1494
  ...r ? {} : { width: "100%" }
1451
1495
  },
1452
1496
  onClick: () => {
1453
- s.isDisabled || f(new Date(s.year, 0));
1497
+ s.isDisabled || h(new Date(s.year, 0));
1454
1498
  },
1455
1499
  children: s.year
1456
1500
  },
1457
1501
  x
1458
1502
  )) });
1459
1503
  }, kn = ({
1460
- setViews: a,
1504
+ setViews: e,
1461
1505
  views: n,
1462
1506
  filter: t,
1463
1507
  previewDate: o,
1464
1508
  setPreviewDate: l
1465
1509
  }) => {
1466
1510
  const u = () => {
1467
- t || a((r) => r === "days" ? "months" : r === "months" ? "years" : "days");
1511
+ t || e((r) => r === "days" ? "months" : r === "months" ? "years" : "days");
1468
1512
  }, i = () => {
1469
1513
  if (n === "years") {
1470
1514
  l((r) => new Date(r.getFullYear() + 10, 0));
@@ -1477,7 +1521,7 @@ const H = (a) => {
1477
1521
  return;
1478
1522
  }
1479
1523
  l((r) => new Date(r.getFullYear(), r.getMonth() + 1));
1480
- }, h = () => {
1524
+ }, g = () => {
1481
1525
  if (n === "years") {
1482
1526
  l((r) => new Date(r.getFullYear() - 10, 0));
1483
1527
  return;
@@ -1495,8 +1539,8 @@ const H = (a) => {
1495
1539
  )
1496
1540
  );
1497
1541
  };
1498
- return /* @__PURE__ */ Y("div", { className: "sa-calendar-header", children: [
1499
- /* @__PURE__ */ e("div", { className: "sa-calendar-header-title", onClick: u, children: (() => {
1542
+ return /* @__PURE__ */ $("div", { className: "sa-calendar-header", children: [
1543
+ /* @__PURE__ */ a("div", { className: "sa-calendar-header-title", onClick: u, children: (() => {
1500
1544
  if (n === "days")
1501
1545
  return `${W[o.getMonth()]} ${o.getFullYear()}`;
1502
1546
  if (n === "months")
@@ -1504,151 +1548,151 @@ const H = (a) => {
1504
1548
  if (n === "years")
1505
1549
  return `${Z(o.getFullYear()).start} ~ ${Z(o.getFullYear()).end}`;
1506
1550
  })() }),
1507
- /* @__PURE__ */ Y("div", { className: "sa-calendar-header-nav", children: [
1508
- /* @__PURE__ */ e("button", { className: "sa-calendar-nav-btn", onClick: h, children: /* @__PURE__ */ e(tn, {}) }),
1509
- /* @__PURE__ */ e("button", { className: "sa-calendar-nav-btn", onClick: i, children: /* @__PURE__ */ e(sn, {}) })
1551
+ /* @__PURE__ */ $("div", { className: "sa-calendar-header-nav", children: [
1552
+ /* @__PURE__ */ a("button", { className: "sa-calendar-nav-btn", onClick: g, children: /* @__PURE__ */ a(tn, {}) }),
1553
+ /* @__PURE__ */ a("button", { className: "sa-calendar-nav-btn", onClick: i, children: /* @__PURE__ */ a(sn, {}) })
1510
1554
  ] })
1511
1555
  ] });
1512
- }, nn = "sa-calendar-styles", Mn = (a) => {
1556
+ }, nn = "sa-calendar-styles", Mn = (e) => {
1513
1557
  if (!document.getElementById(nn)) {
1514
1558
  const n = document.createElement("style");
1515
- n.id = nn, n.textContent = a, document.head.appendChild(n);
1559
+ n.id = nn, n.textContent = e, document.head.appendChild(n);
1516
1560
  }
1517
1561
  };
1518
1562
  Mn(R);
1519
1563
  const Cn = K(
1520
1564
  ({
1521
- value: a,
1565
+ value: e,
1522
1566
  onChange: n,
1523
1567
  filter: t,
1524
1568
  input: o = !0,
1525
1569
  disabled: l,
1526
1570
  minDate: u,
1527
1571
  maxDate: i,
1528
- placeholder: h,
1529
- size: g,
1572
+ placeholder: g,
1573
+ size: f = "sm",
1530
1574
  variant: r,
1531
1575
  status: d,
1532
- clearable: y,
1576
+ clearable: w,
1533
1577
  fullWidth: M = !0,
1534
1578
  withPadding: k = !0,
1535
- label: $,
1579
+ label: N,
1536
1580
  labelPosition: m,
1537
- required: f,
1581
+ required: h,
1538
1582
  optional: s,
1539
1583
  description: x,
1540
- helperText: N,
1541
- errorText: p
1542
- }, w) => {
1543
- const c = p ? "error" : d, { ref: v, isComponentVisible: z, setIsComponentVisible: S } = rn(!1), C = J(null), [L, I] = A("days"), [T, F] = A(/* @__PURE__ */ new Date()), [D, E] = A(/* @__PURE__ */ new Date());
1584
+ helperText: z,
1585
+ errorText: c
1586
+ }, y) => {
1587
+ const p = c ? "error" : d, { ref: b, isComponentVisible: E, setIsComponentVisible: S } = rn(!1), D = J(null), [F, I] = A("days"), [T, Y] = A(/* @__PURE__ */ new Date()), [C, L] = A(/* @__PURE__ */ new Date());
1544
1588
  B(() => {
1545
- a ? (F(a), E(a)) : (F(/* @__PURE__ */ new Date()), E(/* @__PURE__ */ new Date()));
1546
- }, [a]), B(() => {
1589
+ e ? (Y(e), L(e)) : (Y(/* @__PURE__ */ new Date()), L(/* @__PURE__ */ new Date()));
1590
+ }, [e]), B(() => {
1547
1591
  t && I(t);
1548
1592
  }, [t]), B(() => {
1549
1593
  t || I("days");
1550
- }, [z]), B(() => {
1594
+ }, [E]), B(() => {
1551
1595
  o || S(!0);
1552
1596
  }, [o]);
1553
- const G = () => a ? t === "days" ? P(T) : t === "months" ? `${W[T.getMonth()]} ${T.getFullYear()}` : t === "years" ? T.getFullYear() : P(T) : "", j = () => {
1554
- if (C.current && v.current && o) {
1555
- const b = v.current.getBoundingClientRect(), V = C.current.getBoundingClientRect();
1556
- window.innerWidth < b.left + V.width ? C.current.style.left = `${b.left - V.width + b.width}px` : C.current.style.left = `${b.left}px`, b.top + V.height > window.innerHeight ? C.current.style.top = `${b.y - (b.height + V.height - 28)}px` : C.current.style.top = `${b.y + b.height}px`;
1597
+ const G = () => e ? t === "days" ? P(T) : t === "months" ? `${W[T.getMonth()]} ${T.getFullYear()}` : t === "years" ? T.getFullYear() : P(T) : "", j = () => {
1598
+ if (D.current && b.current && o) {
1599
+ const v = b.current.getBoundingClientRect(), V = D.current.getBoundingClientRect();
1600
+ window.innerWidth < v.left + V.width ? D.current.style.left = `${v.left - V.width + v.width}px` : D.current.style.left = `${v.left}px`, v.top + V.height > window.innerHeight ? D.current.style.top = `${v.y - (v.height + V.height - 28)}px` : D.current.style.top = `${v.y + v.height}px`;
1557
1601
  }
1558
1602
  };
1559
1603
  B(() => {
1560
- C.current && v.current && o && j();
1561
- }, [C, v, z]), B(() => {
1562
- const b = w == null ? void 0 : w.current;
1563
- return b && b.addEventListener("scroll", j), window.addEventListener("scroll", j), () => {
1564
- b && b.removeEventListener("scroll", j), window.removeEventListener("scroll", j);
1604
+ D.current && b.current && o && j();
1605
+ }, [D, b, E]), B(() => {
1606
+ const v = y == null ? void 0 : y.current;
1607
+ return v && v.addEventListener("scroll", j), window.addEventListener("scroll", j), () => {
1608
+ v && v.removeEventListener("scroll", j), window.removeEventListener("scroll", j);
1565
1609
  };
1566
1610
  }, []);
1567
- const U = /* @__PURE__ */ Y(
1611
+ const U = /* @__PURE__ */ $(
1568
1612
  "div",
1569
1613
  {
1570
1614
  className: "sa-calendar-wrapper",
1571
1615
  style: { height: o ? "auto" : "100%" },
1572
- ref: o ? v : null,
1616
+ ref: o ? b : null,
1573
1617
  children: [
1574
- o ? /* @__PURE__ */ e(
1618
+ o ? /* @__PURE__ */ a(
1575
1619
  vn,
1576
1620
  {
1577
1621
  value: G(),
1578
1622
  onClick: () => S(!0),
1579
1623
  onChange: () => {
1580
1624
  },
1581
- placeholder: h,
1625
+ placeholder: g,
1582
1626
  disabled: l,
1583
- size: g,
1627
+ size: f,
1584
1628
  variant: r,
1585
- status: c,
1629
+ status: p,
1586
1630
  inputMode: "none",
1587
- clearable: y,
1631
+ clearable: w,
1588
1632
  onClear: () => n(void 0)
1589
1633
  }
1590
1634
  ) : null,
1591
- z ? /* @__PURE__ */ Y(
1635
+ E ? /* @__PURE__ */ $(
1592
1636
  "div",
1593
1637
  {
1594
- className: `sa-calendar sa-calendar-size-${g || "md"} ${o ? "" : "sa-calendar-no-input"} ${k ? "" : "sa-calendar-no-padding"}`,
1638
+ className: `sa-calendar sa-calendar-size-${f || "sm"} ${o ? "" : "sa-calendar-no-input"} ${k ? "" : "sa-calendar-no-padding"}`,
1595
1639
  style: l ? { pointerEvents: "none" } : void 0,
1596
- ref: C,
1640
+ ref: D,
1597
1641
  children: [
1598
- /* @__PURE__ */ e(
1642
+ /* @__PURE__ */ a(
1599
1643
  kn,
1600
1644
  {
1601
1645
  setViews: I,
1602
- views: L,
1646
+ views: F,
1603
1647
  filter: t,
1604
- previewDate: D,
1605
- setPreviewDate: E,
1606
- isComponentVisible: z
1648
+ previewDate: C,
1649
+ setPreviewDate: L,
1650
+ isComponentVisible: E
1607
1651
  }
1608
1652
  ),
1609
- /* @__PURE__ */ e("div", { className: "sa-calendar-body", children: L === "days" ? /* @__PURE__ */ e(
1653
+ /* @__PURE__ */ a("div", { className: "sa-calendar-body", children: F === "days" ? /* @__PURE__ */ a(
1610
1654
  yn,
1611
1655
  {
1612
1656
  date: T,
1613
- setDate: F,
1614
- previewDate: D,
1615
- setPreviewDate: E,
1657
+ setDate: Y,
1658
+ previewDate: C,
1659
+ setPreviewDate: L,
1616
1660
  setIsComponentVisible: S,
1617
1661
  input: o,
1618
1662
  minDate: u,
1619
1663
  maxDate: i,
1620
1664
  onChange: n,
1621
- hasValue: a != null
1665
+ hasValue: e != null
1622
1666
  }
1623
- ) : L === "months" ? /* @__PURE__ */ e(
1667
+ ) : F === "months" ? /* @__PURE__ */ a(
1624
1668
  wn,
1625
1669
  {
1626
1670
  date: T,
1627
- setDate: F,
1628
- previewDate: D,
1629
- setPreviewDate: E,
1671
+ setDate: Y,
1672
+ previewDate: C,
1673
+ setPreviewDate: L,
1630
1674
  filter: t,
1631
1675
  setViews: I,
1632
1676
  onChange: n,
1633
1677
  minDate: u,
1634
1678
  maxDate: i,
1635
1679
  input: o,
1636
- hasValue: a != null
1680
+ hasValue: e != null
1637
1681
  }
1638
- ) : /* @__PURE__ */ e(
1682
+ ) : /* @__PURE__ */ a(
1639
1683
  xn,
1640
1684
  {
1641
1685
  date: T,
1642
- setDate: F,
1643
- previewDate: D,
1644
- setPreviewDate: E,
1686
+ setDate: Y,
1687
+ previewDate: C,
1688
+ setPreviewDate: L,
1645
1689
  filter: t,
1646
1690
  setViews: I,
1647
1691
  onChange: n,
1648
1692
  minDate: u,
1649
1693
  maxDate: i,
1650
1694
  input: o,
1651
- hasValue: a != null
1695
+ hasValue: e != null
1652
1696
  }
1653
1697
  ) })
1654
1698
  ]
@@ -1657,72 +1701,72 @@ const Cn = K(
1657
1701
  ]
1658
1702
  }
1659
1703
  );
1660
- return /* @__PURE__ */ e(
1704
+ return /* @__PURE__ */ a(
1661
1705
  on,
1662
1706
  {
1663
- label: $,
1707
+ label: N,
1664
1708
  labelPosition: m,
1665
- required: f,
1709
+ required: h,
1666
1710
  optional: s,
1667
1711
  description: x,
1668
- helperText: N,
1669
- errorText: p,
1712
+ helperText: z,
1713
+ errorText: c,
1670
1714
  fullWidth: M,
1671
1715
  children: U
1672
1716
  }
1673
1717
  );
1674
1718
  }
1675
- ), $n = K(
1719
+ ), zn = K(
1676
1720
  ({
1677
- value: a,
1721
+ value: e,
1678
1722
  onChange: n,
1679
1723
  filter: t,
1680
1724
  input: o = !0,
1681
1725
  rangedDate: l,
1682
1726
  disabled: u,
1683
1727
  minDate: i,
1684
- maxDate: h,
1685
- placeholder: g,
1728
+ maxDate: g,
1729
+ placeholder: f,
1686
1730
  size: r,
1687
1731
  variant: d,
1688
- status: y,
1732
+ status: w,
1689
1733
  clearable: M,
1690
1734
  fullWidth: k,
1691
- withPadding: $,
1735
+ withPadding: N,
1692
1736
  label: m,
1693
- labelPosition: f,
1737
+ labelPosition: h,
1694
1738
  required: s,
1695
1739
  optional: x,
1696
- description: N,
1697
- helperText: p,
1698
- errorText: w
1699
- }, c) => {
1700
- const v = {
1740
+ description: z,
1741
+ helperText: c,
1742
+ errorText: y
1743
+ }, p) => {
1744
+ const b = {
1701
1745
  onChange: n,
1702
- value: a,
1746
+ value: e,
1703
1747
  input: o,
1704
1748
  filter: t,
1705
1749
  disabled: u,
1706
1750
  minDate: i,
1707
- maxDate: h,
1708
- placeholder: g,
1751
+ maxDate: g,
1752
+ placeholder: f,
1709
1753
  size: r,
1710
1754
  variant: d,
1711
- status: y,
1755
+ status: w,
1712
1756
  clearable: M,
1713
1757
  fullWidth: k,
1714
- withPadding: $,
1758
+ withPadding: N,
1715
1759
  label: m,
1716
- labelPosition: f,
1760
+ labelPosition: h,
1717
1761
  required: s,
1718
1762
  optional: x,
1719
- description: N,
1720
- helperText: p,
1721
- errorText: w
1763
+ description: z,
1764
+ helperText: c,
1765
+ errorText: y
1722
1766
  };
1723
- return /* @__PURE__ */ e(en, { children: l ? /* @__PURE__ */ e(bn, { ...v, ref: c }) : /* @__PURE__ */ e(Cn, { ...v, ref: c }) });
1767
+ return /* @__PURE__ */ a(en, { children: l ? /* @__PURE__ */ a(mn, { ...b, ref: p }) : /* @__PURE__ */ a(Cn, { ...b, ref: p }) });
1724
1768
  }
1725
1769
  );
1726
1770
  export {
1727
- $n as StarasiaDate
1771
+ zn as StarasiaDate
1728
1772
  };