@dmsi/wedgekit-react 0.0.411 → 0.0.412

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 (35) hide show
  1. package/dist/components/CalendarRange.cjs +46 -71
  2. package/dist/components/CalendarRange.js +1 -6
  3. package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.cjs +4 -29
  4. package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.js +1 -6
  5. package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.cjs +13 -38
  6. package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.js +1 -6
  7. package/dist/components/DataGrid/PinnedColumns.cjs +29 -54
  8. package/dist/components/DataGrid/PinnedColumns.js +1 -6
  9. package/dist/components/DataGrid/TableBody/LoadingCell.cjs +5 -30
  10. package/dist/components/DataGrid/TableBody/LoadingCell.js +1 -6
  11. package/dist/components/DataGrid/TableBody/TableBodyRow.cjs +11 -36
  12. package/dist/components/DataGrid/TableBody/TableBodyRow.js +1 -6
  13. package/dist/components/DataGrid/TableBody/index.cjs +26 -51
  14. package/dist/components/DataGrid/TableBody/index.js +1 -6
  15. package/dist/components/DataGrid/index.cjs +115 -140
  16. package/dist/components/DataGrid/index.js +1 -6
  17. package/dist/components/DataGrid/utils.cjs +5 -30
  18. package/dist/components/DataGrid/utils.js +1 -6
  19. package/dist/components/DateInput.cjs +65 -90
  20. package/dist/components/DateInput.js +1 -6
  21. package/dist/components/DateRangeInput.cjs +65 -90
  22. package/dist/components/DateRangeInput.js +1 -6
  23. package/dist/components/MobileDataGrid/ColumnSelector/index.cjs +12 -37
  24. package/dist/components/MobileDataGrid/ColumnSelector/index.js +1 -6
  25. package/dist/components/MobileDataGrid/MobileDataGridHeader.cjs +20 -45
  26. package/dist/components/MobileDataGrid/MobileDataGridHeader.js +1 -6
  27. package/dist/components/MobileDataGrid/index.cjs +499 -524
  28. package/dist/components/MobileDataGrid/index.js +1 -6
  29. package/dist/components/PDFViewer/index.js +109 -6
  30. package/dist/components/index.cjs +0 -286
  31. package/dist/components/index.js +1 -9
  32. package/package.json +1 -1
  33. package/src/components/index.ts +0 -1
  34. package/dist/chunk-LLZ3SSZJ.js +0 -114
  35. /package/dist/{chunk-OW3WN3JV.js → chunk-OBY5EH47.js} +0 -0
@@ -4410,50 +4410,25 @@ var import_react29 = require("react");
4410
4410
  var import_clsx32 = __toESM(require("clsx"), 1);
4411
4411
  var import_jsx_runtime48 = require("react/jsx-runtime");
4412
4412
 
4413
- // src/components/PDFViewer/index.tsx
4414
- var import_react32 = require("react");
4415
-
4416
- // src/components/PDFViewer/PDFElement.tsx
4417
- var import_react_pdf2 = require("@mikecousins/react-pdf");
4418
- var import_react31 = require("react");
4419
-
4420
- // src/components/PDFViewer/PDFPage.tsx
4421
- var import_react_pdf = require("@mikecousins/react-pdf");
4422
- var import_react30 = require("react");
4423
- var import_jsx_runtime49 = require("react/jsx-runtime");
4424
-
4425
- // src/components/PDFViewer/PDFElement.tsx
4426
- var import_clsx33 = __toESM(require("clsx"), 1);
4427
- var import_jsx_runtime50 = require("react/jsx-runtime");
4428
-
4429
- // src/components/PDFViewer/DownloadIcon.tsx
4430
- var import_jsx_runtime51 = require("react/jsx-runtime");
4431
-
4432
- // src/components/PDFViewer/PDFNavigation.tsx
4433
- var import_jsx_runtime52 = require("react/jsx-runtime");
4434
-
4435
- // src/components/PDFViewer/index.tsx
4436
- var import_jsx_runtime53 = require("react/jsx-runtime");
4437
-
4438
4413
  // src/components/DataGrid/PinnedColumns.tsx
4439
- var import_clsx34 = __toESM(require("clsx"), 1);
4440
- var import_react35 = __toESM(require("react"), 1);
4414
+ var import_clsx33 = __toESM(require("clsx"), 1);
4415
+ var import_react32 = __toESM(require("react"), 1);
4441
4416
 
4442
4417
  // src/components/DataGrid/ColumnSelectorHeaderCell/index.tsx
4443
- var import_react34 = require("react");
4418
+ var import_react31 = require("react");
4444
4419
 
4445
4420
  // src/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.tsx
