Make WordPress Core

Ticket #57903: 57903.diff

File 57903.diff, 706 bytes (added by david.binda, 18 months ago)
  • src/wp-includes/blocks.php

     
    260260        if ( $has_style_file ) {
    261261                wp_style_add_data( $style_handle, 'path', $style_path_norm );
    262262
    263                 $rtl_file = str_replace( "{$suffix}.css", "-rtl{$suffix}.css", $style_path_norm );
     263                if ( $is_core_block ) {
     264                        $rtl_file = str_replace( "{$suffix}.css", "-rtl{$suffix}.css", $style_path_norm );
     265                } else {
     266                        $rtl_file = str_replace( ".css", "-rtl.css", $style_path_norm );
     267                }
    264268
    265269                if ( is_rtl() && file_exists( $rtl_file ) ) {
    266270                        wp_style_add_data( $style_handle, 'rtl', 'replace' );