Created
August 8, 2019 17:11
-
-
Save zastrow/bd1ce9330b57021c4d060f60c2c22dd5 to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
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
> 1% | |
last 2 versions |
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
// ---- | |
// libsass (v3.5.4) | |
// ---- | |
@mixin positions($top:null, $right:null, $bottom:null, $left:null) { | |
@if ($top != null and $right == null and $bottom == null and $left == null) { | |
$top: $top; | |
$right: $top; | |
$bottom: $top; | |
$left: $top; | |
} | |
@else if ($top != null and $right != null and $bottom == null and $left == null) { | |
$top: $top; | |
$right: $right; | |
$bottom: $top; | |
$left: $right; | |
} | |
@else if ($top != null and $right != null and $bottom != null and $left == null) { | |
$top: $top; | |
$right: $right; | |
$bottom: $bottom; | |
$left: $right; | |
} | |
@else if ($top != null and $right != null and $bottom != null and $left != null) { | |
$top: $top; | |
$right: $right; | |
$bottom: $bottom; | |
$left: $left; | |
} | |
top: $top; | |
right: $right; | |
bottom: $bottom; | |
left: $left; | |
} | |
.example-1 { | |
position: absolute; | |
@include positions(1rem); | |
} | |
.example-2 { | |
position: absolute; | |
@include positions(1rem, 2rem); | |
} | |
.example-3 { | |
position: absolute; | |
@include positions(1rem, 2rem, 3rem); | |
} | |
.example-3 { | |
position: absolute; | |
@include positions(1rem, 2rem, 3rem, 4rem); | |
} |
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
.example-1 { | |
position: absolute; | |
top: 1rem; | |
right: 1rem; | |
bottom: 1rem; | |
left: 1rem; | |
} | |
.example-2 { | |
position: absolute; | |
top: 1rem; | |
right: 2rem; | |
bottom: 1rem; | |
left: 2rem; | |
} | |
.example-3 { | |
position: absolute; | |
top: 1rem; | |
right: 2rem; | |
bottom: 3rem; | |
left: 2rem; | |
} | |
.example-3 { | |
position: absolute; | |
top: 1rem; | |
right: 2rem; | |
bottom: 3rem; | |
left: 4rem; | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment