react-spectrum
react-spectrum copied to clipboard
Allowing BC era timestamps in fromAbsolute (#6541)
Closes #6541
✅ Pull Request Checklist:
- [x] Included link to corresponding React Spectrum GitHub Issue.
- [x] Added/updated unit tests and storybook for this change (for new code or code which already has tests).
- [x] Filled out test instructions.
- [x] Updated documentation (if it already exists for this component).
- [x] Looked at the Accessibility Practices for this feature - Aria Practices
📝 Test Instructions:
The unit test should cover this. By hand:
import { fromAbsolute } from "@internationalized/date";
console.log(fromAbsolute(-62135596800001, "UTC").toAbsoluteString());
// ^^ should return: 0000-12-31T23:59:59.999Z