(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[5973],{48256:function(e,s,u){Promise.resolve().then(u.bind(u,67431))},99376:function(e,s,u){"use strict";var i=u(35475);u.o(i,"useParams")&&u.d(s,{useParams:function(){return i.useParams}}),u.o(i,"usePathname")&&u.d(s,{usePathname:function(){return i.usePathname}}),u.o(i,"useRouter")&&u.d(s,{useRouter:function(){return i.useRouter}}),u.o(i,"useSearchParams")&&u.d(s,{useSearchParams:function(){return i.useSearchParams}})},67431:function(e,s,u){"use strict";u.r(s),u.d(s,{default:function(){return D}});var i=u(57437),l=u(2265),a=u(99376),r=u(41119),o=u(40525),t=u(91236);let n={Electronics:"\uD83D\uDCF1",Vehicles:"\uD83D\uDE97",Furniture:"\uD83D\uDECB️",Books:"\uD83D\uDCDA",Sports:"⚽","Home Appliances":"\uD83C\uDFE0",Fashion:"\uD83D\uDC57",Property:"\uD83C\uDFE2",Jobs:"\uD83D\uDCBC",Services:"\uD83D\uDD27","Kids & Baby":"\uD83D\uDC76",Pets:"\uD83D\uDC3E",Music:"\uD83C\uDFB5","Art & Collectibles":"\uD83C\uDFA8"};function c(){let e=(0,a.useRouter)(),[s,u]=(0,l.useState)(null),{categories:c,isLoading:D}=(0,o.C)(e=>e.marketplaceCategory),d=c.length>0?c.filter(e=>1===e.status).sort((e,s)=>e.sort_order-s.sort_order).map(e=>{var s;return{id:String(e.id),slug:e.name.toLowerCase().replace(/\s+/g,"-").replace(/[^a-z0-9-]/g,""),label:e.name,icon:null!==(s=n[e.name])&&void 0!==s?s:"\uD83D\uDCE6",image:e.image}}):t.yi.map(e=>({id:e.id,slug:e.slug,label:e.label,icon:e.icon,image:void 0}));return(0,i.jsxs)("div",{className:"p-4 md:p-6 max-w-6xl mx-auto",children:[(0,i.jsxs)("div",{className:"mb-6",children:[(0,i.jsx)("h1",{className:"text-xl font-bold",style:{color:"var(--text-primary)"},children:"Browse Categories"}),(0,i.jsx)("p",{className:"text-sm mt-0.5",style:{color:"var(--text-muted)"},children:"Find what you're looking for"})]}),D?(0,i.jsx)("div",{className:"space-y-2",children:Array.from({length:6}).map((e,s)=>(0,i.jsx)("div",{className:"h-14 rounded-2xl animate-pulse",style:{background:"var(--card)"}},s))}):(0,i.jsx)("div",{className:"space-y-2",children:d.map(l=>(0,i.jsx)("div",{children:(0,i.jsxs)("button",{onClick:()=>{u(e=>e===l.id?null:l.id),e.push("/marketplace/search?category=".concat(l.slug))},className:"w-full flex items-center gap-3 p-3 rounded-2xl transition-all hover:opacity-90",style:{background:"var(--card)",border:"1px solid var(--border)"},children:[l.image&&!l.image.includes("no_img")?(0,i.jsx)("img",{src:l.image,alt:l.label,className:"w-9 h-9 rounded-xl object-cover shrink-0"}):(0,i.jsx)("span",{className:"text-2xl",children:l.icon}),(0,i.jsx)("span",{className:"flex-1 text-left text-sm font-medium",style:{color:"var(--text-primary)"},children:l.label}),(0,i.jsx)(r.Z,{size:16,style:{color:"var(--text-muted)",transform:s===l.id?"rotate(90deg)":"none",transition:"transform 0.2s"}})]})},l.id))})]})}function D(){return(0,i.jsx)(c,{})}},91236:function(e,s,u){"use strict";u.d(s,{R_:function(){return l},yi:function(){return i}});let i=[{id:"electronics",slug:"electronics",label:"Electronics",icon:"\uD83D\uDCF1",subcategories:[{id:"mobiles",slug:"mobiles",label:"Mobiles",icon:"\uD83D\uDCF1"},{id:"laptops",slug:"laptops",label:"Laptops",icon:"\uD83D\uDCBB"},{id:"tablets",slug:"tablets",label:"Tablets",icon:"\uD83D\uDCDF"},{id:"cameras",slug:"cameras",label:"Cameras",icon:"\uD83D\uDCF7"},{id:"audio",slug:"audio",label:"Audio",icon:"\uD83C\uDFA7"},{id:"tvs",slug:"tvs",label:"TVs & Monitors",icon:"\uD83D\uDDA5️"}]},{id:"fashion",slug:"fashion",label:"Fashion",icon:"\uD83D\uDC57",subcategories:[{id:"mens",slug:"mens",label:"Men's",icon:"\uD83D\uDC54"},{id:"womens",slug:"womens",label:"Women's",icon:"\uD83D\uDC57"},{id:"kids",slug:"kids",label:"Kids'",icon:"\uD83D\uDC76"},{id:"accessories",slug:"accessories",label:"Accessories",icon:"\uD83D\uDC5C"}]},{id:"home",slug:"home",label:"Home & Garden",icon:"\uD83C\uDFE0",subcategories:[{id:"furniture",slug:"furniture",label:"Furniture",icon:"\uD83E\uDE91"},{id:"appliances",slug:"appliances",label:"Appliances",icon:"\uD83E\uDED9"},{id:"decor",slug:"decor",label:"Decor",icon:"\uD83D\uDDBC️"}]},{id:"books",slug:"books",label:"Books & Media",icon:"\uD83D\uDCDA"},{id:"sports",slug:"sports",label:"Sports & Fitness",icon:"⚽"},{id:"vehicles",slug:"vehicles",label:"Vehicles",icon:"\uD83D\uDE97"},{id:"property",slug:"property",label:"Property",icon:"\uD83C\uDFD8️"},{id:"jobs",slug:"jobs",label:"Jobs",icon:"\uD83D\uDCBC"},{id:"services",slug:"services",label:"Services",icon:"\uD83D\uDEE0️"}],l="$"},40525:function(e,s,u){"use strict";u.d(s,{C:function(){return a},T:function(){return l}});var i=u(68575);let l=()=>(0,i.I0)(),a=e=>(0,i.v9)(e)},41119:function(e,s,u){"use strict";u.d(s,{Z:function(){return i}});let i=(0,u(95480).Z)("chevron-right",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]])}},function(e){e.O(0,[2716,2971,2117,1744],function(){return e(e.s=48256)}),_N_E=e.O()}]);