Jump to navigation
Jump to search
No edit summary |
No edit summary |
||
Line 1: | Line 1: | ||
{ | { | ||
"$schema": "http://json-schema.org/draft-07/schema#", | |||
"$id": "https://readium.org/webpub-manifest/schema/link.schema.json", | |||
"title": "Link Object", | |||
"description": "Link Object for the Readium Web Publication Manifest", | |||
"type": "object", | |||
"properties": { | |||
"href": { | |||
"description": "URI or URI template of the linked resource", | |||
"type": "string" | |||
}, | |||
"type": { | |||
"description": "MIME type of the linked resource", | |||
"type": "string" | |||
}, | |||
"templated": { | |||
"description": "Indicates that a URI template is used in href", | |||
"type": "boolean" | |||
}, | |||
"title": { | |||
"description": "Title of the linked resource", | |||
"type": "string" | |||
}, | |||
"rel": { | |||
"description": "Relation between the linked resource and its containing collection", | |||
"type": [ | |||
"string", | |||
"array" | |||
], | |||
"items": { | |||
"type": "string" | |||
} | |||
}, | |||
"properties": { | |||
"description": "Properties associated to the linked resource", | |||
"type": "object", | |||
"properties": { | |||
"page": { | |||
"description": "Indicates how the linked resource should be displayed in a reading environment that displays synthetic spreads.", | |||
"type": "string", | |||
"enum": [ | |||
"left", | |||
"right", | |||
"center" | |||
] | |||
} | |||
}, | |||
"allOf": [ | |||
{ | |||
"$ref": "/mediawiki-1.44.0/index.php?title=JsonSchema:WebPublication/ExtensionsEpubProperties\u0026action=raw" | |||
}, | |||
{ | |||
"$ref": "/mediawiki-1.44.0/index.php?title=JsonSchema:WebPublication/ExtensionsEncryptionProperties\u0026action=raw" | |||
}, | |||
{ | |||
"$ref": "https://drafts.opds.io/schema/properties.schema.json" | |||
} | |||
] | |||
}, | |||
"height": { | |||
"description": "Height of the linked resource in pixels", | |||
"type": "integer", | |||
"exclusiveMinimum": 0 | |||
}, | |||
"width": { | |||
"description": "Width of the linked resource in pixels", | |||
"type": "integer", | |||
"exclusiveMinimum": 0 | |||
}, | |||
"size": { | |||
"description": "Original size of the resource in bytes, prior to any use of encryption or compression in an archive", | |||
"type": "integer", | |||
"exclusiveMinimum": 0 | |||
}, | |||
"bitrate": { | |||
"description": "Bitrate of the linked resource in kbps", | |||
"type": "number", | |||
"exclusiveMinimum": 0 | |||
}, | |||
"duration": { | |||
"description": "Length of the linked resource in seconds", | |||
"type": "number", | |||
"exclusiveMinimum": 0 | |||
}, | |||
"language": { | |||
"description": "Expected language of the linked resource", | |||
"type": [ | |||
"string", | |||
"array" | |||
], | |||
"items": { | |||
"type": "string", | |||
"pattern": "^((?\u003Cgrandfathered\u003E(en-GB-oed|i-ami|i-bnn|i-default|i-enochian|i-hak|i-klingon|i-lux|i-mingo|i-navajo|i-pwn|i-tao|i-tay|i-tsu|sgn-BE-FR|sgn-BE-NL|sgn-CH-DE)|(art-lojban|cel-gaulish|no-bok|no-nyn|zh-guoyu|zh-hakka|zh-min|zh-min-nan|zh-xiang))|((?\u003Clanguage\u003E([A-Za-z]{2,3}(-(?\u003Cextlang\u003E[A-Za-z]{3}(-[A-Za-z]{3}){0,2}))?)|[A-Za-z]{4}|[A-Za-z]{5,8})(-(?\u003Cscript\u003E[A-Za-z]{4}))?(-(?\u003Cregion\u003E[A-Za-z]{2}|[0-9]{3}))?(-(?\u003Cvariant\u003E[A-Za-z0-9]{5,8}|[0-9][A-Za-z0-9]{3}))*(-(?\u003Cextension\u003E[0-9A-WY-Za-wy-z](-[A-Za-z0-9]{2,8})+))*(-(?\u003CprivateUse\u003Ex(-[A-Za-z0-9]{1,8})+))?)|(?\u003CprivateUse2\u003Ex(-[A-Za-z0-9]{1,8})+))$" | |||
}, | |||
"pattern": "^((?\u003Cgrandfathered\u003E(en-GB-oed|i-ami|i-bnn|i-default|i-enochian|i-hak|i-klingon|i-lux|i-mingo|i-navajo|i-pwn|i-tao|i-tay|i-tsu|sgn-BE-FR|sgn-BE-NL|sgn-CH-DE)|(art-lojban|cel-gaulish|no-bok|no-nyn|zh-guoyu|zh-hakka|zh-min|zh-min-nan|zh-xiang))|((?\u003Clanguage\u003E([A-Za-z]{2,3}(-(?\u003Cextlang\u003E[A-Za-z]{3}(-[A-Za-z]{3}){0,2}))?)|[A-Za-z]{4}|[A-Za-z]{5,8})(-(?\u003Cscript\u003E[A-Za-z]{4}))?(-(?\u003Cregion\u003E[A-Za-z]{2}|[0-9]{3}))?(-(?\u003Cvariant\u003E[A-Za-z0-9]{5,8}|[0-9][A-Za-z0-9]{3}))*(-(?\u003Cextension\u003E[0-9A-WY-Za-wy-z](-[A-Za-z0-9]{2,8})+))*(-(?\u003CprivateUse\u003Ex(-[A-Za-z0-9]{1,8})+))?)|(?\u003CprivateUse2\u003Ex(-[A-Za-z0-9]{1,8})+))$" | |||
}, | |||
"alternate": { | |||
"description": "Alternate resources for the linked resource", | |||
"type": "array", | |||
"items": { | |||
"$ref": "/mediawiki-1.44.0/index.php?title=JsonSchema:WebPublication/Link\u0026action=raw" | |||
} | |||
}, | |||
"children": { | |||
"description": "Resources that are children of the linked resource, in the context of a given collection role", | |||
"type": "array", | |||
"items": { | |||
"$ref": "/mediawiki-1.44.0/index.php?title=JsonSchema:WebPublication/Link\u0026action=raw" | |||
} | |||
} | |||
}, | |||
"required": [ | |||
"href" | |||
], | |||
"if": { | |||
"properties": { | |||
"templated": { | |||
"enum": [ | |||
false, | |||
null | |||
] | |||
} | |||
} | |||
}, | |||
"then": { | |||
"properties": { | |||
"href": { | |||
"type": "string", | |||
"format": "uri-reference" | |||
} | |||
} | |||
}, | |||
"else": { | |||
"properties": { | |||
"href": { | |||
"type": "string", | |||
"format": "uri-template" | |||
} | |||
} | |||
} | |||
} | } |
Revision as of 09:35, 8 September 2025
$schema | "http://json-schema.org/draft-07/schema#" | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
$id | "https://readium.org/webpub-manifest/schema/link.schema.json" | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
title | "Link Object" | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
description | "Link Object for the Readium Web Publication Manifest" | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
type | "object" | ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
properties |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
required |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
if |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
then |
| ||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
else |
|