nlbdev / nordic-epub3-dtbook-migrator

Tools for converting between a strict subset of DTBook and EPUB3.
http://nlbdev.github.io/nordic-epub3-dtbook-migrator/
GNU Lesser General Public License v2.1
8 stars 7 forks source link

Validator issue: [nordic_nav_references_1] All headings in the content documents must be referenced exactly once in the navigation document. #443

Closed martinpub closed 3 years ago

martinpub commented 3 years ago

[nordic_nav_references_1] All headings in the content documents must be referenced exactly once in the navigation document. In the content document "DTB37628-009-chapter.xhtml", the heading "2. Kuppartad inledning – i god demokratisk ordning? 1994–2000" with id="h1_6" inside the "section" element is not referenced from the navigation document.

(from DTB37628-corrected validation)

This does not seem correct.

The content doc looks like this:

<section id="level1_9" role="doc-chapter" aria-labelledby="h1_6" epub:type="bodymatter chapter">
<div epub:type="pagebreak" role="doc-pagebreak" class="page-normal" id="page-33" aria-label="33"/>
<h1 id="h1_6">2. Kuppartad inledning &#x2013; i god demokratisk ordning? 1994&#x2013;2000</h1>

And the section "level1_9" is correctly referenced in nav.xhtml. Having the headings referenced directly is something we actively want to avoid, so the check should be to check that all sections are covered by nav.xhtml?