Open polamoros opened 3 weeks ago
Map is recentered and the zoom is restarted when expanding/collapsing a node.
https://github.com/winglang/wing/assets/5547636/1e5c1b5b-a7e1-4ad3-ac60-15d360745104
https://github.com/winglang/wing/assets/5547636/471a3720-9061-471f-b879-a7daed6c3be3
Improve the collapsing/expanding transition by keeping the same zoom level and the node position.
Reuse previous node positions in elk.layout() https://github.com/winglang/wing/blob/main/apps/wing-console/console/ui/src/ui/elk-flow/graph-generator.tsx#L216
elk.layout()
No response
Wing Console
feat-reuse-previous-node-positions
Use Case
Map is recentered and the zoom is restarted when expanding/collapsing a node.
https://github.com/winglang/wing/assets/5547636/1e5c1b5b-a7e1-4ad3-ac60-15d360745104
https://github.com/winglang/wing/assets/5547636/471a3720-9061-471f-b879-a7daed6c3be3
Proposed Solution
Improve the collapsing/expanding transition by keeping the same zoom level and the node position.
Reuse previous node positions in
elk.layout()
https://github.com/winglang/wing/blob/main/apps/wing-console/console/ui/src/ui/elk-flow/graph-generator.tsx#L216Implementation Notes
No response
Component
Wing Console
Community Notes