module-text: multiple instances on one page

A page can contain multiple separate module-text instances in the order declared by page.layout.sections. Each instance keeps its own configuration, language overlays and items.

This page uses three text modules. The first owns one page-wide table of contents; the following text modules contribute their headings without creating more indexes.

An index in the page's actual order

The table of contents is built from visible headings in the final rendered page. It covers every active text instance and can also link to titled CCMS modules further down the page.

Heading IDs and item anchors are made unique across the page by the builder. Hidden items are excluded.

Alternation starts on the first visible item

item_background_mode: "alternating" enables the pattern. With item_background_start: 1, the first, third and every other visible item use the design's section background.

The control item above is hidden and therefore does not shift the pattern.

The background spans edge to edge

Each visible item becomes a full-width section: its background spans the browser and includes the same vertical padding as an ordinary CCMS section, while the heading, copy and media remain aligned to the page's content width.

The module wrapper's and item's previous spacing is neutralised in this mode, so padding is added only once per visual section. This fourth visible item is uncoloured. The ordinary module-blocks section immediately after it therefore receives the section colour when the automatic page phase continues.

The automatic page phase continues here

This ordinary module-blocks section follows the final full-width item without restarting the background sequence. Its heading is also listed in the table of contents above.

The next ordinary module gets the right background


The text module ends with an uncoloured full-width item. This following standard module therefore receives design.background_colors.section automatically. At the same time, the table of contents follows the final DOM order and links headings across the module boundary.

Alternation can start on the second visible item

With item_background_start: 2, the first visible item keeps the standard page background. The second uses design.background_colors.section, and the pattern continues from there.

CCMS logo with a white C and the letters CMS on a blue background

The image, caption and body copy sit above the same full-width band.

One band paints the entire section surface

The full-width band alone owns the item's section background. The inner .text-item is transparent, so even translucent colours are painted exactly once behind the heading, image, caption, fact box and body copy.

Layout, rounded corners and other item styling remain intact on desktop and mobile; only the responsive image placement changes.

An instance can continue or reset the phase

Omit item_background_start to continue the page's current alternating phase. Set it explicitly to 1 or 2 when this text instance should reset the pattern on its first or second visible item.

Standard items are transparent

This third text instance omits both item_background_mode and item_background_start. Each inner text item is therefore transparent, allowing the module's outer section to show the page's automatic background without white cards on top.

The module participates in the colored-sections rhythm as one section. Alternating item backgrounds remain explicitly opt-in.

One article can continue through several modules

This showcase page uses page.article from text-1 through text-3. The blocks module between the text sections therefore belongs to the same semantic article, while the table of contents is still built from all visible page headings.

items[] no longer has a hard-coded limit of 20 items. Every item can have its own image, caption and fact box; the practical limit is the page's readability and performance.