Page 1 of 1

Expand/collapse text

Posted: Thu Jun 13, 2019 9:48 pm
by Carl
Is there an easy way to hide a block of text so that you can reveal/collapse it by clicking a link? This was easy to do in Flare, but I've gone in circles trying to find out how to do this in OxygenXML.

Re: Expand/collapse text

Posted: Fri Jun 14, 2019 10:52 am
by sorin_carbunaru
Hello Carl,

Are you asking about the text from the editing area (Text page or Author page) or about the text in the published output (for example WebHelp)?

Best wishes,
Sorin Carbunaru
oXygen XML

Re: Expand/collapse text

Posted: Wed Jun 19, 2019 8:07 pm
by Carl
Hello. I am asking about text in the WebHelp output.

Re: Expand/collapse text

Posted: Fri Jun 21, 2019 10:45 am
by ionela
Hi,

In the WebHelp Responsive output we have implemented for the expand/collapse feature. Our implementation is targeted on components that have a title. The title will act as a toggle button and it will always remain visible while the rest of the component will be collapsed/expanded. The expand-collapse widget is rendered before the title. The expand-collapsed state will actually be toggled by clicking only on this widget (not on the title's text).

We have 4 categories of components that match this pattern:
  • nested topics (to have nested topics you need to set chunk="to-content" attribute on the parent topic
  • sections that have a title
  • tables that have a title
  • index terms groups

Here is an example from our user-manual with a topic that contains collapsible elements:Publishing Template Package Contents

Regards,
Ionela