Automattic\WooCommerce\Internal\EmailEditor

WooContentProcessor::inline_cssprivateWC 1.0

Inline the CSS from the email theme and user email settings.

Method of the class: WooContentProcessor{}

No Hooks.

Returns

String.

Usage

// private - for code of main (parent) class only
$result = $this->inline_css( $woo_content ): string;
$woo_content(string) (required)
WooCommerce content.

WooContentProcessor::inline_css() code WC 10.3.6

private function inline_css( string $woo_content ): string {
	if ( empty( $woo_content ) ) {
		return '';
	}
	$css = $this->theme_controller->get_stylesheet_for_rendering();
	return $this->css_inliner->from_html( $woo_content )->inline_css( $css )->render();
}