\n
\n
\n
0 && 'hidden')}>查無符合項目,請調整搜尋項目。
\n {data.length > 0 && (\n
\n {currentData.map((pm) => (\n \n ))}\n
\n )}\n
\n
\n
\n );\n}\n\nexport default Pokedex;\n"],"names":["localStorageKey","Abilities","pokemon","abilities","map","ability","className","hiddenAbility","EVs","Array","fill","_","i","key","EVName","EVIndex","String","val","filter","item","t","Pids","pokedex","galar","toString","padStart","armor","crown","pid","ShowGi","tags","has","GI","includes","pm","Card","display","PokedexList","clsx","nameZh","altForm","types","type","to","SearchBar","value","onChange","toggleDisplay","hasFilter","placeholder","e","target","FilterButton","checked","advancedFilter","toggleState","pagingButtonLength","window","screen","width","Pagination","currentPage","totalPages","updateNumberState","onClick","n","Math","max","abs","min","PaginationMobile","length","name","id","event","htmlFor","Buttons","list","currVal","updateState","Header","updateSetState","typeUpdate","abilityUpdate","showChildUpdate","EV","region","Boolean","filterList","share","shareData","title","text","document","url","location","href","navigator","console","error","keyword","handleChange","onlyEvolution","bool","Object","keys","TypeEnum","size","split","some","char","useSearchParams","searchParams","setSearchParams","useState","setDisplay","cacheObj","getJsonCache","get","page","Number","Set","useEffect","forEach","localStorage","setItem","JSON","stringify","prev","delete","set","fn","newVal","vals","add","join","UseFilter","data","usePokemonListContext","pokemonList","concat","flat","sort","filterPokemonList","ceil","startIndex","currentData","slice","Hr","link"],"sourceRoot":""}
\ No newline at end of file
diff --git a/static/js/Pokedex.6766d1e8.chunk.js b/static/js/Pokedex.8753abe5.chunk.js
similarity index 83%
rename from static/js/Pokedex.6766d1e8.chunk.js
rename to static/js/Pokedex.8753abe5.chunk.js
index d17d893..b91a9d4 100644
--- a/static/js/Pokedex.6766d1e8.chunk.js
+++ b/static/js/Pokedex.8753abe5.chunk.js
@@ -1,2 +1,2 @@
-"use strict";(self.webpackChunkgalar=self.webpackChunkgalar||[]).push([[299],{2358:function(e,t,a){a.r(t),a.d(t,{default:function(){return V}});var n=a(3433),r=a(8182),l=a(4013),s=a(101),i=a(8745),c=a(2791),o=a(4942),d=a(1413),x=a(9439),u=a(6731),m="pokeDexPage";var p=a(6257),g=a(2116),h=a(184),f=function(e){var t=e.pokemon;return(0,h.jsxs)(h.Fragment,{children:[t.abilities.map((function(e){return(0,h.jsx)("span",{className:"rounded bg-blue-100 px-1.5 py-0.5 text-center text-xs font-semibold text-blue-800",children:e},e)})),t.hiddenAbility&&(0,h.jsx)("span",{className:"rounded bg-gray-100 px-1.5 py-0.5 text-center text-xs font-semibold text-gray-800",children:[t.hiddenAbility]})]})},y=function(e){var t=e.pokemon;return(0,h.jsx)(h.Fragment,{children:Array(6).fill(0).map((function(e,a){return{key:g.J$[g.xA[String(a)]],val:t.EVs[a]}})).filter((function(e){return e.val>0})).map((function(e){return"".concat(e.key,": ").concat(e.val)})).map((function(e){return(0,h.jsx)("span",{className:"rounded bg-blue-100 px-1.5 py-0.5 text-center text-xs font-semibold text-blue-800",children:e},e)}))})},j=function(e){var t=e.pokemon,a=e.pokedex;return(0,h.jsxs)(h.Fragment,{children:[t.galar&&"galar"!==a&&(0,h.jsxs)("span",{className:"rounded bg-custom-gold/30 px-1.5 py-0.5 text-center text-xs font-semibold text-gray-800",children:["\u4f3d\u52d2\u723e#",t.galar.toString().padStart(3,"0")]}),t.armor&&"armor"!==a&&(0,h.jsxs)("span",{className:"rounded bg-custom-green/30 px-1.5 py-0.5 text-center text-xs font-semibold text-gray-800",children:["\u93a7\u5cf6#",t.armor.toString().padStart(3,"0")]}),t.crown&&"crown"!==a&&(0,h.jsxs)("span",{className:"rounded bg-custom-blue/30 px-1.5 py-0.5 text-center text-xs font-semibold text-gray-800",children:["\u738b\u51a0\u96ea\u539f#",t.crown.toString().padStart(3,"0")]}),t.pid&&"national"!==a&&(0,h.jsxs)("span",{className:"rounded bg-custom-orange/30 px-1.5 py-0.5 text-center text-xs font-semibold text-gray-800",children:["\u5168\u570b#",t.pid.toString().padStart(3,"0")]})]})},b=function(e){var t=e.pokemon;return e.filter.tags.has(g.GI)&&t.tags.includes(g.GI)?(0,h.jsx)(p.J.lA.pA,{pm:t,className:"absolute -bottom-4 md:-right-6 md:w-4/5"}):(0,h.jsx)(p.J.lA.Pm,{pm:t,className:"absolute -bottom-4 md:-right-6 md:w-4/5"})};function v(e){var t=e.pokemon,a=e.filter,n=e.display,l=g.Sw.includes(a.pokedex)?(t[a.pokedex]||0).toString().padStart(3,"0"):t.pid.toString().padStart(4,"0");return(0,h.jsxs)("div",{className:(0,r.Z)("mt-8 px-4 pb-0 pt-2 md:mt-20 md:pb-2","flex flex-col gap-y-2","rounded-xl bg-white","shadow-list-items hover:shadow-list-items--hover","hover:translate-x-[-0.2rem] hover:translate-y-[-0.2rem]","relative"),children:[(0,h.jsxs)("header",{className:"relative h-6 md:h-auto",children:[(0,h.jsxs)("span",{className:"hidden whitespace-nowrap md:block",children:["#",l]}),(0,h.jsx)(b,{filter:a,pokemon:t,display:n})]}),(0,h.jsx)("hr",{className:"border-0 border-t-[1px] border-[#A29834]"}),(0,h.jsxs)("div",{className:"flex h-full flex-col justify-between gap-y-1",children:[(0,h.jsxs)("div",{className:(0,r.Z)("grid grid-cols-1 md:grid-cols-2"),children:[(0,h.jsxs)("div",{className:"flex flex-col items-center gap-y-1 md:items-start",children:[(0,h.jsxs)("p",{className:"text-center md:text-start",children:[(0,h.jsxs)("span",{className:"block whitespace-nowrap md:hidden",children:["#",l]}),t.nameZh,t.altForm&&(0,h.jsxs)("span",{className:"block text-xs font-thin",children:["(",t.altForm,")"]})]}),(0,h.jsx)("div",{className:"flex gap-x-1",children:t.types.map((function(e){return(0,h.jsx)(p.J.lA.Dy,{type:e},e)}))})]}),(0,h.jsx)("div",{className:"hidden md:block",children:(0,h.jsx)("div",{className:"flex flex-col gap-y-2",children:(0,h.jsx)(f,{pokemon:t})})})]}),(0,h.jsxs)("div",{className:(0,r.Z)("mt-2",n.EVs||n.ability||n.pid?"block":"hidden"),children:[n.ability&&(0,h.jsx)("p",{className:"flex flex-col flex-wrap justify-center gap-2 whitespace-nowrap md:flex-row md:justify-start",children:(0,h.jsx)(f,{pokemon:t})}),n.EVs&&(0,h.jsx)("p",{className:"flex flex-col flex-wrap justify-center gap-2 whitespace-nowrap md:flex-row md:justify-start",children:(0,h.jsx)(y,{pokemon:t})}),n.pid&&(0,h.jsx)("p",{className:"flex flex-col flex-wrap justify-center gap-2 whitespace-nowrap md:flex-row md:justify-start",children:(0,h.jsx)(j,{pokemon:t,pokedex:a.pokedex})})]})]}),(0,h.jsx)(u.rU,{className:"stretchedLink",to:"/pokedex/".concat(t.nameZh).concat(t.altForm?"-"+t.altForm:"")})]})}function N(e){var t=e.value,a=e.onChange,n=e.display,s=e.toggleDisplay,i=e.hasFilter;return(0,h.jsx)(h.Fragment,{children:(0,h.jsxs)("div",{className:"relative my-2 w-full",children:[(0,h.jsx)("div",{className:"pointer-events-none absolute inset-y-0 left-0 flex items-center pl-3",children:(0,h.jsx)(p.J.ol,{className:"h-5 w-5"})}),(0,h.jsx)("input",{type:"search",className:(0,r.Z)("block w-full rounded-full border border-gray-300","bg-gray-50 p-2 pl-10 text-sm text-gray-900","search"),placeholder:"\u641c\u5c0b \u540d\u7a31(\u4e2d/\u82f1/\u65e5), \u6a23\u5b50",value:t,onChange:function(e){a(e.target.value)}}),(0,h.jsxs)("div",{className:"absolute inset-y-0 right-0 flex items-center pr-3",children:[(0,h.jsx)(Z,{checked:n.advancedFilter,toggleState:s("advancedFilter")}),i&&(0,h.jsx)("div",{className:"relative -top-3 right-6",children:(0,h.jsx)(l.z$,{})})]})]})})}var w=window.screen.width<768?1:5;function k(e){var t=e.currentPage,a=e.totalPages,n=e.updateNumberState;return(0,h.jsx)("nav",{children:(0,h.jsxs)("ul",{className:"inline-flex -space-x-px text-sm",children:[(0,h.jsx)("li",{children:(0,h.jsx)("button",{onClick:function(){return n("page",(function(e){return Math.max(1,e-1)}))},className:(0,r.Z)("ml-0 flex h-8 items-center justify-center","rounded-l-lg border border-gray-300","bg-white px-3 leading-tight text-gray-500","hover:bg-gray-100 hover:text-gray-700",1===t&&"cursor-not-allowed"),children:"\u524d\u4e00\u9801"})}),t>w&&(0,h.jsxs)(h.Fragment,{children:[(0,h.jsx)("li",{children:(0,h.jsx)("button",{onClick:function(){return n("page",(function(){return 1}))},className:(0,r.Z)("ml-0 flex h-8 items-center justify-center","border border-gray-300","bg-white px-3 leading-tight text-gray-500","hover:bg-gray-100 hover:text-gray-700"),children:"1"})}),(0,h.jsx)("li",{className:(0,r.Z)("ml-0 flex h-8 items-center justify-center","border border-gray-300","bg-white px-3 leading-tight text-gray-500"),children:"..."})]}),new Array(a).fill(0).map((function(e,t){return t+1})).filter((function(e){return Math.abs(e-t)