Spaces:
Running
Running
i want a app for health care branding of medsdoor company colour is red and blue but you can use white or black also the motive of company is to deliver medicine in minutes and lab test in it and all working is multivendor its mean delivery panel admin panel and user panelalso intregated
579f9e1 verified Download script.js from datads/medsdoor-expressrx: direct link, hf CLI and curl.
- Browser
- Download file 1.53 kB
-
https://huggingface.co/spaces/datads/medsdoor-expressrx/resolve/main/script.js
- Command line
-
hf download hf://spaces/datads/medsdoor-expressrx/script.js
-
curl -L -o script.js https://huggingface.co/spaces/datads/medsdoor-expressrx/resolve/main/script.js
1.53 kB
| // Theme toggle functionality | |
| document.addEventListener('DOMContentLoaded', () => { | |
| // Check for saved theme preference or use system preference | |
| const savedTheme = localStorage.getItem('theme') || | |
| (window.matchMedia('(prefers-color-scheme: dark)').matches ? 'dark' : 'light'); | |
| document.documentElement.classList.add(savedTheme); | |
| // Update theme toggle button state | |
| const themeToggle = document.getElementById('theme-toggle'); | |
| if (themeToggle) { | |
| themeToggle.checked = savedTheme === 'dark'; | |
| } | |
| }); | |
| function toggleTheme() { | |
| const html = document.documentElement; | |
| const isDark = html.classList.contains('dark'); | |
| if (isDark) { | |
| html.classList.remove('dark'); | |
| localStorage.setItem('theme', 'light'); | |
| } else { | |
| html.classList.add('dark'); | |
| localStorage.setItem('theme', 'dark'); | |
| } | |
| } | |
| // Smooth scrolling for anchor links | |
| document.querySelectorAll('a[href^="#"]').forEach(anchor => { | |
| anchor.addEventListener('click', function (e) { | |
| e.preventDefault(); | |
| document.querySelector(this.getAttribute('href')).scrollIntoView({ | |
| behavior: 'smooth' | |
| }); | |
| }); | |
| }); | |
| // Initialize panel animations | |
| document.addEventListener('DOMContentLoaded', () => { | |
| const panels = document.querySelectorAll('.panel-card'); | |
| panels.forEach((panel, index) => { | |
| panel.style.setProperty('--order', index); | |
| }); | |
| // Initialize Feather icons | |
| if (window.feather) { | |
| feather.replace(); | |
| } | |
| }); | |