function sassy_compass_prepro_precompile_sass_alter in Sassy 7.2
Adds the Compass libraries to all SASS files if the user selected this option in the Prepro admin screen.
1 call to sassy_compass_prepro_precompile_sass_alter()
- sassy_compass_prepro_precompile_scss_alter in extensions/
compass/ sassy_compass.module - Adds the Compass libraries to all SCSS files if the user selected this option in the Prepro admin screen.
File
- extensions/
compass/ sassy_compass.module, line 136
Code
function sassy_compass_prepro_precompile_sass_alter(&$contents, $file, $local) {
if (@$local['compass_implicit_include']) {
if (strpos($contents, 'compass/compass') === FALSE && strpos($contents, 'compass/*') === FALSE) {
$comment = '/* ' . t('Including Compass libraries via implicit include') . ' */';
$contents = $comment . "\n@import 'compass/compass';\n\n" . $contents;
}
}
}