Skip to content

Conversation

@DrJKL
Copy link
Contributor

@DrJKL DrJKL commented Nov 19, 2025

Consistent names and order of operations. This does not fix the resizing on load.

┆Issue is synchronized with this Notion page by Unito

@dosubot dosubot bot added the size:L This PR changes 100-499 lines, ignoring generated files. label Nov 19, 2025
@DrJKL DrJKL requested a review from simula-r November 19, 2025 06:12
@github-actions
Copy link

github-actions bot commented Nov 19, 2025

🎨 Storybook Build Status

Build completed successfully!

⏰ Completed at: 11/22/2025, 01:44:06 AM UTC

🔗 Links


🎉 Your Storybook is ready for review!

@github-actions
Copy link

github-actions bot commented Nov 19, 2025

🎭 Playwright Test Results

⚠️ Tests passed with flaky tests

⏰ Completed at: 11/22/2025, 01:54:15 AM UTC

📈 Summary

  • Total Tests: 498
  • Passed: 488 ✅
  • Failed: 0
  • Flaky: 1 ⚠️
  • Skipped: 9 ⏭️

📊 Test Reports by Browser

  • chromium: View Report • ✅ 479 / ❌ 0 / ⚠️ 1 / ⏭️ 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

github-actions bot commented Nov 19, 2025

Bundle Size Report

Summary

  • Raw size: 13.7 MB baseline 13.7 MB — 🟢 -704 B
  • Gzip: 2.76 MB baseline 2.76 MB — 🟢 -80 B
  • Brotli: 2.16 MB baseline 2.16 MB — 🟢 -58 B
  • Bundles: 92 current • 92 baseline • 38 added / 38 removed

Category Glance
App Entry Points 🟢 -704 B (3.13 MB) · Vendor & Third-Party ⚪ 0 B (5.32 MB) · Other ⚪ 0 B (3.87 MB) · Graph Workspace ⚪ 0 B (940 kB) · Panels & Settings ⚪ 0 B (306 kB) · UI Components ⚪ 0 B (141 kB) · + 3 more

Per-category breakdown
App Entry Points — 3.13 MB (baseline 3.13 MB) • 🟢 -704 B

Main entry bundles and manifests

File Before After Δ Raw Δ Gzip Δ Brotli
assets/index-Bo4E5eYr.js (removed) 2.77 MB 🟢 -2.77 MB 🟢 -579 kB 🟢 -440 kB
assets/index-D9YJ1Zq8.js (new) 2.77 MB 🔴 +2.77 MB 🔴 +579 kB 🔴 +440 kB
assets/index-D8Mseokq.js (removed) 364 kB 🟢 -364 kB 🟢 -75.2 kB 🟢 -61.4 kB
assets/index-OtdnA4Bp.js (new) 364 kB 🔴 +364 kB 🔴 +75.2 kB 🔴 +61.4 kB
assets/index-CwftIcvK.js (new) 345 B 🔴 +345 B 🔴 +246 B 🔴 +237 B
assets/index-DVfmcAkQ.js (removed) 345 B 🟢 -345 B 🟢 -245 B 🟢 -236 B

Status: 3 added / 3 removed

Graph Workspace — 940 kB (baseline 940 kB) • ⚪ 0 B

Graph editor runtime, canvas, workflow orchestration

File Before After Δ Raw Δ Gzip Δ Brotli
assets/GraphView-B0ZMk4wO.js (new) 940 kB 🔴 +940 kB 🔴 +182 kB 🔴 +140 kB
assets/GraphView-Da-nd_q6.js (removed) 940 kB 🟢 -940 kB 🟢 -182 kB 🟢 -140 kB

Status: 1 added / 1 removed

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

Top-level views, pages, and routed surfaces

File Before After Δ Raw Δ Gzip Δ Brotli
assets/UserSelectView-CeM-xZr8.js (removed) 7.97 kB 🟢 -7.97 kB 🟢 -2.43 kB 🟢 -2.14 kB
assets/UserSelectView-COi2qJWF.js (new) 7.97 kB 🔴 +7.97 kB 🔴 +2.44 kB 🔴 +2.13 kB

Status: 1 added / 1 removed

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

Configuration panels, inspectors, and settings screens

File Before After Δ Raw Δ Gzip Δ Brotli
assets/CreditsPanel-Cnj7TiWx.js (new) 22.9 kB 🔴 +22.9 kB 🔴 +5.46 kB 🔴 +4.79 kB
assets/CreditsPanel-DqKpgM7j.js (removed) 22.9 kB 🟢 -22.9 kB 🟢 -5.46 kB 🟢 -4.79 kB
assets/KeybindingPanel-B_FIKicp.js (removed) 15.1 kB 🟢 -15.1 kB 🟢 -3.73 kB 🟢 -3.28 kB
assets/KeybindingPanel-Cc4N73fb.js (new) 15.1 kB 🔴 +15.1 kB 🔴 +3.73 kB 🔴 +3.29 kB
assets/ExtensionPanel-BytHCAg_.js (new) 11.9 kB 🔴 +11.9 kB 🔴 +2.8 kB 🔴 +2.45 kB
assets/ExtensionPanel-D2Ak12m3.js (removed) 11.9 kB 🟢 -11.9 kB 🟢 -2.79 kB 🟢 -2.45 kB
assets/AboutPanel-Bg2GD9qX.js (new) 10.1 kB 🔴 +10.1 kB 🔴 +2.62 kB 🔴 +2.31 kB
assets/AboutPanel-DI1J55fk.js (removed) 10.1 kB 🟢 -10.1 kB 🟢 -2.62 kB 🟢 -2.31 kB
assets/ServerConfigPanel-5Il2CSuu.js (removed) 8.02 kB 🟢 -8.02 kB 🟢 -2.12 kB 🟢 -1.87 kB
assets/ServerConfigPanel-BZccVvu_.js (new) 8.02 kB 🔴 +8.02 kB 🔴 +2.12 kB 🔴 +1.87 kB
assets/UserPanel-b_SU5Fro.js (new) 7.74 kB 🔴 +7.74 kB 🔴 +2.03 kB 🔴 +1.77 kB
assets/UserPanel-D7rteUJ0.js (removed) 7.74 kB 🟢 -7.74 kB 🟢 -2.03 kB 🟢 -1.77 kB
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 — 141 kB (baseline 141 kB) • ⚪ 0 B

Reusable component library chunks

