From cc092272eefa0e89bebfc716c8df8214d2804c77 Mon Sep 17 00:00:00 2001 From: gijsbotje Date: Wed, 13 Sep 2017 17:32:44 +0200 Subject: modified the yiq to to an actual function function only returns a value, not the attribute itself updated every use of the former mixin to use the new function --- scss/_functions.scss | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'scss/_functions.scss') diff --git a/scss/_functions.scss b/scss/_functions.scss index a63680aa5..bbb015d07 100644 --- a/scss/_functions.scss +++ b/scss/_functions.scss @@ -49,7 +49,7 @@ } // Color contrast -@mixin color-yiq($color) { +@function color-yiq($color) { $r: red($color); $g: green($color); $b: blue($color); @@ -57,9 +57,9 @@ $yiq: (($r * 299) + ($g * 587) + ($b * 114)) / 1000; @if ($yiq >= 150) { - color: #111; + @return #111; } @else { - color: #fff; + @return #fff; } } -- cgit v1.2.3