GithubHelp home page GithubHelp logo

Comments (9)

owenh000 avatar owenh000 commented on June 5, 2024

Hi @************, thanks for the feedback. Unfortunately I don't understand the problem. As I write this, the example you linked does not include any Table of Contents.

Please note that the asciidoctor-multipage extension does not have or maintain a stylesheet (only a few rules which can be disabled)β€”the stylesheet is maintained in the Asciidoctor project. And regardless, you're free to use a custom stylesheet instead of the default.

from asciidoctor-multipage.

************ avatar ************ commented on June 5, 2024

Hi @************, thanks for the feedback. Unfortunately I don't understand the problem. As I write this, the example you linked does not include any Table of Contents.

Hi, precisely, there is no Table contents. What I propose is that something like a <h1>table of contents</h1> or <h1>List of children</h1> be added automatically to the output before the child list.

from asciidoctor-multipage.

owenh000 avatar owenh000 commented on June 5, 2024

@************, the Table of Contents already has a title.

Here is the HTML portion:

<div id="toctitle">Table of Contents</div>

And here is a screenshot of the sample document in the repository:

sample

If there is still a problem or I am misunderstanding, please provide an example, test case, or screenshot clearly demonstrating it and re-open this issue.

from asciidoctor-multipage.

************ avatar ************ commented on June 5, 2024

Just in case:

input.adoc

= h1

* big
* long
* list

== h2 

Desired multipage output:

h1.html

<h1>h1</h1>

<ul>
<li>big</li>
<li>long</li>
<li>list</li>
</ul>

<h2>Child sections</h2>

<ul>
<li><a href="h2.html">h2</a></li>
</ul>

Current multipage output: there is no h2 or anything that clearly separates list from h2. They are in two different lists, but this is not easy to see on the rendered output (there is a slightly taller vertical displacement, but it is not very easy to see for large lists)

<h1>h1</h1>

<ul>
<li>big</li>
<li>long</li>
<li>list</li>
</ul>
<ul>
<li><a href="h2.html">h2</a></li>
</ul>

This can be seen e.g. at: https://************.com/china-************/anti-ccp-info-sources.html "Backlinks to this page" is the last list item, and "Reddit" is the first child.

Screenshot from 2021-08-27 09-26-13

from asciidoctor-multipage.

owenh000 avatar owenh000 commented on June 5, 2024

@************, so this isn't related to the Table of Contents, as mentioned in the title and description? The "Table of Contents" is the listing of all parts/chapters/etc. in the document, including (when asciidoctor-multipage is in use) those that are not included on the current page. In the screenshot from earlier, the Table of Contents is on the left side with a grey background.

From a writing style perspective, I recommend avoiding using multiple lists in succession. Instead use a regular paragraph to tell the reader what the new list contains. However, if you want more spacing between successive lists, just add this CSS rule, adjusting the margin value to suit you:

ul,ol,dl{margin-bottom:2em}

(As mentioned before, the asciidoctor-multipage extension does not have or maintain a stylesheet.)

from asciidoctor-multipage.

************ avatar ************ commented on June 5, 2024

************, so this isn't related to the Table of Contents, as mentioned in the title and description? The "Table of Contents" is the listing of all parts/chapters/etc. in the document, including (when asciidoctor-multipage is in use) those that are not included on the current page. In the screenshot from earlier, the Table of Contents is on the left side with a grey background.

Sorry if terminology was confusing. What I meant is that multipage essentially adds a one level ToC to every page automatically.

From a writing style perspective, I recommend avoiding using multiple lists in succession. Instead use a regular paragraph to tell the reader what the new list contains. However, if you want more spacing between successive lists, just add this CSS rule, adjusting the margin value to suit you:

Note that the input does not contain consecutive lists. Only the multipage does.

from asciidoctor-multipage.

owenh000 avatar owenh000 commented on June 5, 2024

Note that the input does not contain consecutive lists. Only the multipage does.

Oh, okay. I understand now. You are suggesting that we add an h2 on each landing page before its list of child pages. Thanks for the examples and clarification.

In my opinion, the best solution here is to understand that your document output (with asciidoctor-multipage) will be generated using landing and leaf pages. Landing pages are not intended to contain document content; the purpose of those pages is to list child pages. As described in more detail over there, this extension is not designed for use as a website generator.

Still, I will leave this issue open in case there is need for further discussion.

from asciidoctor-multipage.

rwoldu avatar rwoldu commented on June 5, 2024

+1
@************ I found an intermediate solution by adding "discrete heading" https://docs.asciidoctor.org/asciidoc/latest/blocks/discrete-headings/ whichdon't show up in the table of content

from asciidoctor-multipage.

rwoldu avatar rwoldu commented on June 5, 2024

found another possibility using css:

.ulist:last-child:before {
    content: "Heading before child list:";

the list of child headers is always displayed at last on a page (except in the first page as "first-child")

from asciidoctor-multipage.

Related Issues (20)

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.