Open
Description
requirements
ScrollView
is fluid (width/height 100%) and this brings up a problem:
- width/height 100% always refers to parent -->
ScrollView
doesn't take into account itschildren
size - max-width/height always refers to parent's width/height --> putting max-width/height on parent is useless
Take the example of Menu
in PanelMenu
/ContextualMenu
:
- we want
ScrollView
to have the size of its content - we want
ScrollView
to stop at some point and enable scrolling (max-width/height)
That is currently impossible.
specs
we should consider refactoring ScrollVIew
to have
width/height: auto
(grow with content)
and one of these two:
- have
max-width/height: 100%
(don't overflow parent) - have
max-width/height: inherit
(use parent's max-width/height --> throw warning if missing)
I may prefer the first one as max-width/height
could always be overwritten with inline style through props (also, it's less magical)
...
...
or simply use FlexView
and require the parent to be a column FlexView
!
misc
This is a breaking change --> it'll probably break some points of current layout