@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,106 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsxs as h, jsx as n } from "react/jsx-runtime";
|
|
3
|
+
import { clsx as a } from "../node_modules/clsx/dist/clsx.js";
|
|
4
|
+
import { useState as p, useRef as y, useEffect as g } from "react";
|
|
5
|
+
import { componentPaddingMinusBorder as v, baseTransition as w, typography as f, componentGap as C } from "../classNames.js";
|
|
6
|
+
const B = a(
|
|
7
|
+
"w-full min-h-19",
|
|
8
|
+
"rounded-base border border-border-primary-normal bg-background-primary-normal caret-text-action-normal",
|
|
9
|
+
"outline-transparent outline-2 -outline-offset-2",
|
|
10
|
+
v,
|
|
11
|
+
w
|
|
12
|
+
), F = a(
|
|
13
|
+
"has-[[data-error]]:border-transparent has-[[data-error]]:not-focus-within:outline-border-primary-error has-[[data-error]]:not-focus-within:outline-1"
|
|
14
|
+
), k = a(
|
|
15
|
+
"has-[[data-focus]]:border-transparent has-[[data-focus]]:outline-border-primary-focus focus-within:border-transparent focus-within:outline-border-primary-focus"
|
|
16
|
+
), E = a(
|
|
17
|
+
"has-disabled:bg-background-action-secondary-disabled"
|
|
18
|
+
), N = a(
|
|
19
|
+
"has-[textarea:not(:disabled):read-only]:outline-none has-[textarea:not(:disabled):read-only]:bg-transparent has-[textarea:not(:disabled):read-only]:border-transparent has-[textarea:not(:disabled):read-only]:pl-0"
|
|
20
|
+
);
|
|
21
|
+
function T({
|
|
22
|
+
id: t,
|
|
23
|
+
testid: o,
|
|
24
|
+
label: s,
|
|
25
|
+
error: m,
|
|
26
|
+
caption: d,
|
|
27
|
+
selectOnFocus: l,
|
|
28
|
+
...e
|
|
29
|
+
}) {
|
|
30
|
+
const [i, c] = p(!1), u = y(null);
|
|
31
|
+
g(() => {
|
|
32
|
+
const r = u.current, b = () => {
|
|
33
|
+
r?.select();
|
|
34
|
+
};
|
|
35
|
+
if (l)
|
|
36
|
+
return r?.addEventListener("focus", b), () => {
|
|
37
|
+
r?.removeEventListener("focus", b);
|
|
38
|
+
};
|
|
39
|
+
}, [l]);
|
|
40
|
+
const x = {
|
|
41
|
+
"data-error": m && !i || null,
|
|
42
|
+
"data-focus": i || null
|
|
43
|
+
};
|
|
44
|
+
return /* @__PURE__ */ h(
|
|
45
|
+
"label",
|
|
46
|
+
{
|
|
47
|
+
htmlFor: t,
|
|
48
|
+
className: a(
|
|
49
|
+
"flex flex-col w-full",
|
|
50
|
+
"text-text-primary-normal has-disabled:text-text-primary-disabled",
|
|
51
|
+
!e.disabled && !e.readOnly && "has-[[data-error]]:text-text-primary-error",
|
|
52
|
+
C
|
|
53
|
+
),
|
|
54
|
+
children: [
|
|
55
|
+
s && /* @__PURE__ */ n(
|
|
56
|
+
"span",
|
|
57
|
+
{
|
|
58
|
+
className: a(
|
|
59
|
+
f.label,
|
|
60
|
+
"text-inherit",
|
|
61
|
+
e.disabled || e.readOnly ? "cursor-default" : "cursor-pointer",
|
|
62
|
+
"inline-block"
|
|
63
|
+
),
|
|
64
|
+
children: s
|
|
65
|
+
}
|
|
66
|
+
),
|
|
67
|
+
/* @__PURE__ */ n(
|
|
68
|
+
"textarea",
|
|
69
|
+
{
|
|
70
|
+
...e,
|
|
71
|
+
...x,
|
|
72
|
+
id: t,
|
|
73
|
+
"data-testid": o,
|
|
74
|
+
ref: u,
|
|
75
|
+
className: a(
|
|
76
|
+
"disabled:text-text-primary-disabled",
|
|
77
|
+
f.paragraph,
|
|
78
|
+
B,
|
|
79
|
+
F,
|
|
80
|
+
k,
|
|
81
|
+
E,
|
|
82
|
+
N
|
|
83
|
+
),
|
|
84
|
+
onFocus: (r) => {
|
|
85
|
+
e.onFocus?.(r), c(!0);
|
|
86
|
+
},
|
|
87
|
+
onBlur: (r) => {
|
|
88
|
+
e.onBlur?.(r), c(!1);
|
|
89
|
+
}
|
|
90
|
+
}
|
|
91
|
+
),
|
|
92
|
+
d && /* @__PURE__ */ n(
|
|
93
|
+
"div",
|
|
94
|
+
{
|
|
95
|
+
id: t ? `${t}-caption` : void 0,
|
|
96
|
+
"data-testid": o ? `${o}-caption` : void 0,
|
|
97
|
+
children: d
|
|
98
|
+
}
|
|
99
|
+
)
|
|
100
|
+
]
|
|
101
|
+
}
|
|
102
|
+
);
|
|
103
|
+
}
|
|
104
|
+
export {
|
|
105
|
+
T as Textarea
|
|
106
|
+
};
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
import { jsx as m } from "react/jsx-runtime";
|
|
2
|
+
function s({
|
|
3
|
+
theme: e,
|
|
4
|
+
children: r,
|
|
5
|
+
id: a,
|
|
6
|
+
testid: n,
|
|
7
|
+
ref: t
|
|
8
|
+
}) {
|
|
9
|
+
return /* @__PURE__ */ m(
|
|
10
|
+
"div",
|
|
11
|
+
{
|
|
12
|
+
id: a,
|
|
13
|
+
"data-testid": n,
|
|
14
|
+
className: "contents",
|
|
15
|
+
"data-theme": e,
|
|
16
|
+
ref: (i) => {
|
|
17
|
+
t && (t.current = i);
|
|
18
|
+
},
|
|
19
|
+
children: r
|
|
20
|
+
}
|
|
21
|
+
);
|
|
22
|
+
}
|
|
23
|
+
export {
|
|
24
|
+
s as Theme
|
|
25
|
+
};
|
|
@@ -0,0 +1,225 @@
|
|
|
1
|
+
import { jsxs as L, jsx as l } from "react/jsx-runtime";
|
|
2
|
+
import { useState as v, useRef as w, useEffect as A } from "react";
|
|
3
|
+
import { InputBase as Q } from "./Input.js";
|
|
4
|
+
import { createPortal as W } from "react-dom";
|
|
5
|
+
import { clsx as R } from "../node_modules/clsx/dist/clsx.js";
|
|
6
|
+
import { componentPadding as Z, typography as ee } from "../classNames.js";
|
|
7
|
+
import { Icon as te } from "./Icon.js";
|
|
8
|
+
import { findDocumentRoot as re } from "../utils.js";
|
|
9
|
+
import { Stack as ne } from "./Stack.js";
|
|
10
|
+
const U = "overflow-auto max-h-full py-4 no-scrollbar w-12 desktop:w-10";
|
|
11
|
+
function he({ onChange: P, format: V = "12h", id: a, testid: f, wrapperClassName: $, ...c }) {
|
|
12
|
+
const [i, h] = v(!1), [T, j] = v(!1), y = w(null), D = w(null), x = w(null), [N, H] = v({ top: 0, left: 0, width: 0 }), [s, k] = v(null), [p, I] = v(null), [d, S] = v(null), [X, O] = v(""), C = w(/* @__PURE__ */ new Set()), n = V === "12h", b = s && p ? n ? d ? `${s}:${p} ${d}` : `${s}:${p}` : `${s}:${p}` : "", Y = () => {
|
|
13
|
+
const r = y.current?.parentElement ?? D.current;
|
|
14
|
+
if (r) {
|
|
15
|
+
const e = r.getBoundingClientRect();
|
|
16
|
+
H({
|
|
17
|
+
top: e.bottom + window.scrollY + 4,
|
|
18
|
+
left: e.left + window.scrollX,
|
|
19
|
+
width: e.width
|
|
20
|
+
});
|
|
21
|
+
}
|
|
22
|
+
};
|
|
23
|
+
A(() => {
|
|
24
|
+
i && Y();
|
|
25
|
+
}, [i, n]), A(() => {
|
|
26
|
+
i && n && d === null && S("AM");
|
|
27
|
+
}, [i, n, d]), A(() => {
|
|
28
|
+
const r = (e) => {
|
|
29
|
+
y.current && x.current && !y.current.contains(e.target) && !x.current.contains(e.target) && h(!1);
|
|
30
|
+
};
|
|
31
|
+
return i && document.addEventListener("mousedown", r), () => {
|
|
32
|
+
document.removeEventListener("mousedown", r);
|
|
33
|
+
};
|
|
34
|
+
}, [i, n]), A(() => {
|
|
35
|
+
b && T && (O(b), P?.({
|
|
36
|
+
target: { value: b }
|
|
37
|
+
}));
|
|
38
|
+
}, [b, T, P]);
|
|
39
|
+
const _ = () => {
|
|
40
|
+
!c.disabled && !c.readOnly && (j(!0), h(!0), C.current = /* @__PURE__ */ new Set(), n && d === null && S("AM"));
|
|
41
|
+
}, z = (r, e) => {
|
|
42
|
+
r === "hour" && k(e), r === "minute" && I(e), r === "meridiem" && S(e), C.current.add(r), setTimeout(() => {
|
|
43
|
+
(n ? ["hour", "minute", "meridiem"] : ["hour", "minute"]).every((o) => C.current.has(o)) && h(!1);
|
|
44
|
+
}, 100);
|
|
45
|
+
};
|
|
46
|
+
A(() => {
|
|
47
|
+
!i && b && O(b);
|
|
48
|
+
}, [i, b]);
|
|
49
|
+
const G = (r) => {
|
|
50
|
+
const e = r.target.value.toUpperCase().replace(/[^0-9:APM ]/gi, "").trim();
|
|
51
|
+
O(e), e === "" && (k(null), I(null), S(null), h(!0), C.current = /* @__PURE__ */ new Set());
|
|
52
|
+
const t = e.match(
|
|
53
|
+
n ? /^(\d{1,2}):(\d{2})\s*(AM|PM)$/i : /^(\d{1,2}):(\d{2})$/
|
|
54
|
+
);
|
|
55
|
+
if (t) {
|
|
56
|
+
const [, o, u, M] = t, m = parseInt(o, 10), F = parseInt(u, 10);
|
|
57
|
+
if (m >= 0 && m <= 23 && F >= 0 && F <= 59) {
|
|
58
|
+
let E;
|
|
59
|
+
const K = F.toString().padStart(2, "0");
|
|
60
|
+
let B = M;
|
|
61
|
+
n ? (E = (m % 12 || 12).toString().padStart(2, "0"), m > 12 && (B = "PM"), k(E), I(K), B && S(B)) : (E = m.toString().padStart(2, "0"), k(E), I(K));
|
|
62
|
+
}
|
|
63
|
+
}
|
|
64
|
+
P?.(r);
|
|
65
|
+
}, g = {
|
|
66
|
+
hour: w(null),
|
|
67
|
+
minute: w(null),
|
|
68
|
+
meridiem: w(null)
|
|
69
|
+
}, J = (r) => {
|
|
70
|
+
if (r.key === "Enter") {
|
|
71
|
+
h(!1);
|
|
72
|
+
return;
|
|
73
|
+
}
|
|
74
|
+
if (r.key !== "ArrowUp" && r.key !== "ArrowDown") return;
|
|
75
|
+
r.preventDefault();
|
|
76
|
+
let e, t, o;
|
|
77
|
+
if (s === null || p === null || n && d === null) {
|
|
78
|
+
const m = /* @__PURE__ */ new Date();
|
|
79
|
+
e = m.getHours(), t = Math.round(m.getMinutes() / 5) * 5, t === 60 && (t = 0, e += 1), n ? (o = e >= 12 ? "PM" : "AM", e = e % 12 || 12) : o = "AM";
|
|
80
|
+
} else
|
|
81
|
+
e = parseInt(s, 10), t = parseInt(p, 10), o = d || "AM";
|
|
82
|
+
const u = 5, M = t % u;
|
|
83
|
+
t += r.key === "ArrowDown" ? M === 0 ? u : u - M : -(M === 0 ? u : M), t >= 60 ? (t -= 60, e += 1) : t < 0 && (t += 60, e -= 1), n ? e > 12 ? (e = 1, o = o === "AM" ? "PM" : "AM") : e <= 0 && (e = 12, o = o === "AM" ? "PM" : "AM") : e = (e + 24) % 24, k(e.toString().padStart(2, "0")), I(t.toString().padStart(2, "0")), n && S(o);
|
|
84
|
+
};
|
|
85
|
+
A(() => {
|
|
86
|
+
i && setTimeout(() => {
|
|
87
|
+
g.hour.current?.scrollIntoView({
|
|
88
|
+
block: "nearest",
|
|
89
|
+
behavior: "instant"
|
|
90
|
+
}), g.minute.current?.scrollIntoView({
|
|
91
|
+
block: "nearest",
|
|
92
|
+
behavior: "instant"
|
|
93
|
+
}), n && g.meridiem.current?.scrollIntoView({
|
|
94
|
+
block: "nearest",
|
|
95
|
+
behavior: "instant"
|
|
96
|
+
});
|
|
97
|
+
}, 0);
|
|
98
|
+
}, [
|
|
99
|
+
i,
|
|
100
|
+
n,
|
|
101
|
+
g.hour,
|
|
102
|
+
g.minute,
|
|
103
|
+
g.meridiem
|
|
104
|
+
]);
|
|
105
|
+
const q = (r, e) => r.map((t) => {
|
|
106
|
+
const o = e === "hour" && t === s || e === "minute" && t === p || e === "meridiem" && t === d;
|
|
107
|
+
return /* @__PURE__ */ l(
|
|
108
|
+
oe,
|
|
109
|
+
{
|
|
110
|
+
id: a ? `${a}-${e}-${t}` : void 0,
|
|
111
|
+
testid: f ? `${f}-${e}-${t}` : void 0,
|
|
112
|
+
selected: o,
|
|
113
|
+
ref: o ? (u) => {
|
|
114
|
+
g[e].current = u;
|
|
115
|
+
} : null,
|
|
116
|
+
onClick: () => z(e, t),
|
|
117
|
+
className: R(Z, "cursor-pointer", ee.caption),
|
|
118
|
+
children: t
|
|
119
|
+
},
|
|
120
|
+
t
|
|
121
|
+
);
|
|
122
|
+
});
|
|
123
|
+
return /* @__PURE__ */ L("div", { className: R("relative max-w-38", $), children: [
|
|
124
|
+
/* @__PURE__ */ l(
|
|
125
|
+
Q,
|
|
126
|
+
{
|
|
127
|
+
...c,
|
|
128
|
+
id: a,
|
|
129
|
+
testid: f,
|
|
130
|
+
ref: y,
|
|
131
|
+
inputContainerRef: D,
|
|
132
|
+
value: X,
|
|
133
|
+
placeholder: n ? "hh:mm am" : "hh:mm",
|
|
134
|
+
after: /* @__PURE__ */ l("span", { className: "text-icon-primary-normal contents", children: /* @__PURE__ */ l(te, { name: "schedule" }) }),
|
|
135
|
+
onFocus: _,
|
|
136
|
+
caption: c.caption,
|
|
137
|
+
onChange: G,
|
|
138
|
+
onKeyDown: J,
|
|
139
|
+
type: "text"
|
|
140
|
+
}
|
|
141
|
+
),
|
|
142
|
+
i && W(
|
|
143
|
+
/* @__PURE__ */ l(
|
|
144
|
+
ne,
|
|
145
|
+
{
|
|
146
|
+
id: a ? `${a}-timepicker` : void 0,
|
|
147
|
+
elevation: 4,
|
|
148
|
+
height: 240,
|
|
149
|
+
position: "absolute",
|
|
150
|
+
backgroundColor: "background-grouped-primary-normal",
|
|
151
|
+
overflowX: "hidden",
|
|
152
|
+
overflowY: "hidden",
|
|
153
|
+
zIndex: 50,
|
|
154
|
+
top: N.top,
|
|
155
|
+
left: N.left,
|
|
156
|
+
width: "fit",
|
|
157
|
+
rounded: !0,
|
|
158
|
+
children: /* @__PURE__ */ L("div", { ref: x, className: "px-4 flex justify-center h-60", children: [
|
|
159
|
+
/* @__PURE__ */ l("div", { className: R(U), children: q(
|
|
160
|
+
Array.from(
|
|
161
|
+
{ length: n ? 12 : 24 },
|
|
162
|
+
(r, e) => (e + (n ? 1 : 0)).toString().padStart(2, "0")
|
|
163
|
+
),
|
|
164
|
+
"hour"
|
|
165
|
+
) }),
|
|
166
|
+
/* @__PURE__ */ l("div", { className: R(U), children: q(
|
|
167
|
+
Array.from(
|
|
168
|
+
{ length: 12 },
|
|
169
|
+
(r, e) => (e * 5).toString().padStart(2, "0")
|
|
170
|
+
),
|
|
171
|
+
"minute"
|
|
172
|
+
) }),
|
|
173
|
+
n && /* @__PURE__ */ l("div", { className: "py-4 w-12 desktop:w-10", children: q(["AM", "PM"], "meridiem") })
|
|
174
|
+
] })
|
|
175
|
+
}
|
|
176
|
+
),
|
|
177
|
+
re(x.current)
|
|
178
|
+
)
|
|
179
|
+
] });
|
|
180
|
+
}
|
|
181
|
+
function oe({
|
|
182
|
+
id: P,
|
|
183
|
+
testid: V,
|
|
184
|
+
selected: a = !1,
|
|
185
|
+
start: f = !1,
|
|
186
|
+
intermediate: $ = !1,
|
|
187
|
+
end: c = !1,
|
|
188
|
+
today: i = !1,
|
|
189
|
+
disabled: h = !1,
|
|
190
|
+
onClick: T,
|
|
191
|
+
onHover: j,
|
|
192
|
+
onKeyDown: y,
|
|
193
|
+
children: D,
|
|
194
|
+
className: x,
|
|
195
|
+
ref: N,
|
|
196
|
+
...H
|
|
197
|
+
}) {
|
|
198
|
+
return /* @__PURE__ */ l(
|
|
199
|
+
"button",
|
|
200
|
+
{
|
|
201
|
+
id: P,
|
|
202
|
+
"data-testid": V,
|
|
203
|
+
onPointerOver: j,
|
|
204
|
+
onClick: T,
|
|
205
|
+
onKeyDown: y,
|
|
206
|
+
disabled: h,
|
|
207
|
+
ref: N,
|
|
208
|
+
className: R(
|
|
209
|
+
"w-full aspect-square flex items-center justify-center",
|
|
210
|
+
!a && !f && !$ && !c && !i && "text-text-primary-normal hover:bg-background-action-secondary-hover hover:text-text-action-primary-hover active:text-text-action-primary-active disabled:text-text-primary-disabled disabled:pointer-events-none rounded",
|
|
211
|
+
i && !a && !f && !$ && !c && "rounded-full border border-border-primary-normal hover:bg-background-action-secondary-hover hover:text-text-action-primary-hover active:text-text-action-primary-active disabled:text-text-primary-disabled",
|
|
212
|
+
a && "text-text-on-action-primary-normal bg-background-action-primary-normal hover:bg-background-action-primary-hover active:bg-background-action-primary-active disabled:text-text-primary-disabled disabled:bg-neutral-200 rounded",
|
|
213
|
+
f && "bg-background-action-primary-normal hover:bg-background-action-primary-hover active:bg-background-action-primary-active disabled:text-text-primary-disabled disabled:bg-neutral-200 rounded-l",
|
|
214
|
+
c && "bg-background-action-primary-normal hover:bg-background-action-primary-hover active:bg-background-action-primary-active disabled:text-text-primary-disabled disabled:bg-neutral-200 rounded-r",
|
|
215
|
+
$ && "bg-action-100 border-y border-action-400",
|
|
216
|
+
x
|
|
217
|
+
),
|
|
218
|
+
...H,
|
|
219
|
+
children: D
|
|
220
|
+
}
|
|
221
|
+
);
|
|
222
|
+
}
|
|
223
|
+
export {
|
|
224
|
+
he as Time
|
|
225
|
+
};
|
|
@@ -0,0 +1,170 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsxs as p, jsx as o } from "react/jsx-runtime";
|
|
3
|
+
import { clsx as h } from "../node_modules/clsx/dist/clsx.js";
|
|
4
|
+
import { useRef as m, useEffect as b } from "react";
|
|
5
|
+
import { useMatchesMobile as E } from "../hooks/useMatchesMedia.js";
|
|
6
|
+
import { Heading3 as B } from "./Heading.js";
|
|
7
|
+
import { Paragraph as O } from "./Paragraph.js";
|
|
8
|
+
import { Icon as d } from "./Icon.js";
|
|
9
|
+
import { Button as z } from "./Button.js";
|
|
10
|
+
import { createRoot as L } from "react-dom/client";
|
|
11
|
+
import { componentGap as Y, layoutGroupGap as M, componentPadding as D } from "../classNames.js";
|
|
12
|
+
const R = {
|
|
13
|
+
success: {
|
|
14
|
+
className: "border-background-success-normal",
|
|
15
|
+
icon: /* @__PURE__ */ o("span", { className: "text-icon-success-normal contents", children: /* @__PURE__ */ o(d, { name: "check_circle", size: 24 }) })
|
|
16
|
+
},
|
|
17
|
+
warning: {
|
|
18
|
+
className: "border-background-warning-normal",
|
|
19
|
+
icon: /* @__PURE__ */ o("span", { className: "text-icon-warning-normal contents", children: /* @__PURE__ */ o(d, { name: "warning", size: 24 }) })
|
|
20
|
+
},
|
|
21
|
+
error: {
|
|
22
|
+
className: "border-border-action-critical-normal",
|
|
23
|
+
icon: /* @__PURE__ */ o("span", { className: "text-icon-critical-normal contents", children: /* @__PURE__ */ o(d, { name: "error", size: 24 }) })
|
|
24
|
+
},
|
|
25
|
+
info: {
|
|
26
|
+
className: "border-border-action-normal",
|
|
27
|
+
icon: /* @__PURE__ */ o("span", { className: "text-icon-on-action-secondary-normal contents", children: /* @__PURE__ */ o(d, { name: "info", size: 24 }) })
|
|
28
|
+
}
|
|
29
|
+
}, U = 8e3, G = 50, H = 50, P = (e, n = !1, r = U, t = G, a = H) => {
|
|
30
|
+
const s = t + r + a, c = e.getBoundingClientRect(), i = n ? -(c.top + 16) : window.innerHeight - c.bottom + 16;
|
|
31
|
+
return e.animate(
|
|
32
|
+
[
|
|
33
|
+
{ opacity: 0, transform: `translateY(${i}px)`, offset: 0 },
|
|
34
|
+
{ opacity: 1, transform: "translateY(0)", offset: t / s },
|
|
35
|
+
{ opacity: 1, transform: "translateY(0)", offset: (t + r) / s },
|
|
36
|
+
{ opacity: 0, transform: `translateY(${i}px)`, offset: 1 }
|
|
37
|
+
],
|
|
38
|
+
{
|
|
39
|
+
duration: s,
|
|
40
|
+
easing: "cubic-bezier(0.4, 0, 0.2, 1)",
|
|
41
|
+
fill: "both"
|
|
42
|
+
}
|
|
43
|
+
);
|
|
44
|
+
}, y = "toast-root";
|
|
45
|
+
function S() {
|
|
46
|
+
const r = `${window.matchMedia("(width < 48rem)").matches ? "fixed top-mobile-container-padding left-1/2 -translate-x-1/2 items-center" : "fixed bottom-desktop-container-padding right-desktop-container-padding items-end"} z-50 flex flex-col gap-4 pointer-events-none`;
|
|
47
|
+
let t = document.getElementById(y);
|
|
48
|
+
return t || (t = document.createElement("div"), t.id = y, document.body.appendChild(t)), t.className = r, t;
|
|
49
|
+
}
|
|
50
|
+
function V({
|
|
51
|
+
id: e,
|
|
52
|
+
testid: n,
|
|
53
|
+
variant: r = "success",
|
|
54
|
+
title: t,
|
|
55
|
+
message: a,
|
|
56
|
+
show: s = !1,
|
|
57
|
+
showToast: c = !1,
|
|
58
|
+
// deprecated
|
|
59
|
+
onClose: i,
|
|
60
|
+
viewButtonLink: I,
|
|
61
|
+
viewButtonLabel: A = "View",
|
|
62
|
+
showViewButton: T = !1,
|
|
63
|
+
...v
|
|
64
|
+
}) {
|
|
65
|
+
const u = m(null), l = m(null), f = E(), g = m(i);
|
|
66
|
+
b(() => {
|
|
67
|
+
g.current = i;
|
|
68
|
+
}, [i]);
|
|
69
|
+
const N = m(f);
|
|
70
|
+
b(() => {
|
|
71
|
+
N.current = f;
|
|
72
|
+
}, [f]);
|
|
73
|
+
const w = m(!1);
|
|
74
|
+
b(() => {
|
|
75
|
+
if (s && !c) {
|
|
76
|
+
if (u.current) {
|
|
77
|
+
const x = P(u.current, N.current === !0);
|
|
78
|
+
l.current = x, x.onfinish = () => {
|
|
79
|
+
g.current?.();
|
|
80
|
+
};
|
|
81
|
+
}
|
|
82
|
+
return () => {
|
|
83
|
+
l.current?.cancel();
|
|
84
|
+
};
|
|
85
|
+
}
|
|
86
|
+
}, [s, c]);
|
|
87
|
+
const _ = () => {
|
|
88
|
+
w.current = !0, l.current?.pause();
|
|
89
|
+
}, $ = () => {
|
|
90
|
+
w.current = !1, l.current?.playState === "paused" && l.current.play();
|
|
91
|
+
}, { className: k, icon: C } = R[r] ?? R.success;
|
|
92
|
+
return s ? /* @__PURE__ */ p(
|
|
93
|
+
"div",
|
|
94
|
+
{
|
|
95
|
+
id: e,
|
|
96
|
+
"data-testid": n,
|
|
97
|
+
ref: u,
|
|
98
|
+
onMouseEnter: _,
|
|
99
|
+
onMouseLeave: $,
|
|
100
|
+
className: h(
|
|
101
|
+
"flex items-start border-2 rounded-sm bg-background-grouped-primary-normal shadow-16 cursor-pointer pointer-events-auto transition-colors w-fit",
|
|
102
|
+
D,
|
|
103
|
+
M,
|
|
104
|
+
k
|
|
105
|
+
),
|
|
106
|
+
...v,
|
|
107
|
+
style: v.style,
|
|
108
|
+
children: [
|
|
109
|
+
C,
|
|
110
|
+
/* @__PURE__ */ p("div", { className: h("flex items-center", M), children: [
|
|
111
|
+
/* @__PURE__ */ p("div", { className: h("flex flex-col w-68", Y), children: [
|
|
112
|
+
t && /* @__PURE__ */ o(
|
|
113
|
+
B,
|
|
114
|
+
{
|
|
115
|
+
testid: n ? `${n}-title` : void 0,
|
|
116
|
+
id: e ? `${e}-title` : void 0,
|
|
117
|
+
children: t
|
|
118
|
+
}
|
|
119
|
+
),
|
|
120
|
+
a && /* @__PURE__ */ o(
|
|
121
|
+
O,
|
|
122
|
+
{
|
|
123
|
+
testid: n ? `${n}-message` : void 0,
|
|
124
|
+
id: e ? `${e}-message` : void 0,
|
|
125
|
+
children: a
|
|
126
|
+
}
|
|
127
|
+
)
|
|
128
|
+
] }),
|
|
129
|
+
T && /* @__PURE__ */ o(
|
|
130
|
+
z,
|
|
131
|
+
{
|
|
132
|
+
id: e ? `${e}-view-button` : void 0,
|
|
133
|
+
testid: n ? `${n}-view-button` : void 0,
|
|
134
|
+
variant: "tertiary",
|
|
135
|
+
href: I,
|
|
136
|
+
children: A
|
|
137
|
+
}
|
|
138
|
+
)
|
|
139
|
+
] })
|
|
140
|
+
]
|
|
141
|
+
}
|
|
142
|
+
) : null;
|
|
143
|
+
}
|
|
144
|
+
function te(e) {
|
|
145
|
+
const n = S(), r = document.createElement("div");
|
|
146
|
+
n.appendChild(r);
|
|
147
|
+
const t = L(r), a = () => {
|
|
148
|
+
t.unmount(), r.remove();
|
|
149
|
+
};
|
|
150
|
+
t.render(
|
|
151
|
+
/* @__PURE__ */ o(
|
|
152
|
+
V,
|
|
153
|
+
{
|
|
154
|
+
id: e.id,
|
|
155
|
+
testid: e.testid,
|
|
156
|
+
show: !0,
|
|
157
|
+
onClose: a,
|
|
158
|
+
variant: e.variant,
|
|
159
|
+
title: e.title,
|
|
160
|
+
message: e.message,
|
|
161
|
+
showViewButton: e.showViewButton,
|
|
162
|
+
viewButtonLink: e.viewButtonLink
|
|
163
|
+
}
|
|
164
|
+
)
|
|
165
|
+
);
|
|
166
|
+
}
|
|
167
|
+
export {
|
|
168
|
+
V as Toast,
|
|
169
|
+
te as createToast
|
|
170
|
+
};
|
|
@@ -0,0 +1,102 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { jsxs as L, jsx as $ } from "react/jsx-runtime";
|
|
3
|
+
import { clsx as q } from "../node_modules/clsx/dist/clsx.js";
|
|
4
|
+
import { useRef as g, useState as d, useEffect as v } from "react";
|
|
5
|
+
import { createPortal as z } from "react-dom";
|
|
6
|
+
import { typography as F, componentPadding as j } from "../classNames.js";
|
|
7
|
+
import { useMatchesMobile as A } from "../hooks/useMatchesMedia.js";
|
|
8
|
+
function W({
|
|
9
|
+
id: c,
|
|
10
|
+
testid: l,
|
|
11
|
+
message: b,
|
|
12
|
+
position: w = "top",
|
|
13
|
+
children: x,
|
|
14
|
+
showOnTruncation: p = !1,
|
|
15
|
+
offset: s = 8,
|
|
16
|
+
keepHidden: y = !1
|
|
17
|
+
}) {
|
|
18
|
+
const o = g(null), a = g(null), [f, M] = d({ top: 0, left: 0 }), [i, m] = d(!1), [R, h] = d(!1), u = () => {
|
|
19
|
+
if (!o.current || !a.current) return;
|
|
20
|
+
const e = o.current.getBoundingClientRect(), t = a.current.getBoundingClientRect();
|
|
21
|
+
let n = 0, r = 0;
|
|
22
|
+
switch (w) {
|
|
23
|
+
case "top":
|
|
24
|
+
n = e.top - t.height - s, r = e.left + e.width / 2 - t.width / 2;
|
|
25
|
+
break;
|
|
26
|
+
case "bottom":
|
|
27
|
+
n = e.bottom + s, r = e.left + e.width / 2 - t.width / 2;
|
|
28
|
+
break;
|
|
29
|
+
case "left":
|
|
30
|
+
n = e.top + e.height / 2 - t.height / 2, r = e.left - t.width - s;
|
|
31
|
+
break;
|
|
32
|
+
case "right":
|
|
33
|
+
n = e.top + e.height / 2 - t.height / 2, r = e.right + s;
|
|
34
|
+
break;
|
|
35
|
+
}
|
|
36
|
+
M({ top: n, left: r }), requestAnimationFrame(() => {
|
|
37
|
+
h(!0);
|
|
38
|
+
});
|
|
39
|
+
}, k = () => {
|
|
40
|
+
(!p || T()) && m(!0);
|
|
41
|
+
}, E = () => {
|
|
42
|
+
m(!1), h(!1);
|
|
43
|
+
};
|
|
44
|
+
v(() => {
|
|
45
|
+
i && a.current && requestAnimationFrame(() => {
|
|
46
|
+
u();
|
|
47
|
+
});
|
|
48
|
+
}, [i]), v(() => {
|
|
49
|
+
if (i)
|
|
50
|
+
return window.addEventListener("resize", u), () => window.removeEventListener("resize", u);
|
|
51
|
+
}, [i]);
|
|
52
|
+
const P = A();
|
|
53
|
+
return /* @__PURE__ */ L(
|
|
54
|
+
"div",
|
|
55
|
+
{
|
|
56
|
+
id: c,
|
|
57
|
+
"data-testid": l,
|
|
58
|
+
ref: o,
|
|
59
|
+
className: "relative inline-grid grid-cols-[auto_1fr] items-center cursor-pointer",
|
|
60
|
+
onMouseEnter: k,
|
|
61
|
+
onMouseLeave: E,
|
|
62
|
+
children: [
|
|
63
|
+
x,
|
|
64
|
+
!y && i && !P && typeof document < "u" && z(
|
|
65
|
+
/* @__PURE__ */ $(
|
|
66
|
+
"div",
|
|
67
|
+
{
|
|
68
|
+
id: c ? `${c}-message` : void 0,
|
|
69
|
+
"data-testid": l ? `${l}-message` : void 0,
|
|
70
|
+
ref: a,
|
|
71
|
+
style: {
|
|
72
|
+
position: "fixed",
|
|
73
|
+
top: `${f.top}px`,
|
|
74
|
+
left: `${f.left}px`,
|
|
75
|
+
zIndex: 9999
|
|
76
|
+
},
|
|
77
|
+
className: q(
|
|
78
|
+
F.caption,
|
|
79
|
+
"bg-neutral-500 text-neutral-100 rounded whitespace-nowrap shadow-2 pointer-events-none transition-opacity duration-100 ease-in-out",
|
|
80
|
+
j,
|
|
81
|
+
!R && "opacity-0"
|
|
82
|
+
),
|
|
83
|
+
children: b
|
|
84
|
+
}
|
|
85
|
+
),
|
|
86
|
+
document.body
|
|
87
|
+
)
|
|
88
|
+
]
|
|
89
|
+
}
|
|
90
|
+
);
|
|
91
|
+
function T() {
|
|
92
|
+
if (p && o.current) {
|
|
93
|
+
const e = o.current.querySelector("p, a");
|
|
94
|
+
if (e)
|
|
95
|
+
return e.scrollWidth > e.clientWidth;
|
|
96
|
+
}
|
|
97
|
+
return !1;
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
export {
|
|
101
|
+
W as Tooltip
|
|
102
|
+
};
|