Skip to content

Conversation

@brucew4yn3rp
Copy link
Collaborator

@brucew4yn3rp brucew4yn3rp commented Jan 11, 2026

Summary

What was previously a simple Mask Editor has been refactored and now functions as a more general Image Canvas, with masking being only one of its features. To avoid confusing users, the context menu option was renamed to Mask Editor | Image Canvas. As a longer-term solution, we should fully adopt the Image Canvas name.

Re-work of #7950

Changes

Renaming & Refactoring

  • Updated all references, filenames, and file paths from maskEditor to imageCanvas
  • Preserved various naming conventions:
    • MaskEditorImageCanvas
    • maskEditorimageCanvas
    • mask-editorimage-canvas

Bug Fixes

  • Fixed typo: maskEditor_is_opended()imageCanvas_is_opened()

Migration

  • Added automatic migration in settingStore.ts to preserve user settings and keybindings when upgrading:
    • Migrates Comfy.MaskEditor.BrushAdjustmentSpeedComfy.imageCanvas.BrushAdjustmentSpeed
    • Migrates Comfy.MaskEditor.UseDominantAxisComfy.imageCanvas.UseDominantAxis
    • Migrates all command keybindings from Comfy.MaskEditor.* to Comfy.imageCanvas.*

Breaking Changes

While this is technically a breaking change for extensions that reference the old maskEditor naming, the migration ensures that end users will not lose any settings or keybindings from the update.

┆Issue is synchronized with this Notion page by Unito

@dosubot dosubot bot added the size:XXL This PR changes 1000+ lines, ignoring generated files. label Jan 11, 2026
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Jan 11, 2026

📝 Walkthrough

Walkthrough

This PR renames and migrates the Mask Editor feature to Image Canvas across code, assets, CSS, stores, commands, localization, and documentation; it also adds migrations to preserve user settings and keybindings during the rename.

Changes

