@hailin-zheng/editor-core 1.1.30 → 1.1.31

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/index-cjs.js CHANGED
@@ -709,10 +709,6 @@ function appendToOps(doc, ele, ops) {
709
709
  ele,
710
710
  ops
711
711
  };
712
- if (log.prevIndex === -1) {
713
- const nextEle = ElementUtil.getNextSiblingElement(ele);
714
- log.nextIndex = nextEle ? ElementUtil.getControlIndex(nextEle, true) : -1;
715
- }
716
712
  array.push(log);
717
713
  }
718
714
  function inputText(ele, startIndex, input) {
@@ -803,14 +799,15 @@ function generatePatch(doc) {
803
799
  if (!ops || !ops.length) {
804
800
  return [];
805
801
  }
806
- const delOpsMap = getDeleteEleOps(ops);
802
+ getDeleteEleOps(ops);
807
803
  for (let i = 0; i < ops.length; i++) {
808
804
  const op = ops[i];
809
805
  const ele = op.ele;
810
806
  //修改样式
811
807
  if ('format' in op.ops) {
812
808
  //修改插入或者删除的不做处理
813
- if (insertOpsMap.has(ele) || delOpsMap.has(ele)) {
809
+ //|| delOpsMap.has(ele)
810
+ if (insertOpsMap.has(ele)) {
814
811
  continue;
815
812
  }
816
813
  //合并操作属性
@@ -5147,8 +5144,8 @@ class TableUtil {
5147
5144
  const hMergeEndIndex = this.getHMergeEndIndex(tb, i, colIndex);
5148
5145
  //当前单元格处于合并行的最后一行,并且合并的行数为2行
5149
5146
  if (hMergeEndIndex === colIndex && hMergeEndIndex - hMergeStartIndex === 1) {
5150
- const masterVMergeCell = tb.getChild(hMergeStartIndex).getChild(i);
5151
- masterVMergeCell.props.hMerge = null;
5147
+ const masterHMergeCell = tb.getChild(i).getChild(hMergeStartIndex);
5148
+ masterHMergeCell.props.hMerge = null;
5152
5149
  }
5153
5150
  }
5154
5151
  row.removeChild(cell);