Date picker's year selection does not show the leading 0s and this creates confusion.
- Dominant language
- TypeScript
- Stars
- 15.9k
- Forks
- 1.6k
- Avg merge
- 3d 5h
- Merged PRs (30d)
- 58
Description
### Provide a general summary of the issue here
https://react-aria.adobe.com/DateField
You can try it here. It is possible to leave the date as 10/10/25 but actual value there is 0025. Since there is no visual indicator that the date is incomplete, it creates a confusion. I created my own validator around here but in my opinion there should be better out of the box behavior to handle the year segment.
### 🤔 Expected Behavior?
Show the leading zeros in the date fields, add internal validation for the date segment
### 😯 Current Behavior
You can leave the date segment as two digit and form submissions will get it as is unless there is a custom validation
### 💁 Possible Solution
_No response_
### 🔦 Context
_No response_
### 🖥️ Steps to Reproduce
https://react-aria.adobe.com/DateField
### Version
3.44.0
### What browsers are you seeing the problem on?
Firefox
### If other, please specify.
_No response_
### What operating system are you using?
MacOS
### 🧢 Your Company/Team
_No response_
### 🕷 Tracking Issue
_No response_
Contributor guide
Research direction
Start with the DateField example at https://react-aria.adobe.com/DateField and reproduce the two-digit year behavior in Firefox. Trace the year segment handling and verify that leading zeros are shown and incomplete date segments are validated before considering the issue done.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- react, typescript
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 45/100