Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions app.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,7 @@ const splash = document.querySelector('#splash');
const app = document.querySelector('#app');
const content = document.querySelector('#content');
const versionEl = document.querySelector('#splash-version');
let appVersion = '1.2';
const menuButton = document.querySelector('.options-button');
const optionsMenu = document.querySelector('#options-menu');
const homeLogoBtn = document.querySelector('#homeLogoBtn');
Expand Down Expand Up @@ -564,14 +565,14 @@ function openAppModal(kind){
? `<h2>Opcje</h2><p>EasyTune działa offline po pierwszym uruchomieniu.${isPwaInstalled() ? ' Aplikacja jest już uruchomiona jako zainstalowane PWA.' : ' Aby działała jako pełne PWA, wybierz „Zainstaluj aplikację”, a nie „Dodaj skrót”.'}</p>${installMarkup}`
: kind === 'transpose-result'
? '<h2>Wynik transpozycji</h2><p>Kliknij dowolny akord w oknie wyniku, aby otworzyć powiększony diagram tego chwytu.</p>'
: '<h2>EasyTune</h2><p>Transpozycja, akordy i metronom. Wersja PWA offline 1.2.</p>';
: `<h2>EasyTune</h2><p>Transpozycja, akordy i metronom. Wersja PWA offline ${appVersion}.</p>`;
appModal.classList.add('visible'); appModal.setAttribute('aria-hidden','false');
syncInstallButtons();
}
function closeAppModal(){ if(!appModal) return; appModal.classList.remove('visible'); appModal.setAttribute('aria-hidden','true'); }

async function loadManifestVersion(){
try{ const res = await fetch('manifest.webmanifest', {cache:'no-store'}); const m = await res.json(); versionEl.textContent = `v${m.version || '1.2'}`; } catch { versionEl.textContent = 'v1.2'; }
try{ const res = await fetch('manifest.webmanifest', {cache:'no-store'}); const m = await res.json(); appVersion = m.version || '1.2'; versionEl.textContent = `v${appVersion}`; } catch { versionEl.textContent = `v${appVersion}`; }
}
function showApp(){ app.hidden = false; renderView('home'); setTimeout(()=>splash.classList.add('is-hidden'), 850); setTimeout(()=>splash.remove(), 1300); }

Expand Down
Loading