-
Notifications
You must be signed in to change notification settings - Fork 402
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
fix: allow foreign namespaces in EPUB 2 SVGs
* allow foreign namespaced elements and attributes in EPUB 2 SVGs * Remove the restriction to HTML on foreignObject as that is an epub 3-specific rule
- Loading branch information
1 parent
929806b
commit e3ffc37
Showing
4 changed files
with
55 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
30 changes: 30 additions & 0 deletions
30
src/main/resources/com/adobe/epubcheck/schema/20/rng/ops20-svg.nvdl
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<rules xmlns="http://purl.oclc.org/dsdl/nvdl/ns/structure/1.0" startMode="svg"> | ||
<mode name="svg"> | ||
<namespace ns="http://www.w3.org/2000/svg"> | ||
<validate schema="svg11.rng" schemaType="application/relax-ng" | ||
useMode="allowForeignNS"> | ||
</validate> | ||
</namespace> | ||
</mode> | ||
<mode name="allowForeignNS"> | ||
<namespace ns="http://www.w3.org/1999/xhtml"> | ||
<attach/> | ||
</namespace> | ||
<namespace ns="http://www.idpf.org/2007/ops" match="attributes"> | ||
<attach/> | ||
</namespace> | ||
<namespace ns="http://www.w3.org/1999/xlink" match="attributes"> | ||
<attach/> | ||
</namespace> | ||
<namespace ns="http://www.w3.org/XML/1998/namespace" match="attributes"> | ||
<attach/> | ||
</namespace> | ||
<namespace ns="" match="attributes"> | ||
<attach/> | ||
</namespace> | ||
<anyNamespace match="elements attributes"> | ||
<allow/> | ||
</anyNamespace> | ||
</mode> | ||
</rules> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters