@miadi/chronicle-tui 0.3.0 → 0.4.1
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/README.md +41 -21
- package/dist/App.d.ts +14 -5
- package/dist/App.d.ts.map +1 -1
- package/dist/App.js +595 -321
- package/dist/App.js.map +1 -1
- package/dist/actions.d.ts +31 -21
- package/dist/actions.d.ts.map +1 -1
- package/dist/actions.js +62 -44
- package/dist/actions.js.map +1 -1
- package/dist/api.d.ts +58 -30
- package/dist/api.d.ts.map +1 -1
- package/dist/api.js +129 -44
- package/dist/api.js.map +1 -1
- package/dist/attention.d.ts +50 -0
- package/dist/attention.d.ts.map +1 -0
- package/dist/attention.js +69 -0
- package/dist/attention.js.map +1 -0
- package/dist/bin.d.ts +2 -1
- package/dist/bin.d.ts.map +1 -1
- package/dist/bin.js +19 -11
- package/dist/bin.js.map +1 -1
- package/dist/data.d.ts +48 -12
- package/dist/data.d.ts.map +1 -1
- package/dist/data.js +124 -24
- package/dist/data.js.map +1 -1
- package/dist/index.d.ts +6 -4
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +6 -4
- package/dist/index.js.map +1 -1
- package/dist/model.d.ts +10 -2
- package/dist/model.d.ts.map +1 -1
- package/dist/model.js +47 -35
- package/dist/model.js.map +1 -1
- package/dist/text.d.ts +23 -0
- package/dist/text.d.ts.map +1 -0
- package/dist/text.js +57 -0
- package/dist/text.js.map +1 -0
- package/package.json +5 -4
package/README.md
CHANGED
|
@@ -27,7 +27,8 @@ On Termux, install with `--ignore-scripts`. Node 22 or later.
|
|
|
27
27
|
| `o` | the doors of the reference, file or episode in focus: room (local, tailnet, public), wheel, vessel. Enter opens one |
|
|
28
28
|
| `r` | the phone door as a QR code (`i` inverts it for a light terminal) |
|
|
29
29
|
| `p` | the five-stage proof (git and the wheel, on demand) |
|
|
30
|
-
| `a` | the episode's attention items
|
|
30
|
+
| `a` | the episode's attention items, Open and History (Tab), each with what it cites. Enter reads one; Enter again answers an open one |
|
|
31
|
+
| `!` | the chronicle's attention board: every open item, newest asked first, filtered by `/`. `e` on an item opens its episode |
|
|
31
32
|
| `v` | hold a Miadi review in the episode (writer token) |
|
|
32
33
|
| `?` | all keys · `q` quits |
|
|
33
34
|
|
|
@@ -53,26 +54,45 @@ miadi-chronicle --env ~/.env.miadi-writer # a file holding MIADI_API_TOKE
|
|
|
53
54
|
miadi-chronicle --url https://miadi.tail3b11eb.ts.net
|
|
54
55
|
```
|
|
55
56
|
|
|
56
|
-
- **
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
`
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
- **
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
- **
|
|
70
|
-
|
|
71
|
-
`
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
57
|
+
- **Two tokens, each for what it is.** `MIADI_PERSON_TOKEN` is you: it is the
|
|
58
|
+
bearer of every read, so the header names you and a ceremony or circle shows
|
|
59
|
+
what your seat allows. `MIADI_API_TOKEN_WRITER` passes the write gate: it is
|
|
60
|
+
the bearer of writes, with you named beside it in `x-miadi-person-token`, as
|
|
61
|
+
the app expects an agent acting for a person. Either alone does what it can.
|
|
62
|
+
- **`--env <file>`** loads only these keys from a `KEY=value` file (`export`,
|
|
63
|
+
quotes and `#` comments are understood, nothing is expanded, `PATH` is never
|
|
64
|
+
touched): the two tokens, `MIADI_CHRONICLE_ROOT`, `MIADI_WEB_URL`,
|
|
65
|
+
`MIADI_URL_BASE_INTERNAL`, `MIADI_URL_BASE`, `MIADI_CHRONICLE_MW_URL`.
|
|
66
|
+
- **The app** is `--url`, else the local app (`MIADI_WEB_URL` or
|
|
67
|
+
`127.0.0.1:3335`), then the tailnet one (`MIADI_URL_BASE_INTERNAL`). The
|
|
68
|
+
public front is used only when named with `--url`. A token travels over
|
|
69
|
+
https, or plain http to this machine only.
|
|
70
|
+
- **What you see is what the web room would show you** (jgwill/Miadi#712). A
|
|
71
|
+
visitor sees no `community` episode and nothing under `captures/` or
|
|
72
|
+
`ceremonies/`. A reader the app names sees community episodes (◇); a reader
|
|
73
|
+
the app lets write sees the room's private folders too.
|
|
74
|
+
- **A ceremony or circle reference** opens as a card for a person the app
|
|
75
|
+
seats (`GET /api/ceremony/{id}`, `GET /api/circles/{id}`): its kind,
|
|
76
|
+
direction, intention, episode or facilitator, and what your seat may do.
|
|
77
|
+
Never its turns. Otherwise it shows its pages, and never the wheel's record.
|
|
78
|
+
- **Attention** works as in the web room, through `@miadi/attention-core`: the
|
|
79
|
+
board (`!`) and each episode's panel (`a`) read the vessels exactly as the
|
|
80
|
+
room does; an answer is checked the same way and posted to
|
|
81
|
+
`POST /api/chronicle/attention`, and the wheel is reported, never assumed.
|
|
82
|
+
- **A review** (`v`) posts to `POST /api/chronicle/episodes/{ref}/reviews`;
|
|
83
|
+
with your person token its talking circle opens in your name.
|
|
84
|
+
|
|
85
|
+
Write actions declare `effect: "write"` and are offered only when the app said
|
|
86
|
+
it would record them.
|
|
87
|
+
|
|
88
|
+
## Safe to point at any chronicle
|
|
89
|
+
|
|
90
|
+
Chronicle files are written by many agents and people. Every string the
|
|
91
|
+
browser prints goes through one sanitizer: terminal escape sequences, control
|
|
92
|
+
characters and bidi overrides are removed, tabs are expanded, and only
|
|
93
|
+
http(s) and `file:` URLs without controls become links. A door opens through
|
|
94
|
+
the system opener only when it is a web page, or a folder or a text, document
|
|
95
|
+
or media file inside the chronicle; the opener and `rg` never inherit a token.
|
|
76
96
|
|
|
77
97
|
## Where each read comes from
|
|
78
98
|
|
package/dist/App.d.ts
CHANGED
|
@@ -1,9 +1,14 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* The terminal browser's screen. It draws the panes and routes keys; every
|
|
3
|
-
* read goes through `data.ts`, every operation through the
|
|
3
|
+
* read goes through `data.ts` and `attention.ts`, every operation through the
|
|
4
|
+
* action registry, every printed string through `text.ts`.
|
|
4
5
|
*
|
|
5
|
-
*
|
|
6
|
-
*
|
|
6
|
+
* State lives in one ref and is read from there, so keys that arrive together
|
|
7
|
+
* (fast typing, a paste, ssh) each act on the state the previous one left, not
|
|
8
|
+
* on the last render (jgwill/Miadi#706 UI review, F5 and F13).
|
|
9
|
+
*
|
|
10
|
+
* Keys are plain letters, arrows, Tab, Enter and Esc. No Ctrl or Meta chord is
|
|
11
|
+
* taken, so tmux (C-b) and herdr (prefix+…) keep all of theirs.
|
|
7
12
|
*/
|
|
8
13
|
import React from "react";
|
|
9
14
|
import { type ChronicleAction } from "./actions.js";
|
|
@@ -15,10 +20,14 @@ export interface AppProps {
|
|
|
15
20
|
search?: string;
|
|
16
21
|
/** Start on this episode (number, epNNN or folder name). */
|
|
17
22
|
episode?: string;
|
|
23
|
+
/** Start on the chronicle's attention board. */
|
|
24
|
+
attention?: boolean;
|
|
18
25
|
/** Operations beyond the built-in ones. */
|
|
19
26
|
actions?: readonly ChronicleAction[];
|
|
20
|
-
/** The Miadi app to act through. Default: the
|
|
27
|
+
/** The Miadi app to act through. Default: the local app, then the tailnet one. */
|
|
21
28
|
url?: string;
|
|
29
|
+
/** Environment keys `--env` loaded: an opener never inherits them. */
|
|
30
|
+
withheld?: readonly string[];
|
|
22
31
|
}
|
|
23
|
-
export declare function App(
|
|
32
|
+
export declare function App(props: AppProps): React.JSX.Element;
|
|
24
33
|
//# sourceMappingURL=App.d.ts.map
|
package/dist/App.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"App.d.ts","sourceRoot":"","sources":["../src/App.tsx"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"App.d.ts","sourceRoot":"","sources":["../src/App.tsx"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,KAAiD,MAAM,OAAO,CAAA;AAGrE,OAAO,EAIL,KAAK,eAAe,EAGrB,MAAM,cAAc,CAAA;AA0CrB,MAAM,WAAW,QAAQ;IACvB,IAAI,EAAE,MAAM,CAAA;IACZ,oCAAoC;IACpC,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,+CAA+C;IAC/C,MAAM,CAAC,EAAE,MAAM,CAAA;IACf,4DAA4D;IAC5D,OAAO,CAAC,EAAE,MAAM,CAAA;IAChB,gDAAgD;IAChD,SAAS,CAAC,EAAE,OAAO,CAAA;IACnB,2CAA2C;IAC3C,OAAO,CAAC,EAAE,SAAS,eAAe,EAAE,CAAA;IACpC,kFAAkF;IAClF,GAAG,CAAC,EAAE,MAAM,CAAA;IACZ,sEAAsE;IACtE,QAAQ,CAAC,EAAE,SAAS,MAAM,EAAE,CAAA;CAC7B;AAoHD,wBAAgB,GAAG,CAAC,KAAK,EAAE,QAAQ,qBA+9BlC"}
|