Giter Site home page Giter Site logo

org.dita4publishers.epub's Introduction

DITA for Publishers

Version 1.1.0 Under development

Master project for the DITA for Publishers activity. This project includes the toolkit plugins and samples as git submodules. See the wiki for details on how to set up new clones of this project.

NOTE: Issues for specific transformation types (EPUB, HTML5, etc.) are maintained in the project each transformation type. If you're not sure which project an issue applies to, feel free to submit the issue against the dita4publishers project.

News

5 Aug 2021 Release 1.0.0RC28

Many updates. Tested against OT 3.6.1 (see release notes in user guide). Many Word2DITA issues resolved.

24 April 2016: EPUB3 implementation essentially complete with the addition of font embedding and obfuscation.

7 Oct 2014: EPUB3 implementation is under way. See the org.dita4publishers.epub project for details.

Publishing the User Guide

The D4P User Guide is published via GitHub Pages through the separate repo dita4publishers.github.io.

To update the user guide do the following:

  1. Using InDesign, update the cover graphic to reflect the latest release and copyright date (docs/D4P Logo and User Guide Cover/D4P_UserGuide_cover Folder/D4P_UserGuide_cover.indd)
  2. Export new copies of cover-graphic.png (300PPI) and epub-cover-graphic.png (72PPI) to the user_docs/d4p-users-guide/images directory
  3. Run the html5-d4p-user-guide ant target
  4. Copy the generated HTML (d4p-users-guide from the build/docs/html5 directory) to the dita4publishers.github.io repo on branch main.
  5. Commit updates to dita4publishers.github.io repo and push

org.dita4publishers.epub's People

Contributors

blefort-uo avatar contrext avatar drmacro avatar jelovirt avatar raducoravu avatar rlhamilton avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

org.dita4publishers.epub's Issues

Should topicheads expanded by map-driven processing retain the topichead's node URI?

In map2epubContentImpl.xsl, topicheads are "expanded" to be their own DITA topics (c.f., <xsl:template match="*[df:isTopicHead(.)]" mode="generate-content">). The creation of their topic and title elements means their node URIs are that of the XSLT file rather than the context's (i.e., the topichead). It seems to me that the topic and title elements being created should retain the topichead's node URI in case someone wants to use those elements' URIs. I can't readily imagine typical use cases where that would actually occur. It would of course be easy to implement. (This decision will also apply to the HTML2 [which is going end of life soon] and Kindle plugins, which have identical code.)

Implement automated regression test on travis-ci

Need one or more regression tests to verify that the EPUB transform works for OT 1.8 and 2.0.

Ideally should run epubcheck after building the EPUB.

Would be possible to unzip the EPUB and verify specific structures, but that might be too hard to maintain.

Map references result in inappropriate entries in OPF manifest

These keydefs:

  <keydefs>
    <mapref
      href="content/keydefs-content.ditamap"/>
    <mapref
      href="media/keydefs-media-pdf.ditamap"/>
    <mapref
      href="media/keydefs-media-epub.ditamap"/>
  </keydefs>

Result in these OPF entries:

      <item id="d70e17"
            href="content/keydefs-content.xhtml"
            media-type="application/xhtml+xml"/>
      <item id="d70e19"
            href="media/keydefs-media-pdf.xhtml"
            media-type="application/xhtml+xml"/>
      <item id="d70e21"
            href="media/keydefs-media-epub.xhtml"
            media-type="application/xhtml+xml"/>

EPUB Zip does not pass epubcheck

Getting this failure:

The mimetype file has an extension of length 20. No filename extensions are permitted for the mimetype file.

From epubcheck for the EPUB Zip file generated by the Ant task. Have asked Radu and Jean Kaplansky for guidance. Using Oxygen's archive browser to open and save the EPUB file resolves the issue, so it must be something with how Ant's Zip implementation works.

Would like to avoid having custom Java code just to make the Zip file.

Handle missing graphics

Detect missing graphics and use the "missing graphics" images in the plugin's resources/ dir for any missing graphic.

This should be an optional behavior, with the option to continue to fail if any graphic cannot be found.

EPUB3: Need way to generate arbitrary EPUB3 meta elements

For EPUB3, the meta element uses the @Property attribute rather than @name, where @Property is a prefix-qualified name. See http://www.idpf.org/epub/301/spec/epub-publications.html#sec-meta-elem and http://www.idpf.org/epub/301/spec/epub-publications.html#sec-property-datatype

It's not yet clear what to do for DITA data elements with names that are not prefixed. Unprefixed names are inherently in the default vocabulary, which means you can't just put in any unprefixed name you want.

Add CSS references to the NAV XHTML document.

In the module map2epubNavImpl.xsl, there is no CSS references in the xsl:result-document instruction that generates the NAV XHTML document. Actually there is a "FIXME" comment there.

Code:

<xsl:result-document href="{$resultUri}" format="html5">
      <html 
        xmlns:epub="http://www.idpf.org/2007/ops" 
        >
        <head>
            <meta charset="utf-8" />
            <!-- FIXME: May need to generate appropriate CSS references here -->
        </head>
        <body>
          <xsl:for-each select="$navTypes">
            <xsl:variable name="navType" as="xs:string" select="."/>
            <xsl:message> + [INFO]   Generating nav structure for type "<xsl:value-of select="$navType"/>"...</xsl:message>
            <xsl:for-each select="$map">
                <xsl:call-template name="generate-nav-structure">
                  <xsl:with-param name="doDebug" as="xs:boolean" tunnel="yes" select="$doDebug"/>
                  <xsl:with-param name="navType" select="$navType" as="xs:string" tunnel="yes"/>
                </xsl:call-template>
            </xsl:for-each>
          </xsl:for-each>
        </body>
      </html>
    </xsl:result-document>  

Generate unique HTML files for each navigation reference to a topic

EPUB requires that each navigation reference to a file be the only reference to that file. Thus, each navigation reference must be to a separate HTML file or equivalent resource.

The process should behave as follows:

  1. If the navigation topicref has a @keys value, use the first or only key as the base filename, if the key is the first effective definition of the key in the map.
  2. If no @keys value, use the base filename of the source topic (possibly as set by @copy-to) as the base for the result filename. Count the number of preceding references in order to generate a filename of the form {basename}-{nn}.

This processing could be implemented during the base chunk processing or during final map-driven HTML processing.

Map to Graphic Map: Relative path constructed incorrectly

See file sample_data/epub-test/chapters/reusable-resources/common-figures.xml

The relative path with a go-up is not being handled correctly: the absolute path is one level too low so copy instruction in copy-graphics.xml is wrong.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.