@syncfusion/ej2-richtexteditor 24.1.46 → 24.2.3

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 (116) hide show
  1. package/CHANGELOG.md +22 -0
  2. package/dist/ej2-richtexteditor.min.js +2 -2
  3. package/dist/ej2-richtexteditor.umd.min.js +2 -2
  4. package/dist/ej2-richtexteditor.umd.min.js.map +1 -1
  5. package/dist/es6/ej2-richtexteditor.es2015.js +760 -168
  6. package/dist/es6/ej2-richtexteditor.es2015.js.map +1 -1
  7. package/dist/es6/ej2-richtexteditor.es5.js +769 -167
  8. package/dist/es6/ej2-richtexteditor.es5.js.map +1 -1
  9. package/dist/global/ej2-richtexteditor.min.js +2 -2
  10. package/dist/global/ej2-richtexteditor.min.js.map +1 -1
  11. package/dist/global/index.d.ts +1 -1
  12. package/package.json +12 -12
  13. package/src/common/constant.d.ts +6 -0
  14. package/src/common/constant.js +6 -0
  15. package/src/common/util.js +31 -20
  16. package/src/editor-manager/base/constant.d.ts +6 -0
  17. package/src/editor-manager/base/constant.js +6 -0
  18. package/src/editor-manager/base/editor-manager.d.ts +5 -0
  19. package/src/editor-manager/base/editor-manager.js +59 -0
  20. package/src/editor-manager/base/interface.d.ts +8 -0
  21. package/src/editor-manager/plugin/dom-node.js +3 -1
  22. package/src/editor-manager/plugin/format-painter-actions.js +1 -1
  23. package/src/editor-manager/plugin/ms-word-clean-up.d.ts +2 -0
  24. package/src/editor-manager/plugin/ms-word-clean-up.js +39 -10
  25. package/src/editor-manager/plugin/selection-commands.js +16 -0
  26. package/src/editor-manager/plugin/table.d.ts +0 -1
  27. package/src/editor-manager/plugin/table.js +14 -26
  28. package/src/editor-manager/plugin/undo.d.ts +1 -0
  29. package/src/editor-manager/plugin/undo.js +21 -1
  30. package/src/rich-text-editor/actions/base-quick-toolbar.js +3 -0
  31. package/src/rich-text-editor/actions/base-toolbar.js +8 -4
  32. package/src/rich-text-editor/actions/count.js +1 -1
  33. package/src/rich-text-editor/actions/dropdown-buttons.js +21 -2
  34. package/src/rich-text-editor/actions/emoji-picker.js +1 -1
  35. package/src/rich-text-editor/actions/full-screen.js +1 -0
  36. package/src/rich-text-editor/actions/html-editor.d.ts +2 -0
  37. package/src/rich-text-editor/actions/html-editor.js +88 -4
  38. package/src/rich-text-editor/actions/keyboard.js +3 -1
  39. package/src/rich-text-editor/actions/paste-clean-up.d.ts +1 -0
  40. package/src/rich-text-editor/actions/paste-clean-up.js +32 -4
  41. package/src/rich-text-editor/actions/toolbar.d.ts +2 -1
  42. package/src/rich-text-editor/base/constant.d.ts +30 -0
  43. package/src/rich-text-editor/base/constant.js +199 -0
  44. package/src/rich-text-editor/base/interface.d.ts +7 -1
  45. package/src/rich-text-editor/base/rich-text-editor.d.ts +1 -0
  46. package/src/rich-text-editor/base/rich-text-editor.js +33 -61
  47. package/src/rich-text-editor/base/util.d.ts +4 -0
  48. package/src/rich-text-editor/base/util.js +35 -1
  49. package/src/rich-text-editor/formatter/formatter.js +15 -4
  50. package/src/rich-text-editor/models/default-locale.js +12 -12
  51. package/src/rich-text-editor/models/items.js +2 -2
  52. package/src/rich-text-editor/renderer/audio-module.d.ts +1 -0
  53. package/src/rich-text-editor/renderer/audio-module.js +13 -0
  54. package/src/rich-text-editor/renderer/dialog-renderer.d.ts +2 -0
  55. package/src/rich-text-editor/renderer/dialog-renderer.js +7 -0
  56. package/src/rich-text-editor/renderer/image-module.d.ts +1 -0
  57. package/src/rich-text-editor/renderer/image-module.js +20 -2
  58. package/src/rich-text-editor/renderer/link-module.js +10 -1
  59. package/src/rich-text-editor/renderer/table-module.d.ts +2 -0
  60. package/src/rich-text-editor/renderer/table-module.js +22 -2
  61. package/src/rich-text-editor/renderer/toolbar-renderer.d.ts +1 -0
  62. package/src/rich-text-editor/renderer/toolbar-renderer.js +25 -3
  63. package/src/rich-text-editor/renderer/video-module.d.ts +1 -0
  64. package/src/rich-text-editor/renderer/video-module.js +21 -4
  65. package/src/rich-text-editor/renderer/view-source.d.ts +1 -0
  66. package/src/rich-text-editor/renderer/view-source.js +5 -0
  67. package/styles/bootstrap-dark.css +49 -12
  68. package/styles/bootstrap.css +49 -12
  69. package/styles/bootstrap4.css +49 -12
  70. package/styles/bootstrap5-dark.css +49 -12
  71. package/styles/bootstrap5.css +49 -12
  72. package/styles/fabric-dark.css +49 -12
  73. package/styles/fabric.css +49 -12
  74. package/styles/fluent-dark.css +49 -12
  75. package/styles/fluent.css +49 -12
  76. package/styles/highcontrast-light.css +49 -12
  77. package/styles/highcontrast.css +49 -12
  78. package/styles/material-dark.css +49 -12
  79. package/styles/material.css +49 -12
  80. package/styles/material3-dark.css +56 -19
  81. package/styles/material3.css +56 -19
  82. package/styles/rich-text-editor/_bootstrap-dark-definition.scss +1 -0
  83. package/styles/rich-text-editor/_bootstrap-definition.scss +1 -0
  84. package/styles/rich-text-editor/_bootstrap4-definition.scss +1 -0
  85. package/styles/rich-text-editor/_bootstrap5-definition.scss +2 -1
  86. package/styles/rich-text-editor/_fabric-dark-definition.scss +1 -0
  87. package/styles/rich-text-editor/_fabric-definition.scss +1 -0
  88. package/styles/rich-text-editor/_fluent-definition.scss +2 -1
  89. package/styles/rich-text-editor/_fusionnew-definition.scss +2 -1
  90. package/styles/rich-text-editor/_highcontrast-definition.scss +1 -0
  91. package/styles/rich-text-editor/_highcontrast-light-definition.scss +1 -0
  92. package/styles/rich-text-editor/_layout.scss +40 -5
  93. package/styles/rich-text-editor/_material-dark-definition.scss +1 -0
  94. package/styles/rich-text-editor/_material-definition.scss +1 -0
  95. package/styles/rich-text-editor/_material3-definition.scss +9 -8
  96. package/styles/rich-text-editor/_tailwind-definition.scss +2 -1
  97. package/styles/rich-text-editor/_theme.scss +9 -5
  98. package/styles/rich-text-editor/bootstrap-dark.css +49 -12
  99. package/styles/rich-text-editor/bootstrap.css +49 -12
  100. package/styles/rich-text-editor/bootstrap4.css +49 -12
  101. package/styles/rich-text-editor/bootstrap5-dark.css +49 -12
  102. package/styles/rich-text-editor/bootstrap5.css +49 -12
  103. package/styles/rich-text-editor/fabric-dark.css +49 -12
  104. package/styles/rich-text-editor/fabric.css +49 -12
  105. package/styles/rich-text-editor/fluent-dark.css +49 -12
  106. package/styles/rich-text-editor/fluent.css +49 -12
  107. package/styles/rich-text-editor/highcontrast-light.css +49 -12
  108. package/styles/rich-text-editor/highcontrast.css +49 -12
  109. package/styles/rich-text-editor/material-dark.css +49 -12
  110. package/styles/rich-text-editor/material.css +49 -12
  111. package/styles/rich-text-editor/material3-dark.css +56 -19
  112. package/styles/rich-text-editor/material3.css +56 -19
  113. package/styles/rich-text-editor/tailwind-dark.css +49 -12
  114. package/styles/rich-text-editor/tailwind.css +49 -12
  115. package/styles/tailwind-dark.css +49 -12
  116. package/styles/tailwind.css +49 -12
@@ -749,6 +749,21 @@ const hidePopup = 'hidePopup';
749
749
  * @deprecated
750
750
  */
751
751
  const cleanupResizeElements = 'cleanupResizeElements';
752
+ /**
753
+ * @hidden
754
+ * @deprecated
755
+ */
756
+ const afterKeyDown = 'afterKeyDown';
757
+ /**
758
+ * @hidden
759
+ * @deprecated
760
+ */
761
+ const updateValueOnIdle = 'updateValueOnIdle';
762
+ /**
763
+ * @hidden
764
+ * @deprecated
765
+ */
766
+ const documentClickClosedBy = 'documentClickClosedBy';
752
767
  /**
753
768
  * @hidden
754
769
  * @deprecated
@@ -766,6 +781,190 @@ canvas:empty, cite:empty, code:empty, data:empty, datalist:empty, del:empty, dfn
766
781
  ins:empty, kbd:empty, label:empty, map:empty, mark:empty, meter:empty, noscript:empty, object:empty, output:empty, picture:empty, progress:empty,
767
782
  q:empty, ruby:empty, s:empty, samp:empty, script:empty, select:empty, slot:empty, small:empty, span:empty, strong:empty, strike:empty, sub:empty, sup:empty, svg:empty,
768
783
  template:empty, textarea:empty, time:empty, u:empty, tt:empty, var:empty, wbr:empty`;
784
+ /**
785
+ * @hidden
786
+ * @deprecated
787
+ */
788
+ const supportedUnits = ['px', 'em', 'rem', 'pt', 'cm', 'mm', 'in', 'pc', 'vw', 'vh', 'vmin', 'vmax'];
789
+ /**
790
+ * @hidden
791
+ * @deprecated
792
+ */
793
+ const conversionFactors = {
794
+ 'px': {
795
+ 'px': 1,
796
+ 'em': 0.0625,
797
+ 'rem': 0.0625,
798
+ 'pt': 0.75,
799
+ 'cm': 0.0264583,
800
+ 'mm': 0.0026458,
801
+ 'in': 0.0104167,
802
+ 'pc': 0.0625,
803
+ 'vw': 0.00625,
804
+ 'vh': 0.00625,
805
+ 'vmin': 0.00625,
806
+ 'vmax': 0.00625
807
+ },
808
+ 'em': {
809
+ 'px': 16,
810
+ 'em': 1,
811
+ 'rem': 1,
812
+ 'pt': 12,
813
+ 'cm': 0.423333,
814
+ 'mm': 0.0423333,
815
+ 'in': 0.166667,
816
+ 'pc': 0.0625,
817
+ 'vw': 1,
818
+ 'vh': 1,
819
+ 'vmin': 1,
820
+ 'vmax': 1
821
+ },
822
+ 'rem': {
823
+ 'px': 16,
824
+ 'em': 1,
825
+ 'rem': 1,
826
+ 'pt': 12,
827
+ 'cm': 0.423333,
828
+ 'mm': 0.0423333,
829
+ 'in': 0.166667,
830
+ 'pc': 0.0625,
831
+ 'vw': 1,
832
+ 'vh': 1,
833
+ 'vmin': 1,
834
+ 'vmax': 1
835
+ },
836
+ 'pt': {
837
+ 'px': 1.33333,
838
+ 'em': 0.0833333,
839
+ 'rem': 0.0833333,
840
+ 'pt': 1,
841
+ 'cm': 0.0352778,
842
+ 'mm': 0.0035278,
843
+ 'in': 0.0138889,
844
+ 'pc': 0.0416667,
845
+ 'vw': 0.00416667,
846
+ 'vh': 0.00416667,
847
+ 'vmin': 0.00416667,
848
+ 'vmax': 0.00416667
849
+ },
850
+ 'cm': {
851
+ 'px': 37.7953,
852
+ 'em': 2.3622,
853
+ 'rem': 2.3622,
854
+ 'pt': 28.3465,
855
+ 'cm': 1,
856
+ 'mm': 0.1,
857
+ 'in': 0.393701,
858
+ 'pc': 0.148148,
859
+ 'vw': 0.0377953,
860
+ 'vh': 0.0377953,
861
+ 'vmin': 0.0377953,
862
+ 'vmax': 0.0377953
863
+ },
864
+ 'mm': {
865
+ 'px': 3.77953,
866
+ 'em': 0.23622,
867
+ 'rem': 0.23622,
868
+ 'pt': 2.83465,
869
+ 'cm': 10,
870
+ 'mm': 1,
871
+ 'in': 0.0393701,
872
+ 'pc': 0.0148148,
873
+ 'vw': 0.00377953,
874
+ 'vh': 0.00377953,
875
+ 'vmin': 0.00377953,
876
+ 'vmax': 0.00377953
877
+ },
878
+ 'in': {
879
+ 'px': 96,
880
+ 'em': 6,
881
+ 'rem': 6,
882
+ 'pt': 72,
883
+ 'cm': 2.54,
884
+ 'mm': 25.4,
885
+ 'in': 1,
886
+ 'pc': 0.375,
887
+ 'vw': 0.09375,
888
+ 'vh': 0.09375,
889
+ 'vmin': 0.09375,
890
+ 'vmax': 0.09375
891
+ },
892
+ 'pc': {
893
+ 'px': 16,
894
+ 'em': 1,
895
+ 'rem': 1,
896
+ 'pt': 12,
897
+ 'cm': 0.423333,
898
+ 'mm': 0.0423333,
899
+ 'in': 0.166667,
900
+ 'pc': 1,
901
+ 'vw': 0.0625,
902
+ 'vh': 0.0625,
903
+ 'vmin': 0.0625,
904
+ 'vmax': 0.0625
905
+ },
906
+ 'vw': {
907
+ 'px': 160,
908
+ 'em': 10,
909
+ 'rem': 10,
910
+ 'pt': 120,
911
+ 'cm': 4.23333,
912
+ 'mm': 0.423333,
913
+ 'in': 1.66667,
914
+ 'pc': 0.625,
915
+ 'vw': 1,
916
+ 'vh': 1,
917
+ 'vmin': 1,
918
+ 'vmax': 1
919
+ },
920
+ 'vh': {
921
+ 'px': 160,
922
+ 'em': 10,
923
+ 'rem': 10,
924
+ 'pt': 120,
925
+ 'cm': 4.23333,
926
+ 'mm': 0.423333,
927
+ 'in': 1.66667,
928
+ 'pc': 0.625,
929
+ 'vw': 1,
930
+ 'vh': 1,
931
+ 'vmin': 1,
932
+ 'vmax': 1
933
+ },
934
+ 'vmin': {
935
+ 'px': 160,
936
+ 'em': 10,
937
+ 'rem': 10,
938
+ 'pt': 120,
939
+ 'cm': 4.23333,
940
+ 'mm': 0.423333,
941
+ 'in': 1.66667,
942
+ 'pc': 0.625,
943
+ 'vw': 1,
944
+ 'vh': 1,
945
+ 'vmin': 1,
946
+ 'vmax': 1
947
+ },
948
+ 'vmax': {
949
+ 'px': 160,
950
+ 'em': 10,
951
+ 'rem': 10,
952
+ 'pt': 120,
953
+ 'cm': 4.23333,
954
+ 'mm': 0.423333,
955
+ 'in': 1.66667,
956
+ 'pc': 0.625,
957
+ 'vw': 1,
958
+ 'vh': 1,
959
+ 'vmin': 1,
960
+ 'vmax': 1
961
+ }
962
+ };
963
+ /**
964
+ * @hidden
965
+ * @deprecated
966
+ */
967
+ const onHandleFontsizeChange = 'onHandleFontsizeChange';
769
968
 
770
969
  /**
771
970
  * Rich Text Editor classes defined here.
@@ -1904,14 +2103,14 @@ let tools = {
1904
2103
  'sourcecode': {
1905
2104
  'id': 'SourceCode',
1906
2105
  'icon': 'e-source-code',
1907
- 'tooltip': 'Source Code',
2106
+ 'tooltip': 'Code View (Ctrl+Shift+H)',
1908
2107
  'command': 'SourceCode',
1909
2108
  'subCommand': 'SourceCode'
1910
2109
  },
1911
2110
  'preview': {
1912
2111
  'id': 'Preview',
1913
2112
  'icon': 'e-preview',
1914
- 'tooltip': 'Preview',
2113
+ 'tooltip': 'Preview (Ctrl+Shift+H)',
1915
2114
  'command': 'Preview',
1916
2115
  'subCommand': 'Preview'
1917
2116
  },
@@ -2473,7 +2672,7 @@ let defaultLocale = {
2473
2672
  'remove': 'Remove',
2474
2673
  'insertLink': 'Insert Link',
2475
2674
  'display': 'Display',
2476
- 'altText': 'Alternative Text',
2675
+ 'altText': 'Alternative text',
2477
2676
  'dimension': 'Change Size',
2478
2677
  'fullscreen': 'Maximize',
2479
2678
  'maximize': 'Maximize',
@@ -2486,12 +2685,12 @@ let defaultLocale = {
2486
2685
  'preview': 'Preview',
2487
2686
  'viewside': 'ViewSide',
2488
2687
  'insertCode': 'Insert Code',
2489
- 'linkText': 'Display Text',
2688
+ 'linkText': 'Display text',
2490
2689
  'linkTooltipLabel': 'Title',
2491
- 'linkWebUrl': 'Web Address',
2690
+ 'linkWebUrl': 'Web address',
2492
2691
  'linkTitle': 'Enter a title',
2493
2692
  'linkurl': 'http://example.com',
2494
- 'linkOpenInNewWindow': 'Open Link in New Window',
2693
+ 'linkOpenInNewWindow': 'Open link in new window',
2495
2694
  'linkHeader': 'Insert Link',
2496
2695
  'dialogInsert': 'Insert',
2497
2696
  'dialogCancel': 'Cancel',
@@ -2525,8 +2724,8 @@ let defaultLocale = {
2525
2724
  'imageWidth': 'Width',
2526
2725
  'videoHeight': 'Height',
2527
2726
  'videoWidth': 'Width',
2528
- 'textPlaceholder': 'Enter Text',
2529
- 'inserttablebtn': 'Insert Table',
2727
+ 'textPlaceholder': 'Enter text',
2728
+ 'inserttablebtn': 'Insert table',
2530
2729
  'tabledialogHeader': 'Insert Table',
2531
2730
  'tableWidth': 'Width',
2532
2731
  'cellpadding': 'Cell Padding',
@@ -2536,7 +2735,7 @@ let defaultLocale = {
2536
2735
  'tableRows': 'Table Rows',
2537
2736
  'tableColumns': 'Table Columns',
2538
2737
  'tableCellHorizontalAlign': 'Table Cell Horizontal Align',
2539
- 'tableCellVerticalAlign': 'Table Cell Vertical Align',
2738
+ 'tableCellVerticalAlign': 'Table Vertical Align',
2540
2739
  'createTable': 'Create Table',
2541
2740
  'removeTable': 'Remove Table',
2542
2741
  'tableHeader': 'Table Header',
@@ -2614,8 +2813,8 @@ let defaultLocale = {
2614
2813
  'bulletFormatListNone': 'None',
2615
2814
  'formatPainter': 'Format Painter',
2616
2815
  'emojiPicker': 'Emoji Picker',
2617
- 'embeddedCode': 'Embedded Code',
2618
- 'pasteEmbeddedCodeHere': 'Paste Embedded Code here',
2816
+ 'embeddedCode': 'Embedded code',
2817
+ 'pasteEmbeddedCodeHere': 'Paste embedded code here',
2619
2818
  'emojiPickerTypeToFind': 'Type to find',
2620
2819
  'emojiPickerNoResultFound': 'No results found',
2621
2820
  'emojiPickerTrySomethingElse': 'Try something else',
@@ -2675,7 +2874,7 @@ let toolsLocale = {
2675
2874
  'remove': 'remove',
2676
2875
  'insertlink': 'insertLink',
2677
2876
  'display': 'display',
2678
- 'alttext': 'altText',
2877
+ 'alttext': 'alternateHeader',
2679
2878
  'dimension': 'dimension',
2680
2879
  'fullscreen': 'fullscreen',
2681
2880
  'maximize': 'maximize',
@@ -2710,8 +2909,8 @@ let toolsLocale = {
2710
2909
  'deleterow': 'deleteRow',
2711
2910
  'formatpainter': 'formatPainter',
2712
2911
  'emojipicker': 'emojiPicker',
2713
- 'embeddedCode': 'Embedded Code',
2714
- 'pasteEmbeddedCodeHere': 'Paste Embedded Code here',
2912
+ 'embeddedCode': 'Embedded code',
2913
+ 'pasteEmbeddedCodeHere': 'Paste embedded code here',
2715
2914
  'emojiPickerTypeToFind': 'Type to find',
2716
2915
  'emojiPickerNoResultFound': 'No results found',
2717
2916
  'emojiPickerTrySomethingElse': 'Try something else',
@@ -2881,6 +3080,40 @@ function getTooltipText(item, serviceLocator) {
2881
3080
  const tooltipText = i10n.getConstant(itemLocale);
2882
3081
  return tooltipText;
2883
3082
  }
3083
+ function getTooltipTextDropdownItems(item, serviceLocator, localeItems, rteObj) {
3084
+ if (localeItems) {
3085
+ const i10n = serviceLocator.getService('rteLocale');
3086
+ for (let i = 0; i < localeItems.length; i++) {
3087
+ const itemLocale = localeItems[i].value.toLocaleLowerCase();
3088
+ const numberValue = localeItems[i].locale;
3089
+ const numberLocale = defaultLocale[`${numberValue}`].toLocaleLowerCase();
3090
+ if (item === itemLocale || item === numberLocale) {
3091
+ const tooltipText = localeItems[i].locale;
3092
+ return i10n.getConstant(tooltipText);
3093
+ }
3094
+ }
3095
+ }
3096
+ else {
3097
+ const fontsize = rteObj.fontSize.items;
3098
+ for (let i = 0; i < fontsize.length; i++) {
3099
+ if (item === rteObj.fontSize.items[i].value) {
3100
+ const fontSize$$1 = rteObj.fontSize.items[i].text;
3101
+ return fontSize$$1;
3102
+ }
3103
+ }
3104
+ }
3105
+ return '';
3106
+ }
3107
+ function getQuickToolbarTooltipText(item) {
3108
+ const keys = Object.keys(defaultLocale);
3109
+ for (let i = 0; i < keys.length; i++) {
3110
+ const tooltipText = defaultLocale[`${keys[i]}`];
3111
+ if (item === tooltipText) {
3112
+ return tooltipText;
3113
+ }
3114
+ }
3115
+ return '';
3116
+ }
2884
3117
  /**
2885
3118
  * @param {ISetToolbarStatusArgs} e - specifies the e element
2886
3119
  * @param {boolean} isPopToolbar - specifies the boolean value
@@ -3395,6 +3628,7 @@ class ToolbarRenderer {
3395
3628
  }
3396
3629
  dropDownSelected(args) {
3397
3630
  this.parent.notify(dropDownSelect, args);
3631
+ this.destroyTooltip();
3398
3632
  }
3399
3633
  beforeDropDownItemRender(args) {
3400
3634
  if (this.parent.readonly || !this.parent.enabled) {
@@ -3422,12 +3656,18 @@ class ToolbarRenderer {
3422
3656
  if (args.element.parentElement.getAttribute('id').indexOf('TableCell') > -1 && !isNullOrUndefined(args.element.parentElement.querySelector('.e-cell-merge')) &&
3423
3657
  (!isNullOrUndefined(args.element.parentElement.querySelector('.e-cell-horizontal-split')) || !isNullOrUndefined(args.element.parentElement.querySelector('.e-cell-vertical-split')))) {
3424
3658
  const listEle = args.element.querySelectorAll('li');
3425
- if (this.parent.inputElement.querySelectorAll('.e-cell-select').length === 1) {
3659
+ const selectedEles = this.parent.inputElement.querySelectorAll('.e-cell-select');
3660
+ if (selectedEles.length === 1) {
3426
3661
  addClass([listEle[0]], 'e-disabled');
3427
3662
  removeClass([listEle[1], listEle[2]], 'e-disabled');
3428
3663
  }
3429
- else if (this.parent.inputElement.querySelectorAll('.e-cell-select').length > 1) {
3430
- removeClass([listEle[0]], 'e-disabled');
3664
+ else if (selectedEles.length > 1) {
3665
+ if (!Array.from(selectedEles).every((element) => element.tagName.toLowerCase() === selectedEles[0].tagName.toLowerCase())) {
3666
+ addClass([listEle[0]], 'e-disabled');
3667
+ }
3668
+ else {
3669
+ removeClass([listEle[0]], 'e-disabled');
3670
+ }
3431
3671
  addClass([listEle[1], listEle[2]], 'e-disabled');
3432
3672
  }
3433
3673
  }
@@ -3475,6 +3715,19 @@ class ToolbarRenderer {
3475
3715
  });
3476
3716
  this.tooltip.appendTo(args.target);
3477
3717
  }
3718
+ if (this.parent.showTooltip) {
3719
+ this.dropdownTooltip = new Tooltip({
3720
+ target: '[aria-owns="' + this.parent.getID() + '"].e-rte-elements [title]',
3721
+ showTipPointer: true,
3722
+ openDelay: 400,
3723
+ opensOn: 'Hover',
3724
+ beforeRender: this.tooltipBeforeRender.bind(this),
3725
+ cssClass: this.parent.getCssClass(),
3726
+ windowCollision: true,
3727
+ position: 'BottomCenter'
3728
+ });
3729
+ this.dropdownTooltip.appendTo(document.body);
3730
+ }
3478
3731
  }
3479
3732
  /**
3480
3733
  * renderDropDownButton method
@@ -4087,10 +4340,14 @@ class BaseToolbar {
4087
4340
  this.parent.formatter.saveData();
4088
4341
  }
4089
4342
  callback.call(this);
4090
- const currentContentElem = this.parent.createElement('div');
4091
- currentContentElem.appendChild(this.parent.formatter.getUndoRedoStack()[this.parent.formatter.getUndoRedoStack().length - 1].text);
4092
- if (currentContentElem.innerHTML.trim() === this.parent.inputElement.innerHTML.trim()) {
4093
- return;
4343
+ if (this.parent.formatter.getUndoRedoStack().length > 0) {
4344
+ const currentContentElem = this.parent.createElement('div');
4345
+ let stackItem = this.parent.formatter.getUndoRedoStack()[this.parent.formatter.getUndoRedoStack().length - 1];
4346
+ let clonedItem = (stackItem.text).cloneNode(true);
4347
+ currentContentElem.appendChild(clonedItem);
4348
+ if (currentContentElem.innerHTML.trim() === this.parent.inputElement.innerHTML.trim()) {
4349
+ return;
4350
+ }
4094
4351
  }
4095
4352
  if (proxy.undo) {
4096
4353
  this.parent.formatter.saveData();
@@ -4158,10 +4415,28 @@ class DropDownButtons {
4158
4415
  if (item.cssClass) {
4159
4416
  addClass([args.element], item.cssClass);
4160
4417
  }
4418
+ if (item.command === 'Images' || item.command === 'Videos' || item.command === 'Audios' || item.command === 'Table') {
4419
+ args.element.setAttribute('title', getQuickToolbarTooltipText(item.text));
4420
+ }
4161
4421
  if (item.command === 'Alignments' || item.subCommand === 'JustifyLeft'
4162
4422
  || item.subCommand === 'JustifyRight' || item.subCommand === 'JustifyCenter') {
4163
4423
  args.element.setAttribute('title', getTooltipText(item.subCommand.toLocaleLowerCase(), this.locator));
4164
4424
  }
4425
+ if (item.command === 'Formats') {
4426
+ args.element.setAttribute('title', getTooltipTextDropdownItems(item.subCommand.toLocaleLowerCase(), this.locator, formatsLocale));
4427
+ }
4428
+ if (item.command === 'Font') {
4429
+ args.element.setAttribute('title', getTooltipTextDropdownItems(item.value.toLocaleLowerCase(), this.locator, fontNameLocale));
4430
+ }
4431
+ if (item.subCommand === 'BulletFormatList') {
4432
+ args.element.setAttribute('title', getTooltipTextDropdownItems(item.value.toLocaleLowerCase(), this.locator, bulletFormatListLocale));
4433
+ }
4434
+ if (item.subCommand === 'NumberFormatList') {
4435
+ args.element.setAttribute('title', getTooltipTextDropdownItems(item.text.replace(/\s/g, '').toLocaleLowerCase(), this.locator, numberFormatListLocale));
4436
+ }
4437
+ if (item.subCommand === 'FontSize') {
4438
+ args.element.setAttribute('title', getTooltipTextDropdownItems(item.value.toLocaleLowerCase(), null, null, this.parent));
4439
+ }
4165
4440
  }
4166
4441
  dropdownContent(width, type, content) {
4167
4442
  return ('<span style="display: inline-flex;' + 'width:' + ((type === 'quick') ? 'auto' : width) + '" >' +
@@ -4267,7 +4542,7 @@ class DropDownButtons {
4267
4542
  if (isNullOrUndefined(targetElement) || targetElement.classList.contains(CLS_DROPDOWN_BTN)) {
4268
4543
  return;
4269
4544
  }
4270
- const fontsize = this.parent.fontSize.items.slice();
4545
+ const fontsize = !isNullOrUndefined(this.fontSizeDropDown) && !isNullOrUndefined(this.fontSizeDropDown.items) && this.fontSizeDropDown.items.length > 0 ? this.fontSizeDropDown.items : JSON.parse(JSON.stringify(this.parent.fontSize.items.slice()));
4271
4546
  fontsize.forEach((item) => {
4272
4547
  Object.defineProperties(item, {
4273
4548
  command: { value: 'Font', enumerable: true }, subCommand: { value: 'FontSize', enumerable: true }
@@ -5581,7 +5856,9 @@ const keyCode = {
5581
5856
  'singlequote': 222,
5582
5857
  ']': 221,
5583
5858
  '[': 219,
5584
- '=': 187
5859
+ '=': 187,
5860
+ '<': 188,
5861
+ '>': 190
5585
5862
  };
5586
5863
  /**
5587
5864
  * KeyboardEvents class enables you to bind key action desired key combinations for ex., Ctrl+A, Delete, Alt+Space etc.
@@ -6284,6 +6561,9 @@ class BaseQuickToolbar {
6284
6561
  this.parent.enableToolbarItem(this.parent.toolbarSettings.items);
6285
6562
  }
6286
6563
  }
6564
+ if (this.parent.showTooltip && !isNullOrUndefined(document.querySelector('.e-tooltip-wrap'))) {
6565
+ this.parent.notify(destroyTooltip, { args: event });
6566
+ }
6287
6567
  this.removeEleFromDOM();
6288
6568
  this.isDOMElement = false;
6289
6569
  }
@@ -7104,7 +7384,7 @@ class Count {
7104
7384
  }
7105
7385
  appendCount() {
7106
7386
  const htmlText = this.parent.editorMode === 'Markdown' ? this.editPanel.value :
7107
- this.editPanel.textContent;
7387
+ (this.parent.getText().replace(/(\r\n|\n|\r|\t)/gm, ''));
7108
7388
  if (this.parent.editorMode !== 'Markdown' && htmlText.indexOf('\u200B') !== -1) {
7109
7389
  this.htmlLength = htmlText.replace(/\u200B/g, '').length;
7110
7390
  }
@@ -7494,30 +7774,41 @@ function updateTextNode$1(value, enterAction) {
7494
7774
  }
7495
7775
  const tableElm = resultElm.querySelectorAll('table');
7496
7776
  for (let i = 0; i < tableElm.length; i++) {
7497
- if (tableElm[i].getAttribute('border') === '0') {
7498
- tableElm[i].removeAttribute('border');
7499
- }
7500
- const tdElm = tableElm[i].querySelectorAll('td');
7501
- for (let j = 0; j < tdElm.length; j++) {
7502
- if (tdElm[j].style.borderLeft === 'none') {
7503
- tdElm[j].style.removeProperty('border-left');
7504
- }
7505
- if (tdElm[j].style.borderRight === 'none') {
7506
- tdElm[j].style.removeProperty('border-right');
7507
- }
7508
- if (tdElm[j].style.borderBottom === 'none') {
7509
- tdElm[j].style.removeProperty('border-bottom');
7510
- }
7511
- if (tdElm[j].style.borderTop === 'none') {
7512
- tdElm[j].style.removeProperty('border-top');
7777
+ if (tableElm[i].classList.length > 0 && !tableElm[i].classList.contains('e-rte-table')) {
7778
+ tableElm[i].classList.add('e-rte-paste-table');
7779
+ if (tableElm[i].classList.contains('e-rte-paste-word-table')) {
7780
+ tableElm[i].classList.remove('e-rte-paste-word-table');
7781
+ continue; // Sking the removal of the border if the source is from word.
7782
+ }
7783
+ else if (tableElm[i].classList.contains('e-rte-paste-excel-table')) {
7784
+ tableElm[i].classList.remove('e-rte-paste-excel-table');
7785
+ if (tableElm[i].getAttribute('border') === '0') {
7786
+ tableElm[i].removeAttribute('border');
7787
+ }
7788
+ const tdElm = tableElm[i].querySelectorAll('td');
7789
+ for (let j = 0; j < tdElm.length; j++) {
7790
+ if (tdElm[j].style.borderLeft === 'none') {
7791
+ tdElm[j].style.removeProperty('border-left');
7792
+ }
7793
+ if (tdElm[j].style.borderRight === 'none') {
7794
+ tdElm[j].style.removeProperty('border-right');
7795
+ }
7796
+ if (tdElm[j].style.borderBottom === 'none') {
7797
+ tdElm[j].style.removeProperty('border-bottom');
7798
+ }
7799
+ if (tdElm[j].style.borderTop === 'none') {
7800
+ tdElm[j].style.removeProperty('border-top');
7801
+ }
7802
+ if (tdElm[j].style.border === 'none') {
7803
+ tdElm[j].style.removeProperty('border');
7804
+ }
7805
+ }
7513
7806
  }
7514
- if (tdElm[j].style.border === 'none') {
7515
- tdElm[j].style.removeProperty('border');
7807
+ else if (tableElm[i].classList.contains('e-rte-paste-onenote-table')) {
7808
+ tableElm[i].classList.remove('e-rte-paste-onenote-table');
7809
+ continue;
7516
7810
  }
7517
7811
  }
7518
- if (!tableElm[i].classList.contains('e-rte-table')) {
7519
- tableElm[i].classList.add('e-rte-table');
7520
- }
7521
7812
  }
7522
7813
  const imageElm = resultElm.querySelectorAll('img');
7523
7814
  for (let i = 0; i < imageElm.length; i++) {
@@ -7833,6 +8124,12 @@ const FORMAT_PAINTER_ACTIONS = 'format_painter_actions';
7833
8124
  * @hidden
7834
8125
  */
