diff --git a/README.md b/README.md index f7e19c1..c0c00b9 100644 --- a/README.md +++ b/README.md @@ -23,9 +23,11 @@ ComfyUI-NodeAligner is a lightweight ComfyUI layout plugin that includes feature Click on the blank space to deselect. 4. 如果没选中任何节点的情况下,点击左对齐这画布返回“0、0”坐标。 If no nodes are selected, clicking left alignment will return the canvas to "0,0" coordinates. +5. 点中对齐按钮中间的黑色分割线可实现组件的拖拽,进行移动。 + The black division line in the center of the right alignment button allows for component dragging and movement. - ps: 按住 Shift 进行拖拽可以对多个选择节点进行拖拽。 + ps: 按住 Shift 进行拖拽可以对多个选择节点同时进行拖拽。 ps: Hold Shift to drag and move multiple selected nodes. diff --git a/node_info.js b/node_info.js index b11800d..b59b4f0 100644 --- a/node_info.js +++ b/node_info.js @@ -58,11 +58,11 @@ const ButtonManager = { background-color: #555555; } .divider { - width: 2.5px; + width: 3.2px; height: 15px; background-color: #262626; margin: 5px 4px; - border-radius: 2.5px; + border-radius: 9px; cursor: grab; } .divider:active { @@ -392,10 +392,11 @@ function pollForCanvas() { const canvas = document.querySelector('canvas#graph-canvas'); if (canvas) { ButtonManager.show(); - // 监听左键单击事件 canvas.addEventListener('click', function (event) { event.preventDefault(); + // console.log(event.target.data); + // console.log(event); // 获取当前的 `LGraphCanvas` 数据 const current_node = event.target.data?.current_node;