File Before After Δ Raw Δ Gzip Δ Brotli
assets/Load3D.vue_vue_type_script_setup_true_lang-B2np-g3o.js (new) 53.9 kB 🔴 +53.9 kB 🔴 +8.43 kB 🔴 +7.24 kB
assets/Load3D.vue_vue_type_script_setup_true_lang-CI58Q9vL.js (removed) 53.9 kB 🟢 -53.9 kB 🟢 -8.43 kB 🟢 -7.23 kB
assets/WidgetSelect.vue_vue_type_script_setup_true_lang-DBTM9X0w.js (new) 48.1 kB 🔴 +48.1 kB 🔴 +10.3 kB 🔴 +8.97 kB
assets/WidgetSelect.vue_vue_type_script_setup_true_lang-Mx4Fj3Xh.js (removed) 48.1 kB 🟢 -48.1 kB 🟢 -10.3 kB 🟢 -8.93 kB
assets/WidgetInputNumber.vue_vue_type_script_setup_true_lang-C-kzldhF.js (removed) 12.7 kB 🟢 -12.7 kB 🟢 -3.3 kB 🟢 -2.92 kB
assets/WidgetInputNumber.vue_vue_type_script_setup_true_lang-C8epnBdQ.js (new) 12.7 kB 🔴 +12.7 kB 🔴 +3.31 kB 🔴 +2.92 kB
assets/ComfyQueueButton-DY8OnOpZ.js (removed) 9.22 kB 🟢 -9.22 kB 🟢 -2.5 kB 🟢 -2.2 kB
assets/ComfyQueueButton-v1oMMYNn.js (new) 9.22 kB 🔴 +9.22 kB 🔴 +2.5 kB 🔴 +2.2 kB
assets/WidgetLayoutField.vue_vue_type_script_setup_true_lang-61t3YrdH.js (removed) 2.14 kB 🟢 -2.14 kB 🟢 -794 B 🟢 -699 B
assets/WidgetLayoutField.vue_vue_type_script_setup_true_lang-BRPcB1fd.js (new) 2.14 kB 🔴 +2.14 kB 🔴 +796 B 🔴 +690 B
assets/MediaTitle.vue_vue_type_script_setup_true_lang-7pt8yAnT.js (new) 848 B 🔴 +848 B 🔴 +477 B 🔴 +418 B
assets/MediaTitle.vue_vue_type_script_setup_true_lang-COWx2qbN.js (removed) 848 B 🟢 -848 B 🟢 -476 B 🟢 -415 B
assets/LazyImage.vue_vue_type_script_setup_true_lang-Wi-CcgaU.js 10.7 kB 10.7 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/UserAvatar.vue_vue_type_script_setup_true_lang-D2s8tnS2.js 1.26 kB 1.26 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetButton-ByrPd5jr.js 1.62 kB 1.62 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-BatdfKB-.js (removed) 7.51 kB 🟢 -7.51 kB 🟢 -1.83 kB 🟢 -1.58 kB
assets/keybindingService-BOyED5Zo.js (new) 7.51 kB 🔴 +7.51 kB 🔴 +1.84 kB 🔴 +1.58 kB
assets/audioService-BQBX08zj.js (new) 2.2 kB 🔴 +2.2 kB 🔴 +964 B 🔴 +823 B
assets/audioService-BsdI04Uq.js (removed) 2.2 kB 🟢 -2.2 kB 🟢 -961 B 🟢 -819 B
assets/serverConfigStore-BoHtzifw.js 2.79 kB 2.79 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 2 added / 2 removed

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

Helpers, composables, and utility bundles

File Before After Δ Raw Δ Gzip Δ Brotli
assets/audioUtils-DabD5H9c.js (new) 1.41 kB 🔴 +1.41 kB 🔴 +653 B 🔴 +542 B
assets/audioUtils-DUyyJeyr.js (removed) 1.41 kB 🟢 -1.41 kB 🟢 -649 B 🟢 -541 B
assets/mathUtil-CTARWQ-l.js 1.07 kB 1.07 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 — 5.32 MB (baseline 5.32 MB) • ⚪ 0 B

External libraries and shared vendor chunks

File Before After Δ Raw Δ Gzip Δ Brotli
assets/vendor-other-z0ajCJVX.js 3.22 MB 3.22 MB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-primevue-PESgPnbc.js 517 B 517 B ⚪ 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-D2zb6Fg1.js 232 kB 232 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-vue-aBQ_uOio.js 92.6 kB 92.6 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-xterm-BZLod3g9.js 407 kB 407 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
Other — 3.87 MB (baseline 3.87 MB) • ⚪ 0 B

Bundles that do not match a named category

