Created
April 28, 2016 16:30
-
-
Save shaimoom/eeb2ed0ccecad8e3cb814a1229c7e3fa to your computer and use it in GitHub Desktop.
ZURB Foundation for Emails responsive spacers using a SASS list
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
// add classname spacer$i to <spacer> tag in your HTML (e.g. <spacer size="20" class="spacer20") | |
// choose numbers for $spacer based on what size spacer you need | |
$spacer: 10, 20, 30, 40, 50; | |
@each $i in $spacer { | |
.spacer#{$i} td{ | |
@media (max-width: 596px) { | |
font-size: ($i/2+px) !important; // reduces spacer in half on mobile screens, customize as needed | |
line-height: ($i/2+px) !important; // reduces spacer in half on mobile screens, customize as needed | |
height: ($i/2+px) !important; // reduces spacer in half on mobile screens, customize as needed | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment