Created
December 9, 2021 02:10
-
-
Save greglockwood/2a4c0659765b0de8cdc9916ca24d6b6d to your computer and use it in GitHub Desktop.
Generated by SassMeister.com.
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
@function -strip-unit($num) { | |
@return $num / ($num * 0 + 1); | |
} | |
@function -convert-to-rem($value, $base-value) { | |
$value: -strip-unit($value) / -strip-unit($base-value) * 1rem; | |
@if ($value == 0rem) { $value: 0; } // Turn 0rem into 0 | |
@return $value; | |
} | |
// convert from px to rem. | |
// px measurements must be based on 1080p resolution | |
// e.g. p {@include convert1080pxToREM(12px);} | |
@function convert1080pxToREM($size) { | |
@return -convert-to-rem($size, 15px); | |
} | |
$ott-spinner-size: convert1080pxToREM(75px); | |
$otherValue: convert1080pxToREM(150); | |
.loadingSpinner { | |
margin-left: -($ott-spinner-size / 2); | |
margin-bottom: -($ott-spinner-size / 2); | |
width: $otherValue; | |
height: $ott-spinner-size; | |
} |
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
.loadingSpinner { | |
margin-left: -2.5rem; | |
margin-bottom: -2.5rem; | |
width: 10rem; | |
height: 5rem; | |
} |
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
{ | |
"sass": { | |
"compiler": "dart-sass/1.32.12", | |
"extensions": {}, | |
"syntax": "SCSS", | |
"outputStyle": "expanded" | |
}, | |
"autoprefixer": false | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment