Created
December 11, 2018 04:50
-
-
Save AlexBrasileiro/88b9ef3cccafcfd8b9868a9fad5ee563 to your computer and use it in GitHub Desktop.
Responsive images with Flexbox
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<figure> | |
<img /> | |
</figure> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
figure { | |
display: flex; | |
align-items: flex-start; | |
max-height: 450px; | |
overflow: hidden; | |
} | |
figure > img { | |
width: 100%; | |
height: auto; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment