fix: add top breathing room for current card

This commit is contained in:
ittoview
2026-05-11 10:03:43 +01:00
parent 2821d21221
commit ade0c6fd6b

View File

@@ -228,7 +228,7 @@ export default function ProcessPurposePracticePage() {
const deckTop = deck.getBoundingClientRect().top
const cardTop = currentCard.getBoundingClientRect().top
const targetTop = Math.max(deck.scrollTop + cardTop - deckTop - 12, 0)
const targetTop = Math.max(deck.scrollTop + cardTop - deckTop - 32, 0)
currentScrollLimitRef.current = targetTop
deck.scrollTo({ top: targetTop, behavior: 'smooth' })
})