mdgriffith / style-elements

Create styles that don't mysteriously break!
http://package.elm-lang.org/packages/mdgriffith/style-elements/latest
BSD 3-Clause "New" or "Revised" License
445 stars 49 forks source link

Styles not being applied to content height #121

Closed ivnsch closed 6 years ago

ivnsch commented 6 years ago

The big picture of what I'm trying to do

Apply a style to a vertically scrollable area with content height. E.g. a shadow or a background image.

What I did

https://ellie-app.com/c65RQMcbYa1/2

What I Expected To Happen

The shadow surrounds the complete area.

What Actually Happened

The shadow only is applied to the part of the area that's initially visible (what would be height fill). This happens with css background images as well.

Notes:

Edit In Chrome I was able to fix it by adding height: fit-content as a custom attribute, to the div with the shadow/background. But seems to be an invalid property in Firefox. In Firefox actually there was no value for height that would make the parent div take the height of the children.

Versions

mdgriffith commented 6 years ago

Switching height to minHeight on the parent row resolved it like we spoke on slack. Thanks for the issue!