Skip to content

Commit

Permalink
fix(search bar): show search bar dynamic results on all pages
Browse files Browse the repository at this point in the history
- removes styling from the listBox element
- changes styling on its parent, the chantsDiv element
  • Loading branch information
dchiller committed Jun 14, 2024
1 parent e50b82f commit 5cee181
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,4 +11,4 @@
</div>
</form>
<!--The chants returned by the ajax call go here-->
<div id="chantsDiv" style="position:relative"></div>
<div id="chantsDiv" style="position:absolute; z-index:1"></div>
2 changes: 1 addition & 1 deletion django/cantusdb_project/static/js/search_bar.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ function globalSearch() {
xhttp.onload = function () {
const data = JSON.parse(this.response);
// the results are to be displayed in a list-group
chantsDiv.innerHTML = `<div class="list-group" id="listBox" style="position:absolute; z-index:1"></div>`;
chantsDiv.innerHTML = `<div class="list-group" id="listBox"></div>`;
const listBox = document.getElementById("listBox");
// for every chant returned in the JSONResponse
data.chants.map(chant => {
Expand Down

0 comments on commit 5cee181

Please sign in to comment.