@astryxdesign/lab 0.4.0-canary.ba1f131 → 0.4.0-canary.dad87f5
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/BottomSheet/BottomSheet.d.ts +2 -1
- package/dist/BottomSheet/BottomSheet.d.ts.map +1 -1
- package/dist/BottomSheet/BottomSheet.js +23 -9
- package/dist/index.d.ts +0 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -3
- package/dist/lab.css +0 -43
- package/package.json +5 -62
- package/src/BottomSheet/BottomSheet.doc.mjs +83 -24
- package/src/BottomSheet/BottomSheet.test.tsx +53 -0
- package/src/BottomSheet/BottomSheet.tsx +22 -8
- package/src/ListInput/ListInput.doc.mjs +3 -3
- package/src/TransferList/TransferList.doc.mjs +1 -1
- package/src/index.ts +4 -28
- package/dist/RichTextEditor/RichTextEditor.d.ts +0 -247
- package/dist/RichTextEditor/RichTextEditor.d.ts.map +0 -1
- package/dist/RichTextEditor/RichTextEditor.js +0 -558
- package/dist/RichTextEditor/RichTextEditorAutoLinkPlugin.d.ts +0 -84
- package/dist/RichTextEditor/RichTextEditorAutoLinkPlugin.d.ts.map +0 -1
- package/dist/RichTextEditor/RichTextEditorAutoLinkPlugin.js +0 -94
- package/dist/RichTextEditor/RichTextEditorToolbar.d.ts +0 -132
- package/dist/RichTextEditor/RichTextEditorToolbar.d.ts.map +0 -1
- package/dist/RichTextEditor/RichTextEditorToolbar.js +0 -776
- package/dist/RichTextEditor/RichTextView.d.ts +0 -65
- package/dist/RichTextEditor/RichTextView.d.ts.map +0 -1
- package/dist/RichTextEditor/RichTextView.js +0 -168
- package/dist/RichTextEditor/editorNodes.d.ts +0 -8
- package/dist/RichTextEditor/editorNodes.d.ts.map +0 -1
- package/dist/RichTextEditor/editorNodes.js +0 -23
- package/dist/RichTextEditor/editorTheme.d.ts +0 -7
- package/dist/RichTextEditor/editorTheme.d.ts.map +0 -1
- package/dist/RichTextEditor/editorTheme.js +0 -102
- package/dist/RichTextEditor/index.d.ts +0 -22
- package/dist/RichTextEditor/index.d.ts.map +0 -1
- package/dist/RichTextEditor/index.js +0 -20
- package/dist/RichTextEditor/linkUtils.d.ts +0 -22
- package/dist/RichTextEditor/linkUtils.d.ts.map +0 -1
- package/dist/RichTextEditor/linkUtils.js +0 -91
- package/dist/RichTextEditor/markdownSerializers.d.ts +0 -40
- package/dist/RichTextEditor/markdownSerializers.d.ts.map +0 -1
- package/dist/RichTextEditor/markdownSerializers.js +0 -85
- package/src/RichTextEditor/RichTextEditor.doc.mjs +0 -218
- package/src/RichTextEditor/RichTextEditor.test.tsx +0 -1671
- package/src/RichTextEditor/RichTextEditor.tsx +0 -945
- package/src/RichTextEditor/RichTextEditorAutoLinkPlugin.tsx +0 -115
- package/src/RichTextEditor/RichTextEditorToolbar.tsx +0 -971
- package/src/RichTextEditor/RichTextView.tsx +0 -227
- package/src/RichTextEditor/editorNodes.ts +0 -34
- package/src/RichTextEditor/editorTheme.ts +0 -185
- package/src/RichTextEditor/index.ts +0 -54
- package/src/RichTextEditor/linkUtils.ts +0 -93
- package/src/RichTextEditor/markdownSerializers.ts +0 -105
|
@@ -17,7 +17,8 @@
|
|
|
17
17
|
* layer, focus trap, scrim, scroll lock, background inert); `false` uses
|
|
18
18
|
* `show()` for a non-modal sheet with no scrim, leaving the page behind
|
|
19
19
|
* interactive and scrollable (the transparent shell is pointer-events:none so
|
|
20
|
-
* taps pass through).
|
|
20
|
+
* taps pass through). Both modes keep the native dialog presented but inert
|
|
21
|
+
* until the slide-out transition ends.
|
|
21
22
|
*
|
|
22
23
|
* The drag/snap/dismiss machinery lives in `useSheetGestures`; the offset
|
|
23
24
|
* geometry lives in the pure, tested `snapOffsets` module. Both are internal
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"BottomSheet.d.ts","sourceRoot":"","sources":["../../src/BottomSheet/BottomSheet.tsx"],"names":[],"mappings":"AAIA
|
|
1
|
+
{"version":3,"file":"BottomSheet.d.ts","sourceRoot":"","sources":["../../src/BottomSheet/BottomSheet.tsx"],"names":[],"mappings":"AAIA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+BG;AAEH,OAAO,EAA2C,KAAK,SAAS,EAAC,MAAM,OAAO,CAAC;AAE/E,OAAO,KAAK,EAAC,SAAS,EAAC,MAAM,oBAAoB,CAAC;AA2BlD;;;;;;GAMG;AACH,QAAA,MAAM,cAAc;;;;CAIV,CAAC;AAEX,MAAM,MAAM,iBAAiB,GAAG,MAAM,OAAO,cAAc,CAAC;AAoL5D,MAAM,WAAW,gBAAiB,SAAQ,SAAS,CAAC,iBAAiB,CAAC;IACpE,wDAAwD;IACxD,GAAG,CAAC,EAAE,KAAK,CAAC,GAAG,CAAC,iBAAiB,CAAC,CAAC;IAEnC,8EAA8E;IAC9E,MAAM,EAAE,OAAO,CAAC;IAEhB;;;;OAIG;IACH,YAAY,EAAE,CAAC,MAAM,EAAE,OAAO,KAAK,IAAI,CAAC;IAExC;;;OAGG;IACH,KAAK,EAAE,MAAM,CAAC;IAEd,0EAA0E;IAC1E,QAAQ,EAAE,SAAS,CAAC;IAEpB;;;;;;;;;;;;;OAaG;IACH,MAAM,CAAC,EAAE,iBAAiB,GAAG,MAAM,GAAG,MAAM,CAAC;IAE7C;;;;;;;;;;;;OAYG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAC;IAEnB,oCAAoC;IACpC,aAAa,CAAC,EAAE,MAAM,CAAC;CACxB;AAED;;;;;;;;;;;;;;;;;;;;;GAqBG;AACH,wBAAgB,WAAW,CAAC,EAC1B,GAAG,EACH,MAAM,EACN,YAAY,EACZ,KAAK,EACL,QAAQ,EACR,MAAiB,EACjB,QAAe,EACf,MAAM,EACN,GAAG,KAAK,EACT,EAAE,gBAAgB,+BAoMlB;yBA9Me,WAAW"}
|
|
@@ -21,7 +21,8 @@
|
|
|
21
21
|
* layer, focus trap, scrim, scroll lock, background inert); `false` uses
|
|
22
22
|
* `show()` for a non-modal sheet with no scrim, leaving the page behind
|
|
23
23
|
* interactive and scrollable (the transparent shell is pointer-events:none so
|
|
24
|
-
* taps pass through).
|
|
24
|
+
* taps pass through). Both modes keep the native dialog presented but inert
|
|
25
|
+
* until the slide-out transition ends.
|
|
25
26
|
*
|
|
26
27
|
* The drag/snap/dismiss machinery lives in `useSheetGestures`; the offset
|
|
27
28
|
* geometry lives in the pure, tested `snapOffsets` module. Both are internal
|
|
@@ -33,7 +34,7 @@
|
|
|
33
34
|
* - /packages/lab/src/BottomSheet/index.ts (exports if types change)
|
|
34
35
|
* - /apps/storybook/stories/BottomSheet.stories.tsx (examples and visual coverage)
|
|
35
36
|
*/
|
|
36
|
-
import { useCallback, useEffect, useRef } from 'react';
|
|
37
|
+
import { useCallback, useEffect, useRef, useState } from 'react';
|
|
37
38
|
import * as stylex from '@stylexjs/stylex';
|
|
38
39
|
import '@astryxdesign/core/theme/tokens.stylex';
|
|
39
40
|
import { colorVars, durationVars, easeVars, radiusVars, shadowVars, sizeVars, spacingVars } from '@astryxdesign/core/theme/tokens.stylex';
|
|
@@ -116,6 +117,10 @@ const styles = {
|
|
|
116
117
|
k3aq6I: "x1weeur4",
|
|
117
118
|
$$css: true
|
|
118
119
|
},
|
|
120
|
+
sheetExiting: {
|
|
121
|
+
kfzvcC: "x47corl",
|
|
122
|
+
$$css: true
|
|
123
|
+
},
|
|
119
124
|
budget: {
|
|
120
125
|
kZKoxP: "x1tpcejd",
|
|
121
126
|
$$css: true
|
|
@@ -159,6 +164,8 @@ export function BottomSheet({
|
|
|
159
164
|
xstyle,
|
|
160
165
|
...props
|
|
161
166
|
}) {
|
|
167
|
+
const [isPresented, setIsPresented] = useState(isOpen);
|
|
168
|
+
const isExiting = !isOpen && isPresented;
|
|
162
169
|
const dialogRef = useRef(null);
|
|
163
170
|
const triggerRef = useRef(null);
|
|
164
171
|
const sheetNodeRef = useRef(null);
|
|
@@ -191,6 +198,7 @@ export function BottomSheet({
|
|
|
191
198
|
return;
|
|
192
199
|
}
|
|
193
200
|
if (isOpen) {
|
|
201
|
+
setIsPresented(true);
|
|
194
202
|
dialog.style.setProperty('--_sheet-scrim-opacity', '1');
|
|
195
203
|
if (!dialog.open) {
|
|
196
204
|
// Only remember/restore focus for modal sheets; a non-modal sheet must
|
|
@@ -211,6 +219,9 @@ export function BottomSheet({
|
|
|
211
219
|
}
|
|
212
220
|
}
|
|
213
221
|
} else if (dialog.open) {
|
|
222
|
+
if (hasScrim) {
|
|
223
|
+
dialog.style.setProperty('--_sheet-scrim-opacity', '0');
|
|
224
|
+
}
|
|
214
225
|
// Wait for the slide-out (sheetClosing, applied this render) before
|
|
215
226
|
// close() releases the top layer. Timeout backstops a missing
|
|
216
227
|
// transitionend (reduced motion, hidden tab).
|
|
@@ -226,6 +237,7 @@ export function BottomSheet({
|
|
|
226
237
|
if (dialog.open) {
|
|
227
238
|
dialog.close();
|
|
228
239
|
}
|
|
240
|
+
setIsPresented(false);
|
|
229
241
|
triggerRef.current?.focus();
|
|
230
242
|
triggerRef.current = null;
|
|
231
243
|
};
|
|
@@ -235,8 +247,8 @@ export function BottomSheet({
|
|
|
235
247
|
}
|
|
236
248
|
};
|
|
237
249
|
sheet?.addEventListener('transitionend', onEnd);
|
|
238
|
-
// Backstop above --duration-medium
|
|
239
|
-
//
|
|
250
|
+
// Backstop above --duration-medium so transitionend normally fires
|
|
251
|
+
// first; this only covers environments that don't emit it.
|
|
240
252
|
const timer = setTimeout(finish, 450);
|
|
241
253
|
return () => {
|
|
242
254
|
clearTimeout(timer);
|
|
@@ -247,7 +259,7 @@ export function BottomSheet({
|
|
|
247
259
|
|
|
248
260
|
// Only a modal sheet locks body scroll; a non-modal sheet leaves the page
|
|
249
261
|
// scrollable behind it.
|
|
250
|
-
useScrollLock(
|
|
262
|
+
useScrollLock(isPresented && hasScrim);
|
|
251
263
|
|
|
252
264
|
// Enforce an accessible name: label is required by types, but a JS caller
|
|
253
265
|
// can still pass an empty string, leaving the sheet unnamed.
|
|
@@ -302,10 +314,12 @@ export function BottomSheet({
|
|
|
302
314
|
7: {
|
|
303
315
|
className: "xixxii4 x10a8y8t x1x1rfll x7ab17h x1ghz6dp x1717udv xjbqb8w x1rea2x4 x1a2a7pz x1lliihq xnixb3f xni466t xxiuuzi xc0dz0a xft5bk6 x15h3t91 x142juwg x1viac0w x47corl xfo81ep xh8yej3 x5yr21d"
|
|
304
316
|
}
|
|
305
|
-
}[!!isOpen << 2 | !!hasScrim << 1 | !!!hasScrim << 0],
|
|
317
|
+
}[!!(isOpen || isPresented) << 2 | !!hasScrim << 1 | !!!hasScrim << 0],
|
|
306
318
|
ref: mergeRefs(ref, dialogRef),
|
|
307
319
|
"aria-label": label,
|
|
308
|
-
"aria-
|
|
320
|
+
"aria-hidden": isExiting ? 'true' : undefined,
|
|
321
|
+
"aria-modal": hasScrim && isOpen ? 'true' : undefined,
|
|
322
|
+
inert: isExiting ? true : undefined,
|
|
309
323
|
onCancel: handleCancel,
|
|
310
324
|
onClick: handleClick,
|
|
311
325
|
onKeyDown: handleKeyDown,
|
|
@@ -317,9 +331,9 @@ export function BottomSheet({
|
|
|
317
331
|
children: /*#__PURE__*/_jsxs("div", {
|
|
318
332
|
ref: mergeRefs(sheetRef, sheetNodeRef),
|
|
319
333
|
tabIndex: -1,
|
|
320
|
-
...mergeProps(themeProps('bottom-sheet'), stylex.props(styles.sheet, isHug ? styles.hugHeight : styles.budget, !isOpen && styles.sheetClosing, xstyle), undefined, {
|
|
334
|
+
...mergeProps(themeProps('bottom-sheet'), stylex.props(styles.sheet, isHug ? styles.hugHeight : styles.budget, !isOpen && styles.sheetClosing, isExiting && styles.sheetExiting, xstyle), undefined, {
|
|
321
335
|
['--_sheet-budget']: budget,
|
|
322
|
-
...contentProps.style
|
|
336
|
+
...(isOpen ? contentProps.style : {})
|
|
323
337
|
}),
|
|
324
338
|
children: [/*#__PURE__*/_jsx("div", {
|
|
325
339
|
...{
|
package/dist/index.d.ts
CHANGED
|
@@ -30,5 +30,4 @@ export * from './Stepper';
|
|
|
30
30
|
export * from './CircularProgress';
|
|
31
31
|
export * from './ListInput';
|
|
32
32
|
export { LogStream, type LogStreamProps, type LogEntry, type LogStreamLevel, } from './LogStream';
|
|
33
|
-
export { RichTextEditor, type RichTextEditorProps, type RichTextEditorRef, type RichTextEditorStatus, type RichTextEditorStatusType, type RichTextEditorSize, type Transformer, RichTextView, type RichTextViewProps, sharedEditorTheme, markdownToEditorStateJSON, editorStateJSONToMarkdown, type MarkdownSerializerOptions, RichTextEditorToolbar, type RichTextEditorToolbarProps, RICHTEXT_ICON_KEYS, RichTextEditorAutoLinkPlugin, type RichTextEditorAutoLinkPluginProps, DEFAULT_LINK_MATCHERS, NEW_TAB_LINK_ATTRIBUTES, sanitizeUrl, validateUrl, URL_MATCHER, EMAIL_MATCHER, } from './RichTextEditor';
|
|
34
33
|
//# sourceMappingURL=index.d.ts.map
|
package/dist/index.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AAEA;;;;;;;;;;GAUG;AAGH,OAAO,EAAC,UAAU,EAAE,KAAK,eAAe,EAAC,MAAM,cAAc,CAAC;AAC9D,OAAO,EACL,QAAQ,EACR,aAAa,EACb,uBAAuB,EACvB,KAAK,WAAW,GACjB,MAAM,8BAA8B,CAAC;AAGtC,OAAO,EAAC,OAAO,EAAE,KAAK,YAAY,EAAE,KAAK,WAAW,EAAC,MAAM,WAAW,CAAC;AAGvE,OAAO,EACL,YAAY,EACZ,oBAAoB,EACpB,gBAAgB,EAChB,KAAK,kBAAkB,EACvB,KAAK,iBAAiB,EACtB,KAAK,kCAAkC,EACvC,KAAK,yBAAyB,GAC/B,MAAM,gBAAgB,CAAC;AAGxB,OAAO,EACL,aAAa,EACb,KAAK,kBAAkB,GACxB,MAAM,+BAA+B,CAAC;AACvC,cAAc,QAAQ,CAAC;AAGvB,OAAO,EAAC,MAAM,EAAE,KAAK,WAA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ACrB,UAAU,EACV,KAAK,eAAe,EACpB,UAAU,EACV,KAAK,eAAe,EACpB,WAAW,EACX,KAAK,gBAAgB,EACrB,SAAS,EACT,KAAK,eAAe,EACpB,KAAK,eAAe,EACpB,KAAK,YAAY,EACjB,KAAK,eAAe,EACpB,KAAK,gBAAgB,EACrB,KAAK,gBAAgB,EACrB,KAAK,kBAAkB,EACvB,UAAU,EACV,KAAK,eAAe,EACpB,KAAK,aAAa,GACnB,MAAM,UAAU,CAAC;AAIlB,cAAc,WAAW,CAAC;AAC1B,cAAc,oBAAoB,CAAC;AAGnC,cAAc,aAAa,CAAC;AAG5B,OAAO,EACL,SAAS,EACT,KAAK,cAAc,EACnB,KAAK,QAAQ,EACb,KAAK,cAAc,GACpB,MAAM,aAAa,CAAC"}
|
package/dist/index.js
CHANGED
|
@@ -70,6 +70,7 @@ export * from "./ListInput/index.js";
|
|
|
70
70
|
// LogStream — experimental streaming log viewer
|
|
71
71
|
export { LogStream } from "./LogStream/index.js";
|
|
72
72
|
|
|
73
|
-
// RichTextEditor
|
|
74
|
-
//
|
|
75
|
-
|
|
73
|
+
// RichTextEditor (RFC facebook/astryx#3899) has graduated out of @astryxdesign/lab
|
|
74
|
+
// into its own canary-only package, @astryxdesign/richtext, so it can be canaried
|
|
75
|
+
// independently (e.g. into EPS/Nest). Import it from there:
|
|
76
|
+
// import {RichTextEditor, RichTextView} from '@astryxdesign/richtext';
|
package/dist/lab.css
CHANGED
|
@@ -28,10 +28,6 @@
|
|
|
28
28
|
@keyframes x17t2jll-B{0%{transform:translateY(0);opacity:.35;}30%{transform:translateY(-3px);opacity:1;}60%{transform:translateY(0);opacity:.35;}100%{transform:translateY(0);opacity:.35;}}
|
|
29
29
|
:root, .x1ucsbpz{--icon-layer-primary-fill:none;--icon-layer-primary-stroke:currentColor;--icon-layer-primary-opacity:1;--icon-layer-primary-stroke-role-fill:none;--icon-layer-primary-stroke-role-stroke:currentColor;--icon-layer-primary-stroke-role-opacity:1;--icon-layer-primary-stroke-role-width:1.5;--icon-layer-secondary-fill:none;--icon-layer-secondary-stroke:currentColor;--icon-layer-secondary-opacity:1;--icon-layer-secondary-stroke-role-fill:none;--icon-layer-secondary-stroke-role-stroke:currentColor;--icon-layer-secondary-stroke-role-opacity:1;--icon-layer-secondary-stroke-role-width:1.5;--icon-size:24px;--icon-stroke-width:1.5;--icon-stroke-linecap:round;--icon-stroke-linejoin:round;--icon-padding:0px;--icon-inline-offset:0px;--icon-block-offset:0px;--icon-bold-stroke-boost:0.5;--icon-gap:0.75;--icon-gap-linejoin:round;}
|
|
30
30
|
:root, .xc6kv0w{--transfer-list-panel-min-block-size:12rem;--transfer-list-panel-max-block-size:20rem;}
|
|
31
|
-
.xax9j7h{--container-padding-block-end:0px}
|
|
32
|
-
.x1047aw6{--container-padding-block-start:0px}
|
|
33
|
-
.xjsfl84{--container-padding-inline-end:0px}
|
|
34
|
-
.xrhngw9{--container-padding-inline-start:0px}
|
|
35
31
|
.x1eijsz{--icon-layer-primary-fill:currentColor}
|
|
36
32
|
.xawlqpt{--icon-layer-primary-fill:none}
|
|
37
33
|
.xgmpc9a{--icon-layer-primary-opacity:1}
|
|
@@ -106,11 +102,9 @@
|
|
|
106
102
|
.xc342km:not(#\#):not(#\#){border-width:0}
|
|
107
103
|
.xmkeg23:not(#\#):not(#\#){border-width:1px}
|
|
108
104
|
.x1litavf:not(#\#):not(#\#){border-width:var(--border-width)}
|
|
109
|
-
.x845mor:not(#\#):not(#\#){flex:1 1 0%}
|
|
110
105
|
.x98rzlu:not(#\#):not(#\#){flex:1}
|
|
111
106
|
.xxhr3t:not(#\#):not(#\#){gap:0}
|
|
112
107
|
.x1lsbc85:not(#\#):not(#\#){gap:var(--spacing-0-5)}
|
|
113
|
-
.xsn7fz1:not(#\#):not(#\#){gap:var(--spacing-0)}
|
|
114
108
|
.x1s4dlld:not(#\#):not(#\#){gap:var(--spacing-1-5)}
|
|
115
109
|
.xzye2dw:not(#\#):not(#\#){gap:var(--spacing-1)}
|
|
116
110
|
.x1txdalj:not(#\#):not(#\#){gap:var(--spacing-2)}
|
|
@@ -128,12 +122,8 @@
|
|
|
128
122
|
.x15daork:not(#\#):not(#\#){grid-row:auto}
|
|
129
123
|
.x33j1x8:not(#\#):not(#\#){grid-row:var(--x-gridRow)}
|
|
130
124
|
.x17y0mx6:not(#\#):not(#\#){inset-inline:0}
|
|
131
|
-
.x10im51j:not(#\#):not(#\#){margin-block:0}
|
|
132
125
|
.x1yqqeh1:not(#\#):not(#\#){margin-block:var(--spacing-0-5)}
|
|
133
|
-
.xsq74q5:not(#\#):not(#\#){margin-block:var(--spacing-1)}
|
|
134
|
-
.x1g06x3t:not(#\#):not(#\#){margin-block:var(--spacing-2)}
|
|
135
126
|
.x1oqu0vw:not(#\#):not(#\#){margin-block:var(--x-marginBlock)}
|
|
136
|
-
.xrxpjvj:not(#\#):not(#\#){margin-inline:0}
|
|
137
127
|
.x1a2a7pz:not(#\#):not(#\#){outline:none}
|
|
138
128
|
.xysyzu8:not(#\#):not(#\#){overflow:auto}
|
|
139
129
|
.xb3r6kr:not(#\#):not(#\#){overflow:hidden}
|
|
@@ -143,13 +133,11 @@
|
|
|
143
133
|
.xt970qd:not(#\#):not(#\#){padding-block:0}
|
|
144
134
|
.xsplgde:not(#\#):not(#\#){padding-block:1px}
|
|
145
135
|
.x13f7esw:not(#\#):not(#\#){padding-block:var(--spacing-0-5)}
|
|
146
|
-
.x1hp7d8q:not(#\#):not(#\#){padding-block:var(--spacing-0)}
|
|
147
136
|
.xu0wf1k:not(#\#):not(#\#){padding-block:var(--spacing-1)}
|
|
148
137
|
.xce4md1:not(#\#):not(#\#){padding-block:var(--spacing-2)}
|
|
149
138
|
.x8o8v82:not(#\#):not(#\#){padding-block:var(--spacing-3)}
|
|
150
139
|
.x1giekp1:not(#\#):not(#\#){padding-block:var(--x-paddingBlock)}
|
|
151
140
|
.xnjsko4:not(#\#):not(#\#){padding-inline:0}
|
|
152
|
-
.x17a0aqu:not(#\#):not(#\#){padding-inline:var(--spacing-0)}
|
|
153
141
|
.x4ezzuc:not(#\#):not(#\#){padding-inline:var(--spacing-1-5)}
|
|
154
142
|
.x7a5moj:not(#\#):not(#\#){padding-inline:var(--spacing-1)}
|
|
155
143
|
.xf314gf:not(#\#):not(#\#){padding-inline:var(--spacing-2)}
|
|
@@ -157,9 +145,7 @@
|
|
|
157
145
|
.x1pzlopt:not(#\#):not(#\#){padding-inline:var(--spacing-4)}
|
|
158
146
|
.x30g6up:not(#\#):not(#\#){padding-inline:var(--x-paddingInline)}
|
|
159
147
|
.x1ku5rj1:not(#\#):not(#\#){place-items:center}
|
|
160
|
-
.xmqliwb:not(#\#):not(#\#){text-decoration:line-through}
|
|
161
148
|
.x1hl2dhg:not(#\#):not(#\#){text-decoration:none}
|
|
162
|
-
.x1bvjpef:not(#\#):not(#\#){text-decoration:underline}
|
|
163
149
|
.xb0j27v:not(#\#):not(#\#){transition:grid-template-rows var(--duration-medium) var(--ease-standard)}
|
|
164
150
|
.x1ob6yzd:not(#\#):not(#\#){transition:transform var(--duration-fast) var(--ease-standard)}
|
|
165
151
|
.x1xfd4ba:hover:not(#\#):not(#\#){border-color:transparent}
|
|
@@ -264,10 +250,8 @@
|
|
|
264
250
|
.x18b5jzi:not(#\#):not(#\#):not(#\#){border-inline-end-style:solid}
|
|
265
251
|
.x10w94by:not(#\#):not(#\#):not(#\#){border-inline-end-width:0}
|
|
266
252
|
.xw8tdv1:not(#\#):not(#\#):not(#\#){border-inline-end-width:var(--border-width)}
|
|
267
|
-
.x14ydlgx:not(#\#):not(#\#):not(#\#){border-inline-start-color:var(--color-border-emphasized)}
|
|
268
253
|
.x1j92z86:not(#\#):not(#\#):not(#\#){border-inline-start-color:var(--color-border)}
|
|
269
254
|
.x1t7ytsu:not(#\#):not(#\#):not(#\#){border-inline-start-style:solid}
|
|
270
|
-
.xct1zlm:not(#\#):not(#\#):not(#\#){border-inline-start-width:3px}
|
|
271
255
|
.xgbv0en:not(#\#):not(#\#):not(#\#){border-inline-start-width:var(--border-width)}
|
|
272
256
|
.x7hs6f1:not(#\#):not(#\#):not(#\#){border-start-end-radius:var(--radius-container)}
|
|
273
257
|
.x81l70g:not(#\#):not(#\#):not(#\#){border-start-start-radius:var(--radius-container)}
|
|
@@ -334,7 +318,6 @@
|
|
|
334
318
|
.xb5mbof:not(#\#):not(#\#):not(#\#){content-visibility:auto}
|
|
335
319
|
.x1jm3nie:not(#\#):not(#\#):not(#\#){cursor:grab}
|
|
336
320
|
.xi9pz9s:not(#\#):not(#\#):not(#\#){cursor:grabbing}
|
|
337
|
-
.x1h6gzvc:not(#\#):not(#\#):not(#\#){cursor:not-allowed}
|
|
338
321
|
.x1ypdohk:not(#\#):not(#\#):not(#\#){cursor:pointer}
|
|
339
322
|
.x1lliihq:not(#\#):not(#\#):not(#\#){display:block}
|
|
340
323
|
.xjp7ctv:not(#\#):not(#\#):not(#\#){display:contents}
|
|
@@ -354,10 +337,6 @@
|
|
|
354
337
|
.x9ynric:not(#\#):not(#\#):not(#\#){font-family:var(--font-family-body)}
|
|
355
338
|
.x9m5x89:not(#\#):not(#\#):not(#\#){font-family:var(--font-family-code)}
|
|
356
339
|
.x1g81bgm:not(#\#):not(#\#):not(#\#){font-family:var(--font-family-heading)}
|
|
357
|
-
.xeb7xqv:not(#\#):not(#\#):not(#\#){font-size:.9em}
|
|
358
|
-
.x1c3i2sq:not(#\#):not(#\#):not(#\#){font-size:1.125rem}
|
|
359
|
-
.x1603h9y:not(#\#):not(#\#):not(#\#){font-size:1.25rem}
|
|
360
|
-
.xngnso2:not(#\#):not(#\#):not(#\#){font-size:1.5rem}
|
|
361
340
|
.x1jvydc1:not(#\#):not(#\#):not(#\#){font-size:15px}
|
|
362
341
|
.xosj86m:not(#\#):not(#\#):not(#\#){font-size:18px}
|
|
363
342
|
.xhs0kqb:not(#\#):not(#\#):not(#\#){font-size:var(--font-size-2xl)}
|
|
@@ -369,7 +348,6 @@
|
|
|
369
348
|
.xjm74w1:not(#\#):not(#\#):not(#\#){font-size:var(--text-body-size)}
|
|
370
349
|
.xcr08ib:not(#\#):not(#\#):not(#\#){font-size:var(--text-label-size)}
|
|
371
350
|
.x141an7d:not(#\#):not(#\#):not(#\#){font-size:var(--text-supporting-size)}
|
|
372
|
-
.x1k4tb9n:not(#\#):not(#\#):not(#\#){font-style:italic}
|
|
373
351
|
.xss6m8b:not(#\#):not(#\#):not(#\#){font-variant-numeric:tabular-nums}
|
|
374
352
|
.x1lvx875:not(#\#):not(#\#):not(#\#){font-weight:var(--font-weight-bold)}
|
|
375
353
|
.x1e4wzip:not(#\#):not(#\#):not(#\#){font-weight:var(--font-weight-medium)}
|
|
@@ -425,15 +403,7 @@
|
|
|
425
403
|
.x1cpk1wn:not(#\#):not(#\#):not(#\#){line-height:var(--text-heading-2-leading)}
|
|
426
404
|
.x1kq96og:not(#\#):not(#\#):not(#\#){line-height:var(--text-label-leading)}
|
|
427
405
|
.x1ltkj2j:not(#\#):not(#\#):not(#\#){line-height:var(--text-supporting-leading)}
|
|
428
|
-
.x43c9pm:not(#\#):not(#\#):not(#\#){list-style-position:outside}
|
|
429
|
-
.xrylv2j:not(#\#):not(#\#):not(#\#){list-style-type:circle}
|
|
430
|
-
.x3yw8vx:not(#\#):not(#\#):not(#\#){list-style-type:decimal}
|
|
431
|
-
.xtaz4m5:not(#\#):not(#\#):not(#\#){list-style-type:disc}
|
|
432
|
-
.x1sle589:not(#\#):not(#\#):not(#\#){list-style-type:inherit}
|
|
433
|
-
.x1rrqm6h:not(#\#):not(#\#):not(#\#){list-style-type:lower-alpha}
|
|
434
|
-
.x19k9dhg:not(#\#):not(#\#):not(#\#){list-style-type:lower-roman}
|
|
435
406
|
.x3ct3a4:not(#\#):not(#\#):not(#\#){list-style-type:none}
|
|
436
|
-
.x152237o:not(#\#):not(#\#):not(#\#){list-style-type:square}
|
|
437
407
|
.x1h1dc9q:not(#\#):not(#\#):not(#\#){margin-inline-end:calc(var(--spacing-0-5) + var(--border-width))}
|
|
438
408
|
.x1pezmd8:not(#\#):not(#\#):not(#\#){margin-inline-end:var(--spacing-2)}
|
|
439
409
|
.x1m70ojl:not(#\#):not(#\#):not(#\#){margin-inline-start:calc(-1 * var(--spacing-1-5))}
|
|
@@ -449,15 +419,12 @@
|
|
|
449
419
|
.xj0a0fe:not(#\#):not(#\#):not(#\#){overflow-wrap:anywhere}
|
|
450
420
|
.x1h4wwuj:not(#\#):not(#\#):not(#\#){overflow-wrap:normal}
|
|
451
421
|
.xyri2b:not(#\#):not(#\#):not(#\#){padding-inline-end:0}
|
|
452
|
-
.xp74n0j:not(#\#):not(#\#):not(#\#){padding-inline-end:calc(var(--spacing-2) + var(--spacing-6))}
|
|
453
422
|
.x1nryj5t:not(#\#):not(#\#):not(#\#){padding-inline-end:var(--spacing-1)}
|
|
454
423
|
.x1t818jl:not(#\#):not(#\#):not(#\#){padding-inline-end:var(--spacing-3)}
|
|
455
424
|
.x1f43n9v:not(#\#):not(#\#):not(#\#){padding-inline-start:calc(16px + var(--spacing-1-5))}
|
|
456
425
|
.xmarwi5:not(#\#):not(#\#):not(#\#){padding-inline-start:var(--icon-inline-offset)}
|
|
457
426
|
.x18gyask:not(#\#):not(#\#):not(#\#){padding-inline-start:var(--spacing-0)}
|
|
458
427
|
.x1vsv5vr:not(#\#):not(#\#):not(#\#){padding-inline-start:var(--spacing-1)}
|
|
459
|
-
.x12gdq22:not(#\#):not(#\#):not(#\#){padding-inline-start:var(--spacing-2)}
|
|
460
|
-
.x126nfab:not(#\#):not(#\#):not(#\#){padding-inline-start:var(--spacing-3)}
|
|
461
428
|
.x1rey3nv:not(#\#):not(#\#):not(#\#){padding-inline-start:var(--spacing-4)}
|
|
462
429
|
.x31w388:not(#\#):not(#\#):not(#\#){padding-inline-start:var(--spacing-6)}
|
|
463
430
|
.xchaq28:not(#\#):not(#\#):not(#\#){padding-inline-start:var(--spacing-7)}
|
|
@@ -541,7 +508,6 @@
|
|
|
541
508
|
@media (prefers-reduced-motion: reduce){.xnh0sag.xnh0sag:not(#\#):not(#\#):not(#\#){animation-duration:3s}}
|
|
542
509
|
@media (prefers-reduced-motion: reduce){.xy02sl2.xy02sl2:not(#\#):not(#\#):not(#\#){animation-duration:4s}}
|
|
543
510
|
@media (prefers-reduced-motion: reduce){.x1aquc0h.x1aquc0h:not(#\#):not(#\#):not(#\#){animation-name:none}}
|
|
544
|
-
@media (pointer: coarse){.x6pjikd.x6pjikd:not(#\#):not(#\#):not(#\#){font-size:max(1rem,var(--text-body-size))}}
|
|
545
511
|
@media (prefers-reduced-motion: reduce){.xsagj69.xsagj69:not(#\#):not(#\#):not(#\#){transition-duration:.01ms}}
|
|
546
512
|
@media (prefers-reduced-motion: reduce){.xzg1mie.xzg1mie:not(#\#):not(#\#):not(#\#){transition-duration:.01s}}
|
|
547
513
|
@media (prefers-reduced-motion: reduce){.x12w9bfk.x12w9bfk:not(#\#):not(#\#):not(#\#){transition-duration:0s}}
|
|
@@ -568,7 +534,6 @@
|
|
|
568
534
|
.x1pc3f07:not(#\#):not(#\#):not(#\#):not(#\#){border-top-color:var(--color-border)}
|
|
569
535
|
.x13fuv20:not(#\#):not(#\#):not(#\#):not(#\#){border-top-style:solid}
|
|
570
536
|
.x972fbf:not(#\#):not(#\#):not(#\#):not(#\#){border-top-width:0}
|
|
571
|
-
.x178xt8z:not(#\#):not(#\#):not(#\#):not(#\#){border-top-width:1px}
|
|
572
537
|
.xamhcws:not(#\#):not(#\#):not(#\#):not(#\#){border-top-width:2px}
|
|
573
538
|
.x11xkdxz:not(#\#):not(#\#):not(#\#):not(#\#){border-top-width:var(--border-width)}
|
|
574
539
|
.x1ey2m1c:not(#\#):not(#\#):not(#\#):not(#\#){bottom:0}
|
|
@@ -597,10 +562,8 @@
|
|
|
597
562
|
.x1unci72:not(#\#):not(#\#):not(#\#):not(#\#){left:var(--spacing-4)}
|
|
598
563
|
.x1if0o47:not(#\#):not(#\#):not(#\#):not(#\#){margin-bottom:-48px}
|
|
599
564
|
.xlstkdb:not(#\#):not(#\#):not(#\#):not(#\#){margin-bottom:var(--spacing-0-5)}
|
|
600
|
-
.x14cgwvg:not(#\#):not(#\#):not(#\#):not(#\#){margin-bottom:var(--spacing-1)}
|
|
601
565
|
.x1p37lm5:not(#\#):not(#\#):not(#\#):not(#\#){margin-bottom:var(--spacing-2)}
|
|
602
566
|
.x160xvyo:not(#\#):not(#\#):not(#\#):not(#\#){margin-top:calc(var(--spacing-1) * -1)}
|
|
603
|
-
.x17ilvqm:not(#\#):not(#\#):not(#\#):not(#\#){margin-top:var(--spacing-0)}
|
|
604
567
|
.xcsaf9d:not(#\#):not(#\#):not(#\#):not(#\#){margin-top:var(--spacing-1)}
|
|
605
568
|
.xtbrsbv:not(#\#):not(#\#):not(#\#):not(#\#){margin-top:var(--spacing-2)}
|
|
606
569
|
.x1vhfslr:not(#\#):not(#\#):not(#\#):not(#\#){margin-top:var(--x-marginBlockStart)}
|
|
@@ -610,7 +573,6 @@
|
|
|
610
573
|
.x7ab17h:not(#\#):not(#\#):not(#\#):not(#\#){max-height:none}
|
|
611
574
|
.x9rxgia:not(#\#):not(#\#):not(#\#):not(#\#){max-height:var(--transfer-list-panel-max-block-size)}
|
|
612
575
|
.x1jols5v:not(#\#):not(#\#):not(#\#):not(#\#){max-height:var(--x-maxHeight)}
|
|
613
|
-
.x193iq5w:not(#\#):not(#\#):not(#\#):not(#\#){max-width:100%}
|
|
614
576
|
.x1va8c73:not(#\#):not(#\#):not(#\#):not(#\#){max-width:320px}
|
|
615
577
|
.x1k2d6hx:not(#\#):not(#\#):not(#\#):not(#\#){max-width:44px}
|
|
616
578
|
.x11gisft:not(#\#):not(#\#):not(#\#):not(#\#){max-width:640px}
|
|
@@ -620,7 +582,6 @@
|
|
|
620
582
|
.xisnujt:not(#\#):not(#\#):not(#\#):not(#\#){min-height:20px}
|
|
621
583
|
.xjwf9q1:not(#\#):not(#\#):not(#\#):not(#\#){min-height:24px}
|
|
622
584
|
.x1cy360x:not(#\#):not(#\#):not(#\#):not(#\#){min-height:3em}
|
|
623
|
-
.x65nank:not(#\#):not(#\#):not(#\#):not(#\#){min-height:auto}
|
|
624
585
|
.x1uogy3y:not(#\#):not(#\#):not(#\#):not(#\#){min-height:var(--size-element-md)}
|
|
625
586
|
.x175cymr:not(#\#):not(#\#):not(#\#):not(#\#){min-height:var(--spacing-2)}
|
|
626
587
|
.xu95rz8:not(#\#):not(#\#):not(#\#):not(#\#){min-height:var(--transfer-list-panel-min-block-size)}
|
|
@@ -633,8 +594,6 @@
|
|
|
633
594
|
.xw2csxc:not(#\#):not(#\#):not(#\#):not(#\#){overflow-x:auto}
|
|
634
595
|
.x6ikm8r:not(#\#):not(#\#):not(#\#):not(#\#){overflow-x:hidden}
|
|
635
596
|
.x1odjw0f:not(#\#):not(#\#):not(#\#):not(#\#){overflow-y:auto}
|
|
636
|
-
.x10wlt62:not(#\#):not(#\#):not(#\#):not(#\#){overflow-y:hidden}
|
|
637
|
-
.x7p5m3t:not(#\#):not(#\#):not(#\#):not(#\#){overscroll-behavior-x:contain}
|
|
638
597
|
.x1j85h84:not(#\#):not(#\#):not(#\#):not(#\#){padding-bottom:1px}
|
|
639
598
|
.x1wkw6tp:not(#\#):not(#\#):not(#\#):not(#\#){padding-bottom:calc(env(safe-area-inset-bottom,0px) + 48px)}
|
|
640
599
|
.xy143xn:not(#\#):not(#\#):not(#\#):not(#\#){padding-bottom:var(--spacing-1)}
|
|
@@ -643,11 +602,9 @@
|
|
|
643
602
|
.x1xye8es:not(#\#):not(#\#):not(#\#):not(#\#){padding-top:var(--spacing-2)}
|
|
644
603
|
.x13vifvy:not(#\#):not(#\#):not(#\#):not(#\#){top:0}
|
|
645
604
|
.x80663w:not(#\#):not(#\#):not(#\#):not(#\#){top:auto}
|
|
646
|
-
.x4xegtk:not(#\#):not(#\#):not(#\#):not(#\#){top:var(--spacing-0)}
|
|
647
605
|
.xctzyg:not(#\#):not(#\#):not(#\#):not(#\#){top:var(--spacing-2)}
|
|
648
606
|
.xyx6v2t:not(#\#):not(#\#):not(#\#):not(#\#){top:var(--spacing-3)}
|
|
649
607
|
.xjbys53:not(#\#):not(#\#):not(#\#):not(#\#){top:var(--x-top)}
|
|
650
|
-
.xnalus7:not(#\#):not(#\#):not(#\#):not(#\#){width:0}
|
|
651
608
|
.xh8yej3:not(#\#):not(#\#):not(#\#):not(#\#){width:100%}
|
|
652
609
|
.x1o6l61p:not(#\#):not(#\#):not(#\#):not(#\#){width:100dvw}
|
|
653
610
|
.x1fsd2vl:not(#\#):not(#\#):not(#\#):not(#\#){width:10px}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@astryxdesign/lab",
|
|
3
|
-
"version": "0.4.0-canary.
|
|
3
|
+
"version": "0.4.0-canary.dad87f5",
|
|
4
4
|
"description": "Experimental Astryx components — published to npm only under the @canary dist-tag for early testing; never released as a stable (latest) version.",
|
|
5
5
|
"author": "Meta Open Source",
|
|
6
6
|
"license": "MIT",
|
|
@@ -45,20 +45,9 @@
|
|
|
45
45
|
},
|
|
46
46
|
"peerDependencies": {
|
|
47
47
|
"@stylexjs/stylex": ">=0.10.0",
|
|
48
|
-
"@astryxdesign/core": "0.4.0-canary.
|
|
48
|
+
"@astryxdesign/core": "0.4.0-canary.dad87f5",
|
|
49
49
|
"react": ">=19.0.0",
|
|
50
|
-
"react-dom": ">=19.0.0"
|
|
51
|
-
"lexical": "^0.46.0",
|
|
52
|
-
"@lexical/react": "^0.46.0",
|
|
53
|
-
"@lexical/markdown": "^0.46.0",
|
|
54
|
-
"@lexical/headless": "^0.46.0",
|
|
55
|
-
"@lexical/html": "^0.46.0",
|
|
56
|
-
"@lexical/link": "^0.46.0",
|
|
57
|
-
"@lexical/list": "^0.46.0",
|
|
58
|
-
"@lexical/rich-text": "^0.46.0",
|
|
59
|
-
"@lexical/selection": "^0.46.0",
|
|
60
|
-
"@lexical/code": "^0.46.0",
|
|
61
|
-
"@lexical/utils": "^0.46.0"
|
|
50
|
+
"react-dom": ">=19.0.0"
|
|
62
51
|
},
|
|
63
52
|
"dependencies": {
|
|
64
53
|
"d3-array": "^3.2.4",
|
|
@@ -66,56 +55,10 @@
|
|
|
66
55
|
"d3-shape": "^3.2.0"
|
|
67
56
|
},
|
|
68
57
|
"devDependencies": {
|
|
69
|
-
"@astryxdesign/cli": "0.4.0-canary.
|
|
70
|
-
"@lexical/code": "^0.46.0",
|
|
71
|
-
"@lexical/headless": "^0.46.0",
|
|
72
|
-
"@lexical/html": "^0.46.0",
|
|
73
|
-
"@lexical/link": "^0.46.0",
|
|
74
|
-
"@lexical/list": "^0.46.0",
|
|
75
|
-
"@lexical/markdown": "^0.46.0",
|
|
76
|
-
"@lexical/react": "^0.46.0",
|
|
77
|
-
"@lexical/rich-text": "^0.46.0",
|
|
78
|
-
"@lexical/selection": "^0.46.0",
|
|
79
|
-
"@lexical/utils": "^0.46.0",
|
|
58
|
+
"@astryxdesign/cli": "0.4.0-canary.dad87f5",
|
|
80
59
|
"@types/d3-array": "^3.2.2",
|
|
81
60
|
"@types/d3-scale": "^4.0.9",
|
|
82
|
-
"@types/d3-shape": "^3.1.8"
|
|
83
|
-
"lexical": "^0.46.0"
|
|
84
|
-
},
|
|
85
|
-
"peerDependenciesMeta": {
|
|
86
|
-
"lexical": {
|
|
87
|
-
"optional": true
|
|
88
|
-
},
|
|
89
|
-
"@lexical/react": {
|
|
90
|
-
"optional": true
|
|
91
|
-
},
|
|
92
|
-
"@lexical/markdown": {
|
|
93
|
-
"optional": true
|
|
94
|
-
},
|
|
95
|
-
"@lexical/headless": {
|
|
96
|
-
"optional": true
|
|
97
|
-
},
|
|
98
|
-
"@lexical/html": {
|
|
99
|
-
"optional": true
|
|
100
|
-
},
|
|
101
|
-
"@lexical/link": {
|
|
102
|
-
"optional": true
|
|
103
|
-
},
|
|
104
|
-
"@lexical/list": {
|
|
105
|
-
"optional": true
|
|
106
|
-
},
|
|
107
|
-
"@lexical/rich-text": {
|
|
108
|
-
"optional": true
|
|
109
|
-
},
|
|
110
|
-
"@lexical/selection": {
|
|
111
|
-
"optional": true
|
|
112
|
-
},
|
|
113
|
-
"@lexical/code": {
|
|
114
|
-
"optional": true
|
|
115
|
-
},
|
|
116
|
-
"@lexical/utils": {
|
|
117
|
-
"optional": true
|
|
118
|
-
}
|
|
61
|
+
"@types/d3-shape": "^3.1.8"
|
|
119
62
|
},
|
|
120
63
|
"scripts": {
|
|
121
64
|
"build": "rm -rf dist && pnpm build:esm && tsc --project tsconfig.build.json && pnpm build:css && node ../../scripts/check-no-dev-jsx.mjs && node ../../scripts/check-fully-specified.mjs",
|
|
@@ -6,59 +6,97 @@ export const docs = {
|
|
|
6
6
|
displayName: 'BottomSheet',
|
|
7
7
|
group: 'BottomSheet',
|
|
8
8
|
category: 'Overlay',
|
|
9
|
-
keywords: [
|
|
9
|
+
keywords: [
|
|
10
|
+
'bottom sheet',
|
|
11
|
+
'sheet',
|
|
12
|
+
'mobile',
|
|
13
|
+
'touch',
|
|
14
|
+
'drag',
|
|
15
|
+
'swipe',
|
|
16
|
+
'dismiss',
|
|
17
|
+
'grab handle',
|
|
18
|
+
'dialog',
|
|
19
|
+
'overlay',
|
|
20
|
+
'modal',
|
|
21
|
+
],
|
|
10
22
|
theming: {
|
|
11
|
-
targets: [
|
|
12
|
-
{className: 'astryx-bottom-sheet', visualProps: []},
|
|
13
|
-
],
|
|
23
|
+
targets: [{className: 'astryx-bottom-sheet', visualProps: []}],
|
|
14
24
|
},
|
|
15
|
-
description:
|
|
25
|
+
description:
|
|
26
|
+
'A mobile touch sheet that rises from the bottom edge, with animated entrance and exit, a grab handle, drag-to-resize snap points, and swipe-to-dismiss. Built on a native modal <dialog>.',
|
|
16
27
|
props: [
|
|
17
28
|
{
|
|
18
29
|
name: 'isOpen',
|
|
19
30
|
type: 'boolean',
|
|
20
|
-
description:
|
|
31
|
+
description:
|
|
32
|
+
'Whether the sheet is open. Fully controlled; pair with onOpenChange.',
|
|
21
33
|
required: true,
|
|
22
34
|
},
|
|
23
35
|
{
|
|
24
36
|
name: 'onOpenChange',
|
|
25
37
|
type: '(isOpen: boolean) => void',
|
|
26
|
-
description:
|
|
38
|
+
description:
|
|
39
|
+
'Called when the sheet opens or closes. The boolean is the requested next state (false on Escape, scrim click, or a swipe past the dismiss threshold). The caller owns the open state.',
|
|
27
40
|
required: true,
|
|
28
41
|
},
|
|
29
42
|
{
|
|
30
43
|
name: 'label',
|
|
31
44
|
type: 'string',
|
|
32
|
-
description:
|
|
45
|
+
description:
|
|
46
|
+
'Accessible label for the sheet. Required; the sheet has no built-in heading to derive a name from.',
|
|
33
47
|
required: true,
|
|
34
48
|
},
|
|
35
49
|
{
|
|
36
50
|
name: 'children',
|
|
37
51
|
type: 'ReactNode',
|
|
38
|
-
description:
|
|
52
|
+
description:
|
|
53
|
+
'Sheet content, rendered below the grab handle in a scrollable area.',
|
|
39
54
|
required: true,
|
|
40
55
|
},
|
|
41
56
|
{
|
|
42
57
|
name: 'height',
|
|
43
58
|
type: "'hug' | 'capped' | 'tall' | number | string",
|
|
44
|
-
description:
|
|
59
|
+
description:
|
|
60
|
+
"How tall the sheet is. Named budgets: 'hug' fits its content up to 92% of the viewport, 'capped' is a scrolling mid-height panel (~62%), and 'tall' is a pinned near-full panel (~92%) for content that streams in. Or pass a number (px) / CSS length for a custom budget. The user can drag between snap points regardless. On shorter viewports the sheet fills the available height.",
|
|
45
61
|
default: "'capped'",
|
|
46
62
|
},
|
|
47
63
|
{
|
|
48
64
|
name: 'hasScrim',
|
|
49
65
|
type: 'boolean',
|
|
50
|
-
description:
|
|
66
|
+
description:
|
|
67
|
+
'Whether to render a scrim, the semi-transparent overlay that covers and blocks the background, behind the sheet. true (default) uses showModal(): top layer, focus trap, ::backdrop scrim, body scroll lock, and tap-scrim-to-dismiss, with the background inert. false still renders a viewport-anchored overlay above the page, not inline content, but uses show() with no scrim, leaving the page behind interactive and scrollable. Escape still closes while focus is inside, and drag/flick-to-dismiss still work.',
|
|
51
68
|
default: 'true',
|
|
52
69
|
},
|
|
53
70
|
],
|
|
54
71
|
usage: {
|
|
55
|
-
description:
|
|
72
|
+
description:
|
|
73
|
+
'A mobile touch surface for filters, actions, and detail views that should rise from the bottom of the screen. Opening slides the sheet in; closing keeps its native dialog presented but inert until the slide-out and scrim fade complete. Drag the grab handle to resize: a slow drag settles to the nearest snap point (a short peek, ~half, and ~full detent, filtered to those shorter than the sheet), a fast flick down dismisses, a fast flick up expands. Pulling down on the content when it is scrolled to the top also drags the sheet, giving a larger, more forgiving target. The scrim thins to a faint glance state (but never fully clears) as the sheet collapses onto its shortest "peek" detent; the sheet stays modal, so the background remains inert until dismissed; a residual dim keeps that legible. The sheet is modal: focus is trapped while open and restored to the opener after its exit, and Escape dismisses, so the swipe gesture always has a keyboard equivalent. Content padding clears the home indicator via env(safe-area-inset-bottom).',
|
|
56
74
|
bestPractices: [
|
|
57
|
-
{
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
75
|
+
{
|
|
76
|
+
guidance: true,
|
|
77
|
+
description:
|
|
78
|
+
'Use for mobile-first surfaces (filters, share sheets, quick actions) where the content should rise from the bottom edge.',
|
|
79
|
+
},
|
|
80
|
+
{
|
|
81
|
+
guidance: true,
|
|
82
|
+
description:
|
|
83
|
+
'Keep the caller as the source of truth: derive isOpen from state and clear it in onOpenChange.',
|
|
84
|
+
},
|
|
85
|
+
{
|
|
86
|
+
guidance: true,
|
|
87
|
+
description:
|
|
88
|
+
"Pick the starting height that fits the content: 'hug' for short bounded content, 'capped' for lists, 'tall' for streaming/resizing content; the user can then drag between snap points.",
|
|
89
|
+
},
|
|
90
|
+
{
|
|
91
|
+
guidance: true,
|
|
92
|
+
description:
|
|
93
|
+
'Use hasScrim={false} for a floating, no-scrim overlay that must coexist with a live page behind it (e.g. a panel over a map). It remains viewport-anchored rather than rendering inline. Keep the default for focused tasks where the background should be inert.',
|
|
94
|
+
},
|
|
95
|
+
{
|
|
96
|
+
guidance: false,
|
|
97
|
+
description:
|
|
98
|
+
'Use a BottomSheet for desktop inspectors or master-detail; use Drawer (side="end", hasScrim={false}) instead.',
|
|
99
|
+
},
|
|
62
100
|
],
|
|
63
101
|
},
|
|
64
102
|
examples: [
|
|
@@ -110,15 +148,36 @@ export const docs = {
|
|
|
110
148
|
|
|
111
149
|
/** @type {import('@astryxdesign/cli/authoring').ComponentTranslationDoc} */
|
|
112
150
|
export const docsDense = {
|
|
113
|
-
description:
|
|
151
|
+
description:
|
|
152
|
+
'mobile touch sheet rising from the bottom edge (native <dialog>): grab handle, drag-to-resize snap points, swipe-to-dismiss, named height scale, modal (default) or non-modal (hasScrim={false}) presentation',
|
|
114
153
|
usage: {
|
|
115
|
-
description:
|
|
154
|
+
description:
|
|
155
|
+
'Mobile surface for filters, actions, and detail views. Drag the handle to resize between snap points; flick down to dismiss, up to expand. Modal: focus trap + restore, and Escape dismisses so swipe has a keyboard equivalent. Content clears the home indicator via safe-area inset.',
|
|
116
156
|
bestPractices: [
|
|
117
|
-
{
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
157
|
+
{
|
|
158
|
+
guidance: true,
|
|
159
|
+
description:
|
|
160
|
+
'Use for mobile-first bottom surfaces (filters, share sheets, quick actions).',
|
|
161
|
+
},
|
|
162
|
+
{
|
|
163
|
+
guidance: true,
|
|
164
|
+
description: 'Derive isOpen from state; clear it in onOpenChange.',
|
|
165
|
+
},
|
|
166
|
+
{
|
|
167
|
+
guidance: true,
|
|
168
|
+
description:
|
|
169
|
+
"Pick a height that fits: 'hug' for short content, 'capped' for lists, 'tall' for streaming content.",
|
|
170
|
+
},
|
|
171
|
+
{
|
|
172
|
+
guidance: true,
|
|
173
|
+
description:
|
|
174
|
+
'hasScrim={false} for a floating no-scrim overlay over a live page; it is not inline. Keep the default for focused tasks (inert background).',
|
|
175
|
+
},
|
|
176
|
+
{
|
|
177
|
+
guidance: false,
|
|
178
|
+
description:
|
|
179
|
+
'Use for desktop inspectors or master-detail; use Drawer instead.',
|
|
180
|
+
},
|
|
122
181
|
],
|
|
123
182
|
},
|
|
124
183
|
};
|