Skip to content

fix: move selected groups when dragging nodes in vueNodes mode#7306

Merged
christian-byrne merged 1 commit intomainfrom
group-move-vueNodes
Dec 10, 2025
Merged

fix: move selected groups when dragging nodes in vueNodes mode#7306
christian-byrne merged 1 commit intomainfrom
group-move-vueNodes

Conversation

@jtydhr88
Copy link
Collaborator

@jtydhr88 jtydhr88 commented Dec 10, 2025

Summary

Captures selected groups at drag start and moves them using frame delta to match LiteGraph's behavior.

Litegraph doesn't have this issue.

Screenshots (if applicable)

Before

2025-12-09.21-25-05.mp4

After

2025-12-09.21-24-02.mp4

┆Issue is synchronized with this Notion page by Unito

@jtydhr88 jtydhr88 requested a review from a team as a code owner December 10, 2025 02:27
@dosubot dosubot bot added the size:S This PR changes 10-29 lines, ignoring generated files. label Dec 10, 2025
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Dec 10, 2025

📝 Walkthrough

Walkthrough

Adds support for dragging LGraphGroup items alongside nodes in the node drag handler. Implementation tracks selected groups and applies delta-based movement to groups during drag operations, with cleanup on drag end. Existing per-node movement logic remains unchanged.

Changes

Cohort / File(s) Summary
Node Drag Handler Enhancement
src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
Extends drag functionality to support moving selected groups alongside individual nodes. Introduces selectedGroups and lastCanvasDelta state variables to track groups and compute frame-based movement deltas. Initializes these values on drag start, applies delta-based moves to groups during drag, and resets state on drag end. Imports LGraphGroup type and isLGraphGroup helper for group detection.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment
  • Commit unit tests in branch group-move-vueNodes

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@github-actions
Copy link

github-actions bot commented Dec 10, 2025

🎨 Storybook Build Status

Build completed successfully!

⏰ Completed at: 12/10/2025, 02:29:23 AM UTC

🔗 Links


🎉 Your Storybook is ready for review!

@github-actions
Copy link

github-actions bot commented Dec 10, 2025

🎭 Playwright Test Results

Some tests failed

⏰ Completed at: 12/10/2025, 03:15:53 AM UTC

📈 Summary

  • Total Tests: 490
  • Passed: 471 ✅
  • Failed: 1 ❌
  • Flaky: 9 ⚠️
  • Skipped: 9 ⏭️

📊 Test Reports by Browser

  • chromium: View Report • ✅ 462 / ❌ 1 / ⚠️ 9 / ⏭️ 9
  • chromium-2x: View Report • ✅ 2 / ❌ 0 / ⚠️ 0 / ⏭️ 0
  • chromium-0.5x: View Report • ✅ 1 / ❌ 0 / ⚠️ 0 / ⏭️ 0
  • mobile-chrome: View Report • ✅ 6 / ❌ 0 / ⚠️ 0 / ⏭️ 0

🎉 Click on the links above to view detailed test results for each browser configuration.

@github-actions
Copy link

Bundle Size Report

Summary

  • Raw size: 17.1 MB baseline 17.1 MB — 🔴 +602 B
  • Gzip: 3.39 MB baseline 3.39 MB — 🔴 +201 B
  • Brotli: 2.6 MB baseline 2.6 MB — 🔴 +298 B
  • Bundles: 97 current • 97 baseline • 37 added / 37 removed

Category Glance
Graph Workspace 🔴 +602 B (988 kB) · Vendor & Third-Party ⚪ 0 B (8.56 MB) · Other ⚪ 0 B (3.81 MB) · App Entry Points ⚪ 0 B (3.22 MB) · Panels & Settings ⚪ 0 B (298 kB) · UI Components ⚪ 0 B (178 kB) · + 3 more

Per-category breakdown
App Entry Points — 3.22 MB (baseline 3.22 MB) • ⚪ 0 B

Main entry bundles and manifests

