File: wp-includes/class-wp-theme-json.php
-
Merges two sets of spacing size presets.
-
Generates a set of spacing sizes by starting with a medium size and applying an operator with an increment value to generate the rest of the sizes outward from the medium size. The medium slug is ’50’ with the rest of the slugs being 10 apart. The generated names use t-shirt sizing.
-
Generates a selector for a block style variation.
-
Collects valid block style variations keyed by block type.
-
Remove insecure element styles within a variation or block.
-
Remove insecure styles from inner blocks and their elements.
-
Scopes the selectors for a given style node.
-
Unwraps shared block style variations.
-
Return the input schema at the root and per origin.
-
Replaces CSS variables with their values in place.
-
Resolves the values of CSS variables in the given styles.
-
This is used to convert the internal representation of variables to the CSS representation.
-
Given a tree, converts the internal representation of variables to the CSS representation.
-
Returns the selectors metadata for a block.
-
Generates all the element selectors for a block.
-
Generates style declarations for a node’s features e.g., color, border, typography etc. that have custom selectors in their related block’s metadata.
-
Prepends a sub-selector to an existing one.
-
Removes indirect properties from the given input node and sets in the given output node.
-
Returns a filtered declarations array if there is a separator block with only a background style defined in theme.json by adding a color attribute to reflect the changes in the front.
-
Processes the CSS, to apply nesting.
-
Returns the global styles custom CSS.
-
Sets the spacingSizes array based on the spacingScale values from theme.json.
-
Gets the CSS rules for a particular block from theme.json.
-
Outputs the CSS for layout rules on the root.
-
Filters the list of style nodes with metadata.
-
A public helper to get the block nodes from a theme.json file.
-
An internal method to get the block nodes from a theme.json file.
-
Gets the CSS layout rules for a particular block from theme.json layout definitions.
-
Returns a class name by an element name.
-
Returns the current theme’s wanted patterns(slugs) to be registered from Pattern Directory.