@pixerate/editor 0.150.1 → 0.151.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/dist/agent/index.cjs +34 -34
- package/dist/agent/index.js +8 -8
- package/dist/animation-editor/editorDocument.d.cts +9 -0
- package/dist/animation-editor/editorDocument.d.ts +9 -0
- package/dist/animation-editor/index.cjs +33 -1
- package/dist/animation-editor/index.d.cts +1 -0
- package/dist/animation-editor/index.d.ts +1 -0
- package/dist/animation-editor/index.js +32 -0
- package/dist/bridge/cli.cjs +4 -4
- package/dist/bridge/cli.js +3 -3
- package/dist/bridge/index.cjs +4 -4
- package/dist/bridge/index.js +3 -3
- package/dist/chart/controller.d.cts +5 -0
- package/dist/chart/controller.d.ts +5 -0
- package/dist/chart/editorDocument.d.cts +10 -0
- package/dist/chart/editorDocument.d.ts +10 -0
- package/dist/chart/index.cjs +54 -18
- package/dist/chart/index.d.cts +1 -0
- package/dist/chart/index.d.ts +1 -0
- package/dist/chart/index.js +37 -1
- package/dist/{chunk-ENIZYNEF.cjs → chunk-24M7VD6M.cjs} +7 -7
- package/dist/{chunk-OET45HIR.js → chunk-4RF2H3N3.js} +10 -0
- package/dist/{chunk-KC7HB5GF.cjs → chunk-5H2C3QSF.cjs} +4 -3
- package/dist/{chunk-HRLT5BYO.js → chunk-GNV54DLO.js} +2 -1
- package/dist/{chunk-EAQ4BGNS.js → chunk-MKTDELCD.js} +1 -1
- package/dist/{chunk-X35BV5YT.cjs → chunk-ML2II3Y3.cjs} +10 -0
- package/dist/{chunk-DVLMW3GB.cjs → chunk-R3PECGTQ.cjs} +44 -44
- package/dist/{chunk-2AQL4JHM.js → chunk-R6HNWN7B.js} +1 -1
- package/dist/{chunk-6QTON3VW.cjs → chunk-RZJCYJWO.cjs} +8 -8
- package/dist/{chunk-O5ML2I6O.js → chunk-SVINJIGK.js} +1 -1
- package/dist/diagram/index.cjs +6 -6
- package/dist/diagram/index.js +5 -5
- package/dist/export/index.cjs +1 -1
- package/dist/export/index.js +1 -1
- package/dist/extensions/index.cjs +5 -5
- package/dist/extensions/index.js +4 -4
- package/dist/image-editor/index.cjs +4 -4
- package/dist/image-editor/index.js +4 -4
- package/dist/index.cjs +14 -14
- package/dist/index.js +8 -8
- package/dist/parameters/controller.d.cts +6 -0
- package/dist/parameters/controller.d.ts +6 -0
- package/dist/parameters/editorDocument.d.cts +9 -0
- package/dist/parameters/editorDocument.d.ts +9 -0
- package/dist/parameters/index.cjs +71 -1
- package/dist/parameters/index.d.cts +1 -0
- package/dist/parameters/index.d.ts +1 -0
- package/dist/parameters/index.js +70 -0
- package/dist/persistence/editorDocument.d.cts +6 -3
- package/dist/persistence/editorDocument.d.ts +6 -3
- package/dist/persistence/index.cjs +7 -7
- package/dist/persistence/index.js +1 -1
- package/dist/tools/index.cjs +5 -5
- package/dist/tools/index.js +6 -6
- package/dist/vector/editorDocument.d.cts +9 -0
- package/dist/vector/editorDocument.d.ts +9 -0
- package/dist/vector/index.cjs +45 -1
- package/dist/vector/index.d.cts +1 -0
- package/dist/vector/index.d.ts +1 -0
- package/dist/vector/index.js +44 -0
- package/dist/video-editor/editorDocument.d.cts +9 -0
- package/dist/video-editor/editorDocument.d.ts +9 -0
- package/dist/video-editor/index.cjs +33 -1
- package/dist/video-editor/index.d.cts +1 -0
- package/dist/video-editor/index.d.ts +1 -0
- package/dist/video-editor/index.js +32 -0
- package/package.json +1 -1
- package/skills/pixerate-animation-editor/SKILL.md +12 -0
- package/skills/pixerate-chart/SKILL.md +12 -0
- package/skills/pixerate-parameters/SKILL.md +12 -0
- package/skills/pixerate-vector/SKILL.md +14 -0
- package/skills/pixerate-video-editor/SKILL.md +12 -0
- package/dist/{chunk-Y4BWZB6J.cjs → chunk-462WGGXX.cjs} +2 -2
- package/dist/{chunk-RFBFTLVN.js → chunk-EVXQNQND.js} +3 -3
package/dist/agent/index.cjs
CHANGED
|
@@ -45,7 +45,7 @@ var _chunkERAGQL2Ncjs = require('../chunk-ERAGQL2N.cjs');
|
|
|
45
45
|
|
|
46
46
|
|
|
47
47
|
|
|
48
|
-
var
|
|
48
|
+
var _chunk462WGGXXcjs = require('../chunk-462WGGXX.cjs');
|
|
49
49
|
|
|
50
50
|
|
|
51
51
|
|
|
@@ -115,10 +115,10 @@ var _chunkN2FGYZ4Qcjs = require('../chunk-N2FGYZ4Q.cjs');
|
|
|
115
115
|
|
|
116
116
|
|
|
117
117
|
|
|
118
|
-
var
|
|
118
|
+
var _chunkRZJCYJWOcjs = require('../chunk-RZJCYJWO.cjs');
|
|
119
119
|
|
|
120
120
|
|
|
121
|
-
var
|
|
121
|
+
var _chunkML2II3Y3cjs = require('../chunk-ML2II3Y3.cjs');
|
|
122
122
|
require('../chunk-XTU6QO2W.cjs');
|
|
123
123
|
|
|
124
124
|
|
|
@@ -134,11 +134,6 @@ require('../chunk-34RQAGWI.cjs');
|
|
|
134
134
|
|
|
135
135
|
|
|
136
136
|
|
|
137
|
-
var _chunk2BSBFBOAcjs = require('../chunk-2BSBFBOA.cjs');
|
|
138
|
-
|
|
139
|
-
|
|
140
|
-
|
|
141
|
-
|
|
142
137
|
|
|
143
138
|
|
|
144
139
|
var _chunkQZFEX2N4cjs = require('../chunk-QZFEX2N4.cjs');
|
|
@@ -160,6 +155,11 @@ var _chunkSWTUM32Hcjs = require('../chunk-SWTUM32H.cjs');
|
|
|
160
155
|
|
|
161
156
|
|
|
162
157
|
var _chunkWOFXZ3XUcjs = require('../chunk-WOFXZ3XU.cjs');
|
|
158
|
+
|
|
159
|
+
|
|
160
|
+
|
|
161
|
+
|
|
162
|
+
var _chunk2BSBFBOAcjs = require('../chunk-2BSBFBOA.cjs');
|
|
163
163
|
require('../chunk-FJ2MSI43.cjs');
|
|
164
164
|
require('../chunk-UKCJ43YL.cjs');
|
|
165
165
|
require('../chunk-IPJ3TEYR.cjs');
|
|
@@ -656,14 +656,14 @@ function describe(chart, includeSpec) {
|
|
|
656
656
|
series: spec.series.map((s) => ({ id: s.id, name: s.name })),
|
|
657
657
|
width: _nullishCoalesce(node.attrs.width, () => ( null)),
|
|
658
658
|
height: node.attrs.height,
|
|
659
|
-
description:
|
|
659
|
+
description: _chunkML2II3Y3cjs.describeChart.call(void 0, spec),
|
|
660
660
|
...includeSpec ? { spec } : {}
|
|
661
661
|
};
|
|
662
662
|
}
|
|
663
663
|
function sparklines(doc) {
|
|
664
664
|
const found = [];
|
|
665
665
|
doc.descendants((node, pos) => {
|
|
666
|
-
if (node.type.name === "sparkline") found.push({ pos, kind: node.attrs.kind, values: node.attrs.values, label:
|
|
666
|
+
if (node.type.name === "sparkline") found.push({ pos, kind: node.attrs.kind, values: node.attrs.values, label: _chunkRZJCYJWOcjs.sparklineLabel.call(void 0, node) });
|
|
667
667
|
});
|
|
668
668
|
return found;
|
|
669
669
|
}
|
|
@@ -674,7 +674,7 @@ function checkPosition(editor, at) {
|
|
|
674
674
|
function createDocumentChartTools(editor) {
|
|
675
675
|
const chartType = () => editor().schema.nodes.chart;
|
|
676
676
|
const findChart = (args) => {
|
|
677
|
-
const charts =
|
|
677
|
+
const charts = _chunkRZJCYJWOcjs.getDocumentCharts.call(void 0, editor().state.doc);
|
|
678
678
|
const list = charts.map((c) => `"${c.id}" at ${c.pos}`).join(", ") || "none; add one with insert_chart";
|
|
679
679
|
if (args.chartId !== void 0) {
|
|
680
680
|
const chart = charts.find((c) => c.id === args.chartId);
|
|
@@ -701,7 +701,7 @@ function createDocumentChartTools(editor) {
|
|
|
701
701
|
annotations: { title: "List charts in the document", ...READ },
|
|
702
702
|
handler: ({ includeSpec = false }) => {
|
|
703
703
|
const doc = editor().state.doc;
|
|
704
|
-
return { charts:
|
|
704
|
+
return { charts: _chunkRZJCYJWOcjs.getDocumentCharts.call(void 0, doc).map((c) => describe(c, includeSpec)), sparklines: editor().schema.nodes.sparkline ? sparklines(doc) : [] };
|
|
705
705
|
}
|
|
706
706
|
};
|
|
707
707
|
const insertChart = {
|
|
@@ -728,7 +728,7 @@ function createDocumentChartTools(editor) {
|
|
|
728
728
|
const node = { type: "chart", attrs: { id, spec, width, ...height !== void 0 ? { height } : {} } };
|
|
729
729
|
const chain = ed.chain().command(({ tr }) => (_history.closeHistory.call(void 0, tr), true));
|
|
730
730
|
const ok = (at !== void 0 ? chain.insertContentAt(at, node) : chain.insertContent(node)).run();
|
|
731
|
-
const chart =
|
|
731
|
+
const chart = _chunkRZJCYJWOcjs.getDocumentCharts.call(void 0, ed.state.doc).find((c) => c.id === id);
|
|
732
732
|
if (!ok || !chart) throw new Error(`A chart cannot go at ${_nullishCoalesce(at, () => ( ed.state.selection.from))}; pass a position between blocks or inside a paragraph.`);
|
|
733
733
|
return { id: chart.id, pos: chart.pos, spec: chart.spec, width: chart.node.attrs.width, height: chart.node.attrs.height };
|
|
734
734
|
}
|
|
@@ -775,8 +775,8 @@ function createDocumentChartTools(editor) {
|
|
|
775
775
|
inputSchema: {
|
|
776
776
|
type: "object",
|
|
777
777
|
properties: {
|
|
778
|
-
values: { type: "array", items: _chunkTLMRGLQQcjs.VALUE, minItems: 1, maxItems:
|
|
779
|
-
kind: { type: "string", enum: [...
|
|
778
|
+
values: { type: "array", items: _chunkTLMRGLQQcjs.VALUE, minItems: 1, maxItems: _chunkRZJCYJWOcjs.MAX_SPARKLINE_VALUES, description: "Values in order (null for a gap)." },
|
|
779
|
+
kind: { type: "string", enum: [..._chunkRZJCYJWOcjs.SPARKLINE_KINDS], description: "line (default), column, or win-loss (sign only)." },
|
|
780
780
|
at: { type: "integer", minimum: 0, description: "Document position inside a paragraph (default: the selection)." },
|
|
781
781
|
width: { type: "number", minimum: 4, maximum: 1e3, description: "Width in pixels (default 80)." },
|
|
782
782
|
height: { type: "number", minimum: 4, maximum: 200, description: "Height in pixels (default 18)." },
|
|
@@ -795,7 +795,7 @@ function createDocumentChartTools(editor) {
|
|
|
795
795
|
if (bad >= 0) throw new Error(`values[${bad}] ("${String(values[bad])}") is not a number; pass numbers, numeric text or null. Nothing was inserted.`);
|
|
796
796
|
const pos = _nullishCoalesce(at, () => ( ed.state.selection.from));
|
|
797
797
|
if (!ed.state.doc.resolve(pos).parent.inlineContent) throw new Error(`Position ${pos} is between blocks; a sparkline goes inside a paragraph (use a position from get_text {blocks: true}).`);
|
|
798
|
-
const stored =
|
|
798
|
+
const stored = _chunkRZJCYJWOcjs.normalizeSparklineValues.call(void 0, parsed);
|
|
799
799
|
ed.chain().command(({ tr }) => (_history.closeHistory.call(void 0, tr), true)).insertContentAt(pos, { type: "sparkline", attrs: { values: stored, kind, width, height, color, label } }).run();
|
|
800
800
|
return { pos, kind, values: stored };
|
|
801
801
|
}
|
|
@@ -1133,8 +1133,8 @@ function createTextPresence(editor, providerId, option) {
|
|
|
1133
1133
|
const config = option === false ? null : option === true || option === void 0 ? {} : option;
|
|
1134
1134
|
const caret = {
|
|
1135
1135
|
id: _nullishCoalesce(_optionalChain([config, 'optionalAccess', _43 => _43.id]), () => ( providerId)),
|
|
1136
|
-
name: _nullishCoalesce(_optionalChain([config, 'optionalAccess', _44 => _44.name]), () => (
|
|
1137
|
-
color: _nullishCoalesce(_optionalChain([config, 'optionalAccess', _45 => _45.color]), () => (
|
|
1136
|
+
name: _nullishCoalesce(_optionalChain([config, 'optionalAccess', _44 => _44.name]), () => ( _chunkRZJCYJWOcjs.DEFAULT_AGENT_CARET_NAME)),
|
|
1137
|
+
color: _nullishCoalesce(_optionalChain([config, 'optionalAccess', _45 => _45.color]), () => ( _chunkRZJCYJWOcjs.DEFAULT_AGENT_CARET_COLOR))
|
|
1138
1138
|
};
|
|
1139
1139
|
const typing = !_optionalChain([config, 'optionalAccess', _46 => _46.typing]) ? null : config.typing === true ? {} : config.typing;
|
|
1140
1140
|
const idleMs = _nullishCoalesce(_optionalChain([config, 'optionalAccess', _47 => _47.idleMs]), () => ( 12e3));
|
|
@@ -1147,19 +1147,19 @@ function createTextPresence(editor, providerId, option) {
|
|
|
1147
1147
|
};
|
|
1148
1148
|
const touch = () => {
|
|
1149
1149
|
clearTimeout(idleTimer);
|
|
1150
|
-
if (idleMs > 0) idleTimer = setTimeout(() => live() &&
|
|
1150
|
+
if (idleMs > 0) idleTimer = setTimeout(() => live() && _chunkRZJCYJWOcjs.clearAgentCaret.call(void 0, live(), caret.id), idleMs);
|
|
1151
1151
|
};
|
|
1152
1152
|
const tint = (ed, ranges) => {
|
|
1153
1153
|
clearTimeout(tintTimer);
|
|
1154
|
-
|
|
1155
|
-
if (changedMs > 0 && ranges.length) tintTimer = setTimeout(() => live() &&
|
|
1154
|
+
_chunkRZJCYJWOcjs.markAgentChanges.call(void 0, ed, caret.id, ranges);
|
|
1155
|
+
if (changedMs > 0 && ranges.length) tintTimer = setTimeout(() => live() && _chunkRZJCYJWOcjs.markAgentChanges.call(void 0, live(), caret.id, []), changedMs);
|
|
1156
1156
|
};
|
|
1157
1157
|
return {
|
|
1158
1158
|
/** Puts the caret at `head`, selecting from `anchor`. */
|
|
1159
1159
|
show(anchor, head = anchor) {
|
|
1160
1160
|
const ed = live();
|
|
1161
1161
|
if (!ed) return;
|
|
1162
|
-
|
|
1162
|
+
_chunkRZJCYJWOcjs.setAgentCaret.call(void 0, ed, { ...caret, from: anchor, to: head });
|
|
1163
1163
|
touch();
|
|
1164
1164
|
},
|
|
1165
1165
|
/** Shows the caret after ranges just changed by a tool, tinting them. */
|
|
@@ -1167,7 +1167,7 @@ function createTextPresence(editor, providerId, option) {
|
|
|
1167
1167
|
const ed = live();
|
|
1168
1168
|
if (!ed || !ranges.length) return;
|
|
1169
1169
|
const last = ranges[ranges.length - 1];
|
|
1170
|
-
|
|
1170
|
+
_chunkRZJCYJWOcjs.setAgentCaret.call(void 0, ed, { ...caret, from: last.to });
|
|
1171
1171
|
tint(ed, ranges);
|
|
1172
1172
|
touch();
|
|
1173
1173
|
},
|
|
@@ -1175,12 +1175,12 @@ function createTextPresence(editor, providerId, option) {
|
|
|
1175
1175
|
async write(ed, from, to, text, signal) {
|
|
1176
1176
|
if (live() && typing) {
|
|
1177
1177
|
clearTimeout(tintTimer);
|
|
1178
|
-
const range2 = await
|
|
1179
|
-
if (changedMs > 0) tintTimer = setTimeout(() => live() &&
|
|
1178
|
+
const range2 = await _chunkRZJCYJWOcjs.typeAgentText.call(void 0, ed, { ...typing, from, to, text, caret, signal });
|
|
1179
|
+
if (changedMs > 0) tintTimer = setTimeout(() => live() && _chunkRZJCYJWOcjs.markAgentChanges.call(void 0, live(), caret.id, []), changedMs);
|
|
1180
1180
|
touch();
|
|
1181
1181
|
return range2;
|
|
1182
1182
|
}
|
|
1183
|
-
const tr = _history.closeHistory.call(void 0,
|
|
1183
|
+
const tr = _history.closeHistory.call(void 0, _chunkRZJCYJWOcjs.replaceWithTextTransaction.call(void 0, ed.state, from, to, text));
|
|
1184
1184
|
const end = tr.mapping.map(to, 1);
|
|
1185
1185
|
const range = { from: Math.min(tr.mapping.map(from, -1), end), to: end };
|
|
1186
1186
|
ed.view.dispatch(tr.scrollIntoView());
|
|
@@ -1209,7 +1209,7 @@ function findMatches(editor, query, args, replacement) {
|
|
|
1209
1209
|
wholeWord: !!args.wholeWord,
|
|
1210
1210
|
...args.regex ? { regex: true } : { literal: true }
|
|
1211
1211
|
};
|
|
1212
|
-
const result =
|
|
1212
|
+
const result = _chunkRZJCYJWOcjs.searchDocument.call(void 0, editor.state.doc, query, options, replacement !== void 0 ? { replacement } : {});
|
|
1213
1213
|
if (result.error) throw new Error(`Invalid search pattern: ${result.error.message}`);
|
|
1214
1214
|
return { matches: result.matches, truncated: result.truncated };
|
|
1215
1215
|
}
|
|
@@ -1371,7 +1371,7 @@ function createRichTextToolProvider(target, options) {
|
|
|
1371
1371
|
replacement: String(replace).replace(/\r\n?|\n/g, "\r")
|
|
1372
1372
|
}));
|
|
1373
1373
|
const tr = _history.closeHistory.call(void 0, ed.state.tr);
|
|
1374
|
-
const ends =
|
|
1374
|
+
const ends = _chunkRZJCYJWOcjs.applyReplacements.call(void 0, tr, chosen);
|
|
1375
1375
|
ed.view.dispatch(tr.scrollIntoView());
|
|
1376
1376
|
const ranges = chosen.map((m, i) => ({ from: tr.mapping.map(m.from, -1), to: ends[i] }));
|
|
1377
1377
|
presence.changed(ranges.filter((r) => r.from < r.to));
|
|
@@ -1472,7 +1472,7 @@ function createRichTextToolProvider(target, options) {
|
|
|
1472
1472
|
inputSchema: {
|
|
1473
1473
|
type: "object",
|
|
1474
1474
|
properties: {
|
|
1475
|
-
operation: { type: "string", enum:
|
|
1475
|
+
operation: { type: "string", enum: _chunkRZJCYJWOcjs.TABLE_ACTIONS.map((a) => a.action), description: "Table operation." },
|
|
1476
1476
|
at: { type: "integer", minimum: 0, description: "Document position to place the cursor first (e.g. inside a cell)." },
|
|
1477
1477
|
rows: { type: "integer", minimum: 1, maximum: 100, description: "insertTable: rows (default 3)." },
|
|
1478
1478
|
cols: { type: "integer", minimum: 1, maximum: 50, description: "insertTable: columns (default 3)." },
|
|
@@ -1502,10 +1502,10 @@ function createRichTextToolProvider(target, options) {
|
|
|
1502
1502
|
ed.view.dispatch(ed.state.tr.setSelection(_state.TextSelection.near(ed.state.doc.resolve(at))));
|
|
1503
1503
|
}
|
|
1504
1504
|
const action = operation;
|
|
1505
|
-
const state =
|
|
1505
|
+
const state = _chunkRZJCYJWOcjs.getTableActionState.call(void 0, ed, action, params);
|
|
1506
1506
|
if (state !== true) throw new Error(state);
|
|
1507
|
-
|
|
1508
|
-
const table =
|
|
1507
|
+
_chunkRZJCYJWOcjs.runTableAction.call(void 0, ed, action, params);
|
|
1508
|
+
const table = _chunkRZJCYJWOcjs.getTableState.call(void 0, ed);
|
|
1509
1509
|
return {
|
|
1510
1510
|
operation,
|
|
1511
1511
|
table: table.inTable ? { rows: table.rows, columns: table.columns, row: table.row, column: table.column } : null,
|
|
@@ -1524,7 +1524,7 @@ function createRichTextToolProvider(target, options) {
|
|
|
1524
1524
|
if (!ed || ed.isDestroyed) return [];
|
|
1525
1525
|
if (!ed.isEditable) return [getText, findText, ...charts.read()];
|
|
1526
1526
|
const tools = [getText, findText, insertText, replaceText, replaceRange, replaceSelection, setSelection, ...formatting.tools(ed)];
|
|
1527
|
-
return [...tools, ...
|
|
1527
|
+
return [...tools, ..._chunkRZJCYJWOcjs.isTableEnabled.call(void 0, ed) ? [editTable] : [], ...charts.read(), ...charts.write().map(withCaret)];
|
|
1528
1528
|
},
|
|
1529
1529
|
subscribe: (notify) => {
|
|
1530
1530
|
const ed = editor();
|
|
@@ -2255,4 +2255,4 @@ function createCanvasComponentToolProvider(controller, options = { id: "canvas-c
|
|
|
2255
2255
|
|
|
2256
2256
|
|
|
2257
2257
|
|
|
2258
|
-
exports.AgentPlayback = _chunkGMWNBSBScjs.AgentPlayback; exports.CAPTURE_EXCLUDE_SELECTOR = _chunkSVFEVKLFcjs.CAPTURE_EXCLUDE_SELECTOR; exports.CAPTURE_OVERLAY_SELECTORS = _chunkSVFEVKLFcjs.CAPTURE_OVERLAY_SELECTORS; exports.EDITOR_CANVAS_TOOLS = _chunkSVFEVKLFcjs.EDITOR_CANVAS_TOOLS; exports.EDITOR_MCP_TOOLS = _chunkSVFEVKLFcjs.EDITOR_MCP_TOOLS; exports.EDITOR_PROMPT_TOOLS = _chunkSVFEVKLFcjs.EDITOR_PROMPT_TOOLS; exports.EDIT_OPERATION_REQUIRED_ARGUMENTS = _chunkSVFEVKLFcjs.EDIT_OPERATION_REQUIRED_ARGUMENTS; exports.EXPORT_EXCLUDED_SELECTORS = _chunkSVFEVKLFcjs.EXPORT_EXCLUDED_SELECTORS; exports.JSON_RPC_ERRORS =
|
|
2258
|
+
exports.AgentPlayback = _chunkGMWNBSBScjs.AgentPlayback; exports.CAPTURE_EXCLUDE_SELECTOR = _chunkSVFEVKLFcjs.CAPTURE_EXCLUDE_SELECTOR; exports.CAPTURE_OVERLAY_SELECTORS = _chunkSVFEVKLFcjs.CAPTURE_OVERLAY_SELECTORS; exports.EDITOR_CANVAS_TOOLS = _chunkSVFEVKLFcjs.EDITOR_CANVAS_TOOLS; exports.EDITOR_MCP_TOOLS = _chunkSVFEVKLFcjs.EDITOR_MCP_TOOLS; exports.EDITOR_PROMPT_TOOLS = _chunkSVFEVKLFcjs.EDITOR_PROMPT_TOOLS; exports.EDIT_OPERATION_REQUIRED_ARGUMENTS = _chunkSVFEVKLFcjs.EDIT_OPERATION_REQUIRED_ARGUMENTS; exports.EXPORT_EXCLUDED_SELECTORS = _chunkSVFEVKLFcjs.EXPORT_EXCLUDED_SELECTORS; exports.JSON_RPC_ERRORS = _chunk462WGGXXcjs.JSON_RPC_ERRORS; exports.MCP_PROTOCOL_VERSIONS = _chunk462WGGXXcjs.MCP_PROTOCOL_VERSIONS; exports.MCP_TOOL_CANVAS_ADD_NODE = _chunkSVFEVKLFcjs.MCP_TOOL_CANVAS_ADD_NODE; exports.MCP_TOOL_CANVAS_CONNECT = _chunkSVFEVKLFcjs.MCP_TOOL_CANVAS_CONNECT; exports.MCP_TOOL_CANVAS_HIGHLIGHT = _chunkSVFEVKLFcjs.MCP_TOOL_CANVAS_HIGHLIGHT; exports.MCP_TOOL_CANVAS_LAYOUT = _chunkSVFEVKLFcjs.MCP_TOOL_CANVAS_LAYOUT; exports.MCP_TOOL_CANVAS_REMOVE_NODES = _chunkSVFEVKLFcjs.MCP_TOOL_CANVAS_REMOVE_NODES; exports.MCP_TOOL_CANVAS_SELECT = _chunkSVFEVKLFcjs.MCP_TOOL_CANVAS_SELECT; exports.MCP_TOOL_CANVAS_UPDATE_NODE = _chunkSVFEVKLFcjs.MCP_TOOL_CANVAS_UPDATE_NODE; exports.MCP_TOOL_EDIT_CANVAS = _chunkSVFEVKLFcjs.MCP_TOOL_EDIT_CANVAS; exports.MCP_TOOL_EDIT_PROMPT = _chunkSVFEVKLFcjs.MCP_TOOL_EDIT_PROMPT; exports.MCP_TOOL_GET_EDITOR_STATE = _chunkSVFEVKLFcjs.MCP_TOOL_GET_EDITOR_STATE; exports.MCP_TOOL_PROMPT_INSERT_TEXT = _chunkSVFEVKLFcjs.MCP_TOOL_PROMPT_INSERT_TEXT; exports.MCP_TOOL_PROMPT_REPLACE_RANGE = _chunkSVFEVKLFcjs.MCP_TOOL_PROMPT_REPLACE_RANGE; exports.MCP_TOOL_PROMPT_SELECT = _chunkSVFEVKLFcjs.MCP_TOOL_PROMPT_SELECT; exports.MCP_TOOL_PROMPT_SET_VARIABLE = _chunkSVFEVKLFcjs.MCP_TOOL_PROMPT_SET_VARIABLE; exports.MCP_TOOL_VIEW_EDITOR = _chunkSVFEVKLFcjs.MCP_TOOL_VIEW_EDITOR; exports.PRESENCE_COLORS = _chunkSWTUM32Hcjs.PRESENCE_COLORS; exports.PerformanceQueue = _chunkSWTUM32Hcjs.PerformanceQueue; exports.PresenceStore = _chunkSWTUM32Hcjs.PresenceStore; exports.TOOL_BRIDGE_DEFAULT_PORT = _chunk462WGGXXcjs.TOOL_BRIDGE_DEFAULT_PORT; exports.TOOL_BRIDGE_PROTOCOL = _chunk462WGGXXcjs.TOOL_BRIDGE_PROTOCOL; exports.TOOL_DISCOVERY_TOOLS = _chunk462WGGXXcjs.TOOL_DISCOVERY_TOOLS; exports.TOOL_NAMESPACE_SEPARATOR = _chunk462WGGXXcjs.TOOL_NAMESPACE_SEPARATOR; exports.ToolRegistry = _chunk462WGGXXcjs.ToolRegistry; exports.ToolRegistryError = _chunk462WGGXXcjs.ToolRegistryError; exports.ToolRegistryView = _chunk462WGGXXcjs.ToolRegistryView; exports.UNSAFE_JSON_KEYS = _chunk2BSBFBOAcjs.UNSAFE_JSON_KEYS; exports.baseToolName = _chunk462WGGXXcjs.baseToolName; exports.captureInputSchema = _chunkN2FGYZ4Qcjs.captureInputSchema; exports.captureOutputSize = _chunkN2FGYZ4Qcjs.captureOutputSize; exports.cloneElementWithStyles = _chunkSVFEVKLFcjs.cloneElementWithStyles; exports.connectToolBridge = _chunk462WGGXXcjs.connectToolBridge; exports.createAgentPlayback = _chunkGMWNBSBScjs.createAgentPlayback; exports.createCanvasComponentToolProvider = createCanvasComponentToolProvider; exports.createCaptureTool = _chunkN2FGYZ4Qcjs.createCaptureTool; exports.createCaptureToolProvider = _chunkN2FGYZ4Qcjs.createCaptureToolProvider; exports.createDocumentChartTools = createDocumentChartTools; exports.createEditorMcpToolProvider = createEditorMcpToolProvider; exports.createElementCaptureSurface = _chunkSVFEVKLFcjs.createElementCaptureSurface; exports.createInstantPresenceClock = _chunkSWTUM32Hcjs.createInstantPresenceClock; exports.createMcpServer = _chunk462WGGXXcjs.createMcpServer; exports.createPlaybackToolProvider = _chunkGMWNBSBScjs.createPlaybackToolProvider; exports.createRichTextToolProvider = createRichTextToolProvider; exports.createSpreadsheetToolProvider = createSpreadsheetToolProvider; exports.createToolRegistry = _chunk462WGGXXcjs.createToolRegistry; exports.derivePlaybackSteps = _chunkGMWNBSBScjs.derivePlaybackSteps; exports.elementToSvg = _chunkSVFEVKLFcjs.elementToSvg; exports.errorResult = _chunk462WGGXXcjs.errorResult; exports.isUnsafeJsonKey = _chunk2BSBFBOAcjs.isUnsafeJsonKey; exports.listSkills = _chunk462WGGXXcjs.listSkills; exports.locatePlaybackChrome = _chunkGMWNBSBScjs.locatePlaybackChrome; exports.normalizeSide = normalizeSide; exports.parseSkillFrontmatter = _chunk462WGGXXcjs.parseSkillFrontmatter; exports.planAgentCommand = planAgentCommand; exports.planCanvasPlaybackSteps = planCanvasPlaybackSteps; exports.planCanvasToolPlayback = planCanvasToolPlayback; exports.planToolCall = planToolCall; exports.playbackRectFromClient = _chunkGMWNBSBScjs.playbackRectFromClient; exports.playbackRefsFromArgs = _chunkGMWNBSBScjs.playbackRefsFromArgs; exports.playbackRefsFromResult = _chunkGMWNBSBScjs.playbackRefsFromResult; exports.rasterizeElement = _chunkSVFEVKLFcjs.rasterizeElement; exports.readSkillFile = _chunk462WGGXXcjs.readSkillFile; exports.readingTime = _chunkGMWNBSBScjs.readingTime; exports.realPresenceClock = _chunkSWTUM32Hcjs.realPresenceClock; exports.resolveCaptureRequest = _chunkN2FGYZ4Qcjs.resolveCaptureRequest; exports.runToolScript = _chunkERAGQL2Ncjs.runToolScript; exports.searchTokens = _chunk462WGGXXcjs.searchTokens; exports.searchTools = _chunk462WGGXXcjs.searchTools; exports.stripPrototypeKeys = _chunk2BSBFBOAcjs.stripPrototypeKeys; exports.summarize = _chunk462WGGXXcjs.summarize; exports.toCapturedImageData = _chunkN2FGYZ4Qcjs.toCapturedImageData; exports.toToolResult = _chunk462WGGXXcjs.toToolResult; exports.toolCallToAgentCommand = toolCallToAgentCommand; exports.toolResultError = _chunkERAGQL2Ncjs.toolResultError; exports.toolResultValue = _chunkERAGQL2Ncjs.toolResultValue; exports.toolsetInstructions = _chunk462WGGXXcjs.toolsetInstructions; exports.toolsetName = _chunk462WGGXXcjs.toolsetName; exports.trackPresenceDrag = _chunkSWTUM32Hcjs.trackPresenceDrag; exports.tweenPresenceCursor = _chunkSWTUM32Hcjs.tweenPresenceCursor; exports.unionCaptureRects = _chunkN2FGYZ4Qcjs.unionCaptureRects; exports.unionRects = _chunkGMWNBSBScjs.unionRects; exports.unknownToolMessage = _chunk462WGGXXcjs.unknownToolMessage; exports.validateAgentCommand = validateAgentCommand; exports.validateJsonSchema = _chunkWOFXZ3XUcjs.validateJsonSchema;
|
package/dist/agent/index.js
CHANGED
|
@@ -45,7 +45,7 @@ import {
|
|
|
45
45
|
toolsetInstructions,
|
|
46
46
|
toolsetName,
|
|
47
47
|
unknownToolMessage
|
|
48
|
-
} from "../chunk-
|
|
48
|
+
} from "../chunk-EVXQNQND.js";
|
|
49
49
|
import {
|
|
50
50
|
AgentPlayback,
|
|
51
51
|
createAgentPlayback,
|
|
@@ -115,10 +115,10 @@ import {
|
|
|
115
115
|
setAgentCaret,
|
|
116
116
|
sparklineLabel,
|
|
117
117
|
typeAgentText
|
|
118
|
-
} from "../chunk-
|
|
118
|
+
} from "../chunk-SVINJIGK.js";
|
|
119
119
|
import {
|
|
120
120
|
describeChart
|
|
121
|
-
} from "../chunk-
|
|
121
|
+
} from "../chunk-4RF2H3N3.js";
|
|
122
122
|
import "../chunk-DSZCDNTM.js";
|
|
123
123
|
import {
|
|
124
124
|
normalizeChartSpec,
|
|
@@ -130,11 +130,6 @@ import {
|
|
|
130
130
|
} from "../chunk-2INPJDNY.js";
|
|
131
131
|
import "../chunk-RTRQ7XFI.js";
|
|
132
132
|
import "../chunk-6IN474P4.js";
|
|
133
|
-
import {
|
|
134
|
-
UNSAFE_JSON_KEYS,
|
|
135
|
-
isUnsafeJsonKey,
|
|
136
|
-
stripPrototypeKeys
|
|
137
|
-
} from "../chunk-HF5QZS7Z.js";
|
|
138
133
|
import {
|
|
139
134
|
isSingleCellRange,
|
|
140
135
|
normalizeRange,
|
|
@@ -160,6 +155,11 @@ import {
|
|
|
160
155
|
import {
|
|
161
156
|
validateJsonSchema
|
|
162
157
|
} from "../chunk-V2ZCJRDM.js";
|
|
158
|
+
import {
|
|
159
|
+
UNSAFE_JSON_KEYS,
|
|
160
|
+
isUnsafeJsonKey,
|
|
161
|
+
stripPrototypeKeys
|
|
162
|
+
} from "../chunk-HF5QZS7Z.js";
|
|
163
163
|
import "../chunk-RNSANXPT.js";
|
|
164
164
|
import "../chunk-AA34BA7G.js";
|
|
165
165
|
import "../chunk-6ONMQ6WF.js";
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type EditorDocument } from '../persistence/editorDocument.cjs';
|
|
2
|
+
import type { AnimationEditorController } from './controller.cjs';
|
|
3
|
+
import type { MotionScene } from './types.cjs';
|
|
4
|
+
/**
|
|
5
|
+
* The save / load / undo contract for an `AnimationEditorController` (kind `animation`,
|
|
6
|
+
* document: the `MotionScene`). Recorded loads are one undo step; read-only editors refuse
|
|
7
|
+
* them. The playhead and playback are not part of the document.
|
|
8
|
+
*/
|
|
9
|
+
export declare function createAnimationEditorDocument(controller: AnimationEditorController): EditorDocument<MotionScene>;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { type EditorDocument } from '../persistence/editorDocument.js';
|
|
2
|
+
import type { AnimationEditorController } from './controller.js';
|
|
3
|
+
import type { MotionScene } from './types.js';
|
|
4
|
+
/**
|
|
5
|
+
* The save / load / undo contract for an `AnimationEditorController` (kind `animation`,
|
|
6
|
+
* document: the `MotionScene`). Recorded loads are one undo step; read-only editors refuse
|
|
7
|
+
* them. The playhead and playback are not part of the document.
|
|
8
|
+
*/
|
|
9
|
+
export declare function createAnimationEditorDocument(controller: AnimationEditorController): EditorDocument<MotionScene>;
|
|
@@ -11,6 +11,9 @@ var _chunkLIXLD433cjs = require('../chunk-LIXLD433.cjs');
|
|
|
11
11
|
var _chunkEBDZWIOPcjs = require('../chunk-EBDZWIOP.cjs');
|
|
12
12
|
|
|
13
13
|
|
|
14
|
+
var _chunk5H2C3QSFcjs = require('../chunk-5H2C3QSF.cjs');
|
|
15
|
+
|
|
16
|
+
|
|
14
17
|
|
|
15
18
|
|
|
16
19
|
|
|
@@ -34,6 +37,7 @@ var _chunkEBDZWIOPcjs = require('../chunk-EBDZWIOP.cjs');
|
|
|
34
37
|
var _chunkRHXW4TA5cjs = require('../chunk-RHXW4TA5.cjs');
|
|
35
38
|
require('../chunk-BXMIBMVG.cjs');
|
|
36
39
|
require('../chunk-CVFAAZXE.cjs');
|
|
40
|
+
require('../chunk-L5OWG2NA.cjs');
|
|
37
41
|
|
|
38
42
|
|
|
39
43
|
|
|
@@ -59,6 +63,7 @@ require('../chunk-NIBFDFYW.cjs');
|
|
|
59
63
|
|
|
60
64
|
var _chunkALNIFK5Gcjs = require('../chunk-ALNIFK5G.cjs');
|
|
61
65
|
require('../chunk-UWEQ55MY.cjs');
|
|
66
|
+
require('../chunk-2BSBFBOA.cjs');
|
|
62
67
|
|
|
63
68
|
|
|
64
69
|
var _chunkFJ2MSI43cjs = require('../chunk-FJ2MSI43.cjs');
|
|
@@ -5931,6 +5936,33 @@ function createAnimationEffectsToolProvider(controller, options = {}) {
|
|
|
5931
5936
|
}), options.playbackSurface);
|
|
5932
5937
|
}
|
|
5933
5938
|
|
|
5939
|
+
// src/animation-editor/editorDocument.ts
|
|
5940
|
+
function createAnimationEditorDocument(controller) {
|
|
5941
|
+
return _chunk5H2C3QSFcjs.defineEditorDocument.call(void 0, {
|
|
5942
|
+
kind: "animation",
|
|
5943
|
+
get: () => controller.getScene(),
|
|
5944
|
+
load: (document, { history }) => {
|
|
5945
|
+
const result = controller.load(document, { clearHistory: history === "reset" });
|
|
5946
|
+
if (!result.ok) throw new Error(result.error);
|
|
5947
|
+
},
|
|
5948
|
+
subscribe: (listener) => {
|
|
5949
|
+
let scene = controller.getScene();
|
|
5950
|
+
return controller.subscribe(() => {
|
|
5951
|
+
if (controller.getScene() === scene) return;
|
|
5952
|
+
scene = controller.getScene();
|
|
5953
|
+
listener();
|
|
5954
|
+
});
|
|
5955
|
+
},
|
|
5956
|
+
history: {
|
|
5957
|
+
undo: () => controller.undo(),
|
|
5958
|
+
redo: () => controller.redo(),
|
|
5959
|
+
getState: () => controller.history.getState()
|
|
5960
|
+
},
|
|
5961
|
+
readOnly: () => controller.getState().readOnly ? "The animation is read-only." : false
|
|
5962
|
+
});
|
|
5963
|
+
}
|
|
5964
|
+
|
|
5965
|
+
|
|
5934
5966
|
|
|
5935
5967
|
|
|
5936
5968
|
|
|
@@ -6092,4 +6124,4 @@ function createAnimationEffectsToolProvider(controller, options = {}) {
|
|
|
6092
6124
|
|
|
6093
6125
|
|
|
6094
6126
|
|
|
6095
|
-
exports.ANIMATION_EDITOR_AGENT_INSTRUCTIONS = ANIMATION_EDITOR_AGENT_INSTRUCTIONS; exports.AnimationEditorController = AnimationEditorController; exports.FLAIR_EASES = FLAIR_EASES; exports.FLAIR_EXPORT_VERSION = FLAIR_EXPORT_VERSION; exports.MOTION_ADDITIVE_PROPERTIES = MOTION_ADDITIVE_PROPERTIES; exports.MOTION_BLENDS = MOTION_BLENDS; exports.MOTION_CAMERA_MS = MOTION_CAMERA_MS; exports.MOTION_CASCADES = MOTION_CASCADES; exports.MOTION_CLIP_TARGET = MOTION_CLIP_TARGET; exports.MOTION_COMMAND_FIELDS = MOTION_COMMAND_FIELDS; exports.MOTION_COMMAND_SCHEMA = MOTION_COMMAND_SCHEMA; exports.MOTION_COMMAND_TYPES = MOTION_COMMAND_TYPES; exports.MOTION_COMMAND_TYPE_SCHEMAS = MOTION_COMMAND_TYPE_SCHEMAS; exports.MOTION_DEFAULT_DURATIONS = MOTION_DEFAULT_DURATIONS; exports.MOTION_DEFAULT_HOLD = MOTION_DEFAULT_HOLD; exports.MOTION_DIRECTIONS = MOTION_DIRECTIONS; exports.MOTION_DRAW_EFFECT_ID = MOTION_DRAW_EFFECT_ID; exports.MOTION_DRAW_MS_PER_UNIT = MOTION_DRAW_MS_PER_UNIT; exports.MOTION_DRAW_RANGE = MOTION_DRAW_RANGE; exports.MOTION_DRIVEN_PROPERTIES = MOTION_DRIVEN_PROPERTIES; exports.MOTION_EASE_CHOICES = MOTION_EASE_CHOICES; exports.MOTION_EASE_IN_OUT = MOTION_EASE_IN_OUT; exports.MOTION_EASE_OUT = MOTION_EASE_OUT; exports.MOTION_EDIT_OPS = MOTION_EDIT_OPS; exports.MOTION_ENTER_STYLES = MOTION_ENTER_STYLES; exports.MOTION_EXIT_STYLES = MOTION_EXIT_STYLES; exports.MOTION_IRIS_SHAPES = MOTION_IRIS_SHAPES; exports.MOTION_ISSUE_CODES = _chunkEBDZWIOPcjs.MOTION_ISSUE_CODES; exports.MOTION_MAX_TAKE_MS = MOTION_MAX_TAKE_MS; exports.MOTION_MIN_CHANGE_MS = MOTION_MIN_CHANGE_MS; exports.MOTION_RECORD_GESTURE_MODES = MOTION_RECORD_GESTURE_MODES; exports.MOTION_REPEAT_MODES = MOTION_REPEAT_MODES; exports.MOTION_SPEED_RANGE = MOTION_SPEED_RANGE; exports.MOTION_SPLIT_ORIENTATIONS = MOTION_SPLIT_ORIENTATIONS; exports.MOTION_TEXT_STAGGER = MOTION_TEXT_STAGGER; exports.MOTION_TEXT_UNITS = MOTION_TEXT_UNITS; exports.MOTION_TRIGGERS = MOTION_TRIGGERS; exports.MotionSceneFormatError = MotionSceneFormatError; exports.activeSegment = activeSegment; exports.applyMotionControlValues = applyMotionControlValues; exports.applyMotionDrivers = applyMotionDrivers; exports.applyMotionEdits = applyMotionEdits; exports.checkMotionScene = checkMotionScene; exports.clipsShapeProblems = clipsShapeProblems; exports.commandShapeProblems = commandShapeProblems; exports.compileMotionScene = compileMotionScene; exports.createAnimationEditorToolProvider = createAnimationEditorToolProvider; exports.createAnimationEffectsToolProvider = createAnimationEffectsToolProvider; exports.createMotionScene = createMotionScene; exports.defaultMotionCommand = defaultMotionCommand; exports.describeMotionElements = describeMotionElements; exports.describeMotionShots = describeMotionShots; exports.driversShapeProblems = driversShapeProblems; exports.duplicateMotionCommandEdit = duplicateMotionCommandEdit; exports.fitMotionRect = fitMotionRect; exports.fitMotionScene = fitMotionScene; exports.fitMotionSceneEdits = fitMotionSceneEdits; exports.flairAtLeast = flairAtLeast; exports.flairCurveFor = flairCurveFor; exports.flairEaseFor = flairEaseFor; exports.formatMotionDrivers = formatMotionDrivers; exports.formatMotionNarration = formatMotionNarration; exports.freshShotId = freshShotId; exports.fromFlairSvgMotion = fromFlairSvgMotion; exports.fromFlairVectorEffect = fromFlairVectorEffect; exports.fromPptxAnimation = fromPptxAnimation; exports.highlightMotionSvg = highlightMotionSvg; exports.indexMotionNodes = indexMotionNodes; exports.interpolateMotionValue = interpolateMotionValue; exports.isMotionCommand = isMotionCommand; exports.isMotionShot = isMotionShot; exports.matchMotionNodes = matchMotionNodes; exports.motionAddTrackKey = motionAddTrackKey; exports.motionArtworkSvg = motionArtworkSvg; exports.motionBeatAt = motionBeatAt; exports.motionBeatTime = motionBeatTime; exports.motionBlurTimes = motionBlurTimes; exports.motionCascade = motionCascade; exports.motionClientToDocument = motionClientToDocument; exports.motionClipAttrs = motionClipAttrs; exports.motionClipLayout = motionClipLayout; exports.motionCommandDuration = motionCommandDuration; exports.motionCommandFields = motionCommandFields; exports.motionCommandRepeat = motionCommandRepeat; exports.motionCommandRows = motionCommandRows; exports.motionCommandSlots = motionCommandSlots; exports.motionCommandSummary = motionCommandSummary; exports.motionCommandsFromEffect = motionCommandsFromEffect; exports.motionContactSheetSvg = motionContactSheetSvg; exports.motionCueChoices = motionCueChoices; exports.motionCueFromKey = motionCueFromKey; exports.motionCueKey = motionCueKey; exports.motionCueTime = motionCueTime; exports.motionCycleDuration = motionCycleDuration; exports.motionDrivenNodes = motionDrivenNodes; exports.motionDriverSources = motionDriverSources; exports.motionEaseKey = motionEaseKey; exports.motionEasingCurve = motionEasingCurve; exports.motionEasingGuides = motionEasingGuides; exports.motionEasingPath = motionEasingPath; exports.motionFieldEdit = motionFieldEdit; exports.motionFieldLabel = motionFieldLabel; exports.motionFlairPrimitive = motionFlairPrimitive; exports.motionFollowRoute = motionFollowRoute; exports.motionFrameAt = motionFrameAt; exports.motionFrameToSvg = motionFrameToSvg; exports.motionGhosts = motionGhosts; exports.motionIssue = _chunkEBDZWIOPcjs.motionIssue; exports.motionIssueKey = _chunkEBDZWIOPcjs.motionIssueKey; exports.motionIssueLine = _chunkEBDZWIOPcjs.motionIssueLine; exports.motionMovingIds = motionMovingIds; exports.motionNodeAtElement = motionNodeAtElement; exports.motionNodeClips = motionNodeClips; exports.motionNodeOffset = motionNodeOffset; exports.motionNodePose = motionNodePose; exports.motionPartsFromVectorEffect = motionPartsFromVectorEffect; exports.motionPath = motionPath; exports.motionPathLength = motionPathLength; exports.motionPathsSvg = motionPathsSvg; exports.motionPropertyValue = motionPropertyValue; exports.motionRestValue = motionRestValue; exports.motionRevealClip = motionRevealClip; exports.motionRevealPadding = motionRevealPadding; exports.motionRulerTicks = motionRulerTicks; exports.motionSceneEffects = motionSceneEffects; exports.motionSceneShapeProblems = motionSceneShapeProblems; exports.motionSceneToJson = motionSceneToJson; exports.motionShotAt = motionShotAt; exports.motionShotCueTime = motionShotCueTime; exports.motionShotTimeScale = motionShotTimeScale; exports.motionStageSvg = motionStageSvg; exports.motionTakeProblems = motionTakeProblems; exports.motionTakeShot = motionTakeShot; exports.motionTextLayout = motionTextLayout; exports.motionTextUnits = motionTextUnits; exports.motionTrackKey = motionTrackKey; exports.namedWithSuggestion = _chunkEBDZWIOPcjs.namedWithSuggestion; exports.nextMotionEffectInstance = nextMotionEffectInstance; exports.parseMotionDrivers = parseMotionDrivers; exports.parseMotionFieldInput = parseMotionFieldInput; exports.parseMotionNarration = parseMotionNarration; exports.parseMotionScene = parseMotionScene; exports.planAnimationToolPlayback = planAnimationToolPlayback; exports.resolveMotionCamera = resolveMotionCamera; exports.resolveMotionEditRefs = resolveMotionEditRefs; exports.segmentProgress = segmentProgress; exports.segmentValue = segmentValue; exports.shotShapeProblems = shotShapeProblems; exports.simplifyTimedSamples = simplifyTimedSamples; exports.smoothMotionLegs = smoothMotionLegs; exports.smoothMotionTimes = smoothMotionTimes; exports.suggestName = _chunkEBDZWIOPcjs.suggestName; exports.toFlairEffectDocument = toFlairEffectDocument; exports.toFlairSvgMotion = toFlairSvgMotion; exports.toFlairVectorEffect = toFlairVectorEffect; exports.toLottie = toLottie; exports.trackValue = trackValue; exports.withAnimationPlayback = withAnimationPlayback; exports.withMotionLayers = withMotionLayers; exports.withViewBox = withViewBox; exports.withoutMotionEffect = withoutMotionEffect;
|
|
6127
|
+
exports.ANIMATION_EDITOR_AGENT_INSTRUCTIONS = ANIMATION_EDITOR_AGENT_INSTRUCTIONS; exports.AnimationEditorController = AnimationEditorController; exports.FLAIR_EASES = FLAIR_EASES; exports.FLAIR_EXPORT_VERSION = FLAIR_EXPORT_VERSION; exports.MOTION_ADDITIVE_PROPERTIES = MOTION_ADDITIVE_PROPERTIES; exports.MOTION_BLENDS = MOTION_BLENDS; exports.MOTION_CAMERA_MS = MOTION_CAMERA_MS; exports.MOTION_CASCADES = MOTION_CASCADES; exports.MOTION_CLIP_TARGET = MOTION_CLIP_TARGET; exports.MOTION_COMMAND_FIELDS = MOTION_COMMAND_FIELDS; exports.MOTION_COMMAND_SCHEMA = MOTION_COMMAND_SCHEMA; exports.MOTION_COMMAND_TYPES = MOTION_COMMAND_TYPES; exports.MOTION_COMMAND_TYPE_SCHEMAS = MOTION_COMMAND_TYPE_SCHEMAS; exports.MOTION_DEFAULT_DURATIONS = MOTION_DEFAULT_DURATIONS; exports.MOTION_DEFAULT_HOLD = MOTION_DEFAULT_HOLD; exports.MOTION_DIRECTIONS = MOTION_DIRECTIONS; exports.MOTION_DRAW_EFFECT_ID = MOTION_DRAW_EFFECT_ID; exports.MOTION_DRAW_MS_PER_UNIT = MOTION_DRAW_MS_PER_UNIT; exports.MOTION_DRAW_RANGE = MOTION_DRAW_RANGE; exports.MOTION_DRIVEN_PROPERTIES = MOTION_DRIVEN_PROPERTIES; exports.MOTION_EASE_CHOICES = MOTION_EASE_CHOICES; exports.MOTION_EASE_IN_OUT = MOTION_EASE_IN_OUT; exports.MOTION_EASE_OUT = MOTION_EASE_OUT; exports.MOTION_EDIT_OPS = MOTION_EDIT_OPS; exports.MOTION_ENTER_STYLES = MOTION_ENTER_STYLES; exports.MOTION_EXIT_STYLES = MOTION_EXIT_STYLES; exports.MOTION_IRIS_SHAPES = MOTION_IRIS_SHAPES; exports.MOTION_ISSUE_CODES = _chunkEBDZWIOPcjs.MOTION_ISSUE_CODES; exports.MOTION_MAX_TAKE_MS = MOTION_MAX_TAKE_MS; exports.MOTION_MIN_CHANGE_MS = MOTION_MIN_CHANGE_MS; exports.MOTION_RECORD_GESTURE_MODES = MOTION_RECORD_GESTURE_MODES; exports.MOTION_REPEAT_MODES = MOTION_REPEAT_MODES; exports.MOTION_SPEED_RANGE = MOTION_SPEED_RANGE; exports.MOTION_SPLIT_ORIENTATIONS = MOTION_SPLIT_ORIENTATIONS; exports.MOTION_TEXT_STAGGER = MOTION_TEXT_STAGGER; exports.MOTION_TEXT_UNITS = MOTION_TEXT_UNITS; exports.MOTION_TRIGGERS = MOTION_TRIGGERS; exports.MotionSceneFormatError = MotionSceneFormatError; exports.activeSegment = activeSegment; exports.applyMotionControlValues = applyMotionControlValues; exports.applyMotionDrivers = applyMotionDrivers; exports.applyMotionEdits = applyMotionEdits; exports.checkMotionScene = checkMotionScene; exports.clipsShapeProblems = clipsShapeProblems; exports.commandShapeProblems = commandShapeProblems; exports.compileMotionScene = compileMotionScene; exports.createAnimationEditorDocument = createAnimationEditorDocument; exports.createAnimationEditorToolProvider = createAnimationEditorToolProvider; exports.createAnimationEffectsToolProvider = createAnimationEffectsToolProvider; exports.createMotionScene = createMotionScene; exports.defaultMotionCommand = defaultMotionCommand; exports.describeMotionElements = describeMotionElements; exports.describeMotionShots = describeMotionShots; exports.driversShapeProblems = driversShapeProblems; exports.duplicateMotionCommandEdit = duplicateMotionCommandEdit; exports.fitMotionRect = fitMotionRect; exports.fitMotionScene = fitMotionScene; exports.fitMotionSceneEdits = fitMotionSceneEdits; exports.flairAtLeast = flairAtLeast; exports.flairCurveFor = flairCurveFor; exports.flairEaseFor = flairEaseFor; exports.formatMotionDrivers = formatMotionDrivers; exports.formatMotionNarration = formatMotionNarration; exports.freshShotId = freshShotId; exports.fromFlairSvgMotion = fromFlairSvgMotion; exports.fromFlairVectorEffect = fromFlairVectorEffect; exports.fromPptxAnimation = fromPptxAnimation; exports.highlightMotionSvg = highlightMotionSvg; exports.indexMotionNodes = indexMotionNodes; exports.interpolateMotionValue = interpolateMotionValue; exports.isMotionCommand = isMotionCommand; exports.isMotionShot = isMotionShot; exports.matchMotionNodes = matchMotionNodes; exports.motionAddTrackKey = motionAddTrackKey; exports.motionArtworkSvg = motionArtworkSvg; exports.motionBeatAt = motionBeatAt; exports.motionBeatTime = motionBeatTime; exports.motionBlurTimes = motionBlurTimes; exports.motionCascade = motionCascade; exports.motionClientToDocument = motionClientToDocument; exports.motionClipAttrs = motionClipAttrs; exports.motionClipLayout = motionClipLayout; exports.motionCommandDuration = motionCommandDuration; exports.motionCommandFields = motionCommandFields; exports.motionCommandRepeat = motionCommandRepeat; exports.motionCommandRows = motionCommandRows; exports.motionCommandSlots = motionCommandSlots; exports.motionCommandSummary = motionCommandSummary; exports.motionCommandsFromEffect = motionCommandsFromEffect; exports.motionContactSheetSvg = motionContactSheetSvg; exports.motionCueChoices = motionCueChoices; exports.motionCueFromKey = motionCueFromKey; exports.motionCueKey = motionCueKey; exports.motionCueTime = motionCueTime; exports.motionCycleDuration = motionCycleDuration; exports.motionDrivenNodes = motionDrivenNodes; exports.motionDriverSources = motionDriverSources; exports.motionEaseKey = motionEaseKey; exports.motionEasingCurve = motionEasingCurve; exports.motionEasingGuides = motionEasingGuides; exports.motionEasingPath = motionEasingPath; exports.motionFieldEdit = motionFieldEdit; exports.motionFieldLabel = motionFieldLabel; exports.motionFlairPrimitive = motionFlairPrimitive; exports.motionFollowRoute = motionFollowRoute; exports.motionFrameAt = motionFrameAt; exports.motionFrameToSvg = motionFrameToSvg; exports.motionGhosts = motionGhosts; exports.motionIssue = _chunkEBDZWIOPcjs.motionIssue; exports.motionIssueKey = _chunkEBDZWIOPcjs.motionIssueKey; exports.motionIssueLine = _chunkEBDZWIOPcjs.motionIssueLine; exports.motionMovingIds = motionMovingIds; exports.motionNodeAtElement = motionNodeAtElement; exports.motionNodeClips = motionNodeClips; exports.motionNodeOffset = motionNodeOffset; exports.motionNodePose = motionNodePose; exports.motionPartsFromVectorEffect = motionPartsFromVectorEffect; exports.motionPath = motionPath; exports.motionPathLength = motionPathLength; exports.motionPathsSvg = motionPathsSvg; exports.motionPropertyValue = motionPropertyValue; exports.motionRestValue = motionRestValue; exports.motionRevealClip = motionRevealClip; exports.motionRevealPadding = motionRevealPadding; exports.motionRulerTicks = motionRulerTicks; exports.motionSceneEffects = motionSceneEffects; exports.motionSceneShapeProblems = motionSceneShapeProblems; exports.motionSceneToJson = motionSceneToJson; exports.motionShotAt = motionShotAt; exports.motionShotCueTime = motionShotCueTime; exports.motionShotTimeScale = motionShotTimeScale; exports.motionStageSvg = motionStageSvg; exports.motionTakeProblems = motionTakeProblems; exports.motionTakeShot = motionTakeShot; exports.motionTextLayout = motionTextLayout; exports.motionTextUnits = motionTextUnits; exports.motionTrackKey = motionTrackKey; exports.namedWithSuggestion = _chunkEBDZWIOPcjs.namedWithSuggestion; exports.nextMotionEffectInstance = nextMotionEffectInstance; exports.parseMotionDrivers = parseMotionDrivers; exports.parseMotionFieldInput = parseMotionFieldInput; exports.parseMotionNarration = parseMotionNarration; exports.parseMotionScene = parseMotionScene; exports.planAnimationToolPlayback = planAnimationToolPlayback; exports.resolveMotionCamera = resolveMotionCamera; exports.resolveMotionEditRefs = resolveMotionEditRefs; exports.segmentProgress = segmentProgress; exports.segmentValue = segmentValue; exports.shotShapeProblems = shotShapeProblems; exports.simplifyTimedSamples = simplifyTimedSamples; exports.smoothMotionLegs = smoothMotionLegs; exports.smoothMotionTimes = smoothMotionTimes; exports.suggestName = _chunkEBDZWIOPcjs.suggestName; exports.toFlairEffectDocument = toFlairEffectDocument; exports.toFlairSvgMotion = toFlairSvgMotion; exports.toFlairVectorEffect = toFlairVectorEffect; exports.toLottie = toLottie; exports.trackValue = trackValue; exports.withAnimationPlayback = withAnimationPlayback; exports.withMotionLayers = withMotionLayers; exports.withViewBox = withViewBox; exports.withoutMotionEffect = withoutMotionEffect;
|
|
@@ -9,6 +9,9 @@ import {
|
|
|
9
9
|
namedWithSuggestion,
|
|
10
10
|
suggestName
|
|
11
11
|
} from "../chunk-W4KFNAWC.js";
|
|
12
|
+
import {
|
|
13
|
+
defineEditorDocument
|
|
14
|
+
} from "../chunk-GNV54DLO.js";
|
|
12
15
|
import {
|
|
13
16
|
IDENTITY_MATRIX,
|
|
14
17
|
applyMatrix,
|
|
@@ -34,6 +37,7 @@ import {
|
|
|
34
37
|
} from "../chunk-FLOGD3QB.js";
|
|
35
38
|
import "../chunk-ORDXMBD4.js";
|
|
36
39
|
import "../chunk-M6DNZNVY.js";
|
|
40
|
+
import "../chunk-WHKNYFM2.js";
|
|
37
41
|
import {
|
|
38
42
|
bezierPathLength,
|
|
39
43
|
bezierPathPointAtLength,
|
|
@@ -59,6 +63,7 @@ import {
|
|
|
59
63
|
readZip
|
|
60
64
|
} from "../chunk-CIQIM2IP.js";
|
|
61
65
|
import "../chunk-VDGBHYC7.js";
|
|
66
|
+
import "../chunk-HF5QZS7Z.js";
|
|
62
67
|
import {
|
|
63
68
|
HistoryManager
|
|
64
69
|
} from "../chunk-RNSANXPT.js";
|
|
@@ -5930,6 +5935,32 @@ function createAnimationEffectsToolProvider(controller, options = {}) {
|
|
|
5930
5935
|
]
|
|
5931
5936
|
}), options.playbackSurface);
|
|
5932
5937
|
}
|
|
5938
|
+
|
|
5939
|
+
// src/animation-editor/editorDocument.ts
|
|
5940
|
+
function createAnimationEditorDocument(controller) {
|
|
5941
|
+
return defineEditorDocument({
|
|
5942
|
+
kind: "animation",
|
|
5943
|
+
get: () => controller.getScene(),
|
|
5944
|
+
load: (document, { history }) => {
|
|
5945
|
+
const result = controller.load(document, { clearHistory: history === "reset" });
|
|
5946
|
+
if (!result.ok) throw new Error(result.error);
|
|
5947
|
+
},
|
|
5948
|
+
subscribe: (listener) => {
|
|
5949
|
+
let scene = controller.getScene();
|
|
5950
|
+
return controller.subscribe(() => {
|
|
5951
|
+
if (controller.getScene() === scene) return;
|
|
5952
|
+
scene = controller.getScene();
|
|
5953
|
+
listener();
|
|
5954
|
+
});
|
|
5955
|
+
},
|
|
5956
|
+
history: {
|
|
5957
|
+
undo: () => controller.undo(),
|
|
5958
|
+
redo: () => controller.redo(),
|
|
5959
|
+
getState: () => controller.history.getState()
|
|
5960
|
+
},
|
|
5961
|
+
readOnly: () => controller.getState().readOnly ? "The animation is read-only." : false
|
|
5962
|
+
});
|
|
5963
|
+
}
|
|
5933
5964
|
export {
|
|
5934
5965
|
ANIMATION_EDITOR_AGENT_INSTRUCTIONS,
|
|
5935
5966
|
AnimationEditorController,
|
|
@@ -5977,6 +6008,7 @@ export {
|
|
|
5977
6008
|
clipsShapeProblems,
|
|
5978
6009
|
commandShapeProblems,
|
|
5979
6010
|
compileMotionScene,
|
|
6011
|
+
createAnimationEditorDocument,
|
|
5980
6012
|
createAnimationEditorToolProvider,
|
|
5981
6013
|
createAnimationEffectsToolProvider,
|
|
5982
6014
|
createMotionScene,
|
package/dist/bridge/cli.cjs
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
"use strict"; function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
|
|
3
3
|
|
|
4
|
-
var
|
|
5
|
-
require('../chunk-
|
|
6
|
-
require('../chunk-2BSBFBOA.cjs');
|
|
4
|
+
var _chunk24M7VD6Mcjs = require('../chunk-24M7VD6M.cjs');
|
|
5
|
+
require('../chunk-462WGGXX.cjs');
|
|
7
6
|
require('../chunk-WOFXZ3XU.cjs');
|
|
7
|
+
require('../chunk-2BSBFBOA.cjs');
|
|
8
8
|
|
|
9
9
|
// src/bridge/cli.ts
|
|
10
10
|
var args = process.argv.slice(2);
|
|
@@ -23,7 +23,7 @@ args.forEach((arg, i) => {
|
|
|
23
23
|
if (arg === "--origin" && args[i + 1]) origins.push(args[i + 1]);
|
|
24
24
|
});
|
|
25
25
|
var port = value("--port");
|
|
26
|
-
void
|
|
26
|
+
void _chunk24M7VD6Mcjs.createToolBridge.call(void 0, {
|
|
27
27
|
name: _nullishCoalesce(value("--name"), () => ( "pixerate")),
|
|
28
28
|
port: port !== void 0 ? Number(port) : void 0,
|
|
29
29
|
token: _nullishCoalesce(value("--token"), () => ( process.env.PIXERATE_BRIDGE_TOKEN)),
|
package/dist/bridge/cli.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
createToolBridge
|
|
4
|
-
} from "../chunk-
|
|
5
|
-
import "../chunk-
|
|
6
|
-
import "../chunk-HF5QZS7Z.js";
|
|
4
|
+
} from "../chunk-MKTDELCD.js";
|
|
5
|
+
import "../chunk-EVXQNQND.js";
|
|
7
6
|
import "../chunk-V2ZCJRDM.js";
|
|
7
|
+
import "../chunk-HF5QZS7Z.js";
|
|
8
8
|
|
|
9
9
|
// src/bridge/cli.ts
|
|
10
10
|
var args = process.argv.slice(2);
|
package/dist/bridge/index.cjs
CHANGED
|
@@ -3,13 +3,13 @@
|
|
|
3
3
|
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunk24M7VD6Mcjs = require('../chunk-24M7VD6M.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
var
|
|
11
|
-
require('../chunk-2BSBFBOA.cjs');
|
|
10
|
+
var _chunk462WGGXXcjs = require('../chunk-462WGGXX.cjs');
|
|
12
11
|
require('../chunk-WOFXZ3XU.cjs');
|
|
12
|
+
require('../chunk-2BSBFBOA.cjs');
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
|
|
@@ -17,4 +17,4 @@ require('../chunk-WOFXZ3XU.cjs');
|
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
|
|
20
|
-
exports.TOOL_BRIDGE_DEFAULT_PORT =
|
|
20
|
+
exports.TOOL_BRIDGE_DEFAULT_PORT = _chunk462WGGXXcjs.TOOL_BRIDGE_DEFAULT_PORT; exports.TOOL_BRIDGE_PROTOCOL = _chunk462WGGXXcjs.TOOL_BRIDGE_PROTOCOL; exports.createToolBridge = _chunk24M7VD6Mcjs.createToolBridge; exports.defaultSkillsDir = _chunk24M7VD6Mcjs.defaultSkillsDir; exports.isLocalOrigin = _chunk24M7VD6Mcjs.isLocalOrigin; exports.loadSkillFiles = _chunk24M7VD6Mcjs.loadSkillFiles;
|
package/dist/bridge/index.js
CHANGED
|
@@ -3,13 +3,13 @@ import {
|
|
|
3
3
|
defaultSkillsDir,
|
|
4
4
|
isLocalOrigin,
|
|
5
5
|
loadSkillFiles
|
|
6
|
-
} from "../chunk-
|
|
6
|
+
} from "../chunk-MKTDELCD.js";
|
|
7
7
|
import {
|
|
8
8
|
TOOL_BRIDGE_DEFAULT_PORT,
|
|
9
9
|
TOOL_BRIDGE_PROTOCOL
|
|
10
|
-
} from "../chunk-
|
|
11
|
-
import "../chunk-HF5QZS7Z.js";
|
|
10
|
+
} from "../chunk-EVXQNQND.js";
|
|
12
11
|
import "../chunk-V2ZCJRDM.js";
|
|
12
|
+
import "../chunk-HF5QZS7Z.js";
|
|
13
13
|
export {
|
|
14
14
|
TOOL_BRIDGE_DEFAULT_PORT,
|
|
15
15
|
TOOL_BRIDGE_PROTOCOL,
|
|
@@ -263,6 +263,11 @@ export declare class ChartController {
|
|
|
263
263
|
load(input: unknown, options?: {
|
|
264
264
|
clearHistory?: boolean;
|
|
265
265
|
}): ChartIssue[];
|
|
266
|
+
/**
|
|
267
|
+
* Replaces the whole chart as one undo step. All-or-nothing: if `input` has any problem,
|
|
268
|
+
* nothing changes and every problem is returned (and shown in `state.issues`).
|
|
269
|
+
*/
|
|
270
|
+
replace(input: unknown, options?: ChartEditOptions): ChartActionResult;
|
|
266
271
|
undo(): boolean;
|
|
267
272
|
redo(): boolean;
|
|
268
273
|
/** Stops listening to the history (reconnected by the next `subscribe`). */
|
|
@@ -263,6 +263,11 @@ export declare class ChartController {
|
|
|
263
263
|
load(input: unknown, options?: {
|
|
264
264
|
clearHistory?: boolean;
|
|
265
265
|
}): ChartIssue[];
|
|
266
|
+
/**
|
|
267
|
+
* Replaces the whole chart as one undo step. All-or-nothing: if `input` has any problem,
|
|
268
|
+
* nothing changes and every problem is returned (and shown in `state.issues`).
|
|
269
|
+
*/
|
|
270
|
+
replace(input: unknown, options?: ChartEditOptions): ChartActionResult;
|
|
266
271
|
undo(): boolean;
|
|
267
272
|
redo(): boolean;
|
|
268
273
|
/** Stops listening to the history (reconnected by the next `subscribe`). */
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type EditorDocument } from '../persistence/editorDocument.cjs';
|
|
2
|
+
import type { ChartController } from './controller.cjs';
|
|
3
|
+
import type { ChartSpec } from './types.cjs';
|
|
4
|
+
/**
|
|
5
|
+
* The save / load / undo contract for a `ChartController` (kind `chart`, document: the
|
|
6
|
+
* `ChartSpec`). A recorded load (agents) is one undo step and refuses a spec with any
|
|
7
|
+
* problem; opening a file (`history: "reset"`) repairs problems with defaults and reports
|
|
8
|
+
* them in the `LoadReport`.
|
|
9
|
+
*/
|
|
10
|
+
export declare function createChartEditorDocument(controller: ChartController): EditorDocument<ChartSpec>;
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import { type EditorDocument } from '../persistence/editorDocument.js';
|
|
2
|
+
import type { ChartController } from './controller.js';
|
|
3
|
+
import type { ChartSpec } from './types.js';
|
|
4
|
+
/**
|
|
5
|
+
* The save / load / undo contract for a `ChartController` (kind `chart`, document: the
|
|
6
|
+
* `ChartSpec`). A recorded load (agents) is one undo step and refuses a spec with any
|
|
7
|
+
* problem; opening a file (`history: "reset"`) repairs problems with defaults and reports
|
|
8
|
+
* them in the `LoadReport`.
|
|
9
|
+
*/
|
|
10
|
+
export declare function createChartEditorDocument(controller: ChartController): EditorDocument<ChartSpec>;
|