Details
-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
18.8.0
-
None
-
Unknown
-
Description
The cssClass parameter of the Container macro replaces the classes that the layout sets on the container, instead of adding to them. With layoutStyle="columns", the container-columns classes are lost, so the content is no longer laid out in columns.
AbstractContainerMacro lays out the container first, then calls containerRoot.setParameter("class", cssClass), which overwrites the class attribute set by ColumnsLayoutManager and the container-justified class set by justify.
Steps to reproduce
- Create a page with this content:
{{container layoutStyle="columns" cssClass="mine"}} (((A))) (((B))) {{/container}} - View the page.
Expected
A and B are displayed as two columns, and the container has the classes container-columns container-columns-2 mine.
Actual
A and B are displayed one below the other, and the container only has the class mine.
Found while auditing the Container macro: https://design.xwiki.org/xwiki/bin/view/Proposal/WYSIWYGusabilityofXWikimacros/Macros/container/