Add search functionality

This commit is contained in:
2021-11-01 21:34:22 -04:00
parent 2ed3e02630
commit 6885daafe9
4 changed files with 153 additions and 53 deletions

View File

@ -2,3 +2,16 @@
// for details on configuring this project to bundle and minify static web assets.
// Write your JavaScript code.
const searchButton = document.getElementById('search-button');
const searchInput = document.getElementById('search-input');
searchButton.addEventListener('click', () => {
const inputValue = searchInput.value;
window.location.href = "/?handler=search&query=" + inputValue;
});
// Menu Toggle Script
$("#menu-toggle").click(function (e) {
e.preventDefault();
$("#wrapper").toggleClass("toggled");
});