Datepicker doesn't accept ISO 8601 with colon in time offset
Reproduction
https://formkit.link/0aa3abaef166adece938a6477f968539
Describe the bug
✅ 2023-01-01T11:00:00Z works
✅ 2023-01-01T12:00:00+0100 works
❌ 2023-01-01T12:00:00+01:00 fails with Error: Non ISO 8601 compliant date
FormKit datepicker Pro allows only Z as time zone designator or ±hhmm without colon as time offset.
ISO 8601 allow several time offsets (wikipedia):
-
Z -
±hh:mm -
±hhmm -
±hh
NB1: the time offset is validated against this regex: (Z|(?:\+|\-)[0-9]{4})?
NB2: somewhat related #675 Non ISO 8601 complient date when extra precision is given to datepicker PRO
Environment
Environment is not relevant to the issue.
Thanks for the detail — we’ll get this sorted out
This was fixed upstream in @formkit/tempo some time ago so should all be good to close here 👍