From e4d24590c1eef8e1f15ce76fb2db22772b407052 Mon Sep 17 00:00:00 2001 From: GitHub Action Date: Thu, 14 Nov 2024 23:02:07 +0000 Subject: [PATCH] Update documentation --- _static/js/versions.js | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/_static/js/versions.js b/_static/js/versions.js index 818bc996..4958195e 100644 --- a/_static/js/versions.js +++ b/_static/js/versions.js @@ -1,6 +1,6 @@ const themeFlyoutDisplay = "hidden"; -const themeVersionSelector = "True"; -const themeLanguageSelector = "True"; +const themeVersionSelector = true; +const themeLanguageSelector = true; if (themeFlyoutDisplay === "attached") { function renderLanguages(config) { @@ -8,10 +8,14 @@ if (themeFlyoutDisplay === "attached") { return ""; } + // Insert the current language to the options on the selector + let languages = config.projects.translations.concat(config.projects.current); + languages = languages.sort((a, b) => a.language.name.localeCompare(b.language.name)); + const languagesHTML = `
Languages
- ${config.projects.translations + ${languages .map( (translation) => `