CoolFace
Apppublic

SanadaKazuma/sql-secure-portal

sourceHugging Faceupdated 11mo agoView on Hugging Face
0likes
script.js19 linesDownload Raw Back to root
1document.addEventListener('DOMContentLoaded', function() {2    // Mobile menu toggle3    const mobileMenuButton = document.querySelector('[aria-controls="mobile-menu"]');4    const mobileMenu = document.getElementById('mobile-menu');5    6    if (mobileMenuButton && mobileMenu) {7        mobileMenuButton.addEventListener('click', function() {8            const expanded = this.getAttribute('aria-expanded') === 'true';9            this.setAttribute('aria-expanded', !expanded);10            mobileMenu.classList.toggle('hidden');11            12            // Change icon13            const icon = this.querySelector('i');14            if (icon) {15                if (expanded) {16                    icon.setAttribute('data-feather', 'menu');17                } else {18                    icon.setAttribute('data-feather', 'x');19                }