Automattic\WooCommerce\Vendor\Sabberworm\CSS\Value
Size::render
Метод класса: Size{}
Хуков нет.
Возвращает
string.
Использование
$Size = new Size(); $Size->render( $oOutputFormat );
- $oOutputFormat(OutputFormat|null) (обязательный)
- .
Код Size::render() Size::render WC 11.2.1
public function render($oOutputFormat)
{
$l = localeconv();
$sPoint = preg_quote($l['decimal_point'], '/');
$sSize = preg_match("/[\d\.]+e[+-]?\d+/i", (string)$this->fSize)
? preg_replace("/$sPoint?0+$/", "", sprintf("%f", $this->fSize)) : (string)$this->fSize;
return preg_replace(["/$sPoint/", "/^(-?)0\./"], ['.', '$1.'], $sSize)
. ($this->sUnit === null ? '' : $this->sUnit);
}