Version banner#

2026-09-11

3 min read time

rocm-docs-core can display a banner across the top of every page to tell readers that they are not on the latest documentation. The banner appears automatically based on the version being built, and its link points to the same page on the latest version. You can also replace it with your own announcement.

Automatic banner#

For projects using the rocm theme flavor, the banner is added automatically based on the version type that rocm-docs-core detects from the build branch. No configuration is required.

Version type

When it applies

Banner message

Old release

A docs-X.Y.Z branch that is not the latest

This is not the latest version of ROCm documentation.

Release candidate

The current release-candidate branch

This page contains changes for a test release of ROCm.

Development

The development branch (for example develop)

This page contains proposed changes for a future release.

No banner is shown when the build is the latest release, because there is nothing newer to point to.

The banner is only added for the rocm flavor. Other flavors do not get an automatic banner, but they can set a custom one (see Custom announcement).

Custom announcement#

To show your own banner, set announcement in html_theme_options in conf.py. Because the automatic banner uses a default, any value you set takes precedence, including on the rocm flavor:

html_theme_options = {
    "announcement": "Read the <a href='https://rocm.docs.amd.com/'>ROCm documentation portal</a> for more.",
}

The value is raw HTML, so you can include links and inline markup.