mirror of
https://github.com/futurepress/epub.js.git
synced 2025-10-04 15:09:16 +02:00
#748 Feature: Media Overlays basic info access
exports metadata media:active-class through metadata.media_active_class exports media-overlay item attribute through overlay key
This commit is contained in:
parent
8d3740aa5d
commit
72ceefc1b6
1 changed files with 3 additions and 0 deletions
|
@ -99,6 +99,7 @@ class Packaging {
|
|||
metadata.orientation = this.getPropertyText(xml, "rendition:orientation");
|
||||
metadata.flow = this.getPropertyText(xml, "rendition:flow");
|
||||
metadata.viewport = this.getPropertyText(xml, "rendition:viewport");
|
||||
metadata.media_active_class = this.getPropertyText(xml, "media:active-class");
|
||||
// metadata.page_prog_dir = packageXml.querySelector("spine").getAttribute("page-progression-direction");
|
||||
|
||||
return metadata;
|
||||
|
@ -123,12 +124,14 @@ class Packaging {
|
|||
var id = item.getAttribute("id"),
|
||||
href = item.getAttribute("href") || "",
|
||||
type = item.getAttribute("media-type") || "",
|
||||
overlay = item.getAttribute("media-overlay") || "",
|
||||
properties = item.getAttribute("properties") || "";
|
||||
|
||||
manifest[id] = {
|
||||
"href" : href,
|
||||
// "url" : href,
|
||||
"type" : type,
|
||||
"overlay" : overlay,
|
||||
"properties" : properties.length ? properties.split(" ") : []
|
||||
};
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue