@univerjs/docs-ui 0.13.0 → 0.14.0-insiders.20251222-4efcfbb

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/index.js CHANGED
@@ -1,16 +1,16 @@
1
1
  var Bc = Object.defineProperty;
2
2
  var Mc = (n, e, t) => e in n ? Bc(n, e, { enumerable: !0, configurable: !0, writable: !0, value: t }) : n[e] = t;
3
3
  var O = (n, e, t) => Mc(n, typeof e != "symbol" ? e + "" : e, t);
4
- import { IUniverInstanceService as L, Inject as j, Disposable as me, toDisposable as Mn, UniverInstanceType as _, BuildTextUtils as ce, JSONX as W, ObjectRelativeFromV as gt, ObjectRelativeFromH as Co, CommandType as D, sequenceExecuteAsync as wr, ICommandService as T, DataStreamTreeTokenType as V, TextX as Ie, TextXActionType as G, PresetListType as xe, UpdateDocsAttributeType as nn, Tools as ue, generateRandomId as ge, TableRowHeightRule as _c, TableSizeType as Yi, TableTextWrapType as Dc, TableAlignmentType as Pc, MemoryCursor as Nt, SHEET_EDITOR_UNITS as En, PositionedObjectLayoutType as Ro, BlockType as wc, LRUMap as Nc, BaselineOffset as Ve, BooleanNumber as z, ColorKit as Qs, DrawingTypeEnum as Nr, skipParseTagNames as Lc, CustomRangeType as Lr, DataStreamTreeNodeType as sn, createIdentifier as Ki, ILogService as Qr, SliceBodyType as ir, DOCS_NORMAL_EDITOR_UNIT_ID_KEY as bo, DOC_RANGE_TYPE as He, normalizeBody as Qc, getBodySlice as qi, FOCUSING_DOC as _n, EDITOR_ACTIVATED as eo, DashStyleType as Uc, RxDisposable as Ct, ThemeService as Ur, IUndoRedoService as xo, PRESET_LIST_TYPE as Fc, HorizontalAlign as Ue, NamedStyleType as K, RANGE_DIRECTION as De, COLORS as gn, Rectangle as Hc, DocumentFlavor as we, LocaleService as Ye, isInternalEditorID as Rt, IContextService as Fr, Injector as Dn, FOCUSING_EDITOR_STANDALONE as Us, FOCUSING_COMMENT_EDITOR as Fs, isCommentEditorID as kc, VerticalAlign as Vc, DEFAULT_EMPTY_DOCUMENT_VALUE as Xi, PageOrientType as Wc, PAPER_TYPES as jc, PAGE_SIZE as ar, DOCS_ZEN_EDITOR_UNIT_ID_KEY as nt, DEFAULT_STYLES as yo, NAMED_STYLE_MAP as zc, DisposableCollection as In, fromEventSubject as Mt, deepCompare as Gc, FOCUSING_UNIVER_EDITOR as Hr, FOCUSING_COMMON_DRAWINGS as Zi, getPlainText as to, debounce as kr, SpacingRule as Xt, IConfigService as Vr, QuickListTypeMap as jo, Direction as le, DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY as Yc, checkForSubstrings as Kc, createInterceptorKey as Ji, InterceptorManager as qc, UndoCommandId as Hs, RedoCommandId as ks, DependentOn as Xc, Plugin as Zc, merge as Jc, touchDependencies as Vs, mergeOverrideWithDependencies as $c, createInternalEditorID as el } from "@univerjs/core";
4
+ import { IUniverInstanceService as L, Inject as z, Disposable as me, toDisposable as Mn, UniverInstanceType as _, BuildTextUtils as ce, JSONX as W, ObjectRelativeFromV as gt, ObjectRelativeFromH as Ro, CommandType as D, sequenceExecuteAsync as wr, ICommandService as T, DataStreamTreeTokenType as V, TextX as Ie, TextXActionType as G, PresetListType as xe, UpdateDocsAttributeType as nn, Tools as ue, generateRandomId as ge, TableRowHeightRule as _c, TableSizeType as Yi, TableTextWrapType as Dc, TableAlignmentType as Pc, MemoryCursor as Nt, SHEET_EDITOR_UNITS as En, PositionedObjectLayoutType as bo, BlockType as wc, LRUMap as Nc, BaselineOffset as Ve, BooleanNumber as j, ColorKit as Qs, DrawingTypeEnum as Nr, skipParseTagNames as Lc, CustomRangeType as Lr, DataStreamTreeNodeType as sn, createIdentifier as Ki, ILogService as Qr, SliceBodyType as ar, DOCS_NORMAL_EDITOR_UNIT_ID_KEY as xo, DOC_RANGE_TYPE as He, normalizeBody as Qc, getBodySlice as qi, FOCUSING_DOC as _n, EDITOR_ACTIVATED as eo, DashStyleType as Uc, RxDisposable as Ct, ThemeService as Ur, IUndoRedoService as yo, PRESET_LIST_TYPE as Fc, HorizontalAlign as Ue, NamedStyleType as K, RANGE_DIRECTION as De, COLORS as gn, Rectangle as Hc, DocumentFlavor as we, LocaleService as Ye, IConfirmService as Xi, isInternalEditorID as Rt, IContextService as Fr, Injector as Dn, FOCUSING_EDITOR_STANDALONE as Us, FOCUSING_COMMENT_EDITOR as Fs, isCommentEditorID as kc, VerticalAlign as Vc, DEFAULT_EMPTY_DOCUMENT_VALUE as Zi, PageOrientType as Wc, PAPER_TYPES as zc, PAGE_SIZE as to, DOCS_ZEN_EDITOR_UNIT_ID_KEY as nt, DEFAULT_STYLES as Oo, NAMED_STYLE_MAP as jc, DisposableCollection as In, fromEventSubject as Mt, deepCompare as Gc, FOCUSING_UNIVER_EDITOR as Hr, FOCUSING_COMMON_DRAWINGS as Ji, getPlainText as no, debounce as kr, SpacingRule as Xt, IConfigService as Vr, QuickListTypeMap as jo, Direction as le, DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY as Yc, checkForSubstrings as Kc, createInterceptorKey as $i, InterceptorManager as qc, UndoCommandId as Hs, RedoCommandId as ks, DependentOn as Xc, Plugin as Zc, merge as Jc, touchDependencies as Vs, mergeOverrideWithDependencies as $c, createInternalEditorID as el } from "@univerjs/core";
5
5
  import { DocSelectionManagerService as Y, RichTextEditingMutation as X, DocSkeletonManagerService as de, SetTextSelectionsOperation as Le, DocStateEmitService as tl, DocInterceptorService as nl } from "@univerjs/docs";
6
- import { IRenderManagerService as pe, DocumentEditArea as ve, hasListGlyph as ol, isIndentByGlyph as rl, isFirstGlyph as sl, getParagraphByGlyph as il, pixelToPt as al, ptToPixel as Ws, parseDataStreamToTree as cl, Liquid as $i, GlyphType as ea, DocumentSkeletonPageType as Oe, getPageFromPath as cr, getTableIdAndSliceIndex as js, NORMAL_TEXT_SELECTION_PLUGIN_STYLE as Sn, getColor as fn, RegularPolygon as ta, Rect as Kn, getOffsetRectForDom as ll, ScrollTimer as dl, CURSOR_TYPE as Dt, getSystemHighlightColor as Al, Vector2 as vn, PageLayoutType as Cn, Shape as ul, Path as zs, pxToNum as na, TRANSFORM_CHANGE_OBSERVABLE_TYPE as oa, getNumberUnitValue as on, Viewport as hl, ScrollBar as lr, Layer as Gs, Documents as gl, DocBackground as fl, getLastLine as pl, lineIterator as ml, getLastColumn as El, UniverRenderEnginePlugin as Il, DeviceInputEventType as ra } from "@univerjs/engine-render";
7
- import { IClipboardInterfaceService as sa, FILE_PNG_CLIPBOARD_MIME_TYPE as Sl, FILE__WEBP_CLIPBOARD_MIME_TYPE as vl, FILE__JPEG_CLIPBOARD_MIME_TYPE as Cl, FILE__BMP_CLIPBOARD_MIME_TYPE as Rl, HTML_CLIPBOARD_MIME_TYPE as ia, PLAIN_TEXT_CLIPBOARD_MIME_TYPE as aa, CopyCommand as bl, CutCommand as xl, PasteCommand as yl, ILayoutService as Oo, KeyCode as q, IConfirmService as ca, useDependency as J, ComponentManager as rn, ISidebarService as la, getMenuHiddenObservable as se, MenuItemType as Z, COLOR_PICKER_COMPONENT as da, FONT_FAMILY_ITEM_COMPONENT as Ol, FONT_FAMILY_COMPONENT as Tl, FONT_SIZE_LIST as Bl, FONT_SIZE_COMPONENT as Ml, HEADING_LIST as Ys, COMMON_LABEL_COMPONENT as _l, HEADING_ITEM_COMPONENT as Dl, ICanvasPopupService as Pl, IMenuManagerService as Aa, ToolbarItem as wl, MenuManagerPosition as Nl, useObservable as et, RectPopup as Ll, DesktopMenu as Ql, ContextMenuPosition as no, MetaKeys as te, Slider as Ul, useConfigValue as ua, useEvent as mn, ContextMenuGroup as an, RibbonInsertGroup as Fl, RibbonStartGroup as Ks, IUIPartsService as Hl, IShortcutService as To, BuiltInUIPart as qs, connectInjector as Xs, imageMimeTypeSet as kl, IContextMenuService as Vl } from "@univerjs/ui";
6
+ import { IRenderManagerService as pe, DocumentEditArea as ve, hasListGlyph as ol, isIndentByGlyph as rl, isFirstGlyph as sl, getParagraphByGlyph as il, pixelToPt as al, ptToPixel as Ws, parseDataStreamToTree as cl, Liquid as ea, GlyphType as ta, DocumentSkeletonPageType as Oe, getPageFromPath as cr, getTableIdAndSliceIndex as zs, NORMAL_TEXT_SELECTION_PLUGIN_STYLE as Sn, getColor as fn, RegularPolygon as na, Rect as Kn, getOffsetRectForDom as ll, ScrollTimer as dl, CURSOR_TYPE as Dt, getSystemHighlightColor as Al, Vector2 as vn, PageLayoutType as Cn, Shape as ul, Path as js, pxToNum as oa, TRANSFORM_CHANGE_OBSERVABLE_TYPE as ra, getNumberUnitValue as on, Viewport as hl, ScrollBar as lr, Layer as Gs, Documents as gl, DocBackground as fl, getLastLine as pl, lineIterator as ml, getLastColumn as El, UniverRenderEnginePlugin as Il, DeviceInputEventType as sa } from "@univerjs/engine-render";
7
+ import { IClipboardInterfaceService as ia, FILE_PNG_CLIPBOARD_MIME_TYPE as Sl, FILE__WEBP_CLIPBOARD_MIME_TYPE as vl, FILE__JPEG_CLIPBOARD_MIME_TYPE as Cl, FILE__BMP_CLIPBOARD_MIME_TYPE as Rl, HTML_CLIPBOARD_MIME_TYPE as aa, PLAIN_TEXT_CLIPBOARD_MIME_TYPE as ca, CopyCommand as bl, CutCommand as xl, PasteCommand as yl, ILayoutService as To, KeyCode as q, useDependency as J, ComponentManager as rn, ISidebarService as la, getMenuHiddenObservable as se, MenuItemType as Z, COLOR_PICKER_COMPONENT as da, FONT_FAMILY_ITEM_COMPONENT as Ol, FONT_FAMILY_COMPONENT as Tl, FONT_SIZE_LIST as Bl, FONT_SIZE_COMPONENT as Ml, HEADING_LIST as Ys, COMMON_LABEL_COMPONENT as _l, HEADING_ITEM_COMPONENT as Dl, ICanvasPopupService as Pl, IMenuManagerService as Aa, ToolbarItem as wl, MenuManagerPosition as Nl, useObservable as et, RectPopup as Ll, DesktopMenu as Ql, ContextMenuPosition as oo, MetaKeys as te, Slider as Ul, useConfigValue as ua, useEvent as mn, ContextMenuGroup as an, RibbonInsertGroup as Fl, RibbonStartGroup as Ks, IUIPartsService as Hl, IShortcutService as Bo, BuiltInUIPart as qs, connectInjector as Xs, imageMimeTypeSet as kl, IContextMenuService as Vl } from "@univerjs/ui";
8
8
  import { ImageSourceType as Wr } from "@univerjs/drawing";
9
- import { Subject as be, BehaviorSubject as Fe, merge as ha, filter as oo, takeUntil as ft, fromEvent as je, Observable as fe, map as Pn, combineLatest as wn, distinctUntilChanged as Wt, throttleTime as Rn, switchMap as Wl, take as jl, first as zl, of as Gl, animationFrameScheduler as Yl } from "rxjs";
9
+ import { Subject as be, BehaviorSubject as Fe, merge as ha, filter as ro, takeUntil as ft, fromEvent as ze, Observable as fe, map as Pn, combineLatest as wn, distinctUntilChanged as Wt, throttleTime as Rn, switchMap as Wl, take as zl, first as jl, of as Gl, animationFrameScheduler as Yl } from "rxjs";
10
10
  import { useRef as ke, createElement as Be, forwardRef as Me, useState as Ee, useEffect as Ce, useMemo as Te, useCallback as ga, useImperativeHandle as Kl, useLayoutEffect as fa } from "react";
11
11
  import { filter as dr, bufferTime as ql, map as Xl } from "rxjs/operators";
12
12
  import { jsxs as re, jsx as Q, Fragment as Zl } from "react/jsx-runtime";
13
- import { Checkbox as Zs, InputNumber as it, Button as Jl, clsx as ze, borderClassName as Nn, Select as pa, scrollbarClassName as $l, Tooltip as ed } from "@univerjs/design";
13
+ import { Checkbox as Zs, InputNumber as it, Button as Jl, clsx as je, borderClassName as Nn, Select as pa, scrollbarClassName as $l, Tooltip as ed } from "@univerjs/design";
14
14
  var td = Object.getOwnPropertyDescriptor, nd = (n, e, t, o) => {
15
15
  for (var r = o > 1 ? void 0 : o ? td(e, t) : e, s = n.length - 1, i; s >= 0; s--)
16
16
  (i = n[s]) && (r = i(r) || r);
@@ -55,7 +55,7 @@ let Pt = class extends me {
55
55
  };
56
56
  Pt = nd([
57
57
  Js(0, L),
58
- Js(1, j(Y))
58
+ Js(1, z(Y))
59
59
  ], Pt);
60
60
  const od = {
61
61
  undo: !0,
@@ -100,7 +100,7 @@ const od = {
100
100
  toolbar: !0
101
101
  }, sd = "DOC_UI_PLUGIN";
102
102
  var $e = /* @__PURE__ */ ((n) => (n.MAIN = "__Document_Render_Main__", n.BACKGROUND = "__Document_Render_Background__", n))($e || {}), We = /* @__PURE__ */ ((n) => (n.VIEW_MAIN = "viewMain", n.VIEW_TOP = "viewTop", n.VIEW_LEFT = "viewLeft", n.VIEW_LEFT_TOP = "viewLeftTop", n))(We || {});
103
- const id = 0, zo = 2, ad = 4, $s = 10, jf = "normalTextSelectionPluginName";
103
+ const id = 0, Go = 2, ad = 4, $s = 10, zf = "normalTextSelectionPluginName";
104
104
  function pt(n) {
105
105
  const { mainComponent: e, scene: t, engine: o, components: r } = n, s = e, i = r.get($e.BACKGROUND);
106
106
  return {
@@ -125,7 +125,7 @@ function cd(n, e) {
125
125
  engine: a
126
126
  };
127
127
  }
128
- function zf(n, e) {
128
+ function jf(n, e) {
129
129
  const t = e.getRenderById(n);
130
130
  if (t == null)
131
131
  return;
@@ -187,7 +187,7 @@ function Yf(n, e) {
187
187
  function Kf(n, e) {
188
188
  return e.some((t) => n.startIndex > t.startIndex && n.startIndex < t.endIndex);
189
189
  }
190
- function Bo(n, e, t, o, r) {
190
+ function Mo(n, e, t, o, r) {
191
191
  const { textRuns: s = [], dataStream: i } = n, a = r && i.startsWith("="), c = {
192
192
  st: 0,
193
193
  ed: 0,
@@ -214,7 +214,7 @@ function Bo(n, e, t, o, r) {
214
214
  ...o
215
215
  }), c;
216
216
  }
217
- function jr(n, e, t) {
217
+ function zr(n, e, t) {
218
218
  if (t) {
219
219
  const r = n.find((s) => e >= s.startIndex && e <= s.endIndex + 1);
220
220
  return r != null && r.wholeEntity ? null : r;
@@ -222,7 +222,7 @@ function jr(n, e, t) {
222
222
  const o = n.find((r) => e > r.startIndex && e <= r.endIndex);
223
223
  return o != null && o.wholeEntity ? null : o;
224
224
  }
225
- function zr(n, e) {
225
+ function jr(n, e) {
226
226
  return n.filter((t) => e > t.startIndex && e <= t.endIndex);
227
227
  }
228
228
  function qf(n) {
@@ -240,7 +240,7 @@ function Xf(n, e = 0, t = 0) {
240
240
  height: n.height
241
241
  },
242
242
  positionH: {
243
- relativeFrom: Co.MARGIN,
243
+ relativeFrom: Ro.MARGIN,
244
244
  posOffset: (n.left || 0) - e
245
245
  },
246
246
  positionV: {
@@ -257,11 +257,11 @@ const dd = "doc.command.tab", Jt = {
257
257
  const o = n.get(Pt).onAutoFormat(Jt.id, e);
258
258
  return (await wr(o, n.get(T))).result;
259
259
  }
260
- }, Ad = "doc.command.after-space", Mo = {
260
+ }, Ad = "doc.command.after-space", _o = {
261
261
  id: Ad,
262
262
  type: D.COMMAND,
263
263
  async handler(n) {
264
- const t = n.get(Pt).onAutoFormat(Mo.id);
264
+ const t = n.get(Pt).onAutoFormat(_o.id);
265
265
  return (await wr(t, n.get(T))).result;
266
266
  }
267
267
  }, bn = {
@@ -276,7 +276,7 @@ var ud = Object.getOwnPropertyDescriptor, hd = (n, e, t, o) => {
276
276
  for (var r = o > 1 ? void 0 : o ? ud(e, t) : e, s = n.length - 1, i; s >= 0; s--)
277
277
  (i = n[s]) && (r = i(r) || r);
278
278
  return r;
279
- }, Go = (n, e) => (t, o) => e(t, o, n);
279
+ }, Yo = (n, e) => (t, o) => e(t, o, n);
280
280
  const gd = 11, fd = 9, kn = {
281
281
  /**
282
282
  * fontFamily
@@ -334,9 +334,9 @@ let at = class extends me {
334
334
  }
335
335
  };
336
336
  at = hd([
337
- Go(0, j(Y)),
338
- Go(1, L),
339
- Go(2, pe)
337
+ Yo(0, z(Y)),
338
+ Yo(1, L),
339
+ Yo(2, pe)
340
340
  ], at);
341
341
  function Ke(n, e) {
342
342
  var o;
@@ -390,7 +390,7 @@ const Gr = {
390
390
  const h = l.getUnitId(), { startOffset: u, endOffset: g } = i, p = ((ee = A.paragraphs) != null ? ee : []).find((k) => k.startIndex >= u);
391
391
  if (!p)
392
392
  return !1;
393
- const m = u === p.startIndex, I = p.startIndex, S = s.getDefaultStyle(), v = s.getStyleCache(), R = Bo(A, g, S, v), E = {
393
+ const m = u === p.startIndex, I = p.startIndex, S = s.getDefaultStyle(), v = s.getStyleCache(), R = Mo(A, g, S, v), E = {
394
394
  dataStream: V.PARAGRAPH,
395
395
  paragraphs: ma(
396
396
  V.PARAGRAPH,
@@ -475,7 +475,7 @@ const Gr = {
475
475
  return y.params.actions = P.editOp(M.serialize(), F), !!r.syncExecuteCommand(y.id, y.params);
476
476
  }
477
477
  };
478
- var _o = /* @__PURE__ */ ((n) => (n[n.ABOVE = 0] = "ABOVE", n[n.BELLOW = 1] = "BELLOW", n))(_o || {}), Yr = /* @__PURE__ */ ((n) => (n[n.LEFT = 0] = "LEFT", n[n.RIGHT = 1] = "RIGHT", n))(Yr || {});
478
+ var Do = /* @__PURE__ */ ((n) => (n[n.ABOVE = 0] = "ABOVE", n[n.BELLOW = 1] = "BELLOW", n))(Do || {}), Yr = /* @__PURE__ */ ((n) => (n[n.LEFT = 0] = "LEFT", n[n.RIGHT = 1] = "RIGHT", n))(Yr || {});
479
479
  function pd(n, e) {
480
480
  let t = V.TABLE_START;
481
481
  const o = [], r = [];
@@ -552,7 +552,7 @@ function Ea(n, e, t) {
552
552
  textWrap: Dc.NONE,
553
553
  position: {
554
554
  positionH: {
555
- relativeFrom: Co.PAGE,
555
+ relativeFrom: Ro.PAGE,
556
556
  posOffset: 0
557
557
  },
558
558
  positionV: {
@@ -993,7 +993,7 @@ const yd = En, va = {
993
993
  v.push(At), v.push(Je);
994
994
  }
995
995
  }
996
- const ne = jr((P = g.customRanges) != null ? P : [], $, yd.includes(f)), ie = zr((F = g.customDecorations) != null ? F : [], $);
996
+ const ne = zr((P = g.customRanges) != null ? P : [], $, yd.includes(f)), ie = jr((F = g.customDecorations) != null ? F : [], $);
997
997
  if (ne && (k.customRanges = [{
998
998
  ...ne,
999
999
  startIndex: 0,
@@ -1454,7 +1454,7 @@ function $r(n, e) {
1454
1454
  }
1455
1455
  return t;
1456
1456
  }
1457
- const Do = {
1457
+ const Po = {
1458
1458
  id: "doc.command.delete-left",
1459
1459
  type: D.COMMAND,
1460
1460
  // eslint-disable-next-line max-lines-per-function, complexity
@@ -1539,7 +1539,7 @@ const Do = {
1539
1539
  if (w == null)
1540
1540
  return !0;
1541
1541
  const N = (F = (P = s.getBody()) == null ? void 0 : P.customBlocks) == null ? void 0 : F.find(($) => $.blockId === b.drawingId);
1542
- if (w.layoutType === Ro.INLINE || (N == null ? void 0 : N.blockType) === wc.CUSTOM) {
1542
+ if (w.layoutType === bo.INLINE || (N == null ? void 0 : N.blockType) === wc.CUSTOM) {
1543
1543
  const $ = s.getUnitId();
1544
1544
  r = await o.executeCommand(Zr.id, {
1545
1545
  direction: Ne.LEFT,
@@ -1634,7 +1634,7 @@ const Do = {
1634
1634
  const b = (v = o.getSnapshot().drawings) == null ? void 0 : v[(S = R.drawingId) != null ? S : ""];
1635
1635
  if (b == null)
1636
1636
  return !0;
1637
- if (b.layoutType === Ro.INLINE) {
1637
+ if (b.layoutType === bo.INLINE) {
1638
1638
  const C = o.getUnitId();
1639
1639
  I = await s.executeCommand(Zr.id, {
1640
1640
  direction: Ne.RIGHT,
@@ -1762,30 +1762,30 @@ class Ld {
1762
1762
  this._cache.clear();
1763
1763
  }
1764
1764
  }
1765
- const Yo = new Ld();
1765
+ const Ko = new Ld();
1766
1766
  function ts(n) {
1767
1767
  const e = n.style, t = {}, o = n.tagName.toLowerCase();
1768
1768
  switch (o) {
1769
1769
  case "b":
1770
1770
  case "em":
1771
1771
  case "strong": {
1772
- t.bl = z.TRUE;
1772
+ t.bl = j.TRUE;
1773
1773
  break;
1774
1774
  }
1775
1775
  case "s": {
1776
1776
  t.st = {
1777
- s: z.TRUE
1777
+ s: j.TRUE
1778
1778
  };
1779
1779
  break;
1780
1780
  }
1781
1781
  case "u": {
1782
1782
  t.ul = {
1783
- s: z.TRUE
1783
+ s: j.TRUE
1784
1784
  };
1785
1785
  break;
1786
1786
  }
1787
1787
  case "i": {
1788
- t.it = z.TRUE;
1788
+ t.it = j.TRUE;
1789
1789
  break;
1790
1790
  }
1791
1791
  case "sub":
@@ -1807,20 +1807,20 @@ function ts(n) {
1807
1807
  break;
1808
1808
  }
1809
1809
  case "font-style": {
1810
- i === "italic" && (t.it = z.TRUE);
1810
+ i === "italic" && (t.it = j.TRUE);
1811
1811
  break;
1812
1812
  }
1813
1813
  case "font-weight": {
1814
- (Number(i) > 400 || String(i) === "bold") && (t.bl = z.TRUE);
1814
+ (Number(i) > 400 || String(i) === "bold") && (t.bl = j.TRUE);
1815
1815
  break;
1816
1816
  }
1817
1817
  case "text-decoration": {
1818
1818
  /underline/.test(i) ? t.ul = {
1819
- s: z.TRUE
1819
+ s: j.TRUE
1820
1820
  } : /overline/.test(i) ? t.ol = {
1821
- s: z.TRUE
1821
+ s: j.TRUE
1822
1822
  } : /line-through/.test(i) && (t.st = {
1823
- s: z.TRUE
1823
+ s: j.TRUE
1824
1824
  });
1825
1825
  break;
1826
1826
  }
@@ -1853,7 +1853,7 @@ function ti(n, e) {
1853
1853
  const t = n.tagName.toLowerCase();
1854
1854
  return typeof e == "string" ? t === e : Array.isArray(e) ? e.some((o) => o === t) : e(n);
1855
1855
  }
1856
- const ni = 660, vo = class vo {
1856
+ const ni = 660, Co = class Co {
1857
1857
  constructor() {
1858
1858
  O(this, "_tableCache", []);
1859
1859
  O(this, "_styleCache", /* @__PURE__ */ new Map());
@@ -1867,7 +1867,7 @@ const ni = 660, vo = class vo {
1867
1867
  }
1868
1868
  convert(e, t = {}) {
1869
1869
  var a;
1870
- const o = vo._pluginList.find((c) => c.checkPasteType(e)), r = Qd(e), i = {
1870
+ const o = Co._pluginList.find((c) => c.checkPasteType(e)), r = Qd(e), i = {
1871
1871
  body: {
1872
1872
  dataStream: "",
1873
1873
  paragraphs: [],
@@ -1911,7 +1911,7 @@ const ni = 660, vo = class vo {
1911
1911
  size: { width: f, height: p },
1912
1912
  angle: 0,
1913
1913
  positionH: {
1914
- relativeFrom: Co.PAGE,
1914
+ relativeFrom: Ro.PAGE,
1915
1915
  posOffset: 0
1916
1916
  },
1917
1917
  positionV: {
@@ -1919,7 +1919,7 @@ const ni = 660, vo = class vo {
1919
1919
  posOffset: 0
1920
1920
  }
1921
1921
  },
1922
- layoutType: Ro.INLINE,
1922
+ layoutType: bo.INLINE,
1923
1923
  drawingType: Nr.DRAWING_IMAGE,
1924
1924
  unitId: o.id || "",
1925
1925
  subUnitId: o.id || ""
@@ -2012,8 +2012,8 @@ ${V.TABLE_CELL_END}`;
2012
2012
  }));
2013
2013
  }
2014
2014
  };
2015
- O(vo, "_pluginList", []);
2016
- let en = vo;
2015
+ O(Co, "_pluginList", []);
2016
+ let en = Co;
2017
2017
  const Ud = {
2018
2018
  name: "univer-doc-paste-plugin-lark",
2019
2019
  checkPasteType(n) {
@@ -2027,7 +2027,7 @@ const Ud = {
2027
2027
  const e = ts(n);
2028
2028
  return {
2029
2029
  st: {
2030
- s: z.TRUE
2030
+ s: j.TRUE
2031
2031
  },
2032
2032
  ...e
2033
2033
  };
@@ -2103,7 +2103,7 @@ const Fd = {
2103
2103
  filter: ["b"],
2104
2104
  getStyle(n) {
2105
2105
  const e = ts(n);
2106
- return { bl: z.TRUE, ...e };
2106
+ return { bl: j.TRUE, ...e };
2107
2107
  }
2108
2108
  }
2109
2109
  ],
@@ -2145,9 +2145,9 @@ function oi(n, e) {
2145
2145
  const { st: t, ed: o, ts: r = {} } = e, { ff: s, fs: i, it: a, bl: c, ul: d, st: l, ol: A, bg: h, cl: u, va: g } = r;
2146
2146
  let f = n.slice(t, o);
2147
2147
  const p = [];
2148
- return a === z.TRUE && (f = `<i>${f}</i>`), g === Ve.SUPERSCRIPT ? f = `<sup>${f}</sup>` : g === Ve.SUBSCRIPT && (f = `<sub>${f}</sub>`), (d == null ? void 0 : d.s) === z.TRUE && (f = `<u>${f}</u>`), (l == null ? void 0 : l.s) === z.TRUE && (f = `<s>${f}</s>`), c === z.TRUE && (f = `<strong>${f}</strong>`), s && p.push(`font-family: ${s}`), u && p.push(`color: ${u.rgb}`), i && p.push(`font-size: ${i}pt`), A && p.push("text-decoration: overline"), h && p.push(`background: ${h.rgb}`), p.length ? `<span style="${p.join("; ")};">${f}</span>` : f;
2148
+ return a === j.TRUE && (f = `<i>${f}</i>`), g === Ve.SUPERSCRIPT ? f = `<sup>${f}</sup>` : g === Ve.SUBSCRIPT && (f = `<sub>${f}</sub>`), (d == null ? void 0 : d.s) === j.TRUE && (f = `<u>${f}</u>`), (l == null ? void 0 : l.s) === j.TRUE && (f = `<s>${f}</s>`), c === j.TRUE && (f = `<strong>${f}</strong>`), s && p.push(`font-family: ${s}`), u && p.push(`color: ${u.rgb}`), i && p.push(`font-size: ${i}pt`), A && p.push("text-decoration: overline"), h && p.push(`background: ${h.rgb}`), p.length ? `<span style="${p.join("; ")};">${f}</span>` : f;
2149
2149
  }
2150
- function Ko(n, e, t) {
2150
+ function qo(n, e, t) {
2151
2151
  const { dataStream: o, textRuns: r = [] } = n;
2152
2152
  if (e === t)
2153
2153
  return "";
@@ -2172,10 +2172,10 @@ function Vd(n, e, t) {
2172
2172
  const A = (u, g) => {
2173
2173
  let f = "", p = 0, m = u, I = a.findIndex((S) => u <= S.startIndex && g >= S.startIndex);
2174
2174
  if (I === -1)
2175
- return f = Ko(o, u, g), { sliceHtml: f, customBlockLength: p };
2175
+ return f = qo(o, u, g), { sliceHtml: f, customBlockLength: p };
2176
2176
  for (; I !== -1; ) {
2177
2177
  const S = a[I];
2178
- a.splice(I, 1), f += Ko(o, m, S.startIndex);
2178
+ a.splice(I, 1), f += qo(o, m, S.startIndex);
2179
2179
  const v = r[S.blockId];
2180
2180
  if (v)
2181
2181
  switch (v.drawingType) {
@@ -2186,7 +2186,7 @@ function Vd(n, e, t) {
2186
2186
  }
2187
2187
  m = S.startIndex + 1, I = a.findIndex((R) => m <= R.startIndex && g >= R.startIndex);
2188
2188
  }
2189
- return f = f + Ko(o, m, g + 1), { sliceHtml: f, customBlockLength: p };
2189
+ return f = f + qo(o, m, g + 1), { sliceHtml: f, customBlockLength: p };
2190
2190
  };
2191
2191
  c.forEach((u) => {
2192
2192
  var v, R;
@@ -2267,7 +2267,7 @@ function Kt(n, e, t) {
2267
2267
  throw new Error(`Unknown node type: ${n.nodeType}`);
2268
2268
  }
2269
2269
  }
2270
- class jd {
2270
+ class zd {
2271
2271
  convert(e) {
2272
2272
  if (e.length === 0)
2273
2273
  throw new Error("The bodyList length at least to be 1");
@@ -2277,8 +2277,8 @@ class jd {
2277
2277
  return t;
2278
2278
  }
2279
2279
  }
2280
- var zd = Object.getOwnPropertyDescriptor, Gd = (n, e, t, o) => {
2281
- for (var r = o > 1 ? void 0 : o ? zd(e, t) : e, s = n.length - 1, i; s >= 0; s--)
2280
+ var jd = Object.getOwnPropertyDescriptor, Gd = (n, e, t, o) => {
2281
+ for (var r = o > 1 ? void 0 : o ? jd(e, t) : e, s = n.length - 1, i; s >= 0; s--)
2282
2282
  (i = n[s]) && (r = i(r) || r);
2283
2283
  return r;
2284
2284
  }, cn = (n, e) => (t, o) => e(t, o, n);
@@ -2305,10 +2305,10 @@ let ur = class extends me {
2305
2305
  super();
2306
2306
  O(this, "_clipboardHooks", []);
2307
2307
  O(this, "_htmlToUDM", new en());
2308
- O(this, "_umdToHtml", new jd());
2308
+ O(this, "_umdToHtml", new zd());
2309
2309
  this._univerInstanceService = e, this._logService = t, this._commandService = o, this._clipboardInterfaceService = r, this._docSelectionManagerService = s;
2310
2310
  }
2311
- async copy(e = ir.copy, t) {
2311
+ async copy(e = ar.copy, t) {
2312
2312
  var a, c;
2313
2313
  const { newSnapshotList: o = [], needCache: r = !1, snapshot: s, ranges: i } = (a = this._getDocumentBodyInRanges(e, t)) != null ? a : {};
2314
2314
  if (o.length === 0 || s == null)
@@ -2334,7 +2334,7 @@ let ur = class extends me {
2334
2334
  if (!t && !o && r.length && (t = await this._createImagePasteHtml(r)), !t && !o)
2335
2335
  return this._logService.warn("[DocClipboardController] html and text cannot be both empty!"), !1;
2336
2336
  const a = this._genDocDataFromHtmlAndText(t, o, i);
2337
- if (i === bo)
2337
+ if (i === xo)
2338
2338
  if (o) {
2339
2339
  const c = ce.transform.fromPlainText(o);
2340
2340
  return this._paste({ body: c });
@@ -2351,7 +2351,7 @@ let ur = class extends me {
2351
2351
  } = (A = t[0]) != null ? A : {};
2352
2352
  if (r == null && this._logService.error("[DocClipboardController] segmentId is not existed"), t.length === 0 && o.length === 0)
2353
2353
  return !1;
2354
- this.copy(ir.cut, e);
2354
+ this.copy(ar.cut, e);
2355
2355
  try {
2356
2356
  let h = 0;
2357
2357
  if (o.length > 0)
@@ -2447,7 +2447,7 @@ let ur = class extends me {
2447
2447
  }
2448
2448
  }
2449
2449
  }
2450
- Yo.set(o, A);
2450
+ Ko.set(o, A);
2451
2451
  }
2452
2452
  return this._clipboardInterfaceService.write(r, s);
2453
2453
  }
@@ -2494,11 +2494,11 @@ let ur = class extends me {
2494
2494
  for (const s of e)
2495
2495
  for (const i of s.types)
2496
2496
  switch (i) {
2497
- case aa: {
2497
+ case ca: {
2498
2498
  o = await s.getType(i).then((a) => a && a.text());
2499
2499
  break;
2500
2500
  }
2501
- case ia: {
2501
+ case aa: {
2502
2502
  t = await s.getType(i).then((a) => a && a.text());
2503
2503
  break;
2504
2504
  }
@@ -2524,7 +2524,7 @@ let ur = class extends me {
2524
2524
  }
2525
2525
  const r = Nd(e);
2526
2526
  if (r) {
2527
- const i = Yo.get(r);
2527
+ const i = Ko.get(r);
2528
2528
  if (i)
2529
2529
  return i;
2530
2530
  }
@@ -2533,7 +2533,7 @@ let ur = class extends me {
2533
2533
  o = (i == null ? void 0 : i.getUnitId()) || "";
2534
2534
  }
2535
2535
  const s = this._htmlToUDM.convert(e, { unitId: o });
2536
- return r && Yo.set(r, s), s;
2536
+ return r && Ko.set(r, s), s;
2537
2537
  }
2538
2538
  async _createImagePasteHtml(e) {
2539
2539
  var a, c;
@@ -2578,7 +2578,7 @@ let ur = class extends me {
2578
2578
  title: "",
2579
2579
  source: A.source,
2580
2580
  description: "",
2581
- layoutType: Ro.INLINE,
2581
+ layoutType: bo.INLINE,
2582
2582
  drawingType: Nr.DRAWING_IMAGE,
2583
2583
  transform: {
2584
2584
  width: h,
@@ -2588,7 +2588,7 @@ let ur = class extends me {
2588
2588
  docTransform: {
2589
2589
  angle: 0,
2590
2590
  size: { width: h, height: u },
2591
- positionH: { relativeFrom: Co.CHARACTER, posOffset: 0 },
2591
+ positionH: { relativeFrom: Ro.CHARACTER, posOffset: 0 },
2592
2592
  positionV: { relativeFrom: gt.LINE, posOffset: 0 }
2593
2593
  }
2594
2594
  };
@@ -2599,19 +2599,19 @@ ur = Gd([
2599
2599
  cn(0, L),
2600
2600
  cn(1, Qr),
2601
2601
  cn(2, T),
2602
- cn(3, sa),
2603
- cn(4, j(Y))
2602
+ cn(3, ia),
2603
+ cn(4, z(Y))
2604
2604
  ], ur);
2605
- function Po(n) {
2605
+ function wo(n) {
2606
2606
  return n.getContextValue(_n) || n.getContextValue(eo);
2607
2607
  }
2608
- const ns = 999, ro = {
2608
+ const ns = 999, so = {
2609
2609
  id: bl.id,
2610
2610
  name: "doc.command.copy",
2611
2611
  type: D.COMMAND,
2612
2612
  multi: !0,
2613
2613
  priority: ns,
2614
- preconditions: Po,
2614
+ preconditions: wo,
2615
2615
  handler: async (n) => n.get(Lt).copy()
2616
2616
  }, os = {
2617
2617
  id: "doc.command.copy-current-paragraph",
@@ -2619,7 +2619,7 @@ const ns = 999, ro = {
2619
2619
  handler: async (n) => {
2620
2620
  const e = n.get(Lt), t = Qn(n);
2621
2621
  return t ? e.copy(
2622
- ir.copy,
2622
+ ar.copy,
2623
2623
  [{
2624
2624
  startOffset: t.paragraphStart,
2625
2625
  endOffset: t.paragraphEnd + 1,
@@ -2633,7 +2633,7 @@ const ns = 999, ro = {
2633
2633
  type: D.COMMAND,
2634
2634
  multi: !0,
2635
2635
  priority: ns,
2636
- preconditions: Po,
2636
+ preconditions: wo,
2637
2637
  handler: async (n) => n.get(Lt).cut()
2638
2638
  }, ss = {
2639
2639
  id: "doc.command.cut-current-paragraph",
@@ -2655,12 +2655,12 @@ const ns = 999, ro = {
2655
2655
  type: D.COMMAND,
2656
2656
  multi: !0,
2657
2657
  priority: ns,
2658
- preconditions: Po,
2658
+ preconditions: wo,
2659
2659
  handler: async (n) => {
2660
- const e = n.get(Lt), o = await n.get(sa).read();
2660
+ const e = n.get(Lt), o = await n.get(ia).read();
2661
2661
  return o.length === 0 ? !1 : e.paste(o);
2662
2662
  }
2663
- }, wo = {
2663
+ }, No = {
2664
2664
  id: "doc.command.horizontal-line",
2665
2665
  type: D.COMMAND,
2666
2666
  handler: (n, e) => n.get(T).syncExecuteCommand(Gr.id, {
@@ -2679,7 +2679,7 @@ const ns = 999, ro = {
2679
2679
  type: D.COMMAND,
2680
2680
  handler: (n) => {
2681
2681
  const e = n.get(T), t = Qn(n);
2682
- return t ? e.syncExecuteCommand(wo.id, {
2682
+ return t ? e.syncExecuteCommand(No.id, {
2683
2683
  insertRange: {
2684
2684
  startOffset: t.startIndex + 1,
2685
2685
  endOffset: t.startIndex + 1
@@ -2727,7 +2727,7 @@ const ns = 999, ro = {
2727
2727
  }, !1), !0;
2728
2728
  }
2729
2729
  };
2730
- class No extends Ct {
2730
+ class Lo extends Ct {
2731
2731
  constructor(t) {
2732
2732
  super();
2733
2733
  O(this, "_previousActiveRange", null);
@@ -2782,7 +2782,7 @@ const Ba = {
2782
2782
  // eslint-disable-next-line max-lines-per-function
2783
2783
  handler: async (n, e) => {
2784
2784
  var N, ee, $;
2785
- const { unitId: t, newText: o, oldTextLen: r, isCompositionEnd: s, isCompositionStart: i } = e, a = n.get(T), c = n.get(pe), d = n.get(L), l = n.get(at), A = (N = c.getRenderById(t)) == null ? void 0 : N.with(No), h = d.getUnit(t, _.UNIVER_DOC);
2785
+ const { unitId: t, newText: o, oldTextLen: r, isCompositionEnd: s, isCompositionStart: i } = e, a = n.get(T), c = n.get(pe), d = n.get(L), l = n.get(at), A = (N = c.getRenderById(t)) == null ? void 0 : N.with(Lo), h = d.getUnit(t, _.UNIVER_DOC);
2786
2786
  if (h == null || A == null)
2787
2787
  return !1;
2788
2788
  const u = A.getActiveRange();
@@ -2806,13 +2806,13 @@ const Ba = {
2806
2806
  actions: [],
2807
2807
  textRanges: R
2808
2808
  }
2809
- }, b = l.getDefaultStyle(), x = l.getStyleCache(), C = jr((ee = p.customRanges) != null ? ee : [], I + r, En.includes(t)), B = Bo(
2809
+ }, b = l.getDefaultStyle(), x = l.getStyleCache(), C = zr((ee = p.customRanges) != null ? ee : [], I + r, En.includes(t)), B = Mo(
2810
2810
  p,
2811
2811
  i ? S : I + r,
2812
2812
  b,
2813
2813
  x,
2814
2814
  En.includes(t)
2815
- ), y = zr(($ = p.customDecorations) != null ? $ : [], I + r), M = new Ie(), P = W.getInstance();
2815
+ ), y = jr(($ = p.customDecorations) != null ? $ : [], I + r), M = new Ie(), P = W.getInstance();
2816
2816
  if (!u.collapsed && i) {
2817
2817
  const U = ce.selection.delete([u], p, 0, null, !1);
2818
2818
  M.push(...U), E.params.textRanges = [{
@@ -3112,12 +3112,12 @@ function Yd(n) {
3112
3112
  }
3113
3113
  function Ma(n, e, t) {
3114
3114
  if (/bl|it/.test(e))
3115
- return (n == null ? void 0 : n[e]) === z.TRUE ? z.FALSE : z.TRUE;
3115
+ return (n == null ? void 0 : n[e]) === j.TRUE ? j.FALSE : j.TRUE;
3116
3116
  if (/ul|st/.test(e))
3117
- return Yd(n == null ? void 0 : n[e]) && (n == null ? void 0 : n[e]).s === z.TRUE ? {
3118
- s: z.FALSE
3117
+ return Yd(n == null ? void 0 : n[e]) && (n == null ? void 0 : n[e]).s === j.TRUE ? {
3118
+ s: j.FALSE
3119
3119
  } : {
3120
- s: z.TRUE
3120
+ s: j.TRUE
3121
3121
  };
3122
3122
  if (/va/.test(e))
3123
3123
  return t === bt.id ? (n == null ? void 0 : n[e]) === Ve.SUBSCRIPT ? Ve.NORMAL : Ve.SUBSCRIPT : (n == null ? void 0 : n[e]) === Ve.SUPERSCRIPT ? Ve.NORMAL : Ve.SUPERSCRIPT;
@@ -3146,16 +3146,16 @@ function _a(n, e, t) {
3146
3146
  return ((C = x.ts) == null ? void 0 : C.ff) != null;
3147
3147
  })) == null ? void 0 : A.ts) == null ? void 0 : h.ff) != null ? u : a.ff, a.it = i.length && i.every((x) => {
3148
3148
  var C;
3149
- return ((C = x.ts) == null ? void 0 : C.it) === z.TRUE;
3150
- }) ? z.TRUE : z.FALSE, a.bl = i.length && i.every((x) => {
3149
+ return ((C = x.ts) == null ? void 0 : C.it) === j.TRUE;
3150
+ }) ? j.TRUE : j.FALSE, a.bl = i.length && i.every((x) => {
3151
3151
  var C;
3152
- return ((C = x.ts) == null ? void 0 : C.bl) === z.TRUE;
3153
- }) ? z.TRUE : z.FALSE, a.ul = i.length && i.every((x) => {
3152
+ return ((C = x.ts) == null ? void 0 : C.bl) === j.TRUE;
3153
+ }) ? j.TRUE : j.FALSE, a.ul = i.length && i.every((x) => {
3154
3154
  var C, B;
3155
- return ((B = (C = x.ts) == null ? void 0 : C.ul) == null ? void 0 : B.s) === z.TRUE;
3155
+ return ((B = (C = x.ts) == null ? void 0 : C.ul) == null ? void 0 : B.s) === j.TRUE;
3156
3156
  }) ? (g = i[0].ts) == null ? void 0 : g.ul : a.ul, a.st = i.length && i.every((x) => {
3157
3157
  var C, B;
3158
- return ((B = (C = x.ts) == null ? void 0 : C.st) == null ? void 0 : B.s) === z.TRUE;
3158
+ return ((B = (C = x.ts) == null ? void 0 : C.st) == null ? void 0 : B.s) === j.TRUE;
3159
3159
  }) ? (f = i[0].ts) == null ? void 0 : f.st : a.st, a.bg = (I = (m = (p = i.find((x) => {
3160
3160
  var C;
3161
3161
  return ((C = x.ts) == null ? void 0 : C.bg) != null;
@@ -3269,7 +3269,7 @@ const Da = {
3269
3269
  id: "doc.command-cover-content",
3270
3270
  type: D.COMMAND,
3271
3271
  handler: (n, e) => {
3272
- const { unitId: t, body: o, segmentId: r = "", textRanges: s } = e, i = n.get(L), a = n.get(T), c = n.get(xo), d = i.getUniverDocInstance(t), l = d == null ? void 0 : d.getSnapshot().body;
3272
+ const { unitId: t, body: o, segmentId: r = "", textRanges: s } = e, i = n.get(L), a = n.get(T), c = n.get(yo), d = i.getUniverDocInstance(t), l = d == null ? void 0 : d.getSnapshot().body;
3273
3273
  if (d == null || l == null)
3274
3274
  return !1;
3275
3275
  const A = Pa(t, r, d, l, o);
@@ -3408,7 +3408,7 @@ const wa = {
3408
3408
  }), m = W.getInstance(), I = Ae(i, c);
3409
3409
  return g.params.actions = m.editOp(p.serialize(), I), !!r.syncExecuteCommand(g.id, g.params);
3410
3410
  }
3411
- }, Lo = {
3411
+ }, Qo = {
3412
3412
  id: "doc.command.change-list-type",
3413
3413
  type: D.COMMAND,
3414
3414
  handler: (n, e) => {
@@ -3474,7 +3474,7 @@ const gr = {
3474
3474
  type: D.COMMAND,
3475
3475
  handler: (n, e) => {
3476
3476
  const t = n.get(T);
3477
- return e != null && e.value ? t.syncExecuteCommand(Lo.id, {
3477
+ return e != null && e.value ? t.syncExecuteCommand(Qo.id, {
3478
3478
  listType: e.value,
3479
3479
  docRange: e.docRange
3480
3480
  }) : t.syncExecuteCommand(Fn.id, {
@@ -3482,12 +3482,12 @@ const gr = {
3482
3482
  docRange: e == null ? void 0 : e.docRange
3483
3483
  });
3484
3484
  }
3485
- }, so = {
3485
+ }, io = {
3486
3486
  id: "doc.command.check-list",
3487
3487
  type: D.COMMAND,
3488
3488
  handler: (n, e) => {
3489
3489
  const t = n.get(T);
3490
- return e != null && e.value ? t.syncExecuteCommand(Lo.id, {
3490
+ return e != null && e.value ? t.syncExecuteCommand(Qo.id, {
3491
3491
  listType: e.value,
3492
3492
  docRange: e.docRange
3493
3493
  }) : t.syncExecuteCommand(Fn.id, {
@@ -3529,7 +3529,7 @@ const gr = {
3529
3529
  type: D.COMMAND,
3530
3530
  handler: (n, e) => {
3531
3531
  const t = n.get(T);
3532
- return e != null && e.value ? t.syncExecuteCommand(Lo.id, {
3532
+ return e != null && e.value ? t.syncExecuteCommand(Qo.id, {
3533
3533
  listType: e.value
3534
3534
  }) : t.syncExecuteCommand(Fn.id, {
3535
3535
  listType: xe.ORDER_LIST
@@ -3724,25 +3724,25 @@ const ls = {
3724
3724
  const S = Ae(i, c);
3725
3725
  return f.params.actions = I.editOp(m.serialize(), S), !!r.syncExecuteCommand(f.id, f.params);
3726
3726
  }
3727
- }, Qo = {
3727
+ }, Uo = {
3728
3728
  id: "doc.command.align-left",
3729
3729
  type: D.COMMAND,
3730
3730
  handler: (n) => n.get(T).syncExecuteCommand(lt.id, {
3731
3731
  alignType: Ue.LEFT
3732
3732
  })
3733
- }, Uo = {
3733
+ }, Fo = {
3734
3734
  id: "doc.command.align-center",
3735
3735
  type: D.COMMAND,
3736
3736
  handler: (n) => n.get(T).syncExecuteCommand(lt.id, {
3737
3737
  alignType: Ue.CENTER
3738
3738
  })
3739
- }, Fo = {
3739
+ }, Ho = {
3740
3740
  id: "doc.command.align-right",
3741
3741
  type: D.COMMAND,
3742
3742
  handler: (n) => n.get(T).syncExecuteCommand(lt.id, {
3743
3743
  alignType: Ue.RIGHT
3744
3744
  })
3745
- }, Ho = {
3745
+ }, ko = {
3746
3746
  id: "doc.command.align-justify",
3747
3747
  type: D.COMMAND,
3748
3748
  handler: (n) => n.get(T).syncExecuteCommand(lt.id, {
@@ -3763,7 +3763,7 @@ const ls = {
3763
3763
  id: "doc.command.set-zoom-ratio",
3764
3764
  handler: async (n, e) => {
3765
3765
  var A, h, u;
3766
- const t = n.get(T), o = n.get(xo), r = n.get(L);
3766
+ const t = n.get(T), o = n.get(yo), r = n.get(L);
3767
3767
  let s = (A = r.getCurrentUniverDocInstance()) == null ? void 0 : A.getUnitId();
3768
3768
  if (!s) return !1;
3769
3769
  let i = 1;
@@ -3858,7 +3858,7 @@ const ls = {
3858
3858
  const S = Ae(i, c);
3859
3859
  return I.params.actions = p.editOp(f.serialize(), S), !!s.syncExecuteCommand(I.id, I.params);
3860
3860
  }
3861
- }, qo = {
3861
+ }, Xo = {
3862
3862
  "#": K.HEADING_1,
3863
3863
  "##": K.HEADING_2,
3864
3864
  "###": K.HEADING_3,
@@ -3894,7 +3894,7 @@ const ls = {
3894
3894
  handler: (n) => n.get(T).syncExecuteCommand(Xe.id, {
3895
3895
  value: K.HEADING_5
3896
3896
  })
3897
- }, io = {
3897
+ }, ao = {
3898
3898
  id: "doc.command.normal-text-heading",
3899
3899
  type: D.COMMAND,
3900
3900
  handler: (n) => n.get(T).syncExecuteCommand(Xe.id, {
@@ -3977,7 +3977,7 @@ function pr(n) {
3977
3977
  }
3978
3978
  class It {
3979
3979
  constructor(e, t) {
3980
- O(this, "_liquid", new $i());
3980
+ O(this, "_liquid", new ea());
3981
3981
  O(this, "_currentStartState", {
3982
3982
  page: 0,
3983
3983
  section: 0,
@@ -4020,7 +4020,7 @@ class It {
4020
4020
  return;
4021
4021
  const { x: E, y: b } = this._liquid;
4022
4022
  let x, C;
4023
- const B = v[d], y = v[l], M = v[d - 1], P = (B == null ? void 0 : B.left) || 0, F = (B == null ? void 0 : B.width) || 0, w = (y == null ? void 0 : y.left) || 0, N = (y == null ? void 0 : y.width) || 0, ee = (B == null ? void 0 : B.glyphType) === ea.LIST, { startOffset: $, endOffset: U } = tA(v, d, l, R), H = a.glyph === d && A ? a.isBack : !0, k = c.glyph === l && h ? c.isBack : !1, ne = a === c, ie = H && M != null ? M : B;
4023
+ const B = v[d], y = v[l], M = v[d - 1], P = (B == null ? void 0 : B.left) || 0, F = (B == null ? void 0 : B.width) || 0, w = (y == null ? void 0 : y.left) || 0, N = (y == null ? void 0 : y.width) || 0, ee = (B == null ? void 0 : B.glyphType) === ta.LIST, { startOffset: $, endOffset: U } = tA(v, d, l, R), H = a.glyph === d && A ? a.isBack : !0, k = c.glyph === l && h ? c.isBack : !1, ne = a === c, ie = H && M != null ? M : B;
4024
4024
  if (d === 0 && l === v.length - 1)
4025
4025
  x = {
4026
4026
  startX: E + P + (ee ? F : 0),
@@ -4198,9 +4198,9 @@ class It {
4198
4198
  );
4199
4199
  this._liquid.translateSave(), this._liquid.translateLine(he, !0, !1);
4200
4200
  for (let Je = Ze; Je <= At; Je++) {
4201
- const Wo = Pe[Je];
4202
- this._liquid.translateSave(), this._liquid.translateDivide(Wo);
4203
- const { glyphGroup: yc } = Wo, { start_next: Oc, end_next: Tc } = this._getSelectionRuler(
4201
+ const zo = Pe[Je];
4202
+ this._liquid.translateSave(), this._liquid.translateDivide(zo);
4203
+ const { glyphGroup: yc } = zo, { start_next: Oc, end_next: Tc } = this._getSelectionRuler(
4204
4204
  qt.divide,
4205
4205
  e,
4206
4206
  t,
@@ -4208,7 +4208,7 @@ class It {
4208
4208
  Je
4209
4209
  );
4210
4210
  let Ns = !1, Ls = !1;
4211
- E === I && w === P && H === $ && oe === ie && Je === Ze && (Ns = !0), E === S && w === F && H === U && oe === ae && Je === At && (Ls = !0), o && o(Oc, Tc, Ns, Ls, Wo, he, k, N, y), this._liquid.translateRestore();
4211
+ E === I && w === P && H === $ && oe === ie && Je === Ze && (Ns = !0), E === S && w === F && H === U && oe === ae && Je === At && (Ls = !0), o && o(Oc, Tc, Ns, Ls, zo, he, k, N, y), this._liquid.translateRestore();
4212
4212
  }
4213
4213
  this._liquid.translateRestore();
4214
4214
  }
@@ -4222,7 +4222,7 @@ function nA(n, e) {
4222
4222
  const { path: t } = n, { path: o } = e;
4223
4223
  if (t.length !== o.length || t.indexOf("cells") === -1)
4224
4224
  return !1;
4225
- const r = t.indexOf("skeTables") + 1, s = t.indexOf("rows") + 1, i = t.indexOf("cells") + 1, { tableId: a, sliceIndex: c } = js(t[r]), { tableId: d, sliceIndex: l } = js(o[r]);
4225
+ const r = t.indexOf("skeTables") + 1, s = t.indexOf("rows") + 1, i = t.indexOf("cells") + 1, { tableId: a, sliceIndex: c } = zs(t[r]), { tableId: d, sliceIndex: l } = zs(o[r]);
4226
4226
  if (a !== d)
4227
4227
  return !1;
4228
4228
  const A = t[s], h = o[s], u = t[i], g = o[i];
@@ -4243,7 +4243,7 @@ function ka(n, e, t) {
4243
4243
  const d = a.parent, l = c.parent, A = d.cells.indexOf(a), h = l.cells.indexOf(c);
4244
4244
  return A === h && d.index === l.index;
4245
4245
  }
4246
- function Xo(n, e) {
4246
+ function Zo(n, e) {
4247
4247
  if (Ha(n, e))
4248
4248
  return ms(n, e);
4249
4249
  const { path: t } = n, { path: o } = e, r = t[t.length - 5], s = o[o.length - 5];
@@ -4254,19 +4254,19 @@ function Xo(n, e) {
4254
4254
  const i = t[t.length - 3], a = o[o.length - 3], c = t[t.length - 1], d = o[o.length - 1];
4255
4255
  return i < a ? !0 : i > a ? !1 : c <= d;
4256
4256
  }
4257
- function jt(n) {
4257
+ function zt(n) {
4258
4258
  return n.sections[0].columns[0].lines.length === 0;
4259
4259
  }
4260
4260
  function oA(n, e, t) {
4261
4261
  let o = e, r = t, s = n[o], i = n[r];
4262
- for (; o < r && (jt(s) || jt(i)); )
4263
- jt(s) ? (o++, s = n[o]) : jt(i) && (r--, i = n[r]);
4264
- if (!jt(s) && !jt(i))
4262
+ for (; o < r && (zt(s) || zt(i)); )
4263
+ zt(s) ? (o++, s = n[o]) : zt(i) && (r--, i = n[r]);
4264
+ if (!zt(s) && !zt(i))
4265
4265
  return [s, i];
4266
4266
  }
4267
4267
  class Va {
4268
4268
  constructor(e, t) {
4269
- O(this, "_liquid", new $i());
4269
+ O(this, "_liquid", new ea());
4270
4270
  this._documentOffsetConfig = e, this._docSkeleton = t;
4271
4271
  }
4272
4272
  // eslint-disable-next-line max-lines-per-function
@@ -4376,7 +4376,7 @@ class Va {
4376
4376
  };
4377
4377
  }
4378
4378
  }
4379
- const rA = "__TestSelectionRange__", sA = "__TestSelectionAnchor__", mi = 6, Zo = 500, iA = 500, mr = 3;
4379
+ const rA = "__TestSelectionRange__", sA = "__TestSelectionAnchor__", mi = 6, Jo = 500, iA = 500, mr = 3;
4380
4380
  function Jn(n) {
4381
4381
  const e = n[0], t = e[0], o = e[2], { x: r, y: s } = t, { x: i, y: a } = o;
4382
4382
  return {
@@ -4415,11 +4415,11 @@ class Zt {
4415
4415
  _anchorBlink() {
4416
4416
  setTimeout(() => {
4417
4417
  this._anchorShape && this._anchorShape.visible && this.deactivateStatic();
4418
- }, Zo), this._anchorBlinkTimer = setInterval(() => {
4418
+ }, Jo), this._anchorBlinkTimer = setInterval(() => {
4419
4419
  this._anchorShape && this._anchorShape.visible && (this.activeStatic(), setTimeout(() => {
4420
4420
  this.deactivateStatic();
4421
- }, Zo));
4422
- }, iA + Zo);
4421
+ }, Jo));
4422
+ }, iA + Jo);
4423
4423
  }
4424
4424
  // The start position of the range
4425
4425
  get startOffset() {
@@ -4568,7 +4568,7 @@ class Zt {
4568
4568
  this._rangeShape.translate(t, o), this._rangeShape.updatePointGroup(e), this._rangeShape.show();
4569
4569
  return;
4570
4570
  }
4571
- const r = 0.3, s = new ta(rA + ge(mi), {
4571
+ const r = 0.3, s = new na(rA + ge(mi), {
4572
4572
  pointsGroup: e,
4573
4573
  fill: ((i = this.style) == null ? void 0 : i.fill) || fn(gn.black, r),
4574
4574
  left: t,
@@ -4586,7 +4586,7 @@ class Zt {
4586
4586
  c < d && (a -= d - c, c = d);
4587
4587
  const l = 12;
4588
4588
  let A = i + t;
4589
- const h = a + o, u = ((f = r == null ? void 0 : r.ts) == null ? void 0 : f.it) === z.TRUE;
4589
+ const h = a + o, u = ((f = r == null ? void 0 : r.ts) == null ? void 0 : f.it) === j.TRUE;
4590
4590
  if (u && (A += c * Math.tan(l * Math.PI / 180) / 2), this._anchorShape) {
4591
4591
  this._anchorShape.transformByState({ left: A, top: h, height: c }), this._anchorShape.show(), u ? this._anchorShape.skew(-l, 0) : this._anchorShape.skew(0, 0);
4592
4592
  return;
@@ -4606,7 +4606,7 @@ class Zt {
4606
4606
  }
4607
4607
  }
4608
4608
  const aA = "__DocTableRectRange__", cA = 6;
4609
- function Jo(n, e, t, o, r, s = Sn, i = "", a = -1) {
4609
+ function $o(n, e, t, o, r, s = Sn, i = "", a = -1) {
4610
4610
  const c = e.getOffsetConfig(), l = new Va(c, t).getNodePositionGroup(o, r);
4611
4611
  return (l != null ? l : []).map((A) => new Wa(
4612
4612
  n,
@@ -4691,15 +4691,15 @@ class Wa {
4691
4691
  }
4692
4692
  get startNodePosition() {
4693
4693
  const { anchorNodePosition: e, focusNodePosition: t } = this;
4694
- return Xo(e, t) ? e : t;
4694
+ return Zo(e, t) ? e : t;
4695
4695
  }
4696
4696
  get endNodePosition() {
4697
4697
  const { anchorNodePosition: e, focusNodePosition: t } = this;
4698
- return Xo(e, t) ? t : e;
4698
+ return Zo(e, t) ? t : e;
4699
4699
  }
4700
4700
  get direction() {
4701
4701
  const { anchorNodePosition: e, focusNodePosition: t } = this;
4702
- return Xo(e, t) ? De.FORWARD : De.BACKWARD;
4702
+ return Zo(e, t) ? De.FORWARD : De.BACKWARD;
4703
4703
  }
4704
4704
  isActive() {
4705
4705
  return this._current === !0;
@@ -4746,7 +4746,7 @@ class Wa {
4746
4746
  this._rangeShape.translate(t, o), this._rangeShape.updatePointGroup(e), this._rangeShape.show();
4747
4747
  return;
4748
4748
  }
4749
- const r = 0.3, s = new ta(aA + ge(cA), {
4749
+ const r = 0.3, s = new na(aA + ge(cA), {
4750
4750
  pointsGroup: e,
4751
4751
  fill: ((i = this.style) == null ? void 0 : i.fill) || fn(gn.black, r),
4752
4752
  left: t,
@@ -4790,7 +4790,7 @@ function Er(n, e, t, o, r, s, i, a) {
4790
4790
  rectRanges: d
4791
4791
  };
4792
4792
  {
4793
- const S = Jo(
4793
+ const S = $o(
4794
4794
  ...l
4795
4795
  );
4796
4796
  return d.push(...S), {
@@ -4800,7 +4800,7 @@ function Er(n, e, t, o, r, s, i, a) {
4800
4800
  }
4801
4801
  }
4802
4802
  if (nA(n, e)) {
4803
- const S = Jo(
4803
+ const S = $o(
4804
4804
  ...l
4805
4805
  );
4806
4806
  return d.push(...S), {
@@ -4834,7 +4834,7 @@ function Er(n, e, t, o, r, s, i, a) {
4834
4834
  }
4835
4835
  if (w && N) {
4836
4836
  const U = g === De.FORWARD ? w : N, H = g === De.FORWARD ? N : w;
4837
- d.push(...Jo(
4837
+ d.push(...$o(
4838
4838
  t,
4839
4839
  o,
4840
4840
  r,
@@ -4951,7 +4951,7 @@ let Re = class extends Ct {
4951
4951
  O(this, "onSelectionStart$", this._onSelectionStart$.asObservable());
4952
4952
  O(this, "onChangeByEvent$", ha(
4953
4953
  this._onInput$,
4954
- this._onKeydown$.pipe(oo((e) => e.event.keyCode === q.BACKSPACE)),
4954
+ this._onKeydown$.pipe(ro((e) => e.event.keyCode === q.BACKSPACE)),
4955
4955
  this._onCompositionend$
4956
4956
  ));
4957
4957
  O(this, "_onPaste$", new be());
@@ -5342,7 +5342,7 @@ let Re = class extends Ct {
5342
5342
  if (i == null)
5343
5343
  return;
5344
5344
  let c = o < 0.5;
5345
- return t.glyphType === ea.LIST && (c = !0), {
5345
+ return t.glyphType === ta.LIST && (c = !0), {
5346
5346
  ...i,
5347
5347
  isBack: c
5348
5348
  };
@@ -5531,13 +5531,13 @@ let Re = class extends Ct {
5531
5531
  // eslint-disable-next-line max-lines-per-function
5532
5532
  _initInputEvents() {
5533
5533
  this.disposeWithMe(
5534
- je(this._input, "keydown").subscribe((e) => {
5534
+ ze(this._input, "keydown").subscribe((e) => {
5535
5535
  this._isIMEInputApply || this._eventHandle(e, (t) => {
5536
5536
  this._onKeydown$.next(t);
5537
5537
  });
5538
5538
  })
5539
5539
  ), this.disposeWithMe(
5540
- je(this._input, "input").subscribe((e) => {
5540
+ ze(this._input, "input").subscribe((e) => {
5541
5541
  if (!(e.inputType === "historyUndo" || e.inputType === "historyRedo")) {
5542
5542
  if (this._rectRangeList.length > 0)
5543
5543
  return e.stopPropagation(), e.preventDefault();
@@ -5547,7 +5547,7 @@ let Re = class extends Ct {
5547
5547
  }
5548
5548
  })
5549
5549
  ), this.disposeWithMe(
5550
- je(this._input, "compositionstart").subscribe((e) => {
5550
+ ze(this._input, "compositionstart").subscribe((e) => {
5551
5551
  if (this._rectRangeList.length > 0)
5552
5552
  return e.stopPropagation(), e.preventDefault();
5553
5553
  this._isIMEInputApply = !0, this._eventHandle(e, (t) => {
@@ -5555,31 +5555,31 @@ let Re = class extends Ct {
5555
5555
  });
5556
5556
  })
5557
5557
  ), this.disposeWithMe(
5558
- je(this._input, "compositionend").subscribe((e) => {
5558
+ ze(this._input, "compositionend").subscribe((e) => {
5559
5559
  this._isIMEInputApply = !1, this._eventHandle(e, (t) => {
5560
5560
  this._onCompositionend$.next(t);
5561
5561
  });
5562
5562
  })
5563
5563
  ), this.disposeWithMe(
5564
- je(this._input, "compositionupdate").subscribe((e) => {
5564
+ ze(this._input, "compositionupdate").subscribe((e) => {
5565
5565
  this._eventHandle(e, (t) => {
5566
5566
  this._onInputBefore$.next(t), this._onCompositionupdate$.next(t);
5567
5567
  });
5568
5568
  })
5569
5569
  ), this.disposeWithMe(
5570
- je(this._input, "paste").subscribe((e) => {
5570
+ ze(this._input, "paste").subscribe((e) => {
5571
5571
  this._eventHandle(e, (t) => {
5572
5572
  this._onPaste$.next(t);
5573
5573
  });
5574
5574
  })
5575
5575
  ), this.disposeWithMe(
5576
- je(this._input, "focus").subscribe((e) => {
5576
+ ze(this._input, "focus").subscribe((e) => {
5577
5577
  this._eventHandle(e, (t) => {
5578
5578
  this._onFocus$.next(t);
5579
5579
  });
5580
5580
  })
5581
5581
  ), this.disposeWithMe(
5582
- je(this._input, "blur").subscribe((e) => {
5582
+ ze(this._input, "blur").subscribe((e) => {
5583
5583
  this._eventHandle(e, (t) => {
5584
5584
  this._onBlur$.next(t);
5585
5585
  });
@@ -5627,12 +5627,12 @@ let Re = class extends Ct {
5627
5627
  }
5628
5628
  };
5629
5629
  Re = gA([
5630
- Vn(1, Oo),
5630
+ Vn(1, To),
5631
5631
  Vn(2, Qr),
5632
5632
  Vn(3, L),
5633
- Vn(4, j(de))
5633
+ Vn(4, z(de))
5634
5634
  ], Re);
5635
- const ko = {
5635
+ const Vo = {
5636
5636
  id: "doc.command.switch-mode",
5637
5637
  type: D.COMMAND,
5638
5638
  // eslint-disable-next-line max-lines-per-function, complexity
@@ -5681,7 +5681,7 @@ const ko = {
5681
5681
  }
5682
5682
  return u.params.actions = f.reduce((b, x) => W.compose(b, x), null), !!e.syncExecuteCommand(u.id, u.params);
5683
5683
  }
5684
- }, fA = "doc.command.create-table", ja = {
5684
+ }, fA = "doc.command.create-table", za = {
5685
5685
  id: fA,
5686
5686
  type: D.COMMAND,
5687
5687
  // eslint-disable-next-line max-lines-per-function
@@ -5722,7 +5722,7 @@ const ko = {
5722
5722
  },
5723
5723
  len: 1
5724
5724
  });
5725
- const B = a.getDefaultStyle(), y = a.getStyleCache(), M = Bo(
5725
+ const B = a.getDefaultStyle(), y = a.getStyleCache(), M = Mo(
5726
5726
  h,
5727
5727
  p,
5728
5728
  B,
@@ -5903,11 +5903,11 @@ const ko = {
5903
5903
  }, vs = "doc.command.table-insert-row", Cs = "doc.command.table-insert-column", pA = "doc.command.table-insert-row-above", mA = "doc.command.table-insert-row-bellow", EA = "doc.command.table-insert-column-left", IA = "doc.command.table-insert-column-right", Rs = {
5904
5904
  id: pA,
5905
5905
  type: D.COMMAND,
5906
- handler: async (n) => n.get(T).executeCommand(vs, { position: _o.ABOVE })
5906
+ handler: async (n) => n.get(T).executeCommand(vs, { position: Do.ABOVE })
5907
5907
  }, bs = {
5908
5908
  id: mA,
5909
5909
  type: D.COMMAND,
5910
- handler: async (n) => n.get(T).executeCommand(vs, { position: _o.BELLOW })
5910
+ handler: async (n) => n.get(T).executeCommand(vs, { position: Do.BELLOW })
5911
5911
  }, xs = {
5912
5912
  id: EA,
5913
5913
  type: D.COMMAND,
@@ -5916,7 +5916,7 @@ const ko = {
5916
5916
  id: IA,
5917
5917
  type: D.COMMAND,
5918
5918
  handler: async (n) => n.get(T).executeCommand(Cs, { position: Yr.RIGHT })
5919
- }, za = {
5919
+ }, ja = {
5920
5920
  id: vs,
5921
5921
  type: D.COMMAND,
5922
5922
  // eslint-disable-next-line max-lines-per-function
@@ -6035,22 +6035,22 @@ const ko = {
6035
6035
  }];
6036
6036
  return o.replaceDocRanges(m), !0;
6037
6037
  }
6038
- return t === !1 ? await s.executeCommand(za.id, {
6039
- position: _o.BELLOW
6038
+ return t === !1 ? await s.executeCommand(ja.id, {
6039
+ position: Do.BELLOW
6040
6040
  }) : !0;
6041
6041
  }
6042
- }, Ya = "COMPONENT_DOC_CREATE_TABLE_CONFIRM", $o = "doc.component.create-table-confirm", Os = {
6042
+ }, Ya = "COMPONENT_DOC_CREATE_TABLE_CONFIRM", er = "doc.component.create-table-confirm", Os = {
6043
6043
  id: "doc.operation.create-table",
6044
6044
  type: D.COMMAND,
6045
6045
  handler: async (n) => {
6046
- const e = n.get(Ye), t = n.get(ca), o = n.get(T), r = {
6046
+ const e = n.get(Ye), t = n.get(Xi), o = n.get(T), r = {
6047
6047
  rowCount: 3,
6048
6048
  colCount: 5
6049
6049
  }, s = (i, a) => {
6050
6050
  r.rowCount = i, r.colCount = a;
6051
6051
  };
6052
6052
  return await t.open({
6053
- id: $o,
6053
+ id: er,
6054
6054
  children: {
6055
6055
  label: {
6056
6056
  name: Ya,
@@ -6063,10 +6063,10 @@ const ko = {
6063
6063
  width: "auto",
6064
6064
  title: { title: e.t("toolbar.table.insert") },
6065
6065
  onConfirm: () => {
6066
- o.executeCommand(ja.id, r), t.close($o);
6066
+ o.executeCommand(za.id, r), t.close(er);
6067
6067
  },
6068
6068
  onClose: () => {
6069
- t.close($o);
6069
+ t.close(er);
6070
6070
  }
6071
6071
  }), !0;
6072
6072
  }
@@ -7050,7 +7050,7 @@ let Sr = class extends me {
7050
7050
  // I moved from the layout service. https://github.com/dream-num/univer-pro/issues/1708
7051
7051
  _initUniverFocusListener() {
7052
7052
  this.disposeWithMe(
7053
- je(window, "focusin").subscribe((e) => {
7053
+ ze(window, "focusin").subscribe((e) => {
7054
7054
  const t = e.target;
7055
7055
  this._blurSheetEditor(t);
7056
7056
  })
@@ -7141,7 +7141,7 @@ let Sr = class extends me {
7141
7141
  return {
7142
7142
  id: e,
7143
7143
  body: {
7144
- dataStream: `${Xi}`,
7144
+ dataStream: `${Zi}`,
7145
7145
  textRuns: [],
7146
7146
  paragraphs: [
7147
7147
  {
@@ -7164,14 +7164,14 @@ let Sr = class extends me {
7164
7164
  Sr = VA([
7165
7165
  Ot(0, L),
7166
7166
  Ot(1, pe),
7167
- Ot(2, j(Y)),
7167
+ Ot(2, z(Y)),
7168
7168
  Ot(3, Fr),
7169
7169
  Ot(4, T),
7170
- Ot(5, xo),
7171
- Ot(6, j(Dn))
7170
+ Ot(5, yo),
7171
+ Ot(6, z(Dn))
7172
7172
  ], Sr);
7173
7173
  const Ge = Ki("univer.editor.service"), vr = "COMPONENT_DOC_HEADER_FOOTER_PANEL";
7174
- function jA(n, e, t) {
7174
+ function zA(n, e, t) {
7175
7175
  const {
7176
7176
  useFirstPageHeaderFooter: o,
7177
7177
  evenAndOddHeaders: r,
@@ -7182,14 +7182,14 @@ function jA(n, e, t) {
7182
7182
  evenPageHeaderId: d,
7183
7183
  evenPageFooterId: l
7184
7184
  } = n;
7185
- return e === ve.HEADER ? o === z.TRUE ? t === 0 ? a : r === z.TRUE && t % 2 === 1 ? d : s : r === z.TRUE && t % 2 === 1 ? d : s : o === z.TRUE ? t === 0 ? c : r === z.TRUE && t % 2 === 1 ? l : i : r === z.TRUE && t % 2 === 1 ? l : i;
7185
+ return e === ve.HEADER ? o === j.TRUE ? t === 0 ? a : r === j.TRUE && t % 2 === 1 ? d : s : r === j.TRUE && t % 2 === 1 ? d : s : o === j.TRUE ? t === 0 ? c : r === j.TRUE && t % 2 === 1 ? l : i : r === j.TRUE && t % 2 === 1 ? l : i;
7186
7186
  }
7187
- const zA = (n) => {
7188
- const e = J(Ye), t = J(L), o = J(pe), r = J(T), s = J(Oo), { unitId: i } = n, a = o.getRenderById(i).with(Re), [c, d] = Ee({}), l = (u, g) => {
7187
+ const jA = (n) => {
7188
+ const e = J(Ye), t = J(L), o = J(pe), r = J(T), s = J(To), { unitId: i } = n, a = o.getRenderById(i).with(Re), [c, d] = Ee({}), l = (u, g) => {
7189
7189
  var b;
7190
7190
  d((x) => ({
7191
7191
  ...x,
7192
- [g]: u ? z.TRUE : z.FALSE
7192
+ [g]: u ? j.TRUE : j.FALSE
7193
7193
  }));
7194
7194
  const f = t.getUniverDocInstance(i), p = f == null ? void 0 : f.getSnapshot().documentStyle, m = (b = o.getRenderById(i)) == null ? void 0 : b.with(de), I = m == null ? void 0 : m.getViewModel();
7195
7195
  if (p == null || I == null)
@@ -7204,14 +7204,14 @@ const zA = (n) => {
7204
7204
  unitId: i,
7205
7205
  segmentId: C,
7206
7206
  headerFooterProps: {
7207
- [g]: u ? z.TRUE : z.FALSE
7207
+ [g]: u ? j.TRUE : j.FALSE
7208
7208
  }
7209
7209
  });
7210
7210
  } else {
7211
- const x = a.getSegmentPage(), C = a.getSegment(), B = jA(
7211
+ const x = a.getSegmentPage(), C = a.getSegment(), B = zA(
7212
7212
  {
7213
7213
  ...p,
7214
- [g]: u ? z.TRUE : z.FALSE
7214
+ [g]: u ? j.TRUE : j.FALSE
7215
7215
  },
7216
7216
  S,
7217
7217
  x
@@ -7219,7 +7219,7 @@ const zA = (n) => {
7219
7219
  B && B !== C && a.setSegment(B), r.executeCommand($n, {
7220
7220
  unitId: i,
7221
7221
  headerFooterProps: {
7222
- [g]: u ? z.TRUE : z.FALSE
7222
+ [g]: u ? j.TRUE : j.FALSE
7223
7223
  }
7224
7224
  });
7225
7225
  }
@@ -7245,8 +7245,8 @@ const zA = (n) => {
7245
7245
  const {
7246
7246
  marginHeader: f = 0,
7247
7247
  marginFooter: p = 0,
7248
- useFirstPageHeaderFooter: m = z.FALSE,
7249
- evenAndOddHeaders: I = z.FALSE
7248
+ useFirstPageHeaderFooter: m = j.FALSE,
7249
+ evenAndOddHeaders: I = j.FALSE
7250
7250
  } = g;
7251
7251
  d({
7252
7252
  marginHeader: f,
@@ -7260,7 +7260,7 @@ const zA = (n) => {
7260
7260
  /* @__PURE__ */ Q("div", { children: /* @__PURE__ */ Q(
7261
7261
  Zs,
7262
7262
  {
7263
- checked: c.useFirstPageHeaderFooter === z.TRUE,
7263
+ checked: c.useFirstPageHeaderFooter === j.TRUE,
7264
7264
  onChange: (u) => {
7265
7265
  l(u, "useFirstPageHeaderFooter");
7266
7266
  },
@@ -7270,7 +7270,7 @@ const zA = (n) => {
7270
7270
  /* @__PURE__ */ Q("div", { children: /* @__PURE__ */ Q(
7271
7271
  Zs,
7272
7272
  {
7273
- checked: c.evenAndOddHeaders === z.TRUE,
7273
+ checked: c.evenAndOddHeaders === j.TRUE,
7274
7274
  onChange: (u) => {
7275
7275
  l(u, "evenAndOddHeaders");
7276
7276
  },
@@ -7326,15 +7326,15 @@ const zA = (n) => {
7326
7326
  return () => {
7327
7327
  A.unsubscribe();
7328
7328
  };
7329
- }, []), /* @__PURE__ */ Q("div", { className: "univer-text-sm", children: a ? /* @__PURE__ */ Q(zA, { unitId: r }) : /* @__PURE__ */ Q("div", { className: "univer-text-gray-400", children: n.t("headerFooter.disableText") }) });
7330
- }, Si = 18, vi = 200, er = 6, YA = 4;
7329
+ }, []), /* @__PURE__ */ Q("div", { className: "univer-text-sm", children: a ? /* @__PURE__ */ Q(jA, { unitId: r }) : /* @__PURE__ */ Q("div", { className: "univer-text-gray-400", children: n.t("headerFooter.disableText") }) });
7330
+ }, Si = 18, vi = 200, tr = 6, YA = 4;
7331
7331
  function KA(n, e) {
7332
7332
  let { radius: t, width: o, height: r } = e;
7333
7333
  t = t != null ? t : 0, o = o != null ? o : 30, r = r != null ? r : 30;
7334
7334
  let s = 0;
7335
7335
  s = Math.min(t, o / 2, r / 2), n.beginPath(), n.moveTo(0, 0), n.lineTo(o, 0), n.lineTo(o, r - s), n.arc(o - s, r - s, s, 0, Math.PI / 2, !1), n.lineTo(0, r), n.lineTo(0, 0), n.closePath(), e.fill && (n.save(), n.fillStyle = e.fill, e.fillRule === "evenodd" ? n.fill("evenodd") : n.fill(), n.restore());
7336
7336
  }
7337
- class ao extends ul {
7337
+ class co extends ul {
7338
7338
  constructor(t, o) {
7339
7339
  super(t, o);
7340
7340
  O(this, "color");
@@ -7345,7 +7345,7 @@ class ao extends ul {
7345
7345
  const { text: r, color: s } = o;
7346
7346
  t.save(), t.font = "13px Source Han Sans CN";
7347
7347
  const i = t.measureText(r).width, a = Math.min(
7348
- i + 2 * er,
7348
+ i + 2 * tr,
7349
7349
  vi
7350
7350
  );
7351
7351
  KA(t, {
@@ -7354,7 +7354,7 @@ class ao extends ul {
7354
7354
  radius: 4,
7355
7355
  fill: s
7356
7356
  }), t.fillStyle = "rgba(58, 96, 247, 1)";
7357
- const c = er, d = Si - YA, l = vi - 2 * er;
7357
+ const c = tr, d = Si - YA, l = vi - 2 * tr;
7358
7358
  if (i > l) {
7359
7359
  let A = "", h = 0;
7360
7360
  for (const u of r) {
@@ -7372,7 +7372,7 @@ class ao extends ul {
7372
7372
  t.restore();
7373
7373
  }
7374
7374
  _draw(t) {
7375
- ao.drawWith(t, this);
7375
+ co.drawWith(t, this);
7376
7376
  }
7377
7377
  }
7378
7378
  var qA = Object.getOwnPropertyDescriptor, XA = (n, e, t, o) => {
@@ -7400,10 +7400,10 @@ function ZA(n, e, t) {
7400
7400
  headerFooterId: null
7401
7401
  };
7402
7402
  case ve.HEADER:
7403
- return A === z.TRUE && !c ? {
7403
+ return A === j.TRUE && !c ? {
7404
7404
  createType: 0,
7405
7405
  headerFooterId: null
7406
- } : l === z.TRUE && t % 2 === 0 && !i ? {
7406
+ } : l === j.TRUE && t % 2 === 0 && !i ? {
7407
7407
  createType: 4,
7408
7408
  headerFooterId: null
7409
7409
  } : r ? {
@@ -7414,10 +7414,10 @@ function ZA(n, e, t) {
7414
7414
  headerFooterId: null
7415
7415
  };
7416
7416
  case ve.FOOTER:
7417
- return A === z.TRUE && !d ? {
7417
+ return A === j.TRUE && !d ? {
7418
7418
  createType: 1,
7419
7419
  headerFooterId: null
7420
- } : l === z.TRUE && t % 2 === 0 && !a ? {
7420
+ } : l === j.TRUE && t % 2 === 0 && !a ? {
7421
7421
  createType: 5,
7422
7422
  headerFooterId: null
7423
7423
  } : s ? {
@@ -7562,10 +7562,10 @@ let Cr = class extends me {
7562
7562
  strokeWidth: 1,
7563
7563
  stroke: Ci
7564
7564
  };
7565
- zs.drawWith(g, S), zs.drawWith(g, v), g.translate(0, m + 1), ao.drawWith(g, {
7565
+ js.drawWith(g, S), js.drawWith(g, v), g.translate(0, m + 1), co.drawWith(g, {
7566
7566
  text: e.t("headerFooter.header"),
7567
7567
  color: Ri
7568
- }), g.translate(0, p - m - I), ao.drawWith(g, {
7568
+ }), g.translate(0, p - m - I), co.drawWith(g, {
7569
7569
  text: e.t("headerFooter.footer"),
7570
7570
  color: Ri
7571
7571
  });
@@ -7590,10 +7590,10 @@ Cr = XA([
7590
7590
  ut(2, Ge),
7591
7591
  ut(3, L),
7592
7592
  ut(4, pe),
7593
- ut(5, j(de)),
7594
- ut(6, j(Re)),
7595
- ut(7, j(Ye)),
7596
- ut(8, j(rn))
7593
+ ut(5, z(de)),
7594
+ ut(6, z(Re)),
7595
+ ut(7, z(Ye)),
7596
+ ut(8, z(rn))
7597
7597
  ], Cr);
7598
7598
  const Ts = {
7599
7599
  id: "sidebar.operation.doc-header-footer-panel",
@@ -7648,7 +7648,7 @@ function bi() {
7648
7648
  ]
7649
7649
  };
7650
7650
  }
7651
- function tr(n, e, t, o) {
7651
+ function nr(n, e, t, o) {
7652
7652
  const r = W.getInstance(), s = 6, i = n != null ? n : ge(s), a = e === Qe.DEFAULT_HEADER || e === Qe.FIRST_PAGE_HEADER || e === Qe.EVEN_PAGE_HEADER, c = r.insertOp([a ? "headers" : "footers", i], {
7653
7653
  [a ? "headerId" : "footerId"]: i,
7654
7654
  body: bi()
@@ -7716,17 +7716,17 @@ const $n = "doc.command.core-header-footer", Ac = {
7716
7716
  };
7717
7717
  g && (p.params.noNeedSetTextRange = !0);
7718
7718
  const m = W.getInstance(), I = [];
7719
- return a != null && tr(i, a, u, I), c != null && Object.keys(c).forEach((R) => {
7719
+ return a != null && nr(i, a, u, I), c != null && Object.keys(c).forEach((R) => {
7720
7720
  const E = c[R], b = u[R];
7721
7721
  if (E === b)
7722
7722
  return;
7723
7723
  let x;
7724
- if (b === void 0 ? x = m.insertOp(["documentStyle", R], E) : x = m.replaceOp(["documentStyle", R], b, E), I.push(x), R === "useFirstPageHeaderFooter" && E === z.TRUE && !u.firstPageHeaderId) {
7724
+ if (b === void 0 ? x = m.insertOp(["documentStyle", R], E) : x = m.replaceOp(["documentStyle", R], b, E), I.push(x), R === "useFirstPageHeaderFooter" && E === j.TRUE && !u.firstPageHeaderId) {
7725
7725
  const C = h === ve.HEADER ? Qe.FIRST_PAGE_HEADER : Qe.FIRST_PAGE_FOOTER;
7726
- tr(i, C, u, I);
7727
- } else if (R === "evenAndOddHeaders" && E === z.TRUE && !u.evenPageHeaderId) {
7726
+ nr(i, C, u, I);
7727
+ } else if (R === "evenAndOddHeaders" && E === j.TRUE && !u.evenPageHeaderId) {
7728
7728
  const C = h === ve.HEADER ? Qe.EVEN_PAGE_HEADER : Qe.EVEN_PAGE_FOOTER;
7729
- tr(i, C, u, I);
7729
+ nr(i, C, u, I);
7730
7730
  }
7731
7731
  }), I.length === 0 ? !1 : (p.params.actions = I.reduce((R, E) => W.compose(R, E), null), !!t.syncExecuteCommand(p.id, p.params));
7732
7732
  }
@@ -7761,7 +7761,7 @@ const $n = "doc.command.core-header-footer", Ac = {
7761
7761
  return /* @__PURE__ */ Q("div", { className: "univer-grid univer-grid-cols-3 univer-gap-2 univer-p-1.5", children: o.map((r) => /* @__PURE__ */ Q(
7762
7762
  "a",
7763
7763
  {
7764
- className: ze("univer-block univer-h-20 univer-w-[72px] univer-cursor-pointer univer-overflow-hidden univer-rounded univer-transition-all hover:univer-border-primary-500", Nn, {
7764
+ className: je("univer-block univer-h-20 univer-w-[72px] univer-cursor-pointer univer-overflow-hidden univer-rounded univer-transition-all hover:univer-border-primary-500", Nn, {
7765
7765
  "univer-border-primary-500": e === r.value
7766
7766
  }),
7767
7767
  onClick: () => {
@@ -7841,23 +7841,27 @@ const $n = "doc.command.core-header-footer", Ac = {
7841
7841
  options: eu
7842
7842
  }
7843
7843
  ), gc = `${uc}_ORDER_LIST_TYPE_COMPONENT`, fc = `${uc}_BULLET_LIST_TYPE_COMPONENT`, nu = (n) => {
7844
- const t = Object.keys(ar).find((o) => {
7845
- const { width: r, height: s } = ar[o];
7844
+ const t = Object.keys(to).find((o) => {
7845
+ const { width: r, height: s } = to[o];
7846
7846
  return n.width === r && n.height === s;
7847
7847
  });
7848
7848
  return t != null ? t : "A4";
7849
7849
  };
7850
7850
  function ou(n) {
7851
7851
  const { hooks: e } = n, r = J(L).getCurrentUnitOfType(_.UNIVER_DOC).getDocumentStyle(), s = J(Ye), [i, a] = Ee(() => {
7852
- var l, A, h, u, g;
7852
+ var l, A, h, u, g, f, p, m, I;
7853
7853
  return {
7854
7854
  paperSize: nu(r.pageSize),
7855
- orientation: (l = r.pageOrient) != null ? l : Wc.PORTRAIT,
7855
+ pageSise: {
7856
+ width: (A = (l = r.pageSize) == null ? void 0 : l.width) != null ? A : 0,
7857
+ height: (u = (h = r.pageSize) == null ? void 0 : h.height) != null ? u : 0
7858
+ },
7859
+ orientation: (g = r.pageOrient) != null ? g : Wc.PORTRAIT,
7856
7860
  margins: {
7857
- top: (A = r.marginTop) != null ? A : 0,
7858
- bottom: (h = r.marginBottom) != null ? h : 0,
7859
- left: (u = r.marginLeft) != null ? u : 0,
7860
- right: (g = r.marginRight) != null ? g : 0
7861
+ top: (f = r.marginTop) != null ? f : 0,
7862
+ bottom: (p = r.marginBottom) != null ? p : 0,
7863
+ left: (m = r.marginLeft) != null ? m : 0,
7864
+ right: (I = r.marginRight) != null ? I : 0
7861
7865
  }
7862
7866
  };
7863
7867
  });
@@ -7865,7 +7869,7 @@ function ou(n) {
7865
7869
  e.beforeClose = () => i, e.beforeConfirm = () => i;
7866
7870
  }, [i]);
7867
7871
  const c = (l) => {
7868
- a((A) => ({ ...A, paperSize: l }));
7872
+ a((A) => ({ ...A, paperSize: l, pageSise: to[l] }));
7869
7873
  }, d = (l, A) => {
7870
7874
  a((h) => ({
7871
7875
  ...h,
@@ -7889,7 +7893,7 @@ function ou(n) {
7889
7893
  {
7890
7894
  value: i.paperSize,
7891
7895
  onChange: c,
7892
- options: jc.map((l) => ({
7896
+ options: zc.map((l) => ({
7893
7897
  label: s.t(`page-settings.page-size.${l.toLocaleLowerCase()}`),
7894
7898
  value: l
7895
7899
  }))
@@ -7911,6 +7915,8 @@ function ou(n) {
7911
7915
  /* @__PURE__ */ Q(
7912
7916
  it,
7913
7917
  {
7918
+ precision: 2,
7919
+ max: i.pageSise.height / 2,
7914
7920
  value: i.margins.top,
7915
7921
  onChange: (l) => d("top", l)
7916
7922
  }
@@ -7921,6 +7927,8 @@ function ou(n) {
7921
7927
  /* @__PURE__ */ Q(
7922
7928
  it,
7923
7929
  {
7930
+ precision: 2,
7931
+ max: i.pageSise.height / 2,
7924
7932
  value: i.margins.bottom,
7925
7933
  onChange: (l) => d("bottom", l)
7926
7934
  }
@@ -7933,6 +7941,8 @@ function ou(n) {
7933
7941
  /* @__PURE__ */ Q(
7934
7942
  it,
7935
7943
  {
7944
+ precision: 2,
7945
+ max: i.pageSise.width / 2,
7936
7946
  value: i.margins.left,
7937
7947
  onChange: (l) => d("left", l)
7938
7948
  }
@@ -7943,6 +7953,8 @@ function ou(n) {
7943
7953
  /* @__PURE__ */ Q(
7944
7954
  it,
7945
7955
  {
7956
+ precision: 2,
7957
+ max: i.pageSise.width / 2,
7946
7958
  value: i.margins.right,
7947
7959
  onChange: (l) => d("right", l)
7948
7960
  }
@@ -8025,7 +8037,7 @@ const Rr = "docs.component.page-setting", pc = {
8025
8037
  id: "docs.operation.open-page-setting",
8026
8038
  type: D.OPERATION,
8027
8039
  handler: (n) => {
8028
- const e = n.get(ca), t = n.get(T), o = n.get(Ye), r = e.open({
8040
+ const e = n.get(Xi), t = n.get(T), o = n.get(Ye), r = e.open({
8029
8041
  id: Rr,
8030
8042
  title: {
8031
8043
  label: o.t("page-settings.document-setting")
@@ -8039,7 +8051,7 @@ const Rr = "docs.component.page-setting", pc = {
8039
8051
  },
8040
8052
  onConfirm: (s) => {
8041
8053
  if (r.dispose(), !s) return;
8042
- const i = ar[s.paperSize];
8054
+ const i = to[s.paperSize];
8043
8055
  t.executeCommand(pc.id, {
8044
8056
  pageOrient: s.orientation,
8045
8057
  marginTop: s.margins.top,
@@ -8177,7 +8189,7 @@ function au(n) {
8177
8189
  return;
8178
8190
  }
8179
8191
  const i = (a = s.ts) == null ? void 0 : a.bl;
8180
- t.next(i === z.TRUE);
8192
+ t.next(i === j.TRUE);
8181
8193
  }, r = e.onCommandExecuted((s) => {
8182
8194
  const i = s.id;
8183
8195
  (i === Le.id || i === xt.id) && o();
@@ -8205,7 +8217,7 @@ function cu(n) {
8205
8217
  return;
8206
8218
  }
8207
8219
  const i = (a = s.ts) == null ? void 0 : a.it;
8208
- t.next(i === z.TRUE);
8220
+ t.next(i === j.TRUE);
8209
8221
  }, r = e.onCommandExecuted((s) => {
8210
8222
  const i = s.id;
8211
8223
  (i === Le.id || i === xt.id) && o();
@@ -8233,7 +8245,7 @@ function lu(n) {
8233
8245
  return;
8234
8246
  }
8235
8247
  const i = (a = s.ts) == null ? void 0 : a.ul;
8236
- t.next((i == null ? void 0 : i.s) === z.TRUE);
8248
+ t.next((i == null ? void 0 : i.s) === j.TRUE);
8237
8249
  }, r = e.onCommandExecuted((s) => {
8238
8250
  const i = s.id;
8239
8251
  (i === Le.id || i === xt.id) && o();
@@ -8261,7 +8273,7 @@ function du(n) {
8261
8273
  return;
8262
8274
  }
8263
8275
  const i = (a = s.ts) == null ? void 0 : a.st;
8264
- t.next((i == null ? void 0 : i.s) === z.TRUE);
8276
+ t.next((i == null ? void 0 : i.s) === j.TRUE);
8265
8277
  }, r = e.onCommandExecuted((s) => {
8266
8278
  const i = s.id;
8267
8279
  (i === Le.id || i === xt.id) && o();
@@ -8345,7 +8357,7 @@ function hu(n) {
8345
8357
  }],
8346
8358
  // disabled$: getCurrentSheetDisabled$(accessor),
8347
8359
  value$: new fe((t) => {
8348
- const o = yo.ff, r = () => {
8360
+ const o = Oo.ff, r = () => {
8349
8361
  var c;
8350
8362
  const i = ot(n);
8351
8363
  if (i == null) {
@@ -8381,7 +8393,7 @@ function gu(n) {
8381
8393
  selections: Bl,
8382
8394
  // disabled$,
8383
8395
  value$: new fe((t) => {
8384
- const o = yo.fs, r = () => {
8396
+ const o = Oo.fs, r = () => {
8385
8397
  var c;
8386
8398
  const i = ot(n);
8387
8399
  if (i == null) {
@@ -8457,7 +8469,7 @@ function pu(n) {
8457
8469
  selectable: !1
8458
8470
  },
8459
8471
  value$: new fe((o) => {
8460
- const r = yo.cl.rgb, s = () => {
8472
+ const r = Oo.cl.rgb, s = () => {
8461
8473
  var d, l;
8462
8474
  const a = ot(n);
8463
8475
  if (!a) {
@@ -8519,7 +8531,7 @@ function Su(n) {
8519
8531
  function vu(n) {
8520
8532
  const e = n.get(T);
8521
8533
  return {
8522
- id: Qo.id,
8534
+ id: Uo.id,
8523
8535
  type: Z.BUTTON,
8524
8536
  icon: "LeftJustifyingIcon",
8525
8537
  tooltip: "toolbar.alignLeft",
@@ -8544,7 +8556,7 @@ function vu(n) {
8544
8556
  function Cu(n) {
8545
8557
  const e = n.get(T);
8546
8558
  return {
8547
- id: Uo.id,
8559
+ id: Fo.id,
8548
8560
  type: Z.BUTTON,
8549
8561
  icon: "HorizontallyIcon",
8550
8562
  tooltip: "toolbar.alignCenter",
@@ -8569,7 +8581,7 @@ function Cu(n) {
8569
8581
  function Ru(n) {
8570
8582
  const e = n.get(T);
8571
8583
  return {
8572
- id: Fo.id,
8584
+ id: Ho.id,
8573
8585
  type: Z.BUTTON,
8574
8586
  icon: "RightJustifyingIcon",
8575
8587
  tooltip: "toolbar.alignRight",
@@ -8594,7 +8606,7 @@ function Ru(n) {
8594
8606
  function bu(n) {
8595
8607
  const e = n.get(T);
8596
8608
  return {
8597
- id: Ho.id,
8609
+ id: ko.id,
8598
8610
  type: Z.BUTTON,
8599
8611
  icon: "AlignTextBothIcon",
8600
8612
  tooltip: "toolbar.alignJustify",
@@ -8618,7 +8630,7 @@ function bu(n) {
8618
8630
  }
8619
8631
  function xu(n) {
8620
8632
  return {
8621
- id: wo.id,
8633
+ id: No.id,
8622
8634
  type: Z.BUTTON,
8623
8635
  icon: "ReduceIcon",
8624
8636
  tooltip: "toolbar.horizontalLine",
@@ -8700,7 +8712,7 @@ function yi(n) {
8700
8712
  }
8701
8713
  function Oi(n) {
8702
8714
  return {
8703
- id: so.id,
8715
+ id: io.id,
8704
8716
  type: Z.BUTTON,
8705
8717
  icon: "TodoListDoubleIcon",
8706
8718
  tooltip: "toolbar.checklist",
@@ -8712,7 +8724,7 @@ function Oi(n) {
8712
8724
  function yu(n) {
8713
8725
  const e = n.get(T), t = n.get(L);
8714
8726
  return {
8715
- id: ko.id,
8727
+ id: Vo.id,
8716
8728
  type: Z.BUTTON,
8717
8729
  icon: "KeyboardIcon",
8718
8730
  tooltip: "toolbar.documentFlavor",
@@ -8753,7 +8765,7 @@ function Tu(n) {
8753
8765
  selectable: !1
8754
8766
  },
8755
8767
  value$: new fe((o) => {
8756
- const r = yo.bg.rgb, s = () => {
8768
+ const r = Oo.bg.rgb, s = () => {
8757
8769
  var d, l;
8758
8770
  const a = ot(n);
8759
8771
  if (!a) {
@@ -8784,7 +8796,7 @@ function Tu(n) {
8784
8796
  }
8785
8797
  function ot(n) {
8786
8798
  var g, f, p, m;
8787
- const e = n.get(L), t = n.get(Y), o = n.get(at), r = e.getCurrentUnitForType(_.UNIVER_DOC), s = t.getDocRanges(), i = (g = s.find((I) => I.isActive)) != null ? g : s[0], a = o.getDefaultStyle(), c = (f = o.getStyleCache()) != null ? f : {}, d = Vt(n), l = (p = d == null ? void 0 : d.paragraphStyle) != null && p.namedStyleType ? zc[(m = d == null ? void 0 : d.paragraphStyle) == null ? void 0 : m.namedStyleType] : null;
8799
+ const e = n.get(L), t = n.get(Y), o = n.get(at), r = e.getCurrentUnitForType(_.UNIVER_DOC), s = t.getDocRanges(), i = (g = s.find((I) => I.isActive)) != null ? g : s[0], a = o.getDefaultStyle(), c = (f = o.getStyleCache()) != null ? f : {}, d = Vt(n), l = (p = d == null ? void 0 : d.paragraphStyle) != null && p.namedStyleType ? jc[(m = d == null ? void 0 : d.paragraphStyle) == null ? void 0 : m.namedStyleType] : null;
8788
8800
  if (r == null || i == null)
8789
8801
  return {
8790
8802
  ts: {
@@ -8844,10 +8856,10 @@ const Mu = {
8844
8856
  [K.HEADING_3]: gs,
8845
8857
  [K.HEADING_4]: fs,
8846
8858
  [K.HEADING_5]: ps,
8847
- [K.NORMAL_TEXT]: io,
8859
+ [K.NORMAL_TEXT]: ao,
8848
8860
  [K.TITLE]: Ua,
8849
8861
  [K.SUBTITLE]: Fa,
8850
- [K.NAMED_STYLE_TYPE_UNSPECIFIED]: io
8862
+ [K.NAMED_STYLE_TYPE_UNSPECIFIED]: ao
8851
8863
  }, Ec = {
8852
8864
  [K.HEADING_1]: { key: "H1Icon", component: ec },
8853
8865
  [K.HEADING_2]: { key: "H2Icon", component: tc },
@@ -8923,7 +8935,7 @@ const Qu = (n) => ({
8923
8935
  icon: "ReduceIcon",
8924
8936
  title: "toolbar.horizontalLine"
8925
8937
  }), Ic = "doc.menu.insert-bellow";
8926
- function ju(n) {
8938
+ function zu(n) {
8927
8939
  return {
8928
8940
  id: Ic,
8929
8941
  type: Z.SUBITEMS,
@@ -8931,8 +8943,8 @@ function ju(n) {
8931
8943
  };
8932
8944
  }
8933
8945
  const Ti = 4;
8934
- var zu = Object.getOwnPropertyDescriptor, Gu = (n, e, t, o) => {
8935
- for (var r = o > 1 ? void 0 : o ? zu(e, t) : e, s = n.length - 1, i; s >= 0; s--)
8946
+ var ju = Object.getOwnPropertyDescriptor, Gu = (n, e, t, o) => {
8947
+ for (var r = o > 1 ? void 0 : o ? ju(e, t) : e, s = n.length - 1, i; s >= 0; s--)
8936
8948
  (i = n[s]) && (r = i(r) || r);
8937
8949
  return r;
8938
8950
  }, Wn = (n, e) => (t, o) => e(t, o, n);
@@ -8971,11 +8983,11 @@ function Mi(n, e, t) {
8971
8983
  y: d
8972
8984
  };
8973
8985
  }
8974
- const nr = (n, e) => {
8986
+ const or = (n, e) => {
8975
8987
  const { scene: t, mainComponent: o, engine: r } = e, s = e.with(de).getSkeleton(), i = s.findNodePositionByCharIndex(n.startOffset, !0, n.segmentId, n.segmentPage), a = n.collapsed ? n.startOffset : n.endOffset - 1, c = s.findNodePositionByCharIndex(a, !0, n.segmentId, n.segmentPage), d = o;
8976
8988
  if (!c || !i)
8977
8989
  return;
8978
- const l = d.getOffsetConfig(), { docsLeft: A, docsTop: h } = l, u = r.getCanvasElement(), g = u.getBoundingClientRect(), f = na(u.style.width), { top: p, left: m, width: I } = g, S = I / f, { scaleX: v, scaleY: R } = t.getAncestorScale(), E = new It(l, s), { borderBoxPointGroup: b } = E.getRangePointData(i, c);
8990
+ const l = d.getOffsetConfig(), { docsLeft: A, docsTop: h } = l, u = r.getCanvasElement(), g = u.getBoundingClientRect(), f = oa(u.style.width), { top: p, left: m, width: I } = g, S = I / f, { scaleX: v, scaleY: R } = t.getAncestorScale(), E = new It(l, s), { borderBoxPointGroup: b } = E.getRangePointData(i, c);
8979
8991
  return Es(b).map((B) => Sc(B, t)).map((B) => ({
8980
8992
  left: (B.left + A * v) * S + m,
8981
8993
  right: (B.right + A * v) * S + m,
@@ -8989,7 +9001,7 @@ let Bn = class extends me {
8989
9001
  }
8990
9002
  _createRectPositionObserver(n, e) {
8991
9003
  const t = () => {
8992
- const { scene: a, engine: c } = e, d = typeof n == "function" ? n() : n, l = c.getCanvasElement(), A = l.getBoundingClientRect(), h = na(l.style.width), u = Sc(d, a), { top: g, left: f, width: p } = A, m = p / h;
9004
+ const { scene: a, engine: c } = e, d = typeof n == "function" ? n() : n, l = c.getCanvasElement(), A = l.getBoundingClientRect(), h = oa(l.style.width), u = Sc(d, a), { top: g, left: f, width: p } = A, m = p / h;
8993
9005
  return {
8994
9006
  left: u.left * m + f,
8995
9007
  right: u.right * m + f,
@@ -9026,16 +9038,16 @@ let Bn = class extends me {
9026
9038
  }
9027
9039
  _createRangePositionObserver(n, e) {
9028
9040
  var i;
9029
- const t = (i = nr(n, e)) != null ? i : [], o = new Fe(t), r = new In();
9041
+ const t = (i = or(n, e)) != null ? i : [], o = new Fe(t), r = new In();
9030
9042
  r.add(this._commandService.onCommandExecuted((a) => {
9031
9043
  if ((a.id === tt.id || a.id === X.id) && a.params.unitId === e.unitId) {
9032
- const d = nr(n, e);
9044
+ const d = or(n, e);
9033
9045
  d && o.next(d);
9034
9046
  }
9035
9047
  }));
9036
9048
  const s = e.scene.getViewport(We.VIEW_MAIN);
9037
9049
  return s && r.add(s.onScrollAfter$.subscribeEvent(() => {
9038
- const a = nr(n, e);
9050
+ const a = or(n, e);
9039
9051
  a && o.next(a);
9040
9052
  })), {
9041
9053
  positions: t,
@@ -9124,7 +9136,7 @@ let Bn = class extends me {
9124
9136
  // #endregion
9125
9137
  };
9126
9138
  Bn = Gu([
9127
- Wn(0, j(Pl)),
9139
+ Wn(0, z(Pl)),
9128
9140
  Wn(1, pe),
9129
9141
  Wn(2, L),
9130
9142
  Wn(3, T)
@@ -9278,7 +9290,7 @@ let wt = class extends me {
9278
9290
  this._customRangeDirty = !0, this._bulletDirty = !0, this._paragraphDirty = !0;
9279
9291
  })), this.disposeWithMe(
9280
9292
  Mt(this._context.engine.onTransformChange$).pipe(
9281
- oo((e) => e.type === oa.resize)
9293
+ ro((e) => e.type === ra.resize)
9282
9294
  ).subscribe(() => {
9283
9295
  this._customRangeDirty = !0, this._bulletDirty = !0, this._paragraphDirty = !0;
9284
9296
  })
@@ -9305,8 +9317,8 @@ let wt = class extends me {
9305
9317
  }));
9306
9318
  const e = Mt(this._context.mainComponent.onPointerDown$), t = Mt(this._context.scene.onPointerUp$);
9307
9319
  this.disposeWithMe(e.pipe(
9308
- Wl((o) => t.pipe(jl(1), Pn((r) => ({ down: o, up: r })))),
9309
- oo(({ down: o, up: r }) => o.target === r.target && r.timeStamp - o.timeStamp < 300)
9320
+ Wl((o) => t.pipe(zl(1), Pn((r) => ({ down: o, up: r })))),
9321
+ ro(({ down: o, up: r }) => o.target === r.target && r.timeStamp - o.timeStamp < 300)
9310
9322
  ).subscribe(({ down: o }) => {
9311
9323
  if (o.button === 2)
9312
9324
  return;
@@ -9552,7 +9564,7 @@ let wt = class extends me {
9552
9564
  }
9553
9565
  };
9554
9566
  wt = Ku([
9555
- qu(1, j(de))
9567
+ qu(1, z(de))
9556
9568
  ], wt);
9557
9569
  const Ju = [
9558
9570
  ct.id,
@@ -9584,7 +9596,7 @@ function $u(n) {
9584
9596
  }, [t]), /* @__PURE__ */ Q(
9585
9597
  "div",
9586
9598
  {
9587
- className: ze("univer-box-border univer-flex univer-rounded univer-bg-white univer-py-1.5 univer-shadow-sm dark:!univer-border-gray-700 dark:!univer-bg-gray-900", Nn),
9599
+ className: je("univer-box-border univer-flex univer-rounded univer-bg-white univer-py-1.5 univer-shadow-sm dark:!univer-border-gray-700 dark:!univer-bg-gray-900", Nn),
9588
9600
  children: o.map((s) => s.item && /* @__PURE__ */ Q("div", { className: "univer-flex univer-flex-nowrap univer-gap-2 univer-px-2", children: /* @__PURE__ */ Q(wl, { ...s.item }, s.key) }, s.key))
9589
9601
  }
9590
9602
  );
@@ -9605,7 +9617,7 @@ const oh = [
9605
9617
  V.CUSTOM_BLOCK,
9606
9618
  V.PARAGRAPH
9607
9619
  ];
9608
- let co = class extends me {
9620
+ let lo = class extends me {
9609
9621
  constructor(e, t, o, r, s, i) {
9610
9622
  super();
9611
9623
  O(this, "_floatMenu", null);
@@ -9666,19 +9678,19 @@ let co = class extends me {
9666
9678
  }, Mn(() => this._hideFloatMenu());
9667
9679
  }
9668
9680
  };
9669
- co = th([
9670
- ln(1, j(Y)),
9671
- ln(2, j(Bn)),
9672
- ln(3, j(rn)),
9673
- ln(4, j(L)),
9674
- ln(5, j(Re))
9675
- ], co);
9681
+ lo = th([
9682
+ ln(1, z(Y)),
9683
+ ln(2, z(Bn)),
9684
+ ln(3, z(rn)),
9685
+ ln(4, z(L)),
9686
+ ln(5, z(Re))
9687
+ ], lo);
9676
9688
  var rh = Object.getOwnPropertyDescriptor, sh = (n, e, t, o) => {
9677
9689
  for (var r = o > 1 ? void 0 : o ? rh(e, t) : e, s = n.length - 1, i; s >= 0; s--)
9678
9690
  (i = n[s]) && (r = i(r) || r);
9679
9691
  return r;
9680
9692
  }, dn = (n, e) => (t, o) => e(t, o, n);
9681
- let lo = class extends me {
9693
+ let Ao = class extends me {
9682
9694
  constructor(e, t, o, r, s, i) {
9683
9695
  super();
9684
9696
  O(this, "_paragrahMenu", null);
@@ -9740,7 +9752,7 @@ let lo = class extends me {
9740
9752
  componentKey: "doc.paragraph.menu",
9741
9753
  direction: "left-center",
9742
9754
  onClickOutside: () => {
9743
- this._docSelectionManagerService.textSelection$.pipe(zl()).subscribe(() => {
9755
+ this._docSelectionManagerService.textSelection$.pipe(jl()).subscribe(() => {
9744
9756
  this._isCursorInActiveParagraph() || this.hideParagraphMenu(!0);
9745
9757
  });
9746
9758
  },
@@ -9758,16 +9770,16 @@ let lo = class extends me {
9758
9770
  this._paragrahMenu && (this._paragrahMenu.disposable.canDispose() || e) && (this._paragrahMenu.disposable.dispose(), this._paragrahMenu = null);
9759
9771
  }
9760
9772
  };
9761
- lo = sh([
9762
- dn(1, j(Y)),
9763
- dn(2, j(wt)),
9764
- dn(3, j(Bn)),
9765
- dn(4, j(de)),
9766
- dn(5, j(co))
9767
- ], lo);
9773
+ Ao = sh([
9774
+ dn(1, z(Y)),
9775
+ dn(2, z(wt)),
9776
+ dn(3, z(Bn)),
9777
+ dn(4, z(de)),
9778
+ dn(5, z(lo))
9779
+ ], Ao);
9768
9780
  const ih = ({ popup: n }) => {
9769
9781
  var E, b;
9770
- const [e, t] = Ee(!1), o = ke(null), r = J(T), s = J(Oo), i = ke(null), a = ke(!1), c = J(pe), d = J(L), l = c.getRenderById(n.unitId), A = d.getUnit(n.unitId, _.UNIVER_DOC), h = l == null ? void 0 : l.with(lo), u = l == null ? void 0 : l.with(wt), g = et(u == null ? void 0 : u.hoverParagraph$), f = et(u == null ? void 0 : u.hoverParagraphLeft$), p = (E = g != null ? g : f) == null ? void 0 : E.startIndex, m = Te(() => {
9782
+ const [e, t] = Ee(!1), o = ke(null), r = J(T), s = J(To), i = ke(null), a = ke(!1), c = J(pe), d = J(L), l = c.getRenderById(n.unitId), A = d.getUnit(n.unitId, _.UNIVER_DOC), h = l == null ? void 0 : l.with(Ao), u = l == null ? void 0 : l.with(wt), g = et(u == null ? void 0 : u.hoverParagraph$), f = et(u == null ? void 0 : u.hoverParagraphLeft$), p = (E = g != null ? g : f) == null ? void 0 : E.startIndex, m = Te(() => {
9771
9783
  var x, C;
9772
9784
  return (C = (x = A == null ? void 0 : A.getBody()) == null ? void 0 : x.paragraphs) == null ? void 0 : C.find((B) => B.startIndex === p);
9773
9785
  }, [A, g]), I = (b = m == null ? void 0 : m.paragraphStyle) == null ? void 0 : b.namedStyleType, S = Ec[I != null ? I : K.NORMAL_TEXT], v = Te(() => new Fe({
@@ -9784,7 +9796,7 @@ const ih = ({ popup: n }) => {
9784
9796
  {
9785
9797
  "data-u-comp": "paragraph-menu",
9786
9798
  ref: i,
9787
- className: ze("univer-mr-1 univer-inline-flex univer-h-7 univer-cursor-pointer univer-items-center univer-gap-1 univer-rounded-full univer-px-2.5 univer-py-0 hover:univer-bg-gray-100 dark:hover:!univer-bg-gray-600", Nn, {
9799
+ className: je("univer-mr-1 univer-inline-flex univer-h-7 univer-cursor-pointer univer-items-center univer-gap-1 univer-rounded-full univer-px-2.5 univer-py-0 hover:univer-bg-gray-100 dark:hover:!univer-bg-gray-600", Nn, {
9788
9800
  "univer-bg-gray-100 dark:!univer-bg-gray-700": e,
9789
9801
  "univer-bg-white dark:!univer-bg-gray-700": !e
9790
9802
  }),
@@ -9845,7 +9857,7 @@ const ih = ({ popup: n }) => {
9845
9857
  Ql,
9846
9858
  {
9847
9859
  style: { width: 212 },
9848
- menuType: no.PARAGRAPH,
9860
+ menuType: oo.PARAGRAPH,
9849
9861
  onOptionSelect: (x) => {
9850
9862
  const { label: C, commandId: B, value: y } = x;
9851
9863
  r && r.executeCommand(B != null ? B : C, { value: y }), s.focus(), R();
@@ -9859,10 +9871,10 @@ const ih = ({ popup: n }) => {
9859
9871
  ] });
9860
9872
  };
9861
9873
  function Se(n) {
9862
- return n.getContextValue(_n) && n.getContextValue(Hr) && !n.getContextValue(Zi);
9874
+ return n.getContextValue(_n) && n.getContextValue(Hr) && !n.getContextValue(Ji);
9863
9875
  }
9864
9876
  function ah(n) {
9865
- return n.getContextValue(_n) && n.getContextValue(Hr) && !n.getContextValue(Zi);
9877
+ return n.getContextValue(_n) && n.getContextValue(Hr) && !n.getContextValue(Ji);
9866
9878
  }
9867
9879
  const ch = {
9868
9880
  id: Jt.id,
@@ -9900,19 +9912,19 @@ const ch = {
9900
9912
  binding: q.PERIOD | te.CTRL_COMMAND,
9901
9913
  preconditions: Se
9902
9914
  }, ph = {
9903
- id: Qo.id,
9915
+ id: Uo.id,
9904
9916
  binding: q.L | te.CTRL_COMMAND | te.SHIFT,
9905
9917
  preconditions: Se
9906
9918
  }, mh = {
9907
- id: Fo.id,
9919
+ id: Ho.id,
9908
9920
  binding: q.R | te.CTRL_COMMAND | te.SHIFT,
9909
9921
  preconditions: Se
9910
9922
  }, Eh = {
9911
- id: Uo.id,
9923
+ id: Fo.id,
9912
9924
  binding: q.E | te.CTRL_COMMAND | te.SHIFT,
9913
9925
  preconditions: Se
9914
9926
  }, Ih = {
9915
- id: Ho.id,
9927
+ id: ko.id,
9916
9928
  binding: q.J | te.CTRL_COMMAND | te.SHIFT,
9917
9929
  preconditions: Se
9918
9930
  }, Sh = {
@@ -9923,7 +9935,7 @@ const ch = {
9923
9935
  id: yn.id,
9924
9936
  binding: q.Digit8 | te.CTRL_COMMAND | te.SHIFT,
9925
9937
  preconditions: Se
9926
- }, Vo = "docs-ui.config", Pi = {
9938
+ }, Wo = "docs-ui.config", Pi = {
9927
9939
  layout: {
9928
9940
  docContainerConfig: rd,
9929
9941
  toolbarConfig: od
@@ -9966,7 +9978,7 @@ function xh(n) {
9966
9978
  }
9967
9979
  function yh() {
9968
9980
  var r, s, i;
9969
- const n = J(L), e = ua(Vo), t = et(() => n.getCurrentTypeOfUnit$(_.UNIVER_SHEET), void 0, void 0, []), o = (i = (s = (r = e == null ? void 0 : e.layout) == null ? void 0 : r.docContainerConfig) == null ? void 0 : s.footer) != null ? i : !0;
9981
+ const n = J(L), e = ua(Wo), t = et(() => n.getCurrentTypeOfUnit$(_.UNIVER_SHEET), void 0, void 0, []), o = (i = (s = (r = e == null ? void 0 : e.layout) == null ? void 0 : r.docContainerConfig) == null ? void 0 : s.footer) != null ? i : !0;
9970
9982
  return t ? null : o && /* @__PURE__ */ re(
9971
9983
  "div",
9972
9984
  {
@@ -9996,12 +10008,12 @@ const Oh = "univer-font-[500] univer-truncate univer-h-[24px] univer-mb-2 univer
9996
10008
  }), []);
9997
10009
  return Kl(e, () => S), Ce(() => {
9998
10010
  c && S.scrollTo(c);
9999
- }, [c, S]), /* @__PURE__ */ re("div", { className: ze("univer-relative", h), style: u, children: [
10011
+ }, [c, S]), /* @__PURE__ */ re("div", { className: je("univer-relative", h), style: u, children: [
10000
10012
  /* @__PURE__ */ Q(
10001
10013
  "div",
10002
10014
  {
10003
10015
  onClick: () => l == null ? void 0 : l(!d),
10004
- className: ze("univer-absolute univer-left-5 univer-top-4 univer-z-[100] univer-flex univer-h-8 univer-w-8 univer-cursor-pointer univer-items-center univer-justify-center univer-rounded-full univer-bg-white univer-text-gray-800 univer-shadow-sm dark:!univer-bg-gray-600 dark:!univer-text-gray-200", g),
10016
+ className: je("univer-absolute univer-left-5 univer-top-4 univer-z-[100] univer-flex univer-h-8 univer-w-8 univer-cursor-pointer univer-items-center univer-justify-center univer-rounded-full univer-bg-white univer-text-gray-800 univer-shadow-sm dark:!univer-bg-gray-600 dark:!univer-text-gray-200", g),
10005
10017
  style: f,
10006
10018
  children: d ? /* @__PURE__ */ Q(ic, {}) : /* @__PURE__ */ Q(Xa, {})
10007
10019
  }
@@ -10009,7 +10021,7 @@ const Oh = "univer-font-[500] univer-truncate univer-h-[24px] univer-mb-2 univer
10009
10021
  /* @__PURE__ */ Q(
10010
10022
  "div",
10011
10023
  {
10012
- className: ze(
10024
+ className: je(
10013
10025
  r,
10014
10026
  `
10015
10027
  univer-absolute univer-left-0 univer-top-0 univer-box-border univer-flex univer-min-w-[180px]
@@ -10031,12 +10043,12 @@ const Oh = "univer-font-[500] univer-truncate univer-h-[24px] univer-mb-2 univer
10031
10043
  "div",
10032
10044
  {
10033
10045
  ref: m,
10034
- className: ze("univer-flex-1 univer-overflow-y-auto univer-overflow-x-hidden", $l),
10046
+ className: je("univer-flex-1 univer-overflow-y-auto univer-overflow-x-hidden", $l),
10035
10047
  children: t == null ? void 0 : t.map((v) => /* @__PURE__ */ Q(
10036
10048
  "div",
10037
10049
  {
10038
10050
  id: `univer-side-menu-${v.id}`,
10039
- className: ze(
10051
+ className: je(
10040
10052
  Oh,
10041
10053
  {
10042
10054
  [Th]: v.isTitle,
@@ -10100,7 +10112,7 @@ function Ph(n, e, t, o) {
10100
10112
  const wi = "__title";
10101
10113
  function wh() {
10102
10114
  var e, t, o;
10103
- const n = ua(Vo);
10115
+ const n = ua(Wo);
10104
10116
  return (o = (t = (e = n == null ? void 0 : n.layout) == null ? void 0 : e.docContainerConfig) == null ? void 0 : t.sideMenu) == null || o ? /* @__PURE__ */ Q(Nh, {}) : null;
10105
10117
  }
10106
10118
  function Nh() {
@@ -10124,7 +10136,7 @@ function Nh() {
10124
10136
  const { paragraphStart: ne, paragraphEnd: ie } = k;
10125
10137
  return {
10126
10138
  id: U.paragraphStyle.headingId,
10127
- text: to(r.slice(ne, ie)),
10139
+ text: no(r.slice(ne, ie)),
10128
10140
  level: H,
10129
10141
  isTitle: ((ae = U.paragraphStyle) == null ? void 0 : ae.namedStyleType) === K.TITLE
10130
10142
  };
@@ -10307,7 +10319,7 @@ const rt = {
10307
10319
  return [t, (s) => (o(s), e.executeCommand(rt.id, {
10308
10320
  paragraph: { spaceAbove: { v: s } }
10309
10321
  }))];
10310
- }, jh = (n) => {
10322
+ }, zh = (n) => {
10311
10323
  const e = J(T), [t, o] = Ee(() => {
10312
10324
  var i;
10313
10325
  const s = n[0];
@@ -10316,7 +10328,7 @@ const rt = {
10316
10328
  return [t, (s) => (o(s), e.executeCommand(rt.id, {
10317
10329
  paragraph: { spaceBelow: { v: s } }
10318
10330
  }))];
10319
- }, zh = (n) => {
10331
+ }, jh = (n) => {
10320
10332
  const e = J(T), t = J(pe), o = J(L), r = Te(() => {
10321
10333
  var g;
10322
10334
  const u = o.getCurrentUnitForType(_.UNIVER_DOC);
@@ -10387,17 +10399,17 @@ function Gh() {
10387
10399
  { label: n.t("toolbar.alignCenter"), value: String(Ue.CENTER), icon: /* @__PURE__ */ Q(sc, {}) },
10388
10400
  { label: n.t("toolbar.alignRight"), value: String(Ue.RIGHT), icon: /* @__PURE__ */ Q(cc, {}) },
10389
10401
  { label: n.t("toolbar.alignJustify"), value: String(Ue.JUSTIFIED), icon: /* @__PURE__ */ Q(qa, {}) }
10390
- ], []), t = Qh(), [o, r] = Uh(t, e[0].value), [s, i] = Fh(t), [a, c] = Hh(t), [d, l] = kh(t), [A, h] = Vh(t), [u, g] = Wh(t), [f, p] = jh(t), { lineSpacing: [m, I], spacingRule: [S, v] } = zh(t), R = Te(() => S === Xt.AUTO ? { min: 1, max: 5, step: m < 2 ? 0.5 : 1 } : { min: 1, max: 100 }, [S, m]);
10402
+ ], []), t = Qh(), [o, r] = Uh(t, e[0].value), [s, i] = Fh(t), [a, c] = Hh(t), [d, l] = kh(t), [A, h] = Vh(t), [u, g] = Wh(t), [f, p] = zh(t), { lineSpacing: [m, I], spacingRule: [S, v] } = jh(t), R = Te(() => S === Xt.AUTO ? { min: 1, max: 5, step: m < 2 ? 0.5 : 1 } : { min: 1, max: 100 }, [S, m]);
10391
10403
  return /* @__PURE__ */ re("div", { children: [
10392
10404
  /* @__PURE__ */ Q("div", { className: "univer-t-4 univer-text-sm univer-font-medium", children: n.t("doc.paragraphSetting.alignment") }),
10393
10405
  /* @__PURE__ */ Q(
10394
10406
  "div",
10395
10407
  {
10396
- className: ze("univer-mt-4 univer-box-border univer-flex univer-w-full univer-items-center univer-justify-between univer-gap-1 univer-rounded-md univer-p-1", Nn),
10408
+ className: je("univer-mt-4 univer-box-border univer-flex univer-w-full univer-items-center univer-justify-between univer-gap-1 univer-rounded-md univer-p-1", Nn),
10397
10409
  children: e.map((E) => /* @__PURE__ */ Q(ed, { title: E.label, placement: "bottom", children: /* @__PURE__ */ Q(
10398
10410
  "span",
10399
10411
  {
10400
- className: ze("hover:univer-bg-black/60 univer-flex univer-cursor-pointer univer-items-center univer-justify-center univer-rounded univer-bg-none univer-px-3 univer-py-1", {
10412
+ className: je("hover:univer-bg-black/60 univer-flex univer-cursor-pointer univer-items-center univer-justify-center univer-rounded univer-bg-none univer-px-3 univer-py-1", {
10401
10413
  "univer-bg-blend-color-dodge/90": o === E.value
10402
10414
  }),
10403
10415
  onClick: () => r(E.value),
@@ -10506,7 +10518,7 @@ var qh = Object.getOwnPropertyDescriptor, Xh = (n, e, t, o) => {
10506
10518
  for (var r = o > 1 ? void 0 : o ? qh(e, t) : e, s = n.length - 1, i; s >= 0; s--)
10507
10519
  (i = n[s]) && (r = i(r) || r);
10508
10520
  return r;
10509
- }, or = (n, e) => (t, o) => e(t, o, n);
10521
+ }, rr = (n, e) => (t, o) => e(t, o, n);
10510
10522
  const Ni = "doc_ui_paragraph-setting-panel";
10511
10523
  let tn = class extends me {
10512
10524
  constructor(e, t, o) {
@@ -10533,9 +10545,9 @@ let tn = class extends me {
10533
10545
  }
10534
10546
  };
10535
10547
  tn = Xh([
10536
- or(0, T),
10537
- or(1, j(rn)),
10538
- or(2, j(la))
10548
+ rr(0, T),
10549
+ rr(1, z(rn)),
10550
+ rr(2, z(la))
10539
10551
  ], tn);
10540
10552
  const Ds = {
10541
10553
  id: "sidebar.operation.doc-paragraph-setting-panel",
@@ -10584,8 +10596,8 @@ const dt = (n) => {
10584
10596
  return Li(o, e, t), () => r.unsubscribe();
10585
10597
  });
10586
10598
  }, Jh = (n) => ({
10587
- id: ro.name,
10588
- commandId: ro.id,
10599
+ id: so.name,
10600
+ commandId: so.id,
10589
10601
  type: Z.BUTTON,
10590
10602
  icon: "CopyDoubleIcon",
10591
10603
  title: "rightClick.copy",
@@ -10611,7 +10623,7 @@ const dt = (n) => {
10611
10623
  title: "rightClick.paste",
10612
10624
  hidden$: se(n, _.UNIVER_DOC)
10613
10625
  }), ng = (n) => ({
10614
- id: Do.id,
10626
+ id: Po.id,
10615
10627
  type: Z.BUTTON,
10616
10628
  icon: "PasteSpecialDoubleIcon",
10617
10629
  title: "rightClick.delete",
@@ -10759,23 +10771,23 @@ const ug = {
10759
10771
  }
10760
10772
  },
10761
10773
  [Ks.LAYOUT]: {
10762
- [Qo.id]: {
10774
+ [Uo.id]: {
10763
10775
  order: 2,
10764
10776
  menuItemFactory: vu
10765
10777
  },
10766
- [Uo.id]: {
10778
+ [Fo.id]: {
10767
10779
  order: 3,
10768
10780
  menuItemFactory: Cu
10769
10781
  },
10770
- [Fo.id]: {
10782
+ [Ho.id]: {
10771
10783
  order: 4,
10772
10784
  menuItemFactory: Ru
10773
10785
  },
10774
- [Ho.id]: {
10786
+ [ko.id]: {
10775
10787
  order: 5,
10776
10788
  menuItemFactory: bu
10777
10789
  },
10778
- [wo.id]: {
10790
+ [No.id]: {
10779
10791
  order: 6,
10780
10792
  menuItemFactory: xu
10781
10793
  },
@@ -10787,7 +10799,7 @@ const ug = {
10787
10799
  order: 8,
10788
10800
  menuItemFactory: yi
10789
10801
  },
10790
- [so.id]: {
10802
+ [io.id]: {
10791
10803
  order: 9,
10792
10804
  menuItemFactory: Oi
10793
10805
  },
@@ -10795,7 +10807,7 @@ const ug = {
10795
10807
  order: 10,
10796
10808
  menuItemFactory: mu
10797
10809
  },
10798
- [ko.id]: {
10810
+ [Vo.id]: {
10799
10811
  order: 11,
10800
10812
  menuItemFactory: yu
10801
10813
  },
@@ -10814,9 +10826,9 @@ const ug = {
10814
10826
  }
10815
10827
  }
10816
10828
  },
10817
- [no.MAIN_AREA]: {
10829
+ [oo.MAIN_AREA]: {
10818
10830
  [an.FORMAT]: {
10819
- [ro.name]: {
10831
+ [so.name]: {
10820
10832
  order: 0,
10821
10833
  menuItemFactory: Jh
10822
10834
  },
@@ -10828,7 +10840,7 @@ const ug = {
10828
10840
  order: 2,
10829
10841
  menuItemFactory: tg
10830
10842
  },
10831
- [Do.id]: {
10843
+ [Po.id]: {
10832
10844
  order: 3,
10833
10845
  menuItemFactory: ng
10834
10846
  }
@@ -10876,7 +10888,7 @@ const ug = {
10876
10888
  }
10877
10889
  }
10878
10890
  },
10879
- [no.PARAGRAPH]: {
10891
+ [oo.PARAGRAPH]: {
10880
10892
  [an.QUICK]: {
10881
10893
  [us.id]: {
10882
10894
  order: 0,
@@ -10898,7 +10910,7 @@ const ug = {
10898
10910
  order: 4,
10899
10911
  menuItemFactory: Nu
10900
10912
  },
10901
- [io.id]: {
10913
+ [ao.id]: {
10902
10914
  order: 5,
10903
10915
  menuItemFactory: Lu
10904
10916
  },
@@ -10910,7 +10922,7 @@ const ug = {
10910
10922
  order: 7,
10911
10923
  menuItemFactory: yi
10912
10924
  },
10913
- [so.id]: {
10925
+ [io.id]: {
10914
10926
  order: 8,
10915
10927
  menuItemFactory: Oi
10916
10928
  }
@@ -10932,7 +10944,7 @@ const ug = {
10932
10944
  [an.LAYOUT]: {
10933
10945
  // title: 'rightClick.insertBellow',
10934
10946
  [Ic]: {
10935
- menuItemFactory: ju,
10947
+ menuItemFactory: zu,
10936
10948
  [ls.id]: {
10937
10949
  order: 0,
10938
10950
  menuItemFactory: Hu
@@ -10958,7 +10970,7 @@ var hg = Object.getOwnPropertyDescriptor, gg = (n, e, t, o) => {
10958
10970
  (i = n[s]) && (r = i(r) || r);
10959
10971
  return r;
10960
10972
  }, st = (n, e) => (t, o) => e(t, o, n);
10961
- let Ao = class extends me {
10973
+ let uo = class extends me {
10962
10974
  constructor(n, e, t, o, r, s, i, a, c) {
10963
10975
  super(), this._injector = n, this._componentManager = e, this._commandService = t, this._layoutService = o, this._menuManagerService = r, this._uiPartsService = s, this._univerInstanceService = i, this._shortcutService = a, this._configService = c, this._init();
10964
10976
  }
@@ -11020,24 +11032,24 @@ let Ao = class extends me {
11020
11032
  );
11021
11033
  }
11022
11034
  };
11023
- Ao = gg([
11024
- st(0, j(Dn)),
11025
- st(1, j(rn)),
11035
+ uo = gg([
11036
+ st(0, z(Dn)),
11037
+ st(1, z(rn)),
11026
11038
  st(2, T),
11027
- st(3, Oo),
11039
+ st(3, To),
11028
11040
  st(4, Aa),
11029
11041
  st(5, Hl),
11030
11042
  st(6, L),
11031
- st(7, To),
11043
+ st(7, Bo),
11032
11044
  st(8, Vr)
11033
- ], Ao);
11045
+ ], uo);
11034
11046
  var fg = Object.getOwnPropertyDescriptor, pg = (n, e, t, o) => {
11035
11047
  for (var r = o > 1 ? void 0 : o ? fg(e, t) : e, s = n.length - 1, i; s >= 0; s--)
11036
11048
  (i = n[s]) && (r = i(r) || r);
11037
11049
  return r;
11038
- }, rr = (n, e) => (t, o) => e(t, o, n);
11050
+ }, sr = (n, e) => (t, o) => e(t, o, n);
11039
11051
  const Qi = 1.5;
11040
- let uo = class extends Ct {
11052
+ let ho = class extends Ct {
11041
11053
  constructor(n, e, t, o) {
11042
11054
  super(), this._context = n, this._textSelectionManagerService = e, this._editorService = t, this._docSkeletonManagerService = o, this._init();
11043
11055
  }
@@ -11046,7 +11058,7 @@ let uo = class extends Ct {
11046
11058
  if (n == null)
11047
11059
  return;
11048
11060
  const { isEditing: e, unitId: t } = n;
11049
- t !== this._context.unitId || !e || this._context.unitId !== bo && this._scrollToSelection();
11061
+ t !== this._context.unitId || !e || this._context.unitId !== xo && this._scrollToSelection();
11050
11062
  });
11051
11063
  }
11052
11064
  scrollToRange(n) {
@@ -11085,16 +11097,16 @@ let uo = class extends Ct {
11085
11097
  e && this.scrollToNode(t);
11086
11098
  }
11087
11099
  };
11088
- uo = pg([
11089
- rr(1, j(Y)),
11090
- rr(2, Ge),
11091
- rr(3, j(de))
11092
- ], uo);
11100
+ ho = pg([
11101
+ sr(1, z(Y)),
11102
+ sr(2, Ge),
11103
+ sr(3, z(de))
11104
+ ], ho);
11093
11105
  var mg = Object.getOwnPropertyDescriptor, Eg = (n, e, t, o) => {
11094
11106
  for (var r = o > 1 ? void 0 : o ? mg(e, t) : e, s = n.length - 1, i; s >= 0; s--)
11095
11107
  (i = n[s]) && (r = i(r) || r);
11096
11108
  return r;
11097
- }, zt = (n, e) => (t, o) => e(t, o, n);
11109
+ }, jt = (n, e) => (t, o) => e(t, o, n);
11098
11110
  let br = class extends Ct {
11099
11111
  constructor(n, e, t, o, r, s, i) {
11100
11112
  super(), this._context = n, this._commandService = e, this._docSelectionRenderService = t, this._docSkeletonManagerService = o, this._editorService = r, this._renderManagerService = s, this._univerInstanceService = i, this._addNewRender(), this._initRenderRefresh(), this._initCommandListener();
@@ -11132,7 +11144,7 @@ let br = class extends Ct {
11132
11144
  } else
11133
11145
  t.onMouseWheel(a, s);
11134
11146
  }), new lr(t), n.addLayer(
11135
- new Gs(n, [], zo),
11147
+ new Gs(n, [], Go),
11136
11148
  new Gs(n, [], ad)
11137
11149
  ), this._addComponent();
11138
11150
  const o = () => n.render();
@@ -11147,7 +11159,7 @@ let br = class extends Ct {
11147
11159
  }, i = new gl($e.MAIN, void 0, s);
11148
11160
  i.zIndex = $s;
11149
11161
  const a = new fl($e.BACKGROUND, void 0, s);
11150
- a.zIndex = $s, this._context.mainComponent = i, t.set($e.MAIN, i), t.set($e.BACKGROUND, a), n.addObjects([i], zo), n.addObjects([a], id), this._editorService.getEditor(e.getUnitId()) == null && n.enableLayerCache(zo);
11162
+ a.zIndex = $s, this._context.mainComponent = i, t.set($e.MAIN, i), t.set($e.BACKGROUND, a), n.addObjects([i], Go), n.addObjects([a], id), this._editorService.getEditor(e.getUnitId()) == null && n.enableLayerCache(Go);
11151
11163
  }
11152
11164
  _initRenderRefresh() {
11153
11165
  this._docSkeletonManagerService.currentSkeletonBefore$.pipe(ft(this.dispose$)).subscribe((n) => {
@@ -11198,12 +11210,12 @@ let br = class extends Ct {
11198
11210
  }
11199
11211
  };
11200
11212
  br = Eg([
11201
- zt(1, T),
11202
- zt(2, j(Re)),
11203
- zt(3, j(de)),
11204
- zt(4, Ge),
11205
- zt(5, pe),
11206
- zt(6, L)
11213
+ jt(1, T),
11214
+ jt(2, z(Re)),
11215
+ jt(3, z(de)),
11216
+ jt(4, Ge),
11217
+ jt(5, pe),
11218
+ jt(6, L)
11207
11219
  ], br);
11208
11220
  function Ig(n) {
11209
11221
  let { pageWidth: e, pageHeight: t } = n;
@@ -11219,7 +11231,7 @@ var Sg = Object.getOwnPropertyDescriptor, vg = (n, e, t, o) => {
11219
11231
  for (var r = o > 1 ? void 0 : o ? Sg(e, t) : e, s = n.length - 1, i; s >= 0; s--)
11220
11232
  (i = n[s]) && (r = i(r) || r);
11221
11233
  return r;
11222
- }, sr = (n, e) => (t, o) => e(t, o, n);
11234
+ }, ir = (n, e) => (t, o) => e(t, o, n);
11223
11235
  let xr = class {
11224
11236
  constructor(n, e, t) {
11225
11237
  O(this, "_docContainer");
@@ -11243,7 +11255,7 @@ let xr = class {
11243
11255
  getUIConfig() {
11244
11256
  return {
11245
11257
  injector: this._injector,
11246
- config: this._configService.getConfig(Vo),
11258
+ config: this._configService.getConfig(Wo),
11247
11259
  changeLocale: this.changeLocale,
11248
11260
  getComponent: this.getComponent
11249
11261
  };
@@ -11260,31 +11272,31 @@ let xr = class {
11260
11272
  }
11261
11273
  };
11262
11274
  xr = vg([
11263
- sr(0, j(Ye)),
11264
- sr(1, j(Dn)),
11265
- sr(2, Vr)
11275
+ ir(0, z(Ye)),
11276
+ ir(1, z(Dn)),
11277
+ ir(2, Vr)
11266
11278
  ], xr);
11267
11279
  var Cg = Object.getOwnPropertyDescriptor, Rg = (n, e, t, o) => {
11268
11280
  for (var r = o > 1 ? void 0 : o ? Cg(e, t) : e, s = n.length - 1, i; s >= 0; s--)
11269
11281
  (i = n[s]) && (r = i(r) || r);
11270
11282
  return r;
11271
11283
  }, bg = (n, e) => (t, o) => e(t, o, n);
11272
- let ho = class extends Ct {
11284
+ let go = class extends Ct {
11273
11285
  constructor(e) {
11274
11286
  super();
11275
11287
  O(this, "_docContainerController");
11276
11288
  this._injector = e, this._docContainerController = this._injector.createInstance(xr);
11277
11289
  }
11278
11290
  };
11279
- ho = Rg([
11280
- bg(0, j(Dn))
11281
- ], ho);
11291
+ go = Rg([
11292
+ bg(0, z(Dn))
11293
+ ], go);
11282
11294
  var xg = Object.getOwnPropertyDescriptor, yg = (n, e, t, o) => {
11283
11295
  for (var r = o > 1 ? void 0 : o ? xg(e, t) : e, s = n.length - 1, i; s >= 0; s--)
11284
11296
  (i = n[s]) && (r = i(r) || r);
11285
11297
  return r;
11286
11298
  }, Ui = (n, e) => (t, o) => e(t, o, n);
11287
- let go = class extends me {
11299
+ let fo = class extends me {
11288
11300
  constructor(n, e) {
11289
11301
  super(), this._docAutoFormatService = n, this._renderManagerService = e, this._initListTabAutoFormat(), this._initSpaceAutoFormat(), this._initDefaultEnterFormat(), this._initExitListAutoFormat();
11290
11302
  }
@@ -11340,14 +11352,14 @@ let go = class extends me {
11340
11352
  _initSpaceAutoFormat() {
11341
11353
  this.disposeWithMe(
11342
11354
  this._docAutoFormatService.registerAutoFormat({
11343
- id: Mo.id,
11355
+ id: _o.id,
11344
11356
  match: (n) => {
11345
11357
  var s;
11346
11358
  const { selection: e, paragraphs: t, unit: o } = n;
11347
11359
  if (!e.collapsed || t.length !== 1 || !e.collapsed)
11348
11360
  return !1;
11349
11361
  const r = (s = o.getBody()) == null ? void 0 : s.dataStream.slice(t[0].paragraphStart, e.startOffset - 1);
11350
- return !!(r && (Object.keys(jo).includes(r) || Object.keys(qo).includes(r)));
11362
+ return !!(r && (Object.keys(jo).includes(r) || Object.keys(Xo).includes(r)));
11351
11363
  },
11352
11364
  getMutations(n) {
11353
11365
  var s;
@@ -11362,8 +11374,8 @@ let go = class extends me {
11362
11374
  }
11363
11375
  }];
11364
11376
  }
11365
- if (r && Object.keys(qo).includes(r)) {
11366
- const i = qo[r];
11377
+ if (r && Object.keys(Xo).includes(r)) {
11378
+ const i = Xo[r];
11367
11379
  return [{
11368
11380
  id: Qa.id,
11369
11381
  params: {
@@ -11416,10 +11428,10 @@ let go = class extends me {
11416
11428
  );
11417
11429
  }
11418
11430
  };
11419
- go = yg([
11420
- Ui(0, j(Pt)),
11431
+ fo = yg([
11432
+ Ui(0, z(Pt)),
11421
11433
  Ui(1, pe)
11422
- ], go);
11434
+ ], fo);
11423
11435
  function Og(n) {
11424
11436
  return n.rows[0].cells[0].sections[0].columns[0].lines[0];
11425
11437
  }
@@ -11529,8 +11541,8 @@ var Pg = Object.getOwnPropertyDescriptor, wg = (n, e, t, o) => {
11529
11541
  for (var r = o > 1 ? void 0 : o ? Pg(e, t) : e, s = n.length - 1, i; s >= 0; s--)
11530
11542
  (i = n[s]) && (r = i(r) || r);
11531
11543
  return r;
11532
- }, jn = (n, e) => (t, o) => e(t, o, n);
11533
- let fo = class extends me {
11544
+ }, zn = (n, e) => (t, o) => e(t, o, n);
11545
+ let po = class extends me {
11534
11546
  constructor(e, t, o, r) {
11535
11547
  super();
11536
11548
  O(this, "_onInputSubscription");
@@ -11820,7 +11832,7 @@ let fo = class extends me {
11820
11832
  }
11821
11833
  _scrollToFocusNodePosition(e, t) {
11822
11834
  var r;
11823
- const o = (r = this._renderManagerService.getRenderById(e)) == null ? void 0 : r.with(uo);
11835
+ const o = (r = this._renderManagerService.getRenderById(e)) == null ? void 0 : r.with(ho);
11824
11836
  o != null && o.scrollToRange({
11825
11837
  startOffset: t,
11826
11838
  endOffset: t,
@@ -11831,12 +11843,12 @@ let fo = class extends me {
11831
11843
  return cd(this._univerInstanceService, this._renderManagerService);
11832
11844
  }
11833
11845
  };
11834
- fo = wg([
11835
- jn(0, L),
11836
- jn(1, pe),
11837
- jn(2, j(Y)),
11838
- jn(3, T)
11839
- ], fo);
11846
+ po = wg([
11847
+ zn(0, L),
11848
+ zn(1, pe),
11849
+ zn(2, z(Y)),
11850
+ zn(3, T)
11851
+ ], po);
11840
11852
  function Hi(n, e) {
11841
11853
  var o, r;
11842
11854
  let t = null;
@@ -11909,7 +11921,7 @@ var Lg = Object.getOwnPropertyDescriptor, Qg = (n, e, t, o) => {
11909
11921
  (i = n[s]) && (r = i(r) || r);
11910
11922
  return r;
11911
11923
  }, ki = (n, e) => (t, o) => e(t, o, n);
11912
- let po = class extends me {
11924
+ let mo = class extends me {
11913
11925
  constructor(n, e) {
11914
11926
  super(), this._commandService = n, this._componentManager = e, this._initialize();
11915
11927
  }
@@ -11928,15 +11940,15 @@ let po = class extends me {
11928
11940
  _init() {
11929
11941
  }
11930
11942
  };
11931
- po = Qg([
11943
+ mo = Qg([
11932
11944
  ki(0, T),
11933
- ki(1, j(rn))
11934
- ], po);
11945
+ ki(1, z(rn))
11946
+ ], mo);
11935
11947
  var Ug = Object.getOwnPropertyDescriptor, Fg = (n, e, t, o) => {
11936
11948
  for (var r = o > 1 ? void 0 : o ? Ug(e, t) : e, s = n.length - 1, i; s >= 0; s--)
11937
11949
  (i = n[s]) && (r = i(r) || r);
11938
11950
  return r;
11939
- }, zn = (n, e) => (t, o) => e(t, o, n);
11951
+ }, jn = (n, e) => (t, o) => e(t, o, n);
11940
11952
  let yr = class extends me {
11941
11953
  constructor(n, e, t, o, r) {
11942
11954
  super(), this._context = n, this._docSkeletonManagerService = e, this._commandService = t, this._docEventManagerService = o, this._textSelectionManagerService = r, this._initPointerDownObserver(), this._initHoverCursor();
@@ -11965,17 +11977,17 @@ let yr = class extends me {
11965
11977
  }
11966
11978
  };
11967
11979
  yr = Fg([
11968
- zn(1, j(de)),
11969
- zn(2, T),
11970
- zn(3, j(wt)),
11971
- zn(4, j(Y))
11980
+ jn(1, z(de)),
11981
+ jn(2, T),
11982
+ jn(3, z(wt)),
11983
+ jn(4, z(Y))
11972
11984
  ], yr);
11973
11985
  var Hg = Object.getOwnPropertyDescriptor, kg = (n, e, t, o) => {
11974
11986
  for (var r = o > 1 ? void 0 : o ? Hg(e, t) : e, s = n.length - 1, i; s >= 0; s--)
11975
11987
  (i = n[s]) && (r = i(r) || r);
11976
11988
  return r;
11977
11989
  }, An = (n, e) => (t, o) => e(t, o, n);
11978
- let mo = class extends Ct {
11990
+ let Eo = class extends Ct {
11979
11991
  constructor(n, e, t, o, r, s) {
11980
11992
  super(), this._context = n, this._commandService = e, this._docClipboardService = t, this._docSelectionRenderService = o, this._contextService = r, this._editorService = s, this._init();
11981
11993
  }
@@ -11986,42 +11998,42 @@ let mo = class extends Ct {
11986
11998
  var n;
11987
11999
  (n = this._docSelectionRenderService) == null || n.onPaste$.pipe(ft(this.dispose$)).subscribe((e) => {
11988
12000
  var a, c, d;
11989
- if (!Po(this._contextService))
12001
+ if (!wo(this._contextService))
11990
12002
  return;
11991
12003
  e.event.preventDefault();
11992
12004
  const t = e.event;
11993
- let o = (a = t.clipboardData) == null ? void 0 : a.getData(ia);
11994
- const r = (c = t.clipboardData) == null ? void 0 : c.getData(aa), s = [...((d = t.clipboardData) == null ? void 0 : d.items) || []].filter((l) => kl.has(l.type)).map((l) => l.getAsFile()).filter((l) => !!l);
12005
+ let o = (a = t.clipboardData) == null ? void 0 : a.getData(aa);
12006
+ const r = (c = t.clipboardData) == null ? void 0 : c.getData(ca), s = [...((d = t.clipboardData) == null ? void 0 : d.items) || []].filter((l) => kl.has(l.type)).map((l) => l.getAsFile()).filter((l) => !!l);
11995
12007
  this._editorService.getEditor(this._context.unitId) && (o != null ? o : "").indexOf("</table>") > -1 && (o = ""), this._docClipboardService.legacyPaste({ html: o, text: r, files: s });
11996
12008
  });
11997
12009
  }
11998
12010
  };
11999
- mo = kg([
12011
+ Eo = kg([
12000
12012
  An(1, T),
12001
12013
  An(2, Lt),
12002
- An(3, j(Re)),
12014
+ An(3, z(Re)),
12003
12015
  An(4, Fr),
12004
12016
  An(5, Ge)
12005
- ], mo);
12017
+ ], Eo);
12006
12018
  var Vg = Object.getOwnPropertyDescriptor, Wg = (n, e, t, o) => {
12007
12019
  for (var r = o > 1 ? void 0 : o ? Vg(e, t) : e, s = n.length - 1, i; s >= 0; s--)
12008
12020
  (i = n[s]) && (r = i(r) || r);
12009
12021
  return r;
12010
12022
  }, Vi = (n, e) => (t, o) => e(t, o, n);
12011
- const jg = [
12012
- Xi,
12023
+ const zg = [
12024
+ Zi,
12013
12025
  Yc,
12014
- bo,
12026
+ xo,
12015
12027
  nt
12016
12028
  ];
12017
12029
  let Or = class extends me {
12018
12030
  constructor(n, e, t) {
12019
- super(), this._context = n, this._contextMenuService = e, this._commandService = t, jg.includes(this._context.unitId) || (this._initPointerDown(), this._initEditChange());
12031
+ super(), this._context = n, this._contextMenuService = e, this._commandService = t, zg.includes(this._context.unitId) || (this._initPointerDown(), this._initEditChange());
12020
12032
  }
12021
12033
  _initPointerDown() {
12022
12034
  var t, o;
12023
12035
  const e = ((o = (t = this._context) == null ? void 0 : t.mainComponent) == null ? void 0 : o.onPointerDown$).subscribeEvent((r) => {
12024
- r.button === 2 && this._contextMenuService.triggerContextMenu(r, no.MAIN_AREA);
12036
+ r.button === 2 && this._contextMenuService.triggerContextMenu(r, oo.MAIN_AREA);
12025
12037
  });
12026
12038
  this.disposeWithMe(e);
12027
12039
  }
@@ -12037,12 +12049,12 @@ Or = Wg([
12037
12049
  Vi(1, Vl),
12038
12050
  Vi(2, T)
12039
12051
  ], Or);
12040
- var zg = Object.getOwnPropertyDescriptor, Gg = (n, e, t, o) => {
12041
- for (var r = o > 1 ? void 0 : o ? zg(e, t) : e, s = n.length - 1, i; s >= 0; s--)
12052
+ var jg = Object.getOwnPropertyDescriptor, Gg = (n, e, t, o) => {
12053
+ for (var r = o > 1 ? void 0 : o ? jg(e, t) : e, s = n.length - 1, i; s >= 0; s--)
12042
12054
  (i = n[s]) && (r = i(r) || r);
12043
12055
  return r;
12044
12056
  }, Gt = (n, e) => (t, o) => e(t, o, n);
12045
- let Eo = class extends me {
12057
+ let Io = class extends me {
12046
12058
  constructor(e, t, o, r, s, i, a) {
12047
12059
  super();
12048
12060
  O(this, "_initialEditors", /* @__PURE__ */ new Set());
@@ -12096,7 +12108,7 @@ let Eo = class extends me {
12096
12108
  "univer-formula-help-param"
12097
12109
  ];
12098
12110
  this.disposeWithMe(
12099
- je(window, "mousedown").subscribe((o) => {
12111
+ ze(window, "mousedown").subscribe((o) => {
12100
12112
  const s = o.target.classList[0] || "";
12101
12113
  Kc(s, e) && o.stopPropagation();
12102
12114
  })
@@ -12109,7 +12121,7 @@ let Eo = class extends me {
12109
12121
  const r = o.getUnitId(), s = this._renderManagerService.getRenderById(r), i = s == null ? void 0 : s.engine.getCanvas().getCanvasEle();
12110
12122
  if (i == null)
12111
12123
  return;
12112
- const a = je(i, "mousedown").subscribe((c) => {
12124
+ const a = ze(i, "mousedown").subscribe((c) => {
12113
12125
  c.stopPropagation();
12114
12126
  });
12115
12127
  t.add(a);
@@ -12134,14 +12146,14 @@ let Eo = class extends me {
12134
12146
  );
12135
12147
  }
12136
12148
  };
12137
- Eo = Gg([
12149
+ Io = Gg([
12138
12150
  Gt(1, L),
12139
12151
  Gt(2, Ge),
12140
12152
  Gt(3, T),
12141
- Gt(4, j(Re)),
12142
- Gt(5, j(de)),
12153
+ Gt(4, z(Re)),
12154
+ Gt(5, z(de)),
12143
12155
  Gt(6, pe)
12144
- ], Eo);
12156
+ ], Io);
12145
12157
  var Yg = Object.getOwnPropertyDescriptor, Kg = (n, e, t, o) => {
12146
12158
  for (var r = o > 1 ? void 0 : o ? Yg(e, t) : e, s = n.length - 1, i; s >= 0; s--)
12147
12159
  (i = n[s]) && (r = i(r) || r);
@@ -12203,9 +12215,9 @@ let Tr = class extends me {
12203
12215
  }
12204
12216
  };
12205
12217
  Tr = Kg([
12206
- Gn(1, j(Re)),
12207
- Gn(2, j(No)),
12208
- Gn(3, j(de)),
12218
+ Gn(1, z(Re)),
12219
+ Gn(2, z(Lo)),
12220
+ Gn(3, z(de)),
12209
12221
  Gn(4, T)
12210
12222
  ], Tr);
12211
12223
  var qg = Object.getOwnPropertyDescriptor, Xg = (n, e, t, o) => {
@@ -12234,7 +12246,7 @@ let Br = class extends me {
12234
12246
  const { unitId: t } = this._context, { event: o, content: r = "", activeRange: s } = e, i = o, a = this._docSkeletonManagerService.getSkeleton();
12235
12247
  if (i.data == null || a == null || s == null)
12236
12248
  return;
12237
- const { segmentId: c } = s, l = this._context.unit.getSelfOrHeaderFooterModel(c).getBody(), A = this._docMenuStyleService.getDefaultStyle(), h = this._docMenuStyleService.getStyleCache(), u = jr((p = l == null ? void 0 : l.customRanges) != null ? p : [], s.endOffset, En.includes(t)), g = Bo(l, s.endOffset, A, h, En.includes(t)), f = zr((m = l == null ? void 0 : l.customDecorations) != null ? m : [], s.endOffset);
12249
+ const { segmentId: c } = s, l = this._context.unit.getSelfOrHeaderFooterModel(c).getBody(), A = this._docMenuStyleService.getDefaultStyle(), h = this._docMenuStyleService.getStyleCache(), u = zr((p = l == null ? void 0 : l.customRanges) != null ? p : [], s.endOffset, En.includes(t)), g = Mo(l, s.endOffset, A, h, En.includes(t)), f = jr((m = l == null ? void 0 : l.customDecorations) != null ? m : [], s.endOffset);
12238
12250
  await this._commandService.executeCommand(Ca.id, {
12239
12251
  unitId: t,
12240
12252
  body: {
@@ -12259,15 +12271,15 @@ let Br = class extends me {
12259
12271
  },
12260
12272
  range: s,
12261
12273
  segmentId: c
12262
- }), r === " " && await this._commandService.executeCommand(Mo.id);
12274
+ }), r === " " && await this._commandService.executeCommand(_o.id);
12263
12275
  });
12264
12276
  }
12265
12277
  };
12266
12278
  Br = Xg([
12267
- Yn(1, j(Re)),
12268
- Yn(2, j(de)),
12279
+ Yn(1, z(Re)),
12280
+ Yn(2, z(de)),
12269
12281
  Yn(3, T),
12270
- Yn(4, j(at))
12282
+ Yn(4, z(at))
12271
12283
  ], Br);
12272
12284
  class ws extends me {
12273
12285
  constructor(e) {
@@ -12302,7 +12314,7 @@ let Mr = class extends me {
12302
12314
  _initResize() {
12303
12315
  this.disposeWithMe(
12304
12316
  Mt(this._context.engine.onTransformChange$).pipe(
12305
- oo((n) => n.type === oa.resize),
12317
+ ro((n) => n.type === ra.resize),
12306
12318
  Rn(0, Yl)
12307
12319
  ).subscribe(() => {
12308
12320
  this._docPageLayoutService.calculatePagePosition(), this._textSelectionManagerService.refreshSelection();
@@ -12311,8 +12323,8 @@ let Mr = class extends me {
12311
12323
  }
12312
12324
  };
12313
12325
  Mr = Jg([
12314
- Wi(1, j(ws)),
12315
- Wi(2, j(Y))
12326
+ Wi(1, z(ws)),
12327
+ Wi(2, z(Y))
12316
12328
  ], Mr);
12317
12329
  var $g = Object.getOwnPropertyDescriptor, ef = (n, e, t, o) => {
12318
12330
  for (var r = o > 1 ? void 0 : o ? $g(e, t) : e, s = n.length - 1, i; s >= 0; s--)
@@ -12444,9 +12456,9 @@ _r = ef([
12444
12456
  Yt(1, T),
12445
12457
  Yt(2, Ge),
12446
12458
  Yt(3, L),
12447
- Yt(4, j(Re)),
12448
- Yt(5, j(de)),
12449
- Yt(6, j(Y))
12459
+ Yt(4, z(Re)),
12460
+ Yt(5, z(de)),
12461
+ Yt(6, z(Y))
12450
12462
  ], _r);
12451
12463
  var tf = Object.getOwnPropertyDescriptor, nf = (n, e, t, o) => {
12452
12464
  for (var r = o > 1 ? void 0 : o ? tf(e, t) : e, s = n.length - 1, i; s >= 0; s--)
@@ -12457,7 +12469,7 @@ let Dr = class extends me {
12457
12469
  constructor(e, t, o, r, s, i, a, c, d) {
12458
12470
  super();
12459
12471
  O(this, "_isSheetEditor", !1);
12460
- this._context = e, this._contextService = t, this._docSkeletonManagerService = o, this._univerInstanceService = r, this._commandService = s, this._textSelectionManagerService = i, this._editorService = a, this._docPageLayoutService = c, this._renderManagerService = d, this._initSkeletonListener(), this._initCommandExecutedListener(), this._initRenderRefresher(), this._isSheetEditor = this._context.unitId === bo;
12472
+ this._context = e, this._contextService = t, this._docSkeletonManagerService = o, this._univerInstanceService = r, this._commandService = s, this._textSelectionManagerService = i, this._editorService = a, this._docPageLayoutService = c, this._renderManagerService = d, this._initSkeletonListener(), this._initCommandExecutedListener(), this._initRenderRefresher(), this._isSheetEditor = this._context.unitId === xo;
12461
12473
  const l = this._univerInstanceService.getCurrentUnitOfType(_.UNIVER_SHEET), A = l && this._renderManagerService.getRenderById(l.getUnitId());
12462
12474
  setTimeout(() => this.updateViewZoom(A && this._isSheetEditor ? A.scene.scaleX : 1, !0), 20), Rt(this._context.unitId) || this._initZoomEventListener();
12463
12475
  }
@@ -12507,7 +12519,7 @@ let Dr = class extends me {
12507
12519
  }
12508
12520
  })), this.disposeWithMe(
12509
12521
  this._commandService.beforeCommandExecuted((t) => {
12510
- t.id === ko.id && this._commandService.executeCommand(Xn.id, {
12522
+ t.id === Vo.id && this._commandService.executeCommand(Xn.id, {
12511
12523
  zoomRatio: 1,
12512
12524
  unitId: this._context.unitId
12513
12525
  });
@@ -12541,15 +12553,15 @@ let Dr = class extends me {
12541
12553
  };
12542
12554
  Dr = nf([
12543
12555
  ht(1, Fr),
12544
- ht(2, j(de)),
12556
+ ht(2, z(de)),
12545
12557
  ht(3, L),
12546
12558
  ht(4, T),
12547
- ht(5, j(Y)),
12559
+ ht(5, z(Y)),
12548
12560
  ht(6, Ge),
12549
- ht(7, j(ws)),
12561
+ ht(7, z(ws)),
12550
12562
  ht(8, pe)
12551
12563
  ], Dr);
12552
- const of = Ji("PRINTING_COMPONENT_COLLECT"), rf = Ji("PRINTING_DOM_COLLECT");
12564
+ const of = $i("PRINTING_COMPONENT_COLLECT"), rf = $i("PRINTING_DOM_COLLECT");
12553
12565
  class sf extends me {
12554
12566
  constructor() {
12555
12567
  super();
@@ -12578,8 +12590,8 @@ var af = Object.getOwnPropertyDescriptor, cf = (n, e, t, o) => {
12578
12590
  (i = n[s]) && (r = i(r) || r);
12579
12591
  return r;
12580
12592
  }, un = (n, e) => (t, o) => e(t, o, n);
12581
- const ji = 300;
12582
- let Io = class extends Ct {
12593
+ const zi = 300;
12594
+ let So = class extends Ct {
12583
12595
  constructor(e, t, o, r, s) {
12584
12596
  super();
12585
12597
  O(this, "_docStateChange$", new Fe(null));
@@ -12623,7 +12635,7 @@ let Io = class extends Ct {
12623
12635
  var a;
12624
12636
  if (e == null)
12625
12637
  return;
12626
- const { isCompositionEnd: t, isSync: o, syncer: r, ...s } = e, i = (a = this._renderManagerService.getRenderById(o ? r : e.unitId)) == null ? void 0 : a.with(No);
12638
+ const { isCompositionEnd: t, isSync: o, syncer: r, ...s } = e, i = (a = this._renderManagerService.getRenderById(o ? r : e.unitId)) == null ? void 0 : a.with(Lo);
12627
12639
  if (i != null) {
12628
12640
  if (t) {
12629
12641
  const c = i.fetchComposedUndoRedoMutationParams();
@@ -12648,9 +12660,9 @@ let Io = class extends Ct {
12648
12660
  a.set(r, [e]);
12649
12661
  i ? t === "history" ? (this._historyTimer && clearTimeout(this._historyTimer), this._historyTimer = setTimeout(() => {
12650
12662
  c(r);
12651
- }, ji)) : (this._changeStateCacheTimer && clearTimeout(this._changeStateCacheTimer), this._changeStateCacheTimer = setTimeout(() => {
12663
+ }, zi)) : (this._changeStateCacheTimer && clearTimeout(this._changeStateCacheTimer), this._changeStateCacheTimer = setTimeout(() => {
12652
12664
  c(r);
12653
- }, ji)) : c(r);
12665
+ }, zi)) : c(r);
12654
12666
  }
12655
12667
  _pushHistory(e) {
12656
12668
  const t = this._undoRedoService, o = this._historyStateCache.get(e);
@@ -12698,20 +12710,20 @@ let Io = class extends Ct {
12698
12710
  t.length = 0, this._docStateChange$.next(u);
12699
12711
  }
12700
12712
  };
12701
- Io = cf([
12702
- un(0, j(xo)),
12713
+ So = cf([
12714
+ un(0, z(yo)),
12703
12715
  un(1, T),
12704
12716
  un(2, L),
12705
- un(3, j(tl)),
12717
+ un(3, z(tl)),
12706
12718
  un(4, pe)
12707
- ], Io);
12719
+ ], So);
12708
12720
  var lf = Object.getOwnPropertyDescriptor, df = (n, e, t, o) => {
12709
12721
  for (var r = o > 1 ? void 0 : o ? lf(e, t) : e, s = n.length - 1, i; s >= 0; s--)
12710
12722
  (i = n[s]) && (r = i(r) || r);
12711
12723
  return r;
12712
- }, zi = (n, e) => (t, o) => e(t, o, n);
12724
+ }, ji = (n, e) => (t, o) => e(t, o, n);
12713
12725
  const Gi = "univer-doc-main-canvas";
12714
- let So = class extends Ct {
12726
+ let vo = class extends Ct {
12715
12727
  constructor(n, e) {
12716
12728
  super(), this._instanceSrv = n, this._renderManagerService = e, this._init();
12717
12729
  }
@@ -12733,16 +12745,16 @@ let So = class extends Ct {
12733
12745
  this._renderManagerService.removeRender(e);
12734
12746
  }
12735
12747
  };
12736
- So = df([
12737
- zi(0, L),
12738
- zi(1, pe)
12739
- ], So);
12748
+ vo = df([
12749
+ ji(0, L),
12750
+ ji(1, pe)
12751
+ ], vo);
12740
12752
  const Af = {
12741
12753
  id: bn.id,
12742
12754
  preconditions: ah,
12743
12755
  binding: q.ENTER
12744
12756
  }, uf = {
12745
- id: Do.id,
12757
+ id: Po.id,
12746
12758
  preconditions: Se,
12747
12759
  binding: q.BACKSPACE
12748
12760
  }, hf = {
@@ -12824,29 +12836,29 @@ let Pr = class extends Zc {
12824
12836
  Pi,
12825
12837
  this._config
12826
12838
  );
12827
- i && this._configService.setConfig("menu", i, { merge: !0 }), this._configService.setConfig(Vo, a), this._initDependencies(e), this._initializeShortcut(), this._initCommand();
12839
+ i && this._configService.setConfig("menu", i, { merge: !0 }), this._configService.setConfig(Wo, a), this._initDependencies(e), this._initializeShortcut(), this._initCommand();
12828
12840
  }
12829
12841
  onReady() {
12830
12842
  this._initRenderBasics(), this._markDocAsFocused(), Vs(this._injector, [
12831
- [Io],
12832
- [So]
12843
+ [So],
12844
+ [vo]
12833
12845
  ]);
12834
12846
  }
12835
12847
  onRendered() {
12836
12848
  this._initUI(), this._initRenderModules(), Vs(this._injector, [
12837
- [go],
12838
12849
  [fo],
12839
- [tn],
12840
12850
  [po],
12851
+ [tn],
12852
+ [mo],
12841
12853
  // FIXME: LifecycleStages.Rendered must be used, otherwise the menu cannot be added to the DOM, but the sheet ui
12842
12854
  // plugin can be added in LifecycleStages.Ready
12843
- [Ao]
12855
+ [uo]
12844
12856
  ]);
12845
12857
  }
12846
12858
  // eslint-disable-next-line max-lines-per-function
12847
12859
  _initCommand() {
12848
12860
  [
12849
- Do,
12861
+ Po,
12850
12862
  xa,
12851
12863
  Qt,
12852
12864
  Ut,
@@ -12871,14 +12883,14 @@ let Pr = class extends Zc {
12871
12883
  On,
12872
12884
  yn,
12873
12885
  Fn,
12874
- Qo,
12875
12886
  Uo,
12876
12887
  Fo,
12877
- lt,
12878
12888
  Ho,
12879
- wo,
12880
- ja,
12889
+ lt,
12890
+ ko,
12891
+ No,
12881
12892
  za,
12893
+ ja,
12882
12894
  Rs,
12883
12895
  bs,
12884
12896
  SA,
@@ -12890,15 +12902,15 @@ let Pr = class extends Zc {
12890
12902
  Ms,
12891
12903
  Ga,
12892
12904
  Jt,
12893
- Mo,
12905
+ _o,
12894
12906
  bn,
12895
12907
  gr,
12896
- Lo,
12897
- so,
12908
+ Qo,
12909
+ io,
12898
12910
  Na,
12899
12911
  La,
12900
12912
  Ba,
12901
- ko,
12913
+ Vo,
12902
12914
  rt,
12903
12915
  va,
12904
12916
  $t,
@@ -12923,7 +12935,7 @@ let Pr = class extends Zc {
12923
12935
  gs,
12924
12936
  fs,
12925
12937
  ps,
12926
- io,
12938
+ ao,
12927
12939
  Ua,
12928
12940
  Fa,
12929
12941
  ls,
@@ -12934,7 +12946,7 @@ let Pr = class extends Zc {
12934
12946
  _s
12935
12947
  ].forEach((n) => {
12936
12948
  this.disposeWithMe(this._commandService.registerCommand(n));
12937
- }), [ro, rs, is].forEach((n) => this.disposeWithMe(this._commandService.registerMultipleCommand(n)));
12949
+ }), [so, rs, is].forEach((n) => this.disposeWithMe(this._commandService.registerMultipleCommand(n)));
12938
12950
  }
12939
12951
  _initializeShortcut() {
12940
12952
  [
@@ -12952,25 +12964,25 @@ let Pr = class extends Zc {
12952
12964
  Af,
12953
12965
  lh
12954
12966
  ].forEach((n) => {
12955
- this._injector.get(To).registerShortcut(n);
12967
+ this._injector.get(Bo).registerShortcut(n);
12956
12968
  });
12957
12969
  }
12958
12970
  _initDependencies(n) {
12959
12971
  $c([
12960
12972
  [sf],
12961
- [mo],
12962
12973
  [Eo],
12963
- [Ao],
12964
- [go],
12965
- [po],
12974
+ [Io],
12975
+ [uo],
12966
12976
  [fo],
12967
- [ho],
12977
+ [mo],
12978
+ [po],
12979
+ [go],
12968
12980
  [tn],
12969
12981
  [Ge, { useClass: Sr }],
12970
12982
  [Lt, { useClass: ur }],
12971
12983
  [Bn],
12984
+ [vo],
12972
12985
  [So],
12973
- [Io],
12974
12986
  [Pt],
12975
12987
  [at]
12976
12988
  ], this._config.override).forEach((t) => n.add(t));
@@ -12987,7 +12999,7 @@ let Pr = class extends Zc {
12987
12999
  }
12988
13000
  }
12989
13001
  _initUI() {
12990
- this._injector.get(ho);
13002
+ this._injector.get(go);
12991
13003
  }
12992
13004
  _initRenderBasics() {
12993
13005
  [
@@ -12995,7 +13007,7 @@ let Pr = class extends Zc {
12995
13007
  [Re],
12996
13008
  [nl],
12997
13009
  [ws],
12998
- [No],
13010
+ [Lo],
12999
13011
  [br],
13000
13012
  [Dr]
13001
13013
  ].forEach((n) => {
@@ -13005,18 +13017,18 @@ let Pr = class extends Zc {
13005
13017
  _initRenderModules() {
13006
13018
  [
13007
13019
  [wt],
13008
- [co],
13009
13020
  [lo],
13010
- [uo],
13021
+ [Ao],
13022
+ [ho],
13011
13023
  [_r],
13012
13024
  [Cr],
13013
13025
  [Mr],
13014
13026
  [Or],
13015
13027
  [yr],
13016
- [mo],
13028
+ [Eo],
13017
13029
  [Br],
13018
13030
  [Tr],
13019
- [Eo]
13031
+ [Io]
13020
13032
  ].forEach((n) => {
13021
13033
  this._renderManagerSrv.registerRenderModule(_.UNIVER_DOC, n);
13022
13034
  });
@@ -13025,14 +13037,14 @@ let Pr = class extends Zc {
13025
13037
  Of(Pr, "pluginName", sd);
13026
13038
  Pr = yf([
13027
13039
  Xc(Il),
13028
- hn(1, j(Dn)),
13040
+ hn(1, z(Dn)),
13029
13041
  hn(2, pe),
13030
13042
  hn(3, T),
13031
13043
  hn(4, Qr),
13032
13044
  hn(5, Vr)
13033
13045
  ], Pr);
13034
13046
  function Tf(n, e, t) {
13035
- const o = J(T), r = J(To), s = Te(() => ge(4), []);
13047
+ const o = J(T), r = J(Bo), s = Te(() => ge(4), []);
13036
13048
  Ce(() => {
13037
13049
  if (!t || !n || !e)
13038
13050
  return;
@@ -13050,7 +13062,7 @@ function Tf(n, e, t) {
13050
13062
  preconditions: () => !0,
13051
13063
  priority: 901,
13052
13064
  staticParameters: {
13053
- eventType: ra.Keyboard,
13065
+ eventType: sa.Keyboard,
13054
13066
  keyCode: d.keyCode,
13055
13067
  metaKey: d.metaKey
13056
13068
  }
@@ -13159,7 +13171,7 @@ function Mf(n) {
13159
13171
  }, []), a;
13160
13172
  }
13161
13173
  const _f = (n, e, t, o) => {
13162
- const r = J(T), s = J(To), i = ke(e);
13174
+ const r = J(T), s = J(Bo), i = ke(e);
13163
13175
  i.current = e;
13164
13176
  const a = ke(o);
13165
13177
  a.current = o, Ce(() => {
@@ -13207,7 +13219,7 @@ const _f = (n, e, t, o) => {
13207
13219
  preconditions: () => !0,
13208
13220
  priority: 900,
13209
13221
  staticParameters: {
13210
- eventType: ra.Keyboard,
13222
+ eventType: sa.Keyboard,
13211
13223
  keyCode: u
13212
13224
  }
13213
13225
  })).forEach((u) => {
@@ -13226,7 +13238,7 @@ function Df(n, e) {
13226
13238
  if (r.id === X.id) {
13227
13239
  if (r.params.unitId !== n.getEditorId()) return;
13228
13240
  const c = n.getDocumentData();
13229
- e(c, to((i = (s = c.body) == null ? void 0 : s.dataStream) != null ? i : ""));
13241
+ e(c, no((i = (s = c.body) == null ? void 0 : s.dataStream) != null ? i : ""));
13230
13242
  }
13231
13243
  });
13232
13244
  return () => {
@@ -13276,7 +13288,7 @@ const Zf = (n) => {
13276
13288
  const U = mn((k) => {
13277
13289
  var ae, oe;
13278
13290
  const ne = y == null ? void 0 : y.with(de), ie = ne == null ? void 0 : ne.getSkeleton().getActualSize();
13279
- ie && (A == null || A(ie.actualHeight), E(Math.max(u, Math.min(ie.actualHeight + 10, g)))), h == null || h(k, to((oe = (ae = k.body) == null ? void 0 : ae.dataStream) != null ? oe : "")), $();
13291
+ ie && (A == null || A(ie.actualHeight), E(Math.max(u, Math.min(ie.actualHeight + 10, g)))), h == null || h(k, no((oe = (ae = k.body) == null ? void 0 : ae.dataStream) != null ? oe : "")), $();
13280
13292
  });
13281
13293
  return Ce(() => {
13282
13294
  var ne, ie;
@@ -13289,7 +13301,7 @@ const Zf = (n) => {
13289
13301
  }, [C]), et(C == null ? void 0 : C.blur$), et(C == null ? void 0 : C.focus$), Ce(() => {
13290
13302
  var ne, ie;
13291
13303
  const k = C == null ? void 0 : C.getDocumentData();
13292
- S == null || S(F, to((ie = (ne = k == null ? void 0 : k.body) == null ? void 0 : ne.dataStream) != null ? ie : ""));
13304
+ S == null || S(F, no((ie = (ne = k == null ? void 0 : k.body) == null ? void 0 : ne.dataStream) != null ? ie : ""));
13293
13305
  }, [F, S]), Ce(() => {
13294
13306
  const k = (ie) => {
13295
13307
  var oe, he;
@@ -13303,7 +13315,7 @@ const Zf = (n) => {
13303
13315
  }, [C, x, I, v]), _f(F && a, !1, C), Tf(F, i, C), Df(C, U), /* @__PURE__ */ Q("div", { className: e, style: c, children: /* @__PURE__ */ re(
13304
13316
  "div",
13305
13317
  {
13306
- className: ze("univer-relative univer-box-border univer-flex univer-h-8 univer-w-full univer-items-center univer-justify-around univer-gap-2 univer-rounded-md univer-pb-0.5 univer-pl-1.5 univer-pr-2 univer-pt-1.5", Nn, {
13318
+ className: je("univer-relative univer-box-border univer-flex univer-h-8 univer-w-full univer-items-center univer-justify-around univer-gap-2 univer-rounded-md univer-pb-0.5 univer-pl-1.5 univer-pr-2 univer-pt-1.5", Nn, {
13307
13319
  "univer-border-primary-500": F
13308
13320
  }),
13309
13321
  style: { height: R },
@@ -13330,25 +13342,25 @@ const Zf = (n) => {
13330
13342
  ) });
13331
13343
  };
13332
13344
  export {
13333
- Mo as AfterSpaceCommand,
13334
- Uo as AlignCenterCommand,
13335
- Ho as AlignJustifyCommand,
13336
- Qo as AlignLeftCommand,
13345
+ _o as AfterSpaceCommand,
13346
+ Fo as AlignCenterCommand,
13347
+ ko as AlignJustifyCommand,
13348
+ Uo as AlignLeftCommand,
13337
13349
  lt as AlignOperationCommand,
13338
- Fo as AlignRightCommand,
13350
+ Ho as AlignRightCommand,
13339
13351
  Gr as BreakLineCommand,
13340
13352
  yn as BulletListCommand,
13341
13353
  gr as ChangeListNestingLevelCommand,
13342
13354
  qn as ChangeListNestingLevelType,
13343
- Lo as ChangeListTypeCommand,
13344
- so as CheckListCommand,
13355
+ Qo as ChangeListTypeCommand,
13356
+ io as CheckListCommand,
13345
13357
  Xd as CoverContentCommand,
13346
- ja as CreateDocTableCommand,
13358
+ za as CreateDocTableCommand,
13347
13359
  $t as CutContentCommand,
13348
13360
  id as DOCS_COMPONENT_BACKGROUND_LAYER_INDEX,
13349
13361
  $s as DOCS_COMPONENT_DEFAULT_Z_INDEX,
13350
13362
  ad as DOCS_COMPONENT_HEADER_LAYER_INDEX,
13351
- zo as DOCS_COMPONENT_MAIN_LAYER_INDEX,
13363
+ Go as DOCS_COMPONENT_MAIN_LAYER_INDEX,
13352
13364
  $e as DOCS_VIEW_KEY,
13353
13365
  sd as DOC_UI_PLUGIN_NAME,
13354
13366
  Ti as DOC_VERTICAL_PADDING,
@@ -13356,22 +13368,22 @@ export {
13356
13368
  od as DefaultToolbarConfig,
13357
13369
  xn as DeleteCommand,
13358
13370
  Zr as DeleteCustomBlockCommand,
13359
- Do as DeleteLeftCommand,
13371
+ Po as DeleteLeftCommand,
13360
13372
  xa as DeleteRightCommand,
13361
13373
  Pt as DocAutoFormatService,
13362
- uo as DocBackScrollRenderController,
13374
+ ho as DocBackScrollRenderController,
13363
13375
  Bn as DocCanvasPopManagerService,
13364
- ro as DocCopyCommand,
13376
+ so as DocCopyCommand,
13365
13377
  Os as DocCreateTableOperation,
13366
13378
  rs as DocCutCommand,
13367
13379
  wt as DocEventManagerService,
13368
- No as DocIMEInputManagerService,
13380
+ Lo as DocIMEInputManagerService,
13369
13381
  is as DocPasteCommand,
13370
13382
  sf as DocPrintInterceptorService,
13371
13383
  br as DocRenderController,
13372
13384
  Ta as DocSelectAllCommand,
13373
13385
  Re as DocSelectionRenderService,
13374
- Io as DocStateChangeManagerService,
13386
+ So as DocStateChangeManagerService,
13375
13387
  Ss as DocTableDeleteColumnsCommand,
13376
13388
  Is as DocTableDeleteRowsCommand,
13377
13389
  Hn as DocTableDeleteTableCommand,
@@ -13380,16 +13392,16 @@ export {
13380
13392
  ys as DocTableInsertColumnRightCommand,
13381
13393
  Rs as DocTableInsertRowAboveCommand,
13382
13394
  bs as DocTableInsertRowBellowCommand,
13383
- za as DocTableInsertRowCommand,
13395
+ ja as DocTableInsertRowCommand,
13384
13396
  Ga as DocTableTabCommand,
13385
- Ao as DocUIController,
13386
- So as DocsRenderService,
13397
+ uo as DocUIController,
13398
+ vo as DocsRenderService,
13387
13399
  ug as DocsUIMenuSchema,
13388
13400
  HA as Editor,
13389
13401
  _d as EditorInsertTextCommandId,
13390
13402
  Sr as EditorService,
13391
13403
  bn as EnterCommand,
13392
- wo as HorizontalLineCommand,
13404
+ No as HorizontalLineCommand,
13393
13405
  Lt as IDocClipboardService,
13394
13406
  Ge as IEditorService,
13395
13407
  Ba as IMEInputCommand,
@@ -13400,7 +13412,7 @@ export {
13400
13412
  Jr as MergeTwoParagraphCommand,
13401
13413
  St as MoveCursorOperation,
13402
13414
  vt as MoveSelectionOperation,
13403
- jf as NORMAL_TEXT_SELECTION_PLUGIN_NAME,
13415
+ zf as NORMAL_TEXT_SELECTION_PLUGIN_NAME,
13404
13416
  It as NodePositionConvertToCursor,
13405
13417
  Va as NodePositionConvertToRectRange,
13406
13418
  On as OrderListCommand,
@@ -13429,7 +13441,7 @@ export {
13429
13441
  mt as SetInlineFormatTextColorCommand,
13430
13442
  Ft as SetInlineFormatUnderlineCommand,
13431
13443
  Xe as SetParagraphNamedStyleCommand,
13432
- ko as SwitchDocModeCommand,
13444
+ Vo as SwitchDocModeCommand,
13433
13445
  mr as TEXT_RANGE_LAYER_INDEX,
13434
13446
  Jt as TabCommand,
13435
13447
  Zt as TextRange,
@@ -13439,9 +13451,9 @@ export {
13439
13451
  We as VIEWPORT_KEY,
13440
13452
  Gf as addCustomDecorationBySelectionFactory,
13441
13453
  ld as addCustomDecorationFactory,
13442
- nr as calcDocRangePositions,
13454
+ or as calcDocRangePositions,
13443
13455
  Wd as convertBodyToHtml,
13444
- Jo as convertPositionsToRectRanges,
13456
+ $o as convertPositionsToRectRanges,
13445
13457
  Yf as deleteCustomDecorationFactory,
13446
13458
  qf as docDrawingPositionToTransform,
13447
13459
  Ea as genTableSource,
@@ -13453,7 +13465,7 @@ export {
13453
13465
  bd as getCustomBlockIdsInSelections,
13454
13466
  Md as getCutActionsFromDocRanges,
13455
13467
  cd as getDocObject,
13456
- zf as getDocObjectById,
13468
+ jf as getDocObjectById,
13457
13469
  Kr as getEmptyTableCell,
13458
13470
  qr as getEmptyTableRow,
13459
13471
  Es as getLineBounding,