hoeditor-web 2.0.52 → 2.0.53
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/lib/hoeditor.common.js +47 -24
- package/lib/hoeditor.css +2 -853
- package/lib/hoeditor.umd.js +47 -24
- package/lib/hoeditor.umd.min.js +2 -2
- package/package.json +1 -1
package/lib/hoeditor.umd.js
CHANGED
|
@@ -62722,7 +62722,7 @@ var NodesDeleteUndoUnit = /*#__PURE__*/function () {
|
|
|
62722
62722
|
//if(nodes.length == 0) return;
|
|
62723
62723
|
|
|
62724
62724
|
if (!(hoEditorFactory.drawTree.paintStatus !== _draw_drawTree_DrawTree__WEBPACK_IMPORTED_MODULE_15__/* .PaintState.psDesign */ .Dh.psDesign && !this._isForceDelete)) {
|
|
62725
|
-
_context.next =
|
|
62725
|
+
_context.next = 33;
|
|
62726
62726
|
break;
|
|
62727
62727
|
}
|
|
62728
62728
|
|
|
@@ -62730,19 +62730,29 @@ var NodesDeleteUndoUnit = /*#__PURE__*/function () {
|
|
|
62730
62730
|
|
|
62731
62731
|
case 13:
|
|
62732
62732
|
if (!(n < nodes.length)) {
|
|
62733
|
-
_context.next =
|
|
62733
|
+
_context.next = 33;
|
|
62734
62734
|
break;
|
|
62735
62735
|
}
|
|
62736
62736
|
|
|
62737
62737
|
node = nodes[n];
|
|
62738
62738
|
|
|
62739
|
+
if (!(node instanceof _dom_treeNode_MarkNode__WEBPACK_IMPORTED_MODULE_21__/* .MarkNode */ .j && node.parentNode instanceof _dom_treeNode_TextInputFieldNode__WEBPACK_IMPORTED_MODULE_20__/* .TextInputFieldNode */ .re && node.MarkNodeType === 1 && !node.parentNode.isAllowDelete)) {
|
|
62740
|
+
_context.next = 18;
|
|
62741
|
+
break;
|
|
62742
|
+
}
|
|
62743
|
+
|
|
62744
|
+
element_ui_lib_message_box__WEBPACK_IMPORTED_MODULE_1___default().alert("元素已设置为不允许删除。请先右键元素属性设置成允许删除,再进行删除操作。", "系统提示");
|
|
62745
|
+
|
|
62746
|
+
return _context.abrupt("return", 0);
|
|
62747
|
+
|
|
62748
|
+
case 18:
|
|
62739
62749
|
if (!(node instanceof _dom_treeNode_ControlNode__WEBPACK_IMPORTED_MODULE_28__/* .ControlNode */ .w || node instanceof _dom_treeNode_TextInputFieldNode__WEBPACK_IMPORTED_MODULE_20__/* .TextInputFieldNode */ .re)) {
|
|
62740
|
-
_context.next =
|
|
62750
|
+
_context.next = 27;
|
|
62741
62751
|
break;
|
|
62742
62752
|
}
|
|
62743
62753
|
|
|
62744
62754
|
if (node.isAllowDelete) {
|
|
62745
|
-
_context.next =
|
|
62755
|
+
_context.next = 27;
|
|
62746
62756
|
break;
|
|
62747
62757
|
}
|
|
62748
62758
|
|
|
@@ -62768,9 +62778,9 @@ var NodesDeleteUndoUnit = /*#__PURE__*/function () {
|
|
|
62768
62778
|
|
|
62769
62779
|
return _context.abrupt("return", 0);
|
|
62770
62780
|
|
|
62771
|
-
case
|
|
62781
|
+
case 27:
|
|
62772
62782
|
if (!(node instanceof _dom_treeNode_SignNode__WEBPACK_IMPORTED_MODULE_33__/* .SignNode */ .N && node.isTemplate && node.number === 0)) {
|
|
62773
|
-
_context.next =
|
|
62783
|
+
_context.next = 30;
|
|
62774
62784
|
break;
|
|
62775
62785
|
}
|
|
62776
62786
|
|
|
@@ -62778,16 +62788,16 @@ var NodesDeleteUndoUnit = /*#__PURE__*/function () {
|
|
|
62778
62788
|
|
|
62779
62789
|
return _context.abrupt("return", 0);
|
|
62780
62790
|
|
|
62781
|
-
case
|
|
62791
|
+
case 30:
|
|
62782
62792
|
n++;
|
|
62783
62793
|
_context.next = 13;
|
|
62784
62794
|
break;
|
|
62785
62795
|
|
|
62786
|
-
case
|
|
62796
|
+
case 33:
|
|
62787
62797
|
pnode = (_currRange$npEnd$node = currRange.npEnd.node) === null || _currRange$npEnd$node === void 0 ? void 0 : _currRange$npEnd$node.parentNode;
|
|
62788
62798
|
|
|
62789
62799
|
if (!(pnode && pnode instanceof _dom_treeNode_TextInputFieldNode__WEBPACK_IMPORTED_MODULE_20__/* .TextInputFieldNode */ .re && currRange.npEnd.path != hoEditorFactory.docTree.getNodeLastPath(pnode))) {
|
|
62790
|
-
_context.next =
|
|
62800
|
+
_context.next = 39;
|
|
62791
62801
|
break;
|
|
62792
62802
|
}
|
|
62793
62803
|
|
|
@@ -62800,24 +62810,24 @@ var NodesDeleteUndoUnit = /*#__PURE__*/function () {
|
|
|
62800
62810
|
});
|
|
62801
62811
|
|
|
62802
62812
|
if (_res[0]) {
|
|
62803
|
-
_context.next =
|
|
62813
|
+
_context.next = 39;
|
|
62804
62814
|
break;
|
|
62805
62815
|
}
|
|
62806
62816
|
|
|
62807
62817
|
return _context.abrupt("return");
|
|
62808
62818
|
|
|
62809
|
-
case
|
|
62819
|
+
case 39:
|
|
62810
62820
|
changeEvent = new _events_NodeChangeEvent__WEBPACK_IMPORTED_MODULE_14__/* .NodeChangeEvent */ .G(this._hoEditorFactoryID, _editor_dom_DocTree__WEBPACK_IMPORTED_MODULE_12__/* .DocAction.daUndoInsert */ .gk.daUndoInsert, currRange.startPath, ""); //FIXME:deleteRange函数完成后调用这个
|
|
62811
62821
|
// hoEditorFactory.docTree.deleteRange(arange.startPath, arange.endPath);
|
|
62812
62822
|
|
|
62813
62823
|
if (currRange.npStart.node && currRange.npEnd.node) {
|
|
62814
|
-
_context.next =
|
|
62824
|
+
_context.next = 42;
|
|
62815
62825
|
break;
|
|
62816
62826
|
}
|
|
62817
62827
|
|
|
62818
62828
|
throw _events_Exception__WEBPACK_IMPORTED_MODULE_22__/* .Exception.NodeNotFound */ .P.NodeNotFound();
|
|
62819
62829
|
|
|
62820
|
-
case
|
|
62830
|
+
case 42:
|
|
62821
62831
|
// const [startPath, endPath] = DomRange.skipStartEndTablePath(
|
|
62822
62832
|
// this._hoEditorFactory,
|
|
62823
62833
|
// currRange.startPath,
|
|
@@ -62830,33 +62840,33 @@ var NodesDeleteUndoUnit = /*#__PURE__*/function () {
|
|
|
62830
62840
|
res = this.deleteRange(currRange.endPath, currRange.startPath);
|
|
62831
62841
|
|
|
62832
62842
|
if (!(res == 1)) {
|
|
62833
|
-
_context.next =
|
|
62843
|
+
_context.next = 54;
|
|
62834
62844
|
break;
|
|
62835
62845
|
}
|
|
62836
62846
|
|
|
62837
62847
|
changeEvent.beforeChangePath = startPath;
|
|
62838
62848
|
changeEvent.afterChangePath = this._tmp.start;
|
|
62839
|
-
_context.next =
|
|
62849
|
+
_context.next = 52;
|
|
62840
62850
|
return hoEditorFactory.docTree.change(changeEvent);
|
|
62841
62851
|
|
|
62842
|
-
case
|
|
62852
|
+
case 52:
|
|
62843
62853
|
cgEvent = new _events_SelectionChangeEvent__WEBPACK_IMPORTED_MODULE_18__/* .SelectionChangeEvent */ .r(hoEditorFactory.docTree.curDomRange, new _dom_DomRange__WEBPACK_IMPORTED_MODULE_16__/* .DomRange */ .a(this._hoEditorFactoryID, this._tmp.start, this._tmp.start));
|
|
62844
62854
|
hoEditorFactory.docTree.selectChange(cgEvent);
|
|
62845
62855
|
|
|
62846
|
-
case
|
|
62856
|
+
case 54:
|
|
62847
62857
|
hoEditorFactory.docTree.curDomRange.setSamePath(this._tmp.start);
|
|
62848
62858
|
hoEditorFactory.drawTree.moveCaretToPath(this._tmp.start);
|
|
62849
62859
|
aNode = currRange.npStart.node;
|
|
62850
62860
|
|
|
62851
62861
|
if (!(aNode && pnode)) {
|
|
62852
|
-
_context.next =
|
|
62862
|
+
_context.next = 60;
|
|
62853
62863
|
break;
|
|
62854
62864
|
}
|
|
62855
62865
|
|
|
62856
|
-
_context.next =
|
|
62866
|
+
_context.next = 60;
|
|
62857
62867
|
return this.ParentRepaint(pnode);
|
|
62858
62868
|
|
|
62859
|
-
case
|
|
62869
|
+
case 60:
|
|
62860
62870
|
case "end":
|
|
62861
62871
|
return _context.stop();
|
|
62862
62872
|
}
|
|
@@ -206691,7 +206701,7 @@ var SignNode = __webpack_require__(78975);
|
|
|
206691
206701
|
// EXTERNAL MODULE: ./src/editor/dom/treeNode/ParagraphNode.ts
|
|
206692
206702
|
var ParagraphNode = __webpack_require__(13880);
|
|
206693
206703
|
;// CONCATENATED MODULE: ./src/components/version.ts
|
|
206694
|
-
/* harmony default export */ var version = ('2.0.
|
|
206704
|
+
/* harmony default export */ var version = ('2.0.53');
|
|
206695
206705
|
;// CONCATENATED MODULE: ./node_modules/@vue/vue-loader-v15/lib/loaders/templateLoader.js??vue-loader-options!./node_modules/@vue/vue-loader-v15/lib/index.js??vue-loader-options!./src/components/controls/poperTipText/PoperTipText.vue?vue&type=template&id=3fa4e4d3&scoped=true&
|
|
206696
206706
|
var PoperTipTextvue_type_template_id_3fa4e4d3_scoped_true_render = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('div',{directives:[{name:"show",rawName:"v-show",value:(_vm.isShow),expression:"isShow"},{name:"click-outside",rawName:"v-click-outside",value:(_vm.handleClose),expression:"handleClose"}],ref:"poperTextNode",staticClass:"poper-text-modal animation-in",style:(_vm.posStyle),on:{"mouseenter":_vm.mouseEnter,"mouseleave":_vm.mouseLeave}},_vm._l((_vm.poperText),function(text){return _c('div',{key:text + Math.random(0, 1),staticClass:"poper-text"},[_vm._v(" "+_vm._s(text)+" ")])}),0)}
|
|
206697
206707
|
var PoperTipTextvue_type_template_id_3fa4e4d3_scoped_true_staticRenderFns = []
|
|
@@ -209603,6 +209613,14 @@ var HTMLconverter2 = /*#__PURE__*/function () {
|
|
|
209603
209613
|
return tmp;
|
|
209604
209614
|
} else {
|
|
209605
209615
|
for (var i = 0; i < jnode.childNodes.length; i++) {
|
|
209616
|
+
if (jnode.childNodes[i].nodeName.toLowerCase() == "img") {
|
|
209617
|
+
var src = jnode.childNodes[i].src;
|
|
209618
|
+
|
|
209619
|
+
if (src && src.toString().substring(src.length - 4, src.length) === ".svg") {
|
|
209620
|
+
continue;
|
|
209621
|
+
}
|
|
209622
|
+
}
|
|
209623
|
+
|
|
209606
209624
|
var fun = this.convert.get(jnode.childNodes[i].nodeName.toLowerCase());
|
|
209607
209625
|
|
|
209608
209626
|
if (fun) {
|
|
@@ -209863,7 +209881,7 @@ var HTMLconverter2 = /*#__PURE__*/function () {
|
|
|
209863
209881
|
|
|
209864
209882
|
var width = styleobj.width ? styleobj.width.replace("px", "") : 20;
|
|
209865
209883
|
var height = styleobj.height ? styleobj.height.replace("px", "") : 20;
|
|
209866
|
-
var node = new ImageNode/* ImageNode */.H(this._hoEditorFactoryID, HOEditorFactorys/* HOEditorFactorys.instance */.b.instance().getFactory(this._hoEditorFactoryID).docTree.activeNodes, null, BaseNode/* NodeType.ntImage */.Jq.ntImage, HOEditorFactorys/* HOEditorFactorys.instance */.b.instance().getFactory(this._hoEditorFactoryID).gernerateCode.generateID("IMG"), jquery_default()(jnode).attr("src") || "", width, height);
|
|
209884
|
+
var node = new ImageNode/* ImageNode */.H(this._hoEditorFactoryID, HOEditorFactorys/* HOEditorFactorys.instance */.b.instance().getFactory(this._hoEditorFactoryID).docTree.activeNodes, null, BaseNode/* NodeType.ntImage */.Jq.ntImage, HOEditorFactorys/* HOEditorFactorys.instance */.b.instance().getFactory(this._hoEditorFactoryID).gernerateCode.generateID("IMG"), jquery_default()(jnode).attr("src") || "", Number(width), Number(height));
|
|
209867
209885
|
return [node];
|
|
209868
209886
|
}
|
|
209869
209887
|
}, {
|
|
@@ -210077,7 +210095,8 @@ var HTMLconverter2 = /*#__PURE__*/function () {
|
|
|
210077
210095
|
var textstyle = this.HTMLStyleToParsStyle(styleobj);
|
|
210078
210096
|
if (textstyle.lineSpace === 0) textstyle.lineSpace = undefined;
|
|
210079
210097
|
var index = hoEditorFactory.docTree.styleCompare(textstyle);
|
|
210080
|
-
var node = new ParagraphNode/* ParagraphNode */.C(this._hoEditorFactoryID, hoEditorFactory.docTree.activeNodes, hoEditorFactory.docTree.getParentNode(HOEditorFactorys/* HOEditorFactorys.instance */.b.instance().getFactory(this._hoEditorFactoryID).docTree.curDomRange.normalize().startPath), index
|
|
210098
|
+
var node = new ParagraphNode/* ParagraphNode */.C(this._hoEditorFactoryID, hoEditorFactory.docTree.activeNodes, hoEditorFactory.docTree.getParentNode(HOEditorFactorys/* HOEditorFactorys.instance */.b.instance().getFactory(this._hoEditorFactoryID).docTree.curDomRange.normalize().startPath), index //hoEditorFactory.docTree.curParaNo
|
|
210099
|
+
);
|
|
210081
210100
|
tmp.push(node);
|
|
210082
210101
|
|
|
210083
210102
|
if (jnode.childNodes.length == 0) {
|
|
@@ -213263,7 +213282,7 @@ var NodeConvert = /*#__PURE__*/function () {
|
|
|
213263
213282
|
if (!uidArr[i]) continue;
|
|
213264
213283
|
|
|
213265
213284
|
if (i > 0) {
|
|
213266
|
-
var paraNode = new ParagraphNode/* ParagraphNode */.C(this._hoEditorFactoryID, hoEditorFactory.docTree.mainNodes, null,
|
|
213285
|
+
var paraNode = new ParagraphNode/* ParagraphNode */.C(this._hoEditorFactoryID, hoEditorFactory.docTree.mainNodes, null, hoEditorFactory.docTree.curParaNo);
|
|
213267
213286
|
nodes.push(paraNode);
|
|
213268
213287
|
}
|
|
213269
213288
|
|
|
@@ -221242,6 +221261,10 @@ var EditController = /*#__PURE__*/function () {
|
|
|
221242
221261
|
for (var n = 0; n < nodes.length; n++) {
|
|
221243
221262
|
var node = nodes[n];
|
|
221244
221263
|
if (node instanceof ParagraphNode/* ParagraphNode */.C || node instanceof TextNode/* TextNode */.R || node instanceof MarkNode/* MarkNode */.j || node instanceof ControlNode/* ControlNode */.w) node.styleIndex = hoeditorfactory.docTree.curStyleIndex;
|
|
221264
|
+
|
|
221265
|
+
if (node instanceof ParagraphNode/* ParagraphNode */.C) {
|
|
221266
|
+
node.paraNo = hoeditorfactory.docTree.curParaNo;
|
|
221267
|
+
}
|
|
221245
221268
|
}
|
|
221246
221269
|
}
|
|
221247
221270
|
|