File tree Expand file tree Collapse file tree 1 file changed +1
-1
lines changed
plugins/view-transitions/includes Expand file tree Collapse file tree 1 file changed +1
-1
lines changed Original file line number Diff line number Diff line change @@ -317,7 +317,7 @@ function plvt_load_view_transitions(): void {
317
317
$ default_animation_args = isset ( $ theme_support ['default-animation-args ' ] ) ? (array ) $ theme_support ['default-animation-args ' ] : array ();
318
318
$ default_animation_stylesheet = $ animation_registry ->get_animation_stylesheet ( $ theme_support ['default-animation ' ], $ default_animation_args );
319
319
$ default_animation_stylesheet = plvt_inject_animation_duration ( $ default_animation_stylesheet , absint ( $ theme_support ['default-animation-duration ' ] ) );
320
- wp_add_inline_style ( 'plvt-view-transitions ' , $ default_animation_stylesheet );
320
+ wp_add_inline_style ( 'plvt-view-transitions ' , ' @media (prefers-reduced-motion: no-preference) { ' . $ default_animation_stylesheet . ' } ' );
321
321
322
322
/*
323
323
* No point in loading the script if no specific view transition names are configured.
You can’t perform that action at this time.
0 commit comments