asciidoctor html table of contents in sidebar with volnitsky ?

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
10 messages Options
Reply | Threaded
Open this post in threaded view
|

asciidoctor html table of contents in sidebar with volnitsky ?

RichardH
    I've been making good-looking htmls using asciidoc
    with the theme volnitsky:-.

asciidoc -b html5 -a icons -a toc2 -a theme=volnitsky
--out-file=outfile01.html infile.adoc

    Now I'd like to switch to asciidoctor.

    So my question - How to get asciidoctor to make table
    of contents in sidebar when using asciidoc theme
    volnitsky ?

    This comes close, but ...

asciidoctor -b html5 -a icons -a toc2 -a
stylesheet=/etc/asciidoc/themes/volnitsky/volnitsky.css
--outfile=outfile02.html infile.adoc

    ... but asciidoctor's table of contents is at the
    top of the html main page, not in asciidoc's sidebar

    Your help appreciated

    Richard H

 [1]
http://asciidoctor.org/docs/asciidoc-writers-guide/#target-window-and-role-attributes-for-links




Reply | Threaded
Open this post in threaded view
|

Re: asciidoctor html table of contents in sidebar with volnitsky ?

abelsromero
Table of contents can be placed in many places using the `toc` attribute. See the reference for all options: http://asciidoctor.org/docs/user-manual/#user-toc.

If you want to set on the side using command args, just use "-a toc=right" or "-a toc=left".
Also, you can set is a document attribute below the header using the syntax ":toc: right" for instance.
Reply | Threaded
Open this post in threaded view
|

Re: asciidoctor html table of contents in sidebar with volnitsky ?

RichardH
Thank you for the quick reply.
I should have said that "-a toc=somewhere" works for default css
but I cant get it to work for volnitsky

i.e.
¶ This, without volnitsky, does put table of contents left sidebar,
  but uses default CSS
    asciidoctor -b html5 \
                -a icons \
                -a toc=left \
                --out-file=outfileGGG.html \
                infile.adoc


¶ This, with volnitsky, puts the table of contents
  top of main file instead of left sidebar
  though it does otherwise look like asciidoc volnitsky
    asciidoctor -b html5 \
                -a icons \
                -a toc=left \
                -a
stylesheet=/etc/asciidoc/themes/volnitsky/volnitsky.css   \
               --out-file=outfileFFF.html \
              infile.adoc

Perhaps something to do with invocation of the stylesheet??
Richard H

On 01/24/2017 01:13 PM, abelsromero [via Asciidoctor :: Discussion] wrote:

