@univerjs/docs 0.1.13 → 0.1.14

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/lib/es/index.js CHANGED
@@ -1,13 +1,13 @@
1
- var Tt = Object.defineProperty;
2
- var Et = (s, e, t) => e in s ? Tt(s, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : s[e] = t;
3
- var y = (s, e, t) => (Et(s, typeof e != "symbol" ? e + "" : e, t), t);
4
- import { UniverInstanceType as Z, CommandType as I, RxDisposable as fe, ICommandService as v, TextXActionType as x, DOCS_NORMAL_EDITOR_UNIT_ID_KEY as mt, IUniverInstanceService as E, IUndoRedoService as Ee, UndoCommandId as Ze, RedoCommandId as Je, JSONX as b, TextX as F, DataStreamTreeTokenType as ye, Tools as ee, LocaleService as Dt, MemoryCursor as re, getDocsUpdateBody as At, UpdateDocsAttributeType as De, DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY as Nt, BooleanNumber as j, BaselineOffset as G, PRESET_LIST_TYPE as Pt, PresetListType as ft, HorizontalAlign as ie, OnLifecycle as Ae, LifecycleStages as Ne, Disposable as Pe, Direction as P, Plugin as bt } from "@univerjs/core";
5
- import { NORMAL_TEXT_SELECTION_PLUGIN_STYLE as Ut, ITextSelectionRenderManager as he, DocumentViewModel as wt, DocumentSkeleton as Lt, hasListGlyph as Bt, isIndentByGlyph as Ft, isFirstGlyph as $t, getParagraphByGlyph as Vt, getCharSpaceApply as kt, getNumberUnitValue as Ce, RANGE_DIRECTION as Ke, NodePositionConvertToCursor as qe, IRenderManagerService as ht, TextSelectionRenderManager as zt } from "@univerjs/engine-render";
1
+ var Ot = Object.defineProperty;
2
+ var Tt = (s, e, t) => e in s ? Ot(s, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : s[e] = t;
3
+ var y = (s, e, t) => (Tt(s, typeof e != "symbol" ? e + "" : e, t), t);
4
+ import { UniverInstanceType as Z, CommandType as I, RxDisposable as fe, ICommandService as v, TextXActionType as x, DOCS_NORMAL_EDITOR_UNIT_ID_KEY as Et, IUniverInstanceService as E, IUndoRedoService as Ee, UndoCommandId as Ze, RedoCommandId as Je, JSONX as b, TextX as F, DataStreamTreeTokenType as ye, Tools as ee, LocaleService as Dt, MemoryCursor as re, getDocsUpdateBody as At, UpdateDocsAttributeType as De, BooleanNumber as j, BaselineOffset as G, PRESET_LIST_TYPE as Nt, PresetListType as mt, HorizontalAlign as ie, OnLifecycle as Ae, LifecycleStages as Ne, Disposable as Pe, Direction as P, Plugin as Pt } from "@univerjs/core";
5
+ import { NORMAL_TEXT_SELECTION_PLUGIN_STYLE as bt, ITextSelectionRenderManager as pe, DocumentViewModel as Ut, DocumentSkeleton as wt, hasListGlyph as Lt, isIndentByGlyph as Bt, isFirstGlyph as Ft, getParagraphByGlyph as $t, getCharSpaceApply as Vt, getNumberUnitValue as Ce, RANGE_DIRECTION as Ke, NodePositionConvertToCursor as qe, IRenderManagerService as ft, TextSelectionRenderManager as kt } from "@univerjs/engine-render";
6
6
  import { BehaviorSubject as te, takeUntil as ne } from "rxjs";
7
- import { Inject as k, Injector as jt } from "@wendellhu/redi";
8
- var be = /* @__PURE__ */ ((s) => (s.MAIN = "__Document_Render_Main__", s.BACKGROUND = "__Document_Render_Background__", s))(be || {}), Gt = /* @__PURE__ */ ((s) => (s.VIEW_MAIN = "viewMain", s.VIEW_TOP = "viewTop", s.VIEW_LEFT = "viewLeft", s.VIEW_LEFT_TOP = "viewLeftTop", s))(Gt || {});
7
+ import { Inject as k, Injector as zt } from "@wendellhu/redi";
8
+ var be = /* @__PURE__ */ ((s) => (s.MAIN = "__Document_Render_Main__", s.BACKGROUND = "__Document_Render_Background__", s))(be || {}), jt = /* @__PURE__ */ ((s) => (s.VIEW_MAIN = "viewMain", s.VIEW_TOP = "viewTop", s.VIEW_LEFT = "viewLeft", s.VIEW_LEFT_TOP = "viewLeftTop", s))(jt || {});
9
9
  const Xn = 0, Hn = 2, Yn = 4, Wn = 10, Zn = "normalTextSelectionPluginName";
10
- function Xt(s, e) {
10
+ function Gt(s, e) {
11
11
  const t = s.getCurrentUnitForType(Z.UNIVER_DOC);
12
12
  if (!t)
13
13
  return null;
@@ -39,10 +39,10 @@ const pt = {
39
39
  type: I.OPERATION,
40
40
  handler: (s, e) => !0
41
41
  };
42
- var Ht = Object.defineProperty, Yt = Object.getOwnPropertyDescriptor, Wt = (s, e, t, n) => {
43
- for (var o = n > 1 ? void 0 : n ? Yt(e, t) : e, r = s.length - 1, i; r >= 0; r--)
42
+ var Xt = Object.defineProperty, Ht = Object.getOwnPropertyDescriptor, Yt = (s, e, t, n) => {
43
+ for (var o = n > 1 ? void 0 : n ? Ht(e, t) : e, r = s.length - 1, i; r >= 0; r--)
44
44
  (i = s[r]) && (o = (n ? i(e, t, o) : i(o)) || o);
45
- return n && o && Ht(e, t, o), o;
45
+ return n && o && Xt(e, t, o), o;
46
46
  }, Qe = (s, e) => (t, n) => e(t, n, s);
47
47
  function J(s) {
48
48
  const { startOffset: e, endOffset: t, collapsed: n } = s, o = {
@@ -118,7 +118,7 @@ let T = class extends fe {
118
118
  textRanges: e,
119
119
  segmentId: "",
120
120
  isEditing: t,
121
- style: Ut
121
+ style: bt
122
122
  // mock style.
123
123
  });
124
124
  }
@@ -171,8 +171,8 @@ let T = class extends fe {
171
171
  c.has(n) ? c.get(n).textRanges.push(...o) : c.set(n, { textRanges: o, style: r, segmentId: i, isEditing: a });
172
172
  }
173
173
  };
174
- T = Wt([
175
- Qe(0, he),
174
+ T = Yt([
175
+ Qe(0, pe),
176
176
  Qe(1, v)
177
177
  ], T);
178
178
  function Ue(s, e = "", t = 0) {
@@ -188,11 +188,11 @@ function Ue(s, e = "", t = 0) {
188
188
  segmentId: e
189
189
  }), r;
190
190
  }
191
- var Zt = Object.defineProperty, Jt = Object.getOwnPropertyDescriptor, Kt = (s, e, t, n) => {
192
- for (var o = n > 1 ? void 0 : n ? Jt(e, t) : e, r = s.length - 1, i; r >= 0; r--)
191
+ var Wt = Object.defineProperty, Zt = Object.getOwnPropertyDescriptor, Jt = (s, e, t, n) => {
192
+ for (var o = n > 1 ? void 0 : n ? Zt(e, t) : e, r = s.length - 1, i; r >= 0; r--)
193
193
  (i = s[r]) && (o = (n ? i(e, t, o) : i(o)) || o);
194
- return n && o && Zt(e, t, o), o;
195
- }, qt = (s, e) => (t, n) => e(t, n, s);
194
+ return n && o && Wt(e, t, o), o;
195
+ }, Kt = (s, e) => (t, n) => e(t, n, s);
196
196
  let se = class extends fe {
197
197
  constructor(e) {
198
198
  super();
@@ -242,7 +242,7 @@ let se = class extends fe {
242
242
  docViewModel: o
243
243
  });
244
244
  }
245
- if (e === mt) {
245
+ if (e === Et) {
246
246
  const o = (n = this._docViewModelMap.get(e)) == null ? void 0 : n.docViewModel;
247
247
  if (o == null)
248
248
  return;
@@ -252,18 +252,18 @@ let se = class extends fe {
252
252
  }
253
253
  }
254
254
  _buildDocViewModel(e) {
255
- return new wt(e);
255
+ return new Ut(e);
256
256
  }
257
257
  };
258
- se = Kt([
259
- qt(0, E)
258
+ se = Jt([
259
+ Kt(0, E)
260
260
  ], se);
261
- var Qt = Object.defineProperty, en = Object.getOwnPropertyDescriptor, tn = (s, e, t, n) => {
262
- for (var o = n > 1 ? void 0 : n ? en(e, t) : e, r = s.length - 1, i; r >= 0; r--)
261
+ var qt = Object.defineProperty, Qt = Object.getOwnPropertyDescriptor, en = (s, e, t, n) => {
262
+ for (var o = n > 1 ? void 0 : n ? Qt(e, t) : e, r = s.length - 1, i; r >= 0; r--)
263
263
  (i = s[r]) && (o = (n ? i(e, t, o) : i(o)) || o);
264
- return n && o && Qt(e, t, o), o;
264
+ return n && o && qt(e, t, o), o;
265
265
  }, Re = (s, e) => (t, n) => e(t, n, s);
266
- const nn = 300;
266
+ const tn = 300;
267
267
  let me = class extends fe {
268
268
  constructor(e, t, n) {
269
269
  super();
@@ -300,7 +300,7 @@ let me = class extends fe {
300
300
  this._stateCache.set(n, [e]);
301
301
  t === Se.id || t === _e.id ? (this._timer && clearTimeout(this._timer), this._timer = setTimeout(() => {
302
302
  this._pushHistory(n);
303
- }, nn)) : this._pushHistory(n);
303
+ }, tn)) : this._pushHistory(n);
304
304
  }
305
305
  }
306
306
  _pushHistory(e) {
@@ -324,12 +324,12 @@ let me = class extends fe {
324
324
  }), n.length = 0;
325
325
  }
326
326
  };
327
- me = tn([
327
+ me = en([
328
328
  Re(0, k(Ee)),
329
329
  Re(1, v),
330
330
  Re(2, E)
331
331
  ], me);
332
- class pe {
332
+ class he {
333
333
  constructor() {
334
334
  y(this, "_previousActiveRange", null);
335
335
  y(this, "_undoMutationParamsCache", []);
@@ -392,7 +392,7 @@ const et = "doc.mutation.rich-text-editing", B = {
392
392
  noHistory: c,
393
393
  isCompositionEnd: d,
394
394
  noNeedSetTextRange: l
395
- } = e, g = s.get(E).getUniverDocInstance(t), S = s.get(se).getViewModel(t), f = s.get(T), _ = ((L = f.getSelections()) != null ? L : []).map(J), p = s.get(me), R = s.get(pe);
395
+ } = e, g = s.get(E).getUniverDocInstance(t), S = s.get(se).getViewModel(t), f = s.get(T), _ = ((L = f.getSelections()) != null ? L : []).map(J), h = s.get(me), R = s.get(he);
396
396
  if (g == null || S == null)
397
397
  throw new Error(`DocumentDataModel or documentViewModel not found for unitId: ${t}`);
398
398
  const C = !!g.getSnapshot().disabled;
@@ -430,14 +430,14 @@ const et = "doc.mutation.rich-text-editing", B = {
430
430
  const { undoMutationParams: U, redoMutationParams: w, previousActiveRange: Y } = O;
431
431
  N.redoState.actions = w.actions, N.undoState.actions = U.actions, N.undoState.textRanges = [Y];
432
432
  }
433
- return p.setChangeState(N), {
433
+ return h.setChangeState(N), {
434
434
  unitId: t,
435
435
  actions: M,
436
436
  textRanges: _
437
437
  };
438
438
  }
439
- }, Se = {
440
- id: "doc.command.insert-text",
439
+ }, nn = "doc.command.insert-text", Se = {
440
+ id: nn,
441
441
  type: I.COMMAND,
442
442
  handler: async (s, e) => {
443
443
  const t = s.get(v), { range: n, segmentId: o, body: r, unitId: i, textRanges: a } = e, { startOffset: c, collapsed: d } = n, l = {
@@ -485,7 +485,7 @@ const _e = {
485
485
  segmentId: o
486
486
  }), l.params.actions = g.editOp(u.serialize()), !!t.syncExecuteCommand(l.id, l.params);
487
487
  }
488
- }, St = {
488
+ }, ht = {
489
489
  id: "doc.command.update-text",
490
490
  type: I.COMMAND,
491
491
  handler: async (s, e) => {
@@ -538,7 +538,7 @@ const on = {
538
538
  endOffset: a + 1,
539
539
  style: d
540
540
  }
541
- ], g = ((f = (S = r.getBody()) == null ? void 0 : S.paragraphs) != null ? f : []).find((h) => h.startIndex >= a);
541
+ ], g = ((f = (S = r.getBody()) == null ? void 0 : S.paragraphs) != null ? f : []).find((p) => p.startIndex >= a);
542
542
  return await n.executeCommand(Se.id, {
543
543
  unitId: i,
544
544
  body: {
@@ -590,9 +590,6 @@ let H = class extends fe {
590
590
  getAllSkeleton() {
591
591
  return this._docSkeletonMap;
592
592
  }
593
- makeDirtyCurrent(e = !0) {
594
- this.makeDirty(this._currentSkeletonUnitId, e);
595
- }
596
593
  makeDirty(e, t = !0) {
597
594
  const n = this.getSkeletonByUnitId(e);
598
595
  n != null && (n.dirty = t);
@@ -616,7 +613,7 @@ let H = class extends fe {
616
613
  return this._currentSkeletonUnitId = t, this._currentSkeletonBefore$.next(this.getCurrent()), this._currentSkeleton$.next(this.getCurrent()), this.getCurrent();
617
614
  }
618
615
  _buildSkeleton(e) {
619
- return Lt.create(e, this._localeService);
616
+ return wt.create(e, this._localeService);
620
617
  }
621
618
  };
622
619
  H = cn([
@@ -644,31 +641,31 @@ const Kn = {
644
641
  }, g = new re();
645
642
  g.reset();
646
643
  const m = new F(), S = b.getInstance();
647
- for (const h of c) {
648
- const { startOffset: _, endOffset: p, collapsed: R } = h, C = _ - g.cursor;
644
+ for (const p of c) {
645
+ const { startOffset: _, endOffset: h, collapsed: R } = p, C = _ - g.cursor;
649
646
  R ? m.push({
650
647
  t: x.RETAIN,
651
648
  len: C,
652
649
  segmentId: t
653
- }) : m.push(...Ue(h, t, g.cursor)), m.push({
650
+ }) : m.push(...Ue(p, t, g.cursor)), m.push({
654
651
  t: x.INSERT,
655
652
  body: n,
656
653
  len: n.dataStream.length,
657
654
  line: 0,
658
655
  segmentId: t
659
- }), g.reset(), g.moveCursor(p);
656
+ }), g.reset(), g.moveCursor(h);
660
657
  }
661
658
  return u.params.actions = S.editOp(m.serialize()), !!r.syncExecuteCommand(u.id, u.params);
662
659
  }
663
- }, _t = {
660
+ }, St = {
664
661
  id: "doc.command.inner-cut",
665
662
  type: I.COMMAND,
666
663
  handler: async (s, e) => {
667
- var h;
664
+ var p;
668
665
  const { segmentId: t, textRanges: n } = e, o = s.get(v), r = s.get(T), i = s.get(E), a = r.getSelections();
669
666
  if (!Array.isArray(a) || a.length === 0)
670
667
  return !1;
671
- const c = (h = i.getCurrentUniverDocInstance()) == null ? void 0 : h.getUnitId();
668
+ const c = (p = i.getCurrentUniverDocInstance()) == null ? void 0 : p.getUnitId();
672
669
  if (!c)
673
670
  return !1;
674
671
  const d = i.getUniverDocInstance(c), l = At(d.getSnapshot(), t);
@@ -685,7 +682,7 @@ const Kn = {
685
682
  g.reset();
686
683
  const m = new F(), S = b.getInstance();
687
684
  for (const _ of a) {
688
- const { startOffset: p, endOffset: R, collapsed: C } = _, M = p - g.cursor;
685
+ const { startOffset: h, endOffset: R, collapsed: C } = _, M = h - g.cursor;
689
686
  C ? m.push({
690
687
  t: x.RETAIN,
691
688
  len: M,
@@ -742,11 +739,11 @@ const dn = {
742
739
  const d = n.getCurrentUniverDocInstance();
743
740
  if (!d)
744
741
  return !1;
745
- const { startOffset: l, collapsed: u, segmentId: g, style: m } = r, S = a.findNodeByCharIndex(l), f = Bt(S), h = Ft(S, d.getBody());
742
+ const { startOffset: l, collapsed: u, segmentId: g, style: m } = r, S = a.findNodeByCharIndex(l), f = Lt(S), p = Bt(S, d.getBody());
746
743
  let _ = l;
747
- const p = a.findNodeByCharIndex(l - 1);
748
- if ($t(S) && p !== S && (f === !0 || h === !0) && u) {
749
- const M = Vt(S, d.getBody());
744
+ const h = a.findNodeByCharIndex(l - 1);
745
+ if (Ft(S) && h !== S && (f === !0 || p === !0) && u) {
746
+ const M = $t(S, d.getBody());
750
747
  if (M == null)
751
748
  return !1;
752
749
  const A = M == null ? void 0 : M.startIndex, D = { startIndex: 0 }, N = M.paragraphStyle;
@@ -757,7 +754,7 @@ const dn = {
757
754
  const { hanging: U } = O;
758
755
  U && (D.paragraphStyle.indentStart = U, D.paragraphStyle.hanging = void 0);
759
756
  }
760
- } else if (h === !0) {
757
+ } else if (p === !0) {
761
758
  const O = M.bullet;
762
759
  O && (D.bullet = O), N != null && (D.paragraphStyle = { ...N }, delete D.paragraphStyle.hanging, delete D.paragraphStyle.indentStart);
763
760
  }
@@ -768,7 +765,7 @@ const dn = {
768
765
  style: m
769
766
  }
770
767
  ];
771
- c = await o.executeCommand(St.id, {
768
+ c = await o.executeCommand(ht.id, {
772
769
  unitId: d.getUnitId(),
773
770
  updateBody: {
774
771
  dataStream: "",
@@ -783,15 +780,15 @@ const dn = {
783
780
  segmentId: g
784
781
  });
785
782
  } else if (u === !0) {
786
- if (p == null)
783
+ if (h == null)
787
784
  return !0;
788
- if (p.content === "\r")
785
+ if (h.content === "\r")
789
786
  c = await o.executeCommand(we.id, {
790
787
  direction: X.LEFT,
791
788
  range: r
792
789
  });
793
790
  else {
794
- _ -= p.count;
791
+ _ -= h.count;
795
792
  const M = [
796
793
  {
797
794
  startOffset: _,
@@ -804,13 +801,13 @@ const dn = {
804
801
  range: r,
805
802
  segmentId: g,
806
803
  direction: X.LEFT,
807
- len: p.count,
804
+ len: h.count,
808
805
  textRanges: M
809
806
  });
810
807
  }
811
808
  } else {
812
- const M = It(r, i);
813
- c = await o.executeCommand(_t.id, {
809
+ const M = _t(r, i);
810
+ c = await o.executeCommand(St.id, {
814
811
  segmentId: g,
815
812
  textRanges: M
816
813
  });
@@ -840,7 +837,7 @@ const dn = {
840
837
  range: r
841
838
  });
842
839
  else {
843
- const h = [
840
+ const p = [
844
841
  {
845
842
  startOffset: l,
846
843
  endOffset: l,
@@ -852,13 +849,13 @@ const dn = {
852
849
  range: r,
853
850
  segmentId: g,
854
851
  direction: X.RIGHT,
855
- textRanges: h,
852
+ textRanges: p,
856
853
  len: f.count
857
854
  });
858
855
  }
859
856
  } else {
860
- const f = It(r, i);
861
- c = await o.executeCommand(_t.id, {
857
+ const f = _t(r, i);
858
+ c = await o.executeCommand(St.id, {
862
859
  segmentId: g,
863
860
  textRanges: f
864
861
  });
@@ -880,7 +877,7 @@ const dn = {
880
877
  const { startOffset: l, collapsed: u, segmentId: g, style: m } = a;
881
878
  if (!u)
882
879
  return !1;
883
- const S = r === X.LEFT ? l : l + 1, f = (O = (L = (N = d.getBody()) == null ? void 0 : N.paragraphs) == null ? void 0 : L.find((U) => U.startIndex >= S)) == null ? void 0 : O.startIndex, h = gn(d.getBody(), S, f), _ = r === X.LEFT ? l - 1 : l, p = d.getUnitId(), R = [
880
+ const S = r === X.LEFT ? l : l + 1, f = (O = (L = (N = d.getBody()) == null ? void 0 : N.paragraphs) == null ? void 0 : L.find((U) => U.startIndex >= S)) == null ? void 0 : O.startIndex, p = gn(d.getBody(), S, f), _ = r === X.LEFT ? l - 1 : l, h = d.getUnitId(), R = [
884
881
  {
885
882
  startOffset: _,
886
883
  endOffset: _,
@@ -889,7 +886,7 @@ const dn = {
889
886
  ], C = {
890
887
  id: B.id,
891
888
  params: {
892
- unitId: p,
889
+ unitId: h,
893
890
  actions: [],
894
891
  textRanges: R,
895
892
  prevTextRanges: [i]
@@ -899,10 +896,10 @@ const dn = {
899
896
  t: x.RETAIN,
900
897
  len: r === X.LEFT ? l - 1 : l,
901
898
  segmentId: g
902
- }), h.dataStream.length && M.push({
899
+ }), p.dataStream.length && M.push({
903
900
  t: x.INSERT,
904
- body: h,
905
- len: h.dataStream.length,
901
+ body: p,
902
+ len: p.dataStream.length,
906
903
  line: 0,
907
904
  segmentId: g
908
905
  }), M.push({
@@ -945,7 +942,7 @@ function gn(s, e, t) {
945
942
  textRuns: r
946
943
  };
947
944
  }
948
- function It(s, e) {
945
+ function _t(s, e) {
949
946
  let t = s.endOffset;
950
947
  for (const o of e) {
951
948
  const { startOffset: r, endOffset: i } = o;
@@ -959,11 +956,11 @@ function It(s, e) {
959
956
  }
960
957
  ];
961
958
  }
962
- const vt = {
959
+ const It = {
963
960
  id: "doc.command.ime-input",
964
961
  type: I.COMMAND,
965
962
  handler: async (s, e) => {
966
- const { unitId: t, newText: n, oldTextLen: o, isCompositionEnd: r, isCompositionStart: i } = e, a = s.get(v), c = s.get(pe), d = c.getActiveRange();
963
+ const { unitId: t, newText: n, oldTextLen: o, isCompositionEnd: r, isCompositionStart: i } = e, a = s.get(v), c = s.get(he), d = c.getActiveRange();
967
964
  if (d == null)
968
965
  return !1;
969
966
  const { startOffset: l, style: u, segmentId: g } = d, m = n.length, S = [
@@ -980,17 +977,17 @@ const vt = {
980
977
  actions: [],
981
978
  textRanges: S
982
979
  }
983
- }, h = new F(), _ = b.getInstance();
984
- !d.collapsed && i ? h.push(...Ue(d, g)) : h.push({
980
+ }, p = new F(), _ = b.getInstance();
981
+ !d.collapsed && i ? p.push(...Ue(d, g)) : p.push({
985
982
  t: x.RETAIN,
986
983
  len: l,
987
984
  segmentId: g
988
- }), o > 0 && h.push({
985
+ }), o > 0 && p.push({
989
986
  t: x.DELETE,
990
987
  len: o,
991
988
  line: 0,
992
989
  segmentId: g
993
- }), h.push({
990
+ }), p.push({
994
991
  t: x.INSERT,
995
992
  body: {
996
993
  dataStream: n
@@ -998,15 +995,15 @@ const vt = {
998
995
  len: n.length,
999
996
  line: 0,
1000
997
  segmentId: g
1001
- }), f.params.actions = _.editOp(h.serialize()), f.params.noHistory = !r, f.params.isCompositionEnd = r;
1002
- const p = a.syncExecuteCommand(f.id, f.params);
1003
- return c.pushUndoRedoMutationParams(p, f.params), !!p;
998
+ }), f.params.actions = _.editOp(p.serialize()), f.params.noHistory = !r, f.params.isCompositionEnd = r;
999
+ const h = a.syncExecuteCommand(f.id, f.params);
1000
+ return c.pushUndoRedoMutationParams(h, f.params), !!h;
1004
1001
  }
1005
1002
  };
1006
1003
  function $(s, e, t, n) {
1007
1004
  var r;
1008
1005
  const { segmentId: o } = (r = t.getActiveRange()) != null ? r : {};
1009
- return o == null ? !1 : n.executeCommand(Ct.id, {
1006
+ return o == null ? !1 : n.executeCommand(Mt.id, {
1010
1007
  segmentId: o,
1011
1008
  preCommandId: s,
1012
1009
  ...e != null ? e : {}
@@ -1144,7 +1141,7 @@ const tt = "doc.command.set-inline-format-bold", Le = {
1144
1141
  t
1145
1142
  );
1146
1143
  }
1147
- }, Mt = {
1144
+ }, vt = {
1148
1145
  [Le.id]: "bl",
1149
1146
  [Be.id]: "it",
1150
1147
  [Fe.id]: "ul",
@@ -1156,7 +1153,7 @@ const tt = "doc.command.set-inline-format-bold", Le = {
1156
1153
  [Xe.id]: "bg",
1157
1154
  [oe.id]: "va",
1158
1155
  [Ve.id]: "va"
1159
- }, Ct = {
1156
+ }, Mt = {
1160
1157
  id: "doc.command.set-inline-format",
1161
1158
  type: I.COMMAND,
1162
1159
  // eslint-disable-next-line max-lines-per-function
@@ -1164,11 +1161,10 @@ const tt = "doc.command.set-inline-format-bold", Le = {
1164
1161
  const { segmentId: t, value: n, preCommandId: o } = e, r = s.get(v), i = s.get(T), a = s.get(E), c = i.getSelections();
1165
1162
  if (!Array.isArray(c) || c.length === 0)
1166
1163
  return !1;
1167
- let d = a.getCurrentUniverDocInstance();
1164
+ const d = a.getCurrentUniverDocInstance();
1168
1165
  if (!d)
1169
1166
  return !1;
1170
- let l = d.getUnitId();
1171
- l === Nt && (d = a.getUniverDocInstance(mt), l = d.getUnitId());
1167
+ const l = d.getUnitId();
1172
1168
  let u;
1173
1169
  switch (o) {
1174
1170
  case Le.id:
@@ -1215,18 +1211,18 @@ const tt = "doc.command.set-inline-format-bold", Le = {
1215
1211
  }, m = new F(), S = b.getInstance(), f = new re();
1216
1212
  f.reset();
1217
1213
  for (const _ of c) {
1218
- const { startOffset: p, endOffset: R } = _, C = {
1214
+ const { startOffset: h, endOffset: R } = _, C = {
1219
1215
  dataStream: "",
1220
1216
  textRuns: [
1221
1217
  {
1222
1218
  st: 0,
1223
- ed: R - p,
1219
+ ed: R - h,
1224
1220
  ts: {
1225
- [Mt[o]]: u
1221
+ [vt[o]]: u
1226
1222
  }
1227
1223
  }
1228
1224
  ]
1229
- }, M = p - f.cursor;
1225
+ }, M = h - f.cursor;
1230
1226
  M !== 0 && m.push({
1231
1227
  t: x.RETAIN,
1232
1228
  len: M,
@@ -1234,7 +1230,7 @@ const tt = "doc.command.set-inline-format-bold", Le = {
1234
1230
  }), m.push({
1235
1231
  t: x.RETAIN,
1236
1232
  body: C,
1237
- len: R - p,
1233
+ len: R - h,
1238
1234
  segmentId: t
1239
1235
  }), f.reset(), f.moveCursor(R);
1240
1236
  }
@@ -1246,7 +1242,7 @@ function mn(s) {
1246
1242
  }
1247
1243
  function fn(s, e, t) {
1248
1244
  let n = 0, o = 0;
1249
- const r = Mt[e];
1245
+ const r = vt[e];
1250
1246
  for (; n !== s.length && o !== t.length; ) {
1251
1247
  const { startOffset: i, endOffset: a } = t[o], { st: c, ed: d, ts: l } = s[n];
1252
1248
  if (a <= c)
@@ -1283,14 +1279,14 @@ const He = {
1283
1279
  const a = t.getActiveRange(), c = (U = t.getSelections()) != null ? U : [], d = (w = i.getBody()) == null ? void 0 : w.paragraphs, l = c.map(J);
1284
1280
  if (a == null || d == null)
1285
1281
  return !1;
1286
- const u = Rt(a, d), { segmentId: g } = a, m = i.getUnitId(), S = u.every((W) => {
1282
+ const u = Ct(a, d), { segmentId: g } = a, m = i.getUnitId(), S = u.every((W) => {
1287
1283
  var V;
1288
1284
  return ((V = W.bullet) == null ? void 0 : V.listType) === r;
1289
1285
  });
1290
- let h = ee.generateRandomId(6);
1286
+ let p = ee.generateRandomId(6);
1291
1287
  if (u.length === 1) {
1292
1288
  const W = d.indexOf(u[0]), V = d[W - 1], z = d[W + 1];
1293
- V && V.bullet && V.bullet.listType === r ? h = V.bullet.listId : z && z.bullet && z.bullet.listType === r && (h = z.bullet.listId);
1289
+ V && V.bullet && V.bullet.listType === r ? p = V.bullet.listId : z && z.bullet && z.bullet.listType === r && (p = z.bullet.listId);
1294
1290
  }
1295
1291
  const _ = {
1296
1292
  id: B.id,
@@ -1299,17 +1295,17 @@ const He = {
1299
1295
  actions: [],
1300
1296
  textRanges: l
1301
1297
  }
1302
- }, p = new re();
1303
- p.reset();
1298
+ }, h = new re();
1299
+ h.reset();
1304
1300
  const R = new F(), C = b.getInstance(), M = (Y = i.getSnapshot().lists) != null ? Y : {}, A = {
1305
- ...Pt,
1301
+ ...Nt,
1306
1302
  ...M
1307
1303
  }, { charSpace: D, defaultTabStop: N = 36, gridType: L } = i.getSnapshot().documentStyle;
1308
1304
  for (const W of u) {
1309
- const { startIndex: V, paragraphStyle: z = {} } = W, { indentFirstLine: yt = 0, snapToGrid: Ot, indentStart: Ie = 0 } = z, { hanging: ve, indentStart: We } = A[r].nestingLevel[0], Me = kt(D, N, L, Ot);
1305
+ const { startIndex: V, paragraphStyle: z = {} } = W, { indentFirstLine: xt = 0, snapToGrid: yt, indentStart: Ie = 0 } = z, { hanging: ve, indentStart: We } = A[r].nestingLevel[0], Me = Vt(D, N, L, yt);
1310
1306
  R.push({
1311
1307
  t: x.RETAIN,
1312
- len: V - p.cursor,
1308
+ len: V - h.cursor,
1313
1309
  segmentId: g
1314
1310
  }), R.push({
1315
1311
  t: x.RETAIN,
@@ -1330,7 +1326,7 @@ const He = {
1330
1326
  ...z,
1331
1327
  indentFirstLine: void 0,
1332
1328
  hanging: ve,
1333
- indentStart: We - ve + Ce(yt, Me) + Ce(Ie, Me)
1329
+ indentStart: We - ve + Ce(xt, Me) + Ce(Ie, Me)
1334
1330
  },
1335
1331
  bullet: {
1336
1332
  ...(Ye = W.bullet) != null ? Ye : {
@@ -1340,31 +1336,31 @@ const He = {
1340
1336
  }
1341
1337
  },
1342
1338
  listType: r,
1343
- listId: h
1339
+ listId: p
1344
1340
  }
1345
1341
  }
1346
1342
  ]
1347
1343
  },
1348
1344
  segmentId: g,
1349
1345
  coverType: De.REPLACE
1350
- }), p.moveCursorTo(V + 1);
1346
+ }), h.moveCursorTo(V + 1);
1351
1347
  }
1352
1348
  return _.params.actions = C.editOp(R.serialize()), !!o.syncExecuteCommand(_.id, _.params);
1353
1349
  }
1354
- }, hn = {
1350
+ }, pn = {
1355
1351
  id: "doc.command.bullet-list",
1356
1352
  type: I.COMMAND,
1357
1353
  handler: (s) => s.get(v).syncExecuteCommand(He.id, {
1358
- listType: ft.BULLET_LIST
1354
+ listType: mt.BULLET_LIST
1359
1355
  })
1360
- }, pn = {
1356
+ }, hn = {
1361
1357
  id: "doc.command.order-list",
1362
1358
  type: I.COMMAND,
1363
1359
  handler: (s) => s.get(v).syncExecuteCommand(He.id, {
1364
- listType: ft.ORDER_LIST
1360
+ listType: mt.ORDER_LIST
1365
1361
  })
1366
1362
  };
1367
- function Rt(s, e) {
1363
+ function Ct(s, e) {
1368
1364
  const { startOffset: t, endOffset: n } = s, o = [];
1369
1365
  let r = -1;
1370
1366
  for (const i of e) {
@@ -1385,7 +1381,7 @@ const ae = {
1385
1381
  const a = t.getActiveRange(), c = (C = t.getSelections()) != null ? C : [], d = (M = i.getBody()) == null ? void 0 : M.paragraphs, l = c.map(J);
1386
1382
  if (a == null || d == null)
1387
1383
  return !1;
1388
- const u = Rt(a, d), { segmentId: g } = a, m = i.getUnitId(), S = u.every((A) => {
1384
+ const u = Ct(a, d), { segmentId: g } = a, m = i.getUnitId(), S = u.every((A) => {
1389
1385
  var D;
1390
1386
  return ((D = A.paragraphStyle) == null ? void 0 : D.horizontalAlign) === r;
1391
1387
  }), f = {
@@ -1395,14 +1391,14 @@ const ae = {
1395
1391
  actions: [],
1396
1392
  textRanges: l
1397
1393
  }
1398
- }, h = new re();
1399
- h.reset();
1400
- const _ = new F(), p = b.getInstance();
1394
+ }, p = new re();
1395
+ p.reset();
1396
+ const _ = new F(), h = b.getInstance();
1401
1397
  for (const A of u) {
1402
1398
  const { startIndex: D } = A;
1403
1399
  _.push({
1404
1400
  t: x.RETAIN,
1405
- len: D - h.cursor,
1401
+ len: D - p.cursor,
1406
1402
  segmentId: g
1407
1403
  });
1408
1404
  const N = {
@@ -1424,9 +1420,9 @@ const ae = {
1424
1420
  },
1425
1421
  segmentId: g,
1426
1422
  coverType: De.REPLACE
1427
- }), h.moveCursorTo(D + 1);
1423
+ }), p.moveCursorTo(D + 1);
1428
1424
  }
1429
- return f.params.actions = p.editOp(_.serialize()), !!o.syncExecuteCommand(f.id, f.params);
1425
+ return f.params.actions = h.editOp(_.serialize()), !!o.syncExecuteCommand(f.id, f.params);
1430
1426
  }
1431
1427
  }, Sn = {
1432
1428
  id: "doc.command.align-left",
@@ -1460,7 +1456,7 @@ const ae = {
1460
1456
  const { unitId: t, body: n, textRanges: o, segmentId: r = "" } = e, i = s.get(E), a = s.get(v), c = s.get(T), d = (m = i.getUniverDocInstance(t)) == null ? void 0 : m.getSnapshot().body, l = c.getSelections();
1461
1457
  if (d == null || !Array.isArray(l) || l.length === 0)
1462
1458
  return !1;
1463
- const u = xt(t, r, d, n);
1459
+ const u = Rt(t, r, d, n);
1464
1460
  return u.params.textRanges = o, !!a.syncExecuteCommand(u.id, u.params);
1465
1461
  }
1466
1462
  }, Cn = {
@@ -1471,14 +1467,14 @@ const ae = {
1471
1467
  const { unitId: t, body: n, segmentId: o = "" } = e, r = s.get(E), i = s.get(v), a = s.get(Ee), c = (l = r.getUniverDocInstance(t)) == null ? void 0 : l.getSnapshot().body;
1472
1468
  if (c == null)
1473
1469
  return !1;
1474
- const d = xt(t, o, c, n);
1470
+ const d = Rt(t, o, c, n);
1475
1471
  return d.params.noNeedSetTextRange = !0, d.params.noHistory = !0, i.syncExecuteCommand(
1476
1472
  d.id,
1477
1473
  d.params
1478
1474
  ), a.clearUndoRedo(t), !0;
1479
1475
  }
1480
1476
  };
1481
- function xt(s, e, t, n) {
1477
+ function Rt(s, e, t, n) {
1482
1478
  const o = {
1483
1479
  id: B.id,
1484
1480
  params: {
@@ -1620,7 +1616,7 @@ let de = class extends Pe {
1620
1616
  if (n == null || i == null)
1621
1617
  return;
1622
1618
  const c = r.data;
1623
- c === this._previousIMEContent && t || (await this._commandService.executeCommand(vt.id, {
1619
+ c === this._previousIMEContent && t || (await this._commandService.executeCommand(It.id, {
1624
1620
  unitId: o.getUnitId(),
1625
1621
  newText: c,
1626
1622
  oldTextLen: this._previousIMEContent.length,
@@ -1636,8 +1632,8 @@ de = En([
1636
1632
  Ae(Ne.Rendered, de),
1637
1633
  K(0, k(H)),
1638
1634
  K(1, E),
1639
- K(2, he),
1640
- K(3, k(pe)),
1635
+ K(2, pe),
1636
+ K(3, k(he)),
1641
1637
  K(4, v)
1642
1638
  ], de);
1643
1639
  var Dn = Object.defineProperty, An = Object.getOwnPropertyDescriptor, Nn = (s, e, t, n) => {
@@ -1674,7 +1670,7 @@ let ue = class extends Pe {
1674
1670
  );
1675
1671
  }
1676
1672
  _handleShiftMoveSelection(e) {
1677
- var f, h, _;
1673
+ var f, p, _;
1678
1674
  const t = this._textSelectionManagerService.getActiveRange(), n = this._textSelectionManagerService.getSelections(), o = this._univerInstanceService.getCurrentUniverDocInstance();
1679
1675
  if (!o)
1680
1676
  return;
@@ -1683,13 +1679,13 @@ let ue = class extends Pe {
1683
1679
  return;
1684
1680
  const { startOffset: a, endOffset: c, style: d, collapsed: l, direction: u } = t;
1685
1681
  if (n.length > 1) {
1686
- let p = Number.POSITIVE_INFINITY, R = Number.NEGATIVE_INFINITY;
1682
+ let h = Number.POSITIVE_INFINITY, R = Number.NEGATIVE_INFINITY;
1687
1683
  for (const C of n)
1688
- p = Math.min(p, C.startOffset), R = Math.max(R, C.endOffset);
1684
+ h = Math.min(h, C.startOffset), R = Math.max(R, C.endOffset);
1689
1685
  this._textSelectionManagerService.replaceTextRanges([
1690
1686
  {
1691
- startOffset: e === P.LEFT || e === P.UP ? R : p,
1692
- endOffset: e === P.LEFT || e === P.UP ? p : R,
1687
+ startOffset: e === P.LEFT || e === P.UP ? R : h,
1688
+ endOffset: e === P.LEFT || e === P.UP ? h : R,
1693
1689
  style: d
1694
1690
  }
1695
1691
  ], !1);
@@ -1697,10 +1693,10 @@ let ue = class extends Pe {
1697
1693
  }
1698
1694
  const g = l || u === Ke.FORWARD ? a : c;
1699
1695
  let m = l || u === Ke.FORWARD ? c : a;
1700
- const S = (h = o.getBody().dataStream.length) != null ? h : Number.POSITIVE_INFINITY;
1696
+ const S = (p = o.getBody().dataStream.length) != null ? p : Number.POSITIVE_INFINITY;
1701
1697
  if (e === P.LEFT || e === P.RIGHT) {
1702
- const p = r.findNodeByCharIndex(m - 1), R = r.findNodeByCharIndex(m);
1703
- m = e === P.RIGHT ? m + R.count : m - ((_ = p == null ? void 0 : p.count) != null ? _ : 0), m = Math.min(S - 2, Math.max(0, m)), this._textSelectionManagerService.replaceTextRanges([
1698
+ const h = r.findNodeByCharIndex(m - 1), R = r.findNodeByCharIndex(m);
1699
+ m = e === P.RIGHT ? m + R.count : m - ((_ = h == null ? void 0 : h.count) != null ? _ : 0), m = Math.min(S - 2, Math.max(0, m)), this._textSelectionManagerService.replaceTextRanges([
1704
1700
  {
1705
1701
  startOffset: g,
1706
1702
  endOffset: m,
@@ -1708,7 +1704,7 @@ let ue = class extends Pe {
1708
1704
  }
1709
1705
  ], !1);
1710
1706
  } else {
1711
- const p = r.findNodeByCharIndex(m), R = i.document.getOffsetConfig(), C = this._getTopOrBottomPosition(r, p, e === P.DOWN);
1707
+ const h = r.findNodeByCharIndex(m), R = i.document.getOffsetConfig(), C = this._getTopOrBottomPosition(r, h, e === P.DOWN);
1712
1708
  if (C == null) {
1713
1709
  const A = e === P.UP ? 0 : S - 2;
1714
1710
  if (A === m)
@@ -1747,13 +1743,13 @@ let ue = class extends Pe {
1747
1743
  if (e === P.LEFT || e === P.RIGHT) {
1748
1744
  let f;
1749
1745
  if (!t.collapsed || n.length > 1) {
1750
- let h = Number.POSITIVE_INFINITY, _ = Number.NEGATIVE_INFINITY;
1751
- for (const p of n)
1752
- h = Math.min(h, p.startOffset), _ = Math.max(_, p.endOffset);
1753
- f = e === P.LEFT ? h : _;
1746
+ let p = Number.POSITIVE_INFINITY, _ = Number.NEGATIVE_INFINITY;
1747
+ for (const h of n)
1748
+ p = Math.min(p, h.startOffset), _ = Math.max(_, h.endOffset);
1749
+ f = e === P.LEFT ? p : _;
1754
1750
  } else {
1755
- const h = r.findNodeByCharIndex(a - 1), _ = r.findNodeByCharIndex(a);
1756
- e === P.LEFT ? f = Math.max(0, a - ((S = h == null ? void 0 : h.count) != null ? S : 0)) : f = Math.min(u - 2, c + _.count);
1751
+ const p = r.findNodeByCharIndex(a - 1), _ = r.findNodeByCharIndex(a);
1752
+ e === P.LEFT ? f = Math.max(0, a - ((S = p == null ? void 0 : p.count) != null ? S : 0)) : f = Math.min(u - 2, c + _.count);
1757
1753
  }
1758
1754
  this._textSelectionManagerService.replaceTextRanges([
1759
1755
  {
@@ -1763,12 +1759,12 @@ let ue = class extends Pe {
1763
1759
  }
1764
1760
  ], !1);
1765
1761
  } else {
1766
- const f = r.findNodeByCharIndex(a), h = r.findNodeByCharIndex(c), _ = i.document.getOffsetConfig(), p = this._getTopOrBottomPosition(
1762
+ const f = r.findNodeByCharIndex(a), p = r.findNodeByCharIndex(c), _ = i.document.getOffsetConfig(), h = this._getTopOrBottomPosition(
1767
1763
  r,
1768
- e === P.UP ? f : h,
1764
+ e === P.UP ? f : p,
1769
1765
  e === P.DOWN
1770
1766
  );
1771
- if (p == null) {
1767
+ if (h == null) {
1772
1768
  let C;
1773
1769
  l ? C = e === P.UP ? 0 : u - 2 : C = e === P.UP ? a : c, this._textSelectionManagerService.replaceTextRanges([
1774
1770
  {
@@ -1780,8 +1776,8 @@ let ue = class extends Pe {
1780
1776
  return;
1781
1777
  }
1782
1778
  const R = new qe(_, r).getRangePointData(
1783
- p,
1784
- p
1779
+ h,
1780
+ h
1785
1781
  ).cursorList[0];
1786
1782
  this._textSelectionManagerService.replaceTextRanges([
1787
1783
  {
@@ -1823,7 +1819,7 @@ let ue = class extends Pe {
1823
1819
  return e.findPositionByGlyph(o.glyph);
1824
1820
  }
1825
1821
  _getNextOrPrevLine(e, t) {
1826
- var S, f, h, _, p, R, C, M, A, D, N, L;
1822
+ var S, f, p, _, h, R, C, M, A, D, N, L;
1827
1823
  const n = e.parent;
1828
1824
  if (n == null)
1829
1825
  return;
@@ -1848,7 +1844,7 @@ let ue = class extends Pe {
1848
1844
  if (t === !0)
1849
1845
  a = (S = c.columns[d + 1]) == null ? void 0 : S.lines[0];
1850
1846
  else {
1851
- const O = (h = (f = c.columns) == null ? void 0 : f[d - 1]) == null ? void 0 : h.lines;
1847
+ const O = (p = (f = c.columns) == null ? void 0 : f[d - 1]) == null ? void 0 : p.lines;
1852
1848
  a = O == null ? void 0 : O[O.length - 1];
1853
1849
  }
1854
1850
  if (a != null)
@@ -1860,7 +1856,7 @@ let ue = class extends Pe {
1860
1856
  if (u === -1)
1861
1857
  return;
1862
1858
  if (t === !0)
1863
- a = (p = (_ = l.sections[u - 1]) == null ? void 0 : _.columns[0]) == null ? void 0 : p.lines[0];
1859
+ a = (h = (_ = l.sections[u - 1]) == null ? void 0 : _.columns[0]) == null ? void 0 : h.lines[0];
1864
1860
  else {
1865
1861
  const O = (C = (R = l.sections) == null ? void 0 : R[u - 1]) == null ? void 0 : C.columns, U = O == null ? void 0 : O[O.length - 1], w = U == null ? void 0 : U.lines;
1866
1862
  a = w == null ? void 0 : w[w.length - 1];
@@ -1886,14 +1882,14 @@ let ue = class extends Pe {
1886
1882
  }
1887
1883
  }
1888
1884
  _getDocObject() {
1889
- return Xt(this._univerInstanceService, this._renderManagerService);
1885
+ return Gt(this._univerInstanceService, this._renderManagerService);
1890
1886
  }
1891
1887
  };
1892
1888
  ue = Nn([
1893
1889
  Ae(Ne.Rendered, ue),
1894
1890
  q(0, k(H)),
1895
1891
  q(1, E),
1896
- q(2, ht),
1892
+ q(2, ft),
1897
1893
  q(3, k(T)),
1898
1894
  q(4, v)
1899
1895
  ], ue);
@@ -1949,8 +1945,8 @@ ge = Un([
1949
1945
  Ae(Ne.Rendered, ge),
1950
1946
  Q(0, k(H)),
1951
1947
  Q(1, E),
1952
- Q(2, ht),
1953
- Q(3, he),
1948
+ Q(2, ft),
1949
+ Q(3, pe),
1954
1950
  Q(4, v)
1955
1951
  ], ge);
1956
1952
  var wn = Object.defineProperty, Ln = Object.getOwnPropertyDescriptor, Bn = (s, e, t, n) => {
@@ -1960,7 +1956,7 @@ var wn = Object.defineProperty, Ln = Object.getOwnPropertyDescriptor, Bn = (s, e
1960
1956
  }, Fn = (s, e) => (t, n) => e(t, n, s);
1961
1957
  const $n = "docs";
1962
1958
  var ce;
1963
- let gt = (ce = class extends bt {
1959
+ let gt = (ce = class extends Pt {
1964
1960
  constructor(s = {}, e) {
1965
1961
  super(), this._injector = e, this._initializeDependencies(e), this._initializeCommands();
1966
1962
  }
@@ -1981,12 +1977,12 @@ let gt = (ce = class extends bt {
1981
1977
  je,
1982
1978
  Xe,
1983
1979
  Ge,
1984
- Ct,
1980
+ Mt,
1985
1981
  on,
1986
1982
  Se,
1987
1983
  _e,
1988
- St,
1989
- vt,
1984
+ ht,
1985
+ It,
1990
1986
  we,
1991
1987
  B,
1992
1988
  Mn,
@@ -1995,8 +1991,8 @@ let gt = (ce = class extends bt {
1995
1991
  le,
1996
1992
  pt,
1997
1993
  yn,
1998
- pn,
1999
1994
  hn,
1995
+ pn,
2000
1996
  He,
2001
1997
  Sn,
2002
1998
  _n,
@@ -2013,11 +2009,11 @@ let gt = (ce = class extends bt {
2013
2009
  [H],
2014
2010
  [se],
2015
2011
  [me],
2016
- [pe],
2012
+ [he],
2017
2013
  [
2018
- he,
2014
+ pe,
2019
2015
  {
2020
- useClass: zt
2016
+ useClass: kt
2021
2017
  }
2022
2018
  ],
2023
2019
  [T],
@@ -2029,7 +2025,7 @@ let gt = (ce = class extends bt {
2029
2025
  }
2030
2026
  }, y(ce, "pluginName", $n), y(ce, "type", Z.UNIVER_DOC), ce);
2031
2027
  gt = Bn([
2032
- Fn(1, k(jt))
2028
+ Fn(1, k(zt))
2033
2029
  ], gt);
2034
2030
  export {
2035
2031
  _n as AlignCenterCommand,
@@ -2038,9 +2034,9 @@ export {
2038
2034
  ae as AlignOperationCommand,
2039
2035
  In as AlignRightCommand,
2040
2036
  on as BreakLineCommand,
2041
- hn as BulletListCommand,
2037
+ pn as BulletListCommand,
2042
2038
  Cn as CoverContentCommand,
2043
- _t as CutContentCommand,
2039
+ St as CutContentCommand,
2044
2040
  Xn as DOCS_COMPONENT_BACKGROUND_LAYER_INDEX,
2045
2041
  Wn as DOCS_COMPONENT_DEFAULT_Z_INDEX,
2046
2042
  Yn as DOCS_COMPONENT_HEADER_LAYER_INDEX,
@@ -2052,14 +2048,15 @@ export {
2052
2048
  H as DocSkeletonManagerService,
2053
2049
  me as DocStateChangeManagerService,
2054
2050
  se as DocViewModelManagerService,
2055
- vt as IMEInputCommand,
2056
- pe as IMEInputManagerService,
2051
+ nn as EditorInsertTextCommandId,
2052
+ It as IMEInputCommand,
2053
+ he as IMEInputManagerService,
2057
2054
  Kn as InnerPasteCommand,
2058
2055
  Se as InsertCommand,
2059
2056
  Oe as MoveCursorOperation,
2060
2057
  Te as MoveSelectionOperation,
2061
2058
  Zn as NORMAL_TEXT_SELECTION_PLUGIN_NAME,
2062
- pn as OrderListCommand,
2059
+ hn as OrderListCommand,
2063
2060
  Mn as ReplaceContentCommand,
2064
2061
  Xe as ResetInlineFormatTextBackgroundColorCommand,
2065
2062
  B as RichTextEditingMutation,
@@ -2067,7 +2064,7 @@ export {
2067
2064
  xn as SetDocZoomRatioCommand,
2068
2065
  le as SetDocZoomRatioOperation,
2069
2066
  Le as SetInlineFormatBoldCommand,
2070
- Ct as SetInlineFormatCommand,
2067
+ Mt as SetInlineFormatCommand,
2071
2068
  ze as SetInlineFormatFontFamilyCommand,
2072
2069
  ke as SetInlineFormatFontSizeCommand,
2073
2070
  Be as SetInlineFormatItalicCommand,
@@ -2080,9 +2077,9 @@ export {
2080
2077
  pt as SetTextSelectionsOperation,
2081
2078
  T as TextSelectionManagerService,
2082
2079
  gt as UniverDocsPlugin,
2083
- St as UpdateCommand,
2084
- Gt as VIEWPORT_KEY,
2085
- Xt as getDocObject,
2080
+ ht as UpdateCommand,
2081
+ jt as VIEWPORT_KEY,
2082
+ Gt as getDocObject,
2086
2083
  Jn as getDocObjectById,
2087
2084
  J as serializeTextRange
2088
2085
  };