Narrow top margin issue with headings in the MultiExcerpt macro

This article shows how to fix the narrow top margin issue with headings in the MultiExcerpt macro.

Issue Description

When defining a heading such as H1 on the first line within the MultiExcerpt macro and subsequently referencing it using the MultiExcerpt Include macro, there is a discrepancy in the top margin compared to a standard H1 heading.

Resolution

To address the issue, it is recommended to set the heading on MultiExcerpt Include instead of placing the heading inside the macro.

Follow the steps provided below:

  1. Edit the page with excerpts, and change the content weight to normal text for each excerpt.

     

  2. Edit the page with MultiExcerpt Includes, and apply the desired heading level to each excerpt.

     

  3. After following the above steps, the top margins are aligned.

     

  • The slight variation in margins is due to Confluence applying a 2px padding to each MultiExcerpt Include macro.