mirror of
https://github.com/moodle/moodle.git
synced 2025-08-10 03:16:42 +02:00
MDL-61529 core: update lib scssphp to version 0.7.5
This commit is contained in:
parent
b63a3b04b1
commit
c8842113a7
28 changed files with 834 additions and 564 deletions
|
@ -2,7 +2,7 @@
|
|||
/**
|
||||
* SCSSPHP
|
||||
*
|
||||
* @copyright 2012-2017 Leaf Corcoran
|
||||
* @copyright 2012-2018 Leaf Corcoran
|
||||
*
|
||||
* @license http://opensource.org/licenses/MIT MIT
|
||||
*
|
||||
|
@ -31,7 +31,7 @@ class Number extends Node implements \ArrayAccess
|
|||
/**
|
||||
* @var integer
|
||||
*/
|
||||
static public $precision = 5;
|
||||
static public $precision = 10;
|
||||
|
||||
/**
|
||||
* @see http://www.w3.org/TR/2012/WD-css3-values-20120308/
|
||||
|
@ -291,8 +291,9 @@ class Number extends Node implements \ArrayAccess
|
|||
|
||||
reset($units);
|
||||
$unit = key($units);
|
||||
$dimension = number_format($dimension, static::$precision, '.', '');
|
||||
|
||||
return (string) $dimension . $unit;
|
||||
return (static::$precision ? rtrim(rtrim($dimension, '0'), '.') : $dimension) . $unit;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue