GPTfree api commited on
Commit
9d4076c
·
verified ·
1 Parent(s): 7cf1d68

Update index.html

Browse files
Files changed (1) hide show
  1. index.html +1 -1
index.html CHANGED
@@ -1 +1 @@
1
- <!DOCTYPE html><html lang=ja><head><meta charset=UTF-8><title>モデル一覧</title><style>.tile-container{display:flex;flex-wrap:wrap;gap:10px}.tile{cursor:pointer;border:1px solid #ccc;border-radius:8px;overflow:hidden;width:200px;text-align:center;box-shadow:0 2px 5px rgba(0,0,0,.1)}.tile img{width:100%;height:auto}.tile .info{padding:10px}.tile .info .version{font-weight:700}</style></head><body><h1>モデル一覧</h1><div class=tile-container></div><script>const jsonUrl="model.json";async function fetchAndDisplayModels(){try{const e=await fetch(jsonUrl),t=await e.json(),n=document.querySelector(".tile-container");t.model_data.forEach((e=>{const[t,a,c,o]=e,d=document.createElement("div");d.className="tile",d.addEventListener("click",(e=>{navigator.clipboard.writeText(c).then((()=>{alert(URLがクリップボードにコピーされました: ${c})})).catch((e=>{console.error("URLのコピーに失敗しました:",e)}))}));const s=document.createElement("img");s.src=o,s.alt=a;const l=document.createElement("div");l.className="info";const r=document.createElement("div");r.className="version",r.textContent=バージョン: ${t};const i=document.createElement("div");i.className="name",i.textContent=名前: ${a},l.appendChild(r),l.appendChild(i),d.appendChild(s),d.appendChild(l),n.appendChild(d)}))}catch(e){console.error("JSONデータの取得または処理中にエラーが発生しました:",e)}}document.addEventListener("DOMContentLoaded",fetchAndDisplayModels)</script></body></html>
 
1
+ <!DOCTYPE html><html lang=ja><head><meta charset=UTF-8><title>モデル一覧</title><style>.tile-container{display:flex;flex-wrap:wrap;gap:10px}.tile{cursor:pointer;border:1px solid #ccc;border-radius:8px;overflow:hidden;width:200px;text-align:center;box-shadow:0 2px 5px rgba(0,0,0,.1)}.tile img{width:100%;height:auto}.tile .info{padding:10px}.tile .info .version{font-weight:700}</style></head><body><h1>モデル一覧</h1><div class=tile-container></div><script>const jsonUrl="https://huggingface.co/spaces/GPT-free-api/genshin-models/raw/main/model.json";async function fetchAndDisplayModels(){try{const e=await fetch(jsonUrl),t=await e.json(),n=document.querySelector(".tile-container");t.model_data.forEach((e=>{const[t,a,c,o]=e,d=document.createElement("div");d.className="tile",d.addEventListener("click",(e=>{navigator.clipboard.writeText(c).then((()=>{alert(URLがクリップボードにコピーされました: ${c})})).catch((e=>{console.error("URLのコピーに失敗しました:",e)}))}));const s=document.createElement("img");s.src=o,s.alt=a;const l=document.createElement("div");l.className="info";const r=document.createElement("div");r.className="version",r.textContent=バージョン: ${t};const i=document.createElement("div");i.className="name",i.textContent=名前: ${a},l.appendChild(r),l.appendChild(i),d.appendChild(s),d.appendChild(l),n.appendChild(d)}))}catch(e){console.error("JSONデータの取得または処理中にエラーが発生しました:",e)}}document.addEventListener("DOMContentLoaded",fetchAndDisplayModels)</script></body></html>