@syncfusion/ej2-richtexteditor 19.4.48 → 19.4.50
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 +10 -2
- package/dist/ej2-richtexteditor.umd.min.js +2 -2
- package/dist/ej2-richtexteditor.umd.min.js.map +1 -1
- package/dist/es6/ej2-richtexteditor.es2015.js +32 -24
- package/dist/es6/ej2-richtexteditor.es2015.js.map +1 -1
- package/dist/es6/ej2-richtexteditor.es5.js +32 -24
- package/dist/es6/ej2-richtexteditor.es5.js.map +1 -1
- package/dist/global/ej2-richtexteditor.min.js +2 -2
- package/dist/global/ej2-richtexteditor.min.js.map +1 -1
- package/dist/global/index.d.ts +1 -1
- package/package.json +9 -9
- package/src/editor-manager/plugin/inserthtml.js +3 -2
- package/src/rich-text-editor/actions/enter-key.js +9 -4
- package/src/rich-text-editor/actions/html-editor.js +1 -1
- package/src/rich-text-editor/renderer/image-module.js +19 -17
package/dist/global/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
/*!
|
|
2
2
|
* filename: index.d.ts
|
|
3
|
-
* version : 19.4.
|
|
3
|
+
* version : 19.4.50
|
|
4
4
|
* Copyright Syncfusion Inc. 2001 - 2020. All rights reserved.
|
|
5
5
|
* Use of this code is subject to the terms of our license.
|
|
6
6
|
* A copy of the current license can be obtained at any time by e-mailing
|
package/package.json
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"_from": "@syncfusion/ej2-richtexteditor@*",
|
|
3
|
-
"_id": "@syncfusion/ej2-richtexteditor@19.4.
|
|
3
|
+
"_id": "@syncfusion/ej2-richtexteditor@19.4.48",
|
|
4
4
|
"_inBundle": false,
|
|
5
|
-
"_integrity": "sha512-
|
|
5
|
+
"_integrity": "sha512-QieTgmAYkkOwu3ZFdLGHs+y4zOaWVeX0ega0Y+aKDujLdgrOd6roe6wdZrAnFGypJmN1kw1ZzpXOl7Z58J95Rg==",
|
|
6
6
|
"_location": "/@syncfusion/ej2-richtexteditor",
|
|
7
7
|
"_phantomChildren": {},
|
|
8
8
|
"_requested": {
|
|
@@ -26,8 +26,8 @@
|
|
|
26
26
|
"/@syncfusion/ej2-react-richtexteditor",
|
|
27
27
|
"/@syncfusion/ej2-vue-richtexteditor"
|
|
28
28
|
],
|
|
29
|
-
"_resolved": "http://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-richtexteditor/-/ej2-richtexteditor-19.4.
|
|
30
|
-
"_shasum": "
|
|
29
|
+
"_resolved": "http://nexus.syncfusion.com/repository/ej2-hotfix-new/@syncfusion/ej2-richtexteditor/-/ej2-richtexteditor-19.4.48.tgz",
|
|
30
|
+
"_shasum": "bcbe604657f0ddbca36bee320dd63465c8c861ff",
|
|
31
31
|
"_spec": "@syncfusion/ej2-richtexteditor@*",
|
|
32
32
|
"_where": "/jenkins/workspace/automation_release_19.1.0.1-ZPMUBNQ6AUYH6YGEFBPVYMEQLRRW2SLD4XCZ6GATNZJFYJ3RIAOA/packages/included",
|
|
33
33
|
"author": {
|
|
@@ -39,11 +39,11 @@
|
|
|
39
39
|
"bundleDependencies": false,
|
|
40
40
|
"dependencies": {
|
|
41
41
|
"@syncfusion/ej2-base": "~19.4.48",
|
|
42
|
-
"@syncfusion/ej2-buttons": "~19.4.
|
|
43
|
-
"@syncfusion/ej2-filemanager": "~19.4.
|
|
42
|
+
"@syncfusion/ej2-buttons": "~19.4.50",
|
|
43
|
+
"@syncfusion/ej2-filemanager": "~19.4.50",
|
|
44
44
|
"@syncfusion/ej2-inputs": "~19.4.48",
|
|
45
|
-
"@syncfusion/ej2-navigations": "~19.4.
|
|
46
|
-
"@syncfusion/ej2-popups": "~19.4.
|
|
45
|
+
"@syncfusion/ej2-navigations": "~19.4.50",
|
|
46
|
+
"@syncfusion/ej2-popups": "~19.4.50",
|
|
47
47
|
"@syncfusion/ej2-splitbuttons": "~19.4.48"
|
|
48
48
|
},
|
|
49
49
|
"deprecated": false,
|
|
@@ -70,6 +70,6 @@
|
|
|
70
70
|
"url": "git+https://github.com/syncfusion/ej2-javascript-ui-controls.git"
|
|
71
71
|
},
|
|
72
72
|
"typings": "index.d.ts",
|
|
73
|
-
"version": "19.4.
|
|
73
|
+
"version": "19.4.50",
|
|
74
74
|
"sideEffects": false
|
|
75
75
|
}
|
|
@@ -311,8 +311,9 @@ var InsertHtml = /** @class */ (function () {
|
|
|
311
311
|
};
|
|
312
312
|
InsertHtml.getNodeCollection = function (range, nodeSelection, node) {
|
|
313
313
|
var nodes = [];
|
|
314
|
-
if (range.startOffset === range.endOffset && range.startContainer === range.endContainer
|
|
315
|
-
|
|
314
|
+
if (range.startOffset === range.endOffset && range.startContainer === range.endContainer &&
|
|
315
|
+
range.startContainer.nodeName != 'BR' &&
|
|
316
|
+
(range.startContainer.nodeName === 'TD' || (range.startContainer.nodeType !== 3 &&
|
|
316
317
|
node.classList && node.classList.contains('pasteContent')))) {
|
|
317
318
|
nodes.push(range.startContainer.childNodes[range.endOffset]);
|
|
318
319
|
}
|
|
@@ -228,7 +228,7 @@ var EnterKeyAction = /** @class */ (function () {
|
|
|
228
228
|
}
|
|
229
229
|
var isEmptyBrInserted = false;
|
|
230
230
|
var currentParentLastChild = currentParent.lastChild;
|
|
231
|
-
while (!isNOU(currentParentLastChild) && !(currentParentLastChild.nodeName === '#text')) {
|
|
231
|
+
while (!isNOU(currentParentLastChild) && !(currentParentLastChild.nodeName === '#text' || currentParentLastChild.nodeName === 'BR')) {
|
|
232
232
|
currentParentLastChild = currentParentLastChild.lastChild;
|
|
233
233
|
}
|
|
234
234
|
var isLastNodeLength = _this.range.startContainer === currentParentLastChild ?
|
|
@@ -238,9 +238,14 @@ var EnterKeyAction = /** @class */ (function () {
|
|
|
238
238
|
_this.range.startOffset === _this.range.endOffset &&
|
|
239
239
|
_this.range.startOffset === isLastNodeLength) {
|
|
240
240
|
var focusBRElem = _this.parent.createElement('br');
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
241
|
+
if (currentParentLastChild.nodeName === 'BR' && currentParent.textContent.length === 0) {
|
|
242
|
+
_this.parent.formatter.editorManager.domNode.insertAfter(focusBRElem, currentParentLastChild);
|
|
243
|
+
}
|
|
244
|
+
else {
|
|
245
|
+
var lineBreakBRElem = _this.parent.createElement('br');
|
|
246
|
+
_this.parent.formatter.editorManager.domNode.insertAfter(focusBRElem, _this.range.startContainer);
|
|
247
|
+
_this.parent.formatter.editorManager.domNode.insertAfter(lineBreakBRElem, _this.range.startContainer);
|
|
248
|
+
}
|
|
244
249
|
_this.parent.formatter.editorManager.nodeSelection.setCursorPoint(_this.parent.contentModule.getDocument(), focusBRElem, 0);
|
|
245
250
|
}
|
|
246
251
|
else if (!isNOU(currentParent) && currentParent !== _this.parent.inputElement && currentParent.nodeName !== 'BR') {
|
|
@@ -231,7 +231,7 @@ var HtmlEditor = /** @class */ (function () {
|
|
|
231
231
|
if (liElement.previousElementSibling && liElement.previousElementSibling.childElementCount > 0) {
|
|
232
232
|
this.oldRangeElement = liElement.previousElementSibling.lastElementChild.nodeName === 'BR' ?
|
|
233
233
|
liElement.previousElementSibling : liElement.previousElementSibling.lastElementChild;
|
|
234
|
-
if (!isNullOrUndefined(liElement.lastElementChild)) {
|
|
234
|
+
if (!isNullOrUndefined(liElement.lastElementChild) && liElement.lastElementChild.nodeName !== 'BR') {
|
|
235
235
|
this.rangeElement = liElement.lastElementChild;
|
|
236
236
|
isLiElement = true;
|
|
237
237
|
}
|
|
@@ -613,26 +613,28 @@ var Image = /** @class */ (function () {
|
|
|
613
613
|
var src = this.deletedImg[i].src;
|
|
614
614
|
this.imageRemovePost(src);
|
|
615
615
|
}
|
|
616
|
-
if (
|
|
617
|
-
if (
|
|
618
|
-
if (
|
|
619
|
-
range.startContainer.previousElementSibling.
|
|
620
|
-
|
|
621
|
-
|
|
616
|
+
if (this.parent.editorMode !== 'Markdown') {
|
|
617
|
+
if (range.startContainer.nodeType === 3) {
|
|
618
|
+
if (originalEvent.code === 'Backspace') {
|
|
619
|
+
if (range.startContainer.previousElementSibling && range.startOffset === 0 &&
|
|
620
|
+
range.startContainer.previousElementSibling.classList.contains(classes.CLS_CAPTION) &&
|
|
621
|
+
range.startContainer.previousElementSibling.classList.contains(classes.CLS_CAPINLINE)) {
|
|
622
|
+
detach(range.startContainer.previousElementSibling);
|
|
623
|
+
}
|
|
622
624
|
}
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
625
|
+
else {
|
|
626
|
+
if (range.startContainer.nextElementSibling &&
|
|
627
|
+
range.endContainer.textContent.length === range.endOffset &&
|
|
628
|
+
range.startContainer.nextElementSibling.classList.contains(classes.CLS_CAPTION) &&
|
|
629
|
+
range.startContainer.nextElementSibling.classList.contains(classes.CLS_CAPINLINE)) {
|
|
630
|
+
detach(range.startContainer.nextElementSibling);
|
|
631
|
+
}
|
|
630
632
|
}
|
|
631
633
|
}
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
634
|
+
else if ((range.startContainer.nodeType === 1 &&
|
|
635
|
+
range.startContainer.querySelector('.' + classes.CLS_CAPTION + '.' + classes.CLS_CAPINLINE))) {
|
|
636
|
+
detach(range.startContainer.querySelector('.' + classes.CLS_CAPTION + '.' + classes.CLS_CAPINLINE));
|
|
637
|
+
}
|
|
636
638
|
}
|
|
637
639
|
break;
|
|
638
640
|
case 'insert-image':
|