@botiverse/porthole 0.14.11 → 0.14.13
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 +28 -0
- package/dist/annotate/types.d.ts +7 -2
- package/dist/annotate/types.js +5 -0
- package/dist/check/page-source.js +1 -1
- package/dist/conformance/harness-source.js +1 -1
- package/dist/host/create-host.js +8 -0
- package/dist/host/types.d.ts +19 -0
- package/dist/react/frame.d.ts +8 -0
- package/dist/react/frame.js +6 -0
- package/dist/react/view.js +1 -0
- package/dist/shell/annotate.d.ts +14 -3
- package/dist/shell/annotate.js +70 -10
- package/docs/ADOPTING.md +58 -4
- package/docs/DECISIONS.md +236 -1
- package/docs/DESIGN.md +17 -8
- package/docs/THREAT_MODEL.md +59 -5
- package/package.json +1 -1
- package/src/annotate/types.ts +7 -2
- package/src/host/create-host.ts +8 -0
- package/src/host/types.ts +19 -0
- package/src/react/frame.tsx +14 -0
- package/src/react/view.tsx +1 -0
- package/src/shell/annotate.ts +71 -10
package/CHANGELOG.md
CHANGED
|
@@ -4,6 +4,34 @@
|
|
|
4
4
|
section); the reasons for every change are in [docs/DECISIONS.md](docs/DECISIONS.md), by the
|
|
5
5
|
P-numbers below.
|
|
6
6
|
|
|
7
|
+
## 0.14.13
|
|
8
|
+
|
|
9
|
+
- **Annotations: a `focusMark` that had to wait (P135).** While the frame finds its marks, `focusMark`
|
|
10
|
+
waits, and is now dropped unless the focus is in the frame by then, so it takes no keyboard from a
|
|
11
|
+
person who moved on. A call on a calm page is unchanged. After your card closes the focus is on your
|
|
12
|
+
`<body>`, so a call that waited is dropped: if the focus is still there a moment later, call
|
|
13
|
+
`display.focus()` and `focusMark(id)` again (ADOPTING). Known gap: on a nested page that had the
|
|
14
|
+
focus, `display.focus()` doesn't bring it back, so a call that waits is dropped even then.
|
|
15
|
+
- **Security (P135):** the shell asks through the platform's `hasFocus`, kept before content runs
|
|
16
|
+
(controls `marker-late`, `marker-has-focus`). No CSP, sandbox, egress or gate changes; the focus
|
|
17
|
+
guard is untouched.
|
|
18
|
+
|
|
19
|
+
## 0.14.12
|
|
20
|
+
|
|
21
|
+
- **Annotations: the keyboard back on a marker (P134).** `annotations.focusMark(id)` (React:
|
|
22
|
+
`focusMark(id)` on the `ref`) moves the DOM focus to that mark's marker in the frame. It is for
|
|
23
|
+
one moment: after Escape closed your own view of that mark, once it is closed. It carries no
|
|
24
|
+
content and reports nothing; with no such marker it does nothing and throws nothing. An older
|
|
25
|
+
shell ignores it.
|
|
26
|
+
- **Annotations: a marker's name (P134).** It reads `1 comment on "Paragraph 3. Filler…"`: the words
|
|
27
|
+
it is on, in quotes, with no element's tag. `anchor.label` and everything you store are unchanged.
|
|
28
|
+
- **Key or pointer (P134).** `activated` is unchanged. Read `document.activeElement` on your own page
|
|
29
|
+
as it arrives: the frame there means the focus is in the frame. A hint: a page can still forge
|
|
30
|
+
`activated` while the person is in the frame, and a host that moves the keyboard into its view on
|
|
31
|
+
this gates what posts from that view itself (ADOPTING, THREAT_MODEL §7).
|
|
32
|
+
- **Security (P134):** the shell's move uses the platform's `focus`, kept before content runs (control
|
|
33
|
+
`marker-focus`). No CSP, sandbox, egress or gate changes; the focus guard is untouched.
|
|
34
|
+
|
|
7
35
|
## 0.14.11
|
|
8
36
|
|
|
9
37
|
- **Annotations: markers are buttons (P133).** A marker is a real button in the frame's Tab order,
|
package/dist/annotate/types.d.ts
CHANGED
|
@@ -91,8 +91,8 @@ export interface AnnotationMark {
|
|
|
91
91
|
* draws the bubble alone) at the end of a text anchor's paragraph (P133) and the top right of an
|
|
92
92
|
* element. The person can click it, or reach it with the keyboard and press Enter or Space
|
|
93
93
|
* (P133): the frame reports `activated`. Its accessible name says what it is, with the count and
|
|
94
|
-
*
|
|
95
|
-
* draft's is dropped (P107): its marker has no number.
|
|
94
|
+
* the words it is on, quoted, an element's tag left out (P134). The content can read the number;
|
|
95
|
+
* give one only where the page may know it. A draft's is dropped (P107): its marker has no number.
|
|
96
96
|
*/
|
|
97
97
|
readonly count?: number;
|
|
98
98
|
/**
|
|
@@ -234,6 +234,11 @@ export declare const ANNOTATE_METHODS: {
|
|
|
234
234
|
readonly tracked: "porthole/annotate.tracked";
|
|
235
235
|
/** Host → frame: take the page's text selection away, telling nothing back (P115). */
|
|
236
236
|
readonly clearSelection: "porthole/annotate.clearSelection";
|
|
237
|
+
/**
|
|
238
|
+
* Host → frame: put the focus on one mark's marker (`{ id }`), telling nothing back (P134); one
|
|
239
|
+
* that waited for the marks is dropped unless the focus is in the frame's document by then (P135).
|
|
240
|
+
*/
|
|
241
|
+
readonly focusMark: "porthole/annotate.focusMark";
|
|
237
242
|
};
|
|
238
243
|
/** The most of each part of an anchor or report the host takes. */
|
|
239
244
|
export declare const ANNOTATION_LIMITS: {
|
package/dist/annotate/types.js
CHANGED
|
@@ -36,6 +36,11 @@ export const ANNOTATE_METHODS = {
|
|
|
36
36
|
tracked: "porthole/annotate.tracked",
|
|
37
37
|
/** Host → frame: take the page's text selection away, telling nothing back (P115). */
|
|
38
38
|
clearSelection: "porthole/annotate.clearSelection",
|
|
39
|
+
/**
|
|
40
|
+
* Host → frame: put the focus on one mark's marker (`{ id }`), telling nothing back (P134); one
|
|
41
|
+
* that waited for the marks is dropped unless the focus is in the frame's document by then (P135).
|
|
42
|
+
*/
|
|
43
|
+
focusMark: "porthole/annotate.focusMark",
|
|
39
44
|
};
|
|
40
45
|
/** The most of each part of an anchor or report the host takes. */
|
|
41
46
|
export const ANNOTATION_LIMITS = {
|