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

Making changes to handle the first 6 comments on the content structure. #424

Closed kalaspuffar closed 3 years ago

kalaspuffar commented 3 years ago

Hi @josteinaj

I've started to look into the RelaxNG files today and update the rules after the comments made on GitHub. Some of them are quite broad so I might have misunderstood the range of the change.

  1. define name="book" is not descriptive in a multipage html validation setting
  2. top-level section is mandatory and should have the semantic attributes currently placed on body, body should not have any semantic attributes
  3. attribute role should be allowed in every location where epub:type is currently allowed (however, there is not a 1-1 relationship between epub:type and role, in some places a matching role is not available, so it shouldn't be always required)
  4. types: remove all z3998 values? No, rather make them optional!
  5. types: update epub:type list based on https://idpf.github.io/epub-vocabs/structure/ (e.g. rearnotes are deprecated in favour of endnotes)
  6. level1.content: currently h1 is the only allowed top-level heading, at least h2 should be allowed too, given the fact that part sectioning will have chapters starting on h2

Best regards Daniel

kalaspuffar commented 3 years ago

Hi @josteinaj

Added a choice and changed to all available heading levels.

Best regards Daniel

josteinaj commented 3 years ago

Looks good. Thanks!