[wp-trac] [WordPress Trac] #31661: Quicktags: Can't add them using just a keyboard in IE

WordPress Trac noreply at wordpress.org
Tue Jul 7 03:02:03 UTC 2015

#31661: Quicktags: Can't add them using just a keyboard in IE
 Reporter:  Cheffheid             |       Owner:
     Type:  defect (bug)          |      Status:  new
 Priority:  normal                |   Milestone:  4.3
Component:  Editor                |     Version:  4.1
 Severity:  normal                |  Resolution:
 Keywords:  has-patch dev-        |     Focuses:  accessibility, javascript
  feedback                        |

Comment (by Cheffheid):

 Thanks for the quick look!

 I'll make a new patch without the disabling "close all tags" stuff. Won't
 hear me complain if that button gets removed either. :)

 I'm not entirely sure if I get your other comments though. I've mainly
 swapped checks around and made `selectionStart` the "main" check before
 falling back to `document.selection` since IE8 seems to be the only one
 that absolutely requires the latter for this to work. Apart from that, it
 saves the start and end positions of the selection when shift+tab is
 pressed in the textarea.

 Regardless of the method used to get the selection, IE8 and up all seem to
 have issues retaining the selection when a button is triggered. As much as
 I'd like to make it IE-specific, I'm not really aware of a way to
 specifically target IE (short of checking the user agent). `selectionStart
 === selectionEnd` could also mean that there is no selection But it is
 also only true for IE when a button is triggered, not when shift+tab is
 pressed to get out of the textarea, assuming a selection was made to begin

Ticket URL: <https://core.trac.wordpress.org/ticket/31661#comment:29>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform

More information about the wp-trac mailing list