@delurio/cli 0.17.0 → 0.18.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +15 -0
- package/README.md +10 -10
- package/SPEC.md +45 -16
- package/js/graph.d.ts +42 -1
- package/js/graph.js +55 -3
- package/js/internal.js +2 -2
- package/js/native.d.cts +41 -2
- package/package.json +7 -7
- package/schemas/binding.schema.json +169 -19
- package/schemas/catalog.schema.json +2 -2
- package/schemas/ui.schema.json +37 -0
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,21 @@
|
|
|
2
2
|
|
|
3
3
|
While the version is 0.x, a release that can judge the same graphs differently (a new check, a stricter schema) bumps the minor; a fix that judges nothing differently bumps the patch.
|
|
4
4
|
|
|
5
|
+
## 0.18.0 (2026-11-30)
|
|
6
|
+
|
|
7
|
+
This release takes in five follow-ups from binding delurio's own panel (SPEC.md §4, §7): where the focus goes when the node a dialog would give it back to is gone, a field kept read-only while its form is sent, a passkey in the walk's own browser, the language a walk reads in when the flow has no catalog of the browser's, and a modal dialog that makes the rest of the page absent. It also takes in three answers of 30 Nov 2026 (SPEC.md §2, §4, §7): a catalog's plurals and selects, read as ICU MessageFormat, a check that walks a flow once for the variables only its screens read, and a scenario's `then` that holds every time a step happens. And it takes in two binding keys of 29 and 30 Nov 2026 for a faster replay (SPEC.md §7): a binding's `settle.time`, the replay's own time, and a navigation binding's `pages.<page>.serial`, a page opened one persona at a time. The ui and binding schemas take the new keys, and `check` holds graphs and bindings to them. A graph whose dialogs are shown with no node of the page behind them, that uses none of the new keys, whose messages ICU's MessageFormat reads as `{name}` was read before (no plural or select, no apostrophe before a brace, no space inside `{ }`), and whose bindings' `then` name only what its flow has, is judged as before.
|
|
8
|
+
|
|
9
|
+
- Where the node that a dialog's `returnsFocus` names is no longer drawn in the state the flow lands in, the rules after it give the focus: the `initialFocus` of a page that opens, else `focus.<state>` (SPEC.md §4, an opener that is gone). A node is no longer drawn where the new state does not show it, by its `in`, `unless` and `when`, and, for a repeat node, where its element on the row the dialog was opened from has left the page: the "⋯" of a member's row once the member is removed, after which the focus goes to the notice that says so, as the ARIA Authoring Practices Guide asks. Before, `returnsFocus` won wherever its node was shown, so a graph could not say where the focus goes once the opener itself is removed. `focusAfter(ui, from, to, pressed, gone)` in `@delurio/cli/graph` takes the nodes a walk found no longer drawn there (`focus_after_gone` in `delurio-core`), and for a list of which the new state shows none it now gives the rules after `returnsFocus`, where it gave nothing. `focus-not-shown` no longer holds a `returnsFocus` to a node no state its dialog closes into shows when each of those states has a `focus`; where some have none, it is given as before, and its message names them.
|
|
10
|
+
- `readOnlyIn: [<state>, ..]` on a field: the states where it is shown read-only, keeping its value and its focus and taking no input, unlike `disabledIn`, as a field is while its form is sent (SPEC.md §4). A replay compares it by the readonly property of the browser's accessibility tree (HTML `readonly`, `aria-readonly`). A read-only field sends no event there: `event-unhandled` does not hold such a state to its event, `during-step-unused` reads it as it reads `disabledIn`, and a tutorial that presses it there is `tutorial-mismatch`. The `schema` rule refuses it on any node but a field whose role takes `aria-readonly` (`checkbox`, `columnheader`, `combobox`, `grid`, `gridcell`, `listbox`, `radiogroup`, `rowheader`, `searchbox`, `slider`, `spinbutton`, `switch`, `textbox`, `treegrid`) or a native date or time input; a state of it that is not a state of the flow, and a state in both `disabledIn` and `readOnlyIn`, keep the graph from loading. `diff` says it as it says `disabledIn` ("is now read-only on …"). The page and `kit check` draw and expect such a field as before.
|
|
11
|
+
- A binding action, `WebAuthn.addCredential: { rpId, credentialId, privateKey, userHandle, resident, signCount }`, gives the browser it is done in a passkey, so that a walk can sign in by passkey (WebAuthn, SPEC.md §7). It is named after the command that does it, Add Credential of the W3C's WebAuthn WebDriver extension, `WebAuthn.addCredential` in Chromium's DevTools Protocol; the dot is part of its name, as in `FAIL.network`. The replay adds a virtual authenticator to that browser the first time (CTAP 2, transport `internal`, discoverable credentials, the user verified, no prompt), as Chromium's DevTools Protocol does with `WebAuthn.addVirtualAuthenticator` and `WebAuthn.addCredential`. The ids and the key are base64url, the key an ECDSA P-256 key in PKCS #8 that no report shows; `resident` is `true` when left out and then needs `userHandle`; `signCount` left out gives a passkey with no counter, as a synced one is. A browser with no virtual authenticator fails the walk at the action. The binding schema takes it, and `check` holds it (rule `schema`): an `rpId` with a `/`, a `:` or a space (an address, not a domain), an id, a key or a user handle that is neither base64url nor holds a `{placeholder}`, a user handle over 64 bytes, a resident passkey without one, a `signCount` below 0, another key in it, or a second verb beside it. `check` runs no walk, so nothing else it does changes.
|
|
12
|
+
- SPEC.md §7: where the flow has no catalog of the locale a walk runs in, the app shows its pages in a language it has, and each screen is checked against the flow's catalog of the language the page itself is in, its `lang` (`<html lang>`), found as a locale is; a page with no `lang`, or in a language the flow has no catalog of either, against the catalog `ui.yaml` names, and the report says so. A flow the walk enters, a flow a node draws and a navigation graph have no such fallback. A walk read in its page's language reads the next screens in the language the page is in then. Before, such a locale was refused. `check` is unchanged by it.
|
|
13
|
+
- A modal dialog makes the rest of the page absent (SPEC.md §4): in a situation that shows one, by its `in`, `unless` and `when`, each node outside it is read as absent, as if the state were not in the node's `in`, as a modal dialog makes the page inert (HTML `showModal()`, `aria-modal`). A dialog, a page node whose role is `dialog` or `alertdialog`, is modal unless it says `modal: false`, a key the ui schema takes only on a dialog. A node is outside the modal dialogs when some situation the flow reaches shows it and shows no modal dialog; one shown only where a modal dialog is shown is inside one, such as the dialog's own buttons, or a notice several dialogs share. Where two are shown at once, neither makes the other's nodes absent. A replay does not look for such a node, and under `--absent` checks that it is out of the accessibility tree rather than out of sight. `check` reads the rule where it reasons about a situation: `event-unhandled` no longer holds a state to the event of a node that a modal dialog makes absent there, `focus.<state>` to a node that a modal dialog makes absent wherever the flow is in the state is `focus-not-shown`, and a tutorial that presses one is `tutorial-mismatch`. Before, the page's nodes had to be taken out of the `in` of every state that shows a dialog over the page, and a drawer drawn by the context (`when: "detail == 'open'"`) could not hide them at all. `modalDialogs(g, m, ex)` and `modalAbsent(g, m, modal, state, ctx)` in `@delurio/cli/graph` give a replay the checker's own rule: the modal dialogs and the nodes outside them, read over every situation the flow reaches as `check` reads it (or over an exploration the caller gives), and, for a situation, the dialog it shows and the nodes that dialog makes absent there; `isModal(n)` says whether a node is a modal dialog, and `UiNode` in its types takes `modal` and `readOnlyIn`. `delurio_core::modal` gives the rule to a Rust program (`Modal::of_flow`); the page and `kit check` draw and expect each state's screen as before, the page behind a dialog included.
|
|
14
|
+
- A catalog's messages are read as ICU MessageFormat wherever the tools read one (SPEC.md §4, Catalog): the page, the tutorial stage, `kit check`'s expectations, `nodeTexts`, the diagram's labels and `check`. `{count, plural, one {# finding} other {# findings}}` takes the case of its number's CLDR plural category in the catalog's language, after an `=<n>` case of that number and less its `offset:`, and `#` writes the number; `selectordinal` reads CLDR's ordinal rules, `select` the value's words, and each needs `other`; an apostrophe quotes as ICU's does (`''`, and `'{ … }'`). A value is written as it is given, as `{name}` was. Each locale's catalog is read by its own language's rules, the locale its file is named by, so English may give `one` and `other`, Polish `few` and `many` too, and Turkish no plural at all, and `check` does not compare their cases. `catalogWords(g, key, values, locale)` in `@delurio/cli/graph` gives what a message shows with the values a walk has: a string, or a RegExp that each form matches where it does not know a value, a plural's or a select's included, a number it does not know (a plural's, a `number` argument's) matching any number and any other value any text, for a replay to expect of a node's words and name; a graph object may carry the `locale` of another locale's catalog lent to it (`{ ...g, catalog, locale }`). `check` holds each argument a message names, in every case, to a sample (`sample-missing`), and a plural's to a number, and a message a screen uses that is not ICU MessageFormat is an error of a new rule, `catalog-message-invalid`, at its key in its catalog, in each locale; the page draws such a message as before. Before, only `{name}` was filled, and a plural was drawn as it is written: delurio's own panel said "1 findings". A message with a space inside `{ }` now names an argument, as ICU reads it: `rehber.register({ navigate })` asks for a sample of `navigate`, and ICU writes the braces themselves `'{ navigate }'`. The plural rules are CLDR's, through `icu_plurals` 2.4.0 of ICU4X.
|
|
15
|
+
- `check` walks a flow once for the variables only its screens read (SPEC.md §2, A variable only the screens read), such as whether a disclosure is opened: a variable that only its own toggles change, each going back to its state and changing nothing else, under a guard that cannot throw, in a state that runs no step, and that only those toggles' guards and the `when` of words that send no event, are no dialog and are given no focus read, and that the flow's tutorial does not name. A situation that differs from one walked only in such variables is not walked again, as nothing `check` judges reads them, and the findings are the same, the ways to them included. With `n` of them, two values each, a situation is walked once where it was walked up to 2ⁿ times, once for each of their values: delurio's own rehber.install at 7ece26a0 folds 17 of its 32 variables, its six disclosures among them, and is checked in 5.9 s and 297 MB, where walking every configuration ran out of a 6 GB limit after 255 s (it needs 12 GB and over six minutes). Differential tests hold the findings folded and whole, byte for byte, on the examples, on 400 flows made at random with such variables and with ones that only look like them, and on the 22 of delurio's own flows that fold a variable (`crates/delurio-core/tests/fold.rs`). `explore` and `cover` in `@delurio/cli/model`, the page and replays walk every configuration as before; `explore_folded` and `screen_only` in `delurio-core` give the walk and the variables to a Rust program.
|
|
16
|
+
- A scenario's `then` may give an effect one entry in place of the list (SPEC.md §7): `then: { <effect>: { <variable>: <value>, .. } }` holds every time the walk applies the effect, however often, where a list is read in order and leaves the variables to chance again once it has run out. So a binding says what a dialog starts with each time it opens, which no list could say of a step a walk takes as often as its ways need: delurio's videos.produce source dialog, opened a second time, was planned with another source and a refusal no step of the binding causes. An effect has one form or the other. The binding schema takes it. `check` holds each scenario's `then`, in each binding beside the flow that binds it, to the flow, as a replay loads the binding: an effect the flow does not have, a variable the effect's `havoc` does not list, or a value the variable does not have is an error of a new rule, `binding-then`, at its place in the binding. `thenEntry(then, effect, before)`, `thenEntries(then, effect)` and `thenProblems(g, then)` in `@delurio/cli/graph` read a scenario's `then` as a replay does, both forms included.
|
|
17
|
+
- `settle.time` in a binding, of a flow or of a navigation graph (SPEC.md §7): `real`, the default, or `virtual`, the replay's own time, which passes the page's idle time at once while the replay waits for the page. The binding schema takes it, and `check` refuses any other value (rule `schema`); a binding without it is judged as before. Proposed 29 Nov 2026 and approved 29 Nov 2026 (Taha: "üçüne de onay veriyorum, devret").
|
|
18
|
+
- `pages.<page>.serial` in a navigation graph's binding (SPEC.md §7): the personas or accounts that open the page one at a time, while their other visits go at once, for a page that holds something for one person at a time (an editor's lock). The binding schema takes it. Proposed 30 Nov 2026 and approved 30 Nov 2026 (Taha: "önerini uygula").
|
|
19
|
+
|
|
5
20
|
## 0.17.0 (2026-11-29)
|
|
6
21
|
|
|
7
22
|
This release lets a binding say how long its commands may run (SPEC.md §7). The binding schema takes the new key, and `check` holds a binding to it (rule `schema`).
|
package/README.md
CHANGED
|
@@ -62,7 +62,7 @@ Several folders may be given (`check graphs examples`); a graph under two of the
|
|
|
62
62
|
|---|---|
|
|
63
63
|
| 0 | every graph loads, and under `--strict` nothing is wrong |
|
|
64
64
|
| 1 | a graph cannot be loaded, or is written for a newer format than this version reads |
|
|
65
|
-
| 2 | under `--strict`: a guarantee is broken, a state cannot be reached or has no way out, a catalog key is missing from a locale or a sample is missing, the main story cannot be walked, a node is shown enabled where its event is not handled, a tutorial no longer matches its flow, a writing flow has no changes note, a domain names an entity or a field it does not have, a flow invokes an action or lists a failure code its domain does not have, a policy names one, a `source:` anchor names a file or a line that is not there, a need's evidence is not there or a product's gaps and its needs disagree… |
|
|
65
|
+
| 2 | under `--strict`: a guarantee is broken, a state cannot be reached or has no way out, a catalog key is missing from a locale, a catalog message is not ICU MessageFormat or a sample is missing, the main story cannot be walked, a node is shown enabled where its event is not handled, a tutorial no longer matches its flow, a writing flow has no changes note, a domain names an entity or a field it does not have, a flow invokes an action or lists a failure code its domain does not have, a policy names one, a `source:` anchor names a file or a line that is not there, a need's evidence is not there or a product's gaps and its needs disagree… |
|
|
66
66
|
|
|
67
67
|
## What a product must have: needs and gaps
|
|
68
68
|
|
|
@@ -120,21 +120,21 @@ A file is a woff2, woff, ttf or otf file of at most 2 MiB, and a kit's files are
|
|
|
120
120
|
## Write a graph in an editor
|
|
121
121
|
|
|
122
122
|
The npm package ships a JSON Schema (2020-12) for each kind of graph file in `schemas/`: `flow`, `ui`, `nav` (also `nav.extracted.yaml`), `domain`, `catalog`, `needs`, `gaps` (`needs.gaps.yaml`) and `binding` (`binding.yaml` and a shared `<name>.binding.yaml`). With them an editor completes keys, explains each one from SPEC.md on hover, and marks a typo, a value of the wrong kind, or a title cut short by a comma inside `{ }`. In VS Code, with the YAML extension, put this in `.vscode/settings.json`, with the version your project pins in
|
|
123
|
-
place of 0.
|
|
123
|
+
place of 0.18.0 (a schema from an older release does not know the keys added since):
|
|
124
124
|
|
|
125
125
|
```json
|
|
126
126
|
{
|
|
127
127
|
"yaml.schemas": {
|
|
128
|
-
"https://unpkg.com/@delurio/cli@0.
|
|
129
|
-
"https://unpkg.com/@delurio/cli@0.
|
|
130
|
-
"https://unpkg.com/@delurio/cli@0.
|
|
131
|
-
"https://unpkg.com/@delurio/cli@0.
|
|
132
|
-
"https://unpkg.com/@delurio/cli@0.
|
|
133
|
-
"https://unpkg.com/@delurio/cli@0.
|
|
134
|
-
"https://unpkg.com/@delurio/cli@0.
|
|
128
|
+
"https://unpkg.com/@delurio/cli@0.18.0/schemas/flow.schema.json": "**/flow.yaml",
|
|
129
|
+
"https://unpkg.com/@delurio/cli@0.18.0/schemas/ui.schema.json": "**/ui.yaml",
|
|
130
|
+
"https://unpkg.com/@delurio/cli@0.18.0/schemas/nav.schema.json": ["**/nav.yaml", "**/nav.extracted.yaml"],
|
|
131
|
+
"https://unpkg.com/@delurio/cli@0.18.0/schemas/domain.schema.json": ["**/domain.yaml", "**/domain/*.yaml"],
|
|
132
|
+
"https://unpkg.com/@delurio/cli@0.18.0/schemas/needs.schema.json": "**/needs.yaml",
|
|
133
|
+
"https://unpkg.com/@delurio/cli@0.18.0/schemas/gaps.schema.json": "**/needs.gaps.yaml",
|
|
134
|
+
"https://unpkg.com/@delurio/cli@0.18.0/schemas/binding.schema.json": ["**/binding.yaml", "**/binding.*.yaml", "**/*.binding.yaml"]
|
|
135
135
|
},
|
|
136
136
|
"json.schemas": [
|
|
137
|
-
{ "fileMatch": ["**/catalog/*.json"], "url": "https://unpkg.com/@delurio/cli@0.
|
|
137
|
+
{ "fileMatch": ["**/catalog/*.json"], "url": "https://unpkg.com/@delurio/cli@0.18.0/schemas/catalog.schema.json" }
|
|
138
138
|
]
|
|
139
139
|
}
|
|
140
140
|
```
|
package/SPEC.md
CHANGED
|
@@ -119,6 +119,14 @@ A transition is a target state id, or `{ target, guard, effect: [..], say, start
|
|
|
119
119
|
|
|
120
120
|
A configuration is a state together with a value for every context variable. The checker starts from every initial configuration and follows every transition whose guard holds, applying its effects, breadth first. An `always` state moves on at once. Every reachable configuration is visited once.
|
|
121
121
|
|
|
122
|
+
**A variable only the screens read.** Whether a disclosure is opened is a variable that its summary toggles and that only the `when` of the words it folds away reads (`opened: { values: [false, true], initial: false }`, with `TOGGLE: [{ guard: "not opened", target: page, effect: [open] }, { target: page, effect: [close] }]`). Each such variable doubles the configurations the checker visits, while none of them changes what the flow can do. So the checker leaves such variables out of what tells two configurations apart: a configuration that differs from one already visited only in them is not visited again, and each configuration it visits keeps the values they had when it was first reached, which are their starting values. Nothing the checker judges reads them, and each finding is found at the first configuration that has it, breadth first, so it finds the same as when it visits every configuration, the way to each finding included: the configurations it visits are the first of each kind that a walk of them all reaches, in the same order and by the same transitions. A variable is one when:
|
|
123
|
+
|
|
124
|
+
- each transition whose effects change it is under `on` of a state that runs no step (`invoke`), and every transition on that event in that state goes back to that state, starts no flow (`starts`), names only effects the flow has, which change no other variable, and has a guard that cannot throw (one that names only variables, guards and `state`, §3);
|
|
125
|
+
- no expression reads it, itself or through a guard it names, but the guards of those transitions and the `when` of a node that sends no event, is no dialog and is not given the focus by `focus` (§4): no other guard, no assertion, no `starts.given`, no node's `disabledWhen`, `checked` or `tone`;
|
|
126
|
+
- the flow's tutorial (§7) names neither it nor a node whose `when` reads it, anywhere in tutorial.yaml.
|
|
127
|
+
|
|
128
|
+
A graph says nothing for it: the checker finds such variables from what the graph says, and a variable that something else reads is visited in every value, as before. With `n` of them, two values each, a configuration is visited once where it was visited up to 2ⁿ times, once for each of their values. The page, a replay, and `explore` and `cover` in `@delurio/cli/model` visit every configuration, as before. Decided on 30 Nov 2026 ("Checker ucuzlayınca"), when three "How it works" disclosures of delurio's own rehber.install took its check from 4.4 GB to 12 GB.
|
|
129
|
+
|
|
122
130
|
Each assertion is `never: <expression>`: it holds when no reachable configuration satisfies the expression. A violation is reported with the shortest event path from a starting situation. Under `--strict` a violated assertion exits 2.
|
|
123
131
|
|
|
124
132
|
`check` gives an error (`state-unreachable`) for a state that no reachable configuration is in: no transition leads to it, or those that do are never taken from a start. It gives one (`state-no-way-out`) for a state that is not an exit (`type: final`) and has no `on`, `always` or `invoke`, so that a flow that reaches it stops there without ending. Both are given at the state and fail `--strict`; the page marks an unreachable state too. Transitions that no situation takes are shown on the page and fail nothing yet; that is [#2](https://github.com/delurio-labs/delurio/issues/2).
|
|
@@ -176,6 +184,7 @@ rules: [ { id, rule } ]
|
|
|
176
184
|
| `when` | a guard or context flag that must hold for the node to show |
|
|
177
185
|
| `disabledIn` | states where the node is shown but disabled |
|
|
178
186
|
| `disabledWhen` | an expression over the context (§3): where it holds, the node is shown but disabled, in any state that shows it. A repeat node's may read its place among the rows (Rows of a repeat, below) |
|
|
187
|
+
| `readOnlyIn` | on a field: states where it is shown read-only, keeping its value and its focus and taking no input, as a field does while its form is sent (What a control holds, below) |
|
|
179
188
|
| `emits` | the event the node sends when pressed |
|
|
180
189
|
| `duringStep: true` | in a state that runs a step (`invoke`): the node stays usable while the step runs, and its event is handled once the step ends, by the state the step's outcome leads to (below) |
|
|
181
190
|
| `initialFocus` | on a page: the node that has focus when it opens (Focus, below) |
|
|
@@ -200,11 +209,13 @@ A `role` is a WAI-ARIA 1.2 role, and `name` is the accessible name that Accessib
|
|
|
200
209
|
|
|
201
210
|
A node is shown in a state when the state is in `in`, not in `unless`, and `when` holds. `edges` records relations the page and the checks use: a node labelled by another, an action that leads to a state, the node a dialog gives the focus back to. `rules` are written but no tool reads them yet; checking them, together with labelled dialogs and confirmation before a destructive action, is [#3](https://github.com/delurio-labs/delurio/issues/3). The focus return of #3 is partly answered: a dialog says where the focus returns with `returnsFocus` (below), and `check` holds that it starts at a dialog and gives the focus to a node shown where the dialog closes. That every dialog says it is still #3. Events handled where shown are answered: `check` holds that a node's event is handled wherever the node is shown enabled (`event-unhandled`, below).
|
|
202
211
|
|
|
212
|
+
**A modal dialog makes the rest of the page absent.** A dialog, a page node whose role is `dialog` or `alertdialog` (Focus, below), is modal unless it says `modal: false`. While a modal dialog is open, the rest of the page is inert: out of the accessibility tree, and out of reach of the pointer and the keyboard, as HTML's `<dialog>` opened with `showModal()` and WAI-ARIA's `aria-modal="true"` make it, and as the dialog pattern of the ARIA Authoring Practices Guide asks. So in a situation (§2) that shows a modal dialog, by its `in`, `unless` and `when`, each node outside it is read as absent, as if the state were not in the node's `in`. A node is outside the modal dialogs when some situation the flow reaches shows it and shows no modal dialog, as the page behind a dialog is shown before the dialog opens; a node shown only where a modal dialog is shown is inside one: the dialog's own heading and buttons, or a notice that several dialogs share. So the page's nodes need not be taken out of the `in` of the states that show a dialog over the page, nor out of the situations in which a drawer drawn by the context is open (a drawer with `when: "detail == 'open'"`). A dialog with `modal: false`, such as a guide's box beside the element it points to, leaves the page as it is. Where two modal dialogs are shown at once, the graph does not say which is on top, and neither makes the other's nodes absent; a graph that stacks dialogs says what the lower one hides by `in` and `when`. A replay does not look for a node that a modal dialog makes absent; under `--absent` it checks that the node is out of the accessibility tree, inert or not there at all (§7), and not that it is out of sight, as the page may still be seen behind the dialog's backdrop. The page draws each state's screen as before, the page behind a dialog included. `check` reads the rule wherever it reasons about what a situation shows, and holds a graph that needs such a node where it is absent as it holds one that needs a node its state does not show: `event-unhandled` (below) does not hold a state to the event of a node that a modal dialog makes absent there, as it cannot be pressed; `focus.<state>` to a node that a modal dialog makes absent in every situation of the state that the flow reaches is `focus-not-shown`; and a tutorial step that presses such a node is `tutorial-mismatch` (§7). Each of the last two is an error, as the graph then says that a node has the focus, or is pressed, where its own screens make it unreachable. Decided on 30 Nov 2026.
|
|
213
|
+
|
|
203
214
|
### Focus
|
|
204
215
|
|
|
205
216
|
A page that opens gives the focus to its `initialFocus`. `focus` and `returnsFocus` say where it goes after that, when someone acts or a step ends. A page opens when the flow enters a state that shows it from a state that does not, or starts in a state that shows it, however the browser got there: by a step inside the app, or by loading the page anew (a link from an e-mail, a reload, the way back from another site). Its `initialFocus` holds in both; an app that leaves the focus at the document's start after a load does not meet it. The flow moves from one state it stops in to the next: a state with `always` is passed at once, so the focus is never said there. When the flow moves from one state into another, the node that has focus in the new state is the first of these that applies:
|
|
206
217
|
|
|
207
|
-
1. the node of `{ returnsFocus: [<dialog>, <node>] }` in `edges`, when the dialog closes (the state before shows it and the new one does not) and the new state
|
|
218
|
+
1. the node of `{ returnsFocus: [<dialog>, <node>] }` in `edges`, when the dialog closes (the state before shows it and the new one does not) and the node is still drawn in the new state (an opener that is gone, below). The dialog is a page node whose role is `dialog` or `alertdialog`, and the node is usually the one that opened it, as the dialog pattern of the ARIA Authoring Practices Guide asks. Where several nodes open the same dialog, the second item is the list of them, `[<dialog>, [<node>, ..]]`, or `opener`, `[<dialog>, opener]`: the focus goes back to the node that opened the dialog this time, one of those listed for a list (opener, below);
|
|
208
219
|
2. the `initialFocus` of a page that opens and has one; when a dialog opens over a page, the dialog's;
|
|
209
220
|
3. `focus.<state>`, the node that has focus when the flow enters that state from another one: on a page that stays open, the alert a failed step shows, or the status that says a step is done.
|
|
210
221
|
|
|
@@ -212,9 +223,11 @@ When none applies, and when the flow moves from a state to itself, the graph say
|
|
|
212
223
|
|
|
213
224
|
The node that opened a dialog is the one pressed to open it: a node shown in the state before the dialog opened, whose `emits` is the event of the transition into the state that shows the dialog (past states with `always`). A dialog that edits any of four fields, each with its own Edit button, gives the focus back to the Edit button that was pressed. The graph cannot say which one that was, as the four lead to the same state; a replay knows the node it pressed, and gives it to `focusAfter` as its fourth argument. Without it, `focusAfter` gives the one node of a list that the new state shows, and nothing for `opener` or for a list of which the new state shows several. `opener` is a word of the format, not a node: no node is called `opener`. A replay checks, in each state it stops in, that the node the graph gives has the focus: the browser's focused element is that node, found by its role and name or by its binding (§7).
|
|
214
225
|
|
|
215
|
-
A
|
|
226
|
+
**An opener that is gone.** A step may take away the node the focus would go back to: the "⋯" of a member's row, gone with the row once the member is removed, or a finding's Dismiss button, which a dismissed finding no longer draws. Where the node that `returnsFocus` names is no longer drawn in the state the flow lands in, the first rule does not apply, and the rules after it do: the `initialFocus` of a page that opens, else `focus.<state>`, such as the notice that says the member was removed (`focus: { teamPage: removedNote }`). It is what the dialog pattern of the ARIA Authoring Practices Guide asks when the element that opened a dialog no longer exists: the focus goes to another element that follows from what was done. A node is no longer drawn where the new state does not show it, by its `in`, `unless` and `when`, and, for a node drawn once per row (`repeat`), where its element on the row the dialog was opened from has left the page, as the row a step removes takes its elements with it, while the node still draws the other rows. The graph knows what `in` and `unless` say; a replay knows the rest: it reads `when` over the context it has walked to, and it knows the element it pressed to open the dialog, or opened the pressed node from (a node's `before`, §7), and whether that element is still in the page. `focusAfter` takes as its fifth argument the nodes the walk found no longer drawn there (`gone`), and gives the focus as if the new state did not show them; for a list of which the new state shows none, it gives the rules after the first, with or without the node pressed. Decided on 30 Nov 2026.
|
|
227
|
+
|
|
228
|
+
A state that `focus` names that is not a state of the flow keeps the graph from loading. `check` gives an error (`focus-not-shown`) where `focus` gives the focus to a node its state does not show (by `in` and `unless`; a replay reads `when`), or a `returnsFocus` to a node no state the dialog closes into shows, unless each of those states has a `focus`, which gives the focus there as the node is gone (the error names those that have none), and one (`returns-focus-not-dialog`) where a `returnsFocus` starts at a node that is not a dialog. For a list, each node it lists is held so; for `opener`, each node that opens the dialog, and a dialog that no node opens is `focus-not-shown` too.
|
|
216
229
|
|
|
217
|
-
`check` gives an error (`event-unhandled`) where a node that sends an event (`emits`) is shown and enabled in a state that does not handle it: in a situation the checker reaches (§2), the state is in the node's `in` and not in its `unless`, its `when` holds, the state is not in its `disabledIn`
|
|
230
|
+
`check` gives an error (`event-unhandled`) where a node that sends an event (`emits`) is shown and enabled in a state that does not handle it: in a situation the checker reaches (§2), the state is in the node's `in` and not in its `unless`, its `when` holds, the state is not in its `disabledIn` (nor, for a field, in its `readOnlyIn`), its `disabledWhen` does not hold, no modal dialog makes it absent there (above), and the state has no transition on the event in its `on`. Pressing the node there sends an event after which the flow says nothing, such as a Save button left enabled while the save runs. Each state that shows such a node disables it or handles its event. Three are not held, by what §2 says of them: a node that sends `NAVIGATE`, the person leaving the page, which is always possible; an exit (`type: final`), which has no transitions, so what a node on its page does is outside the flow (a new run of it, or another flow); and a state with `always`, which is passed at once, so nothing is pressed there. It is given once per node and state, at the node; where the node's `when` or `disabledWhen` decides it, its notes give the way from a start to the first situation that shows it enabled, as for a broken assertion.
|
|
218
231
|
|
|
219
232
|
A node may be meant to stay usable while a step runs, such as a link to sign out beside a form being saved, or a plan's other buttons while a payment is taken: the app lets it be pressed, and acts on the press once the step is over. `duringStep: true` on the node says so, and its event is handled after the step: in a state that runs a step (`invoke`), the state need not handle it, and the state the step's outcome leads to does. So `check` holds, from each situation of the step that shows the node enabled, every situation its `DONE` and its `FAIL.<class>` lead to, past states with `always`: there the state handles the event, or shows the node disabled or not at all, or is an exit; or it runs a step of its own and shows the node enabled, and the press waits again, for that step's outcome, and is held where that leads. A step that leads back to one already walked is not walked twice. Where none of these holds, the error (`event-unhandled`) is given for the step's state, as before, and says the outcome and the state the press is left in; its notes give the way to that state through the step. In a state the person is in, and in a step whose state handles the event, the marker changes nothing. It is what UML 2.5.1 calls a deferred event (a State's `deferrableTrigger`): each state that runs a step defers the node's event, until the flow stops in one that does not. A replay does not press a node while a step runs: in the step's state it checks what the state shows, a marked node enabled as the graph shows it, and then waits for the step's outcome (§7, `call`), so the marker changes nothing a replay does. A node marked so is a warning of `check` (`during-step-unused`) where the marker can change nothing: no state that runs a step shows it, by `in` and `unless`, or every one that does disables it (`disabledIn`), or it sends `NAVIGATE`. On a node that sends no event the `schema` rule refuses it.
|
|
220
233
|
|
|
@@ -224,13 +237,15 @@ A node may be meant to stay usable while a step runs, such as a link to sign out
|
|
|
224
237
|
|
|
225
238
|
`disabledIn` lists the states in which a node is shown but disabled. `disabledWhen` disables it by what the context holds, in every state that shows it: a Continue button disabled until a VAT number is typed (`disabledWhen: "not vatGiven"`, where typing it is an event whose effect sets `vatGiven`), or until a box is ticked (`disabledWhen: "not accepted"`, beside the box's `checked: accepted`). A node is disabled where either says so. A replay compares it in each situation it stops in, from the context it has walked to there. A `disabledWhen` that does not parse, or names anything but a variable, a guard or `state`, keeps the graph from loading, as `checked` does, and so does such a `when`.
|
|
226
239
|
|
|
240
|
+
`readOnlyIn` lists the states in which a field is shown read-only: it keeps its value and can have the focus, and a person can read it and select its words but not change them. A disabled field cannot have the focus, is passed over by the keyboard, and is left out of what its form sends. So a form that is being sent keeps its fields read-only rather than disabled, and the focus stays where it was and what was typed stays readable: `readOnlyIn: [inviting]` on the address of an invitation being sent, beside its Send button's `disabledIn: [inviting]`. HTML says it with the `readonly` attribute of an `<input>` or a `<textarea>`, WAI-ARIA with `aria-readonly="true"`; both are the readonly property of the browser's accessibility tree, which a replay reads. A replay compares it in each situation it stops in, as it compares `disabledIn`: in a state of `readOnlyIn` the field is read-only and not disabled, and in another state that shows it, it is not read-only. Where its `disabledWhen` holds, the field is disabled, and only that is compared. A read-only field takes no input, so it sends no event there: `event-unhandled` (above) does not hold such a state to its event, and a tutorial that presses it there stops (`tutorial-mismatch`, §7). A field can be read-only where its role takes `aria-readonly` (WAI-ARIA 1.2: `checkbox`, `columnheader`, `combobox`, `grid`, `gridcell`, `listbox`, `radiogroup`, `rowheader`, `searchbox`, `slider`, `spinbutton`, `switch`, `textbox` and `treegrid`), or where it is a native date or time input (`native: date`, `time`, `datetime-local`, `month` or `week`). A state of `readOnlyIn` that is not a state of the flow, and a state that is in both `disabledIn` and `readOnlyIn`, keep the graph from loading. Decided on 30 Nov 2026.
|
|
241
|
+
|
|
227
242
|
`script` on a page says how much of it works without JavaScript. With `script: optional` the page and its actions work without it: its forms are posted and its links followed by the browser itself, and JavaScript only adds to them. With `script: actions` the page is drawn and can be read without JavaScript, as a page rendered on the server is, but its actions need it. Without `script` the page needs JavaScript, and the graph says nothing of it without. A replay with `--no-js` (§7) walks the flow a second time with JavaScript off. In a state whose page is `optional` it checks what the state shows, as on the first walk, and takes the next step there. In a state whose page is `actions` it checks what the state shows, and takes no step from it: the walk ends there, as it does where a step leads to a page without `script`.
|
|
228
243
|
|
|
229
244
|
While scripts do not run, an action of a page marked `actions` is not there, or it is there disabled and says why. A control that looks ready and does nothing when pressed, a dead button, does not meet this. The app may leave the control out of the page it draws on the server and add it when its script runs, or draw it disabled (`disabled`, or `aria-disabled="true"`) with an accessible description that gives the reason, such as that it needs JavaScript (a `<noscript>` note that `aria-describedby` points at). So in such a state the `--no-js` walk checks each action node the state shows (`type: action`): it is not visible, or it is disabled and its accessible description (Accessible Name and Description Computation 1.2) is not empty. One that is visible and enabled, or disabled with no description, is a mismatch.
|
|
230
245
|
|
|
231
246
|
`holds` says which field of the flow's domain (§5) a node holds: the value a text shows, such as a client's name in a heading, or the value a field takes, such as a password or an API key typed into it. It names an entity of the domain and one of its fields, `<Entity>.<field>`, as `references` names an entity. So the screens say where a value the domain marks with `sensitivity` is shown or typed, and a tool that records them knows what to keep out: a recording masks every node that holds a field whose `sensitivity` the binding's `mask` names, `credential` unless it says (§7). `check` holds each `holds` to the domain the flow names, found as for `invoke` (§5): an entity the domain does not have, a field the entity does not have, or a domain that is not found beside the flow, is an error (`holds-unknown`) at the `holds`; an entity none of whose files gives `fields` yet is not held to them. `maskedNodes(g, mask)` in `@delurio/cli/graph` names the nodes of a graph that a recording masks, in the order of `nodes`, for the binding's `mask` (`[credential]` when it is left out).
|
|
232
247
|
|
|
233
|
-
The `schema` rule refuses `value` on a node that is not a field, `checked` on a node of another role, `script` on a node that is not a page, and a node called `opener`. A `checked`, a `when` or a `disabledWhen` expression that does not parse, or names neither a variable, a guard nor `state`, keeps the graph from loading. A `value` from the catalog is held as a node's text is (`catalog-key-missing`, `sample-missing`).
|
|
248
|
+
The `schema` rule refuses `value` on a node that is not a field, `checked` on a node of another role, `readOnlyIn` on a node that is not a field that can be read-only, `script` on a node that is not a page, and a node called `opener`. A `checked`, a `when` or a `disabledWhen` expression that does not parse, or names neither a variable, a guard nor `state`, keeps the graph from loading. A `value` from the catalog is held as a node's text is (`catalog-key-missing`, `sample-missing`).
|
|
234
249
|
|
|
235
250
|
### Tone
|
|
236
251
|
|
|
@@ -270,7 +285,17 @@ Adjacent nodes, in the order of `nodes`, that share the same `repeat` are drawn
|
|
|
270
285
|
|
|
271
286
|
### Catalog
|
|
272
287
|
|
|
273
|
-
A JSON object from key to an ICU MessageFormat message: the syntax of the catalogs apps already keep (ICU, FormatJS, next-intl), so a captured catalog is copied as it is.
|
|
288
|
+
A JSON object from key to an ICU MessageFormat message: the syntax of the catalogs apps already keep (ICU, FormatJS, next-intl), so a captured catalog is copied as it is. The tools read each message as ICU's MessageFormat reads it, wherever they read one: the page and the tutorial stage draw it, `kit check` and a replay expect it, and `check` holds it. An argument takes its value from the node's `params`, which name sample or data values, by the argument's name (a sample, or a field of the row a repeat node is drawn for, Rows of a repeat, below):
|
|
289
|
+
|
|
290
|
+
- `{name}`, and an argument of ICU's other types that write one value (`{name, number}`, `{name, date, short}`; `time`, `spellout`, `ordinal`, `duration`), is the value as it is given: the sample's own words, as the screen is to show them, so the tools write no number or date in a locale's way.
|
|
291
|
+
- `{name, plural, ..}` chooses one of its cases by the value read as a number (digits, with a `-` and a fraction after a `.` or without): the case `=<n>` of that number, else the case of the number's plural category in the catalog's language, by the plural rules of CLDR (`zero`, `one`, `two`, `few`, `many`, `other`), else `other`. `offset:<n>` is taken from the number before its category is found, and a `#` in the chosen case is the number less the offset. `{name, selectordinal, ..}` is read the same way, by CLDR's ordinal rules (1st, 2nd, 3rd). So `{count, plural, one {# finding} other {# findings}}` says "1 finding" and "9 findings" in English.
|
|
292
|
+
- `{name, select, ..}` chooses the case named by the value, else `other`.
|
|
293
|
+
|
|
294
|
+
Every plural, selectordinal and select has an `other`. A message may hold arguments in its cases, and a `#` is the number only in a plural's own cases. An apostrophe quotes as in ICU (its default, `DOUBLE_OPTIONAL`): `''` is one apostrophe, and one before `{` or `}`, or before `#` in a plural's case, starts words that run to the next one, so `'{ navigate }'` is the words `{ navigate }`; any other apostrophe is itself, as in `Taha'nın`.
|
|
295
|
+
|
|
296
|
+
Each locale's catalog is read by its own language's rules, its language being the locale its file is named by: an English plural with `one` and `other`, a Polish one with `few` and `many` too, and a Turkish catalog that writes `{count} bulgu` with no plural at all say the same words, and `check` does not compare their cases. A case of a category the language never gives is never chosen. A walk knows some values (its binding's samples and data) and not others, and expects what a message shows from what it knows: the case a plural's number or a select's value chooses, and where it does not know it, any of the cases. A number it does not know, a plural's (its `#`) or a `number` argument's, is any number, as the samples and ICU write one: digits, after a sign or not, grouped by threes or not (`1,234`, `1.234`, `1 234`), with a fraction or not; any other value it does not know is any text. So a group of flows named `{count, plural, one {# flow} other {# flows}}` is told from a row named "Edit this flow". `catalogWords(g, key, values, locale)` in `@delurio/cli/graph` gives the words, or a regular expression that each form matches. Decided on 30 Nov 2026 ("CLI'da çoğul desteği"), as delurio's own panel said "1 findings".
|
|
297
|
+
|
|
298
|
+
`check` holds every message a screen uses to ICU MessageFormat: one that is not, such as an argument that is not closed, a plural with no `other`, an argument named by words with a space or a sign in them (`{"a": 1}`), or a type ICU's MessageFormat does not have (the deprecated `choice`), is an error (`catalog-message-invalid`) at its key in its catalog, in each locale's catalog, and the page draws it as words with its `{name}`s filled. Each argument a message names, in every one of its cases, is held to a sample value as a placeholder is (`sample-missing`, below), and so is a plural's value that is no number. MessageFormat 2 (Unicode, stable since CLDR 47) is read when an app's own catalog is written in it.
|
|
274
299
|
|
|
275
300
|
One file per locale; `ui.yaml` names the one the page uses (`catalog`), and `locales` lists every locale its screens are written in, each in a file of its own beside that one, `<locale>.json`. A `ui.yaml` that names no catalog, or names one that is not there or is not JSON, cannot be loaded. `check` holds every locale's catalog to the same words: a key that a screen uses (a node's `name`, `text` or `value`) and that a locale's catalog lacks is an error (`catalog-key-missing`) at the key in `ui.yaml`, and so is a locale of `locales` whose file is not there. A placeholder with no sample value (`sample-missing`) is looked for in the catalog `ui.yaml` names. A locale is a BCP 47 tag, in the file name (`en.json`, `tr.json`, `pt-BR.json`) and in `locales` and `locale`.
|
|
276
301
|
|
|
@@ -409,7 +434,7 @@ notModeled: [ "..." ]
|
|
|
409
434
|
|
|
410
435
|
## 7. Binding (`kind: binding`) and tutorial (`kind: tutorial`)
|
|
411
436
|
|
|
412
|
-
A **binding** ties a flow to a running app for replay and recording: `apps` (base addresses), `browser`, `data` (JSON or dotenv sources, read again after each command, secrets masked in reports), `signIn`, `accounts`, `scenarios` (each a `given` start, the account, the page to `open`, `setup` and `teardown`, `javaScript: false` for a walk with JavaScript off, `enter`, the way the walk comes in, and `then`, how a step that leaves a variable to chance comes out), `events` (the actions that cause an event no node on screen sends), `effects` (the checks of what a step changes outside the screen), `states` (a URL glob or a text a state must show, the server `call` a step makes or a request the page makes, `storage`, what the page's storage holds, the account `as` whose screen it is, and `before` actions) and `nodes` (a locator for a node that role and name cannot find, or `before` actions such as opening a menu, in every state or by state, `count` for how many elements it finds, `near`, the element it is drawn beside, `draws`, another flow's screen it holds, or `skip` with a reason). It may `extends` a shared binding. An action is one of `goto`, `reload`, `click`, `fill`, `attach`, `key`, `waitUrl`, `waitText`, `waitResponse`, `run` (a command, with `expect`), and any action may carry `as`; a `click`, a `fill` or an `attach` may be `optional`. A locator is `frame`, `role`, `name`, `text`, `label`, `testId`, `css`, `hasText`, `within`, `nth`; `nth` takes one of what the rest finds, from 0 for the first, and a negative one counts from the end, -1 for the last (the row a step has just added); `frame` is the CSS selector of the iframe the element is drawn in, such as a payment provider's hosted form, and is looked in first; a string between slashes is a regular expression.
|
|
437
|
+
A **binding** ties a flow to a running app for replay and recording: `apps` (base addresses), `browser`, `data` (JSON or dotenv sources, read again after each command, secrets masked in reports), `signIn`, `accounts`, `scenarios` (each a `given` start, the account, the page to `open`, `setup` and `teardown`, `javaScript: false` for a walk with JavaScript off, `enter`, the way the walk comes in, and `then`, how a step that leaves a variable to chance comes out), `events` (the actions that cause an event no node on screen sends), `effects` (the checks of what a step changes outside the screen), `states` (a URL glob or a text a state must show, the server `call` a step makes or a request the page makes, `storage`, what the page's storage holds, the account `as` whose screen it is, and `before` actions) and `nodes` (a locator for a node that role and name cannot find, or `before` actions such as opening a menu, in every state or by state, `count` for how many elements it finds, `near`, the element it is drawn beside, `draws`, another flow's screen it holds, or `skip` with a reason). It may `extends` a shared binding. An action is one of `goto`, `reload`, `click`, `fill`, `attach`, `key`, `waitUrl`, `waitText`, `waitResponse`, `run` (a command, with `expect`), `WebAuthn.addCredential` (a passkey for the browser), and any action may carry `as`; a `click`, a `fill` or an `attach` may be `optional`. A locator is `frame`, `role`, `name`, `text`, `label`, `testId`, `css`, `hasText`, `within`, `nth`; `nth` takes one of what the rest finds, from 0 for the first, and a negative one counts from the end, -1 for the last (the row a step has just added); `frame` is the CSS selector of the iframe the element is drawn in, such as a payment provider's hosted form, and is looked in first; a string between slashes is a regular expression.
|
|
413
438
|
|
|
414
439
|
`schemas/binding.schema.json` gives every key a replay reads, of a flow's binding and of a navigation graph's (one with `nav`, `setup`, `personas`, `frames`, `pages` or `entries`). `check` holds `binding.yaml`, a variant of it beside it named `binding.<variant>.yaml` (`binding.noSessions.yaml`), and a shared binding named `<name>.binding.yaml`, to it, as it holds every graph file to its kind's schema (rule `schema`): a key that is not one, such as a misspelt `scenarios` that a replay would pass over, a value of the wrong kind, an action with two verbs or none, `expect` without `run`, a state's `fail` without its `call`, and a `setup` that does more than run commands. A file that `extends` another may leave out what that one gives, so the schema asks only for `kind`. What the binding names in the graph, a state, an event, a node, a context variable, an account, is held to it when a replay loads the binding: `replay --check` loads it and plans its walks with no browser and no app.
|
|
415
440
|
|
|
@@ -417,12 +442,16 @@ A **binding** ties a flow to a running app for replay and recording: `apps` (bas
|
|
|
417
442
|
|
|
418
443
|
`fill` types its value into a field. A native `<select>` cannot be typed in, so on one `fill` chooses the option whose visible text is the value; a value that no option shows fails the step, and the failure lists the options there are. `attach` gives a file input its files, in one of two forms. `attach: { <locator>, file: <path> | [<path>, ..] }` gives it fixtures, each a path relative to the binding's file and inside its folder: a path that is absolute, that climbs above the folder with `..`, that does so once its `{placeholders}` are filled in, or that is a link to a file outside the folder is refused. `attach: { <locator>, run: [<command>, <argument>, ..], fileName: <name>, mimeType: <media type> }` gives it what a helper writes to its standard output, as a file of that name: `run` is the command and its arguments, as a list, run with no shell, and the file's media type is `mimeType`, or else follows from the name's extension. Where the locator finds something other than an `<input type="file">`, such as a button drawn over a hidden input, the replay presses it and gives the files to the file chooser it opens.
|
|
419
444
|
|
|
445
|
+
`WebAuthn.addCredential: { rpId, credentialId, privateKey, userHandle, resident, signCount }` gives the browser it is done in a passkey, so that a walk can sign in by passkey (WebAuthn): a request of the app for one (`navigator.credentials.get()`) is answered by it, with no prompt. It is named after the command that does it, Add Credential of the WebDriver extension of the W3C's Web Authentication, which Chromium's DevTools Protocol calls `WebAuthn.addCredential`; the dot is part of the action's name, as it is of an event's (`FAIL.network`), so the action is written `{ WebAuthn.addCredential: { rpId, .. } }`. The first time a browser of the walk does it (the scenario's own, or an account's own browser by `as`), the replay adds a virtual authenticator to that browser: a platform authenticator (CTAP 2, transport `internal`) that keeps discoverable credentials, verifies the user, and answers each request at once, as a person who touches the sensor would. A passkey added to it stays as long as that browser does, and one with the `credentialId` of a passkey it already holds takes that one's place. `rpId` is the relying party id the passkey is for, a domain such as `id.example.test`, never an address with a scheme or a path. `credentialId` is the credential's id, `privateKey` its private key, an ECDSA P-256 key in PKCS #8, and `userHandle` the user handle it is kept for (WebAuthn's `user.id`), at most 64 bytes; each is written in base64url (RFC 4648 §5, without padding), as WebAuthn writes them. `resident`, `true` when it is left out, says that the passkey is a discoverable credential, found with no user named, which always has a user handle; `resident: false` is a credential the app names when it asks (`allowCredentials`), as a security key's is. `signCount` is the signature counter the passkey starts from; left out, it has none, and every assertion gives 0, as a passkey synced between devices does, so that a passkey added again on every walk is not taken for a copy. Each value may be a `{placeholder}` (below): the app's server must already hold the credential's public key, so the scenario's `setup` typically registers it there and writes the rest to a source of `data`. A report never shows the private key, wherever it was read from. A browser that has no virtual authenticator, such as one not built on Chromium (whose DevTools Protocol gives one, `WebAuthn.addVirtualAuthenticator` and `WebAuthn.addCredential`), fails the walk at the action, and the report says that the browser cannot hold a passkey: the walk never goes on without it, as a sign-in by passkey would then wait for a prompt that no one answers. A passkey the authenticator refuses, such as a private key that is not a P-256 key in PKCS #8, fails the step as any action that fails does. The `schema` rule refuses a `WebAuthn.addCredential` without `rpId`, `credentialId` or `privateKey`, a resident one without `userHandle`, an `rpId` with a `/`, a `:` or a space in it, a `credentialId`, `privateKey` or `userHandle` that is neither base64url nor holds a placeholder, a `userHandle` longer than 64 bytes, a `signCount` below 0, and any other key in it. Decided on 30 Nov 2026.
|
|
446
|
+
|
|
420
447
|
`as: <account>` on an action does it in that account's own browser, with its own cookies, opened and signed in the first time it is used: a step another person takes, such as a second member who approves or an invitee who accepts, is bound to actions `as` that person, and the walk goes on in the first browser after them. A state may carry `as` too: its screen is that person's, so it is checked, and its nodes are pressed, in their browser, while a state without `as` is the scenario's own account's. A state's `before: [actions]` runs when the walk reaches the state, before it is checked, such as that person opening the link an e-mail brought them. So a step another person takes after arriving by a mailed link is bound to its state: `as` the invitee, `before` opening the link. `effects: { <id>: [actions] }` checks what a step leaves outside the screen, such as an e-mail sent or a row written. `<id>` is an effect of the flow (§2) or an action of its domain (§5): the actions run after the walk takes a transition that applies that effect, or after a state that invokes that action ends with `DONE`. They are checks, typically a `run` with `expect` that reads a mail catcher's API or queries the database, and one that fails is a mismatch at that step.
|
|
421
448
|
|
|
422
|
-
`count: <number | "{data.path}">` on a node says how many elements its locator finds, as a number or a value of the binding's data: for a `repeat` node (§4), how many items it shows, and for any other node, how many there are, such as four radios and no fifth. Without it a `repeat` node shows at least one item, and more are accepted. `call: <url glob>` on a state names the server call its `invoke` makes. The replay holds the call until it has checked what the state shows, so a step in progress (its status, the controls in `disabledIn`) is seen as it is, and then lets it go; on a walk through `FAIL.<class>` it compares the call's HTTP status with the `status` of the refusals that the class stands for (§2, `failures`; §5). A state that invokes none of the flow's actions may name a `call` too: a request the page makes while the state is shown, such as one the browser sends to another server, or the one a script makes as the page loads. The replay holds it in the same way, until it has checked what the state shows, and then lets it go. `status` on it, a number or a list of numbers, is the HTTP status its answer has; an answer with another, or no such request while the walk is at the state, is a mismatch at that state. A recording holds the same calls and makes them fail as a replay does, from the same binding: a step that takes `FAIL.<class>` is filmed with its call made to fail as the state's `fail` says, and a step that shows a state whose call runs, such as a progress dialog read and its Cancel pressed while users are updated, is filmed with the call held until the step is over, then let go, or made to fail where the step gives the failure
|
|
449
|
+
`count: <number | "{data.path}">` on a node says how many elements its locator finds, as a number or a value of the binding's data: for a `repeat` node (§4), how many items it shows, and for any other node, how many there are, such as four radios and no fifth. Without it a `repeat` node shows at least one item, and more are accepted. `call: <url glob>` on a state names the server call its `invoke` makes. The replay holds the call until it has checked what the state shows, so a step in progress (its status, the controls in `disabledIn`) is seen as it is, and then lets it go; on a walk through `FAIL.<class>` it compares the call's HTTP status with the `status` of the refusals that the class stands for (§2, `failures`; §5). A state that invokes none of the flow's actions may name a `call` too: a request the page makes while the state is shown, such as one the browser sends to another server, or the one a script makes as the page loads. The replay holds it in the same way, until it has checked what the state shows, and then lets it go. `status` on it, a number or a list of numbers, is the HTTP status its answer has; an answer with another, or no such request while the walk is at the state, is a mismatch at that state. A recording holds the same calls and makes them fail as a replay does, from the same binding: a step that takes `FAIL.<class>` is filmed with its call made to fail as the state's `fail` says, and a step that shows a state whose call runs, such as a progress dialog read and its Cancel pressed while users are updated, is filmed with the call held until the step is over, then let go, or made to fail where the step gives the failure. A scenario with `javaScript: false` is walked with JavaScript off, through the pages marked `script` (§4).
|
|
423
450
|
|
|
424
451
|
A node's `before` is done before the node is pressed, such as opening the menu it sits in. It is a list of actions, done in every state that presses the node, or a map from states to such lists, where the node is reached another way in another state, such as a row's menu opened from the list and already open on the row's own page: `before: { listPage: [ { click: { role: button, name: Actions } } ], rowPage: [] }`. In a state the map names, its list is done; in a state it leaves out, nothing is. A key of the map that is not a state of the flow keeps the binding from loading.
|
|
425
452
|
|
|
453
|
+
`settle: { quiet, max, time }` says when a replay reads a screen: once the page has been still for `quiet` milliseconds (400), waiting for that at most `max` (the binding's `browser.timeout`, which it never passes). `time` says whose time the page lives in. `real`, the default, is the wall clock. `virtual` is the replay's own: between its waits the page's time follows real time, and while it waits for the page (to settle, for a node that may come late) it passes the page's idle time at once, its timers run, and no real time goes by while nothing the page draws from is in flight. A request in flight is waited for in real time. What the app does on its server (an AI's job, CI, something outside) still takes real time, so what may come late after such a step is waited for in real time. A page whose script waits for time inside one task (a loop on `performance.now()`) does not end in virtual time.
|
|
454
|
+
|
|
426
455
|
`optional: true` on a `click`, a `fill` or an `attach` says that the app may not ask for it, such as a notice shown on some visits only, closed before the walk goes on. Once the page is still (the binding's `settle`), the walk looks for the action's element once, without waiting for it further. Where it is there, the action is done as any other, and a failure of it, such as the element disabled or an option that a `<select>` does not have, fails the step. Where it is not there, the action is passed over and the walk goes on. A passed-over action is never silent: the step's report lists it as passed over, naming its locator. `optional` on any other action is an error of the schema.
|
|
427
456
|
|
|
428
457
|
`storage` on a state says what the page's storage holds when the state is checked: `session`, the tab's `sessionStorage`, and `local`, its `localStorage`, each of the origin of the page the state is shown on, in the browser whose screen it is (`as`). Each is a map from a key glob (`*` stands for any run of characters) to what the keys it matches hold. `absent` says that no key it matches is there, such as the values a page wrote into a form and was to clear (`storage: { session: { 'rehber:*': absent } }`); any other value says that a key it matches is there and that each key it matches holds that value: a text, its `{placeholders}` filled in, or a regular expression between slashes. A stored value that is the word absent itself is matched by `/^absent$/`. What does not hold is a mismatch at that state; a storage that the state does not name is not read.
|
|
@@ -435,23 +464,23 @@ The binding's `data` is read when a walk starts, after its `setup`, and again af
|
|
|
435
464
|
|
|
436
465
|
Each command a binding runs, a `run` action wherever it is or an `attach`'s helper, may run for 180 seconds. `commands: { timeout: <seconds> }` gives the binding's commands another time: more than 0 and at most 1800 (30 minutes), so that a time written in milliseconds (`180000`) is refused rather than waited for. A command that runs past its time is stopped with every process it started: they are sent SIGTERM, and whatever of them still runs 5 seconds later SIGKILL. It then fails as a command that exits with an error does, and the report says that it ran over its time. Work that takes longer, such as building the app or loading a whole copy of a database, belongs before the replay, not in a walk.
|
|
437
466
|
|
|
438
|
-
A `{placeholder}` in a binding's string, such as an address, a value an action types or a locator's name, is filled from the first of these that gives it: `{walk}`, the walk's own id; a variable of the scenario's `vars`, or a field of its account; an app of `apps`; a value of `data` (`{<source>.<path>}`); and `{locale}` and `{lang}`, the locale the browser runs in and its language alone (`tr-TR` and `tr`), which is the binding's `browser.locale`, the replay's `--locale`, or the language of the tutorial a recording is told in (below). So one `open: '{app}/{lang}/settings/users'` serves every language a flow is replayed or filmed in. A placeholder that none of these gives fails the walk at the action that uses it, and so does `{locale}` or `{lang}` where no locale is given
|
|
467
|
+
A `{placeholder}` in a binding's string, such as an address, a value an action types or a locator's name, is filled from the first of these that gives it: `{walk}`, the walk's own id; a variable of the scenario's `vars`, or a field of its account; an app of `apps`; a value of `data` (`{<source>.<path>}`); and `{locale}` and `{lang}`, the locale the browser runs in and its language alone (`tr-TR` and `tr`), which is the binding's `browser.locale`, the replay's `--locale`, or the language of the tutorial a recording is told in (below). So one `open: '{app}/{lang}/settings/users'` serves every language a flow is replayed or filmed in. A placeholder that none of these gives fails the walk at the action that uses it, and so does `{locale}` or `{lang}` where no locale is given.
|
|
439
468
|
|
|
440
|
-
A walk reads every screen in one language: the binding's `browser.locale`, a BCP 47 tag the browser is set to, or the replay's `--locale`. Each screen is checked against the flow's catalog of that language (§4), found by the whole tag first and then by its language alone: `tr-TR` reads `catalog/tr.json`, and `pt-BR` reads `pt-BR.json` before `pt.json`.
|
|
469
|
+
A walk reads every screen in one language: the binding's `browser.locale`, a BCP 47 tag the browser is set to, or the replay's `--locale`. Each screen is checked against the flow's catalog of that language (§4), found by the whole tag first and then by its language alone: `tr-TR` reads `catalog/tr.json`, and `pt-BR` reads `pt-BR.json` before `pt.json`. Where the flow has no catalog of that locale, the app shows its pages in a language it has (a player, say, plays a video in the first language it was made in, and says so), and each screen is checked against the flow's catalog of the language the page itself is in: the `lang` of its root element (`<html lang>`), found the same way. A page with no `lang`, or in a language the flow has no catalog of either, is checked against the catalog `ui.yaml` names, and the report says so. A flow the walk enters (`enter`), a flow a node draws (`draws`) and a navigation graph are read in the walk's language, and have no such fallback: a locale one of them has no catalog of is refused. `--locale` may be given more than once: the walks are made in each locale, each with a report of its own. A walk keeps to its language: after a step that switches the app's language, the next screens are still read in the walk's; a walk read in its page's language reads the next screens in the language the page is in then. Without either, the screens are read against the catalog `ui.yaml` names. A recording runs the browser in the language its tutorial is told in (the tutorial's `locale`), as `--locale` runs a walk, and finds the app's nodes by the flow's catalog of that language, so that a tutorial told in English does not look for "Apply" on a page opened in Turkish. Where the binding's `browser.locale` is of the same language, it is kept, with its region; where the flow has no catalog in the tutorial's language, the app is filmed in the binding's locale, and the video tool says so. That a walk falls back on its page's language was decided on 30 Nov 2026.
|
|
441
470
|
|
|
442
471
|
`browser.ignoreHTTPSErrors: true` opens a page served with a certificate no authority signed, such as an app on a self-signed `https` origin in development; without it, such a page fails the walk.
|
|
443
472
|
|
|
444
473
|
What a person types, or what a scenario's `setup` put in place, the graph may leave to chance (`havoc`, §2), while on the app it is what the scenario made it. So a walk keeps, through a `havoc`, the value its scenario's `given` gives each variable that starts from any value: a refusal is walked from a scenario that types the invalid value, and a way that needs the value changed there is not bound from that scenario (it is listed as not bound), rather than walked from one that set up the opposite. A variable that starts from a fixed value takes the values the `havoc` allows, as in the graph.
|
|
445
474
|
|
|
446
|
-
A scenario's `then` says how a step that leaves a variable to chance comes out on its walks, where the app decides it, such as which step of a guide is its last
|
|
475
|
+
A scenario's `then` says how a step that leaves a variable to chance comes out on its walks, where the app decides it, such as which step of a guide is its last, or what a dialog starts with each time it opens. It is a map from an effect whose `havoc` (§2) leaves a variable to chance, to one of two forms. A list, `then: { <effect>: [ { <variable>: <value>, .. }, .. ] }`, is read in order, one entry each time the walk takes a transition that applies that effect: with `then: { next: [ { lastStep: false }, { lastStep: true } ] }`, the first `next` leaves the guide short of its last step and the second brings it there. One entry, a map in place of the list, `then: { <effect>: { <variable>: <value>, .. } }`, holds every time the walk applies the effect, however often: with `then: { dialogOpens: { movingOff: false } }`, a source dialog opens on the source the project has each time it opens, the second time as the first. So it says what no list can of a step that a walk takes as often as its ways need, such as a dialog opened again after a refusal. An effect has one form or the other, as a key has one value. An entry gives values only to variables that the effect's `havoc` lists, each one of its values, and through that `havoc` those variables take them; a variable the entry leaves out, and every variable once a list has run out, keeps its value, as above. So a path is walked from the scenario only where each of its transitions agrees with the values the scenario gives, and one that needs other values is not bound from it, with that reason. A `then` that names an effect the flow does not have, a variable its `havoc` does not list, or a value that is not one of the variable's, keeps the binding from loading, and `check` gives an error (`binding-then`) at it in each binding beside the flow that binds it (`flow`). `thenEntry`, `thenEntries` and `thenProblems` in `@delurio/cli/graph` read a scenario's `then` as a replay does. The entry that holds every time was decided on 30 Nov 2026 ("Her açılışta geçen then").
|
|
447
476
|
|
|
448
477
|
Where several nodes on the screen send the event a step takes, such as two radios of one choice, the binding's `events.<EVENT>` says which is pressed, when it gives one; otherwise the first of them in `ui.yaml` that the state shows enabled is pressed.
|
|
449
478
|
|
|
450
|
-
The **replay** walks a flow on the app through its binding and checks each state it stops in: the nodes the graph shows there (their role, name and text, whether they are disabled, which one has the focus, what a field holds and whether a control is checked, §4), the state's `url` and `text`, and the `effects` of the step that led there. `replay <flow dir> --bind <binding>` walks the main story (§2). `--to <state>` walks the shortest way to that state that the binding can drive. `--cover states` walks paths that together pass every reachable state, and `--cover transitions` paths that together take every reachable transition, from the binding's scenarios and through the steps it can drive (§2, `cover`). Under `--cover` every scenario of the binding is walked at least once. A path is walked from the first scenario, in the order of the file, that starts where it starts. A scenario that no path is walked from, as it starts where another does (the same `given`, with other data or another account) or reaches nothing the others do not, gets one walk of its own: of the paths that `cover` gives from its start alone, the one that covers the most, or its first screen when it can drive no step. That walk covers nothing new, and its id is that path's with the scenario's name. So one binding holds every scenario of a flow. `--scenario <name>`, given once or more, keeps the walks to those scenarios of the binding, with the other choices as they are (`--cover`, `--to`); a name the binding does not have is refused. The main story is walked from the scenario that starts where it starts, and when none of those given does, it is listed as not bound, with that reason. `--no-js` walks the pages marked `script` a second time with JavaScript off: those marked `optional` with their actions, those marked `actions` read only, their actions absent or disabled with a reason (§4). `--absent` also checks that a node the graph does not show in a state is not visible there; without it, the replay checks only what the graph shows, and a node it leaves out of a state may be there or not. An exit may open another page of the same frame: another address, not only another `#fragment`, or a document loaded anew since the screen checked before it. There `--absent` leaves out what that page draws as well, and the step's report names what it left out: the frame's chrome, the nodes that the screen before showed outside every page node it showed (a menu, a bar, a sidebar beside the page's main content), and a node found by a landmark's role alone, such as a bare `role: main`, which matches the next page's own. A node of the flow's page that is still there, its heading, a field, its dialog, or a landmark found by its name, is still a mismatch, and on an exit that stays on the page nothing is left out. A state or a node that only missing needs are drawn as is planned, not built: every walk leaves it out, and the replay lists it with those needs (§13).
|
|
479
|
+
The **replay** walks a flow on the app through its binding and checks each state it stops in: the nodes the graph shows there (their role, name and text, whether they are disabled, which one has the focus, what a field holds and whether a control is checked, §4), the state's `url` and `text`, and the `effects` of the step that led there. `replay <flow dir> --bind <binding>` walks the main story (§2). `--to <state>` walks the shortest way to that state that the binding can drive. `--cover states` walks paths that together pass every reachable state, and `--cover transitions` paths that together take every reachable transition, from the binding's scenarios and through the steps it can drive (§2, `cover`). Under `--cover` every scenario of the binding is walked at least once. A path is walked from the first scenario, in the order of the file, that starts where it starts. A scenario that no path is walked from, as it starts where another does (the same `given`, with other data or another account) or reaches nothing the others do not, gets one walk of its own: of the paths that `cover` gives from its start alone, the one that covers the most, or its first screen when it can drive no step. That walk covers nothing new, and its id is that path's with the scenario's name. So one binding holds every scenario of a flow. `--scenario <name>`, given once or more, keeps the walks to those scenarios of the binding, with the other choices as they are (`--cover`, `--to`); a name the binding does not have is refused. The main story is walked from the scenario that starts where it starts, and when none of those given does, it is listed as not bound, with that reason. `--no-js` walks the pages marked `script` a second time with JavaScript off: those marked `optional` with their actions, those marked `actions` read only, their actions absent or disabled with a reason (§4). `--absent` also checks that a node the graph does not show in a state is not visible there; without it, the replay checks only what the graph shows, and a node it leaves out of a state may be there or not. A node that a modal dialog makes absent (§4) is not looked for either, and under `--absent` it is checked to be out of the accessibility tree, inert or not there, rather than out of sight. An exit may open another page of the same frame: another address, not only another `#fragment`, or a document loaded anew since the screen checked before it. There `--absent` leaves out what that page draws as well, and the step's report names what it left out: the frame's chrome, the nodes that the screen before showed outside every page node it showed (a menu, a bar, a sidebar beside the page's main content), and a node found by a landmark's role alone, such as a bare `role: main`, which matches the next page's own. A node of the flow's page that is still there, its heading, a field, its dialog, or a landmark found by its name, is still a mismatch, and on an exit that stays on the page nothing is left out. A state or a node that only missing needs are drawn as is planned, not built: every walk leaves it out, and the replay lists it with those needs (§13).
|
|
451
480
|
|
|
452
481
|
`enter` says how a scenario's walk comes into the flow, after the scenario opens its page (`open`). `enter: { nav: <nav graph dir>, bind: <nav binding>, entry: <from>-><to> }` presses that entry of a navigation graph (§6), found as its own replay finds it (below), its menu opened first, and the address must become the route of the entry's page; `bind` may be left out when the entry's label alone finds it. `enter: { flow: <graph dir>, bind: <its binding>, given: { .. }, event: <EVENT> }` walks another flow from `given`, by the shortest way its binding can drive, to the transition on `<EVENT>` whose `starts` names this flow (§2, Several flows), and checks its screens on the way; what that `starts` hands over must be this scenario's own `given`. The paths are relative to the binding's file. On arrival the focus must be on the `initialFocus` of the entered flow's first screen, past its rules and server calls, and the flow's own walk then goes on from its initial state, so that every walk of the flow can begin where a person comes in.
|
|
453
482
|
|
|
454
|
-
A binding may tie a navigation graph (§6) to the app instead of a flow. It names the graph with `nav: <id>` in place of `flow`, has the keys a flow's binding has for the app (`root`, `commands`, `extends`, `apps`, `browser`, `data`, `signIn`, `accounts`), and gives `samples` for the `:params` of the routes; a page is opened at the first app and its route. Without `personas`, each persona of the graph signs in as the account named like it. `personas.<persona>: { as, setup }` lets one account stand for several personas: `as` names the account, and `setup`, commands (`run`) done before that persona's visits, gives the account the persona's facts, such as its role. A `setup` at the top, also commands only, runs once before the first persona, for instance to sign the people up. The other keys say where the replay finds what the graph names, and each may be left out. `frames.<frame>` gives `find`, the frame's chrome, where its `menu` entries are; `page`, where a page of the frame draws its own entries (`link`, `button`); and `user` and `picker`, each `{ open: [actions], find }`: what opens the person's menu or the switcher, and the open menu, where their entries are found. `pages.<page>` gives `refusal`, a locator for the words in which the page says no (the graph says them in prose, so a refusal is checked only with one); `shows`, what proves the page opened, absent when it refuses; `samples`, the `:params` of its route for this page, over the binding's own, so that two pages on one route open at items of their own (a revision in review and one decided); or `skip` with a reason. `entries.<from>-><to>` is keyed by the entry's ends, as a code comment cites it (`N:<from>-><to>`), `<from>` being a page or `frame:<frame>`, followed by its `how` or its label key where two entries share their ends (`frame:workspace->start picker`). It gives a locator for the entry's element, where its label is not its accessible name or the entry needs an item (`data: true`); `skip` with a reason; or `follow`. Without a locator in the binding, an entry is found by its label, as the accessible name of what its `how` draws: a link (`menu`, `link`), a button (`button`) or a menu item (`user`, `picker`), in the frame's `find`, its `page` or the open menu.
|
|
483
|
+
A binding may tie a navigation graph (§6) to the app instead of a flow. It names the graph with `nav: <id>` in place of `flow`, has the keys a flow's binding has for the app (`root`, `commands`, `extends`, `apps`, `browser`, `data`, `signIn`, `accounts`), and gives `samples` for the `:params` of the routes; a page is opened at the first app and its route. Without `personas`, each persona of the graph signs in as the account named like it. `personas.<persona>: { as, setup }` lets one account stand for several personas: `as` names the account, and `setup`, commands (`run`) done before that persona's visits, gives the account the persona's facts, such as its role. A `setup` at the top, also commands only, runs once before the first persona, for instance to sign the people up. The other keys say where the replay finds what the graph names, and each may be left out. `frames.<frame>` gives `find`, the frame's chrome, where its `menu` entries are; `page`, where a page of the frame draws its own entries (`link`, `button`); and `user` and `picker`, each `{ open: [actions], find }`: what opens the person's menu or the switcher, and the open menu, where their entries are found. `pages.<page>` gives `refusal`, a locator for the words in which the page says no (the graph says them in prose, so a refusal is checked only with one); `shows`, what proves the page opened, absent when it refuses; `samples`, the `:params` of its route for this page, over the binding's own, so that two pages on one route open at items of their own (a revision in review and one decided); `serial`, the personas or accounts that open the page one at a time while their other visits go at once, for a page that holds something for one person at a time, such as an editor's lock: a visit that opens the page, or may follow an entry to it, waits until the persona before has left it; or `skip` with a reason. Proposed 30 Nov 2026 and approved 30 Nov 2026. `entries.<from>-><to>` is keyed by the entry's ends, as a code comment cites it (`N:<from>-><to>`), `<from>` being a page or `frame:<frame>`, followed by its `how` or its label key where two entries share their ends (`frame:workspace->start picker`). It gives a locator for the entry's element, where its label is not its accessible name or the entry needs an item (`data: true`); `skip` with a reason; or `follow`. Without a locator in the binding, an entry is found by its label, as the accessible name of what its `how` draws: a link (`menu`, `link`), a button (`button`) or a menu item (`user`, `picker`), in the frame's `find`, its `page` or the open menu.
|
|
455
484
|
|
|
456
485
|
`replay <nav graph dir> --bind <binding>` opens every page the binding can open, as every persona it binds, and checks what the graph says that persona meets there: the page stays at the address it was opened at, and it opens, or refuses where its `opensFor` does not hold (its `refusal` shown and its `shows` not); each bound frame's chrome is there on the frame's pages and absent on the others; and each entry of the page or of its frame is shown where its `when` holds for the persona and absent where it does not. An entry that needs an item is checked only where the binding gives its locator. `--persona <id>` and `--page <id>`, each given once or more, keep the walk to those personas and pages. `--follow` also takes each entry shown, once per persona, and checks that it lands on its page's route; a `button` acts, so it is taken only with `follow: true`, and `follow: false` keeps an entry from being taken at all (one that signs out or deletes). `--no-setup` skips the top-level `setup` and uses the people of the last run again. `--locale`, once or more, reads the pages in that language: the entries' labels from the navigation graph's catalog of it, found as a flow's is.
|
|
457
486
|
|
|
@@ -465,17 +494,17 @@ A **tutorial** is written against a flow: `title`, `audience`, `locale`, `appNam
|
|
|
465
494
|
|
|
466
495
|
`row: <n>` on a step that presses a repeat node (§4) says which of the node's sample rows it presses, counted from 1: `{ press: option, row: 2 }` presses the second option. Of the cases the press can take, the step takes the one in which each variable that the transition's effects set from the row (`row.<field>`) has that row's value. `check` stops the tutorial at that step (`tutorial-mismatch`) when `row` is not a whole number from 1, the step presses no node, the node has no `repeat`, the samples give it no rows or fewer than `n`, the row lacks a field the effects read, or no case of the press has the row's value, such as a value its variable does not have. A press on a repeat node without `row` takes the model's first case, as a step without `then` does.
|
|
467
496
|
|
|
468
|
-
A press, or an event a step gives with `after`, may lead into server steps, states with no screen, which pass on their own along their normal way (a transition with no event, then `DONE`) to the next screen. A state that moves on at once (`always`, §2) is passed in the same way, along the first of its transitions whose guard holds, whatever it shows, such as a form whose fields are checked while its Save is still drawn: the flow is never left there, so it is no screen a step shows
|
|
497
|
+
A press, or an event a step gives with `after`, may lead into server steps, states with no screen, which pass on their own along their normal way (a transition with no event, then `DONE`) to the next screen. A state that moves on at once (`always`, §2) is passed in the same way, along the first of its transitions whose guard holds, whatever it shows, such as a form whose fields are checked while its Save is still drawn: the flow is never left there, so it is no screen a step shows. Where the event the step gives next with `after` (its first, after the press; the next in its list, after one of its events) is one that a server step on the way handles another way than its normal one, such as a failure (`FAIL.<class>`, §2) or a refusal, the walk may stop at that server step and take it there: `{ press: send, after: FAIL.network }` shows the screen a send that got no answer leads to, where the send's normal way ends on the screen that says it was sent. An opening card's (`intro`) first event is taken in the same way at the server steps the flow passes from its start, so a failure that comes before the first screen, such as a page whose data cannot be loaded, is given there. Of the places that handle the event, the screen the way ends on and then each server step on the way, the walk takes the first from which the step's events lead to the state the next step shows (its `show` or its `end`): where two server steps in a row each handle a failure, each to a screen of its own, such as a page that reads a registry and then a saved value, the tutorial shows either. Where none of them leads there, or the next step names no state, the event is taken at the screen when it handles it, else at the first server step that does. An event that neither the screen nor a server step on the way handles stops the tutorial (`tutorial-mismatch`). The video walks the flow the same way.
|
|
469
498
|
|
|
470
|
-
`cut: { state, scenario, given }` says which situation a cut jumps to, where its state alone leaves it open: `scenario`, the binding's scenario a recording reaches it through, and `given`, a value for each variable it names, such as `cut: { state: editing, given: { locked: false } }` for a user who is not locked. The step's words and checks are planned from that situation, and a recording films it there, so the two agree. `cut: <state>` takes the first situation the flow reaches in the state, with the nodes the step reveals shown, and a recording plans it where its binding reaches the state
|
|
499
|
+
`cut: { state, scenario, given }` says which situation a cut jumps to, where its state alone leaves it open: `scenario`, the binding's scenario a recording reaches it through, and `given`, a value for each variable it names, such as `cut: { state: editing, given: { locked: false } }` for a user who is not locked. The step's words and checks are planned from that situation, and a recording films it there, so the two agree. `cut: <state>` takes the first situation the flow reaches in the state, with the nodes the step reveals shown, and a recording plans it where its binding reaches the state.
|
|
471
500
|
|
|
472
501
|
`at: <seconds>` on a step that presses a node says when the press comes, counted from the step's start. Without it, on a screen that shows a dialog (a node whose role is `dialog` or `alertdialog`, §4), the press comes once the step's `say` has been said, so that the dialog is read before the press closes it; elsewhere it comes early in the step. A step on a dialog's screen that focuses nothing shows the whole dialog: its title, its words and its buttons. Before a video is made, the video tool warns, on the narration's timings, of a dialog on screen for under 2 seconds, of one that no step focuses or shows whole, and of a press that closes a dialog while its step is still being said.
|
|
473
502
|
|
|
474
503
|
`stage` says what the video shows: the flow's screens (`screen`, the default), or its diagram (`diagram`), for a flow with no screens, such as two programs talking or a job in the background. On the diagram the camera goes from state to state, and the tutorial's own way is drawn as the story, whether or not it is the flow's `main` story; the diagram holds every transition, failures included. No state is passed on its own there: `show <state>` and `end <state>` walk the flow to their state along its normal way (a transition with no event, then `DONE`) and stop the tutorial when that way does not reach it, and every other event is given with `after`. `press`, `reveal` and `focus` point at nodes a diagram does not have, and stop it too. An `end` on the diagram needs no `card`; one it has is shown after the ending.
|
|
475
504
|
|
|
476
|
-
`check` reads the `tutorial.yaml` beside a flow and replays it on the flow as the video does, from the start its `scenario` gives: a value of its list for each variable that starts from any value, and none that differs from a fixed `initial`. On the screens, a step that shows no screen, or a state that moves on at once (above), passes on its own along its normal way (a transition with no event, then `DONE`), and one with no such way waits for an event given with `after`; on the diagram, `show` and `end` walk as above. A tutorial that no longer matches its flow is an error (`tutorial-mismatch`) that fails `--strict`, at the step where it stops: its `flow` is not the flow beside it; a step names a state, a node, an event, a variable or a value the graph does not have, or a `{word}` that is neither a sample value nor a node with visible text; `show` names a state the flow is not in; `cut` is neither a state nor `{ state, scenario, given }`, or names a state no reachable situation is in, with the values its `given` names and the nodes it `reveal`s shown (a `scenario` is the binding's, which `check` does not read: it narrows nothing there); `press` names a node the state does not show, or disables, or that sends no event the state handles; `after` names an event the state does not handle, nor a server step the step passes (above); `reveal` or `focus` names a node the step's screen does not show, or `focus` one shown only `when` something holds and not revealed; `end` names a state the flow is not in, or, given no state, the flow is not at an exit; or a `then` matches no case of its step. Every name is looked for on every step, and the steps are replayed once all are found.
|
|
505
|
+
`check` reads the `tutorial.yaml` beside a flow and replays it on the flow as the video does, from the start its `scenario` gives: a value of its list for each variable that starts from any value, and none that differs from a fixed `initial`. On the screens, a step that shows no screen, or a state that moves on at once (above), passes on its own along its normal way (a transition with no event, then `DONE`), and one with no such way waits for an event given with `after`; on the diagram, `show` and `end` walk as above. A tutorial that no longer matches its flow is an error (`tutorial-mismatch`) that fails `--strict`, at the step where it stops: its `flow` is not the flow beside it; a step names a state, a node, an event, a variable or a value the graph does not have, or a `{word}` that is neither a sample value nor a node with visible text; `show` names a state the flow is not in; `cut` is neither a state nor `{ state, scenario, given }`, or names a state no reachable situation is in, with the values its `given` names and the nodes it `reveal`s shown (a `scenario` is the binding's, which `check` does not read: it narrows nothing there); `press` names a node the state does not show, or disables, or shows read-only, or that a modal dialog makes absent there (§4), or that sends no event the state handles; `after` names an event the state does not handle, nor a server step the step passes (above); `reveal` or `focus` names a node the step's screen does not show, or `focus` one shown only `when` something holds and not revealed; `end` names a state the flow is not in, or, given no state, the flow is not at an exit; or a `then` matches no case of its step. Every name is looked for on every step, and the steps are replayed once all are found.
|
|
477
506
|
|
|
478
|
-
A tutorial planned from the graph, such as the video tool's tutorials that together film every screen of a flow, says the graph's own words: the flow's `title`, a state's `title`, a transition's `say`. A `{name}` there is said as its sample value (§4, `samples`), or else as the bare name, such as an address in a title (`the user's form opens at form/{pk}`), and it no longer keeps the flow from being planned. `check` warns of each such name that neither a sample value nor a node gives (`prose-placeholder`), at the title or the transition that says it; the warning fails nothing, `--strict` included
|
|
507
|
+
A tutorial planned from the graph, such as the video tool's tutorials that together film every screen of a flow, says the graph's own words: the flow's `title`, a state's `title`, a transition's `say`. A `{name}` there is said as its sample value (§4, `samples`), or else as the bare name, such as an address in a title (`the user's form opens at form/{pk}`), and it no longer keeps the flow from being planned. `check` warns of each such name that neither a sample value nor a node gives (`prose-placeholder`), at the title or the transition that says it; the warning fails nothing, `--strict` included.
|
|
479
508
|
|
|
480
509
|
A video is an MP4 file. Its captions are WebVTT (`tutorial.vtt`, what an HTML `<track>` plays, with `tutorial.srt` beside it), and its chapters a WebVTT chapters track (`chapters.vtt`). Every video delurio publishes is marked as AI-made in three ways, none of which can be turned off: a first card that says the whole video is made with AI, an imperceptible watermark in the sound and the picture, and signed, time-stamped provenance metadata (C2PA). The watermark and the metadata are the machine-readable marking that Art. 50(2) of the EU AI Act asks of a system that generates synthetic audio and video, and the Commission's Code of Practice of 10 June 2026 describes. The disclosure is there because every voice is made from real people's recordings and may resemble one of them, which Art. 50(4) treats as a deep fake to disclose; a catalogue voice is no different from a cloned one in that, and delurio cannot tell which listener would recognise which voice (Taha, 24 Oct 2026: "Klon olmayan sesler de gerçek insan sesinden"). It opens the video, since Art. 50(5) asks for it at the latest at the first exposure, and no label is burnt into the picture after it (Taha, 25 Oct 2026: "en başta 'videonun tamamı' diye belirtip yazsak yetmez mi"); a clip cut from the middle loses the card but keeps the watermark and the metadata. A video's maker may draw its own mark in a corner of the picture, for the whole video. That mark is not the AI label, and neither is a draft's stamp (below): the first card is the disclosure, and nothing but that mark and the stamp is burnt into the picture. A lawyer is to confirm this reading. delurio's video tool adds both to every video it makes; the certificate that signs the metadata is not on the C2PA trust list yet.
|
|
481
510
|
|
package/js/graph.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { Exploration, Model } from './model.js';
|
|
1
2
|
export type Scalar = string | number | boolean;
|
|
2
3
|
export interface Transition {
|
|
3
4
|
target: string;
|
|
@@ -109,6 +110,10 @@ export interface UiNode {
|
|
|
109
110
|
/** How the node looks, never all it says (SPEC.md §4): a fixed tone, or each tone with the expression over the context under which the node takes it; the first that holds wins. */
|
|
110
111
|
tone?: Tone | Partial<Record<Tone, string>>;
|
|
111
112
|
duringStep?: boolean;
|
|
113
|
+
/** On a field: the states where it is shown read-only, keeping its value and its focus and taking no input (SPEC.md §4). */
|
|
114
|
+
readOnlyIn?: string[];
|
|
115
|
+
/** On a dialog: false where it leaves the page behind it as it is; every other dialog is modal (SPEC.md §4). */
|
|
116
|
+
modal?: boolean;
|
|
112
117
|
}
|
|
113
118
|
/** The tones a node may take (SPEC.md §4). */
|
|
114
119
|
export type Tone = 'neutral' | 'info' | 'success' | 'warning' | 'danger';
|
|
@@ -122,6 +127,25 @@ export interface UiEdge {
|
|
|
122
127
|
export declare const OPENER = "opener";
|
|
123
128
|
export declare const CHECKABLE: readonly ['checkbox', 'menuitemcheckbox', 'menuitemradio', 'option', 'radio', 'switch'];
|
|
124
129
|
export declare const isDialog: (n: UiNode | undefined) => boolean;
|
|
130
|
+
/** A dialog that makes the rest of the page absent while it is shown: every dialog but one that says `modal: false` (SPEC.md §4). */
|
|
131
|
+
export declare const isModal: (n: UiNode | undefined) => boolean;
|
|
132
|
+
/** A graph's modal dialogs and the nodes outside them (SPEC.md §4, A modal dialog). */
|
|
133
|
+
export interface ModalDialogs {
|
|
134
|
+
/** The modal dialogs, in the order of ui.yaml. */
|
|
135
|
+
dialogs: string[];
|
|
136
|
+
/** Each node that some situation shows with no modal dialog shown: the nodes a modal dialog makes absent where it is shown. */
|
|
137
|
+
outside: string[];
|
|
138
|
+
}
|
|
139
|
+
/**
|
|
140
|
+
* A graph's modal dialogs and the nodes outside them, over the situations of `ex` (an exploration of `m`) where it is
|
|
141
|
+
* given, else over every situation the flow reaches, as `check` reads it.
|
|
142
|
+
*/
|
|
143
|
+
export declare function modalDialogs(g: Graph, m: Model, ex?: Exploration | null): ModalDialogs;
|
|
144
|
+
/**
|
|
145
|
+
* The modal dialog a situation shows (the first in ui.yaml), and the nodes of `modal.outside` it makes absent there:
|
|
146
|
+
* those the state shows by `in` and `unless`. Null where the situation shows no modal dialog.
|
|
147
|
+
*/
|
|
148
|
+
export declare function modalAbsent(g: Graph, m: Model, modal: ModalDialogs, state: string, ctx: Scalar[]): { dialog: string; absent: string[] } | null;
|
|
125
149
|
export interface Ui {
|
|
126
150
|
absent?: boolean;
|
|
127
151
|
id: string;
|
|
@@ -149,6 +173,8 @@ export interface Graph {
|
|
|
149
173
|
flow: Flow;
|
|
150
174
|
ui: Ui;
|
|
151
175
|
catalog: Record<string, string>;
|
|
176
|
+
/** The language of `catalog`, whose plural rules its messages read: left out for the catalog ui.yaml names, whose file is named by its locale; given where a caller lends the graph another locale's catalog. */
|
|
177
|
+
locale?: string;
|
|
152
178
|
}
|
|
153
179
|
export interface ErrorPlace {
|
|
154
180
|
file: string;
|
|
@@ -167,11 +193,26 @@ export declare function titleOf(flow: Flow, state: string): string;
|
|
|
167
193
|
export declare function shownIn(n: UiNode, state: string): boolean;
|
|
168
194
|
export type Sensitivity = 'credential' | 'personal' | 'internal';
|
|
169
195
|
export declare function maskedNodes(g: Graph, mask?: readonly Sensitivity[]): string[];
|
|
196
|
+
/**
|
|
197
|
+
* What a catalog key's message shows with the values a walk has (SPEC.md §4, Catalog), read as ICU MessageFormat:
|
|
198
|
+
* a string where every argument it shows has a value, else a RegExp that each form it may take matches (a plural or a
|
|
199
|
+
* select whose value is not given, any of its cases; a number not given, a plural's or a `number` argument's, any
|
|
200
|
+
* number; any other value not given, any text); null where the catalog has no such message. `locale`, whose plural rules it reads, is `g.locale`, else the name of the catalog's file.
|
|
201
|
+
*/
|
|
202
|
+
/** A scenario's `then` (SPEC.md §7): for each effect, a list of entries read in order, or one entry that holds every time. */
|
|
203
|
+
export type ScenarioThen = Record<string, Array<Record<string, Scalar | null>> | Record<string, Scalar | null>>;
|
|
204
|
+
/** The entry of a scenario's `then` for the time a walk applies `effect` after `before` times: a list's next entry, none once it has run out, or the one entry that holds every time. */
|
|
205
|
+
export declare function thenEntry(then: ScenarioThen | undefined | null, effect: string, before: number): Record<string, Scalar | null> | null;
|
|
206
|
+
/** Every entry a scenario's `then` gives an effect, in order. */
|
|
207
|
+
export declare function thenEntries(then: ScenarioThen | undefined | null, effect: string): Array<Record<string, Scalar | null>>;
|
|
208
|
+
/** What a scenario's `then` names that the graph's flow does not have: an effect, a variable the effect's havoc does not list, a value the variable does not have. Its shape is the binding schema's to say. */
|
|
209
|
+
export declare function thenProblems(g: Graph, then: ScenarioThen): Array<{ path: string[]; message: string }>;
|
|
210
|
+
export declare function catalogWords(g: Graph, key: string, values?: Readonly<Record<string, Scalar>>, locale?: string): string | RegExp | null;
|
|
170
211
|
export interface FocusAfter {
|
|
171
212
|
node: string;
|
|
172
213
|
by: 'returnsFocus' | 'initialFocus' | 'focus';
|
|
173
214
|
from?: string;
|
|
174
215
|
}
|
|
175
|
-
export declare function focusAfter(ui: Ui, from: string | null, to: string, pressed?: string): FocusAfter | null;
|
|
216
|
+
export declare function focusAfter(ui: Ui, from: string | null, to: string, pressed?: string, gone?: readonly string[]): FocusAfter | null;
|
|
176
217
|
export declare function alternatives(spec: TransitionSpec): Transition[];
|
|
177
218
|
export declare function load(dir: string, read?: (file: string) => string, exists?: (file: string) => boolean): Graph;
|
package/js/graph.js
CHANGED
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
// the readers of its parts. The checker is the Rust one (crates/delurio-core/src/graph.rs), run in the addon.
|
|
3
3
|
import { existsSync, readFileSync } from 'node:fs';
|
|
4
4
|
import { join } from 'node:path';
|
|
5
|
-
import { GraphError, Trap, call, json, native, nativeGraph, nativeValue, placed, rememberGraph, warnings } from './internal.js';
|
|
5
|
+
import { GraphError, Trap, call, encode, json, native, nativeExploration, nativeGraph, nativeModel, nativeValue, placed, rememberGraph, warnings } from './internal.js';
|
|
6
6
|
|
|
7
7
|
export { GraphError, placed };
|
|
8
8
|
|
|
@@ -51,8 +51,60 @@ export function maskedNodes(g, mask = ['credential']) {
|
|
|
51
51
|
return native.maskedNodesOf(nativeGraph(g), [...mask]);
|
|
52
52
|
}
|
|
53
53
|
|
|
54
|
-
|
|
55
|
-
|
|
54
|
+
// What a catalog key's message shows with the values a walk has (SPEC.md §4, Catalog), for a replay to expect of a node's
|
|
55
|
+
// words and name: a string where every argument it shows has a value, else a RegExp that each form it may take matches
|
|
56
|
+
// (a plural or a select whose value is not given, any of its cases; a number not given, a plural's or a `number`
|
|
57
|
+
// argument's, any number; any other value not given, any text); null where
|
|
58
|
+
// the catalog has no such message. `values` maps an argument's name to its value; `locale`, the catalog's language,
|
|
59
|
+
// whose plural rules it reads, is `g.locale`, else the name of the catalog's file.
|
|
60
|
+
export function catalogWords(g, key, values = {}, locale = undefined) {
|
|
61
|
+
if (values === null || typeof values !== 'object' || Array.isArray(values)) throw new TypeError('catalogWords: values is a map of names to values');
|
|
62
|
+
const out = JSON.parse(native.catalogWordsOf(nativeGraph(g), String(key), json(values), locale === undefined || locale === null ? undefined : String(locale)));
|
|
63
|
+
if (out === null) return null;
|
|
64
|
+
return out.text !== undefined ? out.text : new RegExp(out.pattern);
|
|
65
|
+
}
|
|
66
|
+
|
|
67
|
+
// A scenario's `then` (SPEC.md §7), as a replay reads it: the entry for the time a walk applies `effect` after it has
|
|
68
|
+
// applied it `before` times (a list's next entry, none once it has run out, or the one entry that holds every time), or
|
|
69
|
+
// null; every entry it gives the effect; and what it names that the graph's flow does not have, each as { path, message }.
|
|
70
|
+
export function thenEntry(then, effect, before) {
|
|
71
|
+
if (!Number.isInteger(before) || before < 0) throw new TypeError('thenEntry: before is how many times the effect was applied before');
|
|
72
|
+
return JSON.parse(native.thenEntryOf(then === undefined || then === null ? undefined : json(then), String(effect), before));
|
|
73
|
+
}
|
|
74
|
+
|
|
75
|
+
export function thenEntries(then, effect) {
|
|
76
|
+
return JSON.parse(native.thenEntriesOf(then === undefined || then === null ? undefined : json(then), String(effect)));
|
|
77
|
+
}
|
|
78
|
+
|
|
79
|
+
export function thenProblems(g, then) {
|
|
80
|
+
return JSON.parse(native.thenProblemsOf(nativeGraph(g), json(then ?? null)));
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
// a dialog that makes the rest of the page absent while it is shown: every dialog but one that says `modal: false`
|
|
84
|
+
export const isModal = (n) => native.isModalNode(n === undefined ? undefined : JSON.stringify(n));
|
|
85
|
+
|
|
86
|
+
// The modal dialogs of a graph and the nodes outside them (SPEC.md §4, A modal dialog): `dialogs`, in the order of
|
|
87
|
+
// ui.yaml, and `outside`, each node that some situation shows with no modal dialog shown. Read over the situations of
|
|
88
|
+
// `ex`, an exploration of `m` that explore() gave, where it is given; else over every situation the flow reaches, as
|
|
89
|
+
// `check` reads it.
|
|
90
|
+
export function modalDialogs(g, m, ex) {
|
|
91
|
+
const nx = ex === undefined || ex === null ? undefined : nativeExploration(ex);
|
|
92
|
+
return JSON.parse(call(null, () => native.modalDialogsOf(nativeGraph(g), nativeModel(m), nx)));
|
|
93
|
+
}
|
|
94
|
+
|
|
95
|
+
// The modal dialog a situation shows, the first in ui.yaml, and the nodes it makes absent there: those of
|
|
96
|
+
// `modal.outside` (modalDialogs) that the state shows by their `in` and `unless`, read as if the state were not in
|
|
97
|
+
// their `in`. Null where the situation shows no modal dialog.
|
|
98
|
+
export function modalAbsent(g, m, modal, state, ctx) {
|
|
99
|
+
const outside = [...(modal?.outside ?? [])].map(String);
|
|
100
|
+
return JSON.parse(call(null, () => native.modalAbsentOf(nativeGraph(g), nativeModel(m), outside, String(state), encode(m, ctx))));
|
|
101
|
+
}
|
|
102
|
+
|
|
103
|
+
export function focusAfter(ui, from, to, pressed, gone) {
|
|
104
|
+
if (gone !== undefined && gone !== null && !Array.isArray(gone))
|
|
105
|
+
throw new TypeError('focusAfter: gone is a list of nodes');
|
|
106
|
+
const left = gone === undefined || gone === null ? undefined : gone.map(String);
|
|
107
|
+
return JSON.parse(native.focusAfterStep(json(ui), from ?? undefined, String(to), pressed ?? undefined, left));
|
|
56
108
|
}
|
|
57
109
|
|
|
58
110
|
export function alternatives(spec) {
|
package/js/internal.js
CHANGED
|
@@ -206,13 +206,13 @@ function object(v, what) {
|
|
|
206
206
|
const graphs = new WeakMap();
|
|
207
207
|
|
|
208
208
|
export function rememberGraph(g, n) {
|
|
209
|
-
graphs.set(g, { n, dir: g.dir, flow: g.flow, ui: g.ui, catalog: g.catalog });
|
|
209
|
+
graphs.set(g, { n, dir: g.dir, flow: g.flow, ui: g.ui, catalog: g.catalog, locale: g.locale });
|
|
210
210
|
return g;
|
|
211
211
|
}
|
|
212
212
|
|
|
213
213
|
export function nativeGraph(g) {
|
|
214
214
|
const hit = graphs.get(object(g, 'the graph'));
|
|
215
|
-
if (hit !== undefined && hit.dir === g.dir && hit.flow === g.flow && hit.ui === g.ui && hit.catalog === g.catalog) return hit.n;
|
|
215
|
+
if (hit !== undefined && hit.dir === g.dir && hit.flow === g.flow && hit.ui === g.ui && hit.catalog === g.catalog && hit.locale === g.locale) return hit.n;
|
|
216
216
|
const n = call(null, () => new native.NativeGraph(JSON.stringify(g)));
|
|
217
217
|
rememberGraph(g, n);
|
|
218
218
|
return n;
|
package/js/native.d.cts
CHANGED
|
@@ -73,6 +73,13 @@ export declare class NativeValue {
|
|
|
73
73
|
/** `alternatives(spec)`, as JSON */
|
|
74
74
|
export declare function alternativesOf(spec?: string | undefined | null): string
|
|
75
75
|
|
|
76
|
+
/**
|
|
77
|
+
* `catalogWords(g, key, values, locale)`: what a key's message shows with the values a walk has, as JSON:
|
|
78
|
+
* `{ "text": .. }`, `{ "pattern": .. }` (a JavaScript regular expression's source), or null where the catalog has no
|
|
79
|
+
* such message (SPEC.md §4, Catalog)
|
|
80
|
+
*/
|
|
81
|
+
export declare function catalogWordsOf(g: NativeGraph, key: string, values: string, locale?: string | undefined | null): string
|
|
82
|
+
|
|
76
83
|
/** `checkAssertions(m, ex)`, as JSON */
|
|
77
84
|
export declare function checkAssertions(m: NativeModel, ex: NativeExploration): string
|
|
78
85
|
|
|
@@ -127,8 +134,8 @@ export declare function finalPaths(m: NativeModel, ex: NativeExploration): strin
|
|
|
127
134
|
/** `findings(g, views, goals)`, as JSON */
|
|
128
135
|
export declare function findings(g: NativeNav, views: string, goals: string): string
|
|
129
136
|
|
|
130
|
-
/** `focusAfter(ui, from, to, pressed)`, as JSON (null when nothing has the focus) */
|
|
131
|
-
export declare function focusAfterStep(ui: string, from: string | undefined | null, to: string, pressed?: string | undefined | null): string
|
|
137
|
+
/** `focusAfter(ui, from, to, pressed, gone)`, as JSON (null when nothing has the focus) */
|
|
138
|
+
export declare function focusAfterStep(ui: string, from: string | undefined | null, to: string, pressed?: string | undefined | null, gone?: Array<string> | undefined | null): string
|
|
132
139
|
|
|
133
140
|
/** `frameLevel(e)`, the entry as JSON */
|
|
134
141
|
export declare function frameLevel(entry: string): boolean
|
|
@@ -153,6 +160,9 @@ export declare function identifiers(e: string): Array<string>
|
|
|
153
160
|
/** `isDialog(n)` */
|
|
154
161
|
export declare function isDialogNode(node?: string | undefined | null): boolean
|
|
155
162
|
|
|
163
|
+
/** `isModal(n)`: a dialog that makes the rest of the page absent while it is shown */
|
|
164
|
+
export declare function isModalNode(node?: string | undefined | null): boolean
|
|
165
|
+
|
|
156
166
|
/** `keyAt(text, path)`, as JSON */
|
|
157
167
|
export declare function keyAt(text: string, path: Array<string>): string
|
|
158
168
|
|
|
@@ -195,6 +205,20 @@ export declare function maskedNodesOf(g: NativeGraph, mask: Array<string>): Arra
|
|
|
195
205
|
/** `menuRows(g, views)`, as JSON */
|
|
196
206
|
export declare function menuRows(g: NativeNav, views: string): string
|
|
197
207
|
|
|
208
|
+
/**
|
|
209
|
+
* `modalAbsent(g, m, modal, state, ctx)`: the first modal dialog a situation shows and the nodes of `outside` it
|
|
210
|
+
* makes absent there, those the state shows by their `in` and `unless`, as JSON `{ dialog, absent }`; null where the
|
|
211
|
+
* situation shows no modal dialog
|
|
212
|
+
*/
|
|
213
|
+
export declare function modalAbsentOf(g: NativeGraph, m: NativeModel, outside: Array<string>, state: string, ctx: Uint16Array): string
|
|
214
|
+
|
|
215
|
+
/**
|
|
216
|
+
* `modalDialogs(g, m, ex)`: the graph's modal dialogs and the nodes outside them, as JSON `{ dialogs, outside }`
|
|
217
|
+
* (SPEC.md §4): over the situations of `ex` where it is given, else over every situation the flow reaches, walked as
|
|
218
|
+
* `check` walks it
|
|
219
|
+
*/
|
|
220
|
+
export declare function modalDialogsOf(g: NativeGraph, m: NativeModel, ex?: NativeExploration | undefined | null): string
|
|
221
|
+
|
|
198
222
|
/** `narrate(g, m, steps)`, as JSON */
|
|
199
223
|
export declare function narrate(g: NativeGraph, m: NativeModel, steps: PathSteps): string
|
|
200
224
|
|
|
@@ -309,6 +333,21 @@ export declare function stepsTo(m: NativeModel, ex: NativeExploration, index: nu
|
|
|
309
333
|
/** the warnings the YAML reader met since the last call (the library hands each to `process.emitWarning`), as JSON */
|
|
310
334
|
export declare function takeYamlWarnings(): string
|
|
311
335
|
|
|
336
|
+
/** `thenEntries(then, effect)`: every entry a scenario's `then` gives an effect, as JSON */
|
|
337
|
+
export declare function thenEntriesOf(then: string | undefined | null, effect: string): string
|
|
338
|
+
|
|
339
|
+
/**
|
|
340
|
+
* `thenEntry(then, effect, before)`: the entry of a scenario's `then` for the time a walk applies `effect` after
|
|
341
|
+
* `before` times, as JSON, or null (SPEC.md §7)
|
|
342
|
+
*/
|
|
343
|
+
export declare function thenEntryOf(then: string | undefined | null, effect: string, before: number): string
|
|
344
|
+
|
|
345
|
+
/**
|
|
346
|
+
* `thenProblems(g, then)`: what a scenario's `then` names that the graph's flow does not have, as JSON
|
|
347
|
+
* (`[{ path, message }]`, SPEC.md §7)
|
|
348
|
+
*/
|
|
349
|
+
export declare function thenProblemsOf(g: NativeGraph, then: string): string
|
|
350
|
+
|
|
312
351
|
/** `titleOf(flow, state)` */
|
|
313
352
|
export declare function titleOfState(flow: NativeValue, state: string): string
|
|
314
353
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@delurio/cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.18.0",
|
|
4
4
|
"description": "The open checker and page of delurio-graph/0: check every graph in a project's own CI, offline, with GNU error lines and SARIF.",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"type": "module",
|
|
@@ -47,12 +47,12 @@
|
|
|
47
47
|
"elkjs": "0.12.1"
|
|
48
48
|
},
|
|
49
49
|
"optionalDependencies": {
|
|
50
|
-
"@delurio/cli-linux-x64-gnu": "0.
|
|
51
|
-
"@delurio/cli-linux-x64-musl": "0.
|
|
52
|
-
"@delurio/cli-linux-arm64-gnu": "0.
|
|
53
|
-
"@delurio/cli-linux-arm64-musl": "0.
|
|
54
|
-
"@delurio/cli-darwin-arm64": "0.
|
|
55
|
-
"@delurio/cli-win32-x64-msvc": "0.
|
|
50
|
+
"@delurio/cli-linux-x64-gnu": "0.18.0",
|
|
51
|
+
"@delurio/cli-linux-x64-musl": "0.18.0",
|
|
52
|
+
"@delurio/cli-linux-arm64-gnu": "0.18.0",
|
|
53
|
+
"@delurio/cli-linux-arm64-musl": "0.18.0",
|
|
54
|
+
"@delurio/cli-darwin-arm64": "0.18.0",
|
|
55
|
+
"@delurio/cli-win32-x64-msvc": "0.18.0"
|
|
56
56
|
},
|
|
57
57
|
"devDependencies": {
|
|
58
58
|
"@napi-rs/cli": "3.10.12"
|
|
@@ -112,7 +112,7 @@
|
|
|
112
112
|
},
|
|
113
113
|
"locale": {
|
|
114
114
|
"$ref": "#/$defs/locale",
|
|
115
|
-
"description": "The BCP 47 tag the browser is set to; every screen is read against the flow's catalog of that language."
|
|
115
|
+
"description": "The BCP 47 tag the browser is set to; every screen is read against the flow's catalog of that language, or, where the flow has none, of the language the page is in (its lang; SPEC.md §7)."
|
|
116
116
|
},
|
|
117
117
|
"timezone": {
|
|
118
118
|
"type": "string",
|
|
@@ -207,9 +207,16 @@
|
|
|
207
207
|
"type": "integer",
|
|
208
208
|
"minimum": 0,
|
|
209
209
|
"description": "How many milliseconds a screen waits for that at most: browser.timeout, which it never passes."
|
|
210
|
+
},
|
|
211
|
+
"time": {
|
|
212
|
+
"enum": [
|
|
213
|
+
"real",
|
|
214
|
+
"virtual"
|
|
215
|
+
],
|
|
216
|
+
"description": "Whose time the page lives in: real (the default), or virtual, the replay's own, which passes the page's idle time at once while it waits for the page."
|
|
210
217
|
}
|
|
211
218
|
},
|
|
212
|
-
"description": "When a screen is read: once the page has been still for `quiet` ms, waiting at most `max` ms."
|
|
219
|
+
"description": "When a screen is read: once the page has been still for `quiet` ms, waiting at most `max` ms, in the page's time (`time`)."
|
|
213
220
|
},
|
|
214
221
|
"parallel": {
|
|
215
222
|
"description": "Walks at once: true (as many as the machine holds), a number from 1 to 16, auto, or { walks, serial }, where each serial group names scenarios or accounts (a navigation graph's personas or accounts) whose walks share something fixed and go one after another. false: one at a time.",
|
|
@@ -416,7 +423,7 @@
|
|
|
416
423
|
},
|
|
417
424
|
"then": {
|
|
418
425
|
"type": "object",
|
|
419
|
-
"description": "How the steps that leave a variable to chance (havoc) come out on this scenario's walks, by the effect: a list read in order, one entry each time the walk takes a transition that applies the effect,
|
|
426
|
+
"description": "How the steps that leave a variable to chance (havoc) come out on this scenario's walks, by the effect: a list read in order, one entry each time the walk takes a transition that applies the effect, or one entry, a map in place of the list, that holds every time it does, however often. Each entry gives a value to some of the variables the effect's havoc lists. A variable an entry leaves out, and every variable once a list has run out, keeps its value (SPEC.md §7).",
|
|
420
427
|
"examples": [
|
|
421
428
|
{
|
|
422
429
|
"next": [
|
|
@@ -427,13 +434,23 @@
|
|
|
427
434
|
"lastStep": true
|
|
428
435
|
}
|
|
429
436
|
]
|
|
437
|
+
},
|
|
438
|
+
{
|
|
439
|
+
"dialogOpens": {
|
|
440
|
+
"movingOff": false,
|
|
441
|
+
"signInSaved": false
|
|
442
|
+
}
|
|
430
443
|
}
|
|
431
444
|
],
|
|
432
445
|
"propertyNames": {
|
|
433
446
|
"pattern": "^[A-Za-z_][A-Za-z0-9_]*$"
|
|
434
447
|
},
|
|
435
448
|
"additionalProperties": {
|
|
436
|
-
"type":
|
|
449
|
+
"type": [
|
|
450
|
+
"array",
|
|
451
|
+
"object"
|
|
452
|
+
],
|
|
453
|
+
"description": "A list of entries, read in order, one each time a walked transition applies the effect; or one entry, which holds every time it does.",
|
|
437
454
|
"minItems": 1,
|
|
438
455
|
"items": {
|
|
439
456
|
"type": "object",
|
|
@@ -446,6 +463,15 @@
|
|
|
446
463
|
"null"
|
|
447
464
|
]
|
|
448
465
|
}
|
|
466
|
+
},
|
|
467
|
+
"minProperties": 1,
|
|
468
|
+
"additionalProperties": {
|
|
469
|
+
"type": [
|
|
470
|
+
"string",
|
|
471
|
+
"number",
|
|
472
|
+
"boolean",
|
|
473
|
+
"null"
|
|
474
|
+
]
|
|
449
475
|
}
|
|
450
476
|
}
|
|
451
477
|
},
|
|
@@ -1084,7 +1110,7 @@
|
|
|
1084
1110
|
},
|
|
1085
1111
|
"locale": {
|
|
1086
1112
|
"$ref": "#/$defs/locale",
|
|
1087
|
-
"description": "The BCP 47 tag the browser is set to; every
|
|
1113
|
+
"description": "The BCP 47 tag the browser is set to; every page is read against the navigation graph's catalog of that language."
|
|
1088
1114
|
},
|
|
1089
1115
|
"timezone": {
|
|
1090
1116
|
"type": "string",
|
|
@@ -1179,9 +1205,16 @@
|
|
|
1179
1205
|
"type": "integer",
|
|
1180
1206
|
"minimum": 0,
|
|
1181
1207
|
"description": "How many milliseconds a screen waits for that at most: browser.timeout, which it never passes."
|
|
1208
|
+
},
|
|
1209
|
+
"time": {
|
|
1210
|
+
"enum": [
|
|
1211
|
+
"real",
|
|
1212
|
+
"virtual"
|
|
1213
|
+
],
|
|
1214
|
+
"description": "Whose time the page lives in: real (the default), or virtual, the replay's own, which passes the page's idle time at once while it waits for the page."
|
|
1182
1215
|
}
|
|
1183
1216
|
},
|
|
1184
|
-
"description": "When a screen is read: once the page has been still for `quiet` ms, waiting at most `max` ms."
|
|
1217
|
+
"description": "When a screen is read: once the page has been still for `quiet` ms, waiting at most `max` ms, in the page's time (`time`)."
|
|
1185
1218
|
},
|
|
1186
1219
|
"parallel": {
|
|
1187
1220
|
"description": "Walks at once: true (as many as the machine holds), a number from 1 to 16, auto, or { walks, serial }, where each serial group names scenarios or accounts (a navigation graph's personas or accounts) whose walks share something fixed and go one after another. false: one at a time.",
|
|
@@ -1391,6 +1424,14 @@
|
|
|
1391
1424
|
]
|
|
1392
1425
|
},
|
|
1393
1426
|
"description": "The :params of its route for this page, over the binding's own."
|
|
1427
|
+
},
|
|
1428
|
+
"serial": {
|
|
1429
|
+
"type": "array",
|
|
1430
|
+
"minItems": 1,
|
|
1431
|
+
"items": {
|
|
1432
|
+
"type": "string"
|
|
1433
|
+
},
|
|
1434
|
+
"description": "The personas or accounts that open this page one at a time, while their other visits go at once: what the page holds is one person's at a time, such as an editor's lock."
|
|
1394
1435
|
}
|
|
1395
1436
|
}
|
|
1396
1437
|
}
|
|
@@ -2077,6 +2118,86 @@
|
|
|
2077
2118
|
"$ref": "#/$defs/command",
|
|
2078
2119
|
"description": "A command and its arguments, as a list, run with no shell."
|
|
2079
2120
|
},
|
|
2121
|
+
"WebAuthn.addCredential": {
|
|
2122
|
+
"type": "object",
|
|
2123
|
+
"additionalProperties": false,
|
|
2124
|
+
"properties": {
|
|
2125
|
+
"rpId": {
|
|
2126
|
+
"type": "string",
|
|
2127
|
+
"minLength": 1,
|
|
2128
|
+
"pattern": "^[^\\s/:]+$",
|
|
2129
|
+
"description": "The relying party id the passkey is for: a domain (the page's own, or one it ends with), never an address with a scheme or a path.",
|
|
2130
|
+
"examples": [
|
|
2131
|
+
"id.example.test",
|
|
2132
|
+
"{rp}"
|
|
2133
|
+
]
|
|
2134
|
+
},
|
|
2135
|
+
"credentialId": {
|
|
2136
|
+
"type": "string",
|
|
2137
|
+
"minLength": 1,
|
|
2138
|
+
"pattern": "^(?:[A-Za-z0-9_-]+|.*\\{[^{}]+\\}.*)$",
|
|
2139
|
+
"description": "The credential's id, base64url (RFC 4648 §5, without padding), as the app's server keeps it.",
|
|
2140
|
+
"examples": [
|
|
2141
|
+
"{passkeys.owner.id}"
|
|
2142
|
+
]
|
|
2143
|
+
},
|
|
2144
|
+
"privateKey": {
|
|
2145
|
+
"type": "string",
|
|
2146
|
+
"minLength": 1,
|
|
2147
|
+
"pattern": "^(?:[A-Za-z0-9_-]+|.*\\{[^{}]+\\}.*)$",
|
|
2148
|
+
"description": "Its private key: an ECDSA P-256 key in PKCS #8, base64url. A report never shows it.",
|
|
2149
|
+
"examples": [
|
|
2150
|
+
"{passkeys.owner.key}"
|
|
2151
|
+
]
|
|
2152
|
+
},
|
|
2153
|
+
"userHandle": {
|
|
2154
|
+
"type": "string",
|
|
2155
|
+
"minLength": 1,
|
|
2156
|
+
"pattern": "^(?:[A-Za-z0-9_-]{1,86}|.*\\{[^{}]+\\}.*)$",
|
|
2157
|
+
"description": "The user handle it is kept for (WebAuthn's user.id), base64url, at most 64 bytes. A resident passkey has one.",
|
|
2158
|
+
"examples": [
|
|
2159
|
+
"{passkeys.owner.user}"
|
|
2160
|
+
]
|
|
2161
|
+
},
|
|
2162
|
+
"resident": {
|
|
2163
|
+
"type": "boolean",
|
|
2164
|
+
"description": "true, the default: a discoverable credential, found with no user named. false: one the app names (allowCredentials), as a security key's is."
|
|
2165
|
+
},
|
|
2166
|
+
"signCount": {
|
|
2167
|
+
"type": "integer",
|
|
2168
|
+
"minimum": 0,
|
|
2169
|
+
"description": "The signature counter it starts from. Left out, it has none, and every assertion gives 0, as a synced passkey does."
|
|
2170
|
+
}
|
|
2171
|
+
},
|
|
2172
|
+
"required": [
|
|
2173
|
+
"rpId",
|
|
2174
|
+
"credentialId",
|
|
2175
|
+
"privateKey"
|
|
2176
|
+
],
|
|
2177
|
+
"description": "Gives the browser it is done in a passkey, in a virtual authenticator the replay adds to it the first time: a sign-in by passkey (WebAuthn) then gets it with no prompt. The app's server already holds its public key, such as one the scenario's setup registered. A browser with no virtual authenticator fails the walk at this action (SPEC.md §7).",
|
|
2178
|
+
"allOf": [
|
|
2179
|
+
{
|
|
2180
|
+
"$comment": "a resident passkey has a user handle, as WebAuthn keeps one for every discoverable credential",
|
|
2181
|
+
"if": {
|
|
2182
|
+
"not": {
|
|
2183
|
+
"required": [
|
|
2184
|
+
"resident"
|
|
2185
|
+
],
|
|
2186
|
+
"properties": {
|
|
2187
|
+
"resident": {
|
|
2188
|
+
"const": false
|
|
2189
|
+
}
|
|
2190
|
+
}
|
|
2191
|
+
}
|
|
2192
|
+
},
|
|
2193
|
+
"then": {
|
|
2194
|
+
"required": [
|
|
2195
|
+
"userHandle"
|
|
2196
|
+
]
|
|
2197
|
+
}
|
|
2198
|
+
}
|
|
2199
|
+
]
|
|
2200
|
+
},
|
|
2080
2201
|
"expect": {
|
|
2081
2202
|
"type": [
|
|
2082
2203
|
"string",
|
|
@@ -2093,7 +2214,7 @@
|
|
|
2093
2214
|
"description": "On a click, a fill or an attach: one the app may not ask for, such as a notice shown on some visits only. Once the page is still, its element is looked for once: where it is not there, the action is passed over, and the step's report says so. Proposed on 23 Nov 2026."
|
|
2094
2215
|
}
|
|
2095
2216
|
},
|
|
2096
|
-
"description": "One thing the replay does: one of goto, reload, click, fill, attach, key, waitUrl, waitText, waitResponse, download, resize and
|
|
2217
|
+
"description": "One thing the replay does: one of goto, reload, click, fill, attach, key, waitUrl, waitText, waitResponse, download, resize, run and WebAuthn.addCredential, which may carry `as`; a click, a fill or an attach may be optional.",
|
|
2097
2218
|
"anyOf": [
|
|
2098
2219
|
{
|
|
2099
2220
|
"required": [
|
|
@@ -2154,9 +2275,14 @@
|
|
|
2154
2275
|
"required": [
|
|
2155
2276
|
"run"
|
|
2156
2277
|
]
|
|
2278
|
+
},
|
|
2279
|
+
{
|
|
2280
|
+
"required": [
|
|
2281
|
+
"WebAuthn.addCredential"
|
|
2282
|
+
]
|
|
2157
2283
|
}
|
|
2158
2284
|
],
|
|
2159
|
-
"$comment": "an action is one of goto, reload, click, fill, attach, key, waitUrl, waitText, waitResponse, download, resize, run",
|
|
2285
|
+
"$comment": "an action is one of goto, reload, click, fill, attach, key, waitUrl, waitText, waitResponse, download, resize, run, WebAuthn.addCredential",
|
|
2160
2286
|
"allOf": [
|
|
2161
2287
|
{
|
|
2162
2288
|
"$comment": "an action does one thing: give each its own item",
|
|
@@ -2177,7 +2303,8 @@
|
|
|
2177
2303
|
"waitResponse": false,
|
|
2178
2304
|
"download": false,
|
|
2179
2305
|
"resize": false,
|
|
2180
|
-
"run": false
|
|
2306
|
+
"run": false,
|
|
2307
|
+
"WebAuthn.addCredential": false
|
|
2181
2308
|
}
|
|
2182
2309
|
}
|
|
2183
2310
|
},
|
|
@@ -2199,7 +2326,8 @@
|
|
|
2199
2326
|
"waitResponse": false,
|
|
2200
2327
|
"download": false,
|
|
2201
2328
|
"resize": false,
|
|
2202
|
-
"run": false
|
|
2329
|
+
"run": false,
|
|
2330
|
+
"WebAuthn.addCredential": false
|
|
2203
2331
|
}
|
|
2204
2332
|
}
|
|
2205
2333
|
},
|
|
@@ -2220,7 +2348,8 @@
|
|
|
2220
2348
|
"waitResponse": false,
|
|
2221
2349
|
"download": false,
|
|
2222
2350
|
"resize": false,
|
|
2223
|
-
"run": false
|
|
2351
|
+
"run": false,
|
|
2352
|
+
"WebAuthn.addCredential": false
|
|
2224
2353
|
}
|
|
2225
2354
|
}
|
|
2226
2355
|
},
|
|
@@ -2240,7 +2369,8 @@
|
|
|
2240
2369
|
"waitResponse": false,
|
|
2241
2370
|
"download": false,
|
|
2242
2371
|
"resize": false,
|
|
2243
|
-
"run": false
|
|
2372
|
+
"run": false,
|
|
2373
|
+
"WebAuthn.addCredential": false
|
|
2244
2374
|
}
|
|
2245
2375
|
}
|
|
2246
2376
|
},
|
|
@@ -2259,7 +2389,8 @@
|
|
|
2259
2389
|
"waitResponse": false,
|
|
2260
2390
|
"download": false,
|
|
2261
2391
|
"resize": false,
|
|
2262
|
-
"run": false
|
|
2392
|
+
"run": false,
|
|
2393
|
+
"WebAuthn.addCredential": false
|
|
2263
2394
|
}
|
|
2264
2395
|
}
|
|
2265
2396
|
},
|
|
@@ -2277,7 +2408,8 @@
|
|
|
2277
2408
|
"waitResponse": false,
|
|
2278
2409
|
"download": false,
|
|
2279
2410
|
"resize": false,
|
|
2280
|
-
"run": false
|
|
2411
|
+
"run": false,
|
|
2412
|
+
"WebAuthn.addCredential": false
|
|
2281
2413
|
}
|
|
2282
2414
|
}
|
|
2283
2415
|
},
|
|
@@ -2294,7 +2426,8 @@
|
|
|
2294
2426
|
"waitResponse": false,
|
|
2295
2427
|
"download": false,
|
|
2296
2428
|
"resize": false,
|
|
2297
|
-
"run": false
|
|
2429
|
+
"run": false,
|
|
2430
|
+
"WebAuthn.addCredential": false
|
|
2298
2431
|
}
|
|
2299
2432
|
}
|
|
2300
2433
|
},
|
|
@@ -2310,7 +2443,8 @@
|
|
|
2310
2443
|
"waitResponse": false,
|
|
2311
2444
|
"download": false,
|
|
2312
2445
|
"resize": false,
|
|
2313
|
-
"run": false
|
|
2446
|
+
"run": false,
|
|
2447
|
+
"WebAuthn.addCredential": false
|
|
2314
2448
|
}
|
|
2315
2449
|
}
|
|
2316
2450
|
},
|
|
@@ -2325,7 +2459,8 @@
|
|
|
2325
2459
|
"properties": {
|
|
2326
2460
|
"download": false,
|
|
2327
2461
|
"resize": false,
|
|
2328
|
-
"run": false
|
|
2462
|
+
"run": false,
|
|
2463
|
+
"WebAuthn.addCredential": false
|
|
2329
2464
|
}
|
|
2330
2465
|
}
|
|
2331
2466
|
},
|
|
@@ -2339,7 +2474,8 @@
|
|
|
2339
2474
|
"then": {
|
|
2340
2475
|
"properties": {
|
|
2341
2476
|
"resize": false,
|
|
2342
|
-
"run": false
|
|
2477
|
+
"run": false,
|
|
2478
|
+
"WebAuthn.addCredential": false
|
|
2343
2479
|
}
|
|
2344
2480
|
}
|
|
2345
2481
|
},
|
|
@@ -2352,7 +2488,21 @@
|
|
|
2352
2488
|
},
|
|
2353
2489
|
"then": {
|
|
2354
2490
|
"properties": {
|
|
2355
|
-
"run": false
|
|
2491
|
+
"run": false,
|
|
2492
|
+
"WebAuthn.addCredential": false
|
|
2493
|
+
}
|
|
2494
|
+
}
|
|
2495
|
+
},
|
|
2496
|
+
{
|
|
2497
|
+
"$comment": "an action does one thing: give each its own item",
|
|
2498
|
+
"if": {
|
|
2499
|
+
"required": [
|
|
2500
|
+
"run"
|
|
2501
|
+
]
|
|
2502
|
+
},
|
|
2503
|
+
"then": {
|
|
2504
|
+
"properties": {
|
|
2505
|
+
"WebAuthn.addCredential": false
|
|
2356
2506
|
}
|
|
2357
2507
|
}
|
|
2358
2508
|
},
|
|
@@ -7,7 +7,7 @@
|
|
|
7
7
|
"propertyNames": { "minLength": 1 },
|
|
8
8
|
"additionalProperties": {
|
|
9
9
|
"type": "string",
|
|
10
|
-
"description": "An ICU MessageFormat message.
|
|
11
|
-
"examples": ["{client} wants access to your account"]
|
|
10
|
+
"description": "An ICU MessageFormat message (SPEC.md §4): `{param}` is filled from the node's `params`, which name sample or data values; `{count, plural, one {# finding} other {# findings}}` chooses its case by the CLDR plural rules of the catalog's language, `selectordinal` by its ordinal rules, and `{role, select, admin {..} other {..}}` by the value. Every plural and select has an `other`.",
|
|
11
|
+
"examples": ["{client} wants access to your account", "{count, plural, one {# finding} other {# findings}}"]
|
|
12
12
|
}
|
|
13
13
|
}
|
package/schemas/ui.schema.json
CHANGED
|
@@ -276,12 +276,20 @@
|
|
|
276
276
|
"description": "An expression over the flow's context (SPEC.md §3): where it holds, the node is shown but disabled, in any state that shows it, such as a button that waits until a VAT number is typed or a box is ticked. Beside disabledIn, the node is disabled where either says so. A replay compares it in each situation it stops in. A repeat node's may also read its row's place among the rows it draws: repeat.first, repeat.last and repeat.index (from 1), such as the first row's Move up (proposed on 23 Nov 2026).",
|
|
277
277
|
"examples": ["not vatGiven", "not accepted", "repeat.first", "saving or repeat.last"]
|
|
278
278
|
},
|
|
279
|
+
"readOnlyIn": {
|
|
280
|
+
"$ref": "#/$defs/states",
|
|
281
|
+
"description": "On a field that can be read-only: the states where it is shown read-only, such as a field while its form is sent. It keeps its value and can have the focus, and takes no input (HTML readonly, or aria-readonly), unlike a disabled one. A replay compares it in each situation it stops in, by the readonly property of the browser's accessibility tree. A state is in disabledIn or in readOnlyIn, not in both (SPEC.md §4)."
|
|
282
|
+
},
|
|
279
283
|
"emits": {
|
|
280
284
|
"type": "string",
|
|
281
285
|
"description": "The event the node sends when pressed: an event of the flow, UPPER_SNAKE.",
|
|
282
286
|
"pattern": "^[A-Z][A-Z0-9_]*$"
|
|
283
287
|
},
|
|
284
288
|
"initialFocus": { "$ref": "#/$defs/nodeRef", "description": "On a page: the node that has focus when it opens, at the flow's start or when a transition shows it." },
|
|
289
|
+
"modal": {
|
|
290
|
+
"type": "boolean",
|
|
291
|
+
"description": "On a dialog (a page whose role is dialog or alertdialog): whether it is modal, true unless it says false. Where a modal dialog is shown, the nodes outside it are read as absent, as if the state were not in their `in`: the rest of the page is inert (HTML showModal, aria-modal). false: a dialog that leaves the page as it is, such as a guide's box beside the element it points to (SPEC.md §4)."
|
|
292
|
+
},
|
|
285
293
|
"repeat": { "type": "string", "description": "The node is drawn once per item of this data: once per row when the samples give its rows (`samples.<data>`), else once. Its params may read the item's fields as `row.<field>`, and so may its `checked`. Adjacent nodes with the same repeat are drawn side by side, one row per item.", "examples": ["request.scopes"] },
|
|
286
294
|
"frame": {
|
|
287
295
|
"description": "For a page: whether it may be framed; `never` (served with CSP frame-ancestors 'none').",
|
|
@@ -353,6 +361,35 @@
|
|
|
353
361
|
"$comment": "duringStep is only on a node that sends an event: it says where that event is handled",
|
|
354
362
|
"if": { "required": ["duringStep"], "properties": { "duringStep": { "const": true } } },
|
|
355
363
|
"then": { "required": ["emits"] }
|
|
364
|
+
},
|
|
365
|
+
{
|
|
366
|
+
"$comment": "readOnlyIn is only on a field that can be read-only: one whose role takes aria-readonly (checkbox, columnheader, combobox, grid, gridcell, listbox, radiogroup, rowheader, searchbox, slider, spinbutton, switch, textbox, treegrid), or a native date, time, datetime-local, month or week input",
|
|
367
|
+
"if": {
|
|
368
|
+
"not": {
|
|
369
|
+
"required": ["type"],
|
|
370
|
+
"properties": { "type": { "const": "field" } },
|
|
371
|
+
"anyOf": [
|
|
372
|
+
{
|
|
373
|
+
"required": ["role"],
|
|
374
|
+
"properties": {
|
|
375
|
+
"role": {
|
|
376
|
+
"enum": [
|
|
377
|
+
"checkbox", "columnheader", "combobox", "grid", "gridcell", "listbox", "radiogroup", "rowheader", "searchbox",
|
|
378
|
+
"slider", "spinbutton", "switch", "textbox", "treegrid"
|
|
379
|
+
]
|
|
380
|
+
}
|
|
381
|
+
}
|
|
382
|
+
},
|
|
383
|
+
{ "required": ["native"], "properties": { "native": { "enum": ["date", "time", "datetime-local", "month", "week"] } } }
|
|
384
|
+
]
|
|
385
|
+
}
|
|
386
|
+
},
|
|
387
|
+
"then": { "properties": { "readOnlyIn": false } }
|
|
388
|
+
},
|
|
389
|
+
{
|
|
390
|
+
"$comment": "modal is only on a dialog: a page whose role is dialog or alertdialog",
|
|
391
|
+
"if": { "not": { "required": ["type", "role"], "properties": { "type": { "const": "page" }, "role": { "enum": ["dialog", "alertdialog"] } } } },
|
|
392
|
+
"then": { "properties": { "modal": false } }
|
|
356
393
|
}
|
|
357
394
|
]
|
|
358
395
|
},
|