@dmsi/wedgekit-react 0.0.415 → 0.0.417

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (123) hide show
  1. package/dist/chunk-3HBYDOYE.js +114 -0
  2. package/dist/{chunk-JIMJIJOF.js → chunk-5TGP5EFM.js} +2 -2
  3. package/dist/{chunk-2HMCS25C.js → chunk-6LHBY2IH.js} +1 -1
  4. package/dist/{chunk-6I5LZ2ZC.js → chunk-7AXHAWJX.js} +3 -3
  5. package/dist/{chunk-MQX7GFLX.js → chunk-CAQWLY5V.js} +24 -6
  6. package/dist/{chunk-QQ5G773N.js → chunk-DCLNAUC4.js} +1 -1
  7. package/dist/{chunk-GB4ZTUQV.js → chunk-DTW7JCBR.js} +36 -0
  8. package/dist/{chunk-BK7SPR6Y.js → chunk-HYJIDHAK.js} +6 -6
  9. package/dist/{chunk-ZHZIIVJN.js → chunk-IMOIZFJZ.js} +5 -5
  10. package/dist/chunk-KBJZUVLM.js +65 -0
  11. package/dist/{chunk-AA6GE3TH.js → chunk-LUPHOXAQ.js} +1 -1
  12. package/dist/chunk-NRNWEQD7.js +66 -0
  13. package/dist/{chunk-44TDIHUP.js → chunk-P3MIP2FD.js} +1 -1
  14. package/dist/{chunk-7ULLUUVJ.js → chunk-PQWWVBSR.js} +1 -1
  15. package/dist/{chunk-ERW5DEIO.js → chunk-RQLWSLVE.js} +1 -1
  16. package/dist/chunk-TYAQWVIM.js +159 -0
  17. package/dist/{chunk-KZZKQLKF.js → chunk-W55J2KJZ.js} +1 -1
  18. package/dist/chunk-Y2GK27RX.js +79 -0
  19. package/dist/components/Accordion.cjs +74 -2
  20. package/dist/components/Accordion.js +3 -3
  21. package/dist/components/CalendarRange.cjs +228 -53
  22. package/dist/components/CalendarRange.css +169 -65
  23. package/dist/components/CalendarRange.js +23 -16
  24. package/dist/components/Card.cjs +38 -2
  25. package/dist/components/Card.js +1 -1
  26. package/dist/components/CompactImagesPreview.cjs +59 -5
  27. package/dist/components/CompactImagesPreview.js +2 -2
  28. package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.cjs +186 -11
  29. package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.css +169 -65
  30. package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.js +23 -16
  31. package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.cjs +195 -20
  32. package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.css +169 -65
  33. package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.js +23 -16
  34. package/dist/components/DataGrid/PinnedColumns.cjs +211 -36
  35. package/dist/components/DataGrid/PinnedColumns.css +169 -65
  36. package/dist/components/DataGrid/PinnedColumns.js +23 -16
  37. package/dist/components/DataGrid/TableBody/LoadingCell.cjs +187 -12
  38. package/dist/components/DataGrid/TableBody/LoadingCell.css +169 -65
  39. package/dist/components/DataGrid/TableBody/LoadingCell.js +23 -16
  40. package/dist/components/DataGrid/TableBody/TableBodyRow.cjs +193 -18
  41. package/dist/components/DataGrid/TableBody/TableBodyRow.css +169 -65
  42. package/dist/components/DataGrid/TableBody/TableBodyRow.js +23 -16
  43. package/dist/components/DataGrid/TableBody/index.cjs +208 -33
  44. package/dist/components/DataGrid/TableBody/index.css +169 -65
  45. package/dist/components/DataGrid/TableBody/index.js +23 -16
  46. package/dist/components/DataGrid/index.cjs +297 -122
  47. package/dist/components/DataGrid/index.css +169 -65
  48. package/dist/components/DataGrid/index.js +23 -16
  49. package/dist/components/DataGrid/utils.cjs +187 -12
  50. package/dist/components/DataGrid/utils.css +169 -65
  51. package/dist/components/DataGrid/utils.js +23 -16
  52. package/dist/components/DateInput.cjs +247 -72
  53. package/dist/components/DateInput.css +169 -65
  54. package/dist/components/DateInput.js +23 -16
  55. package/dist/components/DateRangeInput.cjs +247 -72
  56. package/dist/components/DateRangeInput.css +169 -65
  57. package/dist/components/DateRangeInput.js +23 -16
  58. package/dist/components/Grid.cjs +81 -76
  59. package/dist/components/Grid.js +1 -1
  60. package/dist/components/ListGroup.cjs +553 -0
  61. package/dist/components/ListGroup.js +11 -0
  62. package/dist/components/MobileDataGrid/ColumnList.cjs +36 -0
  63. package/dist/components/MobileDataGrid/ColumnList.js +3 -3
  64. package/dist/components/MobileDataGrid/ColumnSelector/index.cjs +194 -19
  65. package/dist/components/MobileDataGrid/ColumnSelector/index.css +169 -65
  66. package/dist/components/MobileDataGrid/ColumnSelector/index.js +23 -16
  67. package/dist/components/MobileDataGrid/MobileDataGridCard/index.cjs +36 -0
  68. package/dist/components/MobileDataGrid/MobileDataGridCard/index.js +2 -2
  69. package/dist/components/MobileDataGrid/MobileDataGridHeader.cjs +238 -27
  70. package/dist/components/MobileDataGrid/MobileDataGridHeader.css +169 -65
  71. package/dist/components/MobileDataGrid/MobileDataGridHeader.js +23 -16
  72. package/dist/components/MobileDataGrid/RowDetailModalProvider/ModalContent.cjs +36 -0
  73. package/dist/components/MobileDataGrid/RowDetailModalProvider/ModalContent.js +2 -2
  74. package/dist/components/MobileDataGrid/RowDetailModalProvider/index.cjs +36 -0
  75. package/dist/components/MobileDataGrid/RowDetailModalProvider/index.js +5 -5
  76. package/dist/components/MobileDataGrid/index.cjs +740 -529
  77. package/dist/components/MobileDataGrid/index.css +169 -65
  78. package/dist/components/MobileDataGrid/index.js +23 -16
  79. package/dist/components/Modal.js +2 -2
  80. package/dist/components/Notification.cjs +36 -0
  81. package/dist/components/Notification.js +1 -1
  82. package/dist/components/PDFViewer/PDFElement.cjs +36 -0
  83. package/dist/components/PDFViewer/PDFElement.js +2 -2
  84. package/dist/components/PDFViewer/PDFNavigation.cjs +36 -0
  85. package/dist/components/PDFViewer/PDFNavigation.js +2 -2
  86. package/dist/components/PDFViewer/index.cjs +36 -0
  87. package/dist/components/PDFViewer/index.js +8 -111
  88. package/dist/components/Pagination.cjs +427 -0
  89. package/dist/components/Pagination.js +10 -0
  90. package/dist/components/ProductImagePreview/index.cjs +139 -127
  91. package/dist/components/ProductImagePreview/index.js +4 -4
  92. package/dist/components/SideMenuGroup.cjs +36 -0
  93. package/dist/components/SideMenuGroup.js +1 -1
  94. package/dist/components/SideMenuItem.cjs +36 -0
  95. package/dist/components/SideMenuItem.js +1 -1
  96. package/dist/components/SimpleTable.cjs +36 -0
  97. package/dist/components/SimpleTable.js +2 -2
  98. package/dist/components/Stack.cjs +36 -0
  99. package/dist/components/Stack.js +1 -1
  100. package/dist/components/Swatch.cjs +36 -0
  101. package/dist/components/Swatch.js +1 -1
  102. package/dist/components/Time.cjs +36 -0
  103. package/dist/components/Time.js +1 -1
  104. package/dist/components/Tooltip.cjs +1 -1
  105. package/dist/components/Tooltip.js +1 -1
  106. package/dist/components/Upload.cjs +36 -0
  107. package/dist/components/Upload.js +1 -1
  108. package/dist/components/index.cjs +686 -131
  109. package/dist/components/index.css +169 -65
  110. package/dist/components/index.js +33 -17
  111. package/dist/index.css +169 -65
  112. package/package.json +1 -1
  113. package/src/components/Card.tsx +60 -2
  114. package/src/components/CompactImagesPreview.tsx +54 -30
  115. package/src/components/Grid.tsx +59 -91
  116. package/src/components/ListGroup.tsx +82 -0
  117. package/src/components/Pagination.tsx +182 -0
  118. package/src/components/Stack.tsx +76 -0
  119. package/src/components/Tooltip.tsx +4 -3
  120. package/src/components/index.ts +3 -0
  121. package/dist/chunk-ER6RCOH3.js +0 -97
  122. package/dist/chunk-EZCH4PQS.js +0 -29
  123. package/dist/{chunk-D6YCMQPO.js → chunk-SBCFBHNG.js} +3 -3
