]> git.ipfire.org Git - thirdparty/foundation/foundation-sites.git/commitdiff
Update _functions.scss 5933/head
authorHampton Catlin <hcatlin@gmail.com>
Tue, 14 Oct 2014 20:02:28 +0000 (16:02 -0400)
committerHampton Catlin <hcatlin@gmail.com>
Tue, 14 Oct 2014 20:02:28 +0000 (16:02 -0400)
Updating the exports() function to work with Sass 3.2/3.3 and libsass 2.0 which return false for index() AND add support for Sass 3.4 and libsass 3.0 with the new behaviour.

scss/foundation/_functions.scss

index f018ced0e211f1fb75467fb822d52091e935f038..e7eb856d95911f900007fa177eaf3c02aa29acb5 100644 (file)
@@ -9,7 +9,8 @@ $rem-base: 16px !default;
 // We use this to prevent styles from being loaded multiple times for compenents that rely on other components. 
 $modules: () !default;
 @mixin exports($name) {
-  @if (index($modules, $name) == false) {
+  $module_index: index($modules, $name);
+  @if (($module_index == null) or ($module_index == false)) {
     $modules: append($modules, $name);
     @content;
   }