@dmsi/wedgekit-react 2.0.0 → 2.0.1
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/classNames.js +150 -0
- package/dist/components/AccessCard.js +63 -0
- package/dist/components/AccessCardGroup.js +73 -0
- package/dist/components/AccessChangerTabItem.js +51 -0
- package/dist/components/Accordion.js +99 -0
- package/dist/components/Alert.js +78 -0
- package/dist/components/Breadcrumbs.js +111 -0
- package/dist/components/Button.js +137 -0
- package/dist/components/CalendarRange.js +405 -0
- package/dist/components/Caption.js +99 -0
- package/dist/components/Card.js +50 -0
- package/dist/components/Checkbox.js +108 -0
- package/dist/components/CompactImagesPreview.js +120 -0
- package/dist/components/ContentTab.js +68 -0
- package/dist/components/ContentTabs.js +96 -0
- package/dist/components/DMSiLogo.js +54 -0
- package/dist/components/DataGrid/ColumnSelectorHeaderCell/ColumnSelectorMenuOption.js +27 -0
- package/dist/components/DataGrid/ColumnSelectorHeaderCell/index.js +79 -0
- package/dist/components/DataGrid/PinnedColumns.js +165 -0
- package/dist/components/DataGrid/SummaryRow/SummaryCell.js +51 -0
- package/dist/components/DataGrid/SummaryRow/aggregations.js +55 -0
- package/dist/components/DataGrid/SummaryRow/index.js +86 -0
- package/dist/components/DataGrid/TableBody/GroupRow.js +243 -0
- package/dist/components/DataGrid/TableBody/LoadingCell.js +33 -0
- package/dist/components/DataGrid/TableBody/TableBodyRow.js +136 -0
- package/dist/components/DataGrid/TableBody/index.js +161 -0
- package/dist/components/DataGrid/index.js +696 -0
- package/dist/components/DataGrid/utils.js +20 -0
- package/dist/components/DataGridCell.js +412 -0
- package/dist/components/DataTable.js +700 -0
- package/dist/components/DateInput.js +193 -0
- package/dist/components/DateRangeInput.js +368 -0
- package/dist/components/DebugJson.js +28 -0
- package/dist/components/Display.js +46 -0
- package/dist/components/EditingContext.js +34 -0
- package/dist/components/EmblaCarousel/ArrowButtons.js +83 -0
- package/dist/components/EmblaCarousel/SelectedSnapDisplay.js +12 -0
- package/dist/components/EmblaCarousel/index.js +153 -0
- package/dist/components/EmblaCarousel/usePrevNextButtons.js +21 -0
- package/dist/components/EmblaCarousel/useSelectedSnapDisplay.js +15 -0
- package/dist/components/EmptyCartIcon.js +25 -0
- package/dist/components/FilterGroup.js +198 -0
- package/dist/components/FullViewportBox.js +19 -0
- package/dist/components/Grid.js +54 -0
- package/dist/components/Heading.js +50 -0
- package/dist/components/HorizontalDivider.js +20 -0
- package/dist/components/Icon.js +73 -0
- package/dist/components/ImagePlaceholder.js +22 -0
- package/dist/components/Input.js +469 -0
- package/dist/components/InputGroup.js +45 -0
- package/dist/components/Label.js +37 -0
- package/dist/components/Link.js +69 -0
- package/dist/components/List.js +12 -0
- package/dist/components/ListGroup.js +54 -0
- package/dist/components/LiveChatComponent.js +25 -0
- package/dist/components/LoadingScrim.js +22 -0
- package/dist/components/LogoAgilityTopBar.js +90 -0
- package/dist/components/LogoDMSiTopBar.js +54 -0
- package/dist/components/LogoMillworkTopBar.js +196 -0
- package/dist/components/MainBar.js +58 -0
- package/dist/components/MaxViewportBox.js +19 -0
- package/dist/components/Menu.js +202 -0
- package/dist/components/MenuOption.js +161 -0
- package/dist/components/MobileDataGrid/ColumnList.js +85 -0
- package/dist/components/MobileDataGrid/ColumnSelector/index.js +100 -0
- package/dist/components/MobileDataGrid/GridContextProvider/GridContext.d.ts.map +1 -1
- package/dist/components/MobileDataGrid/GridContextProvider/GridContext.js +6 -0
- package/dist/components/MobileDataGrid/GridContextProvider/index.js +80 -0
- package/dist/components/MobileDataGrid/GridContextProvider/useGridContext.js +11 -0
- package/dist/components/MobileDataGrid/MobileDataGridCard/MobileDataGridColumn.js +18 -0
- package/dist/components/MobileDataGrid/MobileDataGridCard/index.js +130 -0
- package/dist/components/MobileDataGrid/MobileDataGridHeader.js +67 -0
- package/dist/components/MobileDataGrid/RowDetailModalProvider/ModalContent.js +42 -0
- package/dist/components/MobileDataGrid/RowDetailModalProvider/index.js +58 -0
- package/dist/components/MobileDataGrid/dataGridReducer.js +28 -0
- package/dist/components/MobileDataGrid/index.js +78 -0
- package/dist/components/MobileNavMenu.js +173 -0
- package/dist/components/Modal.js +201 -0
- package/dist/components/ModalButtons.js +57 -0
- package/dist/components/ModalContent.js +24 -0
- package/dist/components/ModalHeader.js +74 -0
- package/dist/components/ModalScrim.js +32 -0
- package/dist/components/NavigationTab.js +72 -0
- package/dist/components/NavigationTabs.js +45 -0
- package/dist/components/NestedMenu.js +119 -0
- package/dist/components/Notification.js +91 -0
- package/dist/components/OptionPill.js +103 -0
- package/dist/components/OrderCheckIcon.js +28 -0
- package/dist/components/PDFViewer/DownloadIcon.js +25 -0
- package/dist/components/PDFViewer/PDFElement.js +77 -0
- package/dist/components/PDFViewer/PDFNavigation.js +64 -0
- package/dist/components/PDFViewer/PDFPage.js +28 -0
- package/dist/components/PDFViewer/index.js +124 -0
- package/dist/components/Pagination.js +117 -0
- package/dist/components/Paragraph.js +43 -0
- package/dist/components/Password.js +47 -0
- package/dist/components/ProductImagePreview/CarouselPagination.js +48 -0
- package/dist/components/ProductImagePreview/MobileImageCarousel.js +146 -0
- package/dist/components/ProductImagePreview/ProductPrimaryImage.js +138 -0
- package/dist/components/ProductImagePreview/Thumbnail.js +46 -0
- package/dist/components/ProductImagePreview/ZoomWindow.js +74 -0
- package/dist/components/ProductImagePreview/index.js +189 -0
- package/dist/components/ProductImagePreview/useProductImagePreview.js +85 -0
- package/dist/components/ProjectBar.js +54 -0
- package/dist/components/Radio.js +113 -0
- package/dist/components/Search.js +89 -0
- package/dist/components/SearchResultImage/index.js +26 -0
- package/dist/components/Select.js +122 -0
- package/dist/components/SideMenu.js +24 -0
- package/dist/components/SideMenuGroup.js +80 -0
- package/dist/components/SideMenuItem.js +79 -0
- package/dist/components/SimpleTable.js +60 -0
- package/dist/components/SkeletonParagraph.js +24 -0
- package/dist/components/Spinner.js +30 -0
- package/dist/components/Stack.js +174 -0
- package/dist/components/StatusPill.js +44 -0
- package/dist/components/Stepper.js +138 -0
- package/dist/components/Subheader.js +41 -0
- package/dist/components/Surface.js +30 -0
- package/dist/components/Swatch.js +1498 -0
- package/dist/components/Textarea.js +106 -0
- package/dist/components/Theme.js +25 -0
- package/dist/components/Time.js +225 -0
- package/dist/components/Toast.js +170 -0
- package/dist/components/Tooltip.js +102 -0
- package/dist/components/TopBar.js +119 -0
- package/dist/components/Upload.js +107 -0
- package/dist/components/WorldpayIframe.js +19 -0
- package/dist/hooks/useEditCell.js +23 -0
- package/dist/hooks/useInfiniteScroll.js +25 -0
- package/dist/hooks/useKeydown.js +20 -0
- package/dist/hooks/useMatchesMedia.js +15 -0
- package/dist/hooks/useMenuSystem.js +186 -0
- package/dist/hooks/useMounted.js +9 -0
- package/dist/hooks/useTableLayout/computeColumns.js +59 -0
- package/dist/hooks/useTableLayout/storage.js +64 -0
- package/dist/hooks/useTableLayout/useTableLayout.js +163 -0
- package/dist/index.js +249 -53839
- package/dist/lib/loadFonts.js +11 -0
- package/dist/node_modules/@dnd-kit/accessibility/dist/accessibility.esm.js +56 -0
- package/dist/node_modules/@dnd-kit/core/dist/core.esm.js +2299 -0
- package/dist/node_modules/@dnd-kit/modifiers/dist/modifiers.esm.js +13 -0
- package/dist/node_modules/@dnd-kit/sortable/dist/sortable.esm.js +367 -0
- package/dist/node_modules/@dnd-kit/utilities/dist/utilities.esm.js +235 -0
- package/dist/node_modules/@headlessui/react/dist/components/description/description.js +45 -0
- package/dist/node_modules/@headlessui/react/dist/components/keyboard.js +4 -0
- package/dist/node_modules/@headlessui/react/dist/components/label/label.js +62 -0
- package/dist/node_modules/@headlessui/react/dist/components/switch/switch.js +56 -0
- package/dist/node_modules/@headlessui/react/dist/hooks/use-active-press.js +33 -0
- package/dist/node_modules/@headlessui/react/dist/hooks/use-controllable.js +10 -0
- package/dist/node_modules/@headlessui/react/dist/hooks/use-default-value.js +8 -0
- package/dist/node_modules/@headlessui/react/dist/hooks/use-disposables.js +9 -0
- package/dist/node_modules/@headlessui/react/dist/hooks/use-event.js +9 -0
- package/dist/node_modules/@headlessui/react/dist/hooks/use-iso-morphic-effect.js +8 -0
- package/dist/node_modules/@headlessui/react/dist/hooks/use-latest-value.js +11 -0
- package/dist/node_modules/@headlessui/react/dist/hooks/use-resolve-button-type.js +12 -0
- package/dist/node_modules/@headlessui/react/dist/hooks/use-slot.js +7 -0
- package/dist/node_modules/@headlessui/react/dist/hooks/use-sync-refs.js +16 -0
- package/dist/node_modules/@headlessui/react/dist/internal/disabled.js +8 -0
- package/dist/node_modules/@headlessui/react/dist/internal/form-fields.js +35 -0
- package/dist/node_modules/@headlessui/react/dist/internal/hidden.js +13 -0
- package/dist/node_modules/@headlessui/react/dist/internal/id.js +8 -0
- package/dist/node_modules/@headlessui/react/dist/utils/bugs.js +19 -0
- package/dist/node_modules/@headlessui/react/dist/utils/class-names.js +6 -0
- package/dist/node_modules/@headlessui/react/dist/utils/disposables.js +40 -0
- package/dist/node_modules/@headlessui/react/dist/utils/dom.js +34 -0
- package/dist/node_modules/@headlessui/react/dist/utils/env.js +34 -0
- package/dist/node_modules/@headlessui/react/dist/utils/form.js +32 -0
- package/dist/node_modules/@headlessui/react/dist/utils/match.js +11 -0
- package/dist/node_modules/@headlessui/react/dist/utils/micro-task.js +8 -0
- package/dist/node_modules/@headlessui/react/dist/utils/owner.js +8 -0
- package/dist/node_modules/@headlessui/react/dist/utils/render.js +126 -0
- package/dist/node_modules/@js-temporal/polyfill/dist/index.esm.js +3913 -0
- package/dist/node_modules/@mikecousins/react-pdf/dist/index.js +83 -0
- package/dist/node_modules/@react-aria/focus/dist/useFocusRing.js +38 -0
- package/dist/node_modules/@react-aria/interactions/dist/useFocus.js +31 -0
- package/dist/node_modules/@react-aria/interactions/dist/useFocusVisible.js +99 -0
- package/dist/node_modules/@react-aria/interactions/dist/useFocusWithin.js +59 -0
- package/dist/node_modules/@react-aria/interactions/dist/useHover.js +86 -0
- package/dist/node_modules/@react-aria/interactions/dist/utils.js +68 -0
- package/dist/node_modules/@react-aria/utils/dist/DOMFunctions.js +32 -0
- package/dist/node_modules/@react-aria/utils/dist/domHelpers.js +15 -0
- package/dist/node_modules/@react-aria/utils/dist/focusWithoutScrolling.js +45 -0
- package/dist/node_modules/@react-aria/utils/dist/isVirtualEvent.js +7 -0
- package/dist/node_modules/@react-aria/utils/dist/openLink.js +28 -0
- package/dist/node_modules/@react-aria/utils/dist/platform.js +47 -0
- package/dist/node_modules/@react-aria/utils/dist/useGlobalListeners.js +34 -0
- package/dist/node_modules/@react-aria/utils/dist/useLayoutEffect.js +6 -0
- package/dist/node_modules/@react-stately/flags/dist/import.js +7 -0
- package/dist/node_modules/@tanstack/react-table/build/lib/index.js +94 -0
- package/dist/node_modules/@tanstack/react-virtual/dist/esm/index.js +38 -0
- package/dist/node_modules/@tanstack/table-core/build/lib/index.js +1954 -0
- package/dist/node_modules/@tanstack/virtual-core/dist/esm/index.js +575 -0
- package/dist/node_modules/@tanstack/virtual-core/dist/esm/utils.js +52 -0
- package/dist/node_modules/clsx/dist/clsx.js +17 -0
- package/dist/node_modules/embla-carousel/esm/embla-carousel.esm.js +1204 -0
- package/dist/node_modules/embla-carousel-autoplay/esm/embla-carousel-autoplay.esm.js +126 -0
- package/dist/node_modules/embla-carousel-react/esm/embla-carousel-react.esm.js +24 -0
- package/dist/node_modules/embla-carousel-reactive-utils/esm/embla-carousel-reactive-utils.esm.js +35 -0
- package/dist/node_modules/jsbi/dist/jsbi.js +1040 -0
- package/dist/node_modules/react-use/esm/usePrevious.js +10 -0
- package/dist/static/no-results-image.png.js +4 -0
- package/dist/utils/date-patch-dashes.js +28 -0
- package/dist/utils/date.js +95 -0
- package/dist/utils/formatting.js +22 -0
- package/dist/utils/index.js +4 -0
- package/dist/utils/mergeObjectArrays.js +18 -0
- package/dist/utils.js +20 -0
- package/package.json +1 -1
- /package/dist/{pdf-l6QfMa5e.js → node_modules/pdfjs-dist/build/pdf.js} +0 -0
|
@@ -0,0 +1,189 @@
|
|
|
1
|
+
import { jsx as r, jsxs as v } from "react/jsx-runtime";
|
|
2
|
+
import { Thumbnail as x } from "./Thumbnail.js";
|
|
3
|
+
import { Stack as $ } from "../Stack.js";
|
|
4
|
+
import { Grid as D } from "../Grid.js";
|
|
5
|
+
import { ProductPrimaryImage as G } from "./ProductPrimaryImage.js";
|
|
6
|
+
import { ZoomWindow as K } from "./ZoomWindow.js";
|
|
7
|
+
import { CarouselPagination as L } from "./CarouselPagination.js";
|
|
8
|
+
import { MobileImageCarousel as U } from "./MobileImageCarousel.js";
|
|
9
|
+
import { useMatchesMobile as V } from "../../hooks/useMatchesMedia.js";
|
|
10
|
+
import { useState as q, useMemo as P, useCallback as B, useEffect as H } from "react";
|
|
11
|
+
import { useProductImagePreview as J } from "./useProductImagePreview.js";
|
|
12
|
+
const y = "/placeholder.svg";
|
|
13
|
+
function Q(c) {
|
|
14
|
+
const a = c?.trim();
|
|
15
|
+
return !!a && a !== y && !a.endsWith("/placeholder.svg") && !a.includes("/placeholder.svg?");
|
|
16
|
+
}
|
|
17
|
+
function me(c) {
|
|
18
|
+
const {
|
|
19
|
+
width: a = 483,
|
|
20
|
+
height: d = 483,
|
|
21
|
+
thumbsPerRow: h = 4,
|
|
22
|
+
zoomEnabled: g = !1,
|
|
23
|
+
scrollToZoomEnabled: u = !1,
|
|
24
|
+
images: l,
|
|
25
|
+
currentIndex: z,
|
|
26
|
+
onChangeIndex: w,
|
|
27
|
+
zoomLensSize: E,
|
|
28
|
+
zoomFactor: S = 2,
|
|
29
|
+
zoomWindowScaleFactor: C = 2.5,
|
|
30
|
+
zoomWindowOffset: Z = 10,
|
|
31
|
+
testid: k
|
|
32
|
+
} = c, [f, p] = q([]), F = P(
|
|
33
|
+
() => l.map((e) => e.src).join("|"),
|
|
34
|
+
[l]
|
|
35
|
+
), t = P(
|
|
36
|
+
() => l.filter(
|
|
37
|
+
(e) => Q(e.src) && f.indexOf(e.src) === -1
|
|
38
|
+
),
|
|
39
|
+
[f, l]
|
|
40
|
+
), n = B((e) => {
|
|
41
|
+
e && p(
|
|
42
|
+
(o) => o.indexOf(e) >= 0 ? o : [...o, e]
|
|
43
|
+
);
|
|
44
|
+
}, []);
|
|
45
|
+
H(() => {
|
|
46
|
+
p([]);
|
|
47
|
+
}, [F]);
|
|
48
|
+
const i = V(), {
|
|
49
|
+
zoomPoint: W,
|
|
50
|
+
zoomActive: T,
|
|
51
|
+
currentZoomFactor: j,
|
|
52
|
+
primaryImagePosition: M,
|
|
53
|
+
safeIndex: m,
|
|
54
|
+
active: I,
|
|
55
|
+
primaryImageRef: N,
|
|
56
|
+
handleSelect: s,
|
|
57
|
+
handleZoomPositionChange: A,
|
|
58
|
+
handleScrollZoom: O
|
|
59
|
+
} = J({
|
|
60
|
+
images: t,
|
|
61
|
+
currentIndex: z,
|
|
62
|
+
zoomEnabled: g,
|
|
63
|
+
zoomFactor: S,
|
|
64
|
+
scrollToZoomEnabled: u,
|
|
65
|
+
onChangeIndex: w,
|
|
66
|
+
isMobile: i
|
|
67
|
+
});
|
|
68
|
+
if (typeof i > "u") return null;
|
|
69
|
+
if (i && !t.length)
|
|
70
|
+
return /* @__PURE__ */ r(
|
|
71
|
+
"img",
|
|
72
|
+
{
|
|
73
|
+
src: y,
|
|
74
|
+
alt: "Placeholder Image",
|
|
75
|
+
draggable: !1,
|
|
76
|
+
loading: "eager",
|
|
77
|
+
style: {
|
|
78
|
+
aspectRatio: "1 / 1",
|
|
79
|
+
objectFit: "cover",
|
|
80
|
+
height: "100%",
|
|
81
|
+
width: "100%"
|
|
82
|
+
}
|
|
83
|
+
}
|
|
84
|
+
);
|
|
85
|
+
const b = g && !i, R = t.length > 1;
|
|
86
|
+
return /* @__PURE__ */ v(
|
|
87
|
+
$,
|
|
88
|
+
{
|
|
89
|
+
sizing: "layout-group",
|
|
90
|
+
style: { width: a, position: "relative" },
|
|
91
|
+
testid: k,
|
|
92
|
+
children: [
|
|
93
|
+
/* @__PURE__ */ r("div", { className: "hidden md:block", children: /* @__PURE__ */ v("div", { className: "flex gap-4 items-start", children: [
|
|
94
|
+
/* @__PURE__ */ r("div", { ref: N, children: /* @__PURE__ */ r(
|
|
95
|
+
G,
|
|
96
|
+
{
|
|
97
|
+
image: I,
|
|
98
|
+
width: a,
|
|
99
|
+
height: d,
|
|
100
|
+
zoomEnabled: b,
|
|
101
|
+
zoomLensSize: E,
|
|
102
|
+
scrollToZoomEnabled: u && !i,
|
|
103
|
+
onZoomPositionChange: A,
|
|
104
|
+
onScrollZoom: O,
|
|
105
|
+
isPlaceholder: t.length === 0,
|
|
106
|
+
onImageError: n
|
|
107
|
+
}
|
|
108
|
+
) }),
|
|
109
|
+
b && /* @__PURE__ */ r(
|
|
110
|
+
K,
|
|
111
|
+
{
|
|
112
|
+
image: I,
|
|
113
|
+
width: a,
|
|
114
|
+
height: d,
|
|
115
|
+
pointer: W,
|
|
116
|
+
active: T,
|
|
117
|
+
zoomFactor: j,
|
|
118
|
+
scaleFactor: C,
|
|
119
|
+
primaryImagePosition: M,
|
|
120
|
+
offset: Z
|
|
121
|
+
}
|
|
122
|
+
)
|
|
123
|
+
] }) }),
|
|
124
|
+
i && /* @__PURE__ */ r(
|
|
125
|
+
U,
|
|
126
|
+
{
|
|
127
|
+
images: t,
|
|
128
|
+
currentIndex: m,
|
|
129
|
+
width: a,
|
|
130
|
+
height: d,
|
|
131
|
+
onChangeIndex: s,
|
|
132
|
+
onImageError: n
|
|
133
|
+
}
|
|
134
|
+
),
|
|
135
|
+
R && /* @__PURE__ */ r("div", { className: "hidden md:block", children: t.length <= 3 ? /* @__PURE__ */ r(
|
|
136
|
+
"div",
|
|
137
|
+
{
|
|
138
|
+
className: "flex justify-center gap-4",
|
|
139
|
+
style: { width: "100%", maxWidth: a },
|
|
140
|
+
"aria-label": "Product image thumbnails",
|
|
141
|
+
children: t.map((e, o) => /* @__PURE__ */ r("div", { style: { maxWidth: "115px" }, children: /* @__PURE__ */ r(
|
|
142
|
+
x,
|
|
143
|
+
{
|
|
144
|
+
src: e.src,
|
|
145
|
+
alt: e.alt || `Thumbnail ${o + 1}`,
|
|
146
|
+
isActive: o === m,
|
|
147
|
+
onClick: () => s(o),
|
|
148
|
+
onImageError: n
|
|
149
|
+
}
|
|
150
|
+
) }, e.src + o))
|
|
151
|
+
}
|
|
152
|
+
) : /* @__PURE__ */ r(
|
|
153
|
+
D,
|
|
154
|
+
{
|
|
155
|
+
sizing: "layout-group",
|
|
156
|
+
"aria-label": "Product image thumbnails",
|
|
157
|
+
style: {
|
|
158
|
+
width: "100%",
|
|
159
|
+
maxWidth: a
|
|
160
|
+
},
|
|
161
|
+
columns: h > 12 ? 12 : h < 1 ? 1 : h,
|
|
162
|
+
children: t.map((e, o) => /* @__PURE__ */ r(
|
|
163
|
+
x,
|
|
164
|
+
{
|
|
165
|
+
src: e.src,
|
|
166
|
+
alt: e.alt || `Thumbnail ${o + 1}`,
|
|
167
|
+
isActive: o === m,
|
|
168
|
+
onClick: () => s(o),
|
|
169
|
+
onImageError: n
|
|
170
|
+
},
|
|
171
|
+
e.src + o
|
|
172
|
+
))
|
|
173
|
+
}
|
|
174
|
+
) }),
|
|
175
|
+
/* @__PURE__ */ r(
|
|
176
|
+
L,
|
|
177
|
+
{
|
|
178
|
+
images: t,
|
|
179
|
+
currentIndex: m,
|
|
180
|
+
onSelect: s
|
|
181
|
+
}
|
|
182
|
+
)
|
|
183
|
+
]
|
|
184
|
+
}
|
|
185
|
+
);
|
|
186
|
+
}
|
|
187
|
+
export {
|
|
188
|
+
me as ProductImagePreview
|
|
189
|
+
};
|
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
import { useMemo as O, useState as u, useRef as P, useEffect as Z, useCallback as i } from "react";
|
|
2
|
+
function B(b) {
|
|
3
|
+
const {
|
|
4
|
+
images: o,
|
|
5
|
+
currentIndex: m,
|
|
6
|
+
zoomEnabled: E = !1,
|
|
7
|
+
zoomFactor: d = 2,
|
|
8
|
+
scrollToZoomEnabled: p = !1,
|
|
9
|
+
onChangeIndex: s,
|
|
10
|
+
isMobile: a = !1
|
|
11
|
+
} = b, r = !!o?.length, n = r && m >= 0 && m < o.length ? m : 0, x = O(() => r ? o[n] : void 0, [r, o, n]), [z, F] = u(null), [C, R] = u(!1), [f, g] = u(d), [A, L] = u(null), v = P(null), l = P(null), h = E && !a, w = p && !a;
|
|
12
|
+
Z(() => {
|
|
13
|
+
if (!h) return;
|
|
14
|
+
const e = () => {
|
|
15
|
+
const t = v.current;
|
|
16
|
+
if (!t) return;
|
|
17
|
+
const c = () => {
|
|
18
|
+
t && L(t.getBoundingClientRect());
|
|
19
|
+
};
|
|
20
|
+
c();
|
|
21
|
+
const I = new ResizeObserver(c);
|
|
22
|
+
I.observe(t), window.addEventListener("scroll", c), window.addEventListener("resize", c), l.current = () => {
|
|
23
|
+
I.disconnect(), window.removeEventListener("scroll", c), window.removeEventListener("resize", c);
|
|
24
|
+
};
|
|
25
|
+
};
|
|
26
|
+
if (v.current)
|
|
27
|
+
e();
|
|
28
|
+
else {
|
|
29
|
+
const t = requestAnimationFrame(e);
|
|
30
|
+
return () => cancelAnimationFrame(t);
|
|
31
|
+
}
|
|
32
|
+
return () => {
|
|
33
|
+
l.current && (l.current(), l.current = null);
|
|
34
|
+
};
|
|
35
|
+
}, [h]);
|
|
36
|
+
const M = i(
|
|
37
|
+
(e) => {
|
|
38
|
+
e !== n && s(e);
|
|
39
|
+
},
|
|
40
|
+
[n, s]
|
|
41
|
+
), S = i(() => {
|
|
42
|
+
if (!r) return;
|
|
43
|
+
const e = (n + 1) % o.length;
|
|
44
|
+
s(e);
|
|
45
|
+
}, [r, n, o.length, s]), y = i(() => {
|
|
46
|
+
if (!r) return;
|
|
47
|
+
const e = n === 0 ? o.length - 1 : n - 1;
|
|
48
|
+
s(e);
|
|
49
|
+
}, [r, n, o.length, s]), T = i(
|
|
50
|
+
(e, t) => {
|
|
51
|
+
a || (F(e), R(t));
|
|
52
|
+
},
|
|
53
|
+
[a]
|
|
54
|
+
), k = i(
|
|
55
|
+
(e) => {
|
|
56
|
+
if (!w) return;
|
|
57
|
+
const t = Math.max(1, Math.min(5, f + e));
|
|
58
|
+
g(t);
|
|
59
|
+
},
|
|
60
|
+
[w, f]
|
|
61
|
+
);
|
|
62
|
+
return Z(() => {
|
|
63
|
+
g(d);
|
|
64
|
+
}, [d]), {
|
|
65
|
+
// State
|
|
66
|
+
zoomPoint: z,
|
|
67
|
+
zoomActive: C,
|
|
68
|
+
currentZoomFactor: f,
|
|
69
|
+
primaryImagePosition: A,
|
|
70
|
+
hasImages: r,
|
|
71
|
+
safeIndex: n,
|
|
72
|
+
active: x,
|
|
73
|
+
// Refs
|
|
74
|
+
primaryImageRef: v,
|
|
75
|
+
// Handlers
|
|
76
|
+
handleSelect: M,
|
|
77
|
+
handleZoomPositionChange: T,
|
|
78
|
+
handleScrollZoom: k,
|
|
79
|
+
handleNext: S,
|
|
80
|
+
handlePrevious: y
|
|
81
|
+
};
|
|
82
|
+
}
|
|
83
|
+
export {
|
|
84
|
+
B as useProductImagePreview
|
|
85
|
+
};
|
|
@@ -0,0 +1,54 @@
|
|
|
1
|
+
import { jsxs as m, jsx as o } from "react/jsx-runtime";
|
|
2
|
+
import { clsx as r } from "../node_modules/clsx/dist/clsx.js";
|
|
3
|
+
import { layoutGroupGap as a, paddingYUsingLayoutGroupGap as s, containerPaddingX as p, layoutGap as v } from "../classNames.js";
|
|
4
|
+
import { useMatchesMobile as u } from "../hooks/useMatchesMedia.js";
|
|
5
|
+
import "react";
|
|
6
|
+
function g({
|
|
7
|
+
left: c,
|
|
8
|
+
right: e,
|
|
9
|
+
mobileLeft: i,
|
|
10
|
+
mobileRight: l,
|
|
11
|
+
id: t,
|
|
12
|
+
testid: n
|
|
13
|
+
}) {
|
|
14
|
+
const d = u() ? {
|
|
15
|
+
"--color-background-primary-normal": "var(--color-brand-400)",
|
|
16
|
+
"--color-background-action-primary-normal": "var(--color-neutral-000)",
|
|
17
|
+
"--color-background-action-primary-hover": "var(--color-critical-100)",
|
|
18
|
+
"--color-background-action-primary-active": "var(--color-neutral-200)",
|
|
19
|
+
"--color-background-action-secondary-normal": "var(--color-brand-400)",
|
|
20
|
+
"--color-background-action-secondary-hover": "var(--color-critical-100)",
|
|
21
|
+
"--color-text-on-action-primary-normal": "var(--color-brand-400)",
|
|
22
|
+
"--color-text-primary-normal": "var(--color-neutral-000)",
|
|
23
|
+
"--color-text-action-primary-normal": "var(--color-neutral-000)",
|
|
24
|
+
"--color-text-action-primary-hover": "var(--color-critical-500)",
|
|
25
|
+
"--color-text-action-primary-active": "var(--color-critical-300)",
|
|
26
|
+
"--color-border-action-normal": "var(--color-neutral-000)",
|
|
27
|
+
"--color-border-action-hover": "var(--color-critical-500)",
|
|
28
|
+
"--color-border-action-active": "var(--color-critical-300)"
|
|
29
|
+
} : {};
|
|
30
|
+
return /* @__PURE__ */ m(
|
|
31
|
+
"div",
|
|
32
|
+
{
|
|
33
|
+
id: t,
|
|
34
|
+
"data-testid": n,
|
|
35
|
+
style: { ...d },
|
|
36
|
+
className: r(
|
|
37
|
+
"flex items-center justify-between",
|
|
38
|
+
"bg-background-primary-normal text-text-primary-normal",
|
|
39
|
+
s,
|
|
40
|
+
p,
|
|
41
|
+
v
|
|
42
|
+
),
|
|
43
|
+
children: [
|
|
44
|
+
/* @__PURE__ */ o("div", { className: r("hidden desktop:block flex-1 leading-[1]"), children: c }),
|
|
45
|
+
/* @__PURE__ */ o("div", { className: r("hidden desktop:flex items-center", a), children: e }),
|
|
46
|
+
/* @__PURE__ */ o("div", { className: r("flex flex-col desktop:hidden"), children: i }),
|
|
47
|
+
/* @__PURE__ */ o("div", { className: r("flex items-center desktop:hidden", a), children: l })
|
|
48
|
+
]
|
|
49
|
+
}
|
|
50
|
+
);
|
|
51
|
+
}
|
|
52
|
+
export {
|
|
53
|
+
g as ProjectBar
|
|
54
|
+
};
|
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsxs as d, jsx as o } from "react/jsx-runtime";
|
|
3
|
+
import { clsx as r } from "../node_modules/clsx/dist/clsx.js";
|
|
4
|
+
import { baseTransition as x, componentGap as g } from "../classNames.js";
|
|
5
|
+
import { Paragraph as f } from "./Paragraph.js";
|
|
6
|
+
function $({
|
|
7
|
+
className: i,
|
|
8
|
+
label: s,
|
|
9
|
+
error: c,
|
|
10
|
+
disabled: e,
|
|
11
|
+
checked: l,
|
|
12
|
+
readOnly: n,
|
|
13
|
+
id: p,
|
|
14
|
+
testid: a,
|
|
15
|
+
...v
|
|
16
|
+
}) {
|
|
17
|
+
const t = p, b = e ? "text-primary-disabled" : c ? "text-primary-error" : "text-primary-normal", h = r(
|
|
18
|
+
!c && !e && "border-border-primary-normal peer-hover:border-border-action-hover peer-hover:bg-background-action-secondary-hover peer-focus:border-border-action-hover peer-focus:bg-background-action-secondary-hover peer-active:border-border-action-active peer-active:bg-background-action-secondary-active peer-checked:border-0 peer-checked:bg-background-action-secondary-hover"
|
|
19
|
+
), y = r(
|
|
20
|
+
c && !e && "border-border-action-critical-normal peer-hover:border-border-action-critical-hover peer-hover:bg-background-action-critical-secondary-hover peer-focus:border-border-action-critical-hover peer-focus:bg-background-action-critical-secondary-hover peer-active:border-border-action-critical-active peer-active:bg-background-action-secondary-active peer-checked:bg-background-action-critical-secondary-hover peer-checked:border-0 "
|
|
21
|
+
), m = r(
|
|
22
|
+
e && "peer-disabled:bg-background-action-secondary-disabled peer-disabled:border-border-primary-normal peer-checked:border-0"
|
|
23
|
+
), u = r(
|
|
24
|
+
n && "peer-read-only:bg-background-action-secondary-disabled peer-read-only:border-border-primary-normal peer-checked:border-0"
|
|
25
|
+
);
|
|
26
|
+
return /* @__PURE__ */ d(
|
|
27
|
+
"label",
|
|
28
|
+
{
|
|
29
|
+
htmlFor: t,
|
|
30
|
+
"data-testid": a,
|
|
31
|
+
className: r(
|
|
32
|
+
"flex items-center",
|
|
33
|
+
g,
|
|
34
|
+
e ? "cursor-default" : "cursor-pointer",
|
|
35
|
+
i
|
|
36
|
+
),
|
|
37
|
+
children: [
|
|
38
|
+
/* @__PURE__ */ d("div", { className: "relative", children: [
|
|
39
|
+
/* @__PURE__ */ o(
|
|
40
|
+
"input",
|
|
41
|
+
{
|
|
42
|
+
id: t,
|
|
43
|
+
"data-testid": a ? `${a}-input` : void 0,
|
|
44
|
+
type: "radio",
|
|
45
|
+
className: "sr-only peer",
|
|
46
|
+
disabled: e,
|
|
47
|
+
checked: l,
|
|
48
|
+
readOnly: n,
|
|
49
|
+
...v
|
|
50
|
+
}
|
|
51
|
+
),
|
|
52
|
+
/* @__PURE__ */ o(
|
|
53
|
+
"div",
|
|
54
|
+
{
|
|
55
|
+
className: r(
|
|
56
|
+
"size-6 rounded-full border flex items-center justify-center",
|
|
57
|
+
x,
|
|
58
|
+
h,
|
|
59
|
+
y,
|
|
60
|
+
m,
|
|
61
|
+
u
|
|
62
|
+
),
|
|
63
|
+
children: l && /* @__PURE__ */ o(
|
|
64
|
+
k,
|
|
65
|
+
{
|
|
66
|
+
className: r(
|
|
67
|
+
"transition-colors",
|
|
68
|
+
!c && !e && "text-icon-on-action-secondary-normal hover:text-icon-on-action-secondary-hover active:text-icon-on-action-secondary-active peer-hover:text-icon-on-action-secondary-hover peer-focus:text-icon-on-action-secondary-hover peer-active:text-icon-on-action-secondary-active",
|
|
69
|
+
c && !e && "text-icon-action-critical-secondary-normal hover:text-icon-action-critical-secondary-hover active:text-icon-action-critical-secondary-active peer-hover:text-icon-action-critical-secondary-hover peer-focus:text-icon-action-critical-secondary-hover peer-active:text-icon-action-critical-secondary-active",
|
|
70
|
+
e && "text-icon-on-action-secondary-disabled",
|
|
71
|
+
n && "text-icon-on-action-secondary-disabled"
|
|
72
|
+
)
|
|
73
|
+
}
|
|
74
|
+
)
|
|
75
|
+
}
|
|
76
|
+
)
|
|
77
|
+
] }),
|
|
78
|
+
s && /* @__PURE__ */ o(f, { id: t ? `${t}-label` : void 0, testid: a ? `${a}-label` : void 0, padded: !0, color: b, children: s })
|
|
79
|
+
]
|
|
80
|
+
}
|
|
81
|
+
);
|
|
82
|
+
}
|
|
83
|
+
function k({ className: i }) {
|
|
84
|
+
return /* @__PURE__ */ d(
|
|
85
|
+
"svg",
|
|
86
|
+
{
|
|
87
|
+
className: i,
|
|
88
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
89
|
+
width: "24",
|
|
90
|
+
height: "24",
|
|
91
|
+
viewBox: "0 0 24 24",
|
|
92
|
+
fill: "none",
|
|
93
|
+
children: [
|
|
94
|
+
/* @__PURE__ */ o(
|
|
95
|
+
"rect",
|
|
96
|
+
{
|
|
97
|
+
x: "1",
|
|
98
|
+
y: "1",
|
|
99
|
+
width: "22",
|
|
100
|
+
height: "22",
|
|
101
|
+
rx: "11",
|
|
102
|
+
stroke: "currentColor",
|
|
103
|
+
strokeWidth: "2"
|
|
104
|
+
}
|
|
105
|
+
),
|
|
106
|
+
/* @__PURE__ */ o("rect", { x: "4", y: "4", width: "16", height: "16", rx: "8", fill: "currentColor" })
|
|
107
|
+
]
|
|
108
|
+
}
|
|
109
|
+
);
|
|
110
|
+
}
|
|
111
|
+
export {
|
|
112
|
+
$ as Radio
|
|
113
|
+
};
|
|
@@ -0,0 +1,89 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsxs as k, Fragment as C, jsx as R } from "react/jsx-runtime";
|
|
3
|
+
import { useRef as a, useState as S, useId as $, useEffect as M } from "react";
|
|
4
|
+
import { Input as j } from "./Input.js";
|
|
5
|
+
function T({
|
|
6
|
+
id: r,
|
|
7
|
+
testid: u,
|
|
8
|
+
label: q,
|
|
9
|
+
error: v,
|
|
10
|
+
children: A,
|
|
11
|
+
readOnly: f,
|
|
12
|
+
renderMenu: s,
|
|
13
|
+
onClick: F,
|
|
14
|
+
wrapperClassName: I,
|
|
15
|
+
removeRoundness: g,
|
|
16
|
+
autocompletePadding: x = !1,
|
|
17
|
+
...n
|
|
18
|
+
}) {
|
|
19
|
+
const m = a(null), d = a(null), p = a(!0), [c, l] = S(!1), [D, w] = S(!1), h = `search-menu-${$()}`;
|
|
20
|
+
return M(() => {
|
|
21
|
+
if (p.current) {
|
|
22
|
+
p.current = !1;
|
|
23
|
+
return;
|
|
24
|
+
}
|
|
25
|
+
m.current?.focus();
|
|
26
|
+
}, [n.value]), /* @__PURE__ */ k(C, { children: [
|
|
27
|
+
/* @__PURE__ */ R(
|
|
28
|
+
j,
|
|
29
|
+
{
|
|
30
|
+
id: r,
|
|
31
|
+
testid: u,
|
|
32
|
+
variant: "search",
|
|
33
|
+
inputContainerRef: d,
|
|
34
|
+
ref: m,
|
|
35
|
+
label: q,
|
|
36
|
+
wrapperClassName: I,
|
|
37
|
+
autocompletePadding: x,
|
|
38
|
+
onClick: (t) => {
|
|
39
|
+
if (!(n.disabled || f)) {
|
|
40
|
+
if (D) {
|
|
41
|
+
w(!1);
|
|
42
|
+
return;
|
|
43
|
+
}
|
|
44
|
+
F?.(t), l(!c);
|
|
45
|
+
}
|
|
46
|
+
},
|
|
47
|
+
onClear: () => {
|
|
48
|
+
w(!0);
|
|
49
|
+
},
|
|
50
|
+
onKeyDown: (t) => {
|
|
51
|
+
if (l(!0), ["ArrowUp", "ArrowDown"].includes(t.key)) {
|
|
52
|
+
t.preventDefault();
|
|
53
|
+
const o = document.querySelector(
|
|
54
|
+
`[data-menu="${h}"]`
|
|
55
|
+
), y = o?.querySelector("[data-selected]");
|
|
56
|
+
if (y) {
|
|
57
|
+
const e = Array.from(
|
|
58
|
+
o?.querySelectorAll('[role="menuitem"]') || []
|
|
59
|
+
), O = e.indexOf(y);
|
|
60
|
+
let i;
|
|
61
|
+
t.key === "ArrowDown" ? i = e[O + 1] || e[0] : i = e[O - 1] || e[e.length - 1], i?.focus();
|
|
62
|
+
} else
|
|
63
|
+
(t.key === "ArrowDown" ? o?.querySelector('[role="menuitem"]') : o?.querySelector(
|
|
64
|
+
'[role="menuitem"]:last-child'
|
|
65
|
+
))?.focus();
|
|
66
|
+
}
|
|
67
|
+
},
|
|
68
|
+
error: v,
|
|
69
|
+
readOnly: f,
|
|
70
|
+
removeRoundness: g,
|
|
71
|
+
isFocused: s && c,
|
|
72
|
+
...n
|
|
73
|
+
}
|
|
74
|
+
),
|
|
75
|
+
s ? s({
|
|
76
|
+
id: r ? `${r}-menu` : void 0,
|
|
77
|
+
testid: u ? `${u}-menu` : void 0,
|
|
78
|
+
positionTo: d,
|
|
79
|
+
show: c,
|
|
80
|
+
setShow: l,
|
|
81
|
+
topOffset: n.caption ? -16 : null,
|
|
82
|
+
autoFocusOff: !0,
|
|
83
|
+
menuName: h
|
|
84
|
+
}) : A
|
|
85
|
+
] });
|
|
86
|
+
}
|
|
87
|
+
export {
|
|
88
|
+
T as Search
|
|
89
|
+
};
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import { jsx as r, Fragment as n } from "react/jsx-runtime";
|
|
2
|
+
import { useState as s } from "react";
|
|
3
|
+
import { ImagePlaceholder as g } from "../ImagePlaceholder.js";
|
|
4
|
+
function u({
|
|
5
|
+
width: e = 20,
|
|
6
|
+
height: o = 20,
|
|
7
|
+
src: a,
|
|
8
|
+
alt: l
|
|
9
|
+
}) {
|
|
10
|
+
const [m, t] = s(!1);
|
|
11
|
+
return /* @__PURE__ */ r(n, { children: m || !a ? /* @__PURE__ */ r(g, { width: e, height: o }) : /* @__PURE__ */ r(
|
|
12
|
+
"img",
|
|
13
|
+
{
|
|
14
|
+
src: a,
|
|
15
|
+
alt: l,
|
|
16
|
+
width: e,
|
|
17
|
+
height: o,
|
|
18
|
+
draggable: !1,
|
|
19
|
+
loading: "lazy",
|
|
20
|
+
onError: () => t(!0)
|
|
21
|
+
}
|
|
22
|
+
) });
|
|
23
|
+
}
|
|
24
|
+
export {
|
|
25
|
+
u as SearchResultImage
|
|
26
|
+
};
|
|
@@ -0,0 +1,122 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsxs as L, Fragment as U, jsx as p } from "react/jsx-runtime";
|
|
3
|
+
import { useRef as f, useState as w, useId as _, useEffect as z, useCallback as G } from "react";
|
|
4
|
+
import { InputBase as H } from "./Input.js";
|
|
5
|
+
import { Icon as J } from "./Icon.js";
|
|
6
|
+
import { clsx as x } from "../node_modules/clsx/dist/clsx.js";
|
|
7
|
+
function b({
|
|
8
|
+
id: l,
|
|
9
|
+
testid: I,
|
|
10
|
+
label: Q,
|
|
11
|
+
error: T,
|
|
12
|
+
children: C,
|
|
13
|
+
readOnly: m,
|
|
14
|
+
renderMenu: k,
|
|
15
|
+
onClick: R,
|
|
16
|
+
className: F,
|
|
17
|
+
wrapperClassName: K,
|
|
18
|
+
removeRoundness: N,
|
|
19
|
+
displayValue: B,
|
|
20
|
+
value: O,
|
|
21
|
+
searchable: r,
|
|
22
|
+
onChange: A,
|
|
23
|
+
...a
|
|
24
|
+
}) {
|
|
25
|
+
const S = f(null), y = f(null), [t, $] = w(!1), [h, v] = w(""), g = `select-menu-${_()}`, u = f(""), c = f(null), [j, d] = w("");
|
|
26
|
+
z(() => {
|
|
27
|
+
r && t && S.current?.focus();
|
|
28
|
+
}, [r, t]);
|
|
29
|
+
const E = G(() => {
|
|
30
|
+
y.current?.querySelector("input")?.focus();
|
|
31
|
+
}, []);
|
|
32
|
+
function i(e) {
|
|
33
|
+
$(e), e || (v(""), d(""), u.current = "", c.current && clearTimeout(c.current), r && requestAnimationFrame(E));
|
|
34
|
+
}
|
|
35
|
+
const s = r && t;
|
|
36
|
+
return /* @__PURE__ */ L(U, { children: [
|
|
37
|
+
/* @__PURE__ */ p(
|
|
38
|
+
H,
|
|
39
|
+
{
|
|
40
|
+
id: l,
|
|
41
|
+
testid: I,
|
|
42
|
+
inputContainerRef: y,
|
|
43
|
+
ref: S,
|
|
44
|
+
label: Q,
|
|
45
|
+
after: !m && /* @__PURE__ */ p(
|
|
46
|
+
"span",
|
|
47
|
+
{
|
|
48
|
+
className: x(
|
|
49
|
+
a.disabled ? "text-icon-action-primary-disabled" : "text-icon-action-primary-normal",
|
|
50
|
+
"contents"
|
|
51
|
+
),
|
|
52
|
+
children: /* @__PURE__ */ p(J, { name: "keyboard_arrow_down" })
|
|
53
|
+
}
|
|
54
|
+
),
|
|
55
|
+
maxLength: s ? void 0 : 0,
|
|
56
|
+
className: x(!s && "!caret-transparent !cursor-default", F),
|
|
57
|
+
wrapperClassName: K,
|
|
58
|
+
onKeyDown: (e) => {
|
|
59
|
+
if (s && (e.key === "ArrowDown" || e.key === "ArrowUp")) {
|
|
60
|
+
e.preventDefault();
|
|
61
|
+
const n = document.querySelector(
|
|
62
|
+
`[data-menu="${g}"]`
|
|
63
|
+
), D = n?.querySelector("[data-selected]");
|
|
64
|
+
if (D) {
|
|
65
|
+
const o = Array.from(
|
|
66
|
+
n?.querySelectorAll('[role="menuitem"]') ?? []
|
|
67
|
+
), q = o.indexOf(D);
|
|
68
|
+
(e.key === "ArrowDown" ? o[q + 1] ?? o[0] : o[q - 1] ?? o[o.length - 1])?.focus();
|
|
69
|
+
} else
|
|
70
|
+
(e.key === "ArrowDown" ? n?.querySelector('[role="menuitem"]') : n?.querySelector('[role="menuitem"]:last-child'))?.focus();
|
|
71
|
+
return;
|
|
72
|
+
}
|
|
73
|
+
if (!t && (e.key === "ArrowDown" || e.key === "ArrowUp")) {
|
|
74
|
+
e.preventDefault(), i(!0);
|
|
75
|
+
return;
|
|
76
|
+
}
|
|
77
|
+
if (!t && (e.key === " " || e.key === "Enter")) {
|
|
78
|
+
e.preventDefault(), e.target.click();
|
|
79
|
+
return;
|
|
80
|
+
}
|
|
81
|
+
if (t && !r && e.key === " " && !u.current) {
|
|
82
|
+
e.preventDefault(), i(!1);
|
|
83
|
+
return;
|
|
84
|
+
}
|
|
85
|
+
if (!r && e.key.length === 1 && !e.ctrlKey && !e.metaKey && !e.altKey) {
|
|
86
|
+
e.preventDefault(), c.current && clearTimeout(c.current);
|
|
87
|
+
const n = u.current + e.key.toLowerCase();
|
|
88
|
+
u.current = n, c.current = setTimeout(() => {
|
|
89
|
+
u.current = "", d("");
|
|
90
|
+
}, 1e3), d(n), t || i(!0);
|
|
91
|
+
}
|
|
92
|
+
},
|
|
93
|
+
onClick: (e) => {
|
|
94
|
+
a.disabled || m || (i(!t), R?.(e));
|
|
95
|
+
},
|
|
96
|
+
error: T,
|
|
97
|
+
readOnly: m,
|
|
98
|
+
removeRoundness: N,
|
|
99
|
+
isFocused: t,
|
|
100
|
+
...a,
|
|
101
|
+
onChange: (e) => {
|
|
102
|
+
s && v(e.target.value), A?.(e);
|
|
103
|
+
},
|
|
104
|
+
value: s ? h : B ?? O ?? (A ? "" : void 0)
|
|
105
|
+
}
|
|
106
|
+
),
|
|
107
|
+
k ? k({
|
|
108
|
+
id: l ? `${l}-menu` : void 0,
|
|
109
|
+
positionTo: y,
|
|
110
|
+
show: t,
|
|
111
|
+
setShow: i,
|
|
112
|
+
topOffset: a.caption ? -16 : null,
|
|
113
|
+
searchQuery: r ? h : void 0,
|
|
114
|
+
autoFocusOff: r ? !0 : void 0,
|
|
115
|
+
menuName: g,
|
|
116
|
+
typeAheadQuery: r ? void 0 : j || void 0
|
|
117
|
+
}) : C
|
|
118
|
+
] });
|
|
119
|
+
}
|
|
120
|
+
export {
|
|
121
|
+
b as Select
|
|
122
|
+
};
|