@dmsi/wedgekit-react 0.0.369 → 0.0.371

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 (205) hide show
  1. package/dist/{chunk-RLLQRVM7.js → chunk-2H35FETR.js} +18 -10
  2. package/dist/chunk-2IKT6IHB.js +190 -0
  3. package/dist/chunk-4UNWXB4A.js +89 -0
  4. package/dist/chunk-5IFPG6TS.js +17 -0
  5. package/dist/{chunk-6GAYJCFE.js → chunk-6DPFKSCT.js} +1 -1
  6. package/dist/{chunk-ZFOANBWG.js → chunk-AG43RS4Q.js} +2 -1
  7. package/dist/chunk-AJ5M6MVX.js +7 -0
  8. package/dist/chunk-AT4AWD6B.js +44 -0
  9. package/dist/chunk-BQNPOGD5.js +105 -0
  10. package/dist/chunk-CQFPNZTN.js +172 -0
  11. package/dist/chunk-EJSPFQCY.js +29 -0
  12. package/dist/chunk-ER6RCOH3.js +97 -0
  13. package/dist/{chunk-4VER5OEU.js → chunk-FBE2HGEF.js} +35 -11
  14. package/dist/chunk-HPQWEZJL.js +45 -0
  15. package/dist/{chunk-URCLLHO5.js → chunk-IBX6DVHU.js} +376 -102
  16. package/dist/{chunk-I3WFZOFY.js → chunk-J5V2JRIK.js} +1 -1
  17. package/dist/chunk-JGJUVJKD.js +283 -0
  18. package/dist/chunk-KEMCFN4U.js +78 -0
  19. package/dist/chunk-M6TSTDNZ.js +22 -0
  20. package/dist/chunk-M7INAUAJ.js +140 -0
  21. package/dist/chunk-MBZ55T2D.js +51 -0
  22. package/dist/chunk-N6PNLLNS.js +77 -0
  23. package/dist/{chunk-ZA5E7ZYM.js → chunk-NXGUDYRR.js} +1 -1
  24. package/dist/chunk-P36QKH26.js +143 -0
  25. package/dist/chunk-PTRZHGHA.js +89 -0
  26. package/dist/chunk-QVWYTQKL.js +29 -0
  27. package/dist/{chunk-6CPGOW6J.js → chunk-T36HX6QY.js} +6 -4
  28. package/dist/chunk-U6PUOGG4.js +114 -0
  29. package/dist/{chunk-NQXZBWDZ.js → chunk-V6U7LU6M.js} +15 -6
  30. package/dist/chunk-VJVY6NPF.js +32 -0
  31. package/dist/chunk-VVXPGI2P.js +61 -0
  32. package/dist/{chunk-ARQBSR3I.js → chunk-YCKRVNJ3.js} +4 -4
  33. package/dist/chunk-YYHQLQDQ.js +68 -0
  34. package/dist/components/Accordion.cjs +47 -14
  35. package/dist/components/Accordion.js +2 -2
  36. package/dist/components/CalendarRange.cjs +700 -46
  37. package/dist/components/CalendarRange.css +186 -3
  38. package/dist/components/CalendarRange.js +43 -11
  39. package/dist/components/CompactImagesPreview.cjs +485 -0
  40. package/dist/components/CompactImagesPreview.js +13 -0
  41. package/dist/components/ContentTabs.cjs +3 -2
  42. package/dist/components/ContentTabs.js +3 -2
  43. package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.cjs +4687 -0
  44. package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.css +5051 -0
  45. package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.js +62 -0
  46. package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.cjs +4687 -0
  47. package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.css +5051 -0
  48. package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.js +62 -0
  49. package/dist/components/DataGrid/PinnedColumns.cjs +4687 -0
  50. package/dist/components/DataGrid/PinnedColumns.css +5051 -0
  51. package/dist/components/DataGrid/PinnedColumns.js +62 -0
  52. package/dist/components/DataGrid/TableBody/LoadingCell.cjs +4689 -0
  53. package/dist/components/DataGrid/TableBody/LoadingCell.css +5051 -0
  54. package/dist/components/DataGrid/TableBody/LoadingCell.js +62 -0
  55. package/dist/components/DataGrid/TableBody/TableBodyRow.cjs +4689 -0
  56. package/dist/components/DataGrid/TableBody/TableBodyRow.css +5051 -0
  57. package/dist/components/DataGrid/TableBody/TableBodyRow.js +62 -0
  58. package/dist/components/DataGrid/TableBody/index.cjs +4689 -0
  59. package/dist/components/DataGrid/TableBody/index.css +5051 -0
  60. package/dist/components/DataGrid/TableBody/index.js +62 -0
  61. package/dist/components/DataGrid/index.cjs +4692 -0
  62. package/dist/components/DataGrid/index.css +5051 -0
  63. package/dist/components/DataGrid/index.js +65 -0
  64. package/dist/components/DataGrid/utils.cjs +4687 -0
  65. package/dist/components/DataGrid/utils.css +5051 -0
  66. package/dist/components/DataGrid/utils.js +62 -0
  67. package/dist/components/DataGridCell.js +6 -6
  68. package/dist/components/DateInput.cjs +721 -67
  69. package/dist/components/DateInput.css +186 -3
  70. package/dist/components/DateInput.js +45 -13
  71. package/dist/components/DateRangeInput.cjs +721 -67
  72. package/dist/components/DateRangeInput.css +186 -3
  73. package/dist/components/DateRangeInput.js +45 -13
  74. package/dist/components/FilterGroup.js +3 -3
  75. package/dist/components/Grid.cjs +3 -1
  76. package/dist/components/Grid.js +3 -92
  77. package/dist/components/ImagePlaceholder.cjs +65 -0
  78. package/dist/components/ImagePlaceholder.js +7 -0
  79. package/dist/components/Input.js +2 -2
  80. package/dist/components/MenuOption.js +2 -2
  81. package/dist/components/MobileDataGrid/ColumnList.cjs +845 -0
  82. package/dist/components/MobileDataGrid/ColumnList.js +17 -0
  83. package/dist/components/MobileDataGrid/ColumnSelector/index.cjs +4797 -0
  84. package/dist/components/MobileDataGrid/ColumnSelector/index.css +5051 -0
  85. package/dist/components/MobileDataGrid/ColumnSelector/index.js +62 -0
  86. package/dist/components/MobileDataGrid/GridContextProvider/GridContext.cjs +31 -0
  87. package/dist/components/MobileDataGrid/GridContextProvider/GridContext.js +7 -0
  88. package/dist/components/MobileDataGrid/GridContextProvider/index.cjs +177 -0
  89. package/dist/components/MobileDataGrid/GridContextProvider/index.js +8 -0
  90. package/dist/components/MobileDataGrid/MobileDataGridCard/MobileDataGridColumn.cjs +269 -0
  91. package/dist/components/MobileDataGrid/MobileDataGridCard/MobileDataGridColumn.js +9 -0
  92. package/dist/components/MobileDataGrid/MobileDataGridCard/index.cjs +790 -0
  93. package/dist/components/MobileDataGrid/MobileDataGridCard/index.js +16 -0
  94. package/dist/components/MobileDataGrid/MobileDataGridHeader.cjs +5059 -0
  95. package/dist/components/MobileDataGrid/MobileDataGridHeader.css +5051 -0
  96. package/dist/components/MobileDataGrid/MobileDataGridHeader.js +62 -0
  97. package/dist/components/MobileDataGrid/RowDetailModalProvider/ModalContent.cjs +509 -0
  98. package/dist/components/MobileDataGrid/RowDetailModalProvider/ModalContent.js +13 -0
  99. package/dist/components/MobileDataGrid/RowDetailModalProvider/index.cjs +1261 -0
  100. package/dist/components/MobileDataGrid/RowDetailModalProvider/index.js +27 -0
  101. package/dist/components/MobileDataGrid/index.cjs +5521 -0
  102. package/dist/components/MobileDataGrid/index.css +5051 -0
  103. package/dist/components/MobileDataGrid/index.js +62 -0
  104. package/dist/components/Modal.cjs +24 -13
  105. package/dist/components/Modal.js +3 -3
  106. package/dist/components/ModalHeader.cjs +6 -4
  107. package/dist/components/ModalHeader.js +1 -1
  108. package/dist/components/ModalScrim.cjs +2 -1
  109. package/dist/components/ModalScrim.js +1 -1
  110. package/dist/components/NestedMenu.js +4 -4
  111. package/dist/components/Notification.cjs +15 -6
  112. package/dist/components/Notification.js +1 -1
  113. package/dist/components/PDFViewer/DownloadIcon.cjs +394 -0
  114. package/dist/components/PDFViewer/DownloadIcon.js +10 -0
  115. package/dist/components/PDFViewer/PDFElement.cjs +515 -0
  116. package/dist/components/PDFViewer/PDFElement.js +11 -0
  117. package/dist/components/{MobileDataGrid.cjs → PDFViewer/PDFNavigation.cjs} +318 -402
  118. package/dist/components/PDFViewer/PDFNavigation.js +13 -0
  119. package/dist/components/PDFViewer/PDFPage.cjs +56 -0
  120. package/dist/components/PDFViewer/PDFPage.js +7 -0
  121. package/dist/components/{PDFViewer.cjs → PDFViewer/index.cjs} +290 -202
  122. package/dist/components/PDFViewer/index.js +29 -0
  123. package/dist/components/Password.js +2 -2
  124. package/dist/components/ProductImagePreview/CarouselPagination.cjs +75 -0
  125. package/dist/components/ProductImagePreview/CarouselPagination.js +7 -0
  126. package/dist/components/ProductImagePreview/MobileImageCarousel.cjs +214 -0
  127. package/dist/components/ProductImagePreview/MobileImageCarousel.js +7 -0
  128. package/dist/components/ProductImagePreview/ProductPrimaryImage.cjs +255 -0
  129. package/dist/components/ProductImagePreview/ProductPrimaryImage.js +9 -0
  130. package/dist/components/ProductImagePreview/Thumbnail.cjs +105 -0
  131. package/dist/components/ProductImagePreview/Thumbnail.js +8 -0
  132. package/dist/components/ProductImagePreview/ZoomWindow.cjs +198 -0
  133. package/dist/components/ProductImagePreview/ZoomWindow.js +8 -0
  134. package/dist/components/ProductImagePreview/index.cjs +1369 -0
  135. package/dist/components/ProductImagePreview/index.js +22 -0
  136. package/dist/components/Search.js +3 -3
  137. package/dist/components/Select.js +3 -3
  138. package/dist/components/SideMenuGroup.cjs +15 -6
  139. package/dist/components/SideMenuGroup.js +1 -1
  140. package/dist/components/SideMenuItem.cjs +15 -6
  141. package/dist/components/SideMenuItem.js +1 -1
  142. package/dist/components/SkeletonParagraph.cjs +33 -0
  143. package/dist/components/SkeletonParagraph.js +10 -0
  144. package/dist/components/Stack.cjs +15 -6
  145. package/dist/components/Stack.js +1 -1
  146. package/dist/components/Stepper.cjs +61 -53
  147. package/dist/components/Stepper.js +63 -55
  148. package/dist/components/Surface.js +3 -39
  149. package/dist/components/Swatch.cjs +15 -6
  150. package/dist/components/Swatch.js +4 -4
  151. package/dist/components/Time.cjs +15 -6
  152. package/dist/components/Time.js +5 -5
  153. package/dist/components/Upload.cjs +15 -6
  154. package/dist/components/Upload.js +1 -1
  155. package/dist/components/index.cjs +2559 -14
  156. package/dist/components/index.css +186 -3
  157. package/dist/components/index.js +57 -14
  158. package/dist/index.css +186 -3
  159. package/package.json +1 -1
  160. package/src/components/Accordion.tsx +23 -4
  161. package/src/components/CompactImagesPreview.tsx +99 -0
  162. package/src/components/ContentTabs.tsx +3 -1
  163. package/src/components/DataGrid/types.ts +5 -0
  164. package/src/components/Grid.tsx +2 -0
  165. package/src/components/ImagePlaceholder.tsx +22 -0
  166. package/src/components/MobileDataGrid/ColumnList.tsx +66 -0
  167. package/src/components/MobileDataGrid/ColumnSelector/index.tsx +97 -0
  168. package/src/components/MobileDataGrid/GridContextProvider/GridContext.tsx +25 -0
  169. package/src/components/MobileDataGrid/GridContextProvider/index.tsx +132 -0
  170. package/src/components/MobileDataGrid/GridContextProvider/useGridContext.ts +10 -0
  171. package/src/components/MobileDataGrid/MobileDataGridCard/MobileDataGridColumn.tsx +20 -0
  172. package/src/components/MobileDataGrid/MobileDataGridCard/index.tsx +129 -0
  173. package/src/components/MobileDataGrid/MobileDataGridHeader.tsx +80 -0
  174. package/src/components/MobileDataGrid/RowDetailModalProvider/ModalContent.tsx +42 -0
  175. package/src/components/MobileDataGrid/RowDetailModalProvider/index.tsx +68 -0
  176. package/src/components/MobileDataGrid/dataGridReducer.ts +55 -0
  177. package/src/components/MobileDataGrid/index.tsx +92 -0
  178. package/src/components/MobileDataGrid/types.ts +4 -0
  179. package/src/components/Modal.tsx +31 -12
  180. package/src/components/ModalButtons.tsx +1 -1
  181. package/src/components/ModalHeader.tsx +5 -2
  182. package/src/components/ModalScrim.tsx +3 -2
  183. package/src/components/PDFViewer/DownloadIcon.tsx +22 -0
  184. package/src/components/PDFViewer/PDFElement.tsx +90 -0
  185. package/src/components/PDFViewer/PDFNavigation.tsx +68 -0
  186. package/src/components/PDFViewer/PDFPage.tsx +34 -0
  187. package/src/components/PDFViewer/index.tsx +128 -0
  188. package/src/components/ProductImagePreview/CarouselPagination.tsx +54 -0
  189. package/src/components/ProductImagePreview/MobileImageCarousel.tsx +226 -0
  190. package/src/components/ProductImagePreview/ProductPrimaryImage.tsx +218 -0
  191. package/src/components/ProductImagePreview/Thumbnail.tsx +49 -0
  192. package/src/components/ProductImagePreview/ZoomWindow.tsx +136 -0
  193. package/src/components/ProductImagePreview/index.tsx +182 -0
  194. package/src/components/ProductImagePreview/useProductImagePreview.ts +211 -0
  195. package/src/components/SkeletonParagraph.tsx +5 -0
  196. package/src/components/Stack.tsx +29 -6
  197. package/src/components/Stepper.tsx +5 -1
  198. package/src/components/index.ts +4 -0
  199. package/src/types.ts +2 -1
  200. package/dist/components/MobileDataGrid.js +0 -150
  201. package/dist/components/PDFViewer.js +0 -250
  202. package/src/components/MobileDataGrid.tsx +0 -163
  203. package/src/components/PDFViewer.tsx +0 -264
  204. package/dist/{chunk-OXSBIBGT.js → chunk-CKQNJNU3.js} +3 -3
  205. package/dist/{chunk-RJUN52HJ.js → chunk-ZL5X7KP6.js} +3 -3
