fabric-vectr 6.7.8 → 6.7.9

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.mjs CHANGED
@@ -360,7 +360,7 @@ class Cache {
360
360
  }
361
361
  const cache = new Cache();
362
362
 
363
- var version = "6.7.8";
363
+ var version = "6.7.9";
364
364
 
365
365
  // use this syntax so babel plugin see this import here
366
366
  const VERSION = version;
@@ -3075,7 +3075,7 @@ class StaticCanvas extends createCollectionMixin(CommonMethods) {
3075
3075
  if (!isTextObject(instance) || !instance.path) {
3076
3076
  continue;
3077
3077
  }
3078
- let pathId = `TEXTPATH_${uid()}`;
3078
+ let pathId = `TEXTPATH_${instance.id}`;
3079
3079
  let pathMarkup = instance.path._toSVG();
3080
3080
  let index = pathMarkup.indexOf('COMMON_PARTS');
3081
3081
  // 加上id, 和路径偏移
@@ -14198,7 +14198,9 @@ class SelectableCanvas extends StaticCanvas {
14198
14198
  activeObject = this._activeObject,
14199
14199
  aObjects = this.getActiveObjects();
14200
14200
  this.targets = [];
14201
- if (activeObject && aObjects.length >= 1 && !this._fixedSearchTargets) {
14201
+
14202
+ // valid _fixedSearchTargets is null or _fixedSearchTargets includes activeObject
14203
+ if (activeObject && aObjects.length >= 1 && (!this._fixedSearchTargets || this._fixedSearchTargets.includes(activeObject))) {
14202
14204
  if (activeObject.findControl(pointer, isTouchEvent(e))) {
14203
14205
  // if we hit the corner of the active object, let's return that.
14204
14206
  return activeObject;