@dmsi/wedgekit-react 0.0.140 → 0.0.141

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 (240) hide show
  1. package/dist/{chunk-4OS6APPF.js → chunk-4LXG6QNT.js} +2 -1
  2. package/dist/{chunk-KS4RDR6P.js → chunk-4NCDT5ZY.js} +21 -8
  3. package/dist/{chunk-R5TLUWDD.js → chunk-4T3DRGLF.js} +32 -30
  4. package/dist/{chunk-QZGUMB7T.js → chunk-4VTOTNKJ.js} +3 -0
  5. package/dist/{chunk-Y4HUYAI5.js → chunk-56Y5DDG3.js} +5 -2
  6. package/dist/{chunk-D2YP2BTN.js → chunk-5GOJRLQO.js} +10 -4
  7. package/dist/{chunk-J6LETUNM.js → chunk-AZ7LVLOK.js} +5 -2
  8. package/dist/{chunk-TTO4PL7Y.js → chunk-BATIOCXB.js} +7 -4
  9. package/dist/{chunk-CG2NIXZE.js → chunk-C4JGTH6G.js} +7 -3
  10. package/dist/{chunk-O4M2GISS.js → chunk-CYZL57LH.js} +5 -2
  11. package/dist/{chunk-6HIALT5L.js → chunk-E7D24OHM.js} +14 -5
  12. package/dist/{chunk-3ZUSYRI7.js → chunk-EPQLWHCL.js} +2 -2
  13. package/dist/{chunk-AY7ELVQY.js → chunk-EUXB3XKL.js} +5 -2
  14. package/dist/{chunk-6DONKNDT.js → chunk-EWGHVZL5.js} +2 -0
  15. package/dist/{chunk-VH3EJNVE.js → chunk-FFU6FB3K.js} +6 -3
  16. package/dist/{chunk-H6LXXGX6.js → chunk-FKMKHLQH.js} +6 -3
  17. package/dist/{chunk-4F6VQXKY.js → chunk-GG5JOFS6.js} +2 -1
  18. package/dist/{chunk-XCIBYDVK.js → chunk-GXSXCEAA.js} +25 -14
  19. package/dist/{chunk-VG4EPHJA.js → chunk-HVI3CL7Y.js} +6 -3
  20. package/dist/{chunk-AOELEEUS.js → chunk-I6GEUF6Y.js} +6 -3
  21. package/dist/{chunk-Z36QJ7ZF.js → chunk-J4E6Q5TM.js} +12 -9
  22. package/dist/{chunk-S5K22XTH.js → chunk-JWCT72WR.js} +5 -2
  23. package/dist/{chunk-QNQ5K7NW.js → chunk-LM5MKBPM.js} +8 -3
  24. package/dist/{chunk-EO3JJWFW.js → chunk-N6JVLYEE.js} +6 -3
  25. package/dist/{chunk-IGQVA7SC.js → chunk-NKUETCDA.js} +5 -2
  26. package/dist/{chunk-PCCJ7L3N.js → chunk-NMVSRA5Y.js} +12 -4
  27. package/dist/{chunk-X62XGQY7.js → chunk-NW2C4DL4.js} +18 -15
  28. package/dist/{chunk-OB3URVCR.js → chunk-PMBEIP24.js} +5 -1
  29. package/dist/{chunk-6UI5GABI.js → chunk-R7ELP5C5.js} +8 -5
  30. package/dist/{chunk-FWPJ73IK.js → chunk-SYEJVSE4.js} +3 -1
  31. package/dist/{chunk-WT5XXW6G.js → chunk-WFQEE2OO.js} +9 -4
  32. package/dist/{chunk-QTD7K43M.js → chunk-WSS2DFTP.js} +8 -6
  33. package/dist/{chunk-37TJJQL3.js → chunk-YR7JUKYO.js} +3 -0
  34. package/dist/{chunk-4JLU7TAC.js → chunk-ZFOANBWG.js} +3 -1
  35. package/dist/{chunk-P242H6OU.js → chunk-ZGFQN47L.js} +5 -2
  36. package/dist/components/AccessChangerTabItem.cjs +10 -4
  37. package/dist/components/AccessChangerTabItem.js +2 -2
  38. package/dist/components/Accordion.cjs +23 -11
  39. package/dist/components/Accordion.js +5 -5
  40. package/dist/components/Breadcrumbs.cjs +19 -8
  41. package/dist/components/Breadcrumbs.js +10 -5
  42. package/dist/components/Button.cjs +6 -3
  43. package/dist/components/Button.js +1 -1
  44. package/dist/components/CalendarRange.cjs +16 -5
  45. package/dist/components/CalendarRange.js +2 -2
  46. package/dist/components/Caption.cjs +18 -6
  47. package/dist/components/Caption.js +2 -2
  48. package/dist/components/Card.cjs +2 -1
  49. package/dist/components/Card.js +1 -1
  50. package/dist/components/Checkbox.cjs +18 -7
  51. package/dist/components/Checkbox.js +3 -3
  52. package/dist/components/ContentTab.cjs +22 -16
  53. package/dist/components/ContentTab.js +2 -2
  54. package/dist/components/ContentTabs.cjs +27 -18
  55. package/dist/components/ContentTabs.js +7 -4
  56. package/dist/components/DataGridCell.cjs +73 -39
  57. package/dist/components/DataGridCell.js +8 -8
  58. package/dist/components/DateInput.cjs +55 -35
  59. package/dist/components/DateInput.js +8 -4
  60. package/dist/components/DateRangeInput.cjs +55 -35
  61. package/dist/components/DateRangeInput.js +8 -4
  62. package/dist/components/Display.cjs +5 -2
  63. package/dist/components/Display.js +1 -1
  64. package/dist/components/FilterGroup.cjs +85 -44
  65. package/dist/components/FilterGroup.js +20 -10
  66. package/dist/components/FullViewportBox.cjs +3 -1
  67. package/dist/components/FullViewportBox.js +3 -1
  68. package/dist/components/Grid.cjs +3 -1
  69. package/dist/components/Grid.js +3 -1
  70. package/dist/components/Heading.cjs +5 -2
  71. package/dist/components/Heading.js +1 -1
  72. package/dist/components/HorizontalDivider.cjs +2 -2
  73. package/dist/components/HorizontalDivider.js +1 -1
  74. package/dist/components/Icon.cjs +5 -2
  75. package/dist/components/Icon.js +1 -1
  76. package/dist/components/Input.cjs +40 -32
  77. package/dist/components/Input.js +3 -3
  78. package/dist/components/InputGroup.cjs +11 -4
  79. package/dist/components/InputGroup.js +7 -3
  80. package/dist/components/Label.cjs +5 -2
  81. package/dist/components/Label.js +1 -1
  82. package/dist/components/Link.cjs +6 -3
  83. package/dist/components/Link.js +1 -1
  84. package/dist/components/List.cjs +3 -2
  85. package/dist/components/List.js +3 -2
  86. package/dist/components/LoadingScrim.cjs +4 -2
  87. package/dist/components/LoadingScrim.js +3 -2
  88. package/dist/components/MainBar.cjs +2 -0
  89. package/dist/components/MainBar.js +2 -0
  90. package/dist/components/Menu.cjs +3 -0
  91. package/dist/components/Menu.js +1 -1
  92. package/dist/components/MenuOption.cjs +19 -7
  93. package/dist/components/MenuOption.js +4 -4
  94. package/dist/components/MobileDataGrid.cjs +42 -18
  95. package/dist/components/MobileDataGrid.js +18 -11
  96. package/dist/components/Modal.cjs +38 -12
  97. package/dist/components/Modal.js +8 -8
  98. package/dist/components/ModalButtons.cjs +16 -6
  99. package/dist/components/ModalButtons.js +3 -3
  100. package/dist/components/ModalContent.cjs +3 -1
  101. package/dist/components/ModalContent.js +1 -1
  102. package/dist/components/ModalHeader.cjs +21 -9
  103. package/dist/components/ModalHeader.js +4 -4
  104. package/dist/components/ModalScrim.cjs +3 -1
  105. package/dist/components/ModalScrim.js +1 -1
  106. package/dist/components/NavigationTab.cjs +14 -5
  107. package/dist/components/NavigationTab.js +3 -3
  108. package/dist/components/NavigationTabs.cjs +17 -6
  109. package/dist/components/NavigationTabs.js +6 -4
  110. package/dist/components/NestedMenu.cjs +23 -9
  111. package/dist/components/NestedMenu.js +8 -6
  112. package/dist/components/Notification.cjs +32 -13
  113. package/dist/components/Notification.js +9 -5
  114. package/dist/components/OptionPill.cjs +21 -7
  115. package/dist/components/OptionPill.js +4 -4
  116. package/dist/components/PDFViewer.cjs +73 -29
  117. package/dist/components/PDFViewer.js +26 -20
  118. package/dist/components/Paragraph.cjs +6 -3
  119. package/dist/components/Paragraph.js +1 -1
  120. package/dist/components/Password.cjs +50 -37
  121. package/dist/components/Password.js +13 -8
  122. package/dist/components/PaymentOnAccountModal.cjs +135 -69
  123. package/dist/components/PaymentOnAccountModal.js +21 -21
  124. package/dist/components/ProjectBar.cjs +3 -1
  125. package/dist/components/ProjectBar.js +3 -1
  126. package/dist/components/Radio.cjs +12 -6
  127. package/dist/components/Radio.js +2 -2
  128. package/dist/components/Search.cjs +44 -32
  129. package/dist/components/Search.js +4 -4
  130. package/dist/components/Select.cjs +43 -32
  131. package/dist/components/Select.js +4 -4
  132. package/dist/components/SelectPaymentMethod.cjs +67 -29
  133. package/dist/components/SelectPaymentMethod.js +12 -12
  134. package/dist/components/SideMenu.cjs +3 -1
  135. package/dist/components/SideMenu.js +3 -1
  136. package/dist/components/SideMenuGroup.cjs +19 -8
  137. package/dist/components/SideMenuGroup.js +6 -4
  138. package/dist/components/SideMenuItem.cjs +15 -6
  139. package/dist/components/SideMenuItem.js +5 -2
  140. package/dist/components/Spinner.cjs +2 -1
  141. package/dist/components/Spinner.js +1 -1
  142. package/dist/components/Stack.cjs +6 -3
  143. package/dist/components/Stack.js +1 -1
  144. package/dist/components/StatusPill.cjs +12 -6
  145. package/dist/components/StatusPill.js +8 -5
  146. package/dist/components/Stepper.cjs +54 -38
  147. package/dist/components/Stepper.js +12 -7
  148. package/dist/components/Subheader.cjs +5 -2
  149. package/dist/components/Subheader.js +1 -1
  150. package/dist/components/Swatch.cjs +22 -10
  151. package/dist/components/Swatch.js +4 -4
  152. package/dist/components/Textarea.cjs +4 -1
  153. package/dist/components/Textarea.js +4 -1
  154. package/dist/components/Theme.cjs +2 -0
  155. package/dist/components/Theme.js +1 -1
  156. package/dist/components/Time.cjs +52 -36
  157. package/dist/components/Time.js +10 -5
  158. package/dist/components/Toast.cjs +29 -12
  159. package/dist/components/Toast.js +11 -6
  160. package/dist/components/Tooltip.cjs +3 -0
  161. package/dist/components/Tooltip.js +1 -1
  162. package/dist/components/TopBar.cjs +11 -4
  163. package/dist/components/TopBar.js +11 -4
  164. package/dist/components/Upload.cjs +30 -15
  165. package/dist/components/Upload.js +16 -10
  166. package/dist/components/index.cjs +221 -84
  167. package/dist/components/index.js +80 -38
  168. package/dist/index.css +24 -4
  169. package/package.json +1 -1
  170. package/src/components/Accordion.tsx +5 -2
  171. package/src/components/Breadcrumbs.tsx +9 -2
  172. package/src/components/Button.tsx +4 -1
  173. package/src/components/CalendarRange.tsx +9 -0
  174. package/src/components/Caption.tsx +11 -1
  175. package/src/components/Card.tsx +3 -2
  176. package/src/components/Checkbox.tsx +5 -0
  177. package/src/components/ContentTab.tsx +14 -12
  178. package/src/components/ContentTabs.tsx +6 -2
  179. package/src/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.tsx +4 -1
  180. package/src/components/DataGrid/ColumnSelectorHeaderCell/index.tsx +7 -0
  181. package/src/components/DataGrid/PinnedColumns.tsx +8 -1
  182. package/src/components/DataGrid/TableBody/LoadingCell.tsx +7 -3
  183. package/src/components/DataGrid/TableBody/TableBodyRow.tsx +7 -1
  184. package/src/components/DataGrid/TableBody/index.tsx +7 -1
  185. package/src/components/DataGrid/index.tsx +18 -2
  186. package/src/components/DataGrid/types.ts +1 -0
  187. package/src/components/DataGridCell.tsx +12 -0
  188. package/src/components/DateInput.tsx +4 -0
  189. package/src/components/DateRangeInput.tsx +4 -0
  190. package/src/components/Display.tsx +3 -0
  191. package/src/components/FilterGroup.tsx +10 -0
  192. package/src/components/FullViewportBox.tsx +3 -0
  193. package/src/components/Grid.tsx +3 -0
  194. package/src/components/Heading.tsx +3 -0
  195. package/src/components/HorizontalDivider.tsx +2 -2
  196. package/src/components/Icon.tsx +3 -0
  197. package/src/components/Input.tsx +32 -36
  198. package/src/components/InputGroup.tsx +6 -2
  199. package/src/components/Label.tsx +3 -0
  200. package/src/components/Link.tsx +3 -0
  201. package/src/components/List.tsx +3 -1
  202. package/src/components/LoadingScrim.tsx +2 -1
  203. package/src/components/MainBar.tsx +3 -0
  204. package/src/components/Menu.tsx +3 -0
  205. package/src/components/MenuOption.tsx +4 -0
  206. package/src/components/MobileDataGrid.tsx +12 -3
  207. package/src/components/Modal.tsx +7 -0
  208. package/src/components/ModalButtons.tsx +5 -0
  209. package/src/components/ModalContent.tsx +3 -0
  210. package/src/components/ModalHeader.tsx +5 -1
  211. package/src/components/ModalScrim.tsx +3 -0
  212. package/src/components/NavigationTab.tsx +3 -0
  213. package/src/components/NavigationTabs.tsx +7 -3
  214. package/src/components/NestedMenu.tsx +5 -2
  215. package/src/components/Notification.tsx +4 -0
  216. package/src/components/OptionPill.tsx +5 -0
  217. package/src/components/PDFViewer.tsx +16 -8
  218. package/src/components/Paragraph.tsx +3 -0
  219. package/src/components/Password.tsx +7 -2
  220. package/src/components/PaymentOnAccountModal.tsx +6 -2
  221. package/src/components/ProjectBar.tsx +3 -0
  222. package/src/components/Radio.tsx +4 -1
  223. package/src/components/Search.tsx +5 -0
  224. package/src/components/Select.tsx +4 -0
  225. package/src/components/SelectPaymentMethod.tsx +17 -3
  226. package/src/components/SideMenu.tsx +3 -0
  227. package/src/components/SideMenuGroup.tsx +4 -1
  228. package/src/components/SideMenuItem.tsx +4 -0
  229. package/src/components/Spinner.tsx +3 -1
  230. package/src/components/Stack.tsx +3 -0
  231. package/src/components/StatusPill.tsx +4 -1
  232. package/src/components/Stepper.tsx +6 -1
  233. package/src/components/Subheader.tsx +3 -0
  234. package/src/components/Textarea.tsx +4 -1
  235. package/src/components/Theme.tsx +3 -0
  236. package/src/components/Time.tsx +7 -1
  237. package/src/components/Toast.tsx +8 -3
  238. package/src/components/Tooltip.tsx +4 -0
  239. package/src/components/TopBar.tsx +7 -2
  240. package/src/components/Upload.tsx +10 -4
