Automattic\WooCommerce\EmailEditor\Engine\Renderer\ContentRenderer

Process_Manager::preprocess │ public │ WC 1.0

Method to preprocess blocks

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

Хуков нет.

Возвращает

array.

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

$Process_Manager = new Process_Manager();
$Process_Manager->preprocess( $parsed_blocks, $layout, $styles, ?Rendering_Context $rendering_context ): array;
$parsed_blocks(массив) (обязательный)
Parsed blocks.
$layout(array{contentSize: string, wideSize?: string, allowEditing?: bool, allowCustomContentAndWideSize?: bool}) (обязательный)
Layout.
$styles(массив) (обязательный)
.
?Rendering_Context $rendering_context
.
По умолчанию: null

Код Process_Manager::preprocess() WC 11.2.2

public function preprocess( array $parsed_blocks, array $layout, array $styles, ?Rendering_Context $rendering_context = null ): array {
	foreach ( $this->preprocessors as $preprocessor ) {
		$parsed_blocks = $preprocessor instanceof Context_Aware_Preprocessor
			? $preprocessor->preprocess_with_context( $parsed_blocks, $layout, $styles, $rendering_context )
			: $preprocessor->preprocess( $parsed_blocks, $layout, $styles );
	}
	return $parsed_blocks;
}