@justanarthur/modo-ui 2.1.0 → 2.3.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/blocks/desktop-shell/index.tsx +2 -1
- package/components/inputs/checkbox/index.tsx +5 -0
- package/components/inputs/combobox/index.tsx +9 -4
- package/components/inputs/radio/index.tsx +5 -0
- package/components/inputs/select/index.tsx +23 -3
- package/components/inputs/slider/comfortable.tsx +10 -4
- package/components/inputs/slider/compact.tsx +153 -71
- package/components/inputs/slider/examples.mdx +24 -0
- package/components/inputs/slider/geometry.ts +18 -6
- package/components/inputs/slider/index.tsx +30 -8
- package/components/inputs/slider/value-display.tsx +16 -9
- package/components/inputs/switch/index.tsx +5 -0
- package/components/inputs/textarea/examples.mdx +19 -0
- package/components/inputs/textarea/index.tsx +42 -5
- package/components/navigation/sidebar/sidebar-group.tsx +2 -1
- package/components/navigation/sidebar/sidebar-menu-sub.tsx +2 -1
- package/components/navigation/sidebar/sidebar-shell.tsx +2 -1
- package/components/navigation/tree/index.tsx +2 -1
- package/components/overlays/dropdown/index.tsx +50 -8
- package/components/overlays/dropdown/submenu.tsx +41 -10
- package/components/overlays/tooltip/examples.mdx +13 -0
- package/components/overlays/tooltip/index.tsx +58 -16
- package/dist/blocks/desktop-shell/index.js +10 -9
- package/dist/blocks/sidebar-app/index.js +11 -10
- package/dist/components/actions/button/index.js +2 -2
- package/dist/components/actions/copy/index.js +4 -4
- package/dist/components/containers/accordion/index.d.ts +1 -1
- package/dist/components/containers/accordion/index.js +2 -2
- package/dist/components/containers/card/index.js +3 -3
- package/dist/components/data-display/log-view/index.js +3 -3
- package/dist/components/inputs/checkbox/index.d.ts +2 -0
- package/dist/components/inputs/checkbox/index.js +1 -1
- package/dist/components/inputs/color-picker/index.js +5 -5
- package/dist/components/inputs/combobox/index.d.ts +1 -1
- package/dist/components/inputs/combobox/index.js +2 -2
- package/dist/components/inputs/date-time/date-picker/index.js +7 -7
- package/dist/components/inputs/date-time/date-range-picker/index.js +7 -7
- package/dist/components/inputs/date-time/duration-picker/index.js +7 -7
- package/dist/components/inputs/date-time/month-picker/index.js +7 -7
- package/dist/components/inputs/date-time/time-picker/index.js +7 -7
- package/dist/components/inputs/field/index.js +2 -2
- package/dist/components/inputs/file-dropzone/index.js +3 -3
- package/dist/components/inputs/key-value/index.js +3 -3
- package/dist/components/inputs/radio/index.d.ts +2 -0
- package/dist/components/inputs/radio/index.js +1 -1
- package/dist/components/inputs/search/index.js +6 -6
- package/dist/components/inputs/select/index.d.ts +22 -4
- package/dist/components/inputs/select/index.js +3 -3
- package/dist/components/inputs/slider/index.d.ts +12 -3
- package/dist/components/inputs/slider/index.js +1 -1
- package/dist/components/inputs/switch/index.d.ts +2 -0
- package/dist/components/inputs/switch/index.js +1 -1
- package/dist/components/inputs/textarea/index.d.ts +8 -1
- package/dist/components/inputs/textarea/index.js +1 -1
- package/dist/components/navigation/breadcrumb/index.js +4 -4
- package/dist/components/navigation/navigation-menu/index.js +2 -2
- package/dist/components/navigation/pagination/index.js +3 -3
- package/dist/components/navigation/sidebar/index.js +8 -7
- package/dist/components/navigation/tree/index.js +2 -1
- package/dist/components/overlays/alert-dialog/index.d.ts +3 -3
- package/dist/components/overlays/alert-dialog/index.js +5 -5
- package/dist/components/overlays/command/index.d.ts +1 -1
- package/dist/components/overlays/command/index.js +5 -5
- package/dist/components/overlays/context-menu/index.d.ts +20 -1
- package/dist/components/overlays/context-menu/index.js +4 -4
- package/dist/components/overlays/dialog/index.d.ts +3 -3
- package/dist/components/overlays/dialog/index.js +4 -4
- package/dist/components/overlays/dropdown/index.d.ts +30 -8
- package/dist/components/overlays/dropdown/index.js +3 -3
- package/dist/components/overlays/lightbox/index.js +3 -3
- package/dist/components/overlays/popover/index.d.ts +6 -6
- package/dist/components/overlays/popover/index.js +3 -3
- package/dist/components/overlays/preview-card/index.js +2 -2
- package/dist/components/overlays/sheet/index.d.ts +3 -3
- package/dist/components/overlays/sheet/index.js +5 -5
- package/dist/components/overlays/toast/index.d.ts +1 -1
- package/dist/components/overlays/toast/index.js +3 -3
- package/dist/components/overlays/tooltip/index.d.ts +35 -10
- package/dist/components/overlays/tooltip/index.js +3 -3
- package/dist/docs/index.js +9 -8
- package/dist/index.d.ts +92 -38
- package/dist/index.js +47 -46
- package/dist/lib/inert.d.ts +7 -0
- package/dist/lib/inert.js +6 -0
- package/dist/lib/overlay.d.ts +20 -13
- package/dist/lib/overlay.js +2 -1
- package/dist/lib/slot.d.ts +5 -2
- package/dist/lib/slot.js +1 -1
- package/dist/primitives/layout/resizable/index.d.ts +4 -2
- package/dist/primitives/layout/resizable/index.js +1 -1
- package/dist/primitives/systems/morph/index.js +3 -3
- package/dist/primitives/systems/motion/index.js +3 -3
- package/dist/shared/{components-s90v3jpr.js → components-01e24999.js} +60 -11
- package/dist/shared/{components-a1ms36qq.js → components-1f5624hb.js} +1 -1
- package/dist/shared/{components-9z7bq8gn.js → components-1sbnbq6a.js} +1 -1
- package/dist/shared/{components-w2at9ntm.js → components-27fatggq.js} +1 -1
- package/dist/shared/{components-fmyvz4r2.js → components-2bq4ng4d.js} +4 -4
- package/dist/shared/components-2myjk2zf.js +8 -0
- package/dist/shared/{components-hz6armxa.js → components-2tw25pk6.js} +3 -0
- package/dist/shared/{components-nhmgr5xc.js → components-2v4mmw1s.js} +10 -7
- package/dist/shared/{components-twyj2y8c.js → components-3rt5c1qt.js} +1 -1
- package/dist/shared/{components-91mmbrw3.js → components-3sb31vw5.js} +1 -1
- package/dist/shared/{components-1f3a7gmg.js → components-4fswe4kh.js} +1 -1
- package/dist/shared/{components-gsstwhtv.js → components-5vezp3e5.js} +3 -0
- package/dist/shared/{components-ee09xmkh.js → components-6g8a5nrs.js} +4 -1
- package/dist/shared/{components-h0x2pj2y.js → components-6xtntksc.js} +17 -3
- package/dist/shared/{components-1asw2ph0.js → components-7g2q2ccp.js} +1 -1
- package/dist/shared/{components-kwxye0an.js → components-7wjkag2j.js} +4 -2
- package/dist/shared/{components-vfreweq3.js → components-83jn0raj.js} +1 -1
- package/dist/shared/{components-1bnf96sr.js → components-8e0fjgm9.js} +37 -9
- package/dist/shared/{components-j79a6jqa.js → components-8ybvpebx.js} +1 -1
- package/dist/shared/{components-me742146.js → components-a3brpprb.js} +1 -1
- package/dist/shared/{components-ev0ytbqb.js → components-abqfs5fh.js} +1 -1
- package/dist/shared/{components-r5q9gdh4.js → components-agjpst9b.js} +5 -5
- package/dist/shared/{components-6rtawx8y.js → components-e52xgvd9.js} +4 -4
- package/dist/shared/{components-0cpte6s1.js → components-eebf7f9c.js} +4 -3
- package/dist/shared/{components-xa9fvd5b.js → components-etgpz4zk.js} +1 -1
- package/dist/shared/{components-b9bj65j3.js → components-ex2xtqv7.js} +6 -6
- package/dist/shared/{components-n0gbyp5a.js → components-fjg4j430.js} +5 -5
- package/dist/shared/{components-280grw6q.js → components-fxw1122w.js} +1 -1
- package/dist/shared/{components-y8m64zdw.js → components-gnsvnejm.js} +1 -1
- package/dist/shared/{components-7mj5wsv3.js → components-gr82tz50.js} +21 -3
- package/dist/shared/{components-22h8dvt1.js → components-k25zw9g8.js} +3 -3
- package/dist/shared/{components-a1mwqxsv.js → components-k2gg1agj.js} +3 -3
- package/dist/shared/{components-wx1dcp2n.js → components-kz6ak6kj.js} +1 -1
- package/dist/shared/{components-yf2gtq68.js → components-m7d7r3r8.js} +8 -5
- package/dist/shared/{components-62510420.js → components-mvwf8ckh.js} +4 -4
- package/dist/shared/{components-2m2hg11x.js → components-nh05qz8b.js} +3 -3
- package/dist/shared/{components-77gxngmc.js → components-nred2e6g.js} +5 -5
- package/dist/shared/{components-3rvrdsa9.js → components-s2pnh8h9.js} +1 -1
- package/dist/shared/{components-xnkc892z.js → components-t4j0r23n.js} +1 -1
- package/dist/shared/{components-rgng034x.js → components-tcm3k3wj.js} +24 -3
- package/dist/shared/{components-p32aqk3q.js → components-vx286kq7.js} +110 -73
- package/dist/shared/{components-b2kjsn1s.js → components-vykcfb5r.js} +1 -1
- package/dist/shared/{components-hcftn5r8.js → components-x5v7e0fz.js} +3 -0
- package/dist/shared/{components-0h2mng6m.js → components-ycwhrqe1.js} +1 -1
- package/dist/shared/{components-chda6b23.js → components-ypxst3cn.js} +33 -4
- package/dist/shared/{components-14wzcym0.js → components-z87sanbc.js} +5 -5
- package/dist/shared/{components-fqsgd07c.js → components-zv63s4fh.js} +2 -2
- package/dist/styles.css +5 -1
- package/lib/inert.ts +15 -0
- package/lib/overlay.tsx +49 -5
- package/lib/slot.tsx +9 -3
- package/package.json +6 -1
- package/primitives/layout/resizable/index.tsx +35 -7
|
@@ -2,10 +2,10 @@
|
|
|
2
2
|
|
|
3
3
|
import {
|
|
4
4
|
slotRender2
|
|
5
|
-
} from "./components-
|
|
5
|
+
} from "./components-7wjkag2j.js";
|
|
6
6
|
import {
|
|
7
7
|
button_default
|
|
8
|
-
} from "./components-
|
|
8
|
+
} from "./components-ycwhrqe1.js";
|
|
9
9
|
import {
|
|
10
10
|
DialogTrigger2,
|
|
11
11
|
DialogClose2,
|
|
@@ -15,7 +15,7 @@ import {
|
|
|
15
15
|
DialogTitle2,
|
|
16
16
|
DialogDescription2,
|
|
17
17
|
DialogState2
|
|
18
|
-
} from "./components-
|
|
18
|
+
} from "./components-ex2xtqv7.js";
|
|
19
19
|
|
|
20
20
|
// components/overlays/alert-dialog/index.tsx
|
|
21
21
|
import { AlertDialog as AlertDialogPrimitive } from "@base-ui/react/alert-dialog";
|
|
@@ -28,7 +28,7 @@ import {
|
|
|
28
28
|
useOverlayRoot2,
|
|
29
29
|
useOverlay2,
|
|
30
30
|
positionerProps2
|
|
31
|
-
} from "./components-
|
|
31
|
+
} from "./components-tcm3k3wj.js";
|
|
32
32
|
import {
|
|
33
33
|
PopupSurface2
|
|
34
34
|
} from "./components-nxqrw789.js";
|
|
@@ -43,10 +43,10 @@ import {
|
|
|
43
43
|
} from "./components-nz14rwtd.js";
|
|
44
44
|
import {
|
|
45
45
|
button_default
|
|
46
|
-
} from "./components-
|
|
46
|
+
} from "./components-ycwhrqe1.js";
|
|
47
47
|
import {
|
|
48
48
|
sheet_default
|
|
49
|
-
} from "./components-
|
|
49
|
+
} from "./components-mvwf8ckh.js";
|
|
50
50
|
import {
|
|
51
51
|
InputAdornment2,
|
|
52
52
|
InputAction2,
|
|
@@ -11,7 +11,7 @@ import {
|
|
|
11
11
|
} from "./components-xnp09586.js";
|
|
12
12
|
import {
|
|
13
13
|
button_default
|
|
14
|
-
} from "./components-
|
|
14
|
+
} from "./components-ycwhrqe1.js";
|
|
15
15
|
import {
|
|
16
16
|
useControllableState2
|
|
17
17
|
} from "./components-wwd093xg.js";
|
|
@@ -29,16 +29,19 @@ import {
|
|
|
29
29
|
import {
|
|
30
30
|
useSidebarShortcut,
|
|
31
31
|
sidebar_default
|
|
32
|
-
} from "./components-
|
|
32
|
+
} from "./components-2v4mmw1s.js";
|
|
33
|
+
import {
|
|
34
|
+
inertProps2
|
|
35
|
+
} from "./components-2myjk2zf.js";
|
|
33
36
|
import {
|
|
34
37
|
SizeProvider2
|
|
35
38
|
} from "./components-nz14rwtd.js";
|
|
36
39
|
import {
|
|
37
40
|
tooltip_default
|
|
38
|
-
} from "./components-
|
|
41
|
+
} from "./components-8e0fjgm9.js";
|
|
39
42
|
import {
|
|
40
43
|
resizable_default
|
|
41
|
-
} from "./components-
|
|
44
|
+
} from "./components-gr82tz50.js";
|
|
42
45
|
|
|
43
46
|
// blocks/desktop-shell/index.tsx
|
|
44
47
|
import { useCallback, useLayoutEffect, useRef, useState } from "react";
|
|
@@ -286,7 +289,7 @@ function DesktopShell2({
|
|
|
286
289
|
maxSize: maxPaneSize,
|
|
287
290
|
collapsible: true,
|
|
288
291
|
children: /* @__PURE__ */ jsx("div", {
|
|
289
|
-
...paneOpen
|
|
292
|
+
...inertProps2(!paneOpen),
|
|
290
293
|
className: "flex h-full min-w-0 flex-col",
|
|
291
294
|
children: right
|
|
292
295
|
})
|
|
@@ -6,12 +6,12 @@ import {
|
|
|
6
6
|
import {
|
|
7
7
|
useMorph2
|
|
8
8
|
} from "./components-8pnvkrbw.js";
|
|
9
|
-
import {
|
|
10
|
-
usePortalContainer2
|
|
11
|
-
} from "./components-rgng034x.js";
|
|
12
9
|
import {
|
|
13
10
|
cn2
|
|
14
11
|
} from "./components-xnp09586.js";
|
|
12
|
+
import {
|
|
13
|
+
usePortalContainer2
|
|
14
|
+
} from "./components-tcm3k3wj.js";
|
|
15
15
|
import {
|
|
16
16
|
useShape2
|
|
17
17
|
} from "./components-kxpcj2ry.js";
|
|
@@ -27,7 +27,7 @@ import {
|
|
|
27
27
|
DialogTitle2,
|
|
28
28
|
DialogDescription2,
|
|
29
29
|
DialogState2
|
|
30
|
-
} from "./components-
|
|
30
|
+
} from "./components-ex2xtqv7.js";
|
|
31
31
|
|
|
32
32
|
// components/overlays/sheet/index.tsx
|
|
33
33
|
import { Drawer as DrawerPrimitive } from "@base-ui/react/drawer";
|
|
@@ -30,7 +30,7 @@ import {
|
|
|
30
30
|
} from "./components-45r18egt.js";
|
|
31
31
|
import {
|
|
32
32
|
Slider2
|
|
33
|
-
} from "./components-
|
|
33
|
+
} from "./components-vx286kq7.js";
|
|
34
34
|
import {
|
|
35
35
|
useMorph2
|
|
36
36
|
} from "./components-8pnvkrbw.js";
|
|
@@ -50,7 +50,7 @@ import {
|
|
|
50
50
|
positionerProps2,
|
|
51
51
|
PortalContainer2,
|
|
52
52
|
usePortalContainer2
|
|
53
|
-
} from "./components-
|
|
53
|
+
} from "./components-tcm3k3wj.js";
|
|
54
54
|
import {
|
|
55
55
|
POPUP_SHAPE2
|
|
56
56
|
} from "./components-mse06t0x.js";
|
|
@@ -69,7 +69,7 @@ import {
|
|
|
69
69
|
} from "./components-y09nr7fe.js";
|
|
70
70
|
import {
|
|
71
71
|
Tooltip2
|
|
72
|
-
} from "./components-
|
|
72
|
+
} from "./components-8e0fjgm9.js";
|
|
73
73
|
import {
|
|
74
74
|
clamp012,
|
|
75
75
|
hsvToRgb2,
|
|
@@ -15,16 +15,16 @@ import {
|
|
|
15
15
|
import {
|
|
16
16
|
useMorph2
|
|
17
17
|
} from "./components-8pnvkrbw.js";
|
|
18
|
+
import {
|
|
19
|
+
cn2
|
|
20
|
+
} from "./components-xnp09586.js";
|
|
18
21
|
import {
|
|
19
22
|
positionerProps2,
|
|
20
23
|
usePortalContainer2
|
|
21
|
-
} from "./components-
|
|
24
|
+
} from "./components-tcm3k3wj.js";
|
|
22
25
|
import {
|
|
23
26
|
POPUP_SHAPE2
|
|
24
27
|
} from "./components-mse06t0x.js";
|
|
25
|
-
import {
|
|
26
|
-
cn2
|
|
27
|
-
} from "./components-xnp09586.js";
|
|
28
28
|
import {
|
|
29
29
|
useShape2
|
|
30
30
|
} from "./components-kxpcj2ry.js";
|
|
@@ -48,7 +48,7 @@ import {
|
|
|
48
48
|
CommandListRoot2,
|
|
49
49
|
CommandShortcut2,
|
|
50
50
|
CommandList2
|
|
51
|
-
} from "./components-
|
|
51
|
+
} from "./components-8ybvpebx.js";
|
|
52
52
|
|
|
53
53
|
// components/inputs/search/index.tsx
|
|
54
54
|
import { Autocomplete } from "@base-ui/react/autocomplete";
|
|
@@ -23,7 +23,7 @@ import {
|
|
|
23
23
|
} from "./components-6h5qg9rs.js";
|
|
24
24
|
import {
|
|
25
25
|
button_default
|
|
26
|
-
} from "./components-
|
|
26
|
+
} from "./components-ycwhrqe1.js";
|
|
27
27
|
|
|
28
28
|
// components/data-display/log-view/index.tsx
|
|
29
29
|
import { AnimatePresence, motion } from "motion/react";
|
|
@@ -8,9 +8,17 @@ import {
|
|
|
8
8
|
inPlaceOffset2,
|
|
9
9
|
useMorphOrigin2
|
|
10
10
|
} from "./components-8pnvkrbw.js";
|
|
11
|
+
import {
|
|
12
|
+
cn2
|
|
13
|
+
} from "./components-xnp09586.js";
|
|
11
14
|
|
|
12
15
|
// lib/overlay.tsx
|
|
13
|
-
import {
|
|
16
|
+
import {
|
|
17
|
+
createContext,
|
|
18
|
+
useCallback,
|
|
19
|
+
useContext,
|
|
20
|
+
useMemo
|
|
21
|
+
} from "react";
|
|
14
22
|
import { jsx } from "react/jsx-runtime";
|
|
15
23
|
var OverlayContext2 = createContext(null);
|
|
16
24
|
function useOverlayRoot2({ open: openProp, defaultOpen = false, onOpenChange: onChange }) {
|
|
@@ -30,13 +38,26 @@ function useOverlay2(part) {
|
|
|
30
38
|
throw new Error(`${part} must be inside its overlay's root.`);
|
|
31
39
|
return state;
|
|
32
40
|
}
|
|
33
|
-
function positionerProps2({
|
|
41
|
+
function positionerProps2({
|
|
42
|
+
side,
|
|
43
|
+
align,
|
|
44
|
+
sideOffset,
|
|
45
|
+
effect,
|
|
46
|
+
hideSource,
|
|
47
|
+
alignOffset,
|
|
48
|
+
collisionPadding,
|
|
49
|
+
collisionBoundary,
|
|
50
|
+
positionerClassName
|
|
51
|
+
}, defaults) {
|
|
34
52
|
const inPlace = opensInPlace2({ effect, hideSource });
|
|
35
53
|
return {
|
|
36
54
|
side: side ?? defaults.side,
|
|
37
55
|
align: align ?? (inPlace ? "start" : defaults.align),
|
|
38
56
|
sideOffset: inPlace ? inPlaceOffset2 : sideOffset ?? defaults.sideOffset,
|
|
39
|
-
|
|
57
|
+
alignOffset,
|
|
58
|
+
collisionPadding,
|
|
59
|
+
collisionBoundary,
|
|
60
|
+
className: cn2("z-50 outline-none", positionerClassName)
|
|
40
61
|
};
|
|
41
62
|
}
|
|
42
63
|
var PortalContainerContext = createContext(null);
|