7835
8126
  const EMOJI_PICKER_ACTIONS = 'emoji_picker_actions';
8127
+ /**
8128
+ * Mouse down event constant
8129
+ *
8130
+ * @hidden
8131
+ */
8132
+ const MOUSE_DOWN = 'mouseDown';
7836
8133
 
7837
8134
  /**
7838
8135
  * Formatter
@@ -7856,12 +8153,21 @@ class Formatter {
7856
8153
  const selection = self.contentModule.getDocument().getSelection();
7857
8154
  const range = (selection.rangeCount > 0) ? selection.getRangeAt(selection.rangeCount - 1) : null;
7858
8155
  let saveSelection;
8156
+ let newRange;
8157
+ if (!isNullOrUndefined(value) && !isNullOrUndefined(value.selection)) {
8158
+ newRange = value.selection.range;
8159
+ }
7859
8160
  const isKeyboardVideoInsert = (!isNullOrUndefined(value) && !isNullOrUndefined(value.cssClass) &&
7860
8161
  value.cssClass !== 'e-video-inline');
7861
8162
  if (self.editorMode === 'HTML') {
7862
8163
  if (!isNullOrUndefined(args) && !isKeyboardVideoInsert) {
7863
8164
  if (isNullOrUndefined(args.name) || (!isNullOrUndefined(args.name) && args.name !== 'showDialog')) {
7864
- saveSelection = this.editorManager.nodeSelection.save(range, self.contentModule.getDocument());
8165
+ if (newRange) {
8166
+ saveSelection = this.editorManager.nodeSelection.save(newRange, self.contentModule.getDocument());
8167
+ }
8168
+ else {
8169
+ saveSelection = this.editorManager.nodeSelection.save(range, self.contentModule.getDocument());
8170
+ }
7865
8171
  }
7866
8172
  }
7867
8173
  }
@@ -7889,7 +8195,7 @@ class Formatter {
7889
8195
  if (args.item.command === 'Images' || args.item.command === 'Videos' || args.item.command === 'Table' || args.item.command === 'Files') {
7890
8196
  currentInsertContentLength = 1;
7891
8197
  }
7892
- const currentLength = self.getText().trim().replace(/(\r\n|\n|\r)/gm, '').replace(/\u200B/g, '').length;
8198
+ const currentLength = self.getText().trim().replace(/(\r\n|\n|\r|\t)/gm, '').replace(/\u200B/g, '').length;
7893
8199
  const selectionLength = self.getSelection().length;
7894
8200
  const totalLength = (currentLength - selectionLength) + currentInsertContentLength;
7895
8201
  if (!(self.maxLength === -1 || totalLength <= self.maxLength)) {
@@ -7953,7 +8259,9 @@ class Formatter {
7953
8259
  this.saveData();
7954
8260
  }
7955
8261
  self.isBlur = false;
7956
- self.contentModule.getEditPanel().focus();
8262
+ if (isNullOrUndefined(saveSelection) || isNullOrUndefined(closest(saveSelection.range.startContainer.parentElement, ".e-img-caption")) ? true : !(closest(saveSelection.range.startContainer.parentElement, ".e-img-caption").getAttribute("contenteditable") == "false")) {
8263
+ self.contentModule.getEditPanel().focus();
8264
+ }
7957
8265
  if (self.editorMode === 'HTML' && !isKeyboardVideoInsert) {
7958
8266
  if (isNullOrUndefined(args.selectType) || (!isNullOrUndefined(args.selectType) && args.selectType !== 'showDialog')) {
7959
8267
  saveSelection.restore();
@@ -10417,6 +10725,12 @@ const CLEAR_TYPE = 'clear-type';
10417
10725
  * @hidden
10418
10726
  */
10419
10727
  const SELF_CLOSING_TAGS = ['area', 'base', 'br', 'embed', 'hr', 'img', 'input', 'param', 'source', 'track', 'wbr', 'iframe', 'td', 'table'];
10728
+ /**
10729
+ * Source
10730
+ *
10731
+ * @hidden
10732
+ */
10733
+ const PASTE_SOURCE = ['word', 'excel', 'onenote'];
10420
10734
 