@@ -62,8 +62,8 @@ __export(DateInput_exports, {
62
62
  DateInput: () => DateInput
63
63
  });
64
64
  module.exports = __toCommonJS(DateInput_exports);
65
- var import_react20 = require("react");
66
- var import_react_dom3 = require("react-dom");
65
+ var import_react36 = require("react");
66
+ var import_react_dom4 = require("react-dom");
67
67
 
68
68
  // src/components/Input.tsx
69
69
  var import_react = require("react");
@@ -716,8 +716,8 @@ Currency.displayName = "Currency";
716
716
  Percentage.displayName = "Percentage";
717
717
 
718
718
  // src/components/CalendarRange.tsx
719
- var import_clsx22 = __toESM(require("clsx"), 1);
720
- var import_react19 = __toESM(require("react"), 1);
719
+ var import_clsx35 = __toESM(require("clsx"), 1);
720
+ var import_react35 = __toESM(require("react"), 1);
721
721
  var import_polyfill = require("@js-temporal/polyfill");
722
722
 
723
723
  // src/components/DataGridCell.tsx
@@ -4107,8 +4107,662 @@ var import_jsx_runtime23 = require("react/jsx-runtime");
4107
4107
  // src/components/Accordion.tsx
4108
4108
  var import_jsx_runtime24 = require("react/jsx-runtime");
