@syncfusion/ej2-richtexteditor 20.1.58 → 20.1.61
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 +28 -0
- 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 +12 -4
- package/dist/es6/ej2-richtexteditor.es2015.js.map +1 -1
- package/dist/es6/ej2-richtexteditor.es5.js +9 -5
- 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 +10 -10
- package/src/editor-manager/plugin/ms-word-clean-up.js +1 -1
- package/src/rich-text-editor/base/interface.d.ts +1 -0
- package/src/rich-text-editor/base/rich-text-editor.d.ts +5 -0
- package/src/rich-text-editor/base/rich-text-editor.js +2 -1
- package/src/rich-text-editor/renderer/iframe-content-renderer.js +1 -1
- package/src/rich-text-editor/renderer/image-module.js +5 -2
|
@@ -15745,7 +15745,7 @@ class MsWordPaste {
|
|
|
15745
15745
|
this.checkVShape(elm);
|
|
15746
15746
|
let imgElem = elm.querySelectorAll('img');
|
|
15747
15747
|
for (let i = 0; i < imgElem.length; i++) {
|
|
15748
|
-
if (!isNullOrUndefined(imgElem[i].getAttribute('v:shapes')) && imgElem[i].getAttribute('v:shapes').indexOf('Picture') < 0) {
|
|
15748
|
+
if (!isNullOrUndefined(imgElem[i].getAttribute('v:shapes')) && imgElem[i].getAttribute('v:shapes').indexOf('Picture') < 0 && imgElem[i].getAttribute('v:shapes').indexOf('Image') < 0) {
|
|
15749
15749
|
detach(imgElem[i]);
|
|
15750
15750
|
}
|
|
15751
15751
|
}
|
|
@@ -17066,6 +17066,10 @@ const IFRAMEHEADER = `
|
|
|
17066
17066
|
body{color:#333;word-wrap:break-word;padding: 8px;box-sizing: border-box;}
|
|
17067
17067
|
.e-rte-image {border: 0;cursor: pointer;display:
|
|
17068
17068
|
block;float: none;height: auto;margin: 5px auto;max-width: 100%;position: relative;}
|
|
17069
|
+
.e-rte-image.e-imginline {display: inline-block;float: none;max-width: calc(100% - (2 * 5px));padding: 1px;vertical-align: bottom;}
|
|
17070
|
+
.e-rte-image.e-imgcenter {cursor: pointer;display: block;float: none;margin: 5px auto;max-width: 100%;position: relative;}
|
|
17071
|
+
.e-rte-image.e-imgright { float: right; margin: 0 auto;margin-left: 5px;text-align: right;}
|
|
17072
|
+
.e-rte-image.e-imgleft {float: left;margin: 0 auto;margin-right: 5px;text-align: left;}
|
|
17069
17073
|
.e-img-caption { display: inline-block; float: none; margin: 5px auto; max-width: 100%;position: relative;}
|
|
17070
17074
|
.e-img-caption.e-caption-inline {display: inline-block;float: none;
|
|
17071
17075
|
margin: 5px auto;margin-left: 5px;margin-right: 5px;max-width: calc(100% - (2 * 5px));
|
|
@@ -21590,6 +21594,9 @@ class Image {
|
|
|
21590
21594
|
if (target.nodeName === 'IMG') {
|
|
21591
21595
|
this.imgEle = target;
|
|
21592
21596
|
}
|
|
21597
|
+
if (target.nodeName !== '#document') {
|
|
21598
|
+
this.parent.currentTarget = e.target;
|
|
21599
|
+
}
|
|
21593
21600
|
if (!isNullOrUndefined(this.dialogObj) && ((
|
|
21594
21601
|
// eslint-disable-next-line
|
|
21595
21602
|
!closest(target, '[id=' + "'" + this.dialogObj.element.id + "'" + ']') && this.parent.toolbarSettings.enable && this.parent.getToolbarElement() &&
|
|
@@ -21607,12 +21614,12 @@ class Image {
|
|
|
21607
21614
|
}
|
|
21608
21615
|
/* eslint-enable */
|
|
21609
21616
|
}
|
|
21610
|
-
if (e.target.tagName !== 'IMG' && this.imgResizeDiv && !(this.quickToolObj &&
|
|
21617
|
+
if (!(this.parent.iframeSettings.enable && this.parent.currentTarget.nodeName === 'IMG') && e.target.tagName !== 'IMG' && this.imgResizeDiv && !(this.quickToolObj &&
|
|
21611
21618
|
this.quickToolObj.imageQTBar && this.quickToolObj.imageQTBar.element.contains(e.target)) &&
|
|
21612
21619
|
this.contentModule.getEditPanel().contains(this.imgResizeDiv)) {
|
|
21613
21620
|
this.cancelResizeAction();
|
|
21614
21621
|
}
|
|
21615
|
-
if (this.contentModule.getEditPanel().querySelector('.e-img-resize')) {
|
|
21622
|
+
if (this.contentModule.getEditPanel().querySelector('.e-img-resize') && !(this.parent.iframeSettings.enable && this.parent.currentTarget.nodeName === 'IMG')) {
|
|
21616
21623
|
if (target.tagName !== 'IMG') {
|
|
21617
21624
|
this.removeResizeEle();
|
|
21618
21625
|
}
|
|
@@ -25383,7 +25390,7 @@ let RichTextEditor = class RichTextEditor extends Component {
|
|
|
25383
25390
|
range.endContainer;
|
|
25384
25391
|
let closestLI = closest(endNode, 'LI');
|
|
25385
25392
|
if (!isNullOrUndefined(closestLI) && endNode.textContent.length === range.endOffset &&
|
|
25386
|
-
!range.collapsed) {
|
|
25393
|
+
!range.collapsed && isNullOrUndefined(endNode.nextElementSibling)) {
|
|
25387
25394
|
closestLI.textContent = closestLI.textContent.trim();
|
|
25388
25395
|
currentEndOffset = closestLI.textContent.length - 1;
|
|
25389
25396
|
let currentLastElem = closestLI;
|
|
@@ -27001,6 +27008,7 @@ let RichTextEditor = class RichTextEditor extends Component {
|
|
|
27001
27008
|
}
|
|
27002
27009
|
onIframeMouseDown(e) {
|
|
27003
27010
|
this.isBlur = false;
|
|
27011
|
+
this.currentTarget = e.target;
|
|
27004
27012
|
this.notify(iframeMouseDown, e);
|
|
27005
27013
|
}
|
|
27006
27014
|
editorKeyDown(e) {
|