10421
10735
  /**
10422
10736
  * `Selection` module is used to handle RTE Selections.
@@ -11430,7 +11744,9 @@ class DOMNode {
11430
11744
  else if (start.tagName === 'BR') {
11431
11745
  this.replaceWith(start, this.marker(className, this.encode(start.textContent)));
11432
11746
  const markerStart = range.startContainer.querySelector('.' + className);
11433
- markerStart.parentElement.appendChild(start);
11747
+ if (markerStart) {
11748
+ markerStart.parentElement.appendChild(start);
11749
+ }
11434
11750
  }
11435
11751
  else {
11436
11752
  if (start.tagName === 'IMG') {
@@ -15063,7 +15379,6 @@ class TableCommand {
15063
15379
  table.appendChild(tblBody);
15064
15380
  e.item.selection.restore();
15065
15381
  InsertHtml.Insert(this.parent.currentDocument, table, this.parent.editableElement);
15066
- this.removeEmptyNode();
15067
15382
  e.item.selection.setSelectionText(this.parent.currentDocument, table.querySelector('td'), table.querySelector('td'), 0, 0);
15068
15383
  if (table.nextElementSibling === null) {
15069
15384
  let insertElem;
@@ -15107,24 +15422,6 @@ class TableCommand {
15107
15422
  }
15108
15423
  return styleValue;
15109
15424
  }
15110
- removeEmptyNode() {
15111
- const emptyUl = this.parent.editableElement.querySelectorAll('ul:empty, ol:empty');
15112
- for (let i = 0; i < emptyUl.length; i++) {
15113
- detach(emptyUl[i]);
15114
- }
15115
- let emptyLiChild = this.parent.editableElement.querySelectorAll('li *:empty:not(img)');
15116
- for (let i = 0; i < emptyLiChild.length; i++) {
15117
- detach(emptyLiChild[i]);
15118
- if (emptyLiChild.length === i + 1) {
15119
- emptyLiChild = this.parent.editableElement.querySelectorAll('li *:empty:not(img)');
15120
- i = -1;
15121
- }
15122
- }
15123
- const emptyLi = this.parent.editableElement.querySelectorAll('li:empty');
15124
- for (let i = 0; i < emptyLi.length; i++) {
15125
- detach(emptyLi[i]);
15126
- }
15127
- }
15128
15425
  insertAfter(newNode, referenceNode) {
15129
15426
  referenceNode.parentNode.insertBefore(newNode, referenceNode.nextSibling);
15130
15427
  }
@@ -15472,14 +15769,21 @@ class TableCommand {
15472
15769
  }
15473
15770
  }
15474
15771
  tableVerticalAlign(e) {
15475
- if (e.item.subCommand === 'AlignTop') {
15476
- e.item.tableCell.style.verticalAlign = 'top';
15772
+ let value = '';
15773
+ switch (e.item.subCommand) {
15774
+ case 'AlignTop':
15775
+ value = 'top';
15776
+ break;
15777
+ case 'AlignMiddle':
15778
+ value = 'middle';
15779
+ break;
15780
+ case 'AlignBottom':
15781
+ value = 'bottom';
15782
+ break;
15477
15783
  }
15478
- else if (e.item.subCommand === 'AlignMiddle') {
15479
- e.item.tableCell.style.verticalAlign = 'middle';
15480
- }
15481
- else {
15482
- e.item.tableCell.style.verticalAlign = 'bottom';
15784
+ e.item.tableCell.style.verticalAlign = value;
15785
+ if (value && value !== '' && e.item.tableCell.getAttribute('valign')) {
15786
+ e.item.tableCell.removeAttribute('valign');
15483
15787
  }
15484
15788
  if (e.callBack) {
15485
15789
  e.callBack({
@@ -16228,6 +16532,22 @@ class SelectionCommands {
16228
16532
  const nodeCutter = new NodeCutter();
16229
16533
  const isFormatted = new IsFormatted();
16230
16534
  let range = domSelection.getRange(docElement);
16535
+ if (Browser.userAgent.indexOf('Firefox') !== -1 && range.startContainer === range.endContainer && !isNullOrUndefined(endNode) && range.startContainer === endNode) {
16536
+ const startChildNodes = range.startContainer.childNodes;
16537
+ const startNode = ((startChildNodes[(range.startOffset > 0) ? (range.startOffset - 1) :
16538
+ range.startOffset]) || range.startContainer);
16539
+ const endNode = (range.endContainer.childNodes[(range.endOffset > 0) ? (range.endOffset - 1) :
16540
+ range.endOffset] || range.endContainer);
16541
+ let lastSelectionNode = (endNode.lastChild.nodeName === 'BR' ? (isNullOrUndefined(endNode.lastChild.previousSibling) ? endNode
16542
+ : endNode.lastChild.previousSibling) : endNode.firstChild);
16543
+ while (!isNullOrUndefined(lastSelectionNode) && lastSelectionNode.nodeName !== '#text' && lastSelectionNode.nodeName !== 'IMG' &&
16544
+ lastSelectionNode.nodeName !== 'BR' && lastSelectionNode.nodeName !== 'HR') {
16545
+ lastSelectionNode = lastSelectionNode.lastChild;
16546
+ }
16547
+
16548
+ domSelection.setSelectionText(docElement, startNode, lastSelectionNode, 0, 0);
16549
+ range = domSelection.getRange(docElement);
16550
+ }
16231
16551
  const save = domSelection.save(range, docElement);
16232
16552
  const nodes = range.collapsed ? domSelection.getSelectionNodeCollection(range) :
16233
16553
  domSelection.getSelectionNodeCollectionBr(range);
@@ -17447,6 +17767,25 @@ class UndoRedoManager {
17447
17767
  }
17448
17768
  return textContent;
17449
17769
  }
17770
+ isElementStructureEqual(previousFragment, currentFragment) {
17771
+ if (previousFragment.childNodes.length !== currentFragment.childNodes.length) {
17772
+ return false;
17773
+ }
17774
+ for (let i = 0; i < previousFragment.childNodes.length; i++) {
17775
+ const previousFragmentNode = previousFragment.childNodes[i];
17776
+ const currentFragmentNode = currentFragment.childNodes[i];
17777
+ if (!previousFragmentNode || !currentFragmentNode) {
17778
+ return false;
17779
+ }
17780
+ if (previousFragmentNode.nodeType !== currentFragmentNode.nodeType) {
17781
+ return false;
17782
+ }
17783
+ if (previousFragmentNode.outerHTML !== currentFragmentNode.outerHTML) {
17784
+ return false;
17785
+ }
17786
+ }
17787
+ return true;
17788
+ }
17450
17789
  /**
17451
17790
  * RTE collection stored html format.
17452
17791
  *
@@ -17483,7 +17822,8 @@ class UndoRedoManager {
17483
17822
  (this.undoRedoStack[this.undoRedoStack.length - 1].range.endOffset === save.range.endOffset) &&
17484
17823
  (this.undoRedoStack[this.undoRedoStack.length - 1].range.range.startContainer === save.range.startContainer) &&
17485
17824
  (this.getTextContentFromFragment(this.undoRedoStack[this.undoRedoStack.length - 1].text).trim() ===
17486
- this.getTextContentFromFragment(changEle.text).trim())) {
17825
+ this.getTextContentFromFragment(changEle.text).trim()) &&
17826
+ this.isElementStructureEqual(this.undoRedoStack[this.undoRedoStack.length - 1].text, changEle.text)) {
17487
17827
  return;
17488
17828
  }
17489
17829
  this.undoRedoStack.push(changEle);
@@ -17645,6 +17985,7 @@ class MsWordPaste {
17645
17985
  const pattern4 = /style='mso-width-source:/i;
17646
17986
  if (patern.test(tempHTMLContent) || patern2.test(tempHTMLContent) || patern3.test(tempHTMLContent) ||
17647
17987
  pattern4.test(tempHTMLContent)) {
17988
+ const source = this.findSource(elm);
17648
17989
  this.imageConversion(elm, rtfData);
17649
17990
  tempHTMLContent = tempHTMLContent.replace(/<img[^>]+>/i, '');
17650
17991
  this.addListClass(elm);
@@ -17665,16 +18006,8 @@ class MsWordPaste {
17665
18006
  if (pattern4.test(tempHTMLContent)) {
17666
18007
  this.addTableBorderClass(elm);
17667
18008
  }
17668
- // Removing the margin for list items
17669
- const liChildren = elm.querySelectorAll('li');
17670
- if (liChildren.length > 0) {
17671
- for (let i = 0; i < liChildren.length; i++) {
17672
- if (!isNullOrUndefined(liChildren[i].style.marginLeft)) {
17673
- liChildren[i].style.marginLeft = '';
17674
- }
17675
- }
17676
- }
17677
- e.callBack(elm.innerHTML, this.cropImageDimensions);
18009
+ this.processMargin(elm);
18010
+ e.callBack(elm.innerHTML, this.cropImageDimensions, source);
17678
18011
  }
17679
18012
  else {
17680
18013
  e.callBack(elm.innerHTML);
@@ -18508,6 +18841,25 @@ class MsWordPaste {
18508
18841
  }
18509
18842
  this.listContents.push(elem.innerHTML);
18510
18843
  }
18844
+ processMargin(element) {
18845
+ const liChildren = element.querySelectorAll('li');
18846
+ if (liChildren.length > 0) {
18847
+ for (let i = 0; i < liChildren.length; i++) {
18848
+ if (!isNullOrUndefined((liChildren[i]).style.marginLeft)) {
18849
+ (liChildren[i]).style.marginLeft = '';
18850
+ }
18851
+ }
18852
+ }
18853
+ const tableChildren = element.querySelectorAll('table');
18854
+ if (tableChildren.length > 0) {
18855
+ for (let i = 0; i < tableChildren.length; i++) {
18856
+ if (!isNullOrUndefined((tableChildren[i]).style.marginLeft) &&
18857
+ (tableChildren[i]).style.marginLeft.indexOf('-') >= 0) {
18858
+ (tableChildren[i]).style.marginLeft = '';
18859
+ }
18860
+ }
18861
+ }
18862
+ }
18511
18863
  removeEmptyAnchorTag(element) {
18512
18864
  const removableElement = element.querySelectorAll('a:not([href])');
18513
18865
  for (let j = removableElement.length - 1; j >= 0; j--) {
@@ -18518,6 +18870,22 @@ class MsWordPaste {
18518
18870
  parentElem.removeChild(removableElement[j]);
18519
18871
  }
18520
18872
  }
18873
+ findSource(element) {
18874
+ const metaNodes = element.querySelectorAll('meta');
18875
+ for (let i = 0; i < metaNodes.length; i++) {
18876
+ const metaNode = metaNodes[i];
18877
+ const content = metaNode.getAttribute('content');
18878
+ const name = metaNode.getAttribute('name');
18879
+ if (name && name.toLowerCase().indexOf('generator') >= 0 && content && content.toLowerCase().indexOf('microsoft') >= 0) {
18880
+ for (let j = 0; j < PASTE_SOURCE.length; j++) {
18881
+ if (content.toLowerCase().indexOf(PASTE_SOURCE[j]) >= 0) {
18882
+ return PASTE_SOURCE[j];
18883
+ }
18884
+ }
18885
+ }
18886
+ }
18887
+ return 'html';
18888
+ }
18521
18889
  }
18522
18890
 
18523
18891
  /**
@@ -19151,7 +19519,7 @@ class FormatPainterActions {
19151
19519
  }
19152
19520
  copyAction() {
19153
19521
  const copyCollection = [];
19154
- const range = this.parent.nodeSelection.getRange(document);
19522
+ const range = this.parent.nodeSelection.getRange(this.parent.currentDocument);
19155
19523
  const domSelection = this.parent.nodeSelection;
19156
19524
  let nodes = range.collapsed ? domSelection.getSelectionNodeCollection(range) :
19157
19525
  domSelection.getSelectionNodeCollectionBr(range);
@@ -19643,6 +20011,7 @@ class EditorManager {
19643
20011
  this.observer.on(MODEL_CHANGED, this.onPropertyChanged, this);
19644
20012
  this.observer.on(MS_WORD_CLEANUP, this.onWordPaste, this);
19645
20013
  this.observer.on(ON_BEGIN, this.onBegin, this);
20014
+ this.observer.on(MOUSE_DOWN, this.editorMouseDown, this);
19646
20015
  }
19647
20016
  onWordPaste(e) {
19648
20017
  this.observer.notify(MS_WORD_CLEANUP_PLUGIN, e);
@@ -19786,6 +20155,64 @@ class EditorManager {
19786
20155
  event: event, callBack: callBack });
19787
20156
  }
19788
20157
  }
20158
+ editorMouseDown(e) {
20159
+ if (e.args.detail === 3) {
20160
+ this.tripleClickSelection(e.args);
20161
+ }
20162
+ }
20163
+ tripleClickSelection(e) {
20164
+ const range = this.nodeSelection.getRange(this.currentDocument);
20165
+ const selection = this.nodeSelection.get(this.currentDocument);
20166
+ if (selection.rangeCount > 0 && selection.toString() !== '') {
20167
+ const startBlockNode = this.getParentBlockNode(range.startContainer);
20168
+ const endBlockNode = this.getParentBlockNode(range.endContainer);
20169
+ if (startBlockNode && endBlockNode && startBlockNode === endBlockNode) {
20170
+ const newRange = this.currentDocument.createRange();
20171
+ const startTextNode = this.getFirstTextNode(startBlockNode);
20172
+ const endTextNode = this.getLastTextNode(endBlockNode);
20173
+ if (startTextNode && endTextNode) {
20174
+ newRange.setStart(startTextNode, 0);
20175
+ newRange.setEnd(endTextNode, endTextNode.textContent.length);
20176
+ this.nodeSelection.setRange(this.currentDocument, newRange);
20177
+ e.preventDefault();
20178
+ }
20179
+ }
20180
+ }
20181
+ }
20182
+ getParentBlockNode(node) {
20183
+ let treeWalker = this.currentDocument.createTreeWalker(this.editableElement, // root
20184
+ NodeFilter.SHOW_ELEMENT, // whatToShow
20185
+ {
20186
+ acceptNode: function (currentNode) {
20187
+ // Check if the node is a block element
20188
+ let displayStyle = window.getComputedStyle(currentNode).display;
20189
+ if (displayStyle.indexOf('inline') < 0) {
20190
+ return NodeFilter.FILTER_ACCEPT;
20191
+ }
20192
+ else {
20193
+ return NodeFilter.FILTER_SKIP;
20194
+ }
20195
+ }
20196
+ });
20197
+ treeWalker.currentNode = node;
20198
+ let blockParent = treeWalker.parentNode();
20199
+ return blockParent;
20200
+ }
20201
+ getLastTextNode(node) {
20202
+ let treeWalker = this.currentDocument.createTreeWalker(node, NodeFilter.SHOW_TEXT, null);
20203
+ let lastTextNode = null;
20204
+ let currentNode = treeWalker.nextNode();
20205
+ while (currentNode) {
20206
+ lastTextNode = currentNode;
20207
+ currentNode = treeWalker.nextNode();
20208
+ }
20209
+ return lastTextNode;
20210
+ }
20211
+ getFirstTextNode(node) {
20212
+ let treeWalker = this.currentDocument.createTreeWalker(node, NodeFilter.SHOW_TEXT, null);
20213
+ let firstTextNode = treeWalker.nextNode();
20214
+ return firstTextNode;
20215
+ }
19789
20216
  }
19790
20217
 
19791
20218
  /**
@@ -20359,6 +20786,7 @@ class HtmlEditor {
20359
20786
  this.parent.on(readOnlyMode, this.updateReadOnly, this);
20360
20787
  this.parent.on(paste, this.onPaste, this);
20361
20788
  this.parent.on(tableclass, this.isTableClassAdded, this);
20789
+ this.parent.on(onHandleFontsizeChange, this.onHandleFontsizeChange, this);
20362
20790
  }
20363
20791
  updateReadOnly() {
20364
20792
  if (this.parent.readonly) {
@@ -20377,7 +20805,9 @@ class HtmlEditor {
20377
20805
  }
20378
20806
  onSelectionRestore(e) {
20379
20807
  this.parent.isBlur = false;
20380
- this.contentRenderer.getEditPanel().focus();
20808
+ if (isNullOrUndefined(this.saveSelection) || isNullOrUndefined(closest(this.saveSelection.range.startContainer.parentElement, ".e-img-caption")) ? true : !(closest(this.saveSelection.range.startContainer.parentElement, ".e-img-caption").getAttribute("contenteditable") == "false")) {
20809
+ this.contentRenderer.getEditPanel().focus();
20810
+ }
20381
20811
  if (isNullOrUndefined(e.items) || e.items) {
20382
20812
  this.saveSelection.restore();
20383
20813
  }
@@ -20385,11 +20815,85 @@ class HtmlEditor {
20385
20815
  isTableClassAdded() {
20386
20816
  const tableElement = this.parent.inputElement.querySelectorAll('table');
20387
20817
  for (let i = 0; i < tableElement.length; i++) {
20388
- if (!tableElement[i].classList.contains('e-rte-table')) {
20818
+ if (!tableElement[i].classList.contains('e-rte-table') && !tableElement[i].classList.contains('e-rte-paste-table')) {
20389
20819
  tableElement[i].classList.add('e-rte-table');
20390
20820
  }
20391
20821
  }
20392
20822
  }
20823
+ onHandleFontsizeChange(e) {
20824
+ const keyboardArgs = e.args;
20825
+ const args = { name: 'dropDownSelect' };
20826
+ args.item = {
20827
+ command: 'Font',
20828
+ subCommand: 'FontSize'
20829
+ };
20830
+ const items = this.parent.fontSize.items;
20831
+ let activeElem;
20832
+ if (this.parent.toolbarModule && this.parent.toolbarModule.dropDownModule &&
20833
+ this.parent.toolbarModule.dropDownModule.fontSizeDropDown && !isNullOrUndefined(this.parent.toolbarModule.dropDownModule.fontSizeDropDown.activeElem[0].textContent) && this.parent.toolbarModule.dropDownModule.fontSizeDropDown.activeElem[0].textContent !== '') {
20834
+ activeElem = this.parent.toolbarModule.dropDownModule.fontSizeDropDown.activeElem[0].textContent;
20835
+ }
20836
+ else {
20837
+ let fontSizeValue;
20838
+ const selection = this.parent.contentModule.getDocument().getSelection();
20839
+ if (selection && selection.focusNode && selection.focusNode.parentElement) {
20840
+ fontSizeValue = document.defaultView.getComputedStyle(selection.focusNode.parentElement, null).getPropertyValue('font-size');
20841
+ }
20842
+ else {
20843
+ fontSizeValue = this.parent.fontSize.width;
20844
+ }
20845
+ fontSizeValue = isNullOrUndefined(fontSizeValue) ? this.parent.fontSize.width : fontSizeValue;
20846
+ const actualTxtFontValues = fontSizeValue.match(/^([\d.]+)(\D+)$/);
20847
+ const size = parseInt(actualTxtFontValues[1], 10);
20848
+ const unit = actualTxtFontValues[2];
20849
+ const defaultFontValues = items[0].value.match(/^([\d.]+)(\D+)$/);
20850
+ if (defaultFontValues[2] === unit) {
20851
+ const index = items.findIndex(({ value }) => parseInt(value, 10) >= size);
20852
+ activeElem = items[index].text;
20853
+ }
20854
+ else {
20855
+ const convertedSize = this.convertFontSize(size, unit, defaultFontValues[2]);
20856
+ const index = items.findIndex(({ value }) => parseInt(value, 10) >= convertedSize);
20857
+ activeElem = items[index].text;
20858
+ }
20859
+ }
20860
+ const fontIndex = items.findIndex((size) => size.text === activeElem);
20861
+ if (keyboardArgs.action === 'increase-fontsize' && fontIndex !== -1) {
20862
+ if (fontIndex >= items.length - 1) {
20863
+ const fontValues = items[fontIndex].value.match(/^([\d.]+)(\D+)$/);
20864
+ if (fontValues) {
20865
+ const size = parseInt(fontValues[1], 10);
20866
+ const unit = fontValues[2];
20867
+ const roundedSize = size % 10 === 0 ? Math.ceil((size + 1) / 10) * 10 : Math.ceil(size / 10) * 10;
20868
+ args.item.value = roundedSize.toLocaleString() + unit;
20869
+ args.item.text = roundedSize.toLocaleString() + ' ' + unit;
20870
+ }
20871
+ this.parent.fontSize.items.push(args.item);
20872
+ }
20873
+ else {
20874
+ args.item.value = items[fontIndex + 1].value;
20875
+ args.item.text = items[fontIndex + 1].text;
20876
+ }
20877
+ }
20878
+ else if (keyboardArgs.action === 'decrease-fontsize' && fontIndex !== -1 && fontIndex > 0) {
20879
+ args.item.value = items[fontIndex - 1].value;
20880
+ args.item.text = items[fontIndex - 1].text;
20881
+ }
20882
+ else {
20883
+ if (fontIndex >= 0 && fontIndex < items.length && items[fontIndex]) {
20884
+ args.item.value = items[fontIndex].value;
20885
+ args.item.text = items[fontIndex].text;
20886
+ }
20887
+ }
20888
+ this.parent.formatter.process(this.parent, args, keyboardArgs);
20889
+ }
20890
+ convertFontSize(value, originalUnit, targetUnit) {
20891
+ if (supportedUnits.indexOf(originalUnit) !== -1 || supportedUnits.indexOf(targetUnit) !== -1) {
20892
+ originalUnit = 'px';
20893
+ }
20894
+ const convertedValue = value * conversionFactors[originalUnit][targetUnit];
20895
+ return convertedValue;
20896
+ }
20393
20897
  onKeyUp(e) {
20394
20898
  const args = e.args;
20395
20899
  const restrictKeys = [8, 9, 13, 16, 17, 18, 20, 27, 37, 38, 39, 40, 44, 45, 46, 91,
@@ -20510,7 +21014,7 @@ class HtmlEditor {
20510
21014
  e.args.keyCode === 13) {
20511
21015
  this.spaceLink(e.args);
20512
21016
  if (this.parent.editorMode === 'HTML' && !this.parent.readonly) {
20513
- const currentLength = this.parent.getText().trim().replace(/(\r\n|\n|\r)/gm, '').replace(/\u200B/g, '').length;
21017
+ const currentLength = this.parent.getText().trim().replace(/(\r\n|\n|\r|\t)/gm, '').replace(/\u200B/g, '').length;
20514
21018
  const selectionLength = this.parent.getSelection().length;
20515
21019
  const totalLength = (currentLength - selectionLength) + 1;
20516
21020
  if (!(this.parent.maxLength === -1 || totalLength <= this.parent.maxLength) &&
@@ -20672,7 +21176,7 @@ class HtmlEditor {
20672
21176
  let liElement;
20673
21177
  let rootElement;
20674
21178
  if (e.args.code === 'Delete' && e.args.keyCode === 46 &&
20675
- this.parent.contentModule.getText().trim().replace(/(\r\n|\n|\r)/gm, '').replace(/\u200B/g, '').length !== 0 && this.parent.getSelection().length === 0 && currentRange.startContainer.parentElement.tagName !== 'TD' &&
21179
+ this.parent.contentModule.getText().trim().replace(/(\r\n|\n|\r|\t)/gm, '').replace(/\u200B/g, '').length !== 0 && this.parent.getSelection().length === 0 && currentRange.startContainer.parentElement.tagName !== 'TD' &&
20676
21180
  currentRange.startContainer.parentElement.tagName !== 'TH') {
20677
21181
  this.deleteRangeElement = rootElement = this.getRootBlockNode(currentRange.startContainer);
20678
21182
  if (this.deleteRangeElement.tagName === 'OL' || this.deleteRangeElement.tagName === 'UL') {
@@ -21272,7 +21776,8 @@ class PasteCleanup {
21272
21776
  args: e.args,
21273
21777
  text: e.text,
21274
21778
  allowedStylePropertiesArray: this.parent.pasteCleanupSettings.allowedStyleProps,
21275
- callBack: (a, cropImageData) => {
21779
+ callBack: (a, cropImageData, pasteTableSource) => {
21780
+ args.pasteTableSource = pasteTableSource;
21276
21781
  value = a.trim();
21277
21782
  this.cropImageData = cropImageData;
21278
21783
  }
@@ -21842,10 +22347,24 @@ class PasteCleanup {
21842
22347
  }
21843
22348
  this.parent.trigger(afterPasteCleanup, { value: clipBoardElem.innerHTML, filesData: filesData }, (updatedArgs) => { value = updatedArgs.value; });
21844
22349
  clipBoardElem.innerHTML = this.parent.addAnchorAriaLabel(value);
21845
- clipBoardElem = this.addTableClass(clipBoardElem);
22350
+ clipBoardElem = this.addTableClass(clipBoardElem, args.pasteTableSource);
21846
22351
  this.parent.formatter.editorManager.execCommand('inserthtml', 'pasteCleanup', args, (returnArgs) => {
21847
22352
  extend(args, { elements: returnArgs.elements, imageElements: returnArgs.imgElem }, true);
21848
22353
  this.parent.formatter.onSuccess(this.parent, args);
22354
+ if (!isNullOrUndefined(returnArgs.elements) && !isNullOrUndefined(returnArgs.imgElem)) {
22355
+ const pasteContent = returnArgs.elements;
22356
+ const imageContent = returnArgs.imgElem;
22357
+ const lastElementChild = this.findLastElement(pasteContent[pasteContent.length - 1]);
22358
+ const isImageAtLast = !isNullOrUndefined(lastElementChild) ? lastElementChild.nodeName === 'IMG' : false;
22359
+ if (isImageAtLast || pasteContent[pasteContent.length - 1] === imageContent[imageContent.length - 1]) {
22360
+ this.parent.notify(insertCompleted, {
22361
+ args: args.event,
22362
+ type: 'Images',
22363
+ isNotify: true,
22364
+ elements: imageContent[imageContent.length - 1]
22365
+ });
22366
+ }
22367
+ }
21849
22368
  }, clipBoardElem, null, null, this.parent.enterKey);
21850
22369
  this.removeTempClass();
21851
22370
  this.parent.notify(toolbarRefresh, {});
@@ -21896,12 +22415,15 @@ class PasteCleanup {
21896
22415
  }
21897
22416
  }
21898
22417
  }
21899
- addTableClass(element) {
22418
+ addTableClass(element, source) {
21900
22419
  const tableElement = element.querySelectorAll('table');
21901
22420
  for (let i = 0; i < tableElement.length; i++) {
21902
- if (!tableElement[i].classList.contains('e-rte-table')) {
22421
+ if (!tableElement[i].classList.contains('e-rte-table') && (source === 'html' || source === '')) {
21903
22422
  tableElement[i].classList.add('e-rte-table');
21904
22423
  }
22424
+ else if (source && source !== 'html') {
22425
+ tableElement[i].classList.add('e-rte-paste-' + source + '-table');
22426
+ }
21905
22427
  }
21906
22428
  return element;
21907
22429
  }
@@ -22238,6 +22760,16 @@ class PasteCleanup {
22238
22760
  }
22239
22761
  return clipBoardElem;
22240
22762
  }
22763
+ findLastElement(element) {
22764
+ if (!isNullOrUndefined(element) && !isNullOrUndefined(element.lastElementChild)) {
22765
+ let lastChild = element.lastElementChild;
22766
+ while (lastChild && lastChild.lastElementChild) {
22767
+ lastChild = lastChild.lastElementChild;
22768
+ }
22769
+ return lastChild;
22770
+ }
22771
+ return null;
22772
+ }
22241
22773
  /**
22242
22774
  * For internal use only - Get the module name.
22243
22775
  *
@@ -22733,6 +23265,7 @@ class FullScreen {
22733
23265
  this.parent.toolbarModule.addFixedTBarClass();
22734
23266
  }
22735
23267
  }
23268
+ this.parent.refreshUI();
22736
23269
  this.parent.trigger(actionComplete, { requestType: 'Minimize', targetItem: 'Minimize', args: event });
22737
23270
  }
22738
23271
  });
@@ -23646,7 +24179,7 @@ class EmojiPicker {
23646
24179
  noEmojiObj.style.margin = '55px';
23647
24180
  emojipickerAll.appendChild(noEmojiObj);
23648
24181
  }
23649
- else if (!noEMoji && this.parent.element.querySelector('.e-rte-emojiSearch-noEmoji') || (inputValue === '' && value === ':')) {
24182
+ else if (!noEMoji && this.parent.element.querySelector('.e-rte-emojiSearch-noEmoji') || (inputValue === '' && value === ':') || (inputValue === '' && this.parent.element.querySelector('.e-rte-emojiSearch-noEmoji'))) {
23650
24183
  emojipickerAll.removeChild(this.parent.element.querySelector('.e-rte-emojiSearch-noEmoji'));
23651
24184
  }
23652
24185
  emojipickerAll.appendChild(emojiBtnDiv);
@@ -24296,12 +24829,20 @@ class Link {
24296
24829
  }
24297
24830
  const target = (this.selfLink.checkBoxObj.checked) ? '_blank' : null;
24298
24831
  const linkLabel = (this.selfLink.checkBoxObj.checked) ? this.selfLink.i10n.getConstant('linkAriaLabel') : null;
24832
+ if (this.selfLink.parent.editorMode === 'Markdown' && linkUrl === '') {
24833
+ linkUrl = 'http://';
24834
+ }
24299
24835
  if (linkUrl === '') {
24300
24836
  this.selfLink.checkUrl(true);
24301
24837
  return;
24302
24838
  }
24303
24839
  if (!this.selfLink.isUrl(linkUrl)) {
24304
- linkText = (linkText === '') ? linkUrl : linkText;
24840
+ if (this.selfLink.parent.editorMode === 'Markdown') {
24841
+ linkText = (linkText !== '') ? linkText : '';
24842
+ }
24843
+ else {
24844
+ linkText = (linkText === '') ? linkUrl : linkText;
24845
+ }
24305
24846
  if (!this.selfLink.parent.enableAutoUrl) {
24306
24847
  linkUrl = linkUrl.indexOf('http') > -1 ? linkUrl : 'http://' + linkUrl;
24307
24848
  }
@@ -24442,6 +24983,7 @@ class Link {
24442
24983
  this.parent.inlineMode.enable && !closest(target, '#' + this.dialogObj.element.id)) &&
24443
24984
  !closest(target, '#' + this.parent.getID() + '_toolbar_CreateLink') &&
24444
24985
  !target.querySelector('#' + this.parent.getID() + '_toolbar_CreateLink')))) {
24986
+ this.parent.notify(documentClickClosedBy, { closedBy: "outside click" });
24445
24987
  this.dialogObj.hide({ returnValue: true });
24446
24988
  EventHandler.remove(this.parent.element.ownerDocument, 'mousedown', this.onDocumentClick);
24447
24989
  this.parent.isBlur = true;
@@ -25190,6 +25732,14 @@ class Image$1 {
25190
25732
  originalEvent.preventDefault();
25191
25733
  break;
25192
25734
  }
25735
+ if (originalEvent.ctrlKey && originalEvent.key === 'a') {
25736
+ this.handleSelectAll();
25737
+ }
25738
+ }
25739
+ handleSelectAll() {
25740
+ this.cancelResizeAction();
25741
+ const imgFocusNodes = this.parent.inputElement.querySelectorAll('.' + CLS_IMG_FOCUS);
25742
+ removeClass(imgFocusNodes, CLS_IMG_FOCUS);
25193
25743
  }
25194
25744
  openDialog(isInternal, event, selection, ele, parentEle) {
25195
25745
  let range;
@@ -25358,10 +25908,12 @@ class Image$1 {
25358
25908
  this.parent.formatter.editorManager.nodeSelection.Clear(this.contentModule.getDocument());
25359
25909
  this.parent.formatter.editorManager.nodeSelection.setSelectionContents(this.contentModule.getDocument(), target);
25360
25910
  this.quickToolObj.imageQTBar.showPopup(args.pageX, pageY, target);
25911
+ this.resizeStart(e.args, target);
25361
25912
  }, 400);
25362
25913
  }
25363
25914
  else {
25364
- this.quickToolObj.imageQTBar.showPopup(args.pageX, pageY, target);
25915
+ const coordinates = target.getBoundingClientRect();
25916
+ this.quickToolObj.imageQTBar.showPopup(coordinates.left, coordinates.top, target, 'Image');
25365
25917
  }
25366
25918
  }
25367
25919
  }
@@ -25821,7 +26373,7 @@ class Image$1 {
25821
26373
  isModal: Browser.isDevice,
25822
26374
  buttons: [{
25823
26375
  click: this.insertImageUrl.bind(selectObj),
25824
- buttonModel: { content: imgInsert, cssClass: 'e-flat e-insertImage' + this.parent.getCssClass(true), isPrimary: true, disabled: true }
26376
+ buttonModel: { content: imgInsert, cssClass: 'e-flat e-insertImage' + this.parent.getCssClass(true), isPrimary: true, disabled: this.parent.editorMode === 'Markdown' ? false : true }
25825
26377
  },
25826
26378
  {
25827
26379
  click: (e) => {
@@ -25927,6 +26479,7 @@ class Image$1 {
25927
26479
  if (e.offsetX > e.target.clientWidth || e.offsetY > e.target.clientHeight) {
25928
26480
  }
25929
26481
  else {
26482
+ this.parent.notify(documentClickClosedBy, { closedBy: "outside click" });
25930
26483
  this.dialogObj.hide({ returnValue: true });
25931
26484
  this.parent.isBlur = true;
25932
26485
  dispatchEvent(this.parent.element, 'focusout');
@@ -25987,6 +26540,10 @@ class Image$1 {
25987
26540
  }
25988
26541
  }
25989
26542
  });
26543
+ if (e.selectNode && e.selectNode[0].nodeName === 'IMG') {
26544
+ const regex = new RegExp(/([^\S]|^)(((https?\:\/\/)|(www\.))(\S+))/gi);
26545
+ this.inputUrl.value = e.selectNode[0].src.match(regex) ? e.selectNode[0].src : '';
26546
+ }
25990
26547
  imgUrl.appendChild(this.inputUrl);
25991
26548
  return imgUrl;
25992
26549
  }
@@ -25994,7 +26551,10 @@ class Image$1 {
25994
26551
  insertImageUrl(e) {
25995
26552
  const proxy = this.selfImage;
25996
26553
  proxy.isImgUploaded = false;
25997
- const url = proxy.inputUrl.value;
26554
+ let url = proxy.inputUrl.value;
26555
+ if (proxy.parent.editorMode === 'Markdown' && url === '') {
26556
+ url = 'http://';
26557
+ }
25998
26558
  if (proxy.parent.formatter.getUndoRedoStack().length === 0) {
25999
26559
  proxy.parent.formatter.saveData();
26000
26560
  }
@@ -26984,6 +27544,13 @@ class Audio {
26984
27544
  originalEvent.preventDefault();
26985
27545
  break;
26986
27546
  }
27547
+ if (originalEvent.ctrlKey && originalEvent.key === 'a') {
27548
+ this.handleSelectAll();
27549
+ }
27550
+ }
27551
+ handleSelectAll() {
27552
+ const audioFocusNodes = this.parent.inputElement.querySelectorAll('.' + CLS_AUD_FOCUS);
27553
+ removeClass(audioFocusNodes, CLS_AUD_FOCUS);
26987
27554
  }
26988
27555
  openDialog(isInternal, event, selection, ele, parentEle) {
26989
27556
  let range;
@@ -27124,6 +27691,7 @@ class Audio {
27124
27691
  if (e.offsetX > e.target.clientWidth || e.offsetY > e.target.clientHeight) {
27125
27692
  }
27126
27693
  else {
27694
+ this.parent.notify(documentClickClosedBy, { closedBy: "outside click" });
27127
27695
  this.dialogObj.hide({ returnValue: true });
27128
27696
  this.parent.isBlur = true;
27129
27697
  dispatchEvent(this.parent.element, 'focusout');
@@ -27382,6 +27950,11 @@ class Audio {
27382
27950
  }
27383
27951
  }
27384
27952
  });
27953
+ if (e.selectNode && this.isAudioElem(e.selectNode[0])) {
27954
+ const regex = new RegExp(/([^\S]|^)(((https?\:\/\/)|(www\.))(\S+))/gi);
27955
+ const sourceElement = e.selectNode[0].querySelector('source');
27956
+ this.inputUrl.value = sourceElement.src.match(regex) ? sourceElement.src : '';
27957
+ }
27385
27958
  audioUrl.appendChild(this.inputUrl);
27386
27959
  return audioUrl;
27387
27960
  }
@@ -28272,6 +28845,14 @@ class Video {
28272
28845
  originalEvent.preventDefault();
28273
28846
  break;
28274
28847
  }
28848
+ if (originalEvent.ctrlKey && originalEvent.key === 'a') {
28849
+ this.handleSelectAll();
28850
+ }
28851
+ }
28852
+ handleSelectAll() {
28853
+ this.cancelResizeAction();
28854
+ const videoFocusNodes = this.parent.inputElement.querySelectorAll('.' + CLS_VID_FOCUS);
28855
+ removeClass(videoFocusNodes, CLS_VID_FOCUS);
28275
28856
  }
28276
28857
  openDialog(isInternal, event, selection, ele, parentEle) {
28277
28858
  let range;
@@ -28449,6 +29030,7 @@ class Video {
28449
29030
  if (e.offsetX > e.target.clientWidth || e.offsetY > e.target.clientHeight) {
28450
29031
  }
28451
29032
  else {
29033
+ this.parent.notify(documentClickClosedBy, { closedBy: "outside click" });
28452
29034
  this.dialogObj.hide({ returnValue: true });
28453
29035
  this.parent.isBlur = true;
28454
29036
  dispatchEvent(this.parent.element, 'focusout');
@@ -28735,6 +29317,15 @@ class Video {
28735
29317
  }
28736
29318
  }
28737
29319
  });
29320
+ if (e.selectNode && ((e.selectNode[0] && e.selectNode[0].nodeType !== 3 &&
29321
+ e.selectNode[0].nodeName !== 'BR' &&
29322
+ (e.selectNode[0].classList &&
29323
+ e.selectNode[0].classList.contains(CLS_VID_CLICK_ELEM))) ||
29324
+ e.selectNode[0].nodeName === 'IFRAME' || e.selectNode[0].nodeName === 'VIDEO')) {
29325
+ const regex = new RegExp(/([^\S]|^)(((https?\:\/\/)|(www\.))(\S+))/gi);
29326
+ const sourceElement = e.selectNode[0].querySelector('source');
29327
+ this.inputUrl.value = sourceElement.src.match(regex) ? sourceElement.src : '';
29328
+ }
28738
29329
  const embedUrlBtn = new RadioButton({
28739
29330
  label: this.i10n.getConstant('embeddedCode'),
28740
29331
  checked: true,
@@ -28744,7 +29335,6 @@ class Video {
28744
29335
  },
28745
29336
  change: () => {
28746
29337
  urlContent.innerHTML = '';
28747
- this.inputUrl.value = '';
28748
29338
  urlContent.appendChild(this.embedInputUrl);
28749
29339
  }
28750
29340
  });
@@ -28754,7 +29344,6 @@ class Video {
28754
29344
  name: 'URL',
28755
29345
  change: () => {
28756
29346
  urlContent.innerHTML = '';
28757
- this.embedInputUrl.value = '';
28758
29347
  urlContent.appendChild(this.inputUrl);
28759
29348
  }
28760
29349
  });
@@ -28944,10 +29533,11 @@ class Video {
28944
29533
  this.selection = proxy.parent.formatter.editorManager.nodeSelection.save(range, proxy.contentModule.getDocument());
28945
29534
  this.selectParent = proxy.parent.formatter.editorManager.nodeSelection.getParentNodeCollection(range);
28946
29535
  }
28947
- const name = url !== '' ? url.split('/')[url.split('/').length - 1] : embedUrl;
29536
+ const webUrlBtn = document.getElementById('webURL');
29537
+ const name = webUrlBtn.checked ? url.split('/')[url.split('/').length - 1] : embedUrl;
28948
29538
  const value = {
28949
29539
  cssClass: (proxy.parent.insertVideoSettings.layoutOption === 'Inline' ? CLS_VIDEOINLINE : CLS_VIDEOBREAK),
28950
- url: url, selection: this.selection, fileName: name, isEmbedUrl: embedUrl !== '' ? true : false,
29540
+ url: url, selection: this.selection, fileName: name, isEmbedUrl: !webUrlBtn.checked,
28951
29541
  selectParent: this.selectParent, width: {
28952
29542
  width: proxy.parent.insertVideoSettings.width, minWidth: proxy.parent.insertVideoSettings.minWidth,
28953
29543
  maxWidth: proxy.parent.getInsertImgMaxWidth()
@@ -29148,6 +29738,9 @@ class ViewSource {
29148
29738
  }
29149
29739
  this.parent.trigger(actionComplete, { requestType: 'SourceCode', targetItem: 'SourceCode', args: args });
29150
29740
  this.parent.invokeChangeEvent();
29741
+ if (!isNullOrUndefined(this.parent.saveInterval) && this.parent.saveInterval > 0 && this.parent.autoSaveOnIdle) {
29742
+ this.codeViewTimeInterval = setInterval(() => { this.parent.notify(updateValueOnIdle, {}); }, this.parent.saveInterval);
29743
+ }
29151
29744
  }
29152
29745
  /**
29153
29746
  * updateSourceCode method
@@ -29209,6 +29802,7 @@ class ViewSource {
29209
29802
  this.parent.trigger(actionComplete, { requestType: 'Preview', targetItem: 'Preview', args: args });
29210
29803
  this.parent.formatter.enableUndo(this.parent);
29211
29804
  this.parent.addAudioVideoWrapper();
29805
+ clearTimeout(this.codeViewTimeInterval);
29212
29806
  this.parent.invokeChangeEvent();
29213
29807
  this.parent.notify(tableclass, {});
29214
29808
  }
@@ -29300,6 +29894,7 @@ class Table {
29300
29894
  this.parent.on(bindCssClass, this.setCssClass, this);
29301
29895
  this.parent.on(destroy, this.destroy, this);
29302
29896
  this.parent.on(moduleDestroy, this.moduleDestroy, this);
29897
+ this.parent.on(afterKeyDown, this.afterKeyDown, this);
29303
29898
  }
29304
29899
  removeEventListener() {
29305
29900
  if (this.parent.isDestroyed) {
@@ -29325,6 +29920,7 @@ class Table {
29325
29920
  this.parent.off(bindCssClass, this.setCssClass);
29326
29921
  this.parent.off(destroy, this.destroy);
29327
29922
  this.parent.off(moduleDestroy, this.moduleDestroy);
29923
+ this.parent.off(afterKeyDown, this.afterKeyDown);
29328
29924
  if (!Browser.isDevice && this.parent.tableSettings.resize) {
29329
29925
  EventHandler.remove(this.contentModule.getEditPanel(), 'mouseover', this.resizeHelper);
29330
29926
  }
@@ -29482,6 +30078,14 @@ class Table {
29482
30078
  }
29483
30079
  }
29484
30080
  }
30081
+ if (event.ctrlKey && event.key === 'a') {
30082
+ this.handleSelectAll();
30083
+ }
30084
+ }
30085
+ handleSelectAll() {
30086
+ this.cancelResizeAction();
30087
+ const selectedCells = this.parent.inputElement.querySelectorAll('.' + CLS_TABLE_SEL);
30088
+ removeClass(selectedCells, CLS_TABLE_SEL);
29485
30089
  }
29486
30090
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
29487
30091
  tableModulekeyUp(e) {
@@ -29515,7 +30119,6 @@ class Table {
29515
30119
  name: !isInternal ? 'showDialog' : null
29516
30120
  };
29517
30121
  this.insertTableDialog({ self: this, args: args, selection: selection });
29518
- this.parent.formatter.editorManager.nodeSelection.restore();
29519
30122
  }
29520
30123
  }
29521
30124
  showDialog() {
@@ -29860,7 +30463,7 @@ class Table {
29860
30463
  return;
29861
30464
  }
29862
30465
  const target = e.target || e.targetTouches[0].target;
29863
- const closestTable = closest(target, 'table.e-rte-table');
30466
+ const closestTable = closest(target, 'table.e-rte-table, table.e-rte-paste-table');
29864
30467
  if (!isNullOrUndefined(this.curTable) && !isNullOrUndefined(closestTable) && closestTable !== this.curTable &&
29865
30468
  this.parent.contentModule.getEditPanel().contains(closestTable)) {
29866
30469
  this.removeResizeElement();
@@ -30497,6 +31100,7 @@ class Table {
30497
31100
  this.popupObj.hide();
30498
31101
  }
30499
31102
  if (this.editdlgObj) {
31103
+ this.parent.notify(documentClickClosedBy, { closedBy: "outside click" });
30500
31104
  this.editdlgObj.hide();
30501
31105
  }
30502
31106
  this.parent.isBlur = true;
@@ -30805,6 +31409,15 @@ class Table {
30805
31409
  getModuleName() {
30806
31410
  return 'table';
30807
31411
  }
31412
+ afterKeyDown(e) {
31413
+ if (this.curTable) {
31414
+ setTimeout(() => {
31415
+ const mouseOverEvent = document.createEvent('MouseEvents');
31416
+ mouseOverEvent.initEvent('mouseover', true, true);
31417
+ this.curTable.dispatchEvent(mouseOverEvent);
31418
+ }, 1);
31419
+ }
31420
+ }
30808
31421
  }
30809
31422
 
30810
31423
  /**
@@ -30821,6 +31434,7 @@ class DialogRenderer {
30821
31434
  }
30822
31435
  this.parent.on(moduleDestroy, this.moduleDestroy, this);
30823
31436
  this.parent.on(destroy, this.removeEventListener, this);
31437
+ this.parent.on(documentClickClosedBy, this.documentClickClosedBy, this);
30824
31438
  }
30825
31439
  removeEventListener() {
30826
31440
  if (this.parent.isDestroyed) {
@@ -30828,6 +31442,7 @@ class DialogRenderer {
30828
31442
  }
30829
31443
  this.parent.off(destroy, this.removeEventListener);
30830
31444
  this.parent.off(moduleDestroy, this.moduleDestroy);
31445
+ this.parent.off(documentClickClosedBy, this.documentClickClosedBy);
30831
31446
  }
30832
31447
  /**
30833
31448
  * dialog render method
@@ -30874,10 +31489,14 @@ class DialogRenderer {
30874
31489
  open(args) {
30875
31490
  this.parent.trigger(dialogOpen, args);
30876
31491
  }
31492
+ documentClickClosedBy(args) {
31493
+ this.outsideClickClosedBy = args.closedBy;
31494
+ }
30877
31495
  beforeClose(args) {
30878
31496
  if (this.dialogEle) {
30879
31497
  this.dialogEle.removeEventListener('keydown', this.handleEnterKeyDown);
30880
31498
  }
31499
+ args.closedBy = this.outsideClickClosedBy === 'outside click' ? this.outsideClickClosedBy : args.closedBy;
30881
31500
  this.parent.trigger(beforeDialogClose, args, (closeArgs) => {
30882
31501
  if (!closeArgs.cancel) {
30883
31502
  if (closeArgs.container.classList.contains('e-popup-close')) {
@@ -30885,6 +31504,7 @@ class DialogRenderer {
30885
31504
  }
30886
31505
  }
30887
31506
  });
31507
+ this.outsideClickClosedBy = "";
30888
31508
  }
30889
31509
  getDialogPosition() {
30890
31510
  let distanceFromVisibleTop = this.parent.element.getBoundingClientRect().top;
@@ -32390,7 +33010,7 @@ let RichTextEditor = class RichTextEditor extends Component {
32390
33010
  if (tool.command === 'InsertText') {
32391
33011
  currentInsertContentLength = value.length;
32392
33012
  }
32393
- const currentLength = this.getText().trim().replace(/(\r\n|\n|\r)/gm, '').replace(/\u200B/g, '').length;
33013
+ const currentLength = this.getText().trim().replace(/(\r\n|\n|\r|\t)/gm, '').replace(/\u200B/g, '').length;
32394
33014
  const selectionLength = this.getSelection().length;
32395
33015
  const totalLength = (currentLength - selectionLength) + currentInsertContentLength;
32396
33016
  if (!(this.maxLength === -1 || totalLength <= this.maxLength)) {
@@ -32756,7 +33376,7 @@ let RichTextEditor = class RichTextEditor extends Component {
32756
33376
  }
32757
33377
  if (e.action !== 'insert-link' &&
32758
33378
  e.action !== 'format-copy' && e.action !== 'format-paste' &&
32759
- (!e.target || !(e.target.classList.contains('e-mention') && e.code === 'Tab')) &&
33379
+ (!e.target || !(e.target.classList.contains('e-mention') && !isNullOrUndefined(document.querySelector('#' + e.target.id + '_popup.e-popup-open')) && e.code === 'Tab')) &&
32760
33380
  (e.action && e.action !== 'paste' && e.action !== 'space'
32761
33381
  || e.which === 9 || (e.code === 'Backspace' && e.which === 8))) {
32762
33382
  let FormatPainterEscapeAction = false;
@@ -32764,7 +33384,12 @@ let RichTextEditor = class RichTextEditor extends Component {
32764
33384
  FormatPainterEscapeAction = this.formatPainterModule.previousAction === 'escape';
32765
33385
  }
32766
33386
  if (!FormatPainterEscapeAction) {
32767
- this.formatter.process(this, null, e);
33387
+ if (this.editorMode === 'HTML' && (e.action === 'increase-fontsize' || e.action === 'decrease-fontsize')) {
33388
+ this.notify(onHandleFontsizeChange, { member: 'onHandleFontsizeChange', args: e });
33389
+ }
33390
+ else {
33391
+ this.formatter.process(this, null, e);
33392
+ }
32768
33393
  }
32769
33394
  switch (e.action) {
32770
33395
  case 'toolbar-focus':
@@ -32790,6 +33415,7 @@ let RichTextEditor = class RichTextEditor extends Component {
32790
33415
  this.setPlaceHolder();
32791
33416
  }
32792
33417
  }
33418
+ this.notify(afterKeyDown, { member: 'afterKeyDown', args: e });
32793
33419
  this.autoResize();
32794
33420
  }
32795
33421
  keyUp(e) {
@@ -32816,7 +33442,7 @@ let RichTextEditor = class RichTextEditor extends Component {
32816
33442
  const formatPainterCopy = e.key === 'C' && e.altKey && e.shiftKey;
32817
33443
  const formatPainterPaste = e.key === 'V' && e.altKey && e.shiftKey;
32818
33444
  if ((!formatPainterCopy && !formatPainterPaste) && ((e.key !== 'shift' && !e.ctrlKey) && e.key && e.key.length === 1 || allowedKeys) || (this.editorMode === 'Markdown'
32819
- && ((e.key !== 'shift' && !e.ctrlKey) && e.key && e.key.length === 1 || allowedKeys)) && !this.inlineMode.enable) {
33445
+ && ((e.key !== 'shift' && !e.ctrlKey) && e.key && e.key.length === 1 || allowedKeys)) || (this.autoSaveOnIdle && Browser.isDevice) && !this.inlineMode.enable) {
32820
33446
  this.formatter.onKeyHandler(this, e);
32821
33447
  }
32822
33448
  if (this.inputElement && this.inputElement.textContent.length !== 0
@@ -32912,60 +33538,6 @@ let RichTextEditor = class RichTextEditor extends Component {
32912
33538
  return;
32913
33539
  }
32914
33540
  }
32915
- if (e.detail === 3) {
32916
- const range = this.getRange();
32917
- const selection = this.formatter.editorManager.domNode.getSelection();
32918
- // To handle the triple click node selection improper range due to browser behavior.
32919
- if (selection.rangeCount > 0 && !isNullOrUndefined(range.startContainer.parentElement) && (!isNullOrUndefined(range.startContainer.parentElement.nextSibling) &&
32920
- (range.startContainer.parentElement.nextSibling.nodeType !== 3 ||
32921
- /\s+$/.test(range.startContainer.parentElement.nextSibling.textContent)) || range.startOffset === range.endOffset)
32922
- || range.startContainer.parentElement.tagName.toLocaleLowerCase() === 'li') {
32923
- const newRange = new Range();
32924
- let start = range.startContainer;
32925
- let end = range.endContainer;
32926
- let isInvalid = false;
32927
- const isInsideList = range.commonAncestorContainer.nodeName === 'OL' || range.commonAncestorContainer.nodeName === 'UL'
32928
- || range.commonAncestorContainer.nodeName === 'LI';
32929
- if (!isInsideList && end.nodeType === 1 && end.nodeName === 'LI') {
32930
- end = closest(end, 'ol, ul').previousElementSibling.lastElementChild;
32931
- }
32932
- else if (isInsideList && end.nodeType === 1 && range.endOffset === 0) {
32933
- if (end.previousElementSibling && end.previousElementSibling.lastElementChild) {
32934
- end = end.previousElementSibling.lastElementChild;
32935
- }
32936
- else {
32937
- end = closest(end.parentElement, 'li');
32938
- if (end && end.nodeName === 'LI') {
32939
- end = end.previousElementSibling;
32940
- }
32941
- }
32942
- }
32943
- else {
32944
- if (!closest(end, 'li') && end.previousElementSibling && end.previousElementSibling.lastChild &&
32945
- end.previousElementSibling.textContent.trim().length > 0) {
32946
- end = end.previousElementSibling.lastChild;
32947
- }
32948
- else if (closest(end, 'li') && end.previousElementSibling && end.previousElementSibling.lastChild) {
32949
- end = closest(end, 'li').parentElement.previousElementSibling.lastChild;
32950
- }
32951
- }
32952
- if (!end || end === this.inputElement) {
32953
- end = start;
32954
- isInvalid = true;
32955
- }
32956
- while (end.nodeName !== '#text' && !isInvalid) {
32957
- if (end.lastElementChild) {
32958
- end = end.lastElementChild;
32959
- }
32960
- else {
32961
- end = end.lastChild;
32962
- }
32963
- }
32964
- newRange.setStart(start, 0);
32965
- newRange.setEnd(end, end.textContent.length);
32966
- this.formatter.editorManager.nodeSelection.setRange(this.contentModule.getDocument(), newRange);
32967
- }
32968
- }
32969
33541
  this.notifyMouseUp(e);
32970
33542
  }
32971
33543
  /**
@@ -33006,10 +33578,10 @@ let RichTextEditor = class RichTextEditor extends Component {
33006
33578
  requestType: 'Paste'
33007
33579
  };
33008
33580
  this.trigger(actionBegin, evenArgs, (pasteArgs) => {
33009
- const currentLength = this.inputElement.textContent.length;
33581
+ const currentLength = this.getText().replace(/(\r\n|\n|\r|\t)/gm, '').replace(/\u200B/g, '').length;
33010
33582
  const selectionLength = this.getSelection().length;
33011
33583
  const pastedContentLength = (isNullOrUndefined(e) || isNullOrUndefined(e.clipboardData))
33012
- ? 0 : e.clipboardData.getData('text/plain').replace(/(\r\n|\n|\r)/gm, '').replace(/\u200B/g, '').length;
33584
+ ? 0 : e.clipboardData.getData('text/plain').replace(/(\r\n|\n|\r|\t)/gm, '').replace(/\u200B/g, '').length;
33013
33585
  const totalLength = (currentLength - selectionLength) + pastedContentLength;
33014
33586
  if (this.editorMode === 'Markdown') {
33015
33587
  const args = { requestType: 'Paste', editorMode: this.editorMode, event: e };
@@ -34084,6 +34656,7 @@ let RichTextEditor = class RichTextEditor extends Component {
34084
34656
  addClass([this.element], [CLS_FOCUS]);
34085
34657
  this.preventDefaultResize(e);
34086
34658
  this.notify(mouseDown, { args: e });
34659
+ this.formatter.editorManager.observer.notify(mouseDown, { args: e });
34087
34660
  this.clickPoints = { clientX: touch.clientX, clientY: touch.clientY };
34088
34661
  }
34089
34662
  preventImgResize(e) {
@@ -34245,6 +34818,7 @@ let RichTextEditor = class RichTextEditor extends Component {
34245
34818
  detach(item[i]);
34246
34819
  }
34247
34820
  }
34821
+ this.removeSelectionClassStates(valueElementWrapper);
34248
34822
  return valueElementWrapper.innerHTML;
34249
34823
  }
34250
34824
  updateStatus(e) {
@@ -34292,6 +34866,7 @@ let RichTextEditor = class RichTextEditor extends Component {
34292
34866
  }
34293
34867
  if (this.isBlur && isNullOrUndefined(trg)) {
34294
34868
  removeClass([this.element], [CLS_FOCUS]);
34869
+ this.removeSelectionClassStates(this.inputElement);
34295
34870
  this.notify(focusChange, {});
34296
34871
  const value = this.getUpdatedValue();
34297
34872
  this.setProperties({ value: value });
@@ -34455,6 +35030,7 @@ let RichTextEditor = class RichTextEditor extends Component {
34455
35030
  this.on(resizeInitialized, this.updateResizeFlag, this);
34456
35031
  this.on(updateTbItemsStatus, this.updateStatus, this);
34457
35032
  this.on(cleanupResizeElements, this.cleanupResizeElements, this);
35033
+ this.on(updateValueOnIdle, this.updateValueOnIdle, this);
34458
35034
  if (this.readonly && this.enabled) {
34459
35035
  return;
34460
35036
  }
@@ -34463,7 +35039,7 @@ let RichTextEditor = class RichTextEditor extends Component {
34463
35039
  restrict(e) {
34464
35040
  if (this.maxLength >= 0) {
34465
35041
  const element = this.editorMode === 'Markdown' ? this.contentModule.getText() :
34466
- (e && e.currentTarget.textContent);
35042
+ (this.getText().replace(/(\r\n|\n|\r|\t)/gm, '').replace(/\u200B/g, ''));
34467
35043
  if (!element) {
34468
35044
  return;
34469
35045
  }
@@ -34543,6 +35119,7 @@ let RichTextEditor = class RichTextEditor extends Component {
34543
35119
  this.off(resizeInitialized, this.updateResizeFlag);
34544
35120
  this.off(updateTbItemsStatus, this.updateStatus);
34545
35121
  this.off(cleanupResizeElements, this.cleanupResizeElements);
35122
+ this.off(updateValueOnIdle, this.updateValueOnIdle);
34546
35123
  if (this.readonly && this.enabled) {
34547
35124
  return;
34548
35125
  }
@@ -34612,6 +35189,21 @@ let RichTextEditor = class RichTextEditor extends Component {
34612
35189
  }
34613
35190
  }
34614
35191
  }
35192
+ removeSelectionClassStates(element) {
35193
+ const classNames = [CLS_IMG_FOCUS, CLS_TABLE_SEL, CLS_VID_FOCUS, CLS_AUD_FOCUS];
35194
+ for (let i = 0; i < classNames.length; i++) {
35195
+ const item = element.querySelectorAll('.' + classNames[i]);
35196
+ removeClass(item, classNames[i]);
35197
+ if (item.length === 0) {
35198
+ continue;
35199
+ }
35200
+ for (let j = 0; j < item.length; j++) {
35201
+ if (item[j].classList.length === 0) {
35202
+ item[j].removeAttribute('class');
35203
+ }
35204
+ }
35205
+ }
35206
+ }
34615
35207
  };
34616
35208
  __decorate$1([
34617
35209
  Complex({}, ToolbarSettings$1)
@@ -34915,5 +35507,5 @@ RichTextEditor = __decorate$1([
34915
35507
  * Rich Text Editor component exported items
34916
35508
  */
