-
-
Save jetsloth/3faefc105d6b2c009e783f665cd07baa to your computer and use it in GitHub Desktop.
Custom CSS for tiled image choices based on https://www.materialpalette.com/pink/red
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
.image-choices-field { | |
padding: 0 !important; | |
margin: 0 !important; | |
} | |
.image-choices-field .image-choices-choice, | |
.gform_wrapper .gfield.image-choices-field li.image-choices-choice { | |
margin: 0 !important; | |
border: none !important; | |
position: relative; | |
vertical-align: middle; | |
width: 20%; | |
overflow: hidden; | |
background-color: #374046; | |
} | |
.image-choices-field .image-choices-choice-image-wrap { | |
width: 100%; | |
height: auto; | |
padding-bottom: 100%; | |
background-color: transparent; | |
background-size: cover; | |
} | |
.image-choices-field ul.gfield_checkbox, | |
.image-choices-field ul.gfield_radio { | |
width: 100% !important; | |
margin: 0 !important; | |
} | |
.image-choices-field .image-choices-choice label { | |
display: block !important; | |
padding: 0 !important; | |
border: none !important; | |
position: relative; | |
color: #fff; | |
text-align: left; | |
transition: all 0.2s; | |
} | |
.image-choices-field .image-choices-choice label:after { | |
content: "✓"; | |
display: block; | |
position: absolute; | |
bottom: 15px; | |
right: 18px; | |
opacity: 0.5; | |
transition: all 0.2s; | |
} | |
.image-choices-field.image-choices-show-labels .image-choices-choice-text { | |
display: block; | |
position: absolute; | |
width: 100%; | |
top: 0; | |
left: 0; | |
padding: 10px; | |
} | |
.image-choices-field .image-choices-choice.image-choices-choice-hover label, | |
.image-choices-field .image-choices-choice.image-choices-choice-selected label { | |
transform: scale(0.9); | |
} | |
.image-choices-field .image-choices-choice.image-choices-choice-selected label:after { | |
opacity: 1; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment