1
0
mirror of https://github.com/mrclay/minify.git synced 2025-01-17 05:08:14 +01:00

Use scssphp/scssphp

This commit is contained in:
Steve Clay 2024-01-04 00:25:09 -05:00
parent bc1ffdc5fc
commit 9e182a6255
2 changed files with 4 additions and 5 deletions

View File

@ -44,9 +44,9 @@
}, },
"require-dev": { "require-dev": {
"firephp/firephp-core": "~0.4.0", "firephp/firephp-core": "~0.4.0",
"leafo/scssphp": "^0.3 || ^0.6 || ^0.7",
"meenie/javascript-packer": "~1.1", "meenie/javascript-packer": "~1.1",
"phpunit/phpunit": "^8", "phpunit/phpunit": "^8",
"scssphp/scssphp": "^1.12",
"tedivm/jshrink": "~1.1.0" "tedivm/jshrink": "~1.1.0"
}, },
"suggest": { "suggest": {

View File

@ -1,7 +1,6 @@
<?php <?php
use Leafo\ScssPhp\Compiler; use ScssPhp\ScssPhp\Compiler;
use Leafo\ScssPhp\Server; use ScssPhp\ScssPhp\Version;
use Leafo\ScssPhp\Version;
/** /**
* Class for using SCSS files * Class for using SCSS files
@ -152,7 +151,7 @@ class Minify_ScssCssSource extends Minify_Source
// and will treat the @import line as css import // and will treat the @import line as css import
$scss->setImportPaths(dirname($filename)); $scss->setImportPaths(dirname($filename));
$css = $scss->compile(file_get_contents($filename), $filename); $css = $scss->compileString(file_get_contents($filename), $filename)->getCss();
$elapsed = round((microtime(true) - $start), 4); $elapsed = round((microtime(true) - $start), 4);
$v = Version::VERSION; $v = Version::VERSION;