34917
35509
 
34918
- export { Toolbar$2 as Toolbar, KeyboardEvents$1 as KeyboardEvents, BaseToolbar, BaseQuickToolbar, QuickToolbar, Count, ColorPickerInput, MarkdownToolbarStatus, ExecCommandCallBack, ToolbarAction, MarkdownEditor, HtmlEditor, PasteCleanup, Resize, DropDownButtons, FileManager$1 as FileManager, FullScreen, setAttributes, HtmlToolbarStatus, XhtmlValidation, FormatPainter, EmojiPicker, HTMLFormatter, Formatter, MarkdownFormatter, ContentRender, Render, ToolbarRenderer, Link, Image$1 as Image, Audio, Video, ViewSource, Table, DialogRenderer, IframeContentRender, MarkdownRender, PopupRenderer, RichTextEditor, RenderType, ToolbarType, DialogType, executeGroup, created, destroyed, tableclass, load, initialLoad, contentChanged, initialEnd, iframeMouseDown, destroy, toolbarClick, toolbarRefresh, refreshBegin, toolbarUpdated, bindOnEnd, renderColorPicker, htmlToolbarClick, markdownToolbarClick, destroyColorPicker, modelChanged, tableModulekeyUp, keyUp, keyDown, mouseUp, toolbarCreated, toolbarRenderComplete, enableFullScreen, disableFullScreen, dropDownSelect, beforeDropDownItemRender, execCommandCallBack, imageToolbarAction, audioToolbarAction, videoToolbarAction, linkToolbarAction, windowResize, resizeStart, onResize, resizeStop, undo, redo, insertLink, unLink, editLink, openLink, actionBegin, actionComplete, updatedToolbarStatus, actionSuccess, updateToolbarItem, insertImage, insertAudio, insertVideo, insertCompleted, imageLeft, imageRight, imageCenter, imageBreak, imageInline, imageLink, imageAlt, imageDelete, audioDelete, videoDelete, imageCaption, imageSize, videoSize, sourceCode, updateSource, toolbarOpen, beforeDropDownOpen, selectionSave, selectionRestore, expandPopupClick, count, contentFocus, contentBlur, mouseDown, sourceCodeMouseDown, editAreaClick, scroll, contentscroll, colorPickerChanged, tableColorPickerChanged, focusChange, selectAll$1 as selectAll, selectRange, getSelectedHtml, renderInlineToolbar, paste, imgModule, rtlMode, createTable, docClick, tableToolbarAction, checkUndo, readOnlyMode, moduleDestroy, pasteClean, enterHandler, beforeDialogOpen, clearDialogObj, dialogOpen, beforeDialogClose, dialogClose, beforeQuickToolbarOpen, quickToolbarOpen, quickToolbarClose, popupHide, imageSelected, imageUploading, imageUploadSuccess, imageUploadFailed, imageRemoving, fileSelected, fileUploading, fileUploadSuccess, fileUploadFailed, fileRemoving, afterImageDelete, afterMediaDelete, drop, xhtmlValidation, beforeImageUpload, beforeFileUpload, resizeInitialized, renderFileManager, beforeImageDrop, dynamicModule, beforePasteCleanup, afterPasteCleanup, updateTbItemsStatus, showLinkDialog, closeLinkDialog, showImageDialog, showAudioDialog, showVideoDialog, closeImageDialog, closeAudioDialog, closeVideoDialog, showTableDialog, closeTableDialog, bindCssClass, formatPainterClick, formatPainterDoubleClick, emojiPicker, destroyTooltip, hidePopup, cleanupResizeElements, blockEmptyNodes, inlineEmptyNodes, CLS_RTE, CLS_RTL, CLS_CONTENT, CLS_DISABLED, CLS_SCRIPT_SHEET, CLS_STYLE_SHEET, CLS_TOOLBAR, CLS_TB_FIXED, CLS_TB_FLOAT, CLS_TB_ABS_FLOAT, CLS_INLINE, CLS_TB_INLINE, CLS_RTE_EXPAND_TB, CLS_FULL_SCREEN, CLS_QUICK_TB, CLS_TEXT_QUICK_TB, CLS_POP, CLS_TB_STATIC, CLS_QUICK_POP, CLS_QUICK_DROPDOWN, CLS_IMAGE_POP, CLS_TEXT_POP, CLS_INLINE_POP, CLS_INLINE_DROPDOWN, CLS_DROPDOWN_POPUP, CLS_DROPDOWN_ICONS, CLS_DROPDOWN_ITEMS, CLS_DROPDOWN_BTN, CLS_RTE_CONTENT, CLS_TB_ITEM, CLS_TB_EXTENDED, CLS_TB_WRAP, CLS_POPUP, CLS_SEPARATOR, CLS_MINIMIZE, CLS_MAXIMIZE, CLS_BACK, CLS_SHOW, CLS_HIDE, CLS_VISIBLE, CLS_FOCUS, CLS_RM_WHITE_SPACE, CLS_IMGRIGHT, CLS_IMGLEFT, CLS_IMGCENTER, CLS_IMGBREAK, CLS_AUDIOBREAK, CLS_CLICKELEM, CLS_VID_CLICK_ELEM, CLS_AUDIOWRAP, CLS_VIDEOWRAP, CLS_VIDEOBREAK, CLS_CAPTION, CLS_RTE_CAPTION, CLS_CAPINLINE, CLS_IMGINLINE, CLS_AUDIOINLINE, CLS_VIDEOINLINE, CLS_COUNT, CLS_WARNING, CLS_ERROR, CLS_ICONS, CLS_ACTIVE, CLS_EXPAND_OPEN, CLS_RTE_ELEMENTS, CLS_TB_BTN, CLS_HR_SEPARATOR, CLS_TB_IOS_FIX, CLS_LIST_PRIMARY_CONTENT, CLS_NUMBERFORMATLIST_TB_BTN, CLS_BULLETFORMATLIST_TB_BTN, CLS_FORMATS_TB_BTN, CLS_FONT_NAME_TB_BTN, CLS_FONT_SIZE_TB_BTN, CLS_ALIGN_TB_BTN, CLS_FONT_COLOR_TARGET, CLS_BACKGROUND_COLOR_TARGET, CLS_COLOR_CONTENT, CLS_FONT_COLOR_DROPDOWN, CLS_BACKGROUND_COLOR_DROPDOWN, CLS_COLOR_PALETTE, CLS_FONT_COLOR_PICKER, CLS_BACKGROUND_COLOR_PICKER, CLS_RTE_READONLY, CLS_TABLE_SEL, CLS_TB_DASH_BOR, CLS_TB_ALT_BOR, CLS_TB_COL_RES, CLS_TB_ROW_RES, CLS_TB_BOX_RES, CLS_RTE_HIDDEN, CLS_RTE_PASTE_KEEP_FORMAT, CLS_RTE_PASTE_REMOVE_FORMAT, CLS_RTE_PASTE_PLAIN_FORMAT, CLS_RTE_PASTE_OK, CLS_RTE_PASTE_CANCEL, CLS_RTE_DIALOG_MIN_HEIGHT, CLS_RTE_RES_HANDLE, CLS_RTE_RES_EAST, CLS_RTE_IMAGE, CLS_RESIZE, CLS_IMG_FOCUS, CLS_AUD_FOCUS, CLS_VID_FOCUS, CLS_RTE_DRAG_IMAGE, CLS_RTE_UPLOAD_POPUP, CLS_POPUP_OPEN, CLS_IMG_RESIZE, CLS_DROPAREA, CLS_IMG_INNER, CLS_UPLOAD_FILES, CLS_RTE_DIALOG_UPLOAD, CLS_RTE_RES_CNT, CLS_CUSTOM_TILE, CLS_NOCOLOR_ITEM, CLS_TABLE, CLS_TABLE_BORDER, CLS_RTE_TABLE_RESIZE, CLS_RTE_FIXED_TB_EXPAND, CLS_RTE_TB_ENABLED, CLS_RTE_RES_WEST, CLS_RTE_SOURCE_CODE_TXTAREA, getIndex, hasClass, getDropDownValue, isIDevice, getFormattedFontSize, pageYOffset, getTooltipText, setToolbarStatus, getCollection, getTBarItemsIndex, updateUndoRedoStatus, dispatchEvent, parseHtml, getTextNodesUnder, toObjectLowerCase, getEditValue, updateTextNode, getDefaultValue, isEditableValueEmpty, decode, sanitizeHelper, convertToBlob, getLocaleFontFormat, updateDropDownFontFormatLocale, ServiceLocator, RendererFactory, EditorManager, IMAGE, AUDIO, VIDEO, TABLE, LINK, INSERT_ROW, INSERT_COLUMN, DELETEROW, DELETECOLUMN, REMOVETABLE, TABLEHEADER, TABLE_VERTICAL_ALIGN, TABLE_MERGE, TABLE_VERTICAL_SPLIT, TABLE_HORIZONTAL_SPLIT, TABLE_MOVE, ALIGNMENT_TYPE, INDENT_TYPE, DEFAULT_TAG, BLOCK_TAGS, IGNORE_BLOCK_TAGS, TABLE_BLOCK_TAGS, SELECTION_TYPE, INSERTHTML_TYPE, INSERT_TEXT_TYPE, CLEAR_TYPE, SELF_CLOSING_TAGS, CLASS_IMAGE_RIGHT, CLASS_IMAGE_LEFT, CLASS_IMAGE_CENTER, CLASS_VIDEO_RIGHT, CLASS_VIDEO_LEFT, CLASS_VIDEO_CENTER, CLASS_IMAGE_BREAK, CLASS_AUDIO_BREAK, CLASS_VIDEO_BREAK, CLASS_CAPTION, CLASS_RTE_CAPTION, CLASS_CAPTION_INLINE, CLASS_IMAGE_INLINE, CLASS_AUDIO_INLINE, CLASS_CLICK_ELEM, CLASS_VIDEO_CLICK_ELEM, CLASS_AUDIO, CLASS_VIDEO, CLASS_AUDIO_WRAP, CLASS_VIDEO_WRAP, CLASS_EMBED_VIDEO_WRAP, CLASS_AUDIO_FOCUS, CLASS_VIDEO_FOCUS, CLASS_VIDEO_INLINE, Lists, markerClassName, DOMNode, Alignments, Indents, Formats, LinkCommand, InsertMethods, InsertTextExec, InsertHtmlExec, InsertHtml, IsFormatted, MsWordPaste, NodeCutter, ImageCommand, AudioCommand, VideoCommand, SelectionCommands, SelectionBasedExec, ClearFormatExec, UndoRedoManager, TableCommand, statusCollection, ToolbarStatus, FormatPainterActions, EmojiPickerAction, NodeSelection, MarkdownParser, LISTS_COMMAND, selectionCommand, LINK_COMMAND, CLEAR_COMMAND, MD_TABLE, INSERT_TEXT_COMMAND, ClearFormat, MDLists, MDFormats, MarkdownSelection, UndoRedoCommands, MDSelectionFormats, MDLink, MDTable, markdownFormatTags, markdownSelectionTags, markdownListsTags, htmlKeyConfig, markdownKeyConfig, pasteCleanupGroupingTags, listConversionFilters, selfClosingTags, KEY_DOWN, ACTION, FORMAT_TYPE, KEY_DOWN_HANDLER, LIST_TYPE, KEY_UP_HANDLER, KEY_UP, MODEL_CHANGED_PLUGIN, MODEL_CHANGED, MS_WORD_CLEANUP_PLUGIN, MS_WORD_CLEANUP, ON_BEGIN, SPACE_ACTION, FORMAT_PAINTER_ACTIONS, EMOJI_PICKER_ACTIONS };
35510
+ export { Toolbar$2 as Toolbar, KeyboardEvents$1 as KeyboardEvents, BaseToolbar, BaseQuickToolbar, QuickToolbar, Count, ColorPickerInput, MarkdownToolbarStatus, ExecCommandCallBack, ToolbarAction, MarkdownEditor, HtmlEditor, PasteCleanup, Resize, DropDownButtons, FileManager$1 as FileManager, FullScreen, setAttributes, HtmlToolbarStatus, XhtmlValidation, FormatPainter, EmojiPicker, HTMLFormatter, Formatter, MarkdownFormatter, ContentRender, Render, ToolbarRenderer, Link, Image$1 as Image, Audio, Video, ViewSource, Table, DialogRenderer, IframeContentRender, MarkdownRender, PopupRenderer, RichTextEditor, RenderType, ToolbarType, DialogType, executeGroup, created, destroyed, tableclass, load, initialLoad, contentChanged, initialEnd, iframeMouseDown, destroy, toolbarClick, toolbarRefresh, refreshBegin, toolbarUpdated, bindOnEnd, renderColorPicker, htmlToolbarClick, markdownToolbarClick, destroyColorPicker, modelChanged, tableModulekeyUp, keyUp, keyDown, mouseUp, toolbarCreated, toolbarRenderComplete, enableFullScreen, disableFullScreen, dropDownSelect, beforeDropDownItemRender, execCommandCallBack, imageToolbarAction, audioToolbarAction, videoToolbarAction, linkToolbarAction, windowResize, resizeStart, onResize, resizeStop, undo, redo, insertLink, unLink, editLink, openLink, actionBegin, actionComplete, updatedToolbarStatus, actionSuccess, updateToolbarItem, insertImage, insertAudio, insertVideo, insertCompleted, imageLeft, imageRight, imageCenter, imageBreak, imageInline, imageLink, imageAlt, imageDelete, audioDelete, videoDelete, imageCaption, imageSize, videoSize, sourceCode, updateSource, toolbarOpen, beforeDropDownOpen, selectionSave, selectionRestore, expandPopupClick, count, contentFocus, contentBlur, mouseDown, sourceCodeMouseDown, editAreaClick, scroll, contentscroll, colorPickerChanged, tableColorPickerChanged, focusChange, selectAll$1 as selectAll, selectRange, getSelectedHtml, renderInlineToolbar, paste, imgModule, rtlMode, createTable, docClick, tableToolbarAction, checkUndo, readOnlyMode, moduleDestroy, pasteClean, enterHandler, beforeDialogOpen, clearDialogObj, dialogOpen, beforeDialogClose, dialogClose, beforeQuickToolbarOpen, quickToolbarOpen, quickToolbarClose, popupHide, imageSelected, imageUploading, imageUploadSuccess, imageUploadFailed, imageRemoving, fileSelected, fileUploading, fileUploadSuccess, fileUploadFailed, fileRemoving, afterImageDelete, afterMediaDelete, drop, xhtmlValidation, beforeImageUpload, beforeFileUpload, resizeInitialized, renderFileManager, beforeImageDrop, dynamicModule, beforePasteCleanup, afterPasteCleanup, updateTbItemsStatus, showLinkDialog, closeLinkDialog, showImageDialog, showAudioDialog, showVideoDialog, closeImageDialog, closeAudioDialog, closeVideoDialog, showTableDialog, closeTableDialog, bindCssClass, formatPainterClick, formatPainterDoubleClick, emojiPicker, destroyTooltip, hidePopup, cleanupResizeElements, afterKeyDown, updateValueOnIdle, documentClickClosedBy, blockEmptyNodes, inlineEmptyNodes, supportedUnits, conversionFactors, onHandleFontsizeChange, CLS_RTE, CLS_RTL, CLS_CONTENT, CLS_DISABLED, CLS_SCRIPT_SHEET, CLS_STYLE_SHEET, CLS_TOOLBAR, CLS_TB_FIXED, CLS_TB_FLOAT, CLS_TB_ABS_FLOAT, CLS_INLINE, CLS_TB_INLINE, CLS_RTE_EXPAND_TB, CLS_FULL_SCREEN, CLS_QUICK_TB, CLS_TEXT_QUICK_TB, CLS_POP, CLS_TB_STATIC, CLS_QUICK_POP, CLS_QUICK_DROPDOWN, CLS_IMAGE_POP, CLS_TEXT_POP, CLS_INLINE_POP, CLS_INLINE_DROPDOWN, CLS_DROPDOWN_POPUP, CLS_DROPDOWN_ICONS, CLS_DROPDOWN_ITEMS, CLS_DROPDOWN_BTN, CLS_RTE_CONTENT, CLS_TB_ITEM, CLS_TB_EXTENDED, CLS_TB_WRAP, CLS_POPUP, CLS_SEPARATOR, CLS_MINIMIZE, CLS_MAXIMIZE, CLS_BACK, CLS_SHOW, CLS_HIDE, CLS_VISIBLE, CLS_FOCUS, CLS_RM_WHITE_SPACE, CLS_IMGRIGHT, CLS_IMGLEFT, CLS_IMGCENTER, CLS_IMGBREAK, CLS_AUDIOBREAK, CLS_CLICKELEM, CLS_VID_CLICK_ELEM, CLS_AUDIOWRAP, CLS_VIDEOWRAP, CLS_VIDEOBREAK, CLS_CAPTION, CLS_RTE_CAPTION, CLS_CAPINLINE, CLS_IMGINLINE, CLS_AUDIOINLINE, CLS_VIDEOINLINE, CLS_COUNT, CLS_WARNING, CLS_ERROR, CLS_ICONS, CLS_ACTIVE, CLS_EXPAND_OPEN, CLS_RTE_ELEMENTS, CLS_TB_BTN, CLS_HR_SEPARATOR, CLS_TB_IOS_FIX, CLS_LIST_PRIMARY_CONTENT, CLS_NUMBERFORMATLIST_TB_BTN, CLS_BULLETFORMATLIST_TB_BTN, CLS_FORMATS_TB_BTN, CLS_FONT_NAME_TB_BTN, CLS_FONT_SIZE_TB_BTN, CLS_ALIGN_TB_BTN, CLS_FONT_COLOR_TARGET, CLS_BACKGROUND_COLOR_TARGET, CLS_COLOR_CONTENT, CLS_FONT_COLOR_DROPDOWN, CLS_BACKGROUND_COLOR_DROPDOWN, CLS_COLOR_PALETTE, CLS_FONT_COLOR_PICKER, CLS_BACKGROUND_COLOR_PICKER, CLS_RTE_READONLY, CLS_TABLE_SEL, CLS_TB_DASH_BOR, CLS_TB_ALT_BOR, CLS_TB_COL_RES, CLS_TB_ROW_RES, CLS_TB_BOX_RES, CLS_RTE_HIDDEN, CLS_RTE_PASTE_KEEP_FORMAT, CLS_RTE_PASTE_REMOVE_FORMAT, CLS_RTE_PASTE_PLAIN_FORMAT, CLS_RTE_PASTE_OK, CLS_RTE_PASTE_CANCEL, CLS_RTE_DIALOG_MIN_HEIGHT, CLS_RTE_RES_HANDLE, CLS_RTE_RES_EAST, CLS_RTE_IMAGE, CLS_RESIZE, CLS_IMG_FOCUS, CLS_AUD_FOCUS, CLS_VID_FOCUS, CLS_RTE_DRAG_IMAGE, CLS_RTE_UPLOAD_POPUP, CLS_POPUP_OPEN, CLS_IMG_RESIZE, CLS_DROPAREA, CLS_IMG_INNER, CLS_UPLOAD_FILES, CLS_RTE_DIALOG_UPLOAD, CLS_RTE_RES_CNT, CLS_CUSTOM_TILE, CLS_NOCOLOR_ITEM, CLS_TABLE, CLS_TABLE_BORDER, CLS_RTE_TABLE_RESIZE, CLS_RTE_FIXED_TB_EXPAND, CLS_RTE_TB_ENABLED, CLS_RTE_RES_WEST, CLS_RTE_SOURCE_CODE_TXTAREA, getIndex, hasClass, getDropDownValue, isIDevice, getFormattedFontSize, pageYOffset, getTooltipText, getTooltipTextDropdownItems, getQuickToolbarTooltipText, setToolbarStatus, getCollection, getTBarItemsIndex, updateUndoRedoStatus, dispatchEvent, parseHtml, getTextNodesUnder, toObjectLowerCase, getEditValue, updateTextNode, getDefaultValue, isEditableValueEmpty, decode, sanitizeHelper, convertToBlob, getLocaleFontFormat, updateDropDownFontFormatLocale, ServiceLocator, RendererFactory, EditorManager, IMAGE, AUDIO, VIDEO, TABLE, LINK, INSERT_ROW, INSERT_COLUMN, DELETEROW, DELETECOLUMN, REMOVETABLE, TABLEHEADER, TABLE_VERTICAL_ALIGN, TABLE_MERGE, TABLE_VERTICAL_SPLIT, TABLE_HORIZONTAL_SPLIT, TABLE_MOVE, ALIGNMENT_TYPE, INDENT_TYPE, DEFAULT_TAG, BLOCK_TAGS, IGNORE_BLOCK_TAGS, TABLE_BLOCK_TAGS, SELECTION_TYPE, INSERTHTML_TYPE, INSERT_TEXT_TYPE, CLEAR_TYPE, SELF_CLOSING_TAGS, PASTE_SOURCE, CLASS_IMAGE_RIGHT, CLASS_IMAGE_LEFT, CLASS_IMAGE_CENTER, CLASS_VIDEO_RIGHT, CLASS_VIDEO_LEFT, CLASS_VIDEO_CENTER, CLASS_IMAGE_BREAK, CLASS_AUDIO_BREAK, CLASS_VIDEO_BREAK, CLASS_CAPTION, CLASS_RTE_CAPTION, CLASS_CAPTION_INLINE, CLASS_IMAGE_INLINE, CLASS_AUDIO_INLINE, CLASS_CLICK_ELEM, CLASS_VIDEO_CLICK_ELEM, CLASS_AUDIO, CLASS_VIDEO, CLASS_AUDIO_WRAP, CLASS_VIDEO_WRAP, CLASS_EMBED_VIDEO_WRAP, CLASS_AUDIO_FOCUS, CLASS_VIDEO_FOCUS, CLASS_VIDEO_INLINE, Lists, markerClassName, DOMNode, Alignments, Indents, Formats, LinkCommand, InsertMethods, InsertTextExec, InsertHtmlExec, InsertHtml, IsFormatted, MsWordPaste, NodeCutter, ImageCommand, AudioCommand, VideoCommand, SelectionCommands, SelectionBasedExec, ClearFormatExec, UndoRedoManager, TableCommand, statusCollection, ToolbarStatus, FormatPainterActions, EmojiPickerAction, NodeSelection, MarkdownParser, LISTS_COMMAND, selectionCommand, LINK_COMMAND, CLEAR_COMMAND, MD_TABLE, INSERT_TEXT_COMMAND, ClearFormat, MDLists, MDFormats, MarkdownSelection, UndoRedoCommands, MDSelectionFormats, MDLink, MDTable, markdownFormatTags, markdownSelectionTags, markdownListsTags, htmlKeyConfig, markdownKeyConfig, pasteCleanupGroupingTags, listConversionFilters, selfClosingTags, KEY_DOWN, ACTION, FORMAT_TYPE, KEY_DOWN_HANDLER, LIST_TYPE, KEY_UP_HANDLER, KEY_UP, MODEL_CHANGED_PLUGIN, MODEL_CHANGED, MS_WORD_CLEANUP_PLUGIN, MS_WORD_CLEANUP, ON_BEGIN, SPACE_ACTION, FORMAT_PAINTER_ACTIONS, EMOJI_PICKER_ACTIONS, MOUSE_DOWN };
34919
35511
  //# sourceMappingURL=ej2-richtexteditor.es2015.js.map