PluginProbe
Gutenberg / trunk
Gutenberg vtrunk
24.1.0 24.0.0 23.9.1 23.9.0 23.8.0 23.7.2 23.7.1 23.7.0 23.6.1 23.6.2 23.6.0 23.5.3 23.5.2 23.5.1 23.5.0 23.4.0 23.3.2 23.3.1 23.3.0 23.2.0 23.2.1 23.2.2 23.1.1 23.1.0 23.0.1 All 404 releases
← All changes | build/pages/dashboard/page-wp-admin.php +11 -3 23.8.0 → trunk View file →
@@ -145,10 +145,14 @@
145 145
146 146 // Get all registered routes
147 147 $routes = gutenberg_get_dashboard_wp_admin_routes();
148 148
149 - // Get boot module asset file for dependencies
149 + // Get boot module asset file for dependencies. Plugins that build their own
150 + // boot module use it; everyone else falls back to the copy bundled with Core.
150 151 $asset_file = __DIR__ . '/../../modules/boot/index.min.asset.php';
152 + if ( ! file_exists( $asset_file ) ) {
153 + $asset_file = ABSPATH . WPINC . '/js/dist/script-modules/boot/index.min.asset.php';
154 + }
151 155 if ( file_exists( $asset_file ) ) {
152 156 $asset = require $asset_file;
153 157
154 158 // This script serves two purposes:
@@ -282,9 +286,9 @@
282 286 padding-bottom: 0;
283 287 }
284 288
285 289 /* Hide legacy admin elements */
286 - body.js #wpbody-content > div:not(.boot-layout-container):not(#screen-meta) {
290 + body.js #wpbody-content > div:not(#dashboard-wp-admin-app):not(#screen-meta) {
287 291 display: none;
288 292 }
289 293 body.js #wpfooter {
290 294 display: none;
@@ -323,8 +327,13 @@
323 327 array( 'type' => 'error' )
324 328 );
325 329 ?>
326 330 </div>
331 + <?php
332 + // Core's pre-CSS Modules Boot layout uses this class for viewport sizing.
333 + // Remove it when the minimum supported WordPress version includes the Boot
334 + // changes from Gutenberg #81756.
335 + ?>
327 336 <div id="dashboard-wp-admin-app" class="boot-layout-container"></div>
328 337 <?php
329 338 }
330 339
@@ -329,5 +338,4 @@
329 338 }
330 339
331 340 // Hook the enqueue function to admin_enqueue_scripts
332 341 add_action( 'admin_enqueue_scripts', 'gutenberg_dashboard_wp_admin_enqueue_scripts' );
333 -