Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post here questions and problems related to editing and publishing DITA content.
Anonymous1

Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by Anonymous1 »

We are currently customizing the WebHelp Responsive (Tree) to our style. This works fine so far, thanks for the great documentation (https://www.oxygenxml.com/doc/versions/ ... -tips.html).

So far, there are two things I don't know how to customize. It seems that there are no parameters for what I want. Is there another way to implement the following things?
  • How do I get the table of content menu on the left?
  • At the moment, only the selected chapter is displayed in the table of content. Can we have all chapters of the book in the TOC with only the active chapter being open?
HomeGoods
Posts: 96
Joined: Wed Feb 09, 2005 8:57 am

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by HomeGoods »

Regarding the menu position, Alex happened to demonstrate in a webinar.
Anonymous1

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by Anonymous1 »

Great, much easier than expected. Thank you very much!
radu_pisoi
Posts: 403
Joined: Thu Aug 21, 2003 11:36 am
Location: Craiova
Contact:

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by radu_pisoi »

B-E-N wrote:At the moment, only the selected chapter is displayed in the table of content. Can we have all chapters of the book in the TOC with only the active chapter being open?
No, there is no transformation parameter that you can use to display all chapters in the topic's side TOC. I will register this feature request in out issue tracking system.

An workaround is to modify the XSLT stylesheet that produces the side TOC, com.oxygenxml.webhelp/xsl/dita/responsive/navigationLinks.xsl. To achieve your requirement, you have to modify the 'generateSideToc' template.
Radu Pisoi
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
Anonymous1

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by Anonymous1 »

I didn't get far with trying to modify the 'generateSideToc' template.

Can you point me to the template that generates the main page toc (which includes all ditamaps)? Maybe this will help me figure this out.
radu_pisoi
Posts: 403
Joined: Thu Aug 21, 2003 11:36 am
Location: Craiova
Contact:

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by radu_pisoi »

Hi,

If you want to customize the generation of the TOC component from the main page(a simplified TOC because it contains only two levels from the documentation hierarchy) you have to take a look at the template

Code: Select all

<!--
Template used to expand the whc:webhelp_tiles component.
-->
<xsl:template match="whc:webhelp_main_page_toc" mode="copy_template">
from the stylesheet:

Code: Select all

com.oxygenxml.webhelp/xsl/dita/responsive/mainPageComponentsExpander.xsl 
In case when you want to customize the generation of the side TOC component(component which is generated for each topic and it is not available in the main page), you have to look at the generateSideToc named template from com.oxygenxml.webhelp/xsl/dita/responsive/navigationLinks.xsl.
At the moment, only the selected chapter is displayed in the table of content. Can we have all chapters of the book in the TOC with only the active chapter being open?
I will register this requirement in our issue tracking system to be implemented in a future oXygen version. I think we could add a parameter that allows you to customize the side TOC generation:
- an option to generate also all chapters(topics) from the first level;
- an option to generate only the selected topic with its children;
- an option to generated the selected topic with its children and siblings.
Radu Pisoi
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
Anonymous1

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by Anonymous1 »

radu_pisoi wrote: I will register this requirement in our issue tracking system to be implemented in a future oXygen version. I think we could add a parameter that allows you to customize the side TOC generation:
- an option to generate also all chapters(topics) from the first level;
- an option to generate only the selected topic with its children;
- an option to generated the selected topic with its children and siblings.
That sounds perfect. Is it possible to give me a timeline for the implementation?

The thing is, we need this pretty soon. My tries to fix it in the navigationLinks.xsl failed so far. Could you tell me more specifically what I have to change in the Template to generate side TOC?
radu_pisoi
Posts: 403
Joined: Thu Aug 21, 2003 11:36 am
Location: Craiova
Contact:

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by radu_pisoi »

B-E-N wrote:Is it possible to give me a timeline for the implementation?
The issue to extend the generation of the side TOC is not scheduled for the next oXygen version which will be available about the middle of October.
radu_pisoi wrote: Could you tell me more specifically what I have to change in the Template to generate side TOC?
Please contact us on support@oxygenxml.com to give you a patch for this request.
Radu Pisoi
<oXygen/> XML Editor, Schema Editor and XSLT Editor/Debugger
http://www.oxygenxml.com
Anonymous1

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by Anonymous1 »

Thanks for supplying a patch for this. It works great. All chapters are now available in the side toc.
Costin
Posts: 828
Joined: Mon Dec 05, 2011 6:04 pm

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by Costin »

Hi everyone,

Just to update this thread, the patch we offered in the past does not apply anymore and is no longer needed, as we have since implemented this functionality in oXygen.
Starting with version 19.1 of oXygen XML, one can now control which links to be present in the side TOC from the generated output, using the "webhelp.side.toc.links" parameter that we made available for the WebHelp Responsive transformation.
To display all the links in the side TOC, you should just change the parameter value from "Chapter" (which is the default setting) to "All".
The accepted values are documented in the parameter editing dialog from the scenario configuration as well as in our User-Guide.

Regards,
Costin
Costin Sandoi
oXygen XML Editor and Author Support
syed
Posts: 76
Joined: Tue Nov 14, 2017 8:34 pm

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by syed »

Hi,

What is the equivalent parameter for webhelp.side.toc.links in v21? How to view the full TOC to the left side?

Thanks...
Syed
Anonymous1

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by Anonymous1 »

syed wrote: Mon Jul 20, 2020 7:55 pm Hi,

What is the equivalent parameter for webhelp.side.toc.links in v21? How to view the full TOC to the left side?

Thanks...
Syed
The webhelp.publication.toc.links parameter allows you to display the full TOC with all links or only the chapter.

And I think the TOC is on the left side by default in Oxygen 21.

Image
syed
Posts: 76
Joined: Tue Nov 14, 2017 8:34 pm

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by syed »

Thanks. I should have made myself more clear.

Is there a way to view the full TOC to the left side by default? For example, we don't want the top menu. Just the side full TOC.

Thanks...
Syed
alin
Site Admin
Posts: 268
Joined: Thu Dec 24, 2009 11:21 am

Re: Customizing WebHelp Responsive: Menu left / All chapters in TOC

Post by alin »

Hello,

To hide the Top Menu you should set the webhelp.show.top.menu parameter to no.

Regards,
Alin
Alin Balasa
Software Developer
<oXygen/> XML Editor
http://www.oxygenxml.com
Post Reply