@fungi.computer/gills 0.0.0-stage → 0.1.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/LICENSE +21 -0
- package/README.md +100 -2
- package/dist/declaration.d.ts +55 -0
- package/dist/declaration.js +41 -0
- package/dist/gill.d.ts +248 -0
- package/dist/gill.js +134 -0
- package/dist/index.d.ts +3 -0
- package/dist/index.js +3 -0
- package/dist/presentation.d.ts +2 -0
- package/dist/presentation.js +20 -0
- package/dist/rows.d.ts +78 -0
- package/dist/rows.js +46 -0
- package/docs/api/README.md +13 -0
- package/docs/api/index.md +879 -0
- package/docs/api/modules.md +14 -0
- package/docs/api/presentation.md +30 -0
- package/package.json +30 -3
|
@@ -0,0 +1,879 @@
|
|
|
1
|
+
<!-- Generated by Botanical API docs (TypeDoc + typedoc-plugin-markdown). Do not edit. -->
|
|
2
|
+
|
|
3
|
+
[**@fungi.computer/gills**](README.md)
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
[@fungi.computer/gills](modules.md) / index
|
|
8
|
+
|
|
9
|
+
# index
|
|
10
|
+
|
|
11
|
+
## Type Aliases
|
|
12
|
+
|
|
13
|
+
### AppGillDesktopSize
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
type AppGillDesktopSize = "S" | "M" | "L";
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
Sizes the App explicitly offers for a desktop Gill.
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
### AppGillParam
|
|
24
|
+
|
|
25
|
+
```ts
|
|
26
|
+
type AppGillParam = Readonly<{
|
|
27
|
+
key: string;
|
|
28
|
+
label: string;
|
|
29
|
+
kind: "computer" | "repository" | "branch";
|
|
30
|
+
required: boolean;
|
|
31
|
+
options?: string;
|
|
32
|
+
}>;
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
One App-owned placement selector.
|
|
36
|
+
|
|
37
|
+
---
|
|
38
|
+
|
|
39
|
+
### AppGillWatch
|
|
40
|
+
|
|
41
|
+
```ts
|
|
42
|
+
type AppGillWatch = Readonly<
|
|
43
|
+
| {
|
|
44
|
+
storage: string;
|
|
45
|
+
}
|
|
46
|
+
| {
|
|
47
|
+
binding: string;
|
|
48
|
+
}
|
|
49
|
+
>;
|
|
50
|
+
```
|
|
51
|
+
|
|
52
|
+
An existing change feed used to refresh a Gill.
|
|
53
|
+
|
|
54
|
+
---
|
|
55
|
+
|
|
56
|
+
### AppDeclaredGill
|
|
57
|
+
|
|
58
|
+
```ts
|
|
59
|
+
type AppDeclaredGill = Readonly<{
|
|
60
|
+
id: string;
|
|
61
|
+
source: string;
|
|
62
|
+
title: string;
|
|
63
|
+
params?: readonly AppGillParam[];
|
|
64
|
+
watch?: AppGillWatch;
|
|
65
|
+
desktop?: Readonly<{
|
|
66
|
+
sizes: readonly AppGillDesktopSize[];
|
|
67
|
+
}>;
|
|
68
|
+
}>;
|
|
69
|
+
```
|
|
70
|
+
|
|
71
|
+
A digest-covered projection of one declared read method.
|
|
72
|
+
|
|
73
|
+
---
|
|
74
|
+
|
|
75
|
+
### GillRequest
|
|
76
|
+
|
|
77
|
+
```ts
|
|
78
|
+
type GillRequest = Schema.Schema.Type<typeof gillRequestSchema>;
|
|
79
|
+
```
|
|
80
|
+
|
|
81
|
+
Selectors supplied by a Gill caller.
|
|
82
|
+
|
|
83
|
+
---
|
|
84
|
+
|
|
85
|
+
### GillCall
|
|
86
|
+
|
|
87
|
+
```ts
|
|
88
|
+
type GillCall = Schema.Schema.Type<typeof gillCallSchema>;
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
Input to the generated backend Gill entry.
|
|
92
|
+
|
|
93
|
+
---
|
|
94
|
+
|
|
95
|
+
### GillResponse
|
|
96
|
+
|
|
97
|
+
```ts
|
|
98
|
+
type GillResponse = Schema.Schema.Type<typeof gillResponseSchema>;
|
|
99
|
+
```
|
|
100
|
+
|
|
101
|
+
A decoded page of plain-text Gill rows or a bounded error.
|
|
102
|
+
|
|
103
|
+
---
|
|
104
|
+
|
|
105
|
+
### GillOptionsResponse
|
|
106
|
+
|
|
107
|
+
```ts
|
|
108
|
+
type GillOptionsResponse = Schema.Schema.Type<typeof gillOptionsResponseSchema>;
|
|
109
|
+
```
|
|
110
|
+
|
|
111
|
+
Choices remain within the selected App; the host supplies Computer choices.
|
|
112
|
+
|
|
113
|
+
---
|
|
114
|
+
|
|
115
|
+
### GillReply
|
|
116
|
+
|
|
117
|
+
```ts
|
|
118
|
+
type GillReply = Schema.Schema.Type<typeof gillReplySchema>;
|
|
119
|
+
```
|
|
120
|
+
|
|
121
|
+
A rows read or a placement-options read.
|
|
122
|
+
|
|
123
|
+
---
|
|
124
|
+
|
|
125
|
+
### RowV1
|
|
126
|
+
|
|
127
|
+
```ts
|
|
128
|
+
type RowV1 = Schema.Schema.Type<typeof rowSchemaV1>;
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
One shared, bounded data row; the host owns navigation and execution.
|
|
132
|
+
|
|
133
|
+
## Variables
|
|
134
|
+
|
|
135
|
+
### appGillParamKeySchema
|
|
136
|
+
|
|
137
|
+
```ts
|
|
138
|
+
const appGillParamKeySchema: String;
|
|
139
|
+
```
|
|
140
|
+
|
|
141
|
+
Bounded, App-owned parameter key.
|
|
142
|
+
|
|
143
|
+
---
|
|
144
|
+
|
|
145
|
+
### appGillParamSchema
|
|
146
|
+
|
|
147
|
+
```ts
|
|
148
|
+
const appGillParamSchema: Struct<{
|
|
149
|
+
key: String;
|
|
150
|
+
label: String;
|
|
151
|
+
kind: Literals<readonly ["computer", "repository", "branch"]>;
|
|
152
|
+
required: Boolean;
|
|
153
|
+
options: optional<String>;
|
|
154
|
+
}>;
|
|
155
|
+
```
|
|
156
|
+
|
|
157
|
+
Placement parameter metadata, included in the Release digest.
|
|
158
|
+
|
|
159
|
+
---
|
|
160
|
+
|
|
161
|
+
### appGillParamsSchema
|
|
162
|
+
|
|
163
|
+
```ts
|
|
164
|
+
const appGillParamsSchema: $Array<
|
|
165
|
+
Struct<{
|
|
166
|
+
key: String;
|
|
167
|
+
label: String;
|
|
168
|
+
kind: Literals<readonly ["computer", "repository", "branch"]>;
|
|
169
|
+
required: Boolean;
|
|
170
|
+
options: optional<String>;
|
|
171
|
+
}>
|
|
172
|
+
>;
|
|
173
|
+
```
|
|
174
|
+
|
|
175
|
+
The bounded, uniquely keyed placement parameters shared with desktop catalogs.
|
|
176
|
+
|
|
177
|
+
---
|
|
178
|
+
|
|
179
|
+
### appGillWatchSchema
|
|
180
|
+
|
|
181
|
+
```ts
|
|
182
|
+
const appGillWatchSchema: Union<
|
|
183
|
+
readonly [
|
|
184
|
+
Struct<{
|
|
185
|
+
storage: String;
|
|
186
|
+
}>,
|
|
187
|
+
Struct<{
|
|
188
|
+
binding: String;
|
|
189
|
+
}>,
|
|
190
|
+
]
|
|
191
|
+
>;
|
|
192
|
+
```
|
|
193
|
+
|
|
194
|
+
A storage marker or host binding's existing change feed.
|
|
195
|
+
|
|
196
|
+
---
|
|
197
|
+
|
|
198
|
+
### appDeclaredGillSchema
|
|
199
|
+
|
|
200
|
+
```ts
|
|
201
|
+
const appDeclaredGillSchema: Schema.Codec<AppDeclaredGill>;
|
|
202
|
+
```
|
|
203
|
+
|
|
204
|
+
Digest-covered identity, source, context and desktop sizes of a Gill.
|
|
205
|
+
|
|
206
|
+
---
|
|
207
|
+
|
|
208
|
+
### gillParamsSchema
|
|
209
|
+
|
|
210
|
+
```ts
|
|
211
|
+
const gillParamsSchema: $Record<String, String>;
|
|
212
|
+
```
|
|
213
|
+
|
|
214
|
+
Placement values are bounded; the admitting host checks declared keys.
|
|
215
|
+
|
|
216
|
+
---
|
|
217
|
+
|
|
218
|
+
### gillRequestSchema
|
|
219
|
+
|
|
220
|
+
```ts
|
|
221
|
+
const gillRequestSchema: Struct<{
|
|
222
|
+
viewId: String;
|
|
223
|
+
params: optional<$Record<String, String>>;
|
|
224
|
+
after: optional<String>;
|
|
225
|
+
options: optional<String>;
|
|
226
|
+
}>;
|
|
227
|
+
```
|
|
228
|
+
|
|
229
|
+
The caller supplies placement context and a source-owned continuation.
|
|
230
|
+
|
|
231
|
+
---
|
|
232
|
+
|
|
233
|
+
### gillCallSchema
|
|
234
|
+
|
|
235
|
+
```ts
|
|
236
|
+
const gillCallSchema: Struct<{
|
|
237
|
+
id: String;
|
|
238
|
+
params: optional<$Record<String, String>>;
|
|
239
|
+
after: optional<String>;
|
|
240
|
+
options: optional<String>;
|
|
241
|
+
}>;
|
|
242
|
+
```
|
|
243
|
+
|
|
244
|
+
Runtime call selected by the host after admitting a declared source.
|
|
245
|
+
|
|
246
|
+
---
|
|
247
|
+
|
|
248
|
+
### gillResponseSchema
|
|
249
|
+
|
|
250
|
+
```ts
|
|
251
|
+
const gillResponseSchema: Union<readonly [Struct<{
|
|
252
|
+
viewId: String;
|
|
253
|
+
title: String;
|
|
254
|
+
state: Literal<"empty">;
|
|
255
|
+
rows: Tuple<readonly []>;
|
|
256
|
+
next: optional<String>;
|
|
257
|
+
}>, Struct<{
|
|
258
|
+
viewId: String;
|
|
259
|
+
title: String;
|
|
260
|
+
state: Literal<"error">;
|
|
261
|
+
rows: Tuple<readonly []>;
|
|
262
|
+
reason: optional<Literals<readonly ["exec_isolation_required", "params_required"]>>;
|
|
263
|
+
error: String;
|
|
264
|
+
recovery: optional<Union<readonly [Struct<{
|
|
265
|
+
kind: Literal<"configure">;
|
|
266
|
+
param: String;
|
|
267
|
+
}>, Struct<{
|
|
268
|
+
kind: Literal<"open">;
|
|
269
|
+
}>]>>;
|
|
270
|
+
}>, Struct<{
|
|
271
|
+
viewId: String;
|
|
272
|
+
title: String;
|
|
273
|
+
state: Literal<"full">;
|
|
274
|
+
rows: $Array<Struct<{
|
|
275
|
+
id: String;
|
|
276
|
+
title: String;
|
|
277
|
+
detail: optional<String>;
|
|
278
|
+
tone: optional<Literals<readonly ["attention", "running", "error", "settled", "muted"]>>;
|
|
279
|
+
status: optional<Struct<{
|
|
280
|
+
label: String;
|
|
281
|
+
tone: Literals<...>;
|
|
282
|
+
}>>;
|
|
283
|
+
open: optional<Struct<{
|
|
284
|
+
params: $Array<...>;
|
|
285
|
+
}>>;
|
|
286
|
+
}>>;
|
|
287
|
+
next: optional<String>;
|
|
288
|
+
}>]>;
|
|
289
|
+
```
|
|
290
|
+
|
|
291
|
+
Shared response codec. Rows are plain text and cannot carry executable UI.
|
|
292
|
+
|
|
293
|
+
---
|
|
294
|
+
|
|
295
|
+
### decodeGillResponse
|
|
296
|
+
|
|
297
|
+
```ts
|
|
298
|
+
const decodeGillResponse: (
|
|
299
|
+
input,
|
|
300
|
+
options?,
|
|
301
|
+
) =>
|
|
302
|
+
| {
|
|
303
|
+
viewId: string;
|
|
304
|
+
title: string;
|
|
305
|
+
state: "empty";
|
|
306
|
+
rows: readonly [];
|
|
307
|
+
next?: string;
|
|
308
|
+
}
|
|
309
|
+
| {
|
|
310
|
+
viewId: string;
|
|
311
|
+
title: string;
|
|
312
|
+
state: "error";
|
|
313
|
+
rows: readonly [];
|
|
314
|
+
reason?: "exec_isolation_required" | "params_required";
|
|
315
|
+
error: string;
|
|
316
|
+
recovery?:
|
|
317
|
+
| {
|
|
318
|
+
kind: "configure";
|
|
319
|
+
param: string;
|
|
320
|
+
}
|
|
321
|
+
| {
|
|
322
|
+
kind: "open";
|
|
323
|
+
};
|
|
324
|
+
}
|
|
325
|
+
| {
|
|
326
|
+
viewId: string;
|
|
327
|
+
title: string;
|
|
328
|
+
state: "full";
|
|
329
|
+
rows: readonly object[];
|
|
330
|
+
next?: string;
|
|
331
|
+
};
|
|
332
|
+
```
|
|
333
|
+
|
|
334
|
+
Decode backend output once at the App host boundary.
|
|
335
|
+
|
|
336
|
+
#### Parameters
|
|
337
|
+
|
|
338
|
+
| Parameter | Type |
|
|
339
|
+
| ---------- | -------------- |
|
|
340
|
+
| `input` | `unknown` |
|
|
341
|
+
| `options?` | `ParseOptions` |
|
|
342
|
+
|
|
343
|
+
#### Returns
|
|
344
|
+
|
|
345
|
+
##### Type Literal
|
|
346
|
+
|
|
347
|
+
```ts
|
|
348
|
+
{
|
|
349
|
+
viewId: string;
|
|
350
|
+
title: string;
|
|
351
|
+
state: "empty";
|
|
352
|
+
rows: readonly [];
|
|
353
|
+
next?: string;
|
|
354
|
+
}
|
|
355
|
+
```
|
|
356
|
+
|
|
357
|
+
---
|
|
358
|
+
|
|
359
|
+
##### Type Literal
|
|
360
|
+
|
|
361
|
+
```ts
|
|
362
|
+
{
|
|
363
|
+
viewId: string;
|
|
364
|
+
title: string;
|
|
365
|
+
state: "error";
|
|
366
|
+
rows: readonly [];
|
|
367
|
+
reason?: "exec_isolation_required" | "params_required";
|
|
368
|
+
error: string;
|
|
369
|
+
recovery?: | {
|
|
370
|
+
kind: "configure";
|
|
371
|
+
param: string;
|
|
372
|
+
}
|
|
373
|
+
| {
|
|
374
|
+
kind: "open";
|
|
375
|
+
};
|
|
376
|
+
}
|
|
377
|
+
```
|
|
378
|
+
|
|
379
|
+
| Name | Type | Default value | Description |
|
|
380
|
+
| ----------- | ----------------------------------------------------------------------------- | ------------- | --------------------------------------------------------------------------------- |
|
|
381
|
+
| `viewId` | `string` | `identity` | - |
|
|
382
|
+
| `title` | `string` | `label` | - |
|
|
383
|
+
| `state` | `"error"` | - | - |
|
|
384
|
+
| `rows` | readonly \[\] | - | - |
|
|
385
|
+
| `reason?` | `"exec_isolation_required"` \| `"params_required"` | - | Host-owned permanent execution refusal; an ordinary error may still be refreshed. |
|
|
386
|
+
| `error` | `string` | - | - |
|
|
387
|
+
| `recovery?` | \| \{ `kind`: `"configure"`; `param`: `string`; \} \| \{ `kind`: `"open"`; \} | - | The host supplies the same-placement picker and this App's launch. |
|
|
388
|
+
|
|
389
|
+
---
|
|
390
|
+
|
|
391
|
+
##### Type Literal
|
|
392
|
+
|
|
393
|
+
```ts
|
|
394
|
+
{
|
|
395
|
+
viewId: string;
|
|
396
|
+
title: string;
|
|
397
|
+
state: "full";
|
|
398
|
+
rows: readonly object[];
|
|
399
|
+
next?: string;
|
|
400
|
+
}
|
|
401
|
+
```
|
|
402
|
+
|
|
403
|
+
---
|
|
404
|
+
|
|
405
|
+
### gillOptionsResponseSchema
|
|
406
|
+
|
|
407
|
+
```ts
|
|
408
|
+
const gillOptionsResponseSchema: Struct<{
|
|
409
|
+
options: $Array<
|
|
410
|
+
Struct<{
|
|
411
|
+
value: String;
|
|
412
|
+
label: String;
|
|
413
|
+
detail: optional<String>;
|
|
414
|
+
}>
|
|
415
|
+
>;
|
|
416
|
+
next: optional<String>;
|
|
417
|
+
}>;
|
|
418
|
+
```
|
|
419
|
+
|
|
420
|
+
A bounded choice page returned by an App-owned options read method.
|
|
421
|
+
|
|
422
|
+
---
|
|
423
|
+
|
|
424
|
+
### gillReplySchema
|
|
425
|
+
|
|
426
|
+
```ts
|
|
427
|
+
const gillReplySchema: Union<readonly [Union<readonly [Struct<{
|
|
428
|
+
viewId: String;
|
|
429
|
+
title: String;
|
|
430
|
+
state: Literal<"empty">;
|
|
431
|
+
rows: Tuple<readonly []>;
|
|
432
|
+
next: optional<String>;
|
|
433
|
+
}>, Struct<{
|
|
434
|
+
viewId: String;
|
|
435
|
+
title: String;
|
|
436
|
+
state: Literal<"error">;
|
|
437
|
+
rows: Tuple<readonly []>;
|
|
438
|
+
reason: optional<Literals<readonly ["exec_isolation_required", "params_required"]>>;
|
|
439
|
+
error: String;
|
|
440
|
+
recovery: optional<Union<readonly [Struct<{
|
|
441
|
+
kind: ...;
|
|
442
|
+
param: ...;
|
|
443
|
+
}>, Struct<{
|
|
444
|
+
kind: ...;
|
|
445
|
+
}>]>>;
|
|
446
|
+
}>, Struct<{
|
|
447
|
+
viewId: String;
|
|
448
|
+
title: String;
|
|
449
|
+
state: Literal<"full">;
|
|
450
|
+
rows: $Array<Struct<{
|
|
451
|
+
id: String;
|
|
452
|
+
title: String;
|
|
453
|
+
detail: optional<String>;
|
|
454
|
+
tone: optional<Literals<...>>;
|
|
455
|
+
status: optional<Struct<...>>;
|
|
456
|
+
open: optional<Struct<...>>;
|
|
457
|
+
}>>;
|
|
458
|
+
next: optional<String>;
|
|
459
|
+
}>]>, Struct<{
|
|
460
|
+
options: $Array<Struct<{
|
|
461
|
+
value: String;
|
|
462
|
+
label: String;
|
|
463
|
+
detail: optional<String>;
|
|
464
|
+
}>>;
|
|
465
|
+
next: optional<String>;
|
|
466
|
+
}>]>;
|
|
467
|
+
```
|
|
468
|
+
|
|
469
|
+
Shared wire for a rows read or a placement-options read.
|
|
470
|
+
|
|
471
|
+
---
|
|
472
|
+
|
|
473
|
+
### decodeGillReply
|
|
474
|
+
|
|
475
|
+
```ts
|
|
476
|
+
const decodeGillReply: (
|
|
477
|
+
input,
|
|
478
|
+
options?,
|
|
479
|
+
) =>
|
|
480
|
+
| {
|
|
481
|
+
viewId: string;
|
|
482
|
+
title: string;
|
|
483
|
+
state: "empty";
|
|
484
|
+
rows: readonly [];
|
|
485
|
+
next?: string;
|
|
486
|
+
}
|
|
487
|
+
| {
|
|
488
|
+
viewId: string;
|
|
489
|
+
title: string;
|
|
490
|
+
state: "error";
|
|
491
|
+
rows: readonly [];
|
|
492
|
+
reason?: "exec_isolation_required" | "params_required";
|
|
493
|
+
error: string;
|
|
494
|
+
recovery?:
|
|
495
|
+
| {
|
|
496
|
+
kind: "configure";
|
|
497
|
+
param: string;
|
|
498
|
+
}
|
|
499
|
+
| {
|
|
500
|
+
kind: "open";
|
|
501
|
+
};
|
|
502
|
+
}
|
|
503
|
+
| {
|
|
504
|
+
viewId: string;
|
|
505
|
+
title: string;
|
|
506
|
+
state: "full";
|
|
507
|
+
rows: readonly object[];
|
|
508
|
+
next?: string;
|
|
509
|
+
}
|
|
510
|
+
| {
|
|
511
|
+
options: readonly object[];
|
|
512
|
+
next?: string;
|
|
513
|
+
};
|
|
514
|
+
```
|
|
515
|
+
|
|
516
|
+
Decode the selected host's bounded reply before rendering or navigation.
|
|
517
|
+
|
|
518
|
+
#### Parameters
|
|
519
|
+
|
|
520
|
+
| Parameter | Type |
|
|
521
|
+
| ---------- | -------------- |
|
|
522
|
+
| `input` | `unknown` |
|
|
523
|
+
| `options?` | `ParseOptions` |
|
|
524
|
+
|
|
525
|
+
#### Returns
|
|
526
|
+
|
|
527
|
+
##### Type Literal
|
|
528
|
+
|
|
529
|
+
```ts
|
|
530
|
+
{
|
|
531
|
+
viewId: string;
|
|
532
|
+
title: string;
|
|
533
|
+
state: "empty";
|
|
534
|
+
rows: readonly [];
|
|
535
|
+
next?: string;
|
|
536
|
+
}
|
|
537
|
+
```
|
|
538
|
+
|
|
539
|
+
---
|
|
540
|
+
|
|
541
|
+
##### Type Literal
|
|
542
|
+
|
|
543
|
+
```ts
|
|
544
|
+
{
|
|
545
|
+
viewId: string;
|
|
546
|
+
title: string;
|
|
547
|
+
state: "error";
|
|
548
|
+
rows: readonly [];
|
|
549
|
+
reason?: "exec_isolation_required" | "params_required";
|
|
550
|
+
error: string;
|
|
551
|
+
recovery?: | {
|
|
552
|
+
kind: "configure";
|
|
553
|
+
param: string;
|
|
554
|
+
}
|
|
555
|
+
| {
|
|
556
|
+
kind: "open";
|
|
557
|
+
};
|
|
558
|
+
}
|
|
559
|
+
```
|
|
560
|
+
|
|
561
|
+
| Name | Type | Default value | Description |
|
|
562
|
+
| ----------- | ----------------------------------------------------------------------------- | ------------- | --------------------------------------------------------------------------------- |
|
|
563
|
+
| `viewId` | `string` | `identity` | - |
|
|
564
|
+
| `title` | `string` | `label` | - |
|
|
565
|
+
| `state` | `"error"` | - | - |
|
|
566
|
+
| `rows` | readonly \[\] | - | - |
|
|
567
|
+
| `reason?` | `"exec_isolation_required"` \| `"params_required"` | - | Host-owned permanent execution refusal; an ordinary error may still be refreshed. |
|
|
568
|
+
| `error` | `string` | - | - |
|
|
569
|
+
| `recovery?` | \| \{ `kind`: `"configure"`; `param`: `string`; \} \| \{ `kind`: `"open"`; \} | - | The host supplies the same-placement picker and this App's launch. |
|
|
570
|
+
|
|
571
|
+
---
|
|
572
|
+
|
|
573
|
+
##### Type Literal
|
|
574
|
+
|
|
575
|
+
```ts
|
|
576
|
+
{
|
|
577
|
+
viewId: string;
|
|
578
|
+
title: string;
|
|
579
|
+
state: "full";
|
|
580
|
+
rows: readonly object[];
|
|
581
|
+
next?: string;
|
|
582
|
+
}
|
|
583
|
+
```
|
|
584
|
+
|
|
585
|
+
---
|
|
586
|
+
|
|
587
|
+
##### Type Literal
|
|
588
|
+
|
|
589
|
+
```ts
|
|
590
|
+
{
|
|
591
|
+
options: readonly object[];
|
|
592
|
+
next?: string;
|
|
593
|
+
}
|
|
594
|
+
```
|
|
595
|
+
|
|
596
|
+
---
|
|
597
|
+
|
|
598
|
+
### decodeGillOptionsResponse
|
|
599
|
+
|
|
600
|
+
```ts
|
|
601
|
+
const decodeGillOptionsResponse: (input, options?) => object;
|
|
602
|
+
```
|
|
603
|
+
|
|
604
|
+
Decode an options method's result without trusting extra fields.
|
|
605
|
+
|
|
606
|
+
#### Parameters
|
|
607
|
+
|
|
608
|
+
| Parameter | Type |
|
|
609
|
+
| ---------- | -------------- |
|
|
610
|
+
| `input` | `unknown` |
|
|
611
|
+
| `options?` | `ParseOptions` |
|
|
612
|
+
|
|
613
|
+
#### Returns
|
|
614
|
+
|
|
615
|
+
`object`
|
|
616
|
+
|
|
617
|
+
| Name | Type |
|
|
618
|
+
| --------- | ------------------- |
|
|
619
|
+
| `options` | readonly `object`[] |
|
|
620
|
+
| `next?` | `string` |
|
|
621
|
+
|
|
622
|
+
---
|
|
623
|
+
|
|
624
|
+
### rowLabelSchemaV1
|
|
625
|
+
|
|
626
|
+
```ts
|
|
627
|
+
const rowLabelSchemaV1: String;
|
|
628
|
+
```
|
|
629
|
+
|
|
630
|
+
Nonempty display text, bounded to 4,096 characters.
|
|
631
|
+
|
|
632
|
+
---
|
|
633
|
+
|
|
634
|
+
### rowIdentitySchemaV1
|
|
635
|
+
|
|
636
|
+
```ts
|
|
637
|
+
const rowIdentitySchemaV1: String;
|
|
638
|
+
```
|
|
639
|
+
|
|
640
|
+
Producer-owned row identity, bounded to 513 characters.
|
|
641
|
+
|
|
642
|
+
---
|
|
643
|
+
|
|
644
|
+
### rowOpenSchemaV1
|
|
645
|
+
|
|
646
|
+
```ts
|
|
647
|
+
const rowOpenSchemaV1: Struct<{
|
|
648
|
+
params: $Array<
|
|
649
|
+
Struct<{
|
|
650
|
+
key: String;
|
|
651
|
+
value: String;
|
|
652
|
+
}>
|
|
653
|
+
>;
|
|
654
|
+
}>;
|
|
655
|
+
```
|
|
656
|
+
|
|
657
|
+
A navigation parameter interpreted only by the receiving App.
|
|
658
|
+
|
|
659
|
+
---
|
|
660
|
+
|
|
661
|
+
### rowSchemaV1
|
|
662
|
+
|
|
663
|
+
```ts
|
|
664
|
+
const rowSchemaV1: Struct<{
|
|
665
|
+
id: String;
|
|
666
|
+
title: String;
|
|
667
|
+
detail: optional<String>;
|
|
668
|
+
tone: optional<
|
|
669
|
+
Literals<readonly ["attention", "running", "error", "settled", "muted"]>
|
|
670
|
+
>;
|
|
671
|
+
status: optional<
|
|
672
|
+
Struct<{
|
|
673
|
+
label: String;
|
|
674
|
+
tone: Literals<
|
|
675
|
+
readonly [
|
|
676
|
+
"neutral",
|
|
677
|
+
"primary",
|
|
678
|
+
"secondary",
|
|
679
|
+
"accent",
|
|
680
|
+
"success",
|
|
681
|
+
"info",
|
|
682
|
+
"warning",
|
|
683
|
+
"error",
|
|
684
|
+
]
|
|
685
|
+
>;
|
|
686
|
+
}>
|
|
687
|
+
>;
|
|
688
|
+
open: optional<
|
|
689
|
+
Struct<{
|
|
690
|
+
params: $Array<
|
|
691
|
+
Struct<{
|
|
692
|
+
key: String;
|
|
693
|
+
value: String;
|
|
694
|
+
}>
|
|
695
|
+
>;
|
|
696
|
+
}>
|
|
697
|
+
>;
|
|
698
|
+
}>;
|
|
699
|
+
```
|
|
700
|
+
|
|
701
|
+
A bounded text row; each receiving host authorizes its open target.
|
|
702
|
+
|
|
703
|
+
---
|
|
704
|
+
|
|
705
|
+
### rowPageSchemaV1
|
|
706
|
+
|
|
707
|
+
```ts
|
|
708
|
+
const rowPageSchemaV1: $Array<
|
|
709
|
+
Struct<{
|
|
710
|
+
id: String;
|
|
711
|
+
title: String;
|
|
712
|
+
detail: optional<String>;
|
|
713
|
+
tone: optional<
|
|
714
|
+
Literals<readonly ["attention", "running", "error", "settled", "muted"]>
|
|
715
|
+
>;
|
|
716
|
+
status: optional<
|
|
717
|
+
Struct<{
|
|
718
|
+
label: String;
|
|
719
|
+
tone: Literals<
|
|
720
|
+
readonly [
|
|
721
|
+
"neutral",
|
|
722
|
+
"primary",
|
|
723
|
+
"secondary",
|
|
724
|
+
"accent",
|
|
725
|
+
"success",
|
|
726
|
+
"info",
|
|
727
|
+
"warning",
|
|
728
|
+
"error",
|
|
729
|
+
]
|
|
730
|
+
>;
|
|
731
|
+
}>
|
|
732
|
+
>;
|
|
733
|
+
open: optional<
|
|
734
|
+
Struct<{
|
|
735
|
+
params: $Array<
|
|
736
|
+
Struct<{
|
|
737
|
+
key: String;
|
|
738
|
+
value: String;
|
|
739
|
+
}>
|
|
740
|
+
>;
|
|
741
|
+
}>
|
|
742
|
+
>;
|
|
743
|
+
}>
|
|
744
|
+
>;
|
|
745
|
+
```
|
|
746
|
+
|
|
747
|
+
A page containing at most 200 shared rows.
|
|
748
|
+
|
|
749
|
+
## Functions
|
|
750
|
+
|
|
751
|
+
### decodeDeclaredGillResponse()
|
|
752
|
+
|
|
753
|
+
```ts
|
|
754
|
+
function decodeDeclaredGillResponse(
|
|
755
|
+
response,
|
|
756
|
+
declaration,
|
|
757
|
+
):
|
|
758
|
+
| {
|
|
759
|
+
viewId: string;
|
|
760
|
+
title: string;
|
|
761
|
+
state: "empty";
|
|
762
|
+
rows: readonly [];
|
|
763
|
+
next?: string;
|
|
764
|
+
}
|
|
765
|
+
| {
|
|
766
|
+
viewId: string;
|
|
767
|
+
title: string;
|
|
768
|
+
state: "error";
|
|
769
|
+
rows: readonly [];
|
|
770
|
+
reason?: "exec_isolation_required" | "params_required";
|
|
771
|
+
error: string;
|
|
772
|
+
recovery?:
|
|
773
|
+
| {
|
|
774
|
+
kind: "configure";
|
|
775
|
+
param: string;
|
|
776
|
+
}
|
|
777
|
+
| {
|
|
778
|
+
kind: "open";
|
|
779
|
+
};
|
|
780
|
+
}
|
|
781
|
+
| {
|
|
782
|
+
viewId: string;
|
|
783
|
+
title: string;
|
|
784
|
+
state: "full";
|
|
785
|
+
rows: readonly object[];
|
|
786
|
+
next?: string;
|
|
787
|
+
};
|
|
788
|
+
```
|
|
789
|
+
|
|
790
|
+
App output must match its digest-covered view identity.
|
|
791
|
+
|
|
792
|
+
#### Parameters
|
|
793
|
+
|
|
794
|
+
| Parameter | Type |
|
|
795
|
+
| ------------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
|
|
796
|
+
| `response` | \| \{ `viewId`: `string`; `title`: `string`; `state`: `"empty"`; `rows`: readonly \[\]; `next?`: `string`; \} \| \{ `viewId`: `string`; `title`: `string`; `state`: `"error"`; `rows`: readonly \[\]; `reason?`: `"exec_isolation_required"` \| `"params_required"`; `error`: `string`; `recovery?`: \| \{ `kind`: `"configure"`; `param`: `string`; \} \| \{ `kind`: `"open"`; \}; \} \| \{ `viewId`: `string`; `title`: `string`; `state`: `"full"`; `rows`: readonly `object`[]; `next?`: `string`; \} |
|
|
797
|
+
| `declaration` | `Pick`\<[`AppDeclaredGill`](#appdeclaredgill), `"id"` \| `"params"`\> |
|
|
798
|
+
|
|
799
|
+
#### Returns
|
|
800
|
+
|
|
801
|
+
##### Type Literal
|
|
802
|
+
|
|
803
|
+
```ts
|
|
804
|
+
{
|
|
805
|
+
viewId: string;
|
|
806
|
+
title: string;
|
|
807
|
+
state: "empty";
|
|
808
|
+
rows: readonly [];
|
|
809
|
+
next?: string;
|
|
810
|
+
}
|
|
811
|
+
```
|
|
812
|
+
|
|
813
|
+
---
|
|
814
|
+
|
|
815
|
+
##### Type Literal
|
|
816
|
+
|
|
817
|
+
```ts
|
|
818
|
+
{
|
|
819
|
+
viewId: string;
|
|
820
|
+
title: string;
|
|
821
|
+
state: "error";
|
|
822
|
+
rows: readonly [];
|
|
823
|
+
reason?: "exec_isolation_required" | "params_required";
|
|
824
|
+
error: string;
|
|
825
|
+
recovery?: | {
|
|
826
|
+
kind: "configure";
|
|
827
|
+
param: string;
|
|
828
|
+
}
|
|
829
|
+
| {
|
|
830
|
+
kind: "open";
|
|
831
|
+
};
|
|
832
|
+
}
|
|
833
|
+
```
|
|
834
|
+
|
|
835
|
+
| Name | Type | Default value | Description |
|
|
836
|
+
| ----------- | ----------------------------------------------------------------------------- | ------------- | --------------------------------------------------------------------------------- |
|
|
837
|
+
| `viewId` | `string` | `identity` | - |
|
|
838
|
+
| `title` | `string` | `label` | - |
|
|
839
|
+
| `state` | `"error"` | - | - |
|
|
840
|
+
| `rows` | readonly \[\] | - | - |
|
|
841
|
+
| `reason?` | `"exec_isolation_required"` \| `"params_required"` | - | Host-owned permanent execution refusal; an ordinary error may still be refreshed. |
|
|
842
|
+
| `error` | `string` | - | - |
|
|
843
|
+
| `recovery?` | \| \{ `kind`: `"configure"`; `param`: `string`; \} \| \{ `kind`: `"open"`; \} | - | The host supplies the same-placement picker and this App's launch. |
|
|
844
|
+
|
|
845
|
+
---
|
|
846
|
+
|
|
847
|
+
##### Type Literal
|
|
848
|
+
|
|
849
|
+
```ts
|
|
850
|
+
{
|
|
851
|
+
viewId: string;
|
|
852
|
+
title: string;
|
|
853
|
+
state: "full";
|
|
854
|
+
rows: readonly object[];
|
|
855
|
+
next?: string;
|
|
856
|
+
}
|
|
857
|
+
```
|
|
858
|
+
|
|
859
|
+
---
|
|
860
|
+
|
|
861
|
+
### createGillClient()
|
|
862
|
+
|
|
863
|
+
```ts
|
|
864
|
+
function createGillClient(options): object;
|
|
865
|
+
```
|
|
866
|
+
|
|
867
|
+
Authenticated host Fetch stays outside App code and is pinned to one selection.
|
|
868
|
+
|
|
869
|
+
#### Parameters
|
|
870
|
+
|
|
871
|
+
| Parameter | Type |
|
|
872
|
+
| --------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
873
|
+
| `options` | `Readonly`\<\{ `decodeRefusal?`: (`raw`, `declaration`) => [`GillResponse`](#gillresponse) \| `undefined`; `endpoint`: `string`; `fetch`: _typeof_ `globalThis.fetch`; `declaration`: `Pick`\<[`AppDeclaredGill`](#appdeclaredgill), `"id"` \| `"title"` \| `"params"`\>; \}\> |
|
|
874
|
+
|
|
875
|
+
#### Returns
|
|
876
|
+
|
|
877
|
+
| Name | Type | Description |
|
|
878
|
+
| ----------- | --------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- | -------------------------------------------------------------- |
|
|
879
|
+
| `request()` | (`selectors`, `signal?`) => `Promise`\< \| \{ `viewId`: `string`; `title`: `string`; `state`: `"empty"`; `rows`: readonly \[\]; `next?`: `string`; \} \| \{ `viewId`: `string`; `title`: `string`; `state`: `"error"`; `rows`: readonly \[\]; `reason?`: `"exec_isolation_required"` \| `"params_required"`; `error`: `string`; `recovery?`: \| \{ `kind`: `"configure"`; `param`: `string`; \} \| \{ `kind`: `"open"`; \}; \} \| \{ `viewId`: `string`; `title`: `string`; `state`: `"full"`; `rows`: readonly `object`[]; `next?`: `string`; \} \| \{ `options`: readonly `object`[]; `next?`: `string`; \}\> | Fetch one decoded page using this client's pinned declaration. |
|