@popmelt.com/core 0.40.1 → 0.41.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/claude-plugin/.claude-plugin/plugin.json +1 -1
- package/codex-plugin/.codex-plugin/plugin.json +1 -1
- package/dist/ExploreAttachment-ALV7FL3Y.mjs +1 -0
- package/dist/PagePreviewLayer-UPCGG4EV.mjs +1 -0
- package/dist/ParticipantRuntime-CBUA7BL5.mjs +1 -0
- package/dist/PhoneHostGate-TVNOJYL5.mjs +1 -0
- package/dist/PopmeltProvider-5g-1VH5a.d.mts +15 -0
- package/dist/PopmeltTasteConnectedPane-PD64Q6LF.mjs +1 -0
- package/dist/QueuedReplies-ESF5UL3J.mjs +1 -0
- package/dist/SamplePlacementOverlay-V533Y4XN.mjs +1 -0
- package/dist/ShareProjectPane-PMODH6QQ.mjs +1 -0
- package/dist/SuppliedContext-ADMN2D2I.mjs +1 -0
- package/dist/{ThreadErrorCard-SUFOXXLG.mjs → ThreadErrorCard-KS2XWRT3.mjs} +1 -1
- package/dist/ThreadPanel-5TDPZBAU.mjs +1 -0
- package/dist/adapter-react-three-fiber.d.mts +1 -1
- package/dist/adapter-react-three-fiber.mjs +1 -1
- package/dist/adapter-three.d.mts +1 -1
- package/dist/adapter-three.mjs +1 -1
- package/dist/bridge-entry.mjs +1 -1
- package/dist/browser-runtime-FUXWVGQ7.mjs +1 -0
- package/dist/browser.d.mts +4 -4
- package/dist/browser.mjs +1 -1
- package/dist/canvas-text.d.mts +1 -1
- package/dist/{checkFixture-LBDNT3M5.mjs → checkFixture-42NYMFAK.mjs} +1 -1
- package/dist/chunk-2TA7N3CI.mjs +1 -0
- package/dist/chunk-32BKJ5JN.mjs +1 -0
- package/dist/chunk-3HVPVKWV.mjs +1 -0
- package/dist/chunk-4RQ5XD3I.mjs +1 -0
- package/dist/chunk-5J4BZL6N.mjs +1 -0
- package/dist/chunk-6OPX4CUT.mjs +1 -0
- package/dist/{chunk-4MLXPN7W.mjs → chunk-776SEJZO.mjs} +1 -1
- package/dist/chunk-7OATJ6BO.mjs +1 -0
- package/dist/chunk-7VIC4MGC.mjs +1 -0
- package/dist/chunk-AET77LFV.mjs +1 -0
- package/dist/chunk-ALWPAFIW.mjs +1 -0
- package/dist/chunk-AOFKEBLN.mjs +1 -0
- package/dist/{chunk-6EO73WJN.mjs → chunk-BSVZXOOS.mjs} +1 -1
- package/dist/chunk-D2ONGS5P.mjs +1 -0
- package/dist/chunk-DDUXU6LA.mjs +1 -0
- package/dist/chunk-DMKBAI2Z.mjs +1 -0
- package/dist/chunk-DUWONLQE.mjs +1 -0
- package/dist/chunk-EG6UHPJV.mjs +1 -0
- package/dist/{chunk-XVQAHYF2.mjs → chunk-FZUHHJWW.mjs} +1 -1
- package/dist/{chunk-L3QE62SE.mjs → chunk-GE5BE6PI.mjs} +1 -1
- package/dist/{chunk-K22VZV3V.mjs → chunk-GLF7Z5IR.mjs} +1 -1
- package/dist/chunk-GLIGPLM4.mjs +1 -0
- package/dist/chunk-H3T2O3HA.mjs +1 -0
- package/dist/chunk-HFKGW34E.mjs +1 -0
- package/dist/{chunk-Q5MIJ5F2.mjs → chunk-HFWGYXPG.mjs} +1 -1
- package/dist/{chunk-53QOGFAT.mjs → chunk-ITLRSHNZ.mjs} +1 -1
- package/dist/chunk-JWWWU4GY.mjs +1 -0
- package/dist/chunk-KD2AOPYP.mjs +1 -0
- package/dist/chunk-KE4MQBRY.mjs +1 -0
- package/dist/chunk-KF73S7MG.mjs +1 -0
- package/dist/{chunk-ZQMKLODZ.mjs → chunk-LDDDSIAQ.mjs} +1 -1
- package/dist/chunk-LWPNOBGS.mjs +1 -0
- package/dist/{chunk-MPEVFQ43.mjs → chunk-PCUUOIFD.mjs} +1 -1
- package/dist/chunk-PRZ6C5X3.mjs +1 -0
- package/dist/chunk-PTMHSMZH.mjs +1 -0
- package/dist/chunk-RFTQCRGC.mjs +1 -0
- package/dist/{chunk-DBCCE7BA.mjs → chunk-S2U2IGUO.mjs} +1 -1
- package/dist/{chunk-EUFK7B6S.mjs → chunk-S7IWZSWH.mjs} +1 -1
- package/dist/chunk-SOFNYBJD.mjs +1 -0
- package/dist/chunk-SZQTGYPS.mjs +1 -0
- package/dist/chunk-TA2BMDSC.mjs +30 -0
- package/dist/{chunk-ECWY6Z6K.mjs → chunk-ULR4IDEX.mjs} +1 -1
- package/dist/{chunk-OECEYJNK.mjs → chunk-VJKC2RJB.mjs} +1 -1
- package/dist/chunk-VOL4KS67.mjs +1 -0
- package/dist/chunk-VSWRWS2H.mjs +1 -0
- package/dist/chunk-W5TNOJOR.mjs +1 -0
- package/dist/{chunk-LUTP7QBD.mjs → chunk-WSI2SQWU.mjs} +1 -1
- package/dist/chunk-WWNI7JCA.mjs +1 -0
- package/dist/chunk-XDZUDDYB.mjs +1 -0
- package/dist/chunk-XGSOAF5E.mjs +1 -0
- package/dist/chunk-XHTSKQMB.mjs +1 -0
- package/dist/chunk-YG3RSK5J.mjs +1 -0
- package/dist/chunk-YHCZYT4T.mjs +1 -0
- package/dist/chunk-Z4NMA34Y.mjs +1 -0
- package/dist/chunk-ZXCAONMC.mjs +1 -0
- package/dist/cli.mjs +1 -1
- package/dist/codex-note-context-WX33QFE7.mjs +1 -0
- package/dist/codex-project-77GHT2I3.mjs +1 -0
- package/dist/{codex-session-registry-YNU6LEVH.mjs → codex-session-registry-A3NQRRZ3.mjs} +1 -1
- package/dist/codex-store-mount-KFJYT6AS.mjs +1 -0
- package/dist/dev-app-port-LHUBCOBE.mjs +1 -0
- package/dist/{dev-server-BRrhkH5t.d.mts → dev-server-D8Qxrp1A.d.mts} +2 -1
- package/dist/dev-server-FZJ6HDKP.mjs +1 -0
- package/dist/guest-admission.mjs +1 -1
- package/dist/guest-live-canvas.mjs +1 -1
- package/dist/index.d.mts +9 -25
- package/dist/index.mjs +1 -1
- package/dist/media.d.mts +3 -3
- package/dist/memory-store.d.mts +7 -2
- package/dist/memory.mjs +1 -1
- package/dist/orientation-markup.mjs +1 -0
- package/dist/outline-trace.mjs +1 -0
- package/dist/{page-interaction-YXHXEYOT.mjs → page-interaction-74JGNCZ5.mjs} +1 -1
- package/dist/{page-planes-Jz2yR_Wk.d.mts → page-planes-BeFZ3Wso.d.mts} +15 -472
- package/dist/{participantBootstrap-DDOxY-Cy.d.mts → participantBootstrap-BcfNTEe9.d.mts} +3 -3
- package/dist/peer-client-B2KMU667.mjs +1 -0
- package/dist/phone-app-HNBDX7UX.mjs +1 -0
- package/dist/plain-html-H35WPIRO.mjs +1 -0
- package/dist/plane-history.mjs +1 -0
- package/dist/plugin-astro.d.mts +8 -3
- package/dist/plugin-astro.mjs +1 -1
- package/dist/plugin-nuxt.d.mts +6 -2
- package/dist/plugin-nuxt.mjs +1 -1
- package/dist/plugin-vite.d.mts +10 -5
- package/dist/plugin-vite.mjs +1 -1
- package/dist/protocol-BIUE4rB6.d.mts +9 -0
- package/dist/server.d.mts +14 -3
- package/dist/server.mjs +1 -1
- package/dist/shared-page-6AUYAPJ3.mjs +1 -0
- package/dist/steerStyles-C4YBV4TZ.mjs +1 -0
- package/dist/sticker-colors.mjs +1 -0
- package/dist/sticker-mode.mjs +1 -0
- package/dist/{subjects-cLtt9-iK.d.mts → subjects-qHIrZrlt.d.mts} +57 -1
- package/dist/taste-constraints.mjs +1 -0
- package/dist/taste-contract.mjs +1 -0
- package/dist/taste-fragment.mjs +1 -0
- package/dist/taste-graph-inspection.mjs +1 -0
- package/dist/taste-layout.mjs +1 -0
- package/dist/taste-page-composition.mjs +1 -0
- package/dist/taste-proposal-session-PSI4TX6H.mjs +1 -0
- package/dist/taste-proposal.mjs +1 -0
- package/dist/taste-token-math.mjs +1 -0
- package/dist/thread-request.mjs +1 -0
- package/dist/thread-view-client.d.mts +2 -0
- package/dist/thread-view-client.mjs +1 -0
- package/dist/thread-view.html +136 -0
- package/dist/{video-adapter-xL95wukX.d.mts → video-adapter-B5eap10v.d.mts} +1 -1
- package/infra/phone-pairing/app-listener.cjs +107 -0
- package/infra/phone-pairing/binding.mjs +369 -20
- package/infra/phone-pairing/machine-config.mjs +43 -26
- package/infra/phone-pairing/machine-service.mjs +94 -6
- package/infra/phone-pairing/machine.mjs +5 -1
- package/infra/phone-pairing/reservations.mjs +103 -0
- package/infra/phone-pairing/writer-lock.mjs +107 -0
- package/package.json +30 -35
- package/dist/ExploreAttachment-ZPC5AR5V.mjs +0 -1
- package/dist/PagePreviewLayer-C7WBS7IX.mjs +0 -1
- package/dist/ParticipantRuntime-CWE62D2G.mjs +0 -1
- package/dist/PhoneHostGate-NWJXZBBP.mjs +0 -1
- package/dist/PopmeltTasteConnectedPane-2BNDKMMB.mjs +0 -1
- package/dist/QueuedReplies-5YG2DN3W.mjs +0 -1
- package/dist/SamplePlacementOverlay-ULOV22WR.mjs +0 -1
- package/dist/ShareProjectPane-KEE7EYMP.mjs +0 -1
- package/dist/SuppliedContext-IT25WBGQ.mjs +0 -1
- package/dist/ThreadPanel-NNJHQQSD.mjs +0 -1
- package/dist/browser-runtime-G6AEOA4X.mjs +0 -1
- package/dist/chunk-2FHGLE7G.mjs +0 -1
- package/dist/chunk-32TDB3N4.mjs +0 -1
- package/dist/chunk-4EDMISUV.mjs +0 -1
- package/dist/chunk-5IZHN3A7.mjs +0 -1
- package/dist/chunk-6DU4ITXT.mjs +0 -1
- package/dist/chunk-6RC7JZ73.mjs +0 -1
- package/dist/chunk-A4GARXVQ.mjs +0 -1
- package/dist/chunk-AKEVJPGD.mjs +0 -1
- package/dist/chunk-AWWUJO3N.mjs +0 -1
- package/dist/chunk-BD7DW4UK.mjs +0 -1
- package/dist/chunk-CRZEJJI6.mjs +0 -1
- package/dist/chunk-CUVWMYUV.mjs +0 -1
- package/dist/chunk-DSTHM3V5.mjs +0 -30
- package/dist/chunk-EWTZVC7E.mjs +0 -1
- package/dist/chunk-FR6VIGJ2.mjs +0 -1
- package/dist/chunk-HVDJYNQ6.mjs +0 -1
- package/dist/chunk-KN4GC34I.mjs +0 -1
- package/dist/chunk-KUILFVXZ.mjs +0 -1
- package/dist/chunk-LLVF422C.mjs +0 -1
- package/dist/chunk-MHTX52KW.mjs +0 -1
- package/dist/chunk-N37INB4D.mjs +0 -1
- package/dist/chunk-NFPUOL4J.mjs +0 -1
- package/dist/chunk-OA63PYHZ.mjs +0 -1
- package/dist/chunk-PQKSXNIZ.mjs +0 -1
- package/dist/chunk-PYGRFSUU.mjs +0 -1
- package/dist/chunk-QYNW5LE2.mjs +0 -1
- package/dist/chunk-RAABZFBD.mjs +0 -1
- package/dist/chunk-REPKQAJK.mjs +0 -1
- package/dist/chunk-TMSGNHXH.mjs +0 -1
- package/dist/chunk-TVS2ZIAW.mjs +0 -1
- package/dist/chunk-UIADZXVT.mjs +0 -1
- package/dist/chunk-V7AOJQXQ.mjs +0 -1
- package/dist/chunk-WKQGWQ3P.mjs +0 -1
- package/dist/chunk-WPU4472Z.mjs +0 -1
- package/dist/chunk-WYQZ7DAK.mjs +0 -1
- package/dist/chunk-X6I6KQDG.mjs +0 -1
- package/dist/chunk-YMWXWXPV.mjs +0 -1
- package/dist/codex-note-context-GXC2474A.mjs +0 -1
- package/dist/codex-project-HVK7FSWQ.mjs +0 -1
- package/dist/codex-store-mount-KHTSSESB.mjs +0 -1
- package/dist/dev-server-QMA23NJQ.mjs +0 -1
- package/dist/participantBootstrap-BuTrTQbo.d.mts +0 -22
- package/dist/peer-client-JL754ZR7.mjs +0 -1
- package/dist/plain-html-EF7MUNRZ.mjs +0 -1
- package/dist/shared-page-QN2XRXUE.mjs +0 -1
- package/dist/steerStyles-E76E44PI.mjs +0 -1
- package/dist/taste-proposal-session-AAXK4CFL.mjs +0 -1
- package/infra/phone-pairing/README.md +0 -25
|
@@ -1,476 +1,10 @@
|
|
|
1
1
|
import * as node_http from 'node:http';
|
|
2
2
|
import { IncomingMessage, ServerResponse } from 'node:http';
|
|
3
|
-
import {
|
|
3
|
+
import { f as ParticipantBootstrapConfig } from './participantBootstrap-BcfNTEe9.mjs';
|
|
4
4
|
import { build } from 'vite';
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
adapter: string;
|
|
9
|
-
key: string;
|
|
10
|
-
canvasSelector: string;
|
|
11
|
-
inserted?: true;
|
|
12
|
-
label?: string;
|
|
13
|
-
};
|
|
14
|
-
pathname: string;
|
|
15
|
-
selector: string;
|
|
16
|
-
format: string;
|
|
17
|
-
value: string;
|
|
18
|
-
};
|
|
19
|
-
|
|
20
|
-
type ComponentSample = {
|
|
21
|
-
version: string;
|
|
22
|
-
variant: string;
|
|
23
|
-
dark: boolean;
|
|
24
|
-
props?: string;
|
|
25
|
-
label?: string;
|
|
26
|
-
};
|
|
27
|
-
|
|
28
|
-
type Frame = {
|
|
29
|
-
offset: number;
|
|
30
|
-
easing: string;
|
|
31
|
-
[key: string]: string | number;
|
|
32
|
-
};
|
|
33
|
-
type SampledMotion = {
|
|
34
|
-
frames: Frame[];
|
|
35
|
-
timing: {
|
|
36
|
-
duration: number;
|
|
37
|
-
delay: number;
|
|
38
|
-
endDelay: number;
|
|
39
|
-
iterations: number | 'infinite';
|
|
40
|
-
direction: PlaybackDirection;
|
|
41
|
-
fill: FillMode;
|
|
42
|
-
easing: string;
|
|
43
|
-
};
|
|
44
|
-
paused: boolean;
|
|
45
|
-
currentTime?: number;
|
|
46
|
-
};
|
|
47
|
-
|
|
48
|
-
type SampledElement = {
|
|
49
|
-
tag: string;
|
|
50
|
-
imageSourceHash?: string;
|
|
51
|
-
motion?: SampledMotion[];
|
|
52
|
-
backgroundStill?: string;
|
|
53
|
-
component?: ComponentSample;
|
|
54
|
-
attributes?: Record<string, string>;
|
|
55
|
-
previewWidth?: number;
|
|
56
|
-
previewHeight?: number;
|
|
57
|
-
style: Record<string, string>;
|
|
58
|
-
children: (SampledElement | string)[];
|
|
59
|
-
};
|
|
60
|
-
|
|
61
|
-
/** Each path names a text node in the authored paragraph. A boundary between
|
|
62
|
-
* two entries in parts starts a sibling paragraph with the same inline markup. */
|
|
63
|
-
type ParagraphLayout = {
|
|
64
|
-
path: number[];
|
|
65
|
-
parts: string[];
|
|
66
|
-
}[];
|
|
67
|
-
type ParagraphChange = {
|
|
68
|
-
before: ParagraphLayout;
|
|
69
|
-
after: ParagraphLayout;
|
|
70
|
-
};
|
|
71
|
-
|
|
72
|
-
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"];
|
|
73
|
-
type StickerColorName = (typeof STICKER_COLOR_NAMES)[number];
|
|
74
|
-
declare const STICKER_COLOR_STEPS: readonly [50, 100, 200, 300, 400, 500, 600, 700, 800, 900, 950];
|
|
75
|
-
type StickerColorStep = (typeof STICKER_COLOR_STEPS)[number];
|
|
76
|
-
|
|
77
|
-
declare const STICKER_FAMILIES: readonly ["padding", "margin", "border", "radius", "stack", "grid", "text", "color", "transform", "opacity"];
|
|
78
|
-
type StickerFamily = (typeof STICKER_FAMILIES)[number];
|
|
79
|
-
declare const SPACING_STEPS: readonly [0, 1, 2, 3, 4, 6, 8, 10, 12, 16];
|
|
80
|
-
declare const TRANSLATE_STEPS: readonly [-16, -12, -10, -8, -6, -4, -3, -2, -1, 0, 1, 2, 3, 4, 6, 8, 10, 12, 16];
|
|
81
|
-
declare const BORDER_STEPS: readonly [0, 1, 2, 4, 8];
|
|
82
|
-
declare const DIRECTION_STEPS: readonly ["vertical", "horizontal"];
|
|
83
|
-
declare const ALIGN_STEPS: readonly ["stretch", "start", "center", "end", "baseline"];
|
|
84
|
-
declare const JUSTIFY_STEPS: readonly ["start", "center", "end", "between", "around", "evenly"];
|
|
85
|
-
declare const GRID_COUNT_STEPS: readonly [1, 2, 3, 4, 5, 6];
|
|
86
|
-
declare const FONT_SIZE_STEPS: readonly ["xs", "sm", "base", "lg", "xl", "2xl", "3xl", "4xl"];
|
|
87
|
-
declare const FONT_WEIGHT_STEPS: readonly [300, 400, 500, 600, 700, 800];
|
|
88
|
-
declare const LINE_HEIGHT_STEPS: readonly ["none", "tight", "snug", "normal", "relaxed", "loose"];
|
|
89
|
-
declare const LETTER_SPACING_STEPS: readonly ["tighter", "tight", "normal", "wide", "wider", "widest"];
|
|
90
|
-
declare const TEXT_ALIGN_STEPS: readonly ["left", "center", "right", "justify"];
|
|
91
|
-
declare const SCALE_STEPS: readonly [25, 50, 75, 90, 95, 100, 105, 110, 125, 150];
|
|
92
|
-
declare const ROTATE_STEPS: readonly [-180, -90, -45, -25, -12, -6, -3, -2, -1, 0, 1, 2, 3, 6, 12, 25, 45, 90, 180];
|
|
93
|
-
declare const OPACITY_STEPS: readonly [0, 5, 10, 20, 25, 30, 40, 50, 60, 70, 75, 80, 90, 95, 100];
|
|
94
|
-
declare const MIX_BLEND_STEPS: readonly ["normal", "multiply", "screen", "overlay", "darken", "lighten", "color-dodge", "color-burn", "hard-light", "soft-light", "difference", "exclusion", "hue", "saturation", "color", "luminosity"];
|
|
95
|
-
type StickerStep = (typeof SPACING_STEPS)[number] | (typeof BORDER_STEPS)[number] | (typeof DIRECTION_STEPS)[number] | (typeof ALIGN_STEPS)[number] | (typeof JUSTIFY_STEPS)[number] | (typeof GRID_COUNT_STEPS)[number] | (typeof FONT_SIZE_STEPS)[number] | (typeof FONT_WEIGHT_STEPS)[number] | (typeof LINE_HEIGHT_STEPS)[number] | (typeof LETTER_SPACING_STEPS)[number] | (typeof TEXT_ALIGN_STEPS)[number] | (typeof TRANSLATE_STEPS)[number] | (typeof SCALE_STEPS)[number] | (typeof ROTATE_STEPS)[number] | (typeof OPACITY_STEPS)[number] | (typeof MIX_BLEND_STEPS)[number] | StickerColorStep;
|
|
96
|
-
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;
|
|
97
|
-
|
|
98
|
-
type TargetFingerprint = {
|
|
99
|
-
tag: string;
|
|
100
|
-
attributes?: Record<string, string>;
|
|
101
|
-
heading?: string;
|
|
102
|
-
text?: string;
|
|
103
|
-
};
|
|
104
|
-
|
|
105
|
-
type Provider = 'claude' | 'codex' | 'copilot' | 'omp' | 'opencode' | 'cursor';
|
|
106
|
-
|
|
107
|
-
type AnnotationLifecycleStatus = 'pending' | 'sending' | 'awaiting_review' | 'in_flight' | 'resolved' | 'needs_review' | 'dismissed' | 'waiting_input' | 'failed';
|
|
108
|
-
type ScopeBreadth = 'instance' | 'pattern';
|
|
109
|
-
type ScopeTarget = 'element' | 'component' | 'token';
|
|
110
|
-
type Scope = {
|
|
111
|
-
breadth: ScopeBreadth;
|
|
112
|
-
target: ScopeTarget;
|
|
113
|
-
};
|
|
114
|
-
declare const TOOL_TYPES: readonly ["inspector", "sticker", "model"];
|
|
115
|
-
type ToolType = (typeof TOOL_TYPES)[number];
|
|
116
|
-
declare const LEGACY_ANNOTATION_TYPES: readonly ["freehand", "line", "rectangle", "circle"];
|
|
117
|
-
type LegacyAnnotationType = (typeof LEGACY_ANNOTATION_TYPES)[number];
|
|
118
|
-
type AnnotationType = LegacyAnnotationType | 'text';
|
|
119
|
-
/** @internal Retired modes retained temporarily while their dead paths are removed. */
|
|
120
|
-
type InteractionMode = ToolType | LegacyAnnotationType | 'hand';
|
|
121
|
-
type Point = {
|
|
122
|
-
x: number;
|
|
123
|
-
y: number;
|
|
124
|
-
};
|
|
125
|
-
type AnnotationRevealStep = {
|
|
126
|
-
triggerSelector: string;
|
|
127
|
-
targetSelector?: string;
|
|
128
|
-
label: string;
|
|
129
|
-
};
|
|
130
|
-
type AnnotationRevealRecipe = {
|
|
131
|
-
steps: AnnotationRevealStep[];
|
|
132
|
-
location: string[];
|
|
133
|
-
};
|
|
134
|
-
type ReactSourceLocation = {
|
|
135
|
-
fileName: string;
|
|
136
|
-
lineNumber: number;
|
|
137
|
-
columnNumber?: number;
|
|
138
|
-
};
|
|
139
|
-
/** Coordinates refer to the original image, not its responsive DOM rectangle. */
|
|
140
|
-
type ImageObjectContext = {
|
|
141
|
-
src: string;
|
|
142
|
-
alt: string;
|
|
143
|
-
width: number;
|
|
144
|
-
height: number;
|
|
145
|
-
box: {
|
|
146
|
-
x: number;
|
|
147
|
-
y: number;
|
|
148
|
-
width: number;
|
|
149
|
-
height: number;
|
|
150
|
-
};
|
|
151
|
-
normalizedBox: {
|
|
152
|
-
x: number;
|
|
153
|
-
y: number;
|
|
154
|
-
width: number;
|
|
155
|
-
height: number;
|
|
156
|
-
};
|
|
157
|
-
};
|
|
158
|
-
/** Coordinates refer to the decoded video frame, not its responsive DOM box. */
|
|
159
|
-
type VideoObjectContext = {
|
|
160
|
-
src: string;
|
|
161
|
-
width: number;
|
|
162
|
-
height: number;
|
|
163
|
-
duration: number;
|
|
164
|
-
currentTime: number;
|
|
165
|
-
normalizedBox: {
|
|
166
|
-
x: number;
|
|
167
|
-
y: number;
|
|
168
|
-
width: number;
|
|
169
|
-
height: number;
|
|
170
|
-
};
|
|
171
|
-
box: {
|
|
172
|
-
x: number;
|
|
173
|
-
y: number;
|
|
174
|
-
width: number;
|
|
175
|
-
height: number;
|
|
176
|
-
};
|
|
177
|
-
trackStart: number;
|
|
178
|
-
trackEnd: number;
|
|
179
|
-
};
|
|
180
|
-
type ElementInfo = {
|
|
181
|
-
/** Outermost-to-innermost screen context; selectors retain instance identity. */
|
|
182
|
-
frameContext?: {
|
|
183
|
-
url: string;
|
|
184
|
-
title: string;
|
|
185
|
-
label?: string;
|
|
186
|
-
}[];
|
|
187
|
-
targetFingerprint?: TargetFingerprint;
|
|
188
|
-
selector: string;
|
|
189
|
-
tagName: string;
|
|
190
|
-
/** Adapter-owned semantic name for a non-DOM subject. */
|
|
191
|
-
subjectLabel?: string;
|
|
192
|
-
id?: string;
|
|
193
|
-
className?: string;
|
|
194
|
-
textContent?: string;
|
|
195
|
-
dataAttributes?: Record<string, string>;
|
|
196
|
-
reactComponent?: string;
|
|
197
|
-
reactComponentPath?: string[];
|
|
198
|
-
reactSource?: ReactSourceLocation;
|
|
199
|
-
imageObject?: ImageObjectContext;
|
|
200
|
-
videoObject?: VideoObjectContext;
|
|
201
|
-
/** The real DOM surface, rather than the subject's hidden projection. */
|
|
202
|
-
sourceElement?: ElementInfo;
|
|
203
|
-
context?: string;
|
|
204
|
-
revealRecipe?: AnnotationRevealRecipe;
|
|
205
|
-
};
|
|
206
|
-
/** Renderer-owned identity for a target that does not exist as a DOM node. */
|
|
207
|
-
type OpaqueTargetReference = {
|
|
208
|
-
adapter: string;
|
|
209
|
-
key: string;
|
|
210
|
-
};
|
|
211
|
-
type StyleChange = {
|
|
212
|
-
property: string;
|
|
213
|
-
original: string;
|
|
214
|
-
modified: string;
|
|
215
|
-
token?: string;
|
|
216
|
-
sticker?: {
|
|
217
|
-
family: StickerFamily;
|
|
218
|
-
subproperty: StickerSubproperty;
|
|
219
|
-
step: StickerStep;
|
|
220
|
-
axisSteps?: {
|
|
221
|
-
x: StickerStep;
|
|
222
|
-
y: StickerStep;
|
|
223
|
-
};
|
|
224
|
-
};
|
|
225
|
-
};
|
|
226
|
-
type StyleModification = {
|
|
227
|
-
/** Receipt-derived presentation only; never written to the editable draft. */
|
|
228
|
-
awaitingReview?: {
|
|
229
|
-
submissionId: string;
|
|
230
|
-
threadId: string;
|
|
231
|
-
};
|
|
232
|
-
selector: string;
|
|
233
|
-
durableSelector?: string;
|
|
234
|
-
element: ElementInfo;
|
|
235
|
-
changes: StyleChange[];
|
|
236
|
-
createdAt?: number;
|
|
237
|
-
annotationNumber?: number;
|
|
238
|
-
captured?: boolean;
|
|
239
|
-
pathname?: string;
|
|
240
|
-
};
|
|
241
|
-
type TextModification = {
|
|
242
|
-
target?: OpaqueTargetReference;
|
|
243
|
-
/** Whole-field preview for an edit stored as individual inline text runs. */
|
|
244
|
-
canvasLabel?: string;
|
|
245
|
-
paragraphs?: ParagraphChange;
|
|
246
|
-
selector: string;
|
|
247
|
-
durableSelector?: string;
|
|
248
|
-
element: ElementInfo;
|
|
249
|
-
textNodePath: number[];
|
|
250
|
-
original: string;
|
|
251
|
-
modified: string;
|
|
252
|
-
createdAt?: number;
|
|
253
|
-
annotationNumber?: number;
|
|
254
|
-
captured?: boolean;
|
|
255
|
-
pathname?: string;
|
|
256
|
-
};
|
|
257
|
-
type DomInsertionPlacement = 'before' | 'after';
|
|
258
|
-
type DomModification = {
|
|
259
|
-
id: string;
|
|
260
|
-
operation: 'move' | 'copy';
|
|
261
|
-
sampledTree?: SampledElement;
|
|
262
|
-
sourceSlot?: {
|
|
263
|
-
index: number;
|
|
264
|
-
count: number;
|
|
265
|
-
siblings: string;
|
|
266
|
-
};
|
|
267
|
-
selector: string;
|
|
268
|
-
durableSelector?: string;
|
|
269
|
-
element: ElementInfo;
|
|
270
|
-
sourceSelector?: string;
|
|
271
|
-
sourceDurableSelector?: string;
|
|
272
|
-
sourceElement?: ElementInfo;
|
|
273
|
-
originalParentSelector?: string;
|
|
274
|
-
originalParentDurableSelector?: string;
|
|
275
|
-
originalIndex?: number;
|
|
276
|
-
targetParentSelector: string;
|
|
277
|
-
targetParentDurableSelector?: string;
|
|
278
|
-
targetIndex: number;
|
|
279
|
-
referenceSelector?: string;
|
|
280
|
-
referenceDurableSelector?: string;
|
|
281
|
-
placement: DomInsertionPlacement;
|
|
282
|
-
captured?: boolean;
|
|
283
|
-
pathname?: string;
|
|
284
|
-
};
|
|
285
|
-
type SpacingElementEvidence = {
|
|
286
|
-
selector: string;
|
|
287
|
-
reactComponent?: string;
|
|
288
|
-
className: string;
|
|
289
|
-
property: string;
|
|
290
|
-
matchedClass?: string;
|
|
291
|
-
suggestedClass?: string;
|
|
292
|
-
};
|
|
293
|
-
type SpacingTokenChange = {
|
|
294
|
-
id: string;
|
|
295
|
-
tokenPath: string;
|
|
296
|
-
tokenName: string;
|
|
297
|
-
originalPx: number;
|
|
298
|
-
newPx: number;
|
|
299
|
-
captured?: boolean;
|
|
300
|
-
affectedElements: SpacingElementEvidence[];
|
|
301
|
-
};
|
|
302
|
-
type AnnotationAttachment = {
|
|
303
|
-
id: string;
|
|
304
|
-
name: string;
|
|
305
|
-
mimeType: string;
|
|
306
|
-
size: number;
|
|
307
|
-
kind: 'svg' | 'text';
|
|
308
|
-
};
|
|
309
|
-
type InteractionEpisodeElementState = {
|
|
310
|
-
selector?: string;
|
|
311
|
-
tagName: string;
|
|
312
|
-
className?: string;
|
|
313
|
-
role?: string;
|
|
314
|
-
ariaLabel?: string;
|
|
315
|
-
text?: string;
|
|
316
|
-
value?: string;
|
|
317
|
-
checked?: boolean;
|
|
318
|
-
disabled?: boolean;
|
|
319
|
-
expanded?: boolean;
|
|
320
|
-
pressed?: boolean;
|
|
321
|
-
selected?: boolean;
|
|
322
|
-
rect?: {
|
|
323
|
-
x: number;
|
|
324
|
-
y: number;
|
|
325
|
-
width: number;
|
|
326
|
-
height: number;
|
|
327
|
-
};
|
|
328
|
-
subject?: {
|
|
329
|
-
adapter: string;
|
|
330
|
-
key: string;
|
|
331
|
-
label: string;
|
|
332
|
-
context?: string;
|
|
333
|
-
data?: Record<string, string>;
|
|
334
|
-
};
|
|
335
|
-
media?: {
|
|
336
|
-
kind: 'image';
|
|
337
|
-
src?: string;
|
|
338
|
-
complete: boolean;
|
|
339
|
-
naturalWidth: number;
|
|
340
|
-
naturalHeight: number;
|
|
341
|
-
} | {
|
|
342
|
-
kind: 'video';
|
|
343
|
-
src?: string;
|
|
344
|
-
currentTime: number;
|
|
345
|
-
duration?: number;
|
|
346
|
-
paused: boolean;
|
|
347
|
-
} | {
|
|
348
|
-
kind: 'canvas';
|
|
349
|
-
width: number;
|
|
350
|
-
height: number;
|
|
351
|
-
};
|
|
352
|
-
};
|
|
353
|
-
type InteractionEpisodeChange = {
|
|
354
|
-
kind: 'added' | 'removed' | 'updated';
|
|
355
|
-
element: InteractionEpisodeElementState;
|
|
356
|
-
};
|
|
357
|
-
type InteractionEpisodeStep = {
|
|
358
|
-
id: string;
|
|
359
|
-
action: {
|
|
360
|
-
kind: 'click' | 'drag' | 'input' | 'change' | 'submit' | 'keydown' | 'scroll' | 'play' | 'pause' | 'seek';
|
|
361
|
-
label: string;
|
|
362
|
-
key?: string;
|
|
363
|
-
target?: InteractionEpisodeElementState;
|
|
364
|
-
};
|
|
365
|
-
startedAt: number;
|
|
366
|
-
completedAt: number;
|
|
367
|
-
outcome: 'changed' | 'no-observable-change';
|
|
368
|
-
changes: InteractionEpisodeChange[];
|
|
369
|
-
result?: InteractionEpisodeElementState;
|
|
370
|
-
visuals?: {
|
|
371
|
-
beforeFrameId?: string;
|
|
372
|
-
afterFrameId?: string;
|
|
373
|
-
};
|
|
374
|
-
};
|
|
375
|
-
type InteractionEpisodeFrame = {
|
|
376
|
-
id: string;
|
|
377
|
-
/** Index in the annotation's out-of-band image list. */
|
|
378
|
-
imageIndex: number;
|
|
379
|
-
fingerprint: string;
|
|
380
|
-
};
|
|
381
|
-
/** A compact, semantic account of actions performed while Comment passes through. */
|
|
382
|
-
type InteractionEpisode = {
|
|
383
|
-
version: 1;
|
|
384
|
-
startedAt: number;
|
|
385
|
-
completedAt: number;
|
|
386
|
-
subject?: InteractionEpisodeElementState;
|
|
387
|
-
steps: InteractionEpisodeStep[];
|
|
388
|
-
frames?: InteractionEpisodeFrame[];
|
|
389
|
-
};
|
|
390
|
-
/** A view-space annotation, not a renderer selection or a segmentation mask. */
|
|
391
|
-
type AnnotationRegion = {
|
|
392
|
-
kind: 'lasso';
|
|
393
|
-
/** Sampled context only; never used to bind the note to one object. */
|
|
394
|
-
elements?: ElementInfo[];
|
|
395
|
-
coordinateSpace: 'document';
|
|
396
|
-
points: Point[];
|
|
397
|
-
viewport: {
|
|
398
|
-
width: number;
|
|
399
|
-
height: number;
|
|
400
|
-
};
|
|
401
|
-
scroll: Point;
|
|
402
|
-
capturedAt: number;
|
|
403
|
-
};
|
|
404
|
-
type Annotation = {
|
|
405
|
-
region?: AnnotationRegion;
|
|
406
|
-
id: string;
|
|
407
|
-
type: AnnotationType;
|
|
408
|
-
points: Point[];
|
|
409
|
-
color: string;
|
|
410
|
-
strokeWidth: number;
|
|
411
|
-
text?: string;
|
|
412
|
-
fontSize?: number;
|
|
413
|
-
timestamp: number;
|
|
414
|
-
groupId?: string;
|
|
415
|
-
captured?: boolean;
|
|
416
|
-
status?: AnnotationLifecycleStatus;
|
|
417
|
-
question?: string;
|
|
418
|
-
resolutionSummary?: string;
|
|
419
|
-
scope?: Scope | null;
|
|
420
|
-
replyCount?: number;
|
|
421
|
-
replyJobIds?: string[];
|
|
422
|
-
threadId?: string;
|
|
423
|
-
targetBindingId?: string;
|
|
424
|
-
target?: OpaqueTargetReference;
|
|
425
|
-
pathname?: string;
|
|
426
|
-
elements?: ElementInfo[];
|
|
427
|
-
linkedSelector?: string;
|
|
428
|
-
linkedAnchor?: 'top-left' | 'bottom-left';
|
|
429
|
-
imageCount?: number;
|
|
430
|
-
attachments?: AnnotationAttachment[];
|
|
431
|
-
interactionEpisode?: InteractionEpisode;
|
|
432
|
-
};
|
|
433
|
-
/** A token modification tracked for undo/redo. Stores enough to revert both
|
|
434
|
-
* the model.json value and DOM inline style overrides. */
|
|
435
|
-
type SpacingTokenMod = {
|
|
436
|
-
tokenPath: string;
|
|
437
|
-
originalValue: string;
|
|
438
|
-
currentValue: string;
|
|
439
|
-
targets: Array<{
|
|
440
|
-
selector: string;
|
|
441
|
-
property: string;
|
|
442
|
-
}>;
|
|
443
|
-
originalPx: number;
|
|
444
|
-
currentPx: number;
|
|
445
|
-
captured?: boolean;
|
|
446
|
-
};
|
|
447
|
-
type UndoEntry = {
|
|
448
|
-
canvasSamples?: CanvasSample[];
|
|
449
|
-
textEditSessionId?: string;
|
|
450
|
-
annotations: Annotation[];
|
|
451
|
-
styleModifications: StyleModification[];
|
|
452
|
-
textModifications: TextModification[];
|
|
453
|
-
domModifications: DomModification[];
|
|
454
|
-
spacingTokenChanges: SpacingTokenChange[];
|
|
455
|
-
spacingTokenMods: SpacingTokenMod[];
|
|
456
|
-
};
|
|
457
|
-
type AnnotationState = {
|
|
458
|
-
canvasSamples?: CanvasSample[];
|
|
459
|
-
isAnnotating: boolean;
|
|
460
|
-
activeTool: InteractionMode;
|
|
461
|
-
activeColor: string;
|
|
462
|
-
strokeWidth: number;
|
|
463
|
-
annotations: Annotation[];
|
|
464
|
-
undoStack: UndoEntry[];
|
|
465
|
-
redoStack: UndoEntry[];
|
|
466
|
-
selectedAnnotationIds: string[];
|
|
467
|
-
lastSelectedId: string | null;
|
|
468
|
-
styleModifications: StyleModification[];
|
|
469
|
-
textModifications: TextModification[];
|
|
470
|
-
domModifications: DomModification[];
|
|
471
|
-
spacingTokenChanges: SpacingTokenChange[];
|
|
472
|
-
spacingTokenMods: SpacingTokenMod[];
|
|
473
|
-
};
|
|
5
|
+
import { P as Provider } from './protocol-BIUE4rB6.mjs';
|
|
6
|
+
import './PopmeltProvider-5g-1VH5a.mjs';
|
|
7
|
+
import { p as StickerFamily, q as StickerSubproperty, O as OpaqueTargetReference, g as StyleModification, A as Annotation, r as AnnotationState } from './subjects-qHIrZrlt.mjs';
|
|
474
8
|
|
|
475
9
|
/** Experimental peer primitives. Not a public API or an authorization boundary. */
|
|
476
10
|
type PeerIdentity = {
|
|
@@ -951,6 +485,13 @@ type ParticipantPlaneApps = Awaited<ReturnType<typeof createParticipantPlaneApps
|
|
|
951
485
|
/** Public endpoints only. Signing keys and credentials never belong here. */
|
|
952
486
|
type CloudTasteEnvironment = 'production' | 'staging';
|
|
953
487
|
|
|
488
|
+
type PhoneAppTarget = {
|
|
489
|
+
socketPath: string;
|
|
490
|
+
port: number;
|
|
491
|
+
secure: boolean;
|
|
492
|
+
};
|
|
493
|
+
type PhoneApp = () => Promise<PhoneAppTarget | undefined>;
|
|
494
|
+
|
|
954
495
|
type PopmeltOptions = {
|
|
955
496
|
/** Local events. Overrides POPMELT_EXPERIMENTAL_EVENT_TRANSPORT; defaults to WebSocket. */
|
|
956
497
|
experimentalEventTransport?: 'sse' | 'websocket';
|
|
@@ -968,6 +509,7 @@ type PopmeltOptions = {
|
|
|
968
509
|
provider?: Provider;
|
|
969
510
|
timeoutMs?: number;
|
|
970
511
|
devOrigin?: string;
|
|
512
|
+
phoneApp?: PhoneApp;
|
|
971
513
|
/** Optional Chromium DevTools endpoint, e.g. http://127.0.0.1:9222. */
|
|
972
514
|
nativeCaptureUrl?: string;
|
|
973
515
|
restartMode?: 'embedded' | 'detached';
|
|
@@ -1050,12 +592,13 @@ declare function startParticipantLan(bridge: PopmeltHandle, planes: ParticipantP
|
|
|
1050
592
|
}): Promise<{
|
|
1051
593
|
server: node_http.Server<typeof IncomingMessage, typeof ServerResponse>;
|
|
1052
594
|
origin: string;
|
|
595
|
+
onClose(callback: () => void): void;
|
|
1053
596
|
inviteOrigin(): Promise<string>;
|
|
1054
597
|
fingerprint: string | undefined;
|
|
1055
|
-
close()
|
|
598
|
+
close: () => Promise<void>;
|
|
1056
599
|
}>;
|
|
1057
600
|
|
|
1058
601
|
type PageFramework = 'next' | 'astro' | 'nuxt' | 'html';
|
|
1059
602
|
type NextBundlerFlag = '--turbo' | '--turbopack' | '--webpack';
|
|
1060
603
|
|
|
1061
|
-
export { type GuestAppRequest as G, type MemoryReviewReceipt as M, type NextBundlerFlag as N, type PopmeltHandle as P, type ParticipantAgentAdapter as a, type ParticipantCredential as b, createParticipantPlaneApps as c, type ParticipantPlaneApps as d, type PopmeltOptions as e, type
|
|
604
|
+
export { type GuestAppRequest as G, type MemoryReviewReceipt as M, type NextBundlerFlag as N, type PopmeltHandle as P, type ParticipantAgentAdapter as a, type ParticipantCredential as b, createParticipantPlaneApps as c, type ParticipantPlaneApps as d, type PopmeltOptions as e, type PhoneApp as f, type PageFramework as g, PeerSessions as h, type PeerShape as i, type ParticipantAgentView as j, createParticipantGuestAccess as k, startParticipantLan as s };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { A as Annotation, P as PopmeltSubjectAdapter } from './subjects-
|
|
2
|
-
import { d as ImageRecognitionProvider, D as VideoTrackingProvider, t as VideoSegmentationProvider, f as ImageSubjectAdapterOptions, v as VideoSubjectAdapterOptions } from './video-adapter-
|
|
1
|
+
import { A as Annotation, P as PopmeltSubjectAdapter } from './subjects-qHIrZrlt.mjs';
|
|
2
|
+
import { d as ImageRecognitionProvider, D as VideoTrackingProvider, t as VideoSegmentationProvider, f as ImageSubjectAdapterOptions, v as VideoSubjectAdapterOptions } from './video-adapter-B5eap10v.mjs';
|
|
3
3
|
|
|
4
4
|
type CommentMetaValue = null | boolean | number | string | CommentMetaValue[] | {
|
|
5
5
|
[key: string]: CommentMetaValue;
|
|
@@ -103,4 +103,4 @@ declare global {
|
|
|
103
103
|
*/
|
|
104
104
|
declare function isPopmeltPreview(url?: string): boolean;
|
|
105
105
|
|
|
106
|
-
export { type CommentMeta as C, type GetCommentMeta as G, type PopmeltOptions as P, type CommentMetaContext as a, type CommentMetaNote as b, type CommentMetaValue as c, type PopmeltExtension as d, type PopmeltExtensionRuntime as e, isPopmeltPreview as i };
|
|
106
|
+
export { type CommentMeta as C, type GetCommentMeta as G, type PopmeltOptions as P, type CommentMetaContext as a, type CommentMetaNote as b, type CommentMetaValue as c, type PopmeltExtension as d, type PopmeltExtensionRuntime as e, type ParticipantBootstrapConfig as f, isPopmeltPreview as i };
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as m,b as n,c as s,d as r,e as t,f as o}from"./chunk-GE5BE6PI.mjs";import"./chunk-776SEJZO.mjs";import"./chunk-XHTSKQMB.mjs";import"./chunk-VJKC2RJB.mjs";import"./chunk-PCUUOIFD.mjs";import"./chunk-YHCZYT4T.mjs";import"./chunk-TA2BMDSC.mjs";import"./chunk-ALWPAFIW.mjs";import"./chunk-BSVZXOOS.mjs";import"./chunk-7OATJ6BO.mjs";import"./chunk-NC7YXD7Q.mjs";import"./chunk-KOHR4LAQ.mjs";import"./chunk-4RQ5XD3I.mjs";import"./chunk-ITLRSHNZ.mjs";import"./chunk-HKHZBKAN.mjs";import"./chunk-CIKFUS7J.mjs";import"./chunk-W5TNOJOR.mjs";import"./chunk-GLF7Z5IR.mjs";import"./chunk-KD2AOPYP.mjs";import"./chunk-KF73S7MG.mjs";import"./chunk-NOHXTT24.mjs";export{m as agentCredentialFile,t as callPeer,r as canvasChatRequest,s as enrolledCanvasEndpoint,o as runPeerCommand,n as sendThreadNote};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as p,b as e,c as o}from"./chunk-7OATJ6BO.mjs";export{p as confirmsListener,e as ownedPhoneApp,o as wrappedPhoneApp};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
import{a as m}from"./chunk-PCUUOIFD.mjs";import"./chunk-HKHZBKAN.mjs";export{m as startPlainHtml};
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
var e={isAnnotating:!1,activeTool:"inspector",activeColor:"oklch(0.628 0.258 29)",strokeWidth:3,annotations:[],undoStack:[],redoStack:[],selectedAnnotationIds:[],lastSelectedId:null,styleModifications:[],textModifications:[],domModifications:[],spacingTokenChanges:[],spacingTokenMods:[]};function t(e){if(!e||"object"!=typeof e)return!1;let t=e;return(void 0===t.subject||null!==t.subject&&(void 0===t.subject.inserted||!0===t.subject.inserted)&&(void 0===t.subject.label||"string"==typeof t.subject.label&&t.subject.label.length<=256)&&[t.subject.adapter,t.subject.key,t.subject.canvasSelector].every(e=>"string"==typeof e&&e.length>0&&e.length<=2048))&&"string"==typeof t.pathname&&t.pathname.startsWith("/")&&t.pathname.length<=2048&&"string"==typeof t.selector&&t.selector.length>0&&t.selector.length<=2048&&"string"==typeof t.format&&t.format.length>0&&t.format.length<=128&&"string"==typeof t.value&&t.value.length<=65536}var n=8192,o=8388608,r=256,s=1024,i=512,a=100,l=(...e)=>JSON.stringify(e),d=(e,t)=>JSON.stringify(e)===JSON.stringify(t),c=e=>structuredClone(e),p=class extends Error{constructor(){super("This edit predates retained synchronization history"),this.name="PlaneHistoryExpiredError"}},f=(e,t)=>g(e.stamp,t.stamp)||(e.id<t.id?-1:e.id>t.id?1:0);function u(e,t){let n=new Map([...e.checkpoint?.receipts??[],...e.events].map(e=>[e.id,e])),o=[],r=[];for(let s of t){let t=n.get(s.id);if(t){if(!d(t,s))throw new Error("Plane event identity was reused")}else e.checkpoint&&f(s,e.checkpoint.through)<=0?r.push(s):o.push(s)}return{pending:o,superseded:r}}function h(e,t){let n=u(e,t);if(n.superseded.length)throw new p;return n.pending}function g(e,t){return e.time-t.time||e.counter-t.counter||(e.actor<t.actor?-1:e.actor>t.actor?1:0)}function y(e,t,n,o){let r=n.reduce((e,t)=>!e||g(t.stamp,e)>0?t.stamp:e,t),s=Math.max(Math.floor(o),r?.time??0);return{actor:e,time:s,counter:s===r?.time?r.counter+1:0}}function m(e){let t=new Map;for(let n of e.canvasSamples??[])t.set(l("canvas",l(n.pathname,n.selector)),n);for(let n of e.annotations){t.set(l("annotation",n.id),!0);for(let[e,o]of Object.entries(n))"id"!==e&&void 0!==o&&t.set(l("annotation",n.id,e),o)}for(let n of e.styleModifications){let e=l(n.pathname??"/",n.selector),{changes:o,...r}=n;t.set(l("styleMeta",e),r);for(let n of o)t.set(l("style",e,n.property),n)}for(let n of e.textModifications)t.set(l("text",l(n.pathname??"/",n.selector,JSON.stringify(n.textNodePath))),n);for(let n of e.domModifications)t.set(l("dom",n.id),n);for(let n of e.spacingTokenChanges)t.set(l("spacing",n.tokenPath),n);for(let n of e.spacingTokenMods)t.set(l("spacingMod",n.tokenPath),n);return t}function v(e,t){let n=m(e),o=m(t);return[...new Set([...n.keys(),...o.keys()])].filter(e=>!("styleMeta"===JSON.parse(e)[0]&&!o.has(e))).filter(e=>!d(n.get(e),o.get(e))).map(e=>({key:e,...o.has(e)?{value:c(o.get(e))}:{}}))}function k(e,n){let o={...n,canvasSamples:void 0,annotations:[],styleModifications:[],textModifications:[],domModifications:[],spacingTokenChanges:[],spacingTokenMods:[]},r=new Map;for(let[t,n]of e){let[e,o,s]=JSON.parse(t);"annotation"===e&&!s&&!0===n&&r.set(o,{id:o})}let s=new Map;for(let[n,i]of e){let[a,d,c]=JSON.parse(n);if("canvas"===a&&t(i)&&(o.canvasSamples??(o.canvasSamples=[])).push(i),"annotation"===a&&c&&r.has(d)&&Object.defineProperty(r.get(d),c,{value:i,enumerable:!0,configurable:!0,writable:!0}),"style"===a){let t=s.get(d),n=e.get(l("styleMeta",d));if(!n)continue;t||(t={...n,changes:[]},s.set(d,t)),t.changes.push(i)}"text"===a&&o.textModifications.push(i),"dom"===a&&o.domModifications.push(i),"spacing"===a&&o.spacingTokenChanges.push(i),"spacingMod"===a&&o.spacingTokenMods.push(i)}return o.annotations=[...r.values()],o.styleModifications=[...s.values()],o.selectedAnnotationIds=n.selectedAnnotationIds.filter(e=>r.has(e)),o.lastSelectedId=o.selectedAnnotationIds.includes(n.lastSelectedId??"")?n.lastSelectedId:null,o}var S=e=>({canvasSamples:e.canvasSamples,annotations:e.annotations,styleModifications:e.styleModifications,textModifications:e.textModifications,domModifications:e.domModifications,spacingTokenChanges:e.spacingTokenChanges,spacingTokenMods:e.spacingTokenMods});function M(t=e){let n=[...t.undoStack.slice(-a),S(t)],o={...c(t),...c(n[0]),undoStack:[],redoStack:[]},r=[];for(let e=1;e<n.length;e++){let t=`migration:${e}`;r.push({id:t,stamp:{time:0,counter:e,actor:"migration"},kind:"edit",group:t,changes:v({...o,...n[e-1]},{...o,...n[e]})})}let s=t,i=[];for(let e of[...t.redoStack].reverse().slice(0,a)){let t=`migration:${r.length+1}`,n={...o,...e};r.push({id:t,stamp:{time:0,counter:r.length+1,actor:"migration"},kind:"edit",group:t,changes:v(s,n)}),i.push(t),s=n}for(let e of i.reverse()){let t=`migration:${r.length+1}`;r.push({id:t,stamp:{time:0,counter:r.length+1,actor:"migration"},kind:"undo",target:e})}return{version:1,base:o,events:r}}function w(e){if(!Array.isArray(e)||e.length>n||JSON.stringify(e).length>o)throw new Error("Plane history exceeds the local session limit");for(let n of e){let e=e=>"string"==typeof e&&e.length>0&&e.length<=256;if(!n||!e(n.id)||!n.stamp||!e(n.stamp.actor)||!Number.isSafeInteger(n.stamp.time)||n.stamp.time<0||!Number.isSafeInteger(n.stamp.counter)||n.stamp.counter<0||!["edit","undo","redo"].includes(n.kind))throw new Error("Invalid plane event");if("edit"!==n.kind){if(!e(n.target))throw new Error("Invalid history target");continue}if(void 0!==n.group&&!e(n.group)||void 0!==n.pulledFrom&&(!e(n.pulledFrom?.participantId)||!e(n.pulledFrom?.planeId)||!Number.isSafeInteger(n.pulledFrom?.revision)||n.pulledFrom.revision<0)||void 0!==n.reset&&"boolean"!=typeof n.reset||!Array.isArray(n.changes)||n.changes.length>1e4)throw new Error("Invalid plane edit");let o=new Set;for(let e of n.changes){if(!e||"string"!=typeof e.key||e.key.length>8192)throw new Error("Invalid property key");let n=JSON.parse(e.key);if(!Array.isArray(n)||n.length<2||n.length>3||n.some(e=>"string"!=typeof e||!e.length)||!["annotation","canvas","style","styleMeta","text","dom","spacing","spacingMod"].includes(n[0])||"canvas"===n[0]&&void 0!==e.value&&(!t(e.value)||n[1]!==l(e.value.pathname,e.value.selector))||"style"===n[0]&&3!==n.length||!["style","annotation"].includes(n[0])&&2!==n.length||"annotation"===n[0]&&2===n.length&&void 0!==e.value&&!0!==e.value||o.has(e.key))throw new Error("Invalid property key");o.add(e.key)}}return c(e)}function b(e,t){let o=new Map(e.events.map(e=>[e.id,e]));for(let n of h(e,t)){let e=o.get(n.id);if(e&&!d(e,n))throw new Error("Plane event identity was reused");o.set(n.id,n)}if(o.size>n)throw new Error("Plane history exceeds the local session limit");return{...e,events:[...o.values()].sort(f)}}function E(e){if(1!==e.version&&2!==e.version)throw new Error("Unsupported plane history version");if(2===e.version&&!e.checkpoint)throw new Error("Missing plane history checkpoint");let t=e.checkpoint,n=t?new Map(c(t.cells)):m(e.base),o=new Map(t?.writers??[]),r=c(t?.undo??[]),s=c(t?.redo??[]),i=(e,t)=>{let r=[],s=[...e].sort((e,t)=>JSON.parse(e.key).length-JSON.parse(t.key).length);for(let e of s){let[s,i,a]=JSON.parse(e.key);if("styleMeta"===s&&void 0===e.value)continue;let d=o.get(e.key)??"base";if(void 0!==e.guard&&d!==e.guard||"annotation"===s&&a&&!n.has(l(s,i)))continue;let c=n.get(e.key);void 0===e.value?n.delete(e.key):n.set(e.key,e.value);let p=e.restoreWriter??t;if(o.set(e.key,p),r.push({key:e.key,before:c,after:e.value,beforeWriter:d,afterWriter:p}),"annotation"===s&&!a&&void 0===e.value)for(let e of[...n.keys()]){let[t,a]=JSON.parse(e);t===s&&a===i&&(r.push({key:e,before:n.get(e),after:void 0,beforeWriter:o.get(e)??"base",afterWriter:p}),n.delete(e),o.set(e,p))}}return r};for(let t of e.events)if("edit"===t.kind){let e=i(t.changes,t.group??t.id);if(t.reset&&(r.length=0,s.length=0),!t.group||!e.length)continue;let n=r.find(e=>e.id===t.group);if(n)for(let t of e){let e=n.changes.find(e=>e.key===t.key);e?(e.after=t.after,e.afterWriter=t.afterWriter):n.changes.push(t)}else r.push({id:t.group,writer:t.group,changes:e,...t.pulledFrom&&{pulledFrom:t.pulledFrom}});s.length=0,r.length>a&&r.shift()}else{let e="undo"===t.kind?r:s,n="undo"===t.kind?s:r,o=e.findIndex(e=>e.id===t.target);if(o<0)continue;let l=e.splice(o,1)[0],d=i(l.changes.map(e=>({key:e.key,value:e.before,guard:e.afterWriter,restoreWriter:e.beforeWriter})),t.id);d.length&&n.push({id:t.id,writer:t.id,changes:d,...l.pulledFrom&&{pulledFrom:l.pulledFrom}}),n.length>a&&n.shift()}return{cells:n,writers:o,undo:r,redo:s}}function N(e){if(e.events.length<1024)return e;let t=e.events.slice(0,-i),{cells:n,writers:o,undo:r,redo:s}=E({...e,events:t}),a=new Set([...n.keys(),...[...r,...s].flatMap(e=>e.changes.map(e=>e.key))]),l=t.at(-1);return{version:2,...e.hostStyleDeletions?{hostStyleDeletions:c(e.hostStyleDeletions)}:{},...e.hostDeletions?{hostDeletions:c(e.hostDeletions)}:{},base:{...k(new Map,e.base),undoStack:[],redoStack:[]},checkpoint:{through:{id:l.id,stamp:c(l.stamp)},cells:c([...n]),writers:[...o].filter(([e])=>a.has(e)),undo:r,redo:s,receipts:c(t.slice(-i))},events:e.events.slice(-i)}}function P(e,t=e.base,n=!0){let{cells:o,writers:r,undo:s,redo:i}=E(e),a=k(o,t);a.styleModifications=a.styleModifications.filter(t=>!e.hostStyleDeletions?.some(e=>function(e,t){if((e.pathname??"")!==(t.pathname??"")||e.selector!==t.selector&&(!e.durableSelector||e.durableSelector!==t.durableSelector))return!1;let n=e=>JSON.stringify(e.map(({property:e,original:t,modified:n,token:o})=>[e,t,n,o??null]).sort((e,t)=>String(e[0]).localeCompare(String(t[0]))));return n(e.changes)===n(t.changes)}(t,e)));let l=new Set(Object.keys(e.hostDeletions??{}));a.annotations=a.annotations.filter(e=>!l.has(e.id)),a.selectedAnnotationIds=a.selectedAnnotationIds.filter(e=>!l.has(e));let p=e=>{let n=new Map(o);for(let t of e.changes)(r.get(t.key)??"base")===t.afterWriter&&(void 0===t.before?n.delete(t.key):n.set(t.key,t.before));return S(k(n,t))},f=e=>e.filter(e=>e.changes.some(e=>"styleMeta"!==JSON.parse(e.key)[0]&&(r.get(e.key)??"base")===e.afterWriter&&!d(e.before,o.get(e.key)))),u=f(s),h=f(i);return a.undoStack=n?u.map(p):[],a.redoStack=n?h.map(p):[],{state:c(a),undo:u.map(e=>e.id),undoPullSource:u.at(-1)?.pulledFrom,redo:h.map(e=>e.id)}}export{r as MAX_PLANE_BATCH,o as MAX_PLANE_BYTES,n as MAX_PLANE_EVENTS,s as PLANE_COMPACT_AT,i as PLANE_RETAIN_EVENTS,p as PlaneHistoryExpiredError,N as compactPlaneHistory,g as comparePlaneStamps,M as createPlaneHistory,b as mergePlaneEvents,y as nextPlaneStamp,h as pendingPlaneEvents,v as planeChanges,P as projectPlaneHistory,u as reconcilePlaneEvents,w as validatePlaneEvents};
|
package/dist/plugin-astro.d.mts
CHANGED
|
@@ -1,9 +1,14 @@
|
|
|
1
|
-
import { P as PopmeltPluginOptions } from './dev-server-
|
|
1
|
+
import { P as PopmeltPluginOptions } from './dev-server-D8Qxrp1A.mjs';
|
|
2
2
|
import { popmelt as popmelt$1 } from './plugin-vite.mjs';
|
|
3
|
+
import './participantBootstrap-BcfNTEe9.mjs';
|
|
4
|
+
import './subjects-qHIrZrlt.mjs';
|
|
5
|
+
import './video-adapter-B5eap10v.mjs';
|
|
3
6
|
import 'node:http';
|
|
4
|
-
import './
|
|
7
|
+
import './PopmeltProvider-5g-1VH5a.mjs';
|
|
8
|
+
import 'react';
|
|
5
9
|
import 'vite';
|
|
6
|
-
import './page-planes-
|
|
10
|
+
import './page-planes-BeFZ3Wso.mjs';
|
|
11
|
+
import './protocol-BIUE4rB6.mjs';
|
|
7
12
|
|
|
8
13
|
type PopmeltAstroOptions = PopmeltPluginOptions & {
|
|
9
14
|
/** Set false when an existing provider mounts the UI. */
|
package/dist/plugin-astro.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as t}from"./chunk-
|
|
1
|
+
import{b as t}from"./chunk-AOFKEBLN.mjs";import"./chunk-WSI2SQWU.mjs";import"./chunk-LWPNOBGS.mjs";import"./chunk-4RQ5XD3I.mjs";import"./chunk-ITLRSHNZ.mjs";import"./chunk-HKHZBKAN.mjs";import"./chunk-CIKFUS7J.mjs";import"./chunk-W5TNOJOR.mjs";import"./chunk-GLF7Z5IR.mjs";import"./chunk-KD2AOPYP.mjs";import"./chunk-KF73S7MG.mjs";import"./chunk-WWNI7JCA.mjs";import"./chunk-NOHXTT24.mjs";import{fileURLToPath as e}from"url";function n(n={}){return{name:"popmelt",hooks:{"astro:config:setup"({command:r,config:i,updateConfig:s,injectScript:m}){if("dev"!==r||"1"===process.env.POPMELT_PLANE_RENDERER)return;let{client:a=!0,...d}=n;s({vite:{plugins:[t({...d,projectRoot:n.projectRoot??e(i.root)},"astro")],optimizeDeps:{include:a?["react","react/jsx-runtime","react/jsx-dev-runtime","react-dom","react-dom/client"]:[]}}}),m("page",a?o:"\nimport { bridgeUrl, projectId } from 'virtual:popmelt/bridge';\nif (bridgeUrl) window.__POPMELT_BRIDGE_URL__ = bridgeUrl;\nif (projectId) window.__POPMELT_PROJECT_ID__ = projectId;\n")}}}}var o="\nimport { bridgeUrl, projectId } from 'virtual:popmelt/bridge';\nimport { navigate } from 'astro:transitions/client';\nlet disposed = false;\nlet mounting;\nconst start = () => {\n if (disposed || mounting || !bridgeUrl || !projectId) return;\n mounting = Promise.resolve(import.meta.hot?.data.cleanup).then(async () => {\n if (disposed) return;\n const { mountPopmelt } = await import('@popmelt.com/core/browser');\n if (disposed) return;\n const handle = await mountPopmelt({ enabled: true, bridgeUrl, projectId, navigate });\n return handle;\n }).catch(error => { console.warn('[popmelt] startup failed:', error); });\n};\n// The standalone hosts live outside body, so Astro's body swaps retain them.\ndocument.addEventListener('astro:page-load', start);\nif (document.readyState === 'loading') document.addEventListener('DOMContentLoaded', start, { once: true });\nelse start();\nimport.meta.hot?.dispose(data => {\n if (disposed) return;\n disposed = true;\n document.removeEventListener('astro:page-load', start);\n document.removeEventListener('DOMContentLoaded', start);\n data.cleanup = mounting?.then(handle => handle?.unmount());\n});\n";export{n as popmelt};
|
package/dist/plugin-nuxt.d.mts
CHANGED
|
@@ -1,7 +1,11 @@
|
|
|
1
1
|
import { NuxtModule } from 'nuxt/schema';
|
|
2
|
-
import { P as PopmeltPluginOptions } from './dev-server-
|
|
2
|
+
import { P as PopmeltPluginOptions } from './dev-server-D8Qxrp1A.mjs';
|
|
3
|
+
import './participantBootstrap-BcfNTEe9.mjs';
|
|
4
|
+
import './subjects-qHIrZrlt.mjs';
|
|
5
|
+
import './video-adapter-B5eap10v.mjs';
|
|
3
6
|
import 'node:http';
|
|
4
|
-
import './
|
|
7
|
+
import './PopmeltProvider-5g-1VH5a.mjs';
|
|
8
|
+
import 'react';
|
|
5
9
|
|
|
6
10
|
type PopmeltNuxtOptions = Pick<PopmeltPluginOptions, 'port' | 'projectRoot' | 'bridge'> & {
|
|
7
11
|
/** @deprecated Guest access is controlled by the host in Pair and Share. */
|
package/dist/plugin-nuxt.mjs
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
import{b as e,c as t}from"./chunk-
|
|
1
|
+
import{b as e,c as t}from"./chunk-WWNI7JCA.mjs";import{b as o}from"./chunk-NOHXTT24.mjs";import{addPluginTemplate as n,defineNuxtModule as r}from"nuxt/kit";var p=r({meta:{name:"@popmelt.com/core/nuxt",configKey:"popmelt"},async setup(r,p){if(!p.options.dev||"1"===process.env.POPMELT_PLANE_RENDERER)return;let s={config:{server:p.options.devServer},middlewares:{use(){}}},i=await e({...r,projectRoot:r.projectRoot??p.options.rootDir},s,3e3,void 0,"nuxt");if(null===i.port)return;i.updateOrigin&&p.hook("listen",async(e,t)=>{s.httpServer=e;let o=e.address();if(!o||"string"==typeof o)return;let n="127.0.0.1"===o.address?"127.0.0.1":"::1"===o.address?"[::1]":"localhost";await i.updateOrigin(`${t.https?"https":"http"}://${n}:${o.port}`)}),p.hook("nitro:config",e=>{e.routeRules??={},Object.assign(e.routeRules,{...i.bootstrap?.planeApps&&{"/__popmelt/planes/**":{proxy:{to:`http://127.0.0.1:${i.port}/__popmelt/planes/**`,headers:{"x-popmelt-project-id":i.projectId}}}},...i.bootstrap&&{"/__popmelt/host":{proxy:`http://127.0.0.1:${i.port}/__popmelt/host?projectId=${encodeURIComponent(i.projectId)}`}},"/popmelt/phone":{proxy:`http://127.0.0.1:${i.port}/phone-host`}})}),p.hook("vite:extend",({config:e})=>{e.server??={},e.server.fs??={},e.server.fs.strict=!0,e.server.fs.deny=[...e.server.fs.deny??[".env",".env.*","*.{crt,pem}","**/.git/**"],"**/.popmelt","**/.popmelt/**"],e.server.watch??={};let t=e.server.watch.ignored;e.server.watch.ignored=[...Array.isArray(t)?t:t?[t]:[],"**/.popmelt/**"],e.optimizeDeps??={},e.optimizeDeps.include=[...new Set([...e.optimizeDeps.include??[],"react","react/jsx-runtime","react/jsx-dev-runtime","react-dom","react-dom/client"])]});let d=await t(i,s),a=d?o(d):void 0;p.hook("close",async()=>{a?.(),await(d?.release())}),n({filename:"popmelt.client.mjs",mode:"client",getContents:()=>`import { defineNuxtPlugin } from '#app';\nexport default defineNuxtPlugin((nuxtApp) => {\n let disposed = false;\n let mounting;\n const bridgeUrl = ${JSON.stringify(`http://localhost:${i.port}`)};\n const projectId = ${JSON.stringify(i.projectId)};\n ${i.bootstrap?`window.__POPMELT_PARTICIPANTS__=${JSON.stringify(i.bootstrap)};`:""}\n const dispose = () => {\n if (disposed) return;\n disposed = true;\n void mounting?.then(handle => handle?.unmount());\n };\n nuxtApp.hook('app:mounted', () => {\n if (disposed || mounting) return;\n mounting = import('@popmelt.com/core/browser').then(({ mountPopmelt }) => {\n if (disposed) return;\n return mountPopmelt({\n enabled: true,\n bridgeUrl,\n projectId,\n navigate: (url) => nuxtApp.$router.push(url),\n });\n }).then(handle => {\n if (disposed) handle?.unmount();\n return handle;\n }).catch(error => { console.warn('[popmelt] startup failed:', error); });\n });\n nuxtApp.vueApp.onUnmount(dispose);\n import.meta.hot?.dispose(dispose);\n});`})}});export{p as default};
|
package/dist/plugin-vite.d.mts
CHANGED
|
@@ -1,9 +1,14 @@
|
|
|
1
|
-
import { P as PopmeltPluginOptions, D as DevServerLike } from './dev-server-
|
|
1
|
+
import { P as PopmeltPluginOptions, D as DevServerLike } from './dev-server-D8Qxrp1A.mjs';
|
|
2
2
|
import * as vite from 'vite';
|
|
3
|
-
import { createServer, ViteDevServer, Plugin as Plugin$1 } from 'vite';
|
|
4
|
-
import { s as startParticipantLan, P as PopmeltHandle, c as createParticipantPlaneApps } from './page-planes-
|
|
3
|
+
import { createServer, ViteDevServer, Plugin as Plugin$1, UserConfig } from 'vite';
|
|
4
|
+
import { s as startParticipantLan, P as PopmeltHandle, c as createParticipantPlaneApps } from './page-planes-BeFZ3Wso.mjs';
|
|
5
|
+
import './participantBootstrap-BcfNTEe9.mjs';
|
|
6
|
+
import './subjects-qHIrZrlt.mjs';
|
|
7
|
+
import './video-adapter-B5eap10v.mjs';
|
|
5
8
|
import 'node:http';
|
|
6
|
-
import './
|
|
9
|
+
import './PopmeltProvider-5g-1VH5a.mjs';
|
|
10
|
+
import 'react';
|
|
11
|
+
import './protocol-BIUE4rB6.mjs';
|
|
7
12
|
|
|
8
13
|
type Room = {
|
|
9
14
|
tunnel?: Awaited<ReturnType<typeof startParticipantLan>>;
|
|
@@ -75,7 +80,7 @@ type HtmlTags = {
|
|
|
75
80
|
}[];
|
|
76
81
|
type Plugin = {
|
|
77
82
|
name: string;
|
|
78
|
-
config: (config:
|
|
83
|
+
config: (config: UserConfig, env: {
|
|
79
84
|
command: 'serve' | 'build';
|
|
80
85
|
isPreview?: boolean;
|
|
81
86
|
}) => void;
|