-
Notifications
You must be signed in to change notification settings - Fork 3.4k
layout: add flex="noshrink" option #6067
Comments
@julienpa - RE > I just want it to be hidden and accessible when scrolling, to keep the same design. Meanwhile, the
|
@ThomasBurleson I can't hide it, there are important information in there (it's an offline training app). I can keep doing it manually, it's ok. |
What about: Just suggestions to keep names that have a meaning without technical |
@julienpa - Based on your feedback, I think |
@ThomasBurleson So should I change my PR to |
@devversion - That would be great. Thx |
Ok for me, that would be great! |
I've just read this thread: #2632
And based on this specification: https://gist.github.com/ThomasBurleson/88152ec57c9133dec57a
...there is no way to make an element grow by default without shrinking when viewport's height is too small.
The only option to prevent shrinking is
flex="none"
but then the element won't grow.My sample code:
The first
<div>
has a fixed size and I want the second one to take the rest of the space. But when viewport height is too small, I don't want the second<div>
to shrink because it breaks the design. I just want it to be hidden and accessible when scrolling, to keep the same design.So currently I have to set
flex-shrink: 0
manually.Having something like
[flex="fixed"] { flex: 1 0 auto; }
or[flex="noshrink"] { flex: 1 0 auto; }
would be really handy (it's the opposite of initial).The text was updated successfully, but these errors were encountered: