Docs: Correct @since tags for some block parser properties and methods.

This affects:
* `WP_Block_Parser::$empty_attrs`
* `WP_Block_Parser::next_token()`
* `WP_Block_Parser::freeform()`
* `WP_Block_Parser_Block::$innerContent`

The `@since` tags referred to early Gutenberg versions instead of WordPress core. These properties and methods were introduced in WordPress 5.0, so `5.0.0` is the correct version.

Some of the other `@since` tags are removed, as they are related to early Gutenberg development before it was merged into WordPress core, and are not relevant for core.

Follow-up to [43751], [43884], [43955] for the 5.0 branch, [44116], [44261], [44281] for trunk.

Props Chouby.
See #56581.

git-svn-id: https://develop.svn.wordpress.org/trunk@54193 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Sergey Biryukov 2022-09-17 16:47:17 +00:00
parent 7c2f6dd6cb
commit a01206e2fc

View File

@ -62,7 +62,7 @@ class WP_Block_Parser_Block {
* 'innerContent' => array( 'Before', null, 'Inner', null, 'After' ),
* )
*
* @since 4.2.0
* @since 5.0.0
* @var array
*/
public $innerContent;
@ -164,10 +164,9 @@ class WP_Block_Parser_Frame {
/**
* Class WP_Block_Parser
*
* Parses a document and constructs a list of parsed block objects
* Parses a document and constructs a list of parsed blocks.
*
* @since 5.0.0
* @since 4.0.0 returns arrays not objects, all attributes are arrays
*/
class WP_Block_Parser {
/**
@ -207,7 +206,7 @@ class WP_Block_Parser {
/**
* Empty associative array, here due to PHP quirks
*
* @since 4.4.0
* @since 5.0.0
* @var array empty associative array
*/
public $empty_attrs;
@ -395,7 +394,6 @@ class WP_Block_Parser {
*
* @internal
* @since 5.0.0
* @since 4.6.1 fixed a bug in attribute parsing which caused catastrophic backtracking on invalid block comments
* @return array
*/
function next_token() {
@ -468,7 +466,7 @@ class WP_Block_Parser {
* Returns a new block object for freeform HTML
*
* @internal
* @since 3.9.0
* @since 5.0.0
*
* @param string $innerHTML HTML content of block.
* @return WP_Block_Parser_Block freeform block object.