> Table of contents can be placed in many places (top, left, ) using the
> `toc` attribute (http://asciidoctor.org/docs/user-manual/#user-toc).
>
> If you want to set on the side using command args, just use "-a
> toc=right" or "-a toc=left".
>
> ------------------------------------------------------------------------
> If you reply to this email, your message will be added to the discussion
> below:
> http://discuss.asciidoctor.org/asciidoctor-html-table-of-contents-in-sidebar-with-volnitsky-tp5220p5221.html
>
> To start a new topic under Asciidoctor :: Discussion, email
> [hidden email]
> To unsubscribe from Asciidoctor :: Discussion, click here
> <
> NAML
> <
http://discuss.asciidoctor.org/template/NamlServlet.jtp?macro=macro_viewer&id=instant_html%21nabble%3Aemail.naml&base=nabble.naml.namespaces.BasicNamespace-nabble.view.web.template.NabbleNamespace-nabble.view.web.template.NodeNamespace&breadcrumbs=notify_subscribers%21nabble%3Aemail.naml-instant_emails%21nabble%3Aemail.naml-send_instant_email%21nabble%3Aemail.naml>
>
Reply | Threaded
Open this post in threaded view
|

Re: asciidoctor html table of contents in sidebar with volnitsky ?

abelsromero
Documentation acknowledge that Python Styles are no 100% compatible.
I looked into the CSSs and saw that the left and right positions are managed by "toc2" and "toc-right" classes respectively, and those are not defined in volnitsky.css (I used this one https://github.com/asciidoc/asciidoc/tree/master/themes/volnitsky).

I guess -take this with a grain of salt- you would need to patch the CSS to include the modifications necessary to integrate the necessary changes.
Reply | Threaded
Open this post in threaded view
|

Re: asciidoctor html table of contents in sidebar with volnitsky ?

RichardH
Thanks again for quick reply

On 01/24/2017 06:08 PM, abelsromero [via Asciidoctor :: Discussion] wrote:

I guess -take this with a grain of salt- you would need to patch the CSS to include the modifications necessary to integrate the necessary changes.

Thats a pity.
Conclusion - _pace_ http://asciidoctor.org/ - Asciidoctor is *almost* a drop-in replacement for the original AsciiDoc Python processor

Reply | Threaded
Open this post in threaded view
|

Re: asciidoctor html table of contents in sidebar with volnitsky ?

abelsromero
Yep

However, if you allow me the commercial moment, I'd say that "moving from an AsciiDoc (Python) pipeline to Asciidoctor is not a drop-in replacement and it requires a review of current processes. However, it is mostly compatible and it offers some advantages that can make the investment worth while."

If you are really considering migrating, it's a matter of assessing several pros and cons really.
Reply | Threaded
Open this post in threaded view
|

Re: asciidoctor html table of contents in sidebar with volnitsky ?

mojavelinux
Administrator
In reply to this post by RichardH
The stylesheets between AsciiDoc Python and Asciidoctor remain generally compatible for the main content, but Asciidoctor does the sidebar TOC differently, so those styles don't align. You'd need to tweak the volnitsky theme.

Personally, I find the volnitsky theme to be very primitive and it would be better to create a proper Asciidoctor theme using the Asciidoctor stylesheet factory. https://github.com/asciidoctor/asciidoctor-stylesheet-factory

-Dan

--
Dan Allen | @mojavelinux | https://twitter.com/mojavelinux
Reply | Threaded
Open this post in threaded view
|

Re: asciidoctor html table of contents in sidebar with volnitsky ?

mojavelinux
Administrator
In reply to this post by abelsromero
It's important to understand that at some point, the HTML that AsciiDoc Python produces is so legacy, we can't let it hold us back. We've done our very best to stay compatible as Asciidoctor rose to prominence, but now it's time to start looking to the future. What's important is that we provide good tools to work with the format. And that includes tools for creating custom stylesheets.

Having said that, I do think that stylesheets need to be created by people that understand how to create stylesheets. For people that don't have that skill set, you'll either need to pick from one that already exists or hire someone to create one.

There are many stylesheets to choose from, including a new effort that is building on the default stylesheet without using SASS. See https://darshandsoni.com/asciidoctor-skins/

-Dan

On Tue, Jan 24, 2017 at 12:32 PM, abelsromero [via Asciidoctor :: Discussion] <[hidden email]> wrote:
Yep

However, if you allow me the commercial moment, I'd say that "moving from an AsciiDoc (Python) pipeline to Asciidoctor is not a drop-in replacement and it requires a review of current processes. However, it is mostly compatible and it offers some advantages that can make the investment worth while."

If you are really considering migrating, it's a matter of assessing several pros and cons really.


If you reply to this email, your message will be added to the discussion below:
http://discuss.asciidoctor.org/asciidoctor-html-table-of-contents-in-sidebar-with-volnitsky-tp5220p5225.html
To start a new topic under Asciidoctor :: Discussion, email [hidden email]
To unsubscribe from Asciidoctor :: Discussion, click here.
NAML



--
Dan Allen | @mojavelinux | https://twitter.com/mojavelinux
Reply | Threaded
Open this post in threaded view
|

Re: asciidoctor html table of contents in sidebar with volnitsky ?

RichardH


On 01/24/2017 08:43 PM, mojavelinux [via Asciidoctor :: Discussion] wrote:
>
> There are many stylesheets to choose from,

   For making that choice,
      https://darshandsoni.com/asciidoctor-skins/
   is rather nice
   Are there any more pages like that?
   … but I still like volnitsky :-)
Reply | Threaded
Open this post in threaded view
|

Re: asciidoctor html table of contents in sidebar with volnitsky ?

mojavelinux
Administrator
There's also the themes from the stylesheet factory, but they are a little bit long in the tooth.


On Tue, Jan 24, 2017 at 1:59 PM, RichardH [via Asciidoctor :: Discussion] <[hidden email]> wrote:


On 01/24/2017 08:43 PM, mojavelinux [via Asciidoctor :: Discussion] wrote:
>
> There are many stylesheets to choose from,

   For making that choice,
      https://darshandsoni.com/asciidoctor-skins/
   is rather nice
   Are there any more pages like that?
   … but I still like volnitsky :-)



If you reply to this email, your message will be added to the discussion below:
http://discuss.asciidoctor.org/asciidoctor-html-table-of-contents-in-sidebar-with-volnitsky-tp5220p5228.html
To start a new topic under Asciidoctor :: Discussion, email [hidden email]
To unsubscribe from Asciidoctor :: Discussion, click here.
NAML



--
Dan Allen | @mojavelinux | https://twitter.com/mojavelinux