Skip to content

Instantly share code, notes, and snippets.

@mmulich
Created April 14, 2016 23:33
Show Gist options
  • Select an option

  • Save mmulich/fe030dfb7b13d61fb62736e20176899d to your computer and use it in GitHub Desktop.

Select an option

Save mmulich/fe030dfb7b13d61fb62736e20176899d to your computer and use it in GitHub Desktop.

Revisions

  1. Michael Mulich created this gist Apr 14, 2016.
    140 changes: 140 additions & 0 deletions cooked.html
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,140 @@
    <html xmlns="http://www.w3.org/1999/xhtml" xmlns:epub="http://www.idpf.org/2007/ops" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:lrmi="http://lrmi.net/the-specification">
    <head itemscope="itemscope" itemtype="http://schema.org/Book">

    <title>Book One</title>
    <meta itemprop="inLanguage" data-type="language" content="">

    <!-- These are for discoverability of accessible content. -->
    <meta itemprop="accessibilityFeature" content="MathML">
    <meta itemprop="accessibilityFeature" content="LaTeX">
    <meta itemprop="accessibilityFeature" content="alternativeText">
    <meta itemprop="accessibilityFeature" content="captions">
    <meta itemprop="accessibilityFeature" content="structuredNavigation">


    <meta itemprop="dateCreated" content="">
    <meta itemprop="dateModified" content="">
    </head>
    <body xmlns:bib="http://bibtexml.sf.net/" xmlns:data="http://www.w3.org/TR/html5/dom.html#custom-data-attribute" itemscope="itemscope" itemtype="http://schema.org/Book">
    <div data-type="metadata">
    <h1 data-type="document-title" itemprop="name">Book One</h1>

    <div class="authors">
    By:

    Edited by:

    Illustrated by:

    Translated by:

    </div>

    <div class="publishers">
    Published By:
    </div>



    <div class="permissions">
    <p class="license">
    Licensed:
    <a href="" itemprop="dc:license,lrmi:useRightsURL" data-type="license"></a>
    </p>
    </div>

    <div class="description" itemprop="description" data-type="description">

    </div>


    <div data-type="resources" style="display: none">
    <ul>
    <li>ruleset</li> </ul>
    </div>
    </div>

    <nav id="toc"><ol><li><a href="[email protected]">Document One</a></li><li><a href="[email protected]">Document Two</a></li></ol></nav>
    <div data-type="page">
    <div data-type="metadata">
    <h1 data-type="document-title" itemprop="name">Document One</h1>

    <div class="authors">
    By:

    Edited by:

    Illustrated by:

    Translated by:

    </div>

    <div class="publishers">
    Published By:
    </div>



    <div class="permissions">
    <p class="license">
    Licensed:
    <a href="" itemprop="dc:license,lrmi:useRightsURL" data-type="license"></a>
    </p>
    </div>

    <div class="description" itemprop="description" data-type="description">

    </div>



    </div>

    <p>document one</p>
    </div>
    <div data-type="page">
    <div data-type="metadata">
    <h1 data-type="document-title" itemprop="name">Document Two</h1>

    <div class="authors">
    By:

    Edited by:

    Illustrated by:

    Translated by:

    </div>

    <div class="publishers">
    Published By:
    </div>



    <div class="permissions">
    <p class="license">
    Licensed:
    <a href="" itemprop="dc:license,lrmi:useRightsURL" data-type="license"></a>
    </p>
    </div>

    <div class="description" itemprop="description" data-type="description">

    </div>



    </div>

    <p>document two</p>
    </div><div class="end-of-chapter" data-type="composite-page"><h1 data-type="document-title" itemprop="name">Document One</h1><p class="license">
    Licensed:
    <a href="" itemprop="dc:license,lrmi:useRightsURL" data-type="license"></a>
    </p><a href="" itemprop="dc:license,lrmi:useRightsURL" data-type="license"></a><p>document one</p><h1 data-type="document-title" itemprop="name">Document Two</h1><p class="license">
    Licensed:
    <a href="" itemprop="dc:license,lrmi:useRightsURL" data-type="license"></a>
    </p><a href="" itemprop="dc:license,lrmi:useRightsURL" data-type="license"></a><p>document two</p></div></body>
    </html>
    134 changes: 134 additions & 0 deletions raw.html
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,134 @@
    <html xmlns="http://www.w3.org/1999/xhtml" xmlns:epub="http://www.idpf.org/2007/ops" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:lrmi="http://lrmi.net/the-specification">
    <head itemscope="itemscope" itemtype="http://schema.org/Book">

    <title>Book One</title>
    <meta itemprop="inLanguage" data-type="language" content=""></meta>

    <!-- These are for discoverability of accessible content. -->
    <meta itemprop="accessibilityFeature" content="MathML"></meta>
    <meta itemprop="accessibilityFeature" content="LaTeX"></meta>
    <meta itemprop="accessibilityFeature" content="alternativeText"></meta>
    <meta itemprop="accessibilityFeature" content="captions"></meta>
    <meta itemprop="accessibilityFeature" content="structuredNavigation"></meta>


    <meta itemprop="dateCreated" content=""></meta>
    <meta itemprop="dateModified" content=""></meta>
    </head>
    <body xmlns:bib="http://bibtexml.sf.net/" xmlns:data="http://www.w3.org/TR/html5/dom.html#custom-data-attribute" itemscope="itemscope" itemtype="http://schema.org/Book">
    <div data-type="metadata">
    <h1 data-type="document-title" itemprop="name">Book One</h1>

    <div class="authors">
    By:

    Edited by:

    Illustrated by:

    Translated by:

    </div>

    <div class="publishers">
    Published By:
    </div>



    <div class="permissions">
    <p class="license">
    Licensed:
    <a href="" itemprop="dc:license,lrmi:useRightsURL" data-type="license"></a>
    </p>
    </div>

    <div class="description" itemprop="description" data-type="description">

    </div>


    <div data-type="resources" style="display: none">
    <ul>
    <li>ruleset</li> </ul>
    </div>
    </div>

    <nav id="toc"><ol><li><a href="[email protected]">Document One</a></li><li><a href="[email protected]">Document Two</a></li></ol></nav>
    <div data-type="page">
    <div data-type="metadata">
    <h1 data-type="document-title" itemprop="name">Document One</h1>

    <div class="authors">
    By:

    Edited by:

    Illustrated by:

    Translated by:

    </div>

    <div class="publishers">
    Published By:
    </div>



    <div class="permissions">
    <p class="license">
    Licensed:
    <a href="" itemprop="dc:license,lrmi:useRightsURL" data-type="license"></a>
    </p>
    </div>

    <div class="description" itemprop="description" data-type="description">

    </div>



    </div>

    <p>document one</p>
    </div>
    <div data-type="page">
    <div data-type="metadata">
    <h1 data-type="document-title" itemprop="name">Document Two</h1>

    <div class="authors">
    By:

    Edited by:

    Illustrated by:

    Translated by:

    </div>

    <div class="publishers">
    Published By:
    </div>



    <div class="permissions">
    <p class="license">
    Licensed:
    <a href="" itemprop="dc:license,lrmi:useRightsURL" data-type="license"></a>
    </p>
    </div>

    <div class="description" itemprop="description" data-type="description">

    </div>



    </div>

    <p>document two</p>
    </div></body>
    </html>
    9 changes: 9 additions & 0 deletions ruleset.css
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,9 @@
    div[data-type='page'] *:not(div[data-type='metadata']) {
    copy-to: eob-all
    }
    body::after {
    content: pending(eob-all);
    class: end-of-book;
    data-type: composite-page;
    container: div;
    }