Skip to content

Commit 2f0abe6

Browse files
author
r00ster91
committed
fix: disable search bar before loading
This fixes the new search placeholder not disappearing if you type before it finished loading, and maybe some other things.
1 parent df8cfb1 commit 2f0abe6

File tree

2 files changed

+3
-1
lines changed

2 files changed

+3
-1
lines changed

lib/docs/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -616,7 +616,7 @@ <h2><span>Zig Version</span></h2>
616616
<section class="docs">
617617
<div style="position: relative">
618618
<span id="searchPlaceholder"><kbd>S</kbd> to search, <kbd>?</kbd> for more options</span>
619-
<input type="search" class="search" id="search" autocomplete="off" spellcheck="false">
619+
<input type="search" class="search" id="search" autocomplete="off" spellcheck="false" disabled>
620620
</div>
621621
<p id="status">Loading...</p>
622622
<div id="sectNav" class="hidden"><ul id="listNav"></ul></div>

lib/docs/main.js

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -51,6 +51,8 @@ var zigAnalysis;
5151
let domHelpModal = document.getElementById("helpModal");
5252
const domSearchPlaceholder = document.getElementById("searchPlaceholder");
5353

54+
domSearch.disabled = false;
55+
5456
let searchTimer = null;
5557

5658
let escapeHtmlReplacements = {

0 commit comments

Comments
 (0)