@easy-editor/core 0.0.9 → 0.0.11

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/dist/index.js CHANGED
@@ -6907,9 +6907,6 @@ class NodeChildren {
6907
6907
  if (i === index) {
6908
6908
  return;
6909
6909
  }
6910
- if (index === i) {
6911
- return;
6912
- }
6913
6910
  children.splice(index, 1);
6914
6911
  children.splice(i, 0, node);
6915
6912
  }
@@ -7328,6 +7325,9 @@ let Node$1 = class Node {
7328
7325
  setExtraPropValue(key, value) {
7329
7326
  this.setPropValue(getConvertedExtraKey(key), value);
7330
7327
  }
7328
+ clearExtraPropValue(key) {
7329
+ this.getProp(getConvertedExtraKey(key), false)?.unset();
7330
+ }
7331
7331
  clearPropValue(path) {
7332
7332
  this.getProp(path, false)?.unset();
7333
7333
  }
@@ -7382,7 +7382,7 @@ let Node$1 = class Node {
7382
7382
  return false;
7383
7383
  }
7384
7384
  insert(node, ref, useMutator = true) {
7385
- if (ref && typeof ref === 'number') {
7385
+ if (ref !== undefined && typeof ref === 'number') {
7386
7386
  const nodeInstance = ensureNode(node, this.document);
7387
7387
  this.children?.internalInsert(nodeInstance, ref, useMutator);
7388
7388
  } else {
@@ -9023,7 +9023,7 @@ class Dragon {
9023
9023
  if (!dragObject) {
9024
9024
  return;
9025
9025
  }
9026
- this.boost(dragObject, e);
9026
+ this.boost(dragObject, e, shell);
9027
9027
  };
9028
9028
  if (eventType === 'drag') {
9029
9029
  shell.draggable = true;
@@ -9039,7 +9039,7 @@ class Dragon {
9039
9039
  };
9040
9040
  }
9041
9041
  }
9042
- boost(dragObject, boostEvent) {
9042
+ boost(dragObject, boostEvent, shell) {
9043
9043
  const {
9044
9044
  designer
9045
9045
  } = this;
@@ -9087,7 +9087,10 @@ class Dragon {
9087
9087
  doc.addEventListener('keydown', checkEsc, false);
9088
9088
  });
9089
9089
  }
9090
- this.emitter.emit(DRAGON_EVENT.DRAGSTART, locateEvent);
9090
+ this.emitter.emit(DRAGON_EVENT.DRAGSTART, {
9091
+ ...locateEvent,
9092
+ shell
9093
+ });
9091
9094
  };
9092
9095
  const move = e => {
9093
9096
  if (isBoostFromDragAPI) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@easy-editor/core",
3
- "version": "0.0.9",
3
+ "version": "0.0.11",
4
4
  "description": "A cross-framework low-code engine with scale-out design.",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",