@pixerate/editor 0.272.0 → 0.273.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.
Files changed (65) hide show
  1. package/dist/agent/index.cjs +34 -32
  2. package/dist/agent/index.js +10 -8
  3. package/dist/chart/contract.d.cts +95 -0
  4. package/dist/chart/contract.d.ts +95 -0
  5. package/dist/chart/controller.d.cts +4 -0
  6. package/dist/chart/controller.d.ts +4 -0
  7. package/dist/chart/index.cjs +492 -26
  8. package/dist/chart/index.d.cts +1 -0
  9. package/dist/chart/index.d.ts +1 -0
  10. package/dist/chart/index.js +476 -10
  11. package/dist/chart/tools.d.cts +3 -0
  12. package/dist/chart/tools.d.ts +3 -0
  13. package/dist/chart-maps/index.cjs +4 -64
  14. package/dist/chart-maps/index.js +3 -63
  15. package/dist/chunk-2A5IKZMU.js +557 -0
  16. package/dist/{chunk-NMZQMPFZ.js → chunk-4LZQO5Y7.js} +2 -0
  17. package/dist/chunk-5UGRMVNE.js +328 -0
  18. package/dist/{chunk-X4FTNFIA.js → chunk-7MGPW2OV.js} +1 -1
  19. package/dist/{chunk-DGITFN73.cjs → chunk-BWJBZAUE.cjs} +8 -8
  20. package/dist/chunk-CHZYVNXZ.js +336 -0
  21. package/dist/chunk-DRMZ5R3S.cjs +67 -0
  22. package/dist/chunk-EI5GFTKG.js +67 -0
  23. package/dist/chunk-JV7DKLMX.js +1073 -0
  24. package/dist/chunk-MFBUQC67.cjs +328 -0
  25. package/dist/{chunk-IBXEQOGI.js → chunk-PYHB2EHE.js} +2 -324
  26. package/dist/chunk-QEUI6OGE.cjs +336 -0
  27. package/dist/{chunk-6ZSFRRJI.js → chunk-RSF6BT34.js} +1 -1
  28. package/dist/chunk-T2HUQBRC.cjs +1073 -0
  29. package/dist/{chunk-GSLOH2IN.cjs → chunk-VF6ODSYX.cjs} +2 -0
  30. package/dist/{chunk-NQUKTRKN.cjs → chunk-WZLNNGG3.cjs} +45 -45
  31. package/dist/{chunk-NRBGAEFI.cjs → chunk-Y3RUYOOW.cjs} +8 -330
  32. package/dist/chunk-YH6SKC7P.cjs +557 -0
  33. package/dist/commands/index.cjs +7 -323
  34. package/dist/commands/index.js +5 -321
  35. package/dist/extensions/index.cjs +4 -4
  36. package/dist/extensions/index.js +3 -3
  37. package/dist/index.cjs +9 -9
  38. package/dist/index.js +3 -3
  39. package/dist/paint-editor/controller.d.cts +86 -0
  40. package/dist/paint-editor/controller.d.ts +86 -0
  41. package/dist/paint-editor/document.d.cts +1 -1
  42. package/dist/paint-editor/document.d.ts +1 -1
  43. package/dist/paint-editor/index.cjs +559 -166
  44. package/dist/paint-editor/index.d.cts +1 -0
  45. package/dist/paint-editor/index.d.ts +1 -0
  46. package/dist/paint-editor/index.js +397 -4
  47. package/dist/paint-editor/presence.d.cts +5 -1
  48. package/dist/paint-editor/presence.d.ts +5 -1
  49. package/dist/paint-editor/ui.d.cts +5 -2
  50. package/dist/paint-editor/ui.d.ts +5 -2
  51. package/dist/persistence/index.cjs +24 -1042
  52. package/dist/persistence/index.js +22 -1040
  53. package/dist/raster/fill.d.cts +85 -0
  54. package/dist/raster/fill.d.ts +85 -0
  55. package/dist/raster/index.cjs +9 -1
  56. package/dist/raster/index.d.cts +1 -0
  57. package/dist/raster/index.d.ts +1 -0
  58. package/dist/raster/index.js +8 -0
  59. package/dist/tools/index.cjs +5 -3
  60. package/dist/tools/index.js +8 -6
  61. package/package.json +1 -1
  62. package/skills/pixerate-paint-editor/SKILL.md +19 -43
  63. package/skills/pixerate-paint-editor/references/evolution.md +27 -0
  64. package/skills/pixerate-paint-sketch-to-finish/SKILL.md +16 -5
  65. package/skills/pixerate-paint-sketch-to-finish/evals/flats-under-ink.json +2 -3
@@ -816,6 +816,7 @@ var fail = (message, issues) => ({ ok: false, message, ...issues ? { issues } :
816
816
  var ChartController = (_class = class {
817
817
 
818
818
 
819
+
819
820
  __init() {this.selection = null}
820
821
  __init2() {this.issues = []}
821
822
  __init3() {this.gestureKey = null}
@@ -832,6 +833,7 @@ var ChartController = (_class = class {
832
833
 
833
834
  constructor(options = {}) {;_class.prototype.__init.call(this);_class.prototype.__init2.call(this);_class.prototype.__init3.call(this);_class.prototype.__init4.call(this);_class.prototype.__init5.call(this);_class.prototype.__init6.call(this);_class.prototype.__init7.call(this);_class.prototype.__init8.call(this);_class.prototype.__init9.call(this);_class.prototype.__init10.call(this);_class.prototype.__init11.call(this);_class.prototype.__init12.call(this);
834
835
  this.history = _nullishCoalesce(options.history, () => ( new (0, _chunkWPLGZBNEcjs.HistoryManager)()));
836
+ this.measureText = options.measureText;
835
837
  this.onChange = options.onChange;
836
838
  this.raceTicker = _nullishCoalesce(options.raceTicker, () => ( defaultRaceTicker));
837
839
  const { spec, issues } = _chunkP6WYDBTHcjs.normalizeChartSpec.call(void 0, _nullishCoalesce(options.spec, () => ( {})));
@@ -35,7 +35,7 @@ var _chunkHMGWFXECcjs = require('./chunk-HMGWFXEC.cjs');
35
35
 
36
36
 
37
37
 
38
- var _chunkDGITFN73cjs = require('./chunk-DGITFN73.cjs');
38
+ var _chunkBWJBZAUEcjs = require('./chunk-BWJBZAUE.cjs');
39
39
 
40
40
 
41
41
  var _chunkP6WYDBTHcjs = require('./chunk-P6WYDBTH.cjs');
@@ -2013,9 +2013,9 @@ function insertImportedDocument(target, content, options = {}) {
2013
2013
  if (!htmlSlice && from === to && !state.doc.resolve(from).parent.inlineContent) {
2014
2014
  from = to = _state.Selection.near(state.doc.resolve(from)).from;
2015
2015
  }
2016
- if (htmlSlice && _chunkDGITFN73cjs.sliceContainsTable.call(void 0, htmlSlice) && _chunkDGITFN73cjs.outermostTableDepth.call(void 0, state.doc.resolve(from)) >= 0) {
2016
+ if (htmlSlice && _chunkBWJBZAUEcjs.sliceContainsTable.call(void 0, htmlSlice) && _chunkBWJBZAUEcjs.outermostTableDepth.call(void 0, state.doc.resolve(from)) >= 0) {
2017
2017
  const tr2 = state.tr;
2018
- const end2 = _chunkDGITFN73cjs.insertSliceAfterTable.call(void 0, tr2, from, to, htmlSlice);
2018
+ const end2 = _chunkBWJBZAUEcjs.insertSliceAfterTable.call(void 0, tr2, from, to, htmlSlice);
2019
2019
  if (end2 !== null) {
2020
2020
  if (options.at === void 0) tr2.setSelection(_state.Selection.near(tr2.doc.resolve(end2), -1));
2021
2021
  view.dispatch(tr2.scrollIntoView().setMeta("uiEvent", "drop"));
@@ -3847,7 +3847,7 @@ var RichClipboard = _core.Extension.create({
3847
3847
  const slice = _chunk3AJMR7EGcjs.readRichClipboard.call(void 0, event, view.state.schema, mimeType);
3848
3848
  if (!slice) return false;
3849
3849
  event.preventDefault();
3850
- if (_chunkDGITFN73cjs.handleTablePasteWithoutNesting.call(void 0, view, event, slice)) return true;
3850
+ if (_chunkBWJBZAUEcjs.handleTablePasteWithoutNesting.call(void 0, view, event, slice)) return true;
3851
3851
  view.dispatch(
3852
3852
  view.state.tr.replaceSelection(slice).scrollIntoView().setMeta("paste", true).setMeta("uiEvent", "paste")
3853
3853
  );
@@ -4248,7 +4248,7 @@ function createOutlineStore(editor) {
4248
4248
  if (!editor || editor.isDestroyed) return EMPTY_SNAPSHOT;
4249
4249
  const headings = getOutline(editor);
4250
4250
  const activeId = _nullishCoalesce(_optionalChain([getActiveHeading, 'call', _188 => _188(editor, headings), 'optionalAccess', _189 => _189.id]), () => ( null));
4251
- const sameStructure = _chunkDGITFN73cjs.arraysEqual.call(void 0, snapshot.headings, headings, sameHeading);
4251
+ const sameStructure = _chunkBWJBZAUEcjs.arraysEqual.call(void 0, snapshot.headings, headings, sameHeading);
4252
4252
  if (sameStructure && snapshot.activeId === activeId) return snapshot;
4253
4253
  return {
4254
4254
  headings: sameStructure ? snapshot.headings : headings,
@@ -4296,7 +4296,7 @@ function navigateToHeading(editor, heading, options = {}) {
4296
4296
  editor.view.dispatch(tr);
4297
4297
  editor.view.focus();
4298
4298
  }
4299
- _chunkDGITFN73cjs.scrollDomAtPos.call(void 0, editor.view, current.pos, behavior);
4299
+ _chunkBWJBZAUEcjs.scrollDomAtPos.call(void 0, editor.view, current.pos, behavior);
4300
4300
  return true;
4301
4301
  }
4302
4302
  function assignHeadingIds(state, types, generateId) {
@@ -4321,11 +4321,11 @@ function assignHeadingIds(state, types, generateId) {
4321
4321
  }
4322
4322
  var Outline = _core.Extension.create({
4323
4323
  name: "outline",
4324
- priority: _chunkDGITFN73cjs.STRUCTURE_PRIORITY,
4324
+ priority: _chunkBWJBZAUEcjs.STRUCTURE_PRIORITY,
4325
4325
  addOptions() {
4326
4326
  return {
4327
4327
  types: ["heading"],
4328
- generateId: () => _chunkDGITFN73cjs.generateStructureId.call(void 0, "h"),
4328
+ generateId: () => _chunkBWJBZAUEcjs.generateStructureId.call(void 0, "h"),
4329
4329
  onUpdate: void 0
4330
4330
  };
4331
4331
  },
@@ -4358,14 +4358,14 @@ var Outline = _core.Extension.create({
4358
4358
  tr.scrollIntoView();
4359
4359
  _optionalChain([view, 'optionalAccess', _196 => _196.focus, 'optionalCall', _197 => _197()]);
4360
4360
  }
4361
- _chunkDGITFN73cjs.scrollDomAtPos.call(void 0, view, heading.pos, options.behavior);
4361
+ _chunkBWJBZAUEcjs.scrollDomAtPos.call(void 0, view, heading.pos, options.behavior);
4362
4362
  }
4363
4363
  return true;
4364
4364
  },
4365
4365
  scrollToHeading: (id, options = {}) => ({ state, dispatch, view }) => {
4366
4366
  const heading = findHeading(state, id);
4367
4367
  if (!heading) return false;
4368
- if (dispatch) _chunkDGITFN73cjs.scrollDomAtPos.call(void 0, view, heading.pos, options.behavior);
4368
+ if (dispatch) _chunkBWJBZAUEcjs.scrollDomAtPos.call(void 0, view, heading.pos, options.behavior);
4369
4369
  return true;
4370
4370
  }
4371
4371
  };
@@ -4386,7 +4386,7 @@ var Outline = _core.Extension.create({
4386
4386
  apply: (tr, prev, _oldState, newState) => {
4387
4387
  if (!tr.docChanged) return prev;
4388
4388
  const next = computeOutline(newState.doc, types);
4389
- if (_chunkDGITFN73cjs.arraysEqual.call(void 0, prev, next, sameHeading)) return prev;
4389
+ if (_chunkBWJBZAUEcjs.arraysEqual.call(void 0, prev, next, sameHeading)) return prev;
4390
4390
  storage.headings = next;
4391
4391
  _optionalChain([onUpdate, 'call', _198 => _198(), 'optionalCall', _199 => _199(next)]);
4392
4392
  return next;
@@ -4404,7 +4404,7 @@ var Outline = _core.Extension.create({
4404
4404
  },
4405
4405
  onBeforeCreate() {
4406
4406
  const { types, generateId } = this.options;
4407
- _chunkDGITFN73cjs.syncInitialContent.call(void 0, this.editor, (state) => assignHeadingIds(state, types, generateId));
4407
+ _chunkBWJBZAUEcjs.syncInitialContent.call(void 0, this.editor, (state) => assignHeadingIds(state, types, generateId));
4408
4408
  }
4409
4409
  });
4410
4410
 
@@ -4574,7 +4574,7 @@ function syncTableOfContents(state, headingTypes) {
4574
4574
  node.attrs.minLevel,
4575
4575
  node.attrs.maxLevel
4576
4576
  );
4577
- if (!_chunkDGITFN73cjs.arraysEqual.call(void 0, _nullishCoalesce(node.attrs.entries, () => ( [])), entries, sameEntry)) {
4577
+ if (!_chunkBWJBZAUEcjs.arraysEqual.call(void 0, _nullishCoalesce(node.attrs.entries, () => ( [])), entries, sameEntry)) {
4578
4578
  tr = _nullishCoalesce(tr, () => ( state.tr));
4579
4579
  tr.setNodeMarkup(pos, void 0, { ...node.attrs, entries });
4580
4580
  }
@@ -4586,7 +4586,7 @@ function syncTableOfContents(state, headingTypes) {
4586
4586
  }
4587
4587
  var TableOfContents = _core.Node.create({
4588
4588
  name: "tableOfContents",
4589
- priority: _chunkDGITFN73cjs.STRUCTURE_PRIORITY - 5,
4589
+ priority: _chunkBWJBZAUEcjs.STRUCTURE_PRIORITY - 5,
4590
4590
  group: "block",
4591
4591
  atom: true,
4592
4592
  selectable: true,
@@ -4697,7 +4697,7 @@ var TableOfContents = _core.Node.create({
4697
4697
  return [
4698
4698
  new (0, _state.Plugin)({
4699
4699
  key: tableOfContentsPluginKey,
4700
- state: _chunkDGITFN73cjs.presenceStateSpec.call(void 0, [this.name]),
4700
+ state: _chunkBWJBZAUEcjs.presenceStateSpec.call(void 0, [this.name]),
4701
4701
  appendTransaction: (transactions, _oldState, newState) => {
4702
4702
  if (!transactions.some((tr) => tr.docChanged)) return null;
4703
4703
  if (!tableOfContentsPluginKey.getState(newState)) return null;
@@ -4721,7 +4721,7 @@ var TableOfContents = _core.Node.create({
4721
4721
  );
4722
4722
  view.focus();
4723
4723
  }
4724
- _chunkDGITFN73cjs.scrollDomAtPos.call(void 0, view, heading.pos);
4724
+ _chunkBWJBZAUEcjs.scrollDomAtPos.call(void 0, view, heading.pos);
4725
4725
  return true;
4726
4726
  }
4727
4727
  }
@@ -4731,7 +4731,7 @@ var TableOfContents = _core.Node.create({
4731
4731
  },
4732
4732
  onBeforeCreate() {
4733
4733
  const { headingTypes } = this.options;
4734
- _chunkDGITFN73cjs.syncInitialContent.call(void 0, this.editor, (state) => syncTableOfContents(state, headingTypes));
4734
+ _chunkBWJBZAUEcjs.syncInitialContent.call(void 0, this.editor, (state) => syncTableOfContents(state, headingTypes));
4735
4735
  }
4736
4736
  });
4737
4737
 
@@ -4789,7 +4789,7 @@ function syncFootnotes(tr, options = {}) {
4789
4789
  const listType = schema.nodes[LIST];
4790
4790
  const itemType = schema.nodes[ITEM];
4791
4791
  if (!listType || !itemType) return false;
4792
- const generateId = _nullishCoalesce(options.generateId, () => ( (() => _chunkDGITFN73cjs.generateStructureId.call(void 0, "fn"))));
4792
+ const generateId = _nullishCoalesce(options.generateId, () => ( (() => _chunkBWJBZAUEcjs.generateStructureId.call(void 0, "fn"))));
4793
4793
  const refs = [];
4794
4794
  const lists = [];
4795
4795
  const existing = /* @__PURE__ */ new Map();
@@ -4873,7 +4873,7 @@ function findReferences(doc, id) {
4873
4873
  }
4874
4874
  var FootnoteReference = _core.Node.create({
4875
4875
  name: REFERENCE,
4876
- priority: _chunkDGITFN73cjs.STRUCTURE_PRIORITY - 5,
4876
+ priority: _chunkBWJBZAUEcjs.STRUCTURE_PRIORITY - 5,
4877
4877
  group: "inline",
4878
4878
  inline: true,
4879
4879
  atom: true,
@@ -4881,7 +4881,7 @@ var FootnoteReference = _core.Node.create({
4881
4881
  addOptions() {
4882
4882
  return {
4883
4883
  HTMLAttributes: {},
4884
- generateId: () => _chunkDGITFN73cjs.generateStructureId.call(void 0, "fn")
4884
+ generateId: () => _chunkBWJBZAUEcjs.generateStructureId.call(void 0, "fn")
4885
4885
  };
4886
4886
  },
4887
4887
  addAttributes() {
@@ -4992,7 +4992,7 @@ var FootnoteReference = _core.Node.create({
4992
4992
  _state.TextSelection.create(tr.doc, footnote.pos + footnote.node.nodeSize - 2)
4993
4993
  );
4994
4994
  tr.scrollIntoView();
4995
- _chunkDGITFN73cjs.scrollDomAtPos.call(void 0, view, footnote.pos);
4995
+ _chunkBWJBZAUEcjs.scrollDomAtPos.call(void 0, view, footnote.pos);
4996
4996
  }
4997
4997
  return true;
4998
4998
  },
@@ -5002,7 +5002,7 @@ var FootnoteReference = _core.Node.create({
5002
5002
  if (dispatch) {
5003
5003
  tr.setSelection(_state.NodeSelection.create(tr.doc, ref.pos));
5004
5004
  tr.scrollIntoView();
5005
- _chunkDGITFN73cjs.scrollDomAtPos.call(void 0, view, ref.pos);
5005
+ _chunkBWJBZAUEcjs.scrollDomAtPos.call(void 0, view, ref.pos);
5006
5006
  }
5007
5007
  return true;
5008
5008
  }
@@ -5014,7 +5014,7 @@ var FootnoteReference = _core.Node.create({
5014
5014
  return [
5015
5015
  new (0, _state.Plugin)({
5016
5016
  key: footnotesPluginKey,
5017
- state: _chunkDGITFN73cjs.presenceStateSpec.call(void 0, [REFERENCE, LIST]),
5017
+ state: _chunkBWJBZAUEcjs.presenceStateSpec.call(void 0, [REFERENCE, LIST]),
5018
5018
  appendTransaction: (transactions, _oldState, newState) => {
5019
5019
  if (!transactions.some((tr2) => tr2.docChanged)) return null;
5020
5020
  if (!footnotesPluginKey.getState(newState)) return null;
@@ -5035,7 +5035,7 @@ var FootnoteReference = _core.Node.create({
5035
5035
  },
5036
5036
  onBeforeCreate() {
5037
5037
  const { generateId } = this.options;
5038
- _chunkDGITFN73cjs.syncInitialContent.call(void 0, this.editor, (state) => {
5038
+ _chunkBWJBZAUEcjs.syncInitialContent.call(void 0, this.editor, (state) => {
5039
5039
  const tr = state.tr;
5040
5040
  return syncFootnotes(tr, { generateId }) ? tr : null;
5041
5041
  });
@@ -5175,7 +5175,7 @@ var Bookmark = _core.Mark.create({
5175
5175
  addOptions() {
5176
5176
  return {
5177
5177
  HTMLAttributes: {},
5178
- generateId: () => _chunkDGITFN73cjs.generateStructureId.call(void 0, "bm")
5178
+ generateId: () => _chunkBWJBZAUEcjs.generateStructureId.call(void 0, "bm")
5179
5179
  };
5180
5180
  },
5181
5181
  addAttributes() {
@@ -5260,7 +5260,7 @@ var Bookmark = _core.Mark.create({
5260
5260
  tr.setSelection(_state.TextSelection.create(tr.doc, bookmark.from, bookmark.to));
5261
5261
  tr.scrollIntoView();
5262
5262
  const domPos = state.doc.resolve(bookmark.from);
5263
- _chunkDGITFN73cjs.scrollDomAtPos.call(void 0, view, domPos.before(domPos.depth));
5263
+ _chunkBWJBZAUEcjs.scrollDomAtPos.call(void 0, view, domPos.before(domPos.depth));
5264
5264
  }
5265
5265
  return true;
5266
5266
  }
@@ -5325,7 +5325,7 @@ function syncCrossReferences(state, headingTypes) {
5325
5325
  }
5326
5326
  var CrossReference = _core.Node.create({
5327
5327
  name: NAME,
5328
- priority: _chunkDGITFN73cjs.STRUCTURE_PRIORITY - 5,
5328
+ priority: _chunkBWJBZAUEcjs.STRUCTURE_PRIORITY - 5,
5329
5329
  group: "inline",
5330
5330
  inline: true,
5331
5331
  atom: true,
@@ -5427,7 +5427,7 @@ var CrossReference = _core.Node.create({
5427
5427
  if (dispatch) {
5428
5428
  tr.setSelection(_state.TextSelection.create(tr.doc, range.from, range.to));
5429
5429
  tr.scrollIntoView();
5430
- _chunkDGITFN73cjs.scrollDomAtPos.call(void 0, view, range.blockPos);
5430
+ _chunkBWJBZAUEcjs.scrollDomAtPos.call(void 0, view, range.blockPos);
5431
5431
  }
5432
5432
  return true;
5433
5433
  }
@@ -5439,7 +5439,7 @@ var CrossReference = _core.Node.create({
5439
5439
  return [
5440
5440
  new (0, _state.Plugin)({
5441
5441
  key: crossReferencePluginKey,
5442
- state: _chunkDGITFN73cjs.presenceStateSpec.call(void 0, [NAME]),
5442
+ state: _chunkBWJBZAUEcjs.presenceStateSpec.call(void 0, [NAME]),
5443
5443
  appendTransaction: (transactions, _oldState, newState) => {
5444
5444
  if (!transactions.some((tr) => tr.docChanged)) return null;
5445
5445
  if (!crossReferencePluginKey.getState(newState)) return null;
@@ -5458,7 +5458,7 @@ var CrossReference = _core.Node.create({
5458
5458
  },
5459
5459
  onBeforeCreate() {
5460
5460
  const { headingTypes } = this.options;
5461
- _chunkDGITFN73cjs.syncInitialContent.call(void 0, this.editor, (state) => syncCrossReferences(state, headingTypes));
5461
+ _chunkBWJBZAUEcjs.syncInitialContent.call(void 0, this.editor, (state) => syncCrossReferences(state, headingTypes));
5462
5462
  }
5463
5463
  });
5464
5464
 
@@ -5713,7 +5713,7 @@ var FindReplace = _core.Extension.create({
5713
5713
  if (!s || !s.active || s.currentIndex < 0 || !s.matches[s.currentIndex]) return false;
5714
5714
  if (dispatch) {
5715
5715
  _history.closeHistory.call(void 0, tr);
5716
- const [end] = _chunkDGITFN73cjs.applyReplacements.call(void 0, tr, [s.matches[s.currentIndex]]);
5716
+ const [end] = _chunkBWJBZAUEcjs.applyReplacements.call(void 0, tr, [s.matches[s.currentIndex]]);
5717
5717
  tr.setSelection(_state.TextSelection.create(tr.doc, end)).scrollIntoView();
5718
5718
  meta(tr, { type: "replaced", anchor: end, count: 1 });
5719
5719
  }
@@ -5724,7 +5724,7 @@ var FindReplace = _core.Extension.create({
5724
5724
  if (!s || !s.active || !s.matches.length) return false;
5725
5725
  if (dispatch) {
5726
5726
  _history.closeHistory.call(void 0, tr);
5727
- const ends = _chunkDGITFN73cjs.applyReplacements.call(void 0, tr, s.matches);
5727
+ const ends = _chunkBWJBZAUEcjs.applyReplacements.call(void 0, tr, s.matches);
5728
5728
  meta(tr, { type: "replaced", anchor: ends[ends.length - 1], count: s.matches.length });
5729
5729
  }
5730
5730
  return true;
@@ -5756,7 +5756,7 @@ var FindReplace = _core.Extension.create({
5756
5756
  if (!s.active || !s.query) {
5757
5757
  return { ...s, matches: [], currentIndex: -1, error: null, truncated: false };
5758
5758
  }
5759
- const result = _chunkDGITFN73cjs.searchDocument.call(void 0, doc, s.query, s.options, {
5759
+ const result = _chunkBWJBZAUEcjs.searchDocument.call(void 0, doc, s.query, s.options, {
5760
5760
  replacement: s.replacement,
5761
5761
  clipboardText: safeClipboard(options.getClipboardText),
5762
5762
  timeLimitMs: options.timeLimitMs,
@@ -6343,7 +6343,7 @@ function createRichTextPreset(options = {}) {
6343
6343
  })
6344
6344
  ];
6345
6345
  if (options.table !== false) {
6346
- extensions2.push(..._chunkDGITFN73cjs.createTableExtensions.call(void 0, optionObject(options.table)));
6346
+ extensions2.push(..._chunkBWJBZAUEcjs.createTableExtensions.call(void 0, optionObject(options.table)));
6347
6347
  }
6348
6348
  if (characterLimit) {
6349
6349
  extensions2.push(
@@ -6400,7 +6400,7 @@ function createRichTextPreset(options = {}) {
6400
6400
  }
6401
6401
  if (options.comments) {
6402
6402
  extensions2.push(
6403
- typeof options.comments === "object" ? _chunkDGITFN73cjs.Comments.configure(options.comments) : _chunkDGITFN73cjs.Comments
6403
+ typeof options.comments === "object" ? _chunkBWJBZAUEcjs.Comments.configure(options.comments) : _chunkBWJBZAUEcjs.Comments
6404
6404
  );
6405
6405
  }
6406
6406
  if (options.trackChanges) {
@@ -6450,8 +6450,8 @@ function createRichTextPreset(options = {}) {
6450
6450
  }
6451
6451
  if (options.chart) {
6452
6452
  const { sparkline = true, ...chartOptions } = optionObject(options.chart);
6453
- extensions2.push(_chunkDGITFN73cjs.Chart.configure(chartOptions));
6454
- if (sparkline) extensions2.push(_chunkDGITFN73cjs.Sparkline.configure(optionObject(sparkline)));
6453
+ extensions2.push(_chunkBWJBZAUEcjs.Chart.configure(chartOptions));
6454
+ if (sparkline) extensions2.push(_chunkBWJBZAUEcjs.Sparkline.configure(optionObject(sparkline)));
6455
6455
  }
6456
6456
  if (options.paragraphStyles) {
6457
6457
  extensions2.push(ParagraphStyles.configure(optionObject(options.paragraphStyles)));
@@ -6592,7 +6592,7 @@ function createFindReplaceCommands(editor, options = {}) {
6592
6592
  ];
6593
6593
  }
6594
6594
  function validateFindPattern(query, options = {}) {
6595
- const result = _chunkDGITFN73cjs.compileFindPattern.call(void 0, query, options);
6595
+ const result = _chunkBWJBZAUEcjs.compileFindPattern.call(void 0, query, options);
6596
6596
  return result.ok ? null : result.error;
6597
6597
  }
6598
6598
 
@@ -6601,8 +6601,8 @@ var PARAMS = {
6601
6601
  insertTable: {
6602
6602
  type: "object",
6603
6603
  properties: {
6604
- rows: { type: "integer", minimum: 1, maximum: _chunkDGITFN73cjs.MAX_TABLE_ROWS, description: "Rows (default 3)." },
6605
- cols: { type: "integer", minimum: 1, maximum: _chunkDGITFN73cjs.MAX_TABLE_COLUMNS, description: "Columns (default 3)." },
6604
+ rows: { type: "integer", minimum: 1, maximum: _chunkBWJBZAUEcjs.MAX_TABLE_ROWS, description: "Rows (default 3)." },
6605
+ cols: { type: "integer", minimum: 1, maximum: _chunkBWJBZAUEcjs.MAX_TABLE_COLUMNS, description: "Columns (default 3)." },
6606
6606
  withHeaderRow: { type: "boolean", description: "Make the first row a header row (default true)." }
6607
6607
  },
6608
6608
  additionalProperties: false
@@ -6633,7 +6633,7 @@ function createTableCommands(editor, options = {}) {
6633
6633
  const group = _nullishCoalesce(options.group, () => ( "Table"));
6634
6634
  const scope = options.scope ? { scope: options.scope } : {};
6635
6635
  const focus = _nullishCoalesce(options.focus, () => ( true));
6636
- return _chunkDGITFN73cjs.TABLE_ACTIONS.map(({ action, label, description, keywords }) => {
6636
+ return _chunkBWJBZAUEcjs.TABLE_ACTIONS.map(({ action, label, description, keywords }) => {
6637
6637
  const params = PARAMS[action];
6638
6638
  return {
6639
6639
  id: `${prefix}${action}`,
@@ -6643,13 +6643,13 @@ function createTableCommands(editor, options = {}) {
6643
6643
  description,
6644
6644
  ...params ? { params } : {},
6645
6645
  ...scope,
6646
- enabled: (_ctx, p) => _chunkDGITFN73cjs.getTableActionState.call(void 0, editor, action, _nullishCoalesce(p, () => ( {}))),
6646
+ enabled: (_ctx, p) => _chunkBWJBZAUEcjs.getTableActionState.call(void 0, editor, action, _nullishCoalesce(p, () => ( {}))),
6647
6647
  run: (_ctx, p) => {
6648
- if (!_chunkDGITFN73cjs.runTableAction.call(void 0, editor, action, _nullishCoalesce(p, () => ( {})), { focus })) {
6649
- const reason = _chunkDGITFN73cjs.getTableActionState.call(void 0, editor, action, _nullishCoalesce(p, () => ( {})));
6648
+ if (!_chunkBWJBZAUEcjs.runTableAction.call(void 0, editor, action, _nullishCoalesce(p, () => ( {})), { focus })) {
6649
+ const reason = _chunkBWJBZAUEcjs.getTableActionState.call(void 0, editor, action, _nullishCoalesce(p, () => ( {})));
6650
6650
  throw new Error(reason === true ? `${label} did not change the document.` : reason);
6651
6651
  }
6652
- const state = _chunkDGITFN73cjs.getTableState.call(void 0, editor);
6652
+ const state = _chunkBWJBZAUEcjs.getTableState.call(void 0, editor);
6653
6653
  return {
6654
6654
  done: true,
6655
6655
  table: state.inTable ? { rows: state.rows, columns: state.columns, row: state.row, column: state.column } : null