File Before After Δ Raw Δ Gzip Δ Brotli
assets/index-9Xh1drj8.js (new) 3 MB 🔴 +3 MB 🔴 +623 kB 🔴 +474 kB
assets/index-CDex3DwY.js (removed) 3 MB 🟢 -3 MB 🟢 -623 kB 🟢 -474 kB
assets/index-BBj0epJv.js (removed) 223 kB 🟢 -223 kB 🟢 -47.6 kB 🟢 -39.3 kB
assets/index-BIXWxKo-.js (new) 223 kB 🔴 +223 kB 🔴 +47.6 kB 🔴 +39.3 kB
assets/index-CzFyL3YV.js (new) 345 B 🔴 +345 B 🔴 +247 B 🔴 +234 B
assets/index-nrA6lnea.js (removed) 345 B 🟢 -345 B 🟢 -244 B 🟢 -231 B

Status: 3 added / 3 removed

Graph Workspace — 988 kB (baseline 988 kB) • 🔴 +602 B

Graph editor runtime, canvas, workflow orchestration

File Before After Δ Raw Δ Gzip Δ Brotli
assets/GraphView-ZKocGFzm.js (new) 988 kB 🔴 +988 kB 🔴 +191 kB 🔴 +146 kB
assets/GraphView-Dw28xL1J.js (removed) 988 kB 🟢 -988 kB 🟢 -191 kB 🟢 -145 kB

Status: 1 added / 1 removed

Views & Navigation — 6.54 kB (baseline 6.54 kB) • ⚪ 0 B

Top-level views, pages, and routed surfaces

File Before After Δ Raw Δ Gzip Δ Brotli
assets/UserSelectView-CzCZHh-z.js (new) 6.54 kB 🔴 +6.54 kB 🔴 +2.14 kB 🔴 +1.9 kB
assets/UserSelectView-DXC8etFo.js (removed) 6.54 kB 🟢 -6.54 kB 🟢 -2.14 kB 🟢 -1.9 kB

Status: 1 added / 1 removed

Panels & Settings — 298 kB (baseline 298 kB) • ⚪ 0 B

Configuration panels, inspectors, and settings screens

File Before After Δ Raw Δ Gzip Δ Brotli
assets/CreditsPanel-DXDYFnCb.js (removed) 21.4 kB 🟢 -21.4 kB 🟢 -5.15 kB 🟢 -4.49 kB
assets/CreditsPanel-VQzhIE8d.js (new) 21.4 kB 🔴 +21.4 kB 🔴 +5.15 kB 🔴 +4.5 kB
assets/KeybindingPanel-BLuobXLz.js (removed) 13.6 kB 🟢 -13.6 kB 🟢 -3.42 kB 🟢 -3.01 kB
assets/KeybindingPanel-BSKW7gXi.js (new) 13.6 kB 🔴 +13.6 kB 🔴 +3.42 kB 🔴 +3.01 kB
assets/ExtensionPanel-E09CtkHT.js (new) 10.8 kB 🔴 +10.8 kB 🔴 +2.58 kB 🔴 +2.26 kB
assets/ExtensionPanel-VFdPlmzT.js (removed) 10.8 kB 🟢 -10.8 kB 🟢 -2.57 kB 🟢 -2.26 kB
assets/AboutPanel-CNPG17xf.js (new) 9.16 kB 🔴 +9.16 kB 🔴 +2.46 kB 🔴 +2.21 kB
assets/AboutPanel-D_5Y4s8o.js (removed) 9.16 kB 🟢 -9.16 kB 🟢 -2.46 kB 🟢 -2.2 kB
assets/ServerConfigPanel-Bgo0Mwoy.js (new) 6.56 kB 🔴 +6.56 kB 🔴 +1.83 kB 🔴 +1.63 kB
assets/ServerConfigPanel-DDqKdHd9.js (removed) 6.56 kB 🟢 -6.56 kB 🟢 -1.83 kB 🟢 -1.63 kB
assets/UserPanel-CAAm0TpQ.js (removed) 6.23 kB 🟢 -6.23 kB 🟢 -1.72 kB 🟢 -1.51 kB
assets/UserPanel-DC0Uexig.js (new) 6.23 kB 🔴 +6.23 kB 🔴 +1.72 kB 🔴 +1.51 kB
assets/settings-BhbWhsRg.js 101 B 101 B ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-BXTtSH4O.js 33.3 kB 33.3 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-C9Pzn-NG.js 25.2 kB 25.2 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-CCy2fA_h.js 27.3 kB 27.3 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-CQpqEFfl.js 26.6 kB 26.6 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-DHcnxypw.js 21.7 kB 21.7 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-DhFTK9fY.js 25.1 kB 25.1 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-DlT4t_ui.js 25.9 kB 25.9 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-DRgSrIdD.js 24.2 kB 24.2 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-tjkeqiZq.js 21.1 kB 21.1 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 6 added / 6 removed

UI Components — 178 kB (baseline 178 kB) • ⚪ 0 B

Reusable component library chunks

File Before After Δ Raw Δ Gzip Δ Brotli
assets/Load3D.vue_vue_type_script_setup_true_lang-CvZL0JI6.js (removed) 53.9 kB 🟢 -53.9 kB 🟢 -8.52 kB 🟢 -7.31 kB
assets/Load3D.vue_vue_type_script_setup_true_lang-z-_rnQvH.js (new) 53.9 kB 🔴 +53.9 kB 🔴 +8.52 kB 🔴 +7.32 kB
assets/WidgetSelect.vue_vue_type_script_setup_true_lang-DViTv22p.js (removed) 48.1 kB 🟢 -48.1 kB 🟢 -10.4 kB 🟢 -8.98 kB
assets/WidgetSelect.vue_vue_type_script_setup_true_lang-v-Mc3LAz.js (new) 48.1 kB 🔴 +48.1 kB 🔴 +10.4 kB 🔴 +9 kB
assets/LazyImage.vue_vue_type_script_setup_true_lang-Bkpe_g-S.js (removed) 48 kB 🟢 -48 kB 🟢 -10.6 kB 🟢 -9.32 kB
assets/LazyImage.vue_vue_type_script_setup_true_lang-CCHOeSpr.js (new) 48 kB 🔴 +48 kB 🔴 +10.6 kB 🔴 +9.32 kB
assets/WidgetInputNumber.vue_vue_type_script_setup_true_lang-BXJWV81N.js (removed) 12.9 kB 🟢 -12.9 kB 🟢 -3.37 kB 🟢 -2.96 kB
assets/WidgetInputNumber.vue_vue_type_script_setup_true_lang-Dsi2E6SL.js (new) 12.9 kB 🔴 +12.9 kB 🔴 +3.37 kB 🔴 +2.97 kB
assets/ComfyQueueButton-B3P0aYrK.js (removed) 8.44 kB 🟢 -8.44 kB 🟢 -2.48 kB 🟢 -2.21 kB
assets/ComfyQueueButton-C5AvcunQ.js (new) 8.44 kB 🔴 +8.44 kB 🔴 +2.48 kB 🔴 +2.21 kB
assets/MediaTitle.vue_vue_type_script_setup_true_lang-6gnCzHhy.js (new) 897 B 🔴 +897 B 🔴 +502 B 🔴 +433 B
assets/MediaTitle.vue_vue_type_script_setup_true_lang-VNehejMf.js (removed) 897 B 🟢 -897 B 🟢 -502 B 🟢 -430 B
assets/UserAvatar.vue_vue_type_script_setup_true_lang-BkTMAMst.js 1.34 kB 1.34 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetButton-CMkR1knv.js 2.04 kB 2.04 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetLayoutField.vue_vue_type_script_setup_true_lang-6ZIklFyS.js 2.26 kB 2.26 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 6 added / 6 removed

Data & Services — 12.5 kB (baseline 12.5 kB) • ⚪ 0 B

Stores, services, APIs, and repositories

File Before After Δ Raw Δ Gzip Δ Brotli
assets/keybindingService-B0-AQ_qv.js (new) 7.51 kB 🔴 +7.51 kB 🔴 +1.83 kB 🔴 +1.57 kB
assets/keybindingService-DEygpPAw.js (removed) 7.51 kB 🟢 -7.51 kB 🟢 -1.83 kB 🟢 -1.57 kB
assets/audioService-BDn-_Q4R.js (removed) 2.2 kB 🟢 -2.2 kB 🟢 -963 B 🟢 -827 B
assets/audioService-DKSe-iR3.js (new) 2.2 kB 🔴 +2.2 kB 🔴 +962 B 🔴 +822 B
assets/serverConfigStore-L3qzi_1Z.js 2.83 kB 2.83 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 2 added / 2 removed

Utilities & Hooks — 3.18 kB (baseline 3.18 kB) • ⚪ 0 B

Helpers, composables, and utility bundles

File Before After Δ Raw Δ Gzip Δ Brotli
assets/audioUtils-BcOP9Y_i.js (new) 1.41 kB 🔴 +1.41 kB 🔴 +651 B 🔴 +541 B
assets/audioUtils-CoWjarGl.js (removed) 1.41 kB 🟢 -1.41 kB 🟢 -651 B 🟢 -554 B
assets/mathUtil-CD4DsosH.js 1.32 kB 1.32 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeFilterUtil-CXKCRJ-m.js 460 B 460 B ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 1 added / 1 removed

Vendor & Third-Party — 8.56 MB (baseline 8.56 MB) • ⚪ 0 B

External libraries and shared vendor chunks

File Before After Δ Raw Δ Gzip Δ Brotli
assets/vendor-chart-DJFoH6N_.js 452 kB 452 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-other-BZV8aGUB.js 3.98 MB 3.98 MB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-primevue-CkvDSSUa.js 1.96 MB 1.96 MB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-three-aR6ntw5X.js 1.37 MB 1.37 MB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-tiptap-Cmu0_BY4.js 232 kB 232 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-vue-Bz22sFex.js 160 kB 160 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-xterm-BZLod3g9.js 407 kB 407 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
Other — 3.81 MB (baseline 3.81 MB) • ⚪ 0 B

Bundles that do not match a named category

