Block Editor: Expose value of user_can_richedit().

In order for the Block Editor to know whether to allow visual editing, it needs to know the value of `user_can_richedit()`.

Props youknowriad.
Fixes #45375.

Built from https://develop.svn.wordpress.org/branches/5.0@43916


git-svn-id: http://core.svn.wordpress.org/branches/5.0@43748 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
danielbachhuber 2018-11-21 14:11:48 +00:00
parent f979e79d54
commit c06c2fe2d6
2 changed files with 2 additions and 1 deletions

View File

@ -273,6 +273,7 @@ $editor_settings = array(
'allowedMimeTypes' => get_allowed_mime_types(), 'allowedMimeTypes' => get_allowed_mime_types(),
'styles' => $styles, 'styles' => $styles,
'imageSizes' => $available_image_sizes, 'imageSizes' => $available_image_sizes,
'richEditingEnabled' => user_can_richedit(),
'postLock' => $lock_details, 'postLock' => $lock_details,
'postLockUtils' => array( 'postLockUtils' => array(
'nonce' => wp_create_nonce( 'lock-post_' . $post->ID ), 'nonce' => wp_create_nonce( 'lock-post_' . $post->ID ),

View File

@ -4,7 +4,7 @@
* *
* @global string $wp_version * @global string $wp_version
*/ */
$wp_version = '5.0-beta5-43915'; $wp_version = '5.0-beta5-43916';
/** /**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema. * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.