MCPcopy Index your code
hub / github.com/gridstack/gridstack.js / _mouseMove

Method _mouseMove

src/dd-resizable-handle.ts:99–113  ·  view source on GitHub ↗

@internal

(e: MouseEvent)

Source from the content-addressed store, hash-verified

97
98 /** @internal */
99 protected _mouseMove(e: MouseEvent): void {
100 const s = this.mouseDownEvent;
101 if (this.moving) {
102 this._triggerEvent('move', e);
103 } else if (Math.abs(e.x - s.x) + Math.abs(e.y - s.y) > 2) {
104 // don't start unless we've moved at least 3 pixels
105 this.moving = true;
106 this._triggerEvent('start', this.mouseDownEvent);
107 this._triggerEvent('move', e);
108 // now track keyboard events to cancel
109 document.addEventListener('keydown', this._keyEvent);
110 }
111 e.stopPropagation();
112 // e.preventDefault(); passive = true
113 }
114
115 /** @internal */
116 protected _mouseUp(e: MouseEvent): void {

Callers

nothing calls this directly

Calls 1

_triggerEventMethod · 0.95

Tested by

no test coverage detected