Closed jazzdrive3 closed 1 week ago
Thinking we might just label the chapters. Everything is a 'page' but we also have 'chapters' and those are what the TOC looks for.
This might mean changing the URI to use page-n
instead of chapter-n
for everything. I don't think it'd be a big loss to lose the chapter-n
in the URI altogether.
Would it be ok to have everything as /ebooks/over-structured-content/pages/page-9/
for example, even if it's a chapter? Then we could add 'chapter' to the pages designated as a chapter through the front-matter.
This would mean:
That sounds like it would work well, and solve the ToC problem at the same time.
@pjudge also had some good suggestions when we were discussing this in Slack
- URL that would be really helpful and makes a lot of sense would be: https://ebooks.lullabot.com/ebooks/over-structured-content/chapter-3/page-9
- The navigation arrows could be structured like the nav buttons in Drupal Views. << and >> could take you back/forward through chapters while < and > could take you forward/back page by page. The buttons would need to have title attributes to describe the behavior.
- I’m loving the page number in the corner. It would be helpful to also have the Chapter information on every page as well, but only have it in red and prominent on the first page of the chapter. Then, on the subsequent pages inside the chapter, maybe have it gray, and place it somewhere else, like near the page number, near the bottom of the page content, or near the navigation.
Whatever is simplest. I think the URLs and navigation would be nice-to-haves eventually, but not required.
Some progress here:
Questions:
Nice!
Yes, I think the sidebar ToC should match the main ToC.
I don't think we need page numbers in ToC, just the chapter numbers. Since they're all clickable, page numbers aren't that useful in this context.
I'll get the chapter breakdowns for the others soon.
@jazzdrive3 note that I'm still looking for the chapter breakdowns for
These currently don't have a TOC in the associated pull request #75
Right now, every single page is a "chapter" with a chapter title like "Chapter 4." But that's not how the content of most of these ebooks is organized.
For example on the "5 Signs You’ve Over-structured Your Content" ebook.
https://ebooks.lullabot.com/ebooks/over-structured-content/chapters/chapter-8/ This is something a full container of the following items. The H2 for the H3s.
The following pages fall under that container, and aren't really complete thoughts in and of themselves.
https://ebooks.lullabot.com/ebooks/over-structured-content/chapters/chapter-9/ https://ebooks.lullabot.com/ebooks/over-structured-content/chapters/chapter-10/ https://ebooks.lullabot.com/ebooks/over-structured-content/chapters/chapter-11/ https://ebooks.lullabot.com/ebooks/over-structured-content/chapters/chapter-12/ https://ebooks.lullabot.com/ebooks/over-structured-content/chapters/chapter-13/
So while those are pages, they shouldn't necessarily be full "chapters". Everything being flat sort of muddles things all together and you lose the natural hierarchy established by the headings in the original document.
This ebook, hierarchically, should only have 4 chapters.
Possible solution. A new layout instead of the chapter, where there is a new property in the metadata to set the parent so that it would appear above the heading for its children. I'm not sure what that would mean for the Table of Contents.
It would also be helpful to be able to hide the chapter heading altogether to avoid redundancies. For example, on the latest, we have numbers before the items, and it will be awkward to have
Chapter 3 Four: The project has an unrealistic timeline