Skip to content

Commit

Permalink
add try again option
Browse files Browse the repository at this point in the history
  • Loading branch information
rmccrear committed Mar 18, 2024
1 parent bfff4c2 commit cd794e0
Show file tree
Hide file tree
Showing 3 changed files with 41 additions and 2 deletions.
31 changes: 31 additions & 0 deletions app/css/partials/instructions.css
Original file line number Diff line number Diff line change
Expand Up @@ -39,8 +39,39 @@
/*elflord green*/
color: #60ff60;
background-color: black;
float: left;
}

.make-your-own a {
padding: 0 1em;
}

.make-your-own.show a:visited {
/*elflord green*/
color: #60ff60;
}

.try-again {
display: none;
}

.try-again a {
padding: 0 1em;
color: #60ff60;
}

.try-again.show {
display: block;
height: 4em;
padding: 1em;
font-family: monaco, Consolas, "Lucida Console", monospace;
font-size: 14px;
font-style: normal;
font-variant: normal;
font-weight: 400;
line-height: 20px;
/*elflord green*/
color: #60ff60;
background-color: black;
float: right;
}
3 changes: 3 additions & 0 deletions app/decode-message.js
Original file line number Diff line number Diff line change
Expand Up @@ -122,6 +122,9 @@ function handleAtLeaf(leafTile) {
}
if (isDone()) {
$(".make-your-own").addClass("show");
if(mistakeCounter > 0){
$(".try-again").addClass("show");
}
}
showGuide(encodedMessage[bitProgressCounter]);
}
Expand Down
9 changes: 7 additions & 2 deletions decode.html
Original file line number Diff line number Diff line change
Expand Up @@ -38,8 +38,13 @@
</div>
<div id="decoded-message"></div>
</div>
<div class="make-your-own">
<a href="writer.html">Create your own message!</a>
<div class="clearfix">
<div class="make-your-own">
<a href="writer.html">Create your own message!</a>
</div>
<div class="try-again">
<a href="javascript:location.reload()"> Try again! </a>
</div>
</div>
</div>
<div id="board"></div>
Expand Down

0 comments on commit cd794e0

Please sign in to comment.