Hiding Specific Admonition Types

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

Hiding Specific Admonition Types

drichsgirl
I am using Asciidoctor-pdf to create training manuals. I am trying to create a single doc that will generate a facilitator guide or a student guide. I was thinking the easiest way to do this would be to hijack one of the admonition types and use it for facilitator notes. Then, create two themes - one for students and one for facilitators. Then, I could hide the hijacked admonition type in the student theme so they would not see the facilitator notes. The problem: I can't figure out how to hide a specific admonition type. Is there a better way to do this?

Thank you for an amazing project! I have just started using it and I am .
Reply | Threaded
Open this post in threaded view
|

Re: Hiding Specific Admonition Types

mojavelinux
Administrator
I'm so glad to hear that you are liking the project!

I have good news for you. There is a feature that is designed specifically for this purpose. That feature is a conditional directive (aka preprocessor conditional). It allows you to turn on and off sections of content based on the value of an attribute.

For example:

ifdef::show-notes[]
notes goes here
endif::[]

Then do something like:

asciidoctor -a show-notes manual.adoc

This feature is not yet documented in the Asciidoctor User Manual. In the meantime, you can find more information about it in this issue:


Good luck!

-Dan

On Tue, Dec 22, 2015 at 11:20 PM, drichsgirl [via Asciidoctor :: Discussion] <[hidden email]> wrote:
I am using Asciidoctor-pdf to create training manuals. I am trying to create a single doc that will generate a facilitator guide or a student guide. I was thinking the easiest way to do this would be to hijack one of the admonition types and use it for facilitator notes. Then, create two themes - one for students and one for facilitators. Then, I could hide the hijacked admonition type in the student theme so they would not see the facilitator notes. The problem: I can't figure out how to hide a specific admonition type. Is there a better way to do this?

Thank you for an amazing project! I have just started using it and I am .


If you reply to this email, your message will be added to the discussion below:
http://discuss.asciidoctor.org/Hiding-Specific-Admonition-Types-tp4124.html
To start a new topic under Asciidoctor :: Discussion, email [hidden email]
To unsubscribe from Asciidoctor :: Discussion, click here.
NAML



--
Dan Allen | @mojavelinux | http://google.com/profiles/dan.j.allen
Reply | Threaded
Open this post in threaded view
|

Re: Hiding Specific Admonition Types

drichsgirl
I knew there had to be a way! Thank you so much for the info mojavelinux