@nativedesktop/react 0.4.23 → 0.4.26
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/index.js
CHANGED
|
@@ -939,7 +939,7 @@ var styleKeySpec = {
|
|
|
939
939
|
minHeight: null,
|
|
940
940
|
border: ["borderWidth", "borderColor", "borderRadius"]
|
|
941
941
|
};
|
|
942
|
-
var cssClassSpec = ["suggested-action", "destructive-action", "flat", "raised", "circular", "pill", "linked", "toolbar", "spacer", "title-1", "title-2", "title-3", "title-4", "heading", "document", "body", "caption-heading", "caption", "monospace", "numeric", "accent", "success", "warning", "error", "boxed-list", "boxed-list-separate", "card", "activatable", "navigation-sidebar", "nd-native-sidebar", "selection-mode", "osd", "dimmed", "dim-label", "background", "view", "frame", "compact", "menu", "inline", "large-title", "property", "round", "opaque", "devel", "icon-dropshadow", "lowres-icon"];
|
|
942
|
+
var cssClassSpec = ["suggested-action", "destructive-action", "flat", "raised", "circular", "pill", "linked", "toolbar", "spacer", "title-1", "title-2", "title-3", "title-4", "heading", "document", "body", "caption-heading", "caption", "monospace", "numeric", "accent", "success", "warning", "error", "boxed-list", "boxed-list-separate", "card", "activatable", "navigation-sidebar", "nd-native-sidebar", "selection-mode", "osd", "dimmed", "dim-label", "background", "view", "glass", "frame", "compact", "menu", "inline", "large-title", "property", "round", "opaque", "devel", "icon-dropshadow", "lowres-icon"];
|
|
943
943
|
|
|
944
944
|
// src/style-validate.ts
|
|
945
945
|
class StyleError extends Error {
|
package/dist/jsx-runtime.js
CHANGED
|
@@ -14,7 +14,7 @@ var styleKeySpec = {
|
|
|
14
14
|
minHeight: null,
|
|
15
15
|
border: ["borderWidth", "borderColor", "borderRadius"]
|
|
16
16
|
};
|
|
17
|
-
var cssClassSpec = ["suggested-action", "destructive-action", "flat", "raised", "circular", "pill", "linked", "toolbar", "spacer", "title-1", "title-2", "title-3", "title-4", "heading", "document", "body", "caption-heading", "caption", "monospace", "numeric", "accent", "success", "warning", "error", "boxed-list", "boxed-list-separate", "card", "activatable", "navigation-sidebar", "nd-native-sidebar", "selection-mode", "osd", "dimmed", "dim-label", "background", "view", "frame", "compact", "menu", "inline", "large-title", "property", "round", "opaque", "devel", "icon-dropshadow", "lowres-icon"];
|
|
17
|
+
var cssClassSpec = ["suggested-action", "destructive-action", "flat", "raised", "circular", "pill", "linked", "toolbar", "spacer", "title-1", "title-2", "title-3", "title-4", "heading", "document", "body", "caption-heading", "caption", "monospace", "numeric", "accent", "success", "warning", "error", "boxed-list", "boxed-list-separate", "card", "activatable", "navigation-sidebar", "nd-native-sidebar", "selection-mode", "osd", "dimmed", "dim-label", "background", "view", "glass", "frame", "compact", "menu", "inline", "large-title", "property", "round", "opaque", "devel", "icon-dropshadow", "lowres-icon"];
|
|
18
18
|
export {
|
|
19
19
|
jsxs,
|
|
20
20
|
jsx,
|
|
@@ -89,12 +89,15 @@ export interface SourceTreeNode {
|
|
|
89
89
|
actionIds?: string[];
|
|
90
90
|
testID?: string;
|
|
91
91
|
}
|
|
92
|
-
/** CommandPalette result row:
|
|
92
|
+
/** CommandPalette result row, drawn on one line: leading icon, title, subtitle in secondary text after it, and `hint` right-aligned (the action Enter takes on the row, e.g. "Switch to Tab", or a shortcut). `id` is echoed in onActivate. `iconData` (a data: URL or bare base64 image, e.g. a favicon) wins over `iconName`. `completion` on the FIRST row is inline autocompletion: when it starts with what the user typed (case-insensitively) and their last edit inserted text, the field shows the rest of it selected after the caret; Tab or Right accepts it (queryChanged then carries the whole text), typing replaces it, Backspace removes it, after which Enter on that row submits the typed text instead of activating the row. The app supplies rows already filtered and ordered; the widget renders them in order and never filters or reorders. */
|
|
93
93
|
export interface CommandPaletteItem {
|
|
94
94
|
id: string;
|
|
95
95
|
title: string;
|
|
96
96
|
subtitle?: string;
|
|
97
97
|
iconName?: string;
|
|
98
|
+
iconData?: string;
|
|
99
|
+
hint?: string;
|
|
100
|
+
completion?: string;
|
|
98
101
|
}
|
|
99
102
|
/** One datum. `x`/`y` are the numeric axes; `label` names the point on a category axis and names the slice on a pie. The OHLC quartet carries candlestick bodies and wicks and is ignored by every other chart type (which read `y`). */
|
|
100
103
|
export interface ChartPoint {
|
|
@@ -19,7 +19,7 @@ export interface RowJson {
|
|
|
19
19
|
id: string | null;
|
|
20
20
|
subtitle: string | null;
|
|
21
21
|
}
|
|
22
|
-
/** One tree-snapshot node. itemCount is ListView's row count (M5c-D4), null for every widget that isn't data-driven; rows is SourceList's ordered row data, null for every widget that isn't row-driven. role/enabled/focused/value are the accessibility-tree fields (M16): role is the widget's schema-declared automation role (null when the type declares none); enabled/focused/value come from a live per-node backend probe and default to true/false/null on backends without the probe. checked/selected/expanded/placeholder/label/options come from the same probe and are null on every node the field does not apply to (a Label has no checked state), so a locator can ask isChecked/isSelected/isExpanded of any node without first knowing its kind. minSize comes from the same probe, null on backends that do not measure. */
|
|
22
|
+
/** One tree-snapshot node. itemCount is ListView's row count (M5c-D4), null for every widget that isn't data-driven; rows is SourceList's ordered row data, null for every widget that isn't row-driven. role/enabled/focused/value are the accessibility-tree fields (M16): role is the widget's schema-declared automation role (null when the type declares none); enabled/focused/value come from a live per-node backend probe and default to true/false/null on backends without the probe. checked/selected/expanded/placeholder/label/options come from the same probe and are null on every node the field does not apply to (a Label has no checked state), so a locator can ask isChecked/isSelected/isExpanded of any node without first knowing its kind. minSize comes from the same probe, null on backends that do not measure. material is what a tile box is drawn with (glass, raised-glass or fill), from the same probe, null on every other node and on backends that draw tiles one way. */
|
|
23
23
|
export interface JsonNode {
|
|
24
24
|
ref: number;
|
|
25
25
|
type: string;
|
|
@@ -41,6 +41,7 @@ export interface JsonNode {
|
|
|
41
41
|
label: string | null;
|
|
42
42
|
options: string[] | null;
|
|
43
43
|
minSize: MinSize | null;
|
|
44
|
+
material: string | null;
|
|
44
45
|
}
|
|
45
46
|
export interface GetTreeResult {
|
|
46
47
|
coordinateSpace: string;
|
|
@@ -130,6 +131,29 @@ export interface ScrollIntoViewResult {
|
|
|
130
131
|
ok: boolean;
|
|
131
132
|
scrolled: boolean;
|
|
132
133
|
}
|
|
134
|
+
/** One visible palette row. `icon`/`title`/`subtitle`/`hint` are null when the row does not draw that part. `truncated` is true when the title or subtitle is drawn shorter than its text (an ellipsis). */
|
|
135
|
+
export interface PaletteRowLayout {
|
|
136
|
+
row: Geometry;
|
|
137
|
+
icon: Geometry | null;
|
|
138
|
+
title: Geometry | null;
|
|
139
|
+
subtitle: Geometry | null;
|
|
140
|
+
hint: Geometry | null;
|
|
141
|
+
truncated: boolean;
|
|
142
|
+
highlighted: boolean;
|
|
143
|
+
}
|
|
144
|
+
/** `window` is the content area the panel is drawn over; `panel` the card itself; `field` the text field, whose `fieldText` and selection (`selectionStart`, `selectionLength`, in UTF-16 units) show inline autocompletion. `rows` lists the rows currently drawn, top to bottom. */
|
|
145
|
+
export interface PaletteLayout {
|
|
146
|
+
ref: number;
|
|
147
|
+
presented: boolean;
|
|
148
|
+
window: Geometry | null;
|
|
149
|
+
panel: Geometry | null;
|
|
150
|
+
field: Geometry | null;
|
|
151
|
+
fieldText: string;
|
|
152
|
+
selectionStart: number;
|
|
153
|
+
selectionLength: number;
|
|
154
|
+
dimmed: boolean;
|
|
155
|
+
rows: PaletteRowLayout[];
|
|
156
|
+
}
|
|
133
157
|
/** Live page state read off the engine on the UI thread (WebKitGTK's uri/title/is-loading/can-go-back/can-go-forward, WKWebView's url/title/isLoading/canGoBack/canGoForward) — no page JavaScript, no app cooperation. url/title are null before the first commit. */
|
|
134
158
|
export interface WebViewInfo {
|
|
135
159
|
ref: number;
|
|
@@ -261,6 +285,12 @@ export interface WebviewInfoParams {
|
|
|
261
285
|
testId?: string;
|
|
262
286
|
window?: number;
|
|
263
287
|
}
|
|
288
|
+
/** Live geometry of a CommandPalette's presented panel, so a drive can assert its layout (centring, row fit, truncation) instead of reading pixels. Rects use node Geometry units relative to the window the panel is presented over. A palette that is not presented answers {presented:false} with empty rows. Target by exactly one of ref / testId. */
|
|
289
|
+
export interface PaletteLayoutParams {
|
|
290
|
+
ref?: number;
|
|
291
|
+
testId?: string;
|
|
292
|
+
window?: number;
|
|
293
|
+
}
|
|
264
294
|
/** Reads a menu owner's live native menu back, flattened in draw order, so a drive can assert what the user would actually see instead of what the React tree says. Targets a Menubar node (the installed app menu, including the platform's default menus on AppKit), a MenuButton/SplitButton, or a TrayItem; a Menu node answers -32602, since a <menu> only ever draws inside one of those owners. Target by exactly one of ref / testId. */
|
|
265
295
|
export interface MenuModelParams {
|
|
266
296
|
ref?: number;
|
|
@@ -367,6 +397,10 @@ export interface RpcMethods {
|
|
|
367
397
|
params: WebviewInfoParams;
|
|
368
398
|
result: WebViewInfo;
|
|
369
399
|
};
|
|
400
|
+
paletteLayout: {
|
|
401
|
+
params: PaletteLayoutParams;
|
|
402
|
+
result: PaletteLayout;
|
|
403
|
+
};
|
|
370
404
|
menuModel: {
|
|
371
405
|
params: MenuModelParams;
|
|
372
406
|
result: MenuModelResult;
|