Skip to content
Closed
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
Changes from lib/class-wp-theme-json-gutenberg.php
  • Loading branch information
noisysocks committed Nov 22, 2021
commit da3a9096c0dbf122ee0a8606d25e62d6c91bef08
24 changes: 13 additions & 11 deletions src/wp-includes/class-wp-theme-json.php
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ class WP_Theme_JSON {
* @var string[]
*/
const VALID_ORIGINS = array(
'core',
'default',
'theme',
'user',
);
Expand Down Expand Up @@ -220,15 +220,17 @@ class WP_Theme_JSON {
'width' => null,
),
'color' => array(
'background' => null,
'custom' => null,
'customDuotone' => null,
'customGradient' => null,
'duotone' => null,
'gradients' => null,
'link' => null,
'palette' => null,
'text' => null,
'background' => null,
'custom' => null,
'customDuotone' => null,
'customGradient' => null,
'defaultGradients' => null,
'defaultPalette' => null,
'duotone' => null,
'gradients' => null,
'link' => null,
'palette' => null,
'text' => null,
),
'custom' => null,
'layout' => array(
Expand Down Expand Up @@ -324,7 +326,7 @@ class WP_Theme_JSON {
*
* @param array $theme_json A structure that follows the theme.json schema.
* @param string $origin Optional. What source of data this object represents.
* One of 'core', 'theme', or 'user'. Default 'theme'.
* One of 'default', 'theme', or 'user'. Default 'theme'.
*/
public function __construct( $theme_json = array(), $origin = 'theme' ) {
if ( ! in_array( $origin, self::VALID_ORIGINS, true ) ) {
Expand Down