File Before After Δ Raw Δ Gzip Δ Brotli
assets/WidgetRecordAudio-BTjDoxtn.js (removed) 21.9 kB 🟢 -21.9 kB 🟢 -5.52 kB 🟢 -4.88 kB
assets/WidgetRecordAudio-DT5qPhvO.js (new) 21.9 kB 🔴 +21.9 kB 🔴 +5.52 kB 🔴 +4.88 kB
assets/AudioPreviewPlayer-CaemdIzq.js (removed) 14.9 kB 🟢 -14.9 kB 🟢 -3.69 kB 🟢 -3.29 kB
assets/AudioPreviewPlayer-CwlskeKB.js (new) 14.9 kB 🔴 +14.9 kB 🔴 +3.69 kB 🔴 +3.3 kB
assets/WidgetGalleria-DnRr1Cjg.js (new) 5.56 kB 🔴 +5.56 kB 🔴 +1.75 kB 🔴 +1.54 kB
assets/WidgetGalleria-DR3K-4UB.js (removed) 5.56 kB 🟢 -5.56 kB 🟢 -1.74 kB 🟢 -1.54 kB
assets/WidgetColorPicker-D4O_hhfJ.js (new) 4.87 kB 🔴 +4.87 kB 🔴 +1.69 kB 🔴 +1.48 kB
assets/WidgetColorPicker-Quhc7zCU.js (removed) 4.87 kB 🟢 -4.87 kB 🟢 -1.69 kB 🟢 -1.48 kB
assets/WidgetMarkdown-4oyd0KjJ.js (new) 4.64 kB 🔴 +4.64 kB 🔴 +1.62 kB 🔴 +1.41 kB
assets/WidgetMarkdown-D1nPG1Bt.js (removed) 4.64 kB 🟢 -4.64 kB 🟢 -1.62 kB 🟢 -1.41 kB
assets/WidgetAudioUI-DfCwU2Sh.js (removed) 4.33 kB 🟢 -4.33 kB 🟢 -1.44 kB 🟢 -1.29 kB
assets/WidgetAudioUI-DuYNJjCu.js (new) 4.33 kB 🔴 +4.33 kB 🔴 +1.44 kB 🔴 +1.29 kB
assets/WidgetTextarea-D9zamKvm.js (removed) 3.72 kB 🟢 -3.72 kB 🟢 -1.31 kB 🟢 -1.15 kB
assets/WidgetTextarea-Dn77qaN1.js (new) 3.72 kB 🔴 +3.72 kB 🔴 +1.31 kB 🔴 +1.14 kB
assets/WidgetInputText-DyieLOU3.js (new) 3.45 kB 🔴 +3.45 kB 🔴 +1.24 kB 🔴 +1.09 kB
assets/WidgetInputText-JZg53Tmz.js (removed) 3.45 kB 🟢 -3.45 kB 🟢 -1.24 kB 🟢 -1.09 kB
assets/WidgetToggleSwitch-Dbs3l2yg.js (removed) 3.23 kB 🟢 -3.23 kB 🟢 -1.14 kB 🟢 -1.01 kB
assets/WidgetToggleSwitch-Dv_cCss2.js (new) 3.23 kB 🔴 +3.23 kB 🔴 +1.14 kB 🔴 +1.01 kB
assets/MediaImageBottom-BiczVdZY.js (new) 3.05 kB 🔴 +3.05 kB 🔴 +1.05 kB 🔴 +913 B
assets/MediaImageBottom-BTO-Ea6Z.js (removed) 3.05 kB 🟢 -3.05 kB 🟢 -1.05 kB 🟢 -916 B
assets/MediaAudioBottom-Bu8sMppc.js (new) 3 kB 🔴 +3 kB 🔴 +1.05 kB 🔴 +922 B
assets/MediaAudioBottom-CKHbkTaY.js (removed) 3 kB 🟢 -3 kB 🟢 -1.05 kB 🟢 -912 B
assets/Media3DTop-BSTrglXY.js (removed) 3 kB 🟢 -3 kB 🟢 -1.08 kB 🟢 -911 B
assets/Media3DTop-Ds65RV0o.js (new) 3 kB 🔴 +3 kB 🔴 +1.08 kB 🔴 +911 B
assets/MediaVideoBottom-BlWu9wxX.js (new) 3 kB 🔴 +3 kB 🔴 +1.05 kB 🔴 +920 B
assets/MediaVideoBottom-ClHzhMiF.js (removed) 3 kB 🟢 -3 kB 🟢 -1.05 kB 🟢 -927 B
assets/Media3DBottom-Cr5gCLkY.js (removed) 2.98 kB 🟢 -2.98 kB 🟢 -1.04 kB 🟢 -927 B
assets/Media3DBottom-D2KSEAE6.js (new) 2.98 kB 🔴 +2.98 kB 🔴 +1.04 kB 🔴 +911 B
assets/WidgetSelect-B8vZb948.js (new) 2.17 kB 🔴 +2.17 kB 🔴 +675 B 🔴 +576 B
assets/WidgetSelect-BPBzMIq_.js (removed) 2.17 kB 🟢 -2.17 kB 🟢 -675 B 🟢 -568 B
assets/WidgetInputNumber-B-wTMm9t.js (removed) 2.12 kB 🟢 -2.12 kB 🟢 -662 B 🟢 -557 B
assets/WidgetInputNumber-E1KxzqsI.js (new) 2.12 kB 🔴 +2.12 kB 🔴 +664 B 🔴 +556 B
assets/Load3D-COSn7Gg2.js (new) 1.94 kB 🔴 +1.94 kB 🔴 +598 B 🔴 +500 B
assets/Load3D-lHXqy20K.js (removed) 1.94 kB 🟢 -1.94 kB 🟢 -599 B 🟢 -532 B
assets/WidgetLegacy-BACgqQ6C.js (new) 1.88 kB 🔴 +1.88 kB 🔴 +562 B 🔴 +505 B
assets/WidgetLegacy-rLz-te4s.js (removed) 1.88 kB 🟢 -1.88 kB 🟢 -559 B 🟢 -472 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-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-5lOBdqcC.js 84.5 kB 84.5 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-BOCuaVpE.js 73.4 kB 73.4 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-ClrEFGUz.js 72.4 kB 72.4 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-CyNU0iQX.js 99.3 kB 99.3 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-D7gwLxft.js 114 kB 114 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-DC8o4BCt.js 86.8 kB 86.8 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-DKiesCV4.js 94.3 kB 94.3 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-Hq2q-OtB.js 83.6 kB 83.6 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-USAlAlnj.js 82 kB 82 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/MediaAudioTop-RTI8pWy9.js 1.42 kB 1.42 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/MediaImageTop-Cxl4dc80.js 1.68 kB 1.68 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/MediaVideoTop-BB0lT7C5.js 2.7 kB 2.7 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-_Px5dSNW.js 306 kB 306 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-7z21KPoS.js 285 kB 285 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-BWKZzBPK.js 346 kB 346 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-CGbgH4Yl.js 320 kB 320 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-CjjjdWkV.js 313 kB 313 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-CVrNtxvj.js 288 kB 288 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-DLRSA0IK.js 309 kB 309 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-DQV2gnwA.js 372 kB 372 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-ofqLG5vz.js 310 kB 310 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetChart-rDmYEWg5.js 2.39 kB 2.39 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetImageCompare-Ds3K3ULR.js 2.15 kB 2.15 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/widgetPropFilter-BIbGSUAt.js 1.28 kB 1.28 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 18 added / 18 removed

