Changeset 49982 for trunk/src/wp-includes/blocks.php
- Timestamp:
- 01/19/2021 11:48:59 AM (4 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/src/wp-includes/blocks.php
r49981 r49982 170 170 $style_handle = generate_block_asset_handle( $metadata['name'], $field_name ); 171 171 $block_dir = dirname( $metadata['file'] ); 172 $style_file = realpath( "$block_dir/$style_path" ); 172 173 $result = wp_register_style( 173 174 $style_handle, 174 175 plugins_url( $style_path, $metadata['file'] ), 175 176 array(), 176 filemtime( realpath( "$block_dir/$style_path" ) ) 177 ); 177 filemtime( $style_file ) 178 ); 179 if ( file_exists( str_replace( '.css', '-rtl.css', $style_file ) ) ) { 180 wp_style_add_data( $style_handle, 'rtl', 'replace' ); 181 } 182 178 183 return $result ? $style_handle : false; 179 184 }
Note: See TracChangeset
for help on using the changeset viewer.