File Before After Δ Raw Δ Gzip Δ Brotli
assets/WidgetRecordAudio-DAo-rjHC.js (new) 20.4 kB 🔴 +20.4 kB 🔴 +5.24 kB 🔴 +4.64 kB
assets/WidgetRecordAudio-vlTJX3F3.js (removed) 20.4 kB 🟢 -20.4 kB 🟢 -5.24 kB 🟢 -4.64 kB
assets/AudioPreviewPlayer-Bs2-GtpK.js (removed) 13.5 kB 🟢 -13.5 kB 🟢 -3.4 kB 🟢 -3.04 kB
assets/AudioPreviewPlayer-BZCLsLB-.js (new) 13.5 kB 🔴 +13.5 kB 🔴 +3.4 kB 🔴 +3.04 kB
assets/WidgetGalleria-hgYGepry.js (removed) 4.1 kB 🟢 -4.1 kB 🟢 -1.44 kB 🟢 -1.3 kB
assets/WidgetGalleria-o_qsUALA.js (new) 4.1 kB 🔴 +4.1 kB 🔴 +1.44 kB 🔴 +1.3 kB
assets/WidgetColorPicker-CjIpU-Mv.js (removed) 3.41 kB 🟢 -3.41 kB 🟢 -1.37 kB 🟢 -1.23 kB
assets/WidgetColorPicker-DRa38YVM.js (new) 3.41 kB 🔴 +3.41 kB 🔴 +1.38 kB 🔴 +1.23 kB
assets/WidgetMarkdown-CGHRD6Zc.js (removed) 3.08 kB 🟢 -3.08 kB 🟢 -1.28 kB 🟢 -1.12 kB
assets/WidgetMarkdown-KA099hR9.js (new) 3.08 kB 🔴 +3.08 kB 🔴 +1.28 kB 🔴 +1.12 kB
assets/WidgetTextarea-DtlGktFp.js (new) 2.93 kB 🔴 +2.93 kB 🔴 +1.17 kB 🔴 +1.04 kB
assets/WidgetTextarea-DVP1dHoB.js (removed) 2.93 kB 🟢 -2.93 kB 🟢 -1.16 kB 🟢 -1.04 kB
assets/WidgetAudioUI-C2e9qD-1.js (removed) 2.85 kB 🟢 -2.85 kB 🟢 -1.16 kB 🟢 -1.05 kB
assets/WidgetAudioUI-DVVXA7Cl.js (new) 2.85 kB 🔴 +2.85 kB 🔴 +1.16 kB 🔴 +1.05 kB
assets/WidgetInputText-Bl-6xYXV.js (new) 1.99 kB 🔴 +1.99 kB 🔴 +916 B 🔴 +845 B
assets/WidgetInputText-CUe7MCp2.js (removed) 1.99 kB 🟢 -1.99 kB 🟢 -914 B 🟢 -854 B
assets/MediaImageBottom-_s957R5O.js (new) 1.57 kB 🔴 +1.57 kB 🔴 +742 B 🔴 +645 B
assets/MediaImageBottom-YNpVnTVi.js (removed) 1.57 kB 🟢 -1.57 kB 🟢 -738 B 🟢 -649 B
assets/MediaAudioBottom-HqKYqOyq.js (removed) 1.52 kB 🟢 -1.52 kB 🟢 -742 B 🟢 -656 B
assets/MediaAudioBottom-tqgXVQXd.js (new) 1.52 kB 🔴 +1.52 kB 🔴 +741 B 🔴 +656 B
assets/MediaVideoBottom-CB_W-CIZ.js (new) 1.52 kB 🔴 +1.52 kB 🔴 +739 B 🔴 +659 B
assets/MediaVideoBottom-wZLZyvv4.js (removed) 1.52 kB 🟢 -1.52 kB 🟢 -737 B 🟢 -658 B
assets/Media3DBottom-4-nZeb-b.js (new) 1.5 kB 🔴 +1.5 kB 🔴 +731 B 🔴 +651 B
assets/Media3DBottom-B9pRzSH0.js (removed) 1.5 kB 🟢 -1.5 kB 🟢 -732 B 🟢 -652 B
assets/Media3DTop-Bfvm5Z-p.js (removed) 1.49 kB 🟢 -1.49 kB 🟢 -763 B 🟢 -655 B
assets/Media3DTop-oLRusIk8.js (new) 1.49 kB 🔴 +1.49 kB 🔴 +763 B 🔴 +653 B
assets/WidgetSelect-CtskdY90.js (removed) 655 B 🟢 -655 B 🟢 -341 B 🟢 -288 B
assets/WidgetSelect-DxswaMVA.js (new) 655 B 🔴 +655 B 🔴 +343 B 🔴 +289 B
assets/WidgetInputNumber--eifXmyM.js (new) 595 B 🔴 +595 B 🔴 +329 B 🔴 +277 B
assets/WidgetInputNumber-DaWrBskH.js (removed) 595 B 🟢 -595 B 🟢 -328 B 🟢 -279 B
assets/Load3D-0vQhW3Q7.js (new) 424 B 🔴 +424 B 🔴 +267 B 🔴 +223 B
assets/Load3D-BMkhMnGt.js (removed) 424 B 🟢 -424 B 🟢 -267 B 🟢 -224 B
assets/WidgetLegacy-DvTIklm6.js (new) 364 B 🔴 +364 B 🔴 +237 B 🔴 +229 B
assets/WidgetLegacy-DXtEibAN.js (removed) 364 B 🟢 -364 B 🟢 -237 B 🟢 -224 B
assets/commands-_s-RvhJR.js 13.6 kB 13.6 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-BuUILW6P.js 13 kB 13 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-BV4R6fLx.js 14.9 kB 14.9 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-BWp4HdfU.js 101 B 101 B ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-CLwPdnT6.js 14.2 kB 14.2 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-CWMchBmd.js 15.9 kB 15.9 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-DazTQhtc.js 12.9 kB 12.9 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-DmWrOe93.js 13.7 kB 13.7 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-DwiH7Kr6.js 13.8 kB 13.8 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-mS3LCNPn.js 14.5 kB 14.5 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-B1JflQcI.js 72.2 kB 72.2 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-B2lyXe48.js 114 kB 114 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-B9XEQ-pc.js 94 kB 94 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-BErKFzc-.js 73.1 kB 73.1 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-Bf7Tze-u.js 83.4 kB 83.4 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-BhGMcO4Q.js 84.3 kB 84.3 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-CPZUloNQ.js 99 kB 99 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-Cw9RZWRY.js 89 B 89 B ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-Dva0z-T2.js 86.5 kB 86.5 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-un0K9wDS.js 81.8 kB 81.8 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/MediaAudioTop-BPDWO8-i.js 1.46 kB 1.46 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/MediaImageTop-BtY1hGDO.js 1.75 kB 1.75 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/MediaVideoTop-ehTZdDBw.js 2.76 kB 2.76 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-BC3OlaIn.js 342 kB 342 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-BsqN8-W1.js 285 kB 285 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-Bw_Jitw_.js 101 B 101 B ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-CK2saYDx.js 307 kB 307 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-Cm5kR4Hi.js 306 kB 306 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-CMrh-uxB.js 310 kB 310 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-DlUIOit1.js 369 kB 369 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-DNu_xoP2.js 282 kB 282 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-DpcvlpZe.js 303 kB 303 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-IyjOYIl-.js 317 kB 317 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetChart-DhnqAfj7.js 2.48 kB 2.48 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetImageCompare-DFci1T8T.js 2.21 kB 2.21 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/widgetPropFilter-BIbGSUAt.js 1.28 kB 1.28 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetToggleSwitch-D6b0vE-q.js 1.58 kB 1.58 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 17 added / 17 removed

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between ce4837a and c326446.

