@fungi.computer/oyster 0.0.0-stage → 0.0.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/LICENSE +21 -0
- package/README.md +1082 -2
- package/dist/agents.d.ts +114 -0
- package/dist/agents.js +322 -0
- package/dist/app-builds.d.ts +151 -0
- package/dist/app-builds.js +355 -0
- package/dist/app-sandbox.d.ts +2 -0
- package/dist/app-sandbox.js +2 -0
- package/dist/app-sources.d.ts +46 -0
- package/dist/app-sources.js +335 -0
- package/dist/app-storage.d.ts +141 -0
- package/dist/app-storage.js +281 -0
- package/dist/apps/gate.d.ts +105 -0
- package/dist/apps/gate.js +273 -0
- package/dist/apps/index.d.ts +5 -0
- package/dist/apps/index.js +5 -0
- package/dist/apps/installation.d.ts +248 -0
- package/dist/apps/installation.js +307 -0
- package/dist/apps/operations.d.ts +8 -0
- package/dist/apps/operations.js +98 -0
- package/dist/apps/tools.d.ts +33 -0
- package/dist/apps/tools.js +17 -0
- package/dist/auth.d.ts +11 -0
- package/dist/auth.js +93 -0
- package/dist/backend-request.d.ts +3 -0
- package/dist/backend-request.js +53 -0
- package/dist/build/build-jobs.d.ts +128 -0
- package/dist/build/build-jobs.js +197 -0
- package/dist/build/build-step.d.ts +26 -0
- package/dist/build/build-step.js +20 -0
- package/dist/build/bundled-html.d.ts +7 -0
- package/dist/build/bundled-html.js +64 -0
- package/dist/build/definition-emission.d.ts +34 -0
- package/dist/build/definition-emission.js +201 -0
- package/dist/build/effect.d.ts +231 -0
- package/dist/build/effect.js +396 -0
- package/dist/build/git-environment.d.ts +6 -0
- package/dist/build/git-environment.js +48 -0
- package/dist/build/html-recipe.d.ts +20 -0
- package/dist/build/html-recipe.js +51 -0
- package/dist/build/local-build.d.ts +57 -0
- package/dist/build/local-build.js +1078 -0
- package/dist/build/r2-artifact-writer.d.ts +31 -0
- package/dist/build/r2-artifact-writer.js +179 -0
- package/dist/build/snapshot-package-store.d.ts +2 -0
- package/dist/build/snapshot-package-store.js +21 -0
- package/dist/build/snapshot-program-scripts.d.ts +6 -0
- package/dist/build/snapshot-program-scripts.js +2 -0
- package/dist/build/submission-contract.d.ts +384 -0
- package/dist/build/submission-contract.js +70 -0
- package/dist/build/workspace-build.d.ts +50 -0
- package/dist/build/workspace-build.js +156 -0
- package/dist/build-contract.d.ts +4 -0
- package/dist/build-contract.js +4 -0
- package/dist/build-jobs.d.ts +2 -0
- package/dist/build-jobs.js +2 -0
- package/dist/build.d.ts +11 -0
- package/dist/build.js +13 -0
- package/dist/capability-descriptor.d.ts +46 -0
- package/dist/capability-descriptor.js +51 -0
- package/dist/catalog-frame.d.ts +39 -0
- package/dist/catalog-frame.js +72 -0
- package/dist/cause-class.d.ts +19 -0
- package/dist/cause-class.js +54 -0
- package/dist/cloudflare.d.ts +123 -0
- package/dist/cloudflare.js +391 -0
- package/dist/computer-terminal.d.ts +38 -0
- package/dist/computer-terminal.js +410 -0
- package/dist/computer.d.ts +60 -0
- package/dist/computer.js +33 -0
- package/dist/event-recipients.d.ts +57 -0
- package/dist/event-recipients.js +144 -0
- package/dist/facet-invocation.d.ts +4 -0
- package/dist/facet-invocation.js +45 -0
- package/dist/files.d.ts +42 -0
- package/dist/files.js +123 -0
- package/dist/frame-binding-wire-script.d.ts +2 -0
- package/dist/frame-binding-wire-script.js +1 -0
- package/dist/frame-binding-wire.d.ts +28 -0
- package/dist/frame-binding-wire.js +54 -0
- package/dist/git-admission.d.ts +52 -0
- package/dist/git-admission.js +188 -0
- package/dist/git-auth.d.ts +11 -0
- package/dist/git-auth.js +27 -0
- package/dist/git-door.d.ts +35 -0
- package/dist/git-door.js +108 -0
- package/dist/git-journal.d.ts +31 -0
- package/dist/git-journal.js +188 -0
- package/dist/git.d.ts +31 -0
- package/dist/git.js +64 -0
- package/dist/guest-policy.d.ts +9 -0
- package/dist/guest-policy.js +13 -0
- package/dist/host.d.ts +244 -0
- package/dist/host.js +1043 -0
- package/dist/index.d.ts +166 -0
- package/dist/index.js +320 -0
- package/dist/installation-consent.d.ts +79 -0
- package/dist/installation-consent.js +82 -0
- package/dist/internal/background-origins.d.ts +3 -0
- package/dist/internal/background-origins.js +8 -0
- package/dist/internal/delivery.d.ts +12 -0
- package/dist/internal/delivery.js +167 -0
- package/dist/internal/host-gate.d.ts +14 -0
- package/dist/internal/host-gate.js +62 -0
- package/dist/internal/registry-installations.d.ts +6 -0
- package/dist/internal/registry-installations.js +12 -0
- package/dist/invocation.d.ts +251 -0
- package/dist/invocation.js +377 -0
- package/dist/keys.d.ts +48 -0
- package/dist/keys.js +52 -0
- package/dist/mcp-owner.d.ts +27 -0
- package/dist/mcp-owner.js +143 -0
- package/dist/mcp.d.ts +89 -0
- package/dist/mcp.js +429 -0
- package/dist/media.d.ts +23 -0
- package/dist/media.js +12 -0
- package/dist/pack.d.ts +76 -0
- package/dist/pack.js +134 -0
- package/dist/page/capabilities.d.ts +23 -0
- package/dist/page/capabilities.js +256 -0
- package/dist/page/computer-handles.d.ts +79 -0
- package/dist/page/computer-handles.js +44 -0
- package/dist/page/lifetime.d.ts +6 -0
- package/dist/page/lifetime.js +19 -0
- package/dist/page/mount.d.ts +163 -0
- package/dist/page/mount.js +390 -0
- package/dist/page/storage.d.ts +3 -0
- package/dist/page/storage.js +82 -0
- package/dist/page/terminal.d.ts +5 -0
- package/dist/page/terminal.js +7 -0
- package/dist/page-script.d.ts +14 -0
- package/dist/page-script.js +5 -0
- package/dist/r2-files.d.ts +3 -0
- package/dist/r2-files.js +79 -0
- package/dist/release.d.ts +72 -0
- package/dist/release.js +164 -0
- package/dist/root-data.d.ts +86 -0
- package/dist/root-data.js +69 -0
- package/dist/shell/app-directory.d.ts +537 -0
- package/dist/shell/app-directory.js +195 -0
- package/dist/shell/browser-actions.d.ts +7 -0
- package/dist/shell/browser-actions.js +56 -0
- package/dist/shell/command-host.d.ts +112 -0
- package/dist/shell/command-host.js +502 -0
- package/dist/shell/commands.d.ts +25 -0
- package/dist/shell/commands.js +78 -0
- package/dist/shell/index.d.ts +8 -0
- package/dist/shell/index.js +8 -0
- package/dist/shell/keys.d.ts +41 -0
- package/dist/shell/keys.js +134 -0
- package/dist/shell/shell-module.d.ts +31 -0
- package/dist/shell/shell-module.js +37 -0
- package/dist/shell/window-manager.d.ts +124 -0
- package/dist/shell/window-manager.js +711 -0
- package/dist/shell/workbench-contract.d.ts +68 -0
- package/dist/shell/workbench-contract.js +1 -0
- package/dist/shell/workbench-host-types.d.ts +96 -0
- package/dist/shell/workbench-host-types.js +1 -0
- package/dist/shell/workbench-host.d.ts +34 -0
- package/dist/shell/workbench-host.js +347 -0
- package/dist/shell/workbench-model.d.ts +192 -0
- package/dist/shell/workbench-model.js +53 -0
- package/dist/shell/workbench.d.ts +4 -0
- package/dist/shell/workbench.js +2 -0
- package/dist/source/fork.d.ts +27 -0
- package/dist/source/fork.js +46 -0
- package/dist/source/index.d.ts +11 -0
- package/dist/source/index.js +11 -0
- package/dist/source/seed-receipt.d.ts +53 -0
- package/dist/source/seed-receipt.js +18 -0
- package/dist/source/team-source.d.ts +32 -0
- package/dist/source/team-source.js +42 -0
- package/dist/source/template-repository.d.ts +2 -0
- package/dist/source/template-repository.js +8 -0
- package/dist/source/template-write.d.ts +69 -0
- package/dist/source/template-write.js +344 -0
- package/dist/storage-frame.d.ts +64 -0
- package/dist/storage-frame.js +28 -0
- package/dist/tenant.d.ts +81 -0
- package/dist/tenant.js +71 -0
- package/dist/testing/capabilities.d.ts +29 -0
- package/dist/testing/capabilities.js +130 -0
- package/dist/testing/catalog.d.ts +3 -0
- package/dist/testing/catalog.js +53 -0
- package/dist/testing/index.d.ts +10 -0
- package/dist/testing/index.js +10 -0
- package/dist/testing/installation.d.ts +11 -0
- package/dist/testing/installation.js +25 -0
- package/dist/testing/native-worker.d.ts +21 -0
- package/dist/testing/native-worker.js +106 -0
- package/dist/testing/worker.d.ts +18 -0
- package/dist/testing/worker.js +67 -0
- package/dist/testing/workers-runtime.d.ts +24 -0
- package/dist/testing/workers-runtime.js +33 -0
- package/dist/webhook-delivery.d.ts +14 -0
- package/dist/webhook-delivery.js +17 -0
- package/dist/workers-git.d.ts +285 -0
- package/dist/workers-git.js +1174 -0
- package/dist/workers.d.ts +352 -0
- package/dist/workers.js +866 -0
- package/docs/api/README.md +82 -0
- package/docs/api/agents.md +332 -0
- package/docs/api/app-storage.md +209 -0
- package/docs/api/apps.md +1375 -0
- package/docs/api/auth.md +63 -0
- package/docs/api/build-contract.md +507 -0
- package/docs/api/build.md +1476 -0
- package/docs/api/cloudflare.md +421 -0
- package/docs/api/computer.md +203 -0
- package/docs/api/files.md +117 -0
- package/docs/api/git.md +470 -0
- package/docs/api/host.md +1328 -0
- package/docs/api/index.md +430 -0
- package/docs/api/invocation.md +738 -0
- package/docs/api/keys.md +175 -0
- package/docs/api/mcp.md +301 -0
- package/docs/api/media.md +40 -0
- package/docs/api/modules.md +42 -0
- package/docs/api/pack.md +138 -0
- package/docs/api/page/mount.md +298 -0
- package/docs/api/root-data.md +111 -0
- package/docs/api/shell/app-directory.md +332 -0
- package/docs/api/shell/command-host.md +224 -0
- package/docs/api/shell/commands.md +197 -0
- package/docs/api/shell/keys.md +183 -0
- package/docs/api/shell/shell-module.md +143 -0
- package/docs/api/shell/window-manager.md +267 -0
- package/docs/api/shell/workbench.md +186 -0
- package/docs/api/shell.md +1788 -0
- package/docs/api/tenant.md +194 -0
- package/docs/api/workers-git.md +1527 -0
- package/docs/api/workers.md +1678 -0
- package/docs/media/architecture.mmd +32 -0
- package/docs/media/architecture.png +0 -0
- package/docs/media/bonsai-network.png +0 -0
- package/docs/media/bonsai-repository.png +0 -0
- package/docs/site/agent-quickstart.mdx +349 -0
- package/examples/git/worker.ts +39 -0
- package/examples/git/wrangler.jsonc +32 -0
- package/examples/standalone/worker.ts +14 -0
- package/examples/standalone/wrangler.jsonc +21 -0
- package/package.json +249 -3
|
@@ -0,0 +1,332 @@
|
|
|
1
|
+
<!-- Generated by Botanical API docs (TypeDoc + typedoc-plugin-markdown). Do not edit. -->
|
|
2
|
+
|
|
3
|
+
[**@fungi.computer/oyster**](../README.md)
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
[@fungi.computer/oyster](../modules.md) / shell/app-directory
|
|
8
|
+
|
|
9
|
+
# shell/app-directory
|
|
10
|
+
|
|
11
|
+
## Type Aliases
|
|
12
|
+
|
|
13
|
+
### AppAddress
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
type AppAddress = z.output<typeof appAddressSchema>;
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
Decoded address of a default App or an installation.
|
|
20
|
+
|
|
21
|
+
---
|
|
22
|
+
|
|
23
|
+
### AppAuthorityEnforcement
|
|
24
|
+
|
|
25
|
+
```ts
|
|
26
|
+
type AppAuthorityEnforcement = z.output<typeof appAuthorityEnforcementSchema>;
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
A host-reported authority change and its remaining work.
|
|
30
|
+
|
|
31
|
+
---
|
|
32
|
+
|
|
33
|
+
### AppDirectoryGill
|
|
34
|
+
|
|
35
|
+
```ts
|
|
36
|
+
type AppDirectoryGill = {
|
|
37
|
+
[
|
|
38
|
+
Field in keyof Schema.Schema.Type<typeof appDeclaredGillSchema>
|
|
39
|
+
]: Schema.Schema.Type<typeof appDeclaredGillSchema>[Field];
|
|
40
|
+
};
|
|
41
|
+
```
|
|
42
|
+
|
|
43
|
+
A Release-declared Gill carried by the host's App directory. The named mapped
|
|
44
|
+
type keeps consumer declarations attached to this public contract.
|
|
45
|
+
|
|
46
|
+
---
|
|
47
|
+
|
|
48
|
+
### AppDirectoryEntry
|
|
49
|
+
|
|
50
|
+
```ts
|
|
51
|
+
type AppDirectoryEntry = z.output<typeof appDirectoryEntrySchema>;
|
|
52
|
+
```
|
|
53
|
+
|
|
54
|
+
An App directory row before host-specific permissions are attached.
|
|
55
|
+
|
|
56
|
+
---
|
|
57
|
+
|
|
58
|
+
### AppCatalog
|
|
59
|
+
|
|
60
|
+
```ts
|
|
61
|
+
type AppCatalog = z.output<typeof appCatalogResponseSchema>;
|
|
62
|
+
```
|
|
63
|
+
|
|
64
|
+
Parsed metadata returned by the read-only APPS.catalog binding.
|
|
65
|
+
|
|
66
|
+
## Variables
|
|
67
|
+
|
|
68
|
+
### appAddressSchema
|
|
69
|
+
|
|
70
|
+
```ts
|
|
71
|
+
const appAddressSchema: ZodUnion<
|
|
72
|
+
readonly [
|
|
73
|
+
ZodObject<
|
|
74
|
+
{
|
|
75
|
+
kind: ZodLiteral<"default">;
|
|
76
|
+
appId: ZodString;
|
|
77
|
+
},
|
|
78
|
+
$strict
|
|
79
|
+
>,
|
|
80
|
+
ZodObject<
|
|
81
|
+
{
|
|
82
|
+
kind: ZodLiteral<"installation">;
|
|
83
|
+
installationId: ZodString;
|
|
84
|
+
},
|
|
85
|
+
$strict
|
|
86
|
+
>,
|
|
87
|
+
]
|
|
88
|
+
>;
|
|
89
|
+
```
|
|
90
|
+
|
|
91
|
+
An App address selects a host default or a specific installation.
|
|
92
|
+
|
|
93
|
+
---
|
|
94
|
+
|
|
95
|
+
### appAuthorityEnforcementSchema
|
|
96
|
+
|
|
97
|
+
```ts
|
|
98
|
+
const appAuthorityEnforcementSchema: ZodObject<
|
|
99
|
+
{
|
|
100
|
+
requestId: ZodString;
|
|
101
|
+
address: ZodUnion<
|
|
102
|
+
readonly [
|
|
103
|
+
ZodObject<
|
|
104
|
+
{
|
|
105
|
+
kind: ZodLiteral<"default">;
|
|
106
|
+
appId: ZodString;
|
|
107
|
+
},
|
|
108
|
+
$strict
|
|
109
|
+
>,
|
|
110
|
+
ZodObject<
|
|
111
|
+
{
|
|
112
|
+
kind: ZodLiteral<"installation">;
|
|
113
|
+
installationId: ZodString;
|
|
114
|
+
},
|
|
115
|
+
$strict
|
|
116
|
+
>,
|
|
117
|
+
]
|
|
118
|
+
>;
|
|
119
|
+
authorityVersion: ZodNumber;
|
|
120
|
+
state: ZodEnum<{
|
|
121
|
+
pending: "pending";
|
|
122
|
+
expired: "expired";
|
|
123
|
+
unaffected: "unaffected";
|
|
124
|
+
applied: "applied";
|
|
125
|
+
}>;
|
|
126
|
+
outstanding: ZodNumber;
|
|
127
|
+
},
|
|
128
|
+
$strict
|
|
129
|
+
>;
|
|
130
|
+
```
|
|
131
|
+
|
|
132
|
+
Host-reported progress of applying a revised App authority version.
|
|
133
|
+
|
|
134
|
+
---
|
|
135
|
+
|
|
136
|
+
### appDirectoryEntrySchema
|
|
137
|
+
|
|
138
|
+
```ts
|
|
139
|
+
const appDirectoryEntrySchema: ZodObject<{
|
|
140
|
+
address: ZodUnion<readonly [ZodObject<{
|
|
141
|
+
kind: ZodLiteral<"default">;
|
|
142
|
+
appId: ZodString;
|
|
143
|
+
}, $strict>, ZodObject<{
|
|
144
|
+
kind: ZodLiteral<"installation">;
|
|
145
|
+
installationId: ZodString;
|
|
146
|
+
}, $strict>]>;
|
|
147
|
+
installationId: ZodNullable<ZodString>;
|
|
148
|
+
surfaceId: ZodString;
|
|
149
|
+
appId: ZodString;
|
|
150
|
+
displayName: ZodOptional<ZodString>;
|
|
151
|
+
icon: ZodOptional<ZodNullable<ZodString>>;
|
|
152
|
+
releaseId: ZodNullable<ZodString>;
|
|
153
|
+
authorityVersion: ZodNumber;
|
|
154
|
+
enforcement: ZodNullable<ZodObject<{
|
|
155
|
+
requestId: ZodString;
|
|
156
|
+
address: ZodUnion<readonly [ZodObject<{
|
|
157
|
+
kind: ZodLiteral<"default">;
|
|
158
|
+
appId: ZodString;
|
|
159
|
+
}, $strict>, ZodObject<{
|
|
160
|
+
kind: ZodLiteral<"installation">;
|
|
161
|
+
installationId: ZodString;
|
|
162
|
+
}, $strict>]>;
|
|
163
|
+
authorityVersion: ZodNumber;
|
|
164
|
+
state: ZodEnum<{
|
|
165
|
+
pending: "pending";
|
|
166
|
+
expired: "expired";
|
|
167
|
+
unaffected: "unaffected";
|
|
168
|
+
applied: "applied";
|
|
169
|
+
}>;
|
|
170
|
+
outstanding: ZodNumber;
|
|
171
|
+
}, $strict>>;
|
|
172
|
+
handlers: ZodArray<ZodLiteral<"file.open">>;
|
|
173
|
+
roles: ZodArray<ZodString>;
|
|
174
|
+
declaredCapabilities: ZodArray<ZodString>;
|
|
175
|
+
calls: ZodOptional<ZodPipe<ZodUnknown, ZodTransform<readonly object[], unknown>>>;
|
|
176
|
+
commands: ZodPipe<ZodArray<ZodUnknown>, ZodTransform<Readonly<{
|
|
177
|
+
id: string;
|
|
178
|
+
title: string;
|
|
179
|
+
category: string;
|
|
180
|
+
description?: string;
|
|
181
|
+
sigil?: string;
|
|
182
|
+
projections?: Readonly<{
|
|
183
|
+
bindings?: ... | ...;
|
|
184
|
+
agent?: ... | ...;
|
|
185
|
+
help?: ... | ...;
|
|
186
|
+
menu?: ... | ...;
|
|
187
|
+
palette?: ... | ...;
|
|
188
|
+
slash?: ... | ...;
|
|
189
|
+
}>;
|
|
190
|
+
}>[], unknown[]>>;
|
|
191
|
+
gills: ZodPipe<ZodArray<ZodUnknown>, ZodTransform<AppDirectoryGill[], unknown[]>>;
|
|
192
|
+
availability: ZodEnum<{
|
|
193
|
+
unavailable: "unavailable";
|
|
194
|
+
available: "available";
|
|
195
|
+
}>;
|
|
196
|
+
surface: ZodNullable<ZodObject<{
|
|
197
|
+
stableRoute: ZodString;
|
|
198
|
+
}, $strict>>;
|
|
199
|
+
surfacePath: ZodString;
|
|
200
|
+
}, $strict>;
|
|
201
|
+
```
|
|
202
|
+
|
|
203
|
+
Reusable App metadata supplied by an embedding host; it conveys no permissions.
|
|
204
|
+
|
|
205
|
+
---
|
|
206
|
+
|
|
207
|
+
### appRoleSelectionSchema
|
|
208
|
+
|
|
209
|
+
```ts
|
|
210
|
+
const appRoleSelectionSchema: ZodObject<
|
|
211
|
+
{
|
|
212
|
+
surfaceId: ZodNullable<ZodString>;
|
|
213
|
+
chosen: ZodBoolean;
|
|
214
|
+
},
|
|
215
|
+
$strict
|
|
216
|
+
>;
|
|
217
|
+
```
|
|
218
|
+
|
|
219
|
+
A host-resolved role selection; a surface address is not launch authority.
|
|
220
|
+
|
|
221
|
+
---
|
|
222
|
+
|
|
223
|
+
### appCatalogEntrySchema
|
|
224
|
+
|
|
225
|
+
```ts
|
|
226
|
+
const appCatalogEntrySchema: ZodObject<{
|
|
227
|
+
surfaceId: ZodString;
|
|
228
|
+
appId: ZodString;
|
|
229
|
+
displayName: ZodOptional<ZodString>;
|
|
230
|
+
gills: ZodArray<ZodObject<{
|
|
231
|
+
id: ZodString;
|
|
232
|
+
title: ZodString;
|
|
233
|
+
params: ZodOptional<ZodArray<ZodObject<{
|
|
234
|
+
key: ZodString;
|
|
235
|
+
label: ZodString;
|
|
236
|
+
kind: ZodEnum<...>;
|
|
237
|
+
required: ZodBoolean;
|
|
238
|
+
options: ZodOptional<...>;
|
|
239
|
+
}, $strict>> & ZodType<readonly object[], object[], $ZodTypeInternals<readonly object[], object[]>>>;
|
|
240
|
+
desktop: ZodOptional<ZodObject<{
|
|
241
|
+
sizes: ZodArray<ZodEnum<{
|
|
242
|
+
S: ...;
|
|
243
|
+
M: ...;
|
|
244
|
+
L: ...;
|
|
245
|
+
}>>;
|
|
246
|
+
}, $strict>>;
|
|
247
|
+
}, $strict>>;
|
|
248
|
+
}, $strict>;
|
|
249
|
+
```
|
|
250
|
+
|
|
251
|
+
Read-only catalog metadata for one App, without host-specific role policy.
|
|
252
|
+
|
|
253
|
+
---
|
|
254
|
+
|
|
255
|
+
### appCatalogResponseSchema
|
|
256
|
+
|
|
257
|
+
```ts
|
|
258
|
+
const appCatalogResponseSchema: ZodObject<{
|
|
259
|
+
apps: ZodArray<ZodObject<{
|
|
260
|
+
surfaceId: ZodString;
|
|
261
|
+
appId: ZodString;
|
|
262
|
+
displayName: ZodOptional<ZodString>;
|
|
263
|
+
gills: ZodArray<ZodObject<{
|
|
264
|
+
id: ZodString;
|
|
265
|
+
title: ZodString;
|
|
266
|
+
params: ZodOptional<ZodArray<...> & ZodType<..., ..., ...>>;
|
|
267
|
+
desktop: ZodOptional<ZodObject<{
|
|
268
|
+
sizes: ...;
|
|
269
|
+
}, $strict>>;
|
|
270
|
+
}, $strict>>;
|
|
271
|
+
}, $strict>>;
|
|
272
|
+
roles: ZodObject<{
|
|
273
|
+
inbox: ZodOptional<ZodObject<{
|
|
274
|
+
surfaceId: ZodNullable<ZodString>;
|
|
275
|
+
chosen: ZodBoolean;
|
|
276
|
+
}, $strict>>;
|
|
277
|
+
}, $strict>;
|
|
278
|
+
}, $strict>;
|
|
279
|
+
```
|
|
280
|
+
|
|
281
|
+
Read-only desktop metadata; identities are surface addresses, never launch
|
|
282
|
+
authority.
|
|
283
|
+
|
|
284
|
+
---
|
|
285
|
+
|
|
286
|
+
### appCatalogBrokerResultSchema
|
|
287
|
+
|
|
288
|
+
```ts
|
|
289
|
+
const appCatalogBrokerResultSchema: ZodUnion<readonly [ZodObject<{
|
|
290
|
+
apps: ZodArray<ZodObject<{
|
|
291
|
+
surfaceId: ZodString;
|
|
292
|
+
appId: ZodString;
|
|
293
|
+
displayName: ZodOptional<ZodString>;
|
|
294
|
+
gills: ZodArray<ZodObject<{
|
|
295
|
+
id: ZodString;
|
|
296
|
+
title: ZodString;
|
|
297
|
+
params: ZodOptional<...>;
|
|
298
|
+
desktop: ZodOptional<...>;
|
|
299
|
+
}, $strict>>;
|
|
300
|
+
}, $strict>>;
|
|
301
|
+
roles: ZodObject<{
|
|
302
|
+
inbox: ZodOptional<ZodObject<{
|
|
303
|
+
surfaceId: ZodNullable<ZodString>;
|
|
304
|
+
chosen: ZodBoolean;
|
|
305
|
+
}, $strict>>;
|
|
306
|
+
}, $strict>;
|
|
307
|
+
}, $strict>, ZodObject<{
|
|
308
|
+
error: ZodString;
|
|
309
|
+
}, $strict>]>;
|
|
310
|
+
```
|
|
311
|
+
|
|
312
|
+
Complete APPS.catalog reply, including broker admission failures.
|
|
313
|
+
|
|
314
|
+
## Functions
|
|
315
|
+
|
|
316
|
+
### addressKey()
|
|
317
|
+
|
|
318
|
+
```ts
|
|
319
|
+
function addressKey(address): string;
|
|
320
|
+
```
|
|
321
|
+
|
|
322
|
+
Stable identity of one App address across directory and settings views.
|
|
323
|
+
|
|
324
|
+
#### Parameters
|
|
325
|
+
|
|
326
|
+
| Parameter | Type |
|
|
327
|
+
| --------- | --------------------------------------------------------------------------------------------------------------- |
|
|
328
|
+
| `address` | \| \{ `kind`: `"default"`; `appId`: `string`; \} \| \{ `kind`: `"installation"`; `installationId`: `string`; \} |
|
|
329
|
+
|
|
330
|
+
#### Returns
|
|
331
|
+
|
|
332
|
+
`string`
|
|
@@ -0,0 +1,224 @@
|
|
|
1
|
+
<!-- Generated by Botanical API docs (TypeDoc + typedoc-plugin-markdown). Do not edit. -->
|
|
2
|
+
|
|
3
|
+
[**@fungi.computer/oyster**](../README.md)
|
|
4
|
+
|
|
5
|
+
---
|
|
6
|
+
|
|
7
|
+
[@fungi.computer/oyster](../modules.md) / shell/command-host
|
|
8
|
+
|
|
9
|
+
# shell/command-host
|
|
10
|
+
|
|
11
|
+
## Type Aliases
|
|
12
|
+
|
|
13
|
+
### AppCommandOptional
|
|
14
|
+
|
|
15
|
+
```ts
|
|
16
|
+
type AppCommandOptional<T> = T | undefined;
|
|
17
|
+
```
|
|
18
|
+
|
|
19
|
+
An optional field a declaration may carry as explicitly undefined.
|
|
20
|
+
|
|
21
|
+
#### Type Parameters
|
|
22
|
+
|
|
23
|
+
| Type Parameter |
|
|
24
|
+
| -------------- |
|
|
25
|
+
| `T` |
|
|
26
|
+
|
|
27
|
+
---
|
|
28
|
+
|
|
29
|
+
### AppCommandDeclaration
|
|
30
|
+
|
|
31
|
+
```ts
|
|
32
|
+
type AppCommandDeclaration = Readonly<{
|
|
33
|
+
id: string;
|
|
34
|
+
title: string;
|
|
35
|
+
category: string;
|
|
36
|
+
description?: AppCommandOptional<string>;
|
|
37
|
+
projections?: AppCommandOptional<
|
|
38
|
+
Readonly<{
|
|
39
|
+
bindings?: AppCommandOptional<
|
|
40
|
+
Readonly<{
|
|
41
|
+
order?: AppCommandOptional<number>;
|
|
42
|
+
values: readonly string[];
|
|
43
|
+
}>
|
|
44
|
+
>;
|
|
45
|
+
agent?: AppCommandOptional<
|
|
46
|
+
Readonly<{
|
|
47
|
+
order?: AppCommandOptional<number>;
|
|
48
|
+
keybind?: AppCommandOptional<string>;
|
|
49
|
+
}>
|
|
50
|
+
>;
|
|
51
|
+
help?: AppCommandOptional<
|
|
52
|
+
Readonly<{
|
|
53
|
+
order?: AppCommandOptional<number>;
|
|
54
|
+
}>
|
|
55
|
+
>;
|
|
56
|
+
menu?: AppCommandOptional<
|
|
57
|
+
Readonly<{
|
|
58
|
+
order?: AppCommandOptional<number>;
|
|
59
|
+
}>
|
|
60
|
+
>;
|
|
61
|
+
palette?: AppCommandOptional<
|
|
62
|
+
Readonly<{
|
|
63
|
+
order?: AppCommandOptional<number>;
|
|
64
|
+
}>
|
|
65
|
+
>;
|
|
66
|
+
slash?: AppCommandOptional<
|
|
67
|
+
Readonly<{
|
|
68
|
+
order?: AppCommandOptional<number>;
|
|
69
|
+
aliases: readonly string[];
|
|
70
|
+
}>
|
|
71
|
+
>;
|
|
72
|
+
}>
|
|
73
|
+
>;
|
|
74
|
+
}>;
|
|
75
|
+
```
|
|
76
|
+
|
|
77
|
+
The digest-covered command rows a mounted App's Release declares, as the host
|
|
78
|
+
receives them. Oyster compares and projects them; the Release declaration
|
|
79
|
+
grammar stays with its owner, which hands rows of this shape.
|
|
80
|
+
|
|
81
|
+
---
|
|
82
|
+
|
|
83
|
+
### AppSurfaceCommandMount
|
|
84
|
+
|
|
85
|
+
```ts
|
|
86
|
+
type AppSurfaceCommandMount = Readonly<{
|
|
87
|
+
handlers: Pick<AppHostHandlers, "registerCommands" | "invokeReservedChord">;
|
|
88
|
+
dispose: () => void;
|
|
89
|
+
}>;
|
|
90
|
+
```
|
|
91
|
+
|
|
92
|
+
The command side of one mounted App's host handlers.
|
|
93
|
+
|
|
94
|
+
---
|
|
95
|
+
|
|
96
|
+
### PaneCommands
|
|
97
|
+
|
|
98
|
+
```ts
|
|
99
|
+
type PaneCommands = Readonly<{
|
|
100
|
+
commandId: (id) => string;
|
|
101
|
+
contribute: (commands) => WhistleContributionLease;
|
|
102
|
+
execute: WhistleRuntime["execute"];
|
|
103
|
+
snapshot: WhistleRuntime["snapshot"];
|
|
104
|
+
subscribe: WhistleRuntime["subscribe"];
|
|
105
|
+
present: WhistleRuntime["present"];
|
|
106
|
+
}>;
|
|
107
|
+
```
|
|
108
|
+
|
|
109
|
+
Commands owned by one pane, projected to globals plus its focus scope.
|
|
110
|
+
|
|
111
|
+
---
|
|
112
|
+
|
|
113
|
+
### PaneCommandMount
|
|
114
|
+
|
|
115
|
+
```ts
|
|
116
|
+
type PaneCommandMount = PaneCommands &
|
|
117
|
+
Readonly<{
|
|
118
|
+
dispose: () => void;
|
|
119
|
+
}>;
|
|
120
|
+
```
|
|
121
|
+
|
|
122
|
+
Closing a pane withdraws all its leases, presenters and subscriptions.
|
|
123
|
+
|
|
124
|
+
---
|
|
125
|
+
|
|
126
|
+
### AppSurfaceCommandHost
|
|
127
|
+
|
|
128
|
+
```ts
|
|
129
|
+
type AppSurfaceCommandHost = Readonly<{
|
|
130
|
+
mountPane: (paneId) => PaneCommandMount;
|
|
131
|
+
mount: (mountId, declarations) => AppSurfaceCommandMount;
|
|
132
|
+
focus: (mountId) => void;
|
|
133
|
+
registerShellCommands: (commands) => () => void;
|
|
134
|
+
registerDirectoryCommands: (commands, run) => () => void;
|
|
135
|
+
menu: () => readonly WhistleMenuProjection[];
|
|
136
|
+
active: () => WhistleSnapshot;
|
|
137
|
+
execute: (commandId, input) => Promise<WhistleExecutionOutcome>;
|
|
138
|
+
snapshot: () => WhistleSnapshot;
|
|
139
|
+
subscribe: (listener) => () => void;
|
|
140
|
+
dispose: () => void;
|
|
141
|
+
}>;
|
|
142
|
+
```
|
|
143
|
+
|
|
144
|
+
The shell-owned Whistle graph and its focused menu projection.
|
|
145
|
+
|
|
146
|
+
## Variables
|
|
147
|
+
|
|
148
|
+
### appDirectorySourceId
|
|
149
|
+
|
|
150
|
+
```ts
|
|
151
|
+
const appDirectorySourceId: "app-directory" = "app-directory";
|
|
152
|
+
```
|
|
153
|
+
|
|
154
|
+
Whistle source of Release-advertised rows for Apps not yet mounted.
|
|
155
|
+
|
|
156
|
+
## Functions
|
|
157
|
+
|
|
158
|
+
### commandPaletteReservedChordForPlatform()
|
|
159
|
+
|
|
160
|
+
```ts
|
|
161
|
+
function commandPaletteReservedChordForPlatform(mac): AppHostReservedChord;
|
|
162
|
+
```
|
|
163
|
+
|
|
164
|
+
Select the shell command-palette chord for a Mac or non-Mac keyboard.
|
|
165
|
+
|
|
166
|
+
#### Parameters
|
|
167
|
+
|
|
168
|
+
| Parameter | Type |
|
|
169
|
+
| --------- | --------- |
|
|
170
|
+
| `mac` | `boolean` |
|
|
171
|
+
|
|
172
|
+
#### Returns
|
|
173
|
+
|
|
174
|
+
`AppHostReservedChord`
|
|
175
|
+
|
|
176
|
+
---
|
|
177
|
+
|
|
178
|
+
### commandPaletteReservedChordForUserAgent()
|
|
179
|
+
|
|
180
|
+
```ts
|
|
181
|
+
function commandPaletteReservedChordForUserAgent(
|
|
182
|
+
userAgent,
|
|
183
|
+
): AppHostReservedChord;
|
|
184
|
+
```
|
|
185
|
+
|
|
186
|
+
Select the shell command-palette chord from the embedding browser user agent.
|
|
187
|
+
|
|
188
|
+
#### Parameters
|
|
189
|
+
|
|
190
|
+
| Parameter | Type |
|
|
191
|
+
| ----------- | -------- |
|
|
192
|
+
| `userAgent` | `string` |
|
|
193
|
+
|
|
194
|
+
#### Returns
|
|
195
|
+
|
|
196
|
+
`AppHostReservedChord`
|
|
197
|
+
|
|
198
|
+
---
|
|
199
|
+
|
|
200
|
+
### createAppSurfaceCommandHost()
|
|
201
|
+
|
|
202
|
+
```ts
|
|
203
|
+
function createAppSurfaceCommandHost(whistle?): AppSurfaceCommandHost;
|
|
204
|
+
```
|
|
205
|
+
|
|
206
|
+
Own one shell's Whistle runtime for mounted Apps and local panes. The embedding
|
|
207
|
+
host supplies verified Release declarations and decides which App or pane has
|
|
208
|
+
focus.
|
|
209
|
+
|
|
210
|
+
Agar invokes `registerCommands` once for the aggregate command set of a mount.
|
|
211
|
+
The adapter keeps that aggregate as one Whistle generation, so an Agar update
|
|
212
|
+
replaces the generation atomically and disposal releases only that App. Command
|
|
213
|
+
handlers remain the App's callback; the shell only adds the Whistle identity and
|
|
214
|
+
routes focused menu execution to it.
|
|
215
|
+
|
|
216
|
+
#### Parameters
|
|
217
|
+
|
|
218
|
+
| Parameter | Type |
|
|
219
|
+
| --------- | ---------------- |
|
|
220
|
+
| `whistle` | `WhistleRuntime` |
|
|
221
|
+
|
|
222
|
+
#### Returns
|
|
223
|
+
|
|
224
|
+
[`AppSurfaceCommandHost`](#appsurfacecommandhost)
|