@dmsi/wedgekit-react 0.0.1228 → 0.0.1230
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.
- package/dist/{chunk-YCDDBSVU.js → chunk-65HTZ3R2.js} +3 -1
- package/dist/{chunk-6R5GQV6W.js → chunk-ICJARSLG.js} +35 -11
- package/dist/{chunk-3X3Y4TMS.js → chunk-JRNU5BZ4.js} +3 -1
- package/dist/{chunk-2IKT6IHB.js → chunk-S4XW2XZW.js} +2 -0
- package/dist/{chunk-AJGTMNW5.js → chunk-XW4B4CUY.js} +59 -40
- package/dist/components/CalendarRange.cjs +26 -25
- package/dist/components/CalendarRange.js +5 -5
- package/dist/components/CompactImagesPreview.cjs +34 -10
- package/dist/components/CompactImagesPreview.js +1 -1
- package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.cjs +16 -15
- package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.js +5 -5
- package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.cjs +19 -18
- package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.js +5 -5
- package/dist/components/DataGrid/PinnedColumns.cjs +21 -20
- package/dist/components/DataGrid/PinnedColumns.js +5 -5
- package/dist/components/DataGrid/TableBody/LoadingCell.cjs +14 -13
- package/dist/components/DataGrid/TableBody/LoadingCell.js +5 -5
- package/dist/components/DataGrid/TableBody/TableBodyRow.cjs +16 -15
- package/dist/components/DataGrid/TableBody/TableBodyRow.js +5 -5
- package/dist/components/DataGrid/TableBody/index.cjs +16 -15
- package/dist/components/DataGrid/TableBody/index.js +5 -5
- package/dist/components/DataGrid/index.cjs +39 -38
- package/dist/components/DataGrid/index.js +5 -5
- package/dist/components/DataGrid/utils.cjs +14 -13
- package/dist/components/DataGrid/utils.js +5 -5
- package/dist/components/DateInput.cjs +38 -37
- package/dist/components/DateInput.js +5 -5
- package/dist/components/DateRangeInput.cjs +39 -38
- package/dist/components/DateRangeInput.js +5 -5
- package/dist/components/MobileDataGrid/ColumnSelector/index.cjs +18 -17
- package/dist/components/MobileDataGrid/ColumnSelector/index.js +5 -5
- package/dist/components/MobileDataGrid/MobileDataGridHeader.cjs +18 -17
- package/dist/components/MobileDataGrid/MobileDataGridHeader.js +5 -5
- package/dist/components/MobileDataGrid/index.cjs +41 -40
- package/dist/components/MobileDataGrid/index.js +5 -5
- package/dist/components/ProductImagePreview/MobileImageCarousel.cjs +2 -0
- package/dist/components/ProductImagePreview/MobileImageCarousel.js +1 -1
- package/dist/components/ProductImagePreview/ProductPrimaryImage.cjs +3 -1
- package/dist/components/ProductImagePreview/ProductPrimaryImage.js +1 -1
- package/dist/components/ProductImagePreview/Thumbnail.cjs +3 -1
- package/dist/components/ProductImagePreview/Thumbnail.js +1 -1
- package/dist/components/ProductImagePreview/index.cjs +64 -39
- package/dist/components/ProductImagePreview/index.js +4 -4
- package/dist/components/index.cjs +138 -89
- package/dist/components/index.js +5 -5
- package/package.json +1 -1
|
@@ -62,7 +62,7 @@ __export(ColumnSelector_exports, {
|
|
|
62
62
|
ColumnSelector: () => ColumnSelector
|
|
63
63
|
});
|
|
64
64
|
module.exports = __toCommonJS(ColumnSelector_exports);
|
|
65
|
-
var
|
|
65
|
+
var import_react44 = require("react");
|
|
66
66
|
|
|
67
67
|
// src/components/DataGridCell.tsx
|
|
68
68
|
var import_sortable = require("@dnd-kit/sortable");
|
|
@@ -6213,10 +6213,11 @@ var import_jsx_runtime51 = require("react/jsx-runtime");
|
|
|
6213
6213
|
var import_react32 = require("react");
|
|
6214
6214
|
|
|
6215
6215
|
// src/components/ProductImagePreview/index.tsx
|
|
6216
|
+
var import_react33 = require("react");
|
|
6216
6217
|
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
6217
6218
|
|
|
6218
6219
|
// src/components/CompactImagesPreview.tsx
|
|
6219
|
-
var
|
|
6220
|
+
var import_react34 = require("react");
|
|
6220
6221
|
var import_clsx36 = __toESM(require("clsx"), 1);
|
|
6221
6222
|
var import_jsx_runtime53 = require("react/jsx-runtime");
|
|
6222
6223
|
|
|
@@ -6225,12 +6226,12 @@ var import_clsx37 = __toESM(require("clsx"), 1);
|
|
|
6225
6226
|
var import_jsx_runtime54 = require("react/jsx-runtime");
|
|
6226
6227
|
|
|
6227
6228
|
// src/components/ListGroup.tsx
|
|
6228
|
-
var
|
|
6229
|
+
var import_react35 = require("react");
|
|
6229
6230
|
var import_clsx38 = __toESM(require("clsx"), 1);
|
|
6230
6231
|
var import_jsx_runtime55 = require("react/jsx-runtime");
|
|
6231
6232
|
|
|
6232
6233
|
// src/components/Pagination.tsx
|
|
6233
|
-
var
|
|
6234
|
+
var import_react36 = require("react");
|
|
6234
6235
|
var import_clsx39 = __toESM(require("clsx"), 1);
|
|
6235
6236
|
var import_jsx_runtime56 = require("react/jsx-runtime");
|
|
6236
6237
|
var Pagination = ({
|
|
@@ -6242,7 +6243,7 @@ var Pagination = ({
|
|
|
6242
6243
|
className,
|
|
6243
6244
|
disabled
|
|
6244
6245
|
}) => {
|
|
6245
|
-
const goTo = (0,
|
|
6246
|
+
const goTo = (0, import_react36.useCallback)(
|
|
6246
6247
|
(page) => {
|
|
6247
6248
|
if (disabled) return;
|
|
6248
6249
|
onPageChange(page);
|
|
@@ -6259,7 +6260,7 @@ var Pagination = ({
|
|
|
6259
6260
|
goTo(currentPage + 1);
|
|
6260
6261
|
}
|
|
6261
6262
|
};
|
|
6262
|
-
const pageTokens = (0,
|
|
6263
|
+
const pageTokens = (0, import_react36.useMemo)(() => {
|
|
6263
6264
|
if (totalPages <= 5) {
|
|
6264
6265
|
return Array.from({ length: totalPages }, (_, i) => i + 1);
|
|
6265
6266
|
}
|
|
@@ -6382,21 +6383,21 @@ var import_jsx_runtime57 = require("react/jsx-runtime");
|
|
|
6382
6383
|
var import_jsx_runtime58 = require("react/jsx-runtime");
|
|
6383
6384
|
|
|
6384
6385
|
// src/components/SearchResultImage/index.tsx
|
|
6385
|
-
var
|
|
6386
|
+
var import_react37 = require("react");
|
|
6386
6387
|
var import_jsx_runtime59 = require("react/jsx-runtime");
|
|
6387
6388
|
|
|
6388
6389
|
// src/components/Alert.tsx
|
|
6389
6390
|
var import_clsx40 = __toESM(require("clsx"), 1);
|
|
6390
|
-
var
|
|
6391
|
+
var import_react38 = require("react");
|
|
6391
6392
|
var import_jsx_runtime60 = require("react/jsx-runtime");
|
|
6392
6393
|
|
|
6393
6394
|
// src/components/OrderCheckIcon.tsx
|
|
6394
6395
|
var import_jsx_runtime61 = require("react/jsx-runtime");
|
|
6395
6396
|
|
|
6396
6397
|
// src/components/EditingContext.tsx
|
|
6397
|
-
var
|
|
6398
|
+
var import_react39 = require("react");
|
|
6398
6399
|
var import_jsx_runtime62 = require("react/jsx-runtime");
|
|
6399
|
-
var EditingContext = (0,
|
|
6400
|
+
var EditingContext = (0, import_react39.createContext)(null);
|
|
6400
6401
|
|
|
6401
6402
|
// src/components/AccessCard.tsx
|
|
6402
6403
|
var import_clsx42 = __toESM(require("clsx"), 1);
|
|
@@ -6530,11 +6531,11 @@ var import_jsx_runtime64 = require("react/jsx-runtime");
|
|
|
6530
6531
|
|
|
6531
6532
|
// src/components/AccessCardGroup.tsx
|
|
6532
6533
|
var import_clsx43 = __toESM(require("clsx"), 1);
|
|
6533
|
-
var
|
|
6534
|
+
var import_react40 = require("react");
|
|
6534
6535
|
var import_jsx_runtime65 = require("react/jsx-runtime");
|
|
6535
6536
|
|
|
6536
6537
|
// src/components/EmblaCarousel/index.tsx
|
|
6537
|
-
var
|
|
6538
|
+
var import_react43 = __toESM(require("react"), 1);
|
|
6538
6539
|
var import_embla_carousel_react = __toESM(require("embla-carousel-react"), 1);
|
|
6539
6540
|
var import_embla_carousel_autoplay = __toESM(require("embla-carousel-autoplay"), 1);
|
|
6540
6541
|
|
|
@@ -6542,7 +6543,7 @@ var import_embla_carousel_autoplay = __toESM(require("embla-carousel-autoplay"),
|
|
|
6542
6543
|
var import_jsx_runtime66 = require("react/jsx-runtime");
|
|
6543
6544
|
|
|
6544
6545
|
// src/components/EmblaCarousel/useSelectedSnapDisplay.ts
|
|
6545
|
-
var
|
|
6546
|
+
var import_react41 = require("react");
|
|
6546
6547
|
|
|
6547
6548
|
// src/components/EmblaCarousel/ArrowButtons.tsx
|
|
6548
6549
|
var import_clsx44 = __toESM(require("clsx"), 1);
|
|
@@ -6552,7 +6553,7 @@ var arrowButtonStyles = (0, import_clsx44.default)(
|
|
|
6552
6553
|
);
|
|
6553
6554
|
|
|
6554
6555
|
// src/components/EmblaCarousel/usePrevNextButtons.ts
|
|
6555
|
-
var
|
|
6556
|
+
var import_react42 = require("react");
|
|
6556
6557
|
|
|
6557
6558
|
// src/components/EmblaCarousel/index.tsx
|
|
6558
6559
|
var import_clsx45 = __toESM(require("clsx"), 1);
|
|
@@ -6562,8 +6563,8 @@ var import_jsx_runtime68 = require("react/jsx-runtime");
|
|
|
6562
6563
|
var import_jsx_runtime69 = require("react/jsx-runtime");
|
|
6563
6564
|
function ColumnSelector() {
|
|
6564
6565
|
const context = useGridContext();
|
|
6565
|
-
const ref = (0,
|
|
6566
|
-
const [show, setShow] = (0,
|
|
6566
|
+
const ref = (0, import_react44.useRef)(null);
|
|
6567
|
+
const [show, setShow] = (0, import_react44.useState)(false);
|
|
6567
6568
|
const {
|
|
6568
6569
|
columns,
|
|
6569
6570
|
id,
|
|
@@ -6574,7 +6575,7 @@ function ColumnSelector() {
|
|
|
6574
6575
|
resetColumnVisibility,
|
|
6575
6576
|
dispatch
|
|
6576
6577
|
} = context;
|
|
6577
|
-
const toggleColumnVisibility = (0,
|
|
6578
|
+
const toggleColumnVisibility = (0, import_react44.useCallback)(
|
|
6578
6579
|
(index, visible) => {
|
|
6579
6580
|
dispatch({ type: "UPDATE", index, payload: { meta: { visible } } });
|
|
6580
6581
|
},
|
|
@@ -5,11 +5,11 @@ import "../../../chunk-3UPUZBP5.js";
|
|
|
5
5
|
import "../../../chunk-7ZJIGTFN.js";
|
|
6
6
|
import "../../../chunk-E3FOCECQ.js";
|
|
7
7
|
import "../../../chunk-Y5GD2FJA.js";
|
|
8
|
-
import "../../../chunk-
|
|
8
|
+
import "../../../chunk-XW4B4CUY.js";
|
|
9
9
|
import "../../../chunk-MBZ55T2D.js";
|
|
10
|
-
import "../../../chunk-
|
|
11
|
-
import "../../../chunk-
|
|
12
|
-
import "../../../chunk-
|
|
10
|
+
import "../../../chunk-S4XW2XZW.js";
|
|
11
|
+
import "../../../chunk-65HTZ3R2.js";
|
|
12
|
+
import "../../../chunk-JRNU5BZ4.js";
|
|
13
13
|
import "../../../chunk-BQNPOGD5.js";
|
|
14
14
|
import "../../../chunk-YULGJORA.js";
|
|
15
15
|
import "../../../chunk-Z2HPSFEQ.js";
|
|
@@ -47,7 +47,7 @@ import "../../../chunk-PABII472.js";
|
|
|
47
47
|
import "../../../chunk-4UGMSWWA.js";
|
|
48
48
|
import "../../../chunk-WVUIIBRR.js";
|
|
49
49
|
import "../../../chunk-I3W5K76C.js";
|
|
50
|
-
import "../../../chunk-
|
|
50
|
+
import "../../../chunk-ICJARSLG.js";
|
|
51
51
|
import "../../../chunk-ZRFXUER3.js";
|
|
52
52
|
import "../../../chunk-WVGXD7HT.js";
|
|
53
53
|
import "../../../chunk-VXWSAIB5.js";
|
|
@@ -721,7 +721,7 @@ function Theme({
|
|
|
721
721
|
}
|
|
722
722
|
|
|
723
723
|
// src/components/MobileDataGrid/ColumnSelector/index.tsx
|
|
724
|
-
var
|
|
724
|
+
var import_react44 = require("react");
|
|
725
725
|
|
|
726
726
|
// src/components/DataGridCell.tsx
|
|
727
727
|
var import_sortable = require("@dnd-kit/sortable");
|
|
@@ -6457,10 +6457,11 @@ var import_jsx_runtime50 = require("react/jsx-runtime");
|
|
|
6457
6457
|
var import_react32 = require("react");
|
|
6458
6458
|
|
|
6459
6459
|
// src/components/ProductImagePreview/index.tsx
|
|
6460
|
+
var import_react33 = require("react");
|
|
6460
6461
|
var import_jsx_runtime51 = require("react/jsx-runtime");
|
|
6461
6462
|
|
|
6462
6463
|
// src/components/CompactImagesPreview.tsx
|
|
6463
|
-
var
|
|
6464
|
+
var import_react34 = require("react");
|
|
6464
6465
|
var import_clsx36 = __toESM(require("clsx"), 1);
|
|
6465
6466
|
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
6466
6467
|
|
|
@@ -6469,12 +6470,12 @@ var import_clsx37 = __toESM(require("clsx"), 1);
|
|
|
6469
6470
|
var import_jsx_runtime53 = require("react/jsx-runtime");
|
|
6470
6471
|
|
|
6471
6472
|
// src/components/ListGroup.tsx
|
|
6472
|
-
var
|
|
6473
|
+
var import_react35 = require("react");
|
|
6473
6474
|
var import_clsx38 = __toESM(require("clsx"), 1);
|
|
6474
6475
|
var import_jsx_runtime54 = require("react/jsx-runtime");
|
|
6475
6476
|
|
|
6476
6477
|
// src/components/Pagination.tsx
|
|
6477
|
-
var
|
|
6478
|
+
var import_react36 = require("react");
|
|
6478
6479
|
var import_clsx39 = __toESM(require("clsx"), 1);
|
|
6479
6480
|
var import_jsx_runtime55 = require("react/jsx-runtime");
|
|
6480
6481
|
var Pagination = ({
|
|
@@ -6486,7 +6487,7 @@ var Pagination = ({
|
|
|
6486
6487
|
className,
|
|
6487
6488
|
disabled
|
|
6488
6489
|
}) => {
|
|
6489
|
-
const goTo = (0,
|
|
6490
|
+
const goTo = (0, import_react36.useCallback)(
|
|
6490
6491
|
(page) => {
|
|
6491
6492
|
if (disabled) return;
|
|
6492
6493
|
onPageChange(page);
|
|
@@ -6503,7 +6504,7 @@ var Pagination = ({
|
|
|
6503
6504
|
goTo(currentPage + 1);
|
|
6504
6505
|
}
|
|
6505
6506
|
};
|
|
6506
|
-
const pageTokens = (0,
|
|
6507
|
+
const pageTokens = (0, import_react36.useMemo)(() => {
|
|
6507
6508
|
if (totalPages <= 5) {
|
|
6508
6509
|
return Array.from({ length: totalPages }, (_, i) => i + 1);
|
|
6509
6510
|
}
|
|
@@ -6626,21 +6627,21 @@ var import_jsx_runtime56 = require("react/jsx-runtime");
|
|
|
6626
6627
|
var import_jsx_runtime57 = require("react/jsx-runtime");
|
|
6627
6628
|
|
|
6628
6629
|
// src/components/SearchResultImage/index.tsx
|
|
6629
|
-
var
|
|
6630
|
+
var import_react37 = require("react");
|
|
6630
6631
|
var import_jsx_runtime58 = require("react/jsx-runtime");
|
|
6631
6632
|
|
|
6632
6633
|
// src/components/Alert.tsx
|
|
6633
6634
|
var import_clsx40 = __toESM(require("clsx"), 1);
|
|
6634
|
-
var
|
|
6635
|
+
var import_react38 = require("react");
|
|
6635
6636
|
var import_jsx_runtime59 = require("react/jsx-runtime");
|
|
6636
6637
|
|
|
6637
6638
|
// src/components/OrderCheckIcon.tsx
|
|
6638
6639
|
var import_jsx_runtime60 = require("react/jsx-runtime");
|
|
6639
6640
|
|
|
6640
6641
|
// src/components/EditingContext.tsx
|
|
6641
|
-
var
|
|
6642
|
+
var import_react39 = require("react");
|
|
6642
6643
|
var import_jsx_runtime61 = require("react/jsx-runtime");
|
|
6643
|
-
var EditingContext = (0,
|
|
6644
|
+
var EditingContext = (0, import_react39.createContext)(null);
|
|
6644
6645
|
|
|
6645
6646
|
// src/components/AccessCard.tsx
|
|
6646
6647
|
var import_clsx42 = __toESM(require("clsx"), 1);
|
|
@@ -6774,11 +6775,11 @@ var import_jsx_runtime63 = require("react/jsx-runtime");
|
|
|
6774
6775
|
|
|
6775
6776
|
// src/components/AccessCardGroup.tsx
|
|
6776
6777
|
var import_clsx43 = __toESM(require("clsx"), 1);
|
|
6777
|
-
var
|
|
6778
|
+
var import_react40 = require("react");
|
|
6778
6779
|
var import_jsx_runtime64 = require("react/jsx-runtime");
|
|
6779
6780
|
|
|
6780
6781
|
// src/components/EmblaCarousel/index.tsx
|
|
6781
|
-
var
|
|
6782
|
+
var import_react43 = __toESM(require("react"), 1);
|
|
6782
6783
|
var import_embla_carousel_react = __toESM(require("embla-carousel-react"), 1);
|
|
6783
6784
|
var import_embla_carousel_autoplay = __toESM(require("embla-carousel-autoplay"), 1);
|
|
6784
6785
|
|
|
@@ -6786,7 +6787,7 @@ var import_embla_carousel_autoplay = __toESM(require("embla-carousel-autoplay"),
|
|
|
6786
6787
|
var import_jsx_runtime65 = require("react/jsx-runtime");
|
|
6787
6788
|
|
|
6788
6789
|
// src/components/EmblaCarousel/useSelectedSnapDisplay.ts
|
|
6789
|
-
var
|
|
6790
|
+
var import_react41 = require("react");
|
|
6790
6791
|
|
|
6791
6792
|
// src/components/EmblaCarousel/ArrowButtons.tsx
|
|
6792
6793
|
var import_clsx44 = __toESM(require("clsx"), 1);
|
|
@@ -6796,7 +6797,7 @@ var arrowButtonStyles = (0, import_clsx44.default)(
|
|
|
6796
6797
|
);
|
|
6797
6798
|
|
|
6798
6799
|
// src/components/EmblaCarousel/usePrevNextButtons.ts
|
|
6799
|
-
var
|
|
6800
|
+
var import_react42 = require("react");
|
|
6800
6801
|
|
|
6801
6802
|
// src/components/EmblaCarousel/index.tsx
|
|
6802
6803
|
var import_clsx45 = __toESM(require("clsx"), 1);
|
|
@@ -6806,8 +6807,8 @@ var import_jsx_runtime67 = require("react/jsx-runtime");
|
|
|
6806
6807
|
var import_jsx_runtime68 = require("react/jsx-runtime");
|
|
6807
6808
|
function ColumnSelector() {
|
|
6808
6809
|
const context = useGridContext();
|
|
6809
|
-
const ref = (0,
|
|
6810
|
-
const [show, setShow] = (0,
|
|
6810
|
+
const ref = (0, import_react44.useRef)(null);
|
|
6811
|
+
const [show, setShow] = (0, import_react44.useState)(false);
|
|
6811
6812
|
const {
|
|
6812
6813
|
columns,
|
|
6813
6814
|
id,
|
|
@@ -6818,7 +6819,7 @@ function ColumnSelector() {
|
|
|
6818
6819
|
resetColumnVisibility,
|
|
6819
6820
|
dispatch
|
|
6820
6821
|
} = context;
|
|
6821
|
-
const toggleColumnVisibility = (0,
|
|
6822
|
+
const toggleColumnVisibility = (0, import_react44.useCallback)(
|
|
6822
6823
|
(index, visible) => {
|
|
6823
6824
|
dispatch({ type: "UPDATE", index, payload: { meta: { visible } } });
|
|
6824
6825
|
},
|
|
@@ -5,11 +5,11 @@ import "../../chunk-3UPUZBP5.js";
|
|
|
5
5
|
import "../../chunk-7ZJIGTFN.js";
|
|
6
6
|
import "../../chunk-E3FOCECQ.js";
|
|
7
7
|
import "../../chunk-Y5GD2FJA.js";
|
|
8
|
-
import "../../chunk-
|
|
8
|
+
import "../../chunk-XW4B4CUY.js";
|
|
9
9
|
import "../../chunk-MBZ55T2D.js";
|
|
10
|
-
import "../../chunk-
|
|
11
|
-
import "../../chunk-
|
|
12
|
-
import "../../chunk-
|
|
10
|
+
import "../../chunk-S4XW2XZW.js";
|
|
11
|
+
import "../../chunk-65HTZ3R2.js";
|
|
12
|
+
import "../../chunk-JRNU5BZ4.js";
|
|
13
13
|
import "../../chunk-BQNPOGD5.js";
|
|
14
14
|
import "../../chunk-YULGJORA.js";
|
|
15
15
|
import "../../chunk-Z2HPSFEQ.js";
|
|
@@ -47,7 +47,7 @@ import "../../chunk-PABII472.js";
|
|
|
47
47
|
import "../../chunk-4UGMSWWA.js";
|
|
48
48
|
import "../../chunk-WVUIIBRR.js";
|
|
49
49
|
import "../../chunk-I3W5K76C.js";
|
|
50
|
-
import "../../chunk-
|
|
50
|
+
import "../../chunk-ICJARSLG.js";
|
|
51
51
|
import "../../chunk-ZRFXUER3.js";
|
|
52
52
|
import "../../chunk-WVGXD7HT.js";
|
|
53
53
|
import "../../chunk-VXWSAIB5.js";
|
|
@@ -721,7 +721,7 @@ function Theme({
|
|
|
721
721
|
}
|
|
722
722
|
|
|
723
723
|
// src/components/MobileDataGrid/ColumnSelector/index.tsx
|
|
724
|
-
var
|
|
724
|
+
var import_react41 = require("react");
|
|
725
725
|
|
|
726
726
|
// src/components/DataGridCell.tsx
|
|
727
727
|
var import_sortable = require("@dnd-kit/sortable");
|
|
@@ -5987,10 +5987,11 @@ var import_jsx_runtime38 = require("react/jsx-runtime");
|
|
|
5987
5987
|
var import_react29 = require("react");
|
|
5988
5988
|
|
|
5989
5989
|
// src/components/ProductImagePreview/index.tsx
|
|
5990
|
+
var import_react30 = require("react");
|
|
5990
5991
|
var import_jsx_runtime39 = require("react/jsx-runtime");
|
|
5991
5992
|
|
|
5992
5993
|
// src/components/CompactImagesPreview.tsx
|
|
5993
|
-
var
|
|
5994
|
+
var import_react31 = require("react");
|
|
5994
5995
|
var import_clsx29 = __toESM(require("clsx"), 1);
|
|
5995
5996
|
var import_jsx_runtime40 = require("react/jsx-runtime");
|
|
5996
5997
|
|
|
@@ -5999,12 +6000,12 @@ var import_clsx30 = __toESM(require("clsx"), 1);
|
|
|
5999
6000
|
var import_jsx_runtime41 = require("react/jsx-runtime");
|
|
6000
6001
|
|
|
6001
6002
|
// src/components/ListGroup.tsx
|
|
6002
|
-
var
|
|
6003
|
+
var import_react32 = require("react");
|
|
6003
6004
|
var import_clsx31 = __toESM(require("clsx"), 1);
|
|
6004
6005
|
var import_jsx_runtime42 = require("react/jsx-runtime");
|
|
6005
6006
|
|
|
6006
6007
|
// src/components/Pagination.tsx
|
|
6007
|
-
var
|
|
6008
|
+
var import_react33 = require("react");
|
|
6008
6009
|
var import_clsx32 = __toESM(require("clsx"), 1);
|
|
6009
6010
|
var import_jsx_runtime43 = require("react/jsx-runtime");
|
|
6010
6011
|
var Pagination = ({
|
|
@@ -6016,7 +6017,7 @@ var Pagination = ({
|
|
|
6016
6017
|
className,
|
|
6017
6018
|
disabled
|
|
6018
6019
|
}) => {
|
|
6019
|
-
const goTo = (0,
|
|
6020
|
+
const goTo = (0, import_react33.useCallback)(
|
|
6020
6021
|
(page) => {
|
|
6021
6022
|
if (disabled) return;
|
|
6022
6023
|
onPageChange(page);
|
|
@@ -6033,7 +6034,7 @@ var Pagination = ({
|
|
|
6033
6034
|
goTo(currentPage + 1);
|
|
6034
6035
|
}
|
|
6035
6036
|
};
|
|
6036
|
-
const pageTokens = (0,
|
|
6037
|
+
const pageTokens = (0, import_react33.useMemo)(() => {
|
|
6037
6038
|
if (totalPages <= 5) {
|
|
6038
6039
|
return Array.from({ length: totalPages }, (_, i) => i + 1);
|
|
6039
6040
|
}
|
|
@@ -6156,21 +6157,21 @@ var import_jsx_runtime44 = require("react/jsx-runtime");
|
|
|
6156
6157
|
var import_jsx_runtime45 = require("react/jsx-runtime");
|
|
6157
6158
|
|
|
6158
6159
|
// src/components/SearchResultImage/index.tsx
|
|
6159
|
-
var
|
|
6160
|
+
var import_react34 = require("react");
|
|
6160
6161
|
var import_jsx_runtime46 = require("react/jsx-runtime");
|
|
6161
6162
|
|
|
6162
6163
|
// src/components/Alert.tsx
|
|
6163
6164
|
var import_clsx33 = __toESM(require("clsx"), 1);
|
|
6164
|
-
var
|
|
6165
|
+
var import_react35 = require("react");
|
|
6165
6166
|
var import_jsx_runtime47 = require("react/jsx-runtime");
|
|
6166
6167
|
|
|
6167
6168
|
// src/components/OrderCheckIcon.tsx
|
|
6168
6169
|
var import_jsx_runtime48 = require("react/jsx-runtime");
|
|
6169
6170
|
|
|
6170
6171
|
// src/components/EditingContext.tsx
|
|
6171
|
-
var
|
|
6172
|
+
var import_react36 = require("react");
|
|
6172
6173
|
var import_jsx_runtime49 = require("react/jsx-runtime");
|
|
6173
|
-
var EditingContext = (0,
|
|
6174
|
+
var EditingContext = (0, import_react36.createContext)(null);
|
|
6174
6175
|
|
|
6175
6176
|
// src/components/AccessCard.tsx
|
|
6176
6177
|
var import_clsx35 = __toESM(require("clsx"), 1);
|
|
@@ -6304,11 +6305,11 @@ var import_jsx_runtime51 = require("react/jsx-runtime");
|
|
|
6304
6305
|
|
|
6305
6306
|
// src/components/AccessCardGroup.tsx
|
|
6306
6307
|
var import_clsx36 = __toESM(require("clsx"), 1);
|
|
6307
|
-
var
|
|
6308
|
+
var import_react37 = require("react");
|
|
6308
6309
|
var import_jsx_runtime52 = require("react/jsx-runtime");
|
|
6309
6310
|
|
|
6310
6311
|
// src/components/EmblaCarousel/index.tsx
|
|
6311
|
-
var
|
|
6312
|
+
var import_react40 = __toESM(require("react"), 1);
|
|
6312
6313
|
var import_embla_carousel_react = __toESM(require("embla-carousel-react"), 1);
|
|
6313
6314
|
var import_embla_carousel_autoplay = __toESM(require("embla-carousel-autoplay"), 1);
|
|
6314
6315
|
|
|
@@ -6316,7 +6317,7 @@ var import_embla_carousel_autoplay = __toESM(require("embla-carousel-autoplay"),
|
|
|
6316
6317
|
var import_jsx_runtime53 = require("react/jsx-runtime");
|
|
6317
6318
|
|
|
6318
6319
|
// src/components/EmblaCarousel/useSelectedSnapDisplay.ts
|
|
6319
|
-
var
|
|
6320
|
+
var import_react38 = require("react");
|
|
6320
6321
|
|
|
6321
6322
|
// src/components/EmblaCarousel/ArrowButtons.tsx
|
|
6322
6323
|
var import_clsx37 = __toESM(require("clsx"), 1);
|
|
@@ -6326,7 +6327,7 @@ var arrowButtonStyles = (0, import_clsx37.default)(
|
|
|
6326
6327
|
);
|
|
6327
6328
|
|
|
6328
6329
|
// src/components/EmblaCarousel/usePrevNextButtons.ts
|
|
6329
|
-
var
|
|
6330
|
+
var import_react39 = require("react");
|
|
6330
6331
|
|
|
6331
6332
|
// src/components/EmblaCarousel/index.tsx
|
|
6332
6333
|
var import_clsx38 = __toESM(require("clsx"), 1);
|
|
@@ -6336,8 +6337,8 @@ var import_jsx_runtime55 = require("react/jsx-runtime");
|
|
|
6336
6337
|
var import_jsx_runtime56 = require("react/jsx-runtime");
|
|
6337
6338
|
function ColumnSelector() {
|
|
6338
6339
|
const context = useGridContext();
|
|
6339
|
-
const ref = (0,
|
|
6340
|
-
const [show, setShow] = (0,
|
|
6340
|
+
const ref = (0, import_react41.useRef)(null);
|
|
6341
|
+
const [show, setShow] = (0, import_react41.useState)(false);
|
|
6341
6342
|
const {
|
|
6342
6343
|
columns,
|
|
6343
6344
|
id,
|
|
@@ -6348,7 +6349,7 @@ function ColumnSelector() {
|
|
|
6348
6349
|
resetColumnVisibility,
|
|
6349
6350
|
dispatch
|
|
6350
6351
|
} = context;
|
|
6351
|
-
const toggleColumnVisibility = (0,
|
|
6352
|
+
const toggleColumnVisibility = (0, import_react41.useCallback)(
|
|
6352
6353
|
(index, visible) => {
|
|
6353
6354
|
dispatch({ type: "UPDATE", index, payload: { meta: { visible } } });
|
|
6354
6355
|
},
|
|
@@ -6503,7 +6504,7 @@ function MobileDataGridHeader({
|
|
|
6503
6504
|
}
|
|
6504
6505
|
|
|
6505
6506
|
// src/components/MobileDataGrid/GridContextProvider/index.tsx
|
|
6506
|
-
var
|
|
6507
|
+
var import_react42 = require("react");
|
|
6507
6508
|
|
|
6508
6509
|
// src/components/MobileDataGrid/dataGridReducer.ts
|
|
6509
6510
|
function dataGridReducer(state, action) {
|
|
@@ -6546,10 +6547,10 @@ function GridContextProvider(props) {
|
|
|
6546
6547
|
getId,
|
|
6547
6548
|
onRowSelect
|
|
6548
6549
|
} = props;
|
|
6549
|
-
const [columns, dispatch] = (0,
|
|
6550
|
-
const [selectedRowIds, setSelectedRowIds] = (0,
|
|
6551
|
-
const [currentRow, setCurrentRow] = (0,
|
|
6552
|
-
const resetColumnVisibility = (0,
|
|
6550
|
+
const [columns, dispatch] = (0, import_react42.useReducer)(dataGridReducer, initialColumns);
|
|
6551
|
+
const [selectedRowIds, setSelectedRowIds] = (0, import_react42.useState)([]);
|
|
6552
|
+
const [currentRow, setCurrentRow] = (0, import_react42.useState)(null);
|
|
6553
|
+
const resetColumnVisibility = (0, import_react42.useCallback)(() => {
|
|
6553
6554
|
const newColumns = columns.map((column) => {
|
|
6554
6555
|
var _a;
|
|
6555
6556
|
const initialColumn = initialColumns.find((c) => c.id === column.id);
|
|
@@ -6561,7 +6562,7 @@ function GridContextProvider(props) {
|
|
|
6561
6562
|
});
|
|
6562
6563
|
dispatch({ type: "SET", payload: newColumns });
|
|
6563
6564
|
}, [columns, initialColumns]);
|
|
6564
|
-
const handleRowSelect = (0,
|
|
6565
|
+
const handleRowSelect = (0, import_react42.useCallback)(
|
|
6565
6566
|
(item) => {
|
|
6566
6567
|
var _a;
|
|
6567
6568
|
const rowId = (_a = getId(item)) != null ? _a : "";
|
|
@@ -6572,7 +6573,7 @@ function GridContextProvider(props) {
|
|
|
6572
6573
|
},
|
|
6573
6574
|
[getId, onRowSelect, selectedRowIds]
|
|
6574
6575
|
);
|
|
6575
|
-
const handleRowSelectAll = (0,
|
|
6576
|
+
const handleRowSelectAll = (0, import_react42.useCallback)(() => {
|
|
6576
6577
|
setSelectedRowIds((prev) => {
|
|
6577
6578
|
if (prev.length === data.length) {
|
|
6578
6579
|
return [];
|
|
@@ -6580,13 +6581,13 @@ function GridContextProvider(props) {
|
|
|
6580
6581
|
return data.map(getId).filter((id2) => id2 !== void 0);
|
|
6581
6582
|
});
|
|
6582
6583
|
}, [data, getId]);
|
|
6583
|
-
const openRowDetail = (0,
|
|
6584
|
+
const openRowDetail = (0, import_react42.useCallback)((row) => {
|
|
6584
6585
|
setCurrentRow(row);
|
|
6585
6586
|
}, []);
|
|
6586
|
-
const closeRowDetail = (0,
|
|
6587
|
+
const closeRowDetail = (0, import_react42.useCallback)(() => {
|
|
6587
6588
|
setCurrentRow(null);
|
|
6588
6589
|
}, []);
|
|
6589
|
-
const visibleColumns = (0,
|
|
6590
|
+
const visibleColumns = (0, import_react42.useMemo)(() => {
|
|
6590
6591
|
const effectiveLimit = typeof numberOfColumnsToShow === "number" ? Math.max(numberOfColumnsToShow - 1, 0) : void 0;
|
|
6591
6592
|
if (primaryKey) {
|
|
6592
6593
|
const pkColumn = columns.find((col) => col.id === String(primaryKey));
|
|
@@ -6604,7 +6605,7 @@ function GridContextProvider(props) {
|
|
|
6604
6605
|
return ((_a = x.meta) == null ? void 0 : _a.visible) !== false;
|
|
6605
6606
|
}).slice(0, effectiveLimit);
|
|
6606
6607
|
}, [columns, numberOfColumnsToShow, primaryKey]);
|
|
6607
|
-
(0,
|
|
6608
|
+
(0, import_react42.useEffect)(() => {
|
|
6608
6609
|
setCurrentRow((prev) => {
|
|
6609
6610
|
if (!prev) return prev;
|
|
6610
6611
|
const prevId = getId(prev);
|
|
@@ -6642,7 +6643,7 @@ function GridContextProvider(props) {
|
|
|
6642
6643
|
|
|
6643
6644
|
// src/components/Modal.tsx
|
|
6644
6645
|
var import_clsx43 = __toESM(require("clsx"), 1);
|
|
6645
|
-
var
|
|
6646
|
+
var import_react44 = require("react");
|
|
6646
6647
|
|
|
6647
6648
|
// src/components/ModalHeader.tsx
|
|
6648
6649
|
var import_clsx39 = __toESM(require("clsx"), 1);
|
|
@@ -6829,10 +6830,10 @@ var import_react_dom4 = require("react-dom");
|
|
|
6829
6830
|
var import_react_use = require("react-use");
|
|
6830
6831
|
|
|
6831
6832
|
// src/components/useMounted.tsx
|
|
6832
|
-
var
|
|
6833
|
+
var import_react43 = require("react");
|
|
6833
6834
|
var useMounted = () => {
|
|
6834
|
-
const [isMounted, setIsMounted] = (0,
|
|
6835
|
-
(0,
|
|
6835
|
+
const [isMounted, setIsMounted] = (0, import_react43.useState)(false);
|
|
6836
|
+
(0, import_react43.useEffect)(() => {
|
|
6836
6837
|
setIsMounted(true);
|
|
6837
6838
|
return () => setIsMounted(false);
|
|
6838
6839
|
}, []);
|
|
@@ -6927,12 +6928,12 @@ var Modal = ({
|
|
|
6927
6928
|
}) => {
|
|
6928
6929
|
var _a;
|
|
6929
6930
|
const mounted = useMounted();
|
|
6930
|
-
const modalRef = (0,
|
|
6931
|
-
const bgRef = (0,
|
|
6931
|
+
const modalRef = (0, import_react44.useRef)(null);
|
|
6932
|
+
const bgRef = (0, import_react44.useRef)(null);
|
|
6932
6933
|
const wasOpen = (0, import_react_use.usePrevious)(open);
|
|
6933
6934
|
const isMobile = useMatchesMobile();
|
|
6934
6935
|
const computedFixedHeightScrolling = isMobile || fixedHeightScrolling;
|
|
6935
|
-
(0,
|
|
6936
|
+
(0, import_react44.useEffect)(() => {
|
|
6936
6937
|
if (!mounted) return;
|
|
6937
6938
|
if (!modalRef.current || !bgRef.current) {
|
|
6938
6939
|
console.error("Modal or background reference is not set.");
|
|
@@ -6952,7 +6953,7 @@ var Modal = ({
|
|
|
6952
6953
|
bgFadeIn(bgRef.current);
|
|
6953
6954
|
}
|
|
6954
6955
|
}, [mounted, onClose, open, wasOpen]);
|
|
6955
|
-
const handleKeyDown = (0,
|
|
6956
|
+
const handleKeyDown = (0, import_react44.useCallback)(
|
|
6956
6957
|
(e) => {
|
|
6957
6958
|
if (e.key === "Escape") {
|
|
6958
6959
|
if (onClose) {
|
|
@@ -6963,12 +6964,12 @@ var Modal = ({
|
|
|
6963
6964
|
},
|
|
6964
6965
|
[onClose]
|
|
6965
6966
|
);
|
|
6966
|
-
const handleClose = (0,
|
|
6967
|
+
const handleClose = (0, import_react44.useCallback)(() => {
|
|
6967
6968
|
if (onClose) {
|
|
6968
6969
|
onClose();
|
|
6969
6970
|
}
|
|
6970
6971
|
}, [onClose]);
|
|
6971
|
-
(0,
|
|
6972
|
+
(0, import_react44.useEffect)(() => {
|
|
6972
6973
|
if (open) {
|
|
6973
6974
|
document.addEventListener("keyup", handleKeyDown);
|
|
6974
6975
|
}
|
|
@@ -6976,7 +6977,7 @@ var Modal = ({
|
|
|
6976
6977
|
document.removeEventListener("keyup", handleKeyDown);
|
|
6977
6978
|
};
|
|
6978
6979
|
}, [open, handleKeyDown]);
|
|
6979
|
-
(0,
|
|
6980
|
+
(0, import_react44.useEffect)(() => {
|
|
6980
6981
|
if (!open) return;
|
|
6981
6982
|
const scrollY = window.scrollY;
|
|
6982
6983
|
const body = document.body;
|
|
@@ -6997,7 +6998,7 @@ var Modal = ({
|
|
|
6997
6998
|
};
|
|
6998
6999
|
}, [open]);
|
|
6999
7000
|
const { sizeClass } = (_a = sizes[size]) != null ? _a : sizes.small;
|
|
7000
|
-
const backgroundClickHandler = (0,
|
|
7001
|
+
const backgroundClickHandler = (0, import_react44.useCallback)(
|
|
7001
7002
|
(e) => {
|
|
7002
7003
|
const target = e.target;
|
|
7003
7004
|
const currentTarget = e.currentTarget;
|
|
@@ -5,11 +5,11 @@ import "../../chunk-3UPUZBP5.js";
|
|
|
5
5
|
import "../../chunk-7ZJIGTFN.js";
|
|
6
6
|
import "../../chunk-E3FOCECQ.js";
|
|
7
7
|
import "../../chunk-Y5GD2FJA.js";
|
|
8
|
-
import "../../chunk-
|
|
8
|
+
import "../../chunk-XW4B4CUY.js";
|
|
9
9
|
import "../../chunk-MBZ55T2D.js";
|
|
10
|
-
import "../../chunk-
|
|
11
|
-
import "../../chunk-
|
|
12
|
-
import "../../chunk-
|
|
10
|
+
import "../../chunk-S4XW2XZW.js";
|
|
11
|
+
import "../../chunk-65HTZ3R2.js";
|
|
12
|
+
import "../../chunk-JRNU5BZ4.js";
|
|
13
13
|
import "../../chunk-BQNPOGD5.js";
|
|
14
14
|
import "../../chunk-YULGJORA.js";
|
|
15
15
|
import "../../chunk-Z2HPSFEQ.js";
|
|
@@ -47,7 +47,7 @@ import "../../chunk-PABII472.js";
|
|
|
47
47
|
import "../../chunk-4UGMSWWA.js";
|
|
48
48
|
import "../../chunk-WVUIIBRR.js";
|
|
49
49
|
import "../../chunk-I3W5K76C.js";
|
|
50
|
-
import "../../chunk-
|
|
50
|
+
import "../../chunk-ICJARSLG.js";
|
|
51
51
|
import "../../chunk-ZRFXUER3.js";
|
|
52
52
|
import "../../chunk-WVGXD7HT.js";
|
|
53
53
|
import "../../chunk-VXWSAIB5.js";
|
|
@@ -31,6 +31,7 @@ function MobileImageCarousel({
|
|
|
31
31
|
width = 483,
|
|
32
32
|
height = 483,
|
|
33
33
|
onChangeIndex,
|
|
34
|
+
onImageError,
|
|
34
35
|
className = ""
|
|
35
36
|
}) {
|
|
36
37
|
const containerRef = (0, import_react.useRef)(null);
|
|
@@ -185,6 +186,7 @@ function MobileImageCarousel({
|
|
|
185
186
|
className: "w-full h-full object-cover",
|
|
186
187
|
draggable: false,
|
|
187
188
|
loading: distance <= 1 ? "eager" : "lazy",
|
|
189
|
+
onError: () => onImageError == null ? void 0 : onImageError(image.src),
|
|
188
190
|
style: {
|
|
189
191
|
aspectRatio: "1 / 1"
|
|
190
192
|
}
|
|
@@ -52,6 +52,7 @@ function ProductPrimaryImage({
|
|
|
52
52
|
scrollToZoomEnabled = false,
|
|
53
53
|
className = "",
|
|
54
54
|
isPlaceholder = false,
|
|
55
|
+
onImageError,
|
|
55
56
|
onZoomPositionChange,
|
|
56
57
|
onScrollZoom
|
|
57
58
|
}) {
|
|
@@ -141,12 +142,13 @@ function ProductPrimaryImage({
|
|
|
141
142
|
}, [scrollToZoomEnabled, zoomEnabled, active, onScrollZoom]);
|
|
142
143
|
const handleImgError = (0, import_react.useCallback)(
|
|
143
144
|
(e) => {
|
|
145
|
+
onImageError == null ? void 0 : onImageError(imageSrc);
|
|
144
146
|
if (!placeholderImageUri) return;
|
|
145
147
|
const img = e.currentTarget;
|
|
146
148
|
if (img.src === placeholderImageUri) return;
|
|
147
149
|
img.src = placeholderImageUri;
|
|
148
150
|
},
|
|
149
|
-
[]
|
|
151
|
+
[imageSrc, onImageError]
|
|
150
152
|
);
|
|
151
153
|
const pt = lastPointRef.current;
|
|
152
154
|
let lensStyle;
|