Download app/statics/js/footer.js from LifeVta/Grok3API: direct link, hf CLI and curl.
- Browser
- Download file 1.53 kB
-
https://huggingface.co/spaces/LifeVta/Grok3API/resolve/main/app/statics/js/footer.js
- Command line
-
hf download hf://spaces/LifeVta/Grok3API/app/statics/js/footer.js
-
curl -L -o footer.js https://huggingface.co/spaces/LifeVta/Grok3API/resolve/main/app/statics/js/footer.js
1.53 kB
| window.renderSiteFooter = async function renderSiteFooter() { | |
| if (document.querySelector('.site-footer')) return; | |
| let version = ''; | |
| try { | |
| const res = await fetch('/meta', { cache: 'no-store' }); | |
| if (res.ok) { | |
| const data = await res.json(); | |
| version = String(data?.version || '').trim(); | |
| } | |
| } catch {} | |
| const footer = document.createElement('div'); | |
| footer.className = 'site-footer'; | |
| footer.setAttribute('aria-hidden', 'true'); | |
| const link = (text, href) => { | |
| const node = document.createElement('a'); | |
| node.href = href; | |
| node.target = '_blank'; | |
| node.rel = 'noopener'; | |
| node.textContent = text; | |
| return node; | |
| }; | |
| const sep = () => { | |
| const node = document.createElement('span'); | |
| node.textContent = '·'; | |
| return node; | |
| }; | |
| const brand = link('Grok2API', 'https://github.com/jiujiu532/grok2api'); | |
| footer.appendChild(brand); | |
| footer.appendChild(sep()); | |
| const author = link('@Chenyme', 'https://blog.cheny.me/'); | |
| footer.appendChild(author); | |
| footer.appendChild(sep()); | |
| const author2 = link('@jiu', 'https://github.com/jiujiu532'); | |
| footer.appendChild(author2); | |
| document.body.appendChild(footer); | |
| }; | |
| const _bootSiteFooter = () => { | |
| if (typeof window.renderSiteFooter === 'function') { | |
| void window.renderSiteFooter(); | |
| } | |
| }; | |
| if (document.readyState === 'loading') { | |
| document.addEventListener('DOMContentLoaded', _bootSiteFooter, { once: true }); | |
| } else { | |
| _bootSiteFooter(); | |
| } | |
| window.addEventListener('pageshow', _bootSiteFooter); | |