Merge pull request #65 from ok2/codex/fix-stuck-animation-issue-in-eonstript-detail-view

This commit is contained in:
Kiyomichi Kosaka
2025-06-20 08:00:28 +02:00
committed by GitHub
+5
View File
@@ -840,6 +840,11 @@ function animateSwipe(direction, onDone) {
const grid = document.getElementById('eonstripGrid'); const grid = document.getElementById('eonstripGrid');
if (!grid) { onDone(); return; } if (!grid) { onDone(); return; }
// Ensure a clean starting state when the grid was previously hidden
grid.style.transition = 'none';
grid.style.transform = 'translateX(0)';
void grid.offsetWidth; // force reflow
// slide out // slide out
grid.style.transition = 'transform 0.3s ease'; grid.style.transition = 'transform 0.3s ease';
grid.style.transform = `translateX(${direction > 0 ? '-100%' : '100%'})`; grid.style.transform = `translateX(${direction > 0 ? '-100%' : '100%'})`;