@syncfusion/ej2-richtexteditor 19.3.43 → 19.3.47-6125
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +999 -955
- package/README.md +67 -67
- package/dist/ej2-richtexteditor.umd.min.js +1 -10
- package/dist/ej2-richtexteditor.umd.min.js.map +1 -1
- package/dist/es6/ej2-richtexteditor.es2015.js +323 -204
- package/dist/es6/ej2-richtexteditor.es2015.js.map +1 -1
- package/dist/es6/ej2-richtexteditor.es5.js +428 -313
- package/dist/es6/ej2-richtexteditor.es5.js.map +1 -1
- package/helpers/e2e/index.js +3 -3
- package/license +9 -9
- package/package.json +55 -74
- package/src/common/constant.d.ts +8 -8
- package/src/common/constant.js +8 -8
- package/src/common/interface.d.ts +7 -7
- package/src/editor-manager/base/classes.d.ts +1 -1
- package/src/editor-manager/base/classes.js +1 -1
- package/src/editor-manager/base/editor-manager.d.ts +3 -3
- package/src/editor-manager/base/editor-manager.js +4 -4
- package/src/editor-manager/base/interface.d.ts +7 -7
- package/src/editor-manager/base/types.d.ts +1 -1
- package/src/editor-manager/plugin/alignments.d.ts +2 -2
- package/src/editor-manager/plugin/alignments.js +2 -2
- package/src/editor-manager/plugin/clearformat-exec.d.ts +2 -2
- package/src/editor-manager/plugin/clearformat-exec.js +2 -2
- package/src/editor-manager/plugin/clearformat.d.ts +2 -1
- package/src/editor-manager/plugin/clearformat.js +2 -1
- package/src/editor-manager/plugin/dom-node.d.ts +34 -34
- package/src/editor-manager/plugin/dom-node.js +34 -34
- package/src/editor-manager/plugin/formats.d.ts +2 -2
- package/src/editor-manager/plugin/formats.js +2 -2
- package/src/editor-manager/plugin/image.d.ts +3 -3
- package/src/editor-manager/plugin/image.js +15 -20
- package/src/editor-manager/plugin/indents.d.ts +2 -2
- package/src/editor-manager/plugin/indents.js +2 -2
- package/src/editor-manager/plugin/insert-methods.d.ts +4 -4
- package/src/editor-manager/plugin/insert-methods.js +4 -4
- package/src/editor-manager/plugin/insert-text.d.ts +2 -2
- package/src/editor-manager/plugin/insert-text.js +2 -2
- package/src/editor-manager/plugin/inserthtml-exec.d.ts +2 -2
- package/src/editor-manager/plugin/inserthtml-exec.js +2 -2
- package/src/editor-manager/plugin/inserthtml.d.ts +2 -2
- package/src/editor-manager/plugin/inserthtml.js +18 -8
- package/src/editor-manager/plugin/isformatted.d.ts +8 -8
- package/src/editor-manager/plugin/isformatted.js +8 -8
- package/src/editor-manager/plugin/link.d.ts +2 -2
- package/src/editor-manager/plugin/link.js +2 -2
- package/src/editor-manager/plugin/lists.d.ts +2 -2
- package/src/editor-manager/plugin/lists.js +2 -3
- package/src/editor-manager/plugin/ms-word-clean-up.d.ts +1 -1
- package/src/editor-manager/plugin/ms-word-clean-up.js +2 -1
- package/src/editor-manager/plugin/nodecutter.d.ts +6 -6
- package/src/editor-manager/plugin/nodecutter.js +6 -6
- package/src/editor-manager/plugin/selection-commands.d.ts +2 -1
- package/src/editor-manager/plugin/selection-commands.js +53 -3
- package/src/editor-manager/plugin/selection-exec.d.ts +2 -2
- package/src/editor-manager/plugin/selection-exec.js +2 -2
- package/src/editor-manager/plugin/table.d.ts +2 -2
- package/src/editor-manager/plugin/table.js +5 -5
- package/src/editor-manager/plugin/toolbar-status.d.ts +2 -2
- package/src/editor-manager/plugin/toolbar-status.js +5 -5
- package/src/editor-manager/plugin/undo.d.ts +6 -6
- package/src/editor-manager/plugin/undo.js +6 -6
- package/src/global.d.ts +1 -0
- package/src/markdown-parser/base/interface.d.ts +10 -10
- package/src/markdown-parser/base/markdown-parser.d.ts +3 -3
- package/src/markdown-parser/base/markdown-parser.js +3 -3
- package/src/markdown-parser/base/types.d.ts +1 -1
- package/src/markdown-parser/plugin/clearformat.d.ts +2 -2
- package/src/markdown-parser/plugin/clearformat.js +2 -2
- package/src/markdown-parser/plugin/formats.d.ts +2 -2
- package/src/markdown-parser/plugin/formats.js +2 -2
- package/src/markdown-parser/plugin/link.d.ts +2 -2
- package/src/markdown-parser/plugin/link.js +2 -2
- package/src/markdown-parser/plugin/markdown-selection.d.ts +14 -14
- package/src/markdown-parser/plugin/markdown-selection.js +14 -14
- package/src/markdown-parser/plugin/md-selection-formats.d.ts +1 -1
- package/src/markdown-parser/plugin/md-selection-formats.js +1 -1
- package/src/markdown-parser/plugin/table.d.ts +3 -3
- package/src/markdown-parser/plugin/table.js +3 -3
- package/src/markdown-parser/plugin/undo.d.ts +6 -6
- package/src/markdown-parser/plugin/undo.js +6 -6
- package/src/rich-text-editor/actions/base-quick-toolbar.d.ts +9 -9
- package/src/rich-text-editor/actions/base-quick-toolbar.js +9 -9
- package/src/rich-text-editor/actions/base-toolbar.d.ts +3 -3
- package/src/rich-text-editor/actions/base-toolbar.js +3 -3
- package/src/rich-text-editor/actions/color-picker.d.ts +2 -2
- package/src/rich-text-editor/actions/color-picker.js +2 -2
- package/src/rich-text-editor/actions/count.d.ts +3 -3
- package/src/rich-text-editor/actions/count.js +3 -3
- package/src/rich-text-editor/actions/dropdown-buttons.d.ts +2 -2
- package/src/rich-text-editor/actions/dropdown-buttons.js +2 -2
- package/src/rich-text-editor/actions/enter-key.js +5 -16
- package/src/rich-text-editor/actions/full-screen.d.ts +3 -3
- package/src/rich-text-editor/actions/full-screen.js +3 -3
- package/src/rich-text-editor/actions/html-editor.d.ts +4 -3
- package/src/rich-text-editor/actions/html-editor.js +34 -4
- package/src/rich-text-editor/actions/keyboard-model.d.ts +16 -16
- package/src/rich-text-editor/actions/keyboard.d.ts +1 -1
- package/src/rich-text-editor/actions/keyboard.js +20 -20
- package/src/rich-text-editor/actions/markdown-editor.d.ts +2 -2
- package/src/rich-text-editor/actions/markdown-editor.js +2 -2
- package/src/rich-text-editor/actions/paste-clean-up.d.ts +1 -1
- package/src/rich-text-editor/actions/paste-clean-up.js +1 -1
- package/src/rich-text-editor/actions/quick-toolbar.d.ts +9 -9
- package/src/rich-text-editor/actions/quick-toolbar.js +14 -11
- package/src/rich-text-editor/actions/toolbar.d.ts +13 -13
- package/src/rich-text-editor/actions/toolbar.js +13 -13
- package/src/rich-text-editor/actions/xhtml-validation.d.ts +2 -1
- package/src/rich-text-editor/actions/xhtml-validation.js +6 -4
- package/src/rich-text-editor/base/classes.d.ts +107 -107
- package/src/rich-text-editor/base/classes.js +107 -107
- package/src/rich-text-editor/base/constant.d.ts +120 -120
- package/src/rich-text-editor/base/constant.js +120 -120
- package/src/rich-text-editor/base/enum.d.ts +1 -1
- package/src/rich-text-editor/base/enum.js +1 -1
- package/src/rich-text-editor/base/interface.d.ts +45 -45
- package/src/rich-text-editor/base/interface.js +1 -1
- package/src/rich-text-editor/base/rich-text-editor-model.d.ts +851 -851
- package/src/rich-text-editor/base/rich-text-editor.d.ts +53 -53
- package/src/rich-text-editor/base/rich-text-editor.js +65 -66
- package/src/rich-text-editor/base/util.d.ts +2 -1
- package/src/rich-text-editor/base/util.js +2 -1
- package/src/rich-text-editor/formatter/formatter.d.ts +8 -8
- package/src/rich-text-editor/formatter/formatter.js +8 -8
- package/src/rich-text-editor/formatter/html-formatter.d.ts +2 -2
- package/src/rich-text-editor/formatter/html-formatter.js +15 -15
- package/src/rich-text-editor/formatter/markdown-formatter.d.ts +2 -2
- package/src/rich-text-editor/formatter/markdown-formatter.js +15 -15
- package/src/rich-text-editor/models/iframe-settings-model.d.ts +26 -26
- package/src/rich-text-editor/models/iframe-settings.js +19 -19
- package/src/rich-text-editor/models/inline-mode-model.d.ts +11 -11
- package/src/rich-text-editor/models/inline-mode.js +19 -19
- package/src/rich-text-editor/models/toolbar-settings-model.d.ts +439 -439
- package/src/rich-text-editor/models/toolbar-settings.d.ts +1 -1
- package/src/rich-text-editor/models/toolbar-settings.js +19 -19
- package/src/rich-text-editor/renderer/content-renderer.d.ts +6 -6
- package/src/rich-text-editor/renderer/content-renderer.js +6 -6
- package/src/rich-text-editor/renderer/dialog-renderer.d.ts +2 -2
- package/src/rich-text-editor/renderer/dialog-renderer.js +2 -2
- package/src/rich-text-editor/renderer/iframe-content-renderer.d.ts +4 -4
- package/src/rich-text-editor/renderer/iframe-content-renderer.js +17 -17
- package/src/rich-text-editor/renderer/image-module.d.ts +3 -1
- package/src/rich-text-editor/renderer/image-module.js +40 -13
- package/src/rich-text-editor/renderer/link-module.d.ts +1 -1
- package/src/rich-text-editor/renderer/link-module.js +6 -4
- package/src/rich-text-editor/renderer/markdown-renderer.d.ts +6 -6
- package/src/rich-text-editor/renderer/markdown-renderer.js +6 -6
- package/src/rich-text-editor/renderer/popup-renderer.d.ts +5 -5
- package/src/rich-text-editor/renderer/popup-renderer.js +5 -5
- package/src/rich-text-editor/renderer/render.d.ts +2 -2
- package/src/rich-text-editor/renderer/render.js +2 -2
- package/src/rich-text-editor/renderer/table-module.d.ts +1 -1
- package/src/rich-text-editor/renderer/table-module.js +11 -4
- package/src/rich-text-editor/renderer/toolbar-renderer.d.ts +9 -10
- package/src/rich-text-editor/renderer/toolbar-renderer.js +10 -10
- package/src/rich-text-editor/renderer/view-source.d.ts +6 -6
- package/src/rich-text-editor/renderer/view-source.js +6 -6
- package/src/rich-text-editor/services/renderer-factory.d.ts +3 -3
- package/src/rich-text-editor/services/renderer-factory.js +3 -3
- package/src/rich-text-editor/services/service-locator.d.ts +3 -3
- package/src/rich-text-editor/services/service-locator.js +3 -3
- package/src/selection/selection.d.ts +22 -22
- package/src/selection/selection.js +22 -22
- package/styles/_all.scss +2 -2
- package/styles/bootstrap-dark.css +1 -1
- package/styles/bootstrap.css +1 -1
- package/styles/bootstrap4.css +1 -1
- package/styles/bootstrap5-dark.css +1 -1
- package/styles/bootstrap5.css +1 -1
- package/styles/fabric-dark.css +1 -1
- package/styles/fabric.css +1 -1
- package/styles/highcontrast-light.css +1 -1
- package/styles/highcontrast.css +1 -1
- package/styles/material-dark.css +1 -1
- package/styles/material.css +1 -1
- package/styles/rich-text-editor/_all.scss +2 -2
- package/styles/rich-text-editor/_bootstrap-dark-definition.scss +187 -187
- package/styles/rich-text-editor/_bootstrap-definition.scss +244 -244
- package/styles/rich-text-editor/_bootstrap4-definition.scss +370 -370
- package/styles/rich-text-editor/_bootstrap5-definition.scss +168 -168
- package/styles/rich-text-editor/_fabric-dark-definition.scss +168 -168
- package/styles/rich-text-editor/_fabric-definition.scss +167 -167
- package/styles/rich-text-editor/_highcontrast-definition.scss +167 -167
- package/styles/rich-text-editor/_highcontrast-light-definition.scss +167 -167
- package/styles/rich-text-editor/_layout.scss +1635 -1635
- package/styles/rich-text-editor/_material-dark-definition.scss +172 -172
- package/styles/rich-text-editor/_material-definition.scss +169 -169
- package/styles/rich-text-editor/_tailwind-definition.scss +167 -167
- package/styles/rich-text-editor/_theme.scss +626 -626
- package/styles/rich-text-editor/bootstrap-dark.css +1 -1
- package/styles/rich-text-editor/bootstrap.css +1 -1
- package/styles/rich-text-editor/bootstrap4.css +1 -1
- package/styles/rich-text-editor/bootstrap5-dark.css +1 -1
- package/styles/rich-text-editor/bootstrap5.css +1 -1
- package/styles/rich-text-editor/fabric-dark.css +1 -1
- package/styles/rich-text-editor/fabric.css +1 -1
- package/styles/rich-text-editor/highcontrast-light.css +1 -1
- package/styles/rich-text-editor/highcontrast.css +1 -1
- package/styles/rich-text-editor/icons/_bootstrap-dark.scss +304 -304
- package/styles/rich-text-editor/icons/_bootstrap.scss +304 -304
- package/styles/rich-text-editor/icons/_bootstrap4.scss +304 -304
- package/styles/rich-text-editor/icons/_bootstrap5.scss +303 -303
- package/styles/rich-text-editor/icons/_fabric-dark.scss +304 -304
- package/styles/rich-text-editor/icons/_fabric.scss +304 -304
- package/styles/rich-text-editor/icons/_highcontrast-light.scss +304 -304
- package/styles/rich-text-editor/icons/_highcontrast.scss +304 -304
- package/styles/rich-text-editor/icons/_material-dark.scss +304 -304
- package/styles/rich-text-editor/icons/_material.scss +304 -304
- package/styles/rich-text-editor/icons/_tailwind.scss +304 -304
- package/styles/rich-text-editor/material-dark.css +1 -1
- package/styles/rich-text-editor/material.css +1 -1
- package/styles/rich-text-editor/tailwind-dark.css +1 -1
- package/styles/rich-text-editor/tailwind.css +1 -1
- package/styles/tailwind-dark.css +1 -1
- package/styles/tailwind.css +1 -1
- package/.eslintrc.json +0 -244
- package/dist/global/ej2-richtexteditor.min.js +0 -11
- package/dist/global/ej2-richtexteditor.min.js.map +0 -1
- package/dist/global/index.d.ts +0 -14
- package/tslint.json +0 -111
|
@@ -22,7 +22,7 @@ export declare class Count {
|
|
|
22
22
|
*
|
|
23
23
|
* @returns {void}
|
|
24
24
|
* @hidden
|
|
25
|
-
|
|
25
|
+
* @deprecated
|
|
26
26
|
*/
|
|
27
27
|
renderCount(): void;
|
|
28
28
|
private appendCount;
|
|
@@ -30,7 +30,7 @@ export declare class Count {
|
|
|
30
30
|
/**
|
|
31
31
|
* @returns {void}
|
|
32
32
|
* @hidden
|
|
33
|
-
|
|
33
|
+
* @deprecated
|
|
34
34
|
*/
|
|
35
35
|
refresh(): void;
|
|
36
36
|
/**
|
|
@@ -39,7 +39,7 @@ export declare class Count {
|
|
|
39
39
|
* @function destroy
|
|
40
40
|
* @returns {void}
|
|
41
41
|
* @hidden
|
|
42
|
-
|
|
42
|
+
* @deprecated
|
|
43
43
|
*/
|
|
44
44
|
destroy(): void;
|
|
45
45
|
private toggle;
|
|
@@ -22,7 +22,7 @@ var Count = /** @class */ (function () {
|
|
|
22
22
|
*
|
|
23
23
|
* @returns {void}
|
|
24
24
|
* @hidden
|
|
25
|
-
|
|
25
|
+
* @deprecated
|
|
26
26
|
*/
|
|
27
27
|
Count.prototype.renderCount = function () {
|
|
28
28
|
this.initializeInstance();
|
|
@@ -63,7 +63,7 @@ var Count = /** @class */ (function () {
|
|
|
63
63
|
/**
|
|
64
64
|
* @returns {void}
|
|
65
65
|
* @hidden
|
|
66
|
-
|
|
66
|
+
* @deprecated
|
|
67
67
|
*/
|
|
68
68
|
Count.prototype.refresh = function () {
|
|
69
69
|
if (!isNullOrUndefined(this.editPanel)) {
|
|
@@ -79,7 +79,7 @@ var Count = /** @class */ (function () {
|
|
|
79
79
|
* @function destroy
|
|
80
80
|
* @returns {void}
|
|
81
81
|
* @hidden
|
|
82
|
-
|
|
82
|
+
* @deprecated
|
|
83
83
|
*/
|
|
84
84
|
Count.prototype.destroy = function () {
|
|
85
85
|
if (this.element && !isNullOrUndefined(this.parent.element.querySelector('.' + CLS_COUNT))) {
|
|
@@ -31,7 +31,7 @@ export declare class DropDownButtons {
|
|
|
31
31
|
* @param {IDropDownRenderArgs} args - specifies the arguments
|
|
32
32
|
* @returns {void}
|
|
33
33
|
* @hidden
|
|
34
|
-
|
|
34
|
+
* @deprecated
|
|
35
35
|
*/
|
|
36
36
|
renderDropDowns(args: IDropDownRenderArgs): void;
|
|
37
37
|
private getUpdateItems;
|
|
@@ -50,7 +50,7 @@ export declare class DropDownButtons {
|
|
|
50
50
|
*
|
|
51
51
|
* @returns {void}
|
|
52
52
|
* @hidden
|
|
53
|
-
|
|
53
|
+
* @deprecated
|
|
54
54
|
*/
|
|
55
55
|
destroyDropDowns(): void;
|
|
56
56
|
private setRtl;
|
|
@@ -39,7 +39,7 @@ var DropDownButtons = /** @class */ (function () {
|
|
|
39
39
|
* @param {IDropDownRenderArgs} args - specifies the arguments
|
|
40
40
|
* @returns {void}
|
|
41
41
|
* @hidden
|
|
42
|
-
|
|
42
|
+
* @deprecated
|
|
43
43
|
*/
|
|
44
44
|
DropDownButtons.prototype.renderDropDowns = function (args) {
|
|
45
45
|
var _this = this;
|
|
@@ -400,7 +400,7 @@ var DropDownButtons = /** @class */ (function () {
|
|
|
400
400
|
*
|
|
401
401
|
* @returns {void}
|
|
402
402
|
* @hidden
|
|
403
|
-
|
|
403
|
+
* @deprecated
|
|
404
404
|
*/
|
|
405
405
|
DropDownButtons.prototype.destroyDropDowns = function () {
|
|
406
406
|
if (this.formatDropDown) {
|
|
@@ -69,9 +69,7 @@ var EnterKeyAction = /** @class */ (function () {
|
|
|
69
69
|
}
|
|
70
70
|
else if (focusElem.textContent.length === 0) {
|
|
71
71
|
var currentFocusElem = focusElem.previousSibling.lastChild;
|
|
72
|
-
var finalFocusElem = void 0;
|
|
73
72
|
while (currentFocusElem.nodeName !== '#text') {
|
|
74
|
-
finalFocusElem = currentFocusElem;
|
|
75
73
|
currentFocusElem = currentFocusElem.lastChild;
|
|
76
74
|
}
|
|
77
75
|
_this.parent.formatter.editorManager.nodeSelection.setCursorPoint(_this.parent.contentModule.getDocument(), currentFocusElem, currentFocusElem.textContent.length);
|
|
@@ -86,9 +84,9 @@ var EnterKeyAction = /** @class */ (function () {
|
|
|
86
84
|
_this.getRangeNode();
|
|
87
85
|
}
|
|
88
86
|
}
|
|
89
|
-
if (_this.range.startContainer === _this.range.endContainer &&
|
|
90
|
-
_this.range.startOffset
|
|
91
|
-
_this.parent.formatter.editorManager.nodeSelection.setCursorPoint(_this.parent.contentModule.getDocument(), _this.range.startContainer.childNodes[_this.range.startOffset],
|
|
87
|
+
if (_this.range.startContainer === _this.range.endContainer &&
|
|
88
|
+
_this.range.startOffset === _this.range.endOffset && _this.range.startContainer === _this.parent.inputElement) {
|
|
89
|
+
_this.parent.formatter.editorManager.nodeSelection.setCursorPoint(_this.parent.contentModule.getDocument(), _this.range.startContainer.childNodes[_this.range.startOffset], 0);
|
|
92
90
|
_this.getRangeNode();
|
|
93
91
|
}
|
|
94
92
|
if (_this.parent.enterKey === 'P' || _this.parent.enterKey === 'DIV' ||
|
|
@@ -131,6 +129,7 @@ var EnterKeyAction = /** @class */ (function () {
|
|
|
131
129
|
detach(nearBlockNode);
|
|
132
130
|
}
|
|
133
131
|
}
|
|
132
|
+
_this.parent.formatter.editorManager.nodeSelection.setCursorPoint(_this.parent.contentModule.getDocument(), insertElem.nextElementSibling, 0);
|
|
134
133
|
}
|
|
135
134
|
else if (nearBlockNode.textContent.length === 0 && !(!isNOU(nearBlockNode.childNodes[0]) && nearBlockNode.childNodes[0].nodeName === 'IMG')) {
|
|
136
135
|
if (!isNOU(nearBlockNode.children[0]) && nearBlockNode.children[0].tagName !== 'BR') {
|
|
@@ -164,7 +163,7 @@ var EnterKeyAction = /** @class */ (function () {
|
|
|
164
163
|
}
|
|
165
164
|
_this.parent.formatter.editorManager.domNode.insertAfter(insertElm, newElem);
|
|
166
165
|
detach(newElem);
|
|
167
|
-
_this.parent.formatter.editorManager.nodeSelection.setCursorPoint(_this.parent.contentModule.getDocument(),
|
|
166
|
+
_this.parent.formatter.editorManager.nodeSelection.setCursorPoint(_this.parent.contentModule.getDocument(), _this.parent.formatter.editorManager.domNode.isBlockNode(_this.startNode) ? insertElm : _this.startNode, 0);
|
|
168
167
|
}
|
|
169
168
|
}
|
|
170
169
|
e.args.preventDefault();
|
|
@@ -204,18 +203,14 @@ var EnterKeyAction = /** @class */ (function () {
|
|
|
204
203
|
}
|
|
205
204
|
else {
|
|
206
205
|
var newElem = void 0;
|
|
207
|
-
var focusElem = void 0;
|
|
208
206
|
var outerBRElem = _this.parent.createElement('br');
|
|
209
207
|
if (_this.range.startOffset === 0 && _this.range.endOffset === 0 &&
|
|
210
208
|
!isNOU(currentParent.previousSibling) && currentParent.previousSibling.nodeName === 'BR') {
|
|
211
|
-
focusElem = _this.range.startContainer;
|
|
212
209
|
newElem = _this.parent.formatter.editorManager.nodeCutter.SplitNode(_this.range, currentParent, false).cloneNode(true);
|
|
213
210
|
_this.parent.formatter.editorManager.domNode.insertAfter(outerBRElem, currentParent);
|
|
214
211
|
_this.insertFocusContent();
|
|
215
212
|
var currentFocusElem = outerBRElem.nextSibling;
|
|
216
|
-
var finalFocusElem = void 0;
|
|
217
213
|
while (!isNOU(currentFocusElem) && currentFocusElem.nodeName !== '#text') {
|
|
218
|
-
finalFocusElem = currentFocusElem;
|
|
219
214
|
currentFocusElem = currentFocusElem.lastChild;
|
|
220
215
|
}
|
|
221
216
|
_this.parent.formatter.editorManager.nodeSelection.setCursorPoint(_this.parent.contentModule.getDocument(), currentFocusElem, 0);
|
|
@@ -253,12 +248,6 @@ var EnterKeyAction = /** @class */ (function () {
|
|
|
253
248
|
}
|
|
254
249
|
e.args.preventDefault();
|
|
255
250
|
}
|
|
256
|
-
if (_this.range.startContainer.nodeName === '#text') {
|
|
257
|
-
_this.range.startContainer.parentElement.scrollIntoView(false);
|
|
258
|
-
}
|
|
259
|
-
else {
|
|
260
|
-
_this.range.startContainer.scrollIntoView(false);
|
|
261
|
-
}
|
|
262
251
|
_this.parent.trigger(events.actionComplete, { requestType: shiftKey_1 ? 'ShiftEnterAction' : 'EnterAction', args: e.args });
|
|
263
252
|
}
|
|
264
253
|
});
|
|
@@ -13,7 +13,7 @@ export declare class FullScreen {
|
|
|
13
13
|
* @param {MouseEvent} event - specifies the mouse event
|
|
14
14
|
* @returns {void}
|
|
15
15
|
* @hidden
|
|
16
|
-
|
|
16
|
+
* @deprecated
|
|
17
17
|
*/
|
|
18
18
|
showFullScreen(event?: MouseEvent | KeyboardEventArgs): void;
|
|
19
19
|
/**
|
|
@@ -22,7 +22,7 @@ export declare class FullScreen {
|
|
|
22
22
|
* @param {MouseEvent} event - specifies the mouse event
|
|
23
23
|
* @returns {void}
|
|
24
24
|
* @hidden
|
|
25
|
-
|
|
25
|
+
* @deprecated
|
|
26
26
|
*/
|
|
27
27
|
hideFullScreen(event?: MouseEvent | KeyboardEventArgs): void;
|
|
28
28
|
private toggleParentOverflow;
|
|
@@ -34,7 +34,7 @@ export declare class FullScreen {
|
|
|
34
34
|
*
|
|
35
35
|
* @returns {void}
|
|
36
36
|
* @hidden
|
|
37
|
-
|
|
37
|
+
* @deprecated
|
|
38
38
|
*/
|
|
39
39
|
destroy(): void;
|
|
40
40
|
}
|
|
@@ -17,7 +17,7 @@ var FullScreen = /** @class */ (function () {
|
|
|
17
17
|
* @param {MouseEvent} event - specifies the mouse event
|
|
18
18
|
* @returns {void}
|
|
19
19
|
* @hidden
|
|
20
|
-
|
|
20
|
+
* @deprecated
|
|
21
21
|
*/
|
|
22
22
|
FullScreen.prototype.showFullScreen = function (event) {
|
|
23
23
|
var _this = this;
|
|
@@ -67,7 +67,7 @@ var FullScreen = /** @class */ (function () {
|
|
|
67
67
|
* @param {MouseEvent} event - specifies the mouse event
|
|
68
68
|
* @returns {void}
|
|
69
69
|
* @hidden
|
|
70
|
-
|
|
70
|
+
* @deprecated
|
|
71
71
|
*/
|
|
72
72
|
FullScreen.prototype.hideFullScreen = function (event) {
|
|
73
73
|
var _this = this;
|
|
@@ -150,7 +150,7 @@ var FullScreen = /** @class */ (function () {
|
|
|
150
150
|
*
|
|
151
151
|
* @returns {void}
|
|
152
152
|
* @hidden
|
|
153
|
-
|
|
153
|
+
* @deprecated
|
|
154
154
|
*/
|
|
155
155
|
FullScreen.prototype.destroy = function () {
|
|
156
156
|
if (this.parent.element.classList.contains(classes.CLS_FULL_SCREEN)) {
|
|
@@ -27,20 +27,21 @@ export declare class HtmlEditor {
|
|
|
27
27
|
* @function destroy
|
|
28
28
|
* @returns {void}
|
|
29
29
|
* @hidden
|
|
30
|
-
|
|
30
|
+
* @deprecated
|
|
31
31
|
*/
|
|
32
32
|
destroy(): void;
|
|
33
33
|
/**
|
|
34
34
|
* @param {string} value - specifies the string value
|
|
35
35
|
* @returns {void}
|
|
36
36
|
* @hidden
|
|
37
|
-
|
|
37
|
+
* @deprecated
|
|
38
38
|
*/
|
|
39
39
|
sanitizeHelper(value: string): string;
|
|
40
40
|
private addEventListener;
|
|
41
41
|
private updateReadOnly;
|
|
42
42
|
private onSelectionSave;
|
|
43
43
|
private onSelectionRestore;
|
|
44
|
+
private onKeyUp;
|
|
44
45
|
private onKeyDown;
|
|
45
46
|
private isOrderedList;
|
|
46
47
|
private isUnOrderedList;
|
|
@@ -63,7 +64,7 @@ export declare class HtmlEditor {
|
|
|
63
64
|
* @param {RichTextEditorModel} e - specifies the editor model
|
|
64
65
|
* @returns {void}
|
|
65
66
|
* @hidden
|
|
66
|
-
|
|
67
|
+
* @deprecated
|
|
67
68
|
*/
|
|
68
69
|
protected onPropertyChanged(e: {
|
|
69
70
|
[key: string]: RichTextEditorModel;
|
|
@@ -32,7 +32,7 @@ var HtmlEditor = /** @class */ (function () {
|
|
|
32
32
|
* @function destroy
|
|
33
33
|
* @returns {void}
|
|
34
34
|
* @hidden
|
|
35
|
-
|
|
35
|
+
* @deprecated
|
|
36
36
|
*/
|
|
37
37
|
HtmlEditor.prototype.destroy = function () {
|
|
38
38
|
this.removeEventListener();
|
|
@@ -41,7 +41,7 @@ var HtmlEditor = /** @class */ (function () {
|
|
|
41
41
|
* @param {string} value - specifies the string value
|
|
42
42
|
* @returns {void}
|
|
43
43
|
* @hidden
|
|
44
|
-
|
|
44
|
+
* @deprecated
|
|
45
45
|
*/
|
|
46
46
|
HtmlEditor.prototype.sanitizeHelper = function (value) {
|
|
47
47
|
value = sanitizeHelper(value, this.parent);
|
|
@@ -56,6 +56,7 @@ var HtmlEditor = /** @class */ (function () {
|
|
|
56
56
|
this.parent.on(events.initialLoad, this.instantiateRenderer, this);
|
|
57
57
|
this.parent.on(events.htmlToolbarClick, this.onToolbarClick, this);
|
|
58
58
|
this.parent.on(events.keyDown, this.onKeyDown, this);
|
|
59
|
+
this.parent.on(events.keyUp, this.onKeyUp, this);
|
|
59
60
|
this.parent.on(events.renderColorPicker, this.renderColorPicker, this);
|
|
60
61
|
this.parent.on(events.initialEnd, this.render, this);
|
|
61
62
|
this.parent.on(events.modelChanged, this.onPropertyChanged, this);
|
|
@@ -90,6 +91,30 @@ var HtmlEditor = /** @class */ (function () {
|
|
|
90
91
|
this.saveSelection.restore();
|
|
91
92
|
}
|
|
92
93
|
};
|
|
94
|
+
HtmlEditor.prototype.onKeyUp = function (e) {
|
|
95
|
+
var args = e.args;
|
|
96
|
+
var restrictKeys = [8, 9, 13, 16, 17, 18, 20, 27, 37, 38, 39, 40, 44, 45, 46, 91,
|
|
97
|
+
112, 113, 114, 115, 116, 117, 118, 119, 120, 121, 122, 123];
|
|
98
|
+
var range = this.parent.getRange();
|
|
99
|
+
var regEx = new RegExp(String.fromCharCode(8203), 'g');
|
|
100
|
+
var pointer;
|
|
101
|
+
if (restrictKeys.indexOf(args.keyCode) < 0 && !args.shiftKey && !args.ctrlKey && !args.altKey) {
|
|
102
|
+
if (range.startContainer.textContent.charCodeAt(0) === 8203) {
|
|
103
|
+
pointer = range.startOffset - 1;
|
|
104
|
+
range.startContainer.textContent = range.startContainer.textContent.replace(regEx, '');
|
|
105
|
+
this.parent.formatter.editorManager.nodeSelection.setCursorPoint(this.parent.contentModule.getDocument(), range.startContainer, pointer);
|
|
106
|
+
}
|
|
107
|
+
if (!isNOU(range.startContainer.previousSibling) && !isNOU(range.startContainer.previousSibling.parentElement) &&
|
|
108
|
+
range.startContainer.parentElement === range.startContainer.previousSibling.parentElement && range.startContainer.previousSibling.textContent.charCodeAt(0) === 8203) {
|
|
109
|
+
range.startContainer.previousSibling.textContent = range.startContainer.previousSibling.textContent.replace(regEx, '');
|
|
110
|
+
}
|
|
111
|
+
if (range.endContainer.textContent.charCodeAt(range.endOffset) === 8203) {
|
|
112
|
+
pointer = range.startOffset;
|
|
113
|
+
range.endContainer.textContent = range.endContainer.textContent.replace(regEx, '');
|
|
114
|
+
this.parent.formatter.editorManager.nodeSelection.setCursorPoint(this.parent.contentModule.getDocument(), range.startContainer, pointer);
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
};
|
|
93
118
|
HtmlEditor.prototype.onKeyDown = function (e) {
|
|
94
119
|
var _this = this;
|
|
95
120
|
var currentRange;
|
|
@@ -300,7 +325,12 @@ var HtmlEditor = /** @class */ (function () {
|
|
|
300
325
|
while (this.deleteOldRangeElement.firstChild) {
|
|
301
326
|
this.deleteRangeElement.appendChild(this.deleteOldRangeElement.childNodes[0]);
|
|
302
327
|
}
|
|
303
|
-
!isLiElement
|
|
328
|
+
if (!isLiElement) {
|
|
329
|
+
detach(this.deleteOldRangeElement);
|
|
330
|
+
}
|
|
331
|
+
else {
|
|
332
|
+
detach(this.deleteOldRangeElement.parentElement);
|
|
333
|
+
}
|
|
304
334
|
this.deleteRangeElement.normalize();
|
|
305
335
|
}
|
|
306
336
|
else {
|
|
@@ -611,7 +641,7 @@ var HtmlEditor = /** @class */ (function () {
|
|
|
611
641
|
* @param {RichTextEditorModel} e - specifies the editor model
|
|
612
642
|
* @returns {void}
|
|
613
643
|
* @hidden
|
|
614
|
-
|
|
644
|
+
* @deprecated
|
|
615
645
|
*/
|
|
616
646
|
HtmlEditor.prototype.onPropertyChanged = function (e) {
|
|
617
647
|
// On property code change here
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { Property, NotifyPropertyChanges, INotifyPropertyChanged, Event } from '@syncfusion/ej2-base';
|
|
1
|
+
import { Property, NotifyPropertyChanges, INotifyPropertyChanged, Event } from '@syncfusion/ej2-base';
|
|
2
2
|
import {KeyboardEventArgs} from "./keyboard";
|
|
3
3
|
|
|
4
4
|
/**
|
|
@@ -7,24 +7,24 @@ import {KeyboardEventArgs} from "./keyboard";
|
|
|
7
7
|
export interface KeyboardEventsModel {
|
|
8
8
|
|
|
9
9
|
/**
|
|
10
|
-
* Specifies key combination and it respective action name.
|
|
11
|
-
*
|
|
12
|
-
* @default null
|
|
13
|
-
*/
|
|
14
|
-
keyConfigs?: { [key: string]: string };
|
|
10
|
+
* Specifies key combination and it respective action name.
|
|
11
|
+
*
|
|
12
|
+
* @default null
|
|
13
|
+
*/
|
|
14
|
+
keyConfigs?: { [key: string]: string };
|
|
15
15
|
|
|
16
16
|
/**
|
|
17
|
-
* Specifies on which event keyboardEvents class should listen for key press. For ex., `keyup`, `keydown` or `keypress`
|
|
18
|
-
*
|
|
19
|
-
* @default 'keyup'
|
|
20
|
-
*/
|
|
21
|
-
eventName?: string;
|
|
17
|
+
* Specifies on which event keyboardEvents class should listen for key press. For ex., `keyup`, `keydown` or `keypress`
|
|
18
|
+
*
|
|
19
|
+
* @default 'keyup'
|
|
20
|
+
*/
|
|
21
|
+
eventName?: string;
|
|
22
22
|
|
|
23
23
|
/**
|
|
24
|
-
* Specifies the listener when keyboard actions is performed.
|
|
25
|
-
*
|
|
26
|
-
* @event 'keyAction'
|
|
27
|
-
*/
|
|
28
|
-
keyAction?: EmitType<KeyboardEventArgs>;
|
|
24
|
+
* Specifies the listener when keyboard actions is performed.
|
|
25
|
+
*
|
|
26
|
+
* @event 'keyAction'
|
|
27
|
+
*/
|
|
28
|
+
keyAction?: EmitType<KeyboardEventArgs>;
|
|
29
29
|
|
|
30
30
|
}
|
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
var __extends = (this && this.__extends) || (function () {
|
|
2
|
-
var extendStatics = function (d, b) {
|
|
3
|
-
extendStatics = Object.setPrototypeOf ||
|
|
4
|
-
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
5
|
-
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
|
6
|
-
return extendStatics(d, b);
|
|
7
|
-
};
|
|
8
|
-
return function (d, b) {
|
|
9
|
-
extendStatics(d, b);
|
|
10
|
-
function __() { this.constructor = d; }
|
|
11
|
-
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
12
|
-
};
|
|
13
|
-
})();
|
|
14
|
-
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
15
|
-
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
16
|
-
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
17
|
-
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
18
|
-
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
19
|
-
};
|
|
1
|
+
var __extends = (this && this.__extends) || (function () {
|
|
2
|
+
var extendStatics = function (d, b) {
|
|
3
|
+
extendStatics = Object.setPrototypeOf ||
|
|
4
|
+
({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) ||
|
|
5
|
+
function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; };
|
|
6
|
+
return extendStatics(d, b);
|
|
7
|
+
};
|
|
8
|
+
return function (d, b) {
|
|
9
|
+
extendStatics(d, b);
|
|
10
|
+
function __() { this.constructor = d; }
|
|
11
|
+
d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
|
|
12
|
+
};
|
|
13
|
+
})();
|
|
14
|
+
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
|
|
15
|
+
var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
|
|
16
|
+
if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
|
|
17
|
+
else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
|
|
18
|
+
return c > 3 && r && Object.defineProperty(target, key, r), r;
|
|
19
|
+
};
|
|
20
20
|
import { Property, NotifyPropertyChanges, Event } from '@syncfusion/ej2-base';
|
|
21
21
|
import { Base } from '@syncfusion/ej2-base';
|
|
22
22
|
var keyCode = {
|
|
@@ -84,7 +84,7 @@ var keyCode = {
|
|
|
84
84
|
* ```
|
|
85
85
|
*
|
|
86
86
|
* @hidden
|
|
87
|
-
|
|
87
|
+
* @deprecated
|
|
88
88
|
*/
|
|
89
89
|
var KeyboardEvents = /** @class */ (function (_super) {
|
|
90
90
|
__extends(KeyboardEvents, _super);
|
|
@@ -19,7 +19,7 @@ export declare class MarkdownEditor {
|
|
|
19
19
|
* @function destroy
|
|
20
20
|
* @returns {void}
|
|
21
21
|
* @hidden
|
|
22
|
-
|
|
22
|
+
* @deprecated
|
|
23
23
|
*/
|
|
24
24
|
destroy(): void;
|
|
25
25
|
private addEventListener;
|
|
@@ -36,7 +36,7 @@ export declare class MarkdownEditor {
|
|
|
36
36
|
* @param {RichTextEditorModel} e - specifies the editor model
|
|
37
37
|
* @returns {void}
|
|
38
38
|
* @hidden
|
|
39
|
-
|
|
39
|
+
* @deprecated
|
|
40
40
|
*/
|
|
41
41
|
protected onPropertyChanged(e: {
|
|
42
42
|
[key: string]: RichTextEditorModel;
|
|
@@ -22,7 +22,7 @@ var MarkdownEditor = /** @class */ (function () {
|
|
|
22
22
|
* @function destroy
|
|
23
23
|
* @returns {void}
|
|
24
24
|
* @hidden
|
|
25
|
-
|
|
25
|
+
* @deprecated
|
|
26
26
|
*/
|
|
27
27
|
MarkdownEditor.prototype.destroy = function () {
|
|
28
28
|
this.removeEventListener();
|
|
@@ -138,7 +138,7 @@ var MarkdownEditor = /** @class */ (function () {
|
|
|
138
138
|
* @param {RichTextEditorModel} e - specifies the editor model
|
|
139
139
|
* @returns {void}
|
|
140
140
|
* @hidden
|
|
141
|
-
|
|
141
|
+
* @deprecated
|
|
142
142
|
*/
|
|
143
143
|
MarkdownEditor.prototype.onPropertyChanged = function (e) {
|
|
144
144
|
// On property code change here
|
|
@@ -414,7 +414,7 @@ var PasteCleanup = /** @class */ (function () {
|
|
|
414
414
|
* @param {Element []} imgElement - specifies the array elements.
|
|
415
415
|
* @returns {void}
|
|
416
416
|
* @hidden
|
|
417
|
-
|
|
417
|
+
* @deprecated
|
|
418
418
|
*/
|
|
419
419
|
PasteCleanup.prototype.imageFormatting = function (pasteArgs, imgElement) {
|
|
420
420
|
var imageElement = this.parent.createElement('span');
|
|
@@ -33,7 +33,7 @@ export declare class QuickToolbar {
|
|
|
33
33
|
* @param {RenderType} type - specifies the render type.
|
|
34
34
|
* @returns {BaseQuickToolbar} - specifies the quick toolbar
|
|
35
35
|
* @hidden
|
|
36
|
-
|
|
36
|
+
* @deprecated
|
|
37
37
|
*/
|
|
38
38
|
createQTBar(popupType: string, mode: string, items: (string | IToolbarItems)[], type: RenderType): BaseQuickToolbar;
|
|
39
39
|
private initializeQuickToolbars;
|
|
@@ -48,7 +48,7 @@ export declare class QuickToolbar {
|
|
|
48
48
|
* @param {HTMLElement} target - specifies the target element.
|
|
49
49
|
* @returns {void}
|
|
50
50
|
* @hidden
|
|
51
|
-
|
|
51
|
+
* @deprecated
|
|
52
52
|
*/
|
|
53
53
|
showInlineQTBar(x: number, y: number, target: HTMLElement): void;
|
|
54
54
|
/**
|
|
@@ -56,7 +56,7 @@ export declare class QuickToolbar {
|
|
|
56
56
|
*
|
|
57
57
|
* @returns {void}
|
|
58
58
|
* @hidden
|
|
59
|
-
|
|
59
|
+
* @deprecated
|
|
60
60
|
*/
|
|
61
61
|
hideInlineQTBar(): void;
|
|
62
62
|
/**
|
|
@@ -64,7 +64,7 @@ export declare class QuickToolbar {
|
|
|
64
64
|
*
|
|
65
65
|
* @returns {void}
|
|
66
66
|
* @hidden
|
|
67
|
-
|
|
67
|
+
* @deprecated
|
|
68
68
|
*/
|
|
69
69
|
hideQuickToolbars(): void;
|
|
70
70
|
private deBounce;
|
|
@@ -79,7 +79,7 @@ export declare class QuickToolbar {
|
|
|
79
79
|
*
|
|
80
80
|
* @returns {void}
|
|
81
81
|
* @hidden
|
|
82
|
-
|
|
82
|
+
* @deprecated
|
|
83
83
|
*/
|
|
84
84
|
getInlineBaseToolbar(): BaseToolbar;
|
|
85
85
|
/**
|
|
@@ -88,7 +88,7 @@ export declare class QuickToolbar {
|
|
|
88
88
|
* @function destroy
|
|
89
89
|
* @returns {void}
|
|
90
90
|
* @hidden
|
|
91
|
-
|
|
91
|
+
* @deprecated
|
|
92
92
|
*/
|
|
93
93
|
destroy(): void;
|
|
94
94
|
private wireInlineQTBarEvents;
|
|
@@ -99,7 +99,7 @@ export declare class QuickToolbar {
|
|
|
99
99
|
*
|
|
100
100
|
* @returns {void}
|
|
101
101
|
* @hidden
|
|
102
|
-
|
|
102
|
+
* @deprecated
|
|
103
103
|
*/
|
|
104
104
|
addEventListener(): void;
|
|
105
105
|
private onKeyDown;
|
|
@@ -110,7 +110,7 @@ export declare class QuickToolbar {
|
|
|
110
110
|
*
|
|
111
111
|
* @returns {void}
|
|
112
112
|
* @hidden
|
|
113
|
-
|
|
113
|
+
* @deprecated
|
|
114
114
|
*/
|
|
115
115
|
removeEventListener(): void;
|
|
116
116
|
/**
|
|
@@ -119,7 +119,7 @@ export declare class QuickToolbar {
|
|
|
119
119
|
* @param {RichTextEditorModel} e - specifies the element.
|
|
120
120
|
* @returns {void}
|
|
121
121
|
* @hidden
|
|
122
|
-
|
|
122
|
+
* @deprecated
|
|
123
123
|
*/
|
|
124
124
|
protected onPropertyChanged(e: {
|
|
125
125
|
[key: string]: RichTextEditorModel;
|