first commit

This commit is contained in:
shenjianZ committed 2025-05-24 22:25:49 +08:00
commit bcdeef8892
150 files changed
+9734

No files matched your search

@@ -0,0 +1 @@
(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[429],{2154:(e,t,r)=>{Promise.resolve().then(r.bind(r,7643))},3717:(e,t,r)=>{"use strict";r.d(t,{B:()=>l,d:()=>s});let s={HISTORY:"videoHistory",CATEGORIES:"videoCategories",API_INDEX:"currentApiIndex",USERNAME:"username",THEME:"theme"},l=[{id:"movie",name:"电影",color:"#f43f5e"},{id:"tv",name:"电视剧",color:"#3b82f6"},{id:"variety",name:"综艺",color:"#10b981"},{id:"anime",name:"动漫",color:"#f97316"},{id:"education",name:"教育",color:"#8b5cf6"},{id:"other",name:"其他",color:"#6b7280"}]},7643:(e,t,r)=>{"use strict";r.r(t),r.d(t,{default:()=>i});var s=r(5155),l=r(2115),a=r(5060),o=r(3717);let n=[{name:"接口1",url:"https://jx.xmflv.com/?url="},{name:"接口2",url:"https://jx.parwix.com:4433/player/?url="},{name:"接口3",url:"https://jx.iztyy.com/svip/?url="},{name:"接口4",url:"https://jx.bozrc.com:4433/player/?url="},{name:"接口5",url:"https://jx.4kdv.com/?url="}];function i(){let[e,t]=(0,l.useState)([]),[r,i]=(0,l.useState)(!1),[d,c]=(0,l.useState)(0),[x,m]=(0,l.useState)(""),[h,u]=(0,l.useState)("用户"),[g,v]=(0,l.useState)(null),[w,p]=(0,l.useState)(""),[k,j]=(0,l.useState)(null),[b,y]=(0,l.useState)(""),[N,f]=(0,l.useState)(!1),[L,C]=(0,l.useState)([]),[S,M]=(0,l.useState)(null),[E,B]=(0,l.useState)(null),[I,A]=(0,l.useState)(null);(0,l.useEffect)(()=>{let e=window.matchMedia("(prefers-color-scheme: dark)"),r=e.matches;i(r),r?document.documentElement.classList.add("dark"):document.documentElement.classList.remove("dark");let s=e=>{i(e.matches),e.matches?document.documentElement.classList.add("dark"):document.documentElement.classList.remove("dark")};e.addEventListener("change",s);let l=localStorage.getItem(o.d.HISTORY);l&&t(JSON.parse(l));let a=localStorage.getItem(o.d.CATEGORIES);a?C(JSON.parse(a)):(C(o.B),localStorage.setItem(o.d.CATEGORIES,JSON.stringify(o.B)));let n=localStorage.getItem(o.d.API_INDEX);n&&c(parseInt(n,10));let d=localStorage.getItem(o.d.USERNAME);return d&&u(d),()=>{e.removeEventListener("change",s)}},[]);let W=e=>{t(e),localStorage.setItem(o.d.HISTORY,JSON.stringify(e))},R=(t,r)=>{let s=[...e];s[t].category=r||void 0,W(s),B(null)},O=t=>{let r=[...e];r[t].isFavorite=!r[t].isFavorite,W(r)},H=t=>{W(e.filter((e,r)=>r!==t))},F=e=>{try{let t=new URL(e);return t.origin+t.pathname}catch(t){return e}},_=e=>{let t=n[d].url+encodeURIComponent(e);window.open(t,"_blank")},T=e.filter(e=>e.title.toLowerCase().includes(x.toLowerCase())||e.url.toLowerCase().includes(x.toLowerCase())),Z=e=>e?L.find(t=>t.id===e)||null:null,z=(e,t)=>{v(e),p(t)},J=t=>{if(w.trim()){let r=[...e];r[t].title=w.trim(),W(r)}v(null)},U=()=>{v(null)},D=function(e){let t=arguments.length>1&&void 0!==arguments[1]?arguments[1]:"";j(e),y(t)},G=t=>{let r=[...e];r[t].description=b.trim()||void 0,W(r),j(null)},P=()=>{j(null)},Y=t=>{B(t),A(e[t].category||null)};return(0,s.jsxs)("div",{className:"flex h-full",children:[(0,s.jsx)(a.A,{darkMode:r,username:h,isOpen:N,onToggle:()=>f(!N)}),(0,s.jsxs)("div",{className:"flex-1 md:ml-64 bg-white dark:bg-black min-h-screen text-black dark:text-white transition-all duration-300 ".concat(N?"md:translate-x-0":"translate-x-0"),children:[(0,s.jsx)("nav",{className:"border-b border-gray-100 dark:border-gray-800",children:(0,s.jsxs)("div",{className:"max-w-5xl mx-auto px-4 py-4 flex justify-between items-center",children:[(0,s.jsxs)("div",{className:"flex items-center",children:[(0,s.jsx)("button",{className:"md:hidden mr-4 text-gray-600 dark:text-gray-400",onClick:()=>f(!N),"aria-label":"打开菜单",children:(0,s.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:"w-6 h-6",children:(0,s.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"M3.75 6.75h16.5M3.75 12h16.5m-16.5 5.25h16.5"})})}),(0,s.jsx)("h1",{className:"text-xl font-medium",children:"历史记录"})]}),(0,s.jsxs)("div",{className:"text-sm text-gray-500 dark:text-gray-400",children:["当前接口: ",n[d].name]})]})}),(0,s.jsxs)("main",{className:"max-w-5xl mx-auto px-4 py-8",children:[(0,s.jsx)("div",{className:"mb-8",children:(0,s.jsxs)("div",{className:"flex flex-col sm:flex-row items-start sm:items-center justify-between gap-4 mb-4",children:[(0,s.jsxs)("div",{className:"relative w-full sm:max-w-md",children:[(0,s.jsx)("input",{type:"text",placeholder:"搜索历史记录...",value:x,onChange:e=>m(e.target.value),className:"w-full py-2 px-3 pr-10 border border-gray-200 dark:border-gray-800 rounded-lg bg-white dark:bg-black focus:outline-none focus:ring-1 focus:ring-gray-400 dark:focus:ring-gray-500"}),(0,s.jsx)("svg",{xmlns:"http://www.w3.org/2000/svg",fill:"none",viewBox:"0 0 24 24",strokeWidth:1.5,stroke:"currentColor",className:"w-5 h-5 absolute right-3 top-1/2 -translate-y-1/2 text-gray-400",children:(0,s.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",d:"m21 21-5.197-5.197m0 0A7.5 7.5 0 1 0 5.196 5.196a7.5 7.5 0 0 0 10.607 10.607Z"})})]}),(0,s.jsxs)("button",{onCLine truncated