Converts each styles section into a list of rulesets to be appended to the stylesheet.
Description
These rulesets contain all the css variables (custom variables and preset variables).
See glossary at https://developer.mozilla.org/en-US/docs/Web/CSS/Syntax
For each section this creates a new ruleset such as:
block-selector {
--wp--preset--category--slug: value;
--wp--custom--variable: value;
}
Parameters
$nodes
arrayrequired- Nodes with settings.
$origins
string[]required- List of origins to process.
Source
$stylesheet .= $this->process_blocks_custom_css( $custom_block_css, $selector );
}
}
}
return $stylesheet;
}
/**
* Returns the page templates of the active theme.
*
* @since 5.9.0
*
* @return array
*/
public function get_custom_templates() {
$custom_templates = array();
if ( ! isset( $this->theme_json['customTemplates'] ) || ! is_array( $this->theme_json['customTemplates'] ) ) {
return $custom_templates;
}
User Contributed Notes
You must log in before being able to contribute a note or feedback.