Skip to content

Commit

Permalink
Refactor JavaScript note visibility logic
Browse files Browse the repository at this point in the history
  • Loading branch information
blackstorm committed Jan 3, 2025
1 parent 301d1c4 commit 4e8fcaf
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 5 deletions.
2 changes: 1 addition & 1 deletion server/templates/home.html
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ <h1 class="font-medium">
</h1>
</div>
<div>
<small class="text-gray-300 text-sm">Powered by <a class="hover:underline hover:text-blue-700" target="_blank" href="https://github.com/blackstorm/markdownbrain">MarkdownBrain</a></small>
<small class="text-gray-300 text-xs">Powered by <a class="hover:underline hover:text-blue-700" target="_blank" href="https://github.com/blackstorm/markdownbrain">MarkdownBrain</a></small>
</div>
</header>
<div class="flex grow overflow-x-auto overflow-y-hidden">
Expand Down
7 changes: 4 additions & 3 deletions server/templates/js.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,11 +11,12 @@
for (let i = 0; i < allNotes.length - 1; i++) {
allNotes[i].classList.add("hidden");
}
} else {
for (let i = 0; i < allNotes.length - 1; i++) {
return;
}

for (let i = 0; i < allNotes.length - 1; i++) {
allNotes[i].classList.remove("hidden");
}
}

for (let i = 0; i < allNotes.length - 1; i++) {
const note = allNotes[i];
Expand Down
Loading

0 comments on commit 4e8fcaf

Please sign in to comment.