1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2268],{16615:function(e,t,r){(window.__NEXT_P=window.__NEXT_P||[]).push(["/leaderboard",function(){return r(5550)}])},77263:function(e,t,r){"use strict";var s=r(85893);r(67294);var l=r(11163),n=r(2585),a=r(89583),c=r(63750),i=r(41664),d=r.n(i);let o=()=>((0,l.useRouter)(),(0,s.jsxs)("div",{className:"drawer drawer-mobile m-4 sticky",children:[(0,s.jsx)("input",{id:"my-drawer-2",type:"checkbox",className:"drawer-toggle"}),(0,s.jsx)("div",{className:"drawer-content flex flex-col items-center justify-center",children:(0,s.jsx)("label",{htmlFor:"my-drawer-2",className:"btn btn-primary drawer-button lg:hidden",children:"Open drawer"})}),(0,s.jsxs)("div",{className:"drawer-side lg:md:w-[65%] h-[50%] rounded-2xl shadow-xl",children:[(0,s.jsx)("label",{htmlFor:"my-drawer-2",className:"drawer-overlay"}),(0,s.jsxs)("ul",{className:"menu lg:md:p-4 w-80 bg-[#dbf8df] text-[#504f4f] font-bold border-[1px] ",children:[(0,s.jsx)("li",{children:(0,s.jsxs)(d(),{href:"/learn",className:"",type:"button",children:[(0,s.jsx)(n.NS3,{className:"text-xl text-red-400 mr-[5px]"}),"Learn"]})}),(0,s.jsx)("li",{children:(0,s.jsxs)(d(),{href:"/blogs",children:[(0,s.jsx)(a.h4d,{className:"text-xl text-red-400 mr-[5px]"}),"Blog"]})}),(0,s.jsx)("li",{children:(0,s.jsxs)(d(),{href:"/courses",children:[(0,s.jsx)(c.y6p,{className:"text-xl text-red-400 mr-[5px]"}),"Course"]})}),(0,s.jsx)("li",{children:(0,s.jsxs)(d(),{href:"/community",children:[(0,s.jsx)(c.w7k,{className:"text-xl text-red-400 mr-[5px]"}),"Community"]})})]})]})]}));t.Z=o},5550:function(e,t,r){"use strict";r.r(t),r.d(t,{default:function(){return h}});var s=r(85893),l=r(9008),n=r.n(l),a=r(67294),c=r(78945),i=r(46913);let d=()=>{let[e,t]=(0,a.useState)([]),[r,l]=(0,a.useState)(!0),[n]=(0,i.Z)(),[d,o]=(0,a.useState)(),[x,f]=(0,a.useState)();return(0,a.useEffect)(()=>
1{l(!0),c.Z.get("https://hello-talk-webserver.vercel.app/allusers").then(e=>{t(e.data)}).catch(e=>{console.log(e)}).finally(()=>{l(!1)})},[]),(0,a.useEffect)(()=>{e&&f(e.sort((e,t)=>t.gems-e.gems))},[e]),(0,a.useEffect)(()=>{if(x&&n){let e;x.forEach((t,r)=>{t.email===n.email&&(e=r+1)}),o(e)}},[x,n]),(0,s.jsx)(s.Fragment,{children:(0,s.jsxs)("div",{className:"max-w-[1240px] mx-auto px-8",children:[(0,s.jsx)("div",{className:" w-full my-5",children:(0,s.jsxs)("table",{className:"bg-white table w-full text-center",children:[(0,s.jsx)("thead",{className:"bg-white",children:(0,s.jsxs)("tr",{children:[(0,s.jsx)("th",{className:"bg-[#58cc02] text-[#fff]",children:"Name"}),(0,s.jsx)("th",{className:"bg-[#58cc02] text-[#fff]",children:"Email"}),(0,s.jsx)("th",{className:"bg-[#58cc02] text-[#fff]",children:"Your Position"}),(0,s.jsx)("th",{className:"bg-[#58cc02] text-[#fff]",children:"Gems"})]})}),(0,s.jsx)("tbody",{children:(0,s.jsxs)("tr",{children:[(0,s.jsx)("td",{className:"bg-[#fff] text-green-400",children:(0,s.jsx)("div",{children:(0,s.jsx)("div",{className:"font-bold capitalize",children:null==n?void 0:n.name})})}),(0,s.jsx)("th",{className:"bg-[#fff] text-green-400",children:null==n?void 0:n.email}),(0,s.jsx)("th",{className:"bg-[#fff] text-green-400",children:d}),(0,s.jsx)("td",{className:"bg-[#fff] text-green-400",children:null==n?void 0:n.gems})]})})]})}),(0,s.jsx)("div",{className:" w-full my-5",children:(0,s.jsxs)("table",{className:"bg-white table w-full text-center",children:[(0,s.jsx)("thead",{children:(0,s.jsxs)("tr",{className:"bg-[#ddf3a1] text-[#58cc02]",children:[(0,s.jsx)("th",{children:"Name"}),(0,s.jsx)("th",{children:"Email"}),(0,s.jsx)("th",{children:"Your Position"}),(0,s.jsx)("th",{children:"Gems"})]})}),(0,s.jsx)("tbody",{children:null==x?void 0:x.map((e,t)=>(0,s.jsx)(s.Fragment,{children:(0,s.jsxs)("tr",{className:"bg-[#edffdf] border-none text-[#333] shadow-lg",children:[(0,s.jsx)("td",{className:"bg-[#edffdf] border-none text-[#333]",children:null==e?void 0:e.name}),(0,s.jsx)("td",{className:"bg-[#edffdf] border-none text-[#333]",children:null==e?void 0:e.email}),(0,s.jsx)("td",{className:"bg-[#edffdf] border-none text-[#333]",children:t+1}),(0,s.jsx)("td",{className:"bg-[#edffdf] border-none text-[#333]",children:null==e?void 0:e.gems})]})}))})]})})]})})};var o=r(77263),x=r(80706);let f=()=>(0,s.jsxs)("div",{children:[(0,s.jsx)(n(),{children:(0,s.jsx)("title",{children:"HelloTalk - Leaderboard"})}),(0,s.jsx)(x.Z,{}),(0,s.jsxs)("div",{className:"pt-[6rem] grid grid-cols-[250px_minmax(950px,_1fr)] gap-x-[15px]",children:[(0,s.jsx)(o.Z,{}),(0,s.jsx)("div",{children:(0,s.jsx)(d,{})})]})]});var h=f},9008:function(e,t,r){e.exports=r(83121)},88357:function(e,t,r){"use strict";r.d(t,{w_:function(){return i}});var s=r(67294),l={color:void 0,size:void 0,className:void 0,style:void 0,attr:void 0},n=s.createContext&&s.createContext(l),a=function(){return(a=Object.assign||function(e){for(var t,r=1,s=arguments.length;r<s;r++)for(var l in t=arguments[r])Object.prototype.hasOwnProperty.call(t,l)&&(e[l]=t[l]);return e}).apply(this,arguments)},c=function(e,t){var r={};for(var s in e)Object.prototype.hasOwnProperty.call(e,s)&&0>t.indexOf(s)&&(r[s]=e[s]);if(null!=e&&"function"==typeof Object.getOwnPropertySymbols)for(var l=0,s=Object.getOwnPropertySymbols(e);l<s.length;l++)0>t.indexOf(s[l])&&Object.prototype.propertyIsEnumerable.call(e,s[l])&&(r[s[l]]=e[s[l]]);return r};function i(e){return function(t){return s.createElement(d,a({attr:a({},e.attr)},t),function e(t){return t&&t.map(function(t,r){return s.createElement(t.tag,a({key:r},t.attr),e(t.child))})}(e.child))}}function d(e){var t=function(t){var r,l=e.attr,n=e.size,i=e.title,d=c(e,["attr","size","title"]),o=n||t.size||"1em";return t.className&&(r=t.className),e.className&&(r=(r?r+" ":"")+e.className),s.createElement("svg",a({stroke:"currentColor",fill:"currentColor",strokeWidth:"0"},t.attr,l,d,{className:r,style:a(a({color:e.color||t.color},t.style),e.style),height:o,width:o,xmlns:"http://www.w3.org/2000/svg"}),i&&s.createElement("title",null,i),e.children)};return void 0!==n?s.createElement(n.Consumer,null,function(e){return t(e)}):t(l)}}},function(e){e.O(0,[4597,296,2013,5445,4980,2664,1664,8945,9260,769,706,9774,2888,179],function(){return e(e.s=16615)}),_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.