Skip to content

Commit

Permalink
Added winning message. (#266)
Browse files Browse the repository at this point in the history
Added winning message and removed click on the card to start, since
start button is added.

![Screenshot
(23)](https://github.com/Git21221/JS-beginner-projects/assets/75124124/7500e757-be64-4148-adfb-7f6668415847)


#201
  • Loading branch information
Git21221 authored Oct 4, 2023
2 parents 0ba4c92 + f900539 commit 42998f2
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion JavaScript Pairs Game/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
<body>
<div class="wrapper">
<h1>JavaScript pairs Game</h1>
<h3>Click any card to begin</h3>
<h3>Click Start</h3>
<p><span id="seconds">00</span>:<span id="tens">00</span></p>
<p id="text"></p>
<div id="container">
Expand Down
4 changes: 2 additions & 2 deletions JavaScript Pairs Game/script.js
Original file line number Diff line number Diff line change
Expand Up @@ -64,8 +64,8 @@ var check = function (className) {

var win = function () {
if (counter === 5) {
clearInterval(Interval);
text.innerHTML = "Your time was " + seconds + ":" + tens;
clearInterval(Interval);
text.innerHTML = "<big><b>You Won!!</b></big>"+"<br>"+"Your time was " + seconds + ":" + tens;
document.getElementById("restartButton").disabled = false;
}
};
Expand Down

0 comments on commit 42998f2

Please sign in to comment.