4446
- var import_react33 = require("react");
4447
- var import_jsx_runtime54 = require("react/jsx-runtime");
4421
+ var import_react30 = require("react");
4422
+ var import_jsx_runtime49 = require("react/jsx-runtime");
4448
4423
  function ColumnSelectorMenuOption({
4449
4424
  id,
4450
4425
  testid,
4451
4426
  column,
4452
4427
  toggleColumnVisibility
4453
4428
  }) {
4454
- const [isVisible, setIsVisible] = (0, import_react33.useState)(column.getIsVisible());
4429
+ const [isVisible, setIsVisible] = (0, import_react30.useState)(column.getIsVisible());
4455
4430
  const label = typeof column.columnDef.header === "string" ? column.columnDef.header : null;
4456
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(MenuOption, { id, testid, defaultChecked: isVisible, children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4431
+ return /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(MenuOption, { id, testid, defaultChecked: isVisible, children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
4457
4432
  Checkbox,
4458
4433
  {
4459
4434
  id: id ? `${id}-checkbox` : void 0,
@@ -4469,7 +4444,7 @@ function ColumnSelectorMenuOption({
4469
4444
  }
4470
4445
 
4471
4446
  // src/components/DataGrid/ColumnSelectorHeaderCell/index.tsx
4472
- var import_jsx_runtime55 = require("react/jsx-runtime");
4447
+ var import_jsx_runtime50 = require("react/jsx-runtime");
4473
4448
  function ColumnSelectorHeaderCell({
4474
4449
  id,
4475
4450
  testid,
@@ -4477,9 +4452,9 @@ function ColumnSelectorHeaderCell({
4477
4452
  toggleColumnVisibility,
4478
4453
  resetColumnVisibility
4479
4454
  }) {
4480
- const ref = (0, import_react34.useRef)(null);
4481
- const [show, setShow] = (0, import_react34.useState)(false);
4482
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
4455
+ const ref = (0, import_react31.useRef)(null);
4456
+ const [show, setShow] = (0, import_react31.useState)(false);
4457
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(
4483
4458
  DataGridCell,
4484
4459
  {
4485
4460
  id,
@@ -4489,7 +4464,7 @@ function ColumnSelectorHeaderCell({
4489
4464
  color: "text-secondary-normal",
4490
4465
  ref,
4491
4466
  children: [
4492
- /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4467
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
4493
4468
  Button,
4494
4469
  {
4495
4470
  id: id ? `${id}-button` : void 0,
@@ -4497,10 +4472,10 @@ function ColumnSelectorHeaderCell({
4497
4472
  onClick: () => setShow((prev) => !prev),
4498
4473
  variant: "navigation",
4499
4474
  iconOnly: true,
4500
- leftIcon: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(Icon, { name: "tune" })
4475
+ leftIcon: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(Icon, { name: "tune" })
4501
4476
  }
4502
4477
  ),
4503
- /* @__PURE__ */ (0, import_jsx_runtime55.jsxs)(
4478
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsxs)(
4504
4479
  Menu,
4505
4480
  {
4506
4481
  id: id ? `${id}-menu` : void 0,
@@ -4511,7 +4486,7 @@ function ColumnSelectorHeaderCell({
4511
4486
  setShow,
4512
4487
  calculateMinMaxHeight: true,
4513
4488
  children: [
4514
- /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4489
+ /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
4515
4490
  Button,
4516
4491
  {
4517
4492
  id: id ? `${id}-reset-button` : void 0,
@@ -4527,7 +4502,7 @@ function ColumnSelectorHeaderCell({
4527
4502
  table.getAllColumns().filter((x) => {
4528
4503
  var _a;
4529
4504
  return (_a = x.columnDef.meta) == null ? void 0 : _a.inVisibilityMenu;
4530
- }).map((column) => /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4505
+ }).map((column) => /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
4531
4506
  ColumnSelectorMenuOption,
4532
4507
  {
4533
4508
  id: id ? `${id}-option-${column.id}` : void 0,
@@ -4546,7 +4521,7 @@ function ColumnSelectorHeaderCell({
4546
4521
  }
4547
4522
 
4548
4523
  // src/components/DataGrid/PinnedColumns.tsx
4549
- var import_jsx_runtime56 = require("react/jsx-runtime");
4524
+ var import_jsx_runtime51 = require("react/jsx-runtime");
4550
4525
  function PinnedColumns(_a) {
4551
4526
  var _b = _a, {
4552
4527
  id,
@@ -4578,17 +4553,17 @@ function PinnedColumns(_a) {
4578
4553
  const pinnedTestId = testid ? `${pinDirection}-pinned-${testid}` : void 0;
4579
4554
  const hasAnyHeaders = ((_a2 = headerGroups[0]) == null ? void 0 : _a2.headers.length) > 0;
4580
4555
  if (!hasAnyHeaders && !enableColumnSelector) return;
4581
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(
4556
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(
4582
4557
  "table",
4583
4558
  {
4584
- className: (0, import_clsx34.default)(
4559
+ className: (0, import_clsx33.default)(
4585
4560
  "flex flex-col min-h-min sticky z-20",
4586
4561
  pinDirection === "left" ? "left-0" : "right-0"
4587
4562
  ),
4588
4563
  "data-testid": pinnedTestId,
4589
4564
  children: [
4590
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("thead", { className: "sticky top-0 z-20 grid", children: headerGroups.map((headerGroup) => {
4591
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(
4565
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("thead", { className: "sticky top-0 z-20 grid", children: headerGroups.map((headerGroup) => {
4566
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(
4592
4567
  "tr",
4593
4568
  {
4594
4569
  "data-testid": pinnedTestId ? `${pinnedTestId}-header-row-${headerGroup.id}` : void 0,
@@ -4601,7 +4576,7 @@ function PinnedColumns(_a) {
4601
4576
  }
4602
4577
  if (typeof header.column.columnDef.header === "string") {
4603
4578
  const customHeaderWidth = (_a3 = header.column.columnDef.meta) == null ? void 0 : _a3.headerWidth;
4604
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(
4579
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(
4605
4580
  DataCellHeader,
4606
4581
  {
4607
4582
  locked: true,
@@ -4609,16 +4584,16 @@ function PinnedColumns(_a) {
4609
4584
  header,
4610
4585
  center: centerHeader,
4611
4586
  width: customHeaderWidth,
4612
- className: (0, import_clsx34.default)(
4587
+ className: (0, import_clsx33.default)(
4613
4588
  header.column.getCanSort() ? "cursor-pointer" : "cursor-grab",
4614
4589
  "group"
4615
4590
  ),
4616
4591
  children: [
4617
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(Subheader, { tall: true, children: header.column.columnDef.header }),
4592
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(Subheader, { tall: true, children: header.column.columnDef.header }),
4618
4593
  getSortIcon(header.column.getIsSorted()),
4619
4594
  !header.column.getIsSorted() && header.column.getCanSort() && getSortIcon(header.column.getNextSortingOrder(), true),
4620
- header.column.getSortIndex() !== -1 && table.getState().sorting.length > 1 && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(Subheader, { tall: true, children: header.column.getSortIndex() + 1 }),
4621
- !((_b2 = header.column.columnDef.meta) == null ? void 0 : _b2.locked) && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4595
+ header.column.getSortIndex() !== -1 && table.getState().sorting.length > 1 && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(Subheader, { tall: true, children: header.column.getSortIndex() + 1 }),
4596
+ !((_b2 = header.column.columnDef.meta) == null ? void 0 : _b2.locked) && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4622
4597
  "div",
4623
4598
  {
4624
4599
  onDoubleClick: (e) => {
@@ -4641,7 +4616,7 @@ function PinnedColumns(_a) {
4641
4616
  header.id
4642
4617
  );
4643
4618
  }
4644
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_react35.default.Fragment, { children: ((_c = header.column.columnDef.meta) == null ? void 0 : _c.checkbox) ? /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(DataGridCell, { type: "header", component: "checkbox", locked: true, children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4619
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_react32.default.Fragment, { children: ((_c = header.column.columnDef.meta) == null ? void 0 : _c.checkbox) ? /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(DataGridCell, { type: "header", component: "checkbox", locked: true, children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4645
4620
  Checkbox,
4646
4621
  {
4647
4622
  checked: allSelectedAcrossPages,
@@ -4653,7 +4628,7 @@ function PinnedColumns(_a) {
4653
4628
  header.getContext()
4654
4629
  ) }, header.id);
4655
4630
  }),
4656
- enableColumnSelector && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4631
+ enableColumnSelector && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4657
4632
  ColumnSelectorHeaderCell,
4658
4633
  {
4659
4634
  id: id ? `${id}-column-selector` : void 0,
@@ -4670,7 +4645,7 @@ function PinnedColumns(_a) {
4670
4645
  headerGroup.id
4671
4646
  );
4672
4647
  }) }),
4673
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4648
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4674
4649
  TableBody,
4675
4650
  __spreadProps(__spreadValues({
4676
4651
  testid: pinnedTestId
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  PinnedColumns
3
- } from "../../chunk-OW3WN3JV.js";
3
+ } from "../../chunk-OBY5EH47.js";
4
4
  import "../../chunk-M7INAUAJ.js";
5
5
  import "../../chunk-6I5LZ2ZC.js";
6
6
  import "../../chunk-44TDIHUP.js";
@@ -8,11 +8,6 @@ import "../../chunk-LZGYABCX.js";
8
8
  import "../../chunk-G5DEC7H3.js";
9
9
  import "../../chunk-3X3Y4TMS.js";
10
10
  import "../../chunk-BQNPOGD5.js";
11
- import "../../chunk-LLZ3SSZJ.js";
12
- import "../../chunk-EJSPFQCY.js";
13
- import "../../chunk-ERW5DEIO.js";
14
- import "../../chunk-2HMCS25C.js";
15
- import "../../chunk-VJVY6NPF.js";
16
11
  import "../../chunk-MBZ55T2D.js";
17
12
  import "../../chunk-2IKT6IHB.js";
18
13
  import "../../chunk-AA6GE3TH.js";
@@ -4627,33 +4627,8 @@ var import_react32 = require("react");
4627
4627
  var import_clsx33 = __toESM(require("clsx"), 1);
4628
4628
  var import_jsx_runtime50 = require("react/jsx-runtime");
4629
4629
 
4630
- // src/components/PDFViewer/index.tsx
4631
- var import_react35 = require("react");
4632
-
4633
- // src/components/PDFViewer/PDFElement.tsx
4634
- var import_react_pdf2 = require("@mikecousins/react-pdf");
4635
- var import_react34 = require("react");
4636
-
4637
- // src/components/PDFViewer/PDFPage.tsx
4638
- var import_react_pdf = require("@mikecousins/react-pdf");
4639
- var import_react33 = require("react");
4640
- var import_jsx_runtime51 = require("react/jsx-runtime");
4641
-
4642
- // src/components/PDFViewer/PDFElement.tsx
4643
- var import_clsx34 = __toESM(require("clsx"), 1);
4644
- var import_jsx_runtime52 = require("react/jsx-runtime");
4645
-
4646
- // src/components/PDFViewer/DownloadIcon.tsx
4647
- var import_jsx_runtime53 = require("react/jsx-runtime");
4648
-
4649
- // src/components/PDFViewer/PDFNavigation.tsx
4650
- var import_jsx_runtime54 = require("react/jsx-runtime");
4651
-
4652
- // src/components/PDFViewer/index.tsx
4653
- var import_jsx_runtime55 = require("react/jsx-runtime");
4654
-
4655
4630
  // src/components/DataGrid/TableBody/LoadingCell.tsx
4656
- var import_jsx_runtime56 = require("react/jsx-runtime");
4631
+ var import_jsx_runtime51 = require("react/jsx-runtime");
4657
4632
  function LoadingCell({
4658
4633
  id,
4659
4634
  testid,
@@ -4661,16 +4636,16 @@ function LoadingCell({
4661
4636
  }) {
4662
4637
  const key = `loading-${column.id}`;
4663
4638
  if (column.cell === "checkbox") {
4664
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(DataGridCell, { id: id ? `${id}-${key}` : void 0, testid: testid ? `${testid}-${key}` : void 0, children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(Checkbox, { id: id ? `${id}-${key}-checkbox` : void 0, testid: testid ? `${testid}-${key}-checkbox` : void 0, disabled: true }) }, key);
4639
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(DataGridCell, { id: id ? `${id}-${key}` : void 0, testid: testid ? `${testid}-${key}` : void 0, children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(Checkbox, { id: id ? `${id}-${key}-checkbox` : void 0, testid: testid ? `${testid}-${key}-checkbox` : void 0, disabled: true }) }, key);
4665
4640
  }
4666
4641
  if (column.cell === "input") {
4667
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4642
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4668
4643
  DataGridCell,
4669
4644
  {
4670
4645
  id: id ? `${id}-${key}` : void 0,
4671
4646
  testid: testid ? `${testid}-${key}` : void 0,
4672
4647
  component: "input",
4673
- children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4648
+ children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4674
4649
  Input,
4675
4650
  {
4676
4651
  id: id ? `${id}-${key}-input` : void 0,
@@ -4684,7 +4659,7 @@ function LoadingCell({
4684
4659
  key
4685
4660
  );
4686
4661
  }
4687
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(DataGridCell, { id: id ? `${id}-${key}` : void 0, testid: testid ? `${testid}-${key}` : void 0, children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("div", { className: "bg-linear-270 to-neutral-300/[24%] from-neutral-300/[12%] rounded-xs w-full max-w-25 h-6" }) }, key);
4662
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(DataGridCell, { id: id ? `${id}-${key}` : void 0, testid: testid ? `${testid}-${key}` : void 0, children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("div", { className: "bg-linear-270 to-neutral-300/[24%] from-neutral-300/[12%] rounded-xs w-full max-w-25 h-6" }) }, key);
4688
4663
  }
4689
4664
  // Annotate the CommonJS export names for ESM import in node:
4690
4665
  0 && (module.exports = {
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  LoadingCell
3
- } from "../../../chunk-OW3WN3JV.js";
3
+ } from "../../../chunk-OBY5EH47.js";
4
4
  import "../../../chunk-M7INAUAJ.js";
5
5
  import "../../../chunk-6I5LZ2ZC.js";
6
6
  import "../../../chunk-44TDIHUP.js";
@@ -8,11 +8,6 @@ import "../../../chunk-LZGYABCX.js";
8
8
  import "../../../chunk-G5DEC7H3.js";
9
9
  import "../../../chunk-3X3Y4TMS.js";
10
10
  import "../../../chunk-BQNPOGD5.js";
11
- import "../../../chunk-LLZ3SSZJ.js";
12
- import "../../../chunk-EJSPFQCY.js";
13
- import "../../../chunk-ERW5DEIO.js";
14
- import "../../../chunk-2HMCS25C.js";
15
- import "../../../chunk-VJVY6NPF.js";
16
11
  import "../../../chunk-MBZ55T2D.js";
17
12
  import "../../../chunk-2IKT6IHB.js";
18
13
  import "../../../chunk-AA6GE3TH.js";
@@ -62,9 +62,9 @@ __export(TableBodyRow_exports, {
62
62
  TableBodyRow: () => TableBodyRow
63
63
  });
64
64
  module.exports = __toCommonJS(TableBodyRow_exports);
65
- var import_clsx34 = __toESM(require("clsx"), 1);
65
+ var import_clsx33 = __toESM(require("clsx"), 1);
66
66
  var import_react_table3 = require("@tanstack/react-table");
67
- var import_react35 = __toESM(require("react"), 1);
67
+ var import_react32 = __toESM(require("react"), 1);
68
68
 
69
69
  // src/components/DataGridCell.tsx
70
70
  var import_sortable = require("@dnd-kit/sortable");
@@ -4561,33 +4561,8 @@ var import_react31 = require("react");
4561
4561
  var import_clsx32 = __toESM(require("clsx"), 1);
4562
4562
  var import_jsx_runtime50 = require("react/jsx-runtime");
4563
4563
 
4564
- // src/components/PDFViewer/index.tsx
4565
- var import_react34 = require("react");
4566
-
4567
- // src/components/PDFViewer/PDFElement.tsx
4568
- var import_react_pdf2 = require("@mikecousins/react-pdf");
4569
- var import_react33 = require("react");
4570
-
4571
- // src/components/PDFViewer/PDFPage.tsx
4572
- var import_react_pdf = require("@mikecousins/react-pdf");
4573
- var import_react32 = require("react");
4574
- var import_jsx_runtime51 = require("react/jsx-runtime");
4575
-
4576
- // src/components/PDFViewer/PDFElement.tsx
4577
- var import_clsx33 = __toESM(require("clsx"), 1);
4578
- var import_jsx_runtime52 = require("react/jsx-runtime");
4579
-
4580
- // src/components/PDFViewer/DownloadIcon.tsx
4581
- var import_jsx_runtime53 = require("react/jsx-runtime");
4582
-
4583
- // src/components/PDFViewer/PDFNavigation.tsx
4584
- var import_jsx_runtime54 = require("react/jsx-runtime");
4585
-
4586
- // src/components/PDFViewer/index.tsx
4587
- var import_jsx_runtime55 = require("react/jsx-runtime");
4588
-
4589
4564
  // src/components/DataGrid/TableBody/TableBodyRow.tsx
4590
- var import_jsx_runtime56 = require("react/jsx-runtime");
4565
+ var import_jsx_runtime51 = require("react/jsx-runtime");
4591
4566
  var valueFormatters = {
4592
4567
  date: (value) => typeof value === "string" ? formatDate(value) : "",
4593
4568
  currency: (value) => formatCurrencyDisplay(value)
@@ -4620,10 +4595,10 @@ function TableBodyRow({
4620
4595
  const columns = locked ? visibleCells : virtualColumns;
4621
4596
  const isError = typeof row.original === "object" && row.original !== null && "rowState" in row.original && row.original.rowState === "error";
4622
4597
  const CellElement = locked ? DataGridCell : DragAlongCell;
4623
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(
4598
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(
4624
4599
  "tr",
4625
4600
  {
4626
- className: (0, import_clsx34.default)(
4601
+ className: (0, import_clsx33.default)(
4627
4602
  "min-h-10",
4628
4603
  "transition-colors hover:bg-background-action-secondary-hover",
4629
4604
  row.getIsSelected() && "!bg-background-action-secondary-hover",
@@ -4641,7 +4616,7 @@ function TableBodyRow({
4641
4616
  children: [
4642
4617
  !locked && virtualPaddingLeft ? (
4643
4618
  // fake empty column to the left for virtualization scroll padding
4644
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("td", { style: { display: "flex", width: virtualPaddingLeft } })
4619
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("td", { style: { display: "flex", width: virtualPaddingLeft } })
4645
4620
  ) : null,
4646
4621
  columns.map((column) => {
4647
4622
  var _a2, _b, _c, _d;
@@ -4652,17 +4627,17 @@ function TableBodyRow({
4652
4627
  const cellFormat = (_a2 = cell.column.columnDef.meta) == null ? void 0 : _a2.format;
4653
4628
  const cellValue = cellFormat && isValueFormatterKey(cellFormat) ? valueFormatters[cellFormat](cell.getValue()) : cell.getValue();
4654
4629
  const cellAlignment = (_c = (_b = cell.column.columnDef.meta) == null ? void 0 : _b.align) != null ? _c : typeof cellValue === "number" ? "right" : "left";
4655
- return ((_d = cell.column.columnDef.meta) == null ? void 0 : _d.useCustomRenderer) ? /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(import_react35.default.Fragment, { children: (0, import_react_table3.flexRender)(cell.column.columnDef.cell, cell.getContext()) }, cell.id) : /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4630
+ return ((_d = cell.column.columnDef.meta) == null ? void 0 : _d.useCustomRenderer) ? /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(import_react32.default.Fragment, { children: (0, import_react_table3.flexRender)(cell.column.columnDef.cell, cell.getContext()) }, cell.id) : /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4656
4631
  CellElement,
4657
4632
  {
4658
4633
  id: id ? `${id}-row-${row.id}-cell-${cell.id}` : void 0,
4659
4634
  testid: testid ? `${testid}-row-${row.id}-cell-${cell.id}` : void 0,
4660
4635
  cell,
4661
- className: (0, import_clsx34.default)({
4636
+ className: (0, import_clsx33.default)({
4662
4637
  "justify-start": cellAlignment === "left",
4663
4638
  "justify-end": cellAlignment === "right"
4664
4639
  }),
4665
- children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4640
+ children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4666
4641
  Tooltip,
4667
4642
  {
4668
4643
  id: id ? `${id}-tooltip-${cell.id}` : void 0,
@@ -4670,7 +4645,7 @@ function TableBodyRow({
4670
4645
  showOnTruncation: true,
4671
4646
  message: cellValue,
4672
4647
  position: "bottom",
4673
- children: /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(Paragraph, { addOverflow: true, tall: true, children: cellValue })
4648
+ children: /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(Paragraph, { addOverflow: true, tall: true, children: cellValue })
4674
4649
  }
4675
4650
  )
4676
4651
  },
@@ -4679,7 +4654,7 @@ function TableBodyRow({
4679
4654
  }),
4680
4655
  !locked && virtualPaddingRight ? (
4681
4656
  // fake empty column to the right for virtualization scroll padding
4682
- /* @__PURE__ */ (0, import_jsx_runtime56.jsx)("td", { style: { display: "flex", width: virtualPaddingRight } })
4657
+ /* @__PURE__ */ (0, import_jsx_runtime51.jsx)("td", { style: { display: "flex", width: virtualPaddingRight } })
4683
4658
  ) : null
4684
4659
  ]
4685
4660
  },
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  TableBodyRow
3
- } from "../../../chunk-OW3WN3JV.js";
3
+ } from "../../../chunk-OBY5EH47.js";
4
4
  import "../../../chunk-M7INAUAJ.js";
5
5
  import "../../../chunk-6I5LZ2ZC.js";
6
6
  import "../../../chunk-44TDIHUP.js";
@@ -8,11 +8,6 @@ import "../../../chunk-LZGYABCX.js";
8
8
  import "../../../chunk-G5DEC7H3.js";
9
9
  import "../../../chunk-3X3Y4TMS.js";
10
10
  import "../../../chunk-BQNPOGD5.js";
11
- import "../../../chunk-LLZ3SSZJ.js";
12
- import "../../../chunk-EJSPFQCY.js";
13
- import "../../../chunk-ERW5DEIO.js";
14
- import "../../../chunk-2HMCS25C.js";
15
- import "../../../chunk-VJVY6NPF.js";
16
11
  import "../../../chunk-MBZ55T2D.js";
17
12
  import "../../../chunk-2IKT6IHB.js";
18
13
  import "../../../chunk-AA6GE3TH.js";
@@ -4380,39 +4380,14 @@ var import_react31 = require("react");
4380
4380
  var import_clsx31 = __toESM(require("clsx"), 1);
4381
4381
  var import_jsx_runtime48 = require("react/jsx-runtime");
4382
4382
 
4383
- // src/components/PDFViewer/index.tsx
4384
- var import_react34 = require("react");
4385
-
4386
- // src/components/PDFViewer/PDFElement.tsx
4387
- var import_react_pdf2 = require("@mikecousins/react-pdf");
4388
- var import_react33 = require("react");
4389
-
4390
- // src/components/PDFViewer/PDFPage.tsx
4391
- var import_react_pdf = require("@mikecousins/react-pdf");
4392
- var import_react32 = require("react");
4393
- var import_jsx_runtime49 = require("react/jsx-runtime");
4394
-
4395
- // src/components/PDFViewer/PDFElement.tsx
4396
- var import_clsx32 = __toESM(require("clsx"), 1);
4397
- var import_jsx_runtime50 = require("react/jsx-runtime");
4398
-
4399
- // src/components/PDFViewer/DownloadIcon.tsx
4400
- var import_jsx_runtime51 = require("react/jsx-runtime");
4401
-
4402
- // src/components/PDFViewer/PDFNavigation.tsx
4403
- var import_jsx_runtime52 = require("react/jsx-runtime");
4404
-
4405
- // src/components/PDFViewer/index.tsx
4406
- var import_jsx_runtime53 = require("react/jsx-runtime");
4407
-
4408
4383
  // src/components/DataGrid/TableBody/index.tsx
4409
- var import_clsx34 = __toESM(require("clsx"), 1);
4384
+ var import_clsx33 = __toESM(require("clsx"), 1);
4410
4385
 
4411
4386
  // src/components/DataGrid/TableBody/TableBodyRow.tsx
4412
- var import_clsx33 = __toESM(require("clsx"), 1);
4387
+ var import_clsx32 = __toESM(require("clsx"), 1);
4413
4388
  var import_react_table3 = require("@tanstack/react-table");
4414
- var import_react35 = __toESM(require("react"), 1);
4415
- var import_jsx_runtime54 = require("react/jsx-runtime");
4389
+ var import_react32 = __toESM(require("react"), 1);
4390
+ var import_jsx_runtime49 = require("react/jsx-runtime");
4416
4391
  var valueFormatters = {
4417
4392
  date: (value) => typeof value === "string" ? formatDate(value) : "",
4418
4393
  currency: (value) => formatCurrencyDisplay(value)
@@ -4445,10 +4420,10 @@ function TableBodyRow({
4445
4420
  const columns = locked ? visibleCells : virtualColumns;
4446
4421
  const isError = typeof row.original === "object" && row.original !== null && "rowState" in row.original && row.original.rowState === "error";
4447
4422
  const CellElement = locked ? DataGridCell : DragAlongCell;
4448
- return /* @__PURE__ */ (0, import_jsx_runtime54.jsxs)(
4423
+ return /* @__PURE__ */ (0, import_jsx_runtime49.jsxs)(
4449
4424
  "tr",
4450
4425
  {
4451
- className: (0, import_clsx33.default)(
4426
+ className: (0, import_clsx32.default)(
4452
4427
  "min-h-10",
4453
4428
  "transition-colors hover:bg-background-action-secondary-hover",
4454
4429
  row.getIsSelected() && "!bg-background-action-secondary-hover",
@@ -4466,7 +4441,7 @@ function TableBodyRow({
4466
4441
  children: [
4467
4442
  !locked && virtualPaddingLeft ? (
4468
4443
  // fake empty column to the left for virtualization scroll padding
4469
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("td", { style: { display: "flex", width: virtualPaddingLeft } })
4444
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("td", { style: { display: "flex", width: virtualPaddingLeft } })
4470
4445
  ) : null,
4471
4446
  columns.map((column) => {
4472
4447
  var _a2, _b, _c, _d;
@@ -4477,17 +4452,17 @@ function TableBodyRow({
4477
4452
  const cellFormat = (_a2 = cell.column.columnDef.meta) == null ? void 0 : _a2.format;
4478
4453
  const cellValue = cellFormat && isValueFormatterKey(cellFormat) ? valueFormatters[cellFormat](cell.getValue()) : cell.getValue();
4479
4454
  const cellAlignment = (_c = (_b = cell.column.columnDef.meta) == null ? void 0 : _b.align) != null ? _c : typeof cellValue === "number" ? "right" : "left";
4480
- return ((_d = cell.column.columnDef.meta) == null ? void 0 : _d.useCustomRenderer) ? /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(import_react35.default.Fragment, { children: (0, import_react_table3.flexRender)(cell.column.columnDef.cell, cell.getContext()) }, cell.id) : /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4455
+ return ((_d = cell.column.columnDef.meta) == null ? void 0 : _d.useCustomRenderer) ? /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(import_react32.default.Fragment, { children: (0, import_react_table3.flexRender)(cell.column.columnDef.cell, cell.getContext()) }, cell.id) : /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
4481
4456
  CellElement,
4482
4457
  {
4483
4458
  id: id ? `${id}-row-${row.id}-cell-${cell.id}` : void 0,
4484
4459
  testid: testid ? `${testid}-row-${row.id}-cell-${cell.id}` : void 0,
4485
4460
  cell,
4486
- className: (0, import_clsx33.default)({
4461
+ className: (0, import_clsx32.default)({
4487
4462
  "justify-start": cellAlignment === "left",
4488
4463
  "justify-end": cellAlignment === "right"
4489
4464
  }),
4490
- children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(
4465
+ children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(
4491
4466
  Tooltip,
4492
4467
  {
4493
4468
  id: id ? `${id}-tooltip-${cell.id}` : void 0,
@@ -4495,7 +4470,7 @@ function TableBodyRow({
4495
4470
  showOnTruncation: true,
4496
4471
  message: cellValue,
4497
4472
  position: "bottom",
4498
- children: /* @__PURE__ */ (0, import_jsx_runtime54.jsx)(Paragraph, { addOverflow: true, tall: true, children: cellValue })
4473
+ children: /* @__PURE__ */ (0, import_jsx_runtime49.jsx)(Paragraph, { addOverflow: true, tall: true, children: cellValue })
4499
4474
  }
4500
4475
  )
4501
4476
  },
@@ -4504,7 +4479,7 @@ function TableBodyRow({
4504
4479
  }),
4505
4480
  !locked && virtualPaddingRight ? (
4506
4481
  // fake empty column to the right for virtualization scroll padding
4507
- /* @__PURE__ */ (0, import_jsx_runtime54.jsx)("td", { style: { display: "flex", width: virtualPaddingRight } })
4482
+ /* @__PURE__ */ (0, import_jsx_runtime49.jsx)("td", { style: { display: "flex", width: virtualPaddingRight } })
4508
4483
  ) : null
4509
4484
  ]
4510
4485
  },
@@ -4513,7 +4488,7 @@ function TableBodyRow({
4513
4488
  }
4514
4489
 
4515
4490
  // src/components/DataGrid/TableBody/LoadingCell.tsx
4516
- var import_jsx_runtime55 = require("react/jsx-runtime");
4491
+ var import_jsx_runtime50 = require("react/jsx-runtime");
4517
4492
  function LoadingCell({
4518
4493
  id,
4519
4494
  testid,
@@ -4521,16 +4496,16 @@ function LoadingCell({
4521
4496
  }) {
4522
4497
  const key = `loading-${column.id}`;
4523
4498
  if (column.cell === "checkbox") {
4524
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(DataGridCell, { id: id ? `${id}-${key}` : void 0, testid: testid ? `${testid}-${key}` : void 0, children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(Checkbox, { id: id ? `${id}-${key}-checkbox` : void 0, testid: testid ? `${testid}-${key}-checkbox` : void 0, disabled: true }) }, key);
4499
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(DataGridCell, { id: id ? `${id}-${key}` : void 0, testid: testid ? `${testid}-${key}` : void 0, children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(Checkbox, { id: id ? `${id}-${key}-checkbox` : void 0, testid: testid ? `${testid}-${key}-checkbox` : void 0, disabled: true }) }, key);
4525
4500
  }
4526
4501
  if (column.cell === "input") {
4527
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4502
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
4528
4503
  DataGridCell,
4529
4504
  {
4530
4505
  id: id ? `${id}-${key}` : void 0,
4531
4506
  testid: testid ? `${testid}-${key}` : void 0,
4532
4507
  component: "input",
4533
- children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(
4508
+ children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(
4534
4509
  Input,
4535
4510
  {
4536
4511
  id: id ? `${id}-${key}-input` : void 0,
@@ -4544,11 +4519,11 @@ function LoadingCell({
4544
4519
  key
4545
4520
  );
4546
4521
  }
4547
- return /* @__PURE__ */ (0, import_jsx_runtime55.jsx)(DataGridCell, { id: id ? `${id}-${key}` : void 0, testid: testid ? `${testid}-${key}` : void 0, children: /* @__PURE__ */ (0, import_jsx_runtime55.jsx)("div", { className: "bg-linear-270 to-neutral-300/[24%] from-neutral-300/[12%] rounded-xs w-full max-w-25 h-6" }) }, key);
4522
+ return /* @__PURE__ */ (0, import_jsx_runtime50.jsx)(DataGridCell, { id: id ? `${id}-${key}` : void 0, testid: testid ? `${testid}-${key}` : void 0, children: /* @__PURE__ */ (0, import_jsx_runtime50.jsx)("div", { className: "bg-linear-270 to-neutral-300/[24%] from-neutral-300/[12%] rounded-xs w-full max-w-25 h-6" }) }, key);
4548
4523
  }
4549
4524
 
4550
4525
  // src/components/DataGrid/TableBody/index.tsx
4551
- var import_jsx_runtime56 = require("react/jsx-runtime");
4526
+ var import_jsx_runtime51 = require("react/jsx-runtime");
4552
4527
  function TableBody({
4553
4528
  id,
4554
4529
  testid,
@@ -4582,10 +4557,10 @@ function TableBody({
4582
4557
  } else {
4583
4558
  headerGroups = table.getCenterHeaderGroups();
4584
4559
  }
4585
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsxs)(
4560
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsxs)(
4586
4561
  "tbody",
4587
4562
  {
4588
- className: (0, import_clsx34.default)(locked ? "shadow-16" : ""),
4563
+ className: (0, import_clsx33.default)(locked ? "shadow-16" : ""),
4589
4564
  style: {
4590
4565
  display: "grid",
4591
4566
  height: `${showFilterRow ? rowVirtualizer.getTotalSize() + 40 : rowVirtualizer.getTotalSize()}px`,
@@ -4594,7 +4569,7 @@ function TableBody({
4594
4569
  // needed for absolute positioning of rows
4595
4570
  },
4596
4571
  children: [
4597
- showFilterRow && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4572
+ showFilterRow && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4598
4573
  "tr",
4599
4574
  {
4600
4575
  style: {
@@ -4610,7 +4585,7 @@ function TableBody({
4610
4585
  children: headerGroups.flatMap(
4611
4586
  (x) => x.headers.map((header) => {
4612
4587
  var _a, _b, _c, _d, _e;
4613
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4588
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4614
4589
  CellElement,
4615
4590
  {
4616
4591
  id: id ? `${id}-filter-cell-${header.id}` : void 0,
@@ -4621,7 +4596,7 @@ function TableBody({
4621
4596
  children: header.column.getCanFilter() && ((_e = (_c = (_b = header.column.columnDef.meta) == null ? void 0 : _b.filterRowCell) == null ? void 0 : _c.call(_b, {
4622
4597
  header,
4623
4598
  table
4624
- })) != null ? _e : /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4599
+ })) != null ? _e : /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4625
4600
  Search,
4626
4601
  {
4627
4602
  id: id ? `${id}-filter-search-${header.id}` : void 0,
@@ -4642,7 +4617,7 @@ function TableBody({
4642
4617
  ),
4643
4618
  virtualRows.map((virtualRow) => {
4644
4619
  const row = rows[virtualRow.index];
4645
- return /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4620
+ return /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4646
4621
  TableBodyRow,
4647
4622
  {
4648
4623
  id,
@@ -4661,7 +4636,7 @@ function TableBody({
4661
4636
  row.id
4662
4637
  );
4663
4638
  }),
4664
- !pagination && isLoadingMore && hasMore && /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4639
+ !pagination && isLoadingMore && hasMore && /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4665
4640
  "tr",
4666
4641
  {
4667
4642
  style: {
@@ -4671,7 +4646,7 @@ function TableBody({
4671
4646
  transform: `translateY(${virtualRows[virtualRows.length - 1].start + 40}px)`
4672
4647
  },
4673
4648
  className: "odd:bg-background-grouped-primary-normal even:bg-background-grouped-secondary-normal",
4674
- children: table.getAllLeafColumns().map((column) => /* @__PURE__ */ (0, import_jsx_runtime56.jsx)(
4649
+ children: table.getAllLeafColumns().map((column) => /* @__PURE__ */ (0, import_jsx_runtime51.jsx)(
4675
4650
  LoadingCell,
4676
4651
  {
4677
4652
  id,