Docs: Use correct format for multi-line comments in `the_block_editor_meta_boxes()`.
Follow-up to [44131], [44260]. See #54729. Built from https://develop.svn.wordpress.org/trunk@53056 git-svn-id: http://core.svn.wordpress.org/trunk@52645 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
c9a7acde6a
commit
8ddb40d7a0
|
@ -1069,7 +1069,7 @@ function update_meta( $meta_id, $meta_key, $meta_value ) {
|
|||
//
|
||||
|
||||
/**
|
||||
* Replace hrefs of attachment anchors with up-to-date permalinks.
|
||||
* Replaces hrefs of attachment anchors with up-to-date permalinks.
|
||||
*
|
||||
* @since 2.3.0
|
||||
* @access private
|
||||
|
@ -1361,6 +1361,7 @@ function postbox_classes( $box_id, $screen_id ) {
|
|||
* @param string[] $classes An array of postbox classes.
|
||||
*/
|
||||
$classes = apply_filters( "postbox_classes_{$screen_id}_{$box_id}", $classes );
|
||||
|
||||
return implode( ' ', $classes );
|
||||
}
|
||||
|
||||
|
@ -2336,12 +2337,12 @@ function the_block_editor_meta_boxes() {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
/*
|
||||
* Sadly we probably cannot add this data directly into editor settings.
|
||||
*
|
||||
* Some meta boxes need admin_head to fire for meta box registry.
|
||||
* admin_head fires after admin_enqueue_scripts, which is where we create our
|
||||
* editor instance.
|
||||
* Some meta boxes need `admin_head` to fire for meta box registry.
|
||||
* `admin_head` fires after `admin_enqueue_scripts`, which is where we create
|
||||
* our editor instance.
|
||||
*/
|
||||
$script = 'window._wpLoadBlockEditor.then( function() {
|
||||
wp.data.dispatch( \'core/edit-post\' ).setAvailableMetaBoxesPerLocation( ' . wp_json_encode( $meta_boxes_per_location ) . ' );
|
||||
|
@ -2349,19 +2350,21 @@ function the_block_editor_meta_boxes() {
|
|||
|
||||
wp_add_inline_script( 'wp-edit-post', $script );
|
||||
|
||||
/**
|
||||
* When `wp-edit-post` is output in the `<head>`, the inline script needs to be manually printed. Otherwise,
|
||||
* meta boxes will not display because inline scripts for `wp-edit-post` will not be printed again after this point.
|
||||
/*
|
||||
* When `wp-edit-post` is output in the `<head>`, the inline script needs to be manually printed.
|
||||
* Otherwise, meta boxes will not display because inline scripts for `wp-edit-post`
|
||||
* will not be printed again after this point.
|
||||
*/
|
||||
if ( wp_script_is( 'wp-edit-post', 'done' ) ) {
|
||||
printf( "<script type='text/javascript'>\n%s\n</script>\n", trim( $script ) );
|
||||
}
|
||||
|
||||
/**
|
||||
* If the 'postcustom' meta box is enabled, then we need to perform some
|
||||
* extra initialization on it.
|
||||
/*
|
||||
* If the 'postcustom' meta box is enabled, then we need to perform
|
||||
* some extra initialization on it.
|
||||
*/
|
||||
$enable_custom_fields = (bool) get_user_meta( get_current_user_id(), 'enable_custom_fields', true );
|
||||
|
||||
if ( $enable_custom_fields ) {
|
||||
$script = "( function( $ ) {
|
||||
if ( $('#postcustom').length ) {
|
||||
|
@ -2405,8 +2408,9 @@ function the_block_editor_meta_box_post_form_hidden_fields( $post ) {
|
|||
wp_nonce_field( $nonce_action );
|
||||
|
||||
/*
|
||||
* Some meta boxes hook into these actions to add hidden input fields in the classic post form. For backwards
|
||||
* compatibility, we can capture the output from these actions, and extract the hidden input fields.
|
||||
* Some meta boxes hook into these actions to add hidden input fields in the classic post form.
|
||||
* For backward compatibility, we can capture the output from these actions,
|
||||
* and extract the hidden input fields.
|
||||
*/
|
||||
ob_start();
|
||||
/** This filter is documented in wp-admin/edit-form-advanced.php */
|
||||
|
|
|
@ -16,7 +16,7 @@
|
|||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '6.0-alpha-53055';
|
||||
$wp_version = '6.0-alpha-53056';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
|
Loading…
Reference in New Issue