From e7e042f3c71e63d6ecad9c4ff5f9e8906efbcea6 Mon Sep 17 00:00:00 2001 From: lelo Date: Mon, 24 Mar 2025 19:15:40 +0100 Subject: [PATCH] autoupdate index and autoplay new files --- static/app.css | 12 ++++-- static/app.js | 91 ++++++++++++++++++++++++++----------------- static/audioplayer.js | 63 ++++++++---------------------- static/sw.js | 12 ++++-- templates/app.html | 10 +++-- 5 files changed, 94 insertions(+), 94 deletions(-) diff --git a/static/app.css b/static/app.css index b4b64da..969105c 100644 --- a/static/app.css +++ b/static/app.css @@ -8,13 +8,14 @@ html, body { body { font-family: 'Helvetica Neue', Arial, sans-serif; background-color: #f4f7f9; - padding: 0; + padding-top: 70px; /* Adjust to your header height */ color: #333; } /* Header styles */ .site-header { - position: sticky; + position: fixed; top: 0; + width: 94%; z-index: 1000; display: flex; align-items: center; @@ -52,7 +53,7 @@ body { /* Breadcrumb Styles */ .breadcrumb { margin-bottom: 15px; - font-size: 18px; + font-size: 22px; } .breadcrumb a { text-decoration: none; @@ -64,6 +65,11 @@ body { margin-right: 5px; } +.separator::before { + content: "\A"; /* Inserts a line break */ + white-space: pre; /* Ensures the newline is honored */ +} + /* List Styles */ ul { list-style-type: none; diff --git a/static/app.js b/static/app.js index 6c352aa..37a76d9 100644 --- a/static/app.js +++ b/static/app.js @@ -22,7 +22,7 @@ function renderContent(data) { data.breadcrumbs.forEach((crumb, index) => { breadcrumbHTML += `${crumb.name}`; if (index < data.breadcrumbs.length - 1) { - breadcrumbHTML += `>`; + breadcrumbHTML += `​>`; } }); document.getElementById('breadcrumbs').innerHTML = breadcrumbHTML; @@ -50,6 +50,7 @@ function renderContent(data) { } // Render files. + currentMusicFiles = []; // Reset the music files array. if (data.files.length > 0) { contentHTML += '