Skip to content

Commit

Permalink
Fix download formatting.
Browse files Browse the repository at this point in the history
  • Loading branch information
Intrinsically-Sublime committed Apr 23, 2024
1 parent d2e3ebb commit 840feef
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 16 deletions.
10 changes: 4 additions & 6 deletions 2d-gaps-mapper.css
Original file line number Diff line number Diff line change
Expand Up @@ -94,12 +94,10 @@
padding-left: 0.25em;
}

.downloadBox {
float: left;
text-align: right;
width: 10em;
display: block;
margin: 0.5em;
.button {
font-size: 1em;
height: 1.65em;
line-height: 1.5em;
}

.ledGrid {
Expand Down
2 changes: 1 addition & 1 deletion 2d-gaps-mapper.js
Original file line number Diff line number Diff line change
Expand Up @@ -20,7 +20,7 @@ function download(){
document.createElement("a")
);
a.download = "2d-gaps.json";
a.href = "data:text/html," + document.getElementById("result").innerHTML; // Grab the HTML
a.href = "data:text/html," + document.getElementById("result").innerText; // Grab the HTML
a.click(); // Trigger a click on the element
}

Expand Down
20 changes: 11 additions & 9 deletions index.html
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ <h3>How to use</h3>
<label for="clearAllCHK">Start empty</label>
</div>
<div class="buildBox">
<button id="rebuildArray" onclick="buildGrid()">Rebuild</button>
<button class="button" id="rebuildArray" onclick="buildGrid()">Rebuild</button>
</div>
</ul>
</div>
Expand All @@ -60,14 +60,16 @@ <h3>How to use</h3>
</div>
</ul>
</div>
<div class="buttonBox">
<br>
<br>
<ul>
<div class="downloadBox">
<button id="downloadFile" onclick="download()">Download</button>
</div>
</ul>
<div class="optionBox">
<br>
<ul>
<div class="buildBox">
<br><br>
</div>
<div class="buildBox">
<button class="button" id="downloadFile" onclick="download()">Download</button>
</div>
</ul>
</div>
</div>

Expand Down

0 comments on commit 840feef

Please sign in to comment.