Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
I am not sure if this is supposed to mimic the AsciiDoc implementation which puts the toc in the left frame, using Javascript to generate it - if it is, then it doesn't :-)
|
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Administrator
|
All that's left to do to fully mimic the AsciiDoc implementation is to add these styles to the default stylesheet. The way it works in AsciiDoc is that AsciiDoc includes an extra stylesheet, toc2.css. I took a more standard approach by simply adding the "toc2" class to the toc. That way, we can include the styles for both toc layouts in the default stylesheet (and any of the themes). I have a prototype of the styles on the Golo theme, as you can see here (select Golo from the menu). Those are pretty generic styles, so it's just a matter of porting them over. Can you file an issue for tracking this enhancement? -Dan p.s. Asciidoctor doesn't use JavaScript to generate the toc because it doesn't have to. It has access to the structure of the document during the rendering phase. That's why Asciidoctor makes a reified toc and AsciiDoc does it after the fact.
On Thu, Apr 25, 2013 at 11:23 PM, snowolfe [via Asciidoctor :: Discussion] <[hidden email]> wrote: I am not sure if this is supposed to mimic the AsciiDoc implementation which puts the toc in the left frame, using Javascript to generate it - if it is, then it doesn't :-) Dan Allen Principal Software Engineer, Red Hat | Author of Seam in ActionRegistered Linux User #231597 |
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Administrator
|
In reply to this post by snowolfe
Btw, I also added some other goodies to the toc. You can use the following attributes to customize the toc: toc-title:: The heading text above the toc toc-class:: The CSS class that is added to the toc container div
toclevels:: The depth of the toc (between 1 and 5, default 2) Those are primarily for configuring the built-in toc in the header. You can also put a toc anywhere in the document and customize it like any other block.
[[mytoc]] [role="mytoc"] .My TOC toc::[levels=3] That inserts a toc like: <div id="mytoc" class="mytoc"> <div class="title">My TOC</div> <ul> ...up to 3 levels
</ul> </div> (You guessed it, these features need to be documented :)) -Dan On Thu, Apr 25, 2013 at 11:48 PM, Dan Allen <[hidden email]> wrote:
... [show rest of quote] Dan Allen Principal Software Engineer, Red Hat | Author of Seam in ActionRegistered Linux User #231597 |
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
Administrator
|
In reply to this post by snowolfe
...btw, the toc macro requires setting the toc attribute. To disable the built-in toc, unset the toc-placement attribute (e.g., -a toc-placement!) -Dan On Fri, Apr 26, 2013 at 12:32 AM, Dan Allen <[hidden email]> wrote:
... [show rest of quote] Dan Allen Principal Software Engineer, Red Hat | Author of Seam in ActionRegistered Linux User #231597 |
Loading... |
Reply to author |
Edit post |
Move post |
Delete this post |
Delete this post and replies |
Change post date |
Print post |
Permalink |
Raw mail |
![]() ![]() ![]() ![]() ![]() ![]() ![]() |
In reply to this post by mojavelinux
|
Free forum by Nabble | Edit this page |