Hi,
I am using XML Author 21.1 and I have some issues with procedures in tasks that just include a single step. When I publish to PDF using the out-of-the box DITA Map PDF - based on HTML5 & CSS transformation scenario, the step or command is not numbered or counted, independent, if created in the Dita file in a steps or steps-unordered structure. Procedures with multiple steps however are correctly numbered in the PDF output.
How can I get the number 1. or a bullet in front of a cmd in a single step procedure in the pdf output?
Thank you very much for your help.
Numbering single step procedures in task
Re: Numbering single step procedures in task
I checked the DITA-OT stylesheets. Indeed, the steps element that contains a single item is transformed in a structure like:
This was in fact an improvement request: https://github.com/dita-ot/dita-ot/issues/175
You can use as workaround the following CSS rule:
Unfortunately is not possible to distinguish between a section generated by a "steps" or "steps-unordered", since the section element does not have a class attribute.
Many regards,
Dan
Code: Select all
<section>
<div class="li step p">
<span class="ph cmd">This is a command</span>
</div>
</section>
You can use as workaround the following CSS rule:
Code: Select all
section:not([class]) > div.step {
display:list-item;
list-style-type:disc;
margin-left: 2em;
}
Many regards,
Dan
Re: Numbering single step procedures in task
Thank you very much. This works for me.
-
- Posts: 284
- Joined: Thu May 02, 2019 2:32 pm
Re: Numbering single step procedures in task
My company also uses different formatting for single-step procedures, so it seems like a good enhancement to have.
Re: Numbering single step procedures in task
I recorded an improvement request for this.
Many regards,
Dan
Many regards,
Dan
-
- Posts: 150
- Joined: Wed Oct 16, 2019 3:47 pm
Re: Numbering single step procedures in task
Hello,
Starting with Oxygen 22.1 you can use the @class attribute on <section> elements to identify if the single step is caming from ordered or unordered list.
Regards,
Julien
Starting with Oxygen 22.1 you can use the @class attribute on <section> elements to identify if the single step is caming from ordered or unordered list.
Regards,
Julien