Inwerpsel / use-theme-editor

A React theme editor
GNU General Public License v3.0
4 stars 0 forks source link

Use sticky position on long lists in the inspector to ensure list heading/title is always in view #34

Open Inwerpsel opened 1 year ago

Inwerpsel commented 1 year ago

Currently there are a few cases where long lists result in only a section of the list being in view, forcing you to either remember what the list is about, or scroll up to remind yourself.

It would be nice if each list that can be long is accompanied by a sticky heading. It would allow both seeing what the list is about, and closing it without scrolling.

One challenge is that the second list is inside of the first. Also currently both are lengthening the area they're inside of. So the things we want to be sticky are not direct descendants of the scrollable element they're inside of.

Perhaps the variable list you get when clicking "Link" should function in the same way. Currently this uses a max height and internal scrolling. Then again, this list is a very simple and crude component that will be significantly changed in the future, so maybe better to not touch for now.

Perhaps other things can be done to make big lists more manageable (filtering, better grouping, ...), and those might be enough to make the sticky position unnecessary.