-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathall.js
More file actions
12 lines (10 loc) · 732 Bytes
/
all.js
File metadata and controls
12 lines (10 loc) · 732 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
document.getElementById("c2").innerHTML = '<div class="left"><span>xevalia#8080</span></div><div class="right"><a href="">projects</a><a href="">about</a><a href="">contact</a></div>'
document.getElementById("c1").innerHTML = '<div class="container"><div class="left"><h1>Socials</h1><p>Revvilon</p><p>xevalia#8080</p></div><img src="images/profil.png" alt="face"><div class="right"> <h1>Socials</h1><p>Revvilon</p><p>xevalia#8080</p></div></div>'
document.querySelectorAll('a[href^="#"]').forEach(anchor => {
anchor.addEventListener('click', function (e) {
e.preventDefault();
document.querySelector(this.getAttribute('href')).scrollIntoView({
behavior: 'smooth'
});
});
});