Commit graph

1 commit

Author SHA1 Message Date
Danila Poyarkov ef0b45f0c1 Fix instance swap override propagation through clone chains
Instance swap overrides (symbolOverrides with overriddenSymbolID) now
correctly propagate through multi-level clone chains:

- Track swapped instances in a dedicated set to distinguish real swaps
  from normal clone-chain componentId differences
- Reclone children when a source instance was swapped, copying name,
  componentId, and re-populating children from the swapped component
- Mark recloned targets as swapped too, enabling transitive propagation
  to deeper clone levels (e.g. Preview Thumbnail toolbar icons)
- Only rename on swap when the current name matches the root component
  name, preserving user-given names like 'Static Icon'
- Use getComponentRoot (with cycle detection) instead of manual chain walk
- Null-check source before deleting target children in recloneChildren
2026-03-13 18:58:33 +03:00