@worktile/theia 3.0.2 → 3.0.5

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 (71) hide show
  1. package/bundles/worktile-theia.umd.js +296 -379
  2. package/bundles/worktile-theia.umd.js.map +1 -1
  3. package/components/toolbar/toolbar.component.d.ts +1 -2
  4. package/components/toolbar-dropdown/toolbar-dropdown.component.d.ts +3 -13
  5. package/components/toolbar-group/toolbar-group.component.d.ts +2 -2
  6. package/components/toolbar-item/toolbar-item.component.d.ts +3 -11
  7. package/constants/node-types.d.ts +2 -1
  8. package/core/toolbar-item/base-toolbar-item.d.ts +29 -0
  9. package/editor.module.d.ts +42 -44
  10. package/esm2015/components/inline-toolbar/inline-toolbar.component.js +2 -2
  11. package/esm2015/components/toolbar/toolbar.component.js +14 -24
  12. package/esm2015/components/toolbar-dropdown/toolbar-dropdown.component.js +11 -41
  13. package/esm2015/components/toolbar-group/toolbar-group.component.js +4 -4
  14. package/esm2015/components/toolbar-item/toolbar-item.component.js +24 -41
  15. package/esm2015/constants/auto-format-rules.js +19 -2
  16. package/esm2015/constants/node-types.js +3 -2
  17. package/esm2015/core/toolbar-item/base-toolbar-item.js +92 -0
  18. package/esm2015/core/utils/merge-options.js +8 -8
  19. package/esm2015/editor.component.js +2 -2
  20. package/esm2015/editor.module.js +1 -4
  21. package/esm2015/interfaces/plugins/plugins.js +1 -1
  22. package/esm2015/interfaces/toolbar.js +2 -2
  23. package/esm2015/plugins/align/align.editor.js +3 -7
  24. package/esm2015/plugins/align/align.plugin.js +7 -4
  25. package/esm2015/plugins/code/code.component.js +6 -6
  26. package/esm2015/plugins/color/color.plugin.js +6 -3
  27. package/esm2015/plugins/color/toolbar-item.component.js +14 -23
  28. package/esm2015/plugins/common/reset-type.plugin.js +3 -3
  29. package/esm2015/plugins/deserializers/deserialize-html.plugin.js +3 -3
  30. package/esm2015/plugins/font-size/font-size.editor.js +8 -14
  31. package/esm2015/plugins/heading/heading.editor.js +3 -2
  32. package/esm2015/plugins/heading/heading.plugin.js +2 -2
  33. package/esm2015/plugins/indent/indent.editor.js +1 -10
  34. package/esm2015/plugins/indent/indent.plugin.js +8 -7
  35. package/esm2015/plugins/inline-code/inline-code.plugin.js +6 -3
  36. package/esm2015/plugins/link/link.plugin.js +6 -3
  37. package/esm2015/plugins/mark/mark.plugin.js +6 -3
  38. package/esm2015/plugins/public-api.js +1 -2
  39. package/esm2015/plugins/quick-insert/components/quick-toolbar/quick-toolbar.component.js +2 -2
  40. package/esm2015/plugins/table/components/table.component.js +4 -1
  41. package/esm2015/plugins/table/toolbar-item.component.js +10 -20
  42. package/esm2015/plugins/vertical-align/toolbar-item.component.js +6 -20
  43. package/esm2015/plugins/vertical-align/vertical-align.editor.js +2 -2
  44. package/esm2015/public-api.js +2 -2
  45. package/esm2015/queries/get-insert-elements-path.js +1 -1
  46. package/esm2015/queries/get-plugin-key-by-toolbar-key.js +10 -0
  47. package/esm2015/queries/get-toolbar-disabled.js +14 -0
  48. package/esm2015/queries/index.js +4 -2
  49. package/esm2015/utils/fragment.js +7 -4
  50. package/fesm2015/worktile-theia.js +263 -344
  51. package/fesm2015/worktile-theia.js.map +1 -1
  52. package/interfaces/plugins/plugins.d.ts +5 -2
  53. package/interfaces/toolbar.d.ts +2 -1
  54. package/package.json +1 -1
  55. package/plugins/code/code.component.d.ts +2 -2
  56. package/plugins/color/toolbar-item.component.d.ts +3 -9
  57. package/plugins/font-size/font-size.editor.d.ts +0 -1
  58. package/plugins/heading/heading.plugin.d.ts +3 -3
  59. package/plugins/indent/indent.editor.d.ts +0 -1
  60. package/plugins/public-api.d.ts +0 -1
  61. package/plugins/table/toolbar-item.component.d.ts +3 -9
  62. package/plugins/vertical-align/toolbar-item.component.d.ts +5 -13
  63. package/public-api.d.ts +1 -1
  64. package/queries/get-plugin-key-by-toolbar-key.d.ts +3 -0
  65. package/queries/get-toolbar-disabled.d.ts +4 -0
  66. package/queries/index.d.ts +3 -1
  67. package/utils/fragment.d.ts +2 -2
  68. package/components/toolbar-base-item/toolbar-base-item.component.d.ts +0 -11
  69. package/esm2015/components/toolbar-base-item/toolbar-base-item.component.js +0 -24
  70. package/esm2015/plugins/indent/toolbar-item.component.js +0 -115
  71. package/plugins/indent/toolbar-item.component.d.ts +0 -36
@@ -2,7 +2,7 @@ import * as i0 from '@angular/core';
2
2
  import { InjectionToken, Component, ChangeDetectionStrategy, HostBinding, Injectable, Input, HostListener, ViewContainerRef, ChangeDetectorRef, Inject, ViewChild, Directive, ElementRef, TemplateRef, Pipe, EventEmitter, forwardRef, Output, NgModule } from '@angular/core';
3
3
  import * as i10 from '@angular/common';
4
4
  import { DOCUMENT, CommonModule } from '@angular/common';
5
- import * as i4$1 from '@angular/forms';
5
+ import * as i4 from '@angular/forms';
6
6
  import { NG_VALUE_ACCESSOR, FormsModule } from '@angular/forms';
7
7
  import * as i1 from 'slate-angular';
8
8
  import { BaseTextComponent, BaseElementComponent, AngularEditor, NODE_TO_PARENT, NODE_TO_INDEX, IS_SAFARI, hotkeys, getPlainText as getPlainText$1, ELEMENT_TO_COMPONENT, hasBlockCard, isCardLeft, FAKE_RIGHT_BLOCK_CARD_OFFSET, isComponentType, EDITOR_TO_ELEMENT, withAngular, SlateModule } from 'slate-angular';
@@ -13,7 +13,7 @@ import { HistoryEditor, withHistory } from 'slate-history';
13
13
  import { fromEvent, timer, Subject, combineLatest, Observable, BehaviorSubject, merge, ReplaySubject } from 'rxjs';
14
14
  import * as i1$1 from 'ngx-tethys/popover';
15
15
  import { ThyPopover } from 'ngx-tethys/popover';
16
- import * as i4 from 'ngx-tethys/icon';
16
+ import * as i3 from 'ngx-tethys/icon';
17
17
  import { ThyIconModule } from 'ngx-tethys/icon';
18
18
  import * as i5 from 'ngx-tethys/input';
19
19
  import { ThyInputModule } from 'ngx-tethys/input';
@@ -33,7 +33,7 @@ import { ThyUploadStatus } from 'ngx-tethys/uploader';
33
33
  import * as i1$3 from '@angular/platform-browser';
34
34
  import * as i6 from 'ngx-tethys/progress';
35
35
  import { ThyProgressModule } from 'ngx-tethys/progress';
36
- import * as i3 from 'ngx-tethys/nav';
36
+ import * as i3$1 from 'ngx-tethys/nav';
37
37
  import { ThyNavModule } from 'ngx-tethys/nav';
38
38
  import * as i5$1 from 'ngx-tethys/tooltip';
39
39
  import { ThyTooltipModule } from 'ngx-tethys/tooltip';
@@ -202,7 +202,8 @@ const ALIGN_BLOCK_TYPES = [ElementKinds.default, ElementKinds.listItem, ElementK
202
202
  const CONTAINER_BLOCKS = [ElementKinds.blockquote, ElementKinds.tableCell];
203
203
  const LIST_BLOCK_TYPES = [ElementKinds.numberedList, ElementKinds.bulletedList];
204
204
  const VOID_BLOCK_TYPES = [ElementKinds.image, ElementKinds.hr];
205
- const BLOCK_DELETEBACKWARD_TYPES = [ElementKinds.tableCell];
205
+ const BLOCK_DELETE_BACKWARD_TYPES = [ElementKinds.tableCell];
206
+ const DISABLED_OPERATE_TYPES = [ElementKinds.code, ElementKinds.hr];
206
207
 
207
208
  var ErrorCodes;
208
209
  (function (ErrorCodes) {
@@ -482,7 +483,7 @@ const THE_MODE_PROVIDER = {
482
483
  var ToolbarItemType;
483
484
  (function (ToolbarItemType) {
484
485
  ToolbarItemType["default"] = "default";
485
- ToolbarItemType["toolDropdown"] = "tool-dropdown";
486
+ ToolbarItemType["dropdown"] = "dropdown";
486
487
  })(ToolbarItemType || (ToolbarItemType = {}));
487
488
  var ToolbarAlignment;
488
489
  (function (ToolbarAlignment) {
@@ -700,7 +701,7 @@ class TheColorSelectComponent {
700
701
  }
701
702
  }
702
703
  TheColorSelectComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheColorSelectComponent, deps: [{ token: i1$1.ThyPopoverRef }], target: i0.ɵɵFactoryTarget.Component });
703
- TheColorSelectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheColorSelectComponent, selector: "the-color-select", inputs: { selectedColor: "selectedColor", selectAction: "selectAction", showCustom: "showCustom", colors: "colors", option: "option" }, host: { listeners: { "document: mousedown": "handleDocumentMouseDown($event)", "mousedown": "handleMouseDown($event)", "keydown": "handleKeydown($event)" } }, ngImport: i0, template: "<div class=\"color-container\">\n <div class=\"colors\">\n <div *ngFor=\"let row of selectColors; let rowIndex = index\">\n <span\n class=\"color-item\"\n *ngFor=\"let _color of row.rowValue; let i = index\"\n [ngClass]=\"_color.classMaps\"\n (mousedown)=\"_selectColor($event, _color.value)\"\n >\n <span [ngStyle]=\"{ background: _color.value }\">\n <thy-icon thyIconName=\"check\" [ngStyle]=\"{ color: row.tickColor }\"></thy-icon>\n </span>\n </span>\n </div>\n </div>\n <div *ngIf=\"option.showCustom\" class=\"select-color\">\n <span class=\"color\" [ngStyle]=\"{ background: selectedColor }\"></span>\n #\n <input\n thyInput\n maxlength=\"6\"\n (keydown.enter)=\"customInputColorEnter($event)\"\n onkeyup=\"value=value.replace(/[^0-9A-Fa-f]/g,'')\"\n class=\"value\"\n [(ngModel)]=\"customColor\"\n (ngModelChange)=\"colorChange(false)\"\n />\n </div>\n</div>\n", components: [{ type: i4.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }], directives: [{ type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i10.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.ThyInputDirective, selector: "[thyInput]", inputs: ["thySize", "thyAutocomplete"] }, { type: i4$1.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { type: i4$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i4$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
704
+ TheColorSelectComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheColorSelectComponent, selector: "the-color-select", inputs: { selectedColor: "selectedColor", selectAction: "selectAction", showCustom: "showCustom", colors: "colors", option: "option" }, host: { listeners: { "document: mousedown": "handleDocumentMouseDown($event)", "mousedown": "handleMouseDown($event)", "keydown": "handleKeydown($event)" } }, ngImport: i0, template: "<div class=\"color-container\">\n <div class=\"colors\">\n <div *ngFor=\"let row of selectColors; let rowIndex = index\">\n <span\n class=\"color-item\"\n *ngFor=\"let _color of row.rowValue; let i = index\"\n [ngClass]=\"_color.classMaps\"\n (mousedown)=\"_selectColor($event, _color.value)\"\n >\n <span [ngStyle]=\"{ background: _color.value }\">\n <thy-icon thyIconName=\"check\" [ngStyle]=\"{ color: row.tickColor }\"></thy-icon>\n </span>\n </span>\n </div>\n </div>\n <div *ngIf=\"option.showCustom\" class=\"select-color\">\n <span class=\"color\" [ngStyle]=\"{ background: selectedColor }\"></span>\n #\n <input\n thyInput\n maxlength=\"6\"\n (keydown.enter)=\"customInputColorEnter($event)\"\n onkeyup=\"value=value.replace(/[^0-9A-Fa-f]/g,'')\"\n class=\"value\"\n [(ngModel)]=\"customColor\"\n (ngModelChange)=\"colorChange(false)\"\n />\n </div>\n</div>\n", components: [{ type: i3.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }], directives: [{ type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i10.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.ThyInputDirective, selector: "[thyInput]", inputs: ["thySize", "thyAutocomplete"] }, { type: i4.MaxLengthValidator, selector: "[maxlength][formControlName],[maxlength][formControl],[maxlength][ngModel]", inputs: ["maxlength"] }, { type: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
704
705
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheColorSelectComponent, decorators: [{
705
706
  type: Component,
706
707
  args: [{
@@ -1001,10 +1002,10 @@ function deleteElementKey(nodes, key) {
1001
1002
  return nodes;
1002
1003
  }
1003
1004
  /**
1004
- * 删除 text 节点的 颜色/背景色
1005
+ * 过滤文本格式:颜色/背景色/字体大小
1005
1006
  * @param node
1006
1007
  */
1007
- function deleteColorAndBackgroundColorOfText(node) {
1008
+ function filterTextFormat(node) {
1008
1009
  node.children.forEach((child) => {
1009
1010
  if (Text.isText(child)) {
1010
1011
  if (child['color']) {
@@ -1013,9 +1014,12 @@ function deleteColorAndBackgroundColorOfText(node) {
1013
1014
  if (child['background-color']) {
1014
1015
  delete child['background-color'];
1015
1016
  }
1017
+ if (child['font-size']) {
1018
+ delete child['font-size'];
1019
+ }
1016
1020
  }
1017
1021
  else {
1018
- deleteColorAndBackgroundColorOfText(child);
1022
+ filterTextFormat(child);
1019
1023
  }
1020
1024
  });
1021
1025
  }
@@ -1107,17 +1111,17 @@ const mergeArray = (origin, source) => {
1107
1111
 
1108
1112
  const mergeOptions = (plugin, override) => {
1109
1113
  const { options } = plugin;
1110
- const newOptions = {};
1111
- for (let option in options) {
1112
- if (Array.isArray(options[option]) && override.options[option]) {
1113
- newOptions[option] = mergeArray(options[option], override.options[option]);
1114
+ const newOptions = options;
1115
+ for (let option in override.options) {
1116
+ if (Array.isArray(override.options[option]) && newOptions[option]) {
1117
+ newOptions[option] = mergeArray(newOptions[option], override.options[option]);
1114
1118
  continue;
1115
1119
  }
1116
- if (isObject(options[option])) {
1117
- newOptions[option] = _.assign(options[option], override.options[option]);
1120
+ if (isObject(override.options[option]) && newOptions[option]) {
1121
+ newOptions[option] = _.assign(newOptions[option], override.options[option]);
1118
1122
  continue;
1119
1123
  }
1120
- newOptions[option] = override.options[option] ? override.options[option] : options[option];
1124
+ newOptions[option] = override.options[option];
1121
1125
  }
1122
1126
  plugin.options = newOptions;
1123
1127
  };
@@ -2029,6 +2033,28 @@ const isContainNestedType = (editor, types) => {
2029
2033
  return false;
2030
2034
  };
2031
2035
 
2036
+ const getToolbarItemDisabled = (editor, key, customTypes) => {
2037
+ var _a, _b;
2038
+ if (editor.selection) {
2039
+ let disabledOperateTypes = (_b = (_a = getPluginOptions(editor, key)) === null || _a === void 0 ? void 0 : _a.disabledOperateTypes) !== null && _b !== void 0 ? _b : [];
2040
+ if (customTypes === null || customTypes === void 0 ? void 0 : customTypes.length) {
2041
+ disabledOperateTypes = Array.from(new Set([...disabledOperateTypes, ...customTypes]));
2042
+ }
2043
+ const anchorNode = anchorBlock(editor);
2044
+ return anchorNode && disabledOperateTypes.includes(anchorNode === null || anchorNode === void 0 ? void 0 : anchorNode.type);
2045
+ }
2046
+ };
2047
+
2048
+ const getPluginKeyByToolbarKey = (editor, toolbarKey) => {
2049
+ for (let key in editor.pluginsByKey) {
2050
+ const toolbarItems = editor.pluginsByKey[key].toolbarItems;
2051
+ if (toolbarItems && toolbarItems.some(item => item.key === toolbarKey)) {
2052
+ toolbarKey = key;
2053
+ }
2054
+ }
2055
+ return toolbarKey;
2056
+ };
2057
+
2032
2058
  var index$1 = /*#__PURE__*/Object.freeze({
2033
2059
  __proto__: null,
2034
2060
  getLastNode: getLastNode,
@@ -2085,7 +2111,9 @@ var index$1 = /*#__PURE__*/Object.freeze({
2085
2111
  findPath: findPath,
2086
2112
  findNode: findNode,
2087
2113
  findDescendant: findDescendant,
2088
- someNode: someNode
2114
+ someNode: someNode,
2115
+ getToolbarItemDisabled: getToolbarItemDisabled,
2116
+ getPluginKeyByToolbarKey: getPluginKeyByToolbarKey
2089
2117
  });
2090
2118
 
2091
2119
  const insertElements = (editor, elements) => {
@@ -2612,7 +2640,7 @@ const withResetType = (editor) => {
2612
2640
  editor.onKeydown = (event) => {
2613
2641
  const { selection } = editor;
2614
2642
  if (IS_SAFARI && selection && Range.isCollapsed(selection) && hotkeys.isDeleteBackward(event)) {
2615
- const blockEntry = getAboveByType(editor, BLOCK_DELETEBACKWARD_TYPES);
2643
+ const blockEntry = getAboveByType(editor, BLOCK_DELETE_BACKWARD_TYPES);
2616
2644
  if (blockEntry && blockEntry[0]) {
2617
2645
  const isStart = Editor.isStart(editor, selection.anchor, blockEntry[1]);
2618
2646
  if (isStart) {
@@ -3045,7 +3073,7 @@ class TheImageComponent extends TheBaseElementComponent {
3045
3073
  }
3046
3074
  }
3047
3075
  TheImageComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheImageComponent, deps: [{ token: i0.ElementRef }, { token: i1$3.DomSanitizer }, { token: THE_UPLOAD_SERVICE_TOKEN }, { token: i0.ChangeDetectorRef }, { token: TheContextService }, { token: i1$1.ThyPopover }, { token: i2.Overlay }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Component });
3048
- TheImageComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheImageComponent, selector: "the-image, [theImage]", viewQueries: [{ propertyName: "imageContent", first: true, predicate: ["imageContent"], descendants: true }, { propertyName: "img", first: true, predicate: ["img"], descendants: true }, { propertyName: "layoutToolbar", first: true, predicate: ["layoutToolbar"], descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<slate-children [children]=\"children\" [context]=\"childrenContext\" [viewContext]=\"viewContext\"></slate-children>\n\n<div class=\"image-container\" contenteditable=\"false\" [style.textAlign]=\"imageEntry.align\">\n <div\n #imageContent\n *ngIf=\"imageEntry.thumbUrl\"\n class=\"image-content\"\n [class.pointer]=\"!selection\"\n [ngStyle]=\"{\n 'width.px':\n imageEntry?.layout && imageEntry?.width > layoutDefaultWidth && !imageEntry?.reSized\n ? layoutDefaultWidth\n : imageEntry.width,\n 'height.px': imageEntry.height\n }\"\n >\n <img #img class=\"main-image\" [src]=\"imageEntry.thumbUrl\" [alt]=\"imageEntry.name\" />\n <div *ngIf=\"selection\" class=\"image-profile\" [class.outline]=\"selection\">\n <span *ngIf=\"isCollapsed\" (mousedown)=\"startDrag($event, '-xl')\" class=\"image-pointer left top\"></span>\n <span *ngIf=\"isCollapsed\" (mousedown)=\"startDrag($event, 'xl')\" class=\"image-pointer right top\"></span>\n <span *ngIf=\"isCollapsed\" (mousedown)=\"startDrag($event, 'xl')\" class=\"image-pointer right bottom\"></span>\n <span *ngIf=\"isCollapsed\" (mousedown)=\"startDrag($event, '-xl')\" class=\"image-pointer left bottom\"></span>\n </div>\n <div *ngIf=\"uploading\" class=\"uploading\">\n <div class=\"uploading-percentage\">\n <thy-progress thyType=\"primary\" [thyValue]=\"percentage\" thySize=\"sm\"></thy-progress>\n <thy-icon (click)=\"cancelUpload($event)\" thyIconName=\"close-circle-bold-fill\" thyIconLegging=\"true\"></thy-icon>\n </div>\n </div>\n <div *ngIf=\"!uploading\" class=\"layer\" (mousedown)=\"preview($event)\" [class.readonly]=\"readonly\"></div>\n </div>\n <div *ngIf=\"!imageEntry.thumbUrl\" class=\"image-loading\" contenteditable=\"false\">\n <thy-icon thyIconName=\"image\"></thy-icon>\n </div>\n</div>\n\n<ng-template #layoutToolbar>\n <div class=\"the-block-toolbar-popover\" contenteditable=\"false\">\n <thy-icon-nav>\n <ng-container *ngFor=\"let item of layoutOptions\">\n <a\n *ngIf=\"item.key !== 'split'\"\n href=\"javascript:;\"\n thyIconNavLink\n [ngClass]=\"{ 'remove-link': item.key === 'remove' }\"\n [thyIconNavLinkIcon]=\"item.icon\"\n [thyTooltip]=\"item.name\"\n [thyIconNavLinkActive]=\"layoutActive(item.key)\"\n thyTooltipPlacement=\"top\"\n (mousedown)=\"item?.handle($event, item.key)\"\n ></a>\n <nav-split-line *ngIf=\"item.key === 'split'\"></nav-split-line>\n </ng-container>\n </thy-icon-nav>\n </div>\n</ng-template>\n", components: [{ type: i1.SlateChildrenComponent, selector: "slate-children", inputs: ["children", "context", "viewContext"] }, { type: i6.ThyProgressComponent, selector: "thy-progress", inputs: ["thyType", "thySize", "thyValue", "thyMax", "thyTips"] }, { type: i4.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { type: i3.ThyIconNavComponent, selector: "thy-icon-nav", inputs: ["thyType"] }, { type: i3.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: NavSplitLineComponent, selector: "nav-split-line", inputs: ["mode"] }], directives: [{ type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i10.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }] });
3076
+ TheImageComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheImageComponent, selector: "the-image, [theImage]", viewQueries: [{ propertyName: "imageContent", first: true, predicate: ["imageContent"], descendants: true }, { propertyName: "img", first: true, predicate: ["img"], descendants: true }, { propertyName: "layoutToolbar", first: true, predicate: ["layoutToolbar"], descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<slate-children [children]=\"children\" [context]=\"childrenContext\" [viewContext]=\"viewContext\"></slate-children>\n\n<div class=\"image-container\" contenteditable=\"false\" [style.textAlign]=\"imageEntry.align\">\n <div\n #imageContent\n *ngIf=\"imageEntry.thumbUrl\"\n class=\"image-content\"\n [class.pointer]=\"!selection\"\n [ngStyle]=\"{\n 'width.px':\n imageEntry?.layout && imageEntry?.width > layoutDefaultWidth && !imageEntry?.reSized\n ? layoutDefaultWidth\n : imageEntry.width,\n 'height.px': imageEntry.height\n }\"\n >\n <img #img class=\"main-image\" [src]=\"imageEntry.thumbUrl\" [alt]=\"imageEntry.name\" />\n <div *ngIf=\"selection\" class=\"image-profile\" [class.outline]=\"selection\">\n <span *ngIf=\"isCollapsed\" (mousedown)=\"startDrag($event, '-xl')\" class=\"image-pointer left top\"></span>\n <span *ngIf=\"isCollapsed\" (mousedown)=\"startDrag($event, 'xl')\" class=\"image-pointer right top\"></span>\n <span *ngIf=\"isCollapsed\" (mousedown)=\"startDrag($event, 'xl')\" class=\"image-pointer right bottom\"></span>\n <span *ngIf=\"isCollapsed\" (mousedown)=\"startDrag($event, '-xl')\" class=\"image-pointer left bottom\"></span>\n </div>\n <div *ngIf=\"uploading\" class=\"uploading\">\n <div class=\"uploading-percentage\">\n <thy-progress thyType=\"primary\" [thyValue]=\"percentage\" thySize=\"sm\"></thy-progress>\n <thy-icon (click)=\"cancelUpload($event)\" thyIconName=\"close-circle-bold-fill\" thyIconLegging=\"true\"></thy-icon>\n </div>\n </div>\n <div *ngIf=\"!uploading\" class=\"layer\" (mousedown)=\"preview($event)\" [class.readonly]=\"readonly\"></div>\n </div>\n <div *ngIf=\"!imageEntry.thumbUrl\" class=\"image-loading\" contenteditable=\"false\">\n <thy-icon thyIconName=\"image\"></thy-icon>\n </div>\n</div>\n\n<ng-template #layoutToolbar>\n <div class=\"the-block-toolbar-popover\" contenteditable=\"false\">\n <thy-icon-nav>\n <ng-container *ngFor=\"let item of layoutOptions\">\n <a\n *ngIf=\"item.key !== 'split'\"\n href=\"javascript:;\"\n thyIconNavLink\n [ngClass]=\"{ 'remove-link': item.key === 'remove' }\"\n [thyIconNavLinkIcon]=\"item.icon\"\n [thyTooltip]=\"item.name\"\n [thyIconNavLinkActive]=\"layoutActive(item.key)\"\n thyTooltipPlacement=\"top\"\n (mousedown)=\"item?.handle($event, item.key)\"\n ></a>\n <nav-split-line *ngIf=\"item.key === 'split'\"></nav-split-line>\n </ng-container>\n </thy-icon-nav>\n </div>\n</ng-template>\n", components: [{ type: i1.SlateChildrenComponent, selector: "slate-children", inputs: ["children", "context", "viewContext"] }, { type: i6.ThyProgressComponent, selector: "thy-progress", inputs: ["thyType", "thySize", "thyValue", "thyMax", "thyTips"] }, { type: i3.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { type: i3$1.ThyIconNavComponent, selector: "thy-icon-nav", inputs: ["thyType"] }, { type: i3$1.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: NavSplitLineComponent, selector: "nav-split-line", inputs: ["mode"] }], directives: [{ type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i10.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }] });
3049
3077
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheImageComponent, decorators: [{
3050
3078
  type: Component,
3051
3079
  args: [{
@@ -5375,12 +5403,7 @@ const AlignEditor = {
5375
5403
  var _a;
5376
5404
  const contextService = (_a = editor === null || editor === void 0 ? void 0 : editor.injector) === null || _a === void 0 ? void 0 : _a.get(TheContextService);
5377
5405
  const { theOptions: { richMedia } } = contextService.getOptions();
5378
- if (richMedia && editor.selection) {
5379
- const disableGroup = [ElementKinds.image];
5380
- const anchorBlock$1 = anchorBlock(editor);
5381
- return anchorBlock$1 && disableGroup.includes(anchorBlock$1 === null || anchorBlock$1 === void 0 ? void 0 : anchorBlock$1.type);
5382
- }
5383
- return false;
5406
+ return getToolbarItemDisabled(editor, PluginKeys.align, richMedia ? [ElementKinds.image] : []);
5384
5407
  },
5385
5408
  setAlign(editor, alignment) {
5386
5409
  if (TableEditor.setAlign(editor, alignment)) {
@@ -5420,7 +5443,7 @@ const createAlignPlugin = createPluginFactory({
5420
5443
  toolbarItems: [
5421
5444
  {
5422
5445
  key: ToolbarActionTypes.alignType,
5423
- type: ToolbarItemType.toolDropdown,
5446
+ type: ToolbarItemType.dropdown,
5424
5447
  dropdownMode: DropdownMode.icon,
5425
5448
  dropdownItemKey: ToolbarActionTypes.alignLeft,
5426
5449
  includes: [ToolbarActionTypes.alignLeft, ToolbarActionTypes.alignCenter, ToolbarActionTypes.alignRight],
@@ -5448,11 +5471,15 @@ const createAlignPlugin = createPluginFactory({
5448
5471
  execute: editor => AlignEditor.setAlign(editor, Alignment.right),
5449
5472
  active: editor => AlignEditor.isActive(editor, Alignment.right)
5450
5473
  }
5451
- ]
5474
+ ],
5475
+ options: {
5476
+ disabledOperateTypes: [...DISABLED_OPERATE_TYPES]
5477
+ }
5452
5478
  });
5453
5479
 
5454
5480
  const headingOptions = {
5455
5481
  allowParentTypes: [ElementKinds.tableCell, ElementKinds.blockquote],
5482
+ disabledOperateTypes: [ElementKinds.image, ...DISABLED_OPERATE_TYPES],
5456
5483
  cleanupTypes: [ElementKinds.bulletedList, ElementKinds.numberedList, ElementKinds.listItem]
5457
5484
  };
5458
5485
  const HeadingEditor = {
@@ -5530,7 +5557,7 @@ const createHeadingPlugin = createPluginFactory({
5530
5557
  {
5531
5558
  key: ElementKinds.headingList,
5532
5559
  name: '正文',
5533
- type: ToolbarItemType.toolDropdown,
5560
+ type: ToolbarItemType.dropdown,
5534
5561
  dropdownItemKey: ElementKinds.paragraph,
5535
5562
  includes: [ElementKinds.paragraph, ...STANDARD_HEADING_TYPES]
5536
5563
  },
@@ -5694,7 +5721,10 @@ const createMarkPlugin = createPluginFactory({
5694
5721
  execute: editor => MarkEditor.toggleMark(editor, MarkTypes.underline),
5695
5722
  active: editor => MarkEditor.isMarkActive(editor, MarkTypes.underline)
5696
5723
  }
5697
- ]
5724
+ ],
5725
+ options: {
5726
+ disabledOperateTypes: [ElementKinds.image, ...DISABLED_OPERATE_TYPES]
5727
+ }
5698
5728
  });
5699
5729
 
5700
5730
  const withNodeID = (e) => {
@@ -5955,6 +5985,7 @@ const CodeEditor = {
5955
5985
 
5956
5986
  const defaultAutoFormatRules = [
5957
5987
  {
5988
+ key: ElementKinds.heading_1,
5958
5989
  type: ElementKinds.heading_1,
5959
5990
  markup: '#',
5960
5991
  format: (editor) => {
@@ -5962,6 +5993,7 @@ const defaultAutoFormatRules = [
5962
5993
  }
5963
5994
  },
5964
5995
  {
5996
+ key: ElementKinds.heading_2,
5965
5997
  type: ElementKinds.heading_2,
5966
5998
  markup: '##',
5967
5999
  format: (editor) => {
@@ -5969,6 +6001,7 @@ const defaultAutoFormatRules = [
5969
6001
  }
5970
6002
  },
5971
6003
  {
6004
+ key: ElementKinds.heading_3,
5972
6005
  type: ElementKinds.heading_3,
5973
6006
  markup: '###',
5974
6007
  format: (editor) => {
@@ -5976,6 +6009,7 @@ const defaultAutoFormatRules = [
5976
6009
  }
5977
6010
  },
5978
6011
  {
6012
+ key: ElementKinds.heading_4,
5979
6013
  type: ElementKinds.heading_4,
5980
6014
  markup: '####',
5981
6015
  format: (editor) => {
@@ -5983,6 +6017,7 @@ const defaultAutoFormatRules = [
5983
6017
  }
5984
6018
  },
5985
6019
  {
6020
+ key: ElementKinds.heading_5,
5986
6021
  type: ElementKinds.heading_5,
5987
6022
  markup: '#####',
5988
6023
  format: (editor) => {
@@ -5990,6 +6025,7 @@ const defaultAutoFormatRules = [
5990
6025
  }
5991
6026
  },
5992
6027
  {
6028
+ key: ElementKinds.heading_6,
5993
6029
  type: ElementKinds.heading_6,
5994
6030
  markup: '######',
5995
6031
  format: (editor) => {
@@ -5997,6 +6033,7 @@ const defaultAutoFormatRules = [
5997
6033
  }
5998
6034
  },
5999
6035
  {
6036
+ key: ElementKinds.blockquote,
6000
6037
  type: ElementKinds.blockquote,
6001
6038
  markup: ['>'],
6002
6039
  format: (editor) => {
@@ -6004,30 +6041,35 @@ const defaultAutoFormatRules = [
6004
6041
  }
6005
6042
  },
6006
6043
  {
6044
+ key: MarkTypes.bold,
6007
6045
  type: MarkTypes.bold,
6008
6046
  between: ['**', '**'],
6009
6047
  mode: 'inline',
6010
6048
  insertTrigger: true
6011
6049
  },
6012
6050
  {
6051
+ key: `${MarkTypes.bold}__`,
6013
6052
  type: MarkTypes.bold,
6014
6053
  between: ['__', '__'],
6015
6054
  mode: 'inline',
6016
6055
  insertTrigger: true
6017
6056
  },
6018
6057
  {
6058
+ key: MarkTypes.italic,
6019
6059
  type: MarkTypes.italic,
6020
6060
  between: ['*', '*'],
6021
6061
  mode: 'inline',
6022
6062
  insertTrigger: true
6023
6063
  },
6024
6064
  {
6065
+ key: `${MarkTypes.italic}_`,
6025
6066
  type: MarkTypes.italic,
6026
6067
  between: ['_', '_'],
6027
6068
  mode: 'inline',
6028
6069
  insertTrigger: true
6029
6070
  },
6030
6071
  {
6072
+ key: ElementKinds.inlineCode,
6031
6073
  type: ElementKinds.inlineCode,
6032
6074
  between: ['`', '`'],
6033
6075
  mode: 'inline',
@@ -6037,12 +6079,14 @@ const defaultAutoFormatRules = [
6037
6079
  }
6038
6080
  },
6039
6081
  {
6082
+ key: MarkTypes.strike,
6040
6083
  type: MarkTypes.strike,
6041
6084
  between: ['~~', '~~'],
6042
6085
  mode: 'inline',
6043
6086
  insertTrigger: true
6044
6087
  },
6045
6088
  {
6089
+ key: ElementKinds.code,
6046
6090
  type: ElementKinds.code,
6047
6091
  markup: '```',
6048
6092
  format: (editor) => {
@@ -6050,6 +6094,7 @@ const defaultAutoFormatRules = [
6050
6094
  }
6051
6095
  },
6052
6096
  {
6097
+ key: ElementKinds.listItem,
6053
6098
  type: ElementKinds.listItem,
6054
6099
  markup: [],
6055
6100
  match: (editor) => {
@@ -6060,8 +6105,8 @@ const defaultAutoFormatRules = [
6060
6105
  }
6061
6106
  },
6062
6107
  {
6063
- type: ElementKinds.listItem,
6064
6108
  key: ElementKinds.numberedList,
6109
+ type: ElementKinds.listItem,
6065
6110
  markup: [],
6066
6111
  match: (editor, textFromBlockStart) => {
6067
6112
  return isParagraph(editor) && /^-?\d+(\.|\))$/.test(textFromBlockStart) ? [textFromBlockStart] : [];
@@ -6078,6 +6123,7 @@ const defaultAutoFormatRules = [
6078
6123
  }
6079
6124
  },
6080
6125
  {
6126
+ key: ElementKinds.checkItem,
6081
6127
  type: ElementKinds.checkItem,
6082
6128
  markup: [],
6083
6129
  match: (editor) => {
@@ -6088,6 +6134,7 @@ const defaultAutoFormatRules = [
6088
6134
  }
6089
6135
  },
6090
6136
  {
6137
+ key: ElementKinds.hr,
6091
6138
  type: ElementKinds.hr,
6092
6139
  markup: '---',
6093
6140
  insertTrigger: true
@@ -6758,7 +6805,19 @@ const createRemoveVoidPlugin = createPluginFactory({
6758
6805
  withOverrides: withRemoveVoid
6759
6806
  });
6760
6807
 
6761
- class TheToolbarBaseItemComponent {
6808
+ class TheBaseToolbarItem {
6809
+ set toolbarItem(value) {
6810
+ this._toolbarItem = value;
6811
+ }
6812
+ get toolbarItem() {
6813
+ return this._toolbarItem;
6814
+ }
6815
+ get disabledState() {
6816
+ return this.disabled;
6817
+ }
6818
+ get activeState() {
6819
+ return this.active;
6820
+ }
6762
6821
  execute(event) {
6763
6822
  var _a;
6764
6823
  event.preventDefault();
@@ -6770,30 +6829,76 @@ class TheToolbarBaseItemComponent {
6770
6829
  AngularEditor.focus(this.editor);
6771
6830
  }
6772
6831
  }
6832
+ selectionChange(editor) {
6833
+ var _a, _b, _c, _d, _e, _f;
6834
+ if (editor.selection) {
6835
+ this.active = ((_a = this._toolbarItem) === null || _a === void 0 ? void 0 : _a.active) ? (_b = this._toolbarItem) === null || _b === void 0 ? void 0 : _b.active(editor) : false;
6836
+ if ((_c = this._toolbarItem) === null || _c === void 0 ? void 0 : _c.disable) {
6837
+ this.disabled = ((_d = this._toolbarItem) === null || _d === void 0 ? void 0 : _d.disable) ? (_e = this._toolbarItem) === null || _e === void 0 ? void 0 : _e.disable(editor) : false;
6838
+ }
6839
+ else {
6840
+ const pluginKey = getPluginKeyByToolbarKey(editor, (_f = this._toolbarItem) === null || _f === void 0 ? void 0 : _f.key);
6841
+ this.disabled = pluginKey && getToolbarItemDisabled(editor, pluginKey);
6842
+ }
6843
+ }
6844
+ }
6773
6845
  }
6774
- TheToolbarBaseItemComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheToolbarBaseItemComponent, deps: [], target: i0.ɵɵFactoryTarget.Directive });
6775
- TheToolbarBaseItemComponent.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.15", type: TheToolbarBaseItemComponent, ngImport: i0 });
6776
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheToolbarBaseItemComponent, decorators: [{
6846
+ TheBaseToolbarItem.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheBaseToolbarItem, deps: [], target: i0.ɵɵFactoryTarget.Directive });
6847
+ TheBaseToolbarItem.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.15", type: TheBaseToolbarItem, inputs: { toolbarItem: "toolbarItem", editor: "editor" }, host: { properties: { "class.disabled": "this.disabledState", "class.active": "this.activeState" } }, ngImport: i0 });
6848
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheBaseToolbarItem, decorators: [{
6777
6849
  type: Directive
6778
- }] });
6850
+ }], propDecorators: { toolbarItem: [{
6851
+ type: Input
6852
+ }], editor: [{
6853
+ type: Input
6854
+ }], disabledState: [{
6855
+ type: HostBinding,
6856
+ args: ['class.disabled']
6857
+ }], activeState: [{
6858
+ type: HostBinding,
6859
+ args: ['class.active']
6860
+ }] } });
6861
+ class TheBaseToolbarDropdown extends TheBaseToolbarItem {
6862
+ constructor() {
6863
+ super(...arguments);
6864
+ this.mode = DropdownMode.text;
6865
+ }
6866
+ get defaultDropdownItem() {
6867
+ const activeItem = this.dropdownItemKey && this.menus.find((item) => item.key === this.dropdownItemKey);
6868
+ return activeItem ? activeItem : this.menus[0];
6869
+ }
6870
+ selectionChange(editor) {
6871
+ super.selectionChange(editor);
6872
+ const activeItem = this.menus.find(i => {
6873
+ if (i === null || i === void 0 ? void 0 : i.active) {
6874
+ return i === null || i === void 0 ? void 0 : i.active(editor);
6875
+ }
6876
+ });
6877
+ if (!this.toolbarItem.dropdownFixedIcon) {
6878
+ this.activeMenuItem = activeItem ? activeItem : this.defaultDropdownItem;
6879
+ }
6880
+ }
6881
+ }
6882
+ TheBaseToolbarDropdown.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheBaseToolbarDropdown, deps: null, target: i0.ɵɵFactoryTarget.Directive });
6883
+ TheBaseToolbarDropdown.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "12.0.0", version: "12.2.15", type: TheBaseToolbarDropdown, inputs: { menus: "menus", mode: "mode", dropdownItemKey: "dropdownItemKey" }, usesInheritance: true, ngImport: i0 });
6884
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheBaseToolbarDropdown, decorators: [{
6885
+ type: Directive
6886
+ }], propDecorators: { menus: [{
6887
+ type: Input
6888
+ }], mode: [{
6889
+ type: Input
6890
+ }], dropdownItemKey: [{
6891
+ type: Input
6892
+ }] } });
6779
6893
 
6780
- class TheToolbarDropdownComponent extends TheToolbarBaseItemComponent {
6894
+ class TheToolbarDropdownComponent extends TheBaseToolbarDropdown {
6781
6895
  constructor(elementRef, thyPopover, viewContainerRef, overlay) {
6782
6896
  super();
6783
6897
  this.elementRef = elementRef;
6784
6898
  this.thyPopover = thyPopover;
6785
6899
  this.viewContainerRef = viewContainerRef;
6786
6900
  this.overlay = overlay;
6787
- this.mode = DropdownMode.text;
6788
6901
  this.dropdownMode = DropdownMode;
6789
- this.disabled = false;
6790
- }
6791
- set item(i) {
6792
- this._item = i;
6793
- this.activeMenu = i;
6794
- }
6795
- get item() {
6796
- return this._item;
6797
6902
  }
6798
6903
  get isOpen() {
6799
6904
  return this.dropdownPopoverRef && this.dropdownPopoverRef.getOverlayRef() && this.dropdownPopoverRef.getOverlayRef().hasAttached();
@@ -6811,34 +6916,24 @@ class TheToolbarDropdownComponent extends TheToolbarBaseItemComponent {
6811
6916
  this.closeDropdownPopover();
6812
6917
  }
6813
6918
  }
6814
- get disabledState() {
6815
- return this.disabled;
6816
- }
6817
6919
  ngOnInit() {
6818
6920
  var _a;
6819
6921
  if (!this.template) {
6820
6922
  this.template = this.mode === this.dropdownMode.icon ? this.iconModeTemplate : this.textModeTemplate;
6821
6923
  }
6822
- if (!this.activeMenu) {
6823
- this.activeMenu = this.menus[0];
6924
+ if (!this.activeMenuItem) {
6925
+ this.activeMenuItem = this.defaultDropdownItem;
6824
6926
  }
6825
6927
  if (this.toolbarItem) {
6826
6928
  this.elementRef.nativeElement.classList.add(`${(_a = this.toolbarItem) === null || _a === void 0 ? void 0 : _a.key}`);
6827
6929
  }
6828
6930
  }
6829
- statusChange(editor) {
6830
- var _a, _b;
6831
- this.disabled = ((_a = this.toolbarItem) === null || _a === void 0 ? void 0 : _a.disable) ? (_b = this.toolbarItem) === null || _b === void 0 ? void 0 : _b.disable(editor) : false;
6832
- const activeItem = this.menus.find(i => {
6833
- if (i === null || i === void 0 ? void 0 : i.active) {
6834
- return i === null || i === void 0 ? void 0 : i.active(editor);
6835
- }
6836
- });
6837
- this.activeMenu = activeItem ? activeItem : this.item;
6838
- }
6839
6931
  itemMousedown(event, item) {
6840
6932
  super.execute(event);
6841
6933
  this.closeDropdownPopover();
6934
+ if (!this.toolbarItem.dropdownFixedIcon) {
6935
+ this.activeMenuItem = item;
6936
+ }
6842
6937
  if (this.itemMousedownHandle) {
6843
6938
  this.itemMousedownHandle(item);
6844
6939
  return;
@@ -6888,7 +6983,7 @@ class TheToolbarDropdownComponent extends TheToolbarBaseItemComponent {
6888
6983
  }
6889
6984
  }
6890
6985
  TheToolbarDropdownComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheToolbarDropdownComponent, deps: [{ token: i0.ElementRef }, { token: i1$1.ThyPopover }, { token: i0.ViewContainerRef }, { token: i2.Overlay }], target: i0.ɵɵFactoryTarget.Component });
6891
- TheToolbarDropdownComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheToolbarDropdownComponent, selector: "the-toolbar-dropdown", inputs: { toolbarItem: "toolbarItem", menus: "menus", mode: "mode", item: "item", itemMousedownHandle: "itemMousedownHandle" }, host: { listeners: { "mousedown": "toggleDropdown($event)", "document: mousedown": "handleDocumentMouseDown($event)" }, properties: { "class.disabled": "this.disabledState" }, classAttribute: "the-toolbar-dropdown-container" }, viewQueries: [{ propertyName: "iconModeTemplate", first: true, predicate: ["iconModeTemplate"], descendants: true, static: true }, { propertyName: "textModeTemplate", first: true, predicate: ["textModeTemplate"], descendants: true, static: true }, { propertyName: "dropdownTemplate", first: true, predicate: ["dropdownTemplate"], descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<ng-template [ngTemplateOutlet]=\"template\"></ng-template>\n\n<ng-template #iconModeTemplate>\n <a thyIconNavLink class=\"icon-mode link-with-down\" [thyTooltip]=\"activeMenu?.name\" thyTooltipPlacement=\"top\">\n <thy-icon [thyIconName]=\"activeMenu?.icon\"></thy-icon>\n <thy-icon class=\"caret-down-icon font-size-sm text-desc\" thyIconName=\"caret-down\"></thy-icon>\n </a>\n</ng-template>\n\n<ng-template #textModeTemplate>\n <a thyIconNavLink class=\"text-mode\" [thyTooltip]=\"activeMenu?.name\" thyTooltipPlacement=\"top\">\n <span class=\"show-text\">{{ activeMenu?.name }}</span>\n <thy-icon class=\"text-caret-down-icon font-size-sm text-desc\" thyIconName=\"caret-down\"></thy-icon>\n </a>\n</ng-template>\n\n<ng-template #dropdownTemplate>\n <thy-action-menu class=\"dropdown\">\n <ng-container *ngFor=\"let menu of menus\">\n <a\n *ngIf=\"menu.key !== 'split'\"\n thyActionMenuItem\n href=\"javascript:;\"\n [thyActionMenuItemActive]=\"menu.key === activeMenu.key\"\n (mousedown)=\"itemMousedown($event, menu)\"\n [ngStyle]=\"menu?.styles\"\n >\n <span *ngIf=\"menu.icon && mode === dropdownMode.icon\" thyActionMenuItemIcon>\n <thy-icon [thyIconName]=\"menu.icon\"></thy-icon>\n </span>\n <span *ngIf=\"menu.name\" thyActionMenuItemName>{{ menu.name }}</span>\n </a>\n <thy-action-menu-divider *ngIf=\"menu.key === 'split'\"></thy-action-menu-divider>\n </ng-container>\n </thy-action-menu>\n</ng-template>\n", components: [{ type: i3.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i4.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { type: i2$1.ThyActionMenuComponent, selector: "thy-action-menu", inputs: ["thyTheme", "thyWidth"] }, { type: i2$1.ThyActionMenuDividerComponent, selector: "thy-action-menu-divider", inputs: ["thyTitle", "thyType"] }], directives: [{ type: i10.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }, { type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$1.ThyActionMenuItemDirective, selector: "[thyActionMenuItem]", inputs: ["thyDisabled", "thyType"] }, { type: i2$1.ThyActionMenuItemActiveDirective, selector: "[thyActionMenuItemActive]", inputs: ["thyActionMenuItemActive"] }, { type: i10.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i2$1.ThyActionMenuItemIconDirective, selector: "[thyActionMenuItemIcon]" }, { type: i2$1.ThyActionMenuItemNameDirective, selector: "[thyActionMenuItemName]" }] });
6986
+ TheToolbarDropdownComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheToolbarDropdownComponent, selector: "the-toolbar-dropdown", inputs: { itemMousedownHandle: "itemMousedownHandle" }, host: { listeners: { "mousedown": "toggleDropdown($event)", "document: mousedown": "handleDocumentMouseDown($event)" }, classAttribute: "the-toolbar-dropdown-container" }, viewQueries: [{ propertyName: "iconModeTemplate", first: true, predicate: ["iconModeTemplate"], descendants: true, static: true }, { propertyName: "textModeTemplate", first: true, predicate: ["textModeTemplate"], descendants: true, static: true }, { propertyName: "dropdownTemplate", first: true, predicate: ["dropdownTemplate"], descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<ng-template [ngTemplateOutlet]=\"template\"></ng-template>\n\n<ng-template #iconModeTemplate>\n <a thyIconNavLink class=\"icon-mode link-with-down\" [thyTooltip]=\"activeMenuItem?.name\" thyTooltipPlacement=\"top\">\n <thy-icon [thyIconName]=\"activeMenuItem?.icon\"></thy-icon>\n <thy-icon class=\"caret-down-icon font-size-sm text-desc\" thyIconName=\"caret-down\"></thy-icon>\n </a>\n</ng-template>\n\n<ng-template #textModeTemplate>\n <a thyIconNavLink class=\"text-mode\" [thyTooltip]=\"activeMenuItem?.name\" thyTooltipPlacement=\"top\">\n <span class=\"show-text\">{{ activeMenuItem?.name }}</span>\n <thy-icon class=\"text-caret-down-icon font-size-sm text-desc\" thyIconName=\"caret-down\"></thy-icon>\n </a>\n</ng-template>\n\n<ng-template #dropdownTemplate>\n <thy-action-menu class=\"dropdown\">\n <ng-container *ngFor=\"let menu of menus\">\n <a\n *ngIf=\"menu.key !== 'split'\"\n thyActionMenuItem\n href=\"javascript:;\"\n [thyActionMenuItemActive]=\"menu.key === activeMenuItem.key && !toolbarItem.dropdownFixedIcon\"\n (mousedown)=\"itemMousedown($event, menu)\"\n [ngStyle]=\"menu?.styles\"\n >\n <span *ngIf=\"menu.icon && mode === dropdownMode.icon\" thyActionMenuItemIcon>\n <thy-icon [thyIconName]=\"menu.icon\"></thy-icon>\n </span>\n <span *ngIf=\"menu.name\" thyActionMenuItemName>{{ menu.name }}</span>\n </a>\n <thy-action-menu-divider *ngIf=\"menu.key === 'split'\"></thy-action-menu-divider>\n </ng-container>\n </thy-action-menu>\n</ng-template>\n", components: [{ type: i3$1.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i3.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { type: i2$1.ThyActionMenuComponent, selector: "thy-action-menu", inputs: ["thyTheme", "thyWidth"] }, { type: i2$1.ThyActionMenuDividerComponent, selector: "thy-action-menu-divider", inputs: ["thyTitle", "thyType"] }], directives: [{ type: i10.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }, { type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }, { type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$1.ThyActionMenuItemDirective, selector: "[thyActionMenuItem]", inputs: ["thyDisabled", "thyType"] }, { type: i2$1.ThyActionMenuItemActiveDirective, selector: "[thyActionMenuItemActive]", inputs: ["thyActionMenuItemActive"] }, { type: i10.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i2$1.ThyActionMenuItemIconDirective, selector: "[thyActionMenuItemIcon]" }, { type: i2$1.ThyActionMenuItemNameDirective, selector: "[thyActionMenuItemName]" }] });
6892
6987
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheToolbarDropdownComponent, decorators: [{
6893
6988
  type: Component,
6894
6989
  args: [{
@@ -6898,15 +6993,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImpo
6898
6993
  class: 'the-toolbar-dropdown-container'
6899
6994
  }
6900
6995
  }]
6901
- }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1$1.ThyPopover }, { type: i0.ViewContainerRef }, { type: i2.Overlay }]; }, propDecorators: { toolbarItem: [{
6902
- type: Input
6903
- }], menus: [{
6904
- type: Input
6905
- }], mode: [{
6906
- type: Input
6907
- }], item: [{
6908
- type: Input
6909
- }], itemMousedownHandle: [{
6996
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1$1.ThyPopover }, { type: i0.ViewContainerRef }, { type: i2.Overlay }]; }, propDecorators: { itemMousedownHandle: [{
6910
6997
  type: Input
6911
6998
  }], iconModeTemplate: [{
6912
6999
  type: ViewChild,
@@ -6923,9 +7010,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImpo
6923
7010
  }], handleDocumentMouseDown: [{
6924
7011
  type: HostListener,
6925
7012
  args: ['document: mousedown', ['$event']]
6926
- }], disabledState: [{
6927
- type: HostBinding,
6928
- args: ['class.disabled']
6929
7013
  }] } });
6930
7014
 
6931
7015
  class TheCodeComponent extends TheBaseElementComponent {
@@ -6956,11 +7040,11 @@ class TheCodeComponent extends TheBaseElementComponent {
6956
7040
  lineWrapping: this.config.mode === TheMode.default ? false : true,
6957
7041
  cursorBlinkRate: 500
6958
7042
  };
6959
- this.actives = this.menus[0];
7043
+ this.activeLanguage = this.menus[0];
6960
7044
  this.resizeBounds = null;
6961
- this.onChangeLangulage = item => {
7045
+ this.onChangeLanguage = item => {
6962
7046
  this.options = Object.assign(Object.assign({}, this.options), { mode: item.key });
6963
- this.actives = item;
7047
+ this.activeLanguage = item;
6964
7048
  CodeEditor.setCodeAttribute(this.editor, this.element, { language: item.key });
6965
7049
  };
6966
7050
  }
@@ -7097,7 +7181,7 @@ class TheCodeComponent extends TheBaseElementComponent {
7097
7181
  }
7098
7182
  useMode() {
7099
7183
  this.options = Object.assign(Object.assign({}, this.options), { mode: this.element.language });
7100
- this.actives = this.menus.find(i => i.key === this.element.language);
7184
+ this.activeLanguage = this.menus.find(i => i.key === this.element.language);
7101
7185
  }
7102
7186
  useAutoWrap() {
7103
7187
  this.options = Object.assign(Object.assign({}, this.options), { lineWrapping: this.element.autoWrap || false });
@@ -7130,7 +7214,7 @@ class TheCodeComponent extends TheBaseElementComponent {
7130
7214
  }
7131
7215
  }
7132
7216
  TheCodeComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheCodeComponent, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }, { token: i1$4.ThyNotifyService }, { token: TheContextService }, { token: i0.NgZone }, { token: THE_MODE_TOKEN }], target: i0.ɵɵFactoryTarget.Component });
7133
- TheCodeComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheCodeComponent, selector: "div[theCode]", viewQueries: [{ propertyName: "codemirror", first: true, predicate: ["codemirror"], descendants: true, read: CodeMirrorComponent }], usesInheritance: true, ngImport: i0, template: "<div contenteditable=\"false\" class=\"the-code-block-operation\" *ngIf=\"isCollapsed && codemirror && !options.readOnly\">\n <thy-icon-nav>\n <the-toolbar-dropdown [menus]=\"menus\" [item]=\"actives\" [itemMousedownHandle]=\"onChangeLangulage\"> </the-toolbar-dropdown>\n <span class=\"auto-wrap d-flex align-items-center\">\n <span>\u81EA\u52A8\u6362\u884C</span>\n <thy-switch\n class=\"auto-wrap-btn d-flex\"\n [(ngModel)]=\"options.lineWrapping\"\n (ngModelChange)=\"onChangeWrap($event)\"\n thySize=\"sm\"\n ></thy-switch>\n </span>\n <a\n href=\"javascript:;\"\n thyIconNavLink\n thyIconNavLinkIcon=\"copy\"\n thyTooltip=\"\u590D\u5236\"\n thyTooltipPlacement=\"top\"\n (mousedown)=\"onCopy($event)\"\n ></a>\n <nav-split-line [mode]=\"ToolbarItemMode.vertical\"></nav-split-line>\n <a\n href=\"javascript:;\"\n thyIconNavLink\n thyIconNavLinkIcon=\"trash\"\n thyTooltip=\"\u5220\u9664\"\n class=\"remove-link\"\n thyTooltipPlacement=\"top\"\n (mousedown)=\"onDelete($event)\"\n ></a>\n </thy-icon-nav>\n</div>\n\n<slate-children [children]=\"children\" [context]=\"childrenContext\" [viewContext]=\"viewContext\"></slate-children>\n\n<!-- \u53EA\u8BFB\u6A21\u5F0F\u4E0BCodeMirror-sizer\u9AD8\u5EA6\u6BD4\u7F16\u8F91\u6A21\u5F0F\u4E0B\u591A2px\uFF0C\u8BBE\u7F6EthyMinHeight\u4E3A46px\u9632\u6B62\u62D6\u62FD\u5230\u6700\u5C0F\u9AD8\u5EA6\u65F6\u53EA\u8BFB\u6A21\u5F0F\u4E0B\u51FA\u73B0\u6EDA\u52A8\u6761 -->\n<div\n thyResizable\n [thyMinHeight]=\"46\"\n [thyBounds]=\"resizeBounds\"\n [style.height.px]=\"resizeHeight\"\n (thyResize)=\"onResize($event)\"\n (thyResizeEnd)=\"onEndResize()\"\n class=\"resize-code-container\"\n [ngClass]=\"{ focus: isCollapsed, readonly: options.readOnly, active: isHightLight && isCollapsed }\"\n>\n <ng-codemirror\n *ngIf=\"startRenderCodemirror\"\n #codemirror\n contenteditable=\"false\"\n class=\"ng-codemirror-wrapper\"\n [ngStyle]=\"{ maxHeight: maxHeight > 0 ? maxHeight + 'px' : 'auto' }\"\n [options]=\"options\"\n [ngModel]=\"code\"\n [delayRefreshTime]=\"300\"\n (ngModelChange)=\"codeChange($event)\"\n (focusChange)=\"focusChange($event)\"\n [autoMaxHeight]=\"maxHeight\"\n >\n </ng-codemirror>\n <thy-resize-handle thyDirection=\"bottom\" class=\"code-resize-icon\" *ngIf=\"isCollapsed && !options.readOnly\"></thy-resize-handle>\n</div>\n", components: [{ type: i3.ThyIconNavComponent, selector: "thy-icon-nav", inputs: ["thyType"] }, { type: TheToolbarDropdownComponent, selector: "the-toolbar-dropdown", inputs: ["toolbarItem", "menus", "mode", "item", "itemMousedownHandle"] }, { type: i5$2.ThySwitchComponent, selector: "thy-switch", inputs: ["thyType", "thySize", "thyDisabled"], outputs: ["thyChange"] }, { type: i3.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: NavSplitLineComponent, selector: "nav-split-line", inputs: ["mode"] }, { type: i1.SlateChildrenComponent, selector: "slate-children", inputs: ["children", "context", "viewContext"] }, { type: i8.CodeMirrorComponent, selector: "ng-codemirror, [ngCodeMirror]", inputs: ["autoMaxHeight", "delayRefreshTime", "options"], outputs: ["focusChange"] }, { type: i9.ThyResizeHandleComponent, selector: "thy-resize-handle, [thy-resize-handle]", inputs: ["thyDirection"], outputs: ["thyMouseDown"], exportAs: ["thyResizeHandle"] }], directives: [{ type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i4$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }, { type: i9.ThyResizableDirective, selector: "[thyResizable]", inputs: ["thyBounds", "thyMaxHeight", "thyMaxWidth", "thyMinHeight", "thyMinWidth", "thyGridColumnCount", "thyMaxColumn", "thyMinColumn", "thyLockAspectRatio", "thyPreview", "thyDisabled"], outputs: ["thyResize", "thyResizeEnd", "thyResizeStart"] }, { type: i10.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i10.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
7217
+ TheCodeComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheCodeComponent, selector: "div[theCode]", viewQueries: [{ propertyName: "codemirror", first: true, predicate: ["codemirror"], descendants: true, read: CodeMirrorComponent }], usesInheritance: true, ngImport: i0, template: "<div contenteditable=\"false\" class=\"the-code-block-operation\" *ngIf=\"isCollapsed && codemirror && !options.readOnly\">\n <thy-icon-nav>\n <the-toolbar-dropdown\n [menus]=\"menus\"\n [toolbarItem]=\"activeLanguage\"\n [dropdownItemKey]=\"activeLanguage.key\"\n [itemMousedownHandle]=\"onChangeLanguage\"\n >\n </the-toolbar-dropdown>\n <span class=\"auto-wrap d-flex align-items-center\">\n <span>\u81EA\u52A8\u6362\u884C</span>\n <thy-switch\n class=\"auto-wrap-btn d-flex\"\n [(ngModel)]=\"options.lineWrapping\"\n (ngModelChange)=\"onChangeWrap($event)\"\n thySize=\"sm\"\n ></thy-switch>\n </span>\n <a\n href=\"javascript:;\"\n thyIconNavLink\n thyIconNavLinkIcon=\"copy\"\n thyTooltip=\"\u590D\u5236\"\n thyTooltipPlacement=\"top\"\n (mousedown)=\"onCopy($event)\"\n ></a>\n <nav-split-line [mode]=\"ToolbarItemMode.vertical\"></nav-split-line>\n <a\n href=\"javascript:;\"\n thyIconNavLink\n thyIconNavLinkIcon=\"trash\"\n thyTooltip=\"\u5220\u9664\"\n class=\"remove-link\"\n thyTooltipPlacement=\"top\"\n (mousedown)=\"onDelete($event)\"\n ></a>\n </thy-icon-nav>\n</div>\n\n<slate-children [children]=\"children\" [context]=\"childrenContext\" [viewContext]=\"viewContext\"></slate-children>\n\n<!-- \u53EA\u8BFB\u6A21\u5F0F\u4E0BCodeMirror-sizer\u9AD8\u5EA6\u6BD4\u7F16\u8F91\u6A21\u5F0F\u4E0B\u591A2px\uFF0C\u8BBE\u7F6EthyMinHeight\u4E3A46px\u9632\u6B62\u62D6\u62FD\u5230\u6700\u5C0F\u9AD8\u5EA6\u65F6\u53EA\u8BFB\u6A21\u5F0F\u4E0B\u51FA\u73B0\u6EDA\u52A8\u6761 -->\n<div\n thyResizable\n [thyMinHeight]=\"46\"\n [thyBounds]=\"resizeBounds\"\n [style.height.px]=\"resizeHeight\"\n (thyResize)=\"onResize($event)\"\n (thyResizeEnd)=\"onEndResize()\"\n class=\"resize-code-container\"\n [ngClass]=\"{ focus: isCollapsed, readonly: options.readOnly, active: isHightLight && isCollapsed }\"\n>\n <ng-codemirror\n *ngIf=\"startRenderCodemirror\"\n #codemirror\n contenteditable=\"false\"\n class=\"ng-codemirror-wrapper\"\n [ngStyle]=\"{ maxHeight: maxHeight > 0 ? maxHeight + 'px' : 'auto' }\"\n [options]=\"options\"\n [ngModel]=\"code\"\n [delayRefreshTime]=\"300\"\n (ngModelChange)=\"codeChange($event)\"\n (focusChange)=\"focusChange($event)\"\n [autoMaxHeight]=\"maxHeight\"\n >\n </ng-codemirror>\n <thy-resize-handle thyDirection=\"bottom\" class=\"code-resize-icon\" *ngIf=\"isCollapsed && !options.readOnly\"></thy-resize-handle>\n</div>\n", components: [{ type: i3$1.ThyIconNavComponent, selector: "thy-icon-nav", inputs: ["thyType"] }, { type: TheToolbarDropdownComponent, selector: "the-toolbar-dropdown", inputs: ["itemMousedownHandle"] }, { type: i5$2.ThySwitchComponent, selector: "thy-switch", inputs: ["thyType", "thySize", "thyDisabled"], outputs: ["thyChange"] }, { type: i3$1.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: NavSplitLineComponent, selector: "nav-split-line", inputs: ["mode"] }, { type: i1.SlateChildrenComponent, selector: "slate-children", inputs: ["children", "context", "viewContext"] }, { type: i8.CodeMirrorComponent, selector: "ng-codemirror, [ngCodeMirror]", inputs: ["autoMaxHeight", "delayRefreshTime", "options"], outputs: ["focusChange"] }, { type: i9.ThyResizeHandleComponent, selector: "thy-resize-handle, [thy-resize-handle]", inputs: ["thyDirection"], outputs: ["thyMouseDown"], exportAs: ["thyResizeHandle"] }], directives: [{ type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }, { type: i9.ThyResizableDirective, selector: "[thyResizable]", inputs: ["thyBounds", "thyMaxHeight", "thyMaxWidth", "thyMinHeight", "thyMinWidth", "thyGridColumnCount", "thyMaxColumn", "thyMinColumn", "thyLockAspectRatio", "thyPreview", "thyDisabled"], outputs: ["thyResize", "thyResizeEnd", "thyResizeStart"] }, { type: i10.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i10.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
7134
7218
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheCodeComponent, decorators: [{
7135
7219
  type: Component,
7136
7220
  args: [{
@@ -7376,7 +7460,7 @@ class TheLinkEditComponent {
7376
7460
  }
7377
7461
  }
7378
7462
  TheLinkEditComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheLinkEditComponent, deps: [{ token: i1$1.ThyPopoverRef }], target: i0.ɵɵFactoryTarget.Component });
7379
- TheLinkEditComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheLinkEditComponent, selector: "the-link-edit", inputs: { tag: "tag", node: "node", link: "link", text: "text", originSelection: "originSelection" }, host: { listeners: { "document: mousedown": "handleDocumentMouseDown($event)" }, properties: { "class": "this.className" } }, ngImport: i0, template: "<form\n thyForm\n #linkForm=\"thyForm\"\n [thyFormValidatorConfig]=\"validatorConfig\"\n name=\"linkForm\"\n>\n <thy-form-group thyLabelText=\"\u6587\u672C\">\n <input\n thyInput\n placeholder=\"\u8BF7\u8F93\u5165\u6587\u672C\"\n required\n name=\"text\"\n [(ngModel)]=\"text\"\n thyAutofocus\n type=\"text\"\n />\n </thy-form-group>\n <thy-form-group thyLabelText=\"\u94FE\u63A5\">\n <input\n name=\"link\"\n thyInput\n placeholder=\"\u8BF7\u8F93\u5165\u94FE\u63A5\"\n required\n type=\"text\"\n #linkControl=\"ngModel\"\n [(ngModel)]=\"link\"\n />\n </thy-form-group>\n <thy-form-group-footer>\n <div class=\"btn-pair\">\n <button\n thyButton=\"link-secondary\"\n thySize=\"sm\"\n (click)=\"closePopover()\"\n >\u53D6\u6D88</button>\n <button\n thyButton=\"primary-square\"\n thySize=\"sm\"\n (thyFormSubmit)=\"applyLink(linkForm)\"\n >\u5E94\u7528</button>\n </div>\n </thy-form-group-footer>\n</form>\n", components: [{ type: i2$2.ThyFormGroupComponent, selector: "thy-form-group", inputs: ["thyLabelText", "thyLabelTextTranslateKey", "thyLabelRequired", "thyLabelPaddingTopClear", "thyFeedbackIcon", "thyTipsMode", "thyTips", "thyTipsTranslateKey", "thyRowFill"] }, { type: i2$2.ThyFormGroupFooterComponent, selector: "thy-form-group-footer", inputs: ["thyAlign"] }, { type: i1$5.ThyButtonComponent, selector: "thy-button,[thy-button],[thyButton]", inputs: ["thyButton", "thyType", "thyLoading", "thyLoadingText", "thySize", "thyIcon", "thySquare", "thyBlock"] }], directives: [{ type: i4$1.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i4$1.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i4$1.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i2$2.ThyFormDirective, selector: "[thyForm],[thy-form]", inputs: ["thyLayout", "thyEnterKeyMode", "thyFormValidatorConfig"], exportAs: ["thyForm"] }, { type: i5$3.ThyAutofocusDirective, selector: "input[thyAutofocus],textarea[thyAutofocus]", inputs: ["thyAutoSelect", "thyAutofocus"] }, { type: i4$1.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.ThyInputDirective, selector: "[thyInput]", inputs: ["thySize", "thyAutocomplete"] }, { type: i4$1.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { type: i4$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i4$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i2$2.ThyFormSubmitDirective, selector: "[thyFormSubmit],[thy-form-submit]", outputs: ["thyFormSubmit"] }] });
7463
+ TheLinkEditComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheLinkEditComponent, selector: "the-link-edit", inputs: { tag: "tag", node: "node", link: "link", text: "text", originSelection: "originSelection" }, host: { listeners: { "document: mousedown": "handleDocumentMouseDown($event)" }, properties: { "class": "this.className" } }, ngImport: i0, template: "<form\n thyForm\n #linkForm=\"thyForm\"\n [thyFormValidatorConfig]=\"validatorConfig\"\n name=\"linkForm\"\n>\n <thy-form-group thyLabelText=\"\u6587\u672C\">\n <input\n thyInput\n placeholder=\"\u8BF7\u8F93\u5165\u6587\u672C\"\n required\n name=\"text\"\n [(ngModel)]=\"text\"\n thyAutofocus\n type=\"text\"\n />\n </thy-form-group>\n <thy-form-group thyLabelText=\"\u94FE\u63A5\">\n <input\n name=\"link\"\n thyInput\n placeholder=\"\u8BF7\u8F93\u5165\u94FE\u63A5\"\n required\n type=\"text\"\n #linkControl=\"ngModel\"\n [(ngModel)]=\"link\"\n />\n </thy-form-group>\n <thy-form-group-footer>\n <div class=\"btn-pair\">\n <button\n thyButton=\"link-secondary\"\n thySize=\"sm\"\n (click)=\"closePopover()\"\n >\u53D6\u6D88</button>\n <button\n thyButton=\"primary-square\"\n thySize=\"sm\"\n (thyFormSubmit)=\"applyLink(linkForm)\"\n >\u5E94\u7528</button>\n </div>\n </thy-form-group-footer>\n</form>\n", components: [{ type: i2$2.ThyFormGroupComponent, selector: "thy-form-group", inputs: ["thyLabelText", "thyLabelTextTranslateKey", "thyLabelRequired", "thyLabelPaddingTopClear", "thyFeedbackIcon", "thyTipsMode", "thyTips", "thyTipsTranslateKey", "thyRowFill"] }, { type: i2$2.ThyFormGroupFooterComponent, selector: "thy-form-group-footer", inputs: ["thyAlign"] }, { type: i1$5.ThyButtonComponent, selector: "thy-button,[thy-button],[thyButton]", inputs: ["thyButton", "thyType", "thyLoading", "thyLoadingText", "thySize", "thyIcon", "thySquare", "thyBlock"] }], directives: [{ type: i4.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { type: i4.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { type: i4.NgForm, selector: "form:not([ngNoForm]):not([formGroup]),ng-form,[ngForm]", inputs: ["ngFormOptions"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { type: i2$2.ThyFormDirective, selector: "[thyForm],[thy-form]", inputs: ["thyLayout", "thyEnterKeyMode", "thyFormValidatorConfig"], exportAs: ["thyForm"] }, { type: i5$3.ThyAutofocusDirective, selector: "input[thyAutofocus],textarea[thyAutofocus]", inputs: ["thyAutoSelect", "thyAutofocus"] }, { type: i4.DefaultValueAccessor, selector: "input:not([type=checkbox])[formControlName],textarea[formControlName],input:not([type=checkbox])[formControl],textarea[formControl],input:not([type=checkbox])[ngModel],textarea[ngModel],[ngDefaultControl]" }, { type: i5.ThyInputDirective, selector: "[thyInput]", inputs: ["thySize", "thyAutocomplete"] }, { type: i4.RequiredValidator, selector: ":not([type=checkbox])[required][formControlName],:not([type=checkbox])[required][formControl],:not([type=checkbox])[required][ngModel]", inputs: ["required"] }, { type: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }, { type: i2$2.ThyFormSubmitDirective, selector: "[thyFormSubmit],[thy-form-submit]", outputs: ["thyFormSubmit"] }] });
7380
7464
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheLinkEditComponent, decorators: [{
7381
7465
  type: Component,
7382
7466
  args: [{
@@ -7600,7 +7684,10 @@ const createLinkPlugin = createPluginFactory({
7600
7684
  execute: editor => LinkEditor.insertLink(editor),
7601
7685
  active: editor => LinkEditor.isLinkActive(editor)
7602
7686
  }
7603
- ]
7687
+ ],
7688
+ options: {
7689
+ disabledOperateTypes: [ElementKinds.image, ...DISABLED_OPERATE_TYPES]
7690
+ }
7604
7691
  });
7605
7692
 
7606
7693
  /**
@@ -8410,7 +8497,7 @@ TheTableOptionsComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0
8410
8497
  </a>
8411
8498
  </ng-container>
8412
8499
  </thy-action-menu>
8413
- `, isInline: true, components: [{ type: i2$1.ThyActionMenuComponent, selector: "thy-action-menu", inputs: ["thyTheme", "thyWidth"] }, { type: i4.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }], directives: [{ type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2$1.ThyActionMenuItemDirective, selector: "[thyActionMenuItem]", inputs: ["thyDisabled", "thyType"] }, { type: i2$1.ThyActionMenuItemNameDirective, selector: "[thyActionMenuItemName]" }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$1.ThyActionMenuItemExtendIconDirective, selector: "[thyActionMenuItemExtendIcon]" }] });
8500
+ `, isInline: true, components: [{ type: i2$1.ThyActionMenuComponent, selector: "thy-action-menu", inputs: ["thyTheme", "thyWidth"] }, { type: i3.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }], directives: [{ type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2$1.ThyActionMenuItemDirective, selector: "[thyActionMenuItem]", inputs: ["thyDisabled", "thyType"] }, { type: i2$1.ThyActionMenuItemNameDirective, selector: "[thyActionMenuItemName]" }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$1.ThyActionMenuItemExtendIconDirective, selector: "[thyActionMenuItemExtendIcon]" }] });
8414
8501
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheTableOptionsComponent, decorators: [{
8415
8502
  type: Component,
8416
8503
  args: [{
@@ -8564,7 +8651,7 @@ class TheTableToolbarComponent {
8564
8651
  }
8565
8652
  }
8566
8653
  TheTableToolbarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheTableToolbarComponent, deps: [{ token: i0.NgZone }, { token: TheColorSelectService }, { token: i1$1.ThyPopover }, { token: i1$1.ThyPopoverRef }], target: i0.ɵɵFactoryTarget.Component });
8567
- TheTableToolbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheTableToolbarComponent, selector: "the-table-toolbar", inputs: { tableStore: "tableStore", isActiveSelect: "isActiveSelect" }, ngImport: i0, template: "<thy-icon-nav>\n <ng-container *ngFor=\"let item of cellMenuList\">\n <a href=\"javascript:;\" thyIconNavLink *ngIf=\"!item.invisibility\" [thyTooltip]=\"item.name\" (mousedown)=\"item.actionHandle()\">\n <thy-icon [thyIconName]=\"item.icon\"></thy-icon>\n </a>\n </ng-container>\n <nav-split-line *ngIf=\"!isActiveSelect && isShowSplitLine\"></nav-split-line>\n <a href=\"javascript:;\" thyIconNavLink thyTooltip=\"\u5355\u5143\u683C\u80CC\u666F\" (mousedown)=\"openSelectColor($event)\">\n <thy-icon thyIconName=\"background-tt\" thyIconType=\"twotone\" [thyTwotoneColor]=\"selectedColor\"></thy-icon>\n </a>\n <nav-split-line *ngIf=\"tableStore.isSelectedTable\"></nav-split-line>\n <button\n thyButton=\"default\"\n *ngIf=\"tableStore.isSelectedTable\"\n class=\"mr-2\"\n thySize=\"md\"\n class=\"table-options\"\n (mousedown)=\"openTableOptionMenu($event)\"\n >\n <span>\u8868\u683C\u9009\u9879</span>\n <thy-icon thyIconName=\"caret-down\"></thy-icon>\n </button>\n <nav-split-line *ngIf=\"deleteIcon\"></nav-split-line>\n <a\n *ngIf=\"deleteIcon\"\n href=\"javascript:;\"\n thyIconNavLink\n [thyTooltip]=\"iconName\"\n class=\"danger\"\n [thyIconNavLinkIcon]=\"deleteIcon\"\n (mousedown)=\"onDelete($event)\"\n (mouseenter)=\"onEnterDelete($event)\"\n (mouseleave)=\"onLeaveDelete($event)\"\n ></a>\n</thy-icon-nav>\n", components: [{ type: i3.ThyIconNavComponent, selector: "thy-icon-nav", inputs: ["thyType"] }, { type: i3.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i4.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { type: NavSplitLineComponent, selector: "nav-split-line", inputs: ["mode"] }, { type: i1$5.ThyButtonComponent, selector: "thy-button,[thy-button],[thyButton]", inputs: ["thyButton", "thyType", "thyLoading", "thyLoadingText", "thySize", "thyIcon", "thySquare", "thyBlock"] }], directives: [{ type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }] });
8654
+ TheTableToolbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheTableToolbarComponent, selector: "the-table-toolbar", inputs: { tableStore: "tableStore", isActiveSelect: "isActiveSelect" }, ngImport: i0, template: "<thy-icon-nav>\n <ng-container *ngFor=\"let item of cellMenuList\">\n <a href=\"javascript:;\" thyIconNavLink *ngIf=\"!item.invisibility\" [thyTooltip]=\"item.name\" (mousedown)=\"item.actionHandle()\">\n <thy-icon [thyIconName]=\"item.icon\"></thy-icon>\n </a>\n </ng-container>\n <nav-split-line *ngIf=\"!isActiveSelect && isShowSplitLine\"></nav-split-line>\n <a href=\"javascript:;\" thyIconNavLink thyTooltip=\"\u5355\u5143\u683C\u80CC\u666F\" (mousedown)=\"openSelectColor($event)\">\n <thy-icon thyIconName=\"background-tt\" thyIconType=\"twotone\" [thyTwotoneColor]=\"selectedColor\"></thy-icon>\n </a>\n <nav-split-line *ngIf=\"tableStore.isSelectedTable\"></nav-split-line>\n <button\n thyButton=\"default\"\n *ngIf=\"tableStore.isSelectedTable\"\n class=\"mr-2\"\n thySize=\"md\"\n class=\"table-options\"\n (mousedown)=\"openTableOptionMenu($event)\"\n >\n <span>\u8868\u683C\u9009\u9879</span>\n <thy-icon thyIconName=\"caret-down\"></thy-icon>\n </button>\n <nav-split-line *ngIf=\"deleteIcon\"></nav-split-line>\n <a\n *ngIf=\"deleteIcon\"\n href=\"javascript:;\"\n thyIconNavLink\n [thyTooltip]=\"iconName\"\n class=\"danger\"\n [thyIconNavLinkIcon]=\"deleteIcon\"\n (mousedown)=\"onDelete($event)\"\n (mouseenter)=\"onEnterDelete($event)\"\n (mouseleave)=\"onLeaveDelete($event)\"\n ></a>\n</thy-icon-nav>\n", components: [{ type: i3$1.ThyIconNavComponent, selector: "thy-icon-nav", inputs: ["thyType"] }, { type: i3$1.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i3.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { type: NavSplitLineComponent, selector: "nav-split-line", inputs: ["mode"] }, { type: i1$5.ThyButtonComponent, selector: "thy-button,[thy-button],[thyButton]", inputs: ["thyButton", "thyType", "thyLoading", "thyLoadingText", "thySize", "thyIcon", "thySquare", "thyBlock"] }], directives: [{ type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }] });
8568
8655
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheTableToolbarComponent, decorators: [{
8569
8656
  type: Component,
8570
8657
  args: [{
@@ -8627,7 +8714,7 @@ class TheContextMenuComponent {
8627
8714
  ngOnInit() { }
8628
8715
  }
8629
8716
  TheContextMenuComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheContextMenuComponent, deps: [{ token: i0.ElementRef }, { token: i1$1.ThyPopoverRef }], target: i0.ɵɵFactoryTarget.Component });
8630
- TheContextMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheContextMenuComponent, selector: "the-contextmenu", inputs: { menuEntities: "menuEntities", actionHandle: "actionHandle", activeHandle: "activeHandle", deactiveHandle: "deactiveHandle" }, host: { listeners: { "document: mousedown": "handleDocumentMouseDown($event)", "mousedown": "handleMouseDown($event)" }, properties: { "class.the-overlay-menu-wrap": "this.wrap" } }, ngImport: i0, template: "<thy-action-menu>\n <ng-container *ngFor=\"let menuItem of menuEntities\">\n <a\n thyActionMenuItem\n href=\"javascript:;\"\n *ngIf=\"!menuItem.invisibility\"\n (mousedown)=\"itemMousedown($event, menuItem)\"\n (mouseenter)=\"itemMouseenter($event, menuItem)\"\n (mouseleave)=\"itemMouseleave($event, menuItem)\"\n >\n <span thyActionMenuItemIcon>\n <thy-icon\n *ngIf=\"menuItem.backgroundColor; else elseIcon\"\n [thyIconName]=\"menuItem.icon\"\n thyIconType=\"twotone\"\n [thyTwotoneColor]=\"menuItem.backgroundColor\"\n ></thy-icon>\n <ng-template #elseIcon>\n <thy-icon [thyIconName]=\"menuItem.icon\"></thy-icon>\n </ng-template>\n </span>\n <span thyActionMenuItemName>{{ menuItem.name }}</span>\n <span *ngIf=\"menuItem.extendIcon\" thyActionMenuItemExtendIcon>\n <thy-icon thyIconName=\"{{ menuItem.extendIcon }}\"></thy-icon>\n </span>\n </a>\n <thy-action-menu-divider *ngIf=\"menuItem.divider\"></thy-action-menu-divider>\n </ng-container>\n</thy-action-menu>\n", components: [{ type: i2$1.ThyActionMenuComponent, selector: "thy-action-menu", inputs: ["thyTheme", "thyWidth"] }, { type: i4.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { type: i2$1.ThyActionMenuDividerComponent, selector: "thy-action-menu-divider", inputs: ["thyTitle", "thyType"] }], directives: [{ type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$1.ThyActionMenuItemDirective, selector: "[thyActionMenuItem]", inputs: ["thyDisabled", "thyType"] }, { type: i2$1.ThyActionMenuItemIconDirective, selector: "[thyActionMenuItemIcon]" }, { type: i2$1.ThyActionMenuItemNameDirective, selector: "[thyActionMenuItemName]" }, { type: i2$1.ThyActionMenuItemExtendIconDirective, selector: "[thyActionMenuItemExtendIcon]" }] });
8717
+ TheContextMenuComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheContextMenuComponent, selector: "the-contextmenu", inputs: { menuEntities: "menuEntities", actionHandle: "actionHandle", activeHandle: "activeHandle", deactiveHandle: "deactiveHandle" }, host: { listeners: { "document: mousedown": "handleDocumentMouseDown($event)", "mousedown": "handleMouseDown($event)" }, properties: { "class.the-overlay-menu-wrap": "this.wrap" } }, ngImport: i0, template: "<thy-action-menu>\n <ng-container *ngFor=\"let menuItem of menuEntities\">\n <a\n thyActionMenuItem\n href=\"javascript:;\"\n *ngIf=\"!menuItem.invisibility\"\n (mousedown)=\"itemMousedown($event, menuItem)\"\n (mouseenter)=\"itemMouseenter($event, menuItem)\"\n (mouseleave)=\"itemMouseleave($event, menuItem)\"\n >\n <span thyActionMenuItemIcon>\n <thy-icon\n *ngIf=\"menuItem.backgroundColor; else elseIcon\"\n [thyIconName]=\"menuItem.icon\"\n thyIconType=\"twotone\"\n [thyTwotoneColor]=\"menuItem.backgroundColor\"\n ></thy-icon>\n <ng-template #elseIcon>\n <thy-icon [thyIconName]=\"menuItem.icon\"></thy-icon>\n </ng-template>\n </span>\n <span thyActionMenuItemName>{{ menuItem.name }}</span>\n <span *ngIf=\"menuItem.extendIcon\" thyActionMenuItemExtendIcon>\n <thy-icon thyIconName=\"{{ menuItem.extendIcon }}\"></thy-icon>\n </span>\n </a>\n <thy-action-menu-divider *ngIf=\"menuItem.divider\"></thy-action-menu-divider>\n </ng-container>\n</thy-action-menu>\n", components: [{ type: i2$1.ThyActionMenuComponent, selector: "thy-action-menu", inputs: ["thyTheme", "thyWidth"] }, { type: i3.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { type: i2$1.ThyActionMenuDividerComponent, selector: "thy-action-menu-divider", inputs: ["thyTitle", "thyType"] }], directives: [{ type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$1.ThyActionMenuItemDirective, selector: "[thyActionMenuItem]", inputs: ["thyDisabled", "thyType"] }, { type: i2$1.ThyActionMenuItemIconDirective, selector: "[thyActionMenuItemIcon]" }, { type: i2$1.ThyActionMenuItemNameDirective, selector: "[thyActionMenuItemName]" }, { type: i2$1.ThyActionMenuItemExtendIconDirective, selector: "[thyActionMenuItemExtendIcon]" }] });
8631
8718
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheContextMenuComponent, decorators: [{
8632
8719
  type: Component,
8633
8720
  args: [{
@@ -9339,6 +9426,9 @@ class TheTableComponent extends TheBaseElementComponent {
9339
9426
  image.onload = () => {
9340
9427
  resolve(true);
9341
9428
  };
9429
+ image.onerror = () => {
9430
+ resolve(true);
9431
+ };
9342
9432
  image.src = item.getAttribute('src');
9343
9433
  });
9344
9434
  imageResolves.push(imageLoad);
@@ -10721,27 +10811,21 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImpo
10721
10811
  args: ['document: mousedown', ['$event']]
10722
10812
  }] } });
10723
10813
 
10724
- class TheTableToolbarItemComponent extends TheToolbarBaseItemComponent {
10814
+ class TheTableToolbarItemComponent extends TheBaseToolbarItem {
10725
10815
  constructor(thyPopover, overlay) {
10726
10816
  super();
10727
10817
  this.thyPopover = thyPopover;
10728
10818
  this.overlay = overlay;
10729
- this.active = false;
10730
10819
  }
10731
10820
  get isOpenTableSelect() {
10732
10821
  return this.tableSelectRef && this.tableSelectRef.componentInstance;
10733
10822
  }
10734
- statusChange(editor) {
10735
- var _a;
10736
- this.active = (_a = this.item) === null || _a === void 0 ? void 0 : _a.active(editor);
10737
- }
10738
10823
  execute(event) {
10739
10824
  var _a;
10740
10825
  super.execute(event);
10741
10826
  if ((_a = this.editor) === null || _a === void 0 ? void 0 : _a.disabled) {
10742
10827
  return;
10743
10828
  }
10744
- const type = this.item.key;
10745
10829
  this.toggleTableSelect(event);
10746
10830
  }
10747
10831
  toggleTableSelect(event, optionsParam) {
@@ -10767,19 +10851,19 @@ class TheTableToolbarItemComponent extends TheToolbarBaseItemComponent {
10767
10851
  }
10768
10852
  }
10769
10853
  TheTableToolbarItemComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheTableToolbarItemComponent, deps: [{ token: i1$6.ThyPopover }, { token: i2.Overlay }], target: i0.ɵɵFactoryTarget.Component });
10770
- TheTableToolbarItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheTableToolbarItemComponent, selector: "the-table-toolbar-item", inputs: { item: "item", editor: "editor" }, host: { classAttribute: "the-toolbar-dropdown-container" }, usesInheritance: true, ngImport: i0, template: `
10854
+ TheTableToolbarItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheTableToolbarItemComponent, selector: "the-table-toolbar-item", host: { classAttribute: "the-toolbar-dropdown-container" }, usesInheritance: true, ngImport: i0, template: `
10771
10855
  <a
10772
10856
  thyIconNavLink
10773
10857
  class="link-with-down"
10774
- [thyTooltip]="item?.name"
10858
+ [thyTooltip]="toolbarItem?.name"
10775
10859
  thyTooltipPlacement="top"
10776
10860
  [thyIconNavLinkActive]="active"
10777
10861
  (mousedown)="execute($event)"
10778
10862
  >
10779
- <thy-icon [thyIconName]="item.icon"></thy-icon>
10863
+ <thy-icon [thyIconName]="toolbarItem.icon"></thy-icon>
10780
10864
  <thy-icon class="link-down-icon font-size-sm text-desc table-down-icon" thyIconName="caret-down"> </thy-icon>
10781
10865
  </a>
10782
- `, isInline: true, components: [{ type: i3.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i4.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }], directives: [{ type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }] });
10866
+ `, isInline: true, components: [{ type: i3$1.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i3.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }], directives: [{ type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }] });
10783
10867
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheTableToolbarItemComponent, decorators: [{
10784
10868
  type: Component,
10785
10869
  args: [{
@@ -10788,12 +10872,12 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImpo
10788
10872
  <a
10789
10873
  thyIconNavLink
10790
10874
  class="link-with-down"
10791
- [thyTooltip]="item?.name"
10875
+ [thyTooltip]="toolbarItem?.name"
10792
10876
  thyTooltipPlacement="top"
10793
10877
  [thyIconNavLinkActive]="active"
10794
10878
  (mousedown)="execute($event)"
10795
10879
  >
10796
- <thy-icon [thyIconName]="item.icon"></thy-icon>
10880
+ <thy-icon [thyIconName]="toolbarItem.icon"></thy-icon>
10797
10881
  <thy-icon class="link-down-icon font-size-sm text-desc table-down-icon" thyIconName="caret-down"> </thy-icon>
10798
10882
  </a>
10799
10883
  `,
@@ -10801,11 +10885,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImpo
10801
10885
  class: 'the-toolbar-dropdown-container'
10802
10886
  }
10803
10887
  }]
10804
- }], ctorParameters: function () { return [{ type: i1$6.ThyPopover }, { type: i2.Overlay }]; }, propDecorators: { item: [{
10805
- type: Input
10806
- }], editor: [{
10807
- type: Input
10808
- }] } });
10888
+ }], ctorParameters: function () { return [{ type: i1$6.ThyPopover }, { type: i2.Overlay }]; } });
10809
10889
 
10810
10890
  const withTable = (editor) => {
10811
10891
  const { deleteBackward, deleteForward, onKeydown, setFragmentData, insertData, normalizeNode, isBlockCard, renderElement, deleteCutData, isContainer, onChange } = editor;
@@ -11250,7 +11330,7 @@ const withDeserializeHMTL = (editor) => {
11250
11330
  return;
11251
11331
  }
11252
11332
  // 过滤 text 节点的 color/background-color 属性
11253
- fragment.forEach(node => deleteColorAndBackgroundColorOfText(node));
11333
+ fragment.forEach(node => filterTextFormat(node));
11254
11334
  Transforms.insertFragment(editor, fragment);
11255
11335
  return;
11256
11336
  }
@@ -11263,73 +11343,63 @@ const createDeserializeHMTLPlugin = createPluginFactory({
11263
11343
  withOverrides: withDeserializeHMTL
11264
11344
  });
11265
11345
 
11266
- class TheToolbarItemComponent extends TheToolbarBaseItemComponent {
11346
+ class TheToolbarItemComponent extends TheBaseToolbarItem {
11267
11347
  constructor(ngZone, cfr) {
11268
11348
  super();
11269
11349
  this.ngZone = ngZone;
11270
11350
  this.cfr = cfr;
11271
11351
  this.itemMode = ToolbarItemMode.horizontal;
11272
11352
  this.ToolbarItemMode = ToolbarItemMode;
11273
- this.active = false;
11274
- this.disabled = false;
11275
11353
  }
11276
11354
  toggleDropdown(event) {
11277
11355
  super.execute(event);
11278
11356
  }
11279
- get disabledState() {
11280
- return this.disabled;
11281
- }
11282
11357
  ngOnInit() {
11283
11358
  var _a, _b;
11284
- if (((_a = this.item) === null || _a === void 0 ? void 0 : _a.quickItemComponent) && isComponentType((_b = this.item) === null || _b === void 0 ? void 0 : _b.quickItemComponent)) {
11359
+ if (((_a = this.toolbarItem) === null || _a === void 0 ? void 0 : _a.quickItemComponent) && isComponentType((_b = this.toolbarItem) === null || _b === void 0 ? void 0 : _b.quickItemComponent)) {
11285
11360
  this.renderToolbarItem();
11286
11361
  }
11287
11362
  }
11288
- statusChange(editor) {
11289
- var _a, _b, _c, _d;
11290
- this.disabled = ((_a = this.item) === null || _a === void 0 ? void 0 : _a.disable) ? (_b = this.item) === null || _b === void 0 ? void 0 : _b.disable(editor) : false;
11291
- this.active = ((_c = this.item) === null || _c === void 0 ? void 0 : _c.active) ? (_d = this.item) === null || _d === void 0 ? void 0 : _d.active(editor) : false;
11292
- }
11293
11363
  execute(event) {
11294
11364
  var _a, _b, _c;
11295
11365
  super.execute(event);
11296
- if (((_a = this.editor) === null || _a === void 0 ? void 0 : _a.disabled) || this.disabled || !((_b = this.item) === null || _b === void 0 ? void 0 : _b.execute)) {
11366
+ if (((_a = this.editor) === null || _a === void 0 ? void 0 : _a.disabled) || this.disabled || !((_b = this.toolbarItem) === null || _b === void 0 ? void 0 : _b.execute)) {
11297
11367
  return;
11298
11368
  }
11299
- (_c = this.item) === null || _c === void 0 ? void 0 : _c.execute(this.editor);
11369
+ (_c = this.toolbarItem) === null || _c === void 0 ? void 0 : _c.execute(this.editor);
11300
11370
  }
11301
11371
  renderToolbarItem() {
11302
11372
  this.ngZone.run(() => {
11303
- const toolbarItemFactory = this.cfr.resolveComponentFactory(this.item.quickItemComponent);
11304
- const tollbarItemRef = this.toolbarContainer.createComponent(toolbarItemFactory);
11305
- tollbarItemRef.instance.editor = this.editor;
11306
- tollbarItemRef.instance.item = this.item;
11307
- tollbarItemRef.instance.itemMode = ToolbarItemMode.vertical;
11373
+ const toolbarItemFactory = this.cfr.resolveComponentFactory(this.toolbarItem.quickItemComponent);
11374
+ const toolbarItemRef = this.toolbarContainer.createComponent(toolbarItemFactory);
11375
+ toolbarItemRef.instance.editor = this.editor;
11376
+ toolbarItemRef.instance.item = this.toolbarItem;
11377
+ toolbarItemRef.instance.itemMode = ToolbarItemMode.vertical;
11308
11378
  });
11309
11379
  }
11310
11380
  }
11311
11381
  TheToolbarItemComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheToolbarItemComponent, deps: [{ token: i0.NgZone }, { token: i0.ComponentFactoryResolver }], target: i0.ɵɵFactoryTarget.Component });
11312
- TheToolbarItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheToolbarItemComponent, selector: "the-toolbar-item", inputs: { editor: "editor", item: "item", itemMode: "itemMode" }, host: { listeners: { "mousedown": "toggleDropdown($event)" }, properties: { "class.disabled": "this.disabledState" }, classAttribute: "the-toolbar-item" }, viewQueries: [{ propertyName: "toolbarContainer", first: true, predicate: ["toolbarContainer"], descendants: true, read: ViewContainerRef, static: true }], usesInheritance: true, ngImport: i0, template: `
11382
+ TheToolbarItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheToolbarItemComponent, selector: "the-toolbar-item", inputs: { itemMode: "itemMode" }, host: { listeners: { "mousedown": "toggleDropdown($event)" }, classAttribute: "the-toolbar-item" }, viewQueries: [{ propertyName: "toolbarContainer", first: true, predicate: ["toolbarContainer"], descendants: true, read: ViewContainerRef, static: true }], usesInheritance: true, ngImport: i0, template: `
11313
11383
  <ng-container *ngIf="itemMode === ToolbarItemMode.horizontal; else selectionItem">
11314
11384
  <a
11315
11385
  thyIconNavLink
11316
- [thyIconNavLinkIcon]="item.icon"
11386
+ [thyIconNavLinkIcon]="toolbarItem.icon"
11317
11387
  [thyTooltip]="tooltip"
11318
- [thyTooltipTemplateContext]="{ name: item.name, shortcutKey: item.shortcutKey }"
11388
+ [thyTooltipTemplateContext]="{ name: toolbarItem.name, shortcutKey: toolbarItem.shortcutKey }"
11319
11389
  thyTooltipPlacement="top"
11320
11390
  [thyIconNavLinkActive]="active"
11321
11391
  (mousedown)="execute($event)"
11322
11392
  ></a>
11323
11393
  </ng-container>
11324
11394
  <ng-template #selectionItem>
11325
- <ng-container *ngIf="!item?.quickItemComponent">
11326
- <thy-icon [thyIconName]="item?.icon" [thyIconRotate]="0" class="quick-toolbar-icon"></thy-icon>
11327
- <span class="quick-toolbar-name">{{ item?.name }}</span>
11395
+ <ng-container *ngIf="!toolbarItem?.quickItemComponent">
11396
+ <thy-icon [thyIconName]="toolbarItem?.icon" [thyIconRotate]="0" class="quick-toolbar-icon"></thy-icon>
11397
+ <span class="quick-toolbar-name">{{ toolbarItem?.name }}</span>
11328
11398
  </ng-container>
11329
11399
  </ng-template>
11330
11400
  <ng-template #tooltip let-data> {{ data.name }} {{ data.shortcutKey }} </ng-template>
11331
11401
  <ng-container #toolbarContainer></ng-container>
11332
- `, isInline: true, components: [{ type: i3.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i4.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }], directives: [{ type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }] });
11402
+ `, isInline: true, components: [{ type: i3$1.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i3.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }], directives: [{ type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }] });
11333
11403
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheToolbarItemComponent, decorators: [{
11334
11404
  type: Component,
11335
11405
  args: [{
@@ -11338,18 +11408,18 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImpo
11338
11408
  <ng-container *ngIf="itemMode === ToolbarItemMode.horizontal; else selectionItem">
11339
11409
  <a
11340
11410
  thyIconNavLink
11341
- [thyIconNavLinkIcon]="item.icon"
11411
+ [thyIconNavLinkIcon]="toolbarItem.icon"
11342
11412
  [thyTooltip]="tooltip"
11343
- [thyTooltipTemplateContext]="{ name: item.name, shortcutKey: item.shortcutKey }"
11413
+ [thyTooltipTemplateContext]="{ name: toolbarItem.name, shortcutKey: toolbarItem.shortcutKey }"
11344
11414
  thyTooltipPlacement="top"
11345
11415
  [thyIconNavLinkActive]="active"
11346
11416
  (mousedown)="execute($event)"
11347
11417
  ></a>
11348
11418
  </ng-container>
11349
11419
  <ng-template #selectionItem>
11350
- <ng-container *ngIf="!item?.quickItemComponent">
11351
- <thy-icon [thyIconName]="item?.icon" [thyIconRotate]="0" class="quick-toolbar-icon"></thy-icon>
11352
- <span class="quick-toolbar-name">{{ item?.name }}</span>
11420
+ <ng-container *ngIf="!toolbarItem?.quickItemComponent">
11421
+ <thy-icon [thyIconName]="toolbarItem?.icon" [thyIconRotate]="0" class="quick-toolbar-icon"></thy-icon>
11422
+ <span class="quick-toolbar-name">{{ toolbarItem?.name }}</span>
11353
11423
  </ng-container>
11354
11424
  </ng-template>
11355
11425
  <ng-template #tooltip let-data> {{ data.name }} {{ data.shortcutKey }} </ng-template>
@@ -11359,11 +11429,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImpo
11359
11429
  class: 'the-toolbar-item'
11360
11430
  }
11361
11431
  }]
11362
- }], ctorParameters: function () { return [{ type: i0.NgZone }, { type: i0.ComponentFactoryResolver }]; }, propDecorators: { editor: [{
11363
- type: Input
11364
- }], item: [{
11365
- type: Input
11366
- }], itemMode: [{
11432
+ }], ctorParameters: function () { return [{ type: i0.NgZone }, { type: i0.ComponentFactoryResolver }]; }, propDecorators: { itemMode: [{
11367
11433
  type: Input
11368
11434
  }], toolbarContainer: [{
11369
11435
  type: ViewChild,
@@ -11371,9 +11437,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImpo
11371
11437
  }], toggleDropdown: [{
11372
11438
  type: HostListener,
11373
11439
  args: ['mousedown', ['$event']]
11374
- }], disabledState: [{
11375
- type: HostBinding,
11376
- args: ['class.disabled']
11377
11440
  }] } });
11378
11441
 
11379
11442
  class TheQuickToolbarComponent extends mixinUnsubscribe(MixinBase) {
@@ -11424,7 +11487,7 @@ class TheQuickToolbarComponent extends mixinUnsubscribe(MixinBase) {
11424
11487
  }
11425
11488
  }
11426
11489
  TheQuickToolbarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheQuickToolbarComponent, deps: [{ token: i0.ElementRef }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
11427
- TheQuickToolbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheQuickToolbarComponent, selector: "the-quick-toolbar", inputs: { editor: "editor", quickToolbarItems: "quickToolbarItems" }, host: { listeners: { "document: mousedown": "handleMouseDown($event)", "document: keydown.enter": "handleEnter()", "document: keydown.escape": "handleEsc()" } }, usesInheritance: true, ngImport: i0, template: "<thy-selection-list\n class=\"the-quick-toolbar\"\n [thyBindKeyEventContainer]=\"editorElement\"\n (thySelectionChange)=\"selectionChange($event)\"\n [thyMultiple]=\"false\"\n>\n <ng-container *ngFor=\"let item of quickToolbarItems\">\n <ng-container *ngIf=\"item.key !== ToolbarActionTypes.split; else splitLine\">\n <thy-list-option [thyValue]=\"item?.key\" (mousedown)=\"stopPropagation($event)\">\n <the-toolbar-item [editor]=\"editor\" [item]=\"item\" [itemMode]=\"ToolbarItemMode.vertical\"></the-toolbar-item>\n </thy-list-option>\n </ng-container>\n </ng-container>\n</thy-selection-list>\n\n<ng-template #splitLine>\n <nav-split-line [mode]=\"ToolbarItemMode.horizontal\"></nav-split-line>\n</ng-template>\n", components: [{ type: i1$7.ThySelectionListComponent, selector: "thy-selection-list,[thy-selection-list]", inputs: ["thyMultiple", "thyBindKeyEventContainer", "thyScrollContainer", "thyBeforeKeydown", "thyUniqueKey", "thyCompareWith", "thyLayout", "thyAutoActiveFirstItem", "thySize", "thySpaceKeyEnabled"], outputs: ["thySelectionChange"] }, { type: i5$3.ThyListOptionComponent, selector: "thy-list-option,[thy-list-option]", inputs: ["id", "thyValue", "thyDisabled"] }, { type: TheToolbarItemComponent, selector: "the-toolbar-item", inputs: ["editor", "item", "itemMode"] }, { type: NavSplitLineComponent, selector: "nav-split-line", inputs: ["mode"] }], directives: [{ type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
11490
+ TheQuickToolbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheQuickToolbarComponent, selector: "the-quick-toolbar", inputs: { editor: "editor", quickToolbarItems: "quickToolbarItems" }, host: { listeners: { "document: mousedown": "handleMouseDown($event)", "document: keydown.enter": "handleEnter()", "document: keydown.escape": "handleEsc()" } }, usesInheritance: true, ngImport: i0, template: "<thy-selection-list\n class=\"the-quick-toolbar\"\n [thyBindKeyEventContainer]=\"editorElement\"\n (thySelectionChange)=\"selectionChange($event)\"\n [thyMultiple]=\"false\"\n>\n <ng-container *ngFor=\"let item of quickToolbarItems\">\n <ng-container *ngIf=\"item.key !== ToolbarActionTypes.split; else splitLine\">\n <thy-list-option [thyValue]=\"item?.key\" (mousedown)=\"stopPropagation($event)\">\n <the-toolbar-item [editor]=\"editor\" [toolbarItem]=\"item\" [itemMode]=\"ToolbarItemMode.vertical\"></the-toolbar-item>\n </thy-list-option>\n </ng-container>\n </ng-container>\n</thy-selection-list>\n\n<ng-template #splitLine>\n <nav-split-line [mode]=\"ToolbarItemMode.horizontal\"></nav-split-line>\n</ng-template>\n", components: [{ type: i1$7.ThySelectionListComponent, selector: "thy-selection-list,[thy-selection-list]", inputs: ["thyMultiple", "thyBindKeyEventContainer", "thyScrollContainer", "thyBeforeKeydown", "thyUniqueKey", "thyCompareWith", "thyLayout", "thyAutoActiveFirstItem", "thySize", "thySpaceKeyEnabled"], outputs: ["thySelectionChange"] }, { type: i5$3.ThyListOptionComponent, selector: "thy-list-option,[thy-list-option]", inputs: ["id", "thyValue", "thyDisabled"] }, { type: TheToolbarItemComponent, selector: "the-toolbar-item", inputs: ["itemMode"] }, { type: NavSplitLineComponent, selector: "nav-split-line", inputs: ["mode"] }], directives: [{ type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }] });
11428
11491
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheQuickToolbarComponent, decorators: [{
11429
11492
  type: Component,
11430
11493
  args: [{
@@ -11664,112 +11727,11 @@ const createInlineCodePlugin = createPluginFactory({
11664
11727
  execute: editor => InlineCodeEditor.toggleInlineCode(editor),
11665
11728
  active: editor => InlineCodeEditor.isInlineCodeActive(editor)
11666
11729
  }
11667
- ]
11668
- });
11669
-
11670
- class TheIndentToolbarComponent extends TheToolbarBaseItemComponent {
11671
- constructor(elementRef, thyPopover, viewContainerRef, overlay) {
11672
- super();
11673
- this.elementRef = elementRef;
11674
- this.thyPopover = thyPopover;
11675
- this.viewContainerRef = viewContainerRef;
11676
- this.overlay = overlay;
11677
- this.mode = DropdownMode.text;
11678
- this.dropdownMode = DropdownMode;
11679
- this.disabled = false;
11680
- }
11681
- get isOpen() {
11682
- return this.dropdownPopoverRef && this.dropdownPopoverRef.getOverlayRef() && this.dropdownPopoverRef.getOverlayRef().hasAttached();
11683
- }
11684
- toggleDropdown(event) {
11685
- var _a;
11686
- super.execute(event);
11687
- if (((_a = this.editor) === null || _a === void 0 ? void 0 : _a.disabled) || this.disabled) {
11688
- return;
11689
- }
11690
- this.openDropdownPopover();
11691
- }
11692
- handleDocumentMouseDown(event) {
11693
- if (!this.elementRef.nativeElement.contains(event.target)) {
11694
- this.closeDropdownPopover();
11695
- }
11696
- }
11697
- get disabledState() {
11698
- return this.disabled;
11699
- }
11700
- ngOnInit() {
11701
- var _a;
11702
- if (!this.activeMenu) {
11703
- this.activeMenu = this.menus[0];
11704
- }
11705
- if (this.toolbarItem) {
11706
- this.elementRef.nativeElement.classList.add(`${(_a = this.toolbarItem) === null || _a === void 0 ? void 0 : _a.key}`);
11707
- }
11708
- }
11709
- statusChange(editor) {
11710
- var _a, _b;
11711
- this.disabled = ((_a = this.toolbarItem) === null || _a === void 0 ? void 0 : _a.disable) ? (_b = this.toolbarItem) === null || _b === void 0 ? void 0 : _b.disable(editor) : false;
11712
- }
11713
- itemMousedown(event, item) {
11714
- super.execute(event);
11715
- this.closeDropdownPopover();
11716
- if (item === null || item === void 0 ? void 0 : item.execute) {
11717
- item === null || item === void 0 ? void 0 : item.execute(this.editor);
11718
- }
11719
- }
11720
- openDropdownPopover() {
11721
- var _a;
11722
- this.dropdownPopoverRef = this.thyPopover.open(this.dropdownTemplate, {
11723
- origin: this.elementRef,
11724
- panelClass: ['the-toolbar-dropdown-popover', (_a = this.toolbarItem) === null || _a === void 0 ? void 0 : _a.key],
11725
- placement: 'bottomLeft',
11726
- insideClosable: false,
11727
- backdropClosable: true,
11728
- hasBackdrop: false,
11729
- offset: 10,
11730
- viewContainerRef: this.viewContainerRef,
11731
- scrollStrategy: this.overlay.scrollStrategies.reposition()
11732
- });
11733
- }
11734
- closeDropdownPopover() {
11735
- var _a;
11736
- if (this.dropdownPopoverRef) {
11737
- (_a = this.dropdownPopoverRef) === null || _a === void 0 ? void 0 : _a.close();
11738
- }
11730
+ ],
11731
+ options: {
11732
+ disabledOperateTypes: [ElementKinds.image, ...DISABLED_OPERATE_TYPES]
11739
11733
  }
11740
- }
11741
- TheIndentToolbarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheIndentToolbarComponent, deps: [{ token: i0.ElementRef }, { token: i1$1.ThyPopover }, { token: i0.ViewContainerRef }, { token: i2.Overlay }], target: i0.ɵɵFactoryTarget.Component });
11742
- TheIndentToolbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheIndentToolbarComponent, selector: "the-indent-toolbar-item", inputs: { toolbarItem: "toolbarItem", menus: "menus", mode: "mode", item: "item" }, host: { listeners: { "mousedown": "toggleDropdown($event)", "document: mousedown": "handleDocumentMouseDown($event)" }, properties: { "class.disabled": "this.disabledState" }, classAttribute: "the-toolbar-dropdown-container" }, viewQueries: [{ propertyName: "dropdownTemplate", first: true, predicate: ["dropdownTemplate"], descendants: true, static: true }], usesInheritance: true, ngImport: i0, template: "<a thyIconNavLink class=\"icon-mode link-with-down\" [thyTooltip]=\"activeMenu?.name\" thyTooltipPlacement=\"top\">\n <thy-icon [thyIconName]=\"activeMenu?.icon\"></thy-icon>\n <thy-icon class=\"caret-down-icon font-size-sm text-desc\" thyIconName=\"caret-down\"></thy-icon>\n</a>\n\n<ng-template #dropdownTemplate>\n <thy-action-menu class=\"dropdown-menu\">\n <ng-container *ngFor=\"let menu of menus\">\n <a\n thyActionMenuItem\n href=\"javascript:;\"\n [thyTooltip]=\"tooltip\"\n [thyTooltipTemplateContext]=\"{ name: menu.name, shortcutKey: menu.shortcutKey }\"\n thyTooltipPlacement=\"right\"\n (mousedown)=\"itemMousedown($event, menu)\"\n >\n <span thyActionMenuItemIcon>\n <thy-icon [thyIconName]=\"menu.icon\"></thy-icon>\n </span>\n <span thyActionMenuItemName>{{ menu.name }}</span>\n </a>\n </ng-container>\n </thy-action-menu>\n</ng-template>\n\n<ng-template #tooltip let-data>{{ data?.shortcutKey }}</ng-template>\n", components: [{ type: i3.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i4.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { type: i2$1.ThyActionMenuComponent, selector: "thy-action-menu", inputs: ["thyTheme", "thyWidth"] }], directives: [{ type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }, { type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2$1.ThyActionMenuItemDirective, selector: "[thyActionMenuItem]", inputs: ["thyDisabled", "thyType"] }, { type: i2$1.ThyActionMenuItemIconDirective, selector: "[thyActionMenuItemIcon]" }, { type: i2$1.ThyActionMenuItemNameDirective, selector: "[thyActionMenuItemName]" }] });
11743
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheIndentToolbarComponent, decorators: [{
11744
- type: Component,
11745
- args: [{
11746
- selector: 'the-indent-toolbar-item',
11747
- templateUrl: './toolbar-item.component.html',
11748
- host: {
11749
- class: 'the-toolbar-dropdown-container'
11750
- }
11751
- }]
11752
- }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1$1.ThyPopover }, { type: i0.ViewContainerRef }, { type: i2.Overlay }]; }, propDecorators: { toolbarItem: [{
11753
- type: Input
11754
- }], menus: [{
11755
- type: Input
11756
- }], mode: [{
11757
- type: Input
11758
- }], item: [{
11759
- type: Input
11760
- }], dropdownTemplate: [{
11761
- type: ViewChild,
11762
- args: ['dropdownTemplate', { static: true }]
11763
- }], toggleDropdown: [{
11764
- type: HostListener,
11765
- args: ['mousedown', ['$event']]
11766
- }], handleDocumentMouseDown: [{
11767
- type: HostListener,
11768
- args: ['document: mousedown', ['$event']]
11769
- }], disabledState: [{
11770
- type: HostBinding,
11771
- args: ['class.disabled']
11772
- }] } });
11734
+ });
11773
11735
 
11774
11736
  const IndentEditor = {
11775
11737
  getAllowedTypes(editor) {
@@ -11838,14 +11800,6 @@ const IndentEditor = {
11838
11800
  return true;
11839
11801
  }
11840
11802
  return false;
11841
- },
11842
- isDisabled(editor) {
11843
- if (editor.selection) {
11844
- const allowedTypes = IndentEditor.getAllowedTypes(editor);
11845
- const anchorBlock$1 = anchorBlock(editor);
11846
- return anchorBlock$1 && !allowedTypes.includes(anchorBlock$1 === null || anchorBlock$1 === void 0 ? void 0 : anchorBlock$1.type);
11847
- }
11848
- return false;
11849
11803
  }
11850
11804
  };
11851
11805
 
@@ -11919,8 +11873,10 @@ const createIndentPlugin = createPluginFactory({
11919
11873
  {
11920
11874
  key: ElementKinds.indent,
11921
11875
  includes: [Indents.indentRight, Indents.indentLeft],
11922
- iconComponent: TheIndentToolbarComponent,
11923
- disable: editor => IndentEditor.isDisabled(editor)
11876
+ type: ToolbarItemType.dropdown,
11877
+ dropdownMode: DropdownMode.icon,
11878
+ dropdownItemKey: Indents.indentRight,
11879
+ dropdownFixedIcon: true
11924
11880
  },
11925
11881
  {
11926
11882
  key: Indents.indentRight,
@@ -11934,7 +11890,6 @@ const createIndentPlugin = createPluginFactory({
11934
11890
  name: '减少缩进',
11935
11891
  icon: 'float-right',
11936
11892
  shortcutKey: 'Shift+Tab/BackSpace',
11937
- type: ToolbarItemType.toolDropdown,
11938
11893
  execute: editor => IndentEditor.cancelIndent(editor)
11939
11894
  }
11940
11895
  ],
@@ -11947,7 +11902,8 @@ const createIndentPlugin = createPluginFactory({
11947
11902
  ElementKinds.paragraph,
11948
11903
  ...HEADING_TYPES
11949
11904
  ],
11950
- disableIndentTypes: [ElementKinds.bulletedList, ElementKinds.numberedList, ElementKinds.checkItem]
11905
+ disableIndentTypes: [ElementKinds.bulletedList, ElementKinds.numberedList, ElementKinds.checkItem],
11906
+ disabledOperateTypes: [ElementKinds.image, ...DISABLED_OPERATE_TYPES]
11951
11907
  }
11952
11908
  });
11953
11909
 
@@ -12012,14 +11968,6 @@ const FontSizeEditor = {
12012
11968
  }
12013
11969
  }
12014
11970
  return false;
12015
- },
12016
- isDisabled(editor) {
12017
- if (editor.selection) {
12018
- const disableGroup = HEADING_TYPES;
12019
- const anchorBlock$1 = anchorBlock(editor);
12020
- return anchorBlock$1 && disableGroup.includes(anchorBlock$1 === null || anchorBlock$1 === void 0 ? void 0 : anchorBlock$1.type);
12021
- }
12022
- return false;
12023
11971
  }
12024
11972
  };
12025
11973
  const sizeOptions = () => {
@@ -12038,23 +11986,24 @@ const createFontSizePlugin = createPluginFactory({
12038
11986
  {
12039
11987
  key: MarkTypes.fontSize,
12040
11988
  name: '字号',
12041
- type: ToolbarItemType.toolDropdown,
11989
+ type: ToolbarItemType.dropdown,
12042
11990
  dropdownItemKey: FontSizes.fontSize14,
12043
- includes: FontSizeTypes,
12044
- disable: editor => FontSizeEditor.isDisabled(editor)
11991
+ includes: FontSizeTypes
12045
11992
  },
12046
11993
  ...sizeOptions()
12047
- ]
11994
+ ],
11995
+ options: {
11996
+ disabledOperateTypes: [...HEADING_TYPES, ElementKinds.image, ...DISABLED_OPERATE_TYPES]
11997
+ }
12048
11998
  });
12049
11999
 
12050
- class TheVerticalToolbarItemComponent extends TheToolbarBaseItemComponent {
12000
+ class TheVerticalToolbarItemComponent extends TheBaseToolbarDropdown {
12051
12001
  constructor(elementRef, thyPopover, viewContainerRef) {
12052
12002
  super();
12053
12003
  this.elementRef = elementRef;
12054
12004
  this.thyPopover = thyPopover;
12055
12005
  this.viewContainerRef = viewContainerRef;
12056
12006
  this.isHide = true;
12057
- this.active = false;
12058
12007
  }
12059
12008
  get isOpened() {
12060
12009
  return this.dropdownPopoverRef && this.dropdownPopoverRef.getOverlayRef() && this.dropdownPopoverRef.getOverlayRef().hasAttached();
@@ -12065,11 +12014,6 @@ class TheVerticalToolbarItemComponent extends TheToolbarBaseItemComponent {
12065
12014
  }
12066
12015
  }
12067
12016
  ngOnInit() { }
12068
- statusChange(editor) {
12069
- var _a, _b;
12070
- this.active = ((_a = this.toolbarItem) === null || _a === void 0 ? void 0 : _a.active) ? (_b = this.toolbarItem) === null || _b === void 0 ? void 0 : _b.active(editor) : false;
12071
- this.activeMenu = this.menusActive(editor);
12072
- }
12073
12017
  menusActive(editor) {
12074
12018
  return this.menus.find(i => {
12075
12019
  var _a;
@@ -12114,7 +12058,7 @@ class TheVerticalToolbarItemComponent extends TheToolbarBaseItemComponent {
12114
12058
  }
12115
12059
  }
12116
12060
  TheVerticalToolbarItemComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheVerticalToolbarItemComponent, deps: [{ token: i0.ElementRef }, { token: i1$6.ThyPopover }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Component });
12117
- TheVerticalToolbarItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheVerticalToolbarItemComponent, selector: "the-toolbar-vertical-align-item", inputs: { item: "item", menus: "menus", editor: "editor", toolbarItem: "toolbarItem" }, host: { listeners: { "document: mousedown": "handleDocumentMouseDown($event)" }, properties: { "class.hide": "!active" }, classAttribute: "the-toolbar-dropdown-container verticalAlign" }, viewQueries: [{ propertyName: "template", first: true, predicate: ["VerticalAlignItems"], descendants: true, read: TemplateRef, static: true }], usesInheritance: true, ngImport: i0, template: "<a\n thyIconNavLink\n class=\"icon-mode link-with-down\"\n [thyTooltip]=\"toolbarItem?.name\"\n [thyIconNavLinkActive]=\"isOpened\"\n thyTooltipPlacement=\"top\"\n (mousedown)=\"execute($event)\"\n>\n <thy-icon [thyIconName]=\"activeMenu?.icon\"></thy-icon>\n <thy-icon class=\"caret-down-icon font-size-sm text-desc\" thyIconName=\"caret-down\"></thy-icon>\n</a>\n\n<ng-template #VerticalAlignItems>\n <thy-action-menu class=\"dropdown\">\n <ng-container *ngFor=\"let menu of toolbarItem?.includes\">\n <a\n thyActionMenuItem\n href=\"javascript:;\"\n [thyActionMenuItemActive]=\"menu.key === activeMenu?.key\"\n (mousedown)=\"itemMousedown($event, menu)\"\n >\n <span *ngIf=\"menu.icon\" thyActionMenuItemIcon>\n <thy-icon [thyIconName]=\"menu?.icon\"></thy-icon>\n </span>\n <span thyActionMenuItemName>{{ menu.name }}</span>\n </a>\n </ng-container>\n </thy-action-menu>\n</ng-template>\n", components: [{ type: i3.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i4.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { type: i2$1.ThyActionMenuComponent, selector: "thy-action-menu", inputs: ["thyTheme", "thyWidth"] }], directives: [{ type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }, { type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2$1.ThyActionMenuItemDirective, selector: "[thyActionMenuItem]", inputs: ["thyDisabled", "thyType"] }, { type: i2$1.ThyActionMenuItemActiveDirective, selector: "[thyActionMenuItemActive]", inputs: ["thyActionMenuItemActive"] }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$1.ThyActionMenuItemIconDirective, selector: "[thyActionMenuItemIcon]" }, { type: i2$1.ThyActionMenuItemNameDirective, selector: "[thyActionMenuItemName]" }] });
12061
+ TheVerticalToolbarItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheVerticalToolbarItemComponent, selector: "the-toolbar-vertical-align-item", host: { listeners: { "document: mousedown": "handleDocumentMouseDown($event)" }, properties: { "class.hide": "!active" }, classAttribute: "the-toolbar-dropdown-container verticalAlign" }, viewQueries: [{ propertyName: "template", first: true, predicate: ["VerticalAlignItems"], descendants: true, read: TemplateRef, static: true }], usesInheritance: true, ngImport: i0, template: "<a\n thyIconNavLink\n class=\"icon-mode link-with-down\"\n [thyTooltip]=\"toolbarItem?.name\"\n [thyIconNavLinkActive]=\"isOpened\"\n thyTooltipPlacement=\"top\"\n (mousedown)=\"execute($event)\"\n>\n <thy-icon [thyIconName]=\"activeMenuItem?.icon\"></thy-icon>\n <thy-icon class=\"caret-down-icon font-size-sm text-desc\" thyIconName=\"caret-down\"></thy-icon>\n</a>\n\n<ng-template #VerticalAlignItems>\n <thy-action-menu class=\"dropdown\">\n <ng-container *ngFor=\"let menu of toolbarItem?.includes\">\n <a\n thyActionMenuItem\n href=\"javascript:;\"\n [thyActionMenuItemActive]=\"menu.key === activeMenuItem?.key\"\n (mousedown)=\"itemMousedown($event, menu)\"\n >\n <span *ngIf=\"menu.icon\" thyActionMenuItemIcon>\n <thy-icon [thyIconName]=\"menu?.icon\"></thy-icon>\n </span>\n <span thyActionMenuItemName>{{ menu.name }}</span>\n </a>\n </ng-container>\n </thy-action-menu>\n</ng-template>\n", components: [{ type: i3$1.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i3.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }, { type: i2$1.ThyActionMenuComponent, selector: "thy-action-menu", inputs: ["thyTheme", "thyWidth"] }], directives: [{ type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }, { type: i10.NgForOf, selector: "[ngFor][ngForOf]", inputs: ["ngForOf", "ngForTrackBy", "ngForTemplate"] }, { type: i2$1.ThyActionMenuItemDirective, selector: "[thyActionMenuItem]", inputs: ["thyDisabled", "thyType"] }, { type: i2$1.ThyActionMenuItemActiveDirective, selector: "[thyActionMenuItemActive]", inputs: ["thyActionMenuItemActive"] }, { type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i2$1.ThyActionMenuItemIconDirective, selector: "[thyActionMenuItemIcon]" }, { type: i2$1.ThyActionMenuItemNameDirective, selector: "[thyActionMenuItemName]" }] });
12118
12062
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheVerticalToolbarItemComponent, decorators: [{
12119
12063
  type: Component,
12120
12064
  args: [{
@@ -12125,15 +12069,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImpo
12125
12069
  '[class.hide]': '!active'
12126
12070
  }
12127
12071
  }]
12128
- }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1$6.ThyPopover }, { type: i0.ViewContainerRef }]; }, propDecorators: { item: [{
12129
- type: Input
12130
- }], menus: [{
12131
- type: Input
12132
- }], editor: [{
12133
- type: Input
12134
- }], toolbarItem: [{
12135
- type: Input
12136
- }], template: [{
12072
+ }], ctorParameters: function () { return [{ type: i0.ElementRef }, { type: i1$6.ThyPopover }, { type: i0.ViewContainerRef }]; }, propDecorators: { template: [{
12137
12073
  type: ViewChild,
12138
12074
  args: ['VerticalAlignItems', { read: TemplateRef, static: true }]
12139
12075
  }], handleDocumentMouseDown: [{
@@ -12161,7 +12097,7 @@ const createVerticalAlignPlugin = createPluginFactory({
12161
12097
  {
12162
12098
  key: ToolbarActionTypes.verticalAlign,
12163
12099
  name: '垂直对齐',
12164
- type: ToolbarItemType.toolDropdown,
12100
+ type: ToolbarItemType.dropdown,
12165
12101
  dropdownMode: DropdownMode.icon,
12166
12102
  iconComponent: TheVerticalToolbarItemComponent,
12167
12103
  includes: [ToolbarActionTypes.verticalAlignTop, ToolbarActionTypes.verticalAlignMiddle, ToolbarActionTypes.verticalAlignBottom],
@@ -12342,26 +12278,21 @@ const ColorEditor = {
12342
12278
  }
12343
12279
  };
12344
12280
 
12345
- class TheColorToolbarItemComponent extends TheToolbarBaseItemComponent {
12281
+ class TheColorToolbarItemComponent extends TheBaseToolbarItem {
12346
12282
  constructor(thyPopover) {
12347
12283
  super();
12348
12284
  this.thyPopover = thyPopover;
12349
- this.active = false;
12350
12285
  }
12351
12286
  get isOpenColorSelect() {
12352
12287
  return this.colorSelectRef && this.colorSelectRef.componentInstance;
12353
12288
  }
12354
- statusChange(editor) {
12355
- var _a;
12356
- this.active = (_a = this.item) === null || _a === void 0 ? void 0 : _a.active(editor);
12357
- }
12358
12289
  execute(event) {
12359
12290
  var _a;
12360
12291
  super.execute(event);
12361
- if ((_a = this.editor) === null || _a === void 0 ? void 0 : _a.disabled) {
12292
+ if (((_a = this.editor) === null || _a === void 0 ? void 0 : _a.disabled) || this.disabled) {
12362
12293
  return;
12363
12294
  }
12364
- const type = this.item.key;
12295
+ const type = this.toolbarItem.key;
12365
12296
  this.toggleColorSelect(event, type);
12366
12297
  }
12367
12298
  toggleColorSelect(event, type) {
@@ -12401,19 +12332,19 @@ class TheColorToolbarItemComponent extends TheToolbarBaseItemComponent {
12401
12332
  }
12402
12333
  }
12403
12334
  TheColorToolbarItemComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheColorToolbarItemComponent, deps: [{ token: i1$1.ThyPopover }], target: i0.ɵɵFactoryTarget.Component });
12404
- TheColorToolbarItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheColorToolbarItemComponent, selector: "the-color-toolbar-item", inputs: { item: "item", editor: "editor" }, host: { classAttribute: "the-toolbar-item" }, usesInheritance: true, ngImport: i0, template: `
12335
+ TheColorToolbarItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheColorToolbarItemComponent, selector: "the-color-toolbar-item", host: { classAttribute: "the-toolbar-item" }, usesInheritance: true, ngImport: i0, template: `
12405
12336
  <a
12406
12337
  class="link-width-down"
12407
12338
  thyIconNavLink
12408
12339
  [ngStyle]="{
12409
- width: item.key === 'color' ? '42px' : 'auto'
12340
+ width: toolbarItem.key === 'color' ? '42px' : 'auto'
12410
12341
  }"
12411
- [thyTooltip]="item.name"
12342
+ [thyTooltip]="toolbarItem.name"
12412
12343
  [thyIconNavLinkActive]="active"
12413
12344
  thyTooltipPlacement="top"
12414
12345
  (mousedown)="execute($event)"
12415
12346
  >
12416
- <thy-icon [thyIconName]="item.icon" thyIconType="twotone" [thyTwotoneColor]="active"></thy-icon>
12347
+ <thy-icon [thyIconName]="toolbarItem.icon" thyIconType="twotone" [thyTwotoneColor]="active"></thy-icon>
12417
12348
  <thy-icon
12418
12349
  [ngClass]="{
12419
12350
  'link-down-icon': true,
@@ -12423,7 +12354,7 @@ TheColorToolbarItemComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12
12423
12354
  thyIconName="caret-down"
12424
12355
  ></thy-icon>
12425
12356
  </a>
12426
- `, isInline: true, components: [{ type: i3.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i4.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }], directives: [{ type: i10.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }, { type: i10.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
12357
+ `, isInline: true, components: [{ type: i3$1.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: i3.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }], directives: [{ type: i10.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }, { type: i10.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] });
12427
12358
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheColorToolbarItemComponent, decorators: [{
12428
12359
  type: Component,
12429
12360
  args: [{
@@ -12433,14 +12364,14 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImpo
12433
12364
  class="link-width-down"
12434
12365
  thyIconNavLink
12435
12366
  [ngStyle]="{
12436
- width: item.key === 'color' ? '42px' : 'auto'
12367
+ width: toolbarItem.key === 'color' ? '42px' : 'auto'
12437
12368
  }"
12438
- [thyTooltip]="item.name"
12369
+ [thyTooltip]="toolbarItem.name"
12439
12370
  [thyIconNavLinkActive]="active"
12440
12371
  thyTooltipPlacement="top"
12441
12372
  (mousedown)="execute($event)"
12442
12373
  >
12443
- <thy-icon [thyIconName]="item.icon" thyIconType="twotone" [thyTwotoneColor]="active"></thy-icon>
12374
+ <thy-icon [thyIconName]="toolbarItem.icon" thyIconType="twotone" [thyTwotoneColor]="active"></thy-icon>
12444
12375
  <thy-icon
12445
12376
  [ngClass]="{
12446
12377
  'link-down-icon': true,
@@ -12455,11 +12386,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImpo
12455
12386
  class: 'the-toolbar-item'
12456
12387
  }
12457
12388
  }]
12458
- }], ctorParameters: function () { return [{ type: i1$1.ThyPopover }]; }, propDecorators: { item: [{
12459
- type: Input
12460
- }], editor: [{
12461
- type: Input
12462
- }] } });
12389
+ }], ctorParameters: function () { return [{ type: i1$1.ThyPopover }]; } });
12463
12390
 
12464
12391
  const createColorPlugin = createPluginFactory({
12465
12392
  key: PluginKeys.color,
@@ -12478,7 +12405,10 @@ const createColorPlugin = createPluginFactory({
12478
12405
  iconComponent: TheColorToolbarItemComponent,
12479
12406
  active: editor => ColorEditor.getActiveColor(editor, MarkTypes.backgroundColor)
12480
12407
  }
12481
- ]
12408
+ ],
12409
+ options: {
12410
+ disabledOperateTypes: [ElementKinds.image, ...DISABLED_OPERATE_TYPES]
12411
+ }
12482
12412
  });
12483
12413
 
12484
12414
  const internalPlugins = () => [
@@ -12560,7 +12490,7 @@ class TheToolbarComponent {
12560
12490
  ngOnInit() {
12561
12491
  this.setToolbarClass();
12562
12492
  this.renderToolbarView();
12563
- this.statusChange(this.editor);
12493
+ this.selectionChange(this.editor);
12564
12494
  if (this.isMore) {
12565
12495
  this.resizeElement();
12566
12496
  }
@@ -12595,13 +12525,13 @@ class TheToolbarComponent {
12595
12525
  });
12596
12526
  this.resizeObserver.observe(editableElement);
12597
12527
  }
12598
- statusChange(editor) {
12528
+ selectionChange(editor) {
12599
12529
  const toolbarItems = [...this.toolbarItems, this.moreGroupMenu];
12600
12530
  for (const item of toolbarItems) {
12601
12531
  if (item.key !== ToolbarActionTypes.split) {
12602
12532
  const itemComponent = this.components.get(item.key);
12603
- if (itemComponent) {
12604
- itemComponent.instance.statusChange(editor);
12533
+ if (itemComponent && itemComponent.instance.selectionChange) {
12534
+ itemComponent.instance.selectionChange(editor);
12605
12535
  }
12606
12536
  }
12607
12537
  }
@@ -12669,7 +12599,7 @@ class TheToolbarComponent {
12669
12599
  elementWidth -= headingWidth;
12670
12600
  continue;
12671
12601
  }
12672
- const isCustomComponent = (item === null || item === void 0 ? void 0 : item.type) === ToolbarItemType.toolDropdown || !!(item === null || item === void 0 ? void 0 : item.iconComponent);
12602
+ const isCustomComponent = (item === null || item === void 0 ? void 0 : item.type) === ToolbarItemType.dropdown || !!(item === null || item === void 0 ? void 0 : item.iconComponent);
12673
12603
  elementWidth -= isCustomComponent ? maxItemWidth : defaultItemWidth;
12674
12604
  }
12675
12605
  return {
@@ -12715,15 +12645,17 @@ class TheToolbarComponent {
12715
12645
  createToolbarItem(item) {
12716
12646
  const { iconComponent, type, dropdownMode, dropdownItemKey, includes } = item, args = __rest(item, ["iconComponent", "type", "dropdownMode", "dropdownItemKey", "includes"]);
12717
12647
  const viewComponent = this.viewComponentType(type);
12718
- const dropdownItem = this.getDropdownItem(item);
12719
12648
  const factory = this.cfr.resolveComponentFactory(iconComponent ? iconComponent : viewComponent);
12720
12649
  const compRef = this.toolbarContainer.createComponent(factory);
12721
12650
  compRef.instance.editor = this.editor;
12722
12651
  compRef.instance.toolbarItem = item;
12723
- compRef.instance.menus = includes;
12724
- compRef.instance.item = includes && dropdownItem ? dropdownItem : args;
12725
- compRef.instance.mode = dropdownMode;
12726
12652
  this.components.set(item.key, compRef);
12653
+ if (item.type === ToolbarItemType.dropdown) {
12654
+ const dropdownRef = compRef;
12655
+ dropdownRef.instance.dropdownItemKey = item.dropdownItemKey;
12656
+ dropdownRef.instance.menus = includes;
12657
+ dropdownRef.instance.mode = dropdownMode;
12658
+ }
12727
12659
  }
12728
12660
  createToolbarSplit() {
12729
12661
  const navSplitLineFactory = this.cfr.resolveComponentFactory(NavSplitLineComponent);
@@ -12743,25 +12675,14 @@ class TheToolbarComponent {
12743
12675
  if (type === ToolbarItemType.default) {
12744
12676
  return TheToolbarItemComponent;
12745
12677
  }
12746
- if (type === ToolbarItemType.toolDropdown) {
12678
+ if (type === ToolbarItemType.dropdown) {
12747
12679
  return TheToolbarDropdownComponent;
12748
12680
  }
12749
12681
  return TheToolbarItemComponent;
12750
12682
  }
12751
- getDropdownItem(item) {
12752
- var _a, _b, _c;
12753
- let dropdownKey = item === null || item === void 0 ? void 0 : item.dropdownItemKey;
12754
- // modify the fontsize option externally
12755
- const contextService = (_b = (_a = this.editor) === null || _a === void 0 ? void 0 : _a.injector) === null || _b === void 0 ? void 0 : _b.get(TheContextService);
12756
- const fontSize = contextService === null || contextService === void 0 ? void 0 : contextService.getDefaultFontSize();
12757
- if (contextService && item.key === MarkTypes.fontSize && fontSize) {
12758
- dropdownKey = fontSize;
12759
- }
12760
- return (_c = item === null || item === void 0 ? void 0 : item.includes) === null || _c === void 0 ? void 0 : _c.find((item) => item.key === dropdownKey);
12761
- }
12762
12683
  }
12763
12684
  TheToolbarComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheToolbarComponent, deps: [{ token: i0.ComponentFactoryResolver }, { token: i0.ChangeDetectorRef }, { token: i0.ElementRef }, { token: i0.NgZone }, { token: TheToolbarGroupToken }], target: i0.ɵɵFactoryTarget.Component });
12764
- TheToolbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheToolbarComponent, selector: "the-toolbar", inputs: { editor: "editor", toolbarItems: "toolbarItems", align: "align", containerClass: "containerClass", isMore: "isMore", afterTemplate: "afterTemplate" }, host: { classAttribute: "the-toolbar-container" }, viewQueries: [{ propertyName: "toolbarContainer", first: true, predicate: ["toolbarContainer"], descendants: true, read: ViewContainerRef, static: true }], usesOnChanges: true, ngImport: i0, template: "<thy-icon-nav [style.justifyContent]=\"align\">\n <ng-container #toolbarContainer></ng-container>\n <ng-content></ng-content>\n <ng-template *ngIf=\"afterTemplate\" [ngTemplateOutlet]=\"afterTemplate\"></ng-template>\n</thy-icon-nav>\n", components: [{ type: i3.ThyIconNavComponent, selector: "thy-icon-nav", inputs: ["thyType"] }], directives: [{ type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i10.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }] });
12685
+ TheToolbarComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheToolbarComponent, selector: "the-toolbar", inputs: { editor: "editor", toolbarItems: "toolbarItems", align: "align", containerClass: "containerClass", isMore: "isMore", afterTemplate: "afterTemplate" }, host: { classAttribute: "the-toolbar-container" }, viewQueries: [{ propertyName: "toolbarContainer", first: true, predicate: ["toolbarContainer"], descendants: true, read: ViewContainerRef, static: true }], usesOnChanges: true, ngImport: i0, template: "<thy-icon-nav [style.justifyContent]=\"align\">\n <ng-container #toolbarContainer></ng-container>\n <ng-content></ng-content>\n <ng-template *ngIf=\"afterTemplate\" [ngTemplateOutlet]=\"afterTemplate\"></ng-template>\n</thy-icon-nav>\n", components: [{ type: i3$1.ThyIconNavComponent, selector: "thy-icon-nav", inputs: ["thyType"] }], directives: [{ type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i10.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet"] }] });
12765
12686
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheToolbarComponent, decorators: [{
12766
12687
  type: Component,
12767
12688
  args: [{
@@ -12814,7 +12735,7 @@ class TheInlineToolbarComponent {
12814
12735
  .subscribe(() => {
12815
12736
  var _a;
12816
12737
  this.updateInlineToolbar();
12817
- (_a = this.inlineToolbar) === null || _a === void 0 ? void 0 : _a.statusChange(this.editor);
12738
+ (_a = this.inlineToolbar) === null || _a === void 0 ? void 0 : _a.selectionChange(this.editor);
12818
12739
  this.cdr.detectChanges();
12819
12740
  });
12820
12741
  });
@@ -12987,7 +12908,7 @@ class TheQuickInsertComponent {
12987
12908
  }
12988
12909
  }
12989
12910
  TheQuickInsertComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheQuickInsertComponent, deps: [{ token: i0.Renderer2 }, { token: i0.ElementRef }, { token: i0.ChangeDetectorRef }], target: i0.ɵɵFactoryTarget.Component });
12990
- TheQuickInsertComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheQuickInsertComponent, selector: "[theQuickInsert]", inputs: { editor: "editor", quickToolbarItems: "quickToolbarItems", isVisible: "isVisible" }, host: { listeners: { "mousedown": "handleMousedownNativeElement($event)" }, properties: { "class.hide": "isHide" }, classAttribute: "the-quick-insert" }, viewQueries: [{ propertyName: "iconElement", first: true, predicate: ["iconElement"], descendants: true, read: ElementRef }], ngImport: i0, template: "<thy-icon\n #iconElement\n [thyIconName]=\"displayIconName\"\n class=\"quick-insert-icon text-desc font-size-xlg\"\n (mouseenter)=\"mouseEnter($event)\"\n (mouseleave)=\"mouseLeave($event)\"\n (mousedown)=\"handleClick($event)\"\n></thy-icon>\n", components: [{ type: i4.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }] });
12911
+ TheQuickInsertComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheQuickInsertComponent, selector: "[theQuickInsert]", inputs: { editor: "editor", quickToolbarItems: "quickToolbarItems", isVisible: "isVisible" }, host: { listeners: { "mousedown": "handleMousedownNativeElement($event)" }, properties: { "class.hide": "isHide" }, classAttribute: "the-quick-insert" }, viewQueries: [{ propertyName: "iconElement", first: true, predicate: ["iconElement"], descendants: true, read: ElementRef }], ngImport: i0, template: "<thy-icon\n #iconElement\n [thyIconName]=\"displayIconName\"\n class=\"quick-insert-icon text-desc font-size-xlg\"\n (mouseenter)=\"mouseEnter($event)\"\n (mouseleave)=\"mouseLeave($event)\"\n (mousedown)=\"handleClick($event)\"\n></thy-icon>\n", components: [{ type: i3.ThyIconComponent, selector: "thy-icon", inputs: ["thyIconType", "thyTwotoneColor", "thyIconName", "thyIconRotate", "thyIconSet", "thyIconLegging", "thyIconLinearGradient"] }] });
12991
12912
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheQuickInsertComponent, decorators: [{
12992
12913
  type: Component,
12993
12914
  args: [{
@@ -13327,7 +13248,7 @@ class TheEditorComponent extends mixinUnsubscribe(MixinBase) {
13327
13248
  valueChange(value) {
13328
13249
  var _a, _b, _c, _d, _e, _f;
13329
13250
  const isEditable = !((_a = this.theOptions) === null || _a === void 0 ? void 0 : _a.readonly) && !((_b = this.theOptions) === null || _b === void 0 ? void 0 : _b.disabled);
13330
- (_c = this.theGlobalToolbarInstance) === null || _c === void 0 ? void 0 : _c.statusChange(this.editor);
13251
+ (_c = this.theGlobalToolbarInstance) === null || _c === void 0 ? void 0 : _c.selectionChange(this.editor);
13331
13252
  // quick insert button
13332
13253
  if (isEditable) {
13333
13254
  (_d = this.quickInsertInstance) === null || _d === void 0 ? void 0 : _d.checkStatus();
@@ -13462,7 +13383,7 @@ TheEditorComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", ver
13462
13383
  useExisting: forwardRef(() => TheEditorComponent),
13463
13384
  multi: true
13464
13385
  }
13465
- ], viewQueries: [{ propertyName: "templateInstance", first: true, predicate: ["templateInstance"], descendants: true, static: true }, { propertyName: "globalToolbarInstance", first: true, predicate: ["globalToolbar"], descendants: true }, { propertyName: "quickInsertInstance", first: true, predicate: ["quickInsert"], descendants: true, static: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<the-toolbar\n *ngIf=\"!theOptions?.readonly && !theGlobalToolbar\"\n [ngClass]=\"{\n 'the-toolbar-disabled': theOptions?.disabled\n }\"\n #globalToolbar\n [editor]=\"editor\"\n [toolbarItems]=\"toolbarEntity.global\"\n [containerClass]=\"globalToolbarClass\"\n [align]=\"theOptions?.toolbar?.align\"\n></the-toolbar>\n\n<div\n class=\"the-editable-container\"\n [ngClass]=\"{\n 'the-editor-disabled': theOptions?.disabled,\n 'max-height': maxHeight\n }\"\n [ngStyle]=\"{ 'max-height': maxHeight }\"\n>\n <slate-editable\n class=\"the-editor-typo\"\n [editor]=\"editor\"\n [ngModel]=\"editorValue\"\n (ngModelChange)=\"valueChange($event)\"\n [decorate]=\"decorate\"\n [placeholder]=\"theOptions?.placeholder\"\n [placeholderDecorate]=\"theOptions?.placeholderDecorate ? theOptions?.placeholderDecorate : null\"\n [renderElement]=\"renderElement\"\n [renderText]=\"renderText\"\n [renderLeaf]=\"renderLeaf\"\n [readonly]=\"theOptions?.readonly || theOptions?.disabled\"\n [keydown]=\"onKeyDown\"\n [click]=\"onClick\"\n [paste]=\"onSlaPaste\"\n [beforeInput]=\"onSlaBeforeInput\"\n [blur]=\"onSlaBlur\"\n [focus]=\"onSlaFocus\"\n [copy]=\"onSlaCopy\"\n [cut]=\"onSlaCut\"\n [isStrictDecorate]=\"false\"\n [compositionStart]=\"onSlaCompositionStart\"\n [compositionEnd]=\"onSlaCompositionEnd\"\n [dragStart]=\"onSlaDragStart\"\n [dragOver]=\"onSlaDragOver\"\n [drop]=\"onDrop\"\n (mousedown)=\"mousedown($event)\"\n ></slate-editable>\n <the-inline-toolbar\n *ngIf=\"!theOptions?.readonly && theOptions?.inlineToobarVisible\"\n [editor]=\"editor\"\n [toolbarItems]=\"toolbarEntity.inline\"\n ></the-inline-toolbar>\n <div\n #quickInsert\n theQuickInsert\n [editor]=\"editor\"\n [quickToolbarItems]=\"quickToolbarItems\"\n [isVisible]=\"theOptions?.quickInsertVisible\"\n ></div>\n <the-template #templateInstance></the-template>\n</div>\n", components: [{ type: TheToolbarComponent, selector: "the-toolbar", inputs: ["editor", "toolbarItems", "align", "containerClass", "isMore", "afterTemplate"] }, { type: i1.SlateEditableComponent, selector: "slate-editable", inputs: ["editor", "renderElement", "renderLeaf", "renderText", "decorate", "placeholderDecorate", "isStrictDecorate", "trackBy", "readonly", "placeholder", "beforeInput", "blur", "click", "compositionEnd", "compositionStart", "copy", "cut", "dragOver", "dragStart", "dragEnd", "drop", "focus", "keydown", "paste", "spellCheck", "autoCorrect", "autoCapitalize"] }, { type: TheInlineToolbarComponent, selector: "the-inline-toolbar", inputs: ["editor", "toolbarItems"] }, { type: TheQuickInsertComponent, selector: "[theQuickInsert]", inputs: ["editor", "quickToolbarItems", "isVisible"] }, { type: TheTemplateComponent, selector: "the-template,[theTemplate]" }], directives: [{ type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i10.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i10.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i4$1.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i4$1.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
13386
+ ], viewQueries: [{ propertyName: "templateInstance", first: true, predicate: ["templateInstance"], descendants: true, static: true }, { propertyName: "globalToolbarInstance", first: true, predicate: ["globalToolbar"], descendants: true }, { propertyName: "quickInsertInstance", first: true, predicate: ["quickInsert"], descendants: true, static: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "<the-toolbar\n *ngIf=\"!theOptions?.readonly && !theGlobalToolbar\"\n [ngClass]=\"{\n 'the-toolbar-disabled': theOptions?.disabled\n }\"\n #globalToolbar\n [editor]=\"editor\"\n [toolbarItems]=\"toolbarEntity.global\"\n [containerClass]=\"globalToolbarClass\"\n [align]=\"theOptions?.toolbar?.align\"\n></the-toolbar>\n\n<div\n class=\"the-editable-container\"\n [ngClass]=\"{\n 'the-editor-disabled': theOptions?.disabled,\n 'max-height': maxHeight\n }\"\n [ngStyle]=\"{ 'max-height': maxHeight }\"\n>\n <slate-editable\n class=\"the-editor-typo\"\n [editor]=\"editor\"\n [ngModel]=\"editorValue\"\n (ngModelChange)=\"valueChange($event)\"\n [decorate]=\"decorate\"\n [placeholder]=\"theOptions?.placeholder\"\n [placeholderDecorate]=\"theOptions?.placeholderDecorate ? theOptions?.placeholderDecorate : null\"\n [renderElement]=\"renderElement\"\n [renderText]=\"renderText\"\n [renderLeaf]=\"renderLeaf\"\n [readonly]=\"theOptions?.readonly || theOptions?.disabled\"\n [keydown]=\"onKeyDown\"\n [click]=\"onClick\"\n [paste]=\"onSlaPaste\"\n [beforeInput]=\"onSlaBeforeInput\"\n [blur]=\"onSlaBlur\"\n [focus]=\"onSlaFocus\"\n [copy]=\"onSlaCopy\"\n [cut]=\"onSlaCut\"\n [isStrictDecorate]=\"false\"\n [compositionStart]=\"onSlaCompositionStart\"\n [compositionEnd]=\"onSlaCompositionEnd\"\n [dragStart]=\"onSlaDragStart\"\n [dragOver]=\"onSlaDragOver\"\n [drop]=\"onDrop\"\n (mousedown)=\"mousedown($event)\"\n ></slate-editable>\n <the-inline-toolbar\n *ngIf=\"!theOptions?.readonly && theOptions?.inlineToobarVisible\"\n [editor]=\"editor\"\n [toolbarItems]=\"toolbarEntity.inline\"\n ></the-inline-toolbar>\n <div\n #quickInsert\n theQuickInsert\n [editor]=\"editor\"\n [quickToolbarItems]=\"quickToolbarItems\"\n [isVisible]=\"theOptions?.quickInsertVisible\"\n ></div>\n <the-template #templateInstance></the-template>\n</div>\n", components: [{ type: TheToolbarComponent, selector: "the-toolbar", inputs: ["editor", "toolbarItems", "align", "containerClass", "isMore", "afterTemplate"] }, { type: i1.SlateEditableComponent, selector: "slate-editable", inputs: ["editor", "renderElement", "renderLeaf", "renderText", "decorate", "placeholderDecorate", "isStrictDecorate", "trackBy", "readonly", "placeholder", "beforeInput", "blur", "click", "compositionEnd", "compositionStart", "copy", "cut", "dragOver", "dragStart", "dragEnd", "drop", "focus", "keydown", "paste", "spellCheck", "autoCorrect", "autoCapitalize"] }, { type: TheInlineToolbarComponent, selector: "the-inline-toolbar", inputs: ["editor", "toolbarItems"] }, { type: TheQuickInsertComponent, selector: "[theQuickInsert]", inputs: ["editor", "quickToolbarItems", "isVisible"] }, { type: TheTemplateComponent, selector: "the-template,[theTemplate]" }], directives: [{ type: i10.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { type: i10.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { type: i10.NgStyle, selector: "[ngStyle]", inputs: ["ngStyle"] }, { type: i4.NgControlStatus, selector: "[formControlName],[ngModel],[formControl]" }, { type: i4.NgModel, selector: "[ngModel]:not([formControlName]):not([formControl])", inputs: ["name", "disabled", "ngModel", "ngModelOptions"], outputs: ["ngModelChange"], exportAs: ["ngModel"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
13466
13387
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheEditorComponent, decorators: [{
13467
13388
  type: Component,
13468
13389
  args: [{
@@ -13548,7 +13469,7 @@ class TheToolbarGroupComponent {
13548
13469
  }
13549
13470
  set item(i) {
13550
13471
  this._item = i;
13551
- this.activeMenu = i;
13472
+ this.activeMenuItem = i;
13552
13473
  }
13553
13474
  get item() {
13554
13475
  return this._item;
@@ -13579,9 +13500,9 @@ class TheToolbarGroupComponent {
13579
13500
  this.openGroup(event);
13580
13501
  }
13581
13502
  }
13582
- statusChange(editor) {
13503
+ selectionChange(editor) {
13583
13504
  const activeItem = this.menusActive(editor);
13584
- this.activeMenu = activeItem ? activeItem : null;
13505
+ this.activeMenuItem = activeItem ? activeItem : null;
13585
13506
  this.activeChange();
13586
13507
  this.colseGroup();
13587
13508
  }
@@ -13623,7 +13544,7 @@ class TheToolbarGroupComponent {
13623
13544
  }
13624
13545
  }
13625
13546
  TheToolbarGroupComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheToolbarGroupComponent, deps: [{ token: i0.ElementRef }, { token: i1$1.ThyPopover }, { token: i0.ViewContainerRef }], target: i0.ɵɵFactoryTarget.Component });
13626
- TheToolbarGroupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheToolbarGroupComponent, selector: "the-toolbar-group", inputs: { menus: "menus", item: "item" }, host: { listeners: { "mousedown": "mousedownHandler($event)", "click": "clickHandle($event)" }, classAttribute: "the-toolbar-group" }, viewQueries: [{ propertyName: "groupTemplate", first: true, predicate: ["groupTemplate"], descendants: true, read: TemplateRef, static: true }], ngImport: i0, template: "<a thyIconNavLink [thyIconNavLinkIcon]=\"item.icon\" [thyTooltip]=\"item?.name\" thyTooltipPlacement=\"top\" [thyIconNavLinkActive]=\"active\"></a>\n\n<ng-template #groupTemplate>\n <the-toolbar class=\"group\" [editor]=\"editor\" [toolbarItems]=\"menus\" [isMore]=\"false\"></the-toolbar>\n</ng-template>\n", components: [{ type: i3.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: TheToolbarComponent, selector: "the-toolbar", inputs: ["editor", "toolbarItems", "align", "containerClass", "isMore", "afterTemplate"] }], directives: [{ type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }] });
13547
+ TheToolbarGroupComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.15", type: TheToolbarGroupComponent, selector: "the-toolbar-group", inputs: { menus: "menus", item: "item" }, host: { listeners: { "mousedown": "mousedownHandler($event)", "click": "clickHandle($event)" }, classAttribute: "the-toolbar-group" }, viewQueries: [{ propertyName: "groupTemplate", first: true, predicate: ["groupTemplate"], descendants: true, read: TemplateRef, static: true }], ngImport: i0, template: "<a thyIconNavLink [thyIconNavLinkIcon]=\"item.icon\" [thyTooltip]=\"item?.name\" thyTooltipPlacement=\"top\" [thyIconNavLinkActive]=\"active\"></a>\n\n<ng-template #groupTemplate>\n <the-toolbar class=\"group\" [editor]=\"editor\" [toolbarItems]=\"menus\" [isMore]=\"false\"></the-toolbar>\n</ng-template>\n", components: [{ type: i3$1.ThyIconNavLinkComponent, selector: "[thyIconNavLink]", inputs: ["thyIconNavLinkIcon", "thyIconNavLinkActive"] }, { type: TheToolbarComponent, selector: "the-toolbar", inputs: ["editor", "toolbarItems", "align", "containerClass", "isMore", "afterTemplate"] }], directives: [{ type: i5$1.ThyTooltipDirective, selector: "[thyTooltip],[thy-tooltip]", inputs: ["thyTooltip", "thyTooltipPlacement", "thyTooltipClass", "thyTooltipShowDelay", "thyTooltipHideDelay", "thyTooltipTrigger", "thyTooltipDisabled", "thyTooltipTemplateContext", "thyTooltipOffset", "thyTooltipPin"], exportAs: ["thyTooltip"] }] });
13627
13548
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImport: i0, type: TheToolbarGroupComponent, decorators: [{
13628
13549
  type: Component,
13629
13550
  args: [{
@@ -13686,7 +13607,6 @@ const COMPONENTS = [
13686
13607
  TheTableToolbarItemComponent,
13687
13608
  TheConversionHintComponent,
13688
13609
  TheVerticalToolbarItemComponent,
13689
- TheIndentToolbarComponent,
13690
13610
  TheTableOptionsComponent
13691
13611
  ];
13692
13612
  const PLUGIN_COMPONENTS = [
@@ -13730,7 +13650,6 @@ TheEditorModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "12.0.0", version
13730
13650
  TheTableToolbarItemComponent,
13731
13651
  TheConversionHintComponent,
13732
13652
  TheVerticalToolbarItemComponent,
13733
- TheIndentToolbarComponent,
13734
13653
  TheTableOptionsComponent, TheImageComponent,
13735
13654
  TheTemplateComponent,
13736
13655
  TheHrComponent,
@@ -13841,5 +13760,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.15", ngImpo
13841
13760
  * Generated bundle index. Do not edit.
13842
13761
  */
13843
13762
 
13844
- export { ALIGN_BLOCK_TYPES, A_TAG_REL_ATTR, AlignEditor, Alignment, BLOCK_DELETEBACKWARD_TYPES, BlockquoteEditor, CLIPBOARD_FORMAT_KEY, CODEMIRROR_PADDING_TOP, CODE_MODES, COMPONENTS, CONTAINER_BLOCKS, CONTROL_KEY, CodeEditor, ColorEditor, DEFAULT_LANGUAGE, DEFAULT_SCROLL_CONTAINER, DefaultElementOptions, DefaultGlobalToolbarDefinition, DefaultInlineToolbarDefinition, DefaultQuickToolbarDefinition, DropdownMode, ELEMENT_UNIQUE_ID, ElementKinds, ErrorCodes, FontSizeTypes, FontSizes, HEADING_TYPES, HeadingEditor, HrEditor, IS_MAC, ImageEditor, IndentEditor, Indents, LINK_DEFAULT_TEXT, LIST_BLOCK_TYPES, LayoutTypes, LinkEditor, ListEditor, MarkEditor, MarkProps, MarkTypes, PICTURE_ACCEPTED_UPLOAD_MIME, PICTURE_ACCEPTED_UPLOAD_SIZE, PLUGIN_COMPONENTS, PluginKeys, QuickInsertEditor, STANDARD_HEADING_TYPES, TAB_SPACE, THE_EDITOR_CONVERSION_HINT_REF, THE_EDITOR_QUICK_TOOLBAR_REF, THE_EDITOR_UUID, THE_INLINE_TOOLBAR_TYPES, THE_MODE_PROVIDER, THE_MODE_TOKEN, THE_UPLOAD_SERVICE_TOKEN, TableEditor, TheBaseElementComponent, TheContextService, TheDataMode, TheDefaultElementComponent, TheEditor, TheEditorComponent, TheEditorModule, TheImageComponent, TheIndentToolbarComponent, TheMode, TheModeConfig, index$1 as TheQueries, TheToolbarBaseItemComponent, TheToolbarComponent, TheToolbarDropdownComponent, TheToolbarGroupComponent, TheToolbarGroupToken, TheToolbarItemComponent, TheToolbarService, index as TheTransforms, TodoItemEditor, ToolbarActionTypes, ToolbarAlignment, ToolbarItemMode, ToolbarItemType, ToolbarMoreGroup, VOID_BLOCK_TYPES, VerticalAlignEditor, VerticalAlignment, ZERO_WIDTH_CHAR, autoFocus, autoScrollViewHandle, coercePixelsFromCssValue, combinePlugins, createEmptyParagraph, createPluginFactory, createToolbar, createVerticalAlignPlugin, dataDeserialize, dataSerializing, deleteColorAndBackgroundColorOfText, deleteElementKey, extractFragment, flattenDeepPlugins, getColsTotalWidth, getEditorUUID, getElementClassByPrefix, getElementHeight, getElementWidth, getEndBlock, getPlugin, getPluginOptions, getPlugins, getRowsTotalHeight, getStartBlock, getToolbarClass, headingOptions, htmlToTheia, idCreator, inValidTypes, internalPlugins, isCleanEmptyParagraph, isPureEmptyParagraph, mergeArray, mergeDeepPlugins, mergeElementOptions, mergeOptions, nestedStructureByKey, plainToTheia, pluginsByKey, setEditorUUID, useElementStyle, withTheia };
13763
+ export { ALIGN_BLOCK_TYPES, A_TAG_REL_ATTR, AlignEditor, Alignment, BLOCK_DELETE_BACKWARD_TYPES, BlockquoteEditor, CLIPBOARD_FORMAT_KEY, CODEMIRROR_PADDING_TOP, CODE_MODES, COMPONENTS, CONTAINER_BLOCKS, CONTROL_KEY, CodeEditor, ColorEditor, DEFAULT_LANGUAGE, DEFAULT_SCROLL_CONTAINER, DISABLED_OPERATE_TYPES, DefaultElementOptions, DefaultGlobalToolbarDefinition, DefaultInlineToolbarDefinition, DefaultQuickToolbarDefinition, DropdownMode, ELEMENT_UNIQUE_ID, ElementKinds, ErrorCodes, FontSizeTypes, FontSizes, HEADING_TYPES, HeadingEditor, HrEditor, IS_MAC, ImageEditor, IndentEditor, Indents, LINK_DEFAULT_TEXT, LIST_BLOCK_TYPES, LayoutTypes, LinkEditor, ListEditor, MarkEditor, MarkProps, MarkTypes, PICTURE_ACCEPTED_UPLOAD_MIME, PICTURE_ACCEPTED_UPLOAD_SIZE, PLUGIN_COMPONENTS, PluginKeys, QuickInsertEditor, STANDARD_HEADING_TYPES, TAB_SPACE, THE_EDITOR_CONVERSION_HINT_REF, THE_EDITOR_QUICK_TOOLBAR_REF, THE_EDITOR_UUID, THE_INLINE_TOOLBAR_TYPES, THE_MODE_PROVIDER, THE_MODE_TOKEN, THE_UPLOAD_SERVICE_TOKEN, TableEditor, TheBaseElementComponent, TheBaseToolbarDropdown, TheBaseToolbarItem, TheContextService, TheDataMode, TheDefaultElementComponent, TheEditor, TheEditorComponent, TheEditorModule, TheImageComponent, TheMode, TheModeConfig, index$1 as TheQueries, TheToolbarComponent, TheToolbarDropdownComponent, TheToolbarGroupComponent, TheToolbarGroupToken, TheToolbarItemComponent, TheToolbarService, index as TheTransforms, TodoItemEditor, ToolbarActionTypes, ToolbarAlignment, ToolbarItemMode, ToolbarItemType, ToolbarMoreGroup, VOID_BLOCK_TYPES, VerticalAlignEditor, VerticalAlignment, ZERO_WIDTH_CHAR, autoFocus, autoScrollViewHandle, coercePixelsFromCssValue, combinePlugins, createEmptyParagraph, createPluginFactory, createToolbar, createVerticalAlignPlugin, dataDeserialize, dataSerializing, deleteElementKey, extractFragment, filterTextFormat, flattenDeepPlugins, getColsTotalWidth, getEditorUUID, getElementClassByPrefix, getElementHeight, getElementWidth, getEndBlock, getPlugin, getPluginOptions, getPlugins, getRowsTotalHeight, getStartBlock, getToolbarClass, headingOptions, htmlToTheia, idCreator, inValidTypes, internalPlugins, isCleanEmptyParagraph, isPureEmptyParagraph, mergeArray, mergeDeepPlugins, mergeElementOptions, mergeOptions, nestedStructureByKey, plainToTheia, pluginsByKey, setEditorUUID, useElementStyle, withTheia };
13845
13764
  //# sourceMappingURL=worktile-theia.js.map