Created
March 23, 2017 14:34
-
-
Save dainiuxt/7b2011c7360b367f45c89fb82f0684f5 to your computer and use it in GitHub Desktop.
Divi portfolio grid view image resize.
Just change the padding-top until you get the desired aspect ratio.
This file contains hidden or 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
.et_portfolio_image { | |
padding-top: 100%; | |
} | |
.et_portfolio_image img { | |
position: absolute; | |
height: 100%; | |
top: 0; | |
left: 0; | |
right: 0; | |
bottom: 0; | |
object-fit: cover; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment