[wp-trac] [WordPress Trac] #53562: Widgets Editor in Customizer doesn't load with E2E tests + 0ms Animations

WordPress Trac noreply at wordpress.org
Thu Jul 15 06:34:23 UTC 2021


#53562: Widgets Editor in Customizer doesn't load with E2E tests + 0ms Animations
--------------------------+----------------------------------------------
 Reporter:  mikeschroder  |       Owner:  mikeschroder
     Type:  defect (bug)  |      Status:  reopened
 Priority:  normal        |   Milestone:  5.8.1
Component:  Editor        |     Version:  trunk
 Severity:  normal        |  Resolution:
 Keywords:  needs-patch   |     Focuses:  javascript, css, administration
--------------------------+----------------------------------------------

Comment (by kevin940726):

 I believe we can just add a condition in places like
 [[https://github.com/WordPress/wordpress-
 develop/blob/master/src/js/_enqueues/wp/customize/controls.js#L1268|L1268]]
 with something like `isReducedMotion`.


 {{{
 // Return if CSS transitions are not supported.
 if ( ! normalizedTransitionendEventName || isReducedMotion ) {
         if ( completeCallback ) {
                 completeCallback();
         }
         return;
 }
 }}}

 We can obtain `isReducedMotion` by running `window.matchMedia('(prefers-
 reduced-motion: reduce)').matches`.

 As for browsers that don't support `transitionend`, we no longer support
 those legacy browsers either, so I don't think we need to handle that.

 The focus loss is still a valid problem though, and I agree we have to fix
 that in the Customizer somehow before we fix this.

-- 
Ticket URL: <https://core.trac.wordpress.org/ticket/53562#comment:14>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform


More information about the wp-trac mailing list