Changeset 43800
- Timestamp:
- 10/23/2018 01:25:03 AM (6 years ago)
- Location:
- branches/5.0/src/wp-content/themes/twentyseventeen
- Files:
-
- 2 added
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
branches/5.0/src/wp-content/themes/twentyseventeen/functions.php
r41756 r43800 106 106 */ 107 107 add_editor_style( array( 'assets/css/editor-style.css', twentyseventeen_fonts_url() ) ); 108 109 // Load regular editor styles into the new block-based editor. 110 add_theme_support( 'editor-styles' ); 111 112 // Load default block styles. 113 add_theme_support( 'wp-block-styles' ); 108 114 109 115 // Define and register starter content to showcase the theme on new sites. … … 416 422 wp_enqueue_style( 'twentyseventeen-style', get_stylesheet_uri() ); 417 423 424 // Theme block stylesheet. 425 wp_enqueue_style( 'twentyseventeen-block-style', get_theme_file_uri( '/assets/css/blocks.css' ), array( 'twentyseventeen-style' ), '1.0' ); 426 418 427 // Load the dark colorscheme. 419 428 if ( 'dark' === get_theme_mod( 'colorscheme', 'light' ) || is_customize_preview() ) { … … 461 470 462 471 /** 472 * Enqueue editor styles for Gutenberg 473 * 474 * @since Twenty Seventeen 1.8 475 */ 476 function twentyseventeen_block_editor_styles() { 477 // Block styles. 478 wp_enqueue_style( 'twentyseventeen-block-editor-style', get_theme_file_uri( '/assets/css/editor-blocks.css' ) ); 479 // Add custom fonts. 480 wp_enqueue_style( 'twentyseventeen-fonts', twentyseventeen_fonts_url(), array(), null ); 481 } 482 add_action( 'enqueue_block_editor_assets', 'twentyseventeen_block_editor_styles' ); 483 484 /** 463 485 * Add custom image sizes attribute to enhance responsive image functionality 464 486 * for content images.
Note: See TracChangeset
for help on using the changeset viewer.