Restore pane resizing

This commit is contained in:
DonVoo 2026-07-13 11:39:15 +02:00
parent dee6dd8cd8
commit cc3f796ca3
2 changed files with 25 additions and 21 deletions

View file

@ -73,8 +73,8 @@ func renderStartPage(w http.ResponseWriter, r *http.Request) {
fmt.Fprintf(w, `<!doctype html><html lang="de"><head><meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<title>Mail-Graveyard</title>
<link rel="stylesheet" href="/static/style.css?v=20260713-6">
<script src="/static/app.js?v=20260713-6" defer></script></head>
<link rel="stylesheet" href="/static/style.css?v=20260713-7">
<script src="/static/app.js?v=20260713-7" defer></script></head>
<body class="ol2013">
<header class="ribbon">
<button class="app-menu-button" type="button" aria-label="Mail-Graveyard-Menue" aria-expanded="false" data-backstage-toggle><span class="mail-logo" aria-hidden="true"></span></button>
@ -121,9 +121,9 @@ func renderShell(w http.ResponseWriter, r *http.Request, active, readingPane str
fmt.Fprintf(w, `<!doctype html><html lang="de"><head><meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<title>Mail-Graveyard</title>
<link rel="stylesheet" href="/static/style.css?v=20260713-6">
<link rel="stylesheet" href="/static/style.css?v=20260713-7">
<script src="/static/htmx.min.js"></script>
<script src="/static/app.js?v=20260713-6" defer></script></head>
<script src="/static/app.js?v=20260713-7" defer></script></head>
<body class="ol2013">
<header class="ribbon">
<button class="app-menu-button" type="button" aria-label="Mail-Graveyard-Menue" aria-expanded="false" data-backstage-toggle><span class="mail-logo" aria-hidden="true"></span></button>
@ -697,9 +697,9 @@ func renderAccountsPage(w http.ResponseWriter, r *http.Request, accounts []Accou
fmt.Fprintf(w, `<!doctype html><html lang="de"><head><meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<title>Konten-Verwaltung - Mail-Graveyard</title>
<link rel="stylesheet" href="/static/style.css?v=20260713-6">
<link rel="stylesheet" href="/static/style.css?v=20260713-7">
<script src="/static/htmx.min.js"></script>
<script src="/static/app.js?v=20260713-6" defer></script></head>
<script src="/static/app.js?v=20260713-7" defer></script></head>
<body class="ol2013">
<header class="ribbon">
<button class="app-menu-button" type="button" aria-label="Mail-Graveyard-Menue" aria-expanded="false" data-backstage-toggle><span class="mail-logo" aria-hidden="true"></span></button>
@ -743,9 +743,9 @@ func renderArchivesPage(w http.ResponseWriter, r *http.Request, archives []strin
fmt.Fprintf(w, `<!doctype html><html lang="de"><head><meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<title>Archiv-mbox Verwaltung - Mail-Graveyard</title>
<link rel="stylesheet" href="/static/style.css?v=20260713-6">
<link rel="stylesheet" href="/static/style.css?v=20260713-7">
<script src="/static/htmx.min.js"></script>
<script src="/static/app.js?v=20260713-6" defer></script></head>
<script src="/static/app.js?v=20260713-7" defer></script></head>
<body class="ol2013">
<header class="ribbon">
<button class="app-menu-button" type="button" aria-label="Mail-Graveyard-Menue" aria-expanded="false" data-backstage-toggle><span class="mail-logo" aria-hidden="true"></span></button>
@ -791,9 +791,9 @@ func renderUsersPage(w http.ResponseWriter, r *http.Request, users []AppUser, ed
fmt.Fprintf(w, `<!doctype html><html lang="de"><head><meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<title>Benutzerverwaltung - Mail-Graveyard</title>
<link rel="stylesheet" href="/static/style.css?v=20260713-6">
<link rel="stylesheet" href="/static/style.css?v=20260713-7">
<script src="/static/htmx.min.js"></script>
<script src="/static/app.js?v=20260713-6" defer></script></head>
<script src="/static/app.js?v=20260713-7" defer></script></head>
<body class="ol2013">
<header class="ribbon">
<button class="app-menu-button" type="button" aria-label="Mail-Graveyard-Menue" aria-expanded="false" data-backstage-toggle><span class="mail-logo" aria-hidden="true"></span></button>
@ -865,9 +865,9 @@ func renderTransferPage(w http.ResponseWriter, r *http.Request, mode transferMod
fmt.Fprintf(w, `<!doctype html><html lang="de"><head><meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<title>%s - Mail-Graveyard</title>
<link rel="stylesheet" href="/static/style.css?v=20260713-6">
<link rel="stylesheet" href="/static/style.css?v=20260713-7">
<script src="/static/htmx.min.js"></script>
<script src="/static/app.js?v=20260713-6" defer></script></head>
<script src="/static/app.js?v=20260713-7" defer></script></head>
<body class="ol2013">
<header class="ribbon">
<button class="app-menu-button" type="button" aria-label="Mail-Graveyard-Menue" aria-expanded="false" data-backstage-toggle><span class="mail-logo" aria-hidden="true"></span></button>
@ -1317,9 +1317,9 @@ func renderSourceEmailBoxPage(w http.ResponseWriter, r *http.Request, accounts [
fmt.Fprintf(w, `<!doctype html><html lang="de"><head><meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<title>Quell-Postfach - Mail-Graveyard</title>
<link rel="stylesheet" href="/static/style.css?v=20260713-6">
<link rel="stylesheet" href="/static/style.css?v=20260713-7">
<script src="/static/htmx.min.js"></script>
<script src="/static/app.js?v=20260713-6" defer></script></head>
<script src="/static/app.js?v=20260713-7" defer></script></head>
<body class="ol2013">
<header class="ribbon">
<button class="app-menu-button" type="button" aria-label="Mail-Graveyard-Menue" aria-expanded="false" data-backstage-toggle><span class="mail-logo" aria-hidden="true"></span></button>
@ -1361,9 +1361,9 @@ func renderTargetEmailBoxPage(w http.ResponseWriter, r *http.Request, accounts [
fmt.Fprintf(w, `<!doctype html><html lang="de"><head><meta charset="utf-8">
<meta name="viewport" content="width=device-width,initial-scale=1">
<title>Ziel-Postfach - Mail-Graveyard</title>
<link rel="stylesheet" href="/static/style.css?v=20260713-6">
<link rel="stylesheet" href="/static/style.css?v=20260713-7">
<script src="/static/htmx.min.js"></script>
<script src="/static/app.js?v=20260713-6" defer></script></head>
<script src="/static/app.js?v=20260713-7" defer></script></head>
<body class="ol2013">
<header class="ribbon">
<button class="app-menu-button" type="button" aria-label="Mail-Graveyard-Menue" aria-expanded="false" data-backstage-toggle><span class="mail-logo" aria-hidden="true"></span></button>

View file

@ -83,9 +83,10 @@
function move(moveEvent) {
const delta = moveEvent.clientX - startX;
const next = start.slice();
const left = Math.max(minWidths[index], start[index] + delta);
const mins = minWidths(container);
const left = Math.max(mins[index], start[index] + delta);
const used = left - start[index];
const right = Math.max(minWidths[index + 1], start[index + 1] - used);
const right = Math.max(mins[index + 1], start[index + 1] - used);
const actual = start[index + 1] - right;
next[index] = start[index] + actual;
next[index + 1] = right;
@ -106,9 +107,12 @@
});
}
window.addEventListener("DOMContentLoaded", () => bind(document.querySelector(".transfer-workbench")));
window.addEventListener("DOMContentLoaded", () => bind(document.querySelector(".four-pane")));
window.addEventListener("DOMContentLoaded", () => bind(document.querySelector(".three-pane")));
function bindAll() {
document.querySelectorAll(".transfer-workbench, .four-pane, .three-pane").forEach(bind);
}
window.addEventListener("DOMContentLoaded", bindAll);
document.addEventListener("htmx:afterSwap", bindAll);
})();
(function () {