UX improvements

This commit is contained in:
2026-01-18 12:33:59 -05:00
parent 3f51053ff6
commit 4f6450d5f3
6 changed files with 92 additions and 8 deletions

View File

@@ -20,6 +20,7 @@ const sidebarErrorsEl = document.getElementById("sidebarErrors");
const themeSelect = document.getElementById("themeSelect");
const toolbarPositionSelect = document.getElementById("toolbarPositionSelect");
const toolbarAutoHide = document.getElementById("toolbarAutoHide");
const alwaysShowOutput = document.getElementById("alwaysShowOutput");
const globalSitesContainer = document.getElementById("globalSites");
const toc = document.querySelector(".toc");
const tocResizer = document.getElementById("tocResizer");
@@ -3527,6 +3528,7 @@ async function loadSettings() {
sites = [],
toolbarPosition = "bottom-right",
toolbarAutoHide: storedToolbarAutoHide = true,
alwaysShowOutput: storedAlwaysShowOutput = false,
sidebarWidth
} = await getStorage([
"apiKey",
@@ -3563,6 +3565,9 @@ async function loadSettings() {
if (toolbarAutoHide) {
toolbarAutoHide.checked = Boolean(storedToolbarAutoHide);
}
if (alwaysShowOutput) {
alwaysShowOutput.checked = Boolean(storedAlwaysShowOutput);
}
if (Number.isFinite(sidebarWidth)) {
applySidebarWidth(sidebarWidth);
}
@@ -3962,6 +3967,7 @@ async function saveSettings() {
? toolbarPositionSelect.value
: "bottom-right",
toolbarAutoHide: toolbarAutoHide ? toolbarAutoHide.checked : true,
alwaysShowOutput: alwaysShowOutput ? alwaysShowOutput.checked : false,
workspaces,
sites
});