Skip to content

fix: ensure next card resets to term side on navigation#29

Merged
djoseph-apphelix merged 1 commit intomainfrom
fix/TNL2-553
Mar 20, 2026
Merged

fix: ensure next card resets to term side on navigation#29
djoseph-apphelix merged 1 commit intomainfrom
fix/TNL2-553

Conversation

@pganesh-apphelix
Copy link
Contributor

This PR fixes an issue in the Flashcard / Matching Test where, after flipping a card and navigating to the next one, the next card briefly renders on the back side (definition) before flipping to the front (item).

Fix

  • Reset flashcard state on navigation to ensure each new card starts on the front side
  • Ensure consistent initial render behavior across browsers

JIRA

Copilot AI review requested due to automatic review settings March 18, 2026 13:18
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR addresses a UI glitch in the Flashcards experience where navigating to a new card after flipping could briefly render the back side before showing the front, by resetting flip state instantly during navigation.

Changes:

  • Temporarily disable the flip transition when navigating to a new card to ensure an immediate reset to the front side.
  • Add a CSS utility class to suppress transitions on the flashcard inner element.
  • Bump package version from 1.0.12 to 1.0.13.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 2 comments.

File Description
setup.py Bumps the package version to include the fix release.
games/static/js/src/flashcards.js Resets flip state on navigation by disabling transition and forcing reflow before re-enabling.
games/static/css/flashcards.css Adds .no-transition to disable transitions on the inner card element.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

You can also share your feedback on Copilot code review. Take the survey.

@djoseph-apphelix djoseph-apphelix merged commit c1fb960 into main Mar 20, 2026
2 of 4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants