welcome-ui 8.1.1 → 8.2.0-alpha.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/{AXB53BZF-BOEe01VW.mjs → AXB53BZF-XKOjjeWO.mjs} +3 -3
- package/dist/Accordion.mjs +30 -23
- package/dist/Alert.mjs +72 -66
- package/dist/AspectRatio.mjs +9 -9
- package/dist/Avatar.mjs +45 -41
- package/dist/{BYC7LY2E-B1IDizRs.mjs → BYC7LY2E-CWSI38FM.mjs} +128 -127
- package/dist/Badge.mjs +25 -25
- package/dist/Box.mjs +5 -5
- package/dist/Breadcrumb.mjs +118 -112
- package/dist/Button.mjs +72 -67
- package/dist/ButtonGroup.mjs +12 -11
- package/dist/Card.mjs +14 -14
- package/dist/Checkbox.mjs +2 -2
- package/dist/ClearButton.mjs +15 -15
- package/dist/CloseButton.mjs +9 -9
- package/dist/{CustomInput-IA_gVoXd.mjs → CustomPopper-DezjKb9n.mjs} +1458 -1442
- package/dist/DatePicker.mjs +63 -62
- package/dist/DateTimePicker.mjs +69 -63
- package/dist/DateTimePickerCommon.mjs +1 -1
- package/dist/Drawer.mjs +171 -159
- package/dist/DropdownMenu.mjs +354 -351
- package/dist/Field.mjs +103 -92
- package/dist/FieldGroup.mjs +12 -9
- package/dist/FileDrop.mjs +316 -295
- package/dist/FileUpload.mjs +83 -69
- package/dist/Files.mjs +41 -41
- package/dist/Flex.mjs +13 -13
- package/dist/Grid.mjs +29 -29
- package/dist/Hint.mjs +12 -12
- package/dist/{ITI7HKP4-EL9KXYBU.mjs → ITI7HKP4-C89kOQb8.mjs} +68 -67
- package/dist/Icon.mjs +25 -25
- package/dist/Icons.mjs +988 -988
- package/dist/IconsFont.mjs +22 -22
- package/dist/InputText.mjs +64 -56
- package/dist/{JC64G2H7-BzklVBKM.mjs → JC64G2H7-afsomHuH.mjs} +47 -46
- package/dist/{KUU7WJ55-CS4NemC6.mjs → KUU7WJ55-CzsjuIMv.mjs} +1 -1
- package/dist/LVA2YJMS-C-kJ1lkr.mjs +873 -0
- package/dist/Label.mjs +37 -35
- package/dist/Link.mjs +32 -28
- package/dist/Loader.mjs +20 -16
- package/dist/Logo.mjs +55 -42
- package/dist/{MTZPJQMC-CMjAwC0N.mjs → MTZPJQMC-TybFZCho.mjs} +2 -2
- package/dist/Modal.mjs +263 -244
- package/dist/{NLEBE274-QOMV1l7e.mjs → NLEBE274-oSxMftGy.mjs} +9 -9
- package/dist/{P2CTZE2T-Cl2w7OLV.mjs → P2CTZE2T-DOT1mNnX.mjs} +49 -48
- package/dist/{P4IRICAX-DezbJY4s.mjs → P4IRICAX-CWSZLTGz.mjs} +3 -3
- package/dist/Pagination.mjs +105 -103
- package/dist/PasswordInput.mjs +35 -34
- package/dist/Picker.mjs +36 -34
- package/dist/Popover.mjs +106 -99
- package/dist/{QYJ6MIDR-Bb0O5xUM.mjs → QYJ6MIDR-DJ-vUdAM.mjs} +31 -30
- package/dist/Radio.mjs +52 -46
- package/dist/RadioGroup.mjs +47 -47
- package/dist/RadioTab.mjs +37 -35
- package/dist/{SYRFVSLH-jn06-eLy.mjs → SYRFVSLH-B6m278Vb.mjs} +11 -10
- package/dist/Search.mjs +147 -135
- package/dist/Select.mjs +348 -330
- package/dist/Shape.mjs +9 -9
- package/dist/Slider.mjs +353 -326
- package/dist/Stack.mjs +24 -23
- package/dist/Swiper.mjs +192 -186
- package/dist/Table.mjs +23 -23
- package/dist/Tabs.mjs +205 -200
- package/dist/Tag.mjs +49 -47
- package/dist/Text.mjs +20 -20
- package/dist/Textarea.mjs +40 -40
- package/dist/TimePicker.mjs +59 -58
- package/dist/Toast.mjs +135 -128
- package/dist/Toggle.mjs +27 -24
- package/dist/Tooltip.mjs +103 -99
- package/dist/UniversalLink.mjs +15 -15
- package/dist/{VEVQD5MH-CuegL0m0.mjs → VEVQD5MH-0w9Y7Ytc.mjs} +3 -3
- package/dist/{VGCJ63VH-BMzoZtCu.mjs → VGCJ63VH-C0UPBY-5.mjs} +39 -38
- package/dist/VariantIcon.mjs +23 -22
- package/dist/WelcomeLoader.mjs +122 -121
- package/dist/WuiProvider.mjs +52 -44
- package/dist/{X5NMLKT6-CvSCix-_.mjs → X5NMLKT6-BJw3xE-K.mjs} +2 -2
- package/dist/{YV4JVR4I-Bh7B7TET.mjs → YV4JVR4I-DPC8mMuG.mjs} +57 -57
- package/dist/hide-focus-rings-root-CCXdysih.mjs +15 -0
- package/dist/{index-5PUh49rV.mjs → index-62h-enZF.mjs} +62 -61
- package/dist/{index-C7zM96J_.mjs → index-BaLGEKs7.mjs} +8 -8
- package/dist/index-CYmF7qCH.mjs +11 -0
- package/dist/index-C_k-m0Rl.mjs +36 -0
- package/dist/index-D8v_VJ9z.mjs +26 -0
- package/dist/{index-BNGGwOCo.mjs → index-DAZ1SYdj.mjs} +7 -7
- package/dist/index-DpkNUfAS.mjs +11 -0
- package/dist/{index-DqBUFsqP.mjs → index-DvzWKxKE.mjs} +7 -7
- package/dist/{index-Bkl89twW.mjs → index-QaLwIvZS.mjs} +8 -8
- package/dist/{index-BQtDgQBH.mjs → index-SQQQ4dEE.mjs} +8 -8
- package/dist/index-i_anpNhw.mjs +66 -0
- package/dist/index-wl3X6EM1.mjs +16 -0
- package/dist/jsx-runtime-B7I4PJ0H.mjs +613 -0
- package/dist/radio-group-C0fUHvam.mjs +52 -0
- package/dist/theme.mjs +805 -805
- package/dist/types/components/Accordion/index.d.ts +1 -1
- package/dist/types/components/Alert/index.d.ts +2 -2
- package/dist/types/components/Alert/styles.d.ts +4 -4
- package/dist/types/components/Alert/theme.d.ts +4 -4
- package/dist/types/components/Avatar/index.d.ts +1 -1
- package/dist/types/components/Avatar/styles.d.ts +4 -4
- package/dist/types/components/Avatar/theme.d.ts +1 -1
- package/dist/types/components/Badge/index.d.ts +2 -2
- package/dist/types/components/Badge/styles.d.ts +2 -2
- package/dist/types/components/Breadcrumb/Item.d.ts +1 -1
- package/dist/types/components/Breadcrumb/index.d.ts +1 -1
- package/dist/types/components/Button/index.d.ts +4 -5
- package/dist/types/components/Button/theme.d.ts +7 -7
- package/dist/types/components/ButtonGroup/index.d.ts +3 -3
- package/dist/types/components/Card/Cover.styles.d.ts +2 -2
- package/dist/types/components/Card/index.d.ts +2 -3
- package/dist/types/components/Checkbox/index.d.ts +2 -2
- package/dist/types/components/ClearButton/index.d.ts +4 -5
- package/dist/types/components/ClearButton/styles.d.ts +2 -2
- package/dist/types/components/CloseButton/styles.d.ts +2 -2
- package/dist/types/components/DatePicker/index.d.ts +3 -3
- package/dist/types/components/DateTimePicker/index.d.ts +2 -2
- package/dist/types/components/DateTimePickerCommon/CustomHeader.d.ts +1 -1
- package/dist/types/components/DateTimePickerCommon/CustomInput.d.ts +5 -5
- package/dist/types/components/DateTimePickerCommon/CustomPopper.d.ts +1 -1
- package/dist/types/components/DateTimePickerCommon/index.d.ts +2 -2
- package/dist/types/components/DateTimePickerCommon/utils.d.ts +1 -1
- package/dist/types/components/Drawer/AssetDrawer/Header.d.ts +1 -1
- package/dist/types/components/Drawer/AssetDrawer/index.d.ts +1 -1
- package/dist/types/components/Drawer/index.d.ts +8 -8
- package/dist/types/components/Drawer/styles.d.ts +3 -3
- package/dist/types/components/Drawer/theme.d.ts +1 -1
- package/dist/types/components/DropdownMenu/index.d.ts +4 -4
- package/dist/types/components/Field/index.d.ts +8 -8
- package/dist/types/components/Field/styles.d.ts +1 -1
- package/dist/types/components/Field/utils.d.ts +1 -1
- package/dist/types/components/FileDrop/FilePreview.d.ts +2 -2
- package/dist/types/components/FileDrop/Message.d.ts +1 -1
- package/dist/types/components/FileDrop/index.d.ts +16 -16
- package/dist/types/components/FileUpload/index.d.ts +13 -13
- package/dist/types/components/Files/index.d.ts +4 -4
- package/dist/types/components/Files/types.d.ts +1 -1
- package/dist/types/components/Hint/index.d.ts +1 -2
- package/dist/types/components/Icon/index.d.ts +3 -3
- package/dist/types/components/Icon/styles.d.ts +3 -3
- package/dist/types/components/Icon/theme.d.ts +1 -1
- package/dist/types/components/Icons/index.d.ts +2 -2
- package/dist/types/components/IconsFont/index.d.ts +2 -3
- package/dist/types/components/IconsFont/styles.d.ts +1 -1
- package/dist/types/components/InputText/index.d.ts +1 -1
- package/dist/types/components/InputText/styles.d.ts +1 -1
- package/dist/types/components/Label/index.d.ts +2 -3
- package/dist/types/components/Link/index.d.ts +3 -3
- package/dist/types/components/Link/styles.d.ts +2 -2
- package/dist/types/components/Loader/index.d.ts +1 -1
- package/dist/types/components/Loader/styles.d.ts +2 -2
- package/dist/types/components/Loader/theme.d.ts +2 -2
- package/dist/types/components/Logo/Solutions.d.ts +1 -2
- package/dist/types/components/Logo/Symbol.d.ts +1 -2
- package/dist/types/components/Logo/Wui.d.ts +1 -2
- package/dist/types/components/Logo/index.d.ts +5 -5
- package/dist/types/components/Modal/Assets/Backdrop.d.ts +4 -5
- package/dist/types/components/Modal/Assets/Iframe.d.ts +1 -2
- package/dist/types/components/Modal/Assets/index.d.ts +5 -5
- package/dist/types/components/Modal/Assets/styles.d.ts +4 -4
- package/dist/types/components/Modal/Close.d.ts +1 -2
- package/dist/types/components/Modal/Footer.d.ts +1 -1
- package/dist/types/components/Modal/Header.d.ts +2 -2
- package/dist/types/components/Modal/index.d.ts +11 -11
- package/dist/types/components/Modal/styles.d.ts +4 -4
- package/dist/types/components/Modal/theme.d.ts +1 -1
- package/dist/types/components/Pagination/index.d.ts +2 -2
- package/dist/types/components/Pagination/utils.d.ts +1 -1
- package/dist/types/components/Popover/Arrow.d.ts +1 -2
- package/dist/types/components/Popover/Content.d.ts +2 -3
- package/dist/types/components/Popover/Popover.d.ts +4 -5
- package/dist/types/components/Popover/PopoverHover.d.ts +3 -4
- package/dist/types/components/Popover/Trigger.d.ts +1 -1
- package/dist/types/components/Popover/usePopover.d.ts +6 -6
- package/dist/types/components/Radio/index.d.ts +5 -5
- package/dist/types/components/Radio/styles.d.ts +2 -2
- package/dist/types/components/RadioGroup/index.d.ts +2 -2
- package/dist/types/components/RadioTab/index.d.ts +2 -2
- package/dist/types/components/RadioTab/styles.d.ts +9 -9
- package/dist/types/components/Search/index.d.ts +4 -4
- package/dist/types/components/Select/index.d.ts +9 -9
- package/dist/types/components/Select/styles.d.ts +4 -4
- package/dist/types/components/Select/utils.d.ts +4 -4
- package/dist/types/components/Shape/index.d.ts +1 -1
- package/dist/types/components/Shape/styles.d.ts +2 -2
- package/dist/types/components/Slider/Range.d.ts +3 -3
- package/dist/types/components/Slider/index.d.ts +2 -2
- package/dist/types/components/Slider/styles.d.ts +10 -10
- package/dist/types/components/Stack/index.d.ts +1 -1
- package/dist/types/components/Swiper/index.d.ts +16 -17
- package/dist/types/components/Swiper/styles.d.ts +55 -55
- package/dist/types/components/System/index.d.ts +10 -10
- package/dist/types/components/Table/index.d.ts +6 -7
- package/dist/types/components/Table/styles.d.ts +1 -1
- package/dist/types/components/Tabs/ActiveBar.d.ts +5 -5
- package/dist/types/components/Tabs/TabList.d.ts +2 -2
- package/dist/types/components/Tabs/TabPanel.d.ts +2 -2
- package/dist/types/components/Tabs/theme.d.ts +1 -1
- package/dist/types/components/Tag/index.d.ts +2 -3
- package/dist/types/components/Tag/styles.d.ts +1 -1
- package/dist/types/components/Tag/theme.d.ts +2 -2
- package/dist/types/components/Text/index.d.ts +2 -2
- package/dist/types/components/Textarea/index.d.ts +1 -1
- package/dist/types/components/TimePicker/index.d.ts +2 -2
- package/dist/types/components/Toast/Growl.d.ts +1 -1
- package/dist/types/components/Toast/Snackbar.d.ts +1 -1
- package/dist/types/components/Toast/ToastWrapper.d.ts +4 -4
- package/dist/types/components/Toast/index.d.ts +5 -5
- package/dist/types/components/Toast/styles.d.ts +10 -10
- package/dist/types/components/Toast/theme.d.ts +1 -1
- package/dist/types/components/Toast/utils.d.ts +13 -13
- package/dist/types/components/Toggle/index.d.ts +2 -2
- package/dist/types/components/Toggle/theme.d.ts +4 -4
- package/dist/types/components/Tooltip/index.d.ts +3 -3
- package/dist/types/components/VariantIcon/index.d.ts +1 -1
- package/dist/types/components/VariantIcon/styles.d.ts +1 -1
- package/dist/types/components/VariantIcon/theme.d.ts +1 -1
- package/dist/types/theme/colors.d.ts +3 -3
- package/dist/types/theme/dark.d.ts +1 -1
- package/dist/types/theme/defaultFields.d.ts +5 -5
- package/dist/types/theme/fonts.d.ts +5 -5
- package/dist/types/theme/index.d.ts +31 -31
- package/dist/types/theme/screens.d.ts +7 -7
- package/dist/types/theme/space.d.ts +9 -9
- package/dist/types/utils/field-styles.d.ts +2 -2
- package/dist/types/utils/index.d.ts +2 -2
- package/dist/types/utils/ts-utils.d.ts +1 -1
- package/dist/types/utils/use-copy-text.d.ts +1 -1
- package/dist/types/utils/use-create-portal.d.ts +1 -1
- package/dist/types/utils/wrap-children.d.ts +1 -1
- package/dist/{use-viewport-CfklieD-.mjs → use-viewport-CWpjoHXy.mjs} +2 -2
- package/dist/utils.mjs +13 -13
- package/dist/wrap-children-CzmhoRzd.mjs +13 -0
- package/package.json +3 -27
- package/dist/LVA2YJMS-DDEmK0pp.mjs +0 -1482
- package/dist/hide-focus-rings-root-BNyva1yb.mjs +0 -14
- package/dist/index-B0gDDiFm.mjs +0 -66
- package/dist/index-B22SHR8h.mjs +0 -26
- package/dist/index-CQD9fgf_.mjs +0 -11
- package/dist/index-CmsWSKKs.mjs +0 -11
- package/dist/index-u1oHKa7X.mjs +0 -16
- package/dist/index-wr_b5GSV.mjs +0 -36
- package/dist/radio-group-RFyDp0KD.mjs +0 -51
- package/dist/wrap-children-aq69jtFP.mjs +0 -12
- package/dist/{downshift.esm-D0ns_SQs.mjs → downshift.esm-B7Jil1wW.mjs} +9 -9
package/dist/Tooltip.mjs
CHANGED
|
@@ -1,52 +1,53 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import { Box as
|
|
5
|
-
import { forwardRef as
|
|
6
|
-
import
|
|
7
|
-
import { c as
|
|
8
|
-
import {
|
|
9
|
-
import { c as
|
|
10
|
-
|
|
2
|
+
import { j as p } from "./jsx-runtime-B7I4PJ0H.mjs";
|
|
3
|
+
import Q, { useRef as U, useEffect as C, useState as Z } from "react";
|
|
4
|
+
import { Box as tt } from "./Box.mjs";
|
|
5
|
+
import { forwardRef as et } from "./System.mjs";
|
|
6
|
+
import F, { css as f, th as y } from "@xstyled/styled-components";
|
|
7
|
+
import { c as ot, d as rt, e as nt, f as it, g as st, h as at } from "./BYC7LY2E-CWSI38FM.mjs";
|
|
8
|
+
import { c as M, a as ut, b as A, d as R } from "./YV4JVR4I-DPC8mMuG.mjs";
|
|
9
|
+
import { A as B, B as $, C as P, t as lt, f as z, c as Y, h as L, _ as X, i as K, D as ct, g as E, d as W, X as H, Y as dt, P as pt, b as w } from "./LVA2YJMS-C-kJ1lkr.mjs";
|
|
10
|
+
import { c as ft } from "./JC64G2H7-afsomHuH.mjs";
|
|
11
|
+
function vt(t = {}) {
|
|
11
12
|
var r;
|
|
12
13
|
process.env.NODE_ENV !== "production" && t.type === "label" && console.warn(
|
|
13
14
|
"The `type` option on the tooltip store is deprecated.",
|
|
14
15
|
"Render a visually hidden label or use the `aria-label` or `aria-labelledby` attributes on the anchor element instead.",
|
|
15
16
|
"See https://ariakit.org/components/tooltip#tooltip-anchors-must-have-accessible-names"
|
|
16
17
|
);
|
|
17
|
-
const o = (r = t.store) == null ? void 0 : r.getState(), e =
|
|
18
|
-
placement:
|
|
18
|
+
const o = (r = t.store) == null ? void 0 : r.getState(), e = ot(B(P({}, t), {
|
|
19
|
+
placement: $(
|
|
19
20
|
t.placement,
|
|
20
21
|
o == null ? void 0 : o.placement,
|
|
21
22
|
"top"
|
|
22
23
|
),
|
|
23
|
-
hideTimeout:
|
|
24
|
-
})),
|
|
25
|
-
type:
|
|
26
|
-
skipTimeout:
|
|
27
|
-
}), i =
|
|
28
|
-
return
|
|
24
|
+
hideTimeout: $(t.hideTimeout, o == null ? void 0 : o.hideTimeout, 0)
|
|
25
|
+
})), v = B(P({}, e.getState()), {
|
|
26
|
+
type: $(t.type, o == null ? void 0 : o.type, "description"),
|
|
27
|
+
skipTimeout: $(t.skipTimeout, o == null ? void 0 : o.skipTimeout, 300)
|
|
28
|
+
}), i = M(v, e, t.store);
|
|
29
|
+
return P(P({}, e), i);
|
|
29
30
|
}
|
|
30
31
|
function mt(t, r, o) {
|
|
31
|
-
return A(t, o, "type"), A(t, o, "skipTimeout"),
|
|
32
|
+
return A(t, o, "type"), A(t, o, "skipTimeout"), rt(t, r, o);
|
|
32
33
|
}
|
|
33
34
|
function ht(t = {}) {
|
|
34
|
-
const [r, o] =
|
|
35
|
+
const [r, o] = ut(vt, t);
|
|
35
36
|
return mt(r, o, t);
|
|
36
37
|
}
|
|
37
|
-
var
|
|
38
|
-
[
|
|
39
|
-
[
|
|
40
|
-
), k =
|
|
38
|
+
var q = lt(
|
|
39
|
+
[it],
|
|
40
|
+
[nt]
|
|
41
|
+
), k = q.useProviderContext, bt = q.ScopedContextProvider, St = "div", gt = Y(
|
|
41
42
|
function(r) {
|
|
42
43
|
var o = r, {
|
|
43
44
|
store: e,
|
|
44
|
-
portal:
|
|
45
|
+
portal: v = !0,
|
|
45
46
|
gutter: i = 8,
|
|
46
47
|
preserveTabOrder: g = !1,
|
|
47
48
|
hideOnHoverOutside: d = !0,
|
|
48
49
|
hideOnInteractOutside: c = !0
|
|
49
|
-
} = o, a =
|
|
50
|
+
} = o, a = X(o, [
|
|
50
51
|
"store",
|
|
51
52
|
"portal",
|
|
52
53
|
"gutter",
|
|
@@ -55,20 +56,20 @@ var X = ut(
|
|
|
55
56
|
"hideOnInteractOutside"
|
|
56
57
|
]);
|
|
57
58
|
const h = k();
|
|
58
|
-
e = e || h,
|
|
59
|
+
e = e || h, K(
|
|
59
60
|
e,
|
|
60
61
|
process.env.NODE_ENV !== "production" && "Tooltip must receive a `store` prop or be wrapped in a TooltipProvider component."
|
|
61
|
-
), a =
|
|
62
|
+
), a = ct(
|
|
62
63
|
a,
|
|
63
|
-
(s) => /* @__PURE__ */
|
|
64
|
+
(s) => /* @__PURE__ */ p.jsx(bt, { value: e, children: s }),
|
|
64
65
|
[e]
|
|
65
66
|
);
|
|
66
67
|
const b = e.useState(
|
|
67
68
|
(s) => s.type === "description" ? "tooltip" : "none"
|
|
68
69
|
);
|
|
69
|
-
return a =
|
|
70
|
+
return a = E({ role: b }, a), a = st(W(E({}, a), {
|
|
70
71
|
store: e,
|
|
71
|
-
portal:
|
|
72
|
+
portal: v,
|
|
72
73
|
gutter: i,
|
|
73
74
|
preserveTabOrder: g,
|
|
74
75
|
hideOnHoverOutside(s) {
|
|
@@ -83,16 +84,16 @@ var X = ut(
|
|
|
83
84
|
}
|
|
84
85
|
})), a;
|
|
85
86
|
}
|
|
86
|
-
),
|
|
87
|
+
), xt = ft(
|
|
87
88
|
z(function(r) {
|
|
88
89
|
const o = gt(r);
|
|
89
90
|
return L(St, o);
|
|
90
91
|
}),
|
|
91
92
|
k
|
|
92
|
-
),
|
|
93
|
+
), Tt = "div", m = M({
|
|
93
94
|
activeStore: null
|
|
94
95
|
});
|
|
95
|
-
function
|
|
96
|
+
function I(t) {
|
|
96
97
|
return () => {
|
|
97
98
|
const { activeStore: r } = m.getState();
|
|
98
99
|
r === t && m.setState("activeStore", null);
|
|
@@ -100,14 +101,14 @@ function N(t) {
|
|
|
100
101
|
}
|
|
101
102
|
var yt = Y(
|
|
102
103
|
function(r) {
|
|
103
|
-
var o = r, { store: e, showOnHover:
|
|
104
|
+
var o = r, { store: e, showOnHover: v = !0 } = o, i = X(o, ["store", "showOnHover"]);
|
|
104
105
|
const g = k();
|
|
105
|
-
e = e || g,
|
|
106
|
+
e = e || g, K(
|
|
106
107
|
e,
|
|
107
108
|
process.env.NODE_ENV !== "production" && "TooltipAnchor must receive a `store` prop or be wrapped in a TooltipProvider component."
|
|
108
109
|
);
|
|
109
|
-
const d =
|
|
110
|
-
C(() =>
|
|
110
|
+
const d = U(!1);
|
|
111
|
+
C(() => R(e, ["mounted"], (n) => {
|
|
111
112
|
n.mounted || (d.current = !1);
|
|
112
113
|
}), [e]), C(() => {
|
|
113
114
|
if (e)
|
|
@@ -115,15 +116,15 @@ var yt = Y(
|
|
|
115
116
|
// Immediately remove the current store from the global store when
|
|
116
117
|
// the component unmounts. This is useful, for example, to avoid
|
|
117
118
|
// showing tooltips immediately on serial tests.
|
|
118
|
-
|
|
119
|
-
|
|
119
|
+
I(e),
|
|
120
|
+
R(e, ["mounted", "skipTimeout"], (n) => {
|
|
120
121
|
if (!e) return;
|
|
121
122
|
if (n.mounted) {
|
|
122
|
-
const { activeStore:
|
|
123
|
-
return
|
|
123
|
+
const { activeStore: x } = m.getState();
|
|
124
|
+
return x !== e && (x == null || x.hide()), m.setState("activeStore", e);
|
|
124
125
|
}
|
|
125
126
|
const l = setTimeout(
|
|
126
|
-
|
|
127
|
+
I(e),
|
|
127
128
|
n.skipTimeout
|
|
128
129
|
);
|
|
129
130
|
return () => clearTimeout(l);
|
|
@@ -142,48 +143,48 @@ var yt = Y(
|
|
|
142
143
|
var l;
|
|
143
144
|
return (l = n.contentElement) == null ? void 0 : l.id;
|
|
144
145
|
});
|
|
145
|
-
return i = W(
|
|
146
|
+
return i = W(E({
|
|
146
147
|
"aria-labelledby": O === "label" ? _ : void 0
|
|
147
148
|
}, i), {
|
|
148
149
|
onMouseEnter: a,
|
|
149
150
|
onFocusVisible: b,
|
|
150
151
|
onBlur: u
|
|
151
|
-
}), i =
|
|
152
|
+
}), i = at(E({
|
|
152
153
|
store: e,
|
|
153
154
|
showOnHover(n) {
|
|
154
|
-
if (!d.current || H(
|
|
155
|
+
if (!d.current || H(v, n)) return !1;
|
|
155
156
|
const { activeStore: l } = m.getState();
|
|
156
157
|
return l ? (e == null || e.show(), !1) : !0;
|
|
157
158
|
}
|
|
158
159
|
}, i)), i;
|
|
159
160
|
}
|
|
160
|
-
),
|
|
161
|
+
), $t = z(function(r) {
|
|
161
162
|
const o = yt(r);
|
|
162
|
-
return L(
|
|
163
|
+
return L(Tt, o);
|
|
163
164
|
});
|
|
164
|
-
const
|
|
165
|
-
|
|
166
|
-
right: "translate3d(4px, 0, 0)",
|
|
165
|
+
const Pt = {
|
|
166
|
+
auto: "translate3d(0, 0, 0)",
|
|
167
167
|
bottom: "translate3d(0, 4px, 0)",
|
|
168
168
|
left: "translate3d(-4px, 0, 0)",
|
|
169
|
-
|
|
170
|
-
|
|
169
|
+
right: "translate3d(4px, 0, 0)",
|
|
170
|
+
top: "translate3d(0, -4px, 0)"
|
|
171
|
+
}, Et = (t) => {
|
|
171
172
|
const r = t == null ? void 0 : t.split("-"), o = r[0];
|
|
172
173
|
if (r.length < 2)
|
|
173
|
-
return
|
|
174
|
+
return Pt[o];
|
|
174
175
|
{
|
|
175
176
|
let e = "0, 0";
|
|
176
177
|
return (t == "right-end" || t == "bottom-end") && (e = "4px, 4px"), (t == "right-start" || t == "top-end") && (e = "4px, -4px"), (t == "left-end" || t == "bottom-start") && (e = "-4px, 4px"), (t == "left-start" || t == "top-start") && (e = "-4px, -4px"), `translate3d(${e}, 0)`;
|
|
177
178
|
}
|
|
178
|
-
}, Ot =
|
|
179
|
+
}, Ot = f`
|
|
179
180
|
visibility: visible;
|
|
180
181
|
opacity: 1;
|
|
181
182
|
transform: translate3d(0, 0, 0);
|
|
182
|
-
`, S = 12,
|
|
183
|
-
const o = r -
|
|
184
|
-
return t.includes("end") ? o ? `${S}px` : `calc(100% - ${
|
|
185
|
-
}, _t =
|
|
186
|
-
({ fixed: t, placement: r, popoverHeight: o, withArrow: e }) =>
|
|
183
|
+
`, S = 12, T = S * 1.5, N = (t) => t.includes("start") ? T : t.includes("end") ? `calc(100% - ${T + "px"})` : "50%", D = (t, r) => {
|
|
184
|
+
const o = r - T < S;
|
|
185
|
+
return t.includes("end") ? o ? `${S}px` : `calc(100% - ${T}px)` : t.includes("start") ? o ? `${S}px` : `${T}px` : "50%";
|
|
186
|
+
}, _t = F.divBox(
|
|
187
|
+
({ fixed: t, placement: r, popoverHeight: o, withArrow: e }) => f`
|
|
187
188
|
${y("tooltips")};
|
|
188
189
|
transition:
|
|
189
190
|
opacity ${y.transition("medium")},
|
|
@@ -194,7 +195,7 @@ const $t = {
|
|
|
194
195
|
transform-origin: top center;
|
|
195
196
|
z-index: 10;
|
|
196
197
|
|
|
197
|
-
${t && e &&
|
|
198
|
+
${t && e && f`
|
|
198
199
|
&::after {
|
|
199
200
|
content: '';
|
|
200
201
|
position: absolute;
|
|
@@ -209,92 +210,95 @@ const $t = {
|
|
|
209
210
|
z-index: 0;
|
|
210
211
|
translate: -50% -50%;
|
|
211
212
|
|
|
212
|
-
${r.includes("top") &&
|
|
213
|
+
${r.includes("top") && f`
|
|
213
214
|
top: 100%;
|
|
214
|
-
left: ${
|
|
215
|
+
left: ${N(r)};
|
|
215
216
|
rotate: 45deg;
|
|
216
217
|
`}
|
|
217
218
|
|
|
218
|
-
${r.includes("bottom") &&
|
|
219
|
+
${r.includes("bottom") && f`
|
|
219
220
|
bottom: 100%;
|
|
220
|
-
left: ${
|
|
221
|
+
left: ${N(r)};
|
|
221
222
|
translate: -50% 50%;
|
|
222
223
|
rotate: 225deg;
|
|
223
224
|
`}
|
|
224
225
|
|
|
225
|
-
${r.includes("left") &&
|
|
226
|
-
top: ${
|
|
226
|
+
${r.includes("left") && f`
|
|
227
|
+
top: ${D(r, o)};
|
|
227
228
|
left: 100%;
|
|
228
229
|
rotate: -45deg;
|
|
229
230
|
`}
|
|
230
231
|
|
|
231
|
-
${r.includes("right") &&
|
|
232
|
-
top: ${
|
|
232
|
+
${r.includes("right") && f`
|
|
233
|
+
top: ${D(r, o)};
|
|
233
234
|
left: 0%;
|
|
234
235
|
rotate: 135deg;
|
|
235
236
|
`}
|
|
236
237
|
}
|
|
237
238
|
`}
|
|
238
239
|
|
|
239
|
-
${t &&
|
|
240
|
-
transform: ${
|
|
240
|
+
${t && f`
|
|
241
|
+
transform: ${Et(r)};
|
|
241
242
|
`}
|
|
242
243
|
|
|
243
244
|
[data-enter] & {
|
|
244
245
|
${Ot}
|
|
245
246
|
}
|
|
246
247
|
`
|
|
247
|
-
), wt =
|
|
248
|
+
), wt = F.div`
|
|
248
249
|
display: inline-block;
|
|
249
|
-
`, Nt =
|
|
250
|
+
`, Nt = et(
|
|
250
251
|
({
|
|
251
252
|
children: t,
|
|
252
253
|
content: r,
|
|
253
254
|
fixed: o = !1,
|
|
254
|
-
|
|
255
|
-
|
|
255
|
+
gutter: e = 8,
|
|
256
|
+
placement: v = o ? "top" : "bottom",
|
|
256
257
|
withArrow: i,
|
|
257
258
|
...g
|
|
258
259
|
}, d) => {
|
|
259
|
-
var
|
|
260
|
-
const c = ht({
|
|
260
|
+
var j;
|
|
261
|
+
const c = ht({ animated: 300, placement: v }), [a, h] = Z({ x: 0, y: 0 }), { render: b, stopAnimation: s } = c, { anchorElement: u, currentPlacement: O, mounted: _, popoverElement: n } = c.useState(), l = () => {
|
|
261
262
|
n && Object.assign(n.style, {
|
|
262
263
|
display: _ ? "block" : "none",
|
|
263
|
-
position: "absolute",
|
|
264
264
|
left: `${a.x}px`,
|
|
265
|
+
position: "absolute",
|
|
265
266
|
top: `${a.y + window.scrollY + 20}px`
|
|
266
267
|
});
|
|
267
|
-
},
|
|
268
|
+
}, x = (j = t == null ? void 0 : t.props) != null && j.disabled ? Q.Children.only(/* @__PURE__ */ p.jsx(wt, { children: t })) : t;
|
|
268
269
|
return C(() => {
|
|
269
|
-
function V({ clientX:
|
|
270
|
-
h({ x:
|
|
270
|
+
function V({ clientX: G, clientY: J }) {
|
|
271
|
+
h({ x: G, y: J }), b();
|
|
271
272
|
}
|
|
272
273
|
if (u && !o)
|
|
273
274
|
return u.addEventListener("mousemove", V), () => {
|
|
274
275
|
u.removeEventListener("mousemove", V);
|
|
275
276
|
};
|
|
276
|
-
}, [b, o, u]), r ? /* @__PURE__ */ p.
|
|
277
|
-
|
|
278
|
-
|
|
279
|
-
|
|
280
|
-
gutter: f,
|
|
281
|
-
ref: d,
|
|
282
|
-
render: /* @__PURE__ */ p.createElement(U, { ...g }),
|
|
283
|
-
store: c,
|
|
284
|
-
updatePosition: o ? void 0 : l
|
|
285
|
-
},
|
|
286
|
-
/* @__PURE__ */ p.createElement(
|
|
287
|
-
_t,
|
|
277
|
+
}, [b, o, u]), r ? /* @__PURE__ */ p.jsxs(p.Fragment, { children: [
|
|
278
|
+
/* @__PURE__ */ p.jsx($t, { render: x, store: c }),
|
|
279
|
+
/* @__PURE__ */ p.jsx(
|
|
280
|
+
xt,
|
|
288
281
|
{
|
|
289
282
|
fixed: o,
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
283
|
+
gutter: e,
|
|
284
|
+
ref: d,
|
|
285
|
+
render: /* @__PURE__ */ p.jsx(tt, { ...g }),
|
|
286
|
+
store: c,
|
|
287
|
+
updatePosition: o ? void 0 : l,
|
|
288
|
+
children: /* @__PURE__ */ p.jsx(
|
|
289
|
+
_t,
|
|
290
|
+
{
|
|
291
|
+
fixed: o,
|
|
292
|
+
onTransitionEnd: s,
|
|
293
|
+
placement: O,
|
|
294
|
+
popoverHeight: n == null ? void 0 : n.getBoundingClientRect().height,
|
|
295
|
+
withArrow: i,
|
|
296
|
+
children: r
|
|
297
|
+
}
|
|
298
|
+
)
|
|
299
|
+
}
|
|
296
300
|
)
|
|
297
|
-
)
|
|
301
|
+
] }) : t;
|
|
298
302
|
}
|
|
299
303
|
);
|
|
300
304
|
export {
|
package/dist/UniversalLink.mjs
CHANGED
|
@@ -1,25 +1,25 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import t from "
|
|
3
|
-
import a from "
|
|
4
|
-
import
|
|
5
|
-
const
|
|
2
|
+
import { j as t } from "./jsx-runtime-B7I4PJ0H.mjs";
|
|
3
|
+
import { shouldForwardProp as s, forwardRef as a } from "./System.mjs";
|
|
4
|
+
import l from "@xstyled/styled-components";
|
|
5
|
+
const d = l.aBox.withConfig({ shouldForwardProp: s })`
|
|
6
6
|
color: inherit;
|
|
7
7
|
text-decoration: none;
|
|
8
|
-
`,
|
|
9
|
-
({ children:
|
|
10
|
-
|
|
8
|
+
`, m = a(
|
|
9
|
+
({ children: r, dataTestId: e, target: o, ...i }, n) => /* @__PURE__ */ t.jsx(
|
|
10
|
+
d,
|
|
11
11
|
{
|
|
12
12
|
color: "inherit",
|
|
13
|
-
"data-testid":
|
|
13
|
+
"data-testid": e,
|
|
14
14
|
ref: n,
|
|
15
|
-
rel:
|
|
16
|
-
target:
|
|
17
|
-
...i
|
|
18
|
-
|
|
19
|
-
|
|
15
|
+
rel: o === "_blank" ? "noopener noreferrer" : void 0,
|
|
16
|
+
target: o,
|
|
17
|
+
...i,
|
|
18
|
+
children: r
|
|
19
|
+
}
|
|
20
20
|
)
|
|
21
21
|
);
|
|
22
|
-
|
|
22
|
+
m.displayName = "UniversalLink";
|
|
23
23
|
export {
|
|
24
|
-
|
|
24
|
+
m as UniversalLink
|
|
25
25
|
};
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { C as t, a as r } from "./P2CTZE2T-
|
|
3
|
-
import { P as a, a as i } from "./MTZPJQMC-
|
|
4
|
-
import {
|
|
2
|
+
import { C as t, a as r } from "./P2CTZE2T-DOT1mNnX.mjs";
|
|
3
|
+
import { P as a, a as i } from "./MTZPJQMC-TybFZCho.mjs";
|
|
4
|
+
import { t as s } from "./LVA2YJMS-C-kJ1lkr.mjs";
|
|
5
5
|
import { createContext as o } from "react";
|
|
6
6
|
o(
|
|
7
7
|
void 0
|
|
@@ -1,8 +1,9 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import { m as Y, o as Z, t as ee, c as te, s as y, d as
|
|
3
|
-
import {
|
|
4
|
-
import { createContext as
|
|
2
|
+
import { m as Y, o as Z, t as ee, c as te, s as y, d as A, e as ne, a as oe, b as P, u as R } from "./YV4JVR4I-DPC8mMuG.mjs";
|
|
3
|
+
import { B as p, A as se, C as ae, G as re, t as T, f as H, _ as F, g as _, c as ie, h as ue, i as le, w as ce, E as S, D as de, d as O, e as me, y as fe } from "./LVA2YJMS-C-kJ1lkr.mjs";
|
|
4
|
+
import { createContext as I, useRef as ve, useState as pe, useMemo as Se } from "react";
|
|
5
5
|
import { r as De } from "./index-CBBbX29m.mjs";
|
|
6
|
+
import { j as M } from "./jsx-runtime-B7I4PJ0H.mjs";
|
|
6
7
|
function Ce(n = {}) {
|
|
7
8
|
const o = Y(
|
|
8
9
|
n.store,
|
|
@@ -24,7 +25,7 @@ function Ce(n = {}) {
|
|
|
24
25
|
}, s = te(r, o);
|
|
25
26
|
return y(
|
|
26
27
|
s,
|
|
27
|
-
() =>
|
|
28
|
+
() => A(s, ["animated", "animating"], (a) => {
|
|
28
29
|
a.animated || s.setState("animating", !1);
|
|
29
30
|
})
|
|
30
31
|
), y(
|
|
@@ -34,7 +35,7 @@ function Ce(n = {}) {
|
|
|
34
35
|
})
|
|
35
36
|
), y(
|
|
36
37
|
s,
|
|
37
|
-
() =>
|
|
38
|
+
() => A(s, ["open", "animating"], (a) => {
|
|
38
39
|
s.setState("mounted", a.open || a.animating);
|
|
39
40
|
})
|
|
40
41
|
), se(ae({}, s), {
|
|
@@ -51,15 +52,15 @@ function Ce(n = {}) {
|
|
|
51
52
|
function xe(n, o, e) {
|
|
52
53
|
return re(o, [e.store, e.disclosure]), P(n, e, "open", "setOpen"), P(n, e, "mounted", "setMounted"), P(n, e, "animated"), Object.assign(n, { disclosure: e.disclosure });
|
|
53
54
|
}
|
|
54
|
-
function
|
|
55
|
+
function He(n = {}) {
|
|
55
56
|
const [o, e] = oe(Ce, n);
|
|
56
57
|
return xe(o, e, n);
|
|
57
58
|
}
|
|
58
|
-
var b =
|
|
59
|
+
var b = T(), N = b.useProviderContext, ge = b.ContextProvider, Ee = b.ScopedContextProvider, D = T(
|
|
59
60
|
[ge],
|
|
60
61
|
[Ee]
|
|
61
|
-
),
|
|
62
|
-
function
|
|
62
|
+
), Fe = D.useScopedContext, Ie = D.useProviderContext, Me = D.ContextProvider, ye = D.ScopedContextProvider, Ne = I(void 0), $e = I(void 0), Pe = "div";
|
|
63
|
+
function w(n, o) {
|
|
63
64
|
const e = setTimeout(o, n);
|
|
64
65
|
return () => clearTimeout(e);
|
|
65
66
|
}
|
|
@@ -69,7 +70,7 @@ function _e(n) {
|
|
|
69
70
|
});
|
|
70
71
|
return () => cancelAnimationFrame(o);
|
|
71
72
|
}
|
|
72
|
-
function
|
|
73
|
+
function V(...n) {
|
|
73
74
|
return n.join(", ").split(", ").reduce((o, e) => {
|
|
74
75
|
const t = e.endsWith("ms") ? 1 : 1e3, i = Number.parseFloat(e || "0s") * t;
|
|
75
76
|
return i > o ? i : o;
|
|
@@ -85,7 +86,7 @@ var he = ie(function(o) {
|
|
|
85
86
|
t,
|
|
86
87
|
process.env.NODE_ENV !== "production" && "DisclosureContent must receive a `store` prop or be wrapped in a DisclosureProvider component."
|
|
87
88
|
);
|
|
88
|
-
const a = ve(null), f = ce(r.id), [l, h] = pe(null), c = t.useState("open"), C = t.useState("mounted"), d = t.useState("animated"), m = t.useState("contentElement"), x =
|
|
89
|
+
const a = ve(null), f = ce(r.id), [l, h] = pe(null), c = t.useState("open"), C = t.useState("mounted"), d = t.useState("animated"), m = t.useState("contentElement"), x = R(t.disclosure, "contentElement");
|
|
89
90
|
S(() => {
|
|
90
91
|
a.current && (t == null || t.setContentElement(a.current));
|
|
91
92
|
}, [t]), S(() => {
|
|
@@ -108,41 +109,41 @@ var he = ie(function(o) {
|
|
|
108
109
|
const u = () => t == null ? void 0 : t.setState("animating", !1), v = () => De.flushSync(u);
|
|
109
110
|
if (l === "leave" && c || l === "enter" && !c) return;
|
|
110
111
|
if (typeof d == "number")
|
|
111
|
-
return
|
|
112
|
+
return w(d, v);
|
|
112
113
|
const {
|
|
113
114
|
transitionDuration: k,
|
|
114
115
|
animationDuration: q,
|
|
115
116
|
transitionDelay: U,
|
|
116
117
|
animationDelay: W
|
|
117
118
|
} = getComputedStyle(m), {
|
|
118
|
-
transitionDuration:
|
|
119
|
-
animationDuration:
|
|
119
|
+
transitionDuration: B = "0",
|
|
120
|
+
animationDuration: G = "0",
|
|
120
121
|
transitionDelay: L = "0",
|
|
121
|
-
animationDelay:
|
|
122
|
-
} = x ? getComputedStyle(x) : {}, J =
|
|
122
|
+
animationDelay: z = "0"
|
|
123
|
+
} = x ? getComputedStyle(x) : {}, J = V(
|
|
123
124
|
U,
|
|
124
125
|
W,
|
|
125
126
|
L,
|
|
126
|
-
|
|
127
|
-
), K =
|
|
127
|
+
z
|
|
128
|
+
), K = V(
|
|
128
129
|
k,
|
|
129
130
|
q,
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
),
|
|
133
|
-
if (!
|
|
131
|
+
B,
|
|
132
|
+
G
|
|
133
|
+
), j = J + K;
|
|
134
|
+
if (!j) {
|
|
134
135
|
l === "enter" && t.setState("animated", !1), u();
|
|
135
136
|
return;
|
|
136
137
|
}
|
|
137
|
-
const Q = 1e3 / 60, X = Math.max(
|
|
138
|
-
return
|
|
138
|
+
const Q = 1e3 / 60, X = Math.max(j - Q, 0);
|
|
139
|
+
return w(X, v);
|
|
139
140
|
}, [t, d, m, x, c, l]), r = de(
|
|
140
141
|
r,
|
|
141
|
-
(u) => /* @__PURE__ */
|
|
142
|
+
(u) => /* @__PURE__ */ M.jsx(ye, { value: t, children: u }),
|
|
142
143
|
[t]
|
|
143
144
|
);
|
|
144
|
-
const g = be(C, r.hidden, i), E = r.style, $ = Se(() => g ?
|
|
145
|
-
return r =
|
|
145
|
+
const g = be(C, r.hidden, i), E = r.style, $ = Se(() => g ? O(_({}, E), { display: "none" }) : E, [g, E]);
|
|
146
|
+
return r = O(_({
|
|
146
147
|
id: f,
|
|
147
148
|
"data-open": c || void 0,
|
|
148
149
|
"data-enter": l === "enter" || void 0,
|
|
@@ -152,33 +153,33 @@ var he = ie(function(o) {
|
|
|
152
153
|
ref: me(f ? t.setContentElement : null, a, r.ref),
|
|
153
154
|
style: $
|
|
154
155
|
}), fe(r);
|
|
155
|
-
}),
|
|
156
|
+
}), je = H(function(o) {
|
|
156
157
|
const e = he(o);
|
|
157
158
|
return ue(Pe, e);
|
|
158
|
-
}),
|
|
159
|
+
}), ke = H(function(o) {
|
|
159
160
|
var e = o, {
|
|
160
161
|
unmountOnHide: t
|
|
161
162
|
} = e, i = F(e, [
|
|
162
163
|
"unmountOnHide"
|
|
163
164
|
]);
|
|
164
165
|
const r = N(), s = i.store || r;
|
|
165
|
-
return
|
|
166
|
+
return R(
|
|
166
167
|
s,
|
|
167
168
|
(f) => !t || (f == null ? void 0 : f.mounted)
|
|
168
|
-
) === !1 ? null : /* @__PURE__ */
|
|
169
|
+
) === !1 ? null : /* @__PURE__ */ M.jsx(je, _({}, i));
|
|
169
170
|
});
|
|
170
171
|
export {
|
|
171
172
|
ye as D,
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
173
|
+
Ie as a,
|
|
174
|
+
Fe as b,
|
|
175
|
+
Me as c,
|
|
176
|
+
ke as d,
|
|
177
|
+
He as e,
|
|
177
178
|
he as f,
|
|
178
179
|
Ce as g,
|
|
179
180
|
xe as h,
|
|
180
181
|
be as i,
|
|
181
|
-
|
|
182
|
-
|
|
182
|
+
Ne as j,
|
|
183
|
+
$e as k,
|
|
183
184
|
N as u
|
|
184
185
|
};
|
package/dist/VariantIcon.mjs
CHANGED
|
@@ -1,32 +1,33 @@
|
|
|
1
1
|
"use client";
|
|
2
|
-
import
|
|
3
|
-
import
|
|
2
|
+
import { j as o } from "./jsx-runtime-B7I4PJ0H.mjs";
|
|
3
|
+
import { useMemo as l } from "react";
|
|
4
4
|
import "./Icon.mjs";
|
|
5
|
-
import { P as
|
|
6
|
-
import { forwardRef as
|
|
7
|
-
|
|
8
|
-
|
|
5
|
+
import { P as c, C as u, I as m, A as i, S as a, a as x } from "./index-C_k-m0Rl.mjs";
|
|
6
|
+
import { forwardRef as I } from "./System.mjs";
|
|
7
|
+
import p, { th as d, css as j } from "@xstyled/styled-components";
|
|
8
|
+
const h = p.divBox(
|
|
9
|
+
({ variant: e }) => j`
|
|
9
10
|
display: inline-flex;
|
|
10
|
-
${
|
|
11
|
+
${d(`variantIcon.${e}`)}
|
|
11
12
|
flex-shrink: 0;
|
|
12
13
|
align-self: center;
|
|
13
14
|
`
|
|
14
|
-
),
|
|
15
|
-
({ icon:
|
|
16
|
-
const
|
|
17
|
-
if (
|
|
18
|
-
if (
|
|
19
|
-
if (
|
|
20
|
-
if (
|
|
21
|
-
if (
|
|
22
|
-
if (
|
|
23
|
-
if (
|
|
24
|
-
if (
|
|
25
|
-
}, [
|
|
26
|
-
return
|
|
15
|
+
), g = I(
|
|
16
|
+
({ icon: e, size: n = "md", variant: r, ...s }, f) => {
|
|
17
|
+
const t = l(() => {
|
|
18
|
+
if (e === null) return null;
|
|
19
|
+
if (e) return e;
|
|
20
|
+
if (r === "default") return /* @__PURE__ */ o.jsx(c, { size: n });
|
|
21
|
+
if (r === "success") return /* @__PURE__ */ o.jsx(u, { size: n });
|
|
22
|
+
if (r === "info") return /* @__PURE__ */ o.jsx(m, { size: n });
|
|
23
|
+
if (r === "warning") return /* @__PURE__ */ o.jsx(i, { size: n });
|
|
24
|
+
if (r === "danger") return /* @__PURE__ */ o.jsx(a, { size: n });
|
|
25
|
+
if (r === "ai") return /* @__PURE__ */ o.jsx(x, { size: n });
|
|
26
|
+
}, [n, e, r]);
|
|
27
|
+
return t ? /* @__PURE__ */ o.jsx(h, { ref: f, variant: r, ...s, children: t }) : null;
|
|
27
28
|
}
|
|
28
29
|
);
|
|
29
|
-
|
|
30
|
+
g.displayName = "VariantIcon";
|
|
30
31
|
export {
|
|
31
|
-
|
|
32
|
+
g as VariantIcon
|
|
32
33
|
};
|