WordPress.org

Make WordPress Core

Opened 5 years ago

Closed 5 years ago

#29725 closed defect (bug) (fixed)

Media library arrow key navigation is triggered in textareas

Reported by: essha Owned by: wonderboymusic
Milestone: 4.0.1 Priority: low
Severity: trivial Version: 4.0
Component: Media Keywords: has-patch fixed-major
Focuses: accessibility, javascript Cc:
PR Number:

Description

This is a follow-up to #28704.
Event is fired on arrow keys when you enter textarea, i.e. caption and description.
Please exlude TEXTAREA from event trigger as well.
https://core.trac.wordpress.org/attachment/ticket/28704/28704.diff

Attachments (1)

29725.diff (615 bytes) - added by ryelle 5 years ago.

Download all attachments as: .zip

Change History (12)

@ryelle
5 years ago

#1 @ryelle
5 years ago

  • Summary changed from Media library arrow keys: exclude nodeName to Media library arrow key navigation is triggered in textareas

Ran into this problem last night- the keyEvent function returns when the event target is an input, but not on textareas, so editing the captions becomes very frustrating (since the attachment changes out from under you).

29725.diff adds textarea to the conditional, and also switches to nodeName based on azaozz's comment on r29332.

#2 @ocean90
5 years ago

#29776 was marked as a duplicate.

#3 @ocean90
5 years ago

  • Focuses accessibility javascript added
  • Keywords has-patch commit added
  • Milestone changed from Awaiting Review to 4.0.1
  • Priority changed from normal to low
  • Severity changed from normal to trivial
  • Type changed from enhancement to defect (bug)

#4 @wonderboymusic
5 years ago

  • Owner set to wonderboymusic
  • Resolution set to fixed
  • Status changed from new to closed

In 29777:

Media Grid: when the modal is open, don't respond to arrow keys when <textarea> has focus.

Props ryelle.
Fixes #29725.

#5 @ocean90
5 years ago

  • Keywords fixed-major added; commit removed
  • Resolution fixed deleted
  • Status changed from closed to reopened

This ticket was mentioned in Slack in #core by jorbin. View the logs.


5 years ago

#7 @jorbin
5 years ago

I verified that r29777 applies correctly to the 4.0 branch and fixes the described issue. Tested in chrome 38 and 40 along with FF.

This is ready to be merged.

This ticket was mentioned in Slack in #core by ocean90. View the logs.


5 years ago

#9 @johnbillion
5 years ago

In 30378:

Update the inline docs for the keyEvent callback in the media grid.

Props adamsilverstein
See #29725

#10 @adamsilverstein
5 years ago

#30400 was marked as a duplicate.

#11 @nacin
5 years ago

  • Resolution set to fixed
  • Status changed from reopened to closed

In 30407:

Media Grid: when the modal is open, don't respond to arrow keys when <textarea> has focus.

Merges [29777] (and [30378]) to the 4.0 branch.

Props ryelle, adamsilverstein.
Fixes #29725.

Note: See TracTickets for help on using tickets.