Skip to content

Commit

Permalink
Upgraded scssphp/scssphp vendor to v1.13.0
Browse files Browse the repository at this point in the history
  • Loading branch information
TheCartpenter committed Aug 18, 2024
1 parent 5930e73 commit 329854e
Show file tree
Hide file tree
Showing 13 changed files with 138 additions and 63 deletions.
12 changes: 6 additions & 6 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

14 changes: 7 additions & 7 deletions upload/system/storage/vendor/composer/installed.json
Original file line number Diff line number Diff line change
Expand Up @@ -661,17 +661,17 @@
},
{
"name": "scssphp/scssphp",
"version": "v1.12.1",
"version_normalized": "1.12.1.0",
"version": "v1.13.0",
"version_normalized": "1.13.0.0",
"source": {
"type": "git",
"url": "https://github.com/scssphp/scssphp.git",
"reference": "394ed1e960138710a60d035c1a85d43d0bf0faeb"
"reference": "63d1157457e5554edf00b0c1fabab4c1511d2520"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/scssphp/scssphp/zipball/394ed1e960138710a60d035c1a85d43d0bf0faeb",
"reference": "394ed1e960138710a60d035c1a85d43d0bf0faeb",
"url": "https://api.github.com/repos/scssphp/scssphp/zipball/63d1157457e5554edf00b0c1fabab4c1511d2520",
"reference": "63d1157457e5554edf00b0c1fabab4c1511d2520",
"shasum": ""
},
"require": {
Expand All @@ -694,7 +694,7 @@
"ext-iconv": "Can be used as fallback when ext-mbstring is not available",
"ext-mbstring": "For best performance, mbstring should be installed as it is faster than ext-iconv"
},
"time": "2024-01-13T12:36:40+00:00",
"time": "2024-08-17T21:02:11+00:00",
"bin": [
"bin/pscss"
],
Expand Down Expand Up @@ -738,7 +738,7 @@
],
"support": {
"issues": "https://github.com/scssphp/scssphp/issues",
"source": "https://github.com/scssphp/scssphp/tree/v1.12.1"
"source": "https://github.com/scssphp/scssphp/tree/v1.13.0"
},
"install-path": "../scssphp/scssphp"
},
Expand Down
10 changes: 5 additions & 5 deletions upload/system/storage/vendor/composer/installed.php
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@
'name' => 'opencart/opencart-3',
'pretty_version' => 'dev-main',
'version' => 'dev-main',
'reference' => '02de2c4f0c4931886b61604f44332c3c91d8aa8e',
'reference' => '5930e7357189d9fe45ecea0498fbd7f199902bec',
'type' => 'project',
'install_path' => __DIR__ . '/../../../../../',
'aliases' => array(),
Expand Down Expand Up @@ -58,7 +58,7 @@
'opencart/opencart-3' => array(
'pretty_version' => 'dev-main',
'version' => 'dev-main',
'reference' => '02de2c4f0c4931886b61604f44332c3c91d8aa8e',
'reference' => '5930e7357189d9fe45ecea0498fbd7f199902bec',
'type' => 'project',
'install_path' => __DIR__ . '/../../../../../',
'aliases' => array(),
Expand Down Expand Up @@ -119,9 +119,9 @@
'dev_requirement' => false,
),
'scssphp/scssphp' => array(
'pretty_version' => 'v1.12.1',
'version' => '1.12.1.0',
'reference' => '394ed1e960138710a60d035c1a85d43d0bf0faeb',
'pretty_version' => 'v1.13.0',
'version' => '1.13.0.0',
'reference' => '63d1157457e5554edf00b0c1fabab4c1511d2520',
'type' => 'library',
'install_path' => __DIR__ . '/../scssphp/scssphp',
'aliases' => array(),
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
namespace ScssPhp\ScssPhp\Block;

use ScssPhp\ScssPhp\Block;
use ScssPhp\ScssPhp\Node\Number;
use ScssPhp\ScssPhp\Type;

/**
Expand All @@ -26,7 +27,7 @@ class DirectiveBlock extends Block
public $name;

/**
* @var string|array|null
* @var array|Number|null
*/
public $value;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
namespace ScssPhp\ScssPhp\Block;

use ScssPhp\ScssPhp\Block;
use ScssPhp\ScssPhp\Node\Number;
use ScssPhp\ScssPhp\Type;

/**
Expand All @@ -26,7 +27,7 @@ class EachBlock extends Block
public $vars = [];

/**
* @var array
* @var array|Number
*/
public $list;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
namespace ScssPhp\ScssPhp\Block;

use ScssPhp\ScssPhp\Block;
use ScssPhp\ScssPhp\Node\Number;
use ScssPhp\ScssPhp\Type;

/**
Expand All @@ -21,7 +22,7 @@
class ElseifBlock extends Block
{
/**
* @var array
* @var array|Number
*/
public $cond;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
namespace ScssPhp\ScssPhp\Block;

use ScssPhp\ScssPhp\Block;
use ScssPhp\ScssPhp\Node\Number;
use ScssPhp\ScssPhp\Type;

/**
Expand All @@ -26,12 +27,12 @@ class ForBlock extends Block
public $var;

/**
* @var array
* @var array|Number
*/
public $start;

/**
* @var array
* @var array|Number
*/
public $end;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
namespace ScssPhp\ScssPhp\Block;

use ScssPhp\ScssPhp\Block;
use ScssPhp\ScssPhp\Node\Number;
use ScssPhp\ScssPhp\Type;

/**
Expand All @@ -21,7 +22,7 @@
class IfBlock extends Block
{
/**
* @var array
* @var array|Number
*/
public $cond;

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@
namespace ScssPhp\ScssPhp\Block;

use ScssPhp\ScssPhp\Block;
use ScssPhp\ScssPhp\Node\Number;
use ScssPhp\ScssPhp\Type;

/**
Expand All @@ -21,7 +22,7 @@
class MediaBlock extends Block
{
/**
* @var string|array|null
* @var string|array|Number|null
*/
public $value;

Expand Down
42 changes: 42 additions & 0 deletions upload/system/storage/vendor/scssphp/scssphp/src/Compiler.php
Original file line number Diff line number Diff line change
Expand Up @@ -140,13 +140,28 @@ class Compiler
/** @deprecated */
public static $Infinity = [Type::T_KEYWORD, 'Infinity'];
public static $null = [Type::T_NULL];
/**
* @internal
*/
public static $nullString = [Type::T_STRING, '', []];
/**
* @internal
*/
public static $defaultValue = [Type::T_KEYWORD, ''];
/**
* @internal
*/
public static $selfSelector = [Type::T_SELF];
public static $emptyList = [Type::T_LIST, '', []];
public static $emptyMap = [Type::T_MAP, [], []];
public static $emptyString = [Type::T_STRING, '"', []];
/**
* @internal
*/
public static $with = [Type::T_KEYWORD, 'with'];
/**
* @internal
*/
public static $without = [Type::T_KEYWORD, 'without'];
private static $emptyArgumentList = [Type::T_LIST, '', [], []];

Expand Down Expand Up @@ -1656,6 +1671,7 @@ protected function compileWith($withCondition)
$parser = $this->parserFactory(__METHOD__);

if ($parser->parseValue($buffer, $reParsedWith)) {
\assert(\is_array($reParsedWith));
$withCondition = $reParsedWith;
}
}
Expand Down Expand Up @@ -5702,9 +5718,35 @@ public function registerFunction($name, $callback, $argumentDeclaration = null)
@trigger_error('Omitting the argument declaration when registering custom function is deprecated and won\'t be supported in ScssPhp 2.0 anymore.', E_USER_DEPRECATED);
}

if ($this->reflectCallable($callback)->getNumberOfRequiredParameters() > 1) {
@trigger_error('The second argument passed to the callback of custom functions is deprecated and won\'t be supported in ScssPhp 2.0 anymore. Register a callback accepting only 1 parameter instead.', E_USER_DEPRECATED);
}

$this->userFunctions[$this->normalizeName($name)] = [$callback, $argumentDeclaration];
}

/**
* @return \ReflectionFunctionAbstract
*/
private function reflectCallable(callable $c)
{
if (\is_object($c) && !$c instanceof \Closure) {
$c = [$c, '__invoke'];
}

if (\is_string($c) && false !== strpos($c, '::')) {
$c = explode('::', $c, 2);
}

if (\is_array($c)) {
return new \ReflectionMethod($c[0], $c[1]);
}

\assert(\is_string($c) || $c instanceof \Closure);

return new \ReflectionFunction($c);
}

/**
* Unregister function
*
Expand Down
Loading

0 comments on commit 329854e

Please sign in to comment.