diff --git a/_static/js/versions.js b/_static/js/versions.js index 818bc9969..4958195e0 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 = `