@deepnoid/ui 0.1.38 → 0.1.39

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 (80) hide show
  1. package/.turbo/turbo-build.log +128 -128
  2. package/dist/{chunk-2M5G4MRK.mjs → chunk-4LOREVB7.mjs} +12 -5
  3. package/dist/{chunk-IBI3OVQI.mjs → chunk-BB7MFKNQ.mjs} +1 -1
  4. package/dist/{chunk-K7V4VE7R.mjs → chunk-ECMBAKSJ.mjs} +5 -5
  5. package/dist/{chunk-G67WUZO3.mjs → chunk-III2QUWF.mjs} +1 -1
  6. package/dist/{chunk-IC25OKBJ.mjs → chunk-LR3SWRB4.mjs} +5 -5
  7. package/dist/{chunk-LWRK5TPZ.mjs → chunk-MFRYYZPY.mjs} +1 -1
  8. package/dist/{chunk-25QOEKXS.mjs → chunk-O6YBE7V3.mjs} +3 -3
  9. package/dist/{chunk-BFOK4HVC.mjs → chunk-QJJKJYNR.mjs} +2 -2
  10. package/dist/{chunk-P7YYNA6L.mjs → chunk-SBL6IHEW.mjs} +1 -1
  11. package/dist/{chunk-BFNWSILP.mjs → chunk-ZLY2HICQ.mjs} +8 -14
  12. package/dist/{chunk-MCNCHQ33.mjs → chunk-ZSG4NGLK.mjs} +4 -4
  13. package/dist/components/backdrop/backdrop.mjs +2 -2
  14. package/dist/components/backdrop/index.mjs +2 -2
  15. package/dist/components/breadcrumb/breadcrumb.mjs +5 -5
  16. package/dist/components/breadcrumb/index.mjs +5 -5
  17. package/dist/components/button/button.mjs +2 -2
  18. package/dist/components/button/icon-button.mjs +2 -2
  19. package/dist/components/button/index.mjs +4 -4
  20. package/dist/components/button/text-button.mjs +2 -2
  21. package/dist/components/checkbox/checkbox.mjs +2 -2
  22. package/dist/components/checkbox/index.mjs +2 -2
  23. package/dist/components/chip/chip.mjs +2 -2
  24. package/dist/components/chip/index.mjs +2 -2
  25. package/dist/components/dateTimePicker/calendar.mjs +2 -2
  26. package/dist/components/dateTimePicker/dateTimePicker.mjs +6 -6
  27. package/dist/components/dateTimePicker/index.mjs +6 -6
  28. package/dist/components/dateTimePicker/timePicker.mjs +4 -4
  29. package/dist/components/fileUpload/fileUpload.mjs +6 -6
  30. package/dist/components/fileUpload/index.mjs +6 -6
  31. package/dist/components/input/index.mjs +2 -2
  32. package/dist/components/input/input.mjs +2 -2
  33. package/dist/components/list/index.mjs +3 -3
  34. package/dist/components/list/list.mjs +2 -2
  35. package/dist/components/list/listItem.mjs +2 -2
  36. package/dist/components/modal/index.mjs +6 -6
  37. package/dist/components/modal/modal.mjs +6 -6
  38. package/dist/components/pagination/index.mjs +3 -3
  39. package/dist/components/pagination/pagination.mjs +3 -3
  40. package/dist/components/radio/index.mjs +2 -2
  41. package/dist/components/radio/radio.mjs +2 -2
  42. package/dist/components/select/index.js +5 -11
  43. package/dist/components/select/index.mjs +2 -2
  44. package/dist/components/select/select.js +5 -11
  45. package/dist/components/select/select.mjs +2 -2
  46. package/dist/components/table/index.js +9 -2
  47. package/dist/components/table/index.mjs +7 -7
  48. package/dist/components/table/table-body.mjs +3 -3
  49. package/dist/components/table/table-head.mjs +3 -3
  50. package/dist/components/table/table.d.mts +1 -0
  51. package/dist/components/table/table.d.ts +1 -0
  52. package/dist/components/table/table.js +9 -2
  53. package/dist/components/table/table.mjs +7 -7
  54. package/dist/components/tabs/index.mjs +2 -2
  55. package/dist/components/tabs/tabs.mjs +2 -2
  56. package/dist/components/toast/index.mjs +3 -3
  57. package/dist/components/toast/toast.mjs +2 -2
  58. package/dist/components/toast/use-toast.mjs +3 -3
  59. package/dist/components/tooltip/index.mjs +2 -2
  60. package/dist/components/tooltip/tooltip.mjs +2 -2
  61. package/dist/components/tree/index.mjs +2 -2
  62. package/dist/components/tree/tree.mjs +2 -2
  63. package/dist/index.js +14 -13
  64. package/dist/index.mjs +28 -28
  65. package/package.json +1 -1
  66. package/dist/{chunk-WFMFC7R6.mjs → chunk-2PKM7SLZ.mjs} +3 -3
  67. package/dist/{chunk-QIRL6HY6.mjs → chunk-33LANVZV.mjs} +3 -3
  68. package/dist/{chunk-7TAGGLNY.mjs → chunk-6K3E5BVO.mjs} +3 -3
  69. package/dist/{chunk-UB4YBFOT.mjs → chunk-7J3KVOTS.mjs} +3 -3
  70. package/dist/{chunk-MEY4IL7D.mjs → chunk-7W2ZI2DD.mjs} +3 -3
  71. package/dist/{chunk-Z2537DF6.mjs → chunk-IL5ENWCR.mjs} +3 -3
  72. package/dist/{chunk-LL6F3WDX.mjs → chunk-P5QCU457.mjs} +3 -3
  73. package/dist/{chunk-GH6CPGFN.mjs → chunk-R62HK726.mjs} +3 -3
  74. package/dist/{chunk-2YMAKIZ6.mjs → chunk-SSMMWMQC.mjs} +3 -3
  75. package/dist/{chunk-HIVPDIEP.mjs → chunk-UFVQPPPW.mjs} +3 -3
  76. package/dist/{chunk-RT3S3VVJ.mjs → chunk-W45H2ZMW.mjs} +3 -3
  77. package/dist/{chunk-NFQMXW4Z.mjs → chunk-WPIFIRCJ.mjs} +3 -3
  78. package/dist/{chunk-A7RU3FU5.mjs → chunk-X6D7C7QZ.mjs} +3 -3
  79. package/dist/{chunk-WLNLVX7Q.mjs → chunk-Y6XQTWB5.mjs} +3 -3
  80. package/dist/{chunk-D6QI3DJG.mjs → chunk-YLRYHUTW.mjs} +3 -3
@@ -2,16 +2,16 @@
2
2
  import {
3
3
  paginationStyle,
4
4
  pagination_default
5
- } from "../../chunk-MCNCHQ33.mjs";
5
+ } from "../../chunk-ZSG4NGLK.mjs";
6
6
  import "../../chunk-F3HENRVM.mjs";
7
7
  import "../../chunk-2GCSFWHD.mjs";
8
- import "../../chunk-GH6CPGFN.mjs";
8
+ import "../../chunk-R62HK726.mjs";
9
9
  import "../../chunk-ZYIIXWVY.mjs";
10
10
  import "../../chunk-2TKEWFGH.mjs";
11
11
  import "../../chunk-2SDYFOZL.mjs";
12
- import "../../chunk-4ZJFD3L3.mjs";
13
12
  import "../../chunk-27Y6K5NK.mjs";
14
13
  import "../../chunk-E3G5QXSH.mjs";
14
+ import "../../chunk-4ZJFD3L3.mjs";
15
15
  import "../../chunk-AC6TWLRT.mjs";
16
16
  export {
17
17
  pagination_default as default,
@@ -2,10 +2,10 @@
2
2
  import "../../chunk-TPFN22HR.mjs";
3
3
  import {
4
4
  radio_default
5
- } from "../../chunk-QIRL6HY6.mjs";
6
- import "../../chunk-4ZJFD3L3.mjs";
5
+ } from "../../chunk-33LANVZV.mjs";
7
6
  import "../../chunk-27Y6K5NK.mjs";
8
7
  import "../../chunk-E3G5QXSH.mjs";
8
+ import "../../chunk-4ZJFD3L3.mjs";
9
9
  import "../../chunk-AC6TWLRT.mjs";
10
10
  export {
11
11
  radio_default as Radio
@@ -1,10 +1,10 @@
1
1
  "use client";
2
2
  import {
3
3
  radio_default
4
- } from "../../chunk-QIRL6HY6.mjs";
5
- import "../../chunk-4ZJFD3L3.mjs";
4
+ } from "../../chunk-33LANVZV.mjs";
6
5
  import "../../chunk-27Y6K5NK.mjs";
7
6
  import "../../chunk-E3G5QXSH.mjs";
7
+ import "../../chunk-4ZJFD3L3.mjs";
8
8
  import "../../chunk-AC6TWLRT.mjs";
9
9
  export {
10
10
  radio_default as default
@@ -4371,7 +4371,7 @@ function toVal(mix) {
4371
4371
  // src/components/select/select.tsx
4372
4372
  var import_jsx_runtime3 = require("react/jsx-runtime");
4373
4373
  var Select = (0, import_react.forwardRef)((originalProps, ref) => {
4374
- var _a;
4374
+ var _a, _b;
4375
4375
  const [props, variantProps] = mapPropsVariants(originalProps, select.variantKeys);
4376
4376
  const {
4377
4377
  label,
@@ -4447,6 +4447,7 @@ var Select = (0, import_react.forwardRef)((originalProps, ref) => {
4447
4447
  }, [targetRect]);
4448
4448
  const position = targetRect ? calculatePositionWithScroll(targetRect, optionWrapperHeight) : null;
4449
4449
  const displayValue = multiple ? selectedOptions.map((opt) => opt.label).join(", ") : ((_a = selectedOptions[0]) == null ? void 0 : _a.label) || "";
4450
+ const selectedValue = multiple ? selectedOptions.map((opt) => opt.value).join(", ") : ((_b = selectedOptions[0]) == null ? void 0 : _b.value) || "";
4450
4451
  const Option = ({
4451
4452
  option,
4452
4453
  isSelected,
@@ -4492,11 +4493,13 @@ var Select = (0, import_react.forwardRef)((originalProps, ref) => {
4492
4493
  slots.select({ class: classNames == null ? void 0 : classNames.select }),
4493
4494
  inputProps.readOnly ? "!text-body-foreground placeholder:text-body-foreground" : ""
4494
4495
  ),
4496
+ name: void 0,
4495
4497
  value: displayValue,
4496
4498
  readOnly: true,
4497
4499
  size: 0
4498
4500
  }
4499
4501
  ),
4502
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("input", { type: "hidden", name: inputProps.name, value: selectedValue }),
4500
4503
  /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4501
4504
  Icon_default,
4502
4505
  {
@@ -4504,16 +4507,7 @@ var Select = (0, import_react.forwardRef)((originalProps, ref) => {
4504
4507
  size: originalProps.size,
4505
4508
  className: `transition-transform duration-200 ${isOpen ? "rotate-0" : "rotate-180"}`
4506
4509
  }
4507
- ),
4508
- selectedOptions.map((opt, index) => /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4509
- "input",
4510
- {
4511
- type: "hidden",
4512
- name: multiple ? `${inputProps.name}[]` : inputProps.name,
4513
- value: opt.value
4514
- },
4515
- index
4516
- ))
4510
+ )
4517
4511
  ]
4518
4512
  }
4519
4513
  ),
@@ -2,13 +2,13 @@
2
2
  import "../../chunk-QCEKPS7U.mjs";
3
3
  import {
4
4
  select_default
5
- } from "../../chunk-BFNWSILP.mjs";
5
+ } from "../../chunk-ZLY2HICQ.mjs";
6
6
  import "../../chunk-ZYIIXWVY.mjs";
7
7
  import "../../chunk-2TKEWFGH.mjs";
8
8
  import "../../chunk-2SDYFOZL.mjs";
9
- import "../../chunk-4ZJFD3L3.mjs";
10
9
  import "../../chunk-27Y6K5NK.mjs";
11
10
  import "../../chunk-E3G5QXSH.mjs";
11
+ import "../../chunk-4ZJFD3L3.mjs";
12
12
  import "../../chunk-AC6TWLRT.mjs";
13
13
  export {
14
14
  select_default as Select
@@ -4369,7 +4369,7 @@ function toVal(mix) {
4369
4369
  // src/components/select/select.tsx
4370
4370
  var import_jsx_runtime3 = require("react/jsx-runtime");
4371
4371
  var Select = (0, import_react.forwardRef)((originalProps, ref) => {
4372
- var _a;
4372
+ var _a, _b;
4373
4373
  const [props, variantProps] = mapPropsVariants(originalProps, select.variantKeys);
4374
4374
  const {
4375
4375
  label,
@@ -4445,6 +4445,7 @@ var Select = (0, import_react.forwardRef)((originalProps, ref) => {
4445
4445
  }, [targetRect]);
4446
4446
  const position = targetRect ? calculatePositionWithScroll(targetRect, optionWrapperHeight) : null;
4447
4447
  const displayValue = multiple ? selectedOptions.map((opt) => opt.label).join(", ") : ((_a = selectedOptions[0]) == null ? void 0 : _a.label) || "";
4448
+ const selectedValue = multiple ? selectedOptions.map((opt) => opt.value).join(", ") : ((_b = selectedOptions[0]) == null ? void 0 : _b.value) || "";
4448
4449
  const Option = ({
4449
4450
  option,
4450
4451
  isSelected,
@@ -4490,11 +4491,13 @@ var Select = (0, import_react.forwardRef)((originalProps, ref) => {
4490
4491
  slots.select({ class: classNames == null ? void 0 : classNames.select }),
4491
4492
  inputProps.readOnly ? "!text-body-foreground placeholder:text-body-foreground" : ""
4492
4493
  ),
4494
+ name: void 0,
4493
4495
  value: displayValue,
4494
4496
  readOnly: true,
4495
4497
  size: 0
4496
4498
  }
4497
4499
  ),
4500
+ /* @__PURE__ */ (0, import_jsx_runtime3.jsx)("input", { type: "hidden", name: inputProps.name, value: selectedValue }),
4498
4501
  /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4499
4502
  Icon_default,
4500
4503
  {
@@ -4502,16 +4505,7 @@ var Select = (0, import_react.forwardRef)((originalProps, ref) => {
4502
4505
  size: originalProps.size,
4503
4506
  className: `transition-transform duration-200 ${isOpen ? "rotate-0" : "rotate-180"}`
4504
4507
  }
4505
- ),
4506
- selectedOptions.map((opt, index) => /* @__PURE__ */ (0, import_jsx_runtime3.jsx)(
4507
- "input",
4508
- {
4509
- type: "hidden",
4510
- name: multiple ? `${inputProps.name}[]` : inputProps.name,
4511
- value: opt.value
4512
- },
4513
- index
4514
- ))
4508
+ )
4515
4509
  ]
4516
4510
  }
4517
4511
  ),
@@ -1,13 +1,13 @@
1
1
  "use client";
2
2
  import {
3
3
  select_default
4
- } from "../../chunk-BFNWSILP.mjs";
4
+ } from "../../chunk-ZLY2HICQ.mjs";
5
5
  import "../../chunk-ZYIIXWVY.mjs";
6
6
  import "../../chunk-2TKEWFGH.mjs";
7
7
  import "../../chunk-2SDYFOZL.mjs";
8
- import "../../chunk-4ZJFD3L3.mjs";
9
8
  import "../../chunk-27Y6K5NK.mjs";
10
9
  import "../../chunk-E3G5QXSH.mjs";
10
+ import "../../chunk-4ZJFD3L3.mjs";
11
11
  import "../../chunk-AC6TWLRT.mjs";
12
12
  export {
13
13
  select_default as default
@@ -5472,7 +5472,8 @@ var Table = (0, import_react5.forwardRef)((originalProps, ref) => {
5472
5472
  classNames,
5473
5473
  color,
5474
5474
  size,
5475
- skeletonRow
5475
+ skeletonRow,
5476
+ onCheckedRowsChange
5476
5477
  } = { ...props, ...variantProps };
5477
5478
  const { page = 1, perPage = 15 } = pagination || {};
5478
5479
  const showPagination = pagination && totalData > 0 && !isLoading;
@@ -5482,7 +5483,10 @@ var Table = (0, import_react5.forwardRef)((originalProps, ref) => {
5482
5483
  ref,
5483
5484
  () => ({
5484
5485
  checkedRows,
5485
- setCheckedRows
5486
+ setCheckedRows: (rowsSet) => {
5487
+ setCheckedRows(rowsSet);
5488
+ onCheckedRowsChange == null ? void 0 : onCheckedRowsChange(getCheckedRowData(rowsSet));
5489
+ }
5486
5490
  }),
5487
5491
  [checkedRows]
5488
5492
  );
@@ -5492,14 +5496,17 @@ var Table = (0, import_react5.forwardRef)((originalProps, ref) => {
5492
5496
  const handleAllRowCheck = (checked) => {
5493
5497
  const updated = checked ? new Set(rows.map((_, i) => i)) : /* @__PURE__ */ new Set();
5494
5498
  setCheckedRows(updated);
5499
+ onCheckedRowsChange == null ? void 0 : onCheckedRowsChange(getCheckedRowData(updated));
5495
5500
  };
5496
5501
  const handleRowCheck = (index, checked) => {
5497
5502
  setCheckedRows((prev) => {
5498
5503
  const updated = new Set(prev);
5499
5504
  checked ? updated.add(index) : updated.delete(index);
5505
+ onCheckedRowsChange == null ? void 0 : onCheckedRowsChange(getCheckedRowData(updated));
5500
5506
  return updated;
5501
5507
  });
5502
5508
  };
5509
+ const getCheckedRowData = (checked) => Array.from(checked).map((index) => rows[index]).filter((row) => row !== void 0);
5503
5510
  const slots = (0, import_react5.useMemo)(() => tableStyle(variantProps), [variantProps]);
5504
5511
  return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { ref: divRef, "data-table": "base", className: slots.base({ class: classNames == null ? void 0 : classNames.base }), children: [
5505
5512
  /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(scrollArea_default, { direction: "x", size: size === "xl" ? "lg" : size, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("table", { className: slots.table({ class: classNames == null ? void 0 : classNames.table }), children: [
@@ -2,29 +2,29 @@
2
2
  import "../../chunk-DX3KXNP6.mjs";
3
3
  import {
4
4
  table_default
5
- } from "../../chunk-2M5G4MRK.mjs";
5
+ } from "../../chunk-4LOREVB7.mjs";
6
6
  import {
7
7
  definition_table_default
8
8
  } from "../../chunk-6TIIBU7J.mjs";
9
- import "../../chunk-LWRK5TPZ.mjs";
10
- import "../../chunk-P7YYNA6L.mjs";
9
+ import "../../chunk-MFRYYZPY.mjs";
10
+ import "../../chunk-SBL6IHEW.mjs";
11
11
  import "../../chunk-DQRAFUDA.mjs";
12
12
  import "../../chunk-M37VBNB3.mjs";
13
13
  import "../../chunk-MZ76AA76.mjs";
14
14
  import "../../chunk-6PN3DGOE.mjs";
15
15
  import "../../chunk-7B7LRG5J.mjs";
16
- import "../../chunk-MCNCHQ33.mjs";
16
+ import "../../chunk-ZSG4NGLK.mjs";
17
17
  import "../../chunk-F3HENRVM.mjs";
18
18
  import "../../chunk-2GCSFWHD.mjs";
19
- import "../../chunk-GH6CPGFN.mjs";
19
+ import "../../chunk-R62HK726.mjs";
20
20
  import "../../chunk-QZ3LVYJW.mjs";
21
- import "../../chunk-D6QI3DJG.mjs";
21
+ import "../../chunk-YLRYHUTW.mjs";
22
22
  import "../../chunk-ZYIIXWVY.mjs";
23
23
  import "../../chunk-2TKEWFGH.mjs";
24
24
  import "../../chunk-2SDYFOZL.mjs";
25
- import "../../chunk-4ZJFD3L3.mjs";
26
25
  import "../../chunk-27Y6K5NK.mjs";
27
26
  import "../../chunk-E3G5QXSH.mjs";
27
+ import "../../chunk-4ZJFD3L3.mjs";
28
28
  import "../../chunk-AC6TWLRT.mjs";
29
29
  export {
30
30
  definition_table_default as DefinitionTable,
@@ -1,14 +1,14 @@
1
1
  "use client";
2
2
  import {
3
3
  table_body_default
4
- } from "../../chunk-LWRK5TPZ.mjs";
4
+ } from "../../chunk-MFRYYZPY.mjs";
5
5
  import "../../chunk-MZ76AA76.mjs";
6
6
  import "../../chunk-6PN3DGOE.mjs";
7
7
  import "../../chunk-QZ3LVYJW.mjs";
8
- import "../../chunk-D6QI3DJG.mjs";
9
- import "../../chunk-4ZJFD3L3.mjs";
8
+ import "../../chunk-YLRYHUTW.mjs";
10
9
  import "../../chunk-27Y6K5NK.mjs";
11
10
  import "../../chunk-E3G5QXSH.mjs";
11
+ import "../../chunk-4ZJFD3L3.mjs";
12
12
  import "../../chunk-AC6TWLRT.mjs";
13
13
  export {
14
14
  table_body_default as default
@@ -1,14 +1,14 @@
1
1
  "use client";
2
2
  import {
3
3
  table_head_default
4
- } from "../../chunk-P7YYNA6L.mjs";
4
+ } from "../../chunk-SBL6IHEW.mjs";
5
5
  import "../../chunk-MZ76AA76.mjs";
6
6
  import "../../chunk-6PN3DGOE.mjs";
7
7
  import "../../chunk-QZ3LVYJW.mjs";
8
- import "../../chunk-D6QI3DJG.mjs";
9
- import "../../chunk-4ZJFD3L3.mjs";
8
+ import "../../chunk-YLRYHUTW.mjs";
10
9
  import "../../chunk-27Y6K5NK.mjs";
11
10
  import "../../chunk-E3G5QXSH.mjs";
11
+ import "../../chunk-4ZJFD3L3.mjs";
12
12
  import "../../chunk-AC6TWLRT.mjs";
13
13
  export {
14
14
  table_head_default as default
@@ -21,6 +21,7 @@ interface TableBaseProps extends Omit<ComponentPropsWithRef<"table">, "ref" | "c
21
21
  emptyContent?: ReactNode;
22
22
  isLoading?: boolean;
23
23
  skeletonRow?: number;
24
+ onCheckedRowsChange?: (rows: TableRow[]) => void;
24
25
  classNames?: SlotsToClasses<TableSlots>;
25
26
  }
26
27
  interface TableRef {
@@ -21,6 +21,7 @@ interface TableBaseProps extends Omit<ComponentPropsWithRef<"table">, "ref" | "c
21
21
  emptyContent?: ReactNode;
22
22
  isLoading?: boolean;
23
23
  skeletonRow?: number;
24
+ onCheckedRowsChange?: (rows: TableRow[]) => void;
24
25
  classNames?: SlotsToClasses<TableSlots>;
25
26
  }
26
27
  interface TableRef {
@@ -5469,7 +5469,8 @@ var Table = (0, import_react5.forwardRef)((originalProps, ref) => {
5469
5469
  classNames,
5470
5470
  color,
5471
5471
  size,
5472
- skeletonRow
5472
+ skeletonRow,
5473
+ onCheckedRowsChange
5473
5474
  } = { ...props, ...variantProps };
5474
5475
  const { page = 1, perPage = 15 } = pagination || {};
5475
5476
  const showPagination = pagination && totalData > 0 && !isLoading;
@@ -5479,7 +5480,10 @@ var Table = (0, import_react5.forwardRef)((originalProps, ref) => {
5479
5480
  ref,
5480
5481
  () => ({
5481
5482
  checkedRows,
5482
- setCheckedRows
5483
+ setCheckedRows: (rowsSet) => {
5484
+ setCheckedRows(rowsSet);
5485
+ onCheckedRowsChange == null ? void 0 : onCheckedRowsChange(getCheckedRowData(rowsSet));
5486
+ }
5483
5487
  }),
5484
5488
  [checkedRows]
5485
5489
  );
@@ -5489,14 +5493,17 @@ var Table = (0, import_react5.forwardRef)((originalProps, ref) => {
5489
5493
  const handleAllRowCheck = (checked) => {
5490
5494
  const updated = checked ? new Set(rows.map((_, i) => i)) : /* @__PURE__ */ new Set();
5491
5495
  setCheckedRows(updated);
5496
+ onCheckedRowsChange == null ? void 0 : onCheckedRowsChange(getCheckedRowData(updated));
5492
5497
  };
5493
5498
  const handleRowCheck = (index, checked) => {
5494
5499
  setCheckedRows((prev) => {
5495
5500
  const updated = new Set(prev);
5496
5501
  checked ? updated.add(index) : updated.delete(index);
5502
+ onCheckedRowsChange == null ? void 0 : onCheckedRowsChange(getCheckedRowData(updated));
5497
5503
  return updated;
5498
5504
  });
5499
5505
  };
5506
+ const getCheckedRowData = (checked) => Array.from(checked).map((index) => rows[index]).filter((row) => row !== void 0);
5500
5507
  const slots = (0, import_react5.useMemo)(() => tableStyle(variantProps), [variantProps]);
5501
5508
  return /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("div", { ref: divRef, "data-table": "base", className: slots.base({ class: classNames == null ? void 0 : classNames.base }), children: [
5502
5509
  /* @__PURE__ */ (0, import_jsx_runtime10.jsx)(scrollArea_default, { direction: "x", size: size === "xl" ? "lg" : size, children: /* @__PURE__ */ (0, import_jsx_runtime10.jsxs)("table", { className: slots.table({ class: classNames == null ? void 0 : classNames.table }), children: [
@@ -1,26 +1,26 @@
1
1
  "use client";
2
2
  import {
3
3
  table_default
4
- } from "../../chunk-2M5G4MRK.mjs";
5
- import "../../chunk-LWRK5TPZ.mjs";
6
- import "../../chunk-P7YYNA6L.mjs";
4
+ } from "../../chunk-4LOREVB7.mjs";
5
+ import "../../chunk-MFRYYZPY.mjs";
6
+ import "../../chunk-SBL6IHEW.mjs";
7
7
  import "../../chunk-DQRAFUDA.mjs";
8
8
  import "../../chunk-M37VBNB3.mjs";
9
9
  import "../../chunk-MZ76AA76.mjs";
10
10
  import "../../chunk-6PN3DGOE.mjs";
11
11
  import "../../chunk-7B7LRG5J.mjs";
12
- import "../../chunk-MCNCHQ33.mjs";
12
+ import "../../chunk-ZSG4NGLK.mjs";
13
13
  import "../../chunk-F3HENRVM.mjs";
14
14
  import "../../chunk-2GCSFWHD.mjs";
15
- import "../../chunk-GH6CPGFN.mjs";
15
+ import "../../chunk-R62HK726.mjs";
16
16
  import "../../chunk-QZ3LVYJW.mjs";
17
- import "../../chunk-D6QI3DJG.mjs";
17
+ import "../../chunk-YLRYHUTW.mjs";
18
18
  import "../../chunk-ZYIIXWVY.mjs";
19
19
  import "../../chunk-2TKEWFGH.mjs";
20
20
  import "../../chunk-2SDYFOZL.mjs";
21
- import "../../chunk-4ZJFD3L3.mjs";
22
21
  import "../../chunk-27Y6K5NK.mjs";
23
22
  import "../../chunk-E3G5QXSH.mjs";
23
+ import "../../chunk-4ZJFD3L3.mjs";
24
24
  import "../../chunk-AC6TWLRT.mjs";
25
25
  export {
26
26
  table_default as default
@@ -2,9 +2,9 @@
2
2
  import "../../chunk-3MY6LO7N.mjs";
3
3
  import {
4
4
  tabs_default
5
- } from "../../chunk-2YMAKIZ6.mjs";
6
- import "../../chunk-4ZJFD3L3.mjs";
5
+ } from "../../chunk-SSMMWMQC.mjs";
7
6
  import "../../chunk-E3G5QXSH.mjs";
7
+ import "../../chunk-4ZJFD3L3.mjs";
8
8
  import "../../chunk-AC6TWLRT.mjs";
9
9
  export {
10
10
  tabs_default as Tabs
@@ -2,9 +2,9 @@
2
2
  import {
3
3
  tabs,
4
4
  tabs_default
5
- } from "../../chunk-2YMAKIZ6.mjs";
6
- import "../../chunk-4ZJFD3L3.mjs";
5
+ } from "../../chunk-SSMMWMQC.mjs";
7
6
  import "../../chunk-E3G5QXSH.mjs";
7
+ import "../../chunk-4ZJFD3L3.mjs";
8
8
  import "../../chunk-AC6TWLRT.mjs";
9
9
  export {
10
10
  tabs_default as default,
@@ -3,17 +3,17 @@ import "../../chunk-LUWGOKLG.mjs";
3
3
  import {
4
4
  ToastProvider,
5
5
  useToast
6
- } from "../../chunk-IBI3OVQI.mjs";
6
+ } from "../../chunk-BB7MFKNQ.mjs";
7
7
  import "../../chunk-ZOTHPHXA.mjs";
8
8
  import {
9
9
  toast_default
10
- } from "../../chunk-MEY4IL7D.mjs";
10
+ } from "../../chunk-7W2ZI2DD.mjs";
11
11
  import "../../chunk-ZYIIXWVY.mjs";
12
12
  import "../../chunk-2TKEWFGH.mjs";
13
13
  import "../../chunk-2SDYFOZL.mjs";
14
- import "../../chunk-4ZJFD3L3.mjs";
15
14
  import "../../chunk-27Y6K5NK.mjs";
16
15
  import "../../chunk-E3G5QXSH.mjs";
16
+ import "../../chunk-4ZJFD3L3.mjs";
17
17
  import "../../chunk-AC6TWLRT.mjs";
18
18
  export {
19
19
  toast_default as Toast,
@@ -1,13 +1,13 @@
1
1
  "use client";
2
2
  import {
3
3
  toast_default
4
- } from "../../chunk-MEY4IL7D.mjs";
4
+ } from "../../chunk-7W2ZI2DD.mjs";
5
5
  import "../../chunk-ZYIIXWVY.mjs";
6
6
  import "../../chunk-2TKEWFGH.mjs";
7
7
  import "../../chunk-2SDYFOZL.mjs";
8
- import "../../chunk-4ZJFD3L3.mjs";
9
8
  import "../../chunk-27Y6K5NK.mjs";
10
9
  import "../../chunk-E3G5QXSH.mjs";
10
+ import "../../chunk-4ZJFD3L3.mjs";
11
11
  import "../../chunk-AC6TWLRT.mjs";
12
12
  export {
13
13
  toast_default as default
@@ -2,15 +2,15 @@
2
2
  import {
3
3
  ToastProvider,
4
4
  useToast
5
- } from "../../chunk-IBI3OVQI.mjs";
5
+ } from "../../chunk-BB7MFKNQ.mjs";
6
6
  import "../../chunk-ZOTHPHXA.mjs";
7
- import "../../chunk-MEY4IL7D.mjs";
7
+ import "../../chunk-7W2ZI2DD.mjs";
8
8
  import "../../chunk-ZYIIXWVY.mjs";
9
9
  import "../../chunk-2TKEWFGH.mjs";
10
10
  import "../../chunk-2SDYFOZL.mjs";
11
- import "../../chunk-4ZJFD3L3.mjs";
12
11
  import "../../chunk-27Y6K5NK.mjs";
13
12
  import "../../chunk-E3G5QXSH.mjs";
13
+ import "../../chunk-4ZJFD3L3.mjs";
14
14
  import "../../chunk-AC6TWLRT.mjs";
15
15
  export {
16
16
  ToastProvider,
@@ -2,11 +2,11 @@
2
2
  import "../../chunk-HIE2YRGA.mjs";
3
3
  import {
4
4
  tooltip_default
5
- } from "../../chunk-Z2537DF6.mjs";
5
+ } from "../../chunk-IL5ENWCR.mjs";
6
6
  import "../../chunk-ZMOAFSYE.mjs";
7
7
  import "../../chunk-WSIADHVC.mjs";
8
- import "../../chunk-4ZJFD3L3.mjs";
9
8
  import "../../chunk-E3G5QXSH.mjs";
9
+ import "../../chunk-4ZJFD3L3.mjs";
10
10
  import "../../chunk-AC6TWLRT.mjs";
11
11
  export {
12
12
  tooltip_default as Tooltip
@@ -1,11 +1,11 @@
1
1
  "use client";
2
2
  import {
3
3
  tooltip_default
4
- } from "../../chunk-Z2537DF6.mjs";
4
+ } from "../../chunk-IL5ENWCR.mjs";
5
5
  import "../../chunk-ZMOAFSYE.mjs";
6
6
  import "../../chunk-WSIADHVC.mjs";
7
- import "../../chunk-4ZJFD3L3.mjs";
8
7
  import "../../chunk-E3G5QXSH.mjs";
8
+ import "../../chunk-4ZJFD3L3.mjs";
9
9
  import "../../chunk-AC6TWLRT.mjs";
10
10
  export {
11
11
  tooltip_default as default
@@ -2,12 +2,12 @@
2
2
  import "../../chunk-MBLZYQCN.mjs";
3
3
  import {
4
4
  tree_default
5
- } from "../../chunk-NFQMXW4Z.mjs";
5
+ } from "../../chunk-WPIFIRCJ.mjs";
6
6
  import "../../chunk-ZYIIXWVY.mjs";
7
7
  import "../../chunk-2TKEWFGH.mjs";
8
8
  import "../../chunk-2SDYFOZL.mjs";
9
- import "../../chunk-4ZJFD3L3.mjs";
10
9
  import "../../chunk-27Y6K5NK.mjs";
10
+ import "../../chunk-4ZJFD3L3.mjs";
11
11
  import "../../chunk-AC6TWLRT.mjs";
12
12
  export {
13
13
  tree_default as Tree
@@ -2,12 +2,12 @@
2
2
  import {
3
3
  Tree,
4
4
  tree_default
5
- } from "../../chunk-NFQMXW4Z.mjs";
5
+ } from "../../chunk-WPIFIRCJ.mjs";
6
6
  import "../../chunk-ZYIIXWVY.mjs";
7
7
  import "../../chunk-2TKEWFGH.mjs";
8
8
  import "../../chunk-2SDYFOZL.mjs";
9
- import "../../chunk-4ZJFD3L3.mjs";
10
9
  import "../../chunk-27Y6K5NK.mjs";
10
+ import "../../chunk-4ZJFD3L3.mjs";
11
11
  import "../../chunk-AC6TWLRT.mjs";
12
12
  export {
13
13
  Tree,
package/dist/index.js CHANGED
@@ -7453,7 +7453,8 @@ var Table = (0, import_react15.forwardRef)((originalProps, ref) => {
7453
7453
  classNames,
7454
7454
  color,
7455
7455
  size,
7456
- skeletonRow
7456
+ skeletonRow,
7457
+ onCheckedRowsChange
7457
7458
  } = { ...props, ...variantProps };
7458
7459
  const { page = 1, perPage = 15 } = pagination || {};
7459
7460
  const showPagination = pagination && totalData > 0 && !isLoading;
@@ -7463,7 +7464,10 @@ var Table = (0, import_react15.forwardRef)((originalProps, ref) => {
7463
7464
  ref,
7464
7465
  () => ({
7465
7466
  checkedRows,
7466
- setCheckedRows
7467
+ setCheckedRows: (rowsSet) => {
7468
+ setCheckedRows(rowsSet);
7469
+ onCheckedRowsChange == null ? void 0 : onCheckedRowsChange(getCheckedRowData(rowsSet));
7470
+ }
7467
7471
  }),
7468
7472
  [checkedRows]
7469
7473
  );
@@ -7473,14 +7477,17 @@ var Table = (0, import_react15.forwardRef)((originalProps, ref) => {
7473
7477
  const handleAllRowCheck = (checked) => {
7474
7478
  const updated = checked ? new Set(rows.map((_, i) => i)) : /* @__PURE__ */ new Set();
7475
7479
  setCheckedRows(updated);
7480
+ onCheckedRowsChange == null ? void 0 : onCheckedRowsChange(getCheckedRowData(updated));
7476
7481
  };
7477
7482
  const handleRowCheck = (index, checked) => {
7478
7483
  setCheckedRows((prev) => {
7479
7484
  const updated = new Set(prev);
7480
7485
  checked ? updated.add(index) : updated.delete(index);
7486
+ onCheckedRowsChange == null ? void 0 : onCheckedRowsChange(getCheckedRowData(updated));
7481
7487
  return updated;
7482
7488
  });
7483
7489
  };
7490
+ const getCheckedRowData = (checked) => Array.from(checked).map((index) => rows[index]).filter((row) => row !== void 0);
7484
7491
  const slots = (0, import_react15.useMemo)(() => tableStyle(variantProps), [variantProps]);
7485
7492
  return /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("div", { ref: divRef, "data-table": "base", className: slots.base({ class: classNames == null ? void 0 : classNames.base }), children: [
7486
7493
  /* @__PURE__ */ (0, import_jsx_runtime20.jsx)(scrollArea_default, { direction: "x", size: size === "xl" ? "lg" : size, children: /* @__PURE__ */ (0, import_jsx_runtime20.jsxs)("table", { className: slots.table({ class: classNames == null ? void 0 : classNames.table }), children: [
@@ -7783,7 +7790,7 @@ var import_react17 = require("react");
7783
7790
  var import_react_dom = require("react-dom");
7784
7791
  var import_jsx_runtime22 = require("react/jsx-runtime");
7785
7792
  var Select = (0, import_react17.forwardRef)((originalProps, ref) => {
7786
- var _a;
7793
+ var _a, _b;
7787
7794
  const [props, variantProps] = mapPropsVariants(originalProps, select.variantKeys);
7788
7795
  const {
7789
7796
  label,
@@ -7859,6 +7866,7 @@ var Select = (0, import_react17.forwardRef)((originalProps, ref) => {
7859
7866
  }, [targetRect]);
7860
7867
  const position = targetRect ? calculatePositionWithScroll(targetRect, optionWrapperHeight) : null;
7861
7868
  const displayValue = multiple ? selectedOptions.map((opt) => opt.label).join(", ") : ((_a = selectedOptions[0]) == null ? void 0 : _a.label) || "";
7869
+ const selectedValue = multiple ? selectedOptions.map((opt) => opt.value).join(", ") : ((_b = selectedOptions[0]) == null ? void 0 : _b.value) || "";
7862
7870
  const Option = ({
7863
7871
  option,
7864
7872
  isSelected,
@@ -7904,11 +7912,13 @@ var Select = (0, import_react17.forwardRef)((originalProps, ref) => {
7904
7912
  slots.select({ class: classNames == null ? void 0 : classNames.select }),
7905
7913
  inputProps.readOnly ? "!text-body-foreground placeholder:text-body-foreground" : ""
7906
7914
  ),
7915
+ name: void 0,
7907
7916
  value: displayValue,
7908
7917
  readOnly: true,
7909
7918
  size: 0
7910
7919
  }
7911
7920
  ),
7921
+ /* @__PURE__ */ (0, import_jsx_runtime22.jsx)("input", { type: "hidden", name: inputProps.name, value: selectedValue }),
7912
7922
  /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
7913
7923
  Icon_default,
7914
7924
  {
@@ -7916,16 +7926,7 @@ var Select = (0, import_react17.forwardRef)((originalProps, ref) => {
7916
7926
  size: originalProps.size,
7917
7927
  className: `transition-transform duration-200 ${isOpen ? "rotate-0" : "rotate-180"}`
7918
7928
  }
7919
- ),
7920
- selectedOptions.map((opt, index) => /* @__PURE__ */ (0, import_jsx_runtime22.jsx)(
7921
- "input",
7922
- {
7923
- type: "hidden",
7924
- name: multiple ? `${inputProps.name}[]` : inputProps.name,
7925
- value: opt.value
7926
- },
7927
- index
7928
- ))
7929
+ )
7929
7930
  ]
7930
7931
  }
7931
7932
  ),