@@ -1,8 +1,8 @@
1
1
  "use client";
2
2
  import {
3
3
  ContentTab
4
- } from "../chunk-X62XGQY7.js";
5
- import "../chunk-H6LXXGX6.js";
4
+ } from "../chunk-NW2C4DL4.js";
5
+ import "../chunk-FKMKHLQH.js";
6
6
  import "../chunk-RDLEIAQU.js";
7
7
  import "../chunk-ORMEWXMH.js";
8
8
 
@@ -11,7 +11,7 @@ import clsx from "clsx";
11
11
  import { useState, useRef, useCallback, useEffect } from "react";
12
12
  import { jsx, jsxs } from "react/jsx-runtime";
13
13
  var afterClasses = "after:absolute after:bottom-0 after:left-0 after:w-full after:h-0.5 after:bg-border-primary-normal z-0";
14
- var ContentTabs = ({ tabs, onTabChange, fullWidthTabs, id, selectedTab }) => {
14
+ var ContentTabs = ({ tabs, onTabChange, fullWidthTabs, id, testid, selectedTab }) => {
15
15
  var _a, _b;
16
16
  const [selectedTabId, setSelectedTabId] = useState(((_a = tabs[0]) == null ? void 0 : _a.id) || "");
17
17
  const [focusedTabIndex, setFocusedTabIndex] = useState(0);
@@ -48,11 +48,12 @@ var ContentTabs = ({ tabs, onTabChange, fullWidthTabs, id, selectedTab }) => {
48
48
  setFocusedTabIndex(newIndex);
49
49
  };
50
50
  const selectedContent = (_b = tabs.find((tab) => tab.id === selectedTabId)) == null ? void 0 : _b.content;
51
- return /* @__PURE__ */ jsxs("div", { id, children: [
51
+ return /* @__PURE__ */ jsxs("div", { id, "data-testid": testid, children: [
52
52
  /* @__PURE__ */ jsx("div", { className: "overflow-x-auto pb-2", children: /* @__PURE__ */ jsx(
53
53
  "div",
54
54
  {
55
55
  id: id ? `${id}-tablist` : void 0,
56
+ "data-testid": testid ? `${testid}-tablist` : void 0,
56
57
  role: "tablist",
57
58
  "aria-orientation": "horizontal",
58
59
  className: clsx("flex relative", afterClasses),
@@ -64,6 +65,7 @@ var ContentTabs = ({ tabs, onTabChange, fullWidthTabs, id, selectedTab }) => {
64
65
  {
65
66
  fullWidth: fullWidthTabs,
66
67
  id: id ? `${id}-tab-${tab.id}` : void 0,
68
+ testid: testid ? `${testid}-tab-${tab.id}` : void 0,
67
69
  label: tab.label,
68
70
  selected: isSelected,
69
71
  onClick: () => handleTabClick(tab.id, index),
@@ -90,6 +92,7 @@ var ContentTabs = ({ tabs, onTabChange, fullWidthTabs, id, selectedTab }) => {
90
92
  "div",
91
93
  {
92
94
  id: (id ? `${id}-` : "") + `panel-${selectedTabId}`,
95
+ "data-testid": (testid ? `${testid}-` : "") + `panel-${selectedTabId}`,
93
96
  className: "mt-2",
94
97
  role: "tabpanel",
95
98
  "aria-labelledby": `tab-${selectedTabId}`,
@@ -253,17 +253,20 @@ function Icon(_a) {
253
253
  var _b = _a, {
254
254
  name,
255
255
  size = 24,
256
- variant = "outline"
256
+ variant = "outline",
257
+ testid
257
258
  } = _b, props = __objRest(_b, [
258
259
  "name",
259
260
  "size",
260
- "variant"
261
+ "variant",
262
+ "testid"
261
263
  ]);
262
264
  const variantStyle = variant === "filled" ? '"FILL" 1' : '"FILL" 0';
263
265
  const weightStyle = size === 16 ? '"wght" 400' : '"wght" 300';
264
266
  return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(
265
267
  "span",
266
268
  __spreadProps(__spreadValues({}, props), {
269
+ "data-testid": testid,
267
270
  className: (0, import_clsx2.default)(
268
271
  "icon",
269
272
  `icon-${size}`,
@@ -295,20 +298,23 @@ var Label = (_a) => {
295
298
  className,
296
299
  color,
297
300
  align,
298
- id
301
+ id,
302
+ testid
299
303
  } = _b, props = __objRest(_b, [
300
304
  "as",
301
305
  "padded",
302
306
  "className",
303
307
  "color",
304
308
  "align",
305
- "id"
309
+ "id",
310
+ "testid"
306
311
  ]);
307
312
  const Element = as;
308
313
  return /* @__PURE__ */ (0, import_jsx_runtime2.jsx)(
309
314
  Element,
310
315
  __spreadProps(__spreadValues({
311
316
  id,
317
+ "data-testid": testid,
312
318
  className: (0, import_clsx3.default)(
313
319
  typography.label,
314
320
  align === "left" && "text-left",
@@ -364,6 +370,7 @@ var import_jsx_runtime3 = require("react/jsx-runtime");
364
370
  var InputBase = (_a) => {
365
371
  var _b = _a, {
366
372
  id,
373
+ testid,
367
374
  before,
368
375
  after,
369
376
  type,
@@ -382,6 +389,7 @@ var InputBase = (_a) => {
382
389
  fullWidth = true
383
390
  } = _b, props = __objRest(_b, [
384
391
  "id",
392
+ "testid",
385
393
  "before",
386
394
  "after",
387
395
  "type",
@@ -446,6 +454,7 @@ var InputBase = (_a) => {
446
454
  "label",
447
455
  {
448
456
  id,
457
+ "data-testid": testid,
449
458
  htmlFor: inputId,
450
459
  ref: inputContainerRef,
451
460
  className: (0, import_clsx4.default)(
@@ -498,6 +507,7 @@ var InputBase = (_a) => {
498
507
  required
499
508
  }, props), attributes), {
500
509
  id: inputId,
510
+ "data-testid": testid ? `${testid}-input` : void 0,
501
511
  className: (0, import_clsx4.default)(
502
512
  "flex-1 outline-none w-full max-w-full min-h-6 min-w-0",
503
513
  "[appearance:textfield] [&::-webkit-outer-spin-button]:appearance-none [&::-webkit-inner-spin-button]:appearance-none",
@@ -515,7 +525,7 @@ var InputBase = (_a) => {
515
525
  ]
516
526
  }
517
527
  ),
518
- caption && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { id: id ? `${id}-caption` : void 0, children: caption })
528
+ caption && /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("div", { id: id ? `${id}-caption` : void 0, "data-testid": testid ? `${testid}-caption` : void 0, children: caption })
519
529
  ]
520
530
  }
521
531
  );
@@ -530,7 +540,8 @@ var Input = (_a) => {
530
540
  onChange,
531
541
  onBlur,
532
542
  onClear,
533
- id
543
+ id,
544
+ testid
534
545
  } = _b, props = __objRest(_b, [
535
546
  "variant",
536
547
  "decimals",
@@ -540,30 +551,30 @@ var Input = (_a) => {
540
551
  "onChange",
541
552
  "onBlur",
542
553
  "onClear",
543
- "id"
554
+ "id",
555
+ "testid"
544
556
  ]);
545
557
  const [internalValue, setInternalValue] = (0, import_react2.useState)("");
546
558
  const [displayValue, setDisplayValue] = (0, import_react2.useState)("");
547
559
  (0, import_react2.useEffect)(() => {
548
560
  var _a2;
549
561
  const stringValue = (_a2 = propValue == null ? void 0 : propValue.toString()) != null ? _a2 : "";
550
- if (variant === "currency") {
551
- if (propValue === void 0 || propValue === "" || typeof propValue === "number" && isNaN(propValue)) {
552
- setInternalValue("");
553
- setDisplayValue("");
554
- } else {
555
- const numValue = typeof propValue === "string" ? parseFloat(propValue) : propValue;
556
- if (!isNaN(numValue)) {
557
- const formatted = numValue.toFixed(decimals != null ? decimals : 2);
558
- setInternalValue(formatted);
559
- setDisplayValue(formatCurrencyDisplay(formatted));
560
- }
561
- }
562
- } else {
563
- setInternalValue(stringValue);
564
- setDisplayValue(stringValue);
562
+ setInternalValue(stringValue);
563
+ setDisplayValue(stringValue);
564
+ }, [propValue]);
565
+ (0, import_react2.useEffect)(() => {
566
+ var _a2;
567
+ if (variant !== "currency") {
568
+ return;
565
569
  }
566
- }, [propValue, decimals, variant]);
570
+ const stringValue = (_a2 = propValue == null ? void 0 : propValue.toString()) != null ? _a2 : "";
571
+ if (!stringValue) {
572
+ return;
573
+ }
574
+ const formatted = formatDecimalValue(stringValue, decimals != null ? decimals : 2);
575
+ setInternalValue(formatted);
576
+ setDisplayValue(formatCurrencyDisplay(formatted));
577
+ }, []);
567
578
  const getInputProps = () => {
568
579
  var _a2;
569
580
  const baseProps = __spreadProps(__spreadValues(__spreadProps(__spreadValues({}, props), {
@@ -616,6 +627,7 @@ var Input = (_a) => {
616
627
  Icon,
617
628
  {
618
629
  id: id ? `${id}-clear-button` : void 0,
630
+ testid: testid ? `${testid}-clear-button` : void 0,
619
631
  name: "close",
620
632
  onClick: handleSearchReset,
621
633
  className: "cursor-pointer absolute right-2 bottom-2/4 translate-y-2/4"
@@ -647,14 +659,6 @@ var Input = (_a) => {
647
659
  };
648
660
  const handleChange = (e) => {
649
661
  const rawValue = e.target.value;
650
- if (variant === "search") {
651
- setInternalValue(rawValue);
652
- setDisplayValue(rawValue);
653
- if (typeof onChange === "function") {
654
- onChange(e);
655
- }
656
- return;
657
- }
658
662
  if (variant === "currency") {
659
663
  const raw = rawValue.replace(/,/g, "");
660
664
  if (raw === "") {
@@ -691,6 +695,9 @@ var Input = (_a) => {
691
695
  }
692
696
  };
693
697
  const handleBlur = (e) => {
698
+ if (!internalValue) {
699
+ return;
700
+ }
694
701
  if (variant === "currency") {
695
702
  const formatted = formatDecimalValue(internalValue, decimals != null ? decimals : 2);
696
703
  setInternalValue(formatted);
@@ -715,7 +722,8 @@ var Input = (_a) => {
715
722
  before: getBeforeElement(),
716
723
  after: getAfterElement(),
717
724
  onChange: handleChange,
718
- onBlur: handleBlur
725
+ onBlur: handleBlur,
726
+ testid
719
727
  })
720
728
  );
721
729
  };
@@ -748,6 +756,7 @@ var import_jsx_runtime4 = require("react/jsx-runtime");
748
756
  var Search = (_a) => {
749
757
  var _b = _a, {
750
758
  id,
759
+ testid,
751
760
  label,
752
761
  error,
753
762
  children,
@@ -758,6 +767,7 @@ var Search = (_a) => {
758
767
  removeRoundness
759
768
  } = _b, props = __objRest(_b, [
760
769
  "id",
770
+ "testid",
761
771
  "label",
762
772
  "error",
763
773
  "children",
@@ -787,6 +797,7 @@ var Search = (_a) => {
787
797
  Input,
788
798
  __spreadValues({
789
799
  id,
800
+ testid,
790
801
  variant: "search",
791
802
  inputContainerRef,
792
803
  ref: inputRef,
@@ -842,6 +853,7 @@ var Search = (_a) => {
842
853
  ),
843
854
  renderMenu ? renderMenu({
844
855
  id: id ? `${id}-menu` : void 0,
856
+ testid: testid ? `${testid}-menu` : void 0,
845
857
  positionTo: inputContainerRef,
846
858
  show,
847
859
  setShow,
@@ -1201,6 +1213,7 @@ var import_jsx_runtime5 = require("react/jsx-runtime");
1201
1213
  var Menu = (_a) => {
1202
1214
  var _b = _a, {
1203
1215
  id,
1216
+ testid,
1204
1217
  children,
1205
1218
  className,
1206
1219
  ref,
@@ -1218,6 +1231,7 @@ var Menu = (_a) => {
1218
1231
  menuName
1219
1232
  } = _b, props = __objRest(_b, [
1220
1233
  "id",
1234
+ "testid",
1221
1235
  "children",
1222
1236
  "className",
1223
1237
  "ref",
@@ -1298,6 +1312,7 @@ var Menu = (_a) => {
1298
1312
  "div",
1299
1313
  __spreadProps(__spreadValues({
1300
1314
  id,
1315
+ "data-testid": testid,
1301
1316
  ref: setRefs,
1302
1317
  className: (0, import_clsx5.default)(
1303
1318
  "shadow-4 rounded-base bg-background-grouped-primary-normal overflow-x-hidden overflow-y-auto flex flex-col outline-0",
@@ -1444,7 +1459,8 @@ var Paragraph = (_a) => {
1444
1459
  addOverflow,
1445
1460
  children,
1446
1461
  as = "p",
1447
- id
1462
+ id,
1463
+ testid
1448
1464
  } = _b, props = __objRest(_b, [
1449
1465
  "className",
1450
1466
  "color",
@@ -1454,13 +1470,15 @@ var Paragraph = (_a) => {
1454
1470
  "addOverflow",
1455
1471
  "children",
1456
1472
  "as",
1457
- "id"
1473
+ "id",
1474
+ "testid"
1458
1475
  ]);
1459
1476
  const Element = as;
1460
1477
  return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(
1461
1478
  Element,
1462
1479
  __spreadProps(__spreadValues({
1463
- id
1480
+ id,
1481
+ "data-testid": testid
1464
1482
  }, props), {
1465
1483
  className: (0, import_clsx6.default)(
1466
1484
  typography.paragraph,
@@ -1485,6 +1503,7 @@ Paragraph.displayName = "Paragraph";
1485
1503
  var import_jsx_runtime7 = require("react/jsx-runtime");
1486
1504
  var MenuOption = ({
1487
1505
  id,
1506
+ testid,
1488
1507
  children,
1489
1508
  disabled = false,
1490
1509
  variant = "normal",
@@ -1558,6 +1577,7 @@ var MenuOption = ({
1558
1577
  "div",
1559
1578
  __spreadProps(__spreadValues({
1560
1579
  id,
1580
+ "data-testid": testid,
1561
1581
  ref: actualRef,
1562
1582
  className: (0, import_clsx7.default)(
1563
1583
  "flex items-center cursor-pointer w-full text-left relative outline-none",
@@ -1626,6 +1646,7 @@ var MenuOption = ({
1626
1646
  MenuOption,
1627
1647
  {
1628
1648
  id: id ? `${id}-back` : void 0,
1649
+ testid: testid ? `${testid}-back` : void 0,
1629
1650
  onClick: () => {
1630
1651
  closeSubMenuLevel == null ? void 0 : closeSubMenuLevel(currentSubMenuLevel != null ? currentSubMenuLevel : 0);
1631
1652
  },
@@ -1670,7 +1691,8 @@ var DataGridCell = (0, import_react10.memo)(
1670
1691
  error,
1671
1692
  warning,
1672
1693
  center,
1673
- width
1694
+ width,
1695
+ testid
1674
1696
  } = _b, props = __objRest(_b, [
1675
1697
  "id",
1676
1698
  "type",
@@ -1686,7 +1708,8 @@ var DataGridCell = (0, import_react10.memo)(
1686
1708
  "error",
1687
1709
  "warning",
1688
1710
  "center",
1689
- "width"
1711
+ "width",
1712
+ "testid"
1690
1713
  ]);
1691
1714
  const Element = type === "header" ? "th" : "td";
1692
1715
  const timerRef = (0, import_react10.useRef)(null);
@@ -1757,6 +1780,7 @@ var DataGridCell = (0, import_react10.memo)(
1757
1780
  Element,
1758
1781
  __spreadProps(__spreadValues({
1759
1782
  id,
1783
+ "data-testid": testid,
1760
1784
  className: (0, import_clsx8.default)("flex h-10", !width && "flex-1"),
1761
1785
  style: { width }
1762
1786
  }, props), {
@@ -1788,6 +1812,7 @@ function DataCellHeader(_a) {
1788
1812
  setNodeRef,
1789
1813
  node,
1790
1814
  id,
1815
+ testid,
1791
1816
  useMenuDefaultMinWidth
1792
1817
  } = _b, props = __objRest(_b, [
1793
1818
  "header",
@@ -1795,6 +1820,7 @@ function DataCellHeader(_a) {
1795
1820
  "setNodeRef",
1796
1821
  "node",
1797
1822
  "id",
1823
+ "testid",
1798
1824
  "useMenuDefaultMinWidth"
1799
1825
  ]);
1800
1826
  var _a2;
@@ -1840,6 +1866,7 @@ function DataCellHeader(_a) {
1840
1866
  DataGridCell,
1841
1867
  __spreadProps(__spreadValues({
1842
1868
  id,
1869
+ testid,
1843
1870
  ref: setNodeRef ? setNodeRef : ref,
1844
1871
  type: "header",
1845
1872
  component: "header",
@@ -1853,6 +1880,7 @@ function DataCellHeader(_a) {
1853
1880
  Menu,
1854
1881
  {
1855
1882
  id: id ? `${id}-menu` : void 0,
1883
+ testid: testid ? `${testid}-menu` : void 0,
1856
1884
  ref: menuRootRef,
1857
1885
  positionTo: node ? node : ref,
1858
1886
  show: showMenu,
@@ -1863,14 +1891,16 @@ function DataCellHeader(_a) {
1863
1891
  /* @__PURE__ */ (0, import_jsx_runtime8.jsx)(
1864
1892
  MenuOption,
1865
1893
  __spreadProps(__spreadValues({
1866
- id: id ? `${id}-filter-option` : void 0
1894
+ id: id ? `${id}-filter-option` : void 0,
1895
+ testid: testid ? `${testid}-filter-option` : void 0
1867
1896
  }, subMenuListeners), {
1868
1897
  subMenu: (_b2) => {
1869
1898
  var _c = _b2, { menuId, subMenuLevel } = _c, props2 = __objRest(_c, ["menuId", "subMenuLevel"]);
1870
1899
  return /* @__PURE__ */ (0, import_jsx_runtime8.jsxs)(
1871
1900
  Menu,
1872
1901
  __spreadProps(__spreadValues({
1873
- id: id ? `${id}-filter-submenu` : void 0
1902
+ id: id ? `${id}-filter-submenu` : void 0,
1903
+ testid: testid ? `${testid}-filter-submenu` : void 0
1874
1904
  }, props2), {
1875
1905
  show: isMenuActive(menuId, subMenuLevel),
1876
1906
  ref: (el) => {
@@ -1882,6 +1912,7 @@ function DataCellHeader(_a) {
1882
1912
  Search,
1883
1913
  {
1884
1914
  id: id ? `${id}-filter-search` : void 0,
1915
+ testid: testid ? `${testid}-filter-search` : void 0,
1885
1916
  onChange: (event) => {
1886
1917
  setFilter(event.target.value);
1887
1918
  },
@@ -1897,6 +1928,7 @@ function DataCellHeader(_a) {
1897
1928
  MenuOption,
1898
1929
  {
1899
1930
  id: id ? `${id}-filter-contains` : void 0,
1931
+ testid: testid ? `${testid}-filter-contains` : void 0,
1900
1932
  onClick: handleFilterFnChange,
1901
1933
  before: menuOptionIcon("includesString"),
1902
1934
  children: "Contains"
@@ -1906,6 +1938,7 @@ function DataCellHeader(_a) {
1906
1938
  MenuOption,
1907
1939
  {
1908
1940
  id: id ? `${id}-filter-startswith` : void 0,
1941
+ testid: testid ? `${testid}-filter-startswith` : void 0,
1909
1942
  onClick: handleFilterFnChange,
1910
1943
  before: menuOptionIcon("startsWith"),
1911
1944
  children: "Starts with"
@@ -1915,6 +1948,7 @@ function DataCellHeader(_a) {
1915
1948
  MenuOption,
1916
1949
  {
1917
1950
  id: id ? `${id}-filter-endswith` : void 0,
1951
+ testid: testid ? `${testid}-filter-endswith` : void 0,
1918
1952
  onClick: handleFilterFnChange,
1919
1953
  before: menuOptionIcon("endsWith"),
1920
1954
  children: "Ends with"
@@ -4,19 +4,19 @@ import {
4
4
  DataGridCell,
5
5
  DragAlongCell,
6
6
  DraggableCellHeader
7
- } from "../chunk-KS4RDR6P.js";
8
- import "../chunk-37TJJQL3.js";
7
+ } from "../chunk-4NCDT5ZY.js";
8
+ import "../chunk-YR7JUKYO.js";
9
9
  import "../chunk-5GUW4DUY.js";
10
- import "../chunk-VH3EJNVE.js";
10
+ import "../chunk-FFU6FB3K.js";
11
11
  import "../chunk-WNQ53SVY.js";
12
12
  import "../chunk-4T7F5BZZ.js";
13
- import "../chunk-OB3URVCR.js";
14
- import "../chunk-R5TLUWDD.js";
13
+ import "../chunk-PMBEIP24.js";
14
+ import "../chunk-4T3DRGLF.js";
15
15
  import "../chunk-5UH6QUFB.js";
16
- import "../chunk-S5K22XTH.js";
16
+ import "../chunk-JWCT72WR.js";
17
17
  import "../chunk-WVUIIBRR.js";
18
- import "../chunk-VG4EPHJA.js";
19
- import "../chunk-IGQVA7SC.js";
18
+ import "../chunk-HVI3CL7Y.js";
19
+ import "../chunk-NKUETCDA.js";
20
20
  import "../chunk-RDLEIAQU.js";
21
21
  import "../chunk-ORMEWXMH.js";
22
22
  export {