Skip to content
This repository was archived by the owner on Sep 9, 2024. It is now read-only.

Commit 9379d3c

Browse files
committed
docs: make current docs version message dynamic
1 parent c2982e2 commit 9379d3c

File tree

1 file changed

+8
-2
lines changed

1 file changed

+8
-2
lines changed

packages/docs/src/pages/releases.tsx

Lines changed: 8 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -145,8 +145,14 @@ const Releases = ({ docsGroups, searchablePages }: DocsMenuProps) => {
145145
<strong>Note</strong>
146146
</AlertTitle>
147147
<Typography variant="subtitle1" component="div" color="inherit">
148-
<span>The current docs are for Static CMS v3. For Static CMS v2, see&nbsp;</span>
149-
<StyledLink href="https://v2.staticcms.org">https://v2.staticcms.org</StyledLink>.
148+
<span>
149+
The current docs are for Static CMS v{latestMajorVersionNumber}. For Static CMS v
150+
{latestMajorVersionNumber - 1}, see&nbsp;
151+
</span>
152+
<StyledLink href={`https://v${latestMajorVersionNumber - 1}.staticcms.org`}>
153+
https://v{latestMajorVersionNumber - 1}.staticcms.org
154+
</StyledLink>
155+
.
150156
</Typography>
151157
</Alert>
152158
</Container>

0 commit comments

Comments
 (0)