📒 Files selected for processing (1)
  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts (6 hunks)
🧰 Additional context used
📓 Path-based instructions (6)
src/**/*.{vue,ts}

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

src/**/*.{vue,ts}: Leverage VueUse functions for performance-enhancing styles
Implement proper error handling
Use vue-i18n in composition API for any string literals. Place new translation entries in src/locales/en/main.json

Files:

  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
src/**/*.ts

📄 CodeRabbit inference engine (.github/copilot-instructions.md)

src/**/*.ts: Use es-toolkit for utility functions
Use TypeScript for type safety

Minimize the surface area (exported values) of each module and composable

Files:

  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
src/**/*.{ts,tsx,vue}

📄 CodeRabbit inference engine (src/CLAUDE.md)

src/**/*.{ts,tsx,vue}: Sanitize HTML with DOMPurify to prevent XSS attacks
Avoid using @ts-expect-error; use proper TypeScript types instead
Use es-toolkit for utility functions instead of other utility libraries
Implement proper TypeScript types throughout the codebase

Files:

  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
src/**/*.{vue,ts,tsx}

📄 CodeRabbit inference engine (src/CLAUDE.md)

Follow Vue 3 composition API style guide

Files:

  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
**/*.{ts,tsx,js,jsx,vue,json}

📄 CodeRabbit inference engine (AGENTS.md)

Code style: Use 2-space indentation, single quotes, no trailing semicolons, and 80-character line width (see .prettierrc)

Files:

  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
**/*.{ts,tsx,vue}

📄 CodeRabbit inference engine (AGENTS.md)

**/*.{ts,tsx,vue}: Imports must be sorted and grouped by plugin; run pnpm format before committing
Use TypeScript for type safety; never use any type - use proper TypeScript types
Never use as any type assertions; fix the underlying type issue instead
Use es-toolkit for utility functions
Write code that is expressive and self-documenting; avoid comments unless absolutely necessary; do not add or retain redundant comments
Keep functions short and functional
Minimize nesting in code (e.g., deeply nested if or for statements); apply the Arrow Anti-Pattern principle
Avoid mutable state; prefer immutability and assignment at point of declaration
Favor pure functions, especially testable ones

Files:

  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
🧠 Learnings (6)
📚 Learning: 2025-12-04T21:43:49.363Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7137
File: src/components/rightSidePanel/parameters/TabParameters.vue:10-0
Timestamp: 2025-12-04T21:43:49.363Z
Learning: Vue 3.5+ supports reactive props destructure in <script setup>. Destructuring props directly (e.g., `const { nodes } = defineProps<{ nodes: LGraphNode[] }>()`) maintains reactivity through compiler transformation. This is the recommended modern approach and does not require using `props.x` or `toRef`/`toRefs`.

Applied to files:

  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
📚 Learning: 2025-11-24T19:47:45.616Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: src/components/CLAUDE.md:0-0
Timestamp: 2025-11-24T19:47:45.616Z
Learning: Applies to src/components/**/*.vue : Use ref/reactive for state management in Vue 3 Composition API

Applied to files:

  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
📚 Learning: 2025-12-09T20:22:23.581Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: AGENTS.md:0-0
Timestamp: 2025-12-09T20:22:23.581Z
Learning: Applies to **/*.vue : Use `ref` for reactive state in Vue Composition API components

Applied to files:

  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
📚 Learning: 2025-11-24T19:47:02.860Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-24T19:47:02.860Z
Learning: Applies to src/**/*.vue : Utilize ref and reactive for reactive state

Applied to files:

  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
📚 Learning: 2025-11-24T19:47:02.860Z
Learnt from: CR
Repo: Comfy-Org/ComfyUI_frontend PR: 0
File: .github/copilot-instructions.md:0-0
Timestamp: 2025-11-24T19:47:02.860Z
Learning: Applies to src/**/*.{vue,ts} : Leverage VueUse functions for performance-enhancing styles

Applied to files:

  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
