v6
This commit is contained in:
@@ -562,8 +562,10 @@ document.addEventListener('DOMContentLoaded', function() {
|
||||
// ===== SMOOTH SCROLL FOR INTERNAL LINKS =====
|
||||
document.querySelectorAll('a[href^="#"]').forEach(anchor => {
|
||||
anchor.addEventListener('click', function (e) {
|
||||
const href = this.getAttribute('href');
|
||||
if (!href || href === '#') return;
|
||||
e.preventDefault();
|
||||
const target = document.querySelector(this.getAttribute('href'));
|
||||
const target = document.querySelector(href);
|
||||
if (target) {
|
||||
target.scrollIntoView({
|
||||
behavior: 'smooth',
|
||||
|
||||
Reference in New Issue
Block a user