@DrJKL DrJKL requested review from Myestery and viva-jinyi November 19, 2025 06:26
@DrJKL DrJKL changed the title refactor: Reorganizing scaling logic. Fix: Vue <--> Litegraph scaling logic. Nov 19, 2025
Copy link
Contributor

@christian-byrne christian-byrne left a comment

Choose a reason for hiding this comment

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

LGTM seems like just refactoring

Copy link
Collaborator

@AustinMroz AustinMroz left a comment

Choose a reason for hiding this comment

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

LGTM

@DrJKL DrJKL enabled auto-merge (squash) November 19, 2025 20:44
@DrJKL DrJKL force-pushed the drjkl/map-territory branch from 6d2d50a to 5f964b9 Compare November 21, 2025 02:25
@DrJKL DrJKL requested review from AustinMroz and simula-r November 21, 2025 04:24
@DrJKL DrJKL force-pushed the drjkl/map-territory branch 2 times, most recently from 09ff304 to 405fcb3 Compare November 21, 2025 22:25
@coderabbitai
Copy link

coderabbitai bot commented Nov 21, 2025

📝 Walkthrough

Walkthrough

This PR renames the exported type rendererType to RendererType and updates ensureCorrectLayoutScale() to accept renderer: RendererType = 'LG'; it consolidates upscale/downscale logic, applies origin-relative transforms for layout elements, and gates layout-store updates to the active graph.

Changes

Cohort / File(s) Summary
Type Definition Update
src/lib/litegraph/src/LGraph.ts
Renamed exported type alias rendererTypeRendererType ('LG' | 'Vue'). Updated LGraphExtra.workflowRendererVersion to use RendererType.
Layout Scale Logic Refactor
src/renderer/extensions/vueNodes/layout/ensureCorrectLayoutScale.ts
Import updated to RendererType. Function signature changed to ensureCorrectLayoutScale(renderer: RendererType = 'LG', targetGraph?: LGraph). Consolidated upscale/downscale checks, unified scaleFactor computation, applied origin-relative transforms for nodes/reroutes/IO/groups, simplified auto-scale guard, introduced onActiveGraph gating, batched layout store updates for the active graph, and set graph.extra.workflowRendererVersion once based on final decision.

Sequence Diagram(s)

sequenceDiagram
    participant Caller
    participant ensureCorrectLayoutScale
    participant Graph
    participant LayoutStore

    Caller->>ensureCorrectLayoutScale: ensureCorrectLayoutScale(renderer='LG', targetGraph?)
    activate ensureCorrectLayoutScale
    ensureCorrectLayoutScale->>ensureCorrectLayoutScale: Check auto-scale flag (early return if disabled)
    ensureCorrectLayoutScale->>Graph: Validate graph & gather nodes/groups/reroutes/IO
    ensureCorrectLayoutScale->>ensureCorrectLayoutScale: Compute needsUpscale / needsDownscale and scaleFactor
    ensureCorrectLayoutScale->>ensureCorrectLayoutScale: Determine onActiveGraph (is active graph?)
    Note over ensureCorrectLayoutScale,Graph: For each element: compute origin-relative positions\nand sizes, apply scaleFactor
    ensureCorrectLayoutScale->>Graph: Apply in-memory layout mutations
    alt onActiveGraph
        ensureCorrectLayoutScale->>LayoutStore: Emit batched layout updates
    end
    ensureCorrectLayoutScale->>Graph: Set graph.extra.workflowRendererVersion
    ensureCorrectLayoutScale->>Caller: Return
    deactivate ensureCorrectLayoutScale
Loading
✨ 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 drjkl/map-territory

📜 Recent review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 0c88396 and 18322e0.

📒 Files selected for processing (2)
  • src/lib/litegraph/src/LGraph.ts (2 hunks)
  • src/renderer/extensions/vueNodes/layout/ensureCorrectLayoutScale.ts (3 hunks)
🚧 Files skipped from review as they are similar to previous changes (2)
  • src/lib/litegraph/src/LGraph.ts
  • src/renderer/extensions/vueNodes/layout/ensureCorrectLayoutScale.ts
⏰ 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: lint-and-format
  • GitHub Check: test
  • GitHub Check: setup
  • GitHub Check: collect

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

Copy link

@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: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 9da82f4 and 405fcb3.

📒 Files selected for processing (2)
  • src/lib/litegraph/src/LGraph.ts (2 hunks)
  • src/renderer/extensions/vueNodes/layout/ensureCorrectLayoutScale.ts (3 hunks)
🧰 Additional context used
🧬 Code graph analysis (1)
src/renderer/extensions/vueNodes/layout/ensureCorrectLayoutScale.ts (5)
src/lib/litegraph/src/LGraph.ts (2)
  • RendererType (82-82)
  • LGraph (123-2389)
src/composables/useVueFeatureFlags.ts (1)
  • useVueFeatureFlags (37-39)
src/renderer/core/layout/types.ts (1)
  • NodeBoundsUpdate (34-37)
src/lib/litegraph/src/litegraph.ts (1)
  • LiteGraph (17-17)
src/renderer/core/layout/store/layoutStore.ts (1)
  • layoutStore (1458-1458)
⏰ 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: lint-and-format
  • GitHub Check: collect
  • GitHub Check: setup

@coderabbitai
Copy link

coderabbitai bot commented Nov 21, 2025

Note

Unit test generation is an Early Access feature. Expect some limitations and changes as we gather feedback and continue to improve it.


Generating unit tests... This may take up to 20 minutes.

@coderabbitai
Copy link

coderabbitai bot commented Nov 21, 2025

UTG Post-Process Complete

No new issues were detected in the generated code and all check runs have completed. The unit test generation process has completed successfully.

@coderabbitai
Copy link

coderabbitai bot commented Nov 21, 2025

Creating a PR to put the unit tests in...

The changes have been created in this pull request: View PR

@DrJKL DrJKL added the New Browser Test Expectations New browser test screenshot should be set by github action label Nov 21, 2025
@github-actions
Copy link

Updating Playwright Expectations

@github-actions github-actions bot removed the New Browser Test Expectations New browser test screenshot should be set by github action label Nov 21, 2025
@DrJKL DrJKL force-pushed the drjkl/map-territory branch from 405fcb3 to 0c88396 Compare November 21, 2025 23:01
Copy link

@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: 0

🧹 Nitpick comments (1)
src/renderer/extensions/vueNodes/layout/ensureCorrectLayoutScale.ts (1)

102-121: Reroute scaling is now origin‑relative; consider hoisting useLayoutMutations out of the loop

The reroute transform matches the node logic and correctly scales around the graph origin via:

const scaledX = originX + relativeX * scaleFactor
const scaledY = originY + relativeY * scaleFactor

which should prevent the origin‑drift issue seen before. Updating reroute.pos directly and then emitting a moveReroute only when onActiveGraph && shouldRenderVueNodes.value also makes sense.

You can avoid repeatedly creating the composable inside the loop by hoisting it:

-  for (const reroute of graph.reroutes.values()) {
+  const layoutMutations =
+    onActiveGraph && shouldRenderVueNodes.value
+      ? useLayoutMutations()
+      : null
+
+  for (const reroute of graph.reroutes.values()) {
     const [oldX, oldY] = reroute.pos
@@
-    reroute.pos = [scaledX, scaledY]
-
-    if (onActiveGraph && shouldRenderVueNodes.value) {
-      const layoutMutations = useLayoutMutations()
-      layoutMutations.moveReroute(
+    reroute.pos = [scaledX, scaledY]
+
+    if (layoutMutations) {
+      layoutMutations.moveReroute(
         reroute.id,
         { x: scaledX, y: scaledY },
         { x: oldX, y: oldY }
       )
     }
   }

This keeps behavior identical while reducing per‑reroute setup work.

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 405fcb3 and 0c88396.

📒 Files selected for processing (1)
  • src/renderer/extensions/vueNodes/layout/ensureCorrectLayoutScale.ts (3 hunks)
🧰 Additional context used
🧬 Code graph analysis (1)
src/renderer/extensions/vueNodes/layout/ensureCorrectLayoutScale.ts (5)
src/lib/litegraph/src/LGraph.ts (2)
  • RendererType (82-82)
  • LGraph (123-2389)
src/composables/useVueFeatureFlags.ts (1)
  • useVueFeatureFlags (37-39)
src/renderer/core/layout/types.ts (1)
  • NodeBoundsUpdate (34-37)
src/renderer/core/layout/store/layoutStore.ts (1)
  • layoutStore (1458-1458)
src/renderer/core/layout/operations/layoutMutations.ts (1)
  • useLayoutMutations (67-340)
⏰ 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: setup
  • GitHub Check: lint-and-format
  • GitHub Check: test
  • GitHub Check: collect
🔇 Additional comments (4)
src/renderer/extensions/vueNodes/layout/ensureCorrectLayoutScale.ts (4)

2-3: RendererType usage, guards, and active-graph gating look consistent

Importing RendererType and defaulting renderer to 'LG' keeps the API explicit while still allowing callers to omit the argument. The autoScaleLayoutSetting and !needsUpscale && !needsDownscale guards correctly avoid unnecessary work when scaling isn’t required, and onActiveGraph ensures layout mutations and canvas scaling only touch the active graph. The workflowRendererVersion ??= renderer in the no-scale path also safely initializes the version without overwriting an existing value.

Also applies to: 15-24, 28-38, 51-53


45-76: Node scaling is origin‑relative; verify that height transform won’t drift on repeated LG↔Vue toggles

The node transform around [originX, originY] (including the NODE_TITLE_HEIGHT Y-offset and the batched layoutStore.batchUpdateNodeBounds updates) looks consistent and keeps positions anchored to the graph bounds.

One subtle point: the height formula

const scaledHeight =
  lgNode.height * scaleFactor -
  (needsUpscale ? 0 : LiteGraph.NODE_TITLE_HEIGHT)

only subtracts NODE_TITLE_HEIGHT on the downscale path. Algebraically, an LG → Vue → LG round‑trip will reduce lgNode.size[1] by LiteGraph.NODE_TITLE_HEIGHT, and repeating that cycle would continue shrinking heights.

If ensureCorrectLayoutScale can be invoked multiple times for the same graph as the renderer is toggled back and forth, this will cause cumulative height drift; if it’s guaranteed to run only once per graph per direction (e.g. a one‑time migration), it’s fine. Please confirm the intended call pattern and, if repeated toggles are possible, consider adjusting the height mapping (or explicitly tracking conversion state) to make the transform involutive.

Also applies to: 79-82, 85-92, 98-100


123-143: IO node scaling matches the shared origin‑relative pattern

Subgraph input/output nodes use the same origin‑relative position transform and simple size scaling as reroutes, without extra title‑height adjustments. That keeps their layout consistent across LG↔Vue transitions and avoids additional drift.


35-38: Group and canvas scaling look correct; confirm workflowRendererVersion contract at call sites

The group transform mirrors the node logic (including NODE_TITLE_HEIGHT Y-offsets) but keeps height scaling purely multiplicative, which makes the LG↔Vue↔LG mapping for groups mathematically involutive—no cumulative drift there. The onActiveGraph && canvas guard around changeScale and pivoting at originScreen also ensure only the active graph’s canvas is rescaled and that the visual layout stays fixed while coordinates are renormalized.

For graph.extra.workflowRendererVersion:

  • In the no-scale path you now set workflowRendererVersion ??= renderer, so an existing value is preserved.
  • When scaling occurs you unconditionally set it to 'Vue' or 'LG' based on the direction.

This is sound assuming callers always pass the renderer that produced the current layout (i.e., the “previous renderer”) and only invoke ensureCorrectLayoutScale when that value disagrees with the current shouldRenderVueNodes flag. Please double-check the call sites follow that contract; otherwise, layouts might be left unscaled or scaled more than once.

Also applies to: 146-165, 167-173

@DrJKL DrJKL changed the title Fix: Vue <--> Litegraph scaling logic. Cleanup: Vue <--> Litegraph scaling logic. Nov 21, 2025
@DrJKL DrJKL added the New Browser Test Expectations New browser test screenshot should be set by github action label Nov 21, 2025
@github-actions github-actions bot removed the New Browser Test Expectations New browser test screenshot should be set by github action label Nov 21, 2025
@DrJKL DrJKL force-pushed the drjkl/map-territory branch from 0c88396 to 18322e0 Compare November 22, 2025 01:42
@DrJKL DrJKL merged commit d6c5b33 into main Nov 22, 2025
26 checks passed
@DrJKL DrJKL deleted the drjkl/map-territory branch November 22, 2025 01:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L This PR changes 100-499 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants