mirror of
https://github.com/Comfy-Org/ComfyUI_frontend.git
synced 2026-05-24 22:58:08 +00:00
Consolidate the Parameters-panel drag-and-drop wiring into SectionWidgets,
which now owns the imperative DraggableList lifecycle and emits a typed
`@reorder { fromIndex, toIndex }` event.
TabSubgraphInputs previously passed UI-list indices straight to
reorderSubgraphInputAtIndex, which interprets them as indices into
subgraph.inputs. Because the rendered list is a filtered + augmented view
(filters out non-promoted inputs, appends virtual host widgets), the
indices misaligned whenever any non-promoted input or extra widget was
present — moving the wrong row.
Both Subgraph reorder paths now go through reorderSubgraphInputsByWidgetOrder,
which resolves positions by widget identity, matching the Subgraph Editor.
TabGlobalParameters shares the same SectionWidgets reorder contract.
Amp-Thread-ID: https://ampcode.com/threads/T-019e4cdc-434e-7659-9e1f-b29e3ad8ac14
Co-authored-by: Amp <amp@ampcode.com>