Page 1 of 1

Problem with nested chunking

Posted: Wed Feb 07, 2018 12:38 am
by kgajda
I have a Topic Head with the chunk attribute set to "to-content". The 5 child topics show up in the TOC, but only 2 of the 5 show up in the topic as the other 3 are chunked with children themselves. Is there a workaround for this?

Re: Problem with nested chunking

Posted: Wed Feb 07, 2018 12:44 pm
by cosmin_andrei
Hello,

Could you please send us a complete small sample to reproduce the problem on our side?

You can send the sample by email to support [AT] oxygenxml [DOT] com.

Re: Problem with nested chunking

Posted: Mon Jun 10, 2019 9:52 pm
by damarislc
Hi

I'm having a similar issue.

Here is the main ditamap:

Code: Select all

<!DOCTYPE map PUBLIC "-//OASIS//DTD DITA Map//EN" "map.dtd">
<map>
    <title>Chunking test map</title>
  <topicref href="generic_topic_1.dita"/>
  <topicref href="topic_with_map_child.dita" chunk="to-content">
    <topicref href="generic_topic_2.dita"/>
    <topicref href="child_map_1.ditamap" format="ditamap"  chunk="to-content" />
  </topicref>
</map>
Here is the nested map:

Code: Select all

<!DOCTYPE map PUBLIC "-//OASIS//DTD DITA Map//EN" "map.dtd">
<map>
    <title>Child map 1</title>
  <topicref href="child_map_topic_1.dita"/>
  <topicref href="child_map_topic_2.dita"/>
</map>
The problem is when the nested ditamap is found with the chunk=to-content, the editors wants that the content from "child_map_1.ditamap" to be duplicated inside its parent "topic_with_map_child.dita" file and also into the file for its current "child_map_1.ditamap".

Currently the output looks like this:
Output file from "topic_with_map_child.dita"
Image
Output file from "child_map_1.ditamap"
Image

But they want that the first file look like this:
Image

But still having the second chunk file.

Re: Problem with nested chunking

Posted: Tue Jun 11, 2019 12:01 pm
by ionela
Hi,

Thank you for your example.

Indeed, the issue seems to be caused by the chunk=to-content attribute set on the nested ditamap. The workaround is to set the attribute only on the parent topic topic_with_map_child.dita and removed it from the nested map.

Code: Select all

<!DOCTYPE map PUBLIC "-//OASIS//DTD DITA Map//EN" "map.dtd">
<map>
    <title>Chunking test map</title>
  <topicref href="generic_topic_1.dita"/>
  <topicref href="topic_with_map_child.dita" chunk="to-content">
    <topicref href="generic_topic_2.dita"/>
    <topicref href="child_map_1.ditamap" format="ditamap"/>
  </topicref>
</map>
I hope this helps.

Regards,
Ionela