Branch: refs/heads/main
Home: https://github.com/WebKit/WebKit
Commit: 62d1c2262decd1597d5cf498a6448bbbacd8001a
https://github.com/WebKit/WebKit/commit/62d1c2262decd1597d5cf498a6448bbbacd8001a
Author: Tyler Wilcock <[email protected]>
Date: 2025-10-15 (Wed, 15 Oct 2025)
Changed paths:
A
LayoutTests/fast/forms/datetimelocal/datetimelocal-editable-components/up-down-arrow-starts-at-current-year-expected.txt
A
LayoutTests/fast/forms/datetimelocal/datetimelocal-editable-components/up-down-arrow-starts-at-current-year.html
M Source/WebCore/html/shadow/DateTimeFieldElements.cpp
M Source/WebCore/html/shadow/DateTimeFieldElements.h
M Source/WebCore/html/shadow/DateTimeNumericFieldElement.h
Log Message:
-----------
AX: Pressing the up or down arrow key from the year field of a date input
should start from the current year, not zero
https://bugs.webkit.org/show_bug.cgi?id=300700
rdar://162601959
Reviewed by Joshua Hoffman and Aditya Keerthi.
Starting from the current year provides a better user experience, as starting
from zero as done prior to this commit
means we jump to year 0001 on arrow down, or year 275760 on arrow up, neither
of which are likely to be what a user
actually wanted.
Test:
fast/forms/datetimelocal/datetimelocal-editable-components/up-down-arrow-starts-at-current-year.html
*
LayoutTests/fast/forms/datetimelocal/datetimelocal-editable-components/up-down-arrow-starts-at-current-year-expected.txt:
Added.
*
LayoutTests/fast/forms/datetimelocal/datetimelocal-editable-components/up-down-arrow-starts-at-current-year.html:
Added.
* Source/WebCore/html/shadow/DateTimeFieldElements.cpp:
(WebCore::currentYear):
(WebCore::DateTimeYearFieldElement::stepDown):
(WebCore::DateTimeYearFieldElement::stepUp):
* Source/WebCore/html/shadow/DateTimeFieldElements.h:
* Source/WebCore/html/shadow/DateTimeNumericFieldElement.h:
Canonical link: https://commits.webkit.org/301608@main
To unsubscribe from these emails, change your notification settings at
https://github.com/WebKit/WebKit/settings/notifications
_______________________________________________
webkit-changes mailing list
[email protected]
https://lists.webkit.org/mailman/listinfo/webkit-changes