PageSourceSearch

https://toyotatimes-sports.toyota/_next/static/chunks/pages/teams/…/support/gallery-ba8861596a491335.js

js toyotatimes-sports.toyota collected 2026-10-02 10:46:48 UTC 12,355 bytes, 1 lines download raw bytes

1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[4958],{5814:(e,t,n)=>{"use strict";n.d(t,{C8:()=>l,dK:()=>s});var r=n(37876),o=n(89099),i=n(14232);let s=e=>{let{currentPage:t,totalPages:n,onPageChange:o,isMobile:i=!1}=e;return n<=1?null:(0,r.jsxs)("div",{style:{display:"flex",justifyContent:"center",alignItems:"center",gap:i?8:12,marginTop:48,flexWrap:"wrap"},children:[(0,r.jsx)("button",{onClick:()=>void o(t-1),disabled:1===t,style:{padding:i?"8px 12px":"10px 16px",fontSize:i?13:14,border:"1px solid #ccc",borderRadius:4,backgroundColor:1===t?"#f5f5f5":"#fff",color:1===t?"#999":"#333",cursor:1===t?"not-allowed":"pointer"},type:"button",children:"前へ"}),Array.from({length:n},(e,t)=>t+1).map(e=>(0,r.jsx)("button",{onClick:()=>void o(e),style:{padding:i?"8px 12px":"10px 16px",fontSize:i?13:14,border:t===e?"1px solid #333":"1px solid #ccc",borderRadius:4,backgroundColor:t===e?"#333":"#fff",color:t===e?"#fff":"#333",cursor:"pointer",fontWeight:t===e?"bold":"normal"},type:"button",children:e},e)),(0,r.jsx)("button",{onClick:()=>void o(t+1),disabled:t===n,style:{padding:i?"8px 12px":"10px 16px",fontSize:i?13:14,border:"1px solid #ccc",borderRadius:4,backgroundColor:t===n?"#f5f5f5":"#fff",color:t===n?"#999":"#333",cursor:t===n?"not-allowed":"pointer"},type:"button",children:"次へ"})]})},l=e=>{let t=(0,o.useRouter)(),{fetchData:n,itemsPerPage:r,isAuthenticated:s=!0,enabled:l=!0}=e,[a,d]=i.useState([]),[c,u]=i.useState(1),[p,h]=i.useState(1),[x,g]=i.useState(!1),f=(0,i.useRef)(n);(0,i.useEffect)(()=>{f.current=n},[n]);let y="string"==typeof t.query.page?parseInt(t.query.page,10):1,b=i.useCallback(async e=>{if(l&&s){g(!0);try{let t=await f.current(e);d(t.items),h(Math.ceil(t.total/r))}catch(e){console.error("Error fetching paginated data:",e),d([]),h(1)}finally{g(!1)}}},[r,l,s]),m=i.useCallback(async(e,n)=>{await t.push({pathname:t.pathname,query:1===e?{}:{page:e}},void 0,{shallow:!0}),n&&setTimeout(()=>{let e=document.getElementById(n);e&&e.scrollIntoView({behavior:"smooth"})},100)},[t]);return(0,i.useEffect)(()=>{if(!l||!s||!t.isReady)return;let e=!isNaN(y)&&y>0?y:1;u(e),b(e)},[l,s,t.isReady,y,b]),{data:a,currentPage:c,totalPages:p,isLoading:x,handlePageChange:m}}},97645:(e,t,n)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/teams/long-distance/support/gallery",function(){return n(98504)}])},98504:(e,t,n)=>{"use strict";n.r(t),n.d(t,{__N_SSP:()=>v,default:()=>w});var r=n(37876),o=n(14232),i=n(54243),s=n(37987),l=n(5814),a=n(48230),d=n.n(a),c=n(53972);let u="ld_supporter_auth",p=e=>{let{isMobile:t,onAuth:n,team:i="long_distance",title:s="会員限定コンテンツ",description:l="このページは後援会会員専用です。"}=e,[a,p]=(0,o.useState)(""),[h,x]=(0,o.useState)(""),[g,f]=(0,o.useState)(!1),y=async e=>{e.preventDefault(),f(!0),x("");try{var t;let e=await (0,c.u)("POST","team/".concat(i,"/support/verify-password"),null,{password:a});(null==e||null==(t=e.data)?void 0:t.valid)?(sessionStorage.setItem(u,"true"),n()):(x("パスワードが正しくありません"),p(""))}catch(e){x("認証に失敗しました。もう一度お試しください。"),p("")}finally{f(!1)}};return(0,r.jsx)("div",{style:{minHeight:"100vh",backgroundColor:"#f9fafb",display:"flex",alignItems:"center",justifyContent:"center",padding:16},children:(0,r.jsxs)("div",{style:{backgroundColor:"white",borderRadius:16,padding:t?32:48,maxWidth:400,width:"100%",boxShadow:"0 10px 25px -5px rgba(0,0,0,0.1)",textAlign:"center"},children:[(0,r.jsx)("div",{style:{width:64,height:64,backgroundColor:"rgba(235,10,30,0.1)",borderRadius:"50%",display:"flex",alignItems:"center",justifyContent:"center",margin:"0 auto 24px"},children:(0,r.jsx)("svg",{style:{width:32,height:32,color:"#C60E0E"},fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:(0,r.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M12 15v2m-6 4h12a2 2 0 002-2v-6a2 2 0 00-2-2H6a2 2 0 00-2 2v6a2 2 0 002 2zm10-10V7a4 4 0 00-8 0v4h8z"})})}),(0,r.jsx)("h1",{style:{fontSize:t?20:24,fontWeight:700,color:"#0a0a0a",marginBottom:8},children:s}),(0,r.jsxs)("p",{style:{color:"#6a7282",fontSize:14,marginBottom:32,lineHeight:1.6},children:[l,(0,r.jsx)("br",{}),"会員証に記載のパスワードを入力してください。"]}),(0,r.jsxs)("form",{onSubmit:e=>{y(e)},children:[(0,r.jsx)("input",{type:"password",value:a,onChange:e=>{p(e.target.value),x("")},placeholder:"パスワードを入力",disabled:g,style:{width:"100%",padding:"14px 16px",fontSize:16,border:h?"2px solid #C60E0E":"2px solid #e5e7eb",borderRadius:8,outline:"none",boxSizing:"border-box",marginBottom:8,opacity:g?.7:1}}),h&&(0,r.jsx)("p",{style:{color:"#C60E0E",fontSize:14,marginBottom:16,textAlign:"left"},children:h}),(0,r.jsx)("button",{type:"submit",disabled:g,style:{width:"100%",padding:"14px 24px",backgroundColor:g?"#f87171":"#C60E0E",color:"white",border:"none",borderRadius:8,fontSize:16,fontWeight:500,cursor:g?"not-allowed":"pointer",marginTop:8},children:g?"認証中...":"ログイン"})]}),(0,r.jsxs)("p",{style:{color:"#9ca3af",fontSize:12,marginTop:24},children:["パスワードがわからない場合は",(0,r.jsx)(d(),{href:"/support/#contact",style:{color:"#C60E0E",textDecoration:"none"},children:"お問い合わせ"}),"ください"]})]})})},h=()=>(0,r.jsx)("div",{style:{minHeight:"100vh",display:"flex",alignItems:"center",justifyContent:"center",backgroundColor:"#f9fafb"},children:(0,r.jsx)("p",{style:{color:"#6a7282"},children:"読み込み中..."})});var x=n(59289),g=n(31474),f=n(29223);let y=()=>(0,r.jsx)("svg",{style:{width:24,height:24},fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:(0,r.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M6 18L18 6M6 6l12 12"})}),b=()=>(0,r.jsx)("svg",{style:{width:32,height:32},fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:(0,r.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M15 19l-7-7 7-7"})}),m=()=>(0,r.jsx)("svg",{style:{width:32,height:32},fill:"none",viewBox:"0 0 24 24",stroke:"currentColor",children:(0,r.jsx)("path",{strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:2,d:"M9 5l7 7-7 7"})}),j=e=>{let{selectedImage:t,onClose:n,nextImage:o,prevImage:i,isFirst:s,isLast:l}=e;return(0,r.jsxs)("div",{style:{position:"fixed",inset:0,zIndex:9999,backgroundColor:"rgba(0,0,0,0.9)",display:"flex",alignItems:"center",justifyContent:"center"},onClick:n,children:[(0,r.jsx)("button",{onClick:n,style:{position:"absolute",top:20,right:20,background:"none",border:"none",color:"white",cursor:"pointer",padding:8},children:(0,r.jsx)(y,{})}),!s&&(0,r.jsx)("button",{onClick:e=>{e.stopPropagation(),i()},style:{position:"absolute",left:20,top:"50%",transform:"translateY(-50%)",background:"rgba(255,255,255,0.1)",border:"none",color:"white",cursor:"pointer",padding:12,borderRadius:"50%",zIndex:10},children:(0,r.jsx)(b,{})}),(0,r.jsxs)("div",{onClick:e=>e.stopPropagation(),style:{maxWidth:"90vw",maxHeight:"80vh",position:"relative"},children:[(0,r.jsx)("img",{src:t.src,alt:t.alt,style:{maxWidth:"100%",maxHeight:"80vh",objectFit:"contain",borderRadius:8}}),(0,r.jsxs)("div",{style:{textAlign:"center",color:"white",marginTop:16},children:[(0,r.jsx)("p",{style:{fontSize:16,fontWeight:500,margin:0},children:t.alt}),(0,r.jsx)("p",{style:{fontSize:14,opacity:.7,margin:"8px 0 0 0"},children:t.date})]})]}),!l&&(0,r.jsx)("button",{onClick:e=>{e.stopPropagation(),o()},style:{position:"absolute",right:20,top:"50%",transform:"translateY(-50%)",background:"rgba(255,255,255,0.1)",border:"none",color:"white",cursor:"pointer",padding:12,borderRadius:"50%",zIndex:10},children:(0,r.jsx)(m,{})})]})};var v=!0;function w(e){let{metaInfo:t,scripts:n,styles:a,...d}=e,{isMobile:y}=(0,g.A)(),[b,m]=(0,o.useState)(!1),{isAuthenticated:v,isCheckingAuth:w,setIsAuthenticated:k}=(()=>{let[e,t]=(0,o.useState)(!1),[n,r]=(0,o.useState)(!0);return(0,o.useEffect)(()=>{"true"===sessionStorage.getItem(u)&&t(!0),r(!1)},[]),{isAuthenticated:e,isCheckingAuth:n,setIsAuthenticated:t,logout:()=>{sessionStorage.removeItem(u),t(!1)}}})(),[C,S]=(0,o.useState)(null);y&&a.push({href:"".concat(x.S_,"/assets2020/css/sp.css")});let{data:E,currentPage:I,totalPages:_,isLoading:z,handlePageChange:R}=(0,l.C8)({fetchData:async e=>{var t,n,r,o;let i=await (0,c.u)("GET","team/long_distance/content/gallery?page=".concat(e,"&size=").concat(12));return{items:null!=(r=null==i||null==(t=i.data)?void 0:t.items)?r:[],total:null!=(o=null==i||null==(n=i.data)?void 0:n.total)?o:0}},itemsPerPage:12,isAuthenticated:v,enabled:!0}),L=E.map((e,t)=>{var n,r,o,i,s,l,a,d;return{id:null!=(s=e.seqId)?s:t+1,src:(0,f.sU)(null!=(l=null==(n=e.extra)?void 0:n.image)?l:""),alt:(null==(r=e.extra)?void 0:r.title)||"",category:null!=(a=null==(o=e.extra)?void 0:o.category)?a:"all",date:null!=(d=null==(i=e.extra)?void 0:i.date)?d:""}}),A=async(e,t)=>{await R(e,t)};(0,o.useEffect)(()=>{(async()=>{let e=window.screen.width<=767;m(e),e&&a.push({href:"".concat(x.S_,"/assets2020/css/sp.css")});try{await (0,f.ES)("".concat(x.S_,"/assets2020/js/jquery-3.3.1.min.js"),()=>{var e;return null==(e=window)?void 0:e.jQuery}),await Promise.all([(0,f.ES)("".concat(x.S_,"/assets2020/js/common.js"))])}catch(e){console.error(e)}})()},[]);let P=(0,o.useCallback)(()=>{S(null)},[]),W=(0,o.useCallback)(e=>{S(t=>{if(!t)return null;let n=L.findIndex(e=>e.id===t.id),r="prev"===e?n>0?n-1:L.length-1:n<L.length-1?n+1:0;return L[r]})},[L]),N=(0,o.useCallback)(()=>W("prev"),[W]),T=(0,o.useCallback)(()=>W("next"),[W]);(0,o.useEffect)(()=>{let e=e=>{C&&("Escape"===e.key&&P(),"ArrowLeft"===e.key&&N(),"ArrowRight"===e.key&&T())};return window.addEventListener("keydown",e),()=>window.removeEventListener("keydown",e)},[C,P,N,T]);let M=y||b;return w?(0,r.jsx)(i.A,{metaInfo:t,scripts:n,styles:a,...d,children:(0,r.jsx)(h,{})}):v?(0,r.jsxs)(i.A,{metaInfo:t,scripts:n,styles:a,...d,children:[(0,r.jsxs)("div",{id:"wrapper",style:{overflow:"visible"},children:[(0,r.jsx)(s.Y9,{}),(0,r.jsx)(s.Vx,{}),(0,r.jsxs)("main",{id:"main",children:[(0,r.jsx)("div",{className:"page-ttl-block c-mask is-active",style:{background:"rgb(198, 14, 14)"}
1,children:(0,r.jsx)("div",{className:"inner-block",children:(0,r.jsxs)("h1",{className:"ttl",children:[(0,r.jsx)("span",{className:"en",children:"GALLERY"}),(0,r.jsx)("span",{className:"ja",children:"ギャラリー"})]})})}),(0,r.jsx)("section",{style:{backgroundColor:"#f9fafb",padding:M?"48px 16px":"80px 48px"},children:(0,r.jsxs)("div",{style:{maxWidth:1280,margin:"0 auto"},children:[z&&(0,r.jsx)("div",{style:{textAlign:"center",padding:"64px 0",color:"#6a7282"},children:(0,r.jsx)("p",{children:"読み込み中..."})}),!z&&(0,r.jsx)("div",{id:"gallery-grid",style:{display:"grid",gridTemplateColumns:M?"repeat(2, 1fr)":"repeat(3, 1fr)",gap:M?12:24},children:L.map(e=>(0,r.jsxs)("div",{onClick:()=>S(e),style:{position:"relative",aspectRatio:"4/3",overflow:"hidden",borderRadius:12,cursor:"pointer",boxShadow:"0 4px 6px -1px rgba(0,0,0,0.1)"},children:[(0,r.jsx)("img",{src:e.src,alt:e.alt,style:{width:"100%",height:"100%",objectFit:"cover",transition:"transform 0.3s"},onMouseOver:e=>{e.currentTarget.style.transform="scale(1.05)"},onMouseOut:e=>{e.currentTarget.style.transform="scale(1)"}}),(0,r.jsxs)("div",{style:{position:"absolute",bottom:0,left:0,right:0,padding:M?12:16,background:"linear-gradient(to top, rgba(0,0,0,0.7), transparent)",color:"white"},children:[(0,r.jsx)("p",{style:{fontSize:M?12:14,fontWeight:500,margin:0},children:e.alt}),(0,r.jsx)("p",{style:{fontSize:M?10:12,opacity:.8,margin:"4px 0 0 0"},children:e.date})]})]},e.id))}),!z&&0===L.length&&(0,r.jsx)("div",{style:{textAlign:"center",padding:"64px 0",color:"#6a7282"},children:(0,r.jsx)("p",{children:"該当する画像がありません"})}),(0,r.jsx)(l.dK,{currentPage:I,totalPages:_,onPageChange:e=>{A(e,"main")},isMobile:M})]})})]}),(0,r.jsx)(s.wi,{})]}),C&&(0,r.jsx)(j,{selectedImage:C,onClose:P,nextImage:T,prevImage:N,isFirst:0===L.findIndex(e=>e.id===C.id),isLast:L.findIndex(e=>e.id===C.id)===L.length-1})]}):(0,r.jsx)(i.A,{metaInfo:t,scripts:n,styles:a,...d,children:(0,r.jsx)(p,{isMobile:M,onAuth:()=>k(!0),team:"long_distance",title:"会員限定ギャラリー",description:"このページは後援会会員専用です。"})})}}},e=>{e.O(0,[3510,8230,4233,7987,636,6593,8792],()=>e(e.s=97645)),_N_E=e.O()}]);

Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.