Changeset 44265
- Timestamp:
- 12/17/2018 05:02:02 PM (6 years ago)
- Location:
- trunk
- Files:
-
- 2 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk
- Property svn:mergeinfo changed
/branches/5.0 merged: 43914
- Property svn:mergeinfo changed
-
trunk/src/wp-includes/script-loader.php
r44262 r44265 517 517 * Adds inline scripts required for the TinyMCE in the block editor. 518 518 * 519 * These TinyMCE init settings are used to extend and override the default settings 520 * from `_WP_Editors::default_settings()` for the Classic block. 521 * 519 522 * @since 5.0.0 520 523 * … … 523 526 function wp_tinymce_inline_scripts() { 524 527 global $wp_scripts; 528 529 /** This filter is documented in wp-includes/class-wp-editor.php */ 530 $editor_settings = apply_filters( 'wp_editor_settings', array( 'tinymce' => true ), 'classic-block' ); 525 531 526 532 $tinymce_plugins = array( … … 549 555 $tinymce_plugins = array_unique( $tinymce_plugins ); 550 556 557 $disable_captions = false; 558 // Runs after `tiny_mce_plugins` but before `mce_buttons`. 559 /** This filter is documented in wp-admin/includes/media.php */ 560 if ( apply_filters( 'disable_captions', '' ) ) { 561 $disable_captions = true; 562 } 563 551 564 $toolbar1 = array( 552 565 'formatselect', … … 602 615 'classic_block_editor' => true, 603 616 ); 617 618 if ( $disable_captions ) { 619 $tinymce_settings['wpeditimage_disable_captions'] = true; 620 } 621 622 if ( ! empty( $editor_settings['tinymce'] ) && is_array( $editor_settings['tinymce'] ) ) { 623 array_merge( $tinymce_settings, $editor_settings['tinymce'] ); 624 } 604 625 605 626 /* This filter is documented in wp-includes/class-wp-editor.php */
Note: See TracChangeset
for help on using the changeset viewer.