Automattic\WooCommerce\Vendor\Pelago\Emogrifier\HtmlProcessor

CssToAttributeConverter::mapBorderPropertyprivateWC 1.0

Метод класса: CssToAttributeConverter{}

Хуков нет.

Возвращает

null. Ничего (null).

Использование

// private - только в коде основоного (родительского) класса
$result = $this->mapBorderProperty( $node, $value ): void;
$node(DOMElement) (обязательный)
node to apply styles to.
$value(строка) (обязательный)
the value of the style rule to map.

Код CssToAttributeConverter::mapBorderProperty() WC 11.0.1

private function mapBorderProperty(\DOMElement $node, string $value): void
{
    if (!$this->isTableOrImageNode($node)) {
        return;
    }

    if ($value === 'none' || $value === '0') {
        $node->setAttribute('border', '0');
    }
}