Page 1 of 1

Expand All in DITA Map Side-View

Posted: Wed Feb 05, 2025 5:24 am
by dreifsnider
Hi,

My team has asked for the ability to expand all topic hierarchies in the DITA Map side-view. We see that there is currently a Collapse All option, but for many of our DITA Maps, we have multiple layers of hierarchy and expanding all these layers can be very tedious.

Additionally, we've extended the DITAMapNodeCustomizerRendered to show a badge next to each topic in the DITA Map that contains tracked changes and/or comments. It would be very valuable for our users to be able to quickly expand all topics in the DITA Map to be able to quickly see which topics have a badge next to them.

We're envisioning something like this:
image.png
Is it possible to extend this menu to customize it? What would it take to add this action to this menu?

Thank you!

Daniel

Re: Expand All in DITA Map Side-View

Posted: Wed Feb 05, 2025 5:44 pm
by Bogdan Dumitru
Hello Daniel,

Unfortunately, there's no API available to add custom actions to the DITA Map tree context menu, but we can add the Expand All action. However, we're concerned that it may not work as you expect. While all nodes would expand instantly, the titles (including any custom badges) will be populated lazily.

If you're looking to identify all topics that need to be reviewed—such as those with badges for tracked changes or comments—how about adding a dedicated view that lists only the topics in the map with the badges? This might be more efficient than scanning the entire map tree to find the ones with badges.

Re: Expand All in DITA Map Side-View

Posted: Mon Feb 10, 2025 9:26 pm
by dreifsnider
Hi Bogdan,

Thank you for your reply and for agreeing to add the Expand All action to the context menu.

As for your comment about the titles:
the titles (including any custom badges) will be populated lazily.
We previously noticed how topic titles are populated lazily and this was the primary reason why we started using navtitle in our DITA Maps so that topic titles are populated instantly. We also understand that the badges will be populated lazily, but we still think it will be valuable to our users to let them expand the entire DITA Map.

As for your suggestion:
If you're looking to identify all topics that need to be reviewed—such as those with badges for tracked changes or comments—how about adding a dedicated view that lists only the topics in the map with the badges? This might be more efficient than scanning the entire map tree to find the ones with badges.
We also really like this idea and will start investigating adding this view. Do you have any advice or suggestions on how we might implement this? We are currently extending the DITAMapNodeRendererCustomizer to add the badge. Is there anyway we can collect the list of topics have a badge added?

Thanks!

Re: Expand All in DITA Map Side-View

Posted: Wed Feb 12, 2025 7:43 pm
by Bogdan Dumitru
Hello,

Since you use navtitle it won't take long to compute all the titles. Ok, we will add the Expand All function for the next version..

Regarding the dedicated view to present just the topics with "badges" (that I think are the topics you consider to be changed, or something like this), you cannot use DITAMapNodeRendererCustomizer. You can access the URL of the DITA Map in JS like this: "workspace.getEditingContextManager().getDitaContext().ditamapUrl" and you have to cache somewhere the topicrefs referenced by this map, and the for each use the same logic you have in your DITAMapNodeRendererCustomizer extension.

To show a side-view see this tutorial: https://www.oxygenxml.com/maven/com/oxy ... mview.html

Re: Expand All in DITA Map Side-View

Posted: Tue Mar 25, 2025 12:57 pm
by cosminef
Hello,

We wanted to inform you that we have released version 27.1 of Oxygen XML Web Author, and now you can expand all DITA map nodes using the Expand All action from the contextual menu of the DITA Map side-pane or the specialized DITA map tree editing mode.
To explore what version 27.1 brings, you can visit the **What's New** section [1].

Best,
Cosmin

[1] https://www.oxygenxml.com/xml_web_author/whats_new.html