hilfe eingebaut
This commit is contained in:
1 parent
ae6c818848
commit
836826dba5
6 files changed
+532
-25
No files matched your search
@@ -54,6 +54,18 @@ async function loadCards() {
|
||||
renderBoard();
|
||||
}
|
||||
|
||||
// ── Help ──
|
||||
|
||||
const helpOverlay = document.getElementById('help');
|
||||
function openHelp() { helpOverlay?.classList.add('open'); }
|
||||
function closeHelp() { helpOverlay?.classList.remove('open'); }
|
||||
document.getElementById('help-btn')?.addEventListener('click', openHelp);
|
||||
document.getElementById('help-close')?.addEventListener('click', closeHelp);
|
||||
helpOverlay?.addEventListener('click', e => { if (e.target === helpOverlay) closeHelp(); });
|
||||
document.addEventListener('keydown', e => {
|
||||
if (e.key === 'F1') { e.preventDefault(); helpOverlay?.classList.contains('open') ? closeHelp() : openHelp(); }
|
||||
});
|
||||
|
||||
// ── Export / Import ──
|
||||
|
||||
document.getElementById('export-btn')?.addEventListener('click', () => { window.location.href = 'api/export'; });
|
||||
|
||||
Reference in new issue
Block a user