Cohort / File(s) Summary
Documentation & Config
/.claude/commands/pr.md, CODEOWNERS, README.md, docs/extensions/core.md, src/extensions/core/README.md
Replaced mask editor references with image canvas; updated tags, ownership entries, headings, and documentation formatting.
Design System CSS & Tokens
packages/design-system/src/css/style.css
Renamed large set of public selectors/classes from maskEditor_*imageCanvas_*; introduced --palette-* token namespace and moved/normalized color tokens.
Stores & Settings
src/stores/imageCanvasStore.ts, src/stores/imageCanvasDataStore.ts, src/platform/settings/settingStore.ts, src/schemas/apiSchema.ts
Renamed stores and store IDs; added migrations to move settings and keybindings from Comfy.MaskEditor.*Comfy.ImageCanvas.*; updated schema keys.
Extensions & Commands
src/extensions/core/imagecanvas.ts, src/extensions/core/index.ts, src/scripts/app.ts, src/services/litegraphService.ts
Renamed extension and public command IDs from Comfy.MaskEditorComfy.ImageCanvas; updated ComfyApp static members and compatibility hooks.
UI Components
src/components/graph/SelectionToolbox.vue, src/components/graph/SelectionToolbox.test.ts, src/components/imagecanvas/*, src/renderer/extensions/vueNodes/components/ImagePreview.vue
Replaced MaskEditorButton → ImageCanvasButton; updated component imports, templates, CSS class names, localization keys, and related tests.
Composables & Business Logic
src/composables/imagecanvas/*, src/composables/graph/*, src/composables/useCoreCommands.ts
Switched composables and hooks to use useImageCanvasStore and imagecanvas types; updated menu labels, open-command functions, and undo/redo routing to reference image canvas.
Localization
src/locales/en/commands.json, src/locales/en/main.json, src/locales/en/settings.json
Renamed locale keys and strings from Comfy_MaskEditor_*Comfy_ImageCanvas_* (commands, settings, UI text).
Tests
src/composables/imagecanvas/*.test.ts, src/components/graph/SelectionToolbox.test.ts
Updated mocks, imports, and assertions to reference imagecanvas modules and stores instead of maskeditor equivalents.

Possibly related PRs

✨ Finishing touches
  • 📝 Generate docstrings

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 Jan 11, 2026

🎭 Playwright Tests: ❌ Failed

Results: 504 passed, 1 failed, 0 flaky, 8 skipped (Total: 513)

❌ Failed Tests

📊 Browser Reports
  • chromium: View Report (✅ 494 / ❌ 0 / ⚠️ 0 / ⏭️ 8)
  • chromium-2x: View Report (✅ 2 / ❌ 0 / ⚠️ 0 / ⏭️ 0)
  • chromium-0.5x: View Report (✅ 1 / ❌ 0 / ⚠️ 0 / ⏭️ 0)
  • mobile-chrome: View Report (✅ 7 / ❌ 1 / ⚠️ 0 / ⏭️ 0)

@github-actions
Copy link

github-actions bot commented Jan 11, 2026

🎨 Storybook Build Status

loading Build is starting...

⏰ Started at: 01/11/2026, 05:17:25 PM UTC

🚀 Building Storybook

  • 📦 Installing dependencies...
  • 🔧 Building Storybook components...
  • 🌐 Preparing deployment to Cloudflare Pages...

⏱️ Please wait while the Storybook build is in progress...

@github-actions
Copy link

github-actions bot commented Jan 11, 2026

Bundle Size Report

Summary

  • Raw size: 18.8 MB baseline 18.8 MB — 🔴 +3.75 kB
  • Gzip: 3.85 MB baseline 3.85 MB — 🔴 +486 B
  • Brotli: 2.94 MB baseline 2.94 MB — 🔴 +649 B
  • Bundles: 98 current • 98 baseline • 38 added / 38 removed

Category Glance
App Entry Points 🔴 +3.72 kB (3.32 MB) · Graph Workspace 🔴 +32 B (1.03 MB) · Vendor & Third-Party ⚪ 0 B (9.19 MB) · Other ⚪ 0 B (4.74 MB) · Panels & Settings ⚪ 0 B (337 kB) · UI Components ⚪ 0 B (199 kB) · + 3 more

Per-category breakdown
App Entry Points — 3.32 MB (baseline 3.32 MB) • 🔴 +3.72 kB

Main entry bundles and manifests

File Before After Δ Raw Δ Gzip Δ Brotli
assets/index-4cqmgcUy.js (new) 3.12 MB 🔴 +3.12 MB 🔴 +654 kB 🔴 +497 kB
assets/index-BfmxE8Xz.js (removed) 3.12 MB 🟢 -3.12 MB 🟢 -654 kB 🟢 -496 kB
assets/index-sqPa4YPI.js (new) 200 kB 🔴 +200 kB 🔴 +44 kB 🔴 +36.4 kB
assets/index-BpFxLqvZ.js (removed) 200 kB 🟢 -200 kB 🟢 -44 kB 🟢 -36.4 kB
assets/index-BYtodo6L.js (removed) 345 B 🟢 -345 B 🟢 -243 B 🟢 -209 B
assets/index-CpYoJLn3.js (new) 345 B 🔴 +345 B 🔴 +244 B 🔴 +231 B

Status: 3 added / 3 removed

Graph Workspace — 1.03 MB (baseline 1.03 MB) • 🔴 +32 B

Graph editor runtime, canvas, workflow orchestration

File Before After Δ Raw Δ Gzip Δ Brotli
assets/GraphView-DY_xZtLt.js (new) 1.03 MB 🔴 +1.03 MB 🔴 +198 kB 🔴 +150 kB
assets/GraphView-CWpx-Wlr.js (removed) 1.03 MB 🟢 -1.03 MB 🟢 -198 kB 🟢 -150 kB

Status: 1 added / 1 removed

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

Top-level views, pages, and routed surfaces

File Before After Δ Raw Δ Gzip Δ Brotli
assets/UserSelectView-BEyW2x5s.js (removed) 6.63 kB 🟢 -6.63 kB 🟢 -2.14 kB 🟢 -1.9 kB
assets/UserSelectView-BmXrJdug.js (new) 6.63 kB 🔴 +6.63 kB 🔴 +2.14 kB 🔴 +1.9 kB

Status: 1 added / 1 removed

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

Configuration panels, inspectors, and settings screens

File Before After Δ Raw Δ Gzip Δ Brotli
assets/LegacyCreditsPanel-BwywzpV7.js (removed) 25.1 kB 🟢 -25.1 kB 🟢 -5.74 kB 🟢 -5 kB
assets/LegacyCreditsPanel-Cgsj25n2.js (new) 25.1 kB 🔴 +25.1 kB 🔴 +5.74 kB 🔴 +5 kB
assets/KeybindingPanel-BK52ysGc.js (new) 14.8 kB 🔴 +14.8 kB 🔴 +3.57 kB 🔴 +3.12 kB
assets/KeybindingPanel-CIhTPKT1.js (removed) 14.8 kB 🟢 -14.8 kB 🟢 -3.57 kB 🟢 -3.13 kB
assets/ExtensionPanel-CxnzJlBo.js (removed) 11.1 kB 🟢 -11.1 kB 🟢 -2.62 kB 🟢 -2.3 kB
assets/ExtensionPanel-Dh0Ir0oa.js (new) 11.1 kB 🔴 +11.1 kB 🔴 +2.62 kB 🔴 +2.3 kB
assets/AboutPanel-B1h6dUP5.js (removed) 9.16 kB 🟢 -9.16 kB 🟢 -2.46 kB 🟢 -2.2 kB
assets/AboutPanel-BxINzykm.js (new) 9.16 kB 🔴 +9.16 kB 🔴 +2.46 kB 🔴 +2.21 kB
assets/ServerConfigPanel-DKX2lAN8.js (removed) 7.51 kB 🟢 -7.51 kB 🟢 -2.04 kB 🟢 -1.8 kB
assets/ServerConfigPanel-nlLuMRKo.js (new) 7.51 kB 🔴 +7.51 kB 🔴 +2.04 kB 🔴 +1.8 kB
assets/UserPanel-BWC7Pawb.js (new) 6.88 kB 🔴 +6.88 kB 🔴 +1.79 kB 🔴 +1.56 kB
assets/UserPanel-CZGb5hwt.js (removed) 6.88 kB 🟢 -6.88 kB 🟢 -1.79 kB 🟢 -1.56 kB
assets/settings-BbW1wrcp.js 25.2 kB 25.2 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-BhbWhsRg.js 101 B 101 B ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-CtIClcWI.js 26 kB 26 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-D_f3uAqO.js 22.4 kB 22.4 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-DiVjuKQX.js 34.4 kB 34.4 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-DJiF1Y59.js 25.8 kB 25.8 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-DKkx6nFR.js 28.2 kB 28.2 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-DX5qVgIQ.js 24.9 kB 24.9 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-MzsBgiwB.js 21.7 kB 21.7 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-pR7Ue3ei.js 26.7 kB 26.7 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/settings-y_-zNlA6.js 27.5 kB 27.5 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 6 added / 6 removed

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

Reusable component library chunks

File Before After Δ Raw Δ Gzip Δ Brotli
assets/LazyImage.vue_vue_type_script_setup_true_lang-BOHMmYjD.js (removed) 64.5 kB 🟢 -64.5 kB 🟢 -13.1 kB 🟢 -11.4 kB
assets/LazyImage.vue_vue_type_script_setup_true_lang-W0h4_C4b.js (new) 64.5 kB 🔴 +64.5 kB 🔴 +13.1 kB 🔴 +11.4 kB
assets/Load3D.vue_vue_type_script_setup_true_lang-_d43aJlO.js (removed) 56.4 kB 🟢 -56.4 kB 🟢 -8.78 kB 🟢 -7.54 kB
assets/Load3D.vue_vue_type_script_setup_true_lang-ClV0ad9P.js (new) 56.4 kB 🔴 +56.4 kB 🔴 +8.77 kB 🔴 +7.54 kB
assets/WidgetSelect.vue_vue_type_script_setup_true_lang-DKeQbLvj.js (new) 49 kB 🔴 +49 kB 🔴 +10.5 kB 🔴 +9.14 kB
assets/WidgetSelect.vue_vue_type_script_setup_true_lang-DOjaw7t8.js (removed) 49 kB 🟢 -49 kB 🟢 -10.5 kB 🟢 -9.15 kB
assets/WidgetInputNumber.vue_vue_type_script_setup_true_lang-1xCJbo_Z.js (removed) 10.9 kB 🟢 -10.9 kB 🟢 -2.89 kB 🟢 -2.55 kB
assets/WidgetInputNumber.vue_vue_type_script_setup_true_lang-lXpNAQhY.js (new) 10.9 kB 🔴 +10.9 kB 🔴 +2.9 kB 🔴 +2.55 kB
assets/ComfyQueueButton-02MRP9pN.js (new) 8.83 kB 🔴 +8.83 kB 🔴 +2.58 kB 🔴 +2.28 kB
assets/ComfyQueueButton-CzEGDmxI.js (removed) 8.83 kB 🟢 -8.83 kB 🟢 -2.58 kB 🟢 -2.29 kB
assets/WidgetWithControl.vue_vue_type_script_setup_true_lang-B9cjDOxl.js (new) 3.72 kB 🔴 +3.72 kB 🔴 +1.45 kB 🔴 +1.32 kB
assets/WidgetWithControl.vue_vue_type_script_setup_true_lang-BZc-Y0A0.js (removed) 3.72 kB 🟢 -3.72 kB 🟢 -1.45 kB 🟢 -1.32 kB
assets/WidgetButton-1eCbfsR9.js (new) 2.21 kB 🔴 +2.21 kB 🔴 +996 B 🔴 +900 B
assets/WidgetButton-8GzqSxsQ.js (removed) 2.21 kB 🟢 -2.21 kB 🟢 -998 B 🟢 -901 B
assets/WidgetLayoutField.vue_vue_type_script_setup_true_lang-BB2QU9nm.js (removed) 2.14 kB 🟢 -2.14 kB 🟢 -891 B 🟢 -764 B
assets/WidgetLayoutField.vue_vue_type_script_setup_true_lang-Dyz0dxeJ.js (new) 2.14 kB 🔴 +2.14 kB 🔴 +889 B 🔴 +763 B
assets/UserAvatar.vue_vue_type_script_setup_true_lang-CmvGBeCh.js 1.34 kB 1.34 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 8 added / 8 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-BhLzyXI9.js (removed) 7.51 kB 🟢 -7.51 kB 🟢 -1.83 kB 🟢 -1.57 kB
assets/keybindingService-DBS6ojQq.js (new) 7.51 kB 🔴 +7.51 kB 🔴 +1.83 kB 🔴 +1.57 kB
assets/audioService-B4nvZIEb.js (removed) 2.2 kB 🟢 -2.2 kB 🟢 -963 B 🟢 -823 B
assets/audioService-D0uJKSXn.js (new) 2.2 kB 🔴 +2.2 kB 🔴 +963 B 🔴 +824 B
assets/serverConfigStore-lZrt20fn.js 2.83 kB 2.83 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 2 added / 2 removed

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

Helpers, composables, and utility bundles

File Before After Δ Raw Δ Gzip Δ Brotli
assets/audioUtils-CL-QiP9P.js (removed) 1.41 kB 🟢 -1.41 kB 🟢 -652 B 🟢 -543 B
assets/audioUtils-D0ykFpyE.js (new) 1.41 kB 🔴 +1.41 kB 🔴 +650 B 🔴 +544 B

Status: 1 added / 1 removed

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

External libraries and shared vendor chunks

File Before After Δ Raw Δ Gzip Δ Brotli
assets/vendor-chart-C2WamoVK.js 452 kB 452 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-other-Da7BzmIq.js 3.9 MB 3.9 MB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-primevue-CIEAfgED.js 1.95 MB 1.95 MB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-three-Ds3gPtNh.js 2.08 MB 2.08 MB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-tiptap-WJL3cqV8.js 232 kB 232 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-vue-E9hBZNUh.js 160 kB 160 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/vendor-xterm-BF8peZ5_.js 420 kB 420 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
Other — 4.74 MB (baseline 4.74 MB) • ⚪ 0 B

Bundles that do not match a named category

File Before After Δ Raw Δ Gzip Δ Brotli
assets/SubscriptionRequiredDialogContent-CaVq9gtP.js (removed) 29.3 kB 🟢 -29.3 kB 🟢 -6.51 kB 🟢 -5.64 kB
assets/SubscriptionRequiredDialogContent-Dqh0cB10.js (new) 29.3 kB 🔴 +29.3 kB 🔴 +6.51 kB 🔴 +5.66 kB
assets/WidgetRecordAudio-B_HVlGqW.js (new) 20.4 kB 🔴 +20.4 kB 🔴 +5.24 kB 🔴 +4.63 kB
assets/WidgetRecordAudio-BCZI239U.js (removed) 20.4 kB 🟢 -20.4 kB 🟢 -5.24 kB 🟢 -4.64 kB
assets/AudioPreviewPlayer-B0VXo5Ec.js (removed) 13.3 kB 🟢 -13.3 kB 🟢 -3.35 kB 🟢 -3 kB
assets/AudioPreviewPlayer-gUD_qDlf.js (new) 13.3 kB 🔴 +13.3 kB 🔴 +3.35 kB 🔴 +2.99 kB
assets/ValueControlPopover-BAop-V8B.js (new) 5.49 kB 🔴 +5.49 kB 🔴 +1.71 kB 🔴 +1.52 kB
assets/ValueControlPopover-C5IhL4-v.js (removed) 5.49 kB 🟢 -5.49 kB 🟢 -1.71 kB 🟢 -1.51 kB
assets/WidgetGalleria-AQRRei4R.js (removed) 4.1 kB 🟢 -4.1 kB 🟢 -1.45 kB 🟢 -1.31 kB
assets/WidgetGalleria-DCE9oOH-.js (new) 4.1 kB 🔴 +4.1 kB 🔴 +1.45 kB 🔴 +1.3 kB
assets/WidgetColorPicker-Cy_0UPtF.js (removed) 3.41 kB 🟢 -3.41 kB 🟢 -1.38 kB 🟢 -1.24 kB
assets/WidgetColorPicker-Yi7Yl_zW.js (new) 3.41 kB 🔴 +3.41 kB 🔴 +1.38 kB 🔴 +1.24 kB
assets/WidgetTextarea-BYSCEFA3.js (removed) 3.08 kB 🟢 -3.08 kB 🟢 -1.21 kB 🟢 -1.08 kB
assets/WidgetTextarea-DGhFMOZk.js (new) 3.08 kB 🔴 +3.08 kB 🔴 +1.22 kB 🔴 +1.08 kB
assets/WidgetMarkdown-C4Uvv_Po.js (removed) 3.08 kB 🟢 -3.08 kB 🟢 -1.28 kB 🟢 -1.13 kB
assets/WidgetMarkdown-dcOBgyNw.js (new) 3.08 kB 🔴 +3.08 kB 🔴 +1.28 kB 🔴 +1.13 kB
assets/WidgetAudioUI-BoJx3lUB.js (removed) 2.89 kB 🟢 -2.89 kB 🟢 -1.17 kB 🟢 -1.06 kB
assets/WidgetAudioUI-BTw_PBqc.js (new) 2.89 kB 🔴 +2.89 kB 🔴 +1.17 kB 🔴 +1.06 kB
assets/WidgetToggleSwitch-BroEbe33.js (removed) 2.66 kB 🟢 -2.66 kB 🟢 -1.13 kB 🟢 -1.03 kB
assets/WidgetToggleSwitch-DAoFRggq.js (new) 2.66 kB 🔴 +2.66 kB 🔴 +1.13 kB 🔴 +1.02 kB
assets/WidgetInputText-CLOOuRCc.js (new) 1.99 kB 🔴 +1.99 kB 🔴 +921 B 🔴 +865 B
assets/WidgetInputText-D-x3EXQr.js (removed) 1.99 kB 🟢 -1.99 kB 🟢 -921 B 🟢 -831 B
assets/Media3DTop-Bbh5vJlP.js (new) 1.49 kB 🔴 +1.49 kB 🔴 +765 B 🔴 +649 B
assets/Media3DTop-D2GrmX3L.js (removed) 1.49 kB 🟢 -1.49 kB 🟢 -766 B 🟢 -647 B
assets/WidgetSelect-BwERJWg_.js (removed) 733 B 🟢 -733 B 🟢 -360 B 🟢 -304 B
assets/WidgetSelect-C13k57Lr.js (new) 733 B 🔴 +733 B 🔴 +362 B 🔴 +332 B
assets/WidgetInputNumber-BICHULSH.js (removed) 673 B 🟢 -673 B 🟢 -348 B 🟢 -287 B
assets/WidgetInputNumber-noEvwx9I.js (new) 673 B 🔴 +673 B 🔴 +348 B 🔴 +291 B
assets/Load3D-CZlcPoNp.js (new) 424 B 🔴 +424 B 🔴 +267 B 🔴 +222 B
assets/Load3D-D0XO5TQA.js (removed) 424 B 🟢 -424 B 🟢 -269 B 🟢 -223 B
assets/WidgetLegacy-Dw1hPGQc.js (new) 364 B 🔴 +364 B 🔴 +238 B 🔴 +193 B
assets/WidgetLegacy-FtpsACHs.js (removed) 364 B 🟢 -364 B 🟢 -238 B 🟢 -195 B
assets/commands-7wafkPd1.js 15.6 kB 15.6 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-B3CjBnJe.js 14.6 kB 14.6 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-Bbu2TJPy.js 18.1 kB 18.1 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-BWp4HdfU.js 101 B 101 B ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-C4khqsmz.js 15.6 kB 15.6 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-CDQ7KnIn.js 16.4 kB 16.4 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-CtjMsXHh.js 15.4 kB 15.4 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-CW_l758_.js 16.1 kB 16.1 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-DbX4HUlI.js 15.6 kB 15.6 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-DiGLEtFT.js 16.9 kB 16.9 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/commands-vRVJOWju.js 14.8 kB 14.8 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-AHzlz6Hv.js 106 kB 106 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-B-yEiomY.js 106 kB 106 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-BdD2EpUU.js 149 kB 149 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-CLN9TbD-.js 108 kB 108 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-CSUSXmMZ.js 123 kB 123 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-Cw9RZWRY.js 89 B 89 B ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-De35cJhO.js 129 kB 129 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-DmGxyfV2.js 110 kB 110 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-DqO_HJuV.js 94.1 kB 94.1 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-fjwyoOAj.js 94.9 kB 94.9 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/main-Ic_H-Vim.js 113 kB 113 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/MediaAudioTop-DIQlZoPQ.js 1.46 kB 1.46 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/MediaImageTop-C3CvQRZ8.js 1.75 kB 1.75 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/MediaVideoTop-euoHxxM5.js 2.65 kB 2.65 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-B-XzzBeS.js 317 kB 317 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-BGwoeek4.js 329 kB 329 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-Bw_Jitw_.js 101 B 101 B ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-C6xl5-mL.js 358 kB 358 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-CRZGOJB7.js 310 kB 310 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-D8-Yzlzh.js 289 kB 289 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-Du8VrAwA.js 320 kB 320 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-jjlLVrIs.js 317 kB 317 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-JQwk1kgy.js 292 kB 292 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-JuuXdMpv.js 391 kB 391 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/nodeDefs-l2Y20bod.js 314 kB 314 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/OBJLoader2WorkerModule-DTMpvldF.js 109 kB 109 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetChart-DJzJLSiP.js 2.48 kB 2.48 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/WidgetImageCompare-DOYclIRS.js 3.21 kB 3.21 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B
assets/widgetPropFilter-BIbGSUAt.js 1.28 kB 1.28 kB ⚪ 0 B ⚪ 0 B ⚪ 0 B

Status: 16 added / 16 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: 6

Caution

Some comments are outside the diff and can’t be posted inline due to platform limitations.

⚠️ Outside diff range comments (4)
src/composables/imagecanvas/splineUtils.ts (1)

3-126: Consider relocating utility functions to a dedicated utils directory.

This file exports pure mathematical utility functions rather than Vue composables. Since it doesn't use composition API features (ref, computed, watch, etc.), consider moving it to a utils/ directory for better code organization and alignment with the naming convention that composables follow the useXyz.ts pattern.

Note: This is a pre-existing organizational consideration, not introduced by this PR.

src/components/imagecanvas/controls/ToggleControl.vue (1)

19-33: Consider using defineModel for v-model binding.

The current manual v-model implementation works correctly, but Vue 3.5's defineModel provides a simpler, more idiomatic approach for two-way binding.

♻️ Refactor to use defineModel
 <script setup lang="ts">
 interface Props {
   label: string
-  modelValue: boolean
 }
 
 defineProps<Props>()
 
-const emit = defineEmits<{
-  'update:modelValue': [value: boolean]
-}>()
-
-const onChange = (event: Event) => {
-  const checked = (event.target as HTMLInputElement).checked
-  emit('update:modelValue', checked)
-}
+const modelValue = defineModel<boolean>({ required: true })
+
+const onChange = (event: Event) => {
+  modelValue.value = (event.target as HTMLInputElement).checked
+}
 </script>

As per coding guidelines: "Prefer defineModel over separately defining a prop and emit for v-model bindings."

src/components/imagecanvas/controls/SliderControl.vue (1)

27-29: Refactor to Vue 3.5 reactive props destructuring.

The component uses withDefaults, but the coding guidelines require Vue 3.5 style default prop declaration with reactive props destructuring.

♻️ Proposed refactor
-withDefaults(defineProps<Props>(), {
-  step: 1
-})
+const { label, min, max, step = 1, modelValue } = defineProps<Props>()

Based on coding guidelines: "Use TypeScript Vue 3.5 style default prop declaration with reactive props destructuring - avoid withDefaults or runtime props."

packages/design-system/src/css/style.css (1)

489-494: Undefined CSS variables referenced in theme inline block.

These lines reference CSS variables that are not defined:

  • --interface-panel-hover-surface (line 490)
  • --interface-panel-selected-surface (lines 491-493)
  • --interface-button-hover-surface (line 494)

Only their --palette-* prefixed counterparts are defined (lines 295-309). Add the missing variable definitions in :root:

Suggested fix: Add missing variable mappings in :root
   --palette-interface-button-hover-surface: color-mix(
     in srgb,
     var(--interface-panel-surface) 82%,
     var(--contrast-mix-color)
   );
+
+  --interface-panel-hover-surface: var(--palette-interface-panel-hover-surface);
+  --interface-panel-selected-surface: var(--palette-interface-panel-selected-surface);
+  --interface-button-hover-surface: var(--palette-interface-button-hover-surface);
🤖 Fix all issues with AI agents
In @packages/design-system/src/css/style.css:
- Around line 285-309: The palette CSS uses var(--contrast-mix-color) in
color-mix() calls but only --palette-contrast-mix-color is defined; add a
mapping so --contrast-mix-color points to --palette-contrast-mix-color (or
replace the usages to use --palette-contrast-mix-color) so color-mix() receives
a defined variable; update the token definitions around
--palette-contrast-mix-color and the palette tokens (--palette-interface-stroke,
--palette-interface-panel-hover-surface,
--palette-interface-panel-selected-surface,
--palette-interface-button-hover-surface) accordingly.

In @src/composables/graph/useImageMenuOptions.ts:
- Around line 14-17: The click handler openImageCanvas should guard against a
synchronous throw from commandStore.execute: wrap the call to
useCommandStore().execute('Comfy.ImageCanvas.OpenImageCanvas') inside a
try/catch in the openImageCanvas function (or check for a registration method if
available) and swallow or log the error so a missing command id doesn’t bubble
out and break the context menu; reference the openImageCanvas function and
commandStore.execute call when making the change.

In @src/composables/imagecanvas/useBrushDrawing.ts:
- Line 203: The code now calls loadBrushFromCache('imagecanvas_brush_settings')
which will lose users' previous settings stored under
'maskeditor_brush_settings'; update the loading logic in useBrushDrawing (and
the other occurrence around line 1192) to first attempt to read the old key
'maskeditor_brush_settings' and if present migrate/overwrite the new key
'imagecanvas_brush_settings' (or merge and then persist via the existing
save/persist function), otherwise fall back to reading
'imagecanvas_brush_settings', ensuring the migration runs once so users keep
their prior brush settings.

In @src/extensions/core/imagecanvas.ts:
- Around line 151-159: The deprecation warning is logged during init() at
startup even if ComfyApp.open_imagecanvas is never used; change it so init()
only assigns ComfyApp.open_imagecanvas = openImageCanvasFromClipspace and move
the console.warn into a wrapper function that replaces open_imagecanvas with a
function which logs the deprecation when invoked (or logs once on first
invocation) before delegating to openImageCanvasFromClipspace; update references
to ComfyApp.open_imagecanvas and openImageCanvasFromClipspace accordingly so the
warning fires on actual use, not on registration.

In @src/platform/settings/settingStore.ts:
- Around line 262-263: The migration uses api.storeSetting with newSpeedKey and
oldSpeedKey and bypasses type safety with "as any" because the new image canvas
keys (e.g., Comfy.ImageCanvas.BrushAdjustmentSpeed and related keys) are missing
from the Settings type; add those new keys to the Settings interface/type
(matching their expected value types and defaults), update any Settings-related
enums or union types that list keys, then remove the "as any" casts in the
migration so api.storeSetting(newSpeedKey, ...) and
api.storeSetting(oldSpeedKey, ...) are properly typed.
- Around line 290-302: Fix the typo in the commandMappings object: update the
value for 'Comfy.MaskEditor.OpenMaskEditor' from
'Comfy.ImageCanvas.OpenimageCanvas' to the correct registered command ID
'Comfy.ImageCanvas.OpenImageCanvas' so the keybinding migration in
settingStore.ts matches the command registered in imagecanvas.ts (look for the
commandMappings constant and the registered command
'Comfy.ImageCanvas.OpenImageCanvas').

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: 6

🤖 Fix all issues with AI agents
In @src/platform/settings/settingStore.ts:
- Line 325: The call to api.storeSetting uses an `as any` assertion for
`newBindingsKey` (and the similar occurrence at the other call), remove the `as
any` by making the key and value types explicit: update the Settings schema/type
so `newBindingsKey` is typed as the appropriate setting key (e.g., keyof
Settings or the specific SettingKey union) and ensure `migratedBindings` matches
the corresponding Settings value type, then call api.storeSetting with the
concrete types (or a typed key variable) instead of using `as any`; adjust the
Settings type definitions and the variable declarations for
`newBindingsKey`/`migratedBindings` so the compiler can infer correct types and
the `as any` can be eliminated.
- Around line 306-352: Extract the duplicated migration logic into a single
async helper function (e.g., migrateKeybindingSetting) that accepts the setting
key string (like newBindingsKey / unsetBindingsKey), reads
settingValues.value[key], verifies Array.isArray, maps bindings replacing
binding.commandId using commandMappings, and if any modified updates
settingValues.value[key], calls await api.storeSetting(key as any,
migratedBindings) and returns a boolean indicating whether it migrated; then
call this helper for both 'Comfy.Keybinding.NewBindings' and
'Comfy.Keybinding.UnsetBindings' and set anyMigrated = anyMigrated || await
migrateKeybindingSetting(key). Ensure you reuse commandMappings, settingValues,
and api.storeSetting and preserve the original shape of binding objects.
- Around line 251-279: The two migration blocks for
'Comfy.MaskEditor.BrushAdjustmentSpeed' ->
'Comfy.ImageCanvas.BrushAdjustmentSpeed' and 'Comfy.MaskEditor.UseDominantAxis'
-> 'Comfy.ImageCanvas.UseDominantAxis' are duplicated; extract the logic into a
small async helper like migrateSetting(oldKey: string, newKey: string) that
checks settingValues.value[oldKey] !== undefined && settingValues.value[newKey]
=== undefined, copies the value into settingValues.value[newKey], deletes
settingValues.value[oldKey], then awaits api.storeSetting(newKey as any,
oldValue) and await api.storeSetting(oldKey as any, undefined); replace both
blocks with calls to migrateSetting(oldSpeedKey, newSpeedKey) and
migrateSetting(oldAxisKey, newAxisKey).
- Around line 246-283: The migrateMaskEditorToImageCanvas function currently
calls api.storeSetting without error handling which can leave settings
inconsistent; wrap each migration block (the BrushAdjustmentSpeed and
UseDominantAxis branches) in try-catch, persist the new key with
api.storeSetting(newKey, oldValue) before deleting the old in
settingValues.value, and only delete/clear the old key after the new store
succeeds; on any catch, log the error (or rethrow) and avoid deleting the
original setting so state remains consistent; apply the same guarded pattern
around migrateMaskEditorKeybindings or call it after both migrations succeed.
- Around line 289-355: The function migrateMaskEditorKeybindings currently
computes and returns anyMigrated but the caller doesn't use it; change the
function to return Promise<void> by removing the anyMigrated variable and final
return, delete assignments to anyMigrated inside both NewBindings and
UnsetBindings migration blocks, and leave the await api.storeSetting calls
intact; also update the caller that invoked migrateMaskEditorKeybindings to
ignore the result (no changes to behavior) or optionally add a log inside
migrateMaskEditorKeybindings if you want to record migrations instead of
returning a value.
📜 Review details

Configuration used: Organization UI

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 09fe7e4 and 5996145.

📒 Files selected for processing (1)
  • src/platform/settings/settingStore.ts
🧰 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/platform/settings/settingStore.ts
src/**/*.ts

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

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

