refactor: Working selection management and layout

Still needs expland/collapse
refactor: Add back expand/collapse functionality