@@ -62,7 +62,7 @@ __export(DateRangeInput_exports, {
62
62
  DateRangeInput: () => DateRangeInput
63
63
  });
64
64
  module.exports = __toCommonJS(DateRangeInput_exports);
65
- var import_react34 = require("react");
65
+ var import_react38 = require("react");
66
66
  var import_react_dom4 = require("react-dom");
67
67
 
68
68
  // src/components/Input.tsx
@@ -716,8 +716,8 @@ Currency.displayName = "Currency";
716
716
  Percentage.displayName = "Percentage";
717
717
 
718
718
  // src/components/CalendarRange.tsx
719
- var import_clsx35 = __toESM(require("clsx"), 1);
720
- var import_react33 = __toESM(require("react"), 1);
719
+ var import_clsx38 = __toESM(require("clsx"), 1);
720
+ var import_react37 = __toESM(require("react"), 1);
721
721
  var import_polyfill = require("@js-temporal/polyfill");
722
722
 
723
723
  // src/components/DataGridCell.tsx
@@ -4056,7 +4056,7 @@ var Tooltip = ({
4056
4056
  id,
4057
4057
  "data-testid": testid,
4058
4058
  ref,
4059
- className: "relative inline-grid grid-cols-[auto_1fr] items-center",
4059
+ className: "relative inline-grid grid-cols-[auto_1fr] items-center cursor-pointer",
4060
4060
  onMouseEnter: handleMouseEnter,
4061
4061
  onMouseLeave: handleMouseLeave,
4062
4062
  children: [
@@ -4647,12 +4647,11 @@ var import_jsx_runtime41 = require("react/jsx-runtime");
4647
4647
  var import_jsx_runtime42 = require("react/jsx-runtime");
4648
4648
 
4649
4649
  // src/components/Grid.tsx
4650
- var import_react27 = require("react");
4651
4650
  var import_clsx30 = __toESM(require("clsx"), 1);
4652
4651
  var import_jsx_runtime43 = require("react/jsx-runtime");
4653
4652
 
4654
4653
  // src/components/ProductImagePreview/ProductPrimaryImage.tsx
4655
- var import_react28 = require("react");
4654
+ var import_react27 = require("react");
4656
4655
 
4657
4656
  // src/components/Spinner.tsx
4658
4657
  var import_jsx_runtime44 = require("react/jsx-runtime");
@@ -4688,7 +4687,7 @@ Spinner.displayName = "Spinner";
4688
4687
  var import_jsx_runtime45 = require("react/jsx-runtime");
4689
4688
 
4690
4689
  // src/components/ProductImagePreview/ZoomWindow.tsx
4691
- var import_react29 = require("react");
4690
+ var import_react28 = require("react");
4692
4691
 
4693
4692
  // src/components/Surface.tsx
4694
4693
  var import_clsx31 = __toESM(require("clsx"), 1);
@@ -4733,17 +4732,17 @@ var import_clsx32 = require("clsx");
4733
4732
  var import_jsx_runtime48 = require("react/jsx-runtime");
4734
4733
 
4735
4734
  // src/components/ProductImagePreview/MobileImageCarousel.tsx
4736
- var import_react30 = require("react");
4735
+ var import_react29 = require("react");
4737
4736
  var import_jsx_runtime49 = require("react/jsx-runtime");
4738
4737
 
4739
4738
  // src/components/ProductImagePreview/useProductImagePreview.ts
4740
- var import_react31 = require("react");
4739
+ var import_react30 = require("react");
4741
4740
 
4742
4741
  // src/components/ProductImagePreview/index.tsx
4743
4742
  var import_jsx_runtime50 = require("react/jsx-runtime");
4744
4743
 
4745
4744
  // src/components/CompactImagesPreview.tsx
4746
- var import_react32 = require("react");
4745
+ var import_react31 = require("react");
4747
4746
  var import_clsx33 = __toESM(require("clsx"), 1);
4748
4747
  var import_jsx_runtime51 = require("react/jsx-runtime");
4749
4748
 
@@ -4751,8 +4750,184 @@ var import_jsx_runtime51 = require("react/jsx-runtime");
4751
4750
  var import_clsx34 = __toESM(require("clsx"), 1);
4752
4751
  var import_jsx_runtime52 = require("react/jsx-runtime");
4753
4752
 
4754
- // src/components/CalendarRange.tsx
4753
+ // src/components/PDFViewer/index.tsx
4754
+ var import_react34 = require("react");
4755
+
4756
+ // src/components/PDFViewer/PDFElement.tsx
4757
+ var import_react_pdf2 = require("@mikecousins/react-pdf");
4758
+ var import_react33 = require("react");
4759
+
4760
+ // src/components/PDFViewer/PDFPage.tsx
4761
+ var import_react_pdf = require("@mikecousins/react-pdf");
4762
+ var import_react32 = require("react");
4755
4763
  var import_jsx_runtime53 = require("react/jsx-runtime");
4764
+
4765
+ // src/components/PDFViewer/PDFElement.tsx
4766
+ var import_clsx35 = __toESM(require("clsx"), 1);
4767
+ var import_jsx_runtime54 = require("react/jsx-runtime");
4768
+
4769
+ // src/components/PDFViewer/DownloadIcon.tsx
4770
+ var import_jsx_runtime55 = require("react/jsx-runtime");
4771
+
4772
+ // src/components/PDFViewer/PDFNavigation.tsx
4773
+ var import_jsx_runtime56 = require("react/jsx-runtime");
4774
+
4775
+ // src/components/PDFViewer/index.tsx
4776
+ var import_jsx_runtime57 = require("react/jsx-runtime");
4777
+
4778
+ // src/components/ListGroup.tsx
4779
+ var import_react35 = require("react");
4780
+ var import_clsx36 = __toESM(require("clsx"), 1);
4781
+ var import_jsx_runtime58 = require("react/jsx-runtime");
4782
+
4783
+ // src/components/Pagination.tsx
4784
+ var import_react36 = require("react");
4785
+ var import_clsx37 = __toESM(require("clsx"), 1);
4786
+ var import_jsx_runtime59 = require("react/jsx-runtime");
4787
+ var Pagination = ({
4788
+ totalPages,
4789
+ currentPage,
4790
+ onPageChange,
4791
+ id,
4792
+ testid,
4793
+ className,
4794
+ disabled
4795
+ }) => {
4796
+ const goTo = (0, import_react36.useCallback)(
4797
+ (page) => {
4798
+ if (disabled) return;
4799
+ onPageChange(page);
4800
+ },
4801
+ [onPageChange, disabled]
4802
+ );
4803
+ const handleKey = (e) => {
4804
+ if (disabled) return;
4805
+ if (e.key === "ArrowLeft") {
4806
+ e.preventDefault();
4807
+ goTo(currentPage - 1);
4808
+ } else if (e.key === "ArrowRight") {
4809
+ e.preventDefault();
4810
+ goTo(currentPage + 1);
4811
+ }
4812
+ };
4813
+ const pageTokens = (0, import_react36.useMemo)(() => {
4814
+ if (totalPages <= 5) {
4815
+ return Array.from({ length: totalPages }, (_, i) => i + 1);
4816
+ }
4817
+ const pages = /* @__PURE__ */ new Set();
4818
+ pages.add(1);
4819
+ pages.add(totalPages);
4820
+ if (currentPage <= 3) {
4821
+ pages.add(2);
4822
+ pages.add(3);
4823
+ pages.add(4);
4824
+ } else if (currentPage >= totalPages - 2) {
4825
+ pages.add(totalPages - 1);
4826
+ pages.add(totalPages - 2);
4827
+ pages.add(totalPages - 3);
4828
+ } else {
4829
+ pages.add(currentPage - 1);
4830
+ pages.add(currentPage);
4831
+ pages.add(currentPage + 1);
4832
+ }
4833
+ const sorted = Array.from(pages).sort((a, b) => a - b);
4834
+ const tokens = [];
4835
+ for (let i = 0; i < sorted.length; i++) {
4836
+ const value = sorted[i];
4837
+ const prev = sorted[i - 1];
4838
+ if (i > 0) {
4839
+ if (value - prev === 2) {
4840
+ tokens.push(prev + 1);
4841
+ } else if (value - prev > 2) {
4842
+ tokens.push("ellipsis");
4843
+ }
4844
+ }
4845
+ tokens.push(value);
4846
+ }
4847
+ return tokens;
4848
+ }, [totalPages, currentPage]);
4849
+ if (totalPages <= 1) return null;
4850
+ const buttonClass = (0, import_clsx37.default)(
4851
+ "cursor-pointer disabled:cursor-default",
4852
+ paddingUsingComponentGap,
4853
+ "w-8 h-8",
4854
+ "flex items-center justify-center",
4855
+ "bg-transparent",
4856
+ "box-content",
4857
+ "hover:bg-background-grouped-secondary-normal",
4858
+ "focus:bg-background-grouped-secondary-normal focus:outline-0",
4859
+ "disabled:bg-transparent disabled:text-text-action-primary-disabled"
4860
+ );
4861
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsxs)(
4862
+ "nav",
4863
+ {
4864
+ id,
4865
+ "data-testid": testid,
4866
+ "aria-label": "Pagination",
4867
+ onKeyDown: handleKey,
4868
+ className: (0, import_clsx37.default)(
4869
+ "flex items-center",
4870
+ "border border-border-primary-normal",
4871
+ "bg-background-grouped-primary-normal",
4872
+ "rounded-sm",
4873
+ className
4874
+ ),
4875
+ children: [
4876
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
4877
+ "button",
4878
+ {
4879
+ disabled: disabled || currentPage <= 1,
4880
+ "aria-label": "Previous page",
4881
+ onClick: () => goTo(currentPage - 1),
4882
+ className: (0, import_clsx37.default)(buttonClass, "border-r-1 border-border-primary-normal"),
4883
+ children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(Icon, { name: "keyboard_arrow_left" })
4884
+ }
4885
+ ),
4886
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("ul", { className: (0, import_clsx37.default)("flex items-center"), children: pageTokens.map((token, index) => {
4887
+ if (token === "ellipsis") {
4888
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
4889
+ "li",
4890
+ {
4891
+ className: "w-8 h-8 select-none text-text-action-primary-disabled",
4892
+ children: "\u2026"
4893
+ },
4894
+ `ellipsis-${index}`
4895
+ );
4896
+ }
4897
+ const selected = token === currentPage;
4898
+ return /* @__PURE__ */ (0, import_jsx_runtime59.jsx)("li", { children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
4899
+ "button",
4900
+ {
4901
+ "aria-label": `Page ${token}`,
4902
+ "aria-current": selected ? "page" : void 0,
4903
+ disabled,
4904
+ onClick: () => goTo(token),
4905
+ className: (0, import_clsx37.default)(
4906
+ buttonClass,
4907
+ selected && "border-x-1 bg-background-grouped-secondary-normal border-border-primary-normal"
4908
+ ),
4909
+ children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(Subheader, { align: "center", weight: "bold", children: token })
4910
+ }
4911
+ ) }, token);
4912
+ }) }),
4913
+ /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(
4914
+ "button",
4915
+ {
4916
+ disabled: disabled || currentPage >= totalPages,
4917
+ "aria-label": "Next page",
4918
+ onClick: () => goTo(currentPage + 1),
4919
+ className: (0, import_clsx37.default)(buttonClass, "border-l-1 border-border-primary-normal"),
4920
+ children: /* @__PURE__ */ (0, import_jsx_runtime59.jsx)(Icon, { name: "keyboard_arrow_right" })
4921
+ }
4922
+ )
4923
+ ]
4924
+ }
4925
+ );
4926
+ };
4927
+ Pagination.displayName = "Pagination";
4928
+
4929
+ // src/components/CalendarRange.tsx
4930
+ var import_jsx_runtime60 = require("react/jsx-runtime");
4756
4931
  function DateCell(_a) {
4757
4932
  var _b = _a, {
4758
4933
  date,
@@ -4787,12 +4962,12 @@ function DateCell(_a) {
4787
4962
  "id",
4788
4963
  "testid"
4789
4964
  ]);
4790
- return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
4965
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
4791
4966
  "span",
4792
4967
  __spreadProps(__spreadValues({}, props), {
4793
4968
  id,
4794
4969
  "data-testid": testid,
4795
- className: (0, import_clsx35.default)(
4970
+ className: (0, import_clsx38.default)(
4796
4971
  "flex items-center justify-center aspect-square select-none transition-colors border duration-100 font-medium",
4797
4972
  typography.caption,
4798
4973
  cellPadding,
@@ -4862,20 +5037,20 @@ function CalendarRange({
4862
5037
  const fromDate = parseDate(from);
4863
5038
  const toDate = parseDate(to);
4864
5039
  const today = import_polyfill.Temporal.Now.plainDateISO();
4865
- const [baseMonth, setBaseMonth] = (0, import_react33.useState)(
5040
+ const [baseMonth, setBaseMonth] = (0, import_react37.useState)(
4866
5041
  fromDate != null ? fromDate : today.with({ day: 1 })
4867
5042
  );
4868
- const [selecting, setSelecting] = (0, import_react33.useState)("from");
4869
- const [pendingFrom, setPendingFrom] = (0, import_react33.useState)(void 0);
4870
- const [hoveredDate, setHoveredDate] = (0, import_react33.useState)(void 0);
4871
- (0, import_react33.useEffect)(() => {
5043
+ const [selecting, setSelecting] = (0, import_react37.useState)("from");
5044
+ const [pendingFrom, setPendingFrom] = (0, import_react37.useState)(void 0);
5045
+ const [hoveredDate, setHoveredDate] = (0, import_react37.useState)(void 0);
5046
+ (0, import_react37.useEffect)(() => {
4872
5047
  if (fromDate) {
4873
5048
  setBaseMonth(fromDate.with({ day: 1 }));
4874
5049
  } else if (toDate) {
4875
5050
  setBaseMonth(toDate.with({ day: 1 }));
4876
5051
  }
4877
5052
  }, [from, to]);
4878
- (0, import_react33.useEffect)(() => {
5053
+ (0, import_react37.useEffect)(() => {
4879
5054
  if (fromDate && toDate) {
4880
5055
  setSelecting("from");
4881
5056
  setPendingFrom(void 0);
@@ -4941,12 +5116,12 @@ function CalendarRange({
4941
5116
  }
4942
5117
  return false;
4943
5118
  }
4944
- return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5119
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
4945
5120
  "div",
4946
5121
  {
4947
5122
  id,
4948
5123
  "data-testid": testid,
4949
- className: (0, import_clsx35.default)(
5124
+ className: (0, import_clsx38.default)(
4950
5125
  "relative bg-background-grouped-primary-normal rounded-base w-fit",
4951
5126
  layoutPaddding,
4952
5127
  layoutGap,
@@ -4954,15 +5129,15 @@ function CalendarRange({
4954
5129
  // baseTransition,
4955
5130
  "overflow-hidden"
4956
5131
  ),
4957
- children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5132
+ children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
4958
5133
  "div",
4959
5134
  {
4960
- className: (0, import_clsx35.default)(
5135
+ className: (0, import_clsx38.default)(
4961
5136
  "flex flex-row items-start justify-start bg-background-primary-normal overflow-clip",
4962
5137
  layoutGap
4963
5138
  ),
4964
5139
  children: (mode === "double" ? [0, 1] : [0]).map((offset, idx) => {
4965
- return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5140
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
4966
5141
  CalendarPane,
4967
5142
  {
4968
5143
  getMonthData,
@@ -5020,45 +5195,45 @@ function CalendarPane({
5020
5195
  const years = Array.from({ length: 100 }).map(
5021
5196
  (_, i) => baseMonth.year - 50 + i
5022
5197
  );
5023
- const [monthMenuOpen, setMonthMenuOpen] = (0, import_react33.useState)(false);
5024
- const [yearMenuOpen, setYearMenuOpen] = (0, import_react33.useState)(false);
5025
- const monthMenuRef = (0, import_react33.useRef)(null);
5026
- const yearMenuRef = (0, import_react33.useRef)(null);
5198
+ const [monthMenuOpen, setMonthMenuOpen] = (0, import_react37.useState)(false);
5199
+ const [yearMenuOpen, setYearMenuOpen] = (0, import_react37.useState)(false);
5200
+ const monthMenuRef = (0, import_react37.useRef)(null);
5201
+ const yearMenuRef = (0, import_react37.useRef)(null);
5027
5202
  const month = getMonthData(offset);
5028
5203
  const totalCells = 42;
5029
5204
  const emptyCells = month.firstDayOffset;
5030
- return /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(import_react33.default.Fragment, { children: [
5031
- /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
5205
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(import_react37.default.Fragment, { children: [
5206
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
5032
5207
  "div",
5033
5208
  {
5034
- className: (0, import_clsx35.default)("flex flex-col"),
5209
+ className: (0, import_clsx38.default)("flex flex-col"),
5035
5210
  children: [
5036
- /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)(
5211
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)(
5037
5212
  "div",
5038
5213
  {
5039
- className: (0, import_clsx35.default)(
5214
+ className: (0, import_clsx38.default)(
5040
5215
  "flex flex-row items-center justify-between",
5041
5216
  typography.label,
5042
5217
  "text-text-action-primary-normal"
5043
5218
  ),
5044
5219
  children: [
5045
- idx === 0 ? /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5220
+ idx === 0 ? /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
5046
5221
  "button",
5047
5222
  {
5048
5223
  id: id ? `${id}-prev-month-button` : void 0,
5049
5224
  "data-testid": testid ? `${testid}-prev-month-button` : void 0,
5050
5225
  type: "button",
5051
- className: (0, import_clsx35.default)(
5226
+ className: (0, import_clsx38.default)(
5052
5227
  "flex items-center justify-center rounded-base hover:bg-action-100 active:bg-action-300 text-icon-action-primary-normal",
5053
5228
  componentPadding
5054
5229
  ),
5055
5230
  "aria-label": "Previous month",
5056
5231
  onClick: () => setBaseMonth(baseMonth.subtract({ months: 1 })),
5057
- children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(Icon, { name: "chevron_left", size: 24 })
5232
+ children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(Icon, { name: "chevron_left", size: 24 })
5058
5233
  }
5059
- ) : /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: (0, import_clsx35.default)(componentPadding, "mr-1") }),
5060
- /* @__PURE__ */ (0, import_jsx_runtime53.jsxs)("div", { className: "flex gap-desktop-compact-component-padding", children: [
5061
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5234
+ ) : /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("span", { className: (0, import_clsx38.default)(componentPadding, "mr-1") }),
5235
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsxs)("div", { className: "flex gap-desktop-compact-component-padding", children: [
5236
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
5062
5237
  "button",
5063
5238
  {
5064
5239
  ref: (el) => {
@@ -5073,13 +5248,13 @@ function CalendarPane({
5073
5248
  children: month.name
5074
5249
  }
5075
5250
  ),
5076
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5251
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
5077
5252
  Menu,
5078
5253
  {
5079
5254
  show: monthMenuOpen,
5080
5255
  positionTo: monthMenuRef,
5081
5256
  setShow: () => setMonthMenuOpen(false),
5082
- children: months.map((x) => [x, getMonthDataWith(x + 1)]).map(([x, m]) => /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5257
+ children: months.map((x) => [x, getMonthDataWith(x + 1)]).map(([x, m]) => /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
5083
5258
  MenuOption,
5084
5259
  {
5085
5260
  selected: baseMonth.month === x + 1,
@@ -5093,7 +5268,7 @@ function CalendarPane({
5093
5268
  ))
5094
5269
  }
5095
5270
  ),
5096
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5271
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
5097
5272
  "button",
5098
5273
  {
5099
5274
  ref: (el) => {
@@ -5108,13 +5283,13 @@ function CalendarPane({
5108
5283
  children: month.year
5109
5284
  }
5110
5285
  ),
5111
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5286
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
5112
5287
  Menu,
5113
5288
  {
5114
5289
  show: yearMenuOpen,
5115
5290
  positionTo: yearMenuRef,
5116
5291
  setShow: () => setYearMenuOpen(false),
5117
- children: years.map((y) => /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5292
+ children: years.map((y) => /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
5118
5293
  MenuOption,
5119
5294
  {
5120
5295
  selected: baseMonth.year === y,
@@ -5129,28 +5304,28 @@ function CalendarPane({
5129
5304
  }
5130
5305
  )
5131
5306
  ] }),
5132
- (mode === "double" ? idx === 1 : true) ? /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5307
+ (mode === "double" ? idx === 1 : true) ? /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
5133
5308
  "button",
5134
5309
  {
5135
5310
  id: id ? `${id}-next-month-button` : void 0,
5136
5311
  "data-testid": testid ? `${testid}-next-month-button` : void 0,
5137
5312
  type: "button",
5138
- className: (0, import_clsx35.default)(
5313
+ className: (0, import_clsx38.default)(
5139
5314
  "flex items-center justify-center rounded-base hover:bg-action-100 active:bg-action-300 text-icon-action-primary-normal",
5140
5315
  componentPadding
5141
5316
  ),
5142
5317
  "aria-label": "Next month",
5143
5318
  onClick: () => setBaseMonth(baseMonth.add({ months: 1 })),
5144
- children: /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(Icon, { name: "chevron_right", size: 24 })
5319
+ children: /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(Icon, { name: "chevron_right", size: 24 })
5145
5320
  }
5146
- ) : /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("span", { className: (0, import_clsx35.default)(componentPadding, "ml-1") })
5321
+ ) : /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("span", { className: (0, import_clsx38.default)(componentPadding, "ml-1") })
5147
5322
  ]
5148
5323
  }
5149
5324
  ),
5150
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: (0, import_clsx35.default)("grid grid-cols-7"), children: weekDays.map((d) => /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5325
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: (0, import_clsx38.default)("grid grid-cols-7"), children: weekDays.map((d) => /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
5151
5326
  "span",
5152
5327
  {
5153
- className: (0, import_clsx35.default)(
5328
+ className: (0, import_clsx38.default)(
5154
5329
  typography.caption,
5155
5330
  "text-text-secondary-normal text-center",
5156
5331
  "w-10"
@@ -5159,7 +5334,7 @@ function CalendarPane({
5159
5334
  },
5160
5335
  d
5161
5336
  )) }),
5162
- /* @__PURE__ */ (0, import_jsx_runtime53.jsx)("div", { className: (0, import_clsx35.default)("grid grid-cols-7"), children: Array.from({ length: totalCells }).map((_, i) => {
5337
+ /* @__PURE__ */ (0, import_jsx_runtime60.jsx)("div", { className: (0, import_clsx38.default)("grid grid-cols-7"), children: Array.from({ length: totalCells }).map((_, i) => {
5163
5338
  const day = i - emptyCells + 1;
5164
5339
  const date = month.date.with({ day: 1 }).add({
5165
5340
  days: i - emptyCells
@@ -5173,7 +5348,7 @@ function CalendarPane({
5173
5348
  const hoverDateIsAfterPendingFrom = hoveredDate && pendingFrom && import_polyfill.Temporal.PlainDate.compare(hoveredDate, pendingFrom) >= 0;
5174
5349
  const isRangeStart = mode === "single" && disableRange ? false : !pendingFrom && isInMonth && fromDate && date.equals(fromDate) || hoverDateIsAfterPendingFrom && date.equals(pendingFrom);
5175
5350
  const isRangeEnd = mode === "single" && disableRange ? false : !pendingFrom && isInMonth && toDate && date.equals(toDate) || hoverDateIsBeforePendingFrom && date.equals(pendingFrom);
5176
- return /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5351
+ return /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
5177
5352
  DateCell,
5178
5353
  {
5179
5354
  id: id ? `${id}-date-${date.toString()}` : void 0,
@@ -5198,10 +5373,10 @@ function CalendarPane({
5198
5373
  ]
5199
5374
  }
5200
5375
  ),
5201
- mode === "double" && idx === 0 && /* @__PURE__ */ (0, import_jsx_runtime53.jsx)(
5376
+ mode === "double" && idx === 0 && /* @__PURE__ */ (0, import_jsx_runtime60.jsx)(
5202
5377
  "div",
5203
5378
  {
5204
- className: (0, import_clsx35.default)(
5379
+ className: (0, import_clsx38.default)(
5205
5380
  "self-stretch bg-border-primary-normal rounded-base",
5206
5381
  // 1px width, full height, matches Figma divider
5207
5382
  "w-px"
@@ -5212,7 +5387,7 @@ function CalendarPane({
5212
5387
  }
5213
5388
 
5214
5389
  // src/components/DateRangeInput.tsx
5215
- var import_jsx_runtime54 = require("react/jsx-runtime");
5390
+ var import_jsx_runtime61 = require("react/jsx-runtime");
5216
5391
  var DateRangeInput = (_a) => {
5217
5392
  var _b = _a, {
5218
5393
  id,
@@ -5237,24 +5412,24 @@ var DateRangeInput = (_a) => {
5237
5412
  "disableRange",
5238
5413
  "label"
5239
5414
  ]);
5240
- const [visible, setVisible] = (0, import_react34.useState)(false);
5241
- const [inputValue, setInputValue] = (0, import_react34.useState)("");
5242
- const [isTyping, setIsTyping] = (0, import_react34.useState)(false);
5243
- const popoverRef = (0, import_react34.useRef)(null);
5244
- const rootRef = (0, import_react34.useRef)(null);
5245
- const triggerRef = (0, import_react34.useRef)(null);
5246
- const [calendarPosition, setCalendarPosition] = (0, import_react34.useState)({
5415
+ const [visible, setVisible] = (0, import_react38.useState)(false);
5416
+ const [inputValue, setInputValue] = (0, import_react38.useState)("");
5417
+ const [isTyping, setIsTyping] = (0, import_react38.useState)(false);
5418
+ const popoverRef = (0, import_react38.useRef)(null);
5419
+ const rootRef = (0, import_react38.useRef)(null);
5420
+ const triggerRef = (0, import_react38.useRef)(null);
5421
+ const [calendarPosition, setCalendarPosition] = (0, import_react38.useState)({
5247
5422
  top: 0,
5248
5423
  left: 0,
5249
5424
  width: 0
5250
5425
  });
5251
5426
  const [from, to] = value.split("|");
5252
- (0, import_react34.useEffect)(() => {
5427
+ (0, import_react38.useEffect)(() => {
5253
5428
  if (!isTyping) {
5254
5429
  setInputValue(formatDisplayValue(from, to));
5255
5430
  }
5256
5431
  }, [from, to, isTyping, disableRange]);
5257
- (0, import_react34.useLayoutEffect)(() => {
5432
+ (0, import_react38.useLayoutEffect)(() => {
5258
5433
  if (visible) {
5259
5434
  updatePosition();
5260
5435
  }
@@ -5269,7 +5444,7 @@ var DateRangeInput = (_a) => {
5269
5444
  });
5270
5445
  }
5271
5446
  };
5272
- (0, import_react34.useEffect)(() => {
5447
+ (0, import_react38.useEffect)(() => {
5273
5448
  updatePosition();
5274
5449
  const resizeObserver = new ResizeObserver(updatePosition);
5275
5450
  if (triggerRef.current) {
@@ -5281,7 +5456,7 @@ var DateRangeInput = (_a) => {
5281
5456
  window.removeEventListener("scroll", updatePosition);
5282
5457
  };
5283
5458
  }, []);
5284
- (0, import_react34.useEffect)(() => {
5459
+ (0, import_react38.useEffect)(() => {
5285
5460
  const handleKeyDown2 = (event) => {
5286
5461
  var _a2;
5287
5462
  if (event.key === "Escape" && popoverRef.current) {
@@ -5294,7 +5469,7 @@ var DateRangeInput = (_a) => {
5294
5469
  document.removeEventListener("keydown", handleKeyDown2);
5295
5470
  };
5296
5471
  }, []);
5297
- (0, import_react34.useEffect)(() => {
5472
+ (0, import_react38.useEffect)(() => {
5298
5473
  const handleClickOutside = (event) => {
5299
5474
  if (popoverRef.current && !popoverRef.current.contains(event.target) && triggerRef.current && !triggerRef.current.contains(event.target)) {
5300
5475
  setVisible(false);
@@ -5629,8 +5804,8 @@ var DateRangeInput = (_a) => {
5629
5804
  }
5630
5805
  }
5631
5806
  };
5632
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(import_jsx_runtime54.Fragment, { children: [
5633
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
5807
+ return /* @__PURE__ */ (0, import_jsx_runtime61.jsxs)(import_jsx_runtime61.Fragment, { children: [
5808
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
5634
5809
  InputBase,
5635
5810
  __spreadProps(__spreadValues({
5636
5811
  id,
@@ -5644,7 +5819,7 @@ var DateRangeInput = (_a) => {
5644
5819
  placeholder: disableRange ? "MM/DD/YYYY" : placeholder,
5645
5820
  disabled,
5646
5821
  readOnly,
5647
- after: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(Icon, { name: "calendar_month" }),
5822
+ after: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(Icon, { name: "calendar_month" }),
5648
5823
  onFocus: handleFocus,
5649
5824
  onClick: handleClick,
5650
5825
  onChange: handleInputChange,
@@ -5655,7 +5830,7 @@ var DateRangeInput = (_a) => {
5655
5830
  })
5656
5831
  ),
5657
5832
  visible && !readOnly && (0, import_react_dom4.createPortal)(
5658
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
5833
+ /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
5659
5834
  "div",
5660
5835
  {
5661
5836
  ref: (el) => {
@@ -5667,7 +5842,7 @@ var DateRangeInput = (_a) => {
5667
5842
  left: `${calendarPosition.left}px`,
5668
5843
  minWidth: `${calendarPosition.width}px`
5669
5844
  },
5670
- children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
5845
+ children: /* @__PURE__ */ (0, import_jsx_runtime61.jsx)(
5671
5846
  CalendarRange,
5672
5847
  {
5673
5848
  id: id ? `${id}-calendar` : void 0,