src/**/*.ts: Derive component types using vue-component-type-helpers (ComponentProps, ComponentSlots) instead of separate type files
Use es-toolkit for utility functions
Minimize the surface area (exported values) of each module and composable
Favor pure functions, especially testable ones

Files:

  • src/platform/settings/settingStore.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

src/**/*.{ts,tsx,vue}: Use separate import type statements instead of inline type in mixed imports
Apply Prettier formatting with 2-space indentation, single quotes, no trailing semicolons, 80-character width
Sort and group imports by plugin, run pnpm format before committing
Never use any type - use proper TypeScript types
Never use as any type assertions - fix the underlying type issue
Write code that is expressive and self-documenting - avoid unnecessary comments
Do not add or retain redundant comments - clean as you go
Avoid mutable state - prefer immutability and assignment at point of declaration
Watch out for Code Smells and refactor to avoid them

Files:

  • src/platform/settings/settingStore.ts
src/**/*.{vue,ts,tsx}

📄 CodeRabbit inference engine (src/CLAUDE.md)

Follow Vue 3 composition API style guide

Files:

  • src/platform/settings/settingStore.ts
src/**/*.{ts,vue}

📄 CodeRabbit inference engine (AGENTS.md)

src/**/*.{ts,vue}: Use ref for reactive state, computed() for derived values, and watch/watchEffect for side effects in Composition API
Avoid using ref with watch if a computed would suffice - minimize refs and derived state
Use provide/inject for dependency injection only when simpler alternatives (Store or shared composable) won't work
Leverage VueUse functions for performance-enhancing composables
Use VueUse function for useI18n in composition API for string literals

