function congratulations(){
     if (matchedCard.length == 16){
         clearInterval(interval);
         finalTime = timer.innerHTML;

         // show congratulations modal
         modal.classList.add("show");

         // declare star rating variable
         var starRating = document.querySelector(".stars").innerHTML;

         //showing move, rating, time on modal
         document.getElementById("finalMove").innerHTML = moves;
         document.getElementById("starRating").innerHTML = starRating;
         document.getElementById("totalTime").innerHTML = finalTime;

         //close icon on modal
         closeModal();
     };
 }
/**
 * @description shows congratulations popup when all cards match, show modal and moves, time and star rating
 */
@description shows congratulations popup when all cards match, show modal and moves, time and star rating
@description shows congratulations popup when all cards match show modal and moves time and star rating
function congratulations(){
     if (matchedCard.length == 16){
         clearInterval(interval);
         finalTime = timer.innerHTML;
         modal.classList.add("show");
         var starRating = document.querySelector(".stars").innerHTML;
         document.getElementById("finalMove").innerHTML = moves;
         document.getElementById("starRating").innerHTML = starRating;
         document.getElementById("totalTime").innerHTML = finalTime;
         closeModal();
     };
 }
function congratulations ( ) { if ( matchedCard . length == 16 ) { clearInterval ( interval ) ; finalTime = timer . innerHTML ; modal . classList . add ( "show" ) ; var starRating = document . querySelector ( ".stars" ) . innerHTML ; document . getElementById ( "finalMove" ) . innerHTML = moves ; document . getElementById ( "starRating" ) . innerHTML = starRating ; document . getElementById ( "totalTime" ) . innerHTML = finalTime ; closeModal ( ) ; } ; }
@description shows congratulations popup when all cards match, show modal and moves, time and star rating
@description shows congratulations popup when all cards match show modal and moves time and star rating
// show congratulations modal // declare star rating variable //showing move, rating, time on modal //close icon on modal