Spaces:
Running
Running
Download script.js from wolmarsh/spreadsheet-sparkler: direct link, hf CLI and curl.
- Browser
- Download file 937 Bytes
-
https://huggingface.co/spaces/wolmarsh/spreadsheet-sparkler/resolve/main/script.js
- Command line
-
hf download hf://spaces/wolmarsh/spreadsheet-sparkler/script.js
-
curl -L -o script.js https://huggingface.co/spaces/wolmarsh/spreadsheet-sparkler/resolve/main/script.js
937 Bytes
| document.addEventListener('DOMContentLoaded', function() { | |
| // Smooth scroll for anchor links | |
| document.querySelectorAll('a[href^="#"]').forEach(anchor => { | |
| anchor.addEventListener('click', function (e) { | |
| e.preventDefault(); | |
| document.querySelector(this.getAttribute('href')).scrollIntoView({ | |
| behavior: 'smooth' | |
| }); | |
| }); | |
| }); | |
| // Google Sheets API integration would go here | |
| // This is just a placeholder for the actual implementation | |
| function connectToGoogleSheets() { | |
| console.log('Connecting to Google Sheets API...'); | |
| // Actual implementation would use Google Sheets API | |
| } | |
| // Initialize tooltips | |
| const tooltipTriggerList = [].slice.call(document.querySelectorAll('[data-bs-toggle="tooltip"]')); | |
| tooltipTriggerList.map(function (tooltipTriggerEl) { | |
| return new bootstrap.Tooltip(tooltipTriggerEl); | |
| }); | |
| }); |