focus input element on loading
This commit is contained in:
parent
17a6953716
commit
c3e1d80b8f
@ -13,6 +13,7 @@
|
||||
<h2 class="phrases"></h2>
|
||||
<img als="girl_juice" src="assets/girl_juice.png" />
|
||||
</div>
|
||||
|
||||
<input name="{{ .SearchInputName }}" type="text" class="grid-item" class="search" placeholder="{{ .SearchPlaceholder }}" />
|
||||
|
||||
<div class="cards" id="stores">
|
||||
@ -57,6 +58,14 @@
|
||||
titleChanger(element);
|
||||
})
|
||||
|
||||
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
Array.from(document.querySelectorAll('input')).forEach(element => {
|
||||
console.log(element)
|
||||
element.focus();
|
||||
})
|
||||
});
|
||||
|
||||
document.addEventListener('DOMContentLoaded', function() {
|
||||
const marqueeElement = document.body;
|
||||
let xPosition = 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user