[backport core/1.40] fix: propagate widget disabled state to Vue node components (#9594)

Backport of #9321 to `core/1.40`

Automatically created by backport workflow.

┆Issue is synchronized with this [Notion
page](https://www.notion.so/PR-9594-backport-core-1-40-fix-propagate-widget-disabled-state-to-Vue-node-components-31d6d73d3650817793c4f389e8252614)
by [Unito](https://www.unito.io)

Co-authored-by: Terry Jia <terryjia88@gmail.com>
This commit is contained in:
Comfy Org PR Bot
2026-03-08 11:38:30 +09:00
committed by GitHub
parent 96823b6f58
commit 503eb72c8b

View File

@@ -192,9 +192,11 @@ const processedWidgets = computed((): ProcessedWidget[] => {
// Get value from store (falls back to undefined if not registered)
const value = widgetState?.value as WidgetValue
// Build options from store state, with slot-linked override for disabled
// Build options from store state, with disabled override for
// slot-linked widgets or widgets with disabled state (e.g. display-only)
const storeOptions = widgetState?.options ?? {}
const widgetOptions = slotMetadata?.linked
const isDisabled = slotMetadata?.linked || widgetState?.disabled
const widgetOptions = isDisabled
? { ...storeOptions, disabled: true }
: storeOptions