From faff9dc715914a726e6bfb1a1eb67cc8fbb8f637 Mon Sep 17 00:00:00 2001 From: Wei-Chiu Chuang Date: Wed, 18 Feb 2026 22:35:20 -0800 Subject: [PATCH] HDDS-14658. [Docs] Show all available versions in the drop-down menu and defaults to Next. (cherry picked from commit 54630acd2bdac032ce86cee15bc8851783f7ca5e) --- docusaurus.config.js | 49 +++++++++++++++++++++++++++----------------- 1 file changed, 30 insertions(+), 19 deletions(-) diff --git a/docusaurus.config.js b/docusaurus.config.js index be70bdf939..b192431108 100644 --- a/docusaurus.config.js +++ b/docusaurus.config.js @@ -245,7 +245,13 @@ const config = { exclude: [ '**/06-troubleshooting/**', '**/07-system-internals/**', - ] + ], + versions: { + current: { + label: 'Next', + banner: 'unreleased', + }, + }, }, blog: { showReadingTime: true, @@ -324,24 +330,9 @@ const config = { }, items: [ { - label: 'Docs', - position: 'left', - items: [ - { - label: 'Latest Docs', - to: 'docs', - }, - { - label: 'Docs 2.0.0 (Archived)', - href: '/docs/2.0.0/', - target: '_blank' - }, - { - label: 'Docs 1.4.1 (Archived)', - href: '/docs/1.4.1/', - target: '_blank' - }, - ], + label: 'Docs', // 'User documentation' link + to: 'docs/next', // Links to the 'Next' version + position: 'left', // Keep it on the left }, { to: 'download', @@ -395,6 +386,26 @@ const config = { // type: 'localeDropdown', // position: 'right', // }, + { + type: 'docsVersionDropdown', // User doc version select on the right + position: 'right', + dropdownItemsAfter: [ + { + type: 'html', + value: '', + }, + { + label: 'Docs 2.0.0 (Archived)', + href: '/docs/2.0.0/', + target: '_blank', + }, + { + label: 'Docs 1.4.1 (Archived)', + href: '/docs/1.4.1/', + target: '_blank', + }, + ], + }, { href: 'https://github.com/apache/ozone', position: 'right',