edtf.js icon indicating copy to clipboard operation
edtf.js copied to clipboard

Mismatches for XXXX-X2-<29+>

Open SylvainBigonneau opened this issue 5 years ago • 0 comments

(Sorry for spamming issues, I swear I'm actually trying to work on fixes ':D)

Using v2.7.1

Since X2 sets the inner date to February by default, any value for days above 28 (29 on leap years) on an X2 month will get replaced by March 1rst or February 29th:

> edtf('2019-X2-31').edtf
"2019-X3-01"
> edtf('2020-X2-31').edtf
"2020-X2-29"

Then again, we can assume this is not a big deal since if you select X2-30 and above, you obviously meant to select December... The rest basically boils down to #20

SylvainBigonneau avatar Dec 13 '19 10:12 SylvainBigonneau