@g9tm/lynxcontrols-canvas 0.0.0-stage → 2.5.8

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.
Files changed (60) hide show
  1. package/README.md +39 -2
  2. package/catalog/cards/G9Canvas.md +17 -0
  3. package/catalog/cards/G9CanvasStylePanel.md +13 -0
  4. package/catalog/catalog.json +2334 -0
  5. package/catalog/index.md +6 -0
  6. package/dist/.tsbuildinfo +1 -0
  7. package/dist/board-controller.d.ts +161 -0
  8. package/dist/board-controller.d.ts.map +1 -0
  9. package/dist/board-controller.jsx +812 -0
  10. package/dist/board-model.d.ts +42 -0
  11. package/dist/board-model.d.ts.map +1 -0
  12. package/dist/board-model.jsx +66 -0
  13. package/dist/canvas.css +81 -0
  14. package/dist/canvas.css.map +1 -0
  15. package/dist/canvas.d.ts +144 -0
  16. package/dist/canvas.d.ts.map +1 -0
  17. package/dist/canvas.jsx +481 -0
  18. package/dist/element-core.d.ts +155 -0
  19. package/dist/element-core.d.ts.map +1 -0
  20. package/dist/element-core.jsx +1104 -0
  21. package/dist/export.d.ts +7 -0
  22. package/dist/export.d.ts.map +1 -0
  23. package/dist/export.jsx +75 -0
  24. package/dist/index.d.ts +8 -0
  25. package/dist/index.d.ts.map +1 -0
  26. package/dist/index.jsx +7 -0
  27. package/dist/observable.d.ts +5 -0
  28. package/dist/observable.d.ts.map +1 -0
  29. package/dist/observable.jsx +14 -0
  30. package/dist/protocol.d.ts +258 -0
  31. package/dist/protocol.d.ts.map +1 -0
  32. package/dist/protocol.jsx +2 -0
  33. package/dist/scene/edit.d.ts +59 -0
  34. package/dist/scene/edit.d.ts.map +1 -0
  35. package/dist/scene/edit.jsx +895 -0
  36. package/dist/scene/elements.d.ts +160 -0
  37. package/dist/scene/elements.d.ts.map +1 -0
  38. package/dist/scene/elements.jsx +392 -0
  39. package/dist/scene/geometry.d.ts +36 -0
  40. package/dist/scene/geometry.d.ts.map +1 -0
  41. package/dist/scene/geometry.jsx +367 -0
  42. package/dist/scene/index.d.ts +8 -0
  43. package/dist/scene/index.d.ts.map +1 -0
  44. package/dist/scene/index.jsx +6 -0
  45. package/dist/scene/path-data-parser.d.ts +17 -0
  46. package/dist/scene/path-data-parser.d.ts.map +1 -0
  47. package/dist/scene/path-data-parser.jsx +128 -0
  48. package/dist/scene/scene.d.ts +58 -0
  49. package/dist/scene/scene.d.ts.map +1 -0
  50. package/dist/scene/scene.jsx +169 -0
  51. package/dist/scene/shapes.d.ts +24 -0
  52. package/dist/scene/shapes.d.ts.map +1 -0
  53. package/dist/scene/shapes.jsx +807 -0
  54. package/dist/scene/types.d.ts +118 -0
  55. package/dist/scene/types.d.ts.map +1 -0
  56. package/dist/scene/types.jsx +1 -0
  57. package/dist/words.d.ts +100 -0
  58. package/dist/words.d.ts.map +1 -0
  59. package/dist/words.jsx +186 -0
  60. package/package.json +50 -4
