This commit is contained in:
2026-04-25 16:44:08 +09:00
parent 9d61a19a6e
commit 5a2c2629da
3 changed files with 61 additions and 27 deletions
+4 -4
View File
@@ -46,14 +46,14 @@
function onTap() {
tapCount++;
if (tapCount >= 10) {
if (tapCount >= 3) {
clearTimeout(tapTimer);
tapCount = 0;
location.href = '/qr-code/';
typeof window.__navigate === 'function' ? window.__navigate('/qr-code/') : (location.href = '/qr-code/');
return;
}
clearTimeout(tapTimer);
tapTimer = setTimeout(() => { tapCount = 0; }, 1500);
tapTimer = setTimeout(() => { tapCount = 0; }, 400);
}
el.addEventListener('touchend', (e) => {
@@ -63,7 +63,7 @@
}, { passive: false });
el.addEventListener('click', () => {
if (Date.now() - lastTouch < 1400) return;
if (Date.now() - lastTouch < 300) return;
onTap();
});
})();