📚 Learning: 2025-12-09T03:39:54.501Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7169
File: src/platform/remote/comfyui/jobs/jobTypes.ts:1-107
Timestamp: 2025-12-09T03:39:54.501Z
Learning: In the ComfyUI_frontend project, Zod is on v3.x. Do not suggest Zod v4 standalone validators (z.uuid, z.ulid, z.cuid2, z.nanoid) until an upgrade to Zod 4 is performed. When reviewing TypeScript files (e.g., src/platform/remote/comfyui/jobs/jobTypes.ts) validate against Zod 3 capabilities and avoid introducing v4-specific features; flag any proposal to upgrade or incorporate v4-only validators and propose staying with compatible 3.x patterns.

Applied to files:

  • src/renderer/extensions/vueNodes/layout/useNodeDrag.ts
🧬 Code graph analysis (1)
src/renderer/extensions/vueNodes/layout/useNodeDrag.ts (2)
src/renderer/core/canvas/canvasStore.ts (1)
  • useCanvasStore (24-152)
src/utils/litegraphUtil.ts (1)
  • isLGraphGroup (58-60)
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (4)
  • GitHub Check: test
  • GitHub Check: setup
  • GitHub Check: lint-and-format
  • GitHub Check: collect
🔇 Additional comments (5)
src/renderer/extensions/vueNodes/layout/useNodeDrag.ts (5)

4-4: LGTM! Imports are properly typed.

The added imports for LGraphGroup type and isLGraphGroup helper are appropriate for implementing group movement. Adding selectedItems to the store refs enables access to selected groups.

Also applies to: 17-17, 24-24


42-44: LGTM! State variables are properly typed and positioned.

The lastCanvasDelta and selectedGroups variables follow the existing pattern for drag state management and are appropriately typed.


76-78: LGTM! Group capture is clean and type-safe.

The logic correctly filters selected groups using the isLGraphGroup type guard and properly initializes the frame delta tracking.


1-242: Well-structured implementation that integrates cleanly with existing code.

The implementation follows Vue 3 composition API best practices and coding guidelines:

  • Proper TypeScript typing throughout
  • No use of any or type assertions
  • Clean integration with existing drag logic
  • Appropriate use of VueUse utilities
  • Self-documenting code with helpful comments

The frame-based delta approach for group movement is well-reasoned and should align with LiteGraph's behavior as intended.


140-154: Frame-based delta movement for groups is implemented correctly.

The third parameter true to group.move() is correct—it skips moving child items, preventing unwanted recursive movement during group drag operations. The move() method is safe and performs simple position updates without throwing exceptions, so error handling is unnecessary.

Comment on lines +223 to +224
selectedGroups = null
lastCanvasDelta = null
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🟡 Minor

🧩 Analysis chain

🏁 Script executed:

cat -n src/renderer/extensions/vueNodes/layout/useNodeDrag.ts | sed -n '150,230p'

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 3163


🏁 Script executed:

rg -n 'selectedGroups' src/renderer/extensions/vueNodes/layout/useNodeDrag.ts -B 3 -A 3

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 1411


🏁 Script executed:

rg -n 'class.*Group|interface.*Group|type.*Group' src/renderer/extensions/vueNodes/layout/ --type=ts | head -20

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 193


🏁 Script executed:

rg -n 'group\.move\|group\.position' src/renderer/extensions/vueNodes/layout/useNodeDrag.ts -B 2 -A 2

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 52


🏁 Script executed:

rg -n 'applySnapToPosition|shouldSnap|snapToGrid' src/renderer/extensions/vueNodes/layout/useNodeDrag.ts -B 2 -A 2

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 951


🏁 Script executed:

rg -n 'snap.*grid|grid.*size|GRID' src/renderer/extensions/vueNodes/ --type=ts -i | head -15

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 1989


🏁 Script executed:

find . -name 'LGraphGroup*' -o -name '*litegraph*' | grep -E '\.(ts|js)$' | head -10

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 491


🏁 Script executed:

cat src/lib/litegraph/src/LGraphGroup.ts | head -100

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 2631


🏁 Script executed:

rg -n 'snapToGrid' src/lib/litegraph/src/litegraph.ts -B 3 -A 10 | head -50

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 52


🏁 Script executed:

rg -n 'snapToGrid' src/renderer/extensions/vueNodes/ --type=ts -B 2 -A 5

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 919


🏁 Script executed:

rg -n 'move\(' src/lib/litegraph/src/LGraphGroup.ts -B 3 -A 10

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 670


🏁 Script executed:

