How can I disable scrollability on my personal website when the page is loading with the loader wrapper? I have tried using overflow: hidden;
in the CSS but it didn't work. The loader is set to display for 2.5 seconds. Any suggestions on how to achieve this would be greatly appreciated.
You can view my website at this link:
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="utf-8">
<meta name="viewport" content="width=device-width">
<title>Elliott D'Orazio</title>
<link href="style.css" rel="stylesheet" type="text/css" />
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.3.0/css/all.min.css"
integrity="sha512-SzlrxWUlpfuzQ+pcUCosxcglQRNAq/DZjVsC0lE40xsADsfeQoEypE+enwcOiGjk/bSuGGKHEyjSoQ1zVisanQ=="
crossorigin="anonymous" referrerpolicy="no-referrer" />
<meta content="Elliott-D'Orazio" property="og:title" />
<meta content="my amazing portfolio website" property="og:description" />
<script src="script.js" defer></script>
<link rel="apple-touch-icon" sizes="180x180" href="favicon/apple-touch-icon.png">
<link rel="icon" type="image/png" sizes="32x32" href="favicon/favicon-32x32.png">
<link rel="icon" type="image/png" sizes="16x16" href="favicon/favicon-16x16.png">
<link href="https://unpkg.com/<a href="/cdn-cgi/l/email-protection" class="__cf_email__" data-cfemail="accdc3dfec9e829f829d">[email protected]</a>/dist/aos.css" rel="stylesheet">
...
:root{
--accent-color-: #4022d3;
color-scheme: dark light;
--background-white: white;
--background-dark: #222;
}
html:not(.dark) {
--text: white;
--background-color: var(--background-white);
}
html.dark {
--background-color: var( --background-dark);
--text: white;
}
html {
height: 100%;
...
function $(qry){return document.querySelector(qry);}
setTimeout(() => {
$(".loader-wrapper").classList.add("invis")
$(".content").classList.add("vis")
}, 2500)
I am struggling to find a solution to disabling scrolling on my website during the loading phase with the loader. If you have any insights or solutions, please let me know. Thank you for your assistance!