@domorium/validator 2.0.0 → 2.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +26 -0
- package/dist/index.cjs.js +1 -1
- package/dist/index.esm.js +213 -177
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,32 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to `@domorium/validator` are documented here.
|
|
4
4
|
|
|
5
|
+
## 2.0.1
|
|
6
|
+
|
|
7
|
+
- **A 5.5.1 date names its calendar where the specification puts it.** 5.5.1
|
|
8
|
+
writes the escape inside `<DATE>`, and `<DATE>` comes after the modifier:
|
|
9
|
+
`ABT <DATE>`, `BET <DATE> AND <DATE>`, `FROM <DATE> TO <DATE>`. The escape was
|
|
10
|
+
read only at the front of the whole payload, so `ABT @#DHEBREW@ TSH 5760` and
|
|
11
|
+
a Julian `FROM`/`TO` range were reported as invalid dates, while
|
|
12
|
+
`@#DJULIAN@ FROM 1 JAN 1700 TO 1 JAN 1710`, which the grammar does not admit,
|
|
13
|
+
passed. Each `<DATE>` now carries its own calendar and is read in
|
|
14
|
+
that calendar's months, so a range may cross calendars and neither half is
|
|
15
|
+
read in the other's vocabulary.
|
|
16
|
+
- **An exact date is Gregorian, and says so.** `DATE_EXACT` is
|
|
17
|
+
`<DAY> <MONTH> <YEAR_GREG>` with no slot for a calendar, but the escape was
|
|
18
|
+
stripped before the grammar ran, so `1 CHAN` / `2 DATE @#DHEBREW@ 1 TSH 5760`
|
|
19
|
+
validated clean — where the GEDCOM 7 rule for the same payload rejects it. The
|
|
20
|
+
two dialects agreed on every other date rule and disagreed on this one.
|
|
21
|
+
- **A day is measured against the calendar its own date names.** A calendar binds
|
|
22
|
+
to the date that follows it, which is what `FROM JULIAN 1670 TO 1800` says: two
|
|
23
|
+
dates, two calendars. The day-length check set the calendar once and carried it
|
|
24
|
+
to the end of the payload, so `FROM JULIAN 1 JAN 1700 TO 29 FEB 1900` reported
|
|
25
|
+
nothing — the second date is Gregorian, 1900 is not a Gregorian leap year, and
|
|
26
|
+
it was measured by the Julian rule, which has no exception for a century. The
|
|
27
|
+
same leading calendar suppressed the check for every later date in a range.
|
|
28
|
+
Each word that ends one date and begins the next now returns the calendar to
|
|
29
|
+
Gregorian, so a date names its own or is read as Gregorian.
|
|
30
|
+
|
|
5
31
|
## 2.0.0 - 2026-08-20
|
|
6
32
|
|
|
7
33
|
Removes three members of `GedcomDocument` that no consumer read, which is what
|