rg -n 'snapToGrid|snap.*[Gg]roup' src/lib/litegraph/src/ --type=ts -B 2 -A 3

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 9444


🏁 Script executed:

cat src/tests-ui/tests/litegraph/core/LGraphGroup.test.ts 2>/dev/null | head -150

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 52


🏁 Script executed:

rg -n 'getAllNestedItems' src/lib/litegraph/src/ --type=ts -B 2 -A 8

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 4096


🏁 Script executed:

sed -n '1151,1160p' src/lib/litegraph/src/LGraph.ts

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 339


🏁 Script executed:

rg -n 'function getAllNestedItems|export.*getAllNestedItems' src/lib/litegraph/src/ --type=ts

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 150


🏁 Script executed:

rg -n 'addRecursively' src/lib/litegraph/src/utils/collections.ts -B 3 -A 15

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 1001


🏁 Script executed:

cat src/lib/litegraph/src/utils/collections.ts

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 3221


🏁 Script executed:

cat src/tests-ui/tests/litegraph/core/LGraphGroup.test.ts

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 155


🏁 Script executed:

rg -n 'snapToGrid|snap.*grid' src/tests-ui/tests/litegraph/ --type=ts -B 2 -A 4

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 139


🏁 Script executed:

rg -n 'LGraph.*snapToGrid|graph\.snapToGrid' src/renderer/extensions/vueNodes/ --type=ts

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 52


🏁 Script executed:

sed -n '1,50p' src/renderer/extensions/vueNodes/layout/useNodeDrag.ts

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 2104


🏁 Script executed:

rg -n 'LGraph\|graph\.' src/renderer/extensions/vueNodes/layout/useNodeDrag.ts | head -20

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 52


🏁 Script executed:

rg -n 'snap.*comment|TODO|FIXME|XXX' src/renderer/extensions/vueNodes/layout/useNodeDrag.ts

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 52


🏁 Script executed:

rg -n 'group.move|applySnapToPosition' src/renderer/extensions/vueNodes/layout/useNodeDrag.ts -B 3 -A 3

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 1204


🏁 Script executed:

sed -n '140,160p' src/renderer/extensions/vueNodes/layout/useNodeDrag.ts

Repository: Comfy-Org/ComfyUI_frontend

Length of output: 794


Groups are not snapped to grid at drag end, unlike nodes.

While nodes receive snap-to-grid treatment in endDrag (lines 160-217), selected groups are only moved during drag via group.move() and are never snapped at drag completion. This creates an asymmetry in behavior. Both LGraphGroup and LGraphNode implement the snapToGrid interface, and the applySnapToPosition utility is available, so groups should also be snapped when shouldSnap(event) is true. Currently, the snap logic only executes when nodeId is present, which excludes the group snapping path.

Copy link
Contributor

@DrJKL DrJKL left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Would this be a good time to handle Reroutes too?

Copy link
Contributor

@DrJKL DrJKL left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Approving because this is better, but I feel like there should be a way to handle all the Positionables together.

@christian-byrne christian-byrne merged commit 424bd21 into main Dec 10, 2025
31 of 32 checks passed
@christian-byrne christian-byrne deleted the group-move-vueNodes branch December 10, 2025 06:32
@christian-byrne christian-byrne added needs-backport Fix/change that needs to be cherry-picked to the current feature freeze branch core/1.34 labels Dec 15, 2025
github-actions bot pushed a commit that referenced this pull request Dec 15, 2025
@comfy-pr-bot
Copy link
Member

@jtydhr88 Successfully backported to #7505

@github-actions github-actions bot removed the needs-backport Fix/change that needs to be cherry-picked to the current feature freeze branch label Dec 15, 2025
christian-byrne pushed a commit that referenced this pull request Dec 15, 2025
… vueNodes mode (#7505)

Backport of #7306 to `core/1.34`

Automatically created by backport workflow.

┆Issue is synchronized with this [Notion
page](https://www.notion.so/PR-7505-backport-core-1-34-fix-move-selected-groups-when-dragging-nodes-in-vueNodes-mode-2ca6d73d365081e2af2fd6a5e9599941)
by [Unito](https://www.unito.io)

Co-authored-by: Terry Jia <terryjia88@gmail.com>
Enferlain pushed a commit to Enferlain/ComfyUI_frontend that referenced this pull request Dec 18, 2025
Yourz pushed a commit that referenced this pull request Dec 24, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:S This PR changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants