distribusi-verse/verse/static/js/script.js
2022-03-04 22:15:08 +01:00

26 lines
745 B
JavaScript

console.log("everything is still smooth")
function scrollToTheme() {
var uploadsuccessful = document.getElementById("uploadsuccessful");
if(uploadsuccessful){
const theme = document.getElementById('theme')
theme.scrollIntoView({ behavior: 'smooth', block: 'start' });
}
}
function scrollToLaunch() {
var cssSelected = document.getElementById("cssSelected");
if(cssSelected){
const launch = document.getElementById('launch')
launch.scrollIntoView({ behavior: 'smooth', block: 'end' });
}
}
document.addEventListener("DOMContentLoaded", scrollToTheme);
document.addEventListener("DOMContentLoaded", scrollToLaunch);
// function(e) {
// (e.keyCode === 13 || e.keyCode === 32) && $(this).trigger("click")
// }