@likecoin/epubcheck-ts 0.2.3 → 0.2.4
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/README.md +8 -8
- package/bin/epubcheck.js +4 -4
- package/bin/epubcheck.ts +4 -4
- package/dist/index.cjs +265 -14
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +265 -14
- package/dist/index.js.map +1 -1
- package/package.json +2 -2
- package/schemas/applications.rng +0 -429
- package/schemas/aria.rng +0 -3355
- package/schemas/block.rng +0 -488
- package/schemas/common.rng +0 -1076
- package/schemas/container.rng +0 -24
- package/schemas/core-scripting.rng +0 -950
- package/schemas/data.rng +0 -161
- package/schemas/datatypes.rng +0 -401
- package/schemas/embed.rng +0 -980
- package/schemas/epub-mathml3-inc.rng +0 -161
- package/schemas/epub-nav-30.rnc +0 -44
- package/schemas/epub-nav-30.rng +0 -19985
- package/schemas/epub-nav-30.sch +0 -87
- package/schemas/epub-prefix-attr.rng +0 -17
- package/schemas/epub-shared-inc.rng +0 -29
- package/schemas/epub-ssml-attrs.rng +0 -17
- package/schemas/epub-svg-30.rnc +0 -17
- package/schemas/epub-svg-30.rng +0 -19903
- package/schemas/epub-svg-30.sch +0 -7
- package/schemas/epub-svg-forgiving-inc.rng +0 -315
- package/schemas/epub-switch.rng +0 -121
- package/schemas/epub-trigger.rng +0 -90
- package/schemas/epub-type-attr.rng +0 -12
- package/schemas/epub-xhtml-30.rnc +0 -6
- package/schemas/epub-xhtml-30.rng +0 -19882
- package/schemas/epub-xhtml-30.sch +0 -409
- package/schemas/epub-xhtml-inc.rng +0 -151
- package/schemas/epub-xhtml-integration.rng +0 -565
- package/schemas/epub-xhtml-svg-mathml.rng +0 -17
- package/schemas/form-datatypes.rng +0 -54
- package/schemas/mathml3-common.rng +0 -336
- package/schemas/mathml3-content.rng +0 -1552
- package/schemas/mathml3-inc.rng +0 -30
- package/schemas/mathml3-presentation.rng +0 -2341
- package/schemas/mathml3-strict-content.rng +0 -205
- package/schemas/media.rng +0 -374
- package/schemas/meta.rng +0 -754
- package/schemas/microdata.rng +0 -192
- package/schemas/ncx.rng +0 -308
- package/schemas/ocf-container-30.rnc +0 -37
- package/schemas/ocf-container-30.rng +0 -568
- package/schemas/opf.rng +0 -15
- package/schemas/opf20.rng +0 -513
- package/schemas/package-30.rnc +0 -133
- package/schemas/package-30.rng +0 -1153
- package/schemas/package-30.sch +0 -444
- package/schemas/phrase.rng +0 -746
- package/schemas/rdfa.rng +0 -552
- package/schemas/revision.rng +0 -106
- package/schemas/ruby.rng +0 -141
- package/schemas/sectional.rng +0 -278
- package/schemas/structural.rng +0 -298
- package/schemas/tables.rng +0 -420
- package/schemas/web-components.rng +0 -184
- package/schemas/web-forms.rng +0 -975
- package/schemas/web-forms2.rng +0 -1236
package/schemas/opf20.rng
DELETED
|
@@ -1,513 +0,0 @@
|
|
|
1
|
-
<?xml version="1.0"?>
|
|
2
|
-
<grammar xmlns="http://relaxng.org/ns/structure/1.0" ns="http://www.idpf.org/2007/opf"
|
|
3
|
-
datatypeLibrary="http://www.w3.org/2001/XMLSchema-datatypes">
|
|
4
|
-
|
|
5
|
-
<!--
|
|
6
|
-
Title:
|
|
7
|
-
Relax NG Schema for the Open Packaging
|
|
8
|
-
Format (OPF) version 2.0
|
|
9
|
-
|
|
10
|
-
Version:
|
|
11
|
-
2.0
|
|
12
|
-
|
|
13
|
-
Revision:
|
|
14
|
-
20070222
|
|
15
|
-
|
|
16
|
-
Authors:
|
|
17
|
-
This Version 2.0 :
|
|
18
|
-
Peter Sorotokin <psorotok@adobe.com>
|
|
19
|
-
-->
|
|
20
|
-
|
|
21
|
-
<start>
|
|
22
|
-
<ref name="OPF20.package-element"/>
|
|
23
|
-
</start>
|
|
24
|
-
|
|
25
|
-
<define name="OPF20.optional-id-attribute">
|
|
26
|
-
<optional>
|
|
27
|
-
<attribute name="id">
|
|
28
|
-
<data type="ID"/>
|
|
29
|
-
</attribute>
|
|
30
|
-
</optional>
|
|
31
|
-
</define>
|
|
32
|
-
|
|
33
|
-
<define name="OPF20.optional-xml-lang-attribute">
|
|
34
|
-
<optional>
|
|
35
|
-
<attribute name="lang" ns="http://www.w3.org/XML/1998/namespace">
|
|
36
|
-
<text/>
|
|
37
|
-
</attribute>
|
|
38
|
-
</optional>
|
|
39
|
-
</define>
|
|
40
|
-
|
|
41
|
-
<define name="OPF20.optional-file-as-attribute">
|
|
42
|
-
<optional>
|
|
43
|
-
<attribute name="file-as" ns="http://www.idpf.org/2007/opf">
|
|
44
|
-
<text/>
|
|
45
|
-
</attribute>
|
|
46
|
-
</optional>
|
|
47
|
-
</define>
|
|
48
|
-
|
|
49
|
-
<define name="OPF20.optional-role-attribute">
|
|
50
|
-
<optional>
|
|
51
|
-
<attribute name="role" ns="http://www.idpf.org/2007/opf">
|
|
52
|
-
<text/>
|
|
53
|
-
</attribute>
|
|
54
|
-
</optional>
|
|
55
|
-
</define>
|
|
56
|
-
|
|
57
|
-
<define name="OPF20.optional-scheme-attribute">
|
|
58
|
-
<optional>
|
|
59
|
-
<attribute name="scheme" ns="http://www.idpf.org/2007/opf">
|
|
60
|
-
<text/>
|
|
61
|
-
</attribute>
|
|
62
|
-
</optional>
|
|
63
|
-
</define>
|
|
64
|
-
|
|
65
|
-
<define name="OPF20.optional-event-attribute">
|
|
66
|
-
<optional>
|
|
67
|
-
<attribute name="event" ns="http://www.idpf.org/2007/opf">
|
|
68
|
-
<text/>
|
|
69
|
-
</attribute>
|
|
70
|
-
</optional>
|
|
71
|
-
</define>
|
|
72
|
-
|
|
73
|
-
<define name="OPF20.optional-xsi-type">
|
|
74
|
-
<optional>
|
|
75
|
-
<attribute name="type" ns="http://www.w3.org/2001/XMLSchema-instance">
|
|
76
|
-
<text/>
|
|
77
|
-
</attribute>
|
|
78
|
-
</optional>
|
|
79
|
-
</define>
|
|
80
|
-
|
|
81
|
-
<define name="OPF20.package-element">
|
|
82
|
-
<element name="package">
|
|
83
|
-
<attribute name="version">
|
|
84
|
-
<value>2.0</value>
|
|
85
|
-
</attribute>
|
|
86
|
-
<attribute name="unique-identifier">
|
|
87
|
-
<data type="IDREF"/>
|
|
88
|
-
</attribute>
|
|
89
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
90
|
-
<ref name="OPF20.package-content"/>
|
|
91
|
-
</element>
|
|
92
|
-
</define>
|
|
93
|
-
|
|
94
|
-
<define name="OPF20.package-content">
|
|
95
|
-
<ref name="OPF20.metadata-element"/>
|
|
96
|
-
<ref name="OPF20.manifest-element"/>
|
|
97
|
-
<ref name="OPF20.spine-element"/>
|
|
98
|
-
<optional>
|
|
99
|
-
<ref name="OPF20.tours-element"/>
|
|
100
|
-
</optional>
|
|
101
|
-
<optional>
|
|
102
|
-
<ref name="OPF20.guide-element"/>
|
|
103
|
-
</optional>
|
|
104
|
-
</define>
|
|
105
|
-
|
|
106
|
-
<define name="OPF20.metadata-element">
|
|
107
|
-
<element name="metadata">
|
|
108
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
109
|
-
<ref name="OPF20.metadata-content"/>
|
|
110
|
-
</element>
|
|
111
|
-
</define>
|
|
112
|
-
|
|
113
|
-
<define name="OPF20.metadata-content">
|
|
114
|
-
<choice>
|
|
115
|
-
<interleave>
|
|
116
|
-
<ref name="OPF20.dc-metadata-element"/>
|
|
117
|
-
<optional>
|
|
118
|
-
<ref name="OPF20.x-metadata-element"/>
|
|
119
|
-
</optional>
|
|
120
|
-
</interleave>
|
|
121
|
-
<interleave>
|
|
122
|
-
<oneOrMore>
|
|
123
|
-
<ref name="DC.title-element"/>
|
|
124
|
-
</oneOrMore>
|
|
125
|
-
<oneOrMore>
|
|
126
|
-
<ref name="DC.language-element"/>
|
|
127
|
-
</oneOrMore>
|
|
128
|
-
<oneOrMore>
|
|
129
|
-
<ref name="DC.identifier-element"/>
|
|
130
|
-
</oneOrMore>
|
|
131
|
-
<zeroOrMore>
|
|
132
|
-
<ref name="DC.optional-metadata-element"/>
|
|
133
|
-
</zeroOrMore>
|
|
134
|
-
<zeroOrMore>
|
|
135
|
-
<ref name="OPF20.meta-element"/>
|
|
136
|
-
</zeroOrMore>
|
|
137
|
-
<zeroOrMore>
|
|
138
|
-
<ref name="OPF20.any-other-element"/>
|
|
139
|
-
</zeroOrMore>
|
|
140
|
-
</interleave>
|
|
141
|
-
</choice>
|
|
142
|
-
</define>
|
|
143
|
-
|
|
144
|
-
<define name="OPF20.dc-metadata-element">
|
|
145
|
-
<element name="dc-metadata">
|
|
146
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
147
|
-
<ref name="OPF20.dc-metadata-content"/>
|
|
148
|
-
</element>
|
|
149
|
-
</define>
|
|
150
|
-
|
|
151
|
-
<define name="OPF20.dc-metadata-content">
|
|
152
|
-
<interleave>
|
|
153
|
-
<oneOrMore>
|
|
154
|
-
<ref name="DC.title-element"/>
|
|
155
|
-
</oneOrMore>
|
|
156
|
-
<oneOrMore>
|
|
157
|
-
<ref name="DC.language-element"/>
|
|
158
|
-
</oneOrMore>
|
|
159
|
-
<oneOrMore>
|
|
160
|
-
<ref name="DC.identifier-element"/>
|
|
161
|
-
</oneOrMore>
|
|
162
|
-
<zeroOrMore>
|
|
163
|
-
<ref name="DC.optional-metadata-element"/>
|
|
164
|
-
</zeroOrMore>
|
|
165
|
-
</interleave>
|
|
166
|
-
</define>
|
|
167
|
-
|
|
168
|
-
<define name="DC.identifier-element" ns="http://purl.org/dc/elements/1.1/">
|
|
169
|
-
<element name="identifier">
|
|
170
|
-
<optional>
|
|
171
|
-
<attribute name="id">
|
|
172
|
-
<data type="ID"/>
|
|
173
|
-
</attribute>
|
|
174
|
-
</optional>
|
|
175
|
-
<ref name="OPF20.optional-xsi-type"/>
|
|
176
|
-
<ref name="OPF20.optional-scheme-attribute"/>
|
|
177
|
-
<!-- <ref name="DC.metadata-common-content"/>
|
|
178
|
-
MG 20111024, see epubcheck Issue 114
|
|
179
|
-
-->
|
|
180
|
-
<ref name="DC.metadata-required-content"/>
|
|
181
|
-
</element>
|
|
182
|
-
</define>
|
|
183
|
-
|
|
184
|
-
<define name="DC.title-element" ns="http://purl.org/dc/elements/1.1/">
|
|
185
|
-
<element name="title">
|
|
186
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
187
|
-
<ref name="OPF20.optional-xml-lang-attribute"/>
|
|
188
|
-
<ref name="DC.metadata-common-content"/>
|
|
189
|
-
</element>
|
|
190
|
-
</define>
|
|
191
|
-
|
|
192
|
-
<define name="DC.language-element" ns="http://purl.org/dc/elements/1.1/">
|
|
193
|
-
<element name="language">
|
|
194
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
195
|
-
<ref name="OPF20.optional-xsi-type"/>
|
|
196
|
-
<ref name="DC.metadata-common-content"/>
|
|
197
|
-
</element>
|
|
198
|
-
</define>
|
|
199
|
-
|
|
200
|
-
<define name="DC.optional-metadata-element" ns="http://purl.org/dc/elements/1.1/">
|
|
201
|
-
<choice>
|
|
202
|
-
<element name="contributor">
|
|
203
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
204
|
-
<ref name="OPF20.optional-xml-lang-attribute"/>
|
|
205
|
-
<ref name="OPF20.optional-file-as-attribute"/>
|
|
206
|
-
<ref name="OPF20.optional-role-attribute"/>
|
|
207
|
-
<ref name="DC.metadata-common-content"/>
|
|
208
|
-
</element>
|
|
209
|
-
<element name="coverage">
|
|
210
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
211
|
-
<ref name="OPF20.optional-xml-lang-attribute"/>
|
|
212
|
-
<ref name="DC.metadata-common-content"/>
|
|
213
|
-
</element>
|
|
214
|
-
<element name="creator">
|
|
215
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
216
|
-
<ref name="OPF20.optional-xml-lang-attribute"/>
|
|
217
|
-
<ref name="OPF20.optional-file-as-attribute"/>
|
|
218
|
-
<ref name="OPF20.optional-role-attribute"/>
|
|
219
|
-
<ref name="DC.metadata-common-content"/>
|
|
220
|
-
</element>
|
|
221
|
-
<element name="date">
|
|
222
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
223
|
-
<ref name="OPF20.optional-xsi-type"/>
|
|
224
|
-
<ref name="OPF20.optional-event-attribute"/>
|
|
225
|
-
<ref name="DC.metadata-common-content"/>
|
|
226
|
-
</element>
|
|
227
|
-
<element name="description">
|
|
228
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
229
|
-
<ref name="OPF20.optional-xml-lang-attribute"/>
|
|
230
|
-
<ref name="DC.metadata-common-content"/>
|
|
231
|
-
</element>
|
|
232
|
-
<element name="format">
|
|
233
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
234
|
-
<ref name="OPF20.optional-xsi-type"/>
|
|
235
|
-
<ref name="DC.metadata-common-content"/>
|
|
236
|
-
</element>
|
|
237
|
-
<element name="publisher">
|
|
238
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
239
|
-
<ref name="OPF20.optional-xml-lang-attribute"/>
|
|
240
|
-
<ref name="DC.metadata-common-content"/>
|
|
241
|
-
</element>
|
|
242
|
-
<element name="relation">
|
|
243
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
244
|
-
<ref name="OPF20.optional-xml-lang-attribute"/>
|
|
245
|
-
<ref name="DC.metadata-common-content"/>
|
|
246
|
-
</element>
|
|
247
|
-
<element name="rights">
|
|
248
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
249
|
-
<ref name="OPF20.optional-xml-lang-attribute"/>
|
|
250
|
-
<ref name="DC.metadata-common-content"/>
|
|
251
|
-
</element>
|
|
252
|
-
<element name="source">
|
|
253
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
254
|
-
<ref name="OPF20.optional-xml-lang-attribute"/>
|
|
255
|
-
<ref name="DC.metadata-common-content"/>
|
|
256
|
-
</element>
|
|
257
|
-
<element name="subject">
|
|
258
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
259
|
-
<ref name="OPF20.optional-xml-lang-attribute"/>
|
|
260
|
-
<ref name="DC.metadata-common-content"/>
|
|
261
|
-
</element>
|
|
262
|
-
<element name="type">
|
|
263
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
264
|
-
<ref name="OPF20.optional-xsi-type"/>
|
|
265
|
-
<ref name="DC.metadata-common-content"/>
|
|
266
|
-
</element>
|
|
267
|
-
</choice>
|
|
268
|
-
</define>
|
|
269
|
-
|
|
270
|
-
<define name="DC.metadata-common-content">
|
|
271
|
-
<text/>
|
|
272
|
-
</define>
|
|
273
|
-
|
|
274
|
-
<define name="DC.metadata-required-content">
|
|
275
|
-
<data type="token">
|
|
276
|
-
<param name="minLength">1</param>
|
|
277
|
-
</data>
|
|
278
|
-
</define>
|
|
279
|
-
|
|
280
|
-
<define name="OPF20.x-metadata-element">
|
|
281
|
-
<element name="x-metadata">
|
|
282
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
283
|
-
<ref name="OPF20.x-metadata-content"/>
|
|
284
|
-
</element>
|
|
285
|
-
</define>
|
|
286
|
-
|
|
287
|
-
<define name="OPF20.x-metadata-content">
|
|
288
|
-
<interleave>
|
|
289
|
-
<zeroOrMore>
|
|
290
|
-
<ref name="OPF20.meta-element"/>
|
|
291
|
-
</zeroOrMore>
|
|
292
|
-
<zeroOrMore>
|
|
293
|
-
<ref name="OPF20.any-other-element"/>
|
|
294
|
-
</zeroOrMore>
|
|
295
|
-
</interleave>
|
|
296
|
-
</define>
|
|
297
|
-
|
|
298
|
-
<define name="OPF20.meta-element">
|
|
299
|
-
<element name="meta">
|
|
300
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
301
|
-
<ref name="OPF20.optional-xml-lang-attribute"/>
|
|
302
|
-
<attribute name="name">
|
|
303
|
-
<text/>
|
|
304
|
-
</attribute>
|
|
305
|
-
<attribute name="content">
|
|
306
|
-
<text/>
|
|
307
|
-
</attribute>
|
|
308
|
-
<optional>
|
|
309
|
-
<attribute name="scheme">
|
|
310
|
-
<text/>
|
|
311
|
-
</attribute>
|
|
312
|
-
</optional>
|
|
313
|
-
<ref name="OPF20.meta-content"/>
|
|
314
|
-
</element>
|
|
315
|
-
</define>
|
|
316
|
-
|
|
317
|
-
<define name="OPF20.meta-content">
|
|
318
|
-
<empty/>
|
|
319
|
-
</define>
|
|
320
|
-
|
|
321
|
-
<define name="OPF20.manifest-element">
|
|
322
|
-
<element name="manifest">
|
|
323
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
324
|
-
<ref name="OPF20.manifest-content"/>
|
|
325
|
-
</element>
|
|
326
|
-
</define>
|
|
327
|
-
|
|
328
|
-
<define name="OPF20.manifest-content">
|
|
329
|
-
<oneOrMore>
|
|
330
|
-
<ref name="OPF20.item-element"/>
|
|
331
|
-
</oneOrMore>
|
|
332
|
-
</define>
|
|
333
|
-
|
|
334
|
-
<define name="OPF20.item-element">
|
|
335
|
-
<element name="item">
|
|
336
|
-
<attribute name="id">
|
|
337
|
-
<data type="ID"/>
|
|
338
|
-
</attribute>
|
|
339
|
-
<attribute name="href">
|
|
340
|
-
<data type="anyURI"/>
|
|
341
|
-
</attribute>
|
|
342
|
-
<attribute name="media-type">
|
|
343
|
-
<text/>
|
|
344
|
-
</attribute>
|
|
345
|
-
<optional>
|
|
346
|
-
<attribute name="fallback">
|
|
347
|
-
<data type="IDREF"/>
|
|
348
|
-
</attribute>
|
|
349
|
-
</optional>
|
|
350
|
-
<optional>
|
|
351
|
-
<attribute name="fallback-style">
|
|
352
|
-
<data type="IDREF"/>
|
|
353
|
-
</attribute>
|
|
354
|
-
</optional>
|
|
355
|
-
<optional>
|
|
356
|
-
<attribute name="required-namespace">
|
|
357
|
-
<text/>
|
|
358
|
-
</attribute>
|
|
359
|
-
<optional>
|
|
360
|
-
<attribute name="required-modules">
|
|
361
|
-
<text/>
|
|
362
|
-
</attribute>
|
|
363
|
-
</optional>
|
|
364
|
-
</optional>
|
|
365
|
-
<ref name="OPF20.item-content"/>
|
|
366
|
-
</element>
|
|
367
|
-
</define>
|
|
368
|
-
|
|
369
|
-
<define name="OPF20.item-content">
|
|
370
|
-
<empty/>
|
|
371
|
-
</define>
|
|
372
|
-
|
|
373
|
-
<define name="OPF20.spine-element">
|
|
374
|
-
<element name="spine">
|
|
375
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
376
|
-
<attribute name="toc">
|
|
377
|
-
<data type="IDREF"/>
|
|
378
|
-
</attribute>
|
|
379
|
-
<ref name="OPF20.spine-content"/>
|
|
380
|
-
</element>
|
|
381
|
-
</define>
|
|
382
|
-
|
|
383
|
-
<define name="OPF20.spine-content">
|
|
384
|
-
<oneOrMore>
|
|
385
|
-
<ref name="OPF20.itemref-element"/>
|
|
386
|
-
</oneOrMore>
|
|
387
|
-
</define>
|
|
388
|
-
|
|
389
|
-
<define name="OPF20.itemref-element">
|
|
390
|
-
<element name="itemref">
|
|
391
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
392
|
-
<attribute name="idref">
|
|
393
|
-
<data type="IDREF"/>
|
|
394
|
-
</attribute>
|
|
395
|
-
<optional>
|
|
396
|
-
<attribute name="linear">
|
|
397
|
-
<choice>
|
|
398
|
-
<value>yes</value>
|
|
399
|
-
<value>no</value>
|
|
400
|
-
</choice>
|
|
401
|
-
</attribute>
|
|
402
|
-
</optional>
|
|
403
|
-
<ref name="OPF20.itemref-content"/>
|
|
404
|
-
</element>
|
|
405
|
-
</define>
|
|
406
|
-
|
|
407
|
-
<define name="OPF20.itemref-content">
|
|
408
|
-
<empty/>
|
|
409
|
-
</define>
|
|
410
|
-
|
|
411
|
-
<define name="OPF20.tours-element">
|
|
412
|
-
<element name="tours">
|
|
413
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
414
|
-
<ref name="OPF20.tours-content"/>
|
|
415
|
-
</element>
|
|
416
|
-
</define>
|
|
417
|
-
|
|
418
|
-
<define name="OPF20.tours-content">
|
|
419
|
-
<oneOrMore>
|
|
420
|
-
<ref name="OPF20.tour-element"/>
|
|
421
|
-
</oneOrMore>
|
|
422
|
-
</define>
|
|
423
|
-
|
|
424
|
-
<define name="OPF20.tour-element">
|
|
425
|
-
<element name="tour">
|
|
426
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
427
|
-
<attribute name="title">
|
|
428
|
-
<text/>
|
|
429
|
-
</attribute>
|
|
430
|
-
<ref name="OPF20.tour-content"/>
|
|
431
|
-
</element>
|
|
432
|
-
</define>
|
|
433
|
-
|
|
434
|
-
<define name="OPF20.tour-content">
|
|
435
|
-
<oneOrMore>
|
|
436
|
-
<ref name="OPF20.site-element"/>
|
|
437
|
-
</oneOrMore>
|
|
438
|
-
</define>
|
|
439
|
-
|
|
440
|
-
<define name="OPF20.site-element">
|
|
441
|
-
<element name="site">
|
|
442
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
443
|
-
<attribute name="title">
|
|
444
|
-
<text/>
|
|
445
|
-
</attribute>
|
|
446
|
-
<attribute name="href">
|
|
447
|
-
<data type="anyURI"/>
|
|
448
|
-
</attribute>
|
|
449
|
-
<ref name="OPF20.site-content"/>
|
|
450
|
-
</element>
|
|
451
|
-
</define>
|
|
452
|
-
|
|
453
|
-
<define name="OPF20.site-content">
|
|
454
|
-
<empty/>
|
|
455
|
-
</define>
|
|
456
|
-
|
|
457
|
-
<define name="OPF20.guide-element">
|
|
458
|
-
<element name="guide">
|
|
459
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
460
|
-
<ref name="OPF20.guide-content"/>
|
|
461
|
-
</element>
|
|
462
|
-
</define>
|
|
463
|
-
|
|
464
|
-
<define name="OPF20.guide-content">
|
|
465
|
-
<oneOrMore>
|
|
466
|
-
<ref name="OPF20.reference-element"/>
|
|
467
|
-
</oneOrMore>
|
|
468
|
-
</define>
|
|
469
|
-
|
|
470
|
-
<define name="OPF20.reference-element">
|
|
471
|
-
<element name="reference">
|
|
472
|
-
<ref name="OPF20.optional-id-attribute"/>
|
|
473
|
-
<attribute name="type">
|
|
474
|
-
<text/>
|
|
475
|
-
</attribute>
|
|
476
|
-
<optional>
|
|
477
|
-
<attribute name="title">
|
|
478
|
-
<text/>
|
|
479
|
-
</attribute>
|
|
480
|
-
</optional>
|
|
481
|
-
<attribute name="href">
|
|
482
|
-
<data type="anyURI"/>
|
|
483
|
-
</attribute>
|
|
484
|
-
<ref name="OPF20.reference-content"/>
|
|
485
|
-
</element>
|
|
486
|
-
</define>
|
|
487
|
-
|
|
488
|
-
<define name="OPF20.reference-content">
|
|
489
|
-
<empty/>
|
|
490
|
-
</define>
|
|
491
|
-
|
|
492
|
-
<define name="OPF20.any-other-element">
|
|
493
|
-
<element>
|
|
494
|
-
<anyName>
|
|
495
|
-
<except>
|
|
496
|
-
<nsName ns="http://www.idpf.org/2007/opf"/>
|
|
497
|
-
<nsName ns="http://openebook.org/namespaces/oeb-package/1.0/"/>
|
|
498
|
-
<nsName ns="http://purl.org/dc/elements/1.1/"/>
|
|
499
|
-
</except>
|
|
500
|
-
</anyName>
|
|
501
|
-
<zeroOrMore>
|
|
502
|
-
<choice>
|
|
503
|
-
<attribute>
|
|
504
|
-
<anyName/>
|
|
505
|
-
</attribute>
|
|
506
|
-
<text/>
|
|
507
|
-
<ref name="OPF20.any-other-element"/>
|
|
508
|
-
</choice>
|
|
509
|
-
</zeroOrMore>
|
|
510
|
-
</element>
|
|
511
|
-
</define>
|
|
512
|
-
|
|
513
|
-
</grammar>
|
package/schemas/package-30.rnc
DELETED
|
@@ -1,133 +0,0 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
default namespace = "http://www.idpf.org/2007/opf"
|
|
4
|
-
namespace opf = "http://www.idpf.org/2007/opf"
|
|
5
|
-
namespace dc = "http://purl.org/dc/elements/1.1/"
|
|
6
|
-
|
|
7
|
-
include "./mod/datatypes.rnc"
|
|
8
|
-
include "./mod/epub-prefix-attr.rnc"
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
start = element package { opf.package.attlist & opf.package.content }
|
|
12
|
-
|
|
13
|
-
opf.package.attlist &= opf.version.attr & opf.unique.identifier.attr & opf.id.attr? & epub.prefix.attr? & opf.i18n.attrs
|
|
14
|
-
opf.version.attr = attribute version { '3.0' }
|
|
15
|
-
opf.unique.identifier.attr = attribute unique-identifier { datatype.IDREF }
|
|
16
|
-
|
|
17
|
-
opf.package.content = opf.metadata, opf.manifest, opf.spine, opf.guide?, opf.bindings?, opf.collection*
|
|
18
|
-
|
|
19
|
-
opf.metadata = element metadata { opf.id.attr? & opf.i18n.attrs & opf.metadata.content }
|
|
20
|
-
opf.metadata.content = opf.dc.elems & opf.meta* & opf.link*
|
|
21
|
-
|
|
22
|
-
opf.meta = element meta {
|
|
23
|
-
opf.epub3.meta.content | opf.epub2.meta.content
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
opf.epub3.meta.content = (opf.property.attr & opf.refines.attr? & opf.id.attr? & opf.scheme.attr? & opf.i18n.attrs & datatype.string.nonempty)
|
|
27
|
-
opf.epub2.meta.content = (attribute name { text } & attribute content { text }) #legacy
|
|
28
|
-
|
|
29
|
-
opf.link = element link { opf.href.attr & opf.hreflang.attr? & opf.rel.attr & opf.id.attr? & opf.refines.attr? & opf.media-type.attr? & opf.properties.attr? }
|
|
30
|
-
|
|
31
|
-
opf.property.attr = attribute property { datatype.property }
|
|
32
|
-
opf.rel.attr = attribute rel { datatype.properties }
|
|
33
|
-
opf.hreflang.attr = attribute hreflang { "" | datatype.languagecode }
|
|
34
|
-
opf.scheme.attr = attribute scheme { datatype.property }
|
|
35
|
-
opf.refines.attr = attribute refines { datatype.URI }
|
|
36
|
-
|
|
37
|
-
opf.dc.identifier = element dc:identifier { opf.id.attr? & datatype.string.nonempty }
|
|
38
|
-
opf.dc.title = element dc:title { opf.dc.attlist & datatype.string.nonempty }
|
|
39
|
-
opf.dc.language = element dc:language { opf.id.attr? & datatype.string.nonempty }
|
|
40
|
-
opf.dc.date = element dc:date { opf.id.attr? & datatype.string.nonempty }
|
|
41
|
-
opf.dc.source = element dc:source { opf.dc.attlist & datatype.string.nonempty }
|
|
42
|
-
opf.dc.type = element dc:type { opf.id.attr? & datatype.string.nonempty }
|
|
43
|
-
opf.dc.format = element dc:format { opf.id.attr? & datatype.string.nonempty }
|
|
44
|
-
opf.dc.creator = element dc:creator { opf.dc.attlist & datatype.string.nonempty }
|
|
45
|
-
opf.dc.subject = element dc:subject { opf.dc.attlist & datatype.string.nonempty }
|
|
46
|
-
opf.dc.description = element dc:description { opf.dc.attlist & datatype.string.nonempty }
|
|
47
|
-
opf.dc.publisher = element dc:publisher { opf.dc.attlist & datatype.string.nonempty }
|
|
48
|
-
opf.dc.contributor = element dc:contributor { opf.dc.attlist & datatype.string.nonempty }
|
|
49
|
-
opf.dc.relation = element dc:relation { opf.dc.attlist & datatype.string.nonempty }
|
|
50
|
-
opf.dc.coverage = element dc:coverage { opf.dc.attlist & datatype.string.nonempty }
|
|
51
|
-
opf.dc.rights = element dc:rights { opf.dc.attlist & datatype.string.nonempty }
|
|
52
|
-
|
|
53
|
-
opf.dc.elems = opf.dc.identifier+
|
|
54
|
-
& opf.dc.title+
|
|
55
|
-
& opf.dc.language+
|
|
56
|
-
& opf.dc.date?
|
|
57
|
-
& opf.dc.source*
|
|
58
|
-
& opf.dc.type*
|
|
59
|
-
& opf.dc.format*
|
|
60
|
-
& opf.dc.creator*
|
|
61
|
-
& opf.dc.subject*
|
|
62
|
-
& opf.dc.description*
|
|
63
|
-
& opf.dc.publisher*
|
|
64
|
-
& opf.dc.contributor*
|
|
65
|
-
& opf.dc.relation*
|
|
66
|
-
& opf.dc.coverage*
|
|
67
|
-
& opf.dc.rights*
|
|
68
|
-
|
|
69
|
-
opf.dc.attlist = opf.id.attr? & opf.i18n.attrs
|
|
70
|
-
|
|
71
|
-
opf.manifest = element manifest { opf.manifest.attlist & opf.manifest.content }
|
|
72
|
-
opf.manifest.attlist &= opf.id.attr?
|
|
73
|
-
opf.manifest.content = opf.item+
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
opf.item = element item { opf.item.attlist }
|
|
77
|
-
opf.item.attlist &= opf.id.attr & opf.href.attr & opf.media-type.attr & opf.fallback.attr? & opf.media-overlay.attr? & opf.properties.attr?
|
|
78
|
-
|
|
79
|
-
opf.fallback.attr = attribute fallback { datatype.IDREF }
|
|
80
|
-
opf.media-overlay.attr = attribute media-overlay { datatype.IDREF }
|
|
81
|
-
opf.properties.attr = attribute properties { datatype.properties }
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
opf.spine = element spine { opf.spine.attlist & opf.spine.content }
|
|
85
|
-
opf.spine.attlist &= opf.id.attr? & opf.spine.toc.attr? & opf.ppd.attr?
|
|
86
|
-
opf.spine.toc.attr = attribute toc { datatype.IDREF }
|
|
87
|
-
opf.ppd.attr = attribute page-progression-direction { 'ltr' | 'rtl' | 'default'}
|
|
88
|
-
opf.spine.content = opf.itemref+
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
opf.itemref = element itemref { opf.itemref.attlist }
|
|
92
|
-
opf.itemref.attlist &= opf.itemref.idref.attr & opf.itemref.linear.attr? & opf.id.attr? & opf.properties.attr?
|
|
93
|
-
opf.itemref.idref.attr = attribute idref { datatype.IDREF }
|
|
94
|
-
opf.itemref.linear.attr = attribute linear { 'yes' | 'no' }
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
opf.guide = element guide { opf.reference+ }
|
|
98
|
-
opf.reference = element reference { opf.href.attr & attribute type { datatype.text } & attribute title { datatype.text }?}
|
|
99
|
-
|
|
100
|
-
opf.bindings = element bindings { opf.bindings.mediaType+ }
|
|
101
|
-
opf.bindings.mediaType = element mediaType { opf.bindings.mediaType.attlist }
|
|
102
|
-
opf.bindings.mediaType.attlist &= opf.media-type.attr & attribute handler { datatype.IDREF }
|
|
103
|
-
|
|
104
|
-
opf.collection = element collection { opf.collection.attlist, opf.collection.content }
|
|
105
|
-
opf.collection.attlist &= opf.id.attr? & opf.dir.attr? & opf.xml.lang.attr? & opf.collection.role.attr
|
|
106
|
-
opf.collection.role.attr = attribute role { datatype.space.separated.tokens }
|
|
107
|
-
opf.collection.content = opf.collection.metadata?, (opf.collection+ | (opf.collection*, opf.collection.link+))
|
|
108
|
-
opf.collection.metadata = element metadata { opf.id.attr? & opf.i18n.attrs & opf.collection.metadata.content }
|
|
109
|
-
opf.collection.metadata.content = opf.collection.dc.elems & opf.collection.meta* & opf.link*
|
|
110
|
-
opf.collection.dc.elems = opf.dc.identifier*
|
|
111
|
-
& opf.dc.title*
|
|
112
|
-
& opf.dc.language*
|
|
113
|
-
& opf.dc.date*
|
|
114
|
-
& opf.dc.source*
|
|
115
|
-
& opf.dc.type*
|
|
116
|
-
& opf.dc.format*
|
|
117
|
-
& opf.dc.creator*
|
|
118
|
-
& opf.dc.subject*
|
|
119
|
-
& opf.dc.description*
|
|
120
|
-
& opf.dc.publisher*
|
|
121
|
-
& opf.dc.contributor*
|
|
122
|
-
& opf.dc.relation*
|
|
123
|
-
& opf.dc.coverage*
|
|
124
|
-
& opf.dc.rights*
|
|
125
|
-
opf.collection.meta = element meta { opf.epub3.meta.content }
|
|
126
|
-
opf.collection.link = element link { opf.href.attr & opf.rel.attr? & opf.id.attr? & opf.media-type.attr? }
|
|
127
|
-
|
|
128
|
-
opf.media-type.attr = attribute media-type { datatype.mimetype }
|
|
129
|
-
opf.href.attr = attribute href { datatype.URI }
|
|
130
|
-
opf.id.attr = attribute id { datatype.ID }
|
|
131
|
-
opf.i18n.attrs = opf.xml.lang.attr? & opf.dir.attr?
|
|
132
|
-
opf.xml.lang.attr = attribute xml:lang { "" | datatype.languagecode }
|
|
133
|
-
opf.dir.attr = attribute dir { 'ltr' | 'rtl' | 'auto' }
|