(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[214],{4080:function(e,l,a){(window.__NEXT_P=window.__NEXT_P||[]).push(["/gallery",function(){return a(1560)}])},1560:function(e,l,a){"use strict";a.r(l),a.d(l,{default:function(){return GalleryPage}});var n=a(5893),i=a(7294);let t={customSkins:{},newSkins:{}};var r=a(9746),o=a.n(r),s=a(9008),c=a.n(s);let u=[];function GalleryPage(){var e,l;let[a,r]=function(){let[e,l]=(0,i.useState)(t);(0,i.useEffect)(()=>{let e=new AbortController,a=e.signal,n=!1,loadCustomSkins=async()=>{let e;try{if(e=await fetch("".concat("https://exogen.github.io/t2-skins","/skins.json"),{signal:a}),!n){let a=await e.json();n||l(a)}}catch(e){console.error(e)}};return loadCustomSkins(),()=>{n=!0,e.abort()}},[]);let a=e!==t;return[e,a]}(),[s,d]=(0,i.useState)("lmale"),m="hfemale"===s?"hmale":s,h=null!==(l=null===(e=a.customSkins)||void 0===e?void 0:e[m])&&void 0!==l?l:u;return(0,n.jsxs)(n.Fragment,{children:[(0,n.jsx)(c(),{children:(0,n.jsx)("title",{children:"Tribes 2 Skin Gallery"})}),(0,n.jsxs)("main",{className:o().GalleryPage,children:[(0,n.jsx)("div",{className:o().Tools,children:(0,n.jsxs)("select",{id:"ModelSelect","aria-label":"Player model",onChange:e=>{d(e.target.value)},value:s,children:[(0,n.jsx)("option",{value:"lmale",children:"Human Male \xb7 Light"}),(0,n.jsx)("option",{value:"mmale",children:"Human Male \xb7 Medium"}),(0,n.jsx)("option",{value:"hmale",children:"Human Male \xb7 Heavy"}),(0,n.jsx)("option",{value:"lfemale",children:"Human Female \xb7 Light"}),(0,n.jsx)("option",{value:"mfemale",children:"Human Female \xb7 Medium"}),(0,n.jsx)("option",{value:"hfemale",children:"Human Female \xb7 Heavy"}),(0,n.jsx)("option",{value:"lbioderm",children:"Bioderm \xb7 Light"}),(0,n.jsx)("option",{value:"mbioderm",children:"Bioderm \xb7 Medium"}),(0,n.jsx)("option",{value:"hbioderm",children:"Bioderm \xb7 Heavy"})]})}),(0,n.jsx)("div",{className:o().Gallery,children:h.map(e=>(0,n.jsxs)("div",{className:o().Skin,children:[(0,n.jsx)("img",{className:o().Preview,loading:"lazy",src:"".concat("https://exogen.github.io/t2-skins","/gallery/").concat(encodeURIComponent(e),".").concat(m,".webp"),width:800,height:1600}),(0,n.jsx)("div",{className:o().Label,children:e})]},e))})]})]})}},9746:function(e){e.exports={GalleryPage:"gallery_GalleryPage__QyCLn",Tools:"gallery_Tools__COicv",Gallery:"gallery_Gallery__ZMJE_",Skin:"gallery_Skin__Ep_rb",Preview:"gallery_Preview__JGf2f",Label:"gallery_Label__kJfDw"}},9008:function(e,l,a){e.exports=a(9201)}},function(e){e.O(0,[774,888,179],function(){return e(e.s=4080)}),_N_E=e.O()}]); //# sourceMappingURL=gallery-fdcee2f9a64de949.js.map