4109
4109
 
4110
- // src/components/CalendarRange.tsx
4110
+ // src/components/Heading.tsx
4111
+ var import_clsx22 = __toESM(require("clsx"), 1);
4111
4112
  var import_jsx_runtime25 = require("react/jsx-runtime");
4113
+ var Heading = (_a) => {
4114
+ var _b = _a, {
4115
+ className,
4116
+ children,
4117
+ as,
4118
+ color,
4119
+ align,
4120
+ variant = "heading1",
4121
+ id,
4122
+ testid
4123
+ } = _b, props = __objRest(_b, [
4124
+ "className",
4125
+ "children",
4126
+ "as",
4127
+ "color",
4128
+ "align",
4129
+ "variant",
4130
+ "id",
4131
+ "testid"
4132
+ ]);
4133
+ const defaultElement = variant === "heading1" ? "h1" : variant === "heading2" ? "h2" : "h3";
4134
+ const Element = as != null ? as : defaultElement;
4135
+ return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
4136
+ Element,
4137
+ __spreadProps(__spreadValues({
4138
+ id,
4139
+ "data-testid": testid,
4140
+ className: (0, import_clsx22.default)(
4141
+ typography[variant],
4142
+ className,
4143
+ align === "left" && "text-left",
4144
+ align === "center" && "text-center",
4145
+ align === "right" && "text-right"
4146
+ ),
4147
+ style: __spreadProps(__spreadValues({}, props.style), {
4148
+ color: color ? `var(--color-${color})` : void 0
4149
+ })
4150
+ }, props), {
4151
+ children
4152
+ })
4153
+ );
4154
+ };
4155
+ Heading.displayName = "Heading";
4156
+ var Heading1 = (props) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Heading, __spreadProps(__spreadValues({}, props), { variant: "heading1" }));
4157
+ var Heading2 = (props) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Heading, __spreadProps(__spreadValues({}, props), { variant: "heading2" }));
4158
+ var Heading3 = (props) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Heading, __spreadProps(__spreadValues({}, props), { variant: "heading3" }));
4159
+ Heading1.displayName = "Heading1";
4160
+ Heading2.displayName = "Heading2";
4161
+ Heading3.displayName = "Heading3";
4162
+
4163
+ // src/components/Theme.tsx
4164
+ var import_jsx_runtime26 = require("react/jsx-runtime");
4165
+
4166
+ // src/components/MobileDataGrid/ColumnSelector/index.tsx
4167
+ var import_react21 = require("react");
4168
+
4169
+ // src/components/MobileDataGrid/GridContextProvider/useGridContext.ts
4170
+ var import_react20 = require("react");
4171
+
4172
+ // src/components/MobileDataGrid/GridContextProvider/GridContext.tsx
4173
+ var import_react19 = require("react");
4174
+ var GridContext = (0, import_react19.createContext)(null);
4175
+
4176
+ // src/components/MobileDataGrid/ColumnSelector/index.tsx
4177
+ var import_jsx_runtime27 = require("react/jsx-runtime");
4178
+
4179
+ // src/components/MobileDataGrid/MobileDataGridHeader.tsx
4180
+ var import_jsx_runtime28 = require("react/jsx-runtime");
4181
+
4182
+ // src/components/MobileDataGrid/GridContextProvider/index.tsx
4183
+ var import_react22 = require("react");
4184
+ var import_jsx_runtime29 = require("react/jsx-runtime");
4185
+
4186
+ // src/components/Modal.tsx
4187
+ var import_clsx27 = __toESM(require("clsx"), 1);
4188
+ var import_react24 = require("react");
4189
+
4190
+ // src/components/ModalHeader.tsx
4191
+ var import_clsx23 = __toESM(require("clsx"), 1);
4192
+ var import_jsx_runtime30 = require("react/jsx-runtime");
4193
+ var ModalHeader = ({
4194
+ title,
4195
+ hideCloseIcon,
4196
+ headerIcon,
4197
+ headerIconAlign,
4198
+ onClose,
4199
+ id,
4200
+ testid,
4201
+ headerClassname
4202
+ }) => {
4203
+ return /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)(
4204
+ "div",
4205
+ {
4206
+ id,
4207
+ "data-testid": testid,
4208
+ className: (0, import_clsx23.default)(
4209
+ "flex justify-between items-center",
4210
+ headerIconAlign === "center" && "justify-center",
4211
+ headerIconAlign === "right" && "justify-end",
4212
+ headerIconAlign === "left" && "justify-start",
4213
+ layoutPaddding,
4214
+ layoutGroupGap,
4215
+ headerClassname
4216
+ ),
4217
+ children: [
4218
+ /* @__PURE__ */ (0, import_jsx_runtime30.jsxs)("div", { className: (0, import_clsx23.default)("flex items-center flex-1", layoutGroupGap), children: [
4219
+ headerIcon,
4220
+ title && /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
4221
+ Heading2,
4222
+ {
4223
+ id: id ? `${id}-title` : void 0,
4224
+ testid: testid ? `${testid}-title` : void 0,
4225
+ as: "p",
4226
+ children: title
4227
+ }
4228
+ )
4229
+ ] }),
4230
+ !hideCloseIcon && /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(
4231
+ Button,
4232
+ {
4233
+ id: id ? `${id}-close-button` : void 0,
4234
+ testid: testid ? `${testid}-close-button` : void 0,
4235
+ iconOnly: true,
4236
+ variant: "tertiary",
4237
+ onClick: onClose,
4238
+ leftIcon: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)("span", { className: "text-brand-text-action-primary-normal desktop:text-icon-primary-normal contents", children: /* @__PURE__ */ (0, import_jsx_runtime30.jsx)(Icon, { name: "close", size: 24 }) })
4239
+ }
4240
+ )
4241
+ ]
4242
+ }
4243
+ );
4244
+ };
4245
+ ModalHeader.displayName = "ModalHeader";
4246
+
4247
+ // src/components/ModalContent.tsx
4248
+ var import_clsx24 = __toESM(require("clsx"), 1);
4249
+ var import_jsx_runtime31 = require("react/jsx-runtime");
4250
+ function ModalContent({
4251
+ fixedHeightScrolling,
4252
+ children,
4253
+ id,
4254
+ testid
4255
+ }) {
4256
+ return /* @__PURE__ */ (0, import_jsx_runtime31.jsx)(
4257
+ "div",
4258
+ {
4259
+ id,
4260
+ "data-testid": testid,
4261
+ className: (0, import_clsx24.default)(
4262
+ "flex-grow desktop:flex-grow-0",
4263
+ layoutPaddding,
4264
+ fixedHeightScrolling && "overflow-auto"
4265
+ ),
4266
+ children
4267
+ }
4268
+ );
4269
+ }
4270
+ ModalContent.displayName = "ModalContent";
4271
+
4272
+ // src/components/ModalButtons.tsx
4273
+ var import_clsx25 = __toESM(require("clsx"), 1);
4274
+ var import_jsx_runtime32 = require("react/jsx-runtime");
4275
+ var ModalButtons = ({
4276
+ onClose,
4277
+ onContinue,
4278
+ customActions,
4279
+ id,
4280
+ testid
4281
+ }) => {
4282
+ return /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
4283
+ "div",
4284
+ {
4285
+ id,
4286
+ "data-testid": testid,
4287
+ className: (0, import_clsx25.default)(
4288
+ "border-t border-neutral-300 flex justify-end",
4289
+ layoutPaddding,
4290
+ layoutGroupGap
4291
+ ),
4292
+ children: customActions != null ? customActions : /* @__PURE__ */ (0, import_jsx_runtime32.jsxs)(import_jsx_runtime32.Fragment, { children: [
4293
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
4294
+ Button,
4295
+ {
4296
+ id: id ? `${id}-close-button` : void 0,
4297
+ testid: testid ? `${testid}-close-button` : void 0,
4298
+ variant: "secondary",
4299
+ leftIcon: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(Icon, { name: "close", size: 24 }),
4300
+ onClick: onClose,
4301
+ className: "max-sm:w-full",
4302
+ children: "Close"
4303
+ }
4304
+ ),
4305
+ /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(
4306
+ Button,
4307
+ {
4308
+ id: id ? `${id}-continue-button` : void 0,
4309
+ testid: testid ? `${testid}-continue-button` : void 0,
4310
+ variant: "primary",
4311
+ leftIcon: /* @__PURE__ */ (0, import_jsx_runtime32.jsx)(Icon, { name: "check", size: 24 }),
4312
+ className: "max-sm:w-full",
4313
+ onClick: onContinue,
4314
+ children: "Continue"
4315
+ }
4316
+ )
4317
+ ] })
4318
+ }
4319
+ );
4320
+ };
4321
+ ModalButtons.displayName = "ModalButtons";
4322
+
4323
+ // src/components/ModalScrim.tsx
4324
+ var import_clsx26 = __toESM(require("clsx"), 1);
4325
+ var import_jsx_runtime33 = require("react/jsx-runtime");
4326
+ var ModalScrim = ({
4327
+ show = false,
4328
+ size = "small",
4329
+ children,
4330
+ onClick,
4331
+ ref,
4332
+ id,
4333
+ testid
4334
+ }) => {
4335
+ return /* @__PURE__ */ (0, import_jsx_runtime33.jsx)(
4336
+ "div",
4337
+ {
4338
+ id,
4339
+ "data-testid": testid,
4340
+ className: (0, import_clsx26.default)(
4341
+ "overflow-y-auto h-screen transition-[visibility,opacity,background] ease-in-out duration-100 grid place-content-center group bg-neutral-600/50 fixed opacity-0",
4342
+ !show && " pointer-events-none",
4343
+ size === "small" && "p-4",
4344
+ size === "screen" ? "desktop:p-0" : "desktop:p-4",
4345
+ "inset-0 z-50"
4346
+ ),
4347
+ onMouseDown: onClick,
4348
+ ref,
4349
+ children
4350
+ }
4351
+ );
4352
+ };
4353
+ ModalScrim.displayName = "ModalScrim";
4354
+
4355
+ // src/components/Modal.tsx
4356
+ var import_react_dom3 = require("react-dom");
4357
+ var import_react_use = require("react-use");
4358
+
4359
+ // src/components/useMounted.tsx
4360
+ var import_react23 = require("react");
4361
+ var useMounted = () => {
4362
+ const [isMounted, setIsMounted] = (0, import_react23.useState)(false);
4363
+ (0, import_react23.useEffect)(() => {
4364
+ setIsMounted(true);
4365
+ return () => setIsMounted(false);
4366
+ }, []);
4367
+ return isMounted;
4368
+ };
4369
+
4370
+ // src/components/Modal.tsx
4371
+ var import_jsx_runtime34 = require("react/jsx-runtime");
4372
+ var fadeInScale = (element, duration = 300) => element.animate(
4373
+ [
4374
+ { opacity: 0, transform: "scale(0.95)" },
4375
+ { opacity: 1, transform: "scale(1)" }
4376
+ ],
4377
+ {
4378
+ duration,
4379
+ easing: "cubic-bezier(0.4, 0, 0.2, 1)",
4380
+ fill: "both"
4381
+ }
4382
+ );
4383
+ var fadeOutScale = (element, duration = 200) => element.animate(
4384
+ [
4385
+ { opacity: 1, transform: "scale(1)" },
4386
+ { opacity: 0, transform: "scale(0.95)" }
4387
+ ],
4388
+ {
4389
+ duration,
4390
+ easing: "ease-in-out",
4391
+ fill: "both"
4392
+ }
4393
+ );
4394
+ var bgFadeIn = (element, duration = 300) => element.animate([{ opacity: 0 }, { opacity: 1 }], {
4395
+ duration,
4396
+ easing: "cubic-bezier(0.4, 0, 0.2, 1)",
4397
+ fill: "both"
4398
+ });
4399
+ var bgFadeOut = (element, duration = 200) => element.animate([{ opacity: 1 }, { opacity: 0 }], {
4400
+ duration,
4401
+ easing: "ease-in-out",
4402
+ fill: "both"
4403
+ });
4404
+ var whenAllAnimationsFinish = (animations, callback) => {
4405
+ let finishedCount = 0;
4406
+ animations.forEach((animation) => {
4407
+ animation.onfinish = () => {
4408
+ finishedCount += 1;
4409
+ if (finishedCount === animations.length) {
4410
+ callback();
4411
+ }
4412
+ };
4413
+ });
4414
+ };
4415
+ var sizes = {
4416
+ small: {
4417
+ sizeClass: "max-h-screen desktop:max-w-120 rounded-sm"
4418
+ },
4419
+ medium: {
4420
+ sizeClass: "desktop:max-w-180 w-screen desktop:h-fit h-screen desktop:w-full max-w-240"
4421
+ },
4422
+ large: {
4423
+ sizeClass: "desktop:max-w-240 w-screen desktop:h-fit h-screen desktop:w-full max-w-240"
4424
+ },
4425
+ "x-large": {
4426
+ sizeClass: "desktop:max-w-300 w-screen desktop:h-fit h-screen desktop:w-full max-w-240"
4427
+ },
4428
+ screen: {
4429
+ sizeClass: "w-screen h-screen max-w-screen !rounded-none"
4430
+ }
4431
+ };
4432
+ var Modal = ({
4433
+ id,
4434
+ testid,
4435
+ title,
4436
+ open = false,
4437
+ size = "small",
4438
+ className,
4439
+ children,
4440
+ onClose,
4441
+ onContinue,
4442
+ closeOnBackdropClick = true,
4443
+ showButtons = false,
4444
+ hideCloseIcon = false,
4445
+ headerIcon,
4446
+ headerIconAlign,
4447
+ fixedHeightScrolling = false,
4448
+ customActions,
4449
+ headerClassname,
4450
+ customFooter,
4451
+ noWrapper
4452
+ }) => {
4453
+ var _a;
4454
+ const mounted = useMounted();
4455
+ const modalRef = (0, import_react24.useRef)(null);
4456
+ const bgRef = (0, import_react24.useRef)(null);
4457
+ const wasOpen = (0, import_react_use.usePrevious)(open);
4458
+ const isMobile = useMatchesMobile();
4459
+ const computedFixedHeightScrolling = isMobile || fixedHeightScrolling;
4460
+ (0, import_react24.useEffect)(() => {
4461
+ if (!mounted) return;
4462
+ if (!modalRef.current || !bgRef.current) {
4463
+ console.error("Modal or background reference is not set.");
4464
+ return;
4465
+ }
4466
+ if (wasOpen === void 0) return;
4467
+ if (wasOpen && !open) {
4468
+ const modalAnimation = fadeOutScale(modalRef.current);
4469
+ const bgAnimation = bgFadeOut(bgRef.current);
4470
+ whenAllAnimationsFinish([modalAnimation, bgAnimation], () => {
4471
+ if (onClose) {
4472
+ onClose();
4473
+ }
4474
+ });
4475
+ } else if (!wasOpen && open) {
4476
+ fadeInScale(modalRef.current);
4477
+ bgFadeIn(bgRef.current);
4478
+ }
4479
+ }, [mounted, onClose, open, wasOpen]);
4480
+ const handleKeyDown = (0, import_react24.useCallback)(
4481
+ (e) => {
4482
+ if (e.key === "Escape") {
4483
+ if (onClose) {
4484
+ e.preventDefault();
4485
+ onClose();
4486
+ }
4487
+ }
4488
+ },
4489
+ [onClose]
4490
+ );
4491
+ const handleClose = (0, import_react24.useCallback)(() => {
4492
+ if (onClose) {
4493
+ onClose();
4494
+ }
4495
+ }, [onClose]);
4496
+ (0, import_react24.useEffect)(() => {
4497
+ if (open) {
4498
+ document.addEventListener("keyup", handleKeyDown);
4499
+ }
4500
+ return () => {
4501
+ document.removeEventListener("keyup", handleKeyDown);
4502
+ };
4503
+ }, [open, handleKeyDown]);
4504
+ (0, import_react24.useEffect)(() => {
4505
+ if (!open) return;
4506
+ const scrollY = window.scrollY;
4507
+ const body = document.body;
4508
+ body.style.position = "fixed";
4509
+ body.style.top = `-${scrollY}px`;
4510
+ body.style.left = "0";
4511
+ body.style.right = "0";
4512
+ body.style.overflow = "hidden";
4513
+ body.style.width = "100%";
4514
+ return () => {
4515
+ body.style.position = "";
4516
+ body.style.top = "";
4517
+ body.style.left = "";
4518
+ body.style.right = "";
4519
+ body.style.overflow = "";
4520
+ body.style.width = "";
4521
+ window.scrollTo(0, scrollY);
4522
+ };
4523
+ }, [open]);
4524
+ const { sizeClass } = (_a = sizes[size]) != null ? _a : sizes.small;
4525
+ const backgroundClickHandler = (0, import_react24.useCallback)(
4526
+ (e) => {
4527
+ const target = e.target;
4528
+ const currentTarget = e.currentTarget;
4529
+ if (currentTarget.contains(target) && currentTarget !== target) {
4530
+ e.stopPropagation();
4531
+ return;
4532
+ }
4533
+ if (open && closeOnBackdropClick) {
4534
+ handleClose();
4535
+ }
4536
+ },
4537
+ [open, closeOnBackdropClick, handleClose]
4538
+ );
4539
+ if (!mounted) {
4540
+ return null;
4541
+ }
4542
+ return (0, import_react_dom3.createPortal)(
4543
+ /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
4544
+ ModalScrim,
4545
+ {
4546
+ id: id ? `${id}-scrim` : void 0,
4547
+ testid: testid ? `${testid}-scrim` : void 0,
4548
+ size,
4549
+ ref: bgRef,
4550
+ show: open,
4551
+ onClick: backgroundClickHandler,
4552
+ children: /* @__PURE__ */ (0, import_jsx_runtime34.jsxs)(
4553
+ "div",
4554
+ {
4555
+ id,
4556
+ "data-testid": testid,
4557
+ ref: modalRef,
4558
+ className: (0, import_clsx27.default)(
4559
+ "shadow-md rounded-sm flex flex-col overflow-hidden w-full opacity-0 h-fit",
4560
+ computedFixedHeightScrolling && size !== "screen" && "desktop:max-h-[calc(100vh-32px)] desktop:h-auto",
4561
+ className,
4562
+ !(className == null ? void 0 : className.includes("bg-")) && "bg-white",
4563
+ sizeClass
4564
+ ),
4565
+ onClick: (e) => e.stopPropagation(),
4566
+ children: [
4567
+ /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
4568
+ ModalHeader,
4569
+ {
4570
+ id: id ? `${id}-header` : void 0,
4571
+ testid: testid ? `${testid}-header` : void 0,
4572
+ title,
4573
+ onClose: handleClose,
4574
+ hideCloseIcon,
4575
+ headerIcon,
4576
+ headerIconAlign,
4577
+ headerClassname
4578
+ }
4579
+ ),
4580
+ children && (size !== "screen" || noWrapper) ? /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
4581
+ ModalContent,
4582
+ {
4583
+ id: id ? `${id}-content` : void 0,
4584
+ testid: testid ? `${testid}-content` : void 0,
4585
+ fixedHeightScrolling: computedFixedHeightScrolling,
4586
+ children
4587
+ }
4588
+ ) : children,
4589
+ showButtons ? customFooter ? customActions : /* @__PURE__ */ (0, import_jsx_runtime34.jsx)(
4590
+ ModalButtons,
4591
+ {
4592
+ id: id ? `${id}-buttons` : void 0,
4593
+ testid: testid ? `${testid}-buttons` : void 0,
4594
+ onClose: handleClose,
4595
+ onContinue,
4596
+ customActions
4597
+ }
4598
+ ) : null
4599
+ ]
4600
+ }
4601
+ )
4602
+ }
4603
+ ),
4604
+ findDocumentRoot(bgRef.current)
4605
+ );
4606
+ };
4607
+ Modal.displayName = "Modal";
4608
+
4609
+ // src/components/MobileDataGrid/MobileDataGridCard/MobileDataGridColumn.tsx
4610
+ var import_jsx_runtime35 = require("react/jsx-runtime");
4611
+
4612
+ // src/components/MobileDataGrid/RowDetailModalProvider/ModalContent.tsx
4613
+ var import_jsx_runtime36 = require("react/jsx-runtime");
4614
+
4615
+ // src/components/MobileDataGrid/RowDetailModalProvider/index.tsx
4616
+ var import_jsx_runtime37 = require("react/jsx-runtime");
4617
+
4618
+ // src/components/MobileDataGrid/ColumnList.tsx
4619
+ var import_clsx29 = __toESM(require("clsx"), 1);
4620
+
4621
+ // src/components/MobileDataGrid/MobileDataGridCard/index.tsx
4622
+ var import_clsx28 = __toESM(require("clsx"), 1);
4623
+ var import_jsx_runtime38 = require("react/jsx-runtime");
4624
+
4625
+ // src/components/MobileDataGrid/ColumnList.tsx
4626
+ var import_jsx_runtime39 = require("react/jsx-runtime");
4627
+
4628
+ // src/components/MobileDataGrid/index.tsx
4629
+ var import_jsx_runtime40 = require("react/jsx-runtime");
4630
+
4631
+ // src/components/ImagePlaceholder.tsx
4632
+ var import_react25 = require("react");
4633
+ var import_jsx_runtime41 = require("react/jsx-runtime");
4634
+
4635
+ // src/components/ProductImagePreview/Thumbnail.tsx
4636
+ var import_jsx_runtime42 = require("react/jsx-runtime");
4637
+
4638
+ // src/components/Grid.tsx
4639
+ var import_react26 = require("react");
4640
+ var import_clsx30 = __toESM(require("clsx"), 1);
4641
+ var import_jsx_runtime43 = require("react/jsx-runtime");
4642
+
4643
+ // src/components/ProductImagePreview/ProductPrimaryImage.tsx
4644
+ var import_react27 = require("react");
4645
+
4646
+ // src/components/Spinner.tsx
4647
+ var import_jsx_runtime44 = require("react/jsx-runtime");
4648
+ var Spinner = ({ size = "small", testid }) => {
4649
+ const dimension = size === "large" ? 48 : 24;
4650
+ return /* @__PURE__ */ (0, import_jsx_runtime44.jsxs)(
4651
+ "svg",
4652
+ {
4653
+ "data-testid": testid,
4654
+ width: dimension,
4655
+ height: dimension,
4656
+ viewBox: "0 0 24 24",
4657
+ xmlns: "http://www.w3.org/2000/svg",
4658
+ fill: "#1D1E1E",
4659
+ className: "spinner",
4660
+ "aria-label": "Loading",
4661
+ children: [
4662
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("circle", { cx: "12", cy: "4", r: "2", opacity: "1" }),
4663
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("circle", { cx: "17.666", cy: "6.334", r: "2", opacity: "0.125" }),
4664
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("circle", { cx: "20", cy: "12", r: "2", opacity: "0.25" }),
4665
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("circle", { cx: "17.666", cy: "17.666", r: "2", opacity: "0.375" }),
4666
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("circle", { cx: "12", cy: "20", r: "2", opacity: "0.5" }),
4667
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("circle", { cx: "6.334", cy: "17.666", r: "2", opacity: "0.625" }),
4668
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("circle", { cx: "4", cy: "12", r: "2", opacity: "0.75" }),
4669
+ /* @__PURE__ */ (0, import_jsx_runtime44.jsx)("circle", { cx: "6.334", cy: "6.334", r: "2", opacity: "0.875" })
4670
+ ]
4671
+ }
4672
+ );
4673
+ };
4674
+ Spinner.displayName = "Spinner";
4675
+
4676
+ // src/components/ProductImagePreview/ProductPrimaryImage.tsx
4677
+ var import_jsx_runtime45 = require("react/jsx-runtime");
4678
+
4679
+ // src/components/ProductImagePreview/ZoomWindow.tsx
4680
+ var import_react28 = require("react");
4681
+
4682
+ // src/components/Surface.tsx
4683
+ var import_clsx31 = __toESM(require("clsx"), 1);
4684
+ var import_jsx_runtime46 = require("react/jsx-runtime");
4685
+ var Surface = (_a) => {
4686
+ var _b = _a, {
4687
+ children,
4688
+ className,
4689
+ elevation = 0,
4690
+ id
4691
+ } = _b, props = __objRest(_b, [
4692
+ "children",
4693
+ "className",
4694
+ "elevation",
4695
+ "id"
4696
+ ]);
4697
+ return /* @__PURE__ */ (0, import_jsx_runtime46.jsx)(
4698
+ "div",
4699
+ __spreadProps(__spreadValues({
4700
+ id,
4701
+ className: (0, import_clsx31.default)(
4702
+ "rounded-base",
4703
+ {
4704
+ "shadow-2": elevation === 2,
4705
+ "shadow-4": elevation === 4,
4706
+ "shadow-16": elevation === 16
4707
+ },
4708
+ className
4709
+ )
4710
+ }, props), {
4711
+ children
4712
+ })
4713
+ );
4714
+ };
4715
+ Surface.displayName = "Surface";
4716
+
4717
+ // src/components/ProductImagePreview/ZoomWindow.tsx
4718
+ var import_jsx_runtime47 = require("react/jsx-runtime");
4719
+
4720
+ // src/components/ProductImagePreview/CarouselPagination.tsx
4721
+ var import_clsx32 = require("clsx");
4722
+ var import_jsx_runtime48 = require("react/jsx-runtime");
4723
+
4724
+ // src/components/ProductImagePreview/MobileImageCarousel.tsx
4725
+ var import_react29 = require("react");
4726
+ var import_jsx_runtime49 = require("react/jsx-runtime");
4727
+
4728
+ // src/components/ProductImagePreview/useProductImagePreview.ts
4729
+ var import_react30 = require("react");
4730
+
4731
+ // src/components/ProductImagePreview/index.tsx
4732
+ var import_jsx_runtime50 = require("react/jsx-runtime");
4733
+
4734
+ // src/components/CompactImagesPreview.tsx
4735
+ var import_react31 = require("react");
4736
+ var import_clsx33 = __toESM(require("clsx"), 1);
4737
+ var import_jsx_runtime51 = require("react/jsx-runtime");
4738
+
4739
+ // src/components/PDFViewer/index.tsx
4740
+ var import_react34 = require("react");
4741
+
4742
+ // src/components/PDFViewer/PDFElement.tsx
4743
+ var import_react_pdf2 = require("@mikecousins/react-pdf");
4744
+ var import_react33 = require("react");
4745
+
4746
+ // src/components/PDFViewer/PDFPage.tsx
4747
+ var import_react_pdf = require("@mikecousins/react-pdf");
4748
+ var import_react32 = require("react");
4749
+ var import_jsx_runtime52 = require("react/jsx-runtime");
4750
+
4751
+ // src/components/PDFViewer/PDFElement.tsx
4752
+ var import_clsx34 = __toESM(require("clsx"), 1);
4753
+ var import_jsx_runtime53 = require("react/jsx-runtime");
4754
+
4755
+ // src/components/PDFViewer/DownloadIcon.tsx
4756
+ var import_jsx_runtime54 = require("react/jsx-runtime");
4757
+
4758
+ // src/components/PDFViewer/PDFNavigation.tsx
4759
+ var import_jsx_runtime55 = require("react/jsx-runtime");
4760
+
4761
+ // src/components/PDFViewer/index.tsx
4762
+ var import_jsx_runtime56 = require("react/jsx-runtime");
4763
+
4764
+ // src/components/CalendarRange.tsx
4765
+ var import_jsx_runtime57 = require("react/jsx-runtime");
4112
4766
  function DateCell(_a) {
4113
4767
  var _b = _a, {
4114
4768
  date,
@@ -4143,12 +4797,12 @@ function DateCell(_a) {
4143
4797
  "id",
4144
4798
  "testid"
4145
4799
  ]);
4146
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
4800
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4147
4801
  "span",
4148
4802
  __spreadProps(__spreadValues({}, props), {
4149
4803
  id,
4150
4804
  "data-testid": testid,
4151
- className: (0, import_clsx22.default)(
4805
+ className: (0, import_clsx35.default)(
4152
4806
  "flex items-center justify-center aspect-square select-none transition-colors border duration-100 font-medium",
4153
4807
  typography.caption,
4154
4808
  cellPadding,
@@ -4218,20 +4872,20 @@ function CalendarRange({
4218
4872
  const fromDate = parseDate(from);
4219
4873
  const toDate = parseDate(to);
4220
4874
  const today = import_polyfill.Temporal.Now.plainDateISO();
4221
- const [baseMonth, setBaseMonth] = (0, import_react19.useState)(
4875
+ const [baseMonth, setBaseMonth] = (0, import_react35.useState)(
4222
4876
  fromDate != null ? fromDate : today.with({ day: 1 })
4223
4877
  );
4224
- const [selecting, setSelecting] = (0, import_react19.useState)("from");
4225
- const [pendingFrom, setPendingFrom] = (0, import_react19.useState)(void 0);
4226
- const [hoveredDate, setHoveredDate] = (0, import_react19.useState)(void 0);
4227
- (0, import_react19.useEffect)(() => {
4878
+ const [selecting, setSelecting] = (0, import_react35.useState)("from");
4879
+ const [pendingFrom, setPendingFrom] = (0, import_react35.useState)(void 0);
4880
+ const [hoveredDate, setHoveredDate] = (0, import_react35.useState)(void 0);
4881
+ (0, import_react35.useEffect)(() => {
4228
4882
  if (fromDate) {
4229
4883
  setBaseMonth(fromDate.with({ day: 1 }));
4230
4884
  } else if (toDate) {
4231
4885
  setBaseMonth(toDate.with({ day: 1 }));
4232
4886
  }
4233
4887
  }, [from, to]);
4234
- (0, import_react19.useEffect)(() => {
4888
+ (0, import_react35.useEffect)(() => {
4235
4889
  if (fromDate && toDate) {
4236
4890
  setSelecting("from");
4237
4891
  setPendingFrom(void 0);
@@ -4297,12 +4951,12 @@ function CalendarRange({
4297
4951
  }
4298
4952
  return false;
4299
4953
  }
4300
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
4954
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4301
4955
  "div",
4302
4956
  {
4303
4957
  id,
4304
4958
  "data-testid": testid,
4305
- className: (0, import_clsx22.default)(
4959
+ className: (0, import_clsx35.default)(
4306
4960
  "relative bg-background-grouped-primary-normal rounded-base w-fit",
4307
4961
  layoutPaddding,
4308
4962
  layoutGap,
@@ -4310,15 +4964,15 @@ function CalendarRange({
4310
4964
  // baseTransition,
4311
4965
  "overflow-hidden"
4312
4966
  ),
4313
- children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
4967
+ children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4314
4968
  "div",
4315
4969
  {
4316
- className: (0, import_clsx22.default)(
4970
+ className: (0, import_clsx35.default)(
4317
4971
  "flex flex-row items-start justify-start bg-background-primary-normal overflow-clip",
4318
4972
  layoutGap
4319
4973
  ),
4320
4974
  children: (mode === "double" ? [0, 1] : [0]).map((offset, idx) => {
4321
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
4975
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4322
4976
  CalendarPane,
4323
4977
  {
4324
4978
  getMonthData,
@@ -4376,45 +5030,45 @@ function CalendarPane({
4376
5030
  const years = Array.from({ length: 100 }).map(
4377
5031
  (_, i) => baseMonth.year - 50 + i
4378
5032
  );
4379
- const [monthMenuOpen, setMonthMenuOpen] = (0, import_react19.useState)(false);
4380
- const [yearMenuOpen, setYearMenuOpen] = (0, import_react19.useState)(false);
4381
- const monthMenuRef = (0, import_react19.useRef)(null);
4382
- const yearMenuRef = (0, import_react19.useRef)(null);
5033
+ const [monthMenuOpen, setMonthMenuOpen] = (0, import_react35.useState)(false);
5034
+ const [yearMenuOpen, setYearMenuOpen] = (0, import_react35.useState)(false);
5035
+ const monthMenuRef = (0, import_react35.useRef)(null);
5036
+ const yearMenuRef = (0, import_react35.useRef)(null);
4383
5037
  const month = getMonthData(offset);
4384
5038
  const totalCells = 42;
4385
5039
  const emptyCells = month.firstDayOffset;
4386
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(import_react19.default.Fragment, { children: [
4387
- /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
5040
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(import_react35.default.Fragment, { children: [
5041
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(
4388
5042
  "div",
4389
5043
  {
4390
- className: (0, import_clsx22.default)("flex flex-col"),
5044
+ className: (0, import_clsx35.default)("flex flex-col"),
4391
5045
  children: [
4392
- /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)(
5046
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)(
4393
5047
  "div",
4394
5048
  {
4395
- className: (0, import_clsx22.default)(
5049
+ className: (0, import_clsx35.default)(
4396
5050
  "flex flex-row items-center justify-between",
4397
5051
  typography.label,
4398
5052
  "text-text-action-primary-normal"
4399
5053
  ),
4400
5054
  children: [
4401
- idx === 0 ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
5055
+ idx === 0 ? /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4402
5056
  "button",
4403
5057
  {
4404
5058
  id: id ? `${id}-prev-month-button` : void 0,
4405
5059
  "data-testid": testid ? `${testid}-prev-month-button` : void 0,
4406
5060
  type: "button",
4407
- className: (0, import_clsx22.default)(
5061
+ className: (0, import_clsx35.default)(
4408
5062
  "flex items-center justify-center rounded-base hover:bg-action-100 active:bg-action-300 text-icon-action-primary-normal",
4409
5063
  componentPadding
4410
5064
  ),
4411
5065
  "aria-label": "Previous month",
4412
5066
  onClick: () => setBaseMonth(baseMonth.subtract({ months: 1 })),
4413
- children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Icon, { name: "chevron_left", size: 24 })
5067
+ children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(Icon, { name: "chevron_left", size: 24 })
4414
5068
  }
4415
- ) : /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { className: (0, import_clsx22.default)(componentPadding, "mr-1") }),
4416
- /* @__PURE__ */ (0, import_jsx_runtime25.jsxs)("div", { className: "flex gap-desktop-compact-component-padding", children: [
4417
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
5069
+ ) : /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("span", { className: (0, import_clsx35.default)(componentPadding, "mr-1") }),
5070
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsxs)("div", { className: "flex gap-desktop-compact-component-padding", children: [
5071
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4418
5072
  "button",
4419
5073
  {
4420
5074
  ref: (el) => {
@@ -4429,13 +5083,13 @@ function CalendarPane({
4429
5083
  children: month.name
4430
5084
  }
4431
5085
  ),
4432
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
5086
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4433
5087
  Menu,
4434
5088
  {
4435
5089
  show: monthMenuOpen,
4436
5090
  positionTo: monthMenuRef,
4437
5091
  setShow: () => setMonthMenuOpen(false),
4438
- children: months.map((x) => [x, getMonthDataWith(x + 1)]).map(([x, m]) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
5092
+ children: months.map((x) => [x, getMonthDataWith(x + 1)]).map(([x, m]) => /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4439
5093
  MenuOption,
4440
5094
  {
4441
5095
  selected: baseMonth.month === x + 1,
@@ -4449,7 +5103,7 @@ function CalendarPane({
4449
5103
  ))
4450
5104
  }
4451
5105
  ),
4452
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
5106
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4453
5107
  "button",
4454
5108
  {
4455
5109
  ref: (el) => {
@@ -4464,13 +5118,13 @@ function CalendarPane({
4464
5118
  children: month.year
4465
5119
  }
4466
5120
  ),
4467
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
5121
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4468
5122
  Menu,
4469
5123
  {
4470
5124
  show: yearMenuOpen,
4471
5125
  positionTo: yearMenuRef,
4472
5126
  setShow: () => setYearMenuOpen(false),
4473
- children: years.map((y) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
5127
+ children: years.map((y) => /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4474
5128
  MenuOption,
4475
5129
  {
4476
5130
  selected: baseMonth.year === y,
@@ -4485,28 +5139,28 @@ function CalendarPane({
4485
5139
  }
4486
5140
  )
4487
5141
  ] }),
4488
- (mode === "double" ? idx === 1 : true) ? /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
5142
+ (mode === "double" ? idx === 1 : true) ? /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4489
5143
  "button",
4490
5144
  {
4491
5145
  id: id ? `${id}-next-month-button` : void 0,
4492
5146
  "data-testid": testid ? `${testid}-next-month-button` : void 0,
4493
5147
  type: "button",
4494
- className: (0, import_clsx22.default)(
5148
+ className: (0, import_clsx35.default)(
4495
5149
  "flex items-center justify-center rounded-base hover:bg-action-100 active:bg-action-300 text-icon-action-primary-normal",
4496
5150
  componentPadding
4497
5151
  ),
4498
5152
  "aria-label": "Next month",
4499
5153
  onClick: () => setBaseMonth(baseMonth.add({ months: 1 })),
4500
- children: /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(Icon, { name: "chevron_right", size: 24 })
5154
+ children: /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(Icon, { name: "chevron_right", size: 24 })
4501
5155
  }
4502
- ) : /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("span", { className: (0, import_clsx22.default)(componentPadding, "ml-1") })
5156
+ ) : /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("span", { className: (0, import_clsx35.default)(componentPadding, "ml-1") })
4503
5157
  ]
4504
5158
  }
4505
5159
  ),
4506
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", { className: (0, import_clsx22.default)("grid grid-cols-7"), children: weekDays.map((d) => /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
5160
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("div", { className: (0, import_clsx35.default)("grid grid-cols-7"), children: weekDays.map((d) => /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4507
5161
  "span",
4508
5162
  {
4509
- className: (0, import_clsx22.default)(
5163
+ className: (0, import_clsx35.default)(
4510
5164
  typography.caption,
4511
5165
  "text-text-secondary-normal text-center",
4512
5166
  "w-10"
@@ -4515,7 +5169,7 @@ function CalendarPane({
4515
5169
  },
4516
5170
  d
4517
5171
  )) }),
4518
- /* @__PURE__ */ (0, import_jsx_runtime25.jsx)("div", { className: (0, import_clsx22.default)("grid grid-cols-7"), children: Array.from({ length: totalCells }).map((_, i) => {
5172
+ /* @__PURE__ */ (0, import_jsx_runtime57.jsx)("div", { className: (0, import_clsx35.default)("grid grid-cols-7"), children: Array.from({ length: totalCells }).map((_, i) => {
4519
5173
  const day = i - emptyCells + 1;
4520
5174
  const date = month.date.with({ day: 1 }).add({
4521
5175
  days: i - emptyCells
@@ -4529,7 +5183,7 @@ function CalendarPane({
4529
5183
  const hoverDateIsAfterPendingFrom = hoveredDate && pendingFrom && import_polyfill.Temporal.PlainDate.compare(hoveredDate, pendingFrom) >= 0;
4530
5184
  const isRangeStart = mode === "single" && disableRange ? false : !pendingFrom && isInMonth && fromDate && date.equals(fromDate) || hoverDateIsAfterPendingFrom && date.equals(pendingFrom);
4531
5185
  const isRangeEnd = mode === "single" && disableRange ? false : !pendingFrom && isInMonth && toDate && date.equals(toDate) || hoverDateIsBeforePendingFrom && date.equals(pendingFrom);
4532
- return /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
5186
+ return /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4533
5187
  DateCell,
4534
5188
  {
4535
5189
  id: id ? `${id}-date-${date.toString()}` : void 0,
@@ -4554,10 +5208,10 @@ function CalendarPane({
4554
5208
  ]
4555
5209
  }
4556
5210
  ),
4557
- mode === "double" && idx === 0 && /* @__PURE__ */ (0, import_jsx_runtime25.jsx)(
5211
+ mode === "double" && idx === 0 && /* @__PURE__ */ (0, import_jsx_runtime57.jsx)(
4558
5212
  "div",
4559
5213
  {
4560
- className: (0, import_clsx22.default)(
5214
+ className: (0, import_clsx35.default)(
4561
5215
  "self-stretch bg-border-primary-normal rounded-base",
4562
5216
  // 1px width, full height, matches Figma divider
4563
5217
  "w-px"
@@ -4568,7 +5222,7 @@ function CalendarPane({
4568
5222
  }
4569
5223
 
4570
5224
  // src/components/DateInput.tsx
4571
- var import_jsx_runtime26 = require("react/jsx-runtime");
5225
+ var import_jsx_runtime58 = require("react/jsx-runtime");
4572
5226
  var DateInput = (_a) => {
4573
5227
  var _b = _a, {
4574
5228
  id,
@@ -4589,24 +5243,24 @@ var DateInput = (_a) => {
4589
5243
  "readOnly",
4590
5244
  "label"
4591
5245
  ]);
4592
- const [visible, setVisible] = (0, import_react20.useState)(false);
4593
- const [inputValue, setInputValue] = (0, import_react20.useState)("");
4594
- const [isTyping, setIsTyping] = (0, import_react20.useState)(false);
4595
- const popoverRef = (0, import_react20.useRef)(null);
4596
- const triggerRef = (0, import_react20.useRef)(null);
4597
- const rootRef = (0, import_react20.useRef)(null);
4598
- const [calendarPosition, setCalendarPosition] = (0, import_react20.useState)({
5246
+ const [visible, setVisible] = (0, import_react36.useState)(false);
5247
+ const [inputValue, setInputValue] = (0, import_react36.useState)("");
5248
+ const [isTyping, setIsTyping] = (0, import_react36.useState)(false);
5249
+ const popoverRef = (0, import_react36.useRef)(null);
5250
+ const triggerRef = (0, import_react36.useRef)(null);
5251
+ const rootRef = (0, import_react36.useRef)(null);
5252
+ const [calendarPosition, setCalendarPosition] = (0, import_react36.useState)({
4599
5253
  top: 0,
4600
5254
  left: 0,
4601
5255
  width: 0
4602
5256
  });
4603
5257
  const [from, to] = [value, ""];
4604
- (0, import_react20.useEffect)(() => {
5258
+ (0, import_react36.useEffect)(() => {
4605
5259
  if (!isTyping) {
4606
5260
  setInputValue(formatDisplayValue(from));
4607
5261
  }
4608
5262
  }, [from, isTyping]);
4609
- (0, import_react20.useLayoutEffect)(() => {
5263
+ (0, import_react36.useLayoutEffect)(() => {
4610
5264
  if (visible) {
4611
5265
  updatePosition();
4612
5266
  }
@@ -4621,7 +5275,7 @@ var DateInput = (_a) => {
4621
5275
  });
4622
5276
  }
4623
5277
  };
4624
- (0, import_react20.useEffect)(() => {
5278
+ (0, import_react36.useEffect)(() => {
4625
5279
  updatePosition();
4626
5280
  const resizeObserver = new ResizeObserver(updatePosition);
4627
5281
  if (triggerRef.current) {
@@ -4633,7 +5287,7 @@ var DateInput = (_a) => {
4633
5287
  window.removeEventListener("scroll", updatePosition);
4634
5288
  };
4635
5289
  }, []);
4636
- (0, import_react20.useEffect)(() => {
5290
+ (0, import_react36.useEffect)(() => {
4637
5291
  const handleKeyDown2 = (event) => {
4638
5292
  var _a2;
4639
5293
  if (event.key === "Escape" && popoverRef.current) {
@@ -4646,7 +5300,7 @@ var DateInput = (_a) => {
4646
5300
  document.removeEventListener("keydown", handleKeyDown2);
4647
5301
  };
4648
5302
  });
4649
- (0, import_react20.useEffect)(() => {
5303
+ (0, import_react36.useEffect)(() => {
4650
5304
  const handleClickOutside = (event) => {
4651
5305
  if (popoverRef.current && !popoverRef.current.contains(event.target) && triggerRef.current && !triggerRef.current.contains(event.target)) {
4652
5306
  setVisible(false);
@@ -4727,8 +5381,8 @@ var DateInput = (_a) => {
4727
5381
  }
4728
5382
  }
4729
5383
  };
4730
- return /* @__PURE__ */ (0, import_jsx_runtime26.jsxs)("div", { className: "relative", children: [
4731
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
5384
+ return /* @__PURE__ */ (0, import_jsx_runtime58.jsxs)("div", { className: "relative", children: [
5385
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
4732
5386
  InputBase,
4733
5387
  __spreadProps(__spreadValues({
4734
5388
  id,
@@ -4742,7 +5396,7 @@ var DateInput = (_a) => {
4742
5396
  placeholder,
4743
5397
  disabled,
4744
5398
  readOnly,
4745
- after: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(Icon, { name: "calendar_month" }),
5399
+ after: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(Icon, { name: "calendar_month" }),
4746
5400
  onFocus: handleFocus,
4747
5401
  onClick: handleClick,
4748
5402
  onChange: handleInputChange,
@@ -4752,8 +5406,8 @@ var DateInput = (_a) => {
4752
5406
  secondaryIconColor: true
4753
5407
  })
4754
5408
  ),
4755
- visible && !readOnly && (0, import_react_dom3.createPortal)(
4756
- /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
5409
+ visible && !readOnly && (0, import_react_dom4.createPortal)(
5410
+ /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
4757
5411
  "div",
4758
5412
  {
4759
5413
  ref: (el) => {
@@ -4765,7 +5419,7 @@ var DateInput = (_a) => {
4765
5419
  left: `${calendarPosition.left}px`,
4766
5420
  minWidth: `${calendarPosition.width}px`
4767
5421
  },
4768
- children: /* @__PURE__ */ (0, import_jsx_runtime26.jsx)(
5422
+ children: /* @__PURE__ */ (0, import_jsx_runtime58.jsx)(
4769
5423
  CalendarRange,
4770
5424
  {
4771
5425
  id: id ? `${id}-calendar` : void 0,