Customizing the Author and/or Print Views
Posted: Sun Feb 26, 2023 6:03 pm
Hello,
I am trying to modify the .css for the author and print views in the UI, but I need some guidance on a few topics.
First is where do you do that so that your custom css drives the author and print view?
Second, I would like to customize how notes, warnings, and cautions are presented. Need a custom icon, centered on the page, like this, with left and right indented text:
Third, we use the following type of DITA markup to create challenge and response pairs that are separated by leader dots like this:
1. Prompt..........Action
The DITA for this is:
Would like the leader dots to be responsive so the response is right justified and if it overflows the line, is right justified.
Finally, we have a few rules for how we number our procedural steps due to the constraints of the <ol> structure in DITA.
The basic structure is what you see above and the "challenge" gets the number when published. In DITA, the <li> typically gets the number, but when we run our custom FrameMaker publish process to generate our production output, we have scripts that modify which <p> gets the number so we get the desired layout.
The three other structures are:
(a) One or more <p>, <note>, or <itemgroup> elements prior to the <p outputclass="challenge"> element...we want the <p outputclass="challenge"> element to get the number.
(b) If there is no <p outputclass="challenge"> element in the <li> then the first <p> element that is a direct descendant of the <li> element gets the number.
(c) We use <p props="multipleBranch"> to create a question with choices like shown below. In this case we want the <p> with the props attribute to get the number ant not the <p> element with the outputclass="challenge". The structure is:
This would look like:
We also use the <itemgroup> element to create "headers" since these are allowed inside <li> elements. The look like this:
--- Header ---
We might use them anywhere such as in the previous example:
This would look like:
Thank you for any help you can provide!
Pat
I am trying to modify the .css for the author and print views in the UI, but I need some guidance on a few topics.
First is where do you do that so that your custom css drives the author and print view?
Second, I would like to customize how notes, warnings, and cautions are presented. Need a custom icon, centered on the page, like this, with left and right indented text:
Third, we use the following type of DITA markup to create challenge and response pairs that are separated by leader dots like this:
1. Prompt..........Action
The DITA for this is:
Code: Select all
<li>
<p outputclass="challenge">Prompt</p>
< outputclass="response">Action</p>
</li>
Finally, we have a few rules for how we number our procedural steps due to the constraints of the <ol> structure in DITA.
The basic structure is what you see above and the "challenge" gets the number when published. In DITA, the <li> typically gets the number, but when we run our custom FrameMaker publish process to generate our production output, we have scripts that modify which <p> gets the number so we get the desired layout.
The three other structures are:
(a) One or more <p>, <note>, or <itemgroup> elements prior to the <p outputclass="challenge"> element...we want the <p outputclass="challenge"> element to get the number.
(b) If there is no <p outputclass="challenge"> element in the <li> then the first <p> element that is a direct descendant of the <li> element gets the number.
(c) We use <p props="multipleBranch"> to create a question with choices like shown below. In this case we want the <p> with the props attribute to get the number ant not the <p> element with the outputclass="challenge". The structure is:
Code: Select all
<li>
<p props="multipleBranch">Is the switch on?</p>
<p outputclass="challenge">YES</p>
<p outputclass="response">Go to Step X</p>
<p outputclass="challenge">NO</p>
<p outputclass="response">Go to Step Y</p>
</li>
Code: Select all
1. Is the switch on?
YES.....................Go to Step X
NO......................Go to Step Y
--- Header ---
We might use them anywhere such as in the previous example:
Code: Select all
<li>
<itemgroup>Header</>
<p props="multipleBranch">Is the switch on?</p>
<p outputclass="challenge">YES</p>
<p outputclass="response">Go to Step X</p>
<p outputclass="challenge">NO</p>
<p outputclass="response">Go to Step Y</p>
</li>
Code: Select all
--- Header ---
1. Is the switch on?
YES.....................Go to Step X
NO......................Go to Step Y
Pat