1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[6037],{319:(e,t,r)=>{r.d(t,{Y:()=>l});var a=r(53137),n=r(36272),o=r(78129),s=r(17656);function l(e){var t;let{page:r,totalPages:l,hasNextPage:i,knownLastPage:d,onPageChange:c,scrollTargetRef:u,className:m}=e,p="number"==typeof l&&Number.isFinite(l)&&l>0?Math.floor(l):null,f="number"==typeof d&&Number.isFinite(d)&&d>0?Math.floor(d):null,x=null!=(t=null!=p?p:f)?t:i?r+1:r,h=r>1,g=r<x;if(null!==p?p<=1:!h&&!g)return null;let b=e=>{if(e===r||e<1||e>x)return;c(e);let t=null==u?void 0:u.current;if(t){let e=t.getBoundingClientRect().top+window.scrollY-96;window.scrollTo({top:Math.max(0,e),behavior:"smooth"})}else window.scrollTo({top:0,behavior:"smooth"})},v="flex h-9 min-w-9 items-center justify-center rounded-lg border border-border bg-background px-2 text-sm text-foreground transition-colors hover:border-primary/40 hover:bg-muted disabled:pointer-events-none disabled:opacity-40";return(0,a.jsxs)("nav",{role:"navigation","aria-label":"Pagination",className:(0,s.cn)("flex items-center justify-center gap-1.5",m),children:[(0,a.jsx)("button",{type:"button",onClick:()=>b(r-1),disabled:!h,"aria-label":"Previous page",className:v,children:(0,a.jsx)(n.A,{className:"h-4 w-4 rtl:rotate-180"})}),(function(e,t,r,a){var n;let o,s,l=Math.max(1,null!=(n=null!=t?t:a)?n:r?e+1:e);l<=5?(o=1,s=l):(o=Math.max(1,Math.min(e-2,l-4)),s=Math.min(l,o+4));let i=[];o>1&&(i.push(1),o>2&&i.push("ellipsis"));for(let e=o;e<=s;e++)i.push(e);return(s<l||null===t&&r)&&i.push("ellipsis"),i})(r,p,!!i,f).map((e,t)=>"ellipsis"===e?(0,a.jsx)("span",{"aria-hidden":!0,className:"flex h-9 min-w-9 items-center justify-center text-sm text-muted-foreground",children:"â¦"},"ellipsis-".concat(t)):(0,a.jsx)("button",{type:"button",onClick:()=>b(e),"aria-label":"Page ".concat(e),"aria-current":e===r?"page":void 0,className:(0,s.cn)("flex h-9 min-w-9 items-center justify-center rounded-lg border px-2 text-sm font-medium transition-colors",e===r?"border-primary bg-primary text-primary-foreground":"border-border bg-background text-foreground hover:border-primary/40 hover:bg-muted"),children:e},e)),(0,a.jsx)("button",{type:"button",onClick:()=>b(r+1),disabled:!g,"aria-label":"Next page",className:v,children:(0,a.jsx)(o.A,{className:"h-4 w-4 rtl:rotate-180"})})]})}},611:(e,t,r)=>{r.d(t,{A:()=>a});let a=(0,r(37034).A)("Star",[["path",{d:"M11.525 2.295a.53.53 0 0 1 .95 0l2.31 4.679a2.123 2.123 0 0 0 1.595 1.16l5.166.756a.53.53 0 0 1 .294.904l-3.736 3.638a2.123 2.123 0 0 0-.611 1.878l.882 5.14a.53.53 0 0 1-.771.56l-4.618-2.428a2.122 2.122 0 0 0-1.973 0L6.396 21.01a.53.53 0 0 1-.77-.56l.881-5.139a2.122 2.122 0 0 0-.611-1.879L2.16 9.795a.53.53 0 0 1 .294-.906l5.165-.755a2.122 2.122 0 0 0 1.597-1.16z",key:"r04s7s"}]])},34033:(e,t,r)=>{r.d(t,{A:()=>a});let a=(0,r(37034).A)("Heart",[["path",{d:"M19 14c1.49-1.46 3-3.21 3-5.5A5.5 5.5 0 0 0 16.5 3c-1.76 0-3 .5-4.5 2-1.5-1.5-2.74-2-4.5-2A5.5 5.5 0 0 0 2 8.5c0 2.3 1.5 4.05 3 5.5l7 7Z",key:"c3ymky"}]])},35718:(e,t,r)=>{r.d(t,{G7:()=>i,L$:()=>u,h_:()=>m,oI:()=>d,uB:()=>l,xL:()=>c});var a=r(53137);r(82901);var n=r(76017),o=r(66731),s=r(17656);function l(e){let{className:t,...r}=e;return(0,a.jsx)(n.uB,{"data-slot":"command",className:(0,s.cn)("bg-popover text-popover-foreground flex h-full w-full flex-col overflow-hidden rounded-md",t),...r})}function i(e){let{className:t,...r}=e;return(0,a.jsxs)("div",{"data-slot":"command-input-wrapper",className:"flex h-9 items-center gap-2 border-b px-3",children:[(0,a.jsx)(o.A,{className:"size-4 shrink-0 opacity-50"}),(0,a.jsx)(n.uB.Input,{"data-slot":"command-input",className:(0,s.cn)("placeholder:text-muted-foreground flex h-10 w-full rounded-md bg-transparent py-3 text-sm outline-hidden disabled:cursor-not-allowed disabled:opacity-50",t),...r})]})}function d(e){let{className:t,...r}=e;return(0,a.jsx)(n.uB.List,{"data-slot":"command-list",className:(0,s.cn)("max-h-[300px] scroll-py-1 overflow-x-hidden overflow-y-auto",t),...r})}function c(e){let{...t}=e;return(0,a.jsx)(n.uB.Empty,{"data-slot":"command-empty",className:"py-6 text-center text-sm",...t})}function u(e){let{className:t,...r}=e;return(0,a.jsx)(n.uB.Group,{"data-slot":"command-group",className:(0,s.cn)("text-foreground [&_[cmdk-group-heading]]:text-muted-foreground overflow-hidden p-1 [&_[cmdk-group-heading]]:px-2 [&_[cmdk-group-heading]]:py-1.5 [&_[cmdk-group-heading]]:text-xs [&_[cmdk-group-heading]]:font-medium",t),...r})}function m(e){let{className:t,...r}=e;return(0,a.jsx)(n.uB.Item,{"data-slot":"command-item",className:(0,s.cn)("data-[selected=true]:bg-accent data-[selected=true]:text-accent-foreground [&_svg:not([class*='text-'])]:text-muted-foreground relative flex cursor-default items-center gap-2 rounded-sm px-2 py-1.5 text-sm outline-hidden select-none data-[disabled=true]:pointer-events-none data-[disabled=true]:opacity-50 [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",t),...r})}r(97079)},36272:(e,t,r)=>{r.d(t,{A:()=>a});let a=(0,r(37034).A)("ChevronLeft",[["path",{d:"m15 18-6-6 6-6",key:"1wnfg3"}]])},37705:(e,t,r)=>{r.d(t,{BT:()=>i,Wu:()=>d,ZB:()=>l,Zp:()=>o,aR:()=>s});var a=r(53137);r(82901);var n=r(17656);function o(e){let{className:t,...r}=e;return(0,a.jsx)("div",{"data-slot":"card",className:(0,n.cn)("bg-card text-card-foreground flex flex-col gap-6 rounded-xl border py-6 shadow-sm",t),...r})}function s(e){let{className:t,...r}=e;return(0,a.jsx)("div",{"data-slot":"card-header",className:(0,n.cn)("@container/card-header grid auto-rows-min grid-rows-[auto_auto] items-start gap-2 px-6 has-data-[slot=card-action]:grid-cols-[1fr_auto] [.border-b]:pb-6",t),...r})}function l(e){let{className:t,...r}=e;return(0,a.jsx)("div",{"data-slot":"card-title",className:(0,n.cn)("leading-none font-semibold",t),...r})}function i(e){let{className:t,...r}=e;return(0,a.jsx)("div",{"data-slot":"card-description",className:(0,n.cn)("text-muted-foreground text-sm",t),...r})}function d(e){let{className:t,...r}=e;return(0,a.jsx)("div",{"data-slot":"card-content",className:(0,n.cn)("px-6",t),...r})}},52602:(e,t,r)=>{r.d(t,{D:()=>s});var a=r(53137),n=r(55155),o=r(17656);function s(e){let{label:t,className:r}=e;return(0,a.jsxs)("div",{role:"status","aria-live":"polite",className:(0,o.cn)("flex min-h-[50vh] flex-1 flex-col items-center justify-center gap-4 px-4 py-16",r),children:[(0,a.jsx)(n.A,{className:"h-10 w-10 animate-spin text-primary","aria-hidden":"true"}),t?(0,a.jsx)("p",{className:"text-sm font-medium text-muted-foreground",children:t}):null,(0,a.jsx)("span",{className:"sr-only",children:"Loading"})]})}},61457:(e,t,r)=>{r.d(t,{A:()=>a});let a=(0,r(37034).A)("Play",[["polygon",{points:"6 3 20 12 6 21 6 3",key:"1oa8hb"}]])},67882:(e,t,r)=>{var a=r(98494);r.o(a,"useParams")&&r.d(t,{useParams:function(){return a.useParams}}),r.o(a,"usePathname")&&r.d(t,{usePathname:function(){return a.usePathname}}),r.o(a,"useRouter")&&r.d(t,{useRouter:function(){return a.useRouter}}),r.o(a,"useSearchParams")&&r.d(t,{useSearchParams:function(){return a.useSearchParams}})},71872:(e,t,r)=>{r.d(t,{A:()=>a});let a=(0,r(37034).A)("ShoppingCart",[["circle",{cx:"8",cy:"21",r:"1",key:"jimo8o"}
1],["circle",{cx:"19",cy:"21",r:"1",key:"13723u"}],["path",{d:"M2.05 2.05h2l2.66 12.42a2 2 0 0 0 2 1.58h9.78a2 2 0 0 0 1.95-1.57l1.65-7.43H5.12",key:"9zh506"}]])},78129:(e,t,r)=>{r.d(t,{A:()=>a});let a=(0,r(37034).A)("ChevronRight",[["path",{d:"m9 18 6-6-6-6",key:"mthhwq"}]])},89394:(e,t,r)=>{r.d(t,{J:()=>es});var a=r(53137),n=r(611),o=r(37705),s=r(17656),l=r(82901),i=r(29590),d=r(90125),c=r(20413),u=r(45995),m=r(35718),p=r(83960),f=r(32563),x=r(79049),h=r(32210),g=r(47722),b=r(54785),v=r(83936),j=r(69609),y=r(44142),N=r(73934),w=r(33613),C=r(62107),k=r(61450),A=r(85256),P=r(83815),_=Object.defineProperty,M=(e,t)=>_(e,"name",{value:t,configurable:!0}),R="Popover",[E,F]=(0,x.A)(R,[j.Bk]),z=(0,j.Bk)(),[S,B]=E(R),L=M(e=>{let{__scopePopover:t,children:r,open:n,defaultOpen:o,onOpenChange:s,modal:i=!1}=e,d=z(t),c=l.useRef(null),[u,m]=l.useState(!1),[p,f]=(0,k.i)({prop:n,defaultProp:null!=o&&o,onChange:s,caller:R});return(0,a.jsx)(j.bL,{...d,children:(0,a.jsx)(S,{scope:t,contentId:(0,v.B)(),triggerRef:c,open:p,onOpenChange:f,onOpenToggle:l.useCallback(()=>f(e=>!e),[f]),hasCustomAnchor:u,onCustomAnchorAdd:l.useCallback(()=>m(!0),[]),onCustomAnchorRemove:l.useCallback(()=>m(!1),[]),modal:i,children:r})})},"Popover"),O=l.forwardRef(M(function(e,t){let{__scopePopover:r,...n}=e,o=B("PopoverTrigger",r),s=z(r),l=(0,f.s)(t,o.triggerRef),i=(0,a.jsx)(w.sG.button,{type:"button","aria-haspopup":"dialog","aria-expanded":o.open,"aria-controls":o.open?o.contentId:void 0,"data-state":J(o.open),...n,ref:l,onClick:(0,p.mK)(e.onClick,o.onOpenToggle)});return o.hasCustomAnchor?i:(0,a.jsx)(j.Mz,{asChild:!0,...s,children:i})},"PopoverTrigger")),D="PopoverPortal",[I,T]=E(D,{forceMount:void 0}),Z=M(e=>{let{__scopePopover:t,forceMount:r,children:n,container:o}=e,s=B(D,t);return(0,a.jsx)(I,{scope:t,forceMount:r,children:(0,a.jsx)(N.C,{present:r||s.open,children:(0,a.jsx)(y.Z,{asChild:!0,container:o,children:n})})})},"PopoverPortal"),G="PopoverContent",K=l.forwardRef(M(function(e,t){let r=T(G,e.__scopePopover),{forceMount:n=r.forceMount,...o}=e,s=B(G,e.__scopePopover);return(0,a.jsx)(N.C,{present:n||s.open,children:s.modal?(0,a.jsx)(q,{...o,ref:t}):(0,a.jsx)(Y,{...o,ref:t})})},"PopoverContent")),U=(0,C.TL)("PopoverContent.RemoveScroll"),q=l.forwardRef(M(function(e,t){let r=B(G,e.__scopePopover),n=l.useRef(null),o=(0,f.s)(t,n),s=l.useRef(!1);return l.useEffect(()=>{let e=n.current;if(e)return(0,A.Eq)(e)},[]),(0,a.jsx)(P.A,{as:U,allowPinchZoom:!0,children:(0,a.jsx)(H,{...e,ref:o,trapFocus:r.open,disableOutsidePointerEvents:!0,onCloseAutoFocus:(0,p.mK)(e.onCloseAutoFocus,e=>{var t;e.preventDefault(),s.current||null==(t=r.triggerRef.current)||t.focus()}),onPointerDownOutside:(0,p.mK)(e.onPointerDownOutside,e=>{let t=e.detail.originalEvent,r=0===t.button&&!0===t.ctrlKey;s.current=2===t.button||r},{checkForDefaultPrevented:!1}),onFocusOutside:(0,p.mK)(e.onFocusOutside,e=>e.preventDefault(),{checkForDefaultPrevented:!1})})})},"PopoverContentModal")),Y=l.forwardRef(M(function(e,t){let r=B(G,e.__scopePopover),n=l.useRef(!1),o=l.useRef(!1);return(0,a.jsx)(H,{...e,ref:t,trapFocus:!1,disableOutsidePointerEvents:!1,onCloseAutoFocus:t=>{var a,s;null==(a=e.onCloseAutoFocus)||a.call(e,t),t.defaultPrevented||(n.current||null==(s=r.triggerRef.current)||s.focus(),t.preventDefault()),n.current=!1,o.current=!1},onInteractOutside:t=>{var a,s;null==(a=e.onInteractOutside)||a.call(e,t),t.defaultPrevented||(n.current=!0,"pointerdown"===t.detail.originalEvent.type&&(o.current=!0));let l=t.target;(null==(s=r.triggerRef.current)?void 0:s.contains(l))&&t.preventDefault(),"focusin"===t.detail.originalEvent.type&&o.current&&t.preventDefault()}})},"PopoverContentNonModal")),H=l.forwardRef(M(function(e,t){let{__scopePopover:r,trapFocus:n,onOpenAutoFocus:o,onCloseAutoFocus:s,disableOutsidePointerEvents:l,onEscapeKeyDown:i,onPointerDownOutside:d,onFocusOutside:c,onInteractOutside:u,...m}=e,p=B(G,r),f=z(r);return(0,g.Oh)(),(0,a.jsx)(b.n,{asChild:!0,loop:!0,trapped:n,onMountAutoFocus:o,onUnmountAutoFocus:s,children:(0,a.jsx)(h.qW,{asChild:!0,disableOutsidePointerEvents:l,onInteractOutside:u,onEscapeKeyDown:i,onPointerDownOutside:d,onFocusOutside:c,onDismiss:()=>p.onOpenChange(!1),deferPointerDownOutside:!0,children:(0,a.jsx)(j.UC,{"data-state":J(p.open),role:"dialog",id:p.contentId,...f,...m,ref:t,style:{...m.style,"--radix-popover-content-transform-origin":"var(--radix-popper-transform-origin)","--radix-popover-content-available-width":"var(--radix-popper-available-width)","--radix-popover-content-available-height":"var(--radix-popper-available-height)","--radix-popover-trigger-width":"var(--radix-popper-anchor-width)","--radix-popover-trigger-height":"var(--radix-popper-anchor-height)"}})})})},"PopoverContentImpl"));function J(e){return e?"open":"closed"}function V(e){let{...t}=e;return(0,a.jsx)(L,{"data-slot":"popover",...t})}function W(e){let{...t}=e;return(0,a.jsx)(O,{"data-slot":"popover-trigger",...t})}function $(e){let{className:t,align:r="center",sideOffset:n=4,...o}=e;return(0,a.jsx)(Z,{children:(0,a.jsx)(K,{"data-slot":"popover-content",align:r,sideOffset:n,className:(0,s.cn)("bg-popover text-popover-foreground data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 data-[side=bottom]:slide-in-from-top data-[side=left]:slide-in-from-right data-[side=right]:sli
1de-in-from-left data-[side=top]:slide-in-from-bottom z-50 w-72 origin-(--radix-popover-content-transform-origin) rounded-md border p-4 shadow-md outline-hidden",t),...o})})}function Q(e){return e.name||e.nameEn||e.nameAr||e.slug||e.id}async function X(e){let t=await fetch(e);if(!t.ok)throw Error("Failed to fetch brands: ".concat(t.status));let r=await t.json(),a=Array.isArray(r)?r:[],n=new Set;return a.filter(e=>!(!e.id||n.has(e.id))&&(n.add(e.id),!0))}M(J,"getState");let ee=null,et=null;function er(e){var t;let{selectedBrands:r,onBrandChange:n}=e,[o,p]=(0,l.useState)(!1),[f,x]=(0,l.useState)(""),[h,g]=(0,l.useState)(null!=ee?ee:[]),[b,v]=(0,l.useState)(!ee),[j,y]=(0,l.useState)(null),[N,w]=(0,l.useState)(!1),C=(0,l.useRef)(new Map);(0,l.useEffect)(()=>{let e=!0;return(ee?Promise.resolve(ee):(!et&&(et=X("/api/brands?tier=1&limit=50&sort=name_asc").then(e=>e.length>0?e:X("/api/brands?limit=50&sort=name_asc")).then(e=>(ee=e,e)).catch(e=>(et=null,console.error("[brand-filter] Failed to load brands",e),[]))),et)).then(t=>{e&&(g(t),v(!1))}),()=>{e=!1}},[]);let k=f.trim();(0,l.useEffect)(()=>{if(!k){y(null),w(!1);return}w(!0);let e=new AbortController,t=setTimeout(async()=>{try{let t=new URLSearchParams({search:k,limit:String(20),sort:"name_asc"}),r=await fetch("/api/brands?".concat(t.toString()),{signal:e.signal});if(!r.ok)throw Error("Failed to search brands: ".concat(r.status));let a=await r.json();y(Array.isArray(a)?a.filter(e=>e.id):[])}catch(e){"AbortError"!==e.name&&(console.error("[brand-filter] Brand search failed",e),y(null))}finally{w(!1)}},300);return()=>{e.abort(),clearTimeout(t)}},[k]);let A=(0,l.useMemo)(()=>{if(!k)return h;if(j)return j;let e=k.toLowerCase();return h.filter(t=>Q(t).toLowerCase().includes(e))},[k,j,h]);for(let e of A)C.current.set(e.id,e);let P=e=>{r.includes(e)?n(r.filter(t=>t!==e)):n([...r,e])},_=0===r.length?"All brands":1===r.length?Q(null!=(t=C.current.get(r[0]))?t:{id:r[0]}):"".concat(r.length," brands selected");return(0,a.jsxs)("div",{className:"space-y-2",children:[(0,a.jsxs)(V,{open:o,onOpenChange:p,children:[(0,a.jsx)(W,{asChild:!0,children:(0,a.jsxs)(u.$,{variant:"outline",role:"combobox","aria-expanded":o,className:"w-full justify-between font-normal",children:[(0,a.jsx)("span",{className:"truncate",children:_}),(0,a.jsx)(i.A,{className:"ms-2 h-4 w-4 shrink-0 opacity-50"})]})}),(0,a.jsx)($,{className:"w-[var(--radix-popover-trigger-width)] p-0",align:"start",children:(0,a.jsxs)(m.uB,{shouldFilter:!1,children:[(0,a.jsx)(m.G7,{placeholder:"Search brands...",value:f,onValueChange:x}),(0,a.jsxs)(m.oI,{className:"max-h-72",children:[(0,a.jsx)(m.xL,{children:b||N?"Loading brands...":"No brands found."}),A.map(e=>{let t=r.includes(e.id);return(0,a.jsxs)(m.h_,{value:e.id,onSelect:()=>P(e.id),children:[(0,a.jsx)(d.A,{className:(0,s.cn)("me-2 h-4 w-4 shrink-0",t?"opacity-100":"opacity-0")}),(0,a.jsx)("span",{className:"truncate",children:Q(e)})]},e.id)})]})]})})]}),r.length>0&&(0,a.jsx)("div",{className:"flex flex-wrap gap-1.5",children:r.map(e=>{let t=C.current.get(e);return(0,a.jsxs)("button",{type:"button",onClick:()=>P(e),className:"inline-flex items-center gap-1 rounded-full border border-primary/30 bg-primary/10 py-1 ps-2.5 pe-1.5 text-xs font-medium text-foreground transition hover:bg-primary/20",children:[(0,a.jsx)("span",{className:"max-w-32 truncate",children:t?Q(t):e}),(0,a.jsx)(c.A,{className:"h-3 w-3 shrink-0","aria-hidden":!0}),(0,a.jsx)("span",{className:"sr-only",children:"Remove brand filter"})]},e)})})]})}let ea=[0,50,100,200,300,400,500,750,1e3],en=ea[ea.length-1];function eo(e){return new Intl.NumberFormat("en-AE",{maximumFractionDigits:0}).format(e)}function es(e){let{minPrice:t,maxPrice:r,minRating:l,selectedBrands:i=[],onPriceChange:d,onRatingChange:c,onBrandChange:u,onClear:m,children:p}=e,f=Math.max(ea[0],t),x=Math.min(ea[ea.length-1],r),h=ea.length,g=e=>{let t=0,r=1/0;return ea.forEach((a,n)=>{let o=Math.abs(a-e);o<r&&(r=o,t=n)}),t},b=g(f),v=Math.max(b+1,g(x)),j=b/(h-1)*100,y=Math.max(v/(h-1)*100-j,0),N=ea[b],w=ea[v];return(0,a.jsxs)(o.Zp,{className:"p-6 sticky top-24",children:[(0,a.jsx)("h2",{className:"font-bold text-lg mb-6",children:"Filters"}),p&&(0,a.jsx)("div",{className:"mb-6 space-y-4",children:p}),(0,a.jsxs)("div",{className:"mb-6",children:[(0,a.jsx)("h3",{className:"font-semibold mb-3",children:"Brand"}),(0,a.jsx)(er,{selectedBrands:i,onBrandChange:u})]}),(0,a.jsxs)("div",{className:"mb-6",children:[(0,a.jsx)("h3",{className:"font-semibold mb-3",children:"Price Range"}),(0,a.jsxs)("div",{className:"space-y-4",children:[(0,a.jsxs)("div",{className:"relative h-1.5 rounded-full bg-muted",children:[(0,a.jsx)("div",{className:"absolute inset-y-0 z-[1] rounded-full bg-primary",style:{left:"".concat(j,"%"),width:"".concat(y,"%")}}),(0,a.jsx)("input",{type:"range",min:0,max:h-1,step:1,value:b,onChange:e=>{let t=Number(e.target.value);t>=v&&(t=Math.max(0,v-1)),d(ea[t],w)}
1,"aria-label":"Minimum price",className:"price-slider z-[2]",style:{accentColor:"var(--primary)"}}),(0,a.jsx)("input",{type:"range",min:0,max:h-1,step:1,value:v,onChange:e=>{let t=Number(e.target.value);t<=b&&(t=Math.min(h-1,b+1)),d(N,ea[t])},"aria-label":"Maximum price",className:"price-slider z-[3]",style:{accentColor:"var(--primary)"}})]}),(0,a.jsxs)("div",{className:"grid grid-cols-[minmax(0,1fr)_auto_minmax(0,1fr)] items-end gap-3",children:[(0,a.jsxs)("div",{className:"flex min-w-0 flex-col gap-1",children:[(0,a.jsx)("span",{className:"text-[10px] font-medium uppercase tracking-wide text-muted-foreground",children:"AED"}),(0,a.jsx)("select",{value:N,onChange:e=>d(Number(e.target.value),w),className:"w-full rounded-lg border border-input bg-card px-3 py-2 text-sm font-semibold text-foreground shadow-sm focus:outline-none focus:ring-2 focus:ring-primary/30",children:ea.filter(e=>e<w).map(e=>(0,a.jsx)("option",{value:e,children:0===e?"Min":eo(e)},e))})]}),(0,a.jsx)("span",{className:"pb-2 text-xs font-medium uppercase tracking-wide text-muted-foreground",children:"to"}),(0,a.jsxs)("div",{className:"flex min-w-0 flex-col gap-1",children:[(0,a.jsx)("span",{className:"text-[10px] font-medium uppercase tracking-wide text-muted-foreground",children:"AED"}),(0,a.jsx)("select",{value:w,onChange:e=>d(N,Number(e.target.value)),className:"w-full rounded-lg border border-input bg-card px-3 py-2 text-sm font-semibold text-foreground shadow-sm focus:outline-none focus:ring-2 focus:ring-primary/30",children:ea.filter(e=>e>N).map(e=>(0,a.jsx)("option",{value:e,children:e===en?"".concat(eo(e),"+"):eo(e)},e))})]})]})]})]}),(0,a.jsxs)("div",{className:"mb-6",children:[(0,a.jsx)("h3",{className:"font-semibold mb-3",children:"Rating"}),(0,a.jsx)("div",{className:"space-y-2",children:[4,3,2,1].map(e=>{let t=l===e;return(0,a.jsx)("button",{type:"button",onClick:()=>c(t?0:e),className:(0,s.cn)("flex w-full items-center justify-between rounded-lg border px-3 py-2 text-left text-sm transition",t?"border-primary bg-primary/10 text-primary-foreground":"border-border hover:border-primary/40 hover:bg-muted"),children:(0,a.jsxs)("span",{className:"flex items-center gap-2",children:[(0,a.jsx)("span",{className:(0,s.cn)("grid size-4 place-items-center rounded border",t?"border-primary bg-primary":"border-border bg-background"),children:t&&(0,a.jsx)("span",{className:"size-2.5 rounded-sm bg-primary-foreground"})}),(0,a.jsxs)("span",{className:"flex items-center gap-1 text-foreground",children:[e," ",(0,a.jsx)(n.A,{className:"h-3 w-3 fill-current text-accent"}),(0,a.jsx)("span",{className:"text-muted-foreground",children:"& above"})]})]})},e)})})]}),(0,a.jsx)("button",{onClick:m,className:"w-full px-4 py-2 border border-input rounded-lg hover:bg-accent/10 transition-colors",children:"Clear Filters"})]})}},97079:(e,t,r)=>{r.d(t,{Cf:()=>c,Es:()=>m,L3:()=>p,c7:()=>u,lG:()=>l,rr:()=>f});var a=r(53137);r(82901);var n=r(78061),o=r(20413),s=r(17656);function l(e){let{...t}=e;return(0,a.jsx)(n.bL,{"data-slot":"dialog",...t})}function i(e){let{...t}=e;return(0,a.jsx)(n.ZL,{"data-slot":"dialog-portal",...t})}function d(e){let{className:t,...r}=e;return(0,a.jsx)(n.hJ,{"data-slot":"dialog-overlay",className:(0,s.cn)("data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 fixed inset-0 z-50 bg-black/50",t),...r})}function c(e){let{className:t,children:r,showCloseButton:l=!0,...c}=e;return(0,a.jsxs)(i,{"data-slot":"dialog-portal",children:[(0,a.jsx)(d,{}),(0,a.jsxs)(n.UC,{"data-slot":"dialog-content",className:(0,s.cn)("bg-background data-[state=open]:animate-in data-[state=closed]:animate-out data-[state=closed]:fade-out-0 data-[state=open]:fade-in-0 data-[state=closed]:zoom-out-95 data-[state=open]:zoom-in-95 fixed top-[50%] left-[50%] z-50 grid w-full max-w-[calc(100%-2rem)] translate-x-[-50%] translate-y-[-50%] gap-4 rounded-lg border p-6 shadow-lg duration-200 sm:max-w-lg",t),...c,children:[r,l&&(0,a.jsxs)(n.bm,{"data-slot":"dialog-close",className:"ring-offset-background focus:ring-ring data-[state=open]:bg-accent data-[state=open]:text-muted-foreground absolute top-4 right-4 rounded-xs opacity-70 transition-opacity hover:opacity-100 focus:ring-2 focus:ring-offset-2 focus:outline-hidden disabled:pointer-events-none [&_svg]:pointer-events-none [&_svg]:shrink-0 [&_svg:not([class*='size-'])]:size-4",children:[(0,a.jsx)(o.A,{}),(0,a.jsx)("span",{className:"sr-only",children:"Close"})]})]})]})}function u(e){let{className:t,...r}=e;return(0,a.jsx)("div",{"data-slot":"dialog-header",className:(0,s.cn)("flex flex-col gap-2 text-center sm:text-left",t),...r})}function m(e){let{className:t,...r}=e;return(0,a.jsx)("div",{"data-slot":"dialog-footer",className:(0,s.cn)("flex flex-col-reverse gap-2 sm:flex-row sm:justify-end",t),...r})}function p(e){let{className:t,...r}=e;return(0,a.jsx)(n.hE,{"data-slot":"dialog-title",className:(0,s.cn)("text-lg leading-none font-semibold",t),...r})}function f(e){let{className:t,...r}=e;return(0,a.jsx)(n.VY,{"data-slot":"dialog-description",className:(0,s.cn)("text-muted-foreground text-sm",t),...r})}}}]);
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.