HelpSmith Logo
Making Help Authoring a Pleasure to Do
Free DownloadStart your free trial now
HelpSmith Topics
Making Help Authoring a Pleasure To Do

How to add a collapsible section? (problem with a table)

In my help file I want to put some content into a collapsible section, as implemented in one of your sample projects.

The Toggle JS script (which is available in the sample project) works fine for regular text, user instructions, etc.

Problem:

But when I try to apply the Toggle script to the annotation tables which are generated below a screenshot, the tables are not displayed the same way in the compiled CHM help file or Web help system as they are in the design-time.

My question:

Is it possible to include tables into a collapsible section?

Please help.

25

Comments

Here is a sample help project

We have created a sample help project that adds a collapsible section to the image and annotation tables using the Toggle script.

You can find the sample project in the attachment below.

17

But when I try to apply the Toggle script to the annotation tables which are generated below a screenshot, the tables are not displayed the same way in the compiled CHM help file or Web help system as they are in the design-time.

Applying the Toggle script to paragraphs and tables

Please note that the Toggle script requires that you add the "data-toggle-id" attribute to the paragraphs of the collapsible box, as explained in the "Using JavaScript and CSS" help project (File|Help|Sample Projects).

However, when you select tables and add that attribute to the paragraphs via the HTML Attributes pane (View|HTML Attributes), it will add that attribute not only to the root-level paragraphs which contain the tables, but also to the nested paragraphs (in table cells), which is not correct.

16

Solution for tables:

As a solution, you should select each paragraph containing a table by clicking on the empty space in the left side before the table, and set the "data-toggle-id" attribute to the paragraph manually.

If nested paragraphs within the table (in table cells) have the "data-toggle-id" attribute, you should delete it.

21

It works now, thank you for your help!

8

Add a Comment

Please Login or Register or leave comments.

Hello World
Lorem ipsum dolor sit amet
OK
Login
Nickname or Email:
Password:
If you do not have an account, you can register.