File tree Expand file tree Collapse file tree 3 files changed +34
-2
lines changed
main/resources/com/adobe/epubcheck/schema/30 Expand file tree Collapse file tree 3 files changed +34
-2
lines changed Original file line number Diff line number Diff line change 287
287
<let name =" ref" value =" ./normalize-space(@media-overlay)" />
288
288
<let name =" item" value =" //opf:manifest/opf:item[normalize-space(@id) = $ref]" />
289
289
<let name =" item-media-type" value =" normalize-space($item/@media-type)" />
290
+ <let name =" media-type" value =" normalize-space(@media-type)" />
290
291
<assert test =" $item-media-type = 'application/smil+xml'" >media overlay items must be of
291
292
the "application/smil+xml" type (given type was "<value-of select =" $item-media-type"
292
293
/>")</assert >
294
+ <assert test =" $media-type='application/xhtml+xml' or $media-type='image/svg+xml'"
295
+ >The media-overlay attribute is only allowed on XHTML and SVG content documents.</assert >
293
296
</rule >
294
297
</pattern >
295
298
322
325
<rule context =" opf:meta[normalize-space(@property)='media:playback-active-class']" >
323
326
<report test =" @refines" > @refines must not be used with the media:playback-active-class property</report >
324
327
</rule >
325
- </pattern >
326
-
328
+ </pattern >
329
+
327
330
328
331
329
332
<!-- EPUB 3.2 New Checks -->
Original file line number Diff line number Diff line change
1
+ <?xml version =" 1.0" encoding =" UTF-8" ?>
2
+ <package xmlns =" http://www.idpf.org/2007/opf" version =" 3.0" unique-identifier =" uid"
3
+ xmlns:dc=" http://purl.org/dc/elements/1.1/" >
4
+ <metadata >
5
+ <dc : title >Title</dc : title >
6
+ <dc : language >en</dc : language >
7
+ <dc : identifier id =" uid" >NOID</dc : identifier >
8
+ <meta property =" dcterms:modified" >2019-01-01T12:00:00Z</meta >
9
+ <!-- Media Overlays Duration Properties -->
10
+ <meta property =" media:duration" >0:01:30.200</meta >
11
+ <meta refines =" #mo001" property =" media:duration" >0:01:30.200</meta >
12
+ </metadata >
13
+ <manifest >
14
+ <item id =" t001" href =" contents.xhtml" properties =" nav" media-type =" application/xhtml+xml" media-overlay =" mo001" />
15
+ <item id =" img001" href =" cover.jpg" media-type =" image/jpeg" media-overlay =" mo001" />
16
+ <item id =" mo001" href =" mediaoverlay_001.smil" media-type =" application/smil+xml" />
17
+ </manifest >
18
+ <spine >
19
+ <itemref idref =" t001" />
20
+ </spine >
21
+ </package >
Original file line number Diff line number Diff line change @@ -23,6 +23,12 @@ Feature: EPUB 3 ▸ Media Overlays ▸ Package Document Checks
23
23
And the message contains 'must be of the "application/smil+xml" type'
24
24
And no other errors or warnings are reported
25
25
26
+ Scenario : Report use of the media-overlay attribute on non-EPUB Content Documents
27
+ When checking file 'mediaoverlays-non-contentdoc-error.opf'
28
+ Then error RSC-005 is reported
29
+ And the message contains 'media-overlay attribute is only allowed'
30
+ And no other errors or warnings are reported
31
+
26
32
## 3.5.2 Package Metadata
27
33
28
34
Scenario : the entire publication duration must be defined
@@ -36,6 +42,8 @@ Feature: EPUB 3 ▸ Media Overlays ▸ Package Document Checks
36
42
Then error RSC-005 is reported
37
43
And the message contains "item media:duration meta element not set"
38
44
And no other errors or warnings are reported
45
+
46
+
39
47
40
48
# C. Media Overlays Metadata Vocabulary
41
49
# see https://www.w3.org/publishing/epub32/epub-mediaoverlays.html#app-overlays-vocab
You can’t perform that action at this time.
0 commit comments