@popmelt.com/core 0.23.0 → 0.24.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 +30 -0
- package/claude-plugin/.claude-plugin/plugin.json +1 -1
- package/claude-plugin/skills/popmelt-core/SKILL.md +1 -0
- package/codex-plugin/.codex-plugin/plugin.json +1 -1
- package/codex-plugin/skills/popmelt-core/SKILL.md +1 -0
- package/dist/ParticipantRuntime-SS2IDRLA.mjs +139 -0
- package/dist/PreviewRuntime-NGTLOEX3.mjs +2 -0
- package/dist/adapter-react-three-fiber.d.mts +1 -1
- package/dist/adapter-react-three-fiber.mjs +1 -1
- package/dist/bridge-entry.mjs +88 -86
- package/dist/browser-runtime-HYKTQV6Q.mjs +2 -0
- package/dist/browser.d.mts +4 -3
- package/dist/browser.mjs +1 -1
- package/dist/{chunk-4IUZX7YN.mjs → chunk-3MO7Z4DV.mjs} +1 -1
- package/dist/chunk-3XSTOVWX.mjs +2 -0
- package/dist/{chunk-EXYZQ76K.mjs → chunk-4WAFUF5Y.mjs} +1 -1
- package/dist/chunk-7W3RBRFM.mjs +301 -0
- package/dist/chunk-B5KUI32Q.mjs +413 -0
- package/dist/chunk-ENERPQJN.mjs +2 -0
- package/dist/chunk-EX63NVDN.mjs +2 -0
- package/dist/chunk-J3UIBBU2.mjs +1 -1
- package/dist/chunk-N2ZEZCHO.mjs +1 -1
- package/dist/cli.mjs +101 -97
- package/dist/index.d.mts +6 -6
- package/dist/index.mjs +1 -1
- package/dist/media.d.mts +3 -3
- package/dist/media.mjs +1 -1
- package/dist/{options-5yRxW1AX.d.mts → participantBootstrap-BQHbHI4r.d.mts} +24 -3
- package/dist/plugin-astro.d.mts +2 -0
- package/dist/plugin-astro.mjs +3 -3
- package/dist/plugin-nuxt.d.mts +3 -1
- package/dist/plugin-nuxt.mjs +2 -1
- package/dist/plugin-vite.mjs +1 -1
- package/dist/server-OPX7SKA7.mjs +228 -0
- package/dist/server.d.mts +121 -1
- package/dist/server.mjs +98 -87
- package/dist/{subjects-DzjWdlAk.d.mts → subjects-BM3Smdow.d.mts} +6 -1
- package/dist/{video-adapter-CCLbp86L.d.mts → video-adapter-Gm5gmoiz.d.mts} +1 -1
- package/package.json +25 -23
- package/dist/browser-runtime-FWYFRPVT.mjs +0 -2
- package/dist/chunk-VHUJQWVP.mjs +0 -453
- package/dist/server-7AUQAYVY.mjs +0 -217
package/dist/server.d.mts
CHANGED
|
@@ -1,5 +1,73 @@
|
|
|
1
|
+
import * as node_http from 'node:http';
|
|
2
|
+
import { IncomingMessage, ServerResponse } from 'node:http';
|
|
3
|
+
|
|
4
|
+
declare const STICKER_COLOR_NAMES: readonly ["slate", "gray", "zinc", "neutral", "stone", "red", "orange", "amber", "yellow", "lime", "green", "emerald", "teal", "cyan", "sky", "blue", "indigo", "violet", "purple", "fuchsia", "pink", "rose"];
|
|
5
|
+
type StickerColorName = (typeof STICKER_COLOR_NAMES)[number];
|
|
6
|
+
|
|
7
|
+
declare const STICKER_FAMILIES: readonly ["padding", "margin", "border", "radius", "stack", "grid", "text", "color", "transform", "opacity"];
|
|
8
|
+
type StickerFamily = (typeof STICKER_FAMILIES)[number];
|
|
9
|
+
type StickerSubproperty = 'all' | 'x' | 'y' | 'top' | 'right' | 'bottom' | 'left' | 'top-left' | 'top-right' | 'bottom-right' | 'bottom-left' | 'vertical' | 'horizontal' | 'direction' | 'gap' | 'align' | 'justify' | 'rows' | 'columns' | 'size' | 'weight' | 'line-height' | 'letter-spacing' | 'text-align' | 'color' | 'translate' | 'scale' | 'rotate' | 'opacity' | 'mix-blend' | StickerColorName;
|
|
10
|
+
|
|
1
11
|
type Provider = 'claude' | 'codex' | 'copilot' | 'omp';
|
|
2
12
|
|
|
13
|
+
/** Renderer-owned identity for a target that does not exist as a DOM node. */
|
|
14
|
+
type OpaqueTargetReference = {
|
|
15
|
+
adapter: string;
|
|
16
|
+
key: string;
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
/** Local preview protocol. Peers never supply reducer actions or host authority. */
|
|
20
|
+
type PeerAction = {
|
|
21
|
+
type: 'tokens';
|
|
22
|
+
family?: StickerFamily;
|
|
23
|
+
subproperty?: StickerSubproperty;
|
|
24
|
+
} | {
|
|
25
|
+
type: 'inspect';
|
|
26
|
+
selector: string;
|
|
27
|
+
target?: OpaqueTargetReference;
|
|
28
|
+
properties?: string[];
|
|
29
|
+
plane?: 'own' | 'host';
|
|
30
|
+
} | {
|
|
31
|
+
type: 'comment';
|
|
32
|
+
selector: string;
|
|
33
|
+
target?: OpaqueTargetReference;
|
|
34
|
+
text: string;
|
|
35
|
+
} | {
|
|
36
|
+
type: 'clear';
|
|
37
|
+
selector: string;
|
|
38
|
+
kind: 'comment' | 'style' | 'all';
|
|
39
|
+
} | {
|
|
40
|
+
type: 'style';
|
|
41
|
+
selector: string;
|
|
42
|
+
property: string;
|
|
43
|
+
value: string;
|
|
44
|
+
} | {
|
|
45
|
+
type: 'style';
|
|
46
|
+
selector: string;
|
|
47
|
+
token: string;
|
|
48
|
+
family?: StickerFamily;
|
|
49
|
+
} | {
|
|
50
|
+
type: 'attention';
|
|
51
|
+
selector: string | null;
|
|
52
|
+
target?: OpaqueTargetReference;
|
|
53
|
+
activity?: 'looking' | 'working';
|
|
54
|
+
} | {
|
|
55
|
+
type: 'undo' | 'redo' | 'send' | 'rebase';
|
|
56
|
+
};
|
|
57
|
+
|
|
58
|
+
/** A capability for a person/agent. Keep out of URLs, logs, and peer snapshots. */
|
|
59
|
+
type ParticipantCredential = {
|
|
60
|
+
participantId: string;
|
|
61
|
+
token: string;
|
|
62
|
+
};
|
|
63
|
+
|
|
64
|
+
/** Browser hosting is replaceable; this boundary owns only local agent enrollment. */
|
|
65
|
+
type ParticipantAgentView = {
|
|
66
|
+
act(action: PeerAction): Promise<unknown>;
|
|
67
|
+
close(): Promise<void>;
|
|
68
|
+
};
|
|
69
|
+
type ParticipantAgentAdapter = (credential: ParticipantCredential) => Promise<ParticipantAgentView>;
|
|
70
|
+
|
|
3
71
|
type ImprintExplanationKind = 'intention' | 'principle' | 'pattern';
|
|
4
72
|
type ImprintExplanationState = 'emerging' | 'testing' | 'grounded' | 'challenged' | 'retired';
|
|
5
73
|
type ImprintScopeKind = 'project' | 'route' | 'component' | 'selector' | 'file';
|
|
@@ -200,14 +268,66 @@ type PopmeltOptions = {
|
|
|
200
268
|
/** Optional Chromium DevTools endpoint, e.g. http://127.0.0.1:9222. */
|
|
201
269
|
nativeCaptureUrl?: string;
|
|
202
270
|
restartMode?: 'embedded' | 'detached';
|
|
271
|
+
/** Internal opt-in. Collaboration authority is independent of app revisions. */
|
|
272
|
+
participantSessions?: {
|
|
273
|
+
/** Optional context metadata. Never used as a save, Send, or approval gate. */
|
|
274
|
+
sourceRevision?: () => Promise<string>;
|
|
275
|
+
agentAdapter?: ParticipantAgentAdapter;
|
|
276
|
+
};
|
|
203
277
|
};
|
|
204
278
|
type PopmeltHandle = {
|
|
205
279
|
port: number;
|
|
206
280
|
projectId: string;
|
|
207
281
|
storeId?: string;
|
|
282
|
+
/** Trusted local launch/recovery only; never publish this capability in HTML. */
|
|
283
|
+
participantHost?: () => Promise<ParticipantCredential>;
|
|
208
284
|
close: () => Promise<void>;
|
|
209
285
|
};
|
|
210
286
|
|
|
287
|
+
/** One disposable, local Chrome profile per agent. Never attaches to a user's browser. */
|
|
288
|
+
declare function managedParticipantBrowser(url: string): ParticipantAgentAdapter;
|
|
289
|
+
|
|
290
|
+
/** Same-origin host continuity adapter. A private claim or existing host proof is
|
|
291
|
+
* mandatory before issuing the HttpOnly recovery capability. Localhost is not proof. */
|
|
292
|
+
declare function createParticipantHostEntry(options: {
|
|
293
|
+
projectRoot: string;
|
|
294
|
+
projectId: string;
|
|
295
|
+
origin: string;
|
|
296
|
+
host: () => Promise<ParticipantCredential>;
|
|
297
|
+
}): Promise<{
|
|
298
|
+
handler: (req: IncomingMessage, res: ServerResponse) => Promise<void>;
|
|
299
|
+
claimUrl: string;
|
|
300
|
+
}>;
|
|
301
|
+
|
|
302
|
+
/** Public, credential-free description stamped by the application's dev server.
|
|
303
|
+
* The revision is context metadata (or `unversioned`), never sync/Send authority.
|
|
304
|
+
*/
|
|
305
|
+
type ParticipantBootstrapConfig = {
|
|
306
|
+
version?: 1;
|
|
307
|
+
url: string;
|
|
308
|
+
projectId: string;
|
|
309
|
+
revision: string;
|
|
310
|
+
};
|
|
311
|
+
declare global {
|
|
312
|
+
interface Window {
|
|
313
|
+
__POPMELT_PARTICIPANTS__?: ParticipantBootstrapConfig;
|
|
314
|
+
}
|
|
315
|
+
}
|
|
316
|
+
|
|
317
|
+
/** Dev-server boundary: identify the project and optional source context, and
|
|
318
|
+
* keep host proof in a private local file, never in public bootstrap metadata.
|
|
319
|
+
* The framework owns the bridge lifecycle. No source hashing is required.
|
|
320
|
+
*/
|
|
321
|
+
declare function createParticipantDevBootstrap(options: {
|
|
322
|
+
projectRoot: string;
|
|
323
|
+
origin: string;
|
|
324
|
+
bridge: PopmeltHandle;
|
|
325
|
+
sourceRevision?: () => Promise<string>;
|
|
326
|
+
}): Promise<{
|
|
327
|
+
hostEntry: (req: node_http.IncomingMessage, res: node_http.ServerResponse) => Promise<void>;
|
|
328
|
+
read(): Promise<ParticipantBootstrapConfig>;
|
|
329
|
+
}>;
|
|
330
|
+
|
|
211
331
|
type ImprintManifest = {
|
|
212
332
|
version: 1;
|
|
213
333
|
topologyVersion?: 2;
|
|
@@ -416,4 +536,4 @@ type StartPopmeltOptions = PopmeltOptions & {
|
|
|
416
536
|
};
|
|
417
537
|
declare function startPopmelt(options?: StartPopmeltOptions): Promise<PopmeltHandle>;
|
|
418
538
|
|
|
419
|
-
export { type ImprintConcrete, type ImprintContext, type ImprintEvidence, type ImprintExplanation, type ImprintExplanationKind, type ImprintExplanationRef, type ImprintExplanationState, type ImprintGraph, type ImprintGroundingAction, type ImprintMutation, type ImprintRelation, type ImprintRelationType, type ImprintScope, ImprintService, ImprintStore, type ImprintThreadSummary, type ImprintTransaction, type PopmeltHandle, type PopmeltOptions, type QualifiedImprintRelation, type StartPopmeltOptions, formatImprintPrompt, imprintExplanationRef, parseImprintDraft, qualifyImprintRelation, startPopmelt };
|
|
539
|
+
export { type ImprintConcrete, type ImprintContext, type ImprintEvidence, type ImprintExplanation, type ImprintExplanationKind, type ImprintExplanationRef, type ImprintExplanationState, type ImprintGraph, type ImprintGroundingAction, type ImprintMutation, type ImprintRelation, type ImprintRelationType, type ImprintScope, ImprintService, ImprintStore, type ImprintThreadSummary, type ImprintTransaction, type ParticipantAgentAdapter, type ParticipantAgentView, type PopmeltHandle, type PopmeltOptions, type QualifiedImprintRelation, type StartPopmeltOptions, createParticipantDevBootstrap, createParticipantHostEntry, formatImprintPrompt, imprintExplanationRef, managedParticipantBrowser, parseImprintDraft, qualifyImprintRelation, startPopmelt };
|