[wp-trac] [WordPress Trac] #36316: Image editor: improve form validation errors handling
WordPress Trac
noreply at wordpress.org
Thu Jun 2 20:17:31 UTC 2016
#36316: Image editor: improve form validation errors handling
---------------------------------------+-----------------------------
Reporter: afercia | Owner: afercia
Type: defect (bug) | Status: assigned
Priority: normal | Milestone: 4.6
Component: Media | Version:
Severity: normal | Resolution:
Keywords: has-patch has-screenshots | Focuses: ui, javascript
---------------------------------------+-----------------------------
Comment (by afercia):
It was suggested to use `type="number"` for the input fields, it would
probably be a good thing even if not all browsers prevent to type non-
numerical characters in those fields. By the way, worth mentioning the
`onkeypress` event in `imageEdit.init()` currently triggers a function
that doesn't allow to use the arrow keys on those fields when using
Firefox. Worth reminding `onkeypress` works differently in different
browsers and in Firefox it fires when using the arrow keys so the fields
will be blurred because of:
{{{
if ( 36 < k && k < 41 ) {
$(this).blur();
}
}}}
Thinking this part and all the events in the Image Editor should be
completely reviewed, not sure if in this ticket.
--
Ticket URL: <https://core.trac.wordpress.org/ticket/36316#comment:11>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list