BREAKING CHANGE: Removed dynamic input_count approach entirely
New design:
- keys: multiline text box (one key name per line)
- value_1 ~ value_10: fixed input slots
- Line 1 → value_1, Line 2 → value_2, etc.
Removed frontend JS - no dynamic widgets needed.
This is the most reliable approach since ComfyUI doesn't
support dynamic widget value passing to backend.
Implementation:
- Keys: addWidget('text') with custom serializeValue()
- Values: addInput() for connection slots
- onSerialize: saves dynamic key widget values to node properties
- onConfigure: restores key widgets on workflow load
This allows keys to be pure editable text boxes (not forceInput)
while still being properly serialized and restored.
BREAKING CHANGE: Keys now use forceInput=False (can type OR connect)
- Backend: key_N uses forceInput=False, value_N uses forceInput=True
- Frontend: dynamically adds both as proper inputs (not widgets)
- This ensures ComfyUI correctly serializes dynamic inputs
- Fixes issue where dynamically added keys were not being loaded
- Custom draw function for button rendering
- Blue gradient background (#3a6ea5 → #2c5282)
- Rounded corners (6px radius)
- Subtle border and top highlight
- Icon prefix (⟳) for visual appeal
- Follows Google Material Design principles
Changes:
- Removed unnecessary base_json parameter
- Keys are now editable text widgets (not forceInput)
- Values remain as input slots for upstream connections
- Frontend JS updated to add text widgets for keys