mirror of
https://github.com/gosticks/wordpress-develop.git
synced 2026-10-06 15:47:05 +00:00
Blocks: Add context fields to WP_Block_Type
New block context related fields were added as part of https://github.com/WordPress/gutenberg/pull/22686. This changest backports them to WP_Block_Type class. Props aduth, spacedmonkey, mcsf, epiqueras. Fixes #47656. git-svn-id: https://develop.svn.wordpress.org/trunk@48117 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
@@ -74,9 +74,9 @@ class WP_Block_Type {
|
||||
|
||||
/**
|
||||
* @since 5.5.0
|
||||
* @var array
|
||||
* @var array|null
|
||||
*/
|
||||
public $supports = array();
|
||||
public $supports = null;
|
||||
|
||||
/**
|
||||
* @since 5.5.0
|
||||
@@ -100,6 +100,22 @@ class WP_Block_Type {
|
||||
*/
|
||||
public $attributes = null;
|
||||
|
||||
/**
|
||||
* Context values inherited by blocks of this type.
|
||||
*
|
||||
* @since 5.5.0
|
||||
* @var array
|
||||
*/
|
||||
public $uses_context = array();
|
||||
|
||||
/**
|
||||
* Context provided by blocks of this type.
|
||||
*
|
||||
* @since 5.5.0
|
||||
* @var array|null
|
||||
*/
|
||||
public $provides_context = null;
|
||||
|
||||
/**
|
||||
* Block type editor script handle.
|
||||
*
|
||||
|
||||
Reference in New Issue
Block a user