@preply/ds-web-lib 10.0.0 → 11.1.0
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/Accordion-B0hR-tcI.js +96 -0
- package/dist/AlertBannerProvider-Cf7w9AOq.js +76 -0
- package/dist/AlertDialog-BG-diKBi.js +475 -0
- package/dist/Avatar-B-JdqVyg.js +66 -0
- package/dist/AvatarWithStatus-CD9jEqEB.js +36 -0
- package/dist/Badge-Dd-CLBoW.js +50 -0
- package/dist/Box-BJBE9KNm.js +91 -0
- package/dist/BubbleCounter.module-BU2S0euA.js +16 -0
- package/dist/Button-C35BZJZT.js +91 -0
- package/dist/ButtonBase-8eUyTWxX.js +215 -0
- package/dist/Checkbox-CtolNbxI.js +108 -0
- package/dist/Chips-BRGw7Uup.js +99 -0
- package/dist/ChipsPrimitive-Bezq7ptE.js +1179 -0
- package/dist/CountryFlag-DVDKHmQH.js +43 -0
- package/dist/Dialog.module-Db2BJAn4.js +21 -0
- package/dist/DialogCloseButton-DjDd9Mid.js +98 -0
- package/dist/DialogDescription-8zw9t6pm.js +44 -0
- package/dist/DialogRoot-B67oJduC.js +335 -0
- package/dist/DialogRootContext-Bz8RW-Mq.js +12 -0
- package/dist/DialogTitle-C2Nn2ys-.js +43 -0
- package/dist/Divider-DvwDWB9_.js +17 -0
- package/dist/DropdownMenu.primitives-BrsTBvMk.js +4007 -0
- package/dist/FieldButton-B2slox8P.js +32 -0
- package/dist/FormControl-qnbQL1iF.js +128 -0
- package/dist/Heading-DA9gHfsx.js +71 -0
- package/dist/Icon-CixAeOSd.js +48 -0
- package/dist/IconButton-BPKpgfep.js +31 -0
- package/dist/InputContainer-CzzuOe_p.js +38 -0
- package/dist/LayoutFlex-e9auDvWD.js +86 -0
- package/dist/LayoutFlexItem-D9ziMmHe.js +48 -0
- package/dist/LayoutGridItem-Q8Lnvrri.js +34 -0
- package/dist/Link-CdoJVeER.js +66 -0
- package/dist/Loader-BMOxdJce.js +26 -0
- package/dist/OnboardingTooltip-B47_Yrsj.js +165 -0
- package/dist/OnboardingTour-DUUoI5WE.js +131 -0
- package/dist/PasswordField-Bx5YG62t.js +93 -0
- package/dist/PreplyLogo-abgOre30.js +112 -0
- package/dist/ProgressBar-CEU4GyHn.js +31 -0
- package/dist/ProgressSteps-BSqopxqv.js +45 -0
- package/dist/Select-Bo7PX_8V.js +124 -0
- package/dist/Slider-Crg4DEn_.js +64 -0
- package/dist/Spinner-Ck8KQA22.js +86 -0
- package/dist/Stars-D5QspUBE.js +72 -0
- package/dist/Steps-DbN5vFrP.js +173 -0
- package/dist/Switch-Ck_xB0ID.js +49 -0
- package/dist/Text-CaOF75Z-.js +121 -0
- package/dist/TextHighlighted-Dwq9Clgn.js +34 -0
- package/dist/TextInline-BcA4H2Tk.js +34 -0
- package/dist/Toast-wJAjSLfo.js +1019 -0
- package/dist/TokyoUIChevronDown-DGcVqR1z.js +14 -0
- package/dist/Tooltip-grvKQxTN.js +84 -0
- package/dist/VisuallyHidden-CtcHcZCK.js +29 -0
- package/dist/align-self-VrZUceie.js +42 -0
- package/dist/assets/Accordion.css +2 -2
- package/dist/assets/AlertBannerProvider.css +2 -2
- package/dist/assets/AlertDialog.css +2 -2
- package/dist/assets/Avatar.css +3 -3
- package/dist/assets/AvatarWithStatus.css +2 -2
- package/dist/assets/Badge.css +1 -1
- package/dist/assets/Box.css +3 -3
- package/dist/assets/BubbleCounter.css +1 -1
- package/dist/assets/Button.css +4 -4
- package/dist/assets/ButtonBase.css +40 -46
- package/dist/assets/Checkbox.css +1 -1
- package/dist/assets/Chips.css +2 -2
- package/dist/assets/ChipsPrimitive.css +2 -2
- package/dist/assets/CountryFlag.css +1 -1
- package/dist/assets/Dialog.css +13 -4
- package/dist/assets/Divider.css +1 -1
- package/dist/assets/DropdownMenu.css +2 -2
- package/dist/assets/FieldButton.css +3 -3
- package/dist/assets/FormControl.css +1 -1
- package/dist/assets/Heading.css +3 -3
- package/dist/assets/Icon.css +3 -3
- package/dist/assets/InputContainer.css +2 -2
- package/dist/assets/LayoutFlex.css +1 -1
- package/dist/assets/LayoutFlexItem.css +1 -1
- package/dist/assets/Link.css +3 -3
- package/dist/assets/Loader.css +1 -1
- package/dist/assets/OnboardingTooltip.css +6 -4
- package/dist/assets/OnboardingTour.css +3 -2
- package/dist/assets/PreplyLogo.css +1 -1
- package/dist/assets/ProgressBar.css +1 -1
- package/dist/assets/ProgressSteps.css +1 -1
- package/dist/assets/Select.css +2 -2
- package/dist/assets/Slider.css +1 -1
- package/dist/assets/Spinner.css +3 -3
- package/dist/assets/Stars.css +3 -3
- package/dist/assets/Steps.css +2 -2
- package/dist/assets/Switch.css +1 -1
- package/dist/assets/Text.css +3 -3
- package/dist/assets/TextHighlighted.css +3 -3
- package/dist/assets/TextInline.css +3 -3
- package/dist/assets/Toast.css +2 -2
- package/dist/assets/Tooltip.css +1 -1
- package/dist/assets/align-self.css +1 -1
- package/dist/assets/{IconTile.css → components.css} +9 -1
- package/dist/assets/exp-color.css +2 -2
- package/dist/assets/index.css +1 -1
- package/dist/assets/layout-gap.css +3 -3
- package/dist/assets/layout-grid.css +3 -3
- package/dist/assets/layout-hide.css +1 -1
- package/dist/assets/layout-padding.css +3 -3
- package/dist/assets/layout-relative.css +1 -1
- package/dist/assets/text-accent.css +2 -2
- package/dist/assets/text-centered.css +1 -1
- package/dist/assets/text-weight.css +2 -2
- package/dist/chunk-BVTlhY3a.js +24 -0
- package/dist/components/Accordion/Accordion.js +4 -60
- package/dist/components/Accordion/hooks/useOnOpenChange.js +19 -28
- package/dist/components/AlertBanner/AlertBanner.js +11 -26
- package/dist/components/AlertBanner/AlertBannerProvider.js +3 -8
- package/dist/components/AlertBanner/primitives/AlertBannerAction.js +11 -69
- package/dist/components/AlertBanner/primitives/AlertBannerIcon.js +77 -39
- package/dist/components/AlertBanner/primitives/AlertBannerRoot.js +26 -22
- package/dist/components/AlertBanner/primitives/AlertBannerText.js +11 -70
- package/dist/components/AlertDialog/AlertDialog.d.ts +3 -3
- package/dist/components/AlertDialog/AlertDialog.d.ts.map +1 -1
- package/dist/components/AlertDialog/AlertDialog.js +5 -94
- package/dist/components/Avatar/Avatar.js +3 -71
- package/dist/components/AvatarWithStatus/AvatarWithStatus.js +3 -43
- package/dist/components/Badge/Badge.js +4 -62
- package/dist/components/Box/Box.js +3 -95
- package/dist/components/BubbleCounter/BubbleCounter.js +23 -28
- package/dist/components/Button/Button.js +4 -80
- package/dist/components/CalloutBanner/CalloutBanner.js +61 -12
- package/dist/components/CalloutBanner/primitives/CalloutBannerDismissButton.js +50 -22
- package/dist/components/CalloutBanner/primitives/CalloutBannerIcon.js +86 -45
- package/dist/components/CalloutBanner/primitives/CalloutBannerRoot.js +50 -24
- package/dist/components/CalloutBanner/primitives/CalloutBannerText.js +41 -11
- package/dist/components/Checkbox/Checkbox.js +4 -78
- package/dist/components/Checkbox/hooks/useIndeterminate.js +24 -30
- package/dist/components/Chips/Chips.types.js +0 -1
- package/dist/components/Chips/DismissibleChips.js +117 -86
- package/dist/components/Chips/MultiSelectChips.js +98 -64
- package/dist/components/Chips/SingleSelectChips.js +94 -57
- package/dist/components/Chips/private/ChipsPrimitive.js +4 -17
- package/dist/components/CountryFlag/CountryFlag.js +3 -44
- package/dist/components/Dialog/Dialog.js +56 -31
- package/dist/components/Dialog/DialogSteps.js +40 -29
- package/dist/components/Dialog/primitives/DialogActions.js +26 -19
- package/dist/components/Dialog/primitives/DialogButtonStack.d.ts.map +1 -1
- package/dist/components/Dialog/primitives/DialogButtonStack.js +22 -15
- package/dist/components/Dialog/primitives/DialogCloseButton.d.ts +1 -1
- package/dist/components/Dialog/primitives/DialogCloseButton.d.ts.map +1 -1
- package/dist/components/Dialog/primitives/DialogCloseButton.js +4 -93
- package/dist/components/Dialog/primitives/DialogDescription.js +3 -43
- package/dist/components/Dialog/primitives/DialogFooter.js +37 -34
- package/dist/components/Dialog/primitives/DialogRoot.js +4 -1459
- package/dist/components/Dialog/primitives/DialogTitle.js +3 -42
- package/dist/components/Divider/Divider.js +3 -14
- package/dist/components/DropdownMenu/DropdownMenu.js +253 -188
- package/dist/components/DropdownMenu/primitives/DropdownMenu.primitives.js +5 -34
- package/dist/components/DropdownMenu/primitives/DropdownMenuSelectItem.primitives.js +121 -71
- package/dist/components/FieldButton/FieldButton.js +3 -37
- package/dist/components/FormControl/FormControl.js +3 -105
- package/dist/components/Heading/Heading.js +3 -78
- package/dist/components/Icon/Icon.js +4 -49
- package/dist/components/IconButton/IconButton.d.ts +5 -1
- package/dist/components/IconButton/IconButton.d.ts.map +1 -1
- package/dist/components/IconButton/IconButton.js +4 -28
- package/dist/components/IconTile/IconTile.js +11 -69
- package/dist/components/IntlFormatted/IntlFormattedAggregatedDateTime.js +16 -32
- package/dist/components/IntlFormatted/IntlFormattedCurrency.js +20 -42
- package/dist/components/IntlFormatted/IntlFormattedDate.js +73 -195
- package/dist/components/IntlFormatted/IntlFormattedTime.js +14 -24
- package/dist/components/IntlFormatted/Wrapper.js +14 -8
- package/dist/components/LayoutFlex/LayoutFlex.js +3 -100
- package/dist/components/LayoutFlex/style/getStyleAttrs.js +71 -143
- package/dist/components/LayoutFlex/tests/AlignItems.js +67 -97
- package/dist/components/LayoutFlex/tests/ColumnReverse.js +63 -100
- package/dist/components/LayoutFlex/tests/DataOverride.js +1498 -1093
- package/dist/components/LayoutFlex/tests/Default.js +19 -20
- package/dist/components/LayoutFlex/tests/Direction.js +65 -88
- package/dist/components/LayoutFlex/tests/Gap.js +115 -197
- package/dist/components/LayoutFlex/tests/HideInline.js +95 -136
- package/dist/components/LayoutFlex/tests/JustifyContent.js +75 -108
- package/dist/components/LayoutFlex/tests/Nowrap.js +35 -42
- package/dist/components/LayoutFlex/tests/Padding.js +207 -263
- package/dist/components/LayoutFlex/tests/Relative.js +49 -64
- package/dist/components/LayoutFlexItem/LayoutFlexItem.js +3 -54
- package/dist/components/LayoutGrid/LayoutGrid.js +26 -34
- package/dist/components/LayoutGridItem/LayoutGridItem.js +3 -41
- package/dist/components/Link/Link.js +3 -72
- package/dist/components/Loader/Loader.js +3 -32
- package/dist/components/NumberField/NumberField.js +33 -35
- package/dist/components/ObserveIntersection/ObserveIntersection.js +41 -42
- package/dist/components/OnboardingTooltip/OnboardingTooltip.js +4 -115
- package/dist/components/OnboardingTour/OnboardingTour.js +4 -114
- package/dist/components/PasswordField/PasswordField.js +3 -78
- package/dist/components/PreplyLogo/PreplyLogo.js +3 -81
- package/dist/components/ProgressBar/ProgressBar.js +3 -27
- package/dist/components/ProgressSteps/ProgressSteps.js +3 -48
- package/dist/components/Rating/Rating.js +29 -20
- package/dist/components/Rating/RatingInput.js +57 -59
- package/dist/components/Rating/Stars.js +4 -8
- package/dist/components/Rating/hooks/useHasError.js +11 -15
- package/dist/components/Rating/hooks/useHoverPercentage.js +37 -45
- package/dist/components/Rating/hooks/useInputState.js +18 -24
- package/dist/components/Rating/hooks/useLocalizations.js +12 -24
- package/dist/components/Rating/utils/roundToHalfDecimal.js +4 -4
- package/dist/components/SelectField/Select.js +5 -112
- package/dist/components/SelectField/SelectField.js +29 -24
- package/dist/components/SelectField/hooks/useBreakpointMatch.js +18 -19
- package/dist/components/ShowOnIntersection/ShowOnIntersection.js +32 -21
- package/dist/components/Slider/RangeSlider.js +62 -52
- package/dist/components/Slider/Slider.js +3 -10
- package/dist/components/Steps/Steps.js +4 -210
- package/dist/components/Switch/Switch.js +3 -51
- package/dist/components/Text/Text.js +3 -128
- package/dist/components/TextField/TextField.js +27 -29
- package/dist/components/TextHighlighted/TextHighlighted.js +3 -41
- package/dist/components/TextInline/TextInline.js +3 -40
- package/dist/components/TextareaField/TextareaField.js +26 -28
- package/dist/components/Toast/Toast.js +4 -1168
- package/dist/components/Tooltip/Tooltip.js +3 -66
- package/dist/components/deprecated/Chips/Chips.js +4 -76
- package/dist/components/deprecated/NativeSelectField/NativeSelect.js +40 -32
- package/dist/components/deprecated/NativeSelectField/NativeSelectField.js +34 -33
- package/dist/components/deprecated/index.js +5 -6
- package/dist/components/index.js +50 -150
- package/dist/components/private/ButtonBase/ButtonBase.d.ts +7 -11
- package/dist/components/private/ButtonBase/ButtonBase.d.ts.map +1 -1
- package/dist/components/private/ButtonBase/ButtonBase.js +3 -247
- package/dist/components/private/Input/Input.js +27 -19
- package/dist/components/private/Input/InputContainer.js +3 -5
- package/dist/components/private/Input/Textarea.js +24 -20
- package/dist/components/private/Input/index.js +2 -4
- package/dist/components/private/Spinner/Spinner.js +3 -52
- package/dist/components/private/VisuallyHidden/VisuallyHidden.js +3 -15
- package/dist/components-BIYP8wHJ.js +200 -0
- package/dist/exp-color-C5mKAN91.js +74 -0
- package/dist/floating-ui.utils.dom-CoeTbDZx.js +215 -0
- package/dist/index.js +50 -150
- package/dist/index.module-1c7ENvxc.js +7 -0
- package/dist/jsx-runtime-i4KUlhDu.js +743 -0
- package/dist/layout-gap.module-DLD8bcR4.js +95 -0
- package/dist/layout-grid.module-CZfhrKrB.js +101 -0
- package/dist/layout-hide.module-B1P0N4i3.js +53 -0
- package/dist/layout-padding-ugY-yd2q.js +389 -0
- package/dist/layout-relative.module-B5xrFD9j.js +6 -0
- package/dist/render-icon-Ch3b2dE0.js +290 -0
- package/dist/shared-styles/align-self/align-self.js +2 -36
- package/dist/shared-styles/exp-color/exp-color.js +2 -68
- package/dist/shared-styles/layout-gap/layout-gap.js +13 -7
- package/dist/shared-styles/layout-grid/layout-grid.js +28 -28
- package/dist/shared-styles/layout-grid-responsive-columns/layout-grid-responsive-columns.js +29 -43
- package/dist/shared-styles/layout-hide/layout-hide.js +8 -8
- package/dist/shared-styles/layout-padding/layout-padding.js +2 -5
- package/dist/shared-styles/layout-relative/layout-relative.js +14 -8
- package/dist/shared-styles/text-accent/text-accent.js +2 -25
- package/dist/shared-styles/text-centered/text-centered.js +2 -24
- package/dist/shared-styles/text-weight/text-weight.js +2 -15
- package/dist/store-sN_eYeZT.js +1064 -0
- package/dist/storybook-utils/consts.js +6 -8
- package/dist/storybook-utils/index.js +1 -5
- package/dist/text-accent-CfUFx-1K.js +30 -0
- package/dist/text-centered-Dwp2_-Yp.js +30 -0
- package/dist/text-weight-CwoqmM4o.js +21 -0
- package/dist/useBaseUiId-CWAD_PSs.js +13 -0
- package/dist/useBreakpointMatch-D9a3CTNK.js +338 -0
- package/dist/useButton-DHTh3Hm7.js +148 -0
- package/dist/useDialogClose-BzFIyWco.js +22 -0
- package/dist/useId-CJsH-2wV.js +34 -0
- package/dist/useOpenInteractionType-D8vA_ZKI.js +4104 -0
- package/dist/useRenderElement-ZBds6eRN.js +341 -0
- package/dist/utils/Orientation/OrientationProvider.js +54 -23
- package/dist/utils/Orientation/index.js +2 -4
- package/dist/utils/RovingTabIndex/RovingTabIndexProvider.js +70 -44
- package/dist/utils/RovingTabIndex/index.js +2 -4
- package/dist/utils/createRequiredContext.js +23 -13
- package/dist/utils/filterAttributesPassedByRadixUIAtRuntime.js +28 -25
- package/dist/utils/render-icon.js +3 -320
- package/dist/utils/shared-strings.js +24 -32
- package/dist/utils/useBreakpointMatch.d.ts.map +1 -1
- package/dist/utils/useBreakpointMatch.js +2 -183
- package/dist/utils/useControllableState/useControllableState.js +31 -25
- package/dist/utils/useMergeRefs.js +29 -14
- package/dist/utils/useStableCallback/useStableCallback.js +28 -13
- package/package.json +17 -22
- package/dist/AlertBannerProvider-DTx2Xp3V.js +0 -50
- package/dist/BubbleCounter.module-QMwXWFIS.js +0 -16
- package/dist/ChipsPrimitive-DzsaOWgY.js +0 -1244
- package/dist/Dialog.module-Ba1X7b3N.js +0 -29
- package/dist/DialogRootContext-BCXmmJAw.js +0 -15
- package/dist/DropdownMenu.primitives-CqJE9k4D.js +0 -5871
- package/dist/IconTile-D1G7MljH.js +0 -172
- package/dist/InputContainer-oHJlLWIi.js +0 -30
- package/dist/Slider-DB4Maswa.js +0 -55
- package/dist/Stars-C_mHop2H.js +0 -67
- package/dist/TokyoUIChevronDown-D_tD1yU8.js +0 -11
- package/dist/floating-ui.utils.dom-BvMNldxo.js +0 -234
- package/dist/index.module-Q9TzIR6B.js +0 -11
- package/dist/layout-gap.module-MKn_un_k.js +0 -97
- package/dist/layout-grid.module-P4B4WVUy.js +0 -103
- package/dist/layout-hide.module-Bpl3Pl-a.js +0 -55
- package/dist/layout-padding-D5I6rRlL.js +0 -373
- package/dist/layout-relative.module-1z75aSwo.js +0 -8
- package/dist/useBaseUiId-DavsGYu9.js +0 -8
- package/dist/useButton-fjQ0ak8m.js +0 -193
- package/dist/useId-BhIOp2JG.js +0 -28
- package/dist/useOpenInteractionType-DNYFqf-a.js +0 -2880
- package/dist/useRenderElement-BSthtPOr.js +0 -350
|
@@ -1,320 +1,3 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import
|
|
3
|
-
|
|
4
|
-
var reactIs_production_min = {};
|
|
5
|
-
/**
|
|
6
|
-
* @license React
|
|
7
|
-
* react-is.production.min.js
|
|
8
|
-
*
|
|
9
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
10
|
-
*
|
|
11
|
-
* This source code is licensed under the MIT license found in the
|
|
12
|
-
* LICENSE file in the root directory of this source tree.
|
|
13
|
-
*/
|
|
14
|
-
var hasRequiredReactIs_production_min;
|
|
15
|
-
function requireReactIs_production_min() {
|
|
16
|
-
if (hasRequiredReactIs_production_min) return reactIs_production_min;
|
|
17
|
-
hasRequiredReactIs_production_min = 1;
|
|
18
|
-
var b = Symbol.for("react.element"), c = Symbol.for("react.portal"), d = Symbol.for("react.fragment"), e = Symbol.for("react.strict_mode"), f = Symbol.for("react.profiler"), g = Symbol.for("react.provider"), h = Symbol.for("react.context"), k = Symbol.for("react.server_context"), l = Symbol.for("react.forward_ref"), m = Symbol.for("react.suspense"), n = Symbol.for("react.suspense_list"), p = Symbol.for("react.memo"), q = Symbol.for("react.lazy"), t = Symbol.for("react.offscreen"), u;
|
|
19
|
-
u = Symbol.for("react.module.reference");
|
|
20
|
-
function v(a) {
|
|
21
|
-
if ("object" === typeof a && null !== a) {
|
|
22
|
-
var r = a.$$typeof;
|
|
23
|
-
switch (r) {
|
|
24
|
-
case b:
|
|
25
|
-
switch (a = a.type, a) {
|
|
26
|
-
case d:
|
|
27
|
-
case f:
|
|
28
|
-
case e:
|
|
29
|
-
case m:
|
|
30
|
-
case n:
|
|
31
|
-
return a;
|
|
32
|
-
default:
|
|
33
|
-
switch (a = a && a.$$typeof, a) {
|
|
34
|
-
case k:
|
|
35
|
-
case h:
|
|
36
|
-
case l:
|
|
37
|
-
case q:
|
|
38
|
-
case p:
|
|
39
|
-
case g:
|
|
40
|
-
return a;
|
|
41
|
-
default:
|
|
42
|
-
return r;
|
|
43
|
-
}
|
|
44
|
-
}
|
|
45
|
-
case c:
|
|
46
|
-
return r;
|
|
47
|
-
}
|
|
48
|
-
}
|
|
49
|
-
}
|
|
50
|
-
reactIs_production_min.ContextConsumer = h;
|
|
51
|
-
reactIs_production_min.ContextProvider = g;
|
|
52
|
-
reactIs_production_min.Element = b;
|
|
53
|
-
reactIs_production_min.ForwardRef = l;
|
|
54
|
-
reactIs_production_min.Fragment = d;
|
|
55
|
-
reactIs_production_min.Lazy = q;
|
|
56
|
-
reactIs_production_min.Memo = p;
|
|
57
|
-
reactIs_production_min.Portal = c;
|
|
58
|
-
reactIs_production_min.Profiler = f;
|
|
59
|
-
reactIs_production_min.StrictMode = e;
|
|
60
|
-
reactIs_production_min.Suspense = m;
|
|
61
|
-
reactIs_production_min.SuspenseList = n;
|
|
62
|
-
reactIs_production_min.isAsyncMode = function() {
|
|
63
|
-
return false;
|
|
64
|
-
};
|
|
65
|
-
reactIs_production_min.isConcurrentMode = function() {
|
|
66
|
-
return false;
|
|
67
|
-
};
|
|
68
|
-
reactIs_production_min.isContextConsumer = function(a) {
|
|
69
|
-
return v(a) === h;
|
|
70
|
-
};
|
|
71
|
-
reactIs_production_min.isContextProvider = function(a) {
|
|
72
|
-
return v(a) === g;
|
|
73
|
-
};
|
|
74
|
-
reactIs_production_min.isElement = function(a) {
|
|
75
|
-
return "object" === typeof a && null !== a && a.$$typeof === b;
|
|
76
|
-
};
|
|
77
|
-
reactIs_production_min.isForwardRef = function(a) {
|
|
78
|
-
return v(a) === l;
|
|
79
|
-
};
|
|
80
|
-
reactIs_production_min.isFragment = function(a) {
|
|
81
|
-
return v(a) === d;
|
|
82
|
-
};
|
|
83
|
-
reactIs_production_min.isLazy = function(a) {
|
|
84
|
-
return v(a) === q;
|
|
85
|
-
};
|
|
86
|
-
reactIs_production_min.isMemo = function(a) {
|
|
87
|
-
return v(a) === p;
|
|
88
|
-
};
|
|
89
|
-
reactIs_production_min.isPortal = function(a) {
|
|
90
|
-
return v(a) === c;
|
|
91
|
-
};
|
|
92
|
-
reactIs_production_min.isProfiler = function(a) {
|
|
93
|
-
return v(a) === f;
|
|
94
|
-
};
|
|
95
|
-
reactIs_production_min.isStrictMode = function(a) {
|
|
96
|
-
return v(a) === e;
|
|
97
|
-
};
|
|
98
|
-
reactIs_production_min.isSuspense = function(a) {
|
|
99
|
-
return v(a) === m;
|
|
100
|
-
};
|
|
101
|
-
reactIs_production_min.isSuspenseList = function(a) {
|
|
102
|
-
return v(a) === n;
|
|
103
|
-
};
|
|
104
|
-
reactIs_production_min.isValidElementType = function(a) {
|
|
105
|
-
return "string" === typeof a || "function" === typeof a || a === d || a === f || a === e || a === m || a === n || a === t || "object" === typeof a && null !== a && (a.$$typeof === q || a.$$typeof === p || a.$$typeof === g || a.$$typeof === h || a.$$typeof === l || a.$$typeof === u || void 0 !== a.getModuleId) ? true : false;
|
|
106
|
-
};
|
|
107
|
-
reactIs_production_min.typeOf = v;
|
|
108
|
-
return reactIs_production_min;
|
|
109
|
-
}
|
|
110
|
-
var reactIs_development = {};
|
|
111
|
-
/**
|
|
112
|
-
* @license React
|
|
113
|
-
* react-is.development.js
|
|
114
|
-
*
|
|
115
|
-
* Copyright (c) Facebook, Inc. and its affiliates.
|
|
116
|
-
*
|
|
117
|
-
* This source code is licensed under the MIT license found in the
|
|
118
|
-
* LICENSE file in the root directory of this source tree.
|
|
119
|
-
*/
|
|
120
|
-
var hasRequiredReactIs_development;
|
|
121
|
-
function requireReactIs_development() {
|
|
122
|
-
if (hasRequiredReactIs_development) return reactIs_development;
|
|
123
|
-
hasRequiredReactIs_development = 1;
|
|
124
|
-
if (process.env.NODE_ENV !== "production") {
|
|
125
|
-
(function() {
|
|
126
|
-
var REACT_ELEMENT_TYPE = Symbol.for("react.element");
|
|
127
|
-
var REACT_PORTAL_TYPE = Symbol.for("react.portal");
|
|
128
|
-
var REACT_FRAGMENT_TYPE = Symbol.for("react.fragment");
|
|
129
|
-
var REACT_STRICT_MODE_TYPE = Symbol.for("react.strict_mode");
|
|
130
|
-
var REACT_PROFILER_TYPE = Symbol.for("react.profiler");
|
|
131
|
-
var REACT_PROVIDER_TYPE = Symbol.for("react.provider");
|
|
132
|
-
var REACT_CONTEXT_TYPE = Symbol.for("react.context");
|
|
133
|
-
var REACT_SERVER_CONTEXT_TYPE = Symbol.for("react.server_context");
|
|
134
|
-
var REACT_FORWARD_REF_TYPE = Symbol.for("react.forward_ref");
|
|
135
|
-
var REACT_SUSPENSE_TYPE = Symbol.for("react.suspense");
|
|
136
|
-
var REACT_SUSPENSE_LIST_TYPE = Symbol.for("react.suspense_list");
|
|
137
|
-
var REACT_MEMO_TYPE = Symbol.for("react.memo");
|
|
138
|
-
var REACT_LAZY_TYPE = Symbol.for("react.lazy");
|
|
139
|
-
var REACT_OFFSCREEN_TYPE = Symbol.for("react.offscreen");
|
|
140
|
-
var enableScopeAPI = false;
|
|
141
|
-
var enableCacheElement = false;
|
|
142
|
-
var enableTransitionTracing = false;
|
|
143
|
-
var enableLegacyHidden = false;
|
|
144
|
-
var enableDebugTracing = false;
|
|
145
|
-
var REACT_MODULE_REFERENCE;
|
|
146
|
-
{
|
|
147
|
-
REACT_MODULE_REFERENCE = Symbol.for("react.module.reference");
|
|
148
|
-
}
|
|
149
|
-
function isValidElementType(type) {
|
|
150
|
-
if (typeof type === "string" || typeof type === "function") {
|
|
151
|
-
return true;
|
|
152
|
-
}
|
|
153
|
-
if (type === REACT_FRAGMENT_TYPE || type === REACT_PROFILER_TYPE || enableDebugTracing || type === REACT_STRICT_MODE_TYPE || type === REACT_SUSPENSE_TYPE || type === REACT_SUSPENSE_LIST_TYPE || enableLegacyHidden || type === REACT_OFFSCREEN_TYPE || enableScopeAPI || enableCacheElement || enableTransitionTracing) {
|
|
154
|
-
return true;
|
|
155
|
-
}
|
|
156
|
-
if (typeof type === "object" && type !== null) {
|
|
157
|
-
if (type.$$typeof === REACT_LAZY_TYPE || type.$$typeof === REACT_MEMO_TYPE || type.$$typeof === REACT_PROVIDER_TYPE || type.$$typeof === REACT_CONTEXT_TYPE || type.$$typeof === REACT_FORWARD_REF_TYPE || // This needs to include all possible module reference object
|
|
158
|
-
// types supported by any Flight configuration anywhere since
|
|
159
|
-
// we don't know which Flight build this will end up being used
|
|
160
|
-
// with.
|
|
161
|
-
type.$$typeof === REACT_MODULE_REFERENCE || type.getModuleId !== void 0) {
|
|
162
|
-
return true;
|
|
163
|
-
}
|
|
164
|
-
}
|
|
165
|
-
return false;
|
|
166
|
-
}
|
|
167
|
-
function typeOf(object) {
|
|
168
|
-
if (typeof object === "object" && object !== null) {
|
|
169
|
-
var $$typeof = object.$$typeof;
|
|
170
|
-
switch ($$typeof) {
|
|
171
|
-
case REACT_ELEMENT_TYPE:
|
|
172
|
-
var type = object.type;
|
|
173
|
-
switch (type) {
|
|
174
|
-
case REACT_FRAGMENT_TYPE:
|
|
175
|
-
case REACT_PROFILER_TYPE:
|
|
176
|
-
case REACT_STRICT_MODE_TYPE:
|
|
177
|
-
case REACT_SUSPENSE_TYPE:
|
|
178
|
-
case REACT_SUSPENSE_LIST_TYPE:
|
|
179
|
-
return type;
|
|
180
|
-
default:
|
|
181
|
-
var $$typeofType = type && type.$$typeof;
|
|
182
|
-
switch ($$typeofType) {
|
|
183
|
-
case REACT_SERVER_CONTEXT_TYPE:
|
|
184
|
-
case REACT_CONTEXT_TYPE:
|
|
185
|
-
case REACT_FORWARD_REF_TYPE:
|
|
186
|
-
case REACT_LAZY_TYPE:
|
|
187
|
-
case REACT_MEMO_TYPE:
|
|
188
|
-
case REACT_PROVIDER_TYPE:
|
|
189
|
-
return $$typeofType;
|
|
190
|
-
default:
|
|
191
|
-
return $$typeof;
|
|
192
|
-
}
|
|
193
|
-
}
|
|
194
|
-
case REACT_PORTAL_TYPE:
|
|
195
|
-
return $$typeof;
|
|
196
|
-
}
|
|
197
|
-
}
|
|
198
|
-
return void 0;
|
|
199
|
-
}
|
|
200
|
-
var ContextConsumer = REACT_CONTEXT_TYPE;
|
|
201
|
-
var ContextProvider = REACT_PROVIDER_TYPE;
|
|
202
|
-
var Element = REACT_ELEMENT_TYPE;
|
|
203
|
-
var ForwardRef = REACT_FORWARD_REF_TYPE;
|
|
204
|
-
var Fragment = REACT_FRAGMENT_TYPE;
|
|
205
|
-
var Lazy = REACT_LAZY_TYPE;
|
|
206
|
-
var Memo = REACT_MEMO_TYPE;
|
|
207
|
-
var Portal = REACT_PORTAL_TYPE;
|
|
208
|
-
var Profiler = REACT_PROFILER_TYPE;
|
|
209
|
-
var StrictMode = REACT_STRICT_MODE_TYPE;
|
|
210
|
-
var Suspense = REACT_SUSPENSE_TYPE;
|
|
211
|
-
var SuspenseList = REACT_SUSPENSE_LIST_TYPE;
|
|
212
|
-
var hasWarnedAboutDeprecatedIsAsyncMode = false;
|
|
213
|
-
var hasWarnedAboutDeprecatedIsConcurrentMode = false;
|
|
214
|
-
function isAsyncMode(object) {
|
|
215
|
-
{
|
|
216
|
-
if (!hasWarnedAboutDeprecatedIsAsyncMode) {
|
|
217
|
-
hasWarnedAboutDeprecatedIsAsyncMode = true;
|
|
218
|
-
console["warn"]("The ReactIs.isAsyncMode() alias has been deprecated, and will be removed in React 18+.");
|
|
219
|
-
}
|
|
220
|
-
}
|
|
221
|
-
return false;
|
|
222
|
-
}
|
|
223
|
-
function isConcurrentMode(object) {
|
|
224
|
-
{
|
|
225
|
-
if (!hasWarnedAboutDeprecatedIsConcurrentMode) {
|
|
226
|
-
hasWarnedAboutDeprecatedIsConcurrentMode = true;
|
|
227
|
-
console["warn"]("The ReactIs.isConcurrentMode() alias has been deprecated, and will be removed in React 18+.");
|
|
228
|
-
}
|
|
229
|
-
}
|
|
230
|
-
return false;
|
|
231
|
-
}
|
|
232
|
-
function isContextConsumer(object) {
|
|
233
|
-
return typeOf(object) === REACT_CONTEXT_TYPE;
|
|
234
|
-
}
|
|
235
|
-
function isContextProvider(object) {
|
|
236
|
-
return typeOf(object) === REACT_PROVIDER_TYPE;
|
|
237
|
-
}
|
|
238
|
-
function isElement(object) {
|
|
239
|
-
return typeof object === "object" && object !== null && object.$$typeof === REACT_ELEMENT_TYPE;
|
|
240
|
-
}
|
|
241
|
-
function isForwardRef(object) {
|
|
242
|
-
return typeOf(object) === REACT_FORWARD_REF_TYPE;
|
|
243
|
-
}
|
|
244
|
-
function isFragment(object) {
|
|
245
|
-
return typeOf(object) === REACT_FRAGMENT_TYPE;
|
|
246
|
-
}
|
|
247
|
-
function isLazy(object) {
|
|
248
|
-
return typeOf(object) === REACT_LAZY_TYPE;
|
|
249
|
-
}
|
|
250
|
-
function isMemo(object) {
|
|
251
|
-
return typeOf(object) === REACT_MEMO_TYPE;
|
|
252
|
-
}
|
|
253
|
-
function isPortal(object) {
|
|
254
|
-
return typeOf(object) === REACT_PORTAL_TYPE;
|
|
255
|
-
}
|
|
256
|
-
function isProfiler(object) {
|
|
257
|
-
return typeOf(object) === REACT_PROFILER_TYPE;
|
|
258
|
-
}
|
|
259
|
-
function isStrictMode(object) {
|
|
260
|
-
return typeOf(object) === REACT_STRICT_MODE_TYPE;
|
|
261
|
-
}
|
|
262
|
-
function isSuspense(object) {
|
|
263
|
-
return typeOf(object) === REACT_SUSPENSE_TYPE;
|
|
264
|
-
}
|
|
265
|
-
function isSuspenseList(object) {
|
|
266
|
-
return typeOf(object) === REACT_SUSPENSE_LIST_TYPE;
|
|
267
|
-
}
|
|
268
|
-
reactIs_development.ContextConsumer = ContextConsumer;
|
|
269
|
-
reactIs_development.ContextProvider = ContextProvider;
|
|
270
|
-
reactIs_development.Element = Element;
|
|
271
|
-
reactIs_development.ForwardRef = ForwardRef;
|
|
272
|
-
reactIs_development.Fragment = Fragment;
|
|
273
|
-
reactIs_development.Lazy = Lazy;
|
|
274
|
-
reactIs_development.Memo = Memo;
|
|
275
|
-
reactIs_development.Portal = Portal;
|
|
276
|
-
reactIs_development.Profiler = Profiler;
|
|
277
|
-
reactIs_development.StrictMode = StrictMode;
|
|
278
|
-
reactIs_development.Suspense = Suspense;
|
|
279
|
-
reactIs_development.SuspenseList = SuspenseList;
|
|
280
|
-
reactIs_development.isAsyncMode = isAsyncMode;
|
|
281
|
-
reactIs_development.isConcurrentMode = isConcurrentMode;
|
|
282
|
-
reactIs_development.isContextConsumer = isContextConsumer;
|
|
283
|
-
reactIs_development.isContextProvider = isContextProvider;
|
|
284
|
-
reactIs_development.isElement = isElement;
|
|
285
|
-
reactIs_development.isForwardRef = isForwardRef;
|
|
286
|
-
reactIs_development.isFragment = isFragment;
|
|
287
|
-
reactIs_development.isLazy = isLazy;
|
|
288
|
-
reactIs_development.isMemo = isMemo;
|
|
289
|
-
reactIs_development.isPortal = isPortal;
|
|
290
|
-
reactIs_development.isProfiler = isProfiler;
|
|
291
|
-
reactIs_development.isStrictMode = isStrictMode;
|
|
292
|
-
reactIs_development.isSuspense = isSuspense;
|
|
293
|
-
reactIs_development.isSuspenseList = isSuspenseList;
|
|
294
|
-
reactIs_development.isValidElementType = isValidElementType;
|
|
295
|
-
reactIs_development.typeOf = typeOf;
|
|
296
|
-
})();
|
|
297
|
-
}
|
|
298
|
-
return reactIs_development;
|
|
299
|
-
}
|
|
300
|
-
var hasRequiredReactIs;
|
|
301
|
-
function requireReactIs() {
|
|
302
|
-
if (hasRequiredReactIs) return reactIs.exports;
|
|
303
|
-
hasRequiredReactIs = 1;
|
|
304
|
-
if (process.env.NODE_ENV === "production") {
|
|
305
|
-
reactIs.exports = requireReactIs_production_min();
|
|
306
|
-
} else {
|
|
307
|
-
reactIs.exports = requireReactIs_development();
|
|
308
|
-
}
|
|
309
|
-
return reactIs.exports;
|
|
310
|
-
}
|
|
311
|
-
var reactIsExports = requireReactIs();
|
|
312
|
-
const renderIcon = (ComponentOrElement, attrs) => {
|
|
313
|
-
if (reactIsExports.isElement(ComponentOrElement)) {
|
|
314
|
-
return cloneElement(ComponentOrElement, attrs);
|
|
315
|
-
}
|
|
316
|
-
return /* @__PURE__ */ jsx(ComponentOrElement, { ...attrs });
|
|
317
|
-
};
|
|
318
|
-
export {
|
|
319
|
-
renderIcon
|
|
320
|
-
};
|
|
1
|
+
import { t as renderIcon } from "../render-icon-Ch3b2dE0.js";
|
|
2
|
+
import "../jsx-runtime-i4KUlhDu.js";
|
|
3
|
+
export { renderIcon };
|
|
@@ -1,34 +1,26 @@
|
|
|
1
1
|
import { defineMessages } from "react-intl";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
cancel: {
|
|
25
|
-
id: "preply-ds.genericAriaLabels.cancel",
|
|
26
|
-
defaultMessage: [{
|
|
27
|
-
"type": 0,
|
|
28
|
-
"value": "Cancel"
|
|
29
|
-
}]
|
|
30
|
-
}
|
|
2
|
+
//#region src/utils/shared-strings.ts
|
|
3
|
+
var genericAriaLabels = defineMessages({
|
|
4
|
+
remove: {
|
|
5
|
+
id: "preply-ds.genericAriaLabels.remove",
|
|
6
|
+
defaultMessage: "Remove",
|
|
7
|
+
description: "Generic aria-label for the remove action"
|
|
8
|
+
},
|
|
9
|
+
close: {
|
|
10
|
+
id: "preply-ds.genericAriaLabels.close",
|
|
11
|
+
defaultMessage: "Close",
|
|
12
|
+
description: "Generic aria-label for the close action"
|
|
13
|
+
},
|
|
14
|
+
confirm: {
|
|
15
|
+
id: "preply-ds.genericAriaLabels.confirm",
|
|
16
|
+
defaultMessage: "Confirm",
|
|
17
|
+
description: "Generic aria-label for the confirm action"
|
|
18
|
+
},
|
|
19
|
+
cancel: {
|
|
20
|
+
id: "preply-ds.genericAriaLabels.cancel",
|
|
21
|
+
defaultMessage: "Cancel",
|
|
22
|
+
description: "Generic aria-label for the cancel action"
|
|
23
|
+
}
|
|
31
24
|
});
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
};
|
|
25
|
+
//#endregion
|
|
26
|
+
export { genericAriaLabels };
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"useBreakpointMatch.d.ts","sourceRoot":"","sources":["../../src/utils/useBreakpointMatch.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"useBreakpointMatch.d.ts","sourceRoot":"","sources":["../../src/utils/useBreakpointMatch.ts"],"names":[],"mappings":"AAEA,OAAO,EAAc,UAAU,EAAE,MAAM,iBAAiB,CAAC;AAGzD;;;;;;;GAOG;AACH,wBAAgB,kBAAkB,CAAC,UAAU,EAAE,UAAU,WAGxD"}
|
|
@@ -1,183 +1,2 @@
|
|
|
1
|
-
import {
|
|
2
|
-
|
|
3
|
-
var commonjsGlobal = typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : typeof global !== "undefined" ? global : typeof self !== "undefined" ? self : {};
|
|
4
|
-
var lodash_debounce;
|
|
5
|
-
var hasRequiredLodash_debounce;
|
|
6
|
-
function requireLodash_debounce() {
|
|
7
|
-
if (hasRequiredLodash_debounce) return lodash_debounce;
|
|
8
|
-
hasRequiredLodash_debounce = 1;
|
|
9
|
-
var FUNC_ERROR_TEXT = "Expected a function";
|
|
10
|
-
var NAN = 0 / 0;
|
|
11
|
-
var symbolTag = "[object Symbol]";
|
|
12
|
-
var reTrim = /^\s+|\s+$/g;
|
|
13
|
-
var reIsBadHex = /^[-+]0x[0-9a-f]+$/i;
|
|
14
|
-
var reIsBinary = /^0b[01]+$/i;
|
|
15
|
-
var reIsOctal = /^0o[0-7]+$/i;
|
|
16
|
-
var freeParseInt = parseInt;
|
|
17
|
-
var freeGlobal = typeof commonjsGlobal == "object" && commonjsGlobal && commonjsGlobal.Object === Object && commonjsGlobal;
|
|
18
|
-
var freeSelf = typeof self == "object" && self && self.Object === Object && self;
|
|
19
|
-
var root = freeGlobal || freeSelf || Function("return this")();
|
|
20
|
-
var objectProto = Object.prototype;
|
|
21
|
-
var objectToString = objectProto.toString;
|
|
22
|
-
var nativeMax = Math.max, nativeMin = Math.min;
|
|
23
|
-
var now = function() {
|
|
24
|
-
return root.Date.now();
|
|
25
|
-
};
|
|
26
|
-
function debounce(func, wait, options) {
|
|
27
|
-
var lastArgs, lastThis, maxWait, result, timerId, lastCallTime, lastInvokeTime = 0, leading = false, maxing = false, trailing = true;
|
|
28
|
-
if (typeof func != "function") {
|
|
29
|
-
throw new TypeError(FUNC_ERROR_TEXT);
|
|
30
|
-
}
|
|
31
|
-
wait = toNumber(wait) || 0;
|
|
32
|
-
if (isObject(options)) {
|
|
33
|
-
leading = !!options.leading;
|
|
34
|
-
maxing = "maxWait" in options;
|
|
35
|
-
maxWait = maxing ? nativeMax(toNumber(options.maxWait) || 0, wait) : maxWait;
|
|
36
|
-
trailing = "trailing" in options ? !!options.trailing : trailing;
|
|
37
|
-
}
|
|
38
|
-
function invokeFunc(time) {
|
|
39
|
-
var args = lastArgs, thisArg = lastThis;
|
|
40
|
-
lastArgs = lastThis = void 0;
|
|
41
|
-
lastInvokeTime = time;
|
|
42
|
-
result = func.apply(thisArg, args);
|
|
43
|
-
return result;
|
|
44
|
-
}
|
|
45
|
-
function leadingEdge(time) {
|
|
46
|
-
lastInvokeTime = time;
|
|
47
|
-
timerId = setTimeout(timerExpired, wait);
|
|
48
|
-
return leading ? invokeFunc(time) : result;
|
|
49
|
-
}
|
|
50
|
-
function remainingWait(time) {
|
|
51
|
-
var timeSinceLastCall = time - lastCallTime, timeSinceLastInvoke = time - lastInvokeTime, result2 = wait - timeSinceLastCall;
|
|
52
|
-
return maxing ? nativeMin(result2, maxWait - timeSinceLastInvoke) : result2;
|
|
53
|
-
}
|
|
54
|
-
function shouldInvoke(time) {
|
|
55
|
-
var timeSinceLastCall = time - lastCallTime, timeSinceLastInvoke = time - lastInvokeTime;
|
|
56
|
-
return lastCallTime === void 0 || timeSinceLastCall >= wait || timeSinceLastCall < 0 || maxing && timeSinceLastInvoke >= maxWait;
|
|
57
|
-
}
|
|
58
|
-
function timerExpired() {
|
|
59
|
-
var time = now();
|
|
60
|
-
if (shouldInvoke(time)) {
|
|
61
|
-
return trailingEdge(time);
|
|
62
|
-
}
|
|
63
|
-
timerId = setTimeout(timerExpired, remainingWait(time));
|
|
64
|
-
}
|
|
65
|
-
function trailingEdge(time) {
|
|
66
|
-
timerId = void 0;
|
|
67
|
-
if (trailing && lastArgs) {
|
|
68
|
-
return invokeFunc(time);
|
|
69
|
-
}
|
|
70
|
-
lastArgs = lastThis = void 0;
|
|
71
|
-
return result;
|
|
72
|
-
}
|
|
73
|
-
function cancel() {
|
|
74
|
-
if (timerId !== void 0) {
|
|
75
|
-
clearTimeout(timerId);
|
|
76
|
-
}
|
|
77
|
-
lastInvokeTime = 0;
|
|
78
|
-
lastArgs = lastCallTime = lastThis = timerId = void 0;
|
|
79
|
-
}
|
|
80
|
-
function flush() {
|
|
81
|
-
return timerId === void 0 ? result : trailingEdge(now());
|
|
82
|
-
}
|
|
83
|
-
function debounced() {
|
|
84
|
-
var time = now(), isInvoking = shouldInvoke(time);
|
|
85
|
-
lastArgs = arguments;
|
|
86
|
-
lastThis = this;
|
|
87
|
-
lastCallTime = time;
|
|
88
|
-
if (isInvoking) {
|
|
89
|
-
if (timerId === void 0) {
|
|
90
|
-
return leadingEdge(lastCallTime);
|
|
91
|
-
}
|
|
92
|
-
if (maxing) {
|
|
93
|
-
timerId = setTimeout(timerExpired, wait);
|
|
94
|
-
return invokeFunc(lastCallTime);
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
if (timerId === void 0) {
|
|
98
|
-
timerId = setTimeout(timerExpired, wait);
|
|
99
|
-
}
|
|
100
|
-
return result;
|
|
101
|
-
}
|
|
102
|
-
debounced.cancel = cancel;
|
|
103
|
-
debounced.flush = flush;
|
|
104
|
-
return debounced;
|
|
105
|
-
}
|
|
106
|
-
function isObject(value) {
|
|
107
|
-
var type = typeof value;
|
|
108
|
-
return !!value && (type == "object" || type == "function");
|
|
109
|
-
}
|
|
110
|
-
function isObjectLike(value) {
|
|
111
|
-
return !!value && typeof value == "object";
|
|
112
|
-
}
|
|
113
|
-
function isSymbol(value) {
|
|
114
|
-
return typeof value == "symbol" || isObjectLike(value) && objectToString.call(value) == symbolTag;
|
|
115
|
-
}
|
|
116
|
-
function toNumber(value) {
|
|
117
|
-
if (typeof value == "number") {
|
|
118
|
-
return value;
|
|
119
|
-
}
|
|
120
|
-
if (isSymbol(value)) {
|
|
121
|
-
return NAN;
|
|
122
|
-
}
|
|
123
|
-
if (isObject(value)) {
|
|
124
|
-
var other = typeof value.valueOf == "function" ? value.valueOf() : value;
|
|
125
|
-
value = isObject(other) ? other + "" : other;
|
|
126
|
-
}
|
|
127
|
-
if (typeof value != "string") {
|
|
128
|
-
return value === 0 ? value : +value;
|
|
129
|
-
}
|
|
130
|
-
value = value.replace(reTrim, "");
|
|
131
|
-
var isBinary = reIsBinary.test(value);
|
|
132
|
-
return isBinary || reIsOctal.test(value) ? freeParseInt(value.slice(2), isBinary ? 2 : 8) : reIsBadHex.test(value) ? NAN : +value;
|
|
133
|
-
}
|
|
134
|
-
lodash_debounce = debounce;
|
|
135
|
-
return lodash_debounce;
|
|
136
|
-
}
|
|
137
|
-
requireLodash_debounce();
|
|
138
|
-
var useIsomorphicLayoutEffect = typeof window !== "undefined" ? useLayoutEffect : useEffect;
|
|
139
|
-
var IS_SERVER2 = typeof window === "undefined";
|
|
140
|
-
function useMediaQuery(query, {
|
|
141
|
-
defaultValue = false,
|
|
142
|
-
initializeWithValue = true
|
|
143
|
-
} = {}) {
|
|
144
|
-
const getMatches = (query2) => {
|
|
145
|
-
if (IS_SERVER2) {
|
|
146
|
-
return defaultValue;
|
|
147
|
-
}
|
|
148
|
-
return window.matchMedia(query2).matches;
|
|
149
|
-
};
|
|
150
|
-
const [matches, setMatches] = useState(() => {
|
|
151
|
-
if (initializeWithValue) {
|
|
152
|
-
return getMatches(query);
|
|
153
|
-
}
|
|
154
|
-
return defaultValue;
|
|
155
|
-
});
|
|
156
|
-
function handleChange() {
|
|
157
|
-
setMatches(getMatches(query));
|
|
158
|
-
}
|
|
159
|
-
useIsomorphicLayoutEffect(() => {
|
|
160
|
-
const matchMedia = window.matchMedia(query);
|
|
161
|
-
handleChange();
|
|
162
|
-
if (matchMedia.addListener) {
|
|
163
|
-
matchMedia.addListener(handleChange);
|
|
164
|
-
} else {
|
|
165
|
-
matchMedia.addEventListener("change", handleChange);
|
|
166
|
-
}
|
|
167
|
-
return () => {
|
|
168
|
-
if (matchMedia.removeListener) {
|
|
169
|
-
matchMedia.removeListener(handleChange);
|
|
170
|
-
} else {
|
|
171
|
-
matchMedia.removeEventListener("change", handleChange);
|
|
172
|
-
}
|
|
173
|
-
};
|
|
174
|
-
}, [query]);
|
|
175
|
-
return matches;
|
|
176
|
-
}
|
|
177
|
-
function useBreakpointMatch(breakpoint) {
|
|
178
|
-
const size = BREAKPOINT[breakpoint];
|
|
179
|
-
return useMediaQuery(`(min-width: ${size}px)`);
|
|
180
|
-
}
|
|
181
|
-
export {
|
|
182
|
-
useBreakpointMatch
|
|
183
|
-
};
|
|
1
|
+
import { t as useBreakpointMatch } from "../useBreakpointMatch-D9a3CTNK.js";
|
|
2
|
+
export { useBreakpointMatch };
|
|
@@ -1,27 +1,33 @@
|
|
|
1
|
-
import { useState, useEffect, useCallback } from "react";
|
|
2
1
|
import { useStableCallback } from "../useStableCallback/useStableCallback.js";
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
2
|
+
import { useCallback, useEffect, useState } from "react";
|
|
3
|
+
//#region src/utils/useControllableState/useControllableState.ts
|
|
4
|
+
/**
|
|
5
|
+
* A hook that manages state that can be either controlled or uncontrolled.
|
|
6
|
+
*
|
|
7
|
+
* @example
|
|
8
|
+
* ```tsx
|
|
9
|
+
* function MyInput(props) {
|
|
10
|
+
* const [value, setValue] = useControllableState(props);
|
|
11
|
+
* return <input value={value} onChange={(e) => setValue(e.target.value)} />;
|
|
12
|
+
* }
|
|
13
|
+
* ```
|
|
14
|
+
*/
|
|
15
|
+
function useControllableState({ value, defaultValue, onValueChange }) {
|
|
16
|
+
const isControlled = value !== void 0;
|
|
17
|
+
const [internalValue, setInternalValue] = useState(isControlled ? value : defaultValue);
|
|
18
|
+
useEffect(() => {
|
|
19
|
+
if (isControlled && value !== internalValue) setInternalValue(value);
|
|
20
|
+
}, [
|
|
21
|
+
isControlled,
|
|
22
|
+
value,
|
|
23
|
+
internalValue
|
|
24
|
+
]);
|
|
25
|
+
const onValueChangeStable = useStableCallback(onValueChange);
|
|
26
|
+
const handleValueChange = useCallback((value) => {
|
|
27
|
+
if (!isControlled) setInternalValue(value);
|
|
28
|
+
onValueChangeStable(value);
|
|
29
|
+
}, [isControlled, onValueChangeStable]);
|
|
30
|
+
return [isControlled ? value : internalValue, handleValueChange];
|
|
24
31
|
}
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
};
|
|
32
|
+
//#endregion
|
|
33
|
+
export { useControllableState };
|
|
@@ -1,17 +1,32 @@
|
|
|
1
1
|
import { useCallback } from "react";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
ref.current = value;
|
|
7
|
-
}
|
|
2
|
+
//#region src/utils/useMergeRefs.ts
|
|
3
|
+
var applyRef = (ref, value) => {
|
|
4
|
+
if (typeof ref === "function") ref(value);
|
|
5
|
+
else if (ref) ref.current = value;
|
|
8
6
|
};
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
7
|
+
/**
|
|
8
|
+
* A React hook that merges two refs into a single ref callback.
|
|
9
|
+
* This is useful when you need to pass multiple refs to a single element.
|
|
10
|
+
*
|
|
11
|
+
* @param ref1 The first ref to merge
|
|
12
|
+
* @param ref2 The second ref to merge
|
|
13
|
+
* @returns A callback ref that updates both input refs
|
|
14
|
+
*
|
|
15
|
+
* @example
|
|
16
|
+
* ```tsx
|
|
17
|
+
* const Component = React.forwardRef((props, ref) => {
|
|
18
|
+
* const localRef = useRef(null);
|
|
19
|
+
* const mergedRef = useMergeRefs(ref, localRef);
|
|
20
|
+
*
|
|
21
|
+
* return <div ref={mergedRef} />;
|
|
22
|
+
* });
|
|
23
|
+
* ```
|
|
24
|
+
*/
|
|
25
|
+
var useMergeRefs = (ref1, ref2) => {
|
|
26
|
+
return useCallback((node) => {
|
|
27
|
+
applyRef(ref1, node);
|
|
28
|
+
applyRef(ref2, node);
|
|
29
|
+
}, [ref1, ref2]);
|
|
17
30
|
};
|
|
31
|
+
//#endregion
|
|
32
|
+
export { useMergeRefs };
|