@koide-labs/ui 0.0.15 → 0.1.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/-utils.d.ts +2 -2
- package/dist/-utils.js +1 -1
- package/dist/{Button-DrPFFzo7.js → Button-BmcVHRRW.js} +2 -2
- package/dist/{CompositeRoot-CVk5a-pR.js → CompositeRoot-CCgh2M64.js} +6 -6
- package/dist/{FloatingPortal-tWyuKRSN.js → FloatingPortal-BQsQhvIr.js} +27 -27
- package/dist/{FloatingPortalLite-DVyq6YhV.js → FloatingPortalLite-_ECdFE7b.js} +1 -1
- package/dist/{InternalBackdrop-jYAiOJ8v.js → InternalBackdrop-BSMKU-hc.js} +13 -13
- package/dist/{LabelableContext-BMvjVwor.js → LabelableContext-Be1u-eFg.js} +2 -2
- package/dist/accordion.css +1 -0
- package/dist/alert-dialog.css +1 -0
- package/dist/anchor.css +1 -0
- package/dist/avatar.css +1 -0
- package/dist/badge.css +1 -0
- package/dist/button.css +1 -0
- package/dist/checkbox.css +1 -0
- package/dist/code.css +1 -0
- package/dist/collapse.css +1 -0
- package/dist/command.css +1 -0
- package/dist/components/accordion/accordion.d.ts +19 -0
- package/dist/components/accordion/accordion.js +701 -0
- package/dist/components/accordion/index.d.ts +1 -12
- package/dist/components/accordion/index.js +2 -697
- package/dist/components/alert-dialog/alert-dialog.d.ts +36 -0
- package/dist/components/alert-dialog/alert-dialog.js +138 -0
- package/dist/components/alert-dialog/index.d.ts +1 -26
- package/dist/components/alert-dialog/index.js +2 -134
- package/dist/components/anchor/anchor.d.ts +12 -0
- package/dist/components/anchor/anchor.js +21 -0
- package/dist/components/anchor/index.d.ts +1 -8
- package/dist/components/anchor/index.js +2 -19
- package/dist/components/avatar/avatar.d.ts +25 -0
- package/dist/components/avatar/avatar.js +161 -0
- package/dist/components/avatar/index.d.ts +1 -21
- package/dist/components/avatar/index.js +2 -159
- package/dist/components/badge/badge.d.ts +20 -0
- package/dist/components/badge/badge.js +42 -0
- package/dist/components/badge/index.d.ts +1 -16
- package/dist/components/badge/index.js +2 -40
- package/dist/components/button/button.d.ts +27 -0
- package/dist/components/button/button.js +47 -0
- package/dist/components/button/index.d.ts +1 -24
- package/dist/components/button/index.js +2 -45
- package/dist/components/checkbox/checkbox.d.ts +13 -0
- package/dist/components/checkbox/checkbox.js +269 -0
- package/dist/components/checkbox/index.d.ts +1 -9
- package/dist/components/checkbox/index.js +2 -267
- package/dist/components/code/code.d.ts +13 -0
- package/dist/components/code/code.js +1206 -0
- package/dist/components/code/index.d.ts +1 -9
- package/dist/components/code/index.js +2 -1204
- package/dist/components/collapse/collapse.d.ts +14 -0
- package/dist/components/collapse/collapse.js +35 -0
- package/dist/components/collapse/index.d.ts +1 -11
- package/dist/components/collapse/index.js +2 -33
- package/dist/components/command/command.d.ts +36 -0
- package/dist/components/command/command.js +1695 -0
- package/dist/components/command/index.d.ts +1 -15
- package/dist/components/command/index.js +2 -1693
- package/dist/components/context-menu/context-menu.d.ts +82 -0
- package/dist/components/context-menu/context-menu.js +1445 -0
- package/dist/components/context-menu/index.d.ts +1 -42
- package/dist/components/context-menu/index.js +2 -1442
- package/dist/components/dialog/dialog.d.ts +22 -0
- package/dist/components/dialog/dialog.js +140 -0
- package/dist/components/dialog/dialog.types.d.ts +38 -0
- package/dist/components/dialog/index.d.ts +1 -48
- package/dist/components/dialog/index.js +2 -136
- package/dist/components/heading/heading.d.ts +25 -0
- package/dist/components/heading/heading.js +36 -0
- package/dist/components/heading/index.d.ts +1 -44
- package/dist/components/heading/index.js +2 -49
- package/dist/components/icon/icon.d.ts +28 -0
- package/dist/components/icon/icon.js +43 -0
- package/dist/components/icon/{icon-names.d.ts → icon.types.d.ts} +4 -0
- package/dist/components/icon/icon.types.js +1 -0
- package/dist/components/icon/index.d.ts +2 -24
- package/dist/components/icon/index.js +2 -41
- package/dist/components/icon-button/icon-button.d.ts +16 -0
- package/dist/components/icon-button/icon-button.js +46 -0
- package/dist/components/icon-button/index.d.ts +1 -12
- package/dist/components/icon-button/index.js +2 -44
- package/dist/components/inline-code/index.d.ts +1 -6
- package/dist/components/inline-code/index.js +2 -20
- package/dist/components/inline-code/inline-code.d.ts +10 -0
- package/dist/components/inline-code/inline-code.js +25 -0
- package/dist/components/input/index.d.ts +1 -3
- package/dist/components/input/index.js +2 -117
- package/dist/components/input/input.d.ts +9 -0
- package/dist/components/input/input.js +126 -0
- package/dist/components/meter/index.d.ts +1 -18
- package/dist/components/meter/index.js +2 -163
- package/dist/components/meter/meter.d.ts +22 -0
- package/dist/components/meter/meter.js +165 -0
- package/dist/components/multiline-input/index.d.ts +1 -6
- package/dist/components/multiline-input/index.js +2 -98
- package/dist/components/multiline-input/multiline-input.d.ts +10 -0
- package/dist/components/multiline-input/multiline-input.js +100 -0
- package/dist/components/number-input/index.d.ts +1 -10
- package/dist/components/number-input/index.js +2 -1167
- package/dist/components/number-input/number-input.d.ts +14 -0
- package/dist/components/number-input/number-input.js +1169 -0
- package/dist/components/password-input/index.d.ts +1 -2
- package/dist/components/password-input/index.js +2 -27
- package/dist/components/password-input/password-input.d.ts +7 -0
- package/dist/components/password-input/password-input.js +29 -0
- package/dist/components/pill/index.d.ts +1 -13
- package/dist/components/pill/index.js +2 -36
- package/dist/components/pill/pill.d.ts +17 -0
- package/dist/components/pill/pill.js +38 -0
- package/dist/components/popover/index.d.ts +1 -21
- package/dist/components/popover/index.js +2 -634
- package/dist/components/popover/popover.d.ts +22 -0
- package/dist/components/popover/popover.js +634 -0
- package/dist/components/preview-card/index.d.ts +1 -17
- package/dist/components/preview-card/index.js +2 -400
- package/dist/components/preview-card/preview-card.d.ts +21 -0
- package/dist/components/preview-card/preview-card.js +402 -0
- package/dist/components/radio-group/index.d.ts +1 -0
- package/dist/components/radio-group/index.js +5 -0
- package/dist/components/radio-group/radio-group.d.ts +25 -0
- package/dist/components/{radio/index.js → radio-group/radio-group.js} +91 -90
- package/dist/components/search-bar/index.d.ts +1 -12
- package/dist/components/search-bar/index.js +2 -46
- package/dist/components/search-bar/search-bar.d.ts +16 -0
- package/dist/components/search-bar/search-bar.js +43 -0
- package/dist/components/select/index.d.ts +1 -16
- package/dist/components/select/index.js +2 -1261
- package/dist/components/select/select.d.ts +22 -0
- package/dist/components/select/select.js +1263 -0
- package/dist/components/separator/index.d.ts +1 -7
- package/dist/components/separator/index.js +2 -4
- package/dist/components/separator/separator.d.ts +10 -0
- package/dist/components/separator/separator.js +6 -0
- package/dist/components/slider/index.d.ts +1 -5
- package/dist/components/slider/index.js +2 -900
- package/dist/components/slider/slider.d.ts +10 -0
- package/dist/components/slider/slider.js +899 -0
- package/dist/components/spinner/index.d.ts +1 -2
- package/dist/components/spinner/index.js +2 -11
- package/dist/components/spinner/spinner.d.ts +7 -0
- package/dist/components/spinner/spinner.js +13 -0
- package/dist/components/stacked-avatars/index.d.ts +1 -14
- package/dist/components/stacked-avatars/index.js +2 -90
- package/dist/components/stacked-avatars/stacked-avatars.d.ts +18 -0
- package/dist/components/stacked-avatars/stacked-avatars.js +92 -0
- package/dist/components/status-banner/index.d.ts +1 -17
- package/dist/components/status-banner/index.js +2 -69
- package/dist/components/status-banner/status-banner.d.ts +22 -0
- package/dist/components/status-banner/status-banner.js +71 -0
- package/dist/components/surface/index.d.ts +2 -27
- package/dist/components/surface/index.js +2 -39
- package/dist/components/surface/surface.d.ts +26 -0
- package/dist/components/surface/surface.js +36 -0
- package/dist/components/surface/surface.types.d.ts +1 -0
- package/dist/components/surface/surface.types.js +1 -0
- package/dist/components/switch/index.d.ts +1 -5
- package/dist/components/switch/index.js +2 -194
- package/dist/components/switch/switch.d.ts +10 -0
- package/dist/components/switch/switch.js +193 -0
- package/dist/components/tabs/index.d.ts +1 -18
- package/dist/components/tabs/index.js +2 -507
- package/dist/components/tabs/tabs.d.ts +28 -0
- package/dist/components/tabs/tabs.js +511 -0
- package/dist/components/text/index.d.ts +1 -26
- package/dist/components/text/index.js +2 -46
- package/dist/components/text/text.d.ts +29 -0
- package/dist/components/text/text.js +48 -0
- package/dist/components/theme-provider/index.d.ts +1 -1
- package/dist/components/theme-provider/theme-provider.d.ts +8 -4
- package/dist/components/theme-provider/theme-provider.js +3 -3
- package/dist/components/timestamp/index.d.ts +1 -23
- package/dist/components/timestamp/index.js +2 -1390
- package/dist/components/timestamp/timestamp.d.ts +26 -0
- package/dist/components/timestamp/timestamp.js +1391 -0
- package/dist/components/toaster/index.d.ts +2 -0
- package/dist/components/toaster/index.js +7 -0
- package/dist/components/toaster/toaster.d.ts +7 -0
- package/dist/components/toaster/toaster.js +923 -0
- package/dist/components/{toast → toaster}/use-toast-manager.d.ts +3 -3
- package/dist/components/tooltip/index.d.ts +1 -14
- package/dist/components/tooltip/index.js +2 -710
- package/dist/components/tooltip/tooltip.d.ts +24 -0
- package/dist/components/tooltip/tooltip.js +9 -0
- package/dist/components/view/index.d.ts +2 -30
- package/dist/components/view/index.js +2 -79
- package/dist/components/view/view.d.ts +31 -0
- package/dist/components/view/view.js +83 -0
- package/dist/components/view/view.types.d.ts +5 -0
- package/dist/components/view/view.types.js +1 -0
- package/dist/components/visually-hidden/index.d.ts +5 -1
- package/dist/{composite-Bx7Szd_T.js → composite-BZzP-LlG.js} +3 -3
- package/dist/{composite-C9L5QmZL.js → composite-BwEK5cWH.js} +1 -1
- package/dist/context-menu.css +1 -0
- package/dist/{createBaseUIEventDetails-D8M2Yl-a.js → createBaseUIEventDetails-CCSfZ2vM.js} +7 -7
- package/dist/{detectBrowser-I-s3yzIE.js → detectBrowser-Bl8Ki_1I.js} +2 -2
- package/dist/dialog.css +1 -1
- package/dist/{dialog.module-BeF-6XAo.js → dialog.module-DsbQRp-d.js} +55 -55
- package/dist/{element-CZEOj04G.js → element-u5WgOZX1.js} +7 -7
- package/dist/{event-CKoGyQEJ.js → event-B89-Ng5h.js} +4 -4
- package/dist/{floating-ui.utils-C7pRWMZ_.js → floating-ui.utils-DUVaIF3G.js} +7 -7
- package/dist/{floating-ui.utils.dom-C7FS5id0.js → floating-ui.utils.dom-cbi420Pg.js} +4 -4
- package/dist/{getDisabledMountTransitionStyles-YfHPge6T.js → getDisabledMountTransitionStyles-E2x-_lte.js} +7 -7
- package/dist/heading.css +1 -0
- package/dist/icon-button.css +1 -0
- package/dist/icon.css +1 -0
- package/dist/index.d.ts +10 -10
- package/dist/index.js +86 -104
- package/dist/{inertValue-BCYGsdmf.js → inertValue-BTpPjX30.js} +1 -1
- package/dist/inline-code.css +1 -0
- package/dist/input.css +1 -1
- package/dist/input.module-CtE19OH8.js +8 -0
- package/dist/integrations/react-markdown/index.js +12 -12
- package/dist/meter.css +1 -0
- package/dist/number-input.css +1 -0
- package/dist/password-input.css +1 -0
- package/dist/pill.css +1 -0
- package/dist/popover.css +1 -0
- package/dist/preview-card.css +1 -0
- package/dist/radio-group.css +1 -0
- package/dist/safePolygon-DnkzOIur.js +558 -0
- package/dist/search-bar.css +1 -0
- package/dist/select.css +1 -0
- package/dist/{index-DVjyPAD4.js → separator-fh_wDZNf.js} +7 -11
- package/dist/separator.css +1 -0
- package/dist/slider.css +1 -0
- package/dist/spinner.css +1 -0
- package/dist/stacked-avatars.css +1 -0
- package/dist/status-banner.css +1 -0
- package/dist/styles/core.css +1 -1
- package/dist/surface.css +1 -0
- package/dist/switch.css +1 -0
- package/dist/tabs.css +1 -0
- package/dist/text.css +1 -0
- package/dist/timestamp.css +1 -0
- package/dist/toaster.css +1 -0
- package/dist/tooltip-oCp-elli.js +765 -0
- package/dist/tooltip.css +1 -0
- package/dist/transitions.css +1 -1
- package/dist/{transitions.module-CWX8e5cx.js → transitions.module-D9mMAtfI.js} +11 -11
- package/dist/{useAnimationFrame-451ugS_6.js → useAnimationFrame-DvK1s63A.js} +1 -1
- package/dist/{useButton-DfIwsdb8.js → useButton-d3_JgBNr.js} +3 -3
- package/dist/{useCompositeListItem-OkcAim_1.js → useCompositeListItem-CZp9WTnF.js} +2 -2
- package/dist/{useLabelableId-Ci_jDvmv.js → useLabelableId-CX4tcfzK.js} +3 -3
- package/dist/{useOpenChangeComplete-Dse9kY9E.js → useOpenChangeComplete-BHd-N7Ig.js} +5 -5
- package/dist/{useRender-CLx7dR_1.js → useRender-C3vlzS3t.js} +1 -1
- package/dist/{useRenderElement-DwToLA61.js → useRenderElement-DngNDu_P.js} +2 -2
- package/dist/{useRole-oDBdbuwQ.js → useRole-BD3OL1rr.js} +3 -3
- package/dist/{useStableCallback-CkTrVkNX.js → useStableCallback-DKZHlUAT.js} +1 -1
- package/dist/{useSyncedFloatingRootContext-Dorsv-jf.js → useSyncedFloatingRootContext-BB1vwkV-.js} +20 -20
- package/dist/{useTimeout-CflX-kz3.js → useTimeout-BNni6aw5.js} +1 -1
- package/dist/{useTransitionStatus-CUfcuGAV.js → useTransitionStatus-CmMyUh74.js} +1 -1
- package/dist/{useTypeahead-D85V2IUx.js → useTypeahead-BiL5IAVb.js} +11 -11
- package/dist/{useValueAsRef-HURLzret.js → useValueAsRef-B4EriRsI.js} +1 -1
- package/dist/{useValueChanged-DL757-yD.js → useValueChanged-MJRmEWz1.js} +1 -1
- package/dist/view.css +1 -1
- package/dist/view.module-Dj7wj0kk.js +6 -0
- package/dist/view2.css +1 -0
- package/package.json +1 -1
- package/dist/components/radio/index.d.ts +0 -13
- package/dist/components/toast/index.d.ts +0 -2
- package/dist/components/toast/index.js +0 -8
- package/dist/components/toast/toast.d.ts +0 -2
- package/dist/components/toast/toast.js +0 -921
- package/dist/components/tooltip/tooltip-arrow.d.ts +0 -3
- package/dist/components/tooltip/tooltip-arrow.js +0 -6
- package/dist/index10.css +0 -1
- package/dist/index11.css +0 -1
- package/dist/index12.css +0 -1
- package/dist/index13.css +0 -1
- package/dist/index14.css +0 -1
- package/dist/index15.css +0 -1
- package/dist/index16.css +0 -1
- package/dist/index17.css +0 -1
- package/dist/index18.css +0 -1
- package/dist/index19.css +0 -1
- package/dist/index20.css +0 -1
- package/dist/index21.css +0 -1
- package/dist/index22.css +0 -1
- package/dist/index23.css +0 -1
- package/dist/index24.css +0 -1
- package/dist/index25.css +0 -1
- package/dist/index26.css +0 -1
- package/dist/index27.css +0 -1
- package/dist/index28.css +0 -1
- package/dist/index29.css +0 -1
- package/dist/index3.css +0 -1
- package/dist/index30.css +0 -1
- package/dist/index31.css +0 -1
- package/dist/index32.css +0 -1
- package/dist/index33.css +0 -1
- package/dist/index34.css +0 -1
- package/dist/index35.css +0 -1
- package/dist/index36.css +0 -1
- package/dist/index37.css +0 -1
- package/dist/index4.css +0 -1
- package/dist/index5.css +0 -1
- package/dist/index6.css +0 -1
- package/dist/index7.css +0 -1
- package/dist/index8.css +0 -1
- package/dist/index9.css +0 -1
- package/dist/input.module-DDQY_Ij6.js +0 -7
- package/dist/safePolygon-DWy1dGKJ.js +0 -308
- package/dist/toast.css +0 -1
- package/dist/tooltip-arrow-cs6vjjqZ.js +0 -24
- package/dist/tooltip-arrow.css +0 -1
- package/dist/useHoverReferenceInteraction-SfOBPoXM.js +0 -264
- package/dist/usePopupAutoResize-CNR6Ekmx.js +0 -85
- package/dist/view.module-DfDLgJE0.js +0 -6
- /package/dist/components/{icon/icon-names.js → dialog/dialog.types.js} +0 -0
- /package/dist/components/{toast → toaster}/use-toast-manager.js +0 -0
|
@@ -1,20 +1,20 @@
|
|
|
1
1
|
import * as s from "react";
|
|
2
|
-
import { u as
|
|
3
|
-
import { u as
|
|
4
|
-
import { c as U, i as J, d as Q } from "./createBaseUIEventDetails-
|
|
5
|
-
import { u as X, a as Z, b as ee, p as te, c as oe, d as ne } from "./useSyncedFloatingRootContext-
|
|
6
|
-
import { u as se } from "./useRole-
|
|
7
|
-
import { d as re, e as
|
|
8
|
-
import {
|
|
9
|
-
import { u as P } from "./useRenderElement-
|
|
10
|
-
import { t as
|
|
11
|
-
import { u as
|
|
2
|
+
import { u as H } from "./useStableCallback-DKZHlUAT.js";
|
|
3
|
+
import { u as Y, a as $, F as q, I as z, b as A } from "./InternalBackdrop-BSMKU-hc.js";
|
|
4
|
+
import { c as U, i as J, d as Q } from "./createBaseUIEventDetails-CCSfZ2vM.js";
|
|
5
|
+
import { u as X, a as Z, b as ee, p as te, c as oe, d as ne } from "./useSyncedFloatingRootContext-BB1vwkV-.js";
|
|
6
|
+
import { u as se } from "./useRole-BD3OL1rr.js";
|
|
7
|
+
import { d as re, e as K, R as ie, P as ae, c as S, p as W, C as w, f as le } from "./transitions.module-D9mMAtfI.js";
|
|
8
|
+
import { h as ce, f as de } from "./element-u5WgOZX1.js";
|
|
9
|
+
import { u as P } from "./useRenderElement-DngNDu_P.js";
|
|
10
|
+
import { t as j, u as pe } from "./useOpenChangeComplete-BHd-N7Ig.js";
|
|
11
|
+
import { u as G } from "./useButton-d3_JgBNr.js";
|
|
12
12
|
import { u as B } from "./useBaseUiId-B7WyxtIE.js";
|
|
13
|
-
import { C as ue } from "./composite-
|
|
13
|
+
import { C as ue } from "./composite-BwEK5cWH.js";
|
|
14
14
|
import { jsx as M, jsxs as ge } from "react/jsx-runtime";
|
|
15
|
-
import { i as fe } from "./inertValue-
|
|
15
|
+
import { i as fe } from "./inertValue-BTpPjX30.js";
|
|
16
16
|
import { f as F } from "./formatErrorMessage-BqPuTBN-.js";
|
|
17
|
-
import { h as me, C as _e } from "./FloatingPortal-
|
|
17
|
+
import { h as me, C as _e } from "./FloatingPortal-BQsQhvIr.js";
|
|
18
18
|
import './dialog.css';function ot(t) {
|
|
19
19
|
const {
|
|
20
20
|
store: e,
|
|
@@ -23,14 +23,14 @@ import './dialog.css';function ot(t) {
|
|
|
23
23
|
} = t, i = e.useState("open"), r = e.useState("disablePointerDismissal"), l = e.useState("modal"), a = e.useState("popupElement"), {
|
|
24
24
|
openMethod: o,
|
|
25
25
|
triggerProps: p,
|
|
26
|
-
reset:
|
|
27
|
-
} =
|
|
26
|
+
reset: C
|
|
27
|
+
} = Y(i);
|
|
28
28
|
X(e);
|
|
29
29
|
const {
|
|
30
30
|
forceUnmount: u
|
|
31
31
|
} = Z(i, e, () => {
|
|
32
|
-
|
|
33
|
-
}), c =
|
|
32
|
+
C();
|
|
33
|
+
}), c = H((f) => {
|
|
34
34
|
const E = U(f);
|
|
35
35
|
return E.preventUnmountOnClose = () => {
|
|
36
36
|
e.set("preventUnmountingOnClose", !0);
|
|
@@ -47,7 +47,7 @@ import './dialog.css';function ot(t) {
|
|
|
47
47
|
onOpenChange: e.setOpen,
|
|
48
48
|
treatPopupAsFloatingElement: !0,
|
|
49
49
|
noEmit: !0
|
|
50
|
-
}), [_, D] = s.useState(0),
|
|
50
|
+
}), [_, D] = s.useState(0), h = _ === 0, x = se(g), v = re(g, {
|
|
51
51
|
outsidePressEvent() {
|
|
52
52
|
return e.context.internalBackdropRef.current || e.context.backdropRef.current ? "intentional" : {
|
|
53
53
|
mouse: l === "trap-focus" ? "sloppy" : "intentional",
|
|
@@ -58,20 +58,20 @@ import './dialog.css';function ot(t) {
|
|
|
58
58
|
if ("button" in f && f.button !== 0 || "touches" in f && f.touches.length !== 1)
|
|
59
59
|
return !1;
|
|
60
60
|
const E = ce(f);
|
|
61
|
-
if (
|
|
61
|
+
if (h && !r) {
|
|
62
62
|
const T = E;
|
|
63
63
|
return l && (e.context.internalBackdropRef.current || e.context.backdropRef.current) ? e.context.internalBackdropRef.current === T || e.context.backdropRef.current === T || de(T, a) && !T?.hasAttribute("data-base-ui-portal") : !0;
|
|
64
64
|
}
|
|
65
65
|
return !1;
|
|
66
66
|
},
|
|
67
|
-
escapeKey:
|
|
67
|
+
escapeKey: h
|
|
68
68
|
});
|
|
69
|
-
|
|
69
|
+
$(i && l === !0, a);
|
|
70
70
|
const {
|
|
71
71
|
getReferenceProps: R,
|
|
72
72
|
getFloatingProps: O,
|
|
73
73
|
getTriggerProps: I
|
|
74
|
-
} =
|
|
74
|
+
} = K([x, v]);
|
|
75
75
|
e.useContextCallback("onNestedDialogOpen", (f) => {
|
|
76
76
|
D(f + 1);
|
|
77
77
|
}), e.useContextCallback("onNestedDialogClose", () => {
|
|
@@ -89,15 +89,15 @@ import './dialog.css';function ot(t) {
|
|
|
89
89
|
nestedOpenDialogCount: _
|
|
90
90
|
});
|
|
91
91
|
}
|
|
92
|
-
const
|
|
93
|
-
process.env.NODE_ENV !== "production" && (
|
|
92
|
+
const L = /* @__PURE__ */ s.createContext(void 0);
|
|
93
|
+
process.env.NODE_ENV !== "production" && (L.displayName = "DialogRootContext");
|
|
94
94
|
function N(t) {
|
|
95
|
-
const e = s.useContext(
|
|
95
|
+
const e = s.useContext(L);
|
|
96
96
|
if (t === !1 && e === void 0)
|
|
97
97
|
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: DialogRootContext is missing. Dialog parts must be placed within <Dialog.Root>." : F(27));
|
|
98
98
|
return e;
|
|
99
99
|
}
|
|
100
|
-
const
|
|
100
|
+
const Ce = {
|
|
101
101
|
...te,
|
|
102
102
|
modal: S((t) => t.modal),
|
|
103
103
|
nested: S((t) => t.nested),
|
|
@@ -111,14 +111,14 @@ const he = {
|
|
|
111
111
|
};
|
|
112
112
|
class nt extends ie {
|
|
113
113
|
constructor(e) {
|
|
114
|
-
super(
|
|
114
|
+
super(he(e), {
|
|
115
115
|
popupRef: /* @__PURE__ */ s.createRef(),
|
|
116
116
|
backdropRef: /* @__PURE__ */ s.createRef(),
|
|
117
117
|
internalBackdropRef: /* @__PURE__ */ s.createRef(),
|
|
118
118
|
triggerElements: new ae(),
|
|
119
119
|
onOpenChange: void 0,
|
|
120
120
|
onOpenChangeComplete: void 0
|
|
121
|
-
},
|
|
121
|
+
}, Ce);
|
|
122
122
|
}
|
|
123
123
|
setOpen = (e, n) => {
|
|
124
124
|
if (n.preventUnmountOnClose = () => {
|
|
@@ -138,7 +138,7 @@ class nt extends ie {
|
|
|
138
138
|
(r || e) && (i.activeTriggerId = r, i.activeTriggerElement = n.trigger ?? null), this.update(i);
|
|
139
139
|
};
|
|
140
140
|
}
|
|
141
|
-
function
|
|
141
|
+
function he(t = {}) {
|
|
142
142
|
return {
|
|
143
143
|
...oe(),
|
|
144
144
|
modal: !0,
|
|
@@ -155,8 +155,8 @@ function Ce(t = {}) {
|
|
|
155
155
|
};
|
|
156
156
|
}
|
|
157
157
|
const Ee = {
|
|
158
|
-
...
|
|
159
|
-
...
|
|
158
|
+
...W,
|
|
159
|
+
...j
|
|
160
160
|
}, Se = /* @__PURE__ */ s.forwardRef(function(e, n) {
|
|
161
161
|
const {
|
|
162
162
|
render: d,
|
|
@@ -165,7 +165,7 @@ const Ee = {
|
|
|
165
165
|
...l
|
|
166
166
|
} = e, {
|
|
167
167
|
store: a
|
|
168
|
-
} = N(), o = a.useState("open"), p = a.useState("nested"),
|
|
168
|
+
} = N(), o = a.useState("open"), p = a.useState("nested"), C = a.useState("mounted"), u = a.useState("transitionStatus"), c = s.useMemo(() => ({
|
|
169
169
|
open: o,
|
|
170
170
|
transitionStatus: u
|
|
171
171
|
}), [o, u]);
|
|
@@ -175,7 +175,7 @@ const Ee = {
|
|
|
175
175
|
stateAttributesMapping: Ee,
|
|
176
176
|
props: [{
|
|
177
177
|
role: "presentation",
|
|
178
|
-
hidden: !
|
|
178
|
+
hidden: !C,
|
|
179
179
|
style: {
|
|
180
180
|
userSelect: "none",
|
|
181
181
|
WebkitUserSelect: "none"
|
|
@@ -195,13 +195,13 @@ const De = /* @__PURE__ */ s.forwardRef(function(e, n) {
|
|
|
195
195
|
} = e, {
|
|
196
196
|
store: o
|
|
197
197
|
} = N(), p = o.useState("open");
|
|
198
|
-
function
|
|
198
|
+
function C(g) {
|
|
199
199
|
p && o.setOpen(!1, U(Q, g.nativeEvent));
|
|
200
200
|
}
|
|
201
201
|
const {
|
|
202
202
|
getButtonProps: u,
|
|
203
203
|
buttonRef: c
|
|
204
|
-
} =
|
|
204
|
+
} = G({
|
|
205
205
|
disabled: r,
|
|
206
206
|
native: l
|
|
207
207
|
}), m = s.useMemo(() => ({
|
|
@@ -211,7 +211,7 @@ const De = /* @__PURE__ */ s.forwardRef(function(e, n) {
|
|
|
211
211
|
state: m,
|
|
212
212
|
ref: [n, c],
|
|
213
213
|
props: [{
|
|
214
|
-
onClick:
|
|
214
|
+
onClick: C
|
|
215
215
|
}, a, u]
|
|
216
216
|
});
|
|
217
217
|
});
|
|
@@ -247,8 +247,8 @@ function Ie() {
|
|
|
247
247
|
return t;
|
|
248
248
|
}
|
|
249
249
|
const be = {
|
|
250
|
-
...K,
|
|
251
250
|
...W,
|
|
251
|
+
...j,
|
|
252
252
|
nestedDialogOpen(t) {
|
|
253
253
|
return t ? {
|
|
254
254
|
[Oe.nestedDialogOpen]: ""
|
|
@@ -263,23 +263,23 @@ const be = {
|
|
|
263
263
|
...a
|
|
264
264
|
} = e, {
|
|
265
265
|
store: o
|
|
266
|
-
} = N(), p = o.useState("descriptionElementId"),
|
|
266
|
+
} = N(), p = o.useState("descriptionElementId"), C = o.useState("disablePointerDismissal"), u = o.useState("floatingRootContext"), c = o.useState("popupProps"), m = o.useState("modal"), g = o.useState("mounted"), _ = o.useState("nested"), D = o.useState("nestedOpenDialogCount"), h = o.useState("open"), x = o.useState("openMethod"), v = o.useState("titleElementId"), R = o.useState("transitionStatus"), O = o.useState("role");
|
|
267
267
|
Ie(), pe({
|
|
268
|
-
open:
|
|
268
|
+
open: h,
|
|
269
269
|
ref: o.context.popupRef,
|
|
270
270
|
onComplete() {
|
|
271
|
-
|
|
271
|
+
h && o.context.onOpenChangeComplete?.(!0);
|
|
272
272
|
}
|
|
273
273
|
});
|
|
274
274
|
function I(E) {
|
|
275
275
|
return E === "touch" ? o.context.popupRef.current : !0;
|
|
276
276
|
}
|
|
277
277
|
const y = r === void 0 ? I : r, b = D > 0, k = s.useMemo(() => ({
|
|
278
|
-
open:
|
|
278
|
+
open: h,
|
|
279
279
|
nested: _,
|
|
280
280
|
transitionStatus: R,
|
|
281
281
|
nestedDialogOpen: b
|
|
282
|
-
}), [
|
|
282
|
+
}), [h, _, R, b]), f = P("div", e, {
|
|
283
283
|
state: k,
|
|
284
284
|
props: [c, {
|
|
285
285
|
"aria-labelledby": v ?? void 0,
|
|
@@ -297,11 +297,11 @@ const be = {
|
|
|
297
297
|
ref: [n, o.context.popupRef, o.useStateSetter("popupElement")],
|
|
298
298
|
stateAttributesMapping: be
|
|
299
299
|
});
|
|
300
|
-
return /* @__PURE__ */ M(
|
|
300
|
+
return /* @__PURE__ */ M(q, {
|
|
301
301
|
context: u,
|
|
302
302
|
openInteractionType: x,
|
|
303
303
|
disabled: !g,
|
|
304
|
-
closeOnFocusOut: !
|
|
304
|
+
closeOnFocusOut: !C,
|
|
305
305
|
initialFocus: y,
|
|
306
306
|
returnFocus: i,
|
|
307
307
|
modal: m !== !1,
|
|
@@ -322,7 +322,7 @@ const xe = /* @__PURE__ */ s.forwardRef(function(e, n) {
|
|
|
322
322
|
children: /* @__PURE__ */ ge(me, {
|
|
323
323
|
ref: n,
|
|
324
324
|
...i,
|
|
325
|
-
children: [l && a === !0 && /* @__PURE__ */ M(
|
|
325
|
+
children: [l && a === !0 && /* @__PURE__ */ M(z, {
|
|
326
326
|
ref: r.context.internalBackdropRef,
|
|
327
327
|
inert: fe(!open)
|
|
328
328
|
}), e.children]
|
|
@@ -356,39 +356,39 @@ const ye = /* @__PURE__ */ s.forwardRef(function(e, n) {
|
|
|
356
356
|
id: a,
|
|
357
357
|
payload: o,
|
|
358
358
|
handle: p,
|
|
359
|
-
...
|
|
359
|
+
...C
|
|
360
360
|
} = e, u = N(!0), c = p?.store ?? u?.store;
|
|
361
361
|
if (!c)
|
|
362
362
|
throw new Error(process.env.NODE_ENV !== "production" ? "Base UI: <Dialog.Trigger> must be used within <Dialog.Root> or provided with a handle." : F(79));
|
|
363
363
|
const m = B(a), g = c.useState("floatingRootContext"), _ = c.useState("isOpenedByTrigger", m), D = s.useRef(null), {
|
|
364
|
-
registerTrigger:
|
|
364
|
+
registerTrigger: h,
|
|
365
365
|
isMountedByThisTrigger: x
|
|
366
366
|
} = ne(m, D, c, {
|
|
367
367
|
payload: o
|
|
368
368
|
}), {
|
|
369
369
|
getButtonProps: v,
|
|
370
370
|
buttonRef: R
|
|
371
|
-
} =
|
|
371
|
+
} = G({
|
|
372
372
|
disabled: r,
|
|
373
373
|
native: l
|
|
374
374
|
}), O = A(g, {
|
|
375
375
|
enabled: g != null
|
|
376
|
-
}), I =
|
|
376
|
+
}), I = K([O]), y = s.useMemo(() => ({
|
|
377
377
|
disabled: r,
|
|
378
378
|
open: _
|
|
379
379
|
}), [r, _]), b = c.useState("triggerProps", x);
|
|
380
380
|
return P("button", e, {
|
|
381
381
|
state: y,
|
|
382
|
-
ref: [R, n,
|
|
382
|
+
ref: [R, n, h, D],
|
|
383
383
|
props: [I.getReferenceProps(), b, {
|
|
384
384
|
[_e]: "",
|
|
385
385
|
id: m
|
|
386
|
-
},
|
|
386
|
+
}, C, v],
|
|
387
387
|
stateAttributesMapping: le
|
|
388
388
|
});
|
|
389
389
|
});
|
|
390
390
|
process.env.NODE_ENV !== "production" && (ye.displayName = "DialogTrigger");
|
|
391
|
-
const Te = "
|
|
391
|
+
const Te = "_dialog__backdrop_3490s_2", we = "_dialog__popup_3490s_14", ke = "_dialog__popup_centered_3490s_25", Me = "_dialog__content_3490s_36", Be = "_dialog__content_width_sm_3490s_52", Fe = "_dialog__content_width_md_3490s_56", Ve = "_dialog__content_width_lg_3490s_60", Ue = "_dialog__header_3490s_64", Ke = "_dialog__close_3490s_68", st = {
|
|
392
392
|
dialog__backdrop: Te,
|
|
393
393
|
dialog__popup: we,
|
|
394
394
|
dialog__popup_centered: ke,
|
|
@@ -397,12 +397,12 @@ const Te = "_dialog__backdrop_1hze7_1", we = "_dialog__popup_1hze7_13", ke = "_d
|
|
|
397
397
|
dialog__content_width_md: Fe,
|
|
398
398
|
dialog__content_width_lg: Ve,
|
|
399
399
|
dialog__header: Ue,
|
|
400
|
-
dialog__close:
|
|
400
|
+
dialog__close: Ke
|
|
401
401
|
};
|
|
402
402
|
export {
|
|
403
|
-
|
|
403
|
+
nt as D,
|
|
404
404
|
ot as a,
|
|
405
|
-
|
|
405
|
+
L as b,
|
|
406
406
|
ye as c,
|
|
407
407
|
xe as d,
|
|
408
408
|
Se as e,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { a as i } from "./detectBrowser-
|
|
1
|
+
import { i as s, b as a } from "./floating-ui.utils.dom-cbi420Pg.js";
|
|
2
|
+
import { a as i } from "./detectBrowser-Bl8Ki_1I.js";
|
|
3
3
|
const r = "data-base-ui-focusable", m = "active", b = "selected", u = "input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])", d = "ArrowLeft", h = "ArrowRight", E = "ArrowUp", R = "ArrowDown";
|
|
4
4
|
function A(t) {
|
|
5
5
|
let e = t.activeElement;
|
|
@@ -13,7 +13,7 @@ function T(t, e) {
|
|
|
13
13
|
const o = e.getRootNode?.();
|
|
14
14
|
if (t.contains(e))
|
|
15
15
|
return !0;
|
|
16
|
-
if (o &&
|
|
16
|
+
if (o && a(o)) {
|
|
17
17
|
let n = e;
|
|
18
18
|
for (; n; ) {
|
|
19
19
|
if (t === n)
|
|
@@ -41,7 +41,7 @@ function _(t) {
|
|
|
41
41
|
return t?.ownerDocument || document;
|
|
42
42
|
}
|
|
43
43
|
function c(t) {
|
|
44
|
-
return
|
|
44
|
+
return s(t) && t.matches(u);
|
|
45
45
|
}
|
|
46
46
|
function O(t) {
|
|
47
47
|
return t ? t.getAttribute("role") === "combobox" && c(t) : !1;
|
|
@@ -66,11 +66,11 @@ export {
|
|
|
66
66
|
R as a,
|
|
67
67
|
d as b,
|
|
68
68
|
h as c,
|
|
69
|
-
|
|
70
|
-
|
|
69
|
+
A as d,
|
|
70
|
+
_ as e,
|
|
71
71
|
T as f,
|
|
72
72
|
S as g,
|
|
73
|
-
|
|
73
|
+
p as h,
|
|
74
74
|
O as i,
|
|
75
75
|
c as j,
|
|
76
76
|
g as k,
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { i as r, a as u } from "./detectBrowser-
|
|
1
|
+
import { i as r, a as u } from "./detectBrowser-Bl8Ki_1I.js";
|
|
2
2
|
function n(i) {
|
|
3
3
|
i.preventDefault(), i.stopPropagation();
|
|
4
4
|
}
|
|
@@ -21,10 +21,10 @@ function d(i) {
|
|
|
21
21
|
return t === "click" || t === "mousedown" || t === "keydown" || t === "keyup";
|
|
22
22
|
}
|
|
23
23
|
export {
|
|
24
|
-
|
|
25
|
-
|
|
24
|
+
a,
|
|
25
|
+
c as b,
|
|
26
26
|
d as c,
|
|
27
27
|
e as d,
|
|
28
|
-
|
|
28
|
+
p as i,
|
|
29
29
|
n as s
|
|
30
30
|
};
|
|
@@ -116,13 +116,13 @@ export {
|
|
|
116
116
|
g as i,
|
|
117
117
|
p as j,
|
|
118
118
|
B as k,
|
|
119
|
-
|
|
119
|
+
y as l,
|
|
120
120
|
m,
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
121
|
+
d as n,
|
|
122
|
+
q as o,
|
|
123
|
+
x as p,
|
|
124
|
+
k as q,
|
|
125
|
+
D as r,
|
|
126
126
|
j as s,
|
|
127
|
-
|
|
127
|
+
C as t
|
|
128
128
|
};
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import * as O from "react";
|
|
2
2
|
import { useLayoutEffect as qt } from "react";
|
|
3
|
-
import { e as q, g as z, a as Y, b as Ut, c as Jt, d as Kt, h as Gt, i as re, m as ue, j as _, k as bt,
|
|
3
|
+
import { e as q, g as z, a as Y, b as Ut, c as Jt, d as Kt, h as Gt, i as re, m as ue, j as _, k as bt, r as be, s as Qt, l as At, n as Ot, o as He, p as St, q as j, f as ye, t as Ae } from "./floating-ui.utils-DUVaIF3G.js";
|
|
4
4
|
import { o as Et } from "./owner-rKN292Q9.js";
|
|
5
5
|
import { u as oe } from "./useIsoLayoutEffect-CIDbvm3Q.js";
|
|
6
|
-
import { u as ke } from "./useValueAsRef-
|
|
7
|
-
import { u as Zt } from "./useStableCallback-
|
|
6
|
+
import { u as ke } from "./useValueAsRef-B4EriRsI.js";
|
|
7
|
+
import { u as Zt } from "./useStableCallback-DKZHlUAT.js";
|
|
8
8
|
import { u as en } from "./DirectionContext-C2o_MF_i.js";
|
|
9
|
-
import { h as We, a as k, j as J,
|
|
9
|
+
import { h as We, a as k, j as J, g as K, k as ut, f as U, i as G, l as Ct, m as Ve, n as de, o as Oe, p as tn, q as Pt, r as nn, e as Ie, d as _e, s as Ee } from "./floating-ui.utils.dom-cbi420Pg.js";
|
|
10
10
|
import * as on from "react-dom";
|
|
11
|
-
import { u as sn, F as rn, P as cn, a as ln } from "./transitions.module-
|
|
11
|
+
import { u as sn, F as rn, P as cn, a as ln } from "./transitions.module-D9mMAtfI.js";
|
|
12
12
|
import { u as an } from "./useId-C5kyn6tA.js";
|
|
13
|
-
import { a as fn, E as un } from "./useRenderElement-
|
|
14
|
-
import { D as dn } from "./FloatingPortal-
|
|
13
|
+
import { a as fn, E as un } from "./useRenderElement-DngNDu_P.js";
|
|
14
|
+
import { D as dn } from "./FloatingPortal-BQsQhvIr.js";
|
|
15
15
|
function dt(e, t, i) {
|
|
16
16
|
let {
|
|
17
17
|
reference: n,
|
package/dist/heading.css
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@layer components{._heading_m8x05_2{font-weight:var(--font-weight-medium)}}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@layer components{._icon-button_1aj78_2{display:flex;justify-content:center;align-items:center;border-radius:var(--border-radius-default);aspect-ratio:1 / 1;width:var(--icon-button-size);height:var(--icon-button-size)}._icon-button_size_sm_1aj78_12{--icon-button-size: var(--space-24)}._icon-button_size_md_1aj78_16{--icon-button-size: var(--space-32)}._icon-button_size_lg_1aj78_20{--icon-button-size: var(--space-40)}._icon-button_size_xl_1aj78_24{--icon-button-size: var(--space-48)}._icon-button_size_2xl_1aj78_28{--icon-button-size: var(--space-56)}._icon-button_size_3xl_1aj78_32{--icon-button-size: var(--space-64)}}
|
package/dist/icon.css
ADDED
|
@@ -0,0 +1 @@
|
|
|
1
|
+
@layer components{._icon_ol0rk_2{--icon-size: var(--space-16);vertical-align:middle;width:var(--icon-size);min-width:var(--icon-size);height:var(--icon-size);min-height:var(--icon-size);font-size:var(--icon-size)}._icon_size_sm_ol0rk_14,._icon_size_md_ol0rk_19{--icon-size: var(--space-16)}._icon_size_lg_ol0rk_23{--icon-size: var(--space-20)}._icon_size_xl_ol0rk_27{--icon-size: var(--space-24)}._icon_size_2xl_ol0rk_31{--icon-size: var(--space-32)}._icon_size_3xl_ol0rk_35{--icon-size: var(--space-48)}}
|
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
export { Accordion
|
|
2
|
-
export { AlertDialog
|
|
1
|
+
export { Accordion } from './components/accordion';
|
|
2
|
+
export { AlertDialog } from './components/alert-dialog';
|
|
3
3
|
export { Anchor } from './components/anchor';
|
|
4
4
|
export { Avatar } from './components/avatar';
|
|
5
5
|
export { Badge } from './components/badge';
|
|
@@ -7,10 +7,10 @@ export { Button } from './components/button';
|
|
|
7
7
|
export { Checkbox } from './components/checkbox';
|
|
8
8
|
export { Code } from './components/code';
|
|
9
9
|
export { Collapse } from './components/collapse';
|
|
10
|
-
export {
|
|
11
|
-
export { ContextMenu
|
|
12
|
-
export { Dialog
|
|
13
|
-
export { Heading
|
|
10
|
+
export { Command } from './components/command';
|
|
11
|
+
export { ContextMenu } from './components/context-menu';
|
|
12
|
+
export { Dialog } from './components/dialog';
|
|
13
|
+
export { Heading } from './components/heading';
|
|
14
14
|
export { Icon } from './components/icon';
|
|
15
15
|
export { IconButton } from './components/icon-button';
|
|
16
16
|
export { InlineCode } from './components/inline-code';
|
|
@@ -22,7 +22,7 @@ export { PasswordInput } from './components/password-input';
|
|
|
22
22
|
export { Pill } from './components/pill';
|
|
23
23
|
export { Popover } from './components/popover';
|
|
24
24
|
export { PreviewCard } from './components/preview-card';
|
|
25
|
-
export { RadioGroup
|
|
25
|
+
export { RadioGroup } from './components/radio-group';
|
|
26
26
|
export { SearchBar } from './components/search-bar';
|
|
27
27
|
export { Select } from './components/select';
|
|
28
28
|
export { Separator } from './components/separator';
|
|
@@ -32,11 +32,11 @@ export { StackedAvatars } from './components/stacked-avatars';
|
|
|
32
32
|
export { StatusBanner } from './components/status-banner';
|
|
33
33
|
export { Surface } from './components/surface';
|
|
34
34
|
export { Switch } from './components/switch';
|
|
35
|
-
export { Tabs
|
|
35
|
+
export { Tabs } from './components/tabs';
|
|
36
36
|
export { Text } from './components/text';
|
|
37
37
|
export { ThemeProvider, useThemeContext } from './components/theme-provider';
|
|
38
38
|
export { Timestamp } from './components/timestamp';
|
|
39
|
-
export {
|
|
40
|
-
export {
|
|
39
|
+
export { Toaster, useToastManager } from './components/toaster';
|
|
40
|
+
export { Tooltip } from './components/tooltip';
|
|
41
41
|
export { View } from './components/view';
|
|
42
42
|
export { VisuallyHidden } from './components/visually-hidden';
|