Files:

  • src/platform/settings/settingStore.ts
src/**/*.{ts,tsx}

📄 CodeRabbit inference engine (AGENTS.md)

src/**/*.{ts,tsx}: Keep functions short and functional
Minimize nesting (if statements, for loops, etc.)
Use function declarations instead of function expressions when possible

Files:

  • src/platform/settings/settingStore.ts
🧠 Learnings (5)
📚 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/platform/settings/settingStore.ts
📚 Learning: 2025-12-13T11:03:11.264Z
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 7416
File: src/stores/imagePreviewStore.ts:5-7
Timestamp: 2025-12-13T11:03:11.264Z
Learning: In the ComfyUI_frontend repository, lint rules require keeping 'import type' statements separate from non-type imports, even if importing from the same module. Do not suggest consolidating them into a single import statement. Ensure type imports remain on their own line (import type { ... } from 'module') and regular imports stay on separate lines.

Applied to files:

  • src/platform/settings/settingStore.ts
📚 Learning: 2025-12-17T00:40:09.635Z
Learnt from: DrJKL
Repo: Comfy-Org/ComfyUI_frontend PR: 7537
File: src/components/ui/button/Button.stories.ts:45-55
Timestamp: 2025-12-17T00:40:09.635Z
Learning: Prefer pure function declarations over function expressions (e.g., use function foo() { ... } instead of const foo = () => { ... }) for pure functions in the repository. Function declarations are more functional-leaning, offer better hoisting clarity, and can improve readability and tooling consistency. Apply this guideline across TypeScript files in Comfy-Org/ComfyUI_frontend, including story and UI component code, except where a function expression is semantically required (e.g., callbacks, higher-order functions with closures).

