Merge pull request #30093 from woocommerce/fix/woocommerce-css-editor

Register woocommerce.css so it can be enqueued in the editor
This commit is contained in:
Vedanshu Jain 2021-06-15 11:37:27 +05:30 committed by GitHub
commit f3c9be0492
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 5 additions and 0 deletions

View File

@ -54,6 +54,11 @@ if ( ! class_exists( 'WC_Admin_Assets', false ) ) :
wp_style_add_data( 'woocommerce_admin_marketplace_styles', 'rtl', 'replace' );
wp_style_add_data( 'woocommerce_admin_privacy_styles', 'rtl', 'replace' );
if ( $screen->is_block_editor() ) {
wp_register_style( 'woocommerce-general', WC()->plugin_url() . '/assets/css/woocommerce.css', array(), $version );
wp_style_add_data( 'woocommerce-general', 'rtl', 'replace' );
}
// Sitewide menu CSS.
wp_enqueue_style( 'woocommerce_admin_menu_styles' );