codepod
codepod copied to clipboard
[UI][RFC] SelectiveView
Summary
A prototype of SelectiveView via multi-select items in ToC
- The Canvas only displays selected pods.
- The
Editmode is not affected.
However
- The current implementation renders a deep copy of the selected pods from
nodesMapinupdateView(), thus ALL operations that engage withnodesMapneed to be properly synced, e.g., moving a pod, creating a new pod, changing the size of a pod, etc. I am not exactly sure if it's the best approach and ask for some comments here.
Test
- The current implementation renders a deep copy of the selected pods from
nodesMapinupdateView()
I didn't see "a deep copy". I think you are doing the right thing here, to compute a subset of nodes and set({nodes}).
However, I don't quite understand the gif/code:
- Your gif doesn't show a "partial view" of the canvas. All pods seem to be shown.
- The sidebar ToC should be "togglable" into three states (selected, hidden, blocked), something like this:
- Your gif doesn't show a "partial view" of the canvas. All pods seem to be shown.
It's due to the native multi-selection of tree-view, instead of checkbox-based selection, the selective view happens when there're more than 1 items selected in ToC.
the
selective viewhappens when there're more than 1 items selected in ToC.
Oh, I see.