@teachinglab/omd 0.7.25 → 0.7.26

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.
@@ -202,6 +202,11 @@ export class omdCanvas {
202
202
  this.focusFrameManager = new FocusFrameManager(this);
203
203
  }
204
204
 
205
+ // Keep the custom cursor above toolbar/buttons and all other SVG UI.
206
+ if (this.cursor && this.svg) {
207
+ this.cursor.attachTo(this.svg);
208
+ }
209
+
205
210
  // Apply any selection styles defined in config to the ResizeHandleManager
206
211
  // (PointerTool registers the manager on canvas.resizeHandleManager during its constructor)
207
212
  if (this.resizeHandleManager && this.config.selection) {
@@ -461,4 +461,13 @@ export class Cursor {
461
461
  this.element.parentNode.removeChild(this.element);
462
462
  }
463
463
  }
464
+
465
+ /**
466
+ * Reattach the cursor element to a specific parent so it can sit above other SVG UI.
467
+ * @param {SVGElement} parent
468
+ */
469
+ attachTo(parent) {
470
+ if (!parent || !this.element) return;
471
+ parent.appendChild(this.element);
472
+ }
464
473
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@teachinglab/omd",
3
- "version": "0.7.25",
3
+ "version": "0.7.26",
4
4
  "description": "omd",
5
5
  "main": "./index.js",
6
6
  "module": "./index.js",