fix: @contextmenu.prevent remis (avait été perdu lors du revert)
- Erreur critique: @contextmenu.prevent="onContextMenu" manquait → le handler n'était JAMAIS appelé par Alpine - Rajouté @contextmenu.prevent sur ws-split (entre @keydown et @click.self) - ctxMenu utilise mutations individuelles (pas de remplacement d'objet) pour une meilleure réactivité Alpine - @click.self conserve la fermeture en cliquant sur le fond du workspace
This commit is contained in:
+1
-1
@@ -39,7 +39,7 @@ async def lifespan(_app: FastAPI):
|
|||||||
|
|
||||||
app = FastAPI(
|
app = FastAPI(
|
||||||
title="FlowDeck",
|
title="FlowDeck",
|
||||||
version="2.4.3",
|
version="2.4.4",
|
||||||
docs_url="/docs" if settings.log_level == "DEBUG" else None,
|
docs_url="/docs" if settings.log_level == "DEBUG" else None,
|
||||||
redoc_url=None,
|
redoc_url=None,
|
||||||
lifespan=lifespan,
|
lifespan=lifespan,
|
||||||
|
|||||||
@@ -341,6 +341,7 @@
|
|||||||
@dragleave="onDragLeave($event)"
|
@dragleave="onDragLeave($event)"
|
||||||
@drop.prevent="onDrop($event)"
|
@drop.prevent="onDrop($event)"
|
||||||
@keydown="onKeydown($event)"
|
@keydown="onKeydown($event)"
|
||||||
|
@contextmenu.prevent="onContextMenu($event)"
|
||||||
@click.self="ctxMenu.visible = false"
|
@click.self="ctxMenu.visible = false"
|
||||||
tabindex="0"
|
tabindex="0"
|
||||||
x-ref="layout">
|
x-ref="layout">
|
||||||
@@ -1267,13 +1268,11 @@ document.addEventListener('alpine:init', function() {
|
|||||||
if (!id) { this.ctxMenu.visible = false; return; }
|
if (!id) { this.ctxMenu.visible = false; return; }
|
||||||
var node = this._findNodeById(this.displayTree, id);
|
var node = this._findNodeById(this.displayTree, id);
|
||||||
if (!node) { this.ctxMenu.visible = false; return; }
|
if (!node) { this.ctxMenu.visible = false; return; }
|
||||||
this.ctxMenu = {
|
this.ctxMenu.visible = true;
|
||||||
visible: true,
|
this.ctxMenu.x = ev.clientX;
|
||||||
x: ev.clientX,
|
this.ctxMenu.y = ev.clientY;
|
||||||
y: ev.clientY,
|
this.ctxMenu.node = node;
|
||||||
node: node,
|
this.ctxMenu.tags = [...(node.tags||[])];
|
||||||
tags: [...(node.tags||[])]
|
|
||||||
};
|
|
||||||
this.ctxTagAdding = false;
|
this.ctxTagAdding = false;
|
||||||
this.ctxTagExistingOpen = false;
|
this.ctxTagExistingOpen = false;
|
||||||
this.ctxNewTagColor = '#787774';
|
this.ctxNewTagColor = '#787774';
|
||||||
|
|||||||
Reference in New Issue
Block a user