Skip to content

Commit

Permalink
update parent schema to correctly reference #entry if in an array…
Browse files Browse the repository at this point in the history
…, move description to root of `parent` schema
  • Loading branch information
mkdjr committed Jul 30, 2024
1 parent 5b0a3a8 commit ae1f3a2
Showing 1 changed file with 15 additions and 12 deletions.
27 changes: 15 additions & 12 deletions hayagriva.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -130,28 +130,31 @@
]
},
"parent": {
"description": "The item in which the item was published or to which it is strongly associated.",
"anyOf": [
{
"$dynamicRef": "#entry"
"$dynamicRef": "#entry",
"$comment": "^ This references the `entry` schema defined above by the `$dynamicAnchor` keyword."
},
{
"type": "array",
"items": {
"$ref": "entry"
"$dynamicRef": "#entry",
"$comment": "^ This references the `entry` schema defined above by the `$dynamicAnchor` keyword."
},
"minItems": 1,
"uniqueItems": true,
"description": "The item in which the item was published or to which it is strongly associated.",
"$comment": "^ This references the it's parent entry based on the `id`.",
"examples": [
{
"type": "Anthology",
"title": "Automata studies",
"editor": [
"Shannon, C. E.",
"McCarthy, J."
]
}
[
{
"type": "Anthology",
"title": "Automata studies",
"editor": [
"Shannon, C. E.",
"McCarthy, J."
]
}
]
]
}
]
Expand Down

0 comments on commit ae1f3a2

Please sign in to comment.