1
0
Fork 0
mirror of https://github.com/Kozea/Radicale.git synced 2025-07-23 17:48:30 +00:00

Initial version of documentation generator

This commit is contained in:
Unrud 2020-02-27 02:34:49 +01:00
parent 3f032e00b0
commit b2c3f38766
12 changed files with 890 additions and 0 deletions

View file

@ -0,0 +1,20 @@
window.addEventListener("load", function() {
let select = document.querySelector("header select.documentBranch");
while (select.firstChild) {
select.removeChild(select.firstChild);
}
for (let branch of documentBranches) {
let option = document.createElement("option");
option.textContent = branch;
if (branch === documentBranch) {
option.setAttribute("selected", "");
}
select.appendChild(option);
}
select.addEventListener("change", function() {
if (select.value !== documentBranch) {
location.assign(select.value + ".html");
select.value = documentBranch;
}
});
});