diff --git a/.nojekyll b/.nojekyll new file mode 100644 index 00000000..e69de29b diff --git a/assets/editor-O8LiZDmY.js b/assets/editor-O8LiZDmY.js new file mode 100644 index 00000000..b629e38d --- /dev/null +++ b/assets/editor-O8LiZDmY.js @@ -0,0 +1 @@ +import{R as s,a as O,A as m,s as w,S as j,L as g,t as G,j as e,O as I,C as L,D as E,p as V,b as A,c as B,U as M}from"./index-o0wXbvYb.js";import{c as D}from"./gistapi-Ypf6w1t3.js";import{l as H}from"./lrc-file-name-sR0E2KGQ.js";const c={autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",spellCheck:!1},d=(a,l)=>{const t=((n,p)=>n??p)(l,s.useRef(null));return s.useEffect(()=>{t.current&&(t.current.value=a)},[a,t]),{ref:t,defaultValue:a}},$=({lrcState:a,lrcDispatch:l})=>{const{prefState:f,lang:t,trimOptions:n}=s.useContext(O),p=s.useCallback(o=>{l({type:m.parse,payload:{text:o.target.value,options:n}})},[l,n]),b=s.useCallback(o=>{const{name:i,value:U}=o.target;l({type:m.info,payload:{name:i,value:U}})},[l]),C=w(a,f),x=s.useRef(null),y=s.useCallback(()=>{sessionStorage.setItem(j.editorDetailsOpen,x.current.open.toString())},[]),k=s.useMemo(()=>sessionStorage.getItem(j.editorDetailsOpen)!=="false",[]),r=s.useRef(null),[F,R]=s.useState(void 0),S=s.useCallback(()=>{R(o=>(o&&URL.revokeObjectURL(o),URL.createObjectURL(new Blob([r.current.value],{type:"text/plain;charset=UTF-8"}))))},[]),T=s.useCallback(o=>{if(o.target.files===null||o.target.files.length===0)return;const i=new FileReader;i.addEventListener("load",()=>{l({type:m.parse,payload:{text:i.result,options:n}})}),i.readAsText(o.target.files[0],"UTF-8")},[l,n]),v=s.useCallback(()=>{var o;(o=r.current)==null||o.select(),document.execCommand("copy")},[]),u=s.useMemo(()=>H(a.info),[a.info]),h=s.useMemo(()=>localStorage.getItem(g.token)!==null&&localStorage.getItem(g.gistId)!==null,[]),N=s.useCallback(()=>{setTimeout(()=>{const o=prompt(t.editor.saveFileName,u);o&&D(o,r.current.value).catch(i=>{G.pub({type:"warning",text:i.message})})},500)},[u,t]);return e.jsxs("div",{className:"app-editor",children:[e.jsxs("details",{ref:x,open:k,onToggle:y,children:[e.jsx("summary",{children:t.editor.metaInfo}),e.jsxs("section",{className:"app-editor-infobox",onBlur:b,children:[e.jsx("label",{htmlFor:"info-ti",children:"[ti:"}),e.jsx("input",{id:"info-ti",name:"ti",placeholder:t.editor.title,...c,...d(a.info.get("ti")||"")}),e.jsx("label",{htmlFor:"info-ti",children:"]"}),e.jsx("label",{htmlFor:"info-ar",children:"[ar:"}),e.jsx("input",{id:"info-ar",name:"ar",placeholder:t.editor.artist,...c,...d(a.info.get("ar")||"")}),e.jsx("label",{htmlFor:"info-ar",children:"]"}),e.jsx("label",{htmlFor:"info-al",children:"[al:"}),e.jsx("input",{id:"info-al",name:"al",placeholder:t.editor.album,...c,...d(a.info.get("al")||"")}),e.jsx("label",{htmlFor:"info-al",children:"]"})]})]}),e.jsxs("section",{className:"editor-tools",children:[e.jsxs("label",{className:"editor-tools-item ripple",title:t.editor.uploadText,children:[e.jsx("input",{hidden:!0,type:"file",accept:"text/*, .txt, .lrc",onChange:T}),e.jsx(I,{})]}),e.jsx("button",{className:"editor-tools-item ripple",title:t.editor.copyText,onClick:v,children:e.jsx(L,{})}),e.jsx("a",{className:"editor-tools-item ripple",title:t.editor.downloadText,href:F,onClick:S,download:u,children:e.jsx(E,{})}),e.jsx("a",{title:t.editor.saveToGist,href:h?void 0:V(A.gist),className:"editor-tools-item ripple",onClick:h?N:void 0,children:e.jsx(B,{})}),e.jsx("a",{title:t.editor.utils,href:"/lrc-utils/",className:"editor-tools-item ripple",children:e.jsx(M,{})})]}),e.jsx("textarea",{className:"app-textarea","aria-label":"lrc input here",onBlur:p,...c,...d(C,r)})]})};export{$ as Eidtor}; diff --git a/assets/en-US-zc2O-JdV.js b/assets/en-US-zc2O-JdV.js new file mode 100644 index 00000000..5f91436f --- /dev/null +++ b/assets/en-US-zc2O-JdV.js @@ -0,0 +1 @@ +const e={languageName:"English",app:{name:"LRC Maker",fullname:"Akari's LRC Maker"},header:{home:"home",editor:"editor",synchronizer:"synchronizer",gist:"Github Gist",preferences:"preferences"},audio:{loadAudio:"load audio",play:"play",pause:"pause",replay5s:"replay 5s",forward5s:"forward 5s",resetRate:"reset playback rate",error:["audio error","audio aborted by user","audio network error","audio decoding error","audio not supported"]},loadAudio:{file:"File",url:"URL",loadFile:"Click here or drop audio file in this page"},home:{tips:"Tips",tipForLyricText:"Navigate to the editor page and paste lyric text.",tipForUploadAudio:"Click the bottom left button to load audio file.",tipForSynchronizer:"Navigate to synchronizer page and make your lrc :)",tipTopLeft:"Click here come back to this page",tipTopRight:"Click here to navigate to other page",tipBottomLeft:"load audio here, and control the audio",tipBottomRight:"change the playback rate here"},editor:{metaInfo:"meta info",album:"album",title:"title",artist:"artist",uploadText:"upload text",copyText:"select all and copy",downloadText:"download",saveToGist:"save to Github Gist",saveFileName:"Filename",utils:"lrc utils"},gist:{newTokenTip:"LRC Maker use Github Token to fetch and store data to Github Gist",newTokenButton:"Generate a new Github Token",newGistTip:"Create a new Gist repository or assign an existing Gist id",newGistRepoButton:"Create a new Gist Repository",gistIdPlaceholder:"Or assign an existing Gist id",info:"info",clearTokenAndGist:"Clear token and Gist id"},preferences:{version:"Version",commitHash:"Commit hash",updateTime:"Update time",repo:"Repository",help:"Help & tips",language:"Language",builtInAudio:"Use browser built-in audio player",spaceButton:"On-screen space key",themeColor:"Theme color",lrcFormat:"Change output format",fixed:"Timestamp fixed",leftSpace:"Left space",rightSpace:"Right space",clearCache:"Clear caches",themeMode:{label:"Theme Mode",auto:"auto",light:"light",dark:"dark"}},notify:{audioLoaded:"Audio loaded."}};export{e as default}; diff --git a/assets/gist-i1907ujF.js b/assets/gist-i1907ujF.js new file mode 100644 index 00000000..1fed60cc --- /dev/null +++ b/assets/gist-i1907ujF.js @@ -0,0 +1 @@ +import{R as n,a as _,L as u,S as B,t as g,A as G,j as e,G as C,n as q,o as z,p as T,b as L,E as J,q as P}from"./index-o0wXbvYb.js";import{a as V,b as H,g as K,G as R,d as U}from"./gistapi-Ypf6w1t3.js";const W="https://github.com/settings/tokens/new?scopes=gist&description=https://lrc-maker.github.io",F={autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",spellCheck:!1},Y=({lrcDispatch:p,langName:k})=>{const{lang:i,trimOptions:h}=n.useContext(_),[m,j]=n.useState(()=>localStorage.getItem(u.token)),[l,x]=n.useState(()=>localStorage.getItem(u.gistId)),[f,v]=n.useState(void 0),[o,O]=n.useState(()=>JSON.parse(localStorage.getItem(u.gistFile))),d=n.useMemo(()=>JSON.parse(sessionStorage.getItem(B.ratelimit)),[]),b=n.useCallback(t=>{t.preventDefault();const r=t.target.elements.namedItem("token").value;localStorage.setItem(u.token,r),j(r)},[]),N=n.useCallback(()=>{V().then(t=>{localStorage.setItem(u.gistId,t.id),x(t.id)}).catch(t=>{g.pub({type:"warning",text:t.message})})},[]),I=n.useCallback(t=>{t.preventDefault();const r=t.target.elements.namedItem("gist-id").value;localStorage.setItem(u.gistId,r),x(r),H().catch(c=>{g.pub({type:"warning",text:c.message})})},[]);n.useEffect(()=>{l!==null||m===null||"HTMLDataListElement"in window&&K().then(t=>{v(t.filter(s=>s.description===R.description&&R.fileName in s.files).map(({id:s})=>s))}).catch(t=>{g.pub({type:"warning",text:t.message})})},[m,l]),n.useEffect(()=>{l!==null&&U().then(t=>{if(t===null)return;const s=Object.values(t.files).filter(a=>a.filename.endsWith(".lrc"));localStorage.setItem(u.gistFile,JSON.stringify(s,["filename","content","truncated","raw_url"])),O(s)}).catch(t=>{g.pub({type:"warning",text:t.message})})},[l]);const w=n.useCallback(t=>{const s=t.target;if(!("key"in s.dataset))return;const a=Number.parseInt(s.dataset.key,10),r=o==null?void 0:o[a];r&&(r.truncated?fetch(r.raw_url).then(async c=>c.text()).then(c=>{p({type:G.parse,payload:{text:c,options:h}})}).catch(c=>{g.pub({type:"warning",text:c.message})}):p({type:G.parse,payload:{text:r.content,options:h}}))},[o,p,h]),S=n.useCallback(()=>{x(null),j(null)},[]),y=n.useMemo(()=>{if(d===null)return!1;const t=new Intl.DateTimeFormat(k,{year:"numeric",month:"short",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",hour12:!1}).format(new Date(Number.parseInt(d["x-ratelimit-reset"],10)*1e3));return e.jsxs("section",{className:"ratelimit",children:[e.jsxs("p",{children:["ratelimit-limit: ",d["x-ratelimit-limit"]]}),e.jsxs("p",{children:["ratelimit-remaining: ",d["x-ratelimit-remaining"]]}),e.jsxs("p",{children:["ratelimit-reset: ",t]})]})},[d,k]),E=n.useCallback(()=>l!==null&&m!==null?e.jsxs("details",{className:"gist-details",children:[e.jsx("summary",{children:i.gist.info}),e.jsxs("section",{className:"gist-bar",children:[e.jsxs("section",{className:"gist-info",children:[e.jsxs("p",{children:["Gist id: ",e.jsx("a",{href:`https://gist.github.com/${l}`,target:"_blank",rel:"noopener noreferrer",className:"link",children:l})]}),e.jsx("button",{className:"button",onClick:S,children:i.gist.clearTokenAndGist})]}),y]})]}):null,[l,m,i.gist.info,i.gist.clearTokenAndGist,S,y]),A=n.useMemo(()=>{if(m===null)return e.jsxs("section",{className:"new-token",children:[e.jsx(C,{}),e.jsx("p",{className:"new-token-tip-text",children:i.gist.newTokenTip}),e.jsx("a",{className:"new-token-tip button",target:"_blank",rel:"noopener noreferrer",href:W,children:i.gist.newTokenButton}),e.jsxs("form",{className:"new-token-form",onSubmit:b,children:[e.jsx("label",{htmlFor:"github-token",children:"Token:"}),e.jsx("input",{type:"text",className:"new-token-input",id:"github-token",name:"token",minLength:40,maxLength:40,required:!0,...F},"token"),e.jsx("input",{className:"new-token-submit button",type:"submit"})]})]})},[m,i.gist.newTokenTip,i.gist.newTokenButton,b]),D=n.useMemo(()=>{if(l===null){const t=a=>e.jsx("option",{value:a},a),s=f&&e.jsxs("datalist",{id:"gist-list",children:[f.map(a=>t(a)),";"]});return e.jsxs("section",{className:"get-gist-id",children:[e.jsx(C,{}),e.jsx("p",{className:"gist-id-tip-text",children:i.gist.newGistTip}),e.jsx("button",{className:"create-new-gist button",onClick:N,children:i.gist.newGistRepoButton}),e.jsxs("form",{className:"gist-id-form",onSubmit:I,children:[e.jsx("label",{htmlFor:"gist-id",children:"Gist id:"}),e.jsx("input",{type:"text",className:"gist-id-input",id:"gist-id",name:"gist-id",list:"gist-list",placeholder:i.gist.gistIdPlaceholder,required:!0,...F},"gist-id"),e.jsx("input",{className:"button",type:"submit"}),s]})]})}},[l,f,i.gist.newGistTip,i.gist.newGistRepoButton,i.gist.gistIdPlaceholder,N,I]),M=n.useMemo(()=>{if(o!==null){const t=(s,a)=>e.jsxs("article",{className:"file-item",children:[e.jsx("section",{className:"file-content",children:s.content}),e.jsx("hr",{}),e.jsxs("section",{className:"file-bar",children:[e.jsx("span",{className:"file-title",children:s.filename}),e.jsxs("span",{className:"file-action",children:[e.jsx("a",{className:"file-load",href:T(L.editor),"data-key":a,children:e.jsx(J,{})}),e.jsx("a",{className:"file-load",href:T(L.synchronizer),"data-key":a,children:e.jsx(P,{})})]})]})]},s.raw_url);return o.length===0?e.jsx("section",{className:"gist-no-data",children:e.jsx(q,{})}):e.jsx("section",{className:"file-list",onClick:w,children:o.map(t)})}},[o,w]);return e.jsxs("div",{className:"gist",children:[e.jsx(E,{}),A||D||M||e.jsx($,{})]})},$=()=>e.jsx("section",{className:"gist-loading",children:e.jsx(z,{})});export{Y as Gist}; diff --git a/assets/gistapi-Ypf6w1t3.js b/assets/gistapi-Ypf6w1t3.js new file mode 100644 index 00000000..5bc18987 --- /dev/null +++ b/assets/gistapi-Ypf6w1t3.js @@ -0,0 +1 @@ +import{L as o,S as c}from"./index-o0wXbvYb.js";const a={description:"https://lrc-maker.github.io",fileName:".lrc-maker",fileContent:"This file is used to be tracked and identified by https://lrc-maker.github.io"},n="https://api.github.com/gists",g=async()=>{const s=localStorage.getItem(o.token),t=await fetch(n,{method:"GET",headers:{Authorization:`token ${s}`},mode:"cors"});if(!t.ok)throw new Error(t.statusText);return t.json()},m=async()=>{const s=localStorage.getItem(o.token),t=await fetch(n,{method:"POST",headers:{Authorization:`token ${s}`},body:JSON.stringify({description:a.description,public:!0,files:{[a.fileName]:{content:a.fileContent}}})});if(!t.ok)throw new Error(t.statusText);return t.json()},h=async()=>{const s=localStorage.getItem(o.token),t=localStorage.getItem(o.gistId),i=await fetch(`${n}/${t}`,{method:"PATCH",headers:{Authorization:`token ${s}`},body:JSON.stringify({description:a.description,files:{[a.fileName]:{content:a.fileContent}}})});if(!i.ok)throw new Error(i.statusText);return i.json()},d=async()=>{const s=localStorage.getItem(o.token),t=localStorage.getItem(o.gistId),i=localStorage.getItem(o.gistEtag),e=await fetch(`${n}/${t}`,{headers:{Authorization:`token ${s}`,"If-None-Match":i}});if(!e.ok&&e.status>=400)throw await e.json();localStorage.setItem(o.gistEtag,e.headers.get("etag"));const r={"x-ratelimit-limit":e.headers.get("x-ratelimit-limit"),"x-ratelimit-remaining":e.headers.get("x-ratelimit-remaining"),"x-ratelimit-reset":e.headers.get("x-ratelimit-reset")};return sessionStorage.setItem(c.ratelimit,JSON.stringify(r)),e.status===200?e.json():null},f=async(s,t)=>{const i=localStorage.getItem(o.token),e=localStorage.getItem(o.gistId),r=await fetch(`${n}/${e}`,{method:"PATCH",headers:{Authorization:`token ${i}`},body:JSON.stringify({files:{[s]:{content:t}}})});if(!r.ok)throw new Error(r.statusText);return r.json()};export{a as G,m as a,h as b,f as c,d,g}; diff --git a/assets/index-FuFUnZ6u.css b/assets/index-FuFUnZ6u.css new file mode 100644 index 00000000..cffcac80 --- /dev/null +++ b/assets/index-FuFUnZ6u.css @@ -0,0 +1 @@ +*{box-sizing:inherit}:root{-moz-tab-size:4;tab-size:4}html{-moz-text-size-adjust:100%;text-size-adjust:100%;line-height:1.15}*{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}body{margin:0}hr{height:0}button,input,optgroup,select,textarea{margin:0;font-family:inherit;font-size:100%;line-height:1.15}button,select{text-transform:none}button,[type=button],[type=reset],[type=submit]{-webkit-appearance:button}button::-moz-focus-inner{border-style:none;padding:0}[type=button]::-moz-focus-inner{border-style:none;padding:0}[type=reset]::-moz-focus-inner{border-style:none;padding:0}[type=submit]::-moz-focus-inner{border-style:none;padding:0}button:-moz-focusring{outline:1px dotted ButtonText}[type=button]:-moz-focusring{outline:1px dotted ButtonText}[type=reset]:-moz-focusring{outline:1px dotted ButtonText}[type=submit]:-moz-focusring{outline:1px dotted ButtonText}progress{vertical-align:baseline}[type=number]::-webkit-inner-spin-button{height:auto}[type=number]::-webkit-outer-spin-button{height:auto}::-webkit-file-upload-button{-webkit-appearance:button;font:inherit}:root{--white:#eee;--black:#111;--theme-rgb:245,142,168;--theme-color:rgb(var(--theme-rgb));--theme-contrast-color:var(--black);--font-color:var(--black);--background-color:#f1f3f4;--semi-black-color:#202020cc;--semi-white-color:#e0e0e0cc;--border-radius:8px;--text-shadow:0 0 2px var(--black);--drop-shadow:drop-shadow(0 0 4px currentColor);--transition-duration:.25s;--animation-duration:.25s;--animation-durationx2:.5s;--animation-out-back:cubic-bezier(.18,.89,.32,1.28)}@media (prefers-color-scheme:dark){:root{--font-color:var(--white);--background-color:var(--black)}}[data-theme=light]{--font-color:var(--black);--background-color:#f1f3f4}[data-theme=dark]{--font-color:var(--white);--background-color:var(--black)}@media (prefers-reduced-motion:reduce){:root{--transition-duration:10ms;--animation-duration:.1s;--animation-durationx2:.1s}}@font-face{font-family:Akari Fallback UI;src:local(Segoe UI),local(Roboto),local(Oxygen),local(Ubuntu),local(Cantarell),local(Open Sans),local(Helvetica Neue),local(Helvetica)}:root{color:var(--font-color);background-color:var(--background-color);font-feature-settings:"kern" 1;font-kerning:normal;caret-color:var(--theme-color);overscroll-behavior-y:contain;font-family:-apple-system,BlinkMacSystemFont,system-ui,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,Akari Fallback UI,sans-serif,Apple Color Emoji,Segoe UI Emoji}:root,textarea,input{font-variant-numeric:tabular-nums}[lang]:lang(zh){font-family:-apple-system,BlinkMacSystemFont,system-ui,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,Akari Fallback UI,PingFang SC,Microsoft YaHei UI,Microsoft YaHei,Source Han Sans SC,Noto Sans CJK SC,WenQuanYi Micro Hei,sans-serif,Apple Color Emoji,Segoe UI Emoji}[lang]:lang(zh-HK){font-family:-apple-system,BlinkMacSystemFont,system-ui,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,Akari Fallback UI,PingFang HK,Microsoft JhengHei UI,Microsoft JhengHei,Source Han Sans HK,Noto Sans CJK TC,sans-serif,Apple Color Emoji,Segoe UI Emoji}[lang]:lang(zh-TW){font-family:-apple-system,BlinkMacSystemFont,system-ui,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,Akari Fallback UI,PingFang TC,Microsoft JhengHei UI,Microsoft JhengHei,Source Han Sans TW,Noto Sans CJK TC,sans-serif,Apple Color Emoji,Segoe UI Emoji}[lang]:lang(ja){font-family:-apple-system,BlinkMacSystemFont,system-ui,Segoe UI,Roboto,Noto Sans,Ubuntu,Cantarell,Helvetica Neue,Akari Fallback UI,Hiragino Kaku Gothic Pro,Yu Gothic UI,Yu Gothic,Meiryo UI,Meiryo,Source Han Sans JP,Noto Sans CJK JP,sans-serif,Apple Color Emoji,Segoe UI Emoji}select,input,textarea{color:inherit}svg{fill:currentColor}::selection{color:var(--theme-contrast-color);background-color:var(--theme-color)}@supports (-ms-ime-align:auto) and (not (position:sticky)){::selection{color:unset;background-color:unset}}:focus{outline:none}a{color:currentColor;text-decoration:none}a,button,[type=submit]{cursor:default;-webkit-appearance:none;-moz-appearance:none;appearance:none;-webkit-user-select:none;user-select:none;background:0;border:0;padding:0 8px}ul{margin:0;padding:0;list-style:none}.link{cursor:pointer;text-decoration:underline}.link:hover{-webkit-text-decoration-color:var(--theme-color);-webkit-text-decoration-color:var(--theme-color);text-decoration-color:var(--theme-color)}.link:hover:after{content:"🔗";margin-left:4px;position:absolute}a>*{pointer-events:none}.button{color:var(--black);border-radius:var(--border-radius);opacity:.8;background-color:#fff;padding:8px}.button:hover{opacity:1}.glow{transition:text-shadow var(--transition-duration)ease}.glow:hover{text-shadow:0 0 4px}.glow>svg{transition:filter var(--transition-duration)ease}.glow:hover>svg{filter:var(--drop-shadow)}.ripple{position:relative;overflow:hidden;transform:translate(0)}.ripple:after{opacity:0;content:"";pointer-events:none;background-image:radial-gradient(circle,#000 10%,#0000 10%);background-position:50%;background-repeat:no-repeat;width:100%;height:100%;transition:transform .5s,opacity 1s;display:block;position:absolute;top:0;left:0;transform:scale(10)}.ripple:active:after{opacity:.2;transition:all;transform:scale(0)}.select-all{-webkit-user-select:all;user-select:all}.page-loading:before{background-color:var(--background-color);opacity:.5;content:"";position:fixed;top:0;bottom:0;left:0;right:0}.akari-odango-loading{text-align:center;width:50vmin;height:50vmin;margin:auto;position:fixed;top:0;bottom:0;left:0;right:0}.start-loading{animation:2s linear infinite akari-loading}@keyframes akari-loading{0%{transform:rotate(0)translate(-2vmin)rotate(0)}to{transform:rotate(360deg)translate(-2vmin)rotate(-360deg)}}.akari-not-found{opacity:.2;filter:var(--drop-shadow);flex:auto;align-self:center;max-width:100vw;max-height:80vh;margin-top:auto}.app-header{z-index:233;padding:0 8px;padding-right:env(safe-area-inset-right);padding-left:env(safe-area-inset-left);color:var(--theme-color);background-color:var(--semi-black-color);box-shadow:0 1px 1px var(--theme-color);animation:slide-in-down var(--animation-duration)ease-in-out forwards;-webkit-user-select:none;user-select:none;justify-content:space-between;align-items:center;width:100%;height:60px;display:flex;position:fixed;top:0}@media (max-width:768px){.app-header{padding:0 4px}}.app-title{font-size:1.5rem;font-weight:500}.app-title-text{margin-left:1rem;display:none}.app-title-svg{display:inline-flex}@media (min-width:768px){.app-title-text{display:inline-flex}.app-title-svg{display:none}}.app-header a{color:#fff;transition:color var(--transition-duration)ease-in-out;-webkit-user-select:none;user-select:none;justify-content:center;align-items:center;min-width:60px;min-height:60px;padding:0;display:inline-flex}.app-tab{animation-name:slide-in-down;animation-duration:var(--animation-durationx2);animation-timing-function:ease-out;animation-fill-mode:forwards;position:relative;transform:translateY(-100%)}.app-tab:first-child{animation-delay:.1s}.app-tab:nth-child(2){animation-delay:.2s}.app-tab:nth-child(3){animation-delay:.3s}.app-tab:nth-child(4){animation-delay:.4s}.app-nav:hover .app-tab{color:#fff}.app-nav .app-tab:hover,.app-nav>a:target{color:currentColor}.app-tab:before{z-index:-1;background-color:var(--theme-contrast-color);transform-origin:50% 0;transition:transform var(--transition-duration)ease-in-out;content:"";width:100%;height:100%;position:absolute;top:0;left:0;transform:scaleY(0)}.app-tab:target:before,.app-tab:hover:before{transform:scaleY(1)}:hover>.app-tab:target:before{transform:scaleY(0)}.app-tab:hover:target:before{transform:scaleY(1)}.app-title-svg>svg,.app-tab>svg{width:30px;height:30px;margin:0}.app-footer{z-index:233;animation:slide-in-up var(--animation-duration)ease forwards;width:100%;position:fixed;bottom:0}html{box-sizing:content-box;padding-bottom:env(safe-area-inset-bottom);min-height:100vh;min-height:-webkit-fill-available}body{box-sizing:border-box}html,body,.app-container,.app-main{flex-direction:column;display:flex}body,.app-container,.app-main{flex:1 0 auto}body,.app-container{contain:size;display:contents}@media not all and (-webkit-min-device-pixel-ratio:.0000264583),not all and (-webkit-min-device-pixel-ratio:.0000264583),not all and (min-resolution:.001dpcm){@supports not (((-webkit-appearance:none)) and (stroke-color:transparent)){body,.app-container{display:flex}}}.app-main{width:80%;margin:auto;padding-top:60px;padding-bottom:32px}@media (max-width:1280px){.app-main{width:1024px;max-width:100%}}@media (max-width:1024px){.app-main{padding-right:env(safe-area-inset-right);padding-left:env(safe-area-inset-left);width:100%}}.home{margin-top:env(safe-area-inset-top);margin-bottom:env(safe-area-inset-bottom);margin-left:env(safe-area-inset-left);-webkit-user-select:none;user-select:none;flex-direction:column;justify-content:center;align-items:center;display:flex;position:fixed;top:60px;bottom:32px;left:0;right:0}.home-tip{color:var(--white);background-color:var(--semi-black-color);border-radius:var(--border-radius);max-width:45%;margin:16px;padding:16px}.home-tip-top-left{position:absolute;top:0;left:0}.home-tip-top-right{position:absolute;top:0;right:0}.home-tip-bottom-left{position:absolute;bottom:0;left:0}.home-tip-bottom-right{position:absolute;bottom:0;right:0}.home-tip:after{content:"";border-style:solid;border-width:8px;margin-left:-8px;position:absolute;left:50%}.home-tip-top-left:after,.home-tip-bottom-left:after{left:32px}.home-tip-top-left:after,.home-tip-top-right:after{border-color:transparent transparent var(--semi-black-color)transparent;bottom:100%}.home-tip-bottom-left:after,.home-tip-bottom-right:after{border-color:var(--semi-black-color)transparent transparent transparent;top:100%}.home-tip-section{font-size:1.2rem;line-height:1.5}.home-tip-item{cursor:default;margin:8px;padding:0}.home-tip-item>svg{margin-right:8px}.home-tip-text,.home-tip-item>svg{vertical-align:middle}.app-editor{border:1px solid var(--theme-color);border-radius:var(--border-radius);transition:box-shadow var(--transition-duration)ease-in-out;background-color:#0000;flex-direction:column;flex:1 0 auto;margin:16px;padding:8px;font-size:1.2rem;display:flex;position:relative}.app-editor:hover,.app-editor:focus-within{box-shadow:0 0 10px var(--theme-color)}@media (max-width:768px){.app-editor{border:0;border-radius:0;margin:0}.app-editor:hover,.app-editor:focus-within{box-shadow:none}}.app-editor-infobox{display:none}@supports (display:grid){.app-editor-infobox{grid-template-rows:1fr 1fr 1fr;grid-template-columns:auto 1fr auto}[open]>.app-editor-infobox{display:grid}}@supports not (display:grid){.app-editor-infobox{flex-wrap:wrap}[open]>.app-editor-infobox{display:flex}.app-editor-infobox>input{flex:calc(100% - 38px)}.app-editor-infobox>label:nth-child(3n+1){flex:0 0 30px}.app-editor-infobox>label:nth-child(3n+3){text-align:right;flex:0 0 8px}}.app-textarea{overscroll-behavior-y:contain;border:none;flex:1 0 auto}.app-editor input,.app-editor textarea{resize:none;background-color:#0000;border:none;padding:0}.app-editor>details{opacity:.6;padding-bottom:4px}.app-editor summary{-webkit-user-select:none;user-select:none}.editor-tools{padding:8px;display:flex;position:absolute;top:0;right:0}.editor-tools-item{color:var(--font-color);border-radius:50%;flex-direction:column;justify-content:center;align-items:center;padding:8px;display:inline-flex}.editor-tools-item:active{color:currentColor}.editor-tools-item>svg{color:currentColor;width:24px;height:24px}.editor-tools-item:hover>svg{filter:drop-shadow(0 0 2px var(--theme-color))}.lyric-list{-webkit-user-select:none;user-select:none;width:100%;line-height:1.4;position:relative}.lyric-list.on-screen-button{margin-bottom:40px}.space-button{margin-bottom:env(safe-area-inset-bottom);color:var(--white);background-color:var(--semi-black-color);border-bottom:1px dashed var(--theme-color);width:100%;height:40px;position:fixed;bottom:32px;left:0}.space-button:active{border-bottom-style:solid}.line{white-space:pre-wrap;border-top:2px solid #0000;border-bottom:2px solid #0000;align-items:baseline;padding:8px 0 8px 8rem;font-size:1.2rem}.line:after{content:"";display:inline-block}.line:nth-child(2n){background-color:#0002}.line:nth-child(odd){background-color:#fff2}.line>.line-time,.line>.line-text{pointer-events:none}.select{border-color:var(--theme-color)}.curser{contain:content;position:absolute;left:0}.curser:after{content:"➤"}.line.highlight{color:var(--theme-contrast-color);background-color:var(--theme-color)}.error:before{content:"⚠️";position:absolute;left:-2rem}@media (max-width:1080px){.error:before{left:6rem}.select.error:before{visibility:hidden}}@media (max-width:768px){.line{border-width:1px;padding-left:6rem;font-size:1rem}.error:before{left:4rem}}.aside-panel{margin-bottom:env(safe-area-inset-bottom);background-color:var(--semi-black-color);animation:slide-in-right var(--animation-duration)ease 1s forwards;border-radius:8px 0 0 8px;position:fixed;bottom:64px;right:0;transform:translate(100%)}.on-screen-button+.aside-panel{bottom:100px}.aside-button{box-sizing:content-box;padding:0;padding-right:env(safe-area-inset-right);color:var(--white);flex-direction:column;justify-content:center;align-items:center;width:50px;height:50px;margin:0;line-height:1;display:flex}.aside-button>svg{fill:currentColor;width:30px;height:30px;margin:auto}.aside-button:hover>svg{filter:drop-shadow(0 0 4px var(--theme-color))}.syncmode-button{border-bottom:1px solid var(--white);border-top-left-radius:8px}.syncmode-button.highlight{color:var(--theme-contrast-color);background-color:var(--theme-color)}.syncmode-button.highlight .lock-open,.syncmode-button.select .lock-close{visibility:hidden}audio{margin-bottom:env(safe-area-inset-bottom);background-color:var(--semi-black-color);width:100%;height:32px;position:absolute;bottom:0}audio::-webkit-media-controls-enclosure{border-radius:0}[disabled]{opacity:.5;pointer-events:none}.lrc-audio{padding-right:env(safe-area-inset-right);padding-bottom:env(safe-area-inset-bottom);padding-left:env(safe-area-inset-left);color:var(--white);background-color:var(--semi-black-color);-webkit-user-select:none;user-select:none;justify-content:space-around;align-items:center;font-size:14px;display:flex}.lrc-audio>button,.lrc-audio>span{flex:none}.slider{--slider-height:32px;height:var(--slider-height);margin:0 5px;position:relative}.slider>progress,.slider>input{width:100%;position:absolute;left:0;right:0}@media (max-width:768px){.timeline-slider{--slider-height:4px;width:100%;margin:0;position:absolute;bottom:100%}}.lrc-audio>button{color:#eee;height:32px}audio+.lrc-audio>.loadaudio-button>svg{animation:1s ease-in-out infinite drop-shadow-flash}audio[src]+.lrc-audio>.loadaudio-button>svg{animation:none}@keyframes drop-shadow-flash{0%{filter:0}50%{filter:var(--drop-shadow)}}.lrc-audio section{margin:0 5px}.timeline-slider{flex:4 0 auto}.playbackrate-slider{flex:auto;max-width:150px}input[type=range]{--thumb-size:16px;height:var(--slider-height);color:var(--theme-color);-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#0000;margin:0;padding:0}input[type=range]:focus{outline:none}input[type=range]::-webkit-slider-runnable-track{height:var(--slider-height);background-color:#0000;border:0}input[type=range]::-moz-range-track{height:var(--slider-height);background-color:#0000;border:0}input[type=range]::-ms-track{color:#0000;background-color:#0000;border-color:#0000;top:-6px}input[type=range]::-webkit-slider-thumb{z-index:10;width:var(--thumb-size);height:var(--thumb-size);margin-top:calc((var(--slider-height) - var(--thumb-size))/2);box-shadow:0 0 4px 1px var(--black);filter:brightness(120%);transition:box-shadow var(--transition-duration)ease-in-out;-webkit-appearance:none;background-color:currentColor;border:0;border-radius:50%}input[type=range]:hover::-webkit-slider-thumb{box-shadow:0 0 4px 1px var(--white)}input[type=range]::-moz-range-thumb{z-index:10;width:var(--thumb-size);height:var(--thumb-size);margin-top:calc((var(--slider-height) - var(--thumb-size))/2);box-shadow:0 0 4px 1px var(--black);filter:brightness(120%);transition:box-shadow var(--transition-duration)ease-in-out;-moz-appearance:none;background-color:currentColor;border:0;border-radius:50%}input[type=range]:hover::-moz-range-thumb{box-shadow:0 0 4px var(--white)}input[type=range]::-ms-fill-upper{background-color:#0000}input[type=range]::-ms-fill-lower{background-color:#0000}input[type=range]::-ms-thumb{background-color:currentColor;border-radius:50%;width:16px;height:16px;margin-top:-1px}input[type=range]::-ms-tooltip{display:none}.slider>progress{--progress-meter-color:var(--theme-color);box-sizing:border-box;margin:calc(var(--slider-height)/2 - 2px)0;color:var(--progress-meter-color);vertical-align:0;background:var(--white);box-shadow:0 0 4px var(--black);transition:box-shadow var(--transition-duration)ease-in-out;-webkit-appearance:none;-moz-appearance:none;appearance:none;border:none;border-radius:2px;height:4px;display:inline-block}.slider:hover progress{box-shadow:0 0 4px var(--white)}progress::-moz-progress-bar{background-color:var(--progress-meter-color);background-image:linear-gradient(-45deg,#fff0 0 50%,#fffc 62.5%,#fff0 75%);background-size:35px 20px,100% 100%,100% 100%;border-radius:2px}progress::-webkit-progress-bar{background-color:#eee;border-radius:2px;box-shadow:inset 0 2px 5px #0004}progress::-webkit-progress-value{background-color:var(--progress-meter-color);background-image:linear-gradient(-45deg,#fff0 0 50%,#fffc 62.5%,#fff0 75%);background-repeat:repeat-x;background-size:40px 40px,100% 100%,100% 100%;border-radius:2px}.dialog{z-index:1000;border-radius:var(--border-radius);margin:auto;display:none;position:fixed;top:0;bottom:0;left:0;right:0}.dialog[open]{animation:dialog-slide-in var(--animation-duration)var(--animation-out-back);display:block}.dialog-close{color:var(--theme-color);width:48px;height:48px;padding:0;list-style-type:none;position:absolute;top:-24px;left:-24px}.dialog-close::-webkit-details-marker{display:none}.dialog-close::marker{display:none}.dialog-close:before{z-index:-1;content:"";position:fixed;top:0;bottom:0;left:0;right:0}.dialog-close>svg{width:36px;height:36px;margin:auto;position:absolute;top:0;bottom:0;left:0;right:0}.loadaudio-dialog{color:var(--black);background-color:var(--semi-white-color);border:1px solid var(--theme-color);box-shadow:0 0 1rem var(--theme-color),0 0 0 100vmax #0008;width:500px;max-width:calc(100% - 36px);height:10rem;max-height:100%}.loadaudio-body{box-sizing:border-box;justify-content:space-around;padding:10px;display:flex}.tab{display:inline-block}.loadaudio-tab{text-align:center;width:100%}.loadaudio-tab>[type=radio]{display:none}.loadaudio-content{visibility:hidden;width:100%;height:100px;position:absolute;left:0}.loadaudio-tab>label{border:1px solid #0000;border-bottom:1px solid var(--theme-color);-webkit-user-select:none;user-select:none;border-top-left-radius:6px;border-top-right-radius:6px;width:100%;padding:8px 0;display:inline-block}.loadaudio-tab :checked~label{border:1px solid var(--theme-color);background-color:#fffd;border-bottom-color:#0000}.loadaudio-tab :checked~label~.loadaudio-content{visibility:visible}.audio-input-tip,.audio-input-form{transition:transform var(--transition-duration)ease-in-out;justify-content:center;align-items:center;width:100%;height:100%;padding:16px;display:flex}.audio-input-tip:hover{transform:scale(1.2)}.audio-input-form>input[type=url]{border:0;border-bottom:1px solid var(--theme-color);background:0;flex:1 0 auto;width:60%;margin:8px;font-size:1.5rem}.audio-input-form>input[type=submit]{-webkit-appearance:none;-moz-appearance:none;appearance:none;border:0}@keyframes dialog-slide-in{0%{opacity:0;transform:translateY(100%)}50%{opacity:1}}.toggle-switch{--bar-height:14px;--bar-width:32px;--bar-color:#eee;--knob-size:20px;--knob-color:#fff;--switch-offset:calc(var(--knob-size) - var(--bar-height));--switch-width:calc(var(--bar-width) + var(--switch-offset));--transition-duration:.2s;--switch-transition:all var(--transition-duration)ease-in-out;--switch-theme-rgb:26,115,232;--switch-theme-color:rgb(var(--switch-theme-rgb));--switch-box-shadow:0 0 var(--switch-offset)#11111180;--switch-margin:8px;box-sizing:border-box;min-width:var(--bar-width);min-height:var(--bar-height);margin:var(--switch-margin);-webkit-user-select:none;user-select:none;align-items:center;display:inline-flex;position:relative}.toggle-switch.disabled{opacity:.5;pointer-events:none}.toggle-switch>input,.toggle-switch-input{opacity:0;width:0;height:0;position:absolute}.toggle-switch>label,.toggle-switch-label{--knob-x:calc((var(--bar-height) - var(--bar-width))/2);box-sizing:border-box;width:var(--bar-width);height:var(--bar-height);margin:var(--switch-margin);-webkit-user-select:none;user-select:none;justify-content:center;align-items:center;display:inline-flex;position:relative}.toggle-switch>:checked+label,:checked+.toggle-switch-label{--knob-x:calc((var(--bar-width) - var(--bar-height))/2)}.toggle-switch>label:before,.toggle-switch-label:before{box-sizing:border-box;width:var(--bar-width);height:var(--bar-height);background:var(--bar-color);border:1px solid var(--switch-theme-color);border-radius:var(--bar-height);opacity:.5;transition:var(--switch-transition);content:"";position:absolute;top:0;left:0}.toggle-switch>:checked+label:before,:checked+.toggle-switch-label:before{background:var(--switch-theme-color)}.toggle-switch>label:after,.toggle-switch-label:after{box-sizing:border-box;width:var(--knob-size);height:var(--knob-size);background:var(--knob-color);box-shadow:var(--switch-box-shadow);transform:translateX(var(--knob-x));transition:var(--switch-transition);content:"";border-radius:50%}.toggle-switch>:checked+label:after,:checked+.toggle-switch-label:after{background:var(--switch-theme-color)}.toggle-switch>:focus+label:after,:focus+.toggle-switch-label:after,.toggle-switch:hover>label:after,:hover>.toggle-switch-label:after{box-shadow:var(--switch-box-shadow),0 0 0 calc(var(--knob-size)/2)rgba(var(--switch-theme-rgb),.2)}.preferences{-webkit-user-select:none;user-select:none;width:100%}.preferences>ul{max-width:1024px;margin:auto}.preferences li{width:100%;padding:0 8px}.preferences li:nth-child(2n){background-color:#0002}.list-item{flex-wrap:wrap;justify-content:space-between;align-items:center;max-width:768px;min-height:3.5rem;margin:auto;display:flex}.list-item>span,.list-item>form{margin:8px 0}.list-item>.link{padding:0}.toggle-switch{--switch-theme-rgb:var(--theme-rgb);--switch-margin:0;--bar-height:20px;--bar-width:52px;--knob-size:28px;width:var(--switch-width);height:var(--knob-size);justify-content:center}@supports (-ms-ime-align:auto){.toggle-switch{--switch-offset:8px;--switch-width:60px}.toggle-switch-label:after{box-shadow:0 0 8px #1118}:hover>.toggle-switch-label:after{box-shadow:0 0 8px #1118,0 0 0 14px rgb(var(--theme-rgb)/20%)}.toggle-switch-label{--knob-x:-16px}:checked+.toggle-switch-label{--knob-x:16px}}.color-picker{vertical-align:middle;border-radius:var(--border-radius);justify-content:center;align-items:center;min-width:30px;height:30px;margin:2px;line-height:normal;display:inline-flex}.color-picker.hash{color:var(--theme-contrast-color)}.color-picker.checked:before{color:var(--theme-contrast-color);content:"✔️"}.user-color-input-text{border:0;border-bottom:1px solid var(--theme-color);background:0;flex:74px;grid-column:span 2;place-self:stretch stretch;min-width:60px;margin:2px}.user-color-label{color:var(--theme-contrast-color)}.theme-color-span,.user-color-label,.user-color-input-text{display:none}@media (min-width:768px){.user-color-label,.user-color-input-text{display:inline-flex}}.format-example-time,.format-example-text{vertical-align:middle}.format-example-text{color:var(--theme-contrast-color);white-space:pre-wrap;background-color:var(--theme-color);display:inline}.option-select>select{text-align-last:right;-webkit-appearance:none;-moz-appearance:none;appearance:none;background-color:#0000;border:none;outline:0;padding-right:16px}.option-select>select>option{color:var(--font-color);background-color:var(--background-color)}::-ms-expand{display:none}.option-select{position:relative}.option-select:after{color:var(--theme-color);content:"▼";pointer-events:none;position:absolute;right:0}input[type=number]{text-align:right;border:0;border-bottom:1px solid var(--theme-color);background:0;border-radius:0;width:4rem;height:30px}.akari-hide-wall{z-index:-1;opacity:.8;animation:akari-slide-in .5s var(--animation-out-back)3s forwards,akari-float 20s ease-in-out 4s infinite;stroke-width:4px;width:256px;height:256px;position:fixed;bottom:32px;right:0;transform:translate(100%)}@keyframes akari-slide-in{0%{transform:translate(100%)}to{transform:translate(34%)}}@keyframes akari-float{0%{transform:translate(34%)}50%{transform:translate(34%,1rem)}to{transform:translate(34%)}}.current-theme-color{vertical-align:middle;font-family:Consolas,Monaco,monospace}.dropdown{position:relative}.dropdown>summary{list-style-type:none}.dropdown>summary::-webkit-details-marker{display:none}.dropdown>summary::marker{display:none}.dropdown>summary:after{color:var(--theme-color);vertical-align:middle;content:"▼";pointer-events:none}.dropdown[open]>summary:before{z-index:80;cursor:default;content:"";display:block;position:fixed;top:0;bottom:0;left:0;right:0}.dropdown-body{z-index:100;background-color:var(--background-color);border:1px solid var(--theme-color);border-radius:var(--border-radius);box-shadow:0 0 1rem var(--theme-color);margin:8px;padding:8px;position:absolute;top:100%;right:0}.dropdown-body:before{border-color:transparent transparent var(--theme-color)transparent;content:"";border-style:solid;border-width:8px;margin-left:-8px;position:absolute;bottom:100%;right:74px}.color-wall{grid-gap:4px;grid-template-columns:repeat(5,1fr);place-items:center;width:200px;display:none}[open]>.color-wall{flex-wrap:wrap;display:grid}.pseudo-hidden{visibility:hidden;position:absolute}.gist{flex-direction:column;flex:1 0 auto;justify-content:center;align-items:center;width:100%;display:flex}.new-token,.get-gist-id{flex-direction:column;justify-content:center;align-items:center;width:100%;max-width:768px;margin:0 auto;display:flex}.new-token-tip,.create-new-gist{text-align:center;flex:1 0 auto;width:100%;max-width:500px;margin:1rem;padding:1rem}@media (max-width:500px){.new-token-tip{border-radius:0}}.new-token-tip-text,.gist-id-tip-text{text-align:center;max-width:500px;margin:1rem;font-size:1.2rem}.github-svg{width:100px;height:100px;margin:1rem}.new-token-input,.gist-id-input{border:0;border-bottom:1px solid var(--theme-color);background:0;border-radius:0;flex:1 0 auto;margin:0 .5rem}.new-token-form,.gist-id-form{flex:1 0 auto;justify-content:center;align-items:center;width:100%;max-width:500px;margin:1rem 0;padding:1rem 0;display:flex}.file-list{grid-gap:1rem;flex:1 0 auto;grid-template-rows:min-content;grid-template-columns:repeat(auto-fill,minmax(15rem,1fr));width:100%;display:grid}.file-item{border-radius:var(--border-radius);box-shadow:0 0 2px var(--font-color);transition:box-shadow var(--transition-duration)ease-in-out;-webkit-user-select:none;user-select:none;padding:.5rem}.file-item:hover{box-shadow:0 0 1rem var(--theme-color)}.file-content{white-space:pre;height:15rem;line-height:1.6;overflow:hidden}.file-bar{justify-content:space-between;align-items:flex-start;display:flex}.file-title{padding:.5rem}.file-action{flex:none}.file-load{justify-content:center;align-items:center;width:32px;height:32px;padding:0;transition:color .25s ease-in-out;display:inline-flex}.file-load>svg{pointer-events:none}.file-load:hover{color:var(--theme-color)}.gist-details{-webkit-user-select:none;user-select:none;width:100%;padding:1rem}@media (min-width:1024px){.gist-details{padding:1rem 0}}.gist-bar{justify-content:space-between;width:100%;display:flex}@media (max-width:768px){.gist-bar{flex-direction:column}}.gist-info,.ratelimit{flex:auto;padding:.5rem}.ratelimit>p{margin:0;line-height:1.5}.gist-loading{flex:1 0 auto;justify-content:center;align-items:center;display:flex}.gist-no-data{flex:auto;display:flex}.toast-queue{width:100%;max-width:320px;position:fixed;top:60px;right:0}.toast{color:var(--black);background-color:var(--semi-white-color);border:1px solid var(--theme-color);border-radius:var(--border-radius);box-shadow:0 0 1rem var(--theme-color);animation:height-change var(--animation-duration)ease forwards,slide-in-right var(--animation-duration)ease-in forwards,slide-out-right var(--animation-duration)ease-out 5s forwards;background-color:#fffd;max-height:320px;margin:1rem;display:flex}.toast-badge{flex:none;width:32px;height:32px;margin:8px}.toast-info{color:#1b95e0}.toast-success{color:#19cf86}.toast-warning{color:#fab81e}.toast-badge>svg{width:100%;height:100%}.toast-text{margin:1rem .5rem}@keyframes height-change{0%{max-height:0}to{max-height:320px}}@keyframes slide-in-right{0%{transform:translate(100%)}to{transform:translate(0)}}@keyframes slide-out-right{0%{transform:translate(0)}to{transform:translate(100%)}}@keyframes slide-in-up{0%{transform:translateY(100%)}to{transform:translate(0)}}@keyframes slide-in-down{0%{transform:translateY(-100%)}to{transform:translate(0)}} diff --git a/assets/index-o0wXbvYb.js b/assets/index-o0wXbvYb.js new file mode 100644 index 00000000..043bb7cf --- /dev/null +++ b/assets/index-o0wXbvYb.js @@ -0,0 +1,16 @@ +function pe(e,n){for(var s=0;sr[a]})}}}return Object.freeze(Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}))}const me=function(){const n=typeof document<"u"&&document.createElement("link").relList;return n&&n.supports&&n.supports("modulepreload")?"modulepreload":"preload"}(),fe=function(e,n){return new URL(e,n).href},K={},v=function(n,s,r){let a=Promise.resolve();if(s&&s.length>0){const o=document.getElementsByTagName("link");a=Promise.all(s.map(c=>{if(c=fe(c,r),c in K)return;K[c]=!0;const d=c.endsWith(".css"),l=d?'[rel="stylesheet"]':"";if(!!r)for(let f=o.length-1;f>=0;f--){const g=o[f];if(g.href===c&&(!d||g.rel==="stylesheet"))return}else if(document.querySelector(`link[href="${c}"]${l}`))return;const u=document.createElement("link");if(u.rel=d?"stylesheet":me,d||(u.as="script",u.crossOrigin=""),u.href=c,document.head.appendChild(u),d)return new Promise((f,g)=>{u.addEventListener("load",f),u.addEventListener("error",()=>g(new Error(`Unable to preload CSS for ${c}`)))})}))}return a.then(()=>n()).catch(o=>{const c=new Event("vite:preloadError",{cancelable:!0});if(c.payload=o,window.dispatchEvent(c),!c.defaultPrevented)throw o})},i=React,ge=pe({__proto__:null},[i]),J=ReactDOM;function xe(e){if(e.__esModule)return e;var n=e.default;if(typeof n=="function"){var s=function r(){return this instanceof r?Reflect.construct(n,arguments,this.constructor):n.apply(this,arguments)};s.prototype=n.prototype}else s={};return Object.defineProperty(s,"__esModule",{value:!0}),Object.keys(e).forEach(function(r){var a=Object.getOwnPropertyDescriptor(e,r);Object.defineProperty(s,r,a.get?a:{enumerable:!0,get:function(){return e[r]}})}),s}var Q={exports:{}},D={};const ye=xe(ge);/** + * @license React + * react-jsx-runtime.production.min.js + * + * Copyright (c) Facebook, Inc. and its affiliates. + * + * This source code is licensed under the MIT license found in the + * LICENSE file in the root directory of this source tree. + */var ve=ye,we=Symbol.for("react.element"),be=Symbol.for("react.fragment"),je=Object.prototype.hasOwnProperty,ke=ve.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED.ReactCurrentOwner,Se={key:!0,ref:!0,__self:!0,__source:!0};function X(e,n,s){var r,a={},o=null,c=null;s!==void 0&&(o=""+s),n.key!==void 0&&(o=""+n.key),n.ref!==void 0&&(c=n.ref);for(r in n)je.call(n,r)&&!Se.hasOwnProperty(r)&&(a[r]=n[r]);if(e&&e.defaultProps)for(r in n=e.defaultProps,n)a[r]===void 0&&(a[r]=n[r]);return{$$typeof:we,type:e,key:o,ref:c,props:a,_owner:ke.current}}D.Fragment=be;D.jsx=X;D.jsxs=X;Q.exports=D;var t=Q.exports;const T={lyric:"lrc-maker-lyric",preferences:"lrc-maker-preferences",token:"lrc-maker-oauth-token",gistId:"lrc-maker-gist-id",gistEtag:"lrc-maker-gist-etag",gistFile:"lrc-maker-gist-file"},Y={emptyString:"",space:" "},Le={languageName:"English",app:{name:"LRC Maker",fullname:"Akari's LRC Maker"},header:{home:"home",editor:"editor",synchronizer:"synchronizer",gist:"Github Gist",preferences:"preferences"},audio:{loadAudio:"load audio",play:"play",pause:"pause",replay5s:"replay 5s",forward5s:"forward 5s",resetRate:"reset playback rate",error:["audio error","audio aborted by user","audio network error","audio decoding error","audio not supported"]},loadAudio:{file:"File",url:"URL",loadFile:"Click here or drop audio file in this page"},home:{tips:"Tips",tipForLyricText:"Navigate to the editor page and paste lyric text.",tipForUploadAudio:"Click the bottom left button to load audio file.",tipForSynchronizer:"Navigate to synchronizer page and make your lrc :)",tipTopLeft:"Click here come back to this page",tipTopRight:"Click here to navigate to other page",tipBottomLeft:"load audio here, and control the audio",tipBottomRight:"change the playback rate here"},editor:{metaInfo:"meta info",album:"album",title:"title",artist:"artist",uploadText:"upload text",copyText:"select all and copy",downloadText:"download",saveToGist:"save to Github Gist",saveFileName:"Filename",utils:"lrc utils"},gist:{newTokenTip:"LRC Maker use Github Token to fetch and store data to Github Gist",newTokenButton:"Generate a new Github Token",newGistTip:"Create a new Gist repository or assign an existing Gist id",newGistRepoButton:"Create a new Gist Repository",gistIdPlaceholder:"Or assign an existing Gist id",info:"info",clearTokenAndGist:"Clear token and Gist id"},preferences:{version:"Version",commitHash:"Commit hash",updateTime:"Update time",repo:"Repository",help:"Help & tips",language:"Language",builtInAudio:"Use browser built-in audio player",spaceButton:"On-screen space key",themeColor:"Theme color",lrcFormat:"Change output format",fixed:"Timestamp fixed",leftSpace:"Left space",rightSpace:"Right space",clearCache:"Clear caches",themeMode:{label:"Theme Mode",auto:"auto",light:"light",dark:"dark"}},notify:{audioLoaded:"Audio loaded."}},Ee=Object.assign({"./en-US.json":()=>v(()=>import("./en-US-zc2O-JdV.js"),__vite__mapDeps([]),import.meta.url).then(e=>e.default),"./ja.json":()=>v(()=>import("./ja-GcgVr18M.js"),__vite__mapDeps([]),import.meta.url).then(e=>e.default),"./ko-KR.json":()=>v(()=>import("./ko-KR-yW8HIalv.js"),__vite__mapDeps([]),import.meta.url).then(e=>e.default),"./pt-BR.json":()=>v(()=>import("./pt-BR-DSi-64D4.js"),__vite__mapDeps([]),import.meta.url).then(e=>e.default),"./zh-CN.json":()=>v(()=>import("./zh-CN-IS2wiGhF.js"),__vite__mapDeps([]),import.meta.url).then(e=>e.default),"./zh-HK.json":()=>v(()=>import("./zh-HK--aRTSL7g.js"),__vite__mapDeps([]),import.meta.url).then(e=>e.default),"./zh-TW.json":()=>v(()=>import("./zh-TW-FFP4ehVz.js"),__vite__mapDeps([]),import.meta.url).then(e=>e.default)}),Re=()=>{const[e,n]=i.useState(Le),s=async r=>{const a=await Ee[`./${r}.json`]();n(a)};return[e,i.useCallback(async r=>s(r),[])]};var ze=["en-US","ja","ko-KR","pt-BR","zh-CN","zh-HK","zh-TW"];const Ce={orange:"#ff691f",yellow:"#fab81e",lime:"#7fdbb6",green:"#19cf86",blue:"#91d2fa",navy:"#1b95e0",grey:"#abb8c2",red:"#e81c4f",pink:"#f58ea8",purple:"#c877fe"};var V=(e=>(e[e.auto=0]="auto",e[e.light=1]="light",e[e.dark=2]="dark",e))(V||{});const $={lang:"en-US",spaceStart:1,spaceEnd:0,fixed:3,builtInAudio:!1,screenButton:!1,themeColor:Ce.pink,themeMode:0},_e=(e,n)=>{const s=n.payload;return{...e,[n.type]:typeof s=="function"?s(e):s}},Ie=ze,Me=e=>{const n=$,s=navigator.languages||[navigator.language||"en-US"];n.lang=s.map(r=>r==="zh"?"zh-CN":r.startsWith("en")?"en-US":r).find(r=>Ie.includes(r))||"en-US";try{const r=JSON.parse(e()),a=Object.keys($);for(const o of a)o in r&&(n[o]=r[o])}catch{}return n},Ne=e=>i.useReducer(_e,e,Me),B=()=>{const e=new Map;return{pub:r=>{e.forEach(a=>{a(r)})},sub:(r,a)=>(e.set(r,a),()=>{e.delete(r)})}},Te=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{d:"M10 19v-5h4v5c0 .55.45 1 1 1h3c.55 0 1-.45 1-1v-7h1.7c.46 0 .68-.57.33-.87L12.67 3.6c-.38-.34-.96-.34-1.34 0l-8.36 7.53c-.34.3-.13.87.33.87H5v7c0 .55.45 1 1 1h3c.55 0 1-.45 1-1z"})]}),Z=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{d:"M3 17.46v3.04c0 .28.22.5.5.5h3.04c.13 0 .26-.05.35-.15L17.81 9.94l-3.75-3.75L3.15 17.1c-.1.1-.15.22-.15.36zM20.71 7.04c.39-.39.39-1.02 0-1.41l-2.34-2.34c-.39-.39-1.02-.39-1.41 0l-1.83 1.83 3.75 3.75 1.83-1.83z"})]}),ee=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0z"}),t.jsx("path",{d:"M4 21h16c.55 0 1-.45 1-1s-.45-1-1-1H4c-.55 0-1 .45-1 1s.45 1 1 1zM3 9.21v5.59c0 .45.54.67.85.35l2.79-2.79c.2-.2.2-.51 0-.71l-2.79-2.8a.5.5 0 0 0-.85.36zM8.6 17H20c.55 0 1-.45 1-1s-.45-1-1-1H8.6c-.55 0-1 .45-1 1s.45 1 1 1zM3 4c0 .55.45 1 1 1h16c.55 0 1-.45 1-1s-.45-1-1-1H4c-.55 0-1 .45-1 1zm5.6 5H20c.55 0 1-.45 1-1s-.45-1-1-1H8.6c-.55 0-1 .45-1 1s.45 1 1 1zm0 4H20c.55 0 1-.45 1-1s-.45-1-1-1H8.6c-.55 0-1 .45-1 1s.45 1 1 1z"})]}),Ve=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM19 18H6c-2.21 0-4-1.79-4-4s1.79-4 4-4h.71C7.37 7.69 9.48 6 12 6c3.04 0 5.5 2.46 5.5 5.5v.5H19c1.66 0 3 1.34 3 3s-1.34 3-3 3z"})]}),Oe=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{d:"M19.44 12.99l-.01.02c.04-.33.08-.67.08-1.01 0-.34-.03-.66-.07-.99l.01.02 2.44-1.92-2.43-4.22-2.87 1.16.01.01c-.52-.4-1.09-.74-1.71-1h.01L14.44 2H9.57l-.44 3.07h.01c-.62.26-1.19.6-1.71 1l.01-.01-2.88-1.17-2.44 4.22 2.44 1.92.01-.02c-.04.33-.07.65-.07.99 0 .34.03.68.08 1.01l-.01-.02-2.1 1.65-.33.26 2.43 4.2 2.88-1.15-.02-.04c.53.41 1.1.75 1.73 1.01h-.03L9.58 22h4.85s.03-.18.06-.42l.38-2.65h-.01c.62-.26 1.2-.6 1.73-1.01l-.02.04 2.88 1.15 2.43-4.2s-.14-.12-.33-.26l-2.11-1.66zM12 15.5c-1.93 0-3.5-1.57-3.5-3.5s1.57-3.5 3.5-3.5 3.5 1.57 3.5 3.5-1.57 3.5-3.5 3.5z"})]}),He=()=>t.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:t.jsx("path",{d:"M8 6.82v10.36c0 .79.87 1.27 1.54.84l8.14-5.18c.62-.39.62-1.29 0-1.69L9.54 5.98C8.87 5.55 8 6.03 8 6.82z"})}),Pe=()=>t.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:t.jsx("path",{d:"M8 19c1.1 0 2-.9 2-2V7c0-1.1-.9-2-2-2s-2 .9-2 2v10c0 1.1.9 2 2 2zm6-12v10c0 1.1.9 2 2 2s2-.9 2-2V7c0-1.1-.9-2-2-2s-2 .9-2 2z"})}),De=()=>t.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:t.jsx("path",{d:"M12 5V2.21c0-.45-.54-.67-.85-.35l-3.8 3.79c-.2.2-.2.51 0 .71l3.79 3.79c.32.31.86.09.86-.36V7c3.73 0 6.68 3.42 5.86 7.29-.47 2.26-2.14 3.99-4.39 4.53-3.64.88-6.93-1.6-7.42-4.96-.06-.49-.48-.86-.97-.86-.6 0-1.08.53-1 1.13.63 4.47 4.94 7.75 9.77 6.67 3.09-.69 5.39-3.08 5.99-6.19C20.84 9.48 16.94 5 12 5zm-1.31 8.9l.25-2.17h2.39v.71h-1.7l-.11.92c.03-.02.07-.03.11-.05s.09-.04.15-.05.12-.03.18-.04.13-.02.2-.02c.21 0 .39.03.55.1s.3.16.41.28.2.27.25.45.09.38.09.6c0 .19-.03.37-.09.54s-.15.32-.27.45-.27.24-.45.31-.39.12-.64.12c-.18 0-.36-.03-.53-.08s-.32-.14-.46-.24-.24-.24-.32-.39-.13-.33-.13-.53h.84c.02.18.08.32.19.41s.25.15.42.15c.11 0 .2-.02.27-.06s.14-.1.18-.17.08-.15.11-.25.03-.2.03-.31-.01-.21-.04-.31-.07-.17-.13-.24-.13-.12-.21-.15-.19-.05-.3-.05c-.08 0-.15.01-.2.02s-.11.03-.15.05-.08.05-.12.07-.07.06-.1.09l-.67-.16z"})}),Ae=()=>t.jsx("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:t.jsx("path",{d:"M18.87 13c-.5 0-.91.37-.98.86-.48 3.37-3.77 5.84-7.42 4.96-2.25-.54-3.91-2.27-4.39-4.53C5.27 10.42 8.22 7 11.95 7v2.79c0 .45.54.67.85.35l3.79-3.79c.2-.2.2-.51 0-.71L12.8 1.85c-.31-.31-.85-.09-.85.35V5c-4.94 0-8.84 4.48-7.84 9.6.6 3.11 2.9 5.5 5.99 6.19 4.83 1.08 9.15-2.2 9.77-6.67.09-.59-.4-1.12-1-1.12zm-6.44 2.15c-.05.07-.11.13-.18.17s-.17.06-.27.06c-.17 0-.31-.05-.42-.15s-.17-.24-.19-.41h-.84c.01.2.05.37.13.53s.19.28.32.39.29.19.46.24.35.08.53.08c.24 0 .46-.04.64-.12s.33-.18.45-.31.21-.28.27-.45.09-.35.09-.54c0-.22-.03-.43-.09-.6s-.14-.33-.25-.45-.25-.22-.41-.28-.34-.1-.55-.1c-.07 0-.14.01-.2.02s-.13.02-.18.04-.1.03-.15.05-.08.04-.11.05l.11-.92h1.7v-.71H10.9l-.25 2.17.67.17c.03-.03.06-.06.1-.09s.07-.05.12-.07.1-.04.15-.05.13-.02.2-.02c.12 0 .22.02.3.05s.16.09.21.15.1.14.13.24.04.19.04.31-.01.22-.03.31-.06.17-.11.24z"})}),te=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{d:"M19 4H5c-1.11 0-2 .9-2 2v12c0 1.1.9 2 2 2h3c.55 0 1-.45 1-1s-.45-1-1-1H5V8h14v10h-3c-.55 0-1 .45-1 1s.45 1 1 1h3c1.1 0 2-.9 2-2V6c0-1.1-.89-2-2-2zm-7.35 6.35l-2.79 2.79c-.32.32-.1.86.35.86H11v5c0 .55.45 1 1 1s1-.45 1-1v-5h1.79c.45 0 .67-.54.35-.85l-2.79-2.79c-.19-.2-.51-.2-.7-.01z"})]}),Fe=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{opacity:".3",d:"M12 4c-4.41 0-8 3.59-8 8s3.59 8 8 8 8-3.59 8-8-3.59-8-8-8zm4 10.59L14.59 16 12 13.41 9.41 16 8 14.59 10.59 12 8 9.41 9.41 8 12 10.59 14.59 8 16 9.41 13.41 12 16 14.59z"}),t.jsx("path",{d:"M14.59 8L12 10.59 9.41 8 8 9.41 10.59 12 8 14.59 9.41 16 12 13.41 14.59 16 16 14.59 13.41 12 16 9.41zM12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2zm0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8z"})]}),ht=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{d:"M19 13v5c0 .55-.45 1-1 1H6c-.55 0-1-.45-1-1v-5c0-.55-.45-1-1-1s-1 .45-1 1v6c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2v-6c0-.55-.45-1-1-1s-1 .45-1 1zm-6-.33l1.88-1.88c.39-.39 1.02-.39 1.41 0 .39.39.39 1.02 0 1.41l-3.59 3.59c-.39.39-1.02.39-1.41 0L7.7 12.2c-.39-.39-.39-1.02 0-1.41.39-.39 1.02-.39 1.41 0L11 12.67V4c0-.55.45-1 1-1s1 .45 1 1v8.67z"})]}),pt=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{className:"lock-open",d:"M12 13c-1.1 0-2 .9-2 2s.9 2 2 2 2-.9 2-2-.9-2-2-2zm6-5h-1V6c0-2.76-2.24-5-5-5-2.28 0-4.27 1.54-4.84 3.75-.14.54.18 1.08.72 1.22.53.14 1.08-.18 1.22-.72C9.44 3.93 10.63 3 12 3c1.65 0 3 1.35 3 3v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm0 11c0 .55-.45 1-1 1H7c-.55 0-1-.45-1-1v-8c0-.55.45-1 1-1h10c.55 0 1 .45 1 1v8z"}),t.jsx("path",{className:"lock-close",d:"M18 8h-1V6c0-2.76-2.24-5-5-5S7 3.24 7 6v2H6c-1.1 0-2 .9-2 2v10c0 1.1.9 2 2 2h12c1.1 0 2-.9 2-2V10c0-1.1-.9-2-2-2zm-6 9c-1.1 0-2-.9-2-2s.9-2 2-2 2 .9 2 2-.9 2-2 2zM9 8V6c0-1.66 1.34-3 3-3s3 1.34 3 3v2H9z"})]}),mt=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{d:"M16 1H4c-1.1 0-2 .9-2 2v14h2V3h12V1zm-1 4H8c-1.1 0-1.99.9-1.99 2L6 21c0 1.1.89 2 1.99 2H19c1.1 0 2-.9 2-2V11l-6-6zM8 21V7h6v5h5v9H8z"})]}),ft=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{d:"M9.17 6l2 2H20v10H4V6h5.17M10 4H4c-1.1 0-1.99.9-1.99 2L2 18c0 1.1.9 2 2 2h16c1.1 0 2-.9 2-2V8c0-1.1-.9-2-2-2h-8l-2-2z"})]}),gt=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{d:"M19.35 10.04C18.67 6.59 15.64 4 12 4 9.11 4 6.6 5.64 5.35 8.04 2.34 8.36 0 10.91 0 14c0 3.31 2.69 6 6 6h13c2.76 0 5-2.24 5-5 0-2.64-2.05-4.78-4.65-4.96zM19 18H6c-2.21 0-4-1.79-4-4 0-2.05 1.53-3.76 3.56-3.97l1.07-.11.5-.95C8.08 7.14 9.94 6 12 6c2.62 0 4.88 1.86 5.39 4.43l.3 1.5 1.53.11c1.56.1 2.78 1.41 2.78 2.96 0 1.65-1.35 3-3 3zM8 13h2.55v3h2.9v-3H16l-4-4z"})]}),xt=()=>t.jsx("svg",{className:"github-svg",xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 16 16",children:t.jsx("path",{d:"M8 0C3.58 0 0 3.58 0 8c0 3.54 2.29 6.53 5.47 7.59.4.07.55-.17.55-.38 0-.19-.01-.82-.01-1.49-2.01.37-2.53-.49-2.69-.94-.09-.23-.48-.94-.82-1.13-.28-.15-.68-.52-.01-.53.63-.01 1.08.58 1.23.82.72 1.21 1.87.87 2.33.66.07-.52.28-.87.51-1.07-1.78-.2-3.64-.89-3.64-3.95 0-.87.31-1.59.82-2.15-.08-.2-.36-1.02.08-2.12 0 0 .67-.21 2.2.82.64-.18 1.32-.27 2-.27.68 0 1.36.09 2 .27 1.53-1.04 2.2-.82 2.2-.82.44 1.1.16 1.92.08 2.12.51.56.82 1.27.82 2.15 0 3.07-1.87 3.75-3.65 3.95.29.25.54.73.54 1.48 0 1.07-.01 1.93-.01 2.2 0 .21.15.46.55.38A8.013 8.013 0 0 0 16 8c0-4.42-3.58-8-8-8z"})}),Ge=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zM9.29 16.29L5.7 12.7c-.39-.39-.39-1.02 0-1.41.39-.39 1.02-.39 1.41 0L10 14.17l6.88-6.88c.39-.39 1.02-.39 1.41 0 .39.39.39 1.02 0 1.41l-7.59 7.59c-.38.39-1.02.39-1.41 0z"})]}),Ue=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{d:"M12 2C6.48 2 2 6.48 2 12s4.48 10 10 10 10-4.48 10-10S17.52 2 12 2zm0 15c-.55 0-1-.45-1-1v-4c0-.55.45-1 1-1s1 .45 1 1v4c0 .55-.45 1-1 1zm1-8h-2V7h2v2z"})]}),Be=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0V0z"}),t.jsx("path",{d:"M2.73 21h18.53c.77 0 1.25-.83.87-1.5l-9.27-16c-.39-.67-1.35-.67-1.73 0l-9.27 16c-.38.67.1 1.5.87 1.5zM13 18h-2v-2h2v2zm-1-4c-.55 0-1-.45-1-1v-2c0-.55.45-1 1-1s1 .45 1 1v2c0 .55-.45 1-1 1z"})]}),yt=()=>t.jsxs("svg",{xmlns:"http://www.w3.org/2000/svg",width:"24",height:"24",viewBox:"0 0 24 24",children:[t.jsx("path",{fill:"none",d:"M0 0h24v24H0z"}),t.jsx("path",{d:"M8.2 10.5c-.4-.3-1-.5-1.5-.4 0 0-3.6-3-4.3-4.3-.5-1-.6-2.8 0-3.4.6-.6 2.4-.5 3.4 0C7 3.1 10 6.7 10 6.7c0 .6 0 1.1.4 1.6l-2.3 2.2zM18.7 17.8l.3-.2 1 .9 2 3-.5.5-3-1.9-1-1.1.3-.3L14 15l1-1 3.7 3.9z"}),t.jsx("path",{d:"M13.2 7.8c-.5-1.6 0-3.3 1.1-4.5a4.5 4.5 0 0 1 4.4-1.1L16 4.7l.7 2.5 2.5.7 2.5-2.5c.4 1.5 0 3.1-1.1 4.3a4.5 4.5 0 0 1-4.6 1.1L5.6 21.4a2.1 2.1 0 0 1-3 0c-.8-.8-.8-2.2 0-3L13.2 7.8zM3.9 21c.5 0 .8-.3.8-.8a.8.8 0 1 0-1.6 0c0 .5.4.8.8.8z"})]}),E=B(),Ke={id:0},ne=()=>{const e=i.useRef(Symbol(ne.name)),[n,s]=i.useState([]);i.useEffect(()=>E.sub(e.current,o=>{s(c=>[{id:Ke.id++,...o},...c])}),[]);const r=i.useCallback(o=>{o.animationName==="slide-out-right"&&s(c=>c.slice(0,-1))},[]),a=i.useCallback(o=>{const c={info:t.jsx(Ue,{}),success:t.jsx(Ge,{}),warning:t.jsx(Be,{})}[o.type];return t.jsxs("section",{className:"toast",children:[t.jsx("section",{className:`toast-badge toast-${o.type}`,children:c}),t.jsx("section",{className:"toast-text",children:o.text})]},o.id)},[]);return t.jsx("div",{className:"toast-queue",onAnimationEnd:r,children:n.map(a)})};var C=(e=>(e[e.lang=1]="lang",e[e.builtInAudio=2]="builtInAudio",e[e.prefState=4]="prefState",e))(C||{});const I=i.createContext(void 0,(e,n)=>{let s=0;return e.lang!==n.lang&&(s|=1),e.prefState.builtInAudio!==n.prefState.builtInAudio&&(s|=2),e.prefState!==n.prefState&&(s|=4),s}),$e=({children:e})=>{const[n,s]=Ne(()=>localStorage.getItem(T.preferences)||Y.emptyString),[r,a]=Re();i.useEffect(()=>{a(n.lang).catch(c=>{E.pub({type:"warning",text:c.message})})},[n.lang,a]),i.useEffect(()=>{document.title=r.app.fullname,document.documentElement.lang=n.lang},[r,n,n.lang]);const o=i.useMemo(()=>({lang:r,prefState:n,prefDispatch:s,trimOptions:{trimStart:n.spaceStart>=0,trimEnd:n.spaceEnd>=0}}),[r,s,n]);return t.jsx(I.Provider,{value:o,children:e})},x={home:"/",editor:"/editor/",synchronizer:"/synchronizer/",gist:"/gist/",preferences:"/preferences/"},_={audioSrc:"audio-src",editorDetailsOpen:"editor-details-open",syncMode:"sync-mode",selectIndex:"select-index",ratelimit:"x-ratelimit"},se=(e,n={})=>{const{trimStart:s=!1,trimEnd:r=!1}=n,a=e.split(/\r\n|\n|\r/u),o=/\[\s*(\d{1,3}):(\d{1,2}(?:[:.]\d{1,3})?)\s*]/g,c=/\[\s*(\w{1,6})\s*:(.*?)]/,d=new Map,l=[];for(const h of a){if(h[0]!=="["){l.push({text:h});continue}o.lastIndex=0;const u=o.exec(h);if(u!==null){const g=Number.parseInt(u[1],10),R=Number.parseFloat(u[2].replace(":",".")),y=h.slice(o.lastIndex);l.push({time:g*60+R,text:y});continue}const f=c.exec(h);if(f!==null){const g=f[2].trim();if(g==="")continue;d.set(f[1],g);continue}l.push({text:h})}return s&&r?l.forEach(h=>{h.text=h.text.trim()}):s?l.forEach(h=>{h.text=h.text.trimStart()}):r&&l.forEach(h=>{h.text=h.text.trimEnd()}),{info:d,lyric:l}},G=new Map,qe=e=>{if(G.has(e))return G.get(e);const n=new Intl.NumberFormat("en",{minimumIntegerDigits:2,minimumFractionDigits:e,maximumFractionDigits:e,useGrouping:!1});return G.set(e,n),n},P=(e,n,s=!0)=>{if(e===void 0)return"";const r=qe(n),a=Math.floor(e/60).toString().padStart(2,"0"),o=r.format(e%60);return s?`[${a}:${o}]`:`${a}:${o}`},We=(e,n,s)=>{let r=e;return n>=0&&(r=" ".repeat(n)+r.trimStart()),s>=0&&(r=r.trimEnd()+" ".repeat(s)),r},Je=(e,n)=>{const{spaceStart:s,spaceEnd:r,fixed:a,endOfLine:o=`\r +`}=n,c=Array.from(e.info.entries()).map(([l,h])=>`[${l}: ${h}]`),d=e.lyric.map(l=>{if(l.time===void 0)return l.text;const h=We(l.text,s,r);return`${P(l.time,a)}${h}`});return c.concat(d).join(o)};var O=(e=>(e[e.parse=0]="parse",e[e.refresh=1]="refresh",e[e.next=2]="next",e[e.time=3]="time",e[e.info=4]="info",e[e.select=5]="select",e[e.deleteTime=6]="deleteTime",e[e.getState=7]="getState",e))(O||{});const H=(e,n,s)=>es?s:e,Qe=(e,n)=>{for(const s in n)if(e[s]!==n[s])return{...e,...n};return e},re=(e,n)=>{switch(n.type){case 0:{const{text:s,options:r}=n.payload,a=se(s,r),o=H(e.selectIndex,0,a.lyric.length-1);return{...e,...a,selectIndex:o}}case 1:{const s=n.payload;if(s>=e.currentTime&&s(o.time&&(o.times&&(a.nextTime=o.time,a.nextIndex=c),o.time>a.currentTime&&o.time<=s&&(a.currentTime=o.time,a.currentIndex=c)),a),{currentTime:-1/0,currentIndex:-1/0,nextTime:1/0,nextIndex:1/0});return Qe(e,r)}case 2:{const s=e.selectIndex,r=e.lyric,a=H(s+1,0,r.length-1);return{...re(e,{type:3,payload:n.payload}),selectIndex:a}}case 3:{const s=n.payload,r=e.selectIndex;let a=e.lyric;if(a[r].time!==s){const o=a.slice();o[r]={text:a[r].text,time:s},a=o}return{...e,lyric:a,currentTime:s,nextTime:-1/0}}case 4:{const{name:s,value:r}=n.payload,a=new Map(e.info);return r.trim()===""?a.delete(s):a.set(s,r.trim()),{...e,info:a}}case 5:{const s=H(n.payload(e.selectIndex),0,e.lyric.length-1);return e.selectIndex===s?e:{...e,selectIndex:s}}case 6:{const{selectIndex:s,currentIndex:r}=e;let a=e.lyric;if(a[s].time!==void 0){const o=a.slice();o[s]={text:a[s].text},a=o;let{currentTime:c,nextTime:d}=e;return s===r&&(c=1/0,d=-1/0),{...e,lyric:a,currentTime:c,nextTime:d}}return e}case 7:return n.payload(e),e}return e},Xe=e=>{const{text:n,options:s,select:r}=e();return{...se(n,s),currentTime:1/0,currentIndex:1/0,nextTime:-1/0,nextIndex:-1/0,selectIndex:r}},Ye=e=>i.useReducer(re,e,Xe),p={current:null,get src(){var e;return((e=this.current)==null?void 0:e.src)??""},get duration(){var e;return((e=this.current)==null?void 0:e.duration)??0},get paused(){var e;return((e=this.current)==null?void 0:e.paused)??!0},get playbackRate(){var e;return((e=this.current)==null?void 0:e.playbackRate)??1},set playbackRate(e){this.current!==null&&(this.current.playbackRate=e)},get currentTime(){var e;return((e=this.current)==null?void 0:e.currentTime)??0},set currentTime(e){this.current!==null&&this.current.duration!==0&&(this.current.currentTime=e)},step(e,n,s){return s===void 0&&(s=this.currentTime),e.altKey&&(n*=.2),e.shiftKey&&(n*=.5),this.currentTime=H(n+s,0,this.duration)},toggle(){var e;(e=this.current)!=null&&e.duration&&(this.current.paused?this.current.play():this.current.pause())}};var w=(e=>(e[e.pause=0]="pause",e[e.getDuration=1]="getDuration",e[e.rateChange=2]="rateChange",e))(w||{});const j=B(),U=B(),ae=e=>{if(e===null)return!1;const n=e.type;return n==="textarea"||n==="text"||n==="url"};function S(e){return"#"+e}const L={current:null,get isOpen(){return this.current!==null&&this.current.open},open(){this.current===null||this.current.open||(this.current.open=!0)},close(){this.current===null||!this.current.open||(this.current.open=!1)}},oe=({setAudioSrc:e,lang:n})=>{const s=i.useRef(Symbol(oe.name));i.useEffect(()=>j.sub(s.current,c=>{c.type===w.getDuration&&L.close()}),[]);const r=i.useCallback(()=>{const c=d=>{(d.code==="Escape"||d.key==="Escape")&&L.close()};L.isOpen?window.addEventListener("keydown",c):window.removeEventListener("keydown",c)},[]),a=i.useCallback(c=>{c.preventDefault();const l=c.target.elements.namedItem("url"),h=ie(l.value);sessionStorage.setItem(_.audioSrc,h),e(h)},[e]),o=i.useCallback(c=>{c.target.select()},[]);return J.createPortal(t.jsxs("details",{ref:L,className:"dialog fixed loadaudio-dialog",onToggle:r,children:[t.jsx("summary",{className:"dialog-close",children:t.jsx(Fe,{})}),t.jsxs("section",{className:"dialog-body loadaudio-body",children:[t.jsxs("div",{className:"loadaudio-tab loadaudio-via-file",children:[t.jsx("input",{type:"radio",name:"tabgroup",id:"tab-file",defaultChecked:!0}),t.jsx("label",{className:"ripple",htmlFor:"tab-file",children:n.loadAudio.file}),t.jsx("div",{className:"loadaudio-content",children:t.jsx("label",{className:"audio-input-tip",htmlFor:"audio-input",children:n.loadAudio.loadFile})})]}),t.jsxs("div",{className:"loadaudio-tab loadaudio-via-url",children:[t.jsx("input",{type:"radio",name:"tabgroup",id:"tab-url"}),t.jsx("label",{className:"ripple",htmlFor:"tab-url",children:n.loadAudio.url}),t.jsx("div",{className:"loadaudio-content",children:t.jsxs("form",{className:"audio-input-form",onSubmit:a,children:[t.jsx("input",{type:"url",name:"url",required:!0,autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",spellCheck:!1,onFocus:o}),t.jsx("input",{className:"button",type:"submit"})]})})]})]})]}),document.body)},ie=e=>{if(e.includes("music.163.com")){const n=/\d{4,}/.exec(e);if(n!==null)return`https://music.163.com/song/media/outer/url?id=${n[0]}.mp3`}return e},Ze=()=>{const{lang:e}=i.useContext(I),n=()=>{L.open()};return t.jsxs("div",{className:"home",children:[t.jsx("p",{className:"home-tip home-tip-top-left",children:e.home.tipTopLeft}),t.jsx("p",{className:"home-tip home-tip-top-right",children:e.home.tipTopRight}),t.jsx("p",{className:"home-tip home-tip-bottom-left",children:e.home.tipBottomLeft}),t.jsx("p",{className:"home-tip home-tip-bottom-right",children:e.home.tipBottomRight}),t.jsxs("section",{className:"home-tip-section",children:[t.jsx("p",{children:e.home.tips}),t.jsxs("ol",{children:[t.jsx("li",{children:t.jsxs("a",{className:"home-tip-item",href:S(x.editor),children:[t.jsx(Z,{}),t.jsx("span",{className:"home-tip-text",children:e.home.tipForLyricText})]})}),t.jsx("li",{children:t.jsxs("span",{className:"home-tip-item",onClick:n,children:[t.jsx(te,{}),t.jsx("span",{className:"home-tip-text",children:e.home.tipForUploadAudio})]})}),t.jsx("li",{children:t.jsxs("a",{className:"home-tip-item",href:S(x.synchronizer),children:[t.jsx(ee,{}),t.jsx("span",{className:"home-tip-text",children:e.home.tipForSynchronizer})]})})]})]})]})};document.addEventListener("keydown",e=>{const{code:n,key:s,target:r}=e;ae(r)||(s==="?"||n==="Slash"&&e.shiftKey)&&(location.hash=x.home)});const vt=()=>t.jsx("img",{className:"akari-hide-wall",alt:"akari-hide-wall",src:"./svg/akari-hide-wall.svg",crossOrigin:"anonymous"}),et=()=>t.jsx("img",{className:"akari-not-found",alt:"not found",src:"./svg/akari-not-found.svg",crossOrigin:"anonymous"}),tt=()=>t.jsx("img",{className:"akari-odango-loading start-loading",alt:"loading",src:"./svg/akari-odango-loading.svg",crossOrigin:"anonymous"}),nt=i.lazy(async()=>v(()=>import("./editor-O8LiZDmY.js"),__vite__mapDeps([0,1,2]),import.meta.url).then(({Eidtor:e})=>({default:e}))),st=i.lazy(async()=>v(()=>import("./synchronizer-Te2Y3F7L.js"),__vite__mapDeps([3,2]),import.meta.url).then(({Synchronizer:e})=>({default:e}))),rt=i.lazy(async()=>v(()=>import("./gist-i1907ujF.js"),__vite__mapDeps([4,1]),import.meta.url).then(({Gist:e})=>({default:e}))),at=i.lazy(async()=>v(()=>import("./preferences-H6lGisGs.js"),__vite__mapDeps([]),import.meta.url).then(({Preferences:e})=>({default:e}))),ce=()=>{const e=i.useRef(Symbol(ce.name)),{prefState:n,trimOptions:s}=i.useContext(I,C.prefState),[r,a]=i.useState(location.hash);i.useEffect(()=>{function l(){a(location.hash)}return window.addEventListener("hashchange",l),()=>window.removeEventListener("hashchange",l)},[]);const[o,c]=Ye(()=>({text:localStorage.getItem(T.lyric)||Y.emptyString,options:s,select:Number.parseInt(sessionStorage.getItem(_.selectIndex),10)||0}));i.useEffect(()=>j.sub(e.current,l=>{l.type===w.getDuration&&c({type:O.info,payload:{name:"length",value:P(l.payload,n.fixed,!1)}})}),[c,n.fixed]),i.useEffect(()=>{function l(){c({type:O.getState,payload:u=>{localStorage.setItem(T.lyric,Je(u,n)),sessionStorage.setItem(_.selectIndex,u.selectIndex.toString())}}),localStorage.setItem(T.preferences,JSON.stringify(n))}function h(){document.hidden&&l()}return document.addEventListener("visibilitychange",h),window.addEventListener("beforeunload",l),()=>{document.removeEventListener("visibilitychange",h),window.removeEventListener("beforeunload",l)}},[c,n]),i.useEffect(()=>{function l(h){var f;const u=(f=h.dataTransfer)==null?void 0:f.files[0];if(u&&(u.type.startsWith("text/")||/(?:\.lrc|\.txt)$/i.test(u.name))){const g=new FileReader,R=()=>{c({type:O.parse,payload:{text:g.result,options:s}})};g.addEventListener("load",R,{once:!0}),location.hash=x.editor,g.readAsText(u,"utf-8")}}return document.documentElement.addEventListener("drop",l),()=>document.documentElement.removeEventListener("drop",l)},[c,s]),i.useEffect(()=>{const l={[V.auto]:"auto",[V.light]:"light",[V.dark]:"dark"};document.documentElement.dataset.theme=l[n.themeMode]},[n.themeMode]),i.useEffect(()=>{const l=it(n.themeColor);document.documentElement.style.setProperty("--theme-rgb",l.join(", "));const u=ot(...l)+.05,f=u*u>.0525?"var(--black)":"var(--white)";document.documentElement.style.setProperty("--theme-contrast-color",f)},[n.themeColor]);const d=(()=>{switch(r.slice(1)){case x.editor:return t.jsx(nt,{lrcState:o,lrcDispatch:c});case x.synchronizer:return o.lyric.length===0?t.jsx(et,{}):t.jsx(st,{state:o,dispatch:c});case x.gist:return t.jsx(rt,{lrcDispatch:c,langName:n.lang});case x.preferences:return t.jsx(at,{})}return t.jsx(Ze,{})})();return t.jsx("main",{className:"app-main",children:t.jsx(i.Suspense,{fallback:t.jsx(tt,{}),children:d})})},ot=(...e)=>e.map(n=>n/255).map(n=>n<=.03928?n/12.92:Math.pow((n+.055)/1.055,2.4)).reduce((n,s,r)=>n+s*[.2126,.7152,.0722][r],0),it=e=>{e=e.slice(1);const n=Number.parseInt(e,16),s=n>>16&255,r=n>>8&255,a=n>>0&255;return[s,r,a]},le=({min:e,max:n,step:s,value:r,onInput:a,className:o})=>{const c=n-e||1,d=(r-e)/c;return t.jsxs("div",{className:`slider ${o}-slider`,children:[t.jsx("progress",{value:d}),t.jsx("input",{type:"range",className:o,"aria-label":o,min:e,max:n,step:s,value:r,onInput:a})]})},ue=({duration:e,paused:n})=>{const s=i.useRef(Symbol(ue.name)),[r,a]=i.useState(p.currentTime),[o,c]=i.useState(p.playbackRate);i.useEffect(()=>j.sub(s.current,u=>{u.type===w.rateChange&&c(u.payload)}),[]),i.useEffect(()=>{if(n)return U.sub(s.current,u=>{a(u)});{const u=setInterval(()=>{a(p.currentTime)},500/o);return()=>{clearInterval(u)}}},[n,o]);const d=i.useRef(0),l=i.useCallback(u=>{d.current&&cancelAnimationFrame(d.current);const f=u.target.value;d.current=requestAnimationFrame(()=>{const g=Number.parseInt(f,0);a(g),p.currentTime=g})},[]),h=i.useMemo(()=>e?" / "+P(e,0,!1):!1,[e]);return t.jsxs(t.Fragment,{children:[t.jsxs("time",{children:[P(r,0,!1),h]}),t.jsx(le,{min:0,max:e,step:1,value:r,className:"timeline",onInput:l})]})},de=({lang:e})=>{const n=i.useRef(Symbol(de.name)),[s,r]=i.useState(p.playbackRate);i.useEffect(()=>j.sub(n.current,d=>{d.type===w.rateChange&&r(d.payload)}),[]);const a=i.useMemo(()=>Math.log(s),[s]),o=i.useCallback(d=>{const l=Math.exp(Number.parseFloat(d.target.value));r(l),p.playbackRate=l},[]),c=i.useCallback(()=>{p.playbackRate=1},[]);return t.jsxs(t.Fragment,{children:[t.jsxs("button",{className:"ripple glow",title:e.audio.resetRate,onClick:c,children:["X ",s.toFixed(2)]}),t.jsx(le,{className:"playbackrate",min:-1,max:1,step:"any",value:a,onInput:o})]})},he=({lang:e})=>{const n=i.useRef(Symbol(he.name)),[s,r]=i.useState(p.paused),[a,o]=i.useState(p.duration);i.useEffect(()=>j.sub(n.current,u=>{switch(u.type){case w.getDuration:{o(u.payload),r(p.paused);break}case w.pause:{r(u.payload);break}}}),[]);const c=i.useCallback(u=>{p.step(u,-5)},[]),d=i.useCallback(u=>{p.step(u,5)},[]),l=i.useCallback(()=>{p.toggle()},[]),h=i.useCallback(()=>{L.open()},[]);return t.jsxs("section",{className:"lrc-audio"+(s?"":" playing"),children:[t.jsx("button",{className:"ripple glow loadaudio-button",title:e.audio.loadAudio,onClick:h,children:t.jsx(te,{})}),t.jsx("button",{className:"ripple glow",title:e.audio.replay5s,onClick:c,disabled:!a,children:t.jsx(De,{})}),t.jsx("button",{className:"ripple glow",title:s?e.audio.play:e.audio.pause,disabled:!a,onClick:l,children:s?t.jsx(He,{}):t.jsx(Pe,{})}),t.jsx("button",{className:"ripple glow",title:e.audio.forward5s,onClick:d,disabled:!a,children:t.jsx(Ae,{})}),t.jsx(ue,{duration:a,paused:s}),t.jsx(de,{lang:e})]})},ct=["audio/*",".ncm",".qmcflac",".qmc0",".qmc1",".qmc2",".qmc3","qmcogg"].join(", "),lt=()=>{const{prefState:e,lang:n}=i.useContext(I,C.lang|C.builtInAudio),[s,r]=i.useReducer((y,m)=>(URL.revokeObjectURL(y),m),void 0,()=>{let y=sessionStorage.getItem(_.audioSrc);if(y===null&&location.search&&URLSearchParams){const m=new URLSearchParams(location.search),b=m.get("url");if(b!==null)return b;const k=m.get("text")||m.get("title")||"",M=/https?:\/\/\S+/.exec(k);y=M&&ie(M[0])}return y});i.useEffect(()=>{function y(m){const{code:b,key:k,target:M}=m,z=b||k;if(!ae(M)&&p.src)if(m.metaKey||m.ctrlKey)if(["ArrowUp","KeyJ","Up","J","j"].includes(z)){m.preventDefault();const A=p.playbackRate,F=Math.exp(Math.min(Math.log(A)+.2,1));p.playbackRate=F}else if(["ArrowDown","KeyK","Down","K","k"].includes(z)){m.preventDefault();const A=p.playbackRate,F=Math.exp(Math.max(Math.log(A)-.2,-1));p.playbackRate=F}else z==="Enter"&&(m.preventDefault(),p.toggle());else["ArrowLeft","KeyA","KeyH","Left","A","a","H","h"].includes(z)?(m.preventDefault(),p.step(m,-5)):["ArrowRight","KeyD","KeyL","Right","D","d","L","l"].includes(z)?(m.preventDefault(),p.step(m,5)):(b==="KeyR"||k==="R"||k==="r")&&(m.preventDefault(),p.playbackRate=1)}return document.addEventListener("keydown",y),()=>document.removeEventListener("keydown",y)},[]),i.useEffect(()=>{function y(m){const b=m.dataTransfer.files[0];q(b,r)}return document.documentElement.addEventListener("drop",y),()=>document.documentElement.removeEventListener("drop",y)},[]);const a=i.useCallback(y=>{const m=y.target.files[0];q(m,r)},[]),o=i.useRef(0),c=i.useCallback(()=>{cancelAnimationFrame(o.current),j.pub({type:w.getDuration,payload:p.duration}),E.pub({type:"success",text:n.notify.audioLoaded})},[n]),d=i.useCallback(()=>{U.pub(p.currentTime),o.current=requestAnimationFrame(d)},[]),l=i.useCallback(()=>{o.current=requestAnimationFrame(d),j.pub({type:w.pause,payload:!1})},[d]),h=i.useCallback(()=>{cancelAnimationFrame(o.current),j.pub({type:w.pause,payload:!0})},[]),u=i.useCallback(()=>{cancelAnimationFrame(o.current),j.pub({type:w.pause,payload:!0})},[]),f=i.useCallback(()=>{p.paused&&U.pub(p.currentTime)},[]),g=i.useCallback(()=>{j.pub({type:w.rateChange,payload:p.playbackRate})},[]),R=i.useCallback(y=>{const b=y.target.error,k=n.audio.error[b.code]||b.message||n.audio.error[0];E.pub({type:"warning",text:k})},[n]);return t.jsxs("footer",{className:"app-footer",children:[t.jsx("input",{id:"audio-input",type:"file",accept:ct,hidden:!0,onChange:a}),t.jsx(oe,{setAudioSrc:r,lang:n}),t.jsx("audio",{ref:p,src:s,controls:e.builtInAudio,hidden:!e.builtInAudio,onLoadedMetadata:c,onPlay:l,onPause:h,onEnded:u,onTimeUpdate:f,onRateChange:g,onError:R}),e.builtInAudio||t.jsx(he,{lang:n})]})},q=(e,n)=>{if(sessionStorage.removeItem(_.audioSrc),e){if(e.type.startsWith("audio/")){n(URL.createObjectURL(e));return}if(e.name.endsWith(".ncm")){const s=new Worker(new URL(""+new URL("ncmc-worker-94pMDdCj.js",import.meta.url).href,import.meta.url));s.addEventListener("message",r=>{if(r.data.type==="success"){const a=r.data.payload,o=new Blob([a],{type:W(a)});n(URL.createObjectURL(o))}r.data.type==="error"&&E.pub({type:"warning",text:r.data.payload})},{once:!0}),s.addEventListener("error",r=>{E.pub({type:"warning",text:r.message}),s.terminate()},{once:!0}),s.postMessage(e);return}if(/\.qmc(?:flac|0|1|2|3)$/.test(e.name)){const s=new Worker(new URL(""+new URL("qmc-worker-whNXszNT.js",import.meta.url).href,import.meta.url));s.addEventListener("message",r=>{if(r.data.type==="success"){const a=r.data.payload,o=new Blob([a],{type:W(a)});n(URL.createObjectURL(o))}},{once:!0}),s.postMessage(e)}}},N={fLaC:1716281667,OggS:1332176723,RIFF:1380533830,WAVE:1463899717},W=e=>{switch(new DataView(e.buffer).getUint32(0,!1)){case N.fLaC:return"audio/flac";case N.OggS:return"audio/ogg";case N.RIFF:case N.WAVE:return"audio/wav";default:return"audio/mpeg"}};document.addEventListener("visibilitychange",()=>{p.paused||p.toggle()});const ut=()=>{const{lang:e}=i.useContext(I,C.lang);return t.jsxs("header",{className:"app-header",children:[t.jsxs("a",{id:x.home,className:"app-title",title:e.header.home,href:S(x.home),children:[t.jsx("span",{className:"app-title-text",children:e.app.name}),t.jsx("span",{className:"app-title-svg",children:t.jsx(Te,{})})]}),t.jsxs("nav",{className:"app-nav",children:[t.jsx("a",{id:x.editor,className:"app-tab",title:e.header.editor,href:S(x.editor),children:t.jsx(Z,{})}),t.jsx("a",{id:x.synchronizer,className:"app-tab",title:e.header.synchronizer,href:S(x.synchronizer),children:t.jsx(ee,{})}),t.jsx("a",{id:x.gist,className:"app-tab",title:e.header.gist,href:S(x.gist),children:t.jsx(Ve,{})}),t.jsx("a",{id:x.preferences,className:"app-tab",title:e.header.preferences,href:S(x.preferences),children:t.jsx(Oe,{})})]})]})},dt=()=>t.jsx(i.StrictMode,{children:t.jsxs($e,{children:[t.jsx(ut,{}),t.jsx(ce,{}),t.jsx(lt,{}),t.jsx(ne,{})]})});"scrollBehavior"in document.documentElement.style||v(()=>import("./smooth-scroll-bCWoQaUd.js"),__vite__mapDeps([]),import.meta.url);J.render(i.createElement(dt),document.querySelector(".app-container"),()=>{(navigator.standalone||window.matchMedia("(display-mode: standalone)").matches)&&document.addEventListener("click",e=>{const n=e.target.getAttribute("href");(n==null?void 0:n.startsWith("#"))===!0&&(e.preventDefault(),location.replace(n))}),window.addEventListener("dragover",e=>{e.preventDefault(),e.dataTransfer.dropEffect="copy"}),window.addEventListener("drop",e=>{e.preventDefault()})});export{O as A,mt as C,ht as D,Z as E,xt as G,T as L,ft as O,i as R,_ as S,V as T,yt as U,I as a,x as b,gt as c,pt as d,Y as e,p as f,j as g,w as h,U as i,t as j,P as k,We as l,ae as m,et as n,tt as o,S as p,ee as q,C as r,Je as s,E as t,Ce as u,vt as v}; +function __vite__mapDeps(indexes) { + if (!__vite__mapDeps.viteFileDeps) { + __vite__mapDeps.viteFileDeps = ["./editor-O8LiZDmY.js","./gistapi-Ypf6w1t3.js","./lrc-file-name-sR0E2KGQ.js","./synchronizer-Te2Y3F7L.js","./gist-i1907ujF.js"] + } + return indexes.map((i) => __vite__mapDeps.viteFileDeps[i]) +} diff --git a/assets/ja-GcgVr18M.js b/assets/ja-GcgVr18M.js new file mode 100644 index 00000000..68b0731a --- /dev/null +++ b/assets/ja-GcgVr18M.js @@ -0,0 +1 @@ +const e={languageName:"日本語",app:{name:"歌詞スクロールちゃん",fullname:"あかりの歌詞スクロールちゃん"},header:{home:"ホームページ",editor:"編集",synchronizer:"同期",gist:"Github Gist",preferences:"設定"},audio:{loadAudio:"オーディオファイルを読み込む",play:"再生",pause:"停止",replay5s:"5秒戻る",forward5s:"5秒進む",resetRate:"再生速度をリセット",error:["オーディオエラー","オーディオダウンロードエラー","オーディオネットワークエラー","オーディオデコードエラー","ブラウザでサポートされていないオーディオ"]},loadAudio:{file:"ファイル",url:"URL",loadFile:"ここをクリックするか、このページにオーディオファイルをドロップしてください"},home:{tips:"プロンプト",tipForLyricText:"編集ページに切り替えて歌詞のテキストを貼り付けます。",tipForUploadAudio:"左下のボタンをクリックしてオーディオファイルをロードします。",tipForSynchronizer:"同期ページに切り替えてスクロール歌詞を作り始めます〜",tipTopLeft:"このヘルプページに戻るにはここをクリック",tipTopRight:"ページを切り替えるにはここをクリック",tipBottomLeft:"ここでオーディオをロードして再生を制御できます。",tipBottomRight:"ここでは再生速度を変更できます"},editor:{metaInfo:"メタ情報",album:"アルバム",title:"曲名",artist:"アーティスト名",uploadText:"テキストを読み込む",copyText:"すべて選択してコピー",downloadText:"ダウンロード",saveToGist:"Github Gistに保存",saveFileName:"ファイル名",utils:"lrc utils"},gist:{newTokenTip:"歌詞スクロールちゃんはGithub Gistにデータを取得して保存するためにGithubトークンを使用します",newTokenButton:"新しいGithubトークンを生成する",newGistTip:"新しいGistリポジトリを作成するか、既存のGist IDを割り当てます",newGistRepoButton:"新しいGistリポジトリを作成する",gistIdPlaceholder:"または既存のGist IDを割り当てる",info:"情報",clearTokenAndGist:"クリアトークンとGIST ID"},preferences:{version:"バージョン",commitHash:"Commit hash",updateTime:"更新時間",repo:"プロジェクトURL",help:"について&ヘルプ",language:"言語(language)",builtInAudio:"ブラウザ内蔵のオーディオプレーヤーを使用する",spaceButton:"画面上のスペースキー",themeColor:"テーマカラー",lrcFormat:"歌詞出力フォーマット制御",fixed:"タイムスタンプ小数点",leftSpace:"左側のスペース",rightSpace:"右側スペース",clearCache:"キャッシュをクリア",themeMode:{label:"テーマモード",auto:"自動",light:"ライト",dark:"ダーク"}},notify:{audioLoaded:"オーディオがロードされました"}};export{e as default}; diff --git a/assets/ko-KR-yW8HIalv.js b/assets/ko-KR-yW8HIalv.js new file mode 100644 index 00000000..f33eabdf --- /dev/null +++ b/assets/ko-KR-yW8HIalv.js @@ -0,0 +1 @@ +const e={languageName:"한국어",app:{name:"LRC 메이커",fullname:"Akari의 LRC 메이커"},header:{home:"홈",editor:"편집기",synchronizer:"동기화",gist:"Github Gist",preferences:"설정"},audio:{loadAudio:"음원 로드하기",play:"재생",pause:"일시 중지",replay5s:"5초 뒤로 가기",forward5s:"5초 건더 뛰기",resetRate:"재생 속도 다시 설정",error:["오디오 오류","사용자가 오디오를 중단됨","오디오 넷워크 오류","오디오 디코딩 오류","오디오 지원하지 앖습니다"]},loadAudio:{file:"파일",url:"링크",loadFile:"여기로 파일 선택하기 또는 오디오 파일을 이 페이지에 드롭하기"},home:{tips:"팁",tipForLyricText:"편집기 페이지에 가사 텍스트를 붙여넣기.",tipForUploadAudio:"왼쪽 하단에는 버튼 클릭하면 오디오 파일 로드하기.",tipForSynchronizer:"동기화 페이기에 당신의 가사를 만드세요 :)",tipTopLeft:"에기에 클릭하면 이 페이지 돌아와세요",tipTopRight:"에기에 다른 페이지 탐색하세요",tipBottomLeft:"여기에 오리오를 로드하고 제어하세요",tipBottomRight:"여기에 재생 속도를 조정하세요"},editor:{metaInfo:"메타 정보",album:"앨범",title:"트랙 이름",artist:"아티스트",uploadText:"텍스트 업로드",copyText:"모두 선택 및 복사",downloadText:"다운로드",saveToGist:"GitHub Gist에 저장하기",saveFileName:"파일 이름",utils:"lrc 도구"},gist:{newTokenTip:"LRC 메이커는 GitHub 토큰으로 GitHub Gist 에서 데이터를 접근하고 저장합니다",newTokenButton:"새로운 GitHub 토큰 생성하기",newGistTip:"Create a new Gist repository or assign an existing Gist id",newGistRepoButton:"Create a new Gist Repository",gistIdPlaceholder:"Or assign an existing Gist id",info:"info",clearTokenAndGist:"Clear token and Gist id"},preferences:{version:"버전",commitHash:"토밋 헤시",updateTime:"업데이트 시간",repo:"저장고",help:"도움말 및 팁",language:"언어(language)",builtInAudio:"브라우저 빌트인 오디오 재생기 사용하기",spaceButton:"온 스크린 스페이스 키",themeColor:"모양색",lrcFormat:"LRC 포멧 조정",fixed:"타임 스템 고치됨",leftSpace:"왼쪽 스페이스",rightSpace:"오른쪽 스페이스",clearCache:"캐시 제거",themeMode:{label:"모양 모드",auto:"자동",light:"라이트",dark:"다크"}},notify:{audioLoaded:"음원 로드됨"}};export{e as default}; diff --git a/assets/lrc-file-name-sR0E2KGQ.js b/assets/lrc-file-name-sR0E2KGQ.js new file mode 100644 index 00000000..b368451c --- /dev/null +++ b/assets/lrc-file-name-sR0E2KGQ.js @@ -0,0 +1 @@ +const i=t=>t.replace(/[<>:"/\\|?*]/g,"_").trim(),l=t=>{const e=[t.get("ti"),t.get("ar")].filter(a=>!!a);return e.length===0&&(t.has("al")&&e.push(t.get("al")),e.push(new Date().toLocaleString())),e.map(a=>i(a)).join(" - ")+".lrc"};export{l}; diff --git a/assets/ncmc-worker-94pMDdCj.js b/assets/ncmc-worker-94pMDdCj.js new file mode 100644 index 00000000..3fc3e0da --- /dev/null +++ b/assets/ncmc-worker-94pMDdCj.js @@ -0,0 +1 @@ +(function(){"use strict";const i=self,A=Uint8Array.of(104,122,72,82,65,109,115,111,53,107,73,110,98,97,120,87),g=async(f,y)=>{const l={name:"AES-CBC",iv:new Uint8Array(16)},s=await crypto.subtle.importKey("raw",f,"AES-CBC",!1,["encrypt","decrypt"]),n=y.byteLength-16,u=y.slice(n),d=await crypto.subtle.decrypt(l,s,u),a=new Uint8Array(n+d.byteLength);a.set(new Uint8Array(d),n);const e=new Uint8Array(16);e.fill(16);const c=new Uint8Array(32);for(let t=0;t{const y=f.data,l=new FileReaderSync().readAsArrayBuffer(y),s=new DataView(l);(s.getUint32(0,!0)!==1313166403||s.getUint32(4,!0)!==1296122950)&&(i.postMessage({type:"error",payload:"not ncm file"}),i.close());let n=10;const u=(await(()=>{const e=s.getUint32(n,!0);n+=4;const c=new Uint8Array(l,n,e).map(t=>t^100);return n+=e,g(A,c)})()).slice(17),d=(()=>{const e=new Uint8Array(Array(256).keys()),c=u.length;let t=0;for(let r=0;r<256;r++)t=e[r]+t+u[r%c]&255,[e[r],e[t]]=[e[t],e[r]];return e.map((r,o,p)=>{o=o+1&255;const w=p[o],U=p[o+w&255];return p[w+U&255]})})();n+=s.getUint32(n,!0)+4,n+=s.getUint32(n+5,!0)+13;const a=(()=>{const e=new Uint8Array(l,n),c=e.length;for(let t=0;tPromise.all(n.filter(a=>a.startsWith(l)).map(async a=>caches.delete(a)))),await navigator.serviceWorker.getRegistration().then(n=>{n&&n.unregister().then(()=>{location.reload()})}))}var z=[["en-US","English"],["ja","日本語"],["ko-KR","한국어"],["pt-BR","Português"],["zh-CN","简体中文"],["zh-HK","繁體中文(香港)"],["zh-TW","繁體中文"]],d={hash:"a5d1f60",updateTime:"2024-01-28T06:09:02+00:00",version:"5.6.10"};const D={type:"number",step:1},b=(l,n)=>{const a=r.useRef(null);r.useEffect(()=>{const c=a.current;if(c){const i=()=>{c.value=l.toString()};return c.addEventListener("change",i),()=>c.removeEventListener("change",i)}},[l]);const h=r.useCallback(c=>{c.target.validity.valid&&n(c)},[n]);return{...D,ref:a,onChange:h,defaultValue:l}},q=z,H=()=>{const{prefState:l,prefDispatch:n,lang:a}=r.useContext(R,f.lang||f.prefState),h=r.useCallback(s=>{n({type:"themeColor",payload:s.target.value})},[n]),c=r.useRef(null),i=r.useCallback(s=>{let t=s.value;if(!s.validity.valid){s.value=s.defaultValue;return}t.length===3&&(t=[].map.call(t,o=>o+o).join("")),t.length<6&&(t=t.padEnd(6,"0")),n({type:"themeColor",payload:"#"+t})},[n]),C=r.useCallback(s=>i(s.target),[i]),k=r.useCallback(s=>{s.preventDefault();const o=s.target.elements.namedItem("user-color-input-text");return i(o)},[i]);r.useEffect(()=>{c.current.value=l.themeColor.slice(1)},[l.themeColor]);const p=r.useCallback(s=>{n({type:s.target.name,payload:s.target.value})},[n]),v=r.useCallback(()=>{W()},[]),N=r.useMemo(()=>{const s=new Date(d.updateTime),t={year:"numeric",month:"short",day:"numeric",hour:"numeric",minute:"numeric",second:"numeric",timeZoneName:"short",hour12:!1};return new Intl.DateTimeFormat(l.lang,t).format(s)},[l.lang]),y=r.useCallback(s=>{n({type:"lang",payload:s.target.value})},[n]),T=r.useCallback(()=>n({type:"builtInAudio",payload:s=>!s.builtInAudio}),[n]),I=r.useCallback(()=>n({type:"screenButton",payload:s=>!s.screenButton}),[n]),M=r.useCallback(s=>{n({type:"themeMode",payload:Number.parseInt(s.target.value,10)})},[n]),S=r.useCallback(s=>{n({type:"fixed",payload:Number.parseInt(s.target.value,10)})},[n]),w=r.useMemo(()=>q.map(([s,t])=>e.jsx("option",{value:s,children:t},s)),[]),E=r.useMemo(()=>Object.values(_).map(s=>{const t=s===l.themeColor,o=["color-picker","ripple"];return t&&o.push("checked"),e.jsx("label",{className:o.join(A.space),style:{backgroundColor:s},children:e.jsx("input",{hidden:!0,type:"radio",name:"theme-color",value:s,checked:t,onChange:h})},s)}),[h,l.themeColor]),m=r.useMemo(()=>({backgroundColor:l.themeColor}),[l.themeColor]),B=r.useMemo(()=>P(" hello 世界~ ",l.spaceStart,l.spaceEnd),[l.spaceStart,l.spaceEnd]),x=r.useRef(null),j=r.useRef(null);return r.useEffect(()=>{j.current.type==="color"&&x.current.removeAttribute("for")},[]),e.jsxs("div",{className:"preferences",children:[e.jsxs("ul",{children:[e.jsx("li",{children:e.jsxs("section",{className:"list-item",children:[e.jsx("span",{children:a.preferences.version}),e.jsx("span",{className:"select-all",children:d.version})]})}),e.jsx("li",{children:e.jsxs("section",{className:"list-item",children:[e.jsx("span",{children:a.preferences.commitHash}),e.jsx("span",{className:"select-all",children:d.hash})]})}),e.jsx("li",{children:e.jsxs("section",{className:"list-item",children:[e.jsx("span",{children:a.preferences.updateTime}),e.jsx("span",{children:N})]})}),e.jsx("li",{children:e.jsxs("section",{className:"list-item",children:[e.jsx("span",{children:a.preferences.repo}),e.jsx("a",{className:"link",href:g.url,target:"_blank",rel:"noopener noreferrer",children:"Github"})]})}),e.jsx("li",{children:e.jsxs("section",{className:"list-item",children:[e.jsx("span",{children:a.preferences.help}),e.jsx("a",{className:"link",href:g.wiki,target:"_blank",rel:"noopener noreferrer",children:"Github Wiki"})]})}),e.jsx("li",{children:e.jsxs("section",{className:"list-item",children:[e.jsx("span",{children:a.preferences.language}),e.jsx("div",{className:"option-select",children:e.jsx("select",{value:l.lang,onChange:y,"aria-label":a.preferences.language,children:w})})]})}),e.jsx("li",{children:e.jsxs("label",{className:"list-item",children:[e.jsx("span",{children:a.preferences.builtInAudio}),e.jsxs("label",{className:"toggle-switch",children:[e.jsx("input",{type:"checkbox",checked:l.builtInAudio,onChange:T,"aria-label":a.preferences.builtInAudio}),e.jsx("span",{className:"toggle-switch-label"})]})]})}),e.jsx("li",{children:e.jsxs("label",{className:"list-item",children:[e.jsx("span",{children:a.preferences.spaceButton}),e.jsxs("label",{className:"toggle-switch",children:[e.jsx("input",{type:"checkbox",checked:l.screenButton,onChange:I,"aria-label":a.preferences.spaceButton}),e.jsx("span",{className:"toggle-switch-label"})]})]})}),e.jsx("li",{children:e.jsxs("section",{className:"list-item",children:[e.jsx("span",{children:a.preferences.themeMode.label}),e.jsx("div",{className:"option-select",children:e.jsxs("select",{name:"theme-mode",value:l.themeMode,onChange:M,"aria-label":a.preferences.themeMode.label,children:[e.jsx("option",{value:u.auto,children:a.preferences.themeMode.auto}),e.jsx("option",{value:u.light,children:a.preferences.themeMode.light}),e.jsx("option",{value:u.dark,children:a.preferences.themeMode.dark})]})})]})}),e.jsx("li",{children:e.jsxs("section",{className:"list-item",children:[e.jsx("span",{children:a.preferences.themeColor}),e.jsxs("details",{className:"dropdown",children:[e.jsxs("summary",{children:[e.jsx("span",{className:"color-picker ripple hash",style:m,children:"#"}),e.jsx("span",{className:"current-theme-color",children:l.themeColor.slice(1)})]}),e.jsxs("form",{className:"dropdown-body color-wall",onSubmit:k,children:[E,e.jsxs("label",{className:"color-picker ripple user-color-label hash",htmlFor:"user-color-input-text",style:m,ref:x,children:["#",e.jsx("input",{type:"color",className:"color-picker pseudo-hidden",value:l.themeColor,onChange:h,ref:j})]}),e.jsx("input",{ref:c,id:"user-color-input-text",name:"user-color-input-text",className:"user-color-input-text",type:"text",pattern:"[\\da-f]{3,6}",required:!0,autoCapitalize:"none",autoComplete:"off",autoCorrect:"off",spellCheck:!1,defaultValue:l.themeColor.slice(1),onBlur:C})]})]})]})}),e.jsx("li",{children:e.jsxs("section",{className:"list-item",children:[e.jsx("span",{children:a.preferences.lrcFormat}),e.jsxs("span",{children:[e.jsx("time",{className:"format-example-time",children:F(83.456,l.fixed)}),e.jsx("span",{className:"format-example-text",children:B})]})]})}),e.jsx("li",{children:e.jsxs("section",{className:"list-item",children:[e.jsx("span",{children:a.preferences.fixed}),e.jsx("div",{className:"option-select",children:e.jsxs("select",{name:"fixed",value:l.fixed,onChange:S,"aria-label":a.preferences.lrcFormat,children:[e.jsx("option",{value:0,children:"0"}),e.jsx("option",{value:1,children:"1"}),e.jsx("option",{value:2,children:"2"}),e.jsx("option",{value:3,children:"3"})]})})]})}),e.jsx("li",{children:e.jsxs("label",{className:"list-item",children:[e.jsx("label",{htmlFor:"space-start",children:a.preferences.leftSpace}),e.jsx("input",{name:"spaceStart",id:"space-start",required:!0,min:-1,...b(l.spaceStart,p)})]})}),e.jsx("li",{children:e.jsxs("label",{className:"list-item",children:[e.jsx("label",{htmlFor:"space-end",children:a.preferences.rightSpace}),e.jsx("input",{name:"spaceEnd",id:"space-end",required:!0,min:-1,...b(l.spaceEnd,p)})]})}),e.jsx("li",{className:"ripple",onTransitionEnd:v,children:e.jsx("section",{className:"list-item",children:a.preferences.clearCache})})]}),e.jsx(L,{})]})};export{H as Preferences}; diff --git a/assets/pt-BR-DSi-64D4.js b/assets/pt-BR-DSi-64D4.js new file mode 100644 index 00000000..78d73ea6 --- /dev/null +++ b/assets/pt-BR-DSi-64D4.js @@ -0,0 +1 @@ +const e={languageName:"Português",app:{name:"Criador de LRC",fullname:"Criador de LRC de Akari"},header:{home:"início",editor:"editor",synchronizer:"sincronizador",gist:"Github Gist",preferences:"preferências"},audio:{loadAudio:"carregar áudio",play:"play",pause:"pausar",replay5s:"repetir 5s",forward5s:"avançar 5s",resetRate:"redefinir a taxa de reprodução",error:["erro de áudio","áudio abortado pelo usuário","erro de rede de áudio","erro de decodificação de áudio","áudio não suportado"]},loadAudio:{file:"Arquivo",url:"URL",loadFile:"Clique aqui ou solte um arquivo de áudio nesta página"},home:{tips:"Dicas",tipForLyricText:"Navegue até a página do editor e cole o texto da letra.",tipForUploadAudio:"Clique no botão inferior esquerdo para carregar o arquivo de áudio.",tipForSynchronizer:"Navegue até a página do sincronizador e faça seu lrc :)",tipTopLeft:"Clique aqui para voltar a esta página",tipTopRight:"Clique aqui para navegar para outra página",tipBottomLeft:"carregue o áudio aqui e controle o áudio",tipBottomRight:"altere a taxa de reprodução aqui"},editor:{metaInfo:"informações meta",album:"álbum",title:"título",artist:"artista",uploadText:"enviar texto",copyText:"selecione tudo e copie",downloadText:"baixar",saveToGist:"salvar no Github Gist",saveFileName:"Nome do arquivo",utils:"lrc utils"},gist:{newTokenTip:"o Criador de LRC usa o Token do Github para recolher e armazenar dados para o Github Gist",newTokenButton:"Gerar um novo Token do Github",newGistTip:"Criar um novo repositório Gist ou atribuir um id Gist existente",newGistRepoButton:"Criar um novo Repositório Gist",gistIdPlaceholder:"Ou atribuir um id Gist existente",info:"informação",clearTokenAndGist:"Limpar Token e id Gist"},preferences:{version:"Versão",commitHash:"Commit hash",updateTime:"Tempo de atualização",repo:"Repositório",help:"Ajuda e dicas",language:"Linguagem",builtInAudio:"Use o player de áudio integrado do navegador",spaceButton:"Tecla de espaço na tela",themeColor:"Cor do tema",lrcFormat:"Ajuste de formato LRC",fixed:"Data-de-tempo fixo",leftSpace:"Espaço esquerdo",rightSpace:"Espaço direito",clearCache:"Limpar cache",themeMode:{label:"Modo de tema",auto:"auto",light:"claro",dark:"escuro"}},notify:{audioLoaded:"Áudio carregado"}};export{e as default}; diff --git a/assets/qmc-worker-whNXszNT.js b/assets/qmc-worker-whNXszNT.js new file mode 100644 index 00000000..67c78f6a --- /dev/null +++ b/assets/qmc-worker-whNXszNT.js @@ -0,0 +1 @@ +(function(){"use strict";const s=self,n=[195,74,214,202,144,103,247,82,216,161,102,98,159,91,9,0,195,94,149,35,159,19,17,126,216,146,63,188,144,187,116,14,195,71,116,61,144,170,63,81,216,244,17,132,159,222,149,29,195,198,9,213,159,250,102,249,216,240,247,160,144,161,214,243];s.addEventListener("message",a=>{const c=a.data,f=new FileReaderSync().readAsArrayBuffer(c),r=new Uint8Array(f).map((o,t)=>{let e=(t>32767?t%32767:t)&127;return e>63&&(e=128-e&63),o^n[e]});s.postMessage({type:"success",payload:r},[r.buffer]),s.close()})})(); diff --git a/assets/smooth-scroll-bCWoQaUd.js b/assets/smooth-scroll-bCWoQaUd.js new file mode 100644 index 00000000..8f983d53 --- /dev/null +++ b/assets/smooth-scroll-bCWoQaUd.js @@ -0,0 +1 @@ +const f=(()=>{const u=performance||Date,v=t=>.5*(1-Math.cos(Math.PI*t)),i={current:0},n=()=>{cancelAnimationFrame(i.current),d()},w={passive:!0,once:!0},E=()=>{window.addEventListener("wheel",n,w),window.addEventListener("touchmove",n,w)},d=()=>{window.removeEventListener("wheel",n),window.removeEventListener("touchmove",n)},h=t=>{const a=u.now(),{startTime:l,startX:o,startY:s,stopY:e}=t,r=(a-l)/468;if(r>=1){t.method(o,e),d();return}const m=v(r),c=s+(e-s)*m;t.method(o,c),c!==e&&(i.current=requestAnimationFrame(()=>h(t)))},p=document.scrollingElement||document.documentElement;Element.prototype.scrollIntoView=function(){const{top:t,bottom:a}=this.getBoundingClientRect(),l=(t+a)/2,o=window.visualViewport?window.visualViewport.height:innerHeight,s=p.scrollLeft,e=p.scrollTop,r=e+l-o/2;cancelAnimationFrame(i.current),E(),h({method:(m,c)=>window.scroll(m,c),startTime:u.now(),startX:s,startY:e,stopY:r})}})();export{f as default}; diff --git a/assets/synchronizer-Te2Y3F7L.js b/assets/synchronizer-Te2Y3F7L.js new file mode 100644 index 00000000..e44943cb --- /dev/null +++ b/assets/synchronizer-Te2Y3F7L.js @@ -0,0 +1 @@ +import{R as n,A as p,s as G,j as r,d as V,D as H,e as I,f as d,g as J,h as E,i as K,k as P,a as M,S as R,l as W,m as $}from"./index-o0wXbvYb.js";import{l as q}from"./lrc-file-name-sR0E2KGQ.js";const L=n.memo(({syncMode:s,setSyncMode:t,lrcDispatch:b,prefState:o})=>{const[i,g]=n.useState(),[f,x]=n.useState(),u=n.useCallback(()=>{t(k=>k===D.select?D.highlight:D.select)},[t]),j=n.useCallback(()=>{b({type:p.getState,payload:k=>{const S=G(k,o);g(w=>(w&&URL.revokeObjectURL(w),URL.createObjectURL(new Blob([S],{type:"text/plain;charset=UTF-8"})))),x(q(k.info))}})},[b,o]),C=s===D.select?"select":"highlight",T=["aside-button","syncmode-button","ripple","glow ",C].join(I.space);return r.jsxs("aside",{className:"aside-panel",children:[r.jsx("button",{className:T,onClick:u,"aria-label":`${C} mode`,children:r.jsx(V,{})}),r.jsx("a",{href:i,download:f,className:"aside-button ripple glow",onClick:j,children:r.jsx(H,{})})]})});L.displayName=L.name;const U=({fixed:s})=>{const t=n.useRef(Symbol(U.name)),[b,o]=n.useState(d.currentTime),[i,g]=n.useState(d.paused),[f,x]=n.useState(d.playbackRate);return n.useEffect(()=>J.sub(t.current,u=>{switch(u.type){case E.pause:{g(u.payload);break}case E.rateChange:{x(u.payload);break}}}),[]),n.useEffect(()=>{const u=[1,10,100,1e3][s]*f;if(i||2*u>60)return K.sub(t.current,j=>{o(j)});{const j=setInterval(()=>{o(d.currentTime)},1e3/(2*u));return()=>{clearInterval(j)}}},[s,i,f]),r.jsx("time",{className:"curser",children:P(b,s)})},z=({sync:s})=>r.jsx("button",{className:"space-button",onClick:s,children:"space"});var D=(s=>(s[s.select=0]="select",s[s.highlight=1]="highlight",s))(D||{});const _=({state:s,dispatch:t})=>{const b=n.useRef(Symbol(_.name)),{selectIndex:o,currentIndex:i,lyric:g}=s,{prefState:f,lang:x}=n.useContext(M);n.useEffect(()=>{t({type:p.info,payload:{name:"tool",value:`${x.app.name} https://lrc-maker.github.io`}})},[t,x]);const[u,j]=n.useState(()=>sessionStorage.getItem(R.syncMode)===1 .toString()?1:0);n.useEffect(()=>{sessionStorage.setItem(R.syncMode,u.toString())},[u]);const C=n.useRef(null),T={0:o,1:i}[u];n.useEffect(()=>{var e;const a=(e=C.current)==null?void 0:e.children[T];a!==void 0&&a.scrollIntoView({behavior:"smooth",block:"center",inline:"center"})},[T]),n.useEffect(()=>K.sub(b.current,a=>{t({type:p.refresh,payload:a})}),[t]);const k=n.useCallback(()=>{d.duration&&t({type:p.next,payload:d.currentTime})},[t]),S=n.useCallback((a,e,l)=>{var h;if(!d.duration)return;const c=(h=g[l])==null?void 0:h.time;c!==void 0&&t({type:p.time,payload:d.step(a,e,c)})},[t,g]);n.useEffect(()=>{function a(e){const{code:l,key:c,target:h}=e,m=l||c;if(!$(h)){if(m==="Backspace"||m==="Delete"||m==="Del"){e.preventDefault(),t({type:p.deleteTime,payload:void 0});return}if(l==="Digit0"||c==="0"){e.preventDefault(),S(e,0,o);return}if(l==="Minus"||c==="-"||c==="_"){e.preventDefault(),S(e,-.5,o);return}if(l==="Equal"||c==="+"||c==="="){e.preventDefault(),S(e,.5,o);return}e.metaKey||e.ctrlKey||(l==="Space"||c===" "||c==="Spacebar"?(e.preventDefault(),k()):["ArrowUp","KeyW","KeyJ","Up","W","w","J","j"].includes(m)?(e.preventDefault(),t({type:p.select,payload:y=>y-1})):["ArrowDown","KeyS","KeyK","Down","S","s","K","k"].includes(m)?(e.preventDefault(),t({type:p.select,payload:y=>y+1})):m==="Home"?(e.preventDefault(),t({type:p.select,payload:()=>0})):m==="End"?(e.preventDefault(),t({type:p.select,payload:()=>1/0})):m==="PageUp"?(e.preventDefault(),t({type:p.select,payload:y=>y-10})):m==="PageDown"&&(e.preventDefault(),t({type:p.select,payload:y=>y+10})))}}return document.addEventListener("keydown",a),()=>{document.removeEventListener("keydown",a)}},[S,t,o,k]);const w=n.useCallback(a=>{a.stopPropagation();const e=a.target;if(e.classList.contains("line")){const l=Number.parseInt(e.dataset.key,10)||0;t({type:p.select,payload:()=>l})}},[t]),A=n.useCallback(a=>{if(a.stopPropagation(),!d.duration)return;const e=a.target;if(e.classList.contains("line")){const l=Number.parseInt(e.dataset.key,10);S(a,0,l)}},[S]),B=n.useCallback((a,e,l)=>{const c=e===o,h=e===i,m=e>0&&l[e].time<=l[e-1].time,y=Object.entries({line:!0,select:c,highlight:h,error:m}).reduce((N,[O,F])=>(F&&N.push(O),N),[]).join(I.space);return r.jsx(Q,{index:e,className:y,line:a,select:c,prefState:f},e)},[o,i,f]),v=f.screenButton?"lyric-list on-screen-button":"lyric-list";return r.jsxs(r.Fragment,{children:[r.jsx("ul",{ref:C,className:v,onClickCapture:w,onDoubleClickCapture:A,children:s.lyric.map(B)}),r.jsx(L,{syncMode:u,setSyncMode:j,lrcDispatch:t,prefState:f}),f.screenButton&&r.jsx(z,{sync:k})]})},Q=({line:s,index:t,select:b,className:o,prefState:i})=>{const g=P(s.time,i.fixed),f=W(s.text,i.spaceStart,i.spaceEnd);return r.jsxs("li",{"data-key":t,className:o,children:[b&&r.jsx(U,{fixed:i.fixed}),r.jsx("time",{className:"line-time",children:g}),r.jsx("span",{className:"line-text",children:f})]},t)};export{D as SyncMode,_ as Synchronizer}; diff --git a/assets/zh-CN-IS2wiGhF.js b/assets/zh-CN-IS2wiGhF.js new file mode 100644 index 00000000..7fd681d3 --- /dev/null +++ b/assets/zh-CN-IS2wiGhF.js @@ -0,0 +1 @@ +const e={languageName:"简体中文",app:{name:"歌词滚动姬",fullname:"灯里的歌词滚动姬"},header:{home:"主页",editor:"编辑",synchronizer:"打轴",gist:"Github Gist",preferences:"设置"},audio:{loadAudio:"加载音频",play:"播放",pause:"暂停",replay5s:"后退 5 秒",forward5s:"前进 5 秒",resetRate:"重置播放速度",error:["音频错误","音频请求被用户终止","音频网络请求错误","音频解码错误","浏览器无法支持此音频格式"]},loadAudio:{file:"文件",url:"外链",loadFile:"点击这里或直接拖放音频到这个页面"},home:{tips:"提示",tipForLyricText:"切换到编辑页面,粘贴歌词文本。",tipForUploadAudio:"点击左下方按钮,载入音频文件。",tipForSynchronizer:"切换到打轴页面,开始制作滚动歌词吧~",tipTopLeft:"点击这里可以回到这个帮助页面",tipTopRight:"点击这里切换页面",tipBottomLeft:"这里可以加载音频,控制播放",tipBottomRight:"这里可以调节播放速度"},editor:{metaInfo:"元信息",album:"所属专辑",title:"歌曲名",artist:"艺人名",uploadText:"加载文本",copyText:"全选复制",downloadText:"下载",saveToGist:"保存到 Github Gist",saveFileName:"文件名",utils:"实用工具"},gist:{newTokenTip:"歌词滚动姬使用 Github Token 来存取 Github Gist 上的数据",newTokenButton:"生成新的 Github Token",newGistTip:"创建一个新的 Gist 仓库或指定一个已存在的 Gist id",newGistRepoButton:"创建一个新的 Gist 仓库",gistIdPlaceholder:"或指定一个已存在的 Gist id",info:"信息",clearTokenAndGist:"清除 Github Token 和 Gist id"},preferences:{version:"版本",commitHash:"Commit hash",updateTime:"更新时间",repo:"项目地址",help:"关于 & 帮助",language:"语言(language)",builtInAudio:"使用浏览器内建音频播放器",spaceButton:"启用虚拟空格键",themeColor:"主题颜色",lrcFormat:"歌词输出格式控制",fixed:"时间标签小数点",leftSpace:"左侧空格",rightSpace:"右侧空格",clearCache:"清除缓存",themeMode:{label:"主题模式",auto:"跟随系统",light:"亮色模式",dark:"暗色模式"}},notify:{audioLoaded:"音频已载入"}};export{e as default}; diff --git a/assets/zh-HK--aRTSL7g.js b/assets/zh-HK--aRTSL7g.js new file mode 100644 index 00000000..021a2759 --- /dev/null +++ b/assets/zh-HK--aRTSL7g.js @@ -0,0 +1 @@ +const e={languageName:"繁體中文(香港)",app:{name:"歌詞滾動姬",fullname:"小明的歌詞滾動姬"},header:{home:"主頁",editor:"編輯",synchronizer:"同步",gist:"Github Gist",preferences:"設定"},audio:{loadAudio:"匯入音訊",play:"播放",pause:"暫停",replay5s:"倒轉 5s",forward5s:"快轉 5s",resetRate:"重設播放速度",error:["音訊錯誤","音訊請求被用戶終止","音訊網絡請求錯誤","音訊解碼錯誤","瀏覽器無法支援此音訊格式"]},loadAudio:{file:"檔案",url:"URL",loadFile:"點選這裏或直接拖放音訊檔案到這個頁面"},home:{tips:"提示",tipForLyricText:"切換到編輯頁面,黏貼歌詞文本。",tipForUploadAudio:"點選左下方按鈕,匯入音訊檔案。",tipForSynchronizer:"切換到同步頁面,開始製作滾動歌詞吧~",tipTopLeft:"點選這裏可以回到這個幫助頁面",tipTopRight:"點選這裏切換頁面",tipBottomLeft:"這裏可以加載音訊,控制播放",tipBottomRight:"這裏可以調節播放速度"},editor:{metaInfo:"元數據",album:"所屬專輯",title:"歌曲名",artist:"藝人名",uploadText:"匯入文本",copyText:"全選拷貝",downloadText:"下載",saveToGist:"保存到 Github Gist",saveFileName:"檔名",utils:"實用工具"},gist:{newTokenTip:"歌詞滾動姬使用 Github Token 來存取 Github Gist 上的數據",newTokenButton:"生成新的 Github Token",newGistTip:"創建一個新的 Gist 儲存庫或指定一個已存在的 Gist id",newGistRepoButton:"創建一個新的 Gist 儲存庫",gistIdPlaceholder:"或指定一個已存在的 Gist id",info:"資訊",clearTokenAndGist:"清除 Github Token 和 Gist id"},preferences:{version:"版本",commitHash:"Commit hash",updateTime:"更新時間",repo:"專案地址",help:"關於 & 幫助",language:"語言(language)",builtInAudio:"使用瀏覽器內建音訊播放器",spaceButton:"啓用螢幕 Space 鍵",themeColor:"主題顏色",lrcFormat:"歌詞輸出格式控制",fixed:"時間標籤小數點",leftSpace:"左側空格",rightSpace:"右側空格",clearCache:"清除快取",themeMode:{label:"主題模式",auto:"跟隨系統",light:"亮色模式",dark:"暗色模式"}},notify:{audioLoaded:"音訊已匯入"}};export{e as default}; diff --git a/assets/zh-TW-FFP4ehVz.js b/assets/zh-TW-FFP4ehVz.js new file mode 100644 index 00000000..ec1aab36 --- /dev/null +++ b/assets/zh-TW-FFP4ehVz.js @@ -0,0 +1 @@ +const e={languageName:"繁體中文",app:{name:"歌詞滾動姬",fullname:"小明的歌詞滾動姬"},header:{home:"主頁",editor:"編輯",synchronizer:"同步",gist:"Github Gist",preferences:"設定"},audio:{loadAudio:"匯入音訊",play:"播放",pause:"暫停",replay5s:"倒轉 5s",forward5s:"快轉 5s",resetRate:"重設播放速度",error:["音訊錯誤","音訊請求被用戶終止","音訊網路請求錯誤","音訊解碼錯誤","瀏覽器無法支援此音訊格式"]},loadAudio:{file:"檔案",url:"URL",loadFile:"點選這裡或直接拖放音訊檔案到這個頁面"},home:{tips:"提示",tipForLyricText:"切換到編輯頁面,黏貼歌詞文本。",tipForUploadAudio:"點選左下方按鈕,匯入音訊檔案。",tipForSynchronizer:"切換到同步頁面,開始製作滾動歌詞吧~",tipTopLeft:"點選這裡可以回到這個幫助頁面",tipTopRight:"點選這裡切換頁面",tipBottomLeft:"這裡可以加載音訊,控制播放",tipBottomRight:"這裡可以調節播放速度"},editor:{metaInfo:"元數據",album:"所屬專輯",title:"歌曲名",artist:"藝人名",uploadText:"匯入文本",copyText:"全選拷貝",downloadText:"下載",saveToGist:"保存到 Github Gist",saveFileName:"檔名",utils:"實用工具"},gist:{newTokenTip:"歌詞滾動姬使用 Github Token 來存取 Github Gist 上的數據",newTokenButton:"生成新的 Github Token",newGistTip:"創建一個新的 Gist 儲存庫或指定一個已存在的 Gist id",newGistRepoButton:"創建一個新的 Gist 儲存庫",gistIdPlaceholder:"或指定一個已存在的 Gist id",info:"資訊",clearTokenAndGist:"清除 Github Token 和 Gist id"},preferences:{version:"版本",commitHash:"Commit hash",updateTime:"更新時間",repo:"專案地址",help:"關於 & 幫助",language:"語言(language)",builtInAudio:"使用瀏覽器內建音訊播放器",spaceButton:"啓用螢幕 Space 鍵",themeColor:"主題顏色",lrcFormat:"歌詞輸出格式控制",fixed:"時間標籤小數點",leftSpace:"左側空格",rightSpace:"右側空格",clearCache:"清除快取",themeMode:{label:"主題模式",auto:"跟隨系統",light:"亮色模式",dark:"暗色模式"}},notify:{audioLoaded:"音訊已匯入"}};export{e as default}; diff --git a/favicons/android-chrome-192x192.png b/favicons/android-chrome-192x192.png new file mode 100644 index 00000000..c2c2f361 Binary files /dev/null and b/favicons/android-chrome-192x192.png differ diff --git a/favicons/android-chrome-512x512.png b/favicons/android-chrome-512x512.png new file mode 100644 index 00000000..7b1b2844 Binary files /dev/null and b/favicons/android-chrome-512x512.png differ diff --git a/favicons/apple-touch-icon.png b/favicons/apple-touch-icon.png new file mode 100644 index 00000000..3287c390 Binary files /dev/null and b/favicons/apple-touch-icon.png differ diff --git a/favicons/browserconfig.xml b/favicons/browserconfig.xml new file mode 100644 index 00000000..fb113953 --- /dev/null +++ b/favicons/browserconfig.xml @@ -0,0 +1,10 @@ + + + + + + + #ffffff + + + diff --git a/favicons/favicon-16x16.png b/favicons/favicon-16x16.png new file mode 100644 index 00000000..c9f66488 Binary files /dev/null and b/favicons/favicon-16x16.png differ diff --git a/favicons/favicon-32x32.png b/favicons/favicon-32x32.png new file mode 100644 index 00000000..715ebaaa Binary files /dev/null and b/favicons/favicon-32x32.png differ diff --git a/favicons/favicon.ico b/favicons/favicon.ico new file mode 100644 index 00000000..15b682fc Binary files /dev/null and b/favicons/favicon.ico differ diff --git a/favicons/mstile-150x150.png b/favicons/mstile-150x150.png new file mode 100644 index 00000000..99783a85 Binary files /dev/null and b/favicons/mstile-150x150.png differ diff --git a/favicons/mstile-310x310.png b/favicons/mstile-310x310.png new file mode 100644 index 00000000..eaeac22b Binary files /dev/null and b/favicons/mstile-310x310.png differ diff --git a/favicons/safari-pinned-tab.svg b/favicons/safari-pinned-tab.svg new file mode 100644 index 00000000..10422113 --- /dev/null +++ b/favicons/safari-pinned-tab.svg @@ -0,0 +1 @@ + diff --git a/index.html b/index.html new file mode 100644 index 00000000..6f51d799 --- /dev/null +++ b/index.html @@ -0,0 +1,54 @@ + + + + + LRC Maker + + + + + + + + + + + + + + + + + + + + + + + +
+
+ loading +
+
+ + + diff --git a/site.webmanifest b/site.webmanifest new file mode 100644 index 00000000..1c5428f3 --- /dev/null +++ b/site.webmanifest @@ -0,0 +1,31 @@ +{ + "background_color": "#f1f3f4", + "description": "歌词滚动姬|可能是你所能见到的最好用的歌词制作工具", + "display": "standalone", + "icons": [ + { + "sizes": "192x192", + "src": "./favicons/android-chrome-192x192.png", + "type": "image/png" + }, + { + "sizes": "512x512", + "src": "./favicons/android-chrome-512x512.png", + "type": "image/png" + } + ], + "name": "灯里的歌词滚动姬", + "short_name": "歌词滚动姬", + "start_url": "./", + "theme_color": "#484848", + "share_target": { + "action": "./", + "method": "GET", + "enctype": "application/x-www-form-urlencoded", + "params": { + "title": "title", + "text": "text", + "url": "url" + } + } +} diff --git a/svg/akari-hide-wall.svg b/svg/akari-hide-wall.svg new file mode 100644 index 00000000..4aa12221 --- /dev/null +++ b/svg/akari-hide-wall.svg @@ -0,0 +1,31 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/svg/akari-not-found.svg b/svg/akari-not-found.svg new file mode 100644 index 00000000..5b96408f --- /dev/null +++ b/svg/akari-not-found.svg @@ -0,0 +1,3 @@ + + + \ No newline at end of file diff --git a/svg/akari-odango-loading.svg b/svg/akari-odango-loading.svg new file mode 100644 index 00000000..5189648f --- /dev/null +++ b/svg/akari-odango-loading.svg @@ -0,0 +1,45 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/sw.js b/sw.js new file mode 100644 index 00000000..6c15ca03 --- /dev/null +++ b/sw.js @@ -0,0 +1 @@ +var n={hash:"a5d1f60",updateTime:"2024-01-28T06:09:02+00:00",version:"5.6.10"};const r=self,a="akari-lrc-maker",u=n.version,l=n.hash,c=`${a}-${u}-${l}`;r.addEventListener("install",()=>{r.skipWaiting()});r.addEventListener("activate",t=>{t.waitUntil(caches.keys().then(s=>Promise.all([r.clients.claim(),...s.filter(e=>e.startsWith(a)&&e!==c).map(e=>caches.delete(e))])))});r.addEventListener("fetch",t=>{if(t.request.method!=="GET")return;const s=new URL(t.request.url);!/(?:\.css|\.js|\.svg)$/i.test(s.pathname)&&s.origin!==r.location.origin||t.respondWith(caches.match(t.request).then(e=>e||caches.open(c).then(h=>fetch(t.request).then(i=>(i.status!==200||h.put(t.request,i.clone()),i)))))});