From 7b6dd96d68cb056e16c2252f5ecdfe6ef5dbd17c Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mateusz=20Gruszczy=C5=84ski?= Date: Fri, 29 Aug 2025 22:08:11 +0200 Subject: [PATCH] poprawki --- static/js/error.js | 16 ---------------- static/js/main.js | 1 - templates/error.html | 3 +-- 3 files changed, 1 insertion(+), 19 deletions(-) diff --git a/static/js/error.js b/static/js/error.js index 671f510..3d046c5 100644 --- a/static/js/error.js +++ b/static/js/error.js @@ -1,25 +1,9 @@ (function () { const t = localStorage.getItem('theme') || 'dark'; document.documentElement.setAttribute('data-theme', t); - // prosty "try again" document.querySelector('[data-action="try-again"]')?.addEventListener('click', () => { location.reload(); }); - // kopiowanie logs - document.querySelector('[data-action="copy-text"]')?.addEventListener('click', (e) => { - const sel = e.currentTarget.getAttribute('data-target'); - const el = sel && document.querySelector(sel); - if (!el) return; - const txt = el.textContent || ''; - navigator.clipboard.writeText(txt).then(() => { - const toast = document.getElementById('toast'); - if (toast) { - toast.textContent = 'Copied!'; - toast.classList.add('show'); - setTimeout(() => toast.classList.remove('show'), 1200); - } - }); - }); })(); diff --git a/static/js/main.js b/static/js/main.js index e1c0a44..86b44c3 100644 --- a/static/js/main.js +++ b/static/js/main.js @@ -248,7 +248,6 @@ const expanded = btn.getAttribute('aria-expanded') === 'true'; panel.hidden = !expanded; - // usuń/ustaw inline display spójnie z hidden panel.style.display = expanded ? '' : 'none'; const label = expanded ? 'Collapse' : 'Expand'; diff --git a/templates/error.html b/templates/error.html index 53ec862..0c9ffc6 100644 --- a/templates/error.html +++ b/templates/error.html @@ -65,8 +65,7 @@ user_ip: {{ request.remote_addr if request else '' }} user_agent: {{ request.headers.get('User-Agent') if request else '' }}
- +