@immediately-run/preauth-core 0.1.11 → 0.1.12
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/dist/capabilities.d.ts +8 -7
- package/dist/capabilities.js +23 -6
- package/package.json +1 -1
package/dist/capabilities.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export type CapabilityKind = 'read' | 'action';
|
|
2
2
|
export type CapabilityTier = 'baseline' | 'elevated' | 'first-party-only';
|
|
3
|
-
export type Capability = 'theme:read' | 'theme:set' | 'auth:status' | 'auth:identity' | 'route:read' | 'formFactor:read' | 'mounts:read' | 'mounts:registry' | 'spaces:app' | 'spaces:user' | 'spaces:admin' | 'settings:app' | 'settings:fork' | 'settings:all' | 'contribute:self' | 'contribute:any' | 'contribute:direct' | 'editor:read' | 'editor:open' | 'editor:write' | 'editor:document' | 'editor:requestEdit' | 'vcs:read' | 'vcs:reset' | 'dnd:source' | 'catalog:read' | 'commands:read' | 'commands:run' | 'ipc' | 'task:invoke' | 'net:fetch' | 'secrets:add' | 'secrets:list' | 'secrets:revoke' | 'agent:session' | 'diagnostics:read' | 'llm:chat' | 'authoring:run' | 'analytics:emit';
|
|
3
|
+
export type Capability = 'theme:read' | 'theme:set' | 'auth:status' | 'auth:identity' | 'route:read' | 'formFactor:read' | 'chrome:read' | 'mounts:read' | 'mounts:registry' | 'spaces:app' | 'spaces:user' | 'spaces:admin' | 'settings:app' | 'settings:fork' | 'settings:all' | 'contribute:self' | 'contribute:any' | 'contribute:direct' | 'editor:read' | 'editor:open' | 'editor:write' | 'editor:document' | 'editor:requestEdit' | 'vcs:read' | 'vcs:reset' | 'dnd:source' | 'catalog:read' | 'commands:read' | 'commands:run' | 'ipc' | 'task:invoke' | 'net:fetch' | 'secrets:add' | 'secrets:list' | 'secrets:revoke' | 'agent:session' | 'diagnostics:read' | 'llm:chat' | 'authoring:run' | 'analytics:emit';
|
|
4
4
|
export interface CapabilityDef {
|
|
5
5
|
kind: CapabilityKind;
|
|
6
6
|
tier: CapabilityTier;
|
|
@@ -31,12 +31,13 @@ export interface CapabilityDef {
|
|
|
31
31
|
maximallyExplicit?: boolean;
|
|
32
32
|
}
|
|
33
33
|
export declare const CAPABILITIES: Record<Capability, CapabilityDef>;
|
|
34
|
-
/** The current registry/vocabulary version (§5.11). Bumped to 1.
|
|
35
|
-
*
|
|
36
|
-
*
|
|
37
|
-
* `
|
|
38
|
-
* `llm:chat` slot; 1.2.0 added the
|
|
39
|
-
|
|
34
|
+
/** The current registry/vocabulary version (§5.11). Bumped to 1.7.0 with the baseline
|
|
35
|
+
* state read `chrome:read` (PRESENT_MODE_CHROME_SPEC §6 — R3-191), mirroring
|
|
36
|
+
* capabilities.json. (1.6.0 added the elevated, app-scoped, parameterized
|
|
37
|
+
* `analytics:emit`; 1.5.0 added the first-party-only `mounts:registry`; 1.4.0 added
|
|
38
|
+
* `authoring:run`; 1.3.0 added the provider-agnostic `llm:chat` slot; 1.2.0 added the
|
|
39
|
+
* per-user settings-space capabilities.) */
|
|
40
|
+
export declare const REGISTRY_VERSION = "1.7.0";
|
|
40
41
|
/** Is `cap` a known host-core capability? (Closed vocabulary — §5.12.) */
|
|
41
42
|
export declare function isKnownCapability(cap: string): cap is Capability;
|
|
42
43
|
export declare function tierOf(cap: Capability): CapabilityTier;
|
package/dist/capabilities.js
CHANGED
|
@@ -226,13 +226,30 @@ exports.CAPABILITIES = {
|
|
|
226
226
|
// publisher could observe their aggregates and then ship an alphabet tuned to encode
|
|
227
227
|
// what they now want to read, under a grant the user gave for a different one.
|
|
228
228
|
'analytics:emit': { kind: 'action', tier: 'elevated', since: '1.6.0', parameterized: true, appScoped: true },
|
|
229
|
+
// PRESENT_MODE_CHROME_SPEC §6 (R-PMC-17, R3-191): read the host's own present-mode
|
|
230
|
+
// chrome state — whether the platform menu/sheet is open over the app, and which
|
|
231
|
+
// edge the reveal tab sits on — so a platform-aware app MAY pause an animation
|
|
232
|
+
// while it is dimmed, or keep its corner clear of the tab.
|
|
233
|
+
//
|
|
234
|
+
// **BASELINE, alongside `formFactor:read`.** Both are reads of the HOST's own UI
|
|
235
|
+
// state, not of anything app-foreign: the app already knows it is being displayed,
|
|
236
|
+
// and "chrome is currently over you" discloses nothing about the user, other apps,
|
|
237
|
+
// the filesystem, or the network. There is no `chrome:set` counterpart — an app
|
|
238
|
+
// cannot operate platform chrome, only observe it, so this cannot become an
|
|
239
|
+
// authority-escalation path.
|
|
240
|
+
//
|
|
241
|
+
// R-PMC-18 is the reason it can be baseline without a consent line at all: no
|
|
242
|
+
// platform behavior may depend on an app consuming this channel, so an app that
|
|
243
|
+
// never reads it is indistinguishable from one that does.
|
|
244
|
+
'chrome:read': { kind: 'read', tier: 'baseline', since: '1.7.0' },
|
|
229
245
|
};
|
|
230
|
-
/** The current registry/vocabulary version (§5.11). Bumped to 1.
|
|
231
|
-
*
|
|
232
|
-
*
|
|
233
|
-
* `
|
|
234
|
-
* `llm:chat` slot; 1.2.0 added the
|
|
235
|
-
|
|
246
|
+
/** The current registry/vocabulary version (§5.11). Bumped to 1.7.0 with the baseline
|
|
247
|
+
* state read `chrome:read` (PRESENT_MODE_CHROME_SPEC §6 — R3-191), mirroring
|
|
248
|
+
* capabilities.json. (1.6.0 added the elevated, app-scoped, parameterized
|
|
249
|
+
* `analytics:emit`; 1.5.0 added the first-party-only `mounts:registry`; 1.4.0 added
|
|
250
|
+
* `authoring:run`; 1.3.0 added the provider-agnostic `llm:chat` slot; 1.2.0 added the
|
|
251
|
+
* per-user settings-space capabilities.) */
|
|
252
|
+
exports.REGISTRY_VERSION = '1.7.0';
|
|
236
253
|
/** Is `cap` a known host-core capability? (Closed vocabulary — §5.12.) */
|
|
237
254
|
function isKnownCapability(cap) {
|
|
238
255
|
return Object.prototype.hasOwnProperty.call(exports.CAPABILITIES, cap);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@immediately-run/preauth-core",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.12",
|
|
4
4
|
"description": "The shared §8.9 pre-auth target check + the single grant-mint path (mintConsentedGrants) + the capability vocabulary + the byte-faithful grant/space/net-fetch document layout. Consumed by site-main (browser Firestore) and the backend (admin Firestore) so there is ONE gate, ONE mint path, ONE wire layout.",
|
|
5
5
|
"license": "UNLICENSED",
|
|
6
6
|
"repository": {
|