mirror of
https://github.com/grafana/grafana.git
synced 2026-09-05 04:40:13 -05:00
Canvas: Overlapping elements bugfix (#52343)
This commit is contained in:
@@ -311,6 +311,8 @@ export class Scene {
|
||||
container: this.div,
|
||||
selectableTargets: targetElements,
|
||||
toggleContinueSelect: 'shift',
|
||||
selectFromInside: false,
|
||||
hitRate: 0,
|
||||
});
|
||||
|
||||
this.moveable = new Moveable(this.div!, {
|
||||
@@ -420,12 +422,15 @@ export class Scene {
|
||||
targets = event.selected;
|
||||
this.updateSelection({ targets });
|
||||
|
||||
if (event.isDragStart) {
|
||||
event.inputEvent.preventDefault();
|
||||
setTimeout(() => {
|
||||
this.moveable!.dragStart(event.inputEvent);
|
||||
});
|
||||
}
|
||||
// @TODO Figure out click-drag functionality without phantom mouseup issue
|
||||
// https://github.com/daybrush/moveable/issues/481
|
||||
|
||||
// if (event.isDragStart) {
|
||||
// event.inputEvent.preventDefault();
|
||||
// setTimeout(() => {
|
||||
// this.moveable!.dragStart(event.inputEvent);
|
||||
// });
|
||||
// }
|
||||
});
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user