@fusion.dev/helix 0.162.1 → 0.163.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/custom-elements.json +635 -9
- package/dist/canvas/index.d.ts +1 -1
- package/dist/canvas/root/canvas-root.css.js +1 -1
- package/dist/canvas/root/canvas-root.d.ts +2 -0
- package/dist/element-events.generated.js +2 -0
- package/dist/sandbox/preview/sandbox-preview.css.js +4 -1
- package/dist/sandbox/preview/sandbox-preview.d.ts +50 -0
- package/dist/sandbox/preview/sandbox-preview.js +75 -13
- package/dist/sandbox/root/sandbox-root.css.js +1 -1
- package/dist/sandbox/root/sandbox-root.d.ts +55 -0
- package/dist/sandbox/root/sandbox-root.js +111 -4
- package/dist/sandbox/source/sandbox-source.d.ts +5 -0
- package/dist/sandbox/source/sandbox-source.js +4 -0
- package/lint.json +1 -1
- package/package.json +6 -6
- package/types/jsx.d.ts +295 -12
- package/types/vue.d.ts +73 -5
- package/types/words.d.ts +20 -0
package/types/jsx.d.ts
CHANGED
|
@@ -4748,6 +4748,13 @@ zoom as a percentage, written the way the element's locale writes one. */
|
|
|
4748
4748
|
/** What screen readers hear after a zoom button or key, with `{zoom}` for the
|
|
4749
4749
|
zoom as a percentage, written the way the element's locale writes one. */
|
|
4750
4750
|
zoomedLabel?: (HelixCanvas["zoomedLabel"]) | undefined;
|
|
4751
|
+
/** Draws every connection's line: a function from where it leaves and
|
|
4752
|
+
arrives, and the sides it does, to its SVG path and where its label sits.
|
|
4753
|
+
|
|
4754
|
+
Absent, or returning nothing for a connection, draws the board's own
|
|
4755
|
+
route. A function that throws draws the board's own too, and the error is
|
|
4756
|
+
reported to the page as an uncaught one. Set it as a property. */
|
|
4757
|
+
edgeRoute?: (HelixCanvas["edgeRoute"]) | undefined;
|
|
4751
4758
|
/** The board's current view: the document's point at the middle of the view,
|
|
4752
4759
|
and the zoom.
|
|
4753
4760
|
|
|
@@ -5204,6 +5211,13 @@ zoom as a percentage, written the way the element's locale writes one. */
|
|
|
5204
5211
|
/** What screen readers hear after a zoom button or key, with `{zoom}` for the
|
|
5205
5212
|
zoom as a percentage, written the way the element's locale writes one. */
|
|
5206
5213
|
"prop:zoomedLabel"?: (HelixCanvas["zoomedLabel"]) | undefined;
|
|
5214
|
+
/** Draws every connection's line: a function from where it leaves and
|
|
5215
|
+
arrives, and the sides it does, to its SVG path and where its label sits.
|
|
5216
|
+
|
|
5217
|
+
Absent, or returning nothing for a connection, draws the board's own
|
|
5218
|
+
route. A function that throws draws the board's own too, and the error is
|
|
5219
|
+
reported to the page as an uncaught one. Set it as a property. */
|
|
5220
|
+
"prop:edgeRoute"?: (HelixCanvas["edgeRoute"]) | undefined;
|
|
5207
5221
|
/** The board's current view: the document's point at the middle of the view,
|
|
5208
5222
|
and the zoom.
|
|
5209
5223
|
|
|
@@ -23314,7 +23328,8 @@ was never tickable look identical from here. Announcing only the ticked one
|
|
|
23314
23328
|
as a checkbox tells a reader its siblings are commands, which is the one
|
|
23315
23329
|
thing they are not.
|
|
23316
23330
|
|
|
23317
|
-
`checked`
|
|
23331
|
+
`checked` and `exclusive` imply it, so a row that is on, or one of a set,
|
|
23332
|
+
never has to say both.
|
|
23318
23333
|
|
|
23319
23334
|
Choosing the row checks or unchecks it, after a `helix-before-toggle` that
|
|
23320
23335
|
you can cancel. */
|
|
@@ -23324,6 +23339,18 @@ you can cancel. */
|
|
|
23324
23339
|
The row changes it when it is chosen. Not reflected: the attribute is the
|
|
23325
23340
|
state you start the row in, and `:state(checked)` carries the current one. */
|
|
23326
23341
|
checked?: (HelixMenuItem["checked"]) | undefined;
|
|
23342
|
+
/** Whether choosing the row closes the menu.
|
|
23343
|
+
|
|
23344
|
+
Unset takes the menu's `close-on-select`, which is on, and keeps the menu
|
|
23345
|
+
open after a Space on a choice row. Write `close-on-select="false"` for a
|
|
23346
|
+
row that changes something the reader is watching, such as a zoom step. */
|
|
23347
|
+
"close-on-select"?: (HelixMenuItem["closeOnSelect"]) | undefined;
|
|
23348
|
+
/** Whether choosing the row closes the menu.
|
|
23349
|
+
|
|
23350
|
+
Unset takes the menu's `close-on-select`, which is on, and keeps the menu
|
|
23351
|
+
open after a Space on a choice row. Write `close-on-select="false"` for a
|
|
23352
|
+
row that changes something the reader is watching, such as a zoom step. */
|
|
23353
|
+
closeOnSelect?: (HelixMenuItem["closeOnSelect"]) | undefined;
|
|
23327
23354
|
/** Whether the row is disabled, so it cannot be chosen. */
|
|
23328
23355
|
disabled?: (HelixMenuItem["disabled"]) | undefined;
|
|
23329
23356
|
/** Whether the link downloads the file when the row is chosen.
|
|
@@ -23340,8 +23367,7 @@ that row and unchecks the others. Choosing the row that is checked leaves
|
|
|
23340
23367
|
it checked. `menuitemradio` tells a reader which kind of set they are in,
|
|
23341
23368
|
where `menuitemcheckbox` says every row is independent.
|
|
23342
23369
|
|
|
23343
|
-
|
|
23344
|
-
one of a set of anything. */
|
|
23370
|
+
It makes the row a choice, so it needs no `checkable` beside it. */
|
|
23345
23371
|
exclusive?: (HelixMenuItem["exclusive"]) | undefined;
|
|
23346
23372
|
/** The URL the row links to. Setting it renders the row as a link.
|
|
23347
23373
|
|
|
@@ -23388,7 +23414,8 @@ was never tickable look identical from here. Announcing only the ticked one
|
|
|
23388
23414
|
as a checkbox tells a reader its siblings are commands, which is the one
|
|
23389
23415
|
thing they are not.
|
|
23390
23416
|
|
|
23391
|
-
`checked`
|
|
23417
|
+
`checked` and `exclusive` imply it, so a row that is on, or one of a set,
|
|
23418
|
+
never has to say both.
|
|
23392
23419
|
|
|
23393
23420
|
Choosing the row checks or unchecks it, after a `helix-before-toggle` that
|
|
23394
23421
|
you can cancel. */
|
|
@@ -23398,6 +23425,18 @@ you can cancel. */
|
|
|
23398
23425
|
The row changes it when it is chosen. Not reflected: the attribute is the
|
|
23399
23426
|
state you start the row in, and `:state(checked)` carries the current one. */
|
|
23400
23427
|
"prop:checked"?: (HelixMenuItem["checked"]) | undefined;
|
|
23428
|
+
/** Whether choosing the row closes the menu.
|
|
23429
|
+
|
|
23430
|
+
Unset takes the menu's `close-on-select`, which is on, and keeps the menu
|
|
23431
|
+
open after a Space on a choice row. Write `close-on-select="false"` for a
|
|
23432
|
+
row that changes something the reader is watching, such as a zoom step. */
|
|
23433
|
+
"bool:close-on-select"?: (HelixMenuItem["closeOnSelect"]) | undefined;
|
|
23434
|
+
/** Whether choosing the row closes the menu.
|
|
23435
|
+
|
|
23436
|
+
Unset takes the menu's `close-on-select`, which is on, and keeps the menu
|
|
23437
|
+
open after a Space on a choice row. Write `close-on-select="false"` for a
|
|
23438
|
+
row that changes something the reader is watching, such as a zoom step. */
|
|
23439
|
+
"prop:closeOnSelect"?: (HelixMenuItem["closeOnSelect"]) | undefined;
|
|
23401
23440
|
/** Whether the row is disabled, so it cannot be chosen. */
|
|
23402
23441
|
"prop:disabled"?: (HelixMenuItem["disabled"]) | undefined;
|
|
23403
23442
|
/** Whether the link downloads the file when the row is chosen.
|
|
@@ -23414,8 +23453,7 @@ that row and unchecks the others. Choosing the row that is checked leaves
|
|
|
23414
23453
|
it checked. `menuitemradio` tells a reader which kind of set they are in,
|
|
23415
23454
|
where `menuitemcheckbox` says every row is independent.
|
|
23416
23455
|
|
|
23417
|
-
|
|
23418
|
-
one of a set of anything. */
|
|
23456
|
+
It makes the row a choice, so it needs no `checkable` beside it. */
|
|
23419
23457
|
"prop:exclusive"?: (HelixMenuItem["exclusive"]) | undefined;
|
|
23420
23458
|
/** The URL the row links to. Setting it renders the row as a link.
|
|
23421
23459
|
|
|
@@ -23507,6 +23545,18 @@ the resolved state for stylesheets, which is what the mirror is for. */
|
|
|
23507
23545
|
"back-label"?: (HelixMenu["backLabel"]) | undefined;
|
|
23508
23546
|
/** The text of the row that returns from a submenu. */
|
|
23509
23547
|
backLabel?: (HelixMenu["backLabel"]) | undefined;
|
|
23548
|
+
/** Whether choosing a row closes the menu.
|
|
23549
|
+
|
|
23550
|
+
On by default, and a Space on a choice row leaves the menu open either way.
|
|
23551
|
+
Write `close-on-select="false"` to keep the menu open after every choice, as
|
|
23552
|
+
Ark UI's `closeOnSelect` does. A row's own `close-on-select` wins over this. */
|
|
23553
|
+
"close-on-select"?: (HelixMenu["closeOnSelect"]) | undefined;
|
|
23554
|
+
/** Whether choosing a row closes the menu.
|
|
23555
|
+
|
|
23556
|
+
On by default, and a Space on a choice row leaves the menu open either way.
|
|
23557
|
+
Write `close-on-select="false"` to keep the menu open after every choice, as
|
|
23558
|
+
Ark UI's `closeOnSelect` does. A row's own `close-on-select` wins over this. */
|
|
23559
|
+
closeOnSelect?: (HelixMenu["closeOnSelect"]) | undefined;
|
|
23510
23560
|
/** Whether the menu is the trigger's context menu: it opens where the reader
|
|
23511
23561
|
asks for one, with a right-click, a long press, Shift+F10 or the menu key. */
|
|
23512
23562
|
context?: (HelixMenu["context"]) | undefined;
|
|
@@ -23586,6 +23636,18 @@ the resolved state for stylesheets, which is what the mirror is for. */
|
|
|
23586
23636
|
"attr:back-label"?: (HelixMenu["backLabel"]) | undefined;
|
|
23587
23637
|
/** The text of the row that returns from a submenu. */
|
|
23588
23638
|
"prop:backLabel"?: (HelixMenu["backLabel"]) | undefined;
|
|
23639
|
+
/** Whether choosing a row closes the menu.
|
|
23640
|
+
|
|
23641
|
+
On by default, and a Space on a choice row leaves the menu open either way.
|
|
23642
|
+
Write `close-on-select="false"` to keep the menu open after every choice, as
|
|
23643
|
+
Ark UI's `closeOnSelect` does. A row's own `close-on-select` wins over this. */
|
|
23644
|
+
"bool:close-on-select"?: (HelixMenu["closeOnSelect"]) | undefined;
|
|
23645
|
+
/** Whether choosing a row closes the menu.
|
|
23646
|
+
|
|
23647
|
+
On by default, and a Space on a choice row leaves the menu open either way.
|
|
23648
|
+
Write `close-on-select="false"` to keep the menu open after every choice, as
|
|
23649
|
+
Ark UI's `closeOnSelect` does. A row's own `close-on-select` wins over this. */
|
|
23650
|
+
"prop:closeOnSelect"?: (HelixMenu["closeOnSelect"]) | undefined;
|
|
23589
23651
|
/** Whether the menu is the trigger's context menu: it opens where the reader
|
|
23590
23652
|
asks for one, with a right-click, a long press, Shift+F10 or the menu key. */
|
|
23591
23653
|
"prop:context"?: (HelixMenu["context"]) | undefined;
|
|
@@ -28779,6 +28841,9 @@ keyed on this attribute, and of the 56 tokens that differ by scheme the
|
|
|
28779
28841
|
theme engine emits 19. The other 37 would stay light in a dark preview,
|
|
28780
28842
|
including every one of the 24 series colors a chart reads. */
|
|
28781
28843
|
colorMode?: (HelixSandboxPreview["colorMode"]) | undefined;
|
|
28844
|
+
/** Whether the preview draws a reload button and a button that opens the
|
|
28845
|
+
example in a new tab, in its corner. */
|
|
28846
|
+
controls?: (HelixSandboxPreview["controls"]) | undefined;
|
|
28782
28847
|
/** Writing direction inside the frame.
|
|
28783
28848
|
|
|
28784
28849
|
Not reflected. It is payload for the render message and nothing selects on
|
|
@@ -28800,6 +28865,18 @@ Not reflected, for `direction`'s reason: the placement is applied by the
|
|
|
28800
28865
|
document inside the frame, against its own root, so no rule on this side
|
|
28801
28866
|
could read it. */
|
|
28802
28867
|
layout?: (HelixSandboxPreview["layout"]) | undefined;
|
|
28868
|
+
/** The name of the button that opens the example in a new tab, under
|
|
28869
|
+
`controls`. */
|
|
28870
|
+
"open-label"?: (HelixSandboxPreview["openLabel"]) | undefined;
|
|
28871
|
+
/** The name of the button that opens the example in a new tab, under
|
|
28872
|
+
`controls`. */
|
|
28873
|
+
openLabel?: (HelixSandboxPreview["openLabel"]) | undefined;
|
|
28874
|
+
/** The name of the button that reloads the frame's document, under
|
|
28875
|
+
`controls`. */
|
|
28876
|
+
"reload-label"?: (HelixSandboxPreview["reloadLabel"]) | undefined;
|
|
28877
|
+
/** The name of the button that reloads the frame's document, under
|
|
28878
|
+
`controls`. */
|
|
28879
|
+
reloadLabel?: (HelixSandboxPreview["reloadLabel"]) | undefined;
|
|
28803
28880
|
/** A script to run as a module after the markup, on every render of new
|
|
28804
28881
|
source. A sandbox writes its `js` pane here. */
|
|
28805
28882
|
script?: (HelixSandboxPreview["script"]) | undefined;
|
|
@@ -28846,6 +28923,9 @@ keyed on this attribute, and of the 56 tokens that differ by scheme the
|
|
|
28846
28923
|
theme engine emits 19. The other 37 would stay light in a dark preview,
|
|
28847
28924
|
including every one of the 24 series colors a chart reads. */
|
|
28848
28925
|
"prop:colorMode"?: (HelixSandboxPreview["colorMode"]) | undefined;
|
|
28926
|
+
/** Whether the preview draws a reload button and a button that opens the
|
|
28927
|
+
example in a new tab, in its corner. */
|
|
28928
|
+
"prop:controls"?: (HelixSandboxPreview["controls"]) | undefined;
|
|
28849
28929
|
/** Writing direction inside the frame.
|
|
28850
28930
|
|
|
28851
28931
|
Not reflected. It is payload for the render message and nothing selects on
|
|
@@ -28867,6 +28947,18 @@ Not reflected, for `direction`'s reason: the placement is applied by the
|
|
|
28867
28947
|
document inside the frame, against its own root, so no rule on this side
|
|
28868
28948
|
could read it. */
|
|
28869
28949
|
"prop:layout"?: (HelixSandboxPreview["layout"]) | undefined;
|
|
28950
|
+
/** The name of the button that opens the example in a new tab, under
|
|
28951
|
+
`controls`. */
|
|
28952
|
+
"attr:open-label"?: (HelixSandboxPreview["openLabel"]) | undefined;
|
|
28953
|
+
/** The name of the button that opens the example in a new tab, under
|
|
28954
|
+
`controls`. */
|
|
28955
|
+
"prop:openLabel"?: (HelixSandboxPreview["openLabel"]) | undefined;
|
|
28956
|
+
/** The name of the button that reloads the frame's document, under
|
|
28957
|
+
`controls`. */
|
|
28958
|
+
"attr:reload-label"?: (HelixSandboxPreview["reloadLabel"]) | undefined;
|
|
28959
|
+
/** The name of the button that reloads the frame's document, under
|
|
28960
|
+
`controls`. */
|
|
28961
|
+
"prop:reloadLabel"?: (HelixSandboxPreview["reloadLabel"]) | undefined;
|
|
28870
28962
|
/** A script to run as a module after the markup, on every render of new
|
|
28871
28963
|
source. A sandbox writes its `js` pane here. */
|
|
28872
28964
|
"prop:script"?: (HelixSandboxPreview["script"]) | undefined;
|
|
@@ -28890,6 +28982,9 @@ Empty loads the built-in document, which defines no element. */
|
|
|
28890
28982
|
|
|
28891
28983
|
/** `HelixSandbox` component event */
|
|
28892
28984
|
export type HelixSandboxElementEvent<E = Event> = TypedEvent<HelixSandbox, E>;
|
|
28985
|
+
/** `helix-before-change` event type */
|
|
28986
|
+
export type HelixSandboxHelixBeforeChangeElementEvent =
|
|
28987
|
+
HelixSandboxElementEvent<HelixBeforeChangeEvent>;
|
|
28893
28988
|
/** `helix-before-edit` event type */
|
|
28894
28989
|
export type HelixSandboxHelixBeforeEditElementEvent =
|
|
28895
28990
|
HelixSandboxElementEvent<HelixBeforeEditEvent>;
|
|
@@ -28957,6 +29052,14 @@ sandbox back to the size it already was.
|
|
|
28957
29052
|
Declared rather than captured, so it is a number a consumer states and can
|
|
28958
29053
|
change, and it needs no first frame to be read on. */
|
|
28959
29054
|
defaultSplit?: (HelixSandbox["defaultSplit"]) | undefined;
|
|
29055
|
+
/** The `name` of the source pane shown, where the sandbox holds several.
|
|
29056
|
+
|
|
29057
|
+
Unset, or a name no pane has, shows the first. */
|
|
29058
|
+
file?: (HelixSandbox["file"]) | undefined;
|
|
29059
|
+
/** The name of the file tabs, read by screen readers. */
|
|
29060
|
+
"files-label"?: (HelixSandbox["filesLabel"]) | undefined;
|
|
29061
|
+
/** The name of the file tabs, read by screen readers. */
|
|
29062
|
+
filesLabel?: (HelixSandbox["filesLabel"]) | undefined;
|
|
28960
29063
|
/** Which pane comes first, before the divider.
|
|
28961
29064
|
|
|
28962
29065
|
A sandbox is read in one of two directions and the two are not a
|
|
@@ -29028,6 +29131,12 @@ divider's value is, so each is a whole sentence: "Resize source pane" or
|
|
|
29028
29131
|
is `preview`. */
|
|
29029
29132
|
split?: (HelixSandbox["split"]) | undefined;
|
|
29030
29133
|
|
|
29134
|
+
/** A file tab showed its pane, whose `name` `file` now holds. */
|
|
29135
|
+
onchange?: ((e: HelixSandboxElementEvent) => void) | undefined;
|
|
29136
|
+
/** Fired before a file tab shows its pane, with the pane's `name`. Cancelable: cancel it to keep the pane shown. */
|
|
29137
|
+
"onhelix-before-change"?: ((
|
|
29138
|
+
e: HelixSandboxHelixBeforeChangeElementEvent,
|
|
29139
|
+
) => void) | undefined;
|
|
29031
29140
|
/** Fired before the source is edited. The source pane dispatches it, and you can listen for it on the sandbox. Cancelable: cancel it to keep the source unchanged. */
|
|
29032
29141
|
"onhelix-before-edit"?: ((e: HelixSandboxHelixBeforeEditElementEvent) => void) | undefined;
|
|
29033
29142
|
/** Fired before the panel's divider is released, with the panel's height in pixels. A panel dragged closed reports `panel-collapsed-size`, its smallest height. Cancelable: cancel it to keep the current height. */
|
|
@@ -29093,6 +29202,14 @@ sandbox back to the size it already was.
|
|
|
29093
29202
|
Declared rather than captured, so it is a number a consumer states and can
|
|
29094
29203
|
change, and it needs no first frame to be read on. */
|
|
29095
29204
|
"prop:defaultSplit"?: (HelixSandbox["defaultSplit"]) | undefined;
|
|
29205
|
+
/** The `name` of the source pane shown, where the sandbox holds several.
|
|
29206
|
+
|
|
29207
|
+
Unset, or a name no pane has, shows the first. */
|
|
29208
|
+
"prop:file"?: (HelixSandbox["file"]) | undefined;
|
|
29209
|
+
/** The name of the file tabs, read by screen readers. */
|
|
29210
|
+
"attr:files-label"?: (HelixSandbox["filesLabel"]) | undefined;
|
|
29211
|
+
/** The name of the file tabs, read by screen readers. */
|
|
29212
|
+
"prop:filesLabel"?: (HelixSandbox["filesLabel"]) | undefined;
|
|
29096
29213
|
/** Which pane comes first, before the divider.
|
|
29097
29214
|
|
|
29098
29215
|
A sandbox is read in one of two directions and the two are not a
|
|
@@ -29163,6 +29280,12 @@ divider's value is, so each is a whole sentence: "Resize source pane" or
|
|
|
29163
29280
|
/** Percentage of the sandbox given to the lead pane: the source, unless `lead`
|
|
29164
29281
|
is `preview`. */
|
|
29165
29282
|
"prop:split"?: (HelixSandbox["split"]) | undefined;
|
|
29283
|
+
/** A file tab showed its pane, whose `name` `file` now holds. */
|
|
29284
|
+
"on:change"?: ((e: HelixSandboxElementEvent) => void) | undefined;
|
|
29285
|
+
/** Fired before a file tab shows its pane, with the pane's `name`. Cancelable: cancel it to keep the pane shown. */
|
|
29286
|
+
"on:helix-before-change"?: ((
|
|
29287
|
+
e: HelixSandboxHelixBeforeChangeElementEvent,
|
|
29288
|
+
) => void) | undefined;
|
|
29166
29289
|
/** Fired before the source is edited. The source pane dispatches it, and you can listen for it on the sandbox. Cancelable: cancel it to keep the source unchanged. */
|
|
29167
29290
|
"on:helix-before-edit"?: ((e: HelixSandboxHelixBeforeEditElementEvent) => void) | undefined;
|
|
29168
29291
|
/** Fired before the panel's divider is released, with the panel's height in pixels. A panel dragged closed reports `panel-collapsed-size`, its smallest height. Cancelable: cancel it to keep the current height. */
|
|
@@ -29218,6 +29341,9 @@ export type HelixSandboxSourceProps = {
|
|
|
29218
29341
|
"keys-description"?: (HelixSandboxSource["keysDescription"]) | undefined;
|
|
29219
29342
|
/** The field's description, read by screen readers while Tab indents. */
|
|
29220
29343
|
keysDescription?: (HelixSandboxSource["keysDescription"]) | undefined;
|
|
29344
|
+
/** The pane's file name, such as `index.html`, on its tab where a sandbox
|
|
29345
|
+
holds several panes. Empty puts the pane's `name` on the tab. */
|
|
29346
|
+
label?: (HelixSandboxSource["label"]) | undefined;
|
|
29221
29347
|
/** Which source this pane holds. Every `helix-before-edit` event includes it.
|
|
29222
29348
|
|
|
29223
29349
|
`html` and `css` are what the sandbox root routes on; any other name is
|
|
@@ -29263,6 +29389,9 @@ export type HelixSandboxSourceSolidJsProps = {
|
|
|
29263
29389
|
"attr:keys-description"?: (HelixSandboxSource["keysDescription"]) | undefined;
|
|
29264
29390
|
/** The field's description, read by screen readers while Tab indents. */
|
|
29265
29391
|
"prop:keysDescription"?: (HelixSandboxSource["keysDescription"]) | undefined;
|
|
29392
|
+
/** The pane's file name, such as `index.html`, on its tab where a sandbox
|
|
29393
|
+
holds several panes. Empty puts the pane's `name` on the tab. */
|
|
29394
|
+
"prop:label"?: (HelixSandboxSource["label"]) | undefined;
|
|
29266
29395
|
/** Which source this pane holds. Every `helix-before-edit` event includes it.
|
|
29267
29396
|
|
|
29268
29397
|
`html` and `css` are what the sandbox root routes on; any other name is
|
|
@@ -43897,6 +44026,12 @@ export type CustomElements = {
|
|
|
43897
44026
|
* `gestures="cooperative"`. `{key}` is ⌘ on a Mac and Ctrl elsewhere.
|
|
43898
44027
|
* - `zoomed-label`/`zoomedLabel`: What screen readers hear after a zoom button or key, with `{zoom}` for the
|
|
43899
44028
|
* zoom as a percentage, written the way the element's locale writes one.
|
|
44029
|
+
* - `edgeRoute`: Draws every connection's line: a function from where it leaves and
|
|
44030
|
+
* arrives, and the sides it does, to its SVG path and where its label sits.
|
|
44031
|
+
*
|
|
44032
|
+
* Absent, or returning nothing for a connection, draws the board's own
|
|
44033
|
+
* route. A function that throws draws the board's own too, and the error is
|
|
44034
|
+
* reported to the page as an uncaught one. Set it as a property. (property only)
|
|
43900
44035
|
* - `view`: The board's current view: the document's point at the middle of the view,
|
|
43901
44036
|
* and the zoom.
|
|
43902
44037
|
*
|
|
@@ -44009,6 +44144,8 @@ export type CustomElements = {
|
|
|
44009
44144
|
* - `--canvas-label-color`: The color of the label on a connection.
|
|
44010
44145
|
* - `--canvas-label-editor-inline-size`: The width of the field for editing a label.
|
|
44011
44146
|
* - `--canvas-label-font-size`: The size of the label on a connection.
|
|
44147
|
+
* - `--canvas-minimap-block-size`: The height of the minimap, under `controls="minimap"`.
|
|
44148
|
+
* - `--canvas-minimap-inline-size`: The width of the minimap, under `controls="minimap"`.
|
|
44012
44149
|
* - `--canvas-radius`: The frame's corners.
|
|
44013
44150
|
* - `--canvas-selected-color`: The color of what is selected: a card's outline, its corners and its move handle, a connection and its ends, and the box drawn to select.
|
|
44014
44151
|
* - `--viewport-control-background-color`: The background of the pan and zoom buttons. `Map` uses the same property.
|
|
@@ -44035,6 +44172,9 @@ export type CustomElements = {
|
|
|
44035
44172
|
* - `label-editor`: The field for editing a connection's label or a group's name, placed over that text.
|
|
44036
44173
|
* - `live`: A live region that screen readers announce while a connection is being made.
|
|
44037
44174
|
* - `marquee`: The box a Shift-drag across the empty board draws, which selects the cards it touches.
|
|
44175
|
+
* - `minimap`: The picture of the whole board, under `controls="minimap"`.
|
|
44176
|
+
* - `minimap-node`: One card in the minimap.
|
|
44177
|
+
* - `minimap-view`: The frame in the minimap around what is on screen.
|
|
44038
44178
|
* - `pan-down`: The button that moves the board down.
|
|
44039
44179
|
* - `pan-end`: The button that moves the board toward the end of a line of text: right in English.
|
|
44040
44180
|
* - `pan-start`: The button that moves the board toward the start of a line of text: left in English.
|
|
@@ -56191,7 +56331,8 @@ export type CustomElements = {
|
|
|
56191
56331
|
* as a checkbox tells a reader its siblings are commands, which is the one
|
|
56192
56332
|
* thing they are not.
|
|
56193
56333
|
*
|
|
56194
|
-
* `checked`
|
|
56334
|
+
* `checked` and `exclusive` imply it, so a row that is on, or one of a set,
|
|
56335
|
+
* never has to say both.
|
|
56195
56336
|
*
|
|
56196
56337
|
* Choosing the row checks or unchecks it, after a `helix-before-toggle` that
|
|
56197
56338
|
* you can cancel.
|
|
@@ -56199,6 +56340,11 @@ export type CustomElements = {
|
|
|
56199
56340
|
*
|
|
56200
56341
|
* The row changes it when it is chosen. Not reflected: the attribute is the
|
|
56201
56342
|
* state you start the row in, and `:state(checked)` carries the current one.
|
|
56343
|
+
* - `close-on-select`/`closeOnSelect`: Whether choosing the row closes the menu.
|
|
56344
|
+
*
|
|
56345
|
+
* Unset takes the menu's `close-on-select`, which is on, and keeps the menu
|
|
56346
|
+
* open after a Space on a choice row. Write `close-on-select="false"` for a
|
|
56347
|
+
* row that changes something the reader is watching, such as a zoom step.
|
|
56202
56348
|
* - `disabled`: Whether the row is disabled, so it cannot be chosen.
|
|
56203
56349
|
* - `download`: Whether the link downloads the file when the row is chosen.
|
|
56204
56350
|
*
|
|
@@ -56213,8 +56359,7 @@ export type CustomElements = {
|
|
|
56213
56359
|
* it checked. `menuitemradio` tells a reader which kind of set they are in,
|
|
56214
56360
|
* where `menuitemcheckbox` says every row is independent.
|
|
56215
56361
|
*
|
|
56216
|
-
*
|
|
56217
|
-
* one of a set of anything.
|
|
56362
|
+
* It makes the row a choice, so it needs no `checkable` beside it.
|
|
56218
56363
|
* - `href`: The URL the row links to. Setting it renders the row as a link.
|
|
56219
56364
|
*
|
|
56220
56365
|
* **The row itself becomes an `<a>`, and the role goes with it.** A
|
|
@@ -56376,6 +56521,11 @@ export type CustomElements = {
|
|
|
56376
56521
|
* last reader did rather than what the author wrote. `:state(open)` carries
|
|
56377
56522
|
* the resolved state for stylesheets, which is what the mirror is for.
|
|
56378
56523
|
* - `back-label`/`backLabel`: The text of the row that returns from a submenu.
|
|
56524
|
+
* - `close-on-select`/`closeOnSelect`: Whether choosing a row closes the menu.
|
|
56525
|
+
*
|
|
56526
|
+
* On by default, and a Space on a choice row leaves the menu open either way.
|
|
56527
|
+
* Write `close-on-select="false"` to keep the menu open after every choice, as
|
|
56528
|
+
* Ark UI's `closeOnSelect` does. A row's own `close-on-select` wins over this.
|
|
56379
56529
|
* - `context`: Whether the menu is the trigger's context menu: it opens where the reader
|
|
56380
56530
|
* asks for one, with a right-click, a long press, Shift+F10 or the menu key.
|
|
56381
56531
|
* - `label`: Accessible name for the surface.
|
|
@@ -60548,6 +60698,15 @@ export type CustomElements = {
|
|
|
60548
60698
|
* reports. A page draws its own spinner or message from either, such as a
|
|
60549
60699
|
* sibling shown by `helix-sandbox-preview:state(failed) + .message`.
|
|
60550
60700
|
*
|
|
60701
|
+
* **A failed preview shows the error over the example**, in the `error` part,
|
|
60702
|
+
* until the next source is sent. The terminal says it too, so the part is not
|
|
60703
|
+
* announced. Hide it with `::part(error) { display: none }` where the page
|
|
60704
|
+
* draws its own.
|
|
60705
|
+
*
|
|
60706
|
+
* **`controls` draws two buttons in the preview's corner**: one reloads the
|
|
60707
|
+
* frame's document, as `reload()` does, and one opens the example in a new
|
|
60708
|
+
* tab, as `open()` does. The tab runs it in a frame sandboxed as this one is.
|
|
60709
|
+
*
|
|
60551
60710
|
* ## Attributes & Properties
|
|
60552
60711
|
*
|
|
60553
60712
|
* Component attributes and properties that can be applied to the element or by using JavaScript.
|
|
@@ -60565,6 +60724,8 @@ export type CustomElements = {
|
|
|
60565
60724
|
* keyed on this attribute, and of the 56 tokens that differ by scheme the
|
|
60566
60725
|
* theme engine emits 19. The other 37 would stay light in a dark preview,
|
|
60567
60726
|
* including every one of the 24 series colors a chart reads.
|
|
60727
|
+
* - `controls`: Whether the preview draws a reload button and a button that opens the
|
|
60728
|
+
* example in a new tab, in its corner.
|
|
60568
60729
|
* - `direction`: Writing direction inside the frame.
|
|
60569
60730
|
*
|
|
60570
60731
|
* Not reflected. It is payload for the render message and nothing selects on
|
|
@@ -60583,6 +60744,10 @@ export type CustomElements = {
|
|
|
60583
60744
|
* Not reflected, for `direction`'s reason: the placement is applied by the
|
|
60584
60745
|
* document inside the frame, against its own root, so no rule on this side
|
|
60585
60746
|
* could read it.
|
|
60747
|
+
* - `open-label`/`openLabel`: The name of the button that opens the example in a new tab, under
|
|
60748
|
+
* `controls`.
|
|
60749
|
+
* - `reload-label`/`reloadLabel`: The name of the button that reloads the frame's document, under
|
|
60750
|
+
* `controls`.
|
|
60586
60751
|
* - `script`: A script to run as a module after the markup, on every render of new
|
|
60587
60752
|
* source. A sandbox writes its `js` pane here.
|
|
60588
60753
|
* - `source`: Markup to render.
|
|
@@ -60621,6 +60786,17 @@ export type CustomElements = {
|
|
|
60621
60786
|
*
|
|
60622
60787
|
* Methods that can be called to access component functionality.
|
|
60623
60788
|
*
|
|
60789
|
+
* - `open() => Window | null`: Opens the example in a new tab, and returns the tab's window, or `null`
|
|
60790
|
+
* where the browser refused to open one.
|
|
60791
|
+
*
|
|
60792
|
+
* **The tab runs the example as this preview does**: in a frame that fills
|
|
60793
|
+
* it, with this frame's `sandbox`, loading `src` or the built-in document,
|
|
60794
|
+
* and sent the example once it loads. The example stays on an opaque origin,
|
|
60795
|
+
* and the tab's `opener` is cleared, so it cannot reach this page. The tab
|
|
60796
|
+
* shows the example as it was when it opened, and edits after that do not
|
|
60797
|
+
* reach it. A short inline script in the tab sends the example, so on a page
|
|
60798
|
+
* whose Content Security Policy refuses inline scripts the tab opens empty,
|
|
60799
|
+
* as the built-in document does there.
|
|
60624
60800
|
* - `reload() => void`: Loads the frame's document again, and re-sends the example to it.
|
|
60625
60801
|
*
|
|
60626
60802
|
* For a bundle that has changed underneath a page nobody reloaded. The frame
|
|
@@ -60638,7 +60814,11 @@ export type CustomElements = {
|
|
|
60638
60814
|
*
|
|
60639
60815
|
* Custom selectors for styling elements within the component.
|
|
60640
60816
|
*
|
|
60817
|
+
* - `controls`: The buttons in the preview's corner, under `controls`.
|
|
60818
|
+
* - `error`: The error the example threw and did not catch, shown over it while the preview is `failed`.
|
|
60641
60819
|
* - `frame`: The iframe.
|
|
60820
|
+
* - `open`: The button that opens the example in a new tab, under `controls`.
|
|
60821
|
+
* - `reload`: The button that reloads the frame's document, under `controls`.
|
|
60642
60822
|
*
|
|
60643
60823
|
* ## CSS States
|
|
60644
60824
|
*
|
|
@@ -60668,6 +60848,20 @@ export type CustomElements = {
|
|
|
60668
60848
|
* pointer, the keyboard, and the corner. The inner splitter holds the panes and
|
|
60669
60849
|
* the outer one holds the panel, so the panel spans the full width.
|
|
60670
60850
|
*
|
|
60851
|
+
* **Several source panes are files**, one shown at a time under a row of
|
|
60852
|
+
* tabs, each named by the pane's `label` or, without one, its `name`. `file`
|
|
60853
|
+
* holds the `name` of the pane shown. The tabs are a tab list: the arrow keys
|
|
60854
|
+
* move between them and show each pane, and `Home` and `End` go to the first
|
|
60855
|
+
* and the last. Choosing one sends `helix-before-change` with the pane's
|
|
60856
|
+
* `name`, which you can cancel, and `change` once `file` holds it. The panes
|
|
60857
|
+
* not shown carry `hidden`. One pane draws no tabs.
|
|
60858
|
+
*
|
|
60859
|
+
* **Any editor can be the source pane**: an element in the `source` slot with
|
|
60860
|
+
* a `name` that dispatches `helix-before-edit` with its text, which bubbles.
|
|
60861
|
+
* A wrapper around CodeMirror or Monaco sends one on each change and is a pane
|
|
60862
|
+
* like `helix-sandbox-source`, and the sandbox reads its `value` to seed the
|
|
60863
|
+
* preview. Dispatch `helix-caret` from it too for the status bar's position.
|
|
60864
|
+
*
|
|
60671
60865
|
* On a focused divider, the arrow keys move it, and `Home` and `End` move it
|
|
60672
60866
|
* to its ends. `Enter` on the panes divider shuts the lead pane, and pressed
|
|
60673
60867
|
* again it opens the pane where it was. `Enter` on the panel divider shuts the
|
|
@@ -60694,6 +60888,10 @@ export type CustomElements = {
|
|
|
60694
60888
|
*
|
|
60695
60889
|
* Declared rather than captured, so it is a number a consumer states and can
|
|
60696
60890
|
* change, and it needs no first frame to be read on.
|
|
60891
|
+
* - `file`: The `name` of the source pane shown, where the sandbox holds several.
|
|
60892
|
+
*
|
|
60893
|
+
* Unset, or a name no pane has, shows the first.
|
|
60894
|
+
* - `files-label`/`filesLabel`: The name of the file tabs, read by screen readers.
|
|
60697
60895
|
* - `lead`: Which pane comes first, before the divider.
|
|
60698
60896
|
*
|
|
60699
60897
|
* A sandbox is read in one of two directions and the two are not a
|
|
@@ -60760,6 +60958,8 @@ export type CustomElements = {
|
|
|
60760
60958
|
*
|
|
60761
60959
|
* Events that will be emitted by the component.
|
|
60762
60960
|
*
|
|
60961
|
+
* - `change`: A file tab showed its pane, whose `name` `file` now holds.
|
|
60962
|
+
* - `helix-before-change`: Fired before a file tab shows its pane, with the pane's `name`. Cancelable: cancel it to keep the pane shown.
|
|
60763
60963
|
* - `helix-before-edit`: Fired before the source is edited. The source pane dispatches it, and you can listen for it on the sandbox. Cancelable: cancel it to keep the source unchanged.
|
|
60764
60964
|
* - `helix-before-panel-resize`: Fired before the panel's divider is released, with the panel's height in pixels. A panel dragged closed reports `panel-collapsed-size`, its smallest height. Cancelable: cancel it to keep the current height.
|
|
60765
60965
|
* - `helix-before-split`: Fired before the panes' divider is released, with the lead pane's share. Cancelable: cancel it to keep the current split.
|
|
@@ -60794,6 +60994,8 @@ export type CustomElements = {
|
|
|
60794
60994
|
*
|
|
60795
60995
|
* - `body`: The splitter holding the panes above the panel. `::part(body):state(dragging)` matches while its divider is held.
|
|
60796
60996
|
* - `corner`: The handle where the two dividers cross.
|
|
60997
|
+
* - `file`: One file tab, `aria-selected` while its pane is shown.
|
|
60998
|
+
* - `files`: The file tabs over the source panes, where there are several.
|
|
60797
60999
|
* - `pane`: Either pane.
|
|
60798
61000
|
* - `panel`: The box that holds the slotted panel.
|
|
60799
61001
|
* - `panes`: The splitter holding the source and preview panes. `::part(panes):state(dragging)` matches while its divider is held.
|
|
@@ -60836,6 +61038,8 @@ export type CustomElements = {
|
|
|
60836
61038
|
*
|
|
60837
61039
|
* - `field-label`/`fieldLabel`: The editable region's name, read by screen readers.
|
|
60838
61040
|
* - `keys-description`/`keysDescription`: The field's description, read by screen readers while Tab indents.
|
|
61041
|
+
* - `label`: The pane's file name, such as `index.html`, on its tab where a sandbox
|
|
61042
|
+
* holds several panes. Empty puts the pane's `name` on the tab.
|
|
60839
61043
|
* - `name`: Which source this pane holds. Every `helix-before-edit` event includes it.
|
|
60840
61044
|
*
|
|
60841
61045
|
* `html` and `css` are what the sandbox root routes on; any other name is
|
|
@@ -72840,6 +73044,12 @@ export type CustomElementsSolidJs = {
|
|
|
72840
73044
|
* `gestures="cooperative"`. `{key}` is ⌘ on a Mac and Ctrl elsewhere.
|
|
72841
73045
|
* - `zoomed-label`/`zoomedLabel`: What screen readers hear after a zoom button or key, with `{zoom}` for the
|
|
72842
73046
|
* zoom as a percentage, written the way the element's locale writes one.
|
|
73047
|
+
* - `edgeRoute`: Draws every connection's line: a function from where it leaves and
|
|
73048
|
+
* arrives, and the sides it does, to its SVG path and where its label sits.
|
|
73049
|
+
*
|
|
73050
|
+
* Absent, or returning nothing for a connection, draws the board's own
|
|
73051
|
+
* route. A function that throws draws the board's own too, and the error is
|
|
73052
|
+
* reported to the page as an uncaught one. Set it as a property. (property only)
|
|
72843
73053
|
* - `view`: The board's current view: the document's point at the middle of the view,
|
|
72844
73054
|
* and the zoom.
|
|
72845
73055
|
*
|
|
@@ -72952,6 +73162,8 @@ export type CustomElementsSolidJs = {
|
|
|
72952
73162
|
* - `--canvas-label-color`: The color of the label on a connection.
|
|
72953
73163
|
* - `--canvas-label-editor-inline-size`: The width of the field for editing a label.
|
|
72954
73164
|
* - `--canvas-label-font-size`: The size of the label on a connection.
|
|
73165
|
+
* - `--canvas-minimap-block-size`: The height of the minimap, under `controls="minimap"`.
|
|
73166
|
+
* - `--canvas-minimap-inline-size`: The width of the minimap, under `controls="minimap"`.
|
|
72955
73167
|
* - `--canvas-radius`: The frame's corners.
|
|
72956
73168
|
* - `--canvas-selected-color`: The color of what is selected: a card's outline, its corners and its move handle, a connection and its ends, and the box drawn to select.
|
|
72957
73169
|
* - `--viewport-control-background-color`: The background of the pan and zoom buttons. `Map` uses the same property.
|
|
@@ -72978,6 +73190,9 @@ export type CustomElementsSolidJs = {
|
|
|
72978
73190
|
* - `label-editor`: The field for editing a connection's label or a group's name, placed over that text.
|
|
72979
73191
|
* - `live`: A live region that screen readers announce while a connection is being made.
|
|
72980
73192
|
* - `marquee`: The box a Shift-drag across the empty board draws, which selects the cards it touches.
|
|
73193
|
+
* - `minimap`: The picture of the whole board, under `controls="minimap"`.
|
|
73194
|
+
* - `minimap-node`: One card in the minimap.
|
|
73195
|
+
* - `minimap-view`: The frame in the minimap around what is on screen.
|
|
72981
73196
|
* - `pan-down`: The button that moves the board down.
|
|
72982
73197
|
* - `pan-end`: The button that moves the board toward the end of a line of text: right in English.
|
|
72983
73198
|
* - `pan-start`: The button that moves the board toward the start of a line of text: left in English.
|
|
@@ -85320,7 +85535,8 @@ export type CustomElementsSolidJs = {
|
|
|
85320
85535
|
* as a checkbox tells a reader its siblings are commands, which is the one
|
|
85321
85536
|
* thing they are not.
|
|
85322
85537
|
*
|
|
85323
|
-
* `checked`
|
|
85538
|
+
* `checked` and `exclusive` imply it, so a row that is on, or one of a set,
|
|
85539
|
+
* never has to say both.
|
|
85324
85540
|
*
|
|
85325
85541
|
* Choosing the row checks or unchecks it, after a `helix-before-toggle` that
|
|
85326
85542
|
* you can cancel.
|
|
@@ -85328,6 +85544,11 @@ export type CustomElementsSolidJs = {
|
|
|
85328
85544
|
*
|
|
85329
85545
|
* The row changes it when it is chosen. Not reflected: the attribute is the
|
|
85330
85546
|
* state you start the row in, and `:state(checked)` carries the current one.
|
|
85547
|
+
* - `close-on-select`/`closeOnSelect`: Whether choosing the row closes the menu.
|
|
85548
|
+
*
|
|
85549
|
+
* Unset takes the menu's `close-on-select`, which is on, and keeps the menu
|
|
85550
|
+
* open after a Space on a choice row. Write `close-on-select="false"` for a
|
|
85551
|
+
* row that changes something the reader is watching, such as a zoom step.
|
|
85331
85552
|
* - `disabled`: Whether the row is disabled, so it cannot be chosen.
|
|
85332
85553
|
* - `download`: Whether the link downloads the file when the row is chosen.
|
|
85333
85554
|
*
|
|
@@ -85342,8 +85563,7 @@ export type CustomElementsSolidJs = {
|
|
|
85342
85563
|
* it checked. `menuitemradio` tells a reader which kind of set they are in,
|
|
85343
85564
|
* where `menuitemcheckbox` says every row is independent.
|
|
85344
85565
|
*
|
|
85345
|
-
*
|
|
85346
|
-
* one of a set of anything.
|
|
85566
|
+
* It makes the row a choice, so it needs no `checkable` beside it.
|
|
85347
85567
|
* - `href`: The URL the row links to. Setting it renders the row as a link.
|
|
85348
85568
|
*
|
|
85349
85569
|
* **The row itself becomes an `<a>`, and the role goes with it.** A
|
|
@@ -85508,6 +85728,11 @@ export type CustomElementsSolidJs = {
|
|
|
85508
85728
|
* last reader did rather than what the author wrote. `:state(open)` carries
|
|
85509
85729
|
* the resolved state for stylesheets, which is what the mirror is for.
|
|
85510
85730
|
* - `back-label`/`backLabel`: The text of the row that returns from a submenu.
|
|
85731
|
+
* - `close-on-select`/`closeOnSelect`: Whether choosing a row closes the menu.
|
|
85732
|
+
*
|
|
85733
|
+
* On by default, and a Space on a choice row leaves the menu open either way.
|
|
85734
|
+
* Write `close-on-select="false"` to keep the menu open after every choice, as
|
|
85735
|
+
* Ark UI's `closeOnSelect` does. A row's own `close-on-select` wins over this.
|
|
85511
85736
|
* - `context`: Whether the menu is the trigger's context menu: it opens where the reader
|
|
85512
85737
|
* asks for one, with a right-click, a long press, Shift+F10 or the menu key.
|
|
85513
85738
|
* - `label`: Accessible name for the surface.
|
|
@@ -89759,6 +89984,15 @@ export type CustomElementsSolidJs = {
|
|
|
89759
89984
|
* reports. A page draws its own spinner or message from either, such as a
|
|
89760
89985
|
* sibling shown by `helix-sandbox-preview:state(failed) + .message`.
|
|
89761
89986
|
*
|
|
89987
|
+
* **A failed preview shows the error over the example**, in the `error` part,
|
|
89988
|
+
* until the next source is sent. The terminal says it too, so the part is not
|
|
89989
|
+
* announced. Hide it with `::part(error) { display: none }` where the page
|
|
89990
|
+
* draws its own.
|
|
89991
|
+
*
|
|
89992
|
+
* **`controls` draws two buttons in the preview's corner**: one reloads the
|
|
89993
|
+
* frame's document, as `reload()` does, and one opens the example in a new
|
|
89994
|
+
* tab, as `open()` does. The tab runs it in a frame sandboxed as this one is.
|
|
89995
|
+
*
|
|
89762
89996
|
* ## Attributes & Properties
|
|
89763
89997
|
*
|
|
89764
89998
|
* Component attributes and properties that can be applied to the element or by using JavaScript.
|
|
@@ -89776,6 +90010,8 @@ export type CustomElementsSolidJs = {
|
|
|
89776
90010
|
* keyed on this attribute, and of the 56 tokens that differ by scheme the
|
|
89777
90011
|
* theme engine emits 19. The other 37 would stay light in a dark preview,
|
|
89778
90012
|
* including every one of the 24 series colors a chart reads.
|
|
90013
|
+
* - `controls`: Whether the preview draws a reload button and a button that opens the
|
|
90014
|
+
* example in a new tab, in its corner.
|
|
89779
90015
|
* - `direction`: Writing direction inside the frame.
|
|
89780
90016
|
*
|
|
89781
90017
|
* Not reflected. It is payload for the render message and nothing selects on
|
|
@@ -89794,6 +90030,10 @@ export type CustomElementsSolidJs = {
|
|
|
89794
90030
|
* Not reflected, for `direction`'s reason: the placement is applied by the
|
|
89795
90031
|
* document inside the frame, against its own root, so no rule on this side
|
|
89796
90032
|
* could read it.
|
|
90033
|
+
* - `open-label`/`openLabel`: The name of the button that opens the example in a new tab, under
|
|
90034
|
+
* `controls`.
|
|
90035
|
+
* - `reload-label`/`reloadLabel`: The name of the button that reloads the frame's document, under
|
|
90036
|
+
* `controls`.
|
|
89797
90037
|
* - `script`: A script to run as a module after the markup, on every render of new
|
|
89798
90038
|
* source. A sandbox writes its `js` pane here.
|
|
89799
90039
|
* - `source`: Markup to render.
|
|
@@ -89832,6 +90072,17 @@ export type CustomElementsSolidJs = {
|
|
|
89832
90072
|
*
|
|
89833
90073
|
* Methods that can be called to access component functionality.
|
|
89834
90074
|
*
|
|
90075
|
+
* - `open() => Window | null`: Opens the example in a new tab, and returns the tab's window, or `null`
|
|
90076
|
+
* where the browser refused to open one.
|
|
90077
|
+
*
|
|
90078
|
+
* **The tab runs the example as this preview does**: in a frame that fills
|
|
90079
|
+
* it, with this frame's `sandbox`, loading `src` or the built-in document,
|
|
90080
|
+
* and sent the example once it loads. The example stays on an opaque origin,
|
|
90081
|
+
* and the tab's `opener` is cleared, so it cannot reach this page. The tab
|
|
90082
|
+
* shows the example as it was when it opened, and edits after that do not
|
|
90083
|
+
* reach it. A short inline script in the tab sends the example, so on a page
|
|
90084
|
+
* whose Content Security Policy refuses inline scripts the tab opens empty,
|
|
90085
|
+
* as the built-in document does there.
|
|
89835
90086
|
* - `reload() => void`: Loads the frame's document again, and re-sends the example to it.
|
|
89836
90087
|
*
|
|
89837
90088
|
* For a bundle that has changed underneath a page nobody reloaded. The frame
|
|
@@ -89849,7 +90100,11 @@ export type CustomElementsSolidJs = {
|
|
|
89849
90100
|
*
|
|
89850
90101
|
* Custom selectors for styling elements within the component.
|
|
89851
90102
|
*
|
|
90103
|
+
* - `controls`: The buttons in the preview's corner, under `controls`.
|
|
90104
|
+
* - `error`: The error the example threw and did not catch, shown over it while the preview is `failed`.
|
|
89852
90105
|
* - `frame`: The iframe.
|
|
90106
|
+
* - `open`: The button that opens the example in a new tab, under `controls`.
|
|
90107
|
+
* - `reload`: The button that reloads the frame's document, under `controls`.
|
|
89853
90108
|
*
|
|
89854
90109
|
* ## CSS States
|
|
89855
90110
|
*
|
|
@@ -89882,6 +90137,20 @@ export type CustomElementsSolidJs = {
|
|
|
89882
90137
|
* pointer, the keyboard, and the corner. The inner splitter holds the panes and
|
|
89883
90138
|
* the outer one holds the panel, so the panel spans the full width.
|
|
89884
90139
|
*
|
|
90140
|
+
* **Several source panes are files**, one shown at a time under a row of
|
|
90141
|
+
* tabs, each named by the pane's `label` or, without one, its `name`. `file`
|
|
90142
|
+
* holds the `name` of the pane shown. The tabs are a tab list: the arrow keys
|
|
90143
|
+
* move between them and show each pane, and `Home` and `End` go to the first
|
|
90144
|
+
* and the last. Choosing one sends `helix-before-change` with the pane's
|
|
90145
|
+
* `name`, which you can cancel, and `change` once `file` holds it. The panes
|
|
90146
|
+
* not shown carry `hidden`. One pane draws no tabs.
|
|
90147
|
+
*
|
|
90148
|
+
* **Any editor can be the source pane**: an element in the `source` slot with
|
|
90149
|
+
* a `name` that dispatches `helix-before-edit` with its text, which bubbles.
|
|
90150
|
+
* A wrapper around CodeMirror or Monaco sends one on each change and is a pane
|
|
90151
|
+
* like `helix-sandbox-source`, and the sandbox reads its `value` to seed the
|
|
90152
|
+
* preview. Dispatch `helix-caret` from it too for the status bar's position.
|
|
90153
|
+
*
|
|
89885
90154
|
* On a focused divider, the arrow keys move it, and `Home` and `End` move it
|
|
89886
90155
|
* to its ends. `Enter` on the panes divider shuts the lead pane, and pressed
|
|
89887
90156
|
* again it opens the pane where it was. `Enter` on the panel divider shuts the
|
|
@@ -89908,6 +90177,10 @@ export type CustomElementsSolidJs = {
|
|
|
89908
90177
|
*
|
|
89909
90178
|
* Declared rather than captured, so it is a number a consumer states and can
|
|
89910
90179
|
* change, and it needs no first frame to be read on.
|
|
90180
|
+
* - `file`: The `name` of the source pane shown, where the sandbox holds several.
|
|
90181
|
+
*
|
|
90182
|
+
* Unset, or a name no pane has, shows the first.
|
|
90183
|
+
* - `files-label`/`filesLabel`: The name of the file tabs, read by screen readers.
|
|
89911
90184
|
* - `lead`: Which pane comes first, before the divider.
|
|
89912
90185
|
*
|
|
89913
90186
|
* A sandbox is read in one of two directions and the two are not a
|
|
@@ -89974,6 +90247,8 @@ export type CustomElementsSolidJs = {
|
|
|
89974
90247
|
*
|
|
89975
90248
|
* Events that will be emitted by the component.
|
|
89976
90249
|
*
|
|
90250
|
+
* - `change`: A file tab showed its pane, whose `name` `file` now holds.
|
|
90251
|
+
* - `helix-before-change`: Fired before a file tab shows its pane, with the pane's `name`. Cancelable: cancel it to keep the pane shown.
|
|
89977
90252
|
* - `helix-before-edit`: Fired before the source is edited. The source pane dispatches it, and you can listen for it on the sandbox. Cancelable: cancel it to keep the source unchanged.
|
|
89978
90253
|
* - `helix-before-panel-resize`: Fired before the panel's divider is released, with the panel's height in pixels. A panel dragged closed reports `panel-collapsed-size`, its smallest height. Cancelable: cancel it to keep the current height.
|
|
89979
90254
|
* - `helix-before-split`: Fired before the panes' divider is released, with the lead pane's share. Cancelable: cancel it to keep the current split.
|
|
@@ -90008,6 +90283,8 @@ export type CustomElementsSolidJs = {
|
|
|
90008
90283
|
*
|
|
90009
90284
|
* - `body`: The splitter holding the panes above the panel. `::part(body):state(dragging)` matches while its divider is held.
|
|
90010
90285
|
* - `corner`: The handle where the two dividers cross.
|
|
90286
|
+
* - `file`: One file tab, `aria-selected` while its pane is shown.
|
|
90287
|
+
* - `files`: The file tabs over the source panes, where there are several.
|
|
90011
90288
|
* - `pane`: Either pane.
|
|
90012
90289
|
* - `panel`: The box that holds the slotted panel.
|
|
90013
90290
|
* - `panes`: The splitter holding the source and preview panes. `::part(panes):state(dragging)` matches while its divider is held.
|
|
@@ -90053,6 +90330,8 @@ export type CustomElementsSolidJs = {
|
|
|
90053
90330
|
*
|
|
90054
90331
|
* - `field-label`/`fieldLabel`: The editable region's name, read by screen readers.
|
|
90055
90332
|
* - `keys-description`/`keysDescription`: The field's description, read by screen readers while Tab indents.
|
|
90333
|
+
* - `label`: The pane's file name, such as `index.html`, on its tab where a sandbox
|
|
90334
|
+
* holds several panes. Empty puts the pane's `name` on the tab.
|
|
90056
90335
|
* - `name`: Which source this pane holds. Every `helix-before-edit` event includes it.
|
|
90057
90336
|
*
|
|
90058
90337
|
* `html` and `css` are what the sandbox root routes on; any other name is
|
|
@@ -99199,6 +99478,10 @@ export type CustomCssProperties = {
|
|
|
99199
99478
|
"--canvas-label-editor-inline-size"?: (string) | undefined;
|
|
99200
99479
|
/** The size of the label on a connection. */
|
|
99201
99480
|
"--canvas-label-font-size"?: (string) | undefined;
|
|
99481
|
+
/** The height of the minimap, under `controls="minimap"`. */
|
|
99482
|
+
"--canvas-minimap-block-size"?: (string) | undefined;
|
|
99483
|
+
/** The width of the minimap, under `controls="minimap"`. */
|
|
99484
|
+
"--canvas-minimap-inline-size"?: (string) | undefined;
|
|
99202
99485
|
/** The frame's corners. */
|
|
99203
99486
|
"--canvas-radius"?: (string) | undefined;
|
|
99204
99487
|
/** The color of what is selected: a card's outline, its corners and its move handle, a connection and its ends, and the box drawn to select. */
|