@@ -0,0 +1,7 @@
1
+ import type { CvItem } from './protocol.js';
2
+ /** The board as an SVG document (every item, the fonts named, the background unless left out). */
3
+ export declare function boardSvg(items: readonly CvItem[], files: Record<string, string>, options?: {
4
+ padding?: number;
5
+ background?: string | null;
6
+ }): string;
7
+ //# sourceMappingURL=export.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"export.d.ts","sourceRoot":"","sources":["../src/export.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAS,MAAM,EAAQ,MAAM,YAAY,CAAC;AA6DtD,kGAAkG;AAClG,wBAAgB,QAAQ,CACtB,KAAK,EAAE,SAAS,MAAM,EAAE,EACxB,KAAK,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAAC,EAC7B,OAAO,GAAE;IAAE,OAAO,CAAC,EAAE,MAAM,CAAC;IAAC,UAAU,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;CAAO,GAC7D,MAAM,CAgCR"}
@@ -0,0 +1,75 @@
1
+ const FONT_NAMES = {
2
+ 1: 'Virgil, Segoe UI Emoji',
3
+ 2: 'Helvetica, Segoe UI Emoji',
4
+ 3: 'Cascadia, Segoe UI Emoji',
5
+ 5: 'Excalifont, Xiaolai, Segoe UI Emoji',
6
+ 6: 'Nunito, Segoe UI Emoji',
7
+ 7: 'Lilita One, Segoe UI Emoji',
8
+ 8: 'Comic Shanns, Segoe UI Emoji',
9
+ 9: 'Liberation Sans, Segoe UI Emoji'
10
+ };
11
+ function escapeXml(text) {
12
+ return text.replace(/&/g, '&amp;').replace(/</g, '&lt;').replace(/>/g, '&gt;').replace(/"/g, '&quot;');
13
+ }
14
+ function n(value) {
15
+ return String(Math.round(100 * value) / 100);
16
+ }
17
+ function opSvg(op, files, clipId) {
18
+ if ('p' === op.k) {
19
+ const attributes = [
20
+ `d="${op.d}"`,
21
+ `fill="${op.f ? escapeXml(op.f) : 'none'}"`
22
+ ];
23
+ if (op.f && op.eo) attributes.push('fill-rule="evenodd"');
24
+ if (op.s) {
25
+ var _op_w;
26
+ var _op_dash;
27
+ attributes.push(`stroke="${escapeXml(op.s)}"`, `stroke-width="${n(null != (_op_w = op.w) ? _op_w : 1)}"`, 'stroke-linecap="round"', 'stroke-linejoin="round"');
28
+ if (null == (_op_dash = op.dash) ? void 0 : _op_dash.length) attributes.push(`stroke-dasharray="${op.dash.map(n).join(' ')}"`);
29
+ }
30
+ return `<path ${attributes.join(' ')}/>`;
31
+ }
32
+ if ('t' === op.k) {
33
+ const anchor = 'center' === op.al ? 'middle' : 'right' === op.al ? 'end' : 'start';
34
+ const lines = op.t.map((line, i)=>{
35
+ var _FONT_NAMES_op_font;
36
+ return `<text x="${n(op.x)}" y="${n(op.y + i * op.lh)}" font-family="${null != (_FONT_NAMES_op_font = FONT_NAMES[op.font]) ? _FONT_NAMES_op_font : FONT_NAMES[5]}" font-size="${n(op.size)}px" fill="${escapeXml(op.c)}" text-anchor="${anchor}" style="white-space: pre;" direction="${op.rtl ? 'rtl' : 'ltr'}" dominant-baseline="alphabetic">${escapeXml(line)}</text>`;
37
+ });
38
+ return lines.join('');
39
+ }
40
+ const url = files[op.file];
41
+ if (!url) return `<rect width="${n(op.w)}" height="${n(op.h)}" fill="#e9ecef"/>`;
42
+ const clip = op.r ? `<clipPath id="${clipId}"><rect width="${n(op.w)}" height="${n(op.h)}" rx="${n(op.r)}" ry="${n(op.r)}"/></clipPath>` : '';
43
+ const image = op.crop ? `<svg width="${n(op.w)}" height="${n(op.h)}" viewBox="${op.crop.map(n).join(' ')}" preserveAspectRatio="none"><image href="${escapeXml(url)}"/></svg>` : `<image href="${escapeXml(url)}" width="${n(op.w)}" height="${n(op.h)}" preserveAspectRatio="none"/>`;
44
+ return `${clip}<g${op.r ? ` clip-path="url(#${clipId})"` : ''}>${image}</g>`;
45
+ }
46
+ function boardSvg(items, files, options = {}) {
47
+ var _options_padding, _options_background;
48
+ const padding = null != (_options_padding = options.padding) ? _options_padding : 24;
49
+ const bounds = items.reduce((acc, item)=>[
50
+ Math.min(acc[0], item.b[0]),
51
+ Math.min(acc[1], item.b[1]),
52
+ Math.max(acc[2], item.b[2]),
53
+ Math.max(acc[3], item.b[3])
54
+ ], [
55
+ 1 / 0,
56
+ 1 / 0,
57
+ -1 / 0,
58
+ -1 / 0
59
+ ]);
60
+ if (!items.length) return '';
61
+ const width = bounds[2] - bounds[0] + 2 * padding;
62
+ const height = bounds[3] - bounds[1] + 2 * padding;
63
+ const body = items.map((item, index)=>{
64
+ const transform = item.a ? `translate(${n(item.cx)} ${n(item.cy)}) rotate(${n(180 * item.a / Math.PI)}) translate(${n(item.x - item.cx)} ${n(item.y - item.cy)})` : `translate(${n(item.x)} ${n(item.y)})`;
65
+ return `<g transform="${transform}"${item.o < 1 ? ` opacity="${n(item.o)}"` : ''}>${item.ops.map((op, i)=>opSvg(op, files, `c${index}-${i}`)).join('')}</g>`;
66
+ }).join('\n');
67
+ const background = null === options.background ? '' : `<rect x="0" y="0" width="${n(width)}" height="${n(height)}" fill="${escapeXml(null != (_options_background = options.background) ? _options_background : '#ffffff')}"/>`;
68
+ return `<svg version="1.1" xmlns="http://www.w3.org/2000/svg" viewBox="0 0 ${n(width)} ${n(height)}" width="${n(width)}" height="${n(height)}">
69
+ <!-- svg-source:excalidraw -->
70
+ ${background}<g transform="translate(${n(padding - bounds[0])} ${n(padding - bounds[1])})">
71
+ ${body}
72
+ </g></svg>
73
+ `;
74
+ }
75
+ export { boardSvg };
@@ -0,0 +1,8 @@
1
+ export { BoardController as G9BoardController, type BoardPeerState as G9BoardPeerState, type BoardState as G9BoardState, type BoardStatus as G9BoardStatus, } from './board-controller.js';
2
+ export * from './board-model.js';
3
+ export { dispatchG9CanvasEvent, G9Canvas, type G9CanvasDesktopHost, type G9CanvasElementProps, G9CanvasPort, type G9CanvasProps, G9CanvasStylePanel, type G9CanvasStylePanelProps, useG9CanvasState, } from './canvas.js';
4
+ export { applyMatrix, CanvasCore as G9CanvasCore, resizeBox, resizeMatrix } from './element-core.js';
5
+ export * from './export.js';
6
+ export * from './protocol.js';
7
+ export { type G9CanvasWords, g9CanvasWords, g9CanvasWordsEn, g9CanvasWordsFa } from './words.js';
8
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../src/index.ts"],"names":[],"mappings":"AACA,OAAO,EACL,eAAe,IAAI,iBAAiB,EACpC,KAAK,cAAc,IAAI,gBAAgB,EACvC,KAAK,UAAU,IAAI,YAAY,EAC/B,KAAK,WAAW,IAAI,aAAa,GAClC,MAAM,oBAAoB,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,OAAO,EACL,qBAAqB,EACrB,QAAQ,EACR,KAAK,mBAAmB,EACxB,KAAK,oBAAoB,EACzB,YAAY,EACZ,KAAK,aAAa,EAClB,kBAAkB,EAClB,KAAK,uBAAuB,EAC5B,gBAAgB,GACjB,MAAM,UAAU,CAAC;AAClB,OAAO,EAAE,WAAW,EAAE,UAAU,IAAI,YAAY,EAAE,SAAS,EAAE,YAAY,EAAE,MAAM,gBAAgB,CAAC;AAClG,cAAc,UAAU,CAAC;AACzB,cAAc,YAAY,CAAC;AAC3B,OAAO,EAAE,KAAK,aAAa,EAAE,aAAa,EAAE,eAAe,EAAE,eAAe,EAAE,MAAM,SAAS,CAAC"}
package/dist/index.jsx ADDED
@@ -0,0 +1,7 @@
1
+ export * from "./board-model.jsx";
2
+ export * from "./export.jsx";
3
+ export * from "./protocol.jsx";
4
+ export { BoardController as G9BoardController } from "./board-controller.jsx";
5
+ export { G9Canvas, G9CanvasPort, G9CanvasStylePanel, dispatchG9CanvasEvent, useG9CanvasState } from "./canvas.jsx";
6
+ export { CanvasCore as G9CanvasCore, applyMatrix, resizeBox, resizeMatrix } from "./element-core.jsx";
7
+ export { g9CanvasWords, g9CanvasWordsEn, g9CanvasWordsFa } from "./words.jsx";
@@ -0,0 +1,5 @@
1
+ /** The listeners of an observable state. */
2
+ export type G9Listeners = Set<() => void>;
3
+ /** `initial` whose top-level assignments notify `listeners` (only real changes). */
4
+ export declare function observable<T extends object>(listeners: G9Listeners, initial: T): T;
5
+ //# sourceMappingURL=observable.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"observable.d.ts","sourceRoot":"","sources":["../src/observable.ts"],"names":[],"mappings":"AAIA,4CAA4C;AAC5C,MAAM,MAAM,WAAW,GAAG,GAAG,CAAC,MAAM,IAAI,CAAC,CAAC;AAE1C,oFAAoF;AACpF,wBAAgB,UAAU,CAAC,CAAC,SAAS,MAAM,EAAE,SAAS,EAAE,WAAW,EAAE,OAAO,EAAE,CAAC,GAAG,CAAC,CAUlF"}
@@ -0,0 +1,14 @@
1
+ function observable(listeners, initial) {
2
+ return new Proxy(initial, {
3
+ set (target, key, value) {
4
+ const record = target;
5
+ if (Object.is(record[key], value)) return true;
6
+ record[key] = value;
7
+ for (const listener of [
8
+ ...listeners
9
+ ])listener();
10
+ return true;
11
+ }
12
+ });
13
+ }
14
+ export { observable };
@@ -0,0 +1,258 @@
1
+ /** A picture the element wrote (an export): the host's file handle; the app releases it when done. */
2
+ export interface CvFileRef {
3
+ readonly id: string;
4
+ readonly name?: string;
5
+ readonly size?: number;
6
+ readonly mime?: string;
7
+ /** Where the host put it (a path or an address), when it says. */
8
+ readonly uri?: string;
9
+ }
10
+ /**
11
+ * `<g9-canvas>` (Plan-Lynx §6, W11): the drawing surface of a whiteboard. The scene (Excalidraw elements), hit-testing,
12
+ * editing, history and sync live in the app (`features/whiteboard/scene`, `board-sync.ts`); the element only draws what
13
+ * the app sends and reports gestures. Everything that must follow a finger at 60 fps happens inside the element without
14
+ * a round trip to the app's background thread: pan, pinch-zoom, the live freehand stroke, the outline of a shape being
15
+ * drawn, moving / resizing / rotating the selection (previewed by transforming the already drawn items), the
16
+ * selection box, the eraser trail. The app answers each finished gesture with the real elements.
17
+ *
18
+ * <g9-canvas ref={el} tool="freedraw" editable theme="light" background="#ffffff" accent="#4f46e5"
19
+ * stroke='{"color":"#1e1e1e","width":2,"fill":"transparent","roughness":1}'
20
+ * bindcvview bindcvdown bindcvtap bindcvmove bindcvtransform bindcvbox bindcvshape bindcvline bindcvstroke
21
+ * bindcverase bindcvcursor bindcvexport className="flex-1" />
22
+ * el.invoke({ method: 'apply', params: { json: JSON.stringify(message) } })
23
+ * el.invoke({ method: 'exportImage', params: { token, scale, padding, background, name } }) → cvexport event
24
+ *
25
+ * Coordinates: everything in messages and events is in scene units (Excalidraw's), except `view` (Excalidraw's
26
+ * `scrollX`/`scrollY`/`zoom`: screen = (scene + scroll) × zoom, in the element's px).
27
+ *
28
+ * Hosts: Android `whiteboard/G9CanvasUI.kt` (a `View` drawing on its `Canvas`, scene layer cached in a bitmap), web
29
+ * `client/web/src/canvas.ts` (a custom element with two `<canvas>` layers), desktop — see AIGuides/lynx/W11-whiteboard.md.
30
+ * The gesture rules of `element-core.ts` are the reference both follow.
31
+ */
32
+ /** [x1, y1, x2, y2] in scene units. */
33
+ export type CvBox = [number, number, number, number];
34
+ /** A path in SVG path syntax (M L C Q Z, absolute), stroked (`s`, `w`, `dash`) and/or filled (`f`). */
35
+ export interface CvPathOp {
36
+ k: 'p';
37
+ d: string;
38
+ /** Stroke colour (CSS colour); absent = not stroked. */
39
+ s?: string;
40
+ w?: number;
41
+ dash?: number[];
42
+ /** Fill colour; absent = not filled. */
43
+ f?: string;
44
+ /** Fill rule (`evenodd` for roughjs curves/polygons/paths, else nonzero). */
45
+ eo?: boolean;
46
+ }
47
+ /** Lines of text; `y` is the first baseline, `lh` the line height (px), `al` the alignment inside width `w`. */
48
+ export interface CvTextOp {
49
+ k: 't';
50
+ t: string[];
51
+ x: number;
52
+ y: number;
53
+ lh: number;
54
+ size: number;
55
+ /** Excalidraw font family id (5 Excalifont, 6 Nunito, 8 Comic Shanns, …); hosts map it to a font they have. */
56
+ font: number;
57
+ c: string;
58
+ al: 'left' | 'center' | 'right';
59
+ w: number;
60
+ rtl?: boolean;
61
+ }
62
+ /** A picture (`files[file]` is its URL); `crop` in the picture's natural pixels. */
63
+ export interface CvImageOp {
64
+ k: 'i';
65
+ file: string;
66
+ w: number;
67
+ h: number;
68
+ r?: number;
69
+ crop?: [number, number, number, number];
70
+ }
71
+ /** One drawing operation of an item: a path, a text or a picture. */
72
+ export type CvOp = CvPathOp | CvTextOp | CvImageOp;
73
+ /** One element as drawn: ops relative to (x, y), rotated by `a` (radians) about (cx, cy). */
74
+ export interface CvItem {
75
+ id: string;
76
+ /** The element's version (hosts may skip an unchanged item). */
77
+ v: number;
78
+ x: number;
79
+ y: number;
80
+ a: number;
81
+ cx: number;
82
+ cy: number;
83
+ /** Opacity 0–1. */
84
+ o: number;
85
+ /** Bounds as drawn (culling). */
86
+ b: CvBox;
87
+ ops: CvOp[];
88
+ }
89
+ /** A box with its rotation about its centre. */
90
+ export interface CvRotatedBox {
91
+ b: CvBox;
92
+ a: number;
93
+ }
94
+ /** The selection the app sends: the ids that move together, their outlines, the frame with its handles and a line's points. */
95
+ export interface CvSelection {
96
+ /** Items that move/resize/rotate with the selection (selected elements, their labels, bound arrows' owners…). */
97
+ ids: string[];
98
+ /** Outline per selected element. */
99
+ boxes: CvRotatedBox[];
100
+ /** The box with the handles (null: no handles, e.g. a locked or read-only selection). */
101
+ frame: CvRotatedBox | null;
102
+ /** Which handles the frame has: `all` (8 resize handles + rotation), `corners` (4 corners + rotation), `none`. */
103
+ handles: 'all' | 'corners' | 'none';
104
+ /** A single selected arrow/line: its points (scene), shown as draggable dots. */
105
+ points?: [number, number][];
106
+ }
107
+ /** A collaborator: name, colour, pointer (null when away) and what they have selected. */
108
+ export interface CvPeer {
109
+ id: string;
110
+ name: string;
111
+ color: string;
112
+ /** Null when the pointer left the board. */
113
+ x: number | null;
114
+ y: number | null;
115
+ down?: boolean;
116
+ boxes?: CvRotatedBox[];
117
+ }
118
+ /** The camera: scroll (scene units) and zoom. */
119
+ export interface CvView {
120
+ scrollX: number;
121
+ scrollY: number;
122
+ zoom: number;
123
+ }
124
+ /** app → element (`apply`). Fields absent = unchanged. */
125
+ export interface CvMessage {
126
+ /** Drop every item first (a new scene). */
127
+ reset?: boolean;
128
+ /** Items to add or replace. */
129
+ items?: CvItem[];
130
+ remove?: string[];
131
+ /** The full z-order (bottom first) whenever it changed. */
132
+ order?: string[];
133
+ selection?: CvSelection | null;
134
+ peers?: CvPeer[];
135
+ /** Move the camera (open → fit the content; zoom buttons). */
136
+ view?: CvView;
137
+ /** Picture URLs by file id. */
138
+ files?: Record<string, string>;
139
+ /** Answer to `cvdown`: whether the gesture now drags the (new) selection. */
140
+ gesture?: {
141
+ id: number;
142
+ grab: boolean;
143
+ };
144
+ /** Gestures whose preview is now drawn as real items. */
145
+ done?: number[];
146
+ /** Items not to draw (the text being edited in the app's input). */
147
+ hidden?: string[];
148
+ /** Items the eraser marked (drawn faded). */
149
+ faded?: string[];
150
+ }
151
+ /** Style of the live previews (attribute `stroke`, JSON). */
152
+ export interface CvStrokeStyle {
153
+ color: string;
154
+ width: number;
155
+ fill?: string;
156
+ /** Freehand strokes drawn as variable-width outlines (Excalidraw's look) when true. */
157
+ pressure?: boolean;
158
+ }
159
+ /** The tool in hand. */
160
+ export type CvTool = 'selection' | 'hand' | 'rectangle' | 'diamond' | 'ellipse' | 'arrow' | 'line' | 'freedraw' | 'text' | 'eraser' | 'image' | 'frame' | 'laser';
161
+ /** A selection handle: a side, a corner or the rotation knob. */
162
+ export type CvHandle = 'n' | 's' | 'e' | 'w' | 'ne' | 'nw' | 'se' | 'sw' | 'rotation';
163
+ /** `cvview`: the camera moved (with the element's size); `settled` once the gesture ended. */
164
+ export interface CvViewEvent extends CvView {
165
+ width: number;
166
+ height: number;
167
+ }
168
+ /** Selection tool: a pointer went down outside the selection's frame. The app answers with `gesture`. */
169
+ export interface CvDownEvent {
170
+ g: number;
171
+ x: number;
172
+ y: number;
173
+ shift?: boolean;
174
+ }
175
+ /** A tap (no drag): any tool. `count` 2 = double tap. */
176
+ export interface CvTapEvent {
177
+ g: number;
178
+ x: number;
179
+ y: number;
180
+ count: number;
181
+ tool: CvTool;
182
+ shift?: boolean;
183
+ }
184
+ /** `cvmove`: the selection was dragged by (`dx`, `dy`); `alt` duplicates it. */
185
+ export interface CvMoveEvent {
186
+ g: number;
187
+ dx: number;
188
+ dy: number;
189
+ /** Alt-drag duplicates (web/desktop). */
190
+ alt?: boolean;
191
+ }
192
+ /** `cvtransform`: a handle resized or rotated the selection from one box to another. */
193
+ export interface CvTransformEvent {
194
+ g: number;
195
+ handle: CvHandle;
196
+ /** The frame before and after (unrotated, scene). */
197
+ from: CvBox;
198
+ to: CvBox;
199
+ /** Rotation added (radians), `rotation` handle only. */
200
+ angle: number;
201
+ shift?: boolean;
202
+ }
203
+ /** `cvbox`: a marquee was drawn (shift adds to the selection). */
204
+ export interface CvBoxEvent {
205
+ g: number;
206
+ b: CvBox;
207
+ shift?: boolean;
208
+ }
209
+ /** `cvshape`: a rectangle, ellipse, diamond or frame was drawn in a box. */
210
+ export interface CvShapeEvent {
211
+ g: number;
212
+ tool: 'rectangle' | 'ellipse' | 'diamond' | 'frame';
213
+ b: CvBox;
214
+ }
215
+ /** `cvline`: a line or an arrow was drawn through points. */
216
+ export interface CvLineEvent {
217
+ g: number;
218
+ tool: 'arrow' | 'line';
219
+ points: [number, number][];
220
+ }
221
+ /** A selected line's point dragged to a new place. */
222
+ export interface CvPointEvent {
223
+ g: number;
224
+ index: number;
225
+ x: number;
226
+ y: number;
227
+ }
228
+ /** `cvstroke`: a free stroke was drawn (flat points, pressures when a pen gave them). */
229
+ export interface CvStrokeEvent {
230
+ g: number;
231
+ /** Flat [x0, y0, x1, y1, …] in scene units. */
232
+ points: number[];
233
+ /** Pen pressure per point (0–1); null = simulate (touch, mouse). */
234
+ pressures: number[] | null;
235
+ }
236
+ /** `cverase`: the eraser passed over points. */
237
+ export interface CvEraseEvent {
238
+ g: number;
239
+ points: number[];
240
+ }
241
+ /** `cvcursor`: the pointer moved (for collaborators); `gone` when it left. */
242
+ export interface CvCursorEvent {
243
+ x: number;
244
+ y: number;
245
+ down: boolean;
246
+ /** The pointer left the board. */
247
+ gone?: boolean;
248
+ }
249
+ /** `cvexport`: the answer to `exportImage` — the picture registered as a file, or an error. */
250
+ export interface CvExportEvent {
251
+ token: string;
252
+ /** The picture, registered like a picked file; release it when done. */
253
+ file?: CvFileRef;
254
+ error?: string;
255
+ }
256
+ /** Excalidraw's dark mode: the canvas is shown through `invert(93%) hue-rotate(180deg)`. */
257
+ export declare const DARK_FILTER = "invert(93%) hue-rotate(180deg)";
258
+ //# sourceMappingURL=protocol.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"protocol.d.ts","sourceRoot":"","sources":["../src/protocol.ts"],"names":[],"mappings":"AAAA,sGAAsG;AACtG,MAAM,WAAW,SAAS;IACxB,QAAQ,CAAC,EAAE,EAAE,MAAM,CAAC;IACpB,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,QAAQ,CAAC,IAAI,CAAC,EAAE,MAAM,CAAC;IACvB,kEAA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mC,CAAC"}
@@ -0,0 +1,2 @@
1
+ const DARK_FILTER = 'invert(93%) hue-rotate(180deg)';
2
+ export { DARK_FILTER };
@@ -0,0 +1,59 @@
1
+ import type { Scene } from './scene.js';
2
+ import type { Bounds, ExElement, ItemStyle, Point } from './types.js';
3
+ /** Elements to treat as one with `ids`: groups (outermost), labels of containers, children of frames. */
4
+ export declare function expandSelection(scene: Scene, ids: Iterable<string>): string[];
5
+ /** The ids that move with a selection: plus labels inside containers and frame children. */
6
+ export declare function movingSet(scene: Scene, ids: readonly string[]): string[];
7
+ /** The topmost element under the point (a label hits its container). */
8
+ export declare function hitTest(scene: Scene, point: Point, threshold: number, selected?: ReadonlySet<string>): ExElement | null;
9
+ /** Elements entirely inside the box (frames' children count only when the frame is not selected). */
10
+ export declare function inBox(scene: Scene, box: Bounds): string[];
11
+ /** A new rectangle, ellipse, diamond or frame in a box, inside the frame under it. */
12
+ export declare function createShape(scene: Scene, type: 'rectangle' | 'ellipse' | 'diamond' | 'frame', box: Bounds, style: ItemStyle): ExElement;
13
+ /** A new arrow/line from absolute points, bound to the shapes its ends lie on (arrows only). */
14
+ export declare function createLinear(scene: Scene, type: 'arrow' | 'line', absolute: Point[], style: ItemStyle, zoom?: number): ExElement[];
15
+ /** Puts a bound arrow's ends on the outlines of its shapes (aimed at their centres: focus 0), `gap` away. */
16
+ export declare function followBindings(arrow: ExElement, lookup: (id: string) => ExElement | undefined): ExElement;
17
+ /** A new free stroke from flat points (pressures, or simulated without them). */
18
+ export declare function createFreeDraw(scene: Scene, flat: readonly number[], pressures: readonly number[] | null, style: ItemStyle): ExElement;
19
+ /** A new text at a point, or a label inside a container (re-centred in it). */
20
+ export declare function createText(scene: Scene, x: number, y: number, text: string, style: ItemStyle, container?: ExElement): ExElement[];
21
+ /** A container's label centred inside it (Excalidraw's bound text position for a middle-aligned label). */
22
+ export declare function placeLabel(label: ExElement, container: ExElement): ExElement;
23
+ /** New text for a text element (deleted when empty). */
24
+ export declare function editText(scene: Scene, id: string, value: string): ExElement[];
25
+ /** A new picture of a file at a place and size. */
26
+ export declare function createImage(scene: Scene, fileId: string, x: number, y: number, width: number, height: number, style: ItemStyle): ExElement;
27
+ /** The elements moved by (`dx`, `dy`) with their labels and bound arrows; frames take and drop what moves in and out. */
28
+ export declare function moveElements(scene: Scene, ids: readonly string[], dx: number, dy: number): ExElement[];
29
+ /**
30
+ * Resizes the selection from the frame `from` to `to` (both in the frame's own unrotated space; `angle` is the frame's
31
+ * rotation — a single rotated element).
32
+ */
33
+ export declare function resizeElements(scene: Scene, ids: readonly string[], from: Bounds, to: Bounds, angle?: number): ExElement[];
34
+ /** The elements turned by `delta` (radians) about a pivot. */
35
+ export declare function rotateElements(scene: Scene, ids: readonly string[], delta: number, pivot: Point): ExElement[];
36
+ /** Moves one point of a line/arrow (index in its points) to an absolute position; arrows re-bind at their ends. */
37
+ export declare function movePoint(scene: Scene, id: string, index: number, x: number, y: number, zoom?: number): ExElement[];
38
+ /** The elements deleted with their labels; arrows bound to them let go. */
39
+ export declare function deleteElements(scene: Scene, ids: readonly string[]): ExElement[];
40
+ /** Style changes for the selection (`text*`/`font*` only reach texts, arrowheads only arrows…). */
41
+ export declare function styleElements(scene: Scene, ids: readonly string[], patch: Partial<ExElement>): ExElement[];
42
+ /** A move in the stacking order. */
43
+ export type OrderMove = 'front' | 'back' | 'forward' | 'backward';
44
+ /** New fractional indices for the selection (Excalidraw's z-index actions). */
45
+ export declare function reorder(scene: Scene, ids: readonly string[], move: OrderMove): ExElement[];
46
+ /** Copies of the selection 10 px down-right, above everything, with fresh ids (bindings to copied shapes kept). */
47
+ export declare function duplicate(scene: Scene, ids: readonly string[], offset?: number): {
48
+ elements: ExElement[];
49
+ selected: string[];
50
+ };
51
+ /** Elements the eraser path touches (labels erase their containers and vice versa). */
52
+ export declare function erasedBy(scene: Scene, flat: readonly number[], threshold: number): string[];
53
+ /** Groups the selection (a new outermost group id). */
54
+ export declare function group(scene: Scene, ids: readonly string[]): ExElement[];
55
+ /** The elements out of their outermost group. */
56
+ export declare function ungroup(scene: Scene, ids: readonly string[]): ExElement[];
57
+ /** The elements locked or unlocked. */
58
+ export declare function lockElements(scene: Scene, ids: readonly string[], locked: boolean): ExElement[];
59
+ //# sourceMappingURL=edit.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"edit.d.ts","sourceRoot":"","sources":["../../src/scene/edit.ts"],"names":[],"mappings":"AA8BA,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,SAAS,CAAC;AACrC,OAAO,KAAK,EAAE,MAAM,EAAE,SAAS,EAAE,SAAS,EAAE,KAAK,EAAgB,MAAM,SAAS,CAAC;AAWjF,yGAAyG;AACzG,wBAAgB,eAAe,CAAC,KAAK,EAAE,KAAK,EAAE,GAAG,EAAE,QAAQ,CAAC,MAAM,CAAC,GAAG,MAAM,EAAE,CAW7E;AAED,4FAA4F;AAC5F,wBAAgB,SAAS,CAAC,KAAK,EAAE,KAAK,EAAE,GAAG,EAAE,SAAS,MAAM,EAAE,GAAG,MAAM,EAAE,CASxE;AAED,wEAAwE;AACxE,wBAAgB,OAAO,CACrB,KAAK,EAAE,KAAK,EACZ,KAAK,EAAE,KAAK,EACZ,SAAS,EAAE,MAAM,EACjB,QAAQ,GAAE,WAAW,CAAC,MAAM,CAAa,GACxC,SAAS,GAAG,IAAI,CAoBlB;AAED,qGAAqG;AACrG,wBAAgB,KAAK,CAAC,KAAK,EAAE,KAAK,EAAE,GAAG,EAAE,MAAM,GAAG,MAAM,EAAE,CAQzD;AAcD,sFAAsF;AACtF,wBAAgB,WAAW,CACzB,KAAK,EAAE,KAAK,EACZ,IAAI,EAAE,WAAW,GAAG,SAAS,GAAG,SAAS,GAAG,OAAO,EACnD,GAAG,EAAE,MAAM,EACX,KAAK,EAAE,SAAS,GACf,SAAS,CAWX;AAED,gGAAgG;AAChG,wBAAgB,YAAY,CAC1B,KAAK,EAAE,KAAK,EACZ,IAAI,EAAE,OAAO,GAAG,MAAM,EACtB,QAAQ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