@orioncactuscorp/ui 1.13.0 → 1.15.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/CHANGELOG.md +155 -0
- package/README.md +133 -36
- package/dist/components/BackgroundIconButton/BackgroundIconButton.css +1 -1
- package/dist/components/Button/Button.css +1 -1
- package/dist/components/CheckMark/CheckMark.js +19 -17
- package/dist/components/Checkbox/Checkbox.css +1 -1
- package/dist/components/Checkbox/Checkbox.js +38 -36
- package/dist/components/FloatingWindow/FloatingWindow.css +1 -0
- package/dist/components/FloatingWindow/FloatingWindow.js +693 -0
- package/dist/components/FloatingWindow/FloatingWindow.module.scss.js +17 -0
- package/dist/components/FloatingWindow/FloatingWindowManager.js +36 -0
- package/dist/components/FloatingWindow/contexts.js +25 -0
- package/dist/components/FloatingWindow/geometry.js +222 -0
- package/dist/components/FloatingWindow/stack.js +31 -0
- package/dist/components/FloatingWindow.d.ts +6 -0
- package/dist/components/FloatingWindow.js +18 -0
- package/dist/components/Interaction/Interaction.css +1 -1
- package/dist/components/Menu/Menu.css +1 -1
- package/dist/components/Menu/Menu.js +95 -87
- package/dist/components/Modal/Modal.css +1 -1
- package/dist/components/Modal/Modal.js +558 -723
- package/dist/components/Modal/Modal.module.scss.js +69 -60
- package/dist/components/Modal/initialFocus.js +11 -0
- package/dist/components/Modal/keyboardSession.js +104 -0
- package/dist/components/Modal/snapPoints.js +95 -82
- package/dist/components/Modal/useModalDrag.js +730 -762
- package/dist/components/Modal/useModalKeyboardAvoidance.js +159 -0
- package/dist/components/Modal/useModalViewportGeometry.js +36 -0
- package/dist/components/PositionSnap/PositionSnap.css +1 -0
- package/dist/components/PositionSnap/PositionSnap.js +330 -0
- package/dist/components/PositionSnap/PositionSnap.module.scss.js +9 -0
- package/dist/components/PositionSnap/contexts.js +12 -0
- package/dist/components/PositionSnap/geometry.js +75 -0
- package/dist/components/PositionSnap/gesture.js +7 -0
- package/dist/components/PositionSnap/policy.js +60 -0
- package/dist/components/PositionSnap.d.ts +6 -0
- package/dist/components/PositionSnap.js +7 -0
- package/dist/components/ProgressIndicator/ProgressIndicator.css +1 -0
- package/dist/components/ProgressIndicator/ProgressIndicator.js +45 -0
- package/dist/components/ProgressIndicator/ProgressIndicator.module.scss.js +13 -0
- package/dist/components/ProgressIndicator.d.ts +6 -0
- package/dist/components/ProgressIndicator.js +4 -0
- package/dist/components/Radio/Radio.css +1 -1
- package/dist/components/Radio/Radio.js +26 -24
- package/dist/components/Switch/Switch.css +1 -1
- package/dist/components/Switch/Switch.js +18 -16
- package/dist/components/Tabs/Tabs.css +1 -1
- package/dist/components/Tooltip/Tooltip.css +1 -1
- package/dist/components/Tooltip/Tooltip.js +59 -56
- package/dist/components/Tooltip/Tooltip.module.scss.js +6 -4
- package/dist/components/internal/ModalPresentation.js +361 -0
- package/dist/components/internal/OverlayPortalContext.js +20 -0
- package/dist/index.js +135 -112
- package/dist/styles.css +13 -10
- package/dist/ui/src/components/CheckMark/CheckMark.d.ts +1 -1
- package/dist/ui/src/components/CheckMark/CheckMark.d.ts.map +1 -1
- package/dist/ui/src/components/CheckMark/types.d.ts +2 -1
- package/dist/ui/src/components/CheckMark/types.d.ts.map +1 -1
- package/dist/ui/src/components/Checkbox/Checkbox.d.ts +1 -1
- package/dist/ui/src/components/Checkbox/Checkbox.d.ts.map +1 -1
- package/dist/ui/src/components/Checkbox/types.d.ts +2 -1
- package/dist/ui/src/components/Checkbox/types.d.ts.map +1 -1
- package/dist/ui/src/components/FloatingWindow/FloatingWindow.d.ts +32 -0
- package/dist/ui/src/components/FloatingWindow/FloatingWindow.d.ts.map +1 -0
- package/dist/ui/src/components/FloatingWindow/FloatingWindowManager.d.ts +4 -0
- package/dist/ui/src/components/FloatingWindow/FloatingWindowManager.d.ts.map +1 -0
- package/dist/ui/src/components/FloatingWindow/contexts.d.ts +36 -0
- package/dist/ui/src/components/FloatingWindow/contexts.d.ts.map +1 -0
- package/dist/ui/src/components/FloatingWindow/geometry.d.ts +31 -0
- package/dist/ui/src/components/FloatingWindow/geometry.d.ts.map +1 -0
- package/dist/ui/src/components/FloatingWindow/index.d.ts +4 -0
- package/dist/ui/src/components/FloatingWindow/index.d.ts.map +1 -0
- package/dist/ui/src/components/FloatingWindow/stack.d.ts +9 -0
- package/dist/ui/src/components/FloatingWindow/stack.d.ts.map +1 -0
- package/dist/ui/src/components/FloatingWindow/types.d.ts +121 -0
- package/dist/ui/src/components/FloatingWindow/types.d.ts.map +1 -0
- package/dist/ui/src/components/Interaction/index.d.ts +1 -1
- package/dist/ui/src/components/Interaction/index.d.ts.map +1 -1
- package/dist/ui/src/components/Interaction/types.d.ts +9 -1
- package/dist/ui/src/components/Interaction/types.d.ts.map +1 -1
- package/dist/ui/src/components/Menu/Menu.d.ts +2 -2
- package/dist/ui/src/components/Menu/Menu.d.ts.map +1 -1
- package/dist/ui/src/components/Menu/types.d.ts +9 -2
- package/dist/ui/src/components/Menu/types.d.ts.map +1 -1
- package/dist/ui/src/components/Modal/Modal.d.ts +2 -2
- package/dist/ui/src/components/Modal/Modal.d.ts.map +1 -1
- package/dist/ui/src/components/Modal/contexts.d.ts +3 -0
- package/dist/ui/src/components/Modal/contexts.d.ts.map +1 -1
- package/dist/ui/src/components/Modal/initialFocus.d.ts +18 -0
- package/dist/ui/src/components/Modal/initialFocus.d.ts.map +1 -0
- package/dist/ui/src/components/Modal/keyboardSession.d.ts +46 -0
- package/dist/ui/src/components/Modal/keyboardSession.d.ts.map +1 -0
- package/dist/ui/src/components/Modal/snapPoints.d.ts.map +1 -1
- package/dist/ui/src/components/Modal/types.d.ts +17 -2
- package/dist/ui/src/components/Modal/types.d.ts.map +1 -1
- package/dist/ui/src/components/Modal/useModalDrag.d.ts.map +1 -1
- package/dist/ui/src/components/Modal/useModalKeyboardAvoidance.d.ts +17 -0
- package/dist/ui/src/components/Modal/useModalKeyboardAvoidance.d.ts.map +1 -0
- package/dist/ui/src/components/Modal/useModalViewportGeometry.d.ts +9 -0
- package/dist/ui/src/components/Modal/useModalViewportGeometry.d.ts.map +1 -0
- package/dist/ui/src/components/PositionSnap/PositionSnap.d.ts +11 -0
- package/dist/ui/src/components/PositionSnap/PositionSnap.d.ts.map +1 -0
- package/dist/ui/src/components/PositionSnap/contexts.d.ts +17 -0
- package/dist/ui/src/components/PositionSnap/contexts.d.ts.map +1 -0
- package/dist/ui/src/components/PositionSnap/geometry.d.ts +31 -0
- package/dist/ui/src/components/PositionSnap/geometry.d.ts.map +1 -0
- package/dist/ui/src/components/PositionSnap/gesture.d.ts +2 -0
- package/dist/ui/src/components/PositionSnap/gesture.d.ts.map +1 -0
- package/dist/ui/src/components/PositionSnap/index.d.ts +3 -0
- package/dist/ui/src/components/PositionSnap/index.d.ts.map +1 -0
- package/dist/ui/src/components/PositionSnap/policy.d.ts +24 -0
- package/dist/ui/src/components/PositionSnap/policy.d.ts.map +1 -0
- package/dist/ui/src/components/PositionSnap/types.d.ts +31 -0
- package/dist/ui/src/components/PositionSnap/types.d.ts.map +1 -0
- package/dist/ui/src/components/ProgressIndicator/ProgressIndicator.d.ts +4 -0
- package/dist/ui/src/components/ProgressIndicator/ProgressIndicator.d.ts.map +1 -0
- package/dist/ui/src/components/ProgressIndicator/index.d.ts +3 -0
- package/dist/ui/src/components/ProgressIndicator/index.d.ts.map +1 -0
- package/dist/ui/src/components/ProgressIndicator/types.d.ts +17 -0
- package/dist/ui/src/components/ProgressIndicator/types.d.ts.map +1 -0
- package/dist/ui/src/components/Radio/Radio.d.ts +1 -1
- package/dist/ui/src/components/Radio/Radio.d.ts.map +1 -1
- package/dist/ui/src/components/Radio/types.d.ts +2 -1
- package/dist/ui/src/components/Radio/types.d.ts.map +1 -1
- package/dist/ui/src/components/Switch/Switch.d.ts +1 -1
- package/dist/ui/src/components/Switch/Switch.d.ts.map +1 -1
- package/dist/ui/src/components/Switch/types.d.ts +2 -1
- package/dist/ui/src/components/Switch/types.d.ts.map +1 -1
- package/dist/ui/src/components/Tooltip/Tooltip.d.ts +1 -1
- package/dist/ui/src/components/Tooltip/Tooltip.d.ts.map +1 -1
- package/dist/ui/src/components/Tooltip/types.d.ts +6 -0
- package/dist/ui/src/components/Tooltip/types.d.ts.map +1 -1
- package/dist/ui/src/components/internal/ModalPresentation.d.ts +62 -0
- package/dist/ui/src/components/internal/ModalPresentation.d.ts.map +1 -0
- package/dist/ui/src/components/internal/OverlayPortalContext.d.ts +10 -0
- package/dist/ui/src/components/internal/OverlayPortalContext.d.ts.map +1 -0
- package/dist/ui/src/index.d.ts +7 -1
- package/dist/ui/src/index.d.ts.map +1 -1
- package/dist/ui/src/utils/motion.d.ts.map +1 -1
- package/dist/utils/motion.js +194 -135
- package/docs/api-conventions.md +4 -0
- package/docs/motion.md +4 -0
- package/docs/overlay-stacking.md +48 -0
- package/docs/responsive-foundation-profile.md +1 -1
- package/docs/scss-helpers.md +110 -5
- package/docs/selector-contract.md +126 -2
- package/docs/tokens.md +2 -0
- package/package.json +1 -1
- package/src/scss/foundations/atomic.scss +9 -8
- package/src/scss/index.scss +2 -0
- package/src/scss/mixins/_fluid.scss +57 -0
- package/src/scss/mixins/_fluid.test.ts +87 -0
- package/src/scss/mixins/_gradient.scss +99 -0
- package/src/scss/mixins/_gradient.test.ts +111 -0
- package/src/scss/mixins/_responsive.scss +2 -1
- package/src/scss/mixins/_typo.scss +2 -1
- package/src/scss/mixins/_units.scss +14 -0
- package/src/scss/mixins/_utils.scss +3 -22
|
@@ -0,0 +1,361 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { jsx as t, jsxs as g } from "react/jsx-runtime";
|
|
3
|
+
import { useCallback as B, useEffect as Z, useId as _, useState as aa } from "react";
|
|
4
|
+
import { Dialog as ea } from "@base-ui-components/react/dialog";
|
|
5
|
+
import { MotionExpand as oa } from "../../react/motion.js";
|
|
6
|
+
import { mergeRefs as ta } from "../../utils/mergeRefs.js";
|
|
7
|
+
import na from "../Background/Background.js";
|
|
8
|
+
import ra from "../Interaction/Interaction.js";
|
|
9
|
+
import { ScrollArea as z, ScrollAreaContainer as F } from "../ScrollArea/ScrollArea.js";
|
|
10
|
+
import { DisclosureIndicator as ia } from "./DisclosureIndicator.js";
|
|
11
|
+
import { normalizeSlotIcon as la } from "./slot.js";
|
|
12
|
+
import e from "../Modal/Modal.module.scss.js";
|
|
13
|
+
import { getModalScrollState as ca } from "../Modal/modalScrollArbitration.js";
|
|
14
|
+
import { useControllableState as da } from "../Modal/useControllableState.js";
|
|
15
|
+
import { useMeasuredElement as sa } from "../Modal/useElementSize.js";
|
|
16
|
+
function d(...a) {
|
|
17
|
+
return a.filter(Boolean).join(" ");
|
|
18
|
+
}
|
|
19
|
+
function C(a) {
|
|
20
|
+
return a != null && a !== !1 && a !== "";
|
|
21
|
+
}
|
|
22
|
+
function xa(a, n) {
|
|
23
|
+
return a === !0 || a === "auto" && n.canScroll && !n.scrolledToBottom;
|
|
24
|
+
}
|
|
25
|
+
function Ba({
|
|
26
|
+
bodyNode: a,
|
|
27
|
+
bodyRef: n,
|
|
28
|
+
setBodyNode: i,
|
|
29
|
+
setScrollState: l
|
|
30
|
+
}) {
|
|
31
|
+
const r = B(
|
|
32
|
+
(o) => {
|
|
33
|
+
l(ca(o));
|
|
34
|
+
},
|
|
35
|
+
[l]
|
|
36
|
+
), m = B(
|
|
37
|
+
(o) => {
|
|
38
|
+
ta(i, n, r)(o);
|
|
39
|
+
},
|
|
40
|
+
[n, i, r]
|
|
41
|
+
);
|
|
42
|
+
return Z(() => {
|
|
43
|
+
const o = a;
|
|
44
|
+
if (!o || (r(o), typeof ResizeObserver > "u")) return;
|
|
45
|
+
const s = new ResizeObserver(() => r(o));
|
|
46
|
+
return s.observe(o), o.firstElementChild && s.observe(o.firstElementChild), () => s.disconnect();
|
|
47
|
+
}, [a, r]), { setBodyRef: m, updateScrollState: r };
|
|
48
|
+
}
|
|
49
|
+
function za({
|
|
50
|
+
children: a,
|
|
51
|
+
className: n,
|
|
52
|
+
contentTransition: i,
|
|
53
|
+
placement: l,
|
|
54
|
+
ref: r,
|
|
55
|
+
resize: m,
|
|
56
|
+
scrollable: o,
|
|
57
|
+
size: s,
|
|
58
|
+
style: p,
|
|
59
|
+
variant: u
|
|
60
|
+
}) {
|
|
61
|
+
return /* @__PURE__ */ t(
|
|
62
|
+
"div",
|
|
63
|
+
{
|
|
64
|
+
ref: r,
|
|
65
|
+
className: d(e.surface, e[m], n),
|
|
66
|
+
"data-oc-part": "surface",
|
|
67
|
+
"data-oc-variant": u,
|
|
68
|
+
"data-oc-size": s,
|
|
69
|
+
"data-oc-resize": m,
|
|
70
|
+
"data-oc-content-transition": i,
|
|
71
|
+
"data-oc-modal-placement": l,
|
|
72
|
+
"data-oc-scrollable": o ? "true" : "false",
|
|
73
|
+
style: p,
|
|
74
|
+
children: a
|
|
75
|
+
}
|
|
76
|
+
);
|
|
77
|
+
}
|
|
78
|
+
function Fa({
|
|
79
|
+
bottomSlot: a,
|
|
80
|
+
children: n,
|
|
81
|
+
className: i = "",
|
|
82
|
+
closeContent: l,
|
|
83
|
+
dragEnabled: r,
|
|
84
|
+
handleContent: m,
|
|
85
|
+
leadingContent: o,
|
|
86
|
+
sticky: s,
|
|
87
|
+
titleContent: p,
|
|
88
|
+
trailingContent: u,
|
|
89
|
+
...h
|
|
90
|
+
}) {
|
|
91
|
+
const v = C(o), N = C(a);
|
|
92
|
+
return /* @__PURE__ */ g(
|
|
93
|
+
na,
|
|
94
|
+
{
|
|
95
|
+
...h,
|
|
96
|
+
as: "header",
|
|
97
|
+
backdrop: "compact",
|
|
98
|
+
className: d(e.header, i),
|
|
99
|
+
backColor: "var(--oc-color-theme-background-elevated-normal)",
|
|
100
|
+
frontColor: "transparent",
|
|
101
|
+
"data-oc-part": "header",
|
|
102
|
+
"data-oc-component": "modal-header",
|
|
103
|
+
variant: "strong",
|
|
104
|
+
"data-oc-draggable": r === void 0 ? void 0 : String(r),
|
|
105
|
+
"data-oc-sticky": s ? "true" : "false",
|
|
106
|
+
children: [
|
|
107
|
+
m,
|
|
108
|
+
/* @__PURE__ */ g(
|
|
109
|
+
"div",
|
|
110
|
+
{
|
|
111
|
+
className: e.headerInner,
|
|
112
|
+
"data-oc-has-leading": v ? "true" : "false",
|
|
113
|
+
"data-oc-part": "header-inner",
|
|
114
|
+
children: [
|
|
115
|
+
v ? /* @__PURE__ */ t("div", { className: e.headerLeading, "data-oc-part": "header-leading", children: o }) : null,
|
|
116
|
+
/* @__PURE__ */ t("div", { className: e.headerTitle, "data-oc-part": "header-title", children: p ?? n }),
|
|
117
|
+
/* @__PURE__ */ g("div", { className: e.headerTrailing, "data-oc-part": "header-trailing", children: [
|
|
118
|
+
u,
|
|
119
|
+
l
|
|
120
|
+
] })
|
|
121
|
+
]
|
|
122
|
+
}
|
|
123
|
+
),
|
|
124
|
+
N ? /* @__PURE__ */ t("div", { className: e.headerBottom, "data-oc-part": "header-bottom", children: a }) : null
|
|
125
|
+
]
|
|
126
|
+
}
|
|
127
|
+
);
|
|
128
|
+
}
|
|
129
|
+
function Pa({
|
|
130
|
+
className: a = "",
|
|
131
|
+
title: n,
|
|
132
|
+
children: i,
|
|
133
|
+
expanded: l,
|
|
134
|
+
defaultExpanded: r = !0,
|
|
135
|
+
onExpandedChange: m,
|
|
136
|
+
disabled: o = !1,
|
|
137
|
+
forceMount: s = !0,
|
|
138
|
+
headingLevel: p = 2,
|
|
139
|
+
indicator: u,
|
|
140
|
+
titleAsDialogTitle: h = !0,
|
|
141
|
+
navigationProps: v,
|
|
142
|
+
panelProps: N,
|
|
143
|
+
panelContentProps: P,
|
|
144
|
+
ref: T,
|
|
145
|
+
style: S,
|
|
146
|
+
canRenderHandle: R,
|
|
147
|
+
handleProps: M,
|
|
148
|
+
onPanelMotionStateChange: E,
|
|
149
|
+
...H
|
|
150
|
+
}) {
|
|
151
|
+
const { height: y, setNode: $ } = sa(), b = _(), [c, j] = da({
|
|
152
|
+
value: l,
|
|
153
|
+
defaultValue: r,
|
|
154
|
+
onChange: m
|
|
155
|
+
}), [D, L] = aa(
|
|
156
|
+
c ? "open" : "closed"
|
|
157
|
+
), O = `h${p >= 2 && p <= 6 ? p : 2}`, {
|
|
158
|
+
className: w = "",
|
|
159
|
+
id: A,
|
|
160
|
+
onClick: V,
|
|
161
|
+
...I
|
|
162
|
+
} = v ?? {}, {
|
|
163
|
+
className: q = "",
|
|
164
|
+
id: G,
|
|
165
|
+
role: J,
|
|
166
|
+
...K
|
|
167
|
+
} = N ?? {}, { className: Q = "", ...U } = P ?? {}, k = A ?? `${b}-navigation`, x = G ?? `${b}-panel`, W = `${b}-dialog-title`, X = C(n), Y = y > 0 ? {
|
|
168
|
+
...S,
|
|
169
|
+
"--oc-modal-navigation-block-size": `${y}px`
|
|
170
|
+
} : S;
|
|
171
|
+
return /* @__PURE__ */ g(
|
|
172
|
+
"section",
|
|
173
|
+
{
|
|
174
|
+
ref: T,
|
|
175
|
+
className: d(e.navigationSection, a),
|
|
176
|
+
style: Y,
|
|
177
|
+
...H,
|
|
178
|
+
"data-oc-component": "modal-navigation-section",
|
|
179
|
+
"data-oc-motion-state": D,
|
|
180
|
+
"data-oc-state": c ? "open" : "closed",
|
|
181
|
+
children: [
|
|
182
|
+
h && X ? /* @__PURE__ */ t(
|
|
183
|
+
ea.Title,
|
|
184
|
+
{
|
|
185
|
+
className: e.navigationDialogTitle,
|
|
186
|
+
id: W,
|
|
187
|
+
children: n
|
|
188
|
+
}
|
|
189
|
+
) : null,
|
|
190
|
+
R ? /* @__PURE__ */ t(
|
|
191
|
+
"div",
|
|
192
|
+
{
|
|
193
|
+
...M,
|
|
194
|
+
"aria-hidden": "true",
|
|
195
|
+
className: d(e.handle, M?.className),
|
|
196
|
+
"data-oc-part": "handle"
|
|
197
|
+
}
|
|
198
|
+
) : null,
|
|
199
|
+
/* @__PURE__ */ t(O, { className: e.navigationHeading, "data-oc-part": "heading", children: /* @__PURE__ */ g(
|
|
200
|
+
"button",
|
|
201
|
+
{
|
|
202
|
+
...I,
|
|
203
|
+
ref: $,
|
|
204
|
+
id: k,
|
|
205
|
+
className: d(
|
|
206
|
+
e.navigation,
|
|
207
|
+
w
|
|
208
|
+
),
|
|
209
|
+
type: "button",
|
|
210
|
+
disabled: o,
|
|
211
|
+
"aria-disabled": o ? "true" : I["aria-disabled"],
|
|
212
|
+
"aria-expanded": c,
|
|
213
|
+
"aria-controls": x,
|
|
214
|
+
onClick: (f) => {
|
|
215
|
+
V?.(f), !(f.defaultPrevented || o) && j(!c);
|
|
216
|
+
},
|
|
217
|
+
"data-oc-component": "modal-navigation",
|
|
218
|
+
"data-oc-part": "navigation",
|
|
219
|
+
"data-oc-state": c ? "open" : "closed",
|
|
220
|
+
children: [
|
|
221
|
+
/* @__PURE__ */ t("span", { className: e.navigationTitle, "data-oc-part": "title", children: n }),
|
|
222
|
+
u === void 0 ? /* @__PURE__ */ t(
|
|
223
|
+
ia,
|
|
224
|
+
{
|
|
225
|
+
className: e.navigationIndicator,
|
|
226
|
+
open: c
|
|
227
|
+
}
|
|
228
|
+
) : u ? /* @__PURE__ */ t(
|
|
229
|
+
"span",
|
|
230
|
+
{
|
|
231
|
+
className: e.navigationIndicator,
|
|
232
|
+
"data-oc-part": "indicator",
|
|
233
|
+
"data-oc-state": c ? "open" : "closed",
|
|
234
|
+
children: /* @__PURE__ */ t("span", { "data-oc-part": "indicator-frame", children: la(u) })
|
|
235
|
+
}
|
|
236
|
+
) : null,
|
|
237
|
+
o ? null : /* @__PURE__ */ t(ra, { variant: "light" })
|
|
238
|
+
]
|
|
239
|
+
}
|
|
240
|
+
) }),
|
|
241
|
+
/* @__PURE__ */ t(
|
|
242
|
+
oa,
|
|
243
|
+
{
|
|
244
|
+
className: d(e.navigationPanel, q),
|
|
245
|
+
open: c,
|
|
246
|
+
forceMount: s,
|
|
247
|
+
intent: "expand",
|
|
248
|
+
measureBlockSize: "rendered",
|
|
249
|
+
onMotionStateChange: (f) => {
|
|
250
|
+
L(f), E?.(f);
|
|
251
|
+
},
|
|
252
|
+
contentProps: {
|
|
253
|
+
className: e.navigationPanelFrame,
|
|
254
|
+
"data-oc-part": "panel-inner"
|
|
255
|
+
},
|
|
256
|
+
...K,
|
|
257
|
+
"aria-hidden": c ? void 0 : !0,
|
|
258
|
+
"aria-labelledby": k,
|
|
259
|
+
id: x,
|
|
260
|
+
inert: c ? void 0 : !0,
|
|
261
|
+
role: J ?? "region",
|
|
262
|
+
"data-oc-component": "modal-navigation-panel",
|
|
263
|
+
"data-oc-state": c ? "open" : "closed",
|
|
264
|
+
children: /* @__PURE__ */ t(
|
|
265
|
+
z,
|
|
266
|
+
{
|
|
267
|
+
className: e.navigationPanelScroll,
|
|
268
|
+
"data-oc-component": "modal-navigation-panel-scroll-area",
|
|
269
|
+
"data-oc-part": "panel-scroll-area",
|
|
270
|
+
children: /* @__PURE__ */ t(
|
|
271
|
+
F,
|
|
272
|
+
{
|
|
273
|
+
...U,
|
|
274
|
+
className: d(
|
|
275
|
+
e.navigationPanelInner,
|
|
276
|
+
Q
|
|
277
|
+
),
|
|
278
|
+
"data-oc-component": "modal-navigation-panel-content",
|
|
279
|
+
children: i
|
|
280
|
+
}
|
|
281
|
+
)
|
|
282
|
+
}
|
|
283
|
+
)
|
|
284
|
+
}
|
|
285
|
+
)
|
|
286
|
+
]
|
|
287
|
+
}
|
|
288
|
+
);
|
|
289
|
+
}
|
|
290
|
+
function Ta({
|
|
291
|
+
bodyContainerProps: a,
|
|
292
|
+
bodyContentProps: n,
|
|
293
|
+
children: i,
|
|
294
|
+
layout: l,
|
|
295
|
+
scrollAreaProps: r
|
|
296
|
+
}) {
|
|
297
|
+
return /* @__PURE__ */ t(
|
|
298
|
+
z,
|
|
299
|
+
{
|
|
300
|
+
...r,
|
|
301
|
+
className: d(e.body, r?.className),
|
|
302
|
+
"data-oc-part": "body",
|
|
303
|
+
"data-oc-component": "modal-body",
|
|
304
|
+
children: /* @__PURE__ */ t(
|
|
305
|
+
F,
|
|
306
|
+
{
|
|
307
|
+
...a,
|
|
308
|
+
className: d(
|
|
309
|
+
e.bodyContainer,
|
|
310
|
+
a?.className
|
|
311
|
+
),
|
|
312
|
+
"data-oc-part": "body-container",
|
|
313
|
+
"data-oc-component": "modal-body-container",
|
|
314
|
+
children: /* @__PURE__ */ t(
|
|
315
|
+
"section",
|
|
316
|
+
{
|
|
317
|
+
...n,
|
|
318
|
+
className: d(
|
|
319
|
+
e.bodyContent,
|
|
320
|
+
n?.className
|
|
321
|
+
),
|
|
322
|
+
"data-oc-part": "body-content",
|
|
323
|
+
"data-oc-component": "modal-body-content",
|
|
324
|
+
"data-oc-layout": l,
|
|
325
|
+
children: i
|
|
326
|
+
}
|
|
327
|
+
)
|
|
328
|
+
}
|
|
329
|
+
)
|
|
330
|
+
}
|
|
331
|
+
);
|
|
332
|
+
}
|
|
333
|
+
function Ra({
|
|
334
|
+
backgroundActive: a,
|
|
335
|
+
children: n,
|
|
336
|
+
className: i = "",
|
|
337
|
+
...l
|
|
338
|
+
}) {
|
|
339
|
+
return /* @__PURE__ */ t(
|
|
340
|
+
"footer",
|
|
341
|
+
{
|
|
342
|
+
...l,
|
|
343
|
+
className: d(e.footer, i),
|
|
344
|
+
"data-oc-part": "footer",
|
|
345
|
+
"data-oc-component": "modal-footer",
|
|
346
|
+
"data-oc-background": a ? "true" : "false",
|
|
347
|
+
children: n
|
|
348
|
+
}
|
|
349
|
+
);
|
|
350
|
+
}
|
|
351
|
+
export {
|
|
352
|
+
Ta as ModalBodyFrame,
|
|
353
|
+
Ra as ModalFooterFrame,
|
|
354
|
+
Fa as ModalHeaderFrame,
|
|
355
|
+
Pa as ModalNavigationSectionFrame,
|
|
356
|
+
za as ModalSurfaceFrame,
|
|
357
|
+
C as hasRenderableModalContent,
|
|
358
|
+
d as mergeModalClassName,
|
|
359
|
+
xa as resolveModalFooterBackground,
|
|
360
|
+
Ba as useModalBodyScrollState
|
|
361
|
+
};
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
'use client';
|
|
2
|
+
import { jsx as e } from "react/jsx-runtime";
|
|
3
|
+
import { useContext as n, createContext as a } from "react";
|
|
4
|
+
const t = a(
|
|
5
|
+
void 0
|
|
6
|
+
);
|
|
7
|
+
function u({
|
|
8
|
+
children: r,
|
|
9
|
+
container: o
|
|
10
|
+
}) {
|
|
11
|
+
return /* @__PURE__ */ e(t.Provider, { value: o, children: r });
|
|
12
|
+
}
|
|
13
|
+
function l(r) {
|
|
14
|
+
const o = n(t);
|
|
15
|
+
return r === void 0 ? o : r;
|
|
16
|
+
}
|
|
17
|
+
export {
|
|
18
|
+
u as OverlayPortalProvider,
|
|
19
|
+
l as useOverlayPortalContainer
|
|
20
|
+
};
|
package/dist/index.js
CHANGED
|
@@ -1,116 +1,139 @@
|
|
|
1
|
-
import { default as
|
|
1
|
+
import { default as e } from "./components/SectionHeader/SectionHeader.js";
|
|
2
2
|
import { default as a } from "./components/Button/Button.js";
|
|
3
|
-
import { default as
|
|
4
|
-
import { default as
|
|
5
|
-
import { default as m } from "./components/
|
|
6
|
-
import { default as
|
|
7
|
-
import { default as
|
|
8
|
-
import { default as
|
|
9
|
-
import { default as
|
|
10
|
-
import { default as
|
|
11
|
-
import { default as
|
|
12
|
-
import { default as
|
|
13
|
-
import { default as
|
|
14
|
-
import { default as
|
|
15
|
-
import {
|
|
16
|
-
import {
|
|
17
|
-
import {
|
|
18
|
-
import {
|
|
19
|
-
import { default as
|
|
20
|
-
import { default as
|
|
21
|
-
import { default as
|
|
22
|
-
import { default as
|
|
23
|
-
import { default as
|
|
24
|
-
import { default as
|
|
25
|
-
import { default as
|
|
26
|
-
import { default as
|
|
27
|
-
import {
|
|
28
|
-
import { default as
|
|
29
|
-
import {
|
|
30
|
-
import {
|
|
31
|
-
import {
|
|
32
|
-
import {
|
|
33
|
-
import {
|
|
34
|
-
import {
|
|
35
|
-
import {
|
|
3
|
+
import { default as i, PositionSnapHandle as l, PositionSnapPositioner as d, PositionSnapRoot as f } from "./components/PositionSnap/PositionSnap.js";
|
|
4
|
+
import { default as s, ActionAreaButton as u } from "./components/ActionArea/ActionArea.js";
|
|
5
|
+
import { default as m, ActionAreaLayoutActionArea as c, ActionAreaLayoutBody as A, ActionAreaLayoutFooter as g, ActionAreaLayout as F } from "./components/ActionArea/ActionAreaLayout.js";
|
|
6
|
+
import { default as T } from "./components/Badge/Badge.js";
|
|
7
|
+
import { default as S } from "./components/Background/Background.js";
|
|
8
|
+
import { default as W } from "./components/Divider/Divider.js";
|
|
9
|
+
import { default as y } from "./components/Loading/Loading.js";
|
|
10
|
+
import { default as L } from "./components/ProgressIndicator/ProgressIndicator.js";
|
|
11
|
+
import { default as k } from "./components/Skeleton/Skeleton.js";
|
|
12
|
+
import { default as b, CellItem as D } from "./components/Cell/Cell.js";
|
|
13
|
+
import { default as v } from "./components/TextButton/TextButton.js";
|
|
14
|
+
import { default as N } from "./components/IconButton/IconButton.js";
|
|
15
|
+
import { default as G } from "./components/BackgroundIconButton/BackgroundIconButton.js";
|
|
16
|
+
import { default as q } from "./components/Interaction/Interaction.js";
|
|
17
|
+
import { Field as J, FieldControl as K, FieldErrorMessage as O, FieldLabel as Q, FieldMessage as U } from "./components/Field/Field.js";
|
|
18
|
+
import { FieldGroup as X, FieldLegend as Y, Fieldset as Z, FieldsetContent as _ } from "./components/Fieldset/Fieldset.js";
|
|
19
|
+
import { default as oo } from "./components/Checkbox/Checkbox.js";
|
|
20
|
+
import { default as eo } from "./components/CheckMark/CheckMark.js";
|
|
21
|
+
import { default as ao } from "./components/Radio/Radio.js";
|
|
22
|
+
import { default as io } from "./components/Switch/Switch.js";
|
|
23
|
+
import { default as fo } from "./components/TextInput/TextInput.js";
|
|
24
|
+
import { default as so } from "./components/TextInput/TextInputContent.js";
|
|
25
|
+
import { default as xo } from "./components/TextArea/TextArea.js";
|
|
26
|
+
import { default as co } from "./components/TextArea/TextAreaContent.js";
|
|
27
|
+
import { default as go } from "./components/Select/Select.js";
|
|
28
|
+
import { default as Mo } from "./components/Select/SelectContent.js";
|
|
29
|
+
import { MenuContent as Co, MenuItem as So, MenuRoot as wo, MenuSeparator as Wo, MenuTrigger as Bo } from "./components/Menu/Menu.js";
|
|
30
|
+
import { default as Io, FloatingWindowBody as Lo, FloatingWindowClose as Ro, FloatingWindowContent as ko, FloatingWindowDescription as Po, FloatingWindowDragHandle as bo, FloatingWindowFooter as Do, FloatingWindowHeader as Ho, FloatingWindowNavigationSection as vo, FloatingWindowRoot as ho, FloatingWindowTitle as No, FloatingWindowTrigger as Eo, ModalWindowRoot as Go } from "./components/FloatingWindow/FloatingWindow.js";
|
|
31
|
+
import { FloatingWindowManager as qo } from "./components/FloatingWindow/FloatingWindowManager.js";
|
|
32
|
+
import { default as Jo, AlertAction as Ko, AlertActionArea as Oo, AlertContent as Qo, AlertDescription as Uo, AlertHeading as Vo, AlertRoot as Xo } from "./components/Alert/Alert.js";
|
|
33
|
+
import { default as Zo, AccordionContent as _o, AccordionDescription as $o, AccordionDetails as ot, AccordionItem as tt, AccordionSummary as et } from "./components/Accordion/Accordion.js";
|
|
34
|
+
import { TabsList as at, TabsPanel as nt, TabsRoot as it, TabsTab as lt } from "./components/Tabs/Tabs.js";
|
|
35
|
+
import { default as ft, ModalBody as pt, ModalClose as st, ModalContent as ut, ModalFooter as xt, ModalHeader as mt, ModalNavigationSection as ct, ModalRoot as At, ModalTrigger as gt } from "./components/Modal/Modal.js";
|
|
36
|
+
import { TooltipContent as Mt, TooltipProvider as Tt, TooltipRoot as Ct, TooltipTrigger as St } from "./components/Tooltip/Tooltip.js";
|
|
37
|
+
import { ScrollArea as Wt, ScrollAreaContainer as Bt } from "./components/ScrollArea/ScrollArea.js";
|
|
38
|
+
import { getBreakpoint as It, getBreakpoints as Lt } from "./utils/breakpoints.js";
|
|
39
|
+
import { SvgIcon as kt } from "@orioncactuscorp/icons";
|
|
36
40
|
export {
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
41
|
+
Zo as Accordion,
|
|
42
|
+
_o as AccordionContent,
|
|
43
|
+
$o as AccordionDescription,
|
|
44
|
+
ot as AccordionDetails,
|
|
45
|
+
tt as AccordionItem,
|
|
46
|
+
et as AccordionSummary,
|
|
47
|
+
s as ActionArea,
|
|
48
|
+
u as ActionAreaButton,
|
|
49
|
+
m as ActionAreaLayout,
|
|
50
|
+
c as ActionAreaLayoutActionArea,
|
|
51
|
+
A as ActionAreaLayoutBody,
|
|
52
|
+
g as ActionAreaLayoutFooter,
|
|
53
|
+
F as ActionAreaLayoutRoot,
|
|
54
|
+
Jo as Alert,
|
|
55
|
+
Ko as AlertAction,
|
|
56
|
+
Oo as AlertActionArea,
|
|
57
|
+
Qo as AlertContent,
|
|
58
|
+
Uo as AlertDescription,
|
|
59
|
+
Vo as AlertHeading,
|
|
60
|
+
Xo as AlertRoot,
|
|
61
|
+
S as Background,
|
|
62
|
+
G as BackgroundIconButton,
|
|
63
|
+
T as Badge,
|
|
60
64
|
a as Button,
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
|
|
81
|
-
|
|
82
|
-
|
|
83
|
-
qo as
|
|
84
|
-
|
|
85
|
-
|
|
86
|
-
|
|
87
|
-
|
|
88
|
-
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
|
|
101
|
-
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
108
|
-
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
65
|
+
b as Cell,
|
|
66
|
+
D as CellItem,
|
|
67
|
+
eo as CheckMark,
|
|
68
|
+
oo as Checkbox,
|
|
69
|
+
W as Divider,
|
|
70
|
+
J as Field,
|
|
71
|
+
K as FieldControl,
|
|
72
|
+
O as FieldErrorMessage,
|
|
73
|
+
X as FieldGroup,
|
|
74
|
+
Q as FieldLabel,
|
|
75
|
+
Y as FieldLegend,
|
|
76
|
+
U as FieldMessage,
|
|
77
|
+
Z as Fieldset,
|
|
78
|
+
_ as FieldsetContent,
|
|
79
|
+
Io as FloatingWindow,
|
|
80
|
+
Lo as FloatingWindowBody,
|
|
81
|
+
Ro as FloatingWindowClose,
|
|
82
|
+
ko as FloatingWindowContent,
|
|
83
|
+
Po as FloatingWindowDescription,
|
|
84
|
+
bo as FloatingWindowDragHandle,
|
|
85
|
+
Do as FloatingWindowFooter,
|
|
86
|
+
Ho as FloatingWindowHeader,
|
|
87
|
+
qo as FloatingWindowManager,
|
|
88
|
+
vo as FloatingWindowNavigationSection,
|
|
89
|
+
ho as FloatingWindowRoot,
|
|
90
|
+
No as FloatingWindowTitle,
|
|
91
|
+
Eo as FloatingWindowTrigger,
|
|
92
|
+
N as IconButton,
|
|
93
|
+
q as Interaction,
|
|
94
|
+
y as Loading,
|
|
95
|
+
Co as MenuContent,
|
|
96
|
+
So as MenuItem,
|
|
97
|
+
wo as MenuRoot,
|
|
98
|
+
Wo as MenuSeparator,
|
|
99
|
+
Bo as MenuTrigger,
|
|
100
|
+
ft as Modal,
|
|
101
|
+
pt as ModalBody,
|
|
102
|
+
st as ModalClose,
|
|
103
|
+
ut as ModalContent,
|
|
104
|
+
xt as ModalFooter,
|
|
105
|
+
mt as ModalHeader,
|
|
106
|
+
ct as ModalNavigationSection,
|
|
107
|
+
At as ModalRoot,
|
|
108
|
+
gt as ModalTrigger,
|
|
109
|
+
Go as ModalWindowRoot,
|
|
110
|
+
i as PositionSnap,
|
|
111
|
+
l as PositionSnapHandle,
|
|
112
|
+
d as PositionSnapPositioner,
|
|
113
|
+
f as PositionSnapRoot,
|
|
114
|
+
L as ProgressIndicator,
|
|
115
|
+
ao as Radio,
|
|
116
|
+
Wt as ScrollArea,
|
|
117
|
+
Bt as ScrollAreaContainer,
|
|
118
|
+
e as SectionHeader,
|
|
119
|
+
go as Select,
|
|
120
|
+
Mo as SelectContent,
|
|
121
|
+
k as Skeleton,
|
|
122
|
+
kt as SvgIcon,
|
|
123
|
+
io as Switch,
|
|
124
|
+
at as TabsList,
|
|
125
|
+
nt as TabsPanel,
|
|
126
|
+
it as TabsRoot,
|
|
127
|
+
lt as TabsTab,
|
|
128
|
+
xo as TextArea,
|
|
129
|
+
co as TextAreaContent,
|
|
130
|
+
v as TextButton,
|
|
131
|
+
fo as TextInput,
|
|
132
|
+
so as TextInputContent,
|
|
133
|
+
Mt as TooltipContent,
|
|
134
|
+
Tt as TooltipProvider,
|
|
135
|
+
Ct as TooltipRoot,
|
|
136
|
+
St as TooltipTrigger,
|
|
137
|
+
It as getBreakpoint,
|
|
138
|
+
Lt as getBreakpoints
|
|
116
139
|
};
|