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
//YIQ Implementation | |
@function yiq($color) { | |
$red : red($color); | |
$green: green($color); | |
$blue : blue($color); | |
@return (($red*.299)+($green*.587)+($blue*.114)); | |
} | |
@function color-contrast($background, $dark:#000, $light:#fff) { |
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
div { | |
$colors: ( | |
#c82639, | |
#ef8e00, | |
#9bbc1a, | |
#28649a, | |
); | |
$l: length($colors); | |
@each $color in $colors { | |
$i: index($colors, $color); |
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
# Rules to correctly serve gzip compressed CSS and JS files. | |
# Requires both mod_rewrite and mod_headers to be enabled. | |
<IfModule mod_headers.c> | |
# Serve brotli compressed CSS files if they exist and the client accepts gzip. | |
RewriteCond %{HTTP:Accept-encoding} br | |
RewriteCond %{REQUEST_FILENAME}\.br -s | |
RewriteRule ^(.*)\.css $1\.css\.br [QSA] | |
# Serve gzip compressed CSS files if they exist and the client accepts gzip. | |
RewriteCond %{HTTP:Accept-encoding} gzip |
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
RewriteCond %{HTTPS} !on | |
RewriteCond %{REQUEST_URI} !^/.well-known/ | |
RewriteRule (.*) https://%{HTTP_HOST}%{REQUEST_URI} [R=301,L] |
NewerOlder