Applied to files:

  • src/platform/settings/settingStore.ts
📚 Learning: 2025-12-30T22:22:33.836Z
Learnt from: kaili-yang
Repo: Comfy-Org/ComfyUI_frontend PR: 7805
File: src/composables/useCoreCommands.ts:439-439
Timestamp: 2025-12-30T22:22:33.836Z
Learning: When accessing reactive properties from Pinia stores in TypeScript files, avoid using .value on direct property access (e.g., useStore().isOverlayExpanded). Pinia auto-wraps refs when accessed directly, returning the primitive value. The .value accessor is only needed when destructuring store properties or when using storeToRefs().

Applied to files:

  • src/platform/settings/settingStore.ts
📚 Learning: 2025-12-11T12:25:15.470Z
Learnt from: christian-byrne
Repo: Comfy-Org/ComfyUI_frontend PR: 7358
File: src/components/dialog/content/signin/SignUpForm.vue:45-54
Timestamp: 2025-12-11T12:25:15.470Z
Learning: This repository uses CI automation to format code (pnpm format). Do not include manual formatting suggestions in code reviews for Comfy-Org/ComfyUI_frontend. If formatting issues are detected, rely on the CI formatter or re-run pnpm format. Focus reviews on correctness, readability, performance, accessibility, and maintainability rather than style formatting.

