You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
* Update record validation to follow rules in https://www.loc.gov/marc/specifications/specrecstruc.html , including:
- Validate that leader is 24 characters long (if configured with validationOption `leader: true`)
- Validate that leader contains only printable/graphic ASCII characters (if configured with validationOption `characters: true`)
- Validate that field tags are three characters long
- Validate that field tags consist only of ASCII numeric characters (decimal integers 0-9) and/or ASCII alphabetic characters (uppercase or lowercase, but not both). (if configured with validationOption `characters: true`)
- Validate that controlField tags start with '00' or ASCII alphabetic characters (if configured with validationOption `characters: true`)
- Validate that dataField tags do not start with '00' (if configured with validationOption `characters: true`)
- Validate that controlFields do not have ind1, ind2 or subfields
- Validate that controlField values contain only printable/graphic ASCII characters (if configured with validationOption `characters: true`)
- Validate that controlField value does not exceed maximum length for a field
- Validate that dataFields do not have value
- Validate that indicators are one character long
- Validate that indicators consist only of blanks or ASCII numeric or lowercase alphabetic characters (if configured with validationOption `characters: true`)
- Validate that subfield codes are one character long
- Validate that subfield codes consist only of printable/graphic ASCII characters excluding blank (if configured with validationOption `characters: true`)
- Validate that subfield values do not contain ASCII control characters (if configured with validationOption `noControlCharacters: true`)
- Validate that subfield values do not exceed maximum length for a field
- Validate that fields or subfields do not have additional properties (if configured with validationOption `noAdditionalProperties: true`)
* Add new validationOption `strict: true` that causes all other validationOptions to be handled as `true`
* Add new validationOptions and update default validationOptions:
```
strict: false // If true, all validationOptions below are handled as if true
fields: true, // Do not allow record without fields
subfields: true, // Do not allow empty subfields
subfieldValues: true, // Do not allow subfields without value
controlFieldValues: true // Do not allow controlFields without value
leader: false, // Do not allow record without leader, with empty leader or with leader with length != 24
characters: false // Do not allow erronous characters in tags, indicators and subfield codes
noControlCharacters: false, // Do not allow ASCII control characters in field/subfield values
noAdditionalProperties: false // Do not allow additional properties in fields
```
* Update deps
* Update node-tests: v19.x -> v20.x
* Fix and add tests
* Add some debug
* Update and fix README
* Add commentary to schema
* 7.3.0-alpha.7
0 commit comments