@dmsi/wedgekit-react 0.0.864 → 0.0.865
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-3N34VVYD.js +154 -0
- package/dist/{chunk-57HL5K5I.js → chunk-4DPSNQCM.js} +1 -1
- package/dist/{chunk-BH4UKMXV.js → chunk-5NRKL5CJ.js} +3 -3
- package/dist/{chunk-A57PKP6Z.js → chunk-E7XBOMT4.js} +6 -6
- package/dist/{chunk-CJPGHBV5.js → chunk-EGECC3PQ.js} +1 -1
- package/dist/{chunk-ZL6NXIGS.js → chunk-HT57FLRW.js} +1 -1
- package/dist/{chunk-BXEE6VGQ.js → chunk-KLH67DTH.js} +6 -23
- package/dist/{chunk-C5DKGJ4E.js → chunk-KOKA2IJC.js} +4 -4
- package/dist/{chunk-IPQIZG7U.js → chunk-N36EJLRW.js} +1 -1
- package/dist/{chunk-RFF2EFBX.js → chunk-OM7QLLI2.js} +2 -2
- package/dist/{chunk-FXJ7C6RF.js → chunk-PE3EZP56.js} +1 -1
- package/dist/chunk-WVGXD7HT.js +19 -0
- package/dist/{chunk-7OLDYFKY.js → chunk-X3NDEFVA.js} +1 -1
- package/dist/chunk-YV5FS7NV.js +89 -0
- package/dist/chunk-Z2HPSFEQ.js +14 -0
- package/dist/{chunk-RTZO2OU7.js → chunk-Z7XANQ47.js} +1 -1
- package/dist/components/CalendarRange.cjs +65 -46
- package/dist/components/CalendarRange.css +13 -0
- package/dist/components/CalendarRange.js +17 -14
- package/dist/components/CompactImagesPreview.js +3 -2
- package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.cjs +23 -4
- package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.css +13 -0
- package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.js +17 -14
- package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.cjs +32 -13
- package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.css +13 -0
- package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.js +17 -14
- package/dist/components/DataGrid/PinnedColumns.cjs +48 -29
- package/dist/components/DataGrid/PinnedColumns.css +13 -0
- package/dist/components/DataGrid/PinnedColumns.js +17 -14
- package/dist/components/DataGrid/TableBody/LoadingCell.cjs +24 -5
- package/dist/components/DataGrid/TableBody/LoadingCell.css +13 -0
- package/dist/components/DataGrid/TableBody/LoadingCell.js +17 -14
- package/dist/components/DataGrid/TableBody/TableBodyRow.cjs +30 -11
- package/dist/components/DataGrid/TableBody/TableBodyRow.css +13 -0
- package/dist/components/DataGrid/TableBody/TableBodyRow.js +17 -14
- package/dist/components/DataGrid/TableBody/index.cjs +45 -26
- package/dist/components/DataGrid/TableBody/index.css +13 -0
- package/dist/components/DataGrid/TableBody/index.js +17 -14
- package/dist/components/DataGrid/index.cjs +135 -116
- package/dist/components/DataGrid/index.css +13 -0
- package/dist/components/DataGrid/index.js +17 -14
- package/dist/components/DataGrid/utils.cjs +24 -5
- package/dist/components/DataGrid/utils.css +13 -0
- package/dist/components/DataGrid/utils.js +17 -14
- package/dist/components/DataGridCell.js +6 -5
- package/dist/components/DateInput.cjs +85 -66
- package/dist/components/DateInput.css +13 -0
- package/dist/components/DateInput.js +17 -14
- package/dist/components/DateRangeInput.cjs +84 -65
- package/dist/components/DateRangeInput.css +13 -0
- package/dist/components/DateRangeInput.js +17 -14
- package/dist/components/EmblaCarousel/ArrowButtons.cjs +147 -0
- package/dist/components/EmblaCarousel/ArrowButtons.js +9 -0
- package/dist/components/EmblaCarousel/SelectedSnapDisplay.cjs +38 -0
- package/dist/components/EmblaCarousel/SelectedSnapDisplay.js +7 -0
- package/dist/components/EmblaCarousel/index.cjs +266 -2
- package/dist/components/EmblaCarousel/index.js +4 -1
- package/dist/components/Menu.js +4 -3
- package/dist/components/MenuOption.js +3 -2
- package/dist/components/MobileDataGrid/ColumnList.css +13 -0
- package/dist/components/MobileDataGrid/ColumnList.js +1 -1
- package/dist/components/MobileDataGrid/ColumnSelector/index.cjs +31 -12
- package/dist/components/MobileDataGrid/ColumnSelector/index.css +13 -0
- package/dist/components/MobileDataGrid/ColumnSelector/index.js +17 -14
- package/dist/components/MobileDataGrid/MobileDataGridCard/index.js +1 -1
- package/dist/components/MobileDataGrid/MobileDataGridHeader.cjs +39 -20
- package/dist/components/MobileDataGrid/MobileDataGridHeader.css +13 -0
- package/dist/components/MobileDataGrid/MobileDataGridHeader.js +17 -14
- package/dist/components/MobileDataGrid/RowDetailModalProvider/ModalContent.js +1 -1
- package/dist/components/MobileDataGrid/RowDetailModalProvider/index.js +5 -4
- package/dist/components/MobileDataGrid/index.cjs +151 -132
- package/dist/components/MobileDataGrid/index.css +13 -0
- package/dist/components/MobileDataGrid/index.js +17 -14
- package/dist/components/Modal.js +3 -2
- package/dist/components/NestedMenu.js +3 -2
- package/dist/components/PDFViewer/DownloadIcon.js +4 -3
- package/dist/components/PDFViewer/index.js +5 -4
- package/dist/components/Password.js +3 -2
- package/dist/components/ProductImagePreview/index.js +4 -3
- package/dist/components/ProjectBar.js +2 -1
- package/dist/components/Stepper.js +3 -2
- package/dist/components/Tooltip.js +3 -2
- package/dist/components/index.cjs +222 -2
- package/dist/components/index.css +13 -0
- package/dist/components/index.js +17 -14
- package/dist/components/useMenuSystem.js +3 -2
- package/dist/hooks/index.js +5 -3
- package/dist/index.css +13 -0
- package/package.json +3 -3
- package/dist/chunk-SZ47M32R.js +0 -13
|
@@ -62,7 +62,7 @@ __export(DateInput_exports, {
|
|
|
62
62
|
DateInput: () => DateInput
|
|
63
63
|
});
|
|
64
64
|
module.exports = __toCommonJS(DateInput_exports);
|
|
65
|
-
var
|
|
65
|
+
var import_react43 = require("react");
|
|
66
66
|
var import_react_dom4 = require("react-dom");
|
|
67
67
|
|
|
68
68
|
// src/components/Input.tsx
|
|
@@ -833,8 +833,8 @@ Currency.displayName = "Currency";
|
|
|
833
833
|
Percentage.displayName = "Percentage";
|
|
834
834
|
|
|
835
835
|
// src/components/CalendarRange.tsx
|
|
836
|
-
var
|
|
837
|
-
var
|
|
836
|
+
var import_clsx43 = __toESM(require("clsx"), 1);
|
|
837
|
+
var import_react42 = __toESM(require("react"), 1);
|
|
838
838
|
var import_polyfill = require("@js-temporal/polyfill");
|
|
839
839
|
|
|
840
840
|
// src/components/DataGridCell.tsx
|
|
@@ -5348,11 +5348,30 @@ var import_react38 = require("react");
|
|
|
5348
5348
|
var import_jsx_runtime64 = require("react/jsx-runtime");
|
|
5349
5349
|
|
|
5350
5350
|
// src/components/EmblaCarousel/index.tsx
|
|
5351
|
+
var import_react41 = require("react");
|
|
5351
5352
|
var import_embla_carousel_react = __toESM(require("embla-carousel-react"), 1);
|
|
5353
|
+
|
|
5354
|
+
// src/components/EmblaCarousel/SelectedSnapDisplay.tsx
|
|
5352
5355
|
var import_jsx_runtime65 = require("react/jsx-runtime");
|
|
5353
5356
|
|
|
5354
|
-
// src/components/
|
|
5357
|
+
// src/components/EmblaCarousel/useSelectedSnapDisplay.ts
|
|
5358
|
+
var import_react39 = require("react");
|
|
5359
|
+
|
|
5360
|
+
// src/components/EmblaCarousel/ArrowButtons.tsx
|
|
5361
|
+
var import_clsx42 = __toESM(require("clsx"), 1);
|
|
5355
5362
|
var import_jsx_runtime66 = require("react/jsx-runtime");
|
|
5363
|
+
var arrowButtonStyles = (0, import_clsx42.default)(
|
|
5364
|
+
"appearance-none bg-transparent border cursor-pointer p-2 flex items-center justify-center size-9 rounded-full transition-colors duration-300 ease-in-out"
|
|
5365
|
+
);
|
|
5366
|
+
|
|
5367
|
+
// src/components/EmblaCarousel/usePrevNextButtons.ts
|
|
5368
|
+
var import_react40 = require("react");
|
|
5369
|
+
|
|
5370
|
+
// src/components/EmblaCarousel/index.tsx
|
|
5371
|
+
var import_jsx_runtime67 = require("react/jsx-runtime");
|
|
5372
|
+
|
|
5373
|
+
// src/components/CalendarRange.tsx
|
|
5374
|
+
var import_jsx_runtime68 = require("react/jsx-runtime");
|
|
5356
5375
|
function DateCell(_a) {
|
|
5357
5376
|
var _b = _a, {
|
|
5358
5377
|
date,
|
|
@@ -5387,12 +5406,12 @@ function DateCell(_a) {
|
|
|
5387
5406
|
"id",
|
|
5388
5407
|
"testid"
|
|
5389
5408
|
]);
|
|
5390
|
-
return /* @__PURE__ */ (0,
|
|
5409
|
+
return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5391
5410
|
"span",
|
|
5392
5411
|
__spreadProps(__spreadValues({}, props), {
|
|
5393
5412
|
id,
|
|
5394
5413
|
"data-testid": testid,
|
|
5395
|
-
className: (0,
|
|
5414
|
+
className: (0, import_clsx43.default)(
|
|
5396
5415
|
"flex items-center justify-center aspect-square select-none transition-colors border duration-100 font-medium",
|
|
5397
5416
|
typography.caption,
|
|
5398
5417
|
cellPadding,
|
|
@@ -5463,20 +5482,20 @@ function CalendarRange({
|
|
|
5463
5482
|
const fromDate = parseDate(from);
|
|
5464
5483
|
const toDate = parseDate(to);
|
|
5465
5484
|
const today = import_polyfill.Temporal.Now.plainDateISO();
|
|
5466
|
-
const [baseMonth, setBaseMonth] = (0,
|
|
5485
|
+
const [baseMonth, setBaseMonth] = (0, import_react42.useState)(
|
|
5467
5486
|
fromDate != null ? fromDate : today.with({ day: 1 })
|
|
5468
5487
|
);
|
|
5469
|
-
const [selecting, setSelecting] = (0,
|
|
5470
|
-
const [pendingFrom, setPendingFrom] = (0,
|
|
5471
|
-
const [hoveredDate, setHoveredDate] = (0,
|
|
5472
|
-
(0,
|
|
5488
|
+
const [selecting, setSelecting] = (0, import_react42.useState)("from");
|
|
5489
|
+
const [pendingFrom, setPendingFrom] = (0, import_react42.useState)(void 0);
|
|
5490
|
+
const [hoveredDate, setHoveredDate] = (0, import_react42.useState)(void 0);
|
|
5491
|
+
(0, import_react42.useEffect)(() => {
|
|
5473
5492
|
if (fromDate) {
|
|
5474
5493
|
setBaseMonth(fromDate.with({ day: 1 }));
|
|
5475
5494
|
} else if (toDate) {
|
|
5476
5495
|
setBaseMonth(toDate.with({ day: 1 }));
|
|
5477
5496
|
}
|
|
5478
5497
|
}, [from, to]);
|
|
5479
|
-
(0,
|
|
5498
|
+
(0, import_react42.useEffect)(() => {
|
|
5480
5499
|
if (fromDate && toDate) {
|
|
5481
5500
|
setSelecting("from");
|
|
5482
5501
|
setPendingFrom(void 0);
|
|
@@ -5543,12 +5562,12 @@ function CalendarRange({
|
|
|
5543
5562
|
}
|
|
5544
5563
|
return false;
|
|
5545
5564
|
}
|
|
5546
|
-
return /* @__PURE__ */ (0,
|
|
5565
|
+
return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5547
5566
|
"div",
|
|
5548
5567
|
{
|
|
5549
5568
|
id,
|
|
5550
5569
|
"data-testid": testid,
|
|
5551
|
-
className: (0,
|
|
5570
|
+
className: (0, import_clsx43.default)(
|
|
5552
5571
|
"relative bg-background-grouped-primary-normal rounded-base w-fit",
|
|
5553
5572
|
layoutPaddding,
|
|
5554
5573
|
layoutGap,
|
|
@@ -5556,15 +5575,15 @@ function CalendarRange({
|
|
|
5556
5575
|
// baseTransition,
|
|
5557
5576
|
"overflow-hidden"
|
|
5558
5577
|
),
|
|
5559
|
-
children: /* @__PURE__ */ (0,
|
|
5578
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5560
5579
|
"div",
|
|
5561
5580
|
{
|
|
5562
|
-
className: (0,
|
|
5581
|
+
className: (0, import_clsx43.default)(
|
|
5563
5582
|
"flex flex-row items-start justify-start bg-background-primary-normal overflow-clip",
|
|
5564
5583
|
layoutGap
|
|
5565
5584
|
),
|
|
5566
5585
|
children: (mode === "double" ? [0, 1] : [0]).map((offset, idx) => {
|
|
5567
|
-
return /* @__PURE__ */ (0,
|
|
5586
|
+
return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5568
5587
|
CalendarPane,
|
|
5569
5588
|
{
|
|
5570
5589
|
getMonthData,
|
|
@@ -5622,45 +5641,45 @@ function CalendarPane({
|
|
|
5622
5641
|
const years = Array.from({ length: 100 }).map(
|
|
5623
5642
|
(_, i) => baseMonth.year - 50 + i
|
|
5624
5643
|
);
|
|
5625
|
-
const [monthMenuOpen, setMonthMenuOpen] = (0,
|
|
5626
|
-
const [yearMenuOpen, setYearMenuOpen] = (0,
|
|
5627
|
-
const monthMenuRef = (0,
|
|
5628
|
-
const yearMenuRef = (0,
|
|
5644
|
+
const [monthMenuOpen, setMonthMenuOpen] = (0, import_react42.useState)(false);
|
|
5645
|
+
const [yearMenuOpen, setYearMenuOpen] = (0, import_react42.useState)(false);
|
|
5646
|
+
const monthMenuRef = (0, import_react42.useRef)(null);
|
|
5647
|
+
const yearMenuRef = (0, import_react42.useRef)(null);
|
|
5629
5648
|
const month = getMonthData(offset);
|
|
5630
5649
|
const totalCells = 42;
|
|
5631
5650
|
const emptyCells = month.firstDayOffset;
|
|
5632
|
-
return /* @__PURE__ */ (0,
|
|
5633
|
-
/* @__PURE__ */ (0,
|
|
5651
|
+
return /* @__PURE__ */ (0, import_jsx_runtime68.jsxs)(import_react42.default.Fragment, { children: [
|
|
5652
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsxs)(
|
|
5634
5653
|
"div",
|
|
5635
5654
|
{
|
|
5636
|
-
className: (0,
|
|
5655
|
+
className: (0, import_clsx43.default)("flex flex-col"),
|
|
5637
5656
|
children: [
|
|
5638
|
-
/* @__PURE__ */ (0,
|
|
5657
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsxs)(
|
|
5639
5658
|
"div",
|
|
5640
5659
|
{
|
|
5641
|
-
className: (0,
|
|
5660
|
+
className: (0, import_clsx43.default)(
|
|
5642
5661
|
"flex flex-row items-center justify-between",
|
|
5643
5662
|
typography.label,
|
|
5644
5663
|
"text-text-action-primary-normal"
|
|
5645
5664
|
),
|
|
5646
5665
|
children: [
|
|
5647
|
-
idx === 0 ? /* @__PURE__ */ (0,
|
|
5666
|
+
idx === 0 ? /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5648
5667
|
"button",
|
|
5649
5668
|
{
|
|
5650
5669
|
id: id ? `${id}-prev-month-button` : void 0,
|
|
5651
5670
|
"data-testid": testid ? `${testid}-prev-month-button` : void 0,
|
|
5652
5671
|
type: "button",
|
|
5653
|
-
className: (0,
|
|
5672
|
+
className: (0, import_clsx43.default)(
|
|
5654
5673
|
"flex items-center justify-center rounded-base hover:bg-action-100 active:bg-action-300 text-icon-action-primary-normal",
|
|
5655
5674
|
componentPadding
|
|
5656
5675
|
),
|
|
5657
5676
|
"aria-label": "Previous month",
|
|
5658
5677
|
onClick: () => setBaseMonth(baseMonth.subtract({ months: 1 })),
|
|
5659
|
-
children: /* @__PURE__ */ (0,
|
|
5678
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(Icon, { name: "chevron_left", size: 24 })
|
|
5660
5679
|
}
|
|
5661
|
-
) : /* @__PURE__ */ (0,
|
|
5662
|
-
/* @__PURE__ */ (0,
|
|
5663
|
-
/* @__PURE__ */ (0,
|
|
5680
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("span", { className: (0, import_clsx43.default)(componentPadding, "mr-1") }),
|
|
5681
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsxs)("div", { className: "flex gap-desktop-compact-component-padding", children: [
|
|
5682
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5664
5683
|
"button",
|
|
5665
5684
|
{
|
|
5666
5685
|
ref: (el) => {
|
|
@@ -5675,13 +5694,13 @@ function CalendarPane({
|
|
|
5675
5694
|
children: month.name
|
|
5676
5695
|
}
|
|
5677
5696
|
),
|
|
5678
|
-
/* @__PURE__ */ (0,
|
|
5697
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5679
5698
|
Menu,
|
|
5680
5699
|
{
|
|
5681
5700
|
show: monthMenuOpen,
|
|
5682
5701
|
positionTo: monthMenuRef,
|
|
5683
5702
|
setShow: () => setMonthMenuOpen(false),
|
|
5684
|
-
children: months.map((x) => [x, getMonthDataWith(x + 1)]).map(([x, m]) => /* @__PURE__ */ (0,
|
|
5703
|
+
children: months.map((x) => [x, getMonthDataWith(x + 1)]).map(([x, m]) => /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5685
5704
|
MenuOption,
|
|
5686
5705
|
{
|
|
5687
5706
|
selected: baseMonth.month === x + 1,
|
|
@@ -5695,7 +5714,7 @@ function CalendarPane({
|
|
|
5695
5714
|
))
|
|
5696
5715
|
}
|
|
5697
5716
|
),
|
|
5698
|
-
/* @__PURE__ */ (0,
|
|
5717
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5699
5718
|
"button",
|
|
5700
5719
|
{
|
|
5701
5720
|
ref: (el) => {
|
|
@@ -5710,13 +5729,13 @@ function CalendarPane({
|
|
|
5710
5729
|
children: month.year
|
|
5711
5730
|
}
|
|
5712
5731
|
),
|
|
5713
|
-
/* @__PURE__ */ (0,
|
|
5732
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5714
5733
|
Menu,
|
|
5715
5734
|
{
|
|
5716
5735
|
show: yearMenuOpen,
|
|
5717
5736
|
positionTo: yearMenuRef,
|
|
5718
5737
|
setShow: () => setYearMenuOpen(false),
|
|
5719
|
-
children: years.map((y) => /* @__PURE__ */ (0,
|
|
5738
|
+
children: years.map((y) => /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5720
5739
|
MenuOption,
|
|
5721
5740
|
{
|
|
5722
5741
|
selected: baseMonth.year === y,
|
|
@@ -5731,28 +5750,28 @@ function CalendarPane({
|
|
|
5731
5750
|
}
|
|
5732
5751
|
)
|
|
5733
5752
|
] }),
|
|
5734
|
-
(mode === "double" ? idx === 1 : true) ? /* @__PURE__ */ (0,
|
|
5753
|
+
(mode === "double" ? idx === 1 : true) ? /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5735
5754
|
"button",
|
|
5736
5755
|
{
|
|
5737
5756
|
id: id ? `${id}-next-month-button` : void 0,
|
|
5738
5757
|
"data-testid": testid ? `${testid}-next-month-button` : void 0,
|
|
5739
5758
|
type: "button",
|
|
5740
|
-
className: (0,
|
|
5759
|
+
className: (0, import_clsx43.default)(
|
|
5741
5760
|
"flex items-center justify-center rounded-base hover:bg-action-100 active:bg-action-300 text-icon-action-primary-normal",
|
|
5742
5761
|
componentPadding
|
|
5743
5762
|
),
|
|
5744
5763
|
"aria-label": "Next month",
|
|
5745
5764
|
onClick: () => setBaseMonth(baseMonth.add({ months: 1 })),
|
|
5746
|
-
children: /* @__PURE__ */ (0,
|
|
5765
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(Icon, { name: "chevron_right", size: 24 })
|
|
5747
5766
|
}
|
|
5748
|
-
) : /* @__PURE__ */ (0,
|
|
5767
|
+
) : /* @__PURE__ */ (0, import_jsx_runtime68.jsx)("span", { className: (0, import_clsx43.default)(componentPadding, "ml-1") })
|
|
5749
5768
|
]
|
|
5750
5769
|
}
|
|
5751
5770
|
),
|
|
5752
|
-
/* @__PURE__ */ (0,
|
|
5771
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsx)("div", { className: (0, import_clsx43.default)("grid grid-cols-7"), children: weekDays.map((d) => /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5753
5772
|
"span",
|
|
5754
5773
|
{
|
|
5755
|
-
className: (0,
|
|
5774
|
+
className: (0, import_clsx43.default)(
|
|
5756
5775
|
typography.caption,
|
|
5757
5776
|
"text-text-secondary-normal text-center",
|
|
5758
5777
|
"w-10"
|
|
@@ -5761,7 +5780,7 @@ function CalendarPane({
|
|
|
5761
5780
|
},
|
|
5762
5781
|
d
|
|
5763
5782
|
)) }),
|
|
5764
|
-
/* @__PURE__ */ (0,
|
|
5783
|
+
/* @__PURE__ */ (0, import_jsx_runtime68.jsx)("div", { className: (0, import_clsx43.default)("grid grid-cols-7"), children: Array.from({ length: totalCells }).map((_, i) => {
|
|
5765
5784
|
const day = i - emptyCells + 1;
|
|
5766
5785
|
const date = month.date.with({ day: 1 }).add({
|
|
5767
5786
|
days: i - emptyCells
|
|
@@ -5775,7 +5794,7 @@ function CalendarPane({
|
|
|
5775
5794
|
const hoverDateIsAfterPendingFrom = hoveredDate && pendingFrom && import_polyfill.Temporal.PlainDate.compare(hoveredDate, pendingFrom) >= 0;
|
|
5776
5795
|
const isRangeStart = mode === "single" && disableRange ? false : !pendingFrom && isInMonth && fromDate && date.equals(fromDate) || hoverDateIsAfterPendingFrom && date.equals(pendingFrom);
|
|
5777
5796
|
const isRangeEnd = mode === "single" && disableRange ? false : !pendingFrom && isInMonth && toDate && date.equals(toDate) || hoverDateIsBeforePendingFrom && date.equals(pendingFrom);
|
|
5778
|
-
return /* @__PURE__ */ (0,
|
|
5797
|
+
return /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5779
5798
|
DateCell,
|
|
5780
5799
|
{
|
|
5781
5800
|
id: id ? `${id}-date-${date.toString()}` : void 0,
|
|
@@ -5800,10 +5819,10 @@ function CalendarPane({
|
|
|
5800
5819
|
]
|
|
5801
5820
|
}
|
|
5802
5821
|
),
|
|
5803
|
-
mode === "double" && idx === 0 && /* @__PURE__ */ (0,
|
|
5822
|
+
mode === "double" && idx === 0 && /* @__PURE__ */ (0, import_jsx_runtime68.jsx)(
|
|
5804
5823
|
"div",
|
|
5805
5824
|
{
|
|
5806
|
-
className: (0,
|
|
5825
|
+
className: (0, import_clsx43.default)(
|
|
5807
5826
|
"self-stretch bg-border-primary-normal rounded-base",
|
|
5808
5827
|
// 1px width, full height, matches Figma divider
|
|
5809
5828
|
"w-px"
|
|
@@ -5868,7 +5887,7 @@ function parseInputDateWithDashes(value, dateInDashes) {
|
|
|
5868
5887
|
}
|
|
5869
5888
|
|
|
5870
5889
|
// src/components/DateInput.tsx
|
|
5871
|
-
var
|
|
5890
|
+
var import_jsx_runtime69 = require("react/jsx-runtime");
|
|
5872
5891
|
var DateInput = (_a) => {
|
|
5873
5892
|
var _b = _a, {
|
|
5874
5893
|
id,
|
|
@@ -5895,24 +5914,24 @@ var DateInput = (_a) => {
|
|
|
5895
5914
|
"disableManualInput",
|
|
5896
5915
|
"dateInDashes"
|
|
5897
5916
|
]);
|
|
5898
|
-
const [visible, setVisible] = (0,
|
|
5899
|
-
const [inputValue, setInputValue] = (0,
|
|
5900
|
-
const [isTyping, setIsTyping] = (0,
|
|
5901
|
-
const popoverRef = (0,
|
|
5902
|
-
const triggerRef = (0,
|
|
5903
|
-
const rootRef = (0,
|
|
5904
|
-
const [calendarPosition, setCalendarPosition] = (0,
|
|
5917
|
+
const [visible, setVisible] = (0, import_react43.useState)(false);
|
|
5918
|
+
const [inputValue, setInputValue] = (0, import_react43.useState)("");
|
|
5919
|
+
const [isTyping, setIsTyping] = (0, import_react43.useState)(false);
|
|
5920
|
+
const popoverRef = (0, import_react43.useRef)(null);
|
|
5921
|
+
const triggerRef = (0, import_react43.useRef)(null);
|
|
5922
|
+
const rootRef = (0, import_react43.useRef)(null);
|
|
5923
|
+
const [calendarPosition, setCalendarPosition] = (0, import_react43.useState)({
|
|
5905
5924
|
top: 0,
|
|
5906
5925
|
left: 0,
|
|
5907
5926
|
width: 0
|
|
5908
5927
|
});
|
|
5909
5928
|
const [from, to] = [value, ""];
|
|
5910
|
-
(0,
|
|
5929
|
+
(0, import_react43.useEffect)(() => {
|
|
5911
5930
|
if (!isTyping) {
|
|
5912
5931
|
setInputValue(formatDisplayValue(from, dateInDashes));
|
|
5913
5932
|
}
|
|
5914
5933
|
}, [from, isTyping, dateInDashes]);
|
|
5915
|
-
(0,
|
|
5934
|
+
(0, import_react43.useLayoutEffect)(() => {
|
|
5916
5935
|
if (visible) {
|
|
5917
5936
|
updatePosition();
|
|
5918
5937
|
}
|
|
@@ -5927,7 +5946,7 @@ var DateInput = (_a) => {
|
|
|
5927
5946
|
});
|
|
5928
5947
|
}
|
|
5929
5948
|
};
|
|
5930
|
-
(0,
|
|
5949
|
+
(0, import_react43.useEffect)(() => {
|
|
5931
5950
|
updatePosition();
|
|
5932
5951
|
const resizeObserver = new ResizeObserver(updatePosition);
|
|
5933
5952
|
if (triggerRef.current) {
|
|
@@ -5939,7 +5958,7 @@ var DateInput = (_a) => {
|
|
|
5939
5958
|
window.removeEventListener("scroll", updatePosition);
|
|
5940
5959
|
};
|
|
5941
5960
|
}, []);
|
|
5942
|
-
(0,
|
|
5961
|
+
(0, import_react43.useEffect)(() => {
|
|
5943
5962
|
const handleKeyDown2 = (event) => {
|
|
5944
5963
|
var _a2;
|
|
5945
5964
|
if (event.key === "Escape" && popoverRef.current) {
|
|
@@ -6028,8 +6047,8 @@ var DateInput = (_a) => {
|
|
|
6028
6047
|
}
|
|
6029
6048
|
}
|
|
6030
6049
|
};
|
|
6031
|
-
return /* @__PURE__ */ (0,
|
|
6032
|
-
/* @__PURE__ */ (0,
|
|
6050
|
+
return /* @__PURE__ */ (0, import_jsx_runtime69.jsxs)("div", { className: "relative", children: [
|
|
6051
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
6033
6052
|
InputBase,
|
|
6034
6053
|
__spreadProps(__spreadValues({
|
|
6035
6054
|
id,
|
|
@@ -6043,7 +6062,7 @@ var DateInput = (_a) => {
|
|
|
6043
6062
|
placeholder,
|
|
6044
6063
|
disabled,
|
|
6045
6064
|
readOnly,
|
|
6046
|
-
after: /* @__PURE__ */ (0,
|
|
6065
|
+
after: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(Icon, { name: "calendar_month" }),
|
|
6047
6066
|
onFocus: disableManualInput ? handleIgnoreFocus : handleFocus,
|
|
6048
6067
|
onClick: handleClick,
|
|
6049
6068
|
onChange: handleInputChange,
|
|
@@ -6054,8 +6073,8 @@ var DateInput = (_a) => {
|
|
|
6054
6073
|
})
|
|
6055
6074
|
),
|
|
6056
6075
|
visible && !readOnly && (0, import_react_dom4.createPortal)(
|
|
6057
|
-
/* @__PURE__ */ (0,
|
|
6058
|
-
/* @__PURE__ */ (0,
|
|
6076
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsxs)(import_jsx_runtime69.Fragment, { children: [
|
|
6077
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
6059
6078
|
"div",
|
|
6060
6079
|
{
|
|
6061
6080
|
className: "fixed inset-0 z-30",
|
|
@@ -6076,7 +6095,7 @@ var DateInput = (_a) => {
|
|
|
6076
6095
|
"aria-hidden": "true"
|
|
6077
6096
|
}
|
|
6078
6097
|
),
|
|
6079
|
-
/* @__PURE__ */ (0,
|
|
6098
|
+
/* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
6080
6099
|
"div",
|
|
6081
6100
|
{
|
|
6082
6101
|
ref: (el) => {
|
|
@@ -6087,7 +6106,7 @@ var DateInput = (_a) => {
|
|
|
6087
6106
|
top: `${calendarPosition.top + 4}px`,
|
|
6088
6107
|
left: `${calendarPosition.left}px`
|
|
6089
6108
|
},
|
|
6090
|
-
children: /* @__PURE__ */ (0,
|
|
6109
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime69.jsx)(
|
|
6091
6110
|
CalendarRange,
|
|
6092
6111
|
{
|
|
6093
6112
|
id: id ? `${id}-calendar` : void 0,
|
|
@@ -759,6 +759,10 @@
|
|
|
759
759
|
width: calc(var(--spacing) * 6);
|
|
760
760
|
height: calc(var(--spacing) * 6);
|
|
761
761
|
}
|
|
762
|
+
.size-9 {
|
|
763
|
+
width: calc(var(--spacing) * 9);
|
|
764
|
+
height: calc(var(--spacing) * 9);
|
|
765
|
+
}
|
|
762
766
|
.\!h-4\.5 {
|
|
763
767
|
height: calc(var(--spacing) * 4.5) !important;
|
|
764
768
|
}
|
|
@@ -1063,6 +1067,9 @@
|
|
|
1063
1067
|
.\[appearance\:textfield\] {
|
|
1064
1068
|
appearance: textfield;
|
|
1065
1069
|
}
|
|
1070
|
+
.appearance-none {
|
|
1071
|
+
appearance: none;
|
|
1072
|
+
}
|
|
1066
1073
|
.grid-cols-1 {
|
|
1067
1074
|
grid-template-columns: repeat(1, minmax(0, 1fr));
|
|
1068
1075
|
}
|
|
@@ -2122,6 +2129,9 @@
|
|
|
2122
2129
|
.pb-2 {
|
|
2123
2130
|
padding-bottom: calc(var(--spacing) * 2);
|
|
2124
2131
|
}
|
|
2132
|
+
.pb-3 {
|
|
2133
|
+
padding-bottom: calc(var(--spacing) * 3);
|
|
2134
|
+
}
|
|
2125
2135
|
.pb-mobile-component-padding {
|
|
2126
2136
|
padding-bottom: var(--spacing-mobile-component-padding);
|
|
2127
2137
|
}
|
|
@@ -2345,6 +2355,9 @@
|
|
|
2345
2355
|
.text-icon-on-action-secondary-normal {
|
|
2346
2356
|
color: var(--color-icon-on-action-secondary-normal);
|
|
2347
2357
|
}
|
|
2358
|
+
.text-icon-primary-disabled {
|
|
2359
|
+
color: var(--color-icon-primary-disabled);
|
|
2360
|
+
}
|
|
2348
2361
|
.text-icon-primary-normal {
|
|
2349
2362
|
color: var(--color-icon-primary-normal);
|
|
2350
2363
|
}
|
|
@@ -1,22 +1,24 @@
|
|
|
1
1
|
import {
|
|
2
2
|
DateInput
|
|
3
|
-
} from "../chunk-
|
|
4
|
-
import "../chunk-
|
|
3
|
+
} from "../chunk-E7XBOMT4.js";
|
|
4
|
+
import "../chunk-4DPSNQCM.js";
|
|
5
5
|
import "../chunk-Q4YDNW7N.js";
|
|
6
6
|
import "../chunk-M7INAUAJ.js";
|
|
7
|
-
import "../chunk-
|
|
7
|
+
import "../chunk-KOKA2IJC.js";
|
|
8
|
+
import "../chunk-MBZ55T2D.js";
|
|
8
9
|
import "../chunk-2IKT6IHB.js";
|
|
9
10
|
import "../chunk-YCDDBSVU.js";
|
|
10
11
|
import "../chunk-3X3Y4TMS.js";
|
|
11
12
|
import "../chunk-BQNPOGD5.js";
|
|
12
13
|
import "../chunk-Y5GD2FJA.js";
|
|
13
|
-
import "../chunk-
|
|
14
|
-
import "../chunk-SZ47M32R.js";
|
|
14
|
+
import "../chunk-3N34VVYD.js";
|
|
15
15
|
import "../chunk-B4AE3DCA.js";
|
|
16
16
|
import "../chunk-FP3Y5JJN.js";
|
|
17
17
|
import "../chunk-5IFPG6TS.js";
|
|
18
|
-
import "../chunk-AJ5M6MVX.js";
|
|
19
18
|
import "../chunk-6EYMKEJ6.js";
|
|
19
|
+
import "../chunk-AJ5M6MVX.js";
|
|
20
|
+
import "../chunk-YV5FS7NV.js";
|
|
21
|
+
import "../chunk-Z2HPSFEQ.js";
|
|
20
22
|
import "../chunk-AT4AWD6B.js";
|
|
21
23
|
import "../chunk-EWGHVZL5.js";
|
|
22
24
|
import "../chunk-FZ2TEKOE.js";
|
|
@@ -24,8 +26,8 @@ import "../chunk-FESS4LWU.js";
|
|
|
24
26
|
import "../chunk-KBIEWFQS.js";
|
|
25
27
|
import "../chunk-NSZTJ5R4.js";
|
|
26
28
|
import "../chunk-LB7UT6F3.js";
|
|
27
|
-
import "../chunk-
|
|
28
|
-
import "../chunk-
|
|
29
|
+
import "../chunk-HT57FLRW.js";
|
|
30
|
+
import "../chunk-N36EJLRW.js";
|
|
29
31
|
import "../chunk-4RJKB7LC.js";
|
|
30
32
|
import "../chunk-UUKHQUSF.js";
|
|
31
33
|
import "../chunk-WVVEOCEH.js";
|
|
@@ -36,17 +38,18 @@ import "../chunk-UAMI54FE.js";
|
|
|
36
38
|
import "../chunk-SJZNVG4N.js";
|
|
37
39
|
import "../chunk-75USUR3I.js";
|
|
38
40
|
import "../chunk-BWPNXY7T.js";
|
|
39
|
-
import "../chunk-
|
|
40
|
-
import "../chunk-
|
|
41
|
-
import "../chunk-
|
|
42
|
-
import "../chunk-
|
|
41
|
+
import "../chunk-5NRKL5CJ.js";
|
|
42
|
+
import "../chunk-OM7QLLI2.js";
|
|
43
|
+
import "../chunk-PE3EZP56.js";
|
|
44
|
+
import "../chunk-X3NDEFVA.js";
|
|
43
45
|
import "../chunk-FHXCCVOG.js";
|
|
44
46
|
import "../chunk-7T5RGDCN.js";
|
|
45
47
|
import "../chunk-HXGJVYGQ.js";
|
|
46
48
|
import "../chunk-WVUIIBRR.js";
|
|
47
49
|
import "../chunk-M7WHWZ2J.js";
|
|
48
|
-
import "../chunk-
|
|
49
|
-
import "../chunk-
|
|
50
|
+
import "../chunk-EGECC3PQ.js";
|
|
51
|
+
import "../chunk-KLH67DTH.js";
|
|
52
|
+
import "../chunk-WVGXD7HT.js";
|
|
50
53
|
import "../chunk-VXWSAIB5.js";
|
|
51
54
|
import "../chunk-MMZTPVYB.js";
|
|
52
55
|
import "../chunk-5UH6QUFB.js";
|