Enqueues View Transitions CSS for the admin.
Source
function wp_enqueue_view_transitions_admin_css(): void {
wp_enqueue_style( 'wp-view-transitions-admin' );
}
Changelog
| Version | Description |
|---|---|
| 7.0.0 | Introduced. |
Enqueues View Transitions CSS for the admin.
function wp_enqueue_view_transitions_admin_css(): void {
wp_enqueue_style( 'wp-view-transitions-admin' );
}
| Version | Description |
|---|---|
| 7.0.0 | Introduced. |
You must log in before being able to contribute a note or feedback.
If you want to disable the View Transitions CSS in wp-admin (for example,if it conflicts with a custom admin theme or a plugin), you can dequeue and deregister the style on ‘admin_enqueue_scripts’ with a late priority:
add_action( ‘admin_enqueue_scripts’, function () {
wp_dequeue_style( ‘wp-view-transitions-admin’ );
wp_deregister_style( ‘wp-view-transitions-admin’ );
}, 999 );
Note that this function itself doesn’t accept any filter to bypass it; it unconditionally enqueues the style whenever it’s called, so removing the style afterwards is currently the most reliable way to opt out.