[wp-trac] [WordPress Trac] #36903: Customizer menus search "clear results" should be a button

WordPress Trac noreply at wordpress.org
Sun May 22 15:35:42 UTC 2016


#36903: Customizer menus search "clear results" should be a button
-------------------------------------+-------------------------------------
 Reporter:  afercia                  |       Owner:  afercia
     Type:  defect (bug)             |      Status:  assigned
 Priority:  normal                   |   Milestone:  4.6
Component:  Customize                |     Version:
 Severity:  normal                   |  Resolution:
 Keywords:  has-patch has-           |     Focuses:  ui, accessibility,
  screenshots                        |  javascript
-------------------------------------+-------------------------------------
Changes (by afercia):

 * keywords:   => has-patch has-screenshots
 * owner:   => afercia
 * status:  new => assigned
 * milestone:  Awaiting Review => 4.6


Comment:

 In the proposed patch:
 - make the "Clear results" control a `button` element for better
 accessibility
 - JS clean-up: no need for a `keydown` event, `preventDefault()` and
 toggling `tabindex`
 - removed `event.target.value = ''` since the event target is the button
 - removed `self.search( event )` since the passed event was not the
 intended input field event, now replaced just triggering a `keyup` event
 on the search field
 - CSS tweaking
 - help IE8 redraw the pseudo element

 Tested in latest Chrome/Firefox and IE 8, the new button works nicely on
 click and when pressing Enter or Spacebar.

 Screenshot after:

 [[Image(https://cldup.com/ZhcuaI976G.png)]]

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


More information about the wp-trac mailing list