• Skip to primary navigation
  • Skip to main content
  • Skip to primary sidebar
  • Skip to footer
WordPress a2z

WordPress a2z

WordPress Dynamic API Reference

  • Home
  • Plugins
  • Themes
  • Shortcodes
  • APIs
  • Classes
  • Files
  • Hooks
  • Sitemap
  • Blog
Home / APIs / twentytwenty_block_editor_styles() – Enqueue supplemental block editor styles.

You appear to be a bot. Output may be restricted

Description

Enqueue supplemental block editor styles.

Usage

twentytwenty_block_editor_styles();

Parameters

Returns

void

Source

File name: twentytwenty/functions.php
Lines:

1 to 15 of 15
function twentytwenty_block_editor_styles() {

  // Enqueue the editor styles.
  wp_enqueue_style( 'twentytwenty-block-editor-styles', get_theme_file_uri( '/assets/css/editor-style-block.css' ), array(), wp_get_theme()->get( 'Version' ), 'all' );
  wp_style_add_data( 'twentytwenty-block-editor-styles', 'rtl', 'replace' );

  // Add inline style from the Customizer.
  wp_add_inline_style( 'twentytwenty-block-editor-styles', twentytwenty_get_customizer_css( 'block-editor' ) );

  // Add inline style for non-latin fonts.
  wp_add_inline_style( 'twentytwenty-block-editor-styles', TwentyTwenty_Non_Latin_Languages::get_non_latin_css( 'block-editor' ) );

  // Enqueue the editor script.
  wp_enqueue_script( 'twentytwenty-block-editor-script', get_theme_file_uri( '/assets/js/editor-script-block.js' ), array( 'wp-blocks', 'wp-dom' ), wp_get_theme()->get( 'Version' ), true );
}
 

 View on GitHub View on Trac

Published: 25th November 2019 | Last updated: 15th May 2020

Primary Sidebar

Information

Function name: twentytwenty_block_editor_styles
Plugin ref: Twenty Twenty
Version: 1.6
Sourcefile: functions.php
File ref: functions.php
Deprecated?: No
API Letters: B,E,S,T

Footer

WordPress a2z
WordPress a2z
WordPress Dynamic API Reference
WordPress 5.6.2. PHP: 7.3.27
WordPress a2z
WordPress core a2z
Genesis Theme Framework a2z
Jetpack a2z
WordPress develop tests
Easy Digital Downloads a2z
WooCommerce a2z
Yoast SEO a2z
WordPress Blocks

Site:  wp-a2z.org
© Copyright WordPress a2z 2014-2021. All rights reserved.


Website designed and developed by Herb Miller
Proudly powered by WordPress and oik plugins

  • Home
  • Blog
  • Sitemap
  • Sites