Applied to files:

  • src/platform/settings/settingStore.ts
🧬 Code graph analysis (1)
src/platform/settings/settingStore.ts (1)
src/scripts/api.ts (1)
  • api (1336-1336)
⏰ 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: collect
  • GitHub Check: lint-and-format
🔇 Additional comments (1)
src/platform/settings/settingStore.ts (1)

202-204: LGTM! Migration invocation is correctly placed.

The migration is properly positioned in the initialization flow after settings are loaded from the server but before any settings are registered, which ensures user settings are preserved during the rename.

@trsommer
Copy link
Collaborator

I might be wrong, but I feel this could confuse users. “Image Canvas” doesn’t suggest masking or editing features to me at all. I agree the current name is terrible, but I don’t think Image Canvas is the right choice. How about Image Editing & Masking (or something similar)?

@brucew4yn3rp
Copy link
Collaborator Author

Thanks @trsommer. I get the concern, but I’d push back a bit on the idea that Image Canvas doesn’t imply editing. In most graphics tools, a “canvas” is explicitly the surface where editing happens. Examples of this naming include Photoshop’s canvas, Procreate’s canvas, even HTML5.

image image

Also, the transitional label was “Mask Editor | Image Canvas”, and the natural evolution is the drop-off of the Mask Editor legacy name as to not anchor the naming to one or two features.

With that said, open to feedback if others feel strongly.

@brucew4yn3rp
Copy link
Collaborator Author

Hi @christian-byrne would you / another team member mind reviewing when you have a chance?

I think the other requested reviews are just auto-triggered because of codeowner statuses but not fully relevant since the changes are just naming-related.

@jtydhr88
Copy link
Collaborator

Hi, firstly, thanks for contributing this.
However, right now we are implementing some core features like such full screen size editor, we might reuse this mask editor, we might re-implement, it is still under discussion.
So I would like to pause this PR right now, till we make decisions.

Convert it as draft for now

@jtydhr88 jtydhr88 marked this pull request as draft January 13, 2026 16:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:XXL This PR changes 1000+ lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants