@ones-editor/editor 2.1.1-beta.73 → 2.1.1-beta.74

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (24) hide show
  1. package/@ones-editor/core/src/core/command-providers/block-attributes.d.ts +2 -0
  2. package/@ones-editor/core/src/core/containers/root-container.d.ts +0 -3
  3. package/@ones-editor/mobile-helper/src/fixed-toolbar/providers/insert-menu.d.ts +2 -4
  4. package/@ones-editor/mobile-helper/src/fixed-toolbar/toolbar-handler.d.ts +1 -1
  5. package/@ones-editor/mobile-helper/src/index.d.ts +1 -1
  6. package/@ones-editor/table-block/src/index.d.ts +2 -5
  7. package/@ones-editor/text-commands/src/index.d.ts +0 -1
  8. package/@ones-editor/tsconfig.tsbuildinfo +1 -1
  9. package/@ones-editor/ui/src/locale/en-us.d.ts +8 -0
  10. package/@ones-editor/ui/src/locale/ja-jp.d.ts +8 -0
  11. package/@ones-editor/ui/src/locale/zh-cn.d.ts +8 -0
  12. package/@ones-editor/ui/src/providers/utils/text-styles.d.ts +1 -1
  13. package/@ones-editor/ui-base/src/color-palette/color-palette.d.ts +1 -1
  14. package/@ones-editor/ui-base/src/index.d.ts +1 -1
  15. package/@ones-editor/ui-base/src/mobile-command-bar/mobile-bottom-menu.d.ts +0 -1
  16. package/@ones-editor/ui-base/src/mobile-command-bar/scroll-into-view.d.ts +1 -1
  17. package/dist/index.js +255 -450
  18. package/package.json +1 -1
  19. package/@ones-editor/text-commands/src/locale/en-us.d.ts +0 -13
  20. package/@ones-editor/text-commands/src/locale/index.d.ts +0 -1
  21. package/@ones-editor/text-commands/src/locale/ja-jp.d.ts +0 -13
  22. package/@ones-editor/text-commands/src/locale/zh-cn.d.ts +0 -13
  23. package/@ones-editor/ui/src/providers/utils/text-commands.d.ts +0 -3
  24. /package/@ones-editor/table-block/src/commands/{table-command-provider.d.ts → mobile-command-provider.d.ts} +0 -0
package/dist/index.js CHANGED
@@ -443,6 +443,9 @@ div.comment-editor-root div.root.select-all > .container-blocks > div[data-type=
443
443
  }.editor-command-bar.toolbar .command-item.disabled .color-button {
444
444
  color: #c7c7c7;
445
445
  }
446
+ .editor-command-bar.toolbar .command-item-paste.disabled {
447
+ color: #c7c7c7;
448
+ }
446
449
  .editor-command-bar.toolbar .color-button {
447
450
  width: 24px;
448
451
  height: 24px;
@@ -2022,12 +2025,6 @@ div.tippy-box[data-theme=editor-tooltip] > .tippy-content {
2022
2025
  :root div.tippy-box[data-theme=editor-tooltip] > .tippy-content > div > span:nth-of-type(2) {
2023
2026
  font-weight: 400;
2024
2027
  }
2025
- [data-command-bar-id] .command-item.disabled > .color-button svg {
2026
- color: #b2bccd;
2027
- }
2028
- [data-command-bar-id] .command-item .command-item-paste.disabled {
2029
- color: #c7c7c7;
2030
- }
2031
2028
  [data-command-bar-id=cursor-toolbar].mobile .tippy-box,
2032
2029
  [data-command-bar-id=paste-special-button].mobile .tippy-box,
2033
2030
  [data-command-bar-id=editor-toolbar].mobile .tippy-box {
@@ -4675,10 +4672,6 @@ div[data-command-bar-id=table-row-column-toolbar] .tippy-box .tippy-content butt
4675
4672
  div[data-command-bar-id=table-cell-menu] .tippy-box .tippy-content .editor-command-bar.menu .command-item.selected[data-id=delete-select-row], div[data-command-bar-id=table-cell-menu] .tippy-box .tippy-content .editor-command-bar.menu .command-item.selected[data-id=delete-select-col] {
4676
4673
  color: #eb3723;
4677
4674
  background-color: #fff6f5;
4678
- }
4679
- .editor-root.mobile [data-type=editor-container].root div[data-type=editor-block].table-block div[data-type=block-tools] .table-border-bar-container .table-border-bar .button-root,
4680
- .editor-root.mobile [data-type=editor-container].root div[data-type=editor-block].table-block div[data-type=table-tools] .table-border-bar-container .table-border-bar .button-root {
4681
- display: none;
4682
4675
  }.editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] .block-anchor[data-id=paste-special-button-anchor] {
4683
4676
  z-index: unset;
4684
4677
  }
@@ -6432,7 +6425,7 @@ div[data-command-bar-id=mobile-bottom-menu] .mobile-menu-wrap.editor-mention .co
6432
6425
  width: 100%;
6433
6426
  display: flex;
6434
6427
  align-items: center;
6435
- border-top: 1px solid #DFE1E5;
6428
+ border-top: 1px solid #dfe1e5;
6436
6429
  }
6437
6430
  .command-m-bar > .editor-command-bar-root {
6438
6431
  scrollbar-width: none;
@@ -6443,68 +6436,25 @@ div[data-command-bar-id=mobile-bottom-menu] .mobile-menu-wrap.editor-mention .co
6443
6436
  .command-m-bar > .editor-command-bar-root::-webkit-scrollbar {
6444
6437
  display: none;
6445
6438
  }
6446
- .command-m-bar > .editor-command-bar-root.overflowing::after {
6439
+ .command-m-bar > .editor-command-bar-root .overflowing-float, .command-m-bar > .editor-command-bar-root .command-m-bar > .editor-command-bar-root.overflowing::before, .command-m-bar > .editor-command-bar-root .command-m-bar > .editor-command-bar-root.overflowing::after {
6447
6440
  content: "";
6448
6441
  position: absolute;
6449
6442
  top: 0;
6450
- right: 0;
6443
+ left: 0;
6451
6444
  bottom: 0;
6452
6445
  width: 10px;
6453
- background: linear-gradient(90deg, rgba(255, 255, 255, 0) 0, rgb(255, 255, 255));
6454
6446
  z-index: 1;
6455
6447
  pointer-events: none;
6456
6448
  }
6449
+ .command-m-bar > .editor-command-bar-root.overflowing::after {
6450
+ background: linear-gradient(90deg, rgba(255, 255, 255, 0) 0, rgb(255, 255, 255));
6451
+ }
6457
6452
  .command-m-bar > .editor-command-bar-root.overflowing::before {
6458
- content: "";
6459
- position: absolute;
6460
- top: 0;
6461
- left: 0;
6462
- bottom: 0;
6463
- width: 10px;
6464
6453
  background: linear-gradient(90deg, rgb(255, 255, 255) 0, rgba(255, 255, 255, 0));
6465
- z-index: 1;
6466
- pointer-events: none;
6467
6454
  }
6468
6455
  .command-m-bar > .editor-command-bar-root > .editor-command-bar {
6469
6456
  width: max-content;
6470
6457
  max-width: max-content;
6471
- }
6472
- .command-m-bar .command-m-container {
6473
- display: flex;
6474
- }
6475
- .command-m-bar .child-layout {
6476
- height: 280px;
6477
- width: 100%;
6478
- display: flex;
6479
- display: none;
6480
- padding-top: 20px;
6481
- position: relative;
6482
- }
6483
- .command-m-bar .child-layout.card {
6484
- flex-wrap: wrap;
6485
- gap: 15px;
6486
- justify-content: flex-start;
6487
- }
6488
- .command-m-bar .child-layout.card .child-item {
6489
- width: 80px;
6490
- height: 80px;
6491
- display: flex;
6492
- align-items: center;
6493
- justify-content: center;
6494
- border: 1px solid #ccc;
6495
- }
6496
- .command-m-bar .child-layout.menu {
6497
- flex-direction: column;
6498
- }
6499
- .command-m-bar .child-layout.menu .child-item {
6500
- width: 100%;
6501
- height: 32px;
6502
- line-height: 32px;
6503
- }
6504
- .command-m-bar .child-layout.menu .child-layout-close {
6505
- position: absolute;
6506
- right: 20px;
6507
- top: 20px;
6508
6458
  }[data-command-bar-id=editor-toolbar] .editor-content div[data-type=editor-block] div[data-type=block-tools] div.select-handle,
6509
6459
  .editor-root .editor-content div[data-type=editor-block] div[data-type=block-tools] div.select-handle {
6510
6460
  position: absolute;
@@ -7823,7 +7773,7 @@ var __publicField = (obj, key, value) => {
7823
7773
  loggerClass.set(category, instance);
7824
7774
  return instance;
7825
7775
  }
7826
- const enUS$y = {
7776
+ const enUS$x = {
7827
7777
  name: "ONES Editor",
7828
7778
  date: {
7829
7779
  dateFromFuture: "From the future",
@@ -7843,7 +7793,7 @@ var __publicField = (obj, key, value) => {
7843
7793
  imageExportFailed: "Failed to load image"
7844
7794
  }
7845
7795
  };
7846
- const zhCN$y = {
7796
+ const zhCN$x = {
7847
7797
  name: "Ones Editor",
7848
7798
  date: {
7849
7799
  dateFromFuture: "\u6765\u81EA\u672A\u6765",
@@ -7863,7 +7813,7 @@ var __publicField = (obj, key, value) => {
7863
7813
  imageExportFailed: "\u56FE\u7247\u52A0\u8F7D\u5931\u8D25"
7864
7814
  }
7865
7815
  };
7866
- const jaJP$y = {
7816
+ const jaJP$x = {
7867
7817
  name: "ONES \u30A8\u30C7\u30A3\u30BF\u30FC",
7868
7818
  date: {
7869
7819
  dateFromFuture: "\u672A\u6765\u304B\u3089",
@@ -7885,9 +7835,9 @@ var __publicField = (obj, key, value) => {
7885
7835
  };
7886
7836
  const logger$4C = getLogger("i18n");
7887
7837
  const langs$3 = {
7888
- "en-US": enUS$y,
7889
- "zh-CN": zhCN$y,
7890
- "ja-JP": jaJP$y
7838
+ "en-US": enUS$x,
7839
+ "zh-CN": zhCN$x,
7840
+ "ja-JP": jaJP$x
7891
7841
  };
7892
7842
  const i18n = KiwiIntl__default.default.init("en-US", langs$3);
7893
7843
  let currentLang = "en-US";
@@ -11214,16 +11164,6 @@ var __publicField = (obj, key, value) => {
11214
11164
  __publicField(this, "isMoved", false);
11215
11165
  __publicField(this, "mouseDownEvent", null);
11216
11166
  __publicField(this, "dbClickRef", null);
11217
- __publicField(this, "isMove", false);
11218
- __publicField(this, "handleTouchMove", (e2) => {
11219
- this.isMove = true;
11220
- });
11221
- __publicField(this, "handleTouchEnd", (e2) => {
11222
- if (this.isMove) {
11223
- e2.stopPropagation();
11224
- }
11225
- this.isMove = false;
11226
- });
11227
11167
  __publicField(this, "handleContextMenu", (event) => {
11228
11168
  if (clientType.isSafari) {
11229
11169
  const sel = document.getSelection();
@@ -11366,8 +11306,6 @@ var __publicField = (obj, key, value) => {
11366
11306
  const container = this.editor.rootElement;
11367
11307
  if (clientType.isMobile) {
11368
11308
  container.ontouchend = this.handleMouseDown;
11369
- window.addEventListener("touchmove", this.handleTouchMove);
11370
- window.addEventListener("touchend", this.handleTouchEnd, true);
11371
11309
  } else {
11372
11310
  container.onmousedown = this.handleMouseDown;
11373
11311
  container.oncontextmenu = this.handleContextMenu;
@@ -11387,8 +11325,6 @@ var __publicField = (obj, key, value) => {
11387
11325
  container.onclick = null;
11388
11326
  container.oncontextmenu = null;
11389
11327
  container.ontouchend = null;
11390
- window.removeEventListener("touchmove", this.handleTouchMove);
11391
- window.removeEventListener("touchend", this.handleTouchEnd, true);
11392
11328
  if (this.dbClickRef) {
11393
11329
  this.dbClickRef();
11394
11330
  this.dbClickRef = null;
@@ -25116,7 +25052,7 @@ var __publicField = (obj, key, value) => {
25116
25052
  const rect = target.getBoundingClientRect();
25117
25053
  return rect.right > visibleRect.right || rect.left < visibleRect.left;
25118
25054
  }
25119
- function scrollIntoView$1(editor, target, options) {
25055
+ function scrollIntoView(editor, target, options) {
25120
25056
  var _a;
25121
25057
  if (!target) {
25122
25058
  return;
@@ -25181,10 +25117,10 @@ var __publicField = (obj, key, value) => {
25181
25117
  const delayEmbedBlockTypes = ["image"];
25182
25118
  if (delayEmbedBlockTypes.includes(getEmbedType(block))) {
25183
25119
  setTimeout(() => {
25184
- scrollIntoView$1(editor, next2, { animation: true });
25120
+ scrollIntoView(editor, next2, { animation: true });
25185
25121
  }, 500);
25186
25122
  } else {
25187
- scrollIntoView$1(editor, next2, { animation: true });
25123
+ scrollIntoView(editor, next2, { animation: true });
25188
25124
  }
25189
25125
  return;
25190
25126
  }
@@ -25195,7 +25131,7 @@ var __publicField = (obj, key, value) => {
25195
25131
  const anchorElem = createElement("div", ["editor-block-anchor"], tools);
25196
25132
  const scale = getElementScale(block);
25197
25133
  anchorElem.style.top = `${(rect.top - blockRect.top) / scale}px`;
25198
- scrollIntoView$1(editor, anchorElem, { animation: true });
25134
+ scrollIntoView(editor, anchorElem, { animation: true });
25199
25135
  setTimeout(() => {
25200
25136
  anchorElem.remove();
25201
25137
  }, 200);
@@ -30514,9 +30450,18 @@ ${codeText}
30514
30450
  constructor(editor) {
30515
30451
  __publicField(this, "textBlockAttributes", /* @__PURE__ */ new Map());
30516
30452
  __publicField(this, "activeBlockAttributes", /* @__PURE__ */ new Map());
30453
+ __publicField(this, "lastRange");
30517
30454
  __publicField(this, "clear", () => {
30518
30455
  this.activeBlockAttributes.clear();
30519
30456
  });
30457
+ __publicField(this, "handleSelectionChanged", () => {
30458
+ var _a, _b, _c, _d;
30459
+ const range = this.editor.selection.range;
30460
+ if (range.isSimple() && ((_a = this.lastRange) == null ? void 0 : _a.start.blockId) === range.start.blockId && ((_b = this.lastRange) == null ? void 0 : _b.end.blockId) === range.end.blockId && ((_c = this.lastRange) == null ? void 0 : _c.start.offset) === range.start.offset && ((_d = this.lastRange) == null ? void 0 : _d.end.offset) === range.end.offset) {
30461
+ return;
30462
+ }
30463
+ this.clear();
30464
+ });
30520
30465
  __publicField(this, "setActiveBlockAttributes", (attributes) => {
30521
30466
  Array.from(this.activeBlockAttributes).forEach(([key, value]) => {
30522
30467
  const op = { attributes, insert: "" };
@@ -30543,11 +30488,11 @@ ${codeText}
30543
30488
  });
30544
30489
  this.editor = editor;
30545
30490
  this.editor.addListener("docChanged", this.clear);
30546
- this.editor.addListener("selectionChanged", this.clear);
30491
+ this.editor.addListener("selectionChanged", this.handleSelectionChanged);
30547
30492
  }
30548
30493
  destroy() {
30549
30494
  this.editor.removeListener("docChanged", this.clear);
30550
- this.editor.removeListener("selectionChanged", this.clear);
30495
+ this.editor.removeListener("selectionChanged", this.handleSelectionChanged);
30551
30496
  }
30552
30497
  getEmptyBlockTextAttributes(blockId) {
30553
30498
  var _a;
@@ -38585,7 +38530,7 @@ ${codeText}
38585
38530
  handler.removeListener("insert", callback);
38586
38531
  }
38587
38532
  const style$c = "";
38588
- const zhCN$x = {
38533
+ const zhCN$w = {
38589
38534
  colorPalette: {
38590
38535
  colorDesc: "\u5B57\u4F53\u989C\u8272",
38591
38536
  name: "\u6587\u672C\u989C\u8272",
@@ -38616,7 +38561,7 @@ ${codeText}
38616
38561
  emptyTips: "\u6682\u65E0\u641C\u7D22\u7ED3\u679C"
38617
38562
  }
38618
38563
  };
38619
- const enUS$x = {
38564
+ const enUS$w = {
38620
38565
  colorPalette: {
38621
38566
  colorDesc: "Text color",
38622
38567
  name: "Text color",
@@ -38647,7 +38592,7 @@ ${codeText}
38647
38592
  emptyTips: "No results found"
38648
38593
  }
38649
38594
  };
38650
- const jaJP$x = {
38595
+ const jaJP$w = {
38651
38596
  colorPalette: {
38652
38597
  colorDesc: "\u30D5\u30A9\u30F3\u30C8\u306E\u8272",
38653
38598
  name: "\u30C6\u30AD\u30B9\u30C8\u306E\u8272",
@@ -38679,9 +38624,9 @@ ${codeText}
38679
38624
  }
38680
38625
  };
38681
38626
  i18n$1.mergeLang({
38682
- "zh-CN": zhCN$x,
38683
- "en-US": enUS$x,
38684
- "ja-JP": jaJP$x
38627
+ "zh-CN": zhCN$w,
38628
+ "en-US": enUS$w,
38629
+ "ja-JP": jaJP$w
38685
38630
  });
38686
38631
  const button = "";
38687
38632
  getLogger("button");
@@ -39162,9 +39107,6 @@ ${codeText}
39162
39107
  if (!item) {
39163
39108
  return;
39164
39109
  }
39165
- if (item.switchable && !(target == null ? void 0 : target.closest(".menu-item-checked-icon"))) {
39166
- return;
39167
- }
39168
39110
  const customItem = (item == null ? void 0 : item.element) && !item.children;
39169
39111
  if (clientType.isMobile && !customItem) {
39170
39112
  event.preventDefault();
@@ -40385,22 +40327,6 @@ ${codeText}
40385
40327
  }
40386
40328
  }, 200);
40387
40329
  });
40388
- __publicField(this, "getSubBarOptions", (item) => {
40389
- var _a, _b;
40390
- const getReferenceClientRect2 = () => {
40391
- const elem = this.getItemElementById(item.id);
40392
- const content = this.content;
40393
- const contentRect = content.getBoundingClientRect();
40394
- const elemRect = elem.getBoundingClientRect();
40395
- return new DOMRect(elemRect.left, contentRect.top, elemRect.width, contentRect.height);
40396
- };
40397
- const options = {
40398
- placement: (_a = item.childrenPlacement) != null ? _a : "top",
40399
- getReferenceClientRect: getReferenceClientRect2,
40400
- offset: (_b = item.childrenOffset) != null ? _b : [0, 4]
40401
- };
40402
- return options;
40403
- });
40404
40330
  }
40405
40331
  close(reason) {
40406
40332
  var _a;
@@ -41031,9 +40957,7 @@ ${codeText}
41031
40957
  this.errorContent.innerText = error2;
41032
40958
  });
41033
40959
  __publicField(this, "focus", () => {
41034
- setTimeout(() => {
41035
- this.input.focus();
41036
- }, 200);
40960
+ this.input.focus();
41037
40961
  });
41038
40962
  __publicField(this, "handleKeyDown", (e2, composing) => {
41039
40963
  var _a, _b;
@@ -41982,7 +41906,7 @@ ${codeText}
41982
41906
  return new EmojiItem();
41983
41907
  }
41984
41908
  }
41985
- const scrollIntoView = (bar2, editor) => {
41909
+ const scrollBarIntoView = (editor, bar2) => {
41986
41910
  var _a;
41987
41911
  const activeRect = getBlockClientRects(editor, editor.selection.endBlock, editor.selection.range);
41988
41912
  const popperRect = (_a = bar2.popper) == null ? void 0 : _a.getBoundingClientRect();
@@ -44055,44 +43979,19 @@ ${codeText}
44055
43979
  if (getBlockType(block) !== "table" || clientType.isMobile) {
44056
43980
  return [];
44057
43981
  }
44058
- const ext = {
44059
- blockId: getBlockId(block),
44060
- blockKind: getBlockKind(editor, block),
44061
- blockType: getBlockType(block)
44062
- };
44063
43982
  const commands = [];
44064
- const { selectedColumns, selectedRows } = getTableSelectedRowsAndColumns(editor, block);
44065
- if (clientType.isMobile) {
44066
- if (selectedColumns.size > 0) {
44067
- commands.push({
44068
- id: "table/delete-columns",
44069
- name: i18n$1.t("table.deleteSelectCol"),
44070
- icon: DeleteColIcon,
44071
- ...ext
44072
- });
44073
- } else if (selectedRows.size > 0) {
44074
- commands.push({
44075
- id: "table/delete-rows",
44076
- name: i18n$1.t("table.deleteSelectRow"),
44077
- icon: DeleteRowIcon,
44078
- ...ext
44079
- });
44080
- }
44081
- }
44082
43983
  if (canMergeCells(editor, block, range)) {
44083
43984
  commands.push({
44084
43985
  id: "table/merge-cells",
44085
43986
  name: i18n$1.t("table.mergeCell"),
44086
- icon: MergeCellIcon,
44087
- ...ext
43987
+ icon: MergeCellIcon
44088
43988
  });
44089
43989
  }
44090
43990
  if (canSplitCell(editor, block, range)) {
44091
43991
  commands.push({
44092
43992
  id: "table/split-cell",
44093
43993
  name: i18n$1.t("table.splitCell"),
44094
- icon: SplitCellIcon,
44095
- ...ext
43994
+ icon: SplitCellIcon
44096
43995
  });
44097
43996
  }
44098
43997
  const deleteColumns2 = canDeleteColumns(editor, block, range);
@@ -44101,8 +44000,7 @@ ${codeText}
44101
44000
  commands.push({
44102
44001
  id: "table/delete",
44103
44002
  name: i18n$1.t("table.deleteTable"),
44104
- icon: DeleteTableIcon,
44105
- ...ext
44003
+ icon: DeleteTableIcon
44106
44004
  });
44107
44005
  }
44108
44006
  return commands;
@@ -46164,28 +46062,28 @@ ${codeText}
46164
46062
  }
46165
46063
  }
46166
46064
  const exclusiveBlockStyles = "";
46167
- const zhCN$w = {
46065
+ const zhCN$v = {
46168
46066
  exclusive: {
46169
46067
  tips: "\u300C{editor}\u300D\u6B63\u5728\u7F16\u8F91\uFF0C\u300C{embedType}\u300D\u4E0D\u652F\u6301\u591A\u4EBA\u7F16\u8F91",
46170
46068
  fallbackAbstract: "\u8BE5 Block"
46171
46069
  }
46172
46070
  };
46173
- const enUS$w = {
46071
+ const enUS$v = {
46174
46072
  exclusive: {
46175
46073
  tips: "\u300C{editor}\u300Dis editing\uFF0C\u300C{embedType}\u300Ddoes not support multi-person editing",
46176
46074
  fallbackAbstract: "This Block"
46177
46075
  }
46178
46076
  };
46179
- const jaJP$w = {
46077
+ const jaJP$v = {
46180
46078
  exclusive: {
46181
46079
  tips: "\u300C{editor}\u300D\u306F\u7DE8\u96C6\u4E2D\u3067\u3059\u3002\u300C{embedType}\u300D\u306F\u8907\u6570\u4EBA\u3067\u540C\u6642\u7DE8\u96C6\u3067\u304D\u307E\u305B\u3093",
46182
46080
  fallbackAbstract: "\u3053\u306E\u8981\u7D20"
46183
46081
  }
46184
46082
  };
46185
46083
  i18n$1.mergeLang({
46186
- "zh-CN": zhCN$w,
46187
- "en-US": enUS$w,
46188
- "ja-JP": jaJP$w
46084
+ "zh-CN": zhCN$v,
46085
+ "en-US": enUS$v,
46086
+ "ja-JP": jaJP$v
46189
46087
  });
46190
46088
  function getBlockInfo(editor, block) {
46191
46089
  const data2 = editor.getBlockData(block);
@@ -46362,21 +46260,21 @@ ${codeText}
46362
46260
  }
46363
46261
  }
46364
46262
  const style$a = "";
46365
- const zhCN$v = {
46263
+ const zhCN$u = {
46366
46264
  locker: {
46367
46265
  lock: "\u9501\u5B9A",
46368
46266
  unlock: "\u89E3\u9664\u9501\u5B9A",
46369
46267
  lockedBy: "\u88AB {name} \u9501\u5B9A"
46370
46268
  }
46371
46269
  };
46372
- const enUS$v = {
46270
+ const enUS$u = {
46373
46271
  locker: {
46374
46272
  lock: "Lock",
46375
46273
  unlock: "Unlock",
46376
46274
  lockedBy: "Locked by {name}"
46377
46275
  }
46378
46276
  };
46379
- const jaJP$v = {
46277
+ const jaJP$u = {
46380
46278
  locker: {
46381
46279
  lock: "\u30ED\u30C3\u30AF",
46382
46280
  unlock: "\u30ED\u30C3\u30AF\u89E3\u9664",
@@ -46384,9 +46282,9 @@ ${codeText}
46384
46282
  }
46385
46283
  };
46386
46284
  i18n$1.mergeLang({
46387
- "zh-CN": zhCN$v,
46388
- "en-US": enUS$v,
46389
- "ja-JP": jaJP$v
46285
+ "zh-CN": zhCN$u,
46286
+ "en-US": enUS$u,
46287
+ "ja-JP": jaJP$u
46390
46288
  });
46391
46289
  class BlockLockerPasteHandler {
46392
46290
  async handleBeforePasteDoc(editor, doc2) {
@@ -49240,7 +49138,7 @@ ${codeText}
49240
49138
  }
49241
49139
  return blockContent;
49242
49140
  }
49243
- const zhCN$u = {
49141
+ const zhCN$t = {
49244
49142
  list: {
49245
49143
  confirm: "\u786E\u5B9A",
49246
49144
  setStart: "\u8BBE\u7F6E\u7F16\u53F7",
@@ -49260,7 +49158,7 @@ ${codeText}
49260
49158
  exitFullscreen: "\u9000\u51FA\u5168\u5C4F"
49261
49159
  }
49262
49160
  };
49263
- const enUS$u = {
49161
+ const enUS$t = {
49264
49162
  list: {
49265
49163
  confirm: "Confirm",
49266
49164
  setStart: "Set number",
@@ -49280,7 +49178,7 @@ ${codeText}
49280
49178
  exitFullscreen: "Exit full screen"
49281
49179
  }
49282
49180
  };
49283
- const jaJP$u = {
49181
+ const jaJP$t = {
49284
49182
  list: {
49285
49183
  confirm: "OK",
49286
49184
  setStart: "\u756A\u53F7\u3092\u8A2D\u5B9A",
@@ -49301,9 +49199,9 @@ ${codeText}
49301
49199
  }
49302
49200
  };
49303
49201
  i18n$1.mergeLang({
49304
- "zh-CN": zhCN$u,
49305
- "en-US": enUS$u,
49306
- "ja-JP": jaJP$u
49202
+ "zh-CN": zhCN$t,
49203
+ "en-US": enUS$t,
49204
+ "ja-JP": jaJP$t
49307
49205
  });
49308
49206
  const style$9 = "";
49309
49207
  const logger$1W = getLogger("list-block:paste-handler");
@@ -49714,7 +49612,7 @@ ${codeText}
49714
49612
  this.close();
49715
49613
  });
49716
49614
  __publicField(this, "handleShown", () => {
49717
- scrollIntoView(this.linkPopup, this.editor);
49615
+ scrollBarIntoView(this.editor, this.linkPopup);
49718
49616
  });
49719
49617
  __publicField(this, "disabledSubmit", () => {
49720
49618
  var _a;
@@ -51395,28 +51293,28 @@ $$${mathData.mathjaxText}$$
51395
51293
  getBlockProperties: getBlockProperties$b
51396
51294
  };
51397
51295
  const mathjaxStyle = "";
51398
- const zhCN$t = {
51296
+ const zhCN$s = {
51399
51297
  mathjax: {
51400
51298
  emptyText: "\u7A7A\u7684\u516C\u5F0F",
51401
51299
  abstract: "\u516C\u5F0F"
51402
51300
  }
51403
51301
  };
51404
- const enUS$t = {
51302
+ const enUS$s = {
51405
51303
  mathjax: {
51406
51304
  emptyText: "Empty formula",
51407
51305
  abstract: "Formula"
51408
51306
  }
51409
51307
  };
51410
- const jaJP$t = {
51308
+ const jaJP$s = {
51411
51309
  mathjax: {
51412
51310
  emptyText: "\u6570\u5F0F\u306A\u3057",
51413
51311
  abstract: "\u6570\u5F0F"
51414
51312
  }
51415
51313
  };
51416
51314
  i18n$1.mergeLang({
51417
- "zh-CN": zhCN$t,
51418
- "en-US": enUS$t,
51419
- "ja-JP": jaJP$t
51315
+ "zh-CN": zhCN$s,
51316
+ "en-US": enUS$s,
51317
+ "ja-JP": jaJP$s
51420
51318
  });
51421
51319
  function convertToMath(editor, containerId, blockIndex, offset) {
51422
51320
  const block = editor.getBlockByIndex(containerId, blockIndex);
@@ -57182,7 +57080,7 @@ $$${mathData.mathjaxText}$$
57182
57080
  }
57183
57081
  }
57184
57082
  __publicField(StatusBoxCommand, "id", "insert-status");
57185
- const enUS$s = {
57083
+ const enUS$r = {
57186
57084
  status: {
57187
57085
  empty: "Set status",
57188
57086
  command: {
@@ -57206,7 +57104,7 @@ $$${mathData.mathjaxText}$$
57206
57104
  }
57207
57105
  }
57208
57106
  };
57209
- const zhCN$s = {
57107
+ const zhCN$r = {
57210
57108
  status: {
57211
57109
  empty: "\u8BBE\u7F6E\u72B6\u6001",
57212
57110
  command: {
@@ -57230,7 +57128,7 @@ $$${mathData.mathjaxText}$$
57230
57128
  }
57231
57129
  }
57232
57130
  };
57233
- const jaJP$s = {
57131
+ const jaJP$r = {
57234
57132
  status: {
57235
57133
  empty: "\u30B9\u30C6\u30FC\u30BF\u30B9\u3092\u8A2D\u5B9A",
57236
57134
  command: {
@@ -57255,9 +57153,9 @@ $$${mathData.mathjaxText}$$
57255
57153
  }
57256
57154
  };
57257
57155
  const langs$2 = {
57258
- "en-US": enUS$s,
57259
- "zh-CN": zhCN$s,
57260
- "ja-JP": jaJP$s
57156
+ "en-US": enUS$r,
57157
+ "zh-CN": zhCN$r,
57158
+ "ja-JP": jaJP$r
57261
57159
  };
57262
57160
  i18n$1.mergeLang(langs$2);
57263
57161
  const logger$1M = getLogger("inline-box-items");
@@ -57464,7 +57362,7 @@ $$${mathData.mathjaxText}$$
57464
57362
  }
57465
57363
  });
57466
57364
  };
57467
- class InsertMenuProvider$1 extends ProxyProvider {
57365
+ class InsertMenuProvider extends ProxyProvider {
57468
57366
  constructor(editor, options) {
57469
57367
  var _a, _b, _c, _d, _e, _f, _g;
57470
57368
  super();
@@ -57646,7 +57544,7 @@ $$${mathData.mathjaxText}$$
57646
57544
  return {};
57647
57545
  });
57648
57546
  this.editor = editor;
57649
- this.registerCommandProvider(new InsertMenuProvider$1(editor, { withPlainText: false }));
57547
+ this.registerCommandProvider(new InsertMenuProvider(editor, { withPlainText: false }));
57650
57548
  }
57651
57549
  getCommands(range) {
57652
57550
  var _a, _b;
@@ -57988,8 +57886,7 @@ $$${mathData.mathjaxText}$$
57988
57886
  function getTextCommands(editor, blockCommands) {
57989
57887
  const styleCommandsSet = new Set(Object.keys(TextCommands));
57990
57888
  const styleCommands = blockCommands.filter((command) => styleCommandsSet.has(command.id));
57991
- const commands = mergeCommands(styleCommands);
57992
- return commands;
57889
+ return styleCommands;
57993
57890
  }
57994
57891
  function executeShortcut(editor, style2) {
57995
57892
  if (!editor.isWritable()) {
@@ -58043,7 +57940,7 @@ $$${mathData.mathjaxText}$$
58043
57940
  "CtrlOrCmd+K": (editor) => executeShortcut(editor, "link"),
58044
57941
  ...headingShortcut()
58045
57942
  };
58046
- const zhCN$r = {
57943
+ const zhCN$q = {
58047
57944
  quickMenu: {
58048
57945
  basic: {
58049
57946
  heading: {
@@ -58087,10 +57984,18 @@ $$${mathData.mathjaxText}$$
58087
57984
  text: "\u6B63\u6587",
58088
57985
  paste: "\u7C98\u8D34",
58089
57986
  tab: "Tab",
58090
- shiftTab: "Shift+Tab"
57987
+ shiftTab: "Shift+Tab",
57988
+ bold: "\u7C97\u4F53",
57989
+ italic: "\u659C\u4F53",
57990
+ underline: "\u4E0B\u5212\u7EBF",
57991
+ strikethrough: "\u5220\u9664\u7EBF",
57992
+ code: "\u884C\u5185\u4EE3\u7801",
57993
+ subscript: "\u4E0B\u6807",
57994
+ superscript: "\u4E0A\u6807",
57995
+ more: "\u66F4\u591A"
58091
57996
  }
58092
57997
  };
58093
- const enUS$r = {
57998
+ const enUS$q = {
58094
57999
  quickMenu: {
58095
58000
  basic: {
58096
58001
  heading: {
@@ -58134,10 +58039,18 @@ $$${mathData.mathjaxText}$$
58134
58039
  text: "Text",
58135
58040
  paste: "Paste",
58136
58041
  tab: "Tab",
58137
- shiftTab: "Shift+Tab"
58042
+ shiftTab: "Shift+Tab",
58043
+ bold: "Bold",
58044
+ italic: "Italic",
58045
+ underline: "Underline",
58046
+ strikethrough: "Strikethrough",
58047
+ code: "Inline code",
58048
+ subscript: "Subscript",
58049
+ superscript: "Superscript",
58050
+ more: "More"
58138
58051
  }
58139
58052
  };
58140
- const jaJP$r = {
58053
+ const jaJP$q = {
58141
58054
  quickMenu: {
58142
58055
  basic: {
58143
58056
  heading: {
@@ -58181,13 +58094,21 @@ $$${mathData.mathjaxText}$$
58181
58094
  text: "\u672C\u6587",
58182
58095
  paste: "\u8CBC\u308A\u4ED8\u3051",
58183
58096
  tab: "\u30BF\u30D6",
58184
- shiftTab: "Shift+Tab"
58097
+ shiftTab: "Shift+Tab",
58098
+ bold: "\u592A\u5B57",
58099
+ italic: "\u659C\u4F53",
58100
+ underline: "\u4E0B\u7DDA",
58101
+ strikethrough: "\u53D6\u308A\u6D88\u3057\u7DDA",
58102
+ code: "\u30A4\u30F3\u30E9\u30A4\u30F3\u30B3\u30FC\u30C9",
58103
+ subscript: "\u4E0B\u4ED8\u304D\u6587\u5B57",
58104
+ superscript: "\u4E0A\u4ED8\u304D\u6587\u5B57",
58105
+ more: "\u305D\u306E\u4ED6"
58185
58106
  }
58186
58107
  };
58187
58108
  i18n$1.mergeLang({
58188
- "zh-CN": zhCN$r,
58189
- "en-US": enUS$r,
58190
- "ja-JP": jaJP$r
58109
+ "zh-CN": zhCN$q,
58110
+ "en-US": enUS$q,
58111
+ "ja-JP": jaJP$q
58191
58112
  });
58192
58113
  class TextStylesFixedProvider extends ProxyProvider {
58193
58114
  constructor(editor, afterCommandCallback) {
@@ -58297,7 +58218,7 @@ $$${mathData.mathjaxText}$$
58297
58218
  return false;
58298
58219
  });
58299
58220
  this.editor = editor;
58300
- this.providers = [new InsertMenuProvider$1(this.editor)];
58221
+ this.providers = [new InsertMenuProvider(this.editor)];
58301
58222
  }
58302
58223
  }
58303
58224
  class InsertAfterProvider extends ProxyProvider {
@@ -58344,7 +58265,7 @@ $$${mathData.mathjaxText}$$
58344
58265
  return false;
58345
58266
  });
58346
58267
  this.editor = editor;
58347
- this.providers = [new InsertMenuProvider$1(this.editor)];
58268
+ this.providers = [new InsertMenuProvider(this.editor)];
58348
58269
  }
58349
58270
  }
58350
58271
  class InsertGroupProvider extends ProxyProvider {
@@ -58535,7 +58456,6 @@ $$${mathData.mathjaxText}$$
58535
58456
  __publicField(this, "handleItemClick", (bar2, item) => {
58536
58457
  assert(logger$1H, this.commandBlock, "no command block before show block menu");
58537
58458
  this.blockCommandProviders.executeCommand(this.editor.selection.range, item);
58538
- this.close();
58539
58459
  });
58540
58460
  __publicField(this, "close", () => {
58541
58461
  this.menu.close("clickItem");
@@ -58543,7 +58463,8 @@ $$${mathData.mathjaxText}$$
58543
58463
  this.editor = editor;
58544
58464
  this.blockCommandProviders = new BlockCommandProviders(editor, this.close);
58545
58465
  this.menu = new ManualMenu([], void 0, {
58546
- id: "block-menu"
58466
+ id: "block-menu",
58467
+ autoClose: true
58547
58468
  });
58548
58469
  this.menu.on("show", this.handleShow);
58549
58470
  this.menu.on("close", this.handleClose);
@@ -58600,6 +58521,12 @@ $$${mathData.mathjaxText}$$
58600
58521
  }
58601
58522
  return styles1;
58602
58523
  }
58524
+ function mergeActiveStyle(editor, style2) {
58525
+ var _a;
58526
+ const attributes = Object.fromEntries(style2.entries());
58527
+ (_a = editor.findCustom("block-attributes-handler")) == null ? void 0 : _a.setActiveBlockAttributes(attributes);
58528
+ return new Map(Object.entries(attributes));
58529
+ }
58603
58530
  function applyTextStyle(editor, block, range, style2, value) {
58604
58531
  assert(logger$1G, range.isSimple(), "invalid range");
58605
58532
  const { start, end } = range;
@@ -58620,11 +58547,12 @@ $$${mathData.mathjaxText}$$
58620
58547
  editor.setBlockText(block, newText);
58621
58548
  return newText;
58622
58549
  }
58623
- function getStandardTextStyles(textStyles, text2) {
58550
+ function getStandardTextStyles(editor, textStyles, text2) {
58624
58551
  if (getTextLength(text2) === 0) {
58625
58552
  return textStyles;
58626
58553
  }
58627
- const styles = getIntersectionStyles(text2);
58554
+ let styles = getIntersectionStyles(text2);
58555
+ styles = mergeActiveStyle(editor, styles);
58628
58556
  function getTextStyle(item) {
58629
58557
  const { id, icon, desc, name } = item;
58630
58558
  const value = styles.get(id);
@@ -58668,7 +58596,7 @@ $$${mathData.mathjaxText}$$
58668
58596
  return subText2;
58669
58597
  }
58670
58598
  const logger$1F = getLogger("text-commands");
58671
- function getCommands$1(text2) {
58599
+ function getCommands$1(editor, text2) {
58672
58600
  const StandardTextStyles = {
58673
58601
  "style-bold": [i18n$1.t("commands.bold"), shortcutToDisplayText("CtrlOrCmd+B"), BoldIcon],
58674
58602
  "style-italic": [i18n$1.t("commands.italic"), shortcutToDisplayText("CtrlOrCmd+I"), ItalicIcon],
@@ -58681,7 +58609,7 @@ $$${mathData.mathjaxText}$$
58681
58609
  icon,
58682
58610
  desc
58683
58611
  }));
58684
- return getStandardTextStyles(standardItems, text2);
58612
+ return getStandardTextStyles(editor, standardItems, text2);
58685
58613
  }
58686
58614
  function executeStyleCommand(editor, block, range, command, params, result) {
58687
58615
  if (!command.startsWith("style-")) {
@@ -58711,10 +58639,10 @@ $$${mathData.mathjaxText}$$
58711
58639
  }
58712
58640
  let commands;
58713
58641
  if (getBlockTextLength$6(editor, block) === 0 || !isTextKindBlock(editor, block)) {
58714
- commands = getCommands$1([]);
58642
+ commands = getCommands$1(editor, []);
58715
58643
  } else {
58716
58644
  const subText2 = getSubText(editor, block, range);
58717
- commands = getCommands$1(subText2);
58645
+ commands = getCommands$1(editor, subText2);
58718
58646
  }
58719
58647
  if (!(params == null ? void 0 : params.isFilter)) {
58720
58648
  commands.forEach((item) => {
@@ -58830,7 +58758,7 @@ $$${mathData.mathjaxText}$$
58830
58758
  return false;
58831
58759
  }
58832
58760
  }
58833
- function getCommands(text2) {
58761
+ function getCommands(editor, text2) {
58834
58762
  const StandardTextStyles = {
58835
58763
  "style-super": [i18n$1.t("commands.superscript"), void 0, SuperscriptIcon],
58836
58764
  "style-sub": [i18n$1.t("commands.subscript"), void 0, SubscriptIcon]
@@ -58841,7 +58769,7 @@ $$${mathData.mathjaxText}$$
58841
58769
  icon,
58842
58770
  desc
58843
58771
  }));
58844
- return getStandardTextStyles(standardItems, text2);
58772
+ return getStandardTextStyles(editor, standardItems, text2);
58845
58773
  }
58846
58774
  class TextScriptProvider {
58847
58775
  constructor(editor) {
@@ -58856,10 +58784,10 @@ $$${mathData.mathjaxText}$$
58856
58784
  }
58857
58785
  let commands;
58858
58786
  if (getBlockTextLength$6(editor, block) === 0 || !isTextKindBlock(editor, block)) {
58859
- commands = getCommands([]);
58787
+ commands = getCommands(editor, []);
58860
58788
  } else {
58861
58789
  const subText2 = getSubText(editor, block, range);
58862
- commands = getCommands(subText2);
58790
+ commands = getCommands(editor, subText2);
58863
58791
  }
58864
58792
  if (!(params == null ? void 0 : params.isFilter)) {
58865
58793
  commands.forEach((item) => {
@@ -59056,10 +58984,10 @@ $$${mathData.mathjaxText}$$
59056
58984
  icon: InlineCodeIcon
59057
58985
  }];
59058
58986
  if (getBlockTextLength$6(editor, block) === 0 || !isTextKindBlock(editor, block)) {
59059
- commands = getStandardTextStyles(commands, []);
58987
+ commands = getStandardTextStyles(editor, commands, []);
59060
58988
  } else {
59061
58989
  const subText2 = getSubText(editor, block, range);
59062
- commands = getStandardTextStyles(commands, subText2);
58990
+ commands = getStandardTextStyles(editor, commands, subText2);
59063
58991
  }
59064
58992
  if (!(params == null ? void 0 : params.isFilter)) {
59065
58993
  commands.forEach((item) => {
@@ -62297,7 +62225,7 @@ ${codeText}
62297
62225
  };
62298
62226
  }
62299
62227
  }
62300
- const zhCN$q = {
62228
+ const zhCN$p = {
62301
62229
  code: {
62302
62230
  title: "\u4EE3\u7801",
62303
62231
  abstract: "\u4EE3\u7801",
@@ -62309,7 +62237,7 @@ ${codeText}
62309
62237
  plainText: "Plain Text"
62310
62238
  }
62311
62239
  };
62312
- const enUS$q = {
62240
+ const enUS$p = {
62313
62241
  code: {
62314
62242
  title: "Code",
62315
62243
  abstract: "Code",
@@ -62321,7 +62249,7 @@ ${codeText}
62321
62249
  plainText: "Plain Text"
62322
62250
  }
62323
62251
  };
62324
- const jaJP$q = {
62252
+ const jaJP$p = {
62325
62253
  code: {
62326
62254
  title: "\u30B3\u30FC\u30C9",
62327
62255
  abstract: "\u30B3\u30FC\u30C9",
@@ -62334,9 +62262,9 @@ ${codeText}
62334
62262
  }
62335
62263
  };
62336
62264
  i18n$1.mergeLang({
62337
- "zh-CN": zhCN$q,
62338
- "en-US": enUS$q,
62339
- "ja-JP": jaJP$q
62265
+ "zh-CN": zhCN$p,
62266
+ "en-US": enUS$p,
62267
+ "ja-JP": jaJP$p
62340
62268
  });
62341
62269
  function convertToTable(editor, containerId, blockIndex, offset) {
62342
62270
  const block = editor.getBlockByIndex(containerId, blockIndex);
@@ -62724,7 +62652,7 @@ ${codeText}
62724
62652
  return false;
62725
62653
  }
62726
62654
  }
62727
- const enUS$p = {
62655
+ const enUS$o = {
62728
62656
  placeholder: {
62729
62657
  default: "Type / for commands",
62730
62658
  heading: "Heading {heading}",
@@ -62735,7 +62663,7 @@ ${codeText}
62735
62663
  mobileDefault: "Type to add content"
62736
62664
  }
62737
62665
  };
62738
- const zhCN$p = {
62666
+ const zhCN$o = {
62739
62667
  placeholder: {
62740
62668
  default: "\u8F93\u5165\u300C/\u300D\u5FEB\u901F\u63D2\u5165",
62741
62669
  heading: "\u6807\u9898{heading}",
@@ -62746,7 +62674,7 @@ ${codeText}
62746
62674
  mobileDefault: "\u8F93\u5165\u4EE5\u6DFB\u52A0\u5185\u5BB9"
62747
62675
  }
62748
62676
  };
62749
- const jaJP$p = {
62677
+ const jaJP$o = {
62750
62678
  placeholder: {
62751
62679
  default: "\u300C/\u300D\u3092\u5165\u529B\u3057\u3066\u7D20\u65E9\u304F\u633F\u5165\u3059\u308B",
62752
62680
  heading: "\u898B\u51FA\u3057{heading}",
@@ -62758,9 +62686,9 @@ ${codeText}
62758
62686
  }
62759
62687
  };
62760
62688
  const langs$1 = {
62761
- "en-US": enUS$p,
62762
- "zh-CN": zhCN$p,
62763
- "ja-JP": jaJP$p
62689
+ "en-US": enUS$o,
62690
+ "zh-CN": zhCN$o,
62691
+ "ja-JP": jaJP$o
62764
62692
  };
62765
62693
  i18n$1.mergeLang(langs$1);
62766
62694
  function isEmptyTextBlockWithoutCompositionText(editor, block) {
@@ -63487,7 +63415,7 @@ ${codeText}
63487
63415
  this.rootButton.destroy();
63488
63416
  }
63489
63417
  }
63490
- const zhCN$o = {
63418
+ const zhCN$n = {
63491
63419
  blockMenu: {
63492
63420
  section: {
63493
63421
  basics: "\u57FA\u7840",
@@ -63511,7 +63439,7 @@ ${codeText}
63511
63439
  }
63512
63440
  }
63513
63441
  };
63514
- const enUS$o = {
63442
+ const enUS$n = {
63515
63443
  blockMenu: {
63516
63444
  section: {
63517
63445
  basics: "Basic",
@@ -63535,7 +63463,7 @@ ${codeText}
63535
63463
  }
63536
63464
  }
63537
63465
  };
63538
- const jaJP$o = {
63466
+ const jaJP$n = {
63539
63467
  blockMenu: {
63540
63468
  section: {
63541
63469
  basics: "\u4E00\u822C",
@@ -63560,9 +63488,9 @@ ${codeText}
63560
63488
  }
63561
63489
  };
63562
63490
  i18n$1.mergeLang({
63563
- "zh-CN": zhCN$o,
63564
- "en-US": enUS$o,
63565
- "ja-JP": jaJP$o
63491
+ "zh-CN": zhCN$n,
63492
+ "en-US": enUS$n,
63493
+ "ja-JP": jaJP$n
63566
63494
  });
63567
63495
  const style$6 = "";
63568
63496
  class DragData {
@@ -64518,7 +64446,7 @@ ${codeText}
64518
64446
  }
64519
64447
  }
64520
64448
  }
64521
- const zhCN$n = {
64449
+ const zhCN$m = {
64522
64450
  image: {
64523
64451
  title: "\u56FE\u7247",
64524
64452
  upload: {
@@ -64534,7 +64462,7 @@ ${codeText}
64534
64462
  abstract: "\u56FE\u7247"
64535
64463
  }
64536
64464
  };
64537
- const enUS$n = {
64465
+ const enUS$m = {
64538
64466
  image: {
64539
64467
  title: "Image",
64540
64468
  upload: {
@@ -64550,7 +64478,7 @@ ${codeText}
64550
64478
  abstract: "Image"
64551
64479
  }
64552
64480
  };
64553
- const jaJP$n = {
64481
+ const jaJP$m = {
64554
64482
  image: {
64555
64483
  title: "\u753B\u50CF",
64556
64484
  upload: {
@@ -64567,9 +64495,9 @@ ${codeText}
64567
64495
  }
64568
64496
  };
64569
64497
  i18n$1.mergeLang({
64570
- "zh-CN": zhCN$n,
64571
- "en-US": enUS$n,
64572
- "ja-JP": jaJP$n
64498
+ "zh-CN": zhCN$m,
64499
+ "en-US": enUS$m,
64500
+ "ja-JP": jaJP$m
64573
64501
  });
64574
64502
  function convertToImage(editor, containerId, blockIndex, offset) {
64575
64503
  const block = editor.getBlockByIndex(containerId, blockIndex);
@@ -64937,28 +64865,28 @@ ${codeText}
64937
64865
  }
64938
64866
  return getDragInsertPos(editor, block, images, x);
64939
64867
  }
64940
- const zhCN$m = {
64868
+ const zhCN$l = {
64941
64869
  embedProperties: {
64942
64870
  edit: "\u7F16\u8F91",
64943
64871
  addComment: "\u6DFB\u52A0\u6279\u6CE8"
64944
64872
  }
64945
64873
  };
64946
- const enUS$m = {
64874
+ const enUS$l = {
64947
64875
  embedProperties: {
64948
64876
  edit: "Edit",
64949
64877
  addComment: "Add annotation"
64950
64878
  }
64951
64879
  };
64952
- const jaJP$m = {
64880
+ const jaJP$l = {
64953
64881
  embedProperties: {
64954
64882
  edit: "\u7DE8\u96C6",
64955
64883
  addComment: "\u6CE8\u91C8\u3092\u8FFD\u52A0"
64956
64884
  }
64957
64885
  };
64958
64886
  i18n$1.mergeLang({
64959
- "zh-CN": zhCN$m,
64960
- "en-US": enUS$m,
64961
- "ja-JP": jaJP$m
64887
+ "zh-CN": zhCN$l,
64888
+ "en-US": enUS$l,
64889
+ "ja-JP": jaJP$l
64962
64890
  });
64963
64891
  const logger$1c = getLogger("embed-block-properties");
64964
64892
  function addCommentToBlock(editor, block) {
@@ -67538,7 +67466,7 @@ ${codeText}
67538
67466
  }
67539
67467
  }
67540
67468
  const style$5 = "";
67541
- const zhCN$l = {
67469
+ const zhCN$k = {
67542
67470
  comment: {
67543
67471
  count: "\u6279\u6CE8 ({num})",
67544
67472
  hide: "\u9690\u85CF\u6279\u6CE8",
@@ -67561,7 +67489,7 @@ ${codeText}
67561
67489
  quickMenuCommand: "\u6DFB\u52A0\u6279\u6CE8"
67562
67490
  }
67563
67491
  };
67564
- const enUS$l = {
67492
+ const enUS$k = {
67565
67493
  comment: {
67566
67494
  count: "Annotations ({num})",
67567
67495
  hide: "Hide Annotations",
@@ -67584,7 +67512,7 @@ ${codeText}
67584
67512
  quickMenuCommand: "Add annotation"
67585
67513
  }
67586
67514
  };
67587
- const jaJP$l = {
67515
+ const jaJP$k = {
67588
67516
  comment: {
67589
67517
  count: "\u6CE8\u91C8 ({num})",
67590
67518
  hide: "\u6CE8\u91C8\u3092\u975E\u8868\u793A",
@@ -67608,9 +67536,9 @@ ${codeText}
67608
67536
  }
67609
67537
  };
67610
67538
  i18n$1.mergeLang({
67611
- "zh-CN": zhCN$l,
67612
- "en-US": enUS$l,
67613
- "ja-JP": jaJP$l
67539
+ "zh-CN": zhCN$k,
67540
+ "en-US": enUS$k,
67541
+ "ja-JP": jaJP$k
67614
67542
  });
67615
67543
  class OnesEditorCommentsRender {
67616
67544
  renderText(editor, path, attributes) {
@@ -70195,7 +70123,7 @@ ${codeText}
70195
70123
  return void 0;
70196
70124
  }
70197
70125
  };
70198
- const zhCN$k = {
70126
+ const zhCN$j = {
70199
70127
  table: {
70200
70128
  cellBackground: "\u5355\u5143\u683C\u80CC\u666F\u8272",
70201
70129
  deleteSelectRow: "\u5220\u9664\u6240\u9009\u884C",
@@ -70226,7 +70154,7 @@ ${codeText}
70226
70154
  }
70227
70155
  }
70228
70156
  };
70229
- const enUS$k = {
70157
+ const enUS$j = {
70230
70158
  table: {
70231
70159
  cellBackground: "Cell background color",
70232
70160
  deleteSelectRow: "Delete selected rows",
@@ -70257,7 +70185,7 @@ ${codeText}
70257
70185
  }
70258
70186
  }
70259
70187
  };
70260
- const jaJP$k = {
70188
+ const jaJP$j = {
70261
70189
  table: {
70262
70190
  cellBackground: "\u30BB\u30EB\u306E\u80CC\u666F\u8272",
70263
70191
  deleteSelectRow: "\u9078\u629E\u3057\u305F\u884C\u3092\u524A\u9664",
@@ -70289,9 +70217,9 @@ ${codeText}
70289
70217
  }
70290
70218
  };
70291
70219
  i18n$1.mergeLang({
70292
- "zh-CN": zhCN$k,
70293
- "en-US": enUS$k,
70294
- "ja-JP": jaJP$k
70220
+ "zh-CN": zhCN$j,
70221
+ "en-US": enUS$j,
70222
+ "ja-JP": jaJP$j
70295
70223
  });
70296
70224
  const tableStyle = "";
70297
70225
  const logger$N = getLogger("table");
@@ -70555,13 +70483,7 @@ ${codeText}
70555
70483
  if (!clientType.isMobile) {
70556
70484
  this.item.children = items;
70557
70485
  } else {
70558
- const SEP2 = {
70559
- id: "",
70560
- name: "",
70561
- type: "separator"
70562
- };
70563
- const commands = items.reduce((prev, curr) => prev.concat([SEP2, curr]), []);
70564
- commands.shift();
70486
+ const commands = groupEachCommand(items);
70565
70487
  this.toolbar.updateItems(commands);
70566
70488
  }
70567
70489
  this.toolbar.manualShow(this.anchor, {
@@ -70699,21 +70621,21 @@ ${codeText}
70699
70621
  return false;
70700
70622
  }
70701
70623
  }
70702
- const zhCN$j = {
70624
+ const zhCN$i = {
70703
70625
  pasteSpecial: {
70704
70626
  originFormats: "\u4FDD\u6301\u539F\u6837\u5F0F",
70705
70627
  plainText: "\u7C98\u8D34\u7EAF\u6587\u672C",
70706
70628
  markdown: "\u7C98\u8D34\u4E3A Markdown"
70707
70629
  }
70708
70630
  };
70709
- const enUS$j = {
70631
+ const enUS$i = {
70710
70632
  pasteSpecial: {
70711
70633
  originFormats: "Keep origin formats",
70712
70634
  plainText: "Paste as plain text",
70713
70635
  markdown: "Paste as markdown"
70714
70636
  }
70715
70637
  };
70716
- const jaJP$j = {
70638
+ const jaJP$i = {
70717
70639
  pasteSpecial: {
70718
70640
  originFormats: "\u5143\u306E\u30B9\u30BF\u30A4\u30EB\u3092\u7DAD\u6301\u3059\u308B",
70719
70641
  plainText: "\u30D7\u30EC\u30FC\u30F3\u30C6\u30AD\u30B9\u30C8\u3092\u8CBC\u308A\u4ED8\u3051\u308B",
@@ -70721,9 +70643,9 @@ ${codeText}
70721
70643
  }
70722
70644
  };
70723
70645
  i18n$1.mergeLang({
70724
- "zh-CN": zhCN$j,
70725
- "en-US": enUS$j,
70726
- "ja-JP": jaJP$j
70646
+ "zh-CN": zhCN$i,
70647
+ "en-US": enUS$i,
70648
+ "ja-JP": jaJP$i
70727
70649
  });
70728
70650
  const style$4 = "";
70729
70651
  const logger$L = getLogger("html-to-doc");
@@ -73486,7 +73408,7 @@ ${content}
73486
73408
  const eleRect = firstChild.getBoundingClientRect();
73487
73409
  offsetTop = eleRect.y;
73488
73410
  }
73489
- scrollIntoView$1(editor, firstChild, { animation: true });
73411
+ scrollIntoView(editor, firstChild, { animation: true });
73490
73412
  }
73491
73413
  function getCurrentHighligh(editor) {
73492
73414
  const elem = editor.rootContainer.querySelector(".editor-highlight.active");
@@ -74136,7 +74058,7 @@ ${content}
74136
74058
  (_a = this.dialog) == null ? void 0 : _a.destroy();
74137
74059
  }
74138
74060
  }
74139
- const zhCN$i = {
74061
+ const zhCN$h = {
74140
74062
  find: {
74141
74063
  findLabel: "\u67E5\u627E:",
74142
74064
  replaceLabel: "\u66FF\u6362:",
@@ -74148,7 +74070,7 @@ ${content}
74148
74070
  replacePlaceholder: "\u66FF\u6362\u4E3A"
74149
74071
  }
74150
74072
  };
74151
- const enUS$i = {
74073
+ const enUS$h = {
74152
74074
  find: {
74153
74075
  findLabel: "Search:",
74154
74076
  replaceLabel: "Replace:",
@@ -74160,7 +74082,7 @@ ${content}
74160
74082
  replacePlaceholder: "Replace with"
74161
74083
  }
74162
74084
  };
74163
- const jaJP$i = {
74085
+ const jaJP$h = {
74164
74086
  find: {
74165
74087
  findLabel: "\u691C\u7D22\uFF1A",
74166
74088
  replaceLabel: "\u7F6E\u63DB\uFF1A",
@@ -74173,9 +74095,9 @@ ${content}
74173
74095
  }
74174
74096
  };
74175
74097
  i18n$1.mergeLang({
74176
- "zh-CN": zhCN$i,
74177
- "en-US": enUS$i,
74178
- "ja-JP": jaJP$i
74098
+ "zh-CN": zhCN$h,
74099
+ "en-US": enUS$h,
74100
+ "ja-JP": jaJP$h
74179
74101
  });
74180
74102
  function handleFindReplace(editor) {
74181
74103
  const dialog = editor.addCustom("find-dialog", () => new FindDialog(editor));
@@ -74445,28 +74367,28 @@ ${content}
74445
74367
  this.isShown = false;
74446
74368
  }
74447
74369
  }
74448
- const zhCN$h = {
74370
+ const zhCN$g = {
74449
74371
  authError: {
74450
74372
  tips: '<div>\u670D\u52A1\u5DF2\u65AD\u5F00\uFF0C\u6B63\u5728\u91CD\u65B0\u8FDE\u63A5\uFF0C\u4E3A\u907F\u514D\u5185\u5BB9\u4E22\u5931\uFF0C\u6211\u4EEC\u6682\u65F6\u7981\u7528\u7F16\u8F91\u80FD\u529B\uFF0C\u4F60\u53EF\u4EE5<span id="exit">\u9000\u51FA\u7F16\u8F91</span></div>',
74451
74373
  successTips: "<div>\u7F16\u8F91\u72B6\u6001\u5DF2\u6062\u590D\uFF0C\u4F60\u53EF\u4EE5\u7EE7\u7EED\u7F16\u8F91</div>"
74452
74374
  }
74453
74375
  };
74454
- const enUS$h = {
74376
+ const enUS$g = {
74455
74377
  authError: {
74456
74378
  tips: '<div>Network disconnected. To avoid any potential loss of content, editing is temporarily disabled. <span id="exit">Exit editor<span id="exit">',
74457
74379
  successTips: "<div>The editing mode has been restored and you can now continue editing.</div>"
74458
74380
  }
74459
74381
  };
74460
- const jaJP$h = {
74382
+ const jaJP$g = {
74461
74383
  authError: {
74462
74384
  tips: '<div>\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u306B\u63A5\u7D9A\u3067\u304D\u307E\u305B\u3093\u3002\u30C7\u30FC\u30BF\u640D\u5931\u306E\u56DE\u907F\u306E\u305F\u3081\u306B\u3001\u63A5\u7D9A\u304C\u56DE\u5FA9\u3059\u308B\u307E\u3067\u7DE8\u96C6\u6A5F\u80FD\u306F\u4F7F\u3048\u307E\u305B\u3093\u3002<span id="exit">\u7DE8\u96C6\u3092\u7D42\u4E86</span></div>',
74463
74385
  successTips: "<div>\u30CD\u30C3\u30C8\u30EF\u30FC\u30AF\u63A5\u7D9A\u304C\u56DE\u5FA9\u3057\u307E\u3057\u305F\u3002\u5F15\u304D\u7D9A\u3051\u3054\u7DE8\u96C6\u3044\u305F\u3060\u3051\u307E\u3059\u3002</div>"
74464
74386
  }
74465
74387
  };
74466
74388
  i18n$1.mergeLang({
74467
- "zh-CN": zhCN$h,
74468
- "en-US": enUS$h,
74469
- "ja-JP": jaJP$h
74389
+ "zh-CN": zhCN$g,
74390
+ "en-US": enUS$g,
74391
+ "ja-JP": jaJP$g
74470
74392
  });
74471
74393
  const logger$B = getLogger("re-auth");
74472
74394
  const DOC_RE_AUTH_KEYS = "doc-re-auth-event";
@@ -75041,7 +74963,7 @@ ${content}
75041
74963
  return false;
75042
74964
  }
75043
74965
  }
75044
- const zhCN$g = {
74966
+ const zhCN$f = {
75045
74967
  contextMenu: {
75046
74968
  copyMarkdown: "\u590D\u5236\u4E3A Markdown",
75047
74969
  paste: "\u7C98\u8D34",
@@ -75054,7 +74976,7 @@ ${content}
75054
74976
  uneditableBlockSelected: "\u9009\u4E2D\u533A\u57DF\u5305\u542B\u9501\u5B9A\u533A\u5757\uFF0C\u6682\u4E0D\u652F\u6301\u526A\u5207"
75055
74977
  }
75056
74978
  };
75057
- const enUS$g = {
74979
+ const enUS$f = {
75058
74980
  contextMenu: {
75059
74981
  copyMarkdown: "Copy as Markdown",
75060
74982
  paste: "Paste",
@@ -75067,7 +74989,7 @@ ${content}
75067
74989
  uneditableBlockSelected: "The selected area contains locked blocks, and cutting is not currently supported"
75068
74990
  }
75069
74991
  };
75070
- const jaJP$g = {
74992
+ const jaJP$f = {
75071
74993
  contextMenu: {
75072
74994
  copyMarkdown: "Markdown \u3068\u3057\u3066\u30B3\u30D4\u30FC",
75073
74995
  paste: "\u8CBC\u308A\u4ED8\u3051",
@@ -75081,9 +75003,9 @@ ${content}
75081
75003
  }
75082
75004
  };
75083
75005
  i18n$1.mergeLang({
75084
- "zh-CN": zhCN$g,
75085
- "en-US": enUS$g,
75086
- "ja-JP": jaJP$g
75006
+ "zh-CN": zhCN$f,
75007
+ "en-US": enUS$f,
75008
+ "ja-JP": jaJP$f
75087
75009
  });
75088
75010
  function hideToolbar(editor) {
75089
75011
  const toolbar2 = editor.findCustom("toolbar-handler");
@@ -75109,47 +75031,6 @@ ${content}
75109
75031
  "CtrlOrCmd+Z": undoHandler,
75110
75032
  "CtrlOrCmd+Shift+Z": redoHandler
75111
75033
  };
75112
- const zhCN$f = {
75113
- commands: {
75114
- bold: "\u7C97\u4F53",
75115
- italic: "\u659C\u4F53",
75116
- underline: "\u4E0B\u5212\u7EBF",
75117
- strikethrough: "\u5220\u9664\u7EBF",
75118
- code: "\u884C\u5185\u4EE3\u7801",
75119
- subscript: "\u4E0B\u6807",
75120
- superscript: "\u4E0A\u6807",
75121
- more: "\u66F4\u591A"
75122
- }
75123
- };
75124
- const enUS$f = {
75125
- commands: {
75126
- bold: "Bold",
75127
- italic: "Italic",
75128
- underline: "Underline",
75129
- strikethrough: "Strikethrough",
75130
- code: "Inline code",
75131
- subscript: "Subscript",
75132
- superscript: "Superscript",
75133
- more: "More"
75134
- }
75135
- };
75136
- const jaJP$f = {
75137
- commands: {
75138
- bold: "\u592A\u5B57",
75139
- italic: "\u659C\u4F53",
75140
- underline: "\u4E0B\u7DDA",
75141
- strikethrough: "\u53D6\u308A\u6D88\u3057\u7DDA",
75142
- code: "\u30A4\u30F3\u30E9\u30A4\u30F3\u30B3\u30FC\u30C9",
75143
- subscript: "\u4E0B\u4ED8\u304D\u6587\u5B57",
75144
- superscript: "\u4E0A\u4ED8\u304D\u6587\u5B57",
75145
- more: "\u305D\u306E\u4ED6"
75146
- }
75147
- };
75148
- i18n$1.mergeLang({
75149
- "zh-CN": zhCN$f,
75150
- "en-US": enUS$f,
75151
- "ja-JP": jaJP$f
75152
- });
75153
75034
  var FilePreviewType = /* @__PURE__ */ ((FilePreviewType2) => {
75154
75035
  FilePreviewType2["Card"] = "card";
75155
75036
  FilePreviewType2["Preview"] = "preview";
@@ -78410,7 +78291,7 @@ ${content}
78410
78291
  const mobileWrap = this.getMobileCommandElement();
78411
78292
  const input2 = mobileWrap.querySelector("input");
78412
78293
  input2.focus();
78413
- scrollIntoView(bar2.menu.menu, this.editor);
78294
+ scrollBarIntoView(this.editor, bar2.menu.menu);
78414
78295
  }
78415
78296
  });
78416
78297
  __publicField(this, "handleClickItem", (item) => {
@@ -79687,86 +79568,31 @@ ${content}
79687
79568
  removeClass(this.endGripper, "active");
79688
79569
  }
79689
79570
  }
79690
- class InsertMenuProvider extends ProxyProvider {
79571
+ class MobileInsertMenuProvider extends ProxyProvider {
79691
79572
  constructor(editor) {
79692
79573
  super();
79693
79574
  __publicField(this, "id", "InsertMenuProvider");
79694
79575
  __publicField(this, "providers", []);
79695
79576
  __publicField(this, "getInsertCommands", () => []);
79696
79577
  __publicField(this, "getAvailableCommands", (editor, block, range, params) => {
79697
- var _a, _b;
79698
79578
  const commands = [];
79699
- editor.editorBlocks.forEach((blockClass) => {
79700
- if (!blockClass.getOptions) {
79701
- return;
79702
- }
79703
- const options = blockClass.getOptions(editor);
79704
- if (!options.insertBlockCommandItems) {
79705
- return;
79706
- }
79707
- injectBlockOptions(options.insertBlockCommandItems, options);
79708
- commands.push(...options.insertBlockCommandItems);
79709
- });
79710
- if (!isTextKindBlock(editor, block)) {
79711
- const container = getParentContainer(block);
79712
- const containerId = getContainerId(container);
79713
- for (const provider of this.providers) {
79714
- commands.push(...(_b = (_a = provider.getInsertCommands) == null ? void 0 : _a.call(provider, editor, containerId)) != null ? _b : []);
79715
- }
79716
- } else {
79717
- for (const provider of this.providers) {
79718
- commands.push(...provider.getAvailableCommands(editor, block, range, params));
79719
- }
79579
+ for (const provider of this.providers) {
79580
+ commands.push(...provider.getAvailableCommands(editor, block, range, params));
79720
79581
  }
79721
79582
  return commands.filter((command) => this.whiteList.includes(command.id)).sort((a, b) => this.whiteList.indexOf(a.id) - this.whiteList.indexOf(b.id));
79722
79583
  });
79723
79584
  __publicField(this, "executeInsertCommand", () => false);
79724
- __publicField(this, "getNextBlockIndex", (container, block) => {
79725
- let nextBlock = getNextVisibleBlock(block);
79726
- if (!nextBlock) {
79727
- nextBlock = getLastChildBlock(container);
79728
- return getBlockIndex(nextBlock) + 1;
79729
- }
79730
- return getBlockIndex(nextBlock);
79731
- });
79732
79585
  __publicField(this, "executeCommand", (editor, block, range, item, params) => {
79733
- var _a, _b, _c, _d;
79734
- const quickItem = item;
79735
- const container = getParentContainer(block);
79736
- const containerId = getContainerId(container);
79737
- const blockIndex = editor.getBlockIndex(block);
79738
- if ((_a = quickItem.blockOptions) == null ? void 0 : _a.handleInsertEmptyBlock) {
79739
- let insertIndex = blockIndex;
79740
- const isEmptyBlock = isEmptyTextBlock(editor, block);
79741
- if (!isEmptyBlock) {
79742
- insertIndex = this.getNextBlock(container, block);
79743
- }
79744
- (_b = quickItem.blockOptions) == null ? void 0 : _b.handleInsertEmptyBlock(editor, {
79745
- containerId,
79746
- blockIndex: insertIndex,
79747
- item,
79748
- from: isEmptyBlock ? "add-block-menu" : "quick-menu"
79749
- });
79750
- return true;
79751
- }
79752
- if (!isTextKindBlock(editor, block)) {
79753
- const insertIndex = this.getNextBlock(container, block);
79754
- for (const provider of this.providers) {
79755
- if ((_c = provider.executeInsertCommand) == null ? void 0 : _c.call(provider, editor, containerId, insertIndex, item, params)) {
79756
- return true;
79757
- }
79758
- }
79759
- } else {
79760
- for (const provider of this.providers) {
79761
- if ((_d = provider.executeCommand) == null ? void 0 : _d.call(provider, editor, block, range, item, params)) {
79762
- return true;
79763
- }
79586
+ var _a;
79587
+ for (const provider of this.providers) {
79588
+ if ((_a = provider.executeCommand) == null ? void 0 : _a.call(provider, editor, block, range, item, params)) {
79589
+ return true;
79764
79590
  }
79765
79591
  }
79766
79592
  return false;
79767
79593
  });
79768
79594
  this.editor = editor;
79769
- this.providers.push(new LinkProvider(editor));
79595
+ this.providers.push(new InsertMenuProvider(editor));
79770
79596
  }
79771
79597
  get whiteList() {
79772
79598
  const list2 = ["insert-image", "insert-table", "insert-link", "insert-hr"];
@@ -79776,14 +79602,6 @@ ${content}
79776
79602
  }
79777
79603
  return list2;
79778
79604
  }
79779
- getNextBlock(container, block) {
79780
- let nextBlock = getNextVisibleBlock(block);
79781
- if (!nextBlock) {
79782
- nextBlock = getLastChildBlock(container);
79783
- return getBlockIndex(nextBlock) + 1;
79784
- }
79785
- return getBlockIndex(nextBlock);
79786
- }
79787
79605
  }
79788
79606
  class CursorToolbarHandler {
79789
79607
  constructor(editor) {
@@ -79871,7 +79689,7 @@ ${content}
79871
79689
  ];
79872
79690
  });
79873
79691
  this.editor = editor;
79874
- this.providers = [new InsertMenuProvider(editor)];
79692
+ this.providers = [new MobileInsertMenuProvider(editor)];
79875
79693
  }
79876
79694
  }
79877
79695
  class TurnIntoCommandProvider extends ProxyProvider {
@@ -80104,15 +79922,13 @@ ${content}
80104
79922
  __publicField(this, "mobileToolbar");
80105
79923
  __publicField(this, "fixedProviders");
80106
79924
  __publicField(this, "bar");
80107
- __publicField(this, "handleSubBarShow", (_2, subBar) => {
80108
- scrollIntoView(subBar, this.editor);
80109
- });
80110
- __publicField(this, "handleSelectionChange", () => {
80111
- setTimeout(() => {
80112
- const commands = this.fixedProviders.getCommands(this.editor.selection.range);
80113
- this.mobileToolbar.updateItems(commands);
80114
- });
79925
+ __publicField(this, "handleSubBarShown", (_2, subBar) => {
79926
+ scrollBarIntoView(this.editor, subBar);
80115
79927
  });
79928
+ __publicField(this, "handleSelectionChange", debounce__default.default(() => {
79929
+ const commands = this.fixedProviders.getCommands(this.editor.selection.range);
79930
+ this.mobileToolbar.updateItems(commands);
79931
+ }, 60));
80116
79932
  __publicField(this, "handleClick", (_2, item) => {
80117
79933
  this.fixedProviders.executeCommand(this.editor.selection.range, item, {});
80118
79934
  setTimeout(() => {
@@ -80126,10 +79942,8 @@ ${content}
80126
79942
  this.fixedProviders = new FixedProviders(editor);
80127
79943
  this.bar = createElement("div", ["command-m-bar"], parent);
80128
79944
  const commands = this.fixedProviders.getCommands(this.editor.selection.range);
80129
- this.mobileToolbar = new FixedToolbar(this.bar, commands, {
80130
- tooltipId: "mobile-viewer"
80131
- });
80132
- this.mobileToolbar.addListener("subBarShown", this.handleSubBarShow);
79945
+ this.mobileToolbar = new FixedToolbar(this.bar, commands);
79946
+ this.mobileToolbar.addListener("subBarShown", this.handleSubBarShown);
80133
79947
  this.mobileToolbar.addListener("click", this.handleClick);
80134
79948
  this.editor.addListener("selectionChanged", this.handleSelectionChange);
80135
79949
  setTimeout(() => {
@@ -80221,36 +80035,6 @@ ${content}
80221
80035
  this.editor.scrollContainer.removeEventListener("scroll", this.handScroll);
80222
80036
  }
80223
80037
  }
80224
- const mobileHelperStyles = "";
80225
- const zhCN$7 = {
80226
- mobile: {
80227
- insert: "\u63D2\u5165",
80228
- commands: {
80229
- select: "\u9009\u62E9"
80230
- }
80231
- }
80232
- };
80233
- const enUS$7 = {
80234
- mobile: {
80235
- insert: "Insert",
80236
- commands: {
80237
- select: "Select"
80238
- }
80239
- }
80240
- };
80241
- const jaJP$7 = {
80242
- mobile: {
80243
- insert: "\u633F\u5165",
80244
- commands: {
80245
- select: "\u9078\u629E"
80246
- }
80247
- }
80248
- };
80249
- i18n$1.mergeLang({
80250
- "zh-CN": zhCN$7,
80251
- "en-US": enUS$7,
80252
- "ja-JP": jaJP$7
80253
- });
80254
80038
  class MobileEmbedMask {
80255
80039
  constructor(editor) {
80256
80040
  __publicField(this, "addMask", (block) => {
@@ -80284,6 +80068,36 @@ ${content}
80284
80068
  this.editor.removeListener("selectionChanged", this.handleSelectionChanged);
80285
80069
  }
80286
80070
  }
80071
+ const zhCN$7 = {
80072
+ mobile: {
80073
+ insert: "\u63D2\u5165",
80074
+ commands: {
80075
+ select: "\u9009\u62E9"
80076
+ }
80077
+ }
80078
+ };
80079
+ const enUS$7 = {
80080
+ mobile: {
80081
+ insert: "Insert",
80082
+ commands: {
80083
+ select: "Select"
80084
+ }
80085
+ }
80086
+ };
80087
+ const jaJP$7 = {
80088
+ mobile: {
80089
+ insert: "\u633F\u5165",
80090
+ commands: {
80091
+ select: "\u9078\u629E"
80092
+ }
80093
+ }
80094
+ };
80095
+ i18n$1.mergeLang({
80096
+ "zh-CN": zhCN$7,
80097
+ "en-US": enUS$7,
80098
+ "ja-JP": jaJP$7
80099
+ });
80100
+ const mobileHelperStyles = "";
80287
80101
  const LONG_PRESS_DELAY = 800;
80288
80102
  class OnesEditorMobileHelper {
80289
80103
  constructor(editor) {
@@ -80351,12 +80165,12 @@ ${content}
80351
80165
  window.clearTimeout(this.longPressTimeout);
80352
80166
  this.longPressTimeout = 0;
80353
80167
  }
80354
- this.isMoving = false;
80355
- if (this.longPressTriggered) {
80168
+ if (this.longPressTriggered || this.isMoving) {
80356
80169
  event.preventDefault();
80357
80170
  event.stopPropagation();
80358
- this.longPressTriggered = false;
80359
80171
  }
80172
+ this.longPressTriggered = false;
80173
+ this.isMoving = false;
80360
80174
  });
80361
80175
  this.editor = editor;
80362
80176
  this.editor.addListener("selectionChanged", this.handleSelectionChange);
@@ -82179,7 +81993,7 @@ ${content}
82179
81993
  reject();
82180
81994
  }
82181
81995
  });
82182
- dialog.addListener("show", focus);
81996
+ dialog.addListener("shown", focus);
82183
81997
  dialog.show();
82184
81998
  const input2 = getField();
82185
81999
  bindKeyDownEvent(input2, async (event, composing) => {
@@ -86801,7 +86615,7 @@ ${data2.flowchartText}
86801
86615
  }
86802
86616
  }
86803
86617
  });
86804
- editor.version = "2.1.1-beta.73";
86618
+ editor.version = "2.1.1-beta.74";
86805
86619
  if (Logger$2.level === LogLevel.DEBUG) {
86806
86620
  window.setReauthFail = (fail) => {
86807
86621
  window.isReauthError = fail;
@@ -86902,7 +86716,7 @@ ${data2.flowchartText}
86902
86716
  });
86903
86717
  editor.addCustom(DOC_RE_AUTH_KEYS, (editor2) => new DocReAuthCallbacks(editor2));
86904
86718
  OnesEditorToolbar.register(editor);
86905
- editor.version = "2.1.1-beta.73";
86719
+ editor.version = "2.1.1-beta.74";
86906
86720
  return editor;
86907
86721
  }
86908
86722
  async function showDocVersions(editor, options, serverUrl) {
@@ -132691,7 +132505,7 @@ ${data2.flowchartText}
132691
132505
  exports2.InlineCodeProvider = InlineCodeProvider;
132692
132506
  exports2.InlineStyleProvider = InlineStyleProvider;
132693
132507
  exports2.InputtingInsertion = InputtingInsertion;
132694
- exports2.InsertMenuProvider = InsertMenuProvider$1;
132508
+ exports2.InsertMenuProvider = InsertMenuProvider;
132695
132509
  exports2.LayoutBlock = LayoutBlock;
132696
132510
  exports2.LayoutBlockCaptionInputHandler = LayoutBlockCaptionInputHandler;
132697
132511
  exports2.LayoutQuickMenuItemFilter = LayoutQuickMenuItemFilter;
@@ -132826,7 +132640,6 @@ ${data2.flowchartText}
132826
132640
  exports2.createEmptyContainer = createEmptyContainer;
132827
132641
  exports2.createEmptyDoc = createEmptyDoc$1;
132828
132642
  exports2.createEmptyTextBlockData = createEmptyTextBlockData;
132829
- exports2.createEntireRowAndColumnRange = createEntireRowAndColumnRange;
132830
132643
  exports2.createExpandedRange = createExpandedRange;
132831
132644
  exports2.createIconButton = createIconButton;
132832
132645
  exports2.createImage = createImage;
@@ -132847,8 +132660,6 @@ ${data2.flowchartText}
132847
132660
  exports2.createTextWithReplaceSoftReturn = createTextWithReplaceSoftReturn;
132848
132661
  exports2.daysAfter = daysAfter;
132849
132662
  exports2.deleteColor = deleteColor;
132850
- exports2.deleteColumns = deleteColumns;
132851
- exports2.deleteRows = deleteRows;
132852
132663
  exports2.deleteText = deleteText;
132853
132664
  exports2.diffDays = diffDays;
132854
132665
  exports2.disablePageScroll = disablePageScroll;
@@ -132968,7 +132779,6 @@ ${data2.flowchartText}
132968
132779
  exports2.fromNowString = fromNowString;
132969
132780
  exports2.genId = genId;
132970
132781
  exports2.generateEditorContainerId = generateEditorContainerId;
132971
- exports2.getAbstractTableSelectionRange = getAbstractTableSelectionRange;
132972
132782
  exports2.getAllChildBlocks = getAllChildBlocks;
132973
132783
  exports2.getAllSelectedBlocks = getAllSelectedBlocks;
132974
132784
  exports2.getAttributesAt = getAttributesAt;
@@ -133090,10 +132900,8 @@ ${data2.flowchartText}
133090
132900
  exports2.injectSource = injectSource;
133091
132901
  exports2.injectStyle = injectStyle;
133092
132902
  exports2.inputActions = actions;
133093
- exports2.insertColumn = insertColumn;
133094
132903
  exports2.insertEmptyBlock = insertEmptyBlock;
133095
132904
  exports2.insertEmptyEmbedBlock = insertEmptyEmbedBlock;
133096
- exports2.insertRow = insertRow;
133097
132905
  exports2.insertText = insertText;
133098
132906
  exports2.intersectionCommands = intersectionCommands;
133099
132907
  exports2.isBackspace = isBackspace;
@@ -133205,7 +133013,7 @@ ${data2.flowchartText}
133205
133013
  exports2.requestDownload = requestDownload;
133206
133014
  exports2.resetListStart = resetListStart;
133207
133015
  exports2.saveAs = saveAs$1;
133208
- exports2.scrollIntoView = scrollIntoView$1;
133016
+ exports2.scrollIntoView = scrollIntoView;
133209
133017
  exports2.scrollable = scrollable;
133210
133018
  exports2.selectFile = selectFile;
133211
133019
  exports2.selectedBlockToDoc = selectedBlockToDoc;
@@ -133213,12 +133021,9 @@ ${data2.flowchartText}
133213
133021
  exports2.setAttributes = setAttributes;
133214
133022
  exports2.setClipboardData = setClipboardData;
133215
133023
  exports2.setClipboardDataByEvent = setClipboardDataByEvent;
133216
- exports2.setColTitle = setColTitle;
133217
133024
  exports2.setColorToAttributes = setColorToAttributes;
133218
133025
  exports2.setDataset = setDataset;
133219
133026
  exports2.setDefaultCursor = setDefaultCursor;
133220
- exports2.setRowTitle = setRowTitle;
133221
- exports2.setStripeStyle = setStripeStyle;
133222
133027
  exports2.setStyles = setStyles;
133223
133028
  exports2.shareDBCommentToDocObject = shareDBCommentToDocObject;
133224
133029
  exports2.shareDBDocCommentToComment = shareDBDocCommentToComment;