@multiplatform.one/components 8.4.0 → 8.6.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/SheetModal/detents.cjs +11 -37
- package/dist/cjs/SheetModal/detents.native.js +11 -43
- package/dist/cjs/SheetModal/detents.native.js.map +1 -1
- package/dist/cjs/SheetModal/index.cjs +3 -0
- package/dist/cjs/SheetModal/index.native.js +7 -6
- package/dist/cjs/SheetModal/index.native.js.map +1 -1
- package/dist/cjs/views/ListRow.cjs +101 -19
- package/dist/cjs/views/ListRow.native.js +104 -20
- package/dist/cjs/views/ListRow.native.js.map +1 -1
- package/dist/esm/SheetModal/detents.mjs +2 -32
- package/dist/esm/SheetModal/detents.mjs.map +1 -1
- package/dist/esm/SheetModal/detents.native.js +2 -38
- package/dist/esm/SheetModal/detents.native.js.map +1 -1
- package/dist/esm/SheetModal/index.mjs +3 -0
- package/dist/esm/SheetModal/index.mjs.map +1 -1
- package/dist/esm/SheetModal/index.native.js +8 -7
- package/dist/esm/SheetModal/index.native.js.map +1 -1
- package/dist/esm/views/List.mjs.map +1 -1
- package/dist/esm/views/ListRow.mjs +102 -20
- package/dist/esm/views/ListRow.mjs.map +1 -1
- package/dist/esm/views/ListRow.native.js +105 -21
- package/dist/esm/views/ListRow.native.js.map +1 -1
- package/dist/jsx/SheetModal/detents.mjs +2 -32
- package/dist/jsx/SheetModal/detents.mjs.map +1 -1
- package/dist/jsx/SheetModal/detents.native.js +11 -43
- package/dist/jsx/SheetModal/detents.native.js.map +1 -1
- package/dist/jsx/SheetModal/index.mjs +3 -0
- package/dist/jsx/SheetModal/index.mjs.map +1 -1
- package/dist/jsx/SheetModal/index.native.js +7 -6
- package/dist/jsx/SheetModal/index.native.js.map +1 -1
- package/dist/jsx/views/List.mjs.map +1 -1
- package/dist/jsx/views/List.native.js.map +1 -1
- package/dist/jsx/views/ListRow.mjs +102 -20
- package/dist/jsx/views/ListRow.mjs.map +1 -1
- package/dist/jsx/views/ListRow.native.js +104 -20
- package/dist/jsx/views/ListRow.native.js.map +1 -1
- package/package.json +7 -7
- package/src/SheetModal/SheetModal.detentLayout.spec.tsx +65 -1
- package/src/SheetModal/SheetModal.spec.tsx +8 -3
- package/src/SheetModal/SheetModal.stories.tsx +17 -0
- package/src/SheetModal/detents.ts +25 -78
- package/src/SheetModal/index.native.tsx +13 -9
- package/src/SheetModal/index.tsx +19 -5
- package/src/index.gnome.ts +1 -1
- package/src/views/List.tsx +1 -0
- package/src/views/ListRow.spec.tsx +10 -11
- package/src/views/ListRow.stories.tsx +112 -0
- package/src/views/ListRow.tone.spec.tsx +221 -0
- package/src/views/ListRow.tsx +151 -20
- package/types/SheetModal/detents.d.ts +9 -54
- package/types/SheetModal/detents.d.ts.map +1 -1
- package/types/SheetModal/index.d.ts +18 -5
- package/types/SheetModal/index.d.ts.map +1 -1
- package/types/SheetModal/index.native.d.ts +1 -1
- package/types/SheetModal/index.native.d.ts.map +1 -1
- package/types/index.gnome.d.ts +1 -1
- package/types/index.gnome.d.ts.map +1 -1
- package/types/views/List.d.ts +1 -1
- package/types/views/List.d.ts.map +1 -1
- package/types/views/ListRow.d.ts +33 -3
- package/types/views/ListRow.d.ts.map +1 -1
package/src/views/ListRow.tsx
CHANGED
|
@@ -1,14 +1,16 @@
|
|
|
1
|
-
import { componentColors } from "../componentColors";
|
|
2
1
|
import { useDirection } from "../hooks/useDirection";
|
|
3
2
|
import { ImageFramingContext } from "../images/Image/framing";
|
|
4
3
|
import { Spinner } from "@multiplatform.one/forms";
|
|
5
4
|
import {
|
|
6
5
|
IconSlot,
|
|
7
6
|
type IconSlotValue,
|
|
7
|
+
Intent,
|
|
8
|
+
type IntentProps,
|
|
8
9
|
MIN_PRESS_TARGET,
|
|
9
10
|
recipeKeyAbove,
|
|
10
11
|
sizeRecipeForToken,
|
|
11
12
|
type SizeRecipeToken,
|
|
13
|
+
useAccentOnSurface,
|
|
12
14
|
useResolvedKnobs,
|
|
13
15
|
} from "@multiplatform.one/theme";
|
|
14
16
|
import { CaretLeftIcon, CaretRightIcon } from "@phosphor-icons/react";
|
|
@@ -47,7 +49,7 @@ export function useListItemState(): ListItemState {
|
|
|
47
49
|
* role on one line, and with a subtitle the row is a two-line Mail row whose
|
|
48
50
|
* trailing meta is a caption at the top right.
|
|
49
51
|
*/
|
|
50
|
-
export interface ListRowProps extends ListRowAccessoryProps {
|
|
52
|
+
export interface ListRowProps extends ListRowAccessoryProps, ListRowToneProps {
|
|
51
53
|
/** Leading glyph slot — fixed box so titles share one x (LC-08). */
|
|
52
54
|
icon?: ReactNode;
|
|
53
55
|
/**
|
|
@@ -97,6 +99,67 @@ interface ListRowAccessoryProps {
|
|
|
97
99
|
destructive?: boolean;
|
|
98
100
|
}
|
|
99
101
|
|
|
102
|
+
/**
|
|
103
|
+
* The state a row's own text carries: MPO's intent vocabulary, so a caller
|
|
104
|
+
* names the state and never a colour.
|
|
105
|
+
*/
|
|
106
|
+
export type ListRowTone = IntentProps["name"];
|
|
107
|
+
|
|
108
|
+
/**
|
|
109
|
+
* What a row's text says for itself (FZ-10733). A settings row marks state in
|
|
110
|
+
* the line that carries it — the failing machine's name, the reason a run
|
|
111
|
+
* stopped — so the state reads where the reader already is, with no badge and
|
|
112
|
+
* no second row. `destructive` is the row-level `"error"`: it says the row's
|
|
113
|
+
* ACTION is dangerous and tints the leading glyph with the title, where a tone
|
|
114
|
+
* says what one line of text is reporting.
|
|
115
|
+
*
|
|
116
|
+
* Precedence on a run, strongest first: the selected ink, `destructive`,
|
|
117
|
+
* `done`, then the tone. A finished row reads finished, not toned.
|
|
118
|
+
*/
|
|
119
|
+
interface ListRowToneProps {
|
|
120
|
+
/** The title reports a state: it takes that intent's ink. */
|
|
121
|
+
titleTone?: ListRowTone;
|
|
122
|
+
/** The subtitle reports a state: it takes that intent's ink. */
|
|
123
|
+
subtitleTone?: ListRowTone;
|
|
124
|
+
/**
|
|
125
|
+
* The title is machine text — an id, a path, a command — so it renders in
|
|
126
|
+
* the mono family, untracked, and columns of ids line up down the group. A
|
|
127
|
+
* literal the reader must COPY is a `MachineLiteral` in the slot (LC-221).
|
|
128
|
+
*/
|
|
129
|
+
titleMono?: boolean;
|
|
130
|
+
/** The subtitle is machine text: the mono family, untracked. */
|
|
131
|
+
subtitleMono?: boolean;
|
|
132
|
+
}
|
|
133
|
+
|
|
134
|
+
/**
|
|
135
|
+
* The step a semantic tone paints. `$color11` resolved inside the tone's own
|
|
136
|
+
* hue sub-theme is the intent ink the theme build holds to AA on every page
|
|
137
|
+
* surface in both schemes (`intentInkFloor`, swept by theme's colorRules), and
|
|
138
|
+
* a preset that restates an intent moves it. The base ramp's `$red11` carries
|
|
139
|
+
* no such floor, which is why the tone rides the sub-theme rather than naming
|
|
140
|
+
* a hue here.
|
|
141
|
+
*/
|
|
142
|
+
const intentInk = "$color11";
|
|
143
|
+
|
|
144
|
+
/**
|
|
145
|
+
* Puts a run in a semantic tone's hue sub-theme, where `intentInk` is that
|
|
146
|
+
* intent's ink. Accent is left on the base theme: its accent ramp already
|
|
147
|
+
* tracks the active tint, and the `accent` sub-theme is the solid ramp, which
|
|
148
|
+
* is a fill and not an ink. Same split as Toast.
|
|
149
|
+
*/
|
|
150
|
+
function Toned({ tone, children }: { tone: ListRowTone | undefined; children: ReactNode }) {
|
|
151
|
+
if (!tone || tone === "accent") return <>{children}</>;
|
|
152
|
+
return <Intent name={tone}>{children}</Intent>;
|
|
153
|
+
}
|
|
154
|
+
|
|
155
|
+
/** The mono family a machine-text run takes, untracked so a literal reads as written. */
|
|
156
|
+
const monoRun = { fontFamily: "$mono", letterSpacing: 0 } as const;
|
|
157
|
+
|
|
158
|
+
/** Publishes the tone a run ended up with, for a test and for an app's own checks. */
|
|
159
|
+
function toneAttrs(tone: ListRowTone | undefined) {
|
|
160
|
+
return tone ? ({ "data-list-tone": tone } as Record<string, unknown>) : null;
|
|
161
|
+
}
|
|
162
|
+
|
|
100
163
|
function RowText({
|
|
101
164
|
children,
|
|
102
165
|
...props
|
|
@@ -108,6 +171,60 @@ function RowText({
|
|
|
108
171
|
return <>{children}</>;
|
|
109
172
|
}
|
|
110
173
|
|
|
174
|
+
/**
|
|
175
|
+
* An accent run, which reads the shared accent-on-surface ink. It stands as its
|
|
176
|
+
* own component so only a row that asks for the accent tone subscribes to the
|
|
177
|
+
* theme for it.
|
|
178
|
+
*/
|
|
179
|
+
function AccentRun({ children, ...props }: React.ComponentProps<typeof RowText>) {
|
|
180
|
+
const ink = useAccentOnSurface();
|
|
181
|
+
return (
|
|
182
|
+
<RowText {...props} color={ink} {...toneAttrs("accent")}>
|
|
183
|
+
{children}
|
|
184
|
+
</RowText>
|
|
185
|
+
);
|
|
186
|
+
}
|
|
187
|
+
|
|
188
|
+
/**
|
|
189
|
+
* One of the row's two text runs. `resting` is the ink its role and the row's
|
|
190
|
+
* state give it; a tone replaces that ink, and a semantic tone resolves it on
|
|
191
|
+
* the intent's own hue sub-theme.
|
|
192
|
+
*/
|
|
193
|
+
function TonedRun({
|
|
194
|
+
tone,
|
|
195
|
+
resting,
|
|
196
|
+
mono = false,
|
|
197
|
+
children,
|
|
198
|
+
...props
|
|
199
|
+
}: {
|
|
200
|
+
tone: ListRowTone | undefined;
|
|
201
|
+
resting: string;
|
|
202
|
+
mono?: boolean;
|
|
203
|
+
} & React.ComponentProps<typeof RowText>) {
|
|
204
|
+
const voice = mono ? monoRun : null;
|
|
205
|
+
if (!tone) {
|
|
206
|
+
return (
|
|
207
|
+
<RowText {...props} {...voice} color={resting}>
|
|
208
|
+
{children}
|
|
209
|
+
</RowText>
|
|
210
|
+
);
|
|
211
|
+
}
|
|
212
|
+
if (tone === "accent") {
|
|
213
|
+
return (
|
|
214
|
+
<AccentRun {...props} {...voice}>
|
|
215
|
+
{children}
|
|
216
|
+
</AccentRun>
|
|
217
|
+
);
|
|
218
|
+
}
|
|
219
|
+
return (
|
|
220
|
+
<Intent name={tone}>
|
|
221
|
+
<RowText {...props} {...voice} color={intentInk} {...toneAttrs(tone)}>
|
|
222
|
+
{children}
|
|
223
|
+
</RowText>
|
|
224
|
+
</Intent>
|
|
225
|
+
);
|
|
226
|
+
}
|
|
227
|
+
|
|
111
228
|
/**
|
|
112
229
|
* Trailing Finder/Desk column. Inherits selected fill ink (LC-71). `width`
|
|
113
230
|
* fixes the column (a size token or a measured px) so the same column lines
|
|
@@ -257,13 +374,20 @@ export function ListRow({
|
|
|
257
374
|
disclosure = false,
|
|
258
375
|
loading = false,
|
|
259
376
|
destructive = false,
|
|
377
|
+
titleTone,
|
|
378
|
+
subtitleTone,
|
|
379
|
+
titleMono = false,
|
|
380
|
+
subtitleMono = false,
|
|
260
381
|
}: ListRowProps) {
|
|
261
382
|
const { knobProps } = useResolvedKnobs();
|
|
262
383
|
const { selected, selectedInk, loading: itemLoading } = useListItemState();
|
|
263
384
|
const { headline, meta: metaRole, caption } = knobProps.textRole;
|
|
264
385
|
const selectedOverride = selected && selectedInk ? selectedInk : undefined;
|
|
265
|
-
const
|
|
266
|
-
const
|
|
386
|
+
const rowTone: ListRowTone | undefined = destructive ? "error" : undefined;
|
|
387
|
+
const glyphTone = selectedOverride ? undefined : rowTone;
|
|
388
|
+
const titleRunTone = selectedOverride ? undefined : (rowTone ?? (done ? undefined : titleTone));
|
|
389
|
+
const subtitleRunTone = selectedOverride || done ? undefined : subtitleTone;
|
|
390
|
+
const ink = glyphTone ? intentInk : (selectedOverride ?? knobProps.textAccentColor);
|
|
267
391
|
const busy = loading || Boolean(itemLoading);
|
|
268
392
|
const iconSize = listLeadingIconSize(knobProps.sizeToken);
|
|
269
393
|
const leading = icon ? <IconSlot icon={icon} size={iconSize} color={ink} /> : null;
|
|
@@ -297,44 +421,51 @@ export function ListRow({
|
|
|
297
421
|
</View>
|
|
298
422
|
) : null}
|
|
299
423
|
{leading ? (
|
|
300
|
-
<
|
|
301
|
-
|
|
302
|
-
|
|
303
|
-
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
|
|
308
|
-
|
|
309
|
-
|
|
424
|
+
<Toned tone={glyphTone}>
|
|
425
|
+
<View
|
|
426
|
+
width={iconSize}
|
|
427
|
+
height={iconSize}
|
|
428
|
+
flexShrink={0}
|
|
429
|
+
alignItems="center"
|
|
430
|
+
justifyContent="center"
|
|
431
|
+
{...({ "data-list-slot": "icon", color: ink } as Record<string, unknown>)}
|
|
432
|
+
{...toneAttrs(glyphTone)}
|
|
433
|
+
>
|
|
434
|
+
{leading}
|
|
435
|
+
</View>
|
|
436
|
+
</Toned>
|
|
310
437
|
) : null}
|
|
311
438
|
<YStack
|
|
312
439
|
flex={1}
|
|
313
440
|
minWidth={0}
|
|
314
441
|
{...({ "data-list-slot": "title" } as Record<string, unknown>)}
|
|
315
442
|
>
|
|
316
|
-
<
|
|
443
|
+
<TonedRun
|
|
444
|
+
tone={titleRunTone}
|
|
445
|
+
resting={selectedOverride ?? (done ? metaRole.color : headline.color)}
|
|
446
|
+
mono={titleMono}
|
|
317
447
|
{...knobProps.body}
|
|
318
448
|
{...headline}
|
|
319
|
-
color={selectedOverride ?? errorInk ?? (done ? metaRole.color : headline.color)}
|
|
320
449
|
{...doneProps}
|
|
321
450
|
numberOfLines={titleLines}
|
|
322
451
|
userSelect="none"
|
|
323
452
|
>
|
|
324
453
|
{title}
|
|
325
|
-
</
|
|
454
|
+
</TonedRun>
|
|
326
455
|
{twoLine ? (
|
|
327
|
-
<
|
|
456
|
+
<TonedRun
|
|
457
|
+
tone={subtitleRunTone}
|
|
458
|
+
resting={selectedOverride ?? metaRole.color}
|
|
459
|
+
mono={subtitleMono}
|
|
328
460
|
{...knobProps.body}
|
|
329
461
|
{...metaRole}
|
|
330
|
-
color={selectedOverride ?? metaRole.color}
|
|
331
462
|
{...doneProps}
|
|
332
463
|
opacity={selected ? 0.85 : 1}
|
|
333
464
|
numberOfLines={subtitleLines === "none" ? undefined : subtitleLines}
|
|
334
465
|
userSelect="none"
|
|
335
466
|
>
|
|
336
467
|
{subtitle}
|
|
337
|
-
</
|
|
468
|
+
</TonedRun>
|
|
338
469
|
) : null}
|
|
339
470
|
</YStack>
|
|
340
471
|
{!busy && meta != null && meta !== false ? (
|
|
@@ -1,59 +1,14 @@
|
|
|
1
1
|
/**
|
|
2
|
-
* SheetModal detent geometry
|
|
3
|
-
* without standing up a React Native renderer.
|
|
2
|
+
* SheetModal detent geometry.
|
|
4
3
|
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
7
|
-
* and `
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
export declare const minSheetHeight = 180;
|
|
11
|
-
/**
|
|
12
|
-
* Half-open detent for a sheet that owns a scrollport, as a fraction of its
|
|
13
|
-
* full height. Mirrors FloatingPanel so both native sheets drag alike.
|
|
14
|
-
*/
|
|
15
|
-
export declare const mediumDetent = 0.55;
|
|
16
|
-
export interface ResolveSheetDetentsOptions {
|
|
17
|
-
/** Full (expanded) height of the sheet, in points. */
|
|
18
|
-
travel: number;
|
|
19
|
-
/** The sheet owns a scrollport, so a half-open rest is meaningful. */
|
|
20
|
-
scrollable?: boolean;
|
|
21
|
-
/** Percent detent from the caller — the same prop the web Sheet takes. */
|
|
22
|
-
snapPoint?: number;
|
|
23
|
-
}
|
|
24
|
-
/**
|
|
25
|
-
* The heights the sheet is allowed to rest at, largest first.
|
|
4
|
+
* The implementation moved to `@multiplatform.one/forms`
|
|
5
|
+
* (`shared/sheetDetents.ts`) in FZ-455, because FloatingPanel's sheet face
|
|
6
|
+
* needs the same geometry and `forms` is the lower layer. Keeping a second
|
|
7
|
+
* copy here is what let MPO-71 rewrite one of them from a stale version and
|
|
8
|
+
* drop the `snapPoint` push for a month.
|
|
26
9
|
*
|
|
27
|
-
*
|
|
28
|
-
* Native honours the same prop by turning that percent into a detent, so a
|
|
29
|
-
* caller that writes `snapPoint={85}` gets an 85%-height rest on both twins
|
|
30
|
-
* rather than the prop being silently dropped on device.
|
|
31
|
-
*
|
|
32
|
-
* Anything shorter than `minSheetHeight` is discarded, because a sheet that
|
|
33
|
-
* rests below that is indistinguishable from a dismissed one. A sheet whose
|
|
34
|
-
* full height is already under the floor keeps its own height, otherwise it
|
|
35
|
-
* would have no detents at all.
|
|
36
|
-
*/
|
|
37
|
-
export declare function resolveSheetDetents({ travel, scrollable, snapPoint, }: ResolveSheetDetentsOptions): number[];
|
|
38
|
-
/** The large detent: the tallest a content-sized sheet grows, as a fraction of the window. */
|
|
39
|
-
export declare const largeDetentRatio = 0.85;
|
|
40
|
-
/** Percent rest of a `fill` sheet with no `snapPoint`: it has no intrinsic height to fit. */
|
|
41
|
-
export declare const fillSnapPoint = 60;
|
|
42
|
-
export type WebSnap = {
|
|
43
|
-
snapPointsMode: "fit";
|
|
44
|
-
} | {
|
|
45
|
-
snapPointsMode: "percent";
|
|
46
|
-
snapPoints: number[];
|
|
47
|
-
};
|
|
48
|
-
/**
|
|
49
|
-
* The web Sheet's snap props. FZ-7977: a sheet with no `snapPoint` opens at
|
|
50
|
-
* its content's height (capped at the large detent), the way the native twin
|
|
51
|
-
* already sizes to content, instead of a fixed 60% with a dead band under
|
|
52
|
-
* short content. A caller's percent still wins, and a `fill` sheet, which has
|
|
53
|
-
* no intrinsic height, keeps a percent rest.
|
|
10
|
+
* This file stays as the path SheetModal and its specs already import.
|
|
54
11
|
*/
|
|
55
|
-
export
|
|
56
|
-
|
|
57
|
-
fill?: boolean;
|
|
58
|
-
}): WebSnap;
|
|
12
|
+
export { fillSnapPoint, largeDetentRatio, mediumDetent, minSheetHeight, openingDetentIndex, resolveDetentPercents, resolveSheetDetents, resolveWebSnap, sheetDetent, sheetDismissThreshold, } from "@multiplatform.one/forms";
|
|
13
|
+
export type { DetentSetOptions, ResolveSheetDetentsOptions, ResolveWebSnapOptions, WebSnap, } from "@multiplatform.one/forms";
|
|
59
14
|
//# sourceMappingURL=detents.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"detents.d.ts","sourceRoot":"","sources":["../../src/SheetModal/detents.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"detents.d.ts","sourceRoot":"","sources":["../../src/SheetModal/detents.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;GAUG;AAEH,OAAO,EACL,aAAa,EACb,gBAAgB,EAChB,YAAY,EACZ,cAAc,EACd,kBAAkB,EAClB,qBAAqB,EACrB,mBAAmB,EACnB,cAAc,EACd,WAAW,EACX,qBAAqB,GACtB,MAAM,0BAA0B,CAAC;AAClC,YAAY,EACV,gBAAgB,EAChB,0BAA0B,EAC1B,qBAAqB,EACrB,OAAO,GACR,MAAM,0BAA0B,CAAC"}
|
|
@@ -26,12 +26,25 @@ export interface SheetModalProps {
|
|
|
26
26
|
*/
|
|
27
27
|
headerActions?: ReactNode;
|
|
28
28
|
/**
|
|
29
|
-
* Percent
|
|
30
|
-
*
|
|
31
|
-
*
|
|
32
|
-
*
|
|
29
|
+
* Percent rest. The web twin OPENS there; the native twin opens at full
|
|
30
|
+
* height and takes it as a detent to drag to, which is the twins' one
|
|
31
|
+
* remaining disagreement (FZ-455). Omitted: the sheet opens at its
|
|
32
|
+
* content's height, capped at the large detent (HIG: a sheet as tall as
|
|
33
|
+
* what it holds). A `fill` sheet has no intrinsic height, so it falls back
|
|
34
|
+
* to 60%. With `detents`, it names which of them the web twin opens at.
|
|
33
35
|
*/
|
|
34
36
|
snapPoint?: number;
|
|
37
|
+
/**
|
|
38
|
+
* The rest positions the sheet may settle at, as percents of its full
|
|
39
|
+
* height, the way `UISheetPresentationController.detents` takes an array
|
|
40
|
+
* (FZ-455). A finger on the grabber drags between them and releases onto
|
|
41
|
+
* the nearest; a release below the smallest dismisses (LC-21). Order does
|
|
42
|
+
* not matter, `sheetDetent.medium` / `.large` name the HIG rungs, and
|
|
43
|
+
* `snapPoint` names which one the web twin opens at. Omitted, the set is the sheet's
|
|
44
|
+
* full height plus `snapPoint` and the half-open rest of a `scrollable`
|
|
45
|
+
* sheet, so no existing sheet changes shape.
|
|
46
|
+
*/
|
|
47
|
+
detents?: number[];
|
|
35
48
|
/** Wrap children in the sheet's scroll container. */
|
|
36
49
|
scrollable?: boolean;
|
|
37
50
|
/**
|
|
@@ -47,5 +60,5 @@ export interface SheetModalProps {
|
|
|
47
60
|
*/
|
|
48
61
|
flush?: boolean;
|
|
49
62
|
}
|
|
50
|
-
export declare function SheetModal({ open, onOpenChange, children, header: headerContent, headerActions, snapPoint, scrollable, fill, flush, }: SheetModalProps): import("react/jsx-runtime").JSX.Element;
|
|
63
|
+
export declare function SheetModal({ open, onOpenChange, children, header: headerContent, headerActions, snapPoint, detents, scrollable, fill, flush, }: SheetModalProps): import("react/jsx-runtime").JSX.Element;
|
|
51
64
|
//# sourceMappingURL=index.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/SheetModal/index.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAcH,OAAO,EAA4B,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AASjE,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,OAAO,CAAC;IACd,YAAY,EAAE,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI,CAAC;IACtC,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB;;;;OAIG;IACH,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB;;;;OAIG;IACH,aAAa,CAAC,EAAE,SAAS,CAAC;IAC1B
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/SheetModal/index.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AAcH,OAAO,EAA4B,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AASjE,MAAM,WAAW,eAAe;IAC9B,IAAI,EAAE,OAAO,CAAC;IACd,YAAY,EAAE,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI,CAAC;IACtC,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB;;;;OAIG;IACH,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB;;;;OAIG;IACH,aAAa,CAAC,EAAE,SAAS,CAAC;IAC1B;;;;;;;OAOG;IACH,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB;;;;;;;;;OASG;IACH,OAAO,CAAC,EAAE,MAAM,EAAE,CAAC;IACnB,qDAAqD;IACrD,UAAU,CAAC,EAAE,OAAO,CAAC;IACrB;;;;;OAKG;IACH,IAAI,CAAC,EAAE,OAAO,CAAC;IACf;;;OAGG;IACH,KAAK,CAAC,EAAE,OAAO,CAAC;CACjB;AA2ED,wBAAgB,UAAU,CAAC,EACzB,IAAI,EACJ,YAAY,EACZ,QAAQ,EACR,MAAM,EAAE,aAAa,EACrB,aAAa,EACb,SAAS,EACT,OAAO,EACP,UAAU,EACV,IAAY,EACZ,KAAa,GACd,EAAE,eAAe,2CA4GjB"}
|
|
@@ -17,5 +17,5 @@
|
|
|
17
17
|
*/
|
|
18
18
|
import type { SheetModalProps } from "./index";
|
|
19
19
|
export type { SheetModalProps } from "./index";
|
|
20
|
-
export declare function SheetModal({ open, onOpenChange, children, header: headerContent, headerActions, snapPoint, scrollable, fill, flush, }: SheetModalProps): import("react/jsx-runtime").JSX.Element;
|
|
20
|
+
export declare function SheetModal({ open, onOpenChange, children, header: headerContent, headerActions, snapPoint, detents, scrollable, fill, flush, }: SheetModalProps): import("react/jsx-runtime").JSX.Element;
|
|
21
21
|
//# sourceMappingURL=index.native.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.native.d.ts","sourceRoot":"","sources":["../../src/SheetModal/index.native.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;
|
|
1
|
+
{"version":3,"file":"index.native.d.ts","sourceRoot":"","sources":["../../src/SheetModal/index.native.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;GAgBG;AAqDH,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAG/C,YAAY,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC;AAsB/C,wBAAgB,UAAU,CAAC,EACzB,IAAI,EACJ,YAAY,EACZ,QAAQ,EACR,MAAM,EAAE,aAAa,EACrB,aAAa,EACb,SAAS,EACT,OAAO,EACP,UAAU,EACV,IAAY,EACZ,KAAa,GACd,EAAE,eAAe,2CA4djB"}
|
package/types/index.gnome.d.ts
CHANGED
|
@@ -16,7 +16,7 @@ export { themed } from "./icons/themed";
|
|
|
16
16
|
export { ShortcutCard } from "./views/ShortcutCard";
|
|
17
17
|
export type { ShortcutCardProps, ShortcutConfig } from "./views/ShortcutCard";
|
|
18
18
|
export { ListItemStateContext, listLeadingIconSize, ListRow, ListRowFact, ListRowMeta, listRowPressDelayMs, listRowTouchProps, useListItemState, } from "./views/ListRow";
|
|
19
|
-
export type { ListItemState, ListRowProps } from "./views/ListRow";
|
|
19
|
+
export type { ListItemState, ListRowProps, ListRowTone } from "./views/ListRow";
|
|
20
20
|
export { ListGroup, ListGroupItem } from "./views/ListGroup";
|
|
21
21
|
export type { ListGroupItemProps, ListGroupProps, ListGroupVariant } from "./views/ListGroup";
|
|
22
22
|
export { __resetToastViewportRegistry, claimToastViewport, dismissAllToasts, dismissToast, getToasts, getToastViewportOwner, releaseToastViewport, resetToasts, resolveToastPolicy, showToast, subscribeToasts, subscribeToastViewport, TOAST_ACTION_MIN_MS, TOAST_DEFAULT_MS, TOAST_ERROR_MS, TOAST_EXIT_MS, TOAST_WARNING_MS, } from "./Toast/store";
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.gnome.d.ts","sourceRoot":"","sources":["../src/index.gnome.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EACjB,UAAU,EACV,WAAW,EACX,gBAAgB,EAChB,cAAc,EACd,aAAa,EACb,UAAU,EACV,cAAc,EACd,WAAW,EACX,UAAU,EACV,kBAAkB,EAClB,MAAM,EACN,aAAa,EACb,kBAAkB,GACnB,MAAM,gBAAgB,CAAC;AACxB,YAAY,EACV,eAAe,EACf,qBAA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AAiB,EAAE,cAAc,EAAE,MAAM,sBAAsB,CAAC;AAC9E,OAAO,EACL,oBAAoB,EACpB,mBAAmB,EACnB,OAAO,EACP,WAAW,EACX,WAAW,EACX,mBAAmB,EACnB,iBAAiB,EACjB,gBAAgB,GACjB,MAAM,iBAAiB,CAAC;AACzB,YAAY,EAAE,aAAa,EAAE,YAAY,EAAE,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"index.gnome.d.ts","sourceRoot":"","sources":["../src/index.gnome.ts"],"names":[],"mappings":"AAAA,OAAO,EACL,iBAAiB,EACjB,UAAU,EACV,WAAW,EACX,gBAAgB,EAChB,cAAc,EACd,aAAa,EACb,UAAU,EACV,cAAc,EACd,WAAW,EACX,UAAU,EACV,kBAAkB,EAClB,MAAM,EACN,aAAa,EACb,kBAAkB,GACnB,MAAM,gBAAgB,CAAC;AACxB,YAAY,EACV,eAAe,EACf,qBAAqB,EACrB,mBAAmB,EACnB,kBAAkB,EAClB,eAAe,EACf,gBAAgB,EAChB,WAAW,EACX,kBAAkB,GACnB,MAAM,gBAAgB,CAAC;AACxB,OAAO,EACL,wBAAwB,EACxB,sBAAsB,EACtB,oBAAoB,EACpB,wBAAwB,GACzB,MAAM,4BAA4B,CAAC;AACpC,YAAY,EAAE,iBAAiB,EAAE,MAAM,4BAA4B,CAAC;AACpE,OAAO,EAAE,YAAY,EAAE,MAAM,wBAAwB,CAAC;AACtD,YAAY,EAAE,UAAU,EAAE,iBAAiB,EAAE,MAAM,wBAAwB,CAAC;AAC5E,OAAO,EACL,eAAe,EACf,mBAAmB,EACnB,oBAAoB,EACpB,0BAA0B,EAC1B,0BAA0B,EAC1B,sBAAsB,GACvB,MAAM,2BAA2B,CAAC;AACnC,YAAY,EAAE,oBAAoB,EAAE,oBAAoB,EAAE,MAAM,2BAA2B,CAAC;AAC5F,OAAO,EAAE,SAAS,EAAE,UAAU,EAAE,aAAa,EAAE,MAAM,qBAAqB,CAAC;AAC3E,YAAY,EAAE,cAA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,kBAAkB,CAAC;AAC5C,OAAO,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAC7D,YAAY,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC"}
|
package/types/views/List.d.ts
CHANGED
|
@@ -2,7 +2,7 @@ import type { RegisterableHotkey } from "@tanstack/react-hotkeys";
|
|
|
2
2
|
import React, { type ReactNode } from "react";
|
|
3
3
|
import { type SizeTokens, type YStackProps } from "tamagui";
|
|
4
4
|
import { type ListItemState } from "./ListRow";
|
|
5
|
-
export { ListRow, ListRowFact, ListRowMeta, listLeadingIconSize, listRowLongPressMs, listRowPressDelayMs, listRowTouchProps, useListItemState, type ListItemState, type ListRowProps, } from "./ListRow";
|
|
5
|
+
export { ListRow, ListRowFact, ListRowMeta, listLeadingIconSize, listRowLongPressMs, listRowPressDelayMs, listRowTouchProps, useListItemState, type ListItemState, type ListRowProps, type ListRowTone, } from "./ListRow";
|
|
6
6
|
export { ListGroup, ListGroupItem, type ListGroupItemProps, type ListGroupProps, type ListGroupVariant, } from "./ListGroup";
|
|
7
7
|
/**
|
|
8
8
|
* Configurable hotkey bindings for the List component.
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"List.d.ts","sourceRoot":"","sources":["../../src/views/List.tsx"],"names":[],"mappings":"AAoBA,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAC;AAClE,OAAO,KAAK,EAAE,EAAwC,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAEpF,OAAO,EAAwB,KAAK,UAAU,EAAE,KAAK,WAAW,EAAE,MAAM,SAAS,CAAC;AAClF,OAAO,EAA2C,KAAK,aAAa,EAAE,MAAM,WAAW,CAAC;AAExF,OAAO,EACL,OAAO,EACP,WAAW,EACX,WAAW,EACX,mBAAmB,EACnB,kBAAkB,EAClB,mBAAmB,EACnB,iBAAiB,EACjB,gBAAgB,EAChB,KAAK,aAAa,EAClB,KAAK,YAAY,
|
|
1
|
+
{"version":3,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B,EACjB,KAAY,EACZ,OAAO,EACP,YAAY,EAAE,gBAAgB,EAC9B,QAAY,EACZ,YAAY,EAAE,gBAAgB,EAC9B,MAAM,EAAE,UAAU,EAClB,aAAa,EAAE,iBAAiB,EAChC,oBAAoB,EACpB,iBAAiB,EACjB,YAAY,EAAE,SAAS,EACvB,OAAO,EAAE,eAAe,EACxB,IAAI,EACJ,GAAG,UAAU,EACd,EAAE,SAAS,CAAC,CAAC,CAAC,2CA8Sd"}
|
package/types/views/ListRow.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { type IconSlotValue } from "@multiplatform.one/theme";
|
|
1
|
+
import { type IconSlotValue, type IntentProps } from "@multiplatform.one/theme";
|
|
2
2
|
import type React from "react";
|
|
3
3
|
import { type ReactNode } from "react";
|
|
4
4
|
import { type SizeTokens } from "tamagui";
|
|
@@ -22,7 +22,7 @@ export declare function useListItemState(): ListItemState;
|
|
|
22
22
|
* role on one line, and with a subtitle the row is a two-line Mail row whose
|
|
23
23
|
* trailing meta is a caption at the top right.
|
|
24
24
|
*/
|
|
25
|
-
export interface ListRowProps extends ListRowAccessoryProps {
|
|
25
|
+
export interface ListRowProps extends ListRowAccessoryProps, ListRowToneProps {
|
|
26
26
|
/** Leading glyph slot — fixed box so titles share one x (LC-08). */
|
|
27
27
|
icon?: ReactNode;
|
|
28
28
|
/**
|
|
@@ -70,6 +70,36 @@ interface ListRowAccessoryProps {
|
|
|
70
70
|
*/
|
|
71
71
|
destructive?: boolean;
|
|
72
72
|
}
|
|
73
|
+
/**
|
|
74
|
+
* The state a row's own text carries: MPO's intent vocabulary, so a caller
|
|
75
|
+
* names the state and never a colour.
|
|
76
|
+
*/
|
|
77
|
+
export type ListRowTone = IntentProps["name"];
|
|
78
|
+
/**
|
|
79
|
+
* What a row's text says for itself (FZ-10733). A settings row marks state in
|
|
80
|
+
* the line that carries it — the failing machine's name, the reason a run
|
|
81
|
+
* stopped — so the state reads where the reader already is, with no badge and
|
|
82
|
+
* no second row. `destructive` is the row-level `"error"`: it says the row's
|
|
83
|
+
* ACTION is dangerous and tints the leading glyph with the title, where a tone
|
|
84
|
+
* says what one line of text is reporting.
|
|
85
|
+
*
|
|
86
|
+
* Precedence on a run, strongest first: the selected ink, `destructive`,
|
|
87
|
+
* `done`, then the tone. A finished row reads finished, not toned.
|
|
88
|
+
*/
|
|
89
|
+
interface ListRowToneProps {
|
|
90
|
+
/** The title reports a state: it takes that intent's ink. */
|
|
91
|
+
titleTone?: ListRowTone;
|
|
92
|
+
/** The subtitle reports a state: it takes that intent's ink. */
|
|
93
|
+
subtitleTone?: ListRowTone;
|
|
94
|
+
/**
|
|
95
|
+
* The title is machine text — an id, a path, a command — so it renders in
|
|
96
|
+
* the mono family, untracked, and columns of ids line up down the group. A
|
|
97
|
+
* literal the reader must COPY is a `MachineLiteral` in the slot (LC-221).
|
|
98
|
+
*/
|
|
99
|
+
titleMono?: boolean;
|
|
100
|
+
/** The subtitle is machine text: the mono family, untracked. */
|
|
101
|
+
subtitleMono?: boolean;
|
|
102
|
+
}
|
|
73
103
|
/**
|
|
74
104
|
* Trailing Finder/Desk column. Inherits selected fill ink (LC-71). `width`
|
|
75
105
|
* fixes the column (a size token or a measured px) so the same column lines
|
|
@@ -103,7 +133,7 @@ export declare function listLeadingIconSize(sizeToken: string): number;
|
|
|
103
133
|
* starts partway there, at `holdCueStartMs`.
|
|
104
134
|
*/
|
|
105
135
|
export declare const listRowLongPressMs = 500;
|
|
106
|
-
export declare function ListRow({ icon, media, title, titleLines, subtitle, subtitleLines, meta, done, disclosure, loading, destructive, }: ListRowProps): import("react/jsx-runtime").JSX.Element;
|
|
136
|
+
export declare function ListRow({ icon, media, title, titleLines, subtitle, subtitleLines, meta, done, disclosure, loading, destructive, titleTone, subtitleTone, titleMono, subtitleMono, }: ListRowProps): import("react/jsx-runtime").JSX.Element;
|
|
107
137
|
/**
|
|
108
138
|
* A row in a scroller waits this long before it paints its press, the delay
|
|
109
139
|
* UIScrollView gives its content: a touch that becomes a scroll never fills
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"ListRow.d.ts","sourceRoot":"","sources":["../../src/views/ListRow.tsx"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"ListRow.d.ts","sourceRoot":"","sources":["../../src/views/ListRow.tsx"],"names":[],"mappings":"AAGA,OAAO,EAEL,KAAK,aAAa,EAElB,KAAK,WAAW,EAOjB,MAAM,0BAA0B,CAAC;AAElC,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAC/B,OAAO,EAA6B,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAClE,OAAO,EAAqC,KAAK,UAAU,EAAE,MAAM,SAAS,CAAC;AAE7E,sEAAsE;AACtE,MAAM,WAAW,aAAa;IAC5B,QAAQ,EAAE,OAAO,CAAC;IAClB,OAAO,EAAE,OAAO,CAAC;IACjB,sDAAsD;IACtD,WAAW,CAAC,EAAE,MAAM,CAAC;IACrB,OAAO,CAAC,EAAE,OAAO,CAAC;CACnB;AAKD,eAAO,MAAM,oBAAoB,8BAG/B,CAAC;AAEH,+EAA+E;AAC/E,wBAAgB,gBAAgB,IAAI,aAAa,CAEhD;AAED;;;;;;;;GAQG;AACH,MAAM,WAAW,YAAa,SAAQ,qBAAqB,EAAE,gBAAgB;IAC3E,oEAAoE;IACpE,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB;;;OAGG;IACH,KAAK,CAAC,EAAE,SAAS,CAAC;IAClB,KAAK,EAAE,SAAS,CAAC;IACjB,mEAAmE;IACnE,UAAU,CAAC,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,gEAAgE;IAChE,IAAI,CAAC,EAAE,SAAS,CAAC;IACjB;;;OAGG;IACH,IAAI,CAAC,EAAE,OAAO,CAAC;CAChB;AAED;;;GAGG;AACH,UAAU,qBAAqB;IAC7B;;;OAGG;IACH,aAAa,CAAC,EAAE,MAAM,GAAG,MAAM,CAAC;IA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