Closed Bug 1798347 Opened 1 year ago Closed 1 year ago

<input type=time> not working as expected

Categories

(Core :: Layout: Form Controls, defect)

Firefox 106
defect

Tracking

()

VERIFIED FIXED
108 Branch
Tracking Status
firefox-esr102 --- unaffected
firefox106 --- wontfix
firefox107 --- verified
firefox108 --- verified

People

(Reporter: darrius.dupree, Assigned: emilio)

References

(Regression)

Details

(Keywords: regression)

Attachments

(1 file)

User Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64; rv:106.0) Gecko/20100101 Firefox/106.0

Steps to reproduce:

When using the input type time it always defaults to AM when before it didn't default right away when you enter an hour without a min time. Also when you are stepping through the hours using the arrow keys it only shows PM for 12pm and then jumps back to AM for all other hours. The only exception is if you manually enter military time, which most users won't know to do, and it will enter it as PM but then as soon as you cycle through the hours with the arrow keys it goes back to AM.

Actual results:

It always defaults/changes to AM when editing the hours section of the input type time if not manually entering military time.

Expected results:

It should not default to AM unless you are paging down from 12pm or up from 11pm.

The Bugbug bot thinks this bug should belong to the 'Core::Layout: Form Controls' component, and is moving the bug to that component. Please correct in case you think the bot is wrong.

Component: Untriaged → Layout: Form Controls
Product: Firefox → Core
Severity: -- → S3
Status: UNCONFIRMED → NEW
Ever confirmed: true
Regressed by: 1756211
Assignee: nobody → emilio
Status: NEW → ASSIGNED

Comment on attachment 9301751 [details]
Bug 1798347 - Don't unconditionally override to AM if hour value is <12. r=Gijs,kpatenio,niklas

Beta/Release Uplift Approval Request

  • User impact if declined: Somewhat bad regression in keyboard handling of time inputs.
  • Is this code covered by automated tests?: Yes
  • Has the fix been verified in Nightly?: No
  • Needs manual test from QE?: Yes
  • If yes, steps to reproduce: comment 0
  • List of other uplifts needed: none
  • Risk to taking this patch: Low
  • Why is the change risky/not risky? (and alternatives if risky): Super-well-scoped fix + test change.
  • String changes made/needed: none
  • Is Android affected?: No
Attachment #9301751 - Flags: approval-mozilla-beta?
Flags: qe-verify+
Pushed by ealvarez@mozilla.com:
https://hg.mozilla.org/integration/autoland/rev/3c0b29618e85
Don't unconditionally override to AM if hour value is <12. r=niklas

Set release status flags based on info from the regressing bug 1756211

Status: ASSIGNED → RESOLVED
Closed: 1 year ago
Resolution: --- → FIXED
Target Milestone: --- → 108 Branch
QA Whiteboard: [qa-triaged]

Managed to reproduce this issue using Firefox 106.0.4 (BuildId:20221102214123).

This issue is verified fixed using Firefox 108.0a1 (provided in Comment 6) on Windows 10 64bit, macOS 11, and Ubuntu 22.04.

With this patch applied, if navigating using the arrow keys, the AM switches to PM when reaching 12 but it doesn't switch back to AM if navigating back or cycling through the next 12 hrs mark. I can see that there are some differences in how Firefox & Google Chrome handles this so I've filled Bug 1799126 as a follow-up

Leaving the qe-verify+ flag until this gets verified in beta as well.

Comment on attachment 9301751 [details]
Bug 1798347 - Don't unconditionally override to AM if hour value is <12. r=Gijs,kpatenio,niklas

Approved for 107.0RC1

Attachment #9301751 - Flags: approval-mozilla-beta? → approval-mozilla-beta+

We are in 107 RC week, wontfix 106.

This issue is verified fixed using Firefox 107.0 (BuildId:20221107173030) on Windows 10 64bit, macOS 11 and Ubuntu 22.04

Status: RESOLVED → VERIFIED
Flags: qe-verify+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: