PageSourceSearch

https://shophcc.com/_next/static/immutable/chunks/14y2jygpvy8bb.js

js shophcc.com collected 2026-09-24 12:43:38 UTC 149,774 bytes, 1 lines download raw bytes

1(globalThis.TURBOPACK||(globalThis.TURBOPACK=[])).push(["object"==typeof document?document.currentScript:void 0,908049,e=>{"use strict";var t=e.i(843476),s=e.i(64722),l=e.i(318587),a=e.i(811134),r=e.i(955135),i=e.i(388013),n=e.i(815330),c=e.i(829045),o=e.i(137963),d=e.i(940157),x=e.i(430494),u=e.i(310160),m=e.i(811942),h=e.i(564784);e.s(["default",0,function({children:e,active:p,setActive:f,isSortByOpen:b,setIsSortByOpen:g,options:y,handleSort:j,toggleDrawer:v,customFilterListData:N,queryValues:w,setQueryValues:C,handleClearAll:k,subCategoryList:S,weightList:L,brandList:A,provider:E,todaysSpecialsValue:T,adCategories:F,isBrand:D=!1,isFilterVisible:R,setIsFilterVisible:O,filterResult:P,currentSelectedPage:V=0,showProductSkeleton:G=!1}){let B=(0,h.useFilterPanelWheelChain)(R),z=!G&&P?(0,u.getShopProductRangeDisplay)({currentPage:V,pageCount:P.pageCount??0,productCount:P.productCount??0,pageSize:P.pageSize??x.SHOP_PRODUCTS_PAGE_SIZE_MOBILE}):null,W=(0,u.hasActiveShopFilters)(w);return(0,t.jsxs)("div",{className:"md:grid grid-cols-4 gap-3",id:"category-products",children:[(0,t.jsxs)("div",{className:(0,o.cn)(R?"col-span-3":"col-span-4"),children:[(0,t.jsxs)("div",{className:"sticky top-0 z-20 w-full self-start bg-white p-3 flex justify-between max-md:hidden border-b border-[#E5E5E5]",children:[(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("div",{children:(0,t.jsxs)("button",{type:"button",onClick:()=>O(e=>!e),className:"flex items-center cursor-pointer","aria-expanded":R,"aria-controls":"shop-filter-panel",children:[(0,t.jsx)(d.SlidersIcon,{size:16,className:"-rotate-90"}),(0,t.jsx)("span",{className:"text-sm font-normal ml-2 global-body-color",children:R?"Hide Filter":"Show Filter"})]})}),!D&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(m.SquaresFourIcon,{size:32,onClick:()=>f(1),className:`${1===p&&"primary-background text-white"} rotate-90 text-[#A0A0A0] border border-[#E5E5E5] p-2 w-8 h-8 cursor-pointer text-2xl rounded-md`}),(0,t.jsx)(i.List,{onClick:()=>f(2),className:`${2===p&&"bg-[#34A203] text-white"} text-[#A0A0A0] border border-[#E5E5E5] p-2 w-8 h-8 cursor-pointer text-2xl rounded-md`})]}),z&&(0,t.jsxs)("p",{className:"text-sm global-body-color whitespace-nowrap",children:[z.total.toLocaleString()," products"]})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2",children:[(0,t.jsx)("p",{className:"global-body-color",children:"Sort By"}),(0,t.jsx)("div",{children:(0,t.jsx)(s.default,{onClickOutside:()=>g(!1),children:(0,t.jsxs)("div",{className:"relative",children:[(0,t.jsxs)("div",{onClick:()=>g(!b),className:"flex items-center gap-2 text-sm font-medium py-2 cursor-pointer w-max",children:[(0,t.jsx)("span",{className:"global-body-color",children:w?.sort?.label?w?.sort?.label:"Sort By"}),(0,t.jsx)(n.CaretDown,{size:16,className:"global-body-color"})]}),(0,t.jsx)("div",{className:`absolute left-[-138%] py-3 min-w-48 ${b?"top-12":"top-8 opacity-0 invisible"} border rounded-2xl shadow-md bg-white transition-all z-50`,children:y.map((e,s)=>(0,t.jsx)("div",{className:"hover:bg-green-50 p-2 my-1",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"radio",name:"sort-by-desktop",value:e.value,checked:w?.sort?.label==e.label,onChange:()=>{j(e),g(!1)},className:"peer relative h-5 w-5 appearance-none rounded-full transition-all border-2 checked:border-[4px] checked:border-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"text-sm text-primary_text font-medium ml-2",children:e.label})]})},"sort-filter"+s))})]})})})]})]}),(0,t.jsx)("div",{className:(0,o.cn)("md:hidden sticky top-[74px] z-20 bg-white border-b border-[#E5E5E5] px-3 py-3",D?"px-2":""),children:(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[!D&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("button",{type:"button",onClick:()=>f(1),"aria-label":"Grid view",className:(0,o.cn)("p-2 rounded cursor-pointer w-8 h-8 flex justify-center items-center",1===p?"fill-button rounded-md":"text-[#A0A0A0]"),children:(0,t.jsx)(c.SquaresFour,{size:20})}),(0,t.jsx)("button",{type:"button",onClick:()=>f(2),"aria-label":"List view",className:(0,o.cn)("cursor-pointer w-8 h-8 flex justify-center items-center",2===p?"fill-button rounded-md":"text-[#A0A0A0]"),children:(0,t.jsx)(r.ListDashes,{size:20})})]}),z&&(0,t.jsxs)("p",{className:"text-sm text-gray-600 global-body-color whitespace-nowrap",children:[z.total.toLocaleStr
1ing()," products"]})]}),(0,t.jsxs)("button",{type:"button",onClick:v,className:"flex items-center gap-2 cursor-pointer",children:[(0,t.jsxs)("span",{className:"relative",children:[(0,t.jsx)(d.SlidersIcon,{size:16,className:"-rotate-90 global-body-color"}),W&&(0,t.jsx)("span",{className:"absolute -top-0.5 -right-0.5 h-2 w-2 rounded-full bg-black"})]}),(0,t.jsx)("span",{className:"text-sm global-body-color",children:"Filters"})]})]})}),(0,t.jsx)(a.default,{category:F}),e]}),R&&(0,t.jsx)("div",{id:"shop-filter-panel",className:"col-span-1 max-md:hidden ps-3 min-h-0",children:(0,t.jsx)("div",{ref:B,className:"sticky top-0 z-20 self-start bg-white h-[calc(100dvh-10px)] overflow-y-auto no-scrollbar",children:(0,t.jsx)(l.default,{customFilterListData:N,filterData:w,setQueryValues:C,handleClearAll:k,subCategoryList:S,weightList:L,provider:E,brandList:A,todaysSpecialsValue:T,unifiedScroll:!0})})})]})}])},150814,e=>{"use strict";var t=e.i(843476),s=e.i(271645),l=e.i(912130),a=e.i(64722),r=e.i(258288),i=e.i(715628),n=e.i(944089),c=e.i(831569),o=e.i(466492),d=e.i(836133),x=e.i(111942),u=e.i(578546),m=e.i(247132),h=e.i(8445),p=e.i(310160),f=e.i(375677),b=e.i(29507),g=e.i(430494),y=e.i(808340),j=e.i(396565),v=e.i(209501),N=e.i(811134),w=e.i(815330),C=e.i(829045),k=e.i(388013),S=e.i(676634),L=e.i(137963),A=e.i(411087),E=e.i(701973),T=e.i(331991),F=e.i(201796),D=e.i(577854);let R=({filterName:e,filterOpt:l,secondaryFilterList:a,setSecondaryFilterList:r,handleSubmitFilter:i,filterData:n})=>{let[c,o]=(0,s.useState)(!1),[d,x]=(0,s.useState)(""),{handleStateChange:u,handleClearStates:m}=(0,A.default)();return(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("button",{onClick:()=>o(!0),className:`px-3 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${c||a?.effects?.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),a?.states?.length>0?(0,t.jsx)("p",{className:"bg-teal-800 p-1 text-white rounded-full w-4 h-4 flex items-center justify-center text-xs font-light",children:a?.states?.length}):c?(0,t.jsx)(T.CaretUp,{fontWeight:"300"}):(0,t.jsx)(w.CaretDown,{fontWeight:"300"})]}),c&&(0,t.jsx)("div",{className:"fixed inset-0 flex items-end justify-center bg-black bg-opacity-50 z-[60]",children:(0,t.jsxs)("div",{className:`w-full max-h-[466px] bg-white pt-8 rounded-t-xl flex flex-col items-start justify-between shadow-lg transition-transform duration-500 ease-in-out transform ${c?"translate-y-0":"translate-y-full"}`,children:[(0,t.jsxs)("div",{className:"flex justify-between items-center px-6 w-full",children:[(0,t.jsxs)("h2",{className:"text-lg font-semibold text-center flex-1",children:["Filter By ",e]}),(0,t.jsx)("button",{onClick:()=>o(!1),className:"text-gray-500 hover:text-black",children:(0,t.jsx)(D.X,{size:24})})]}),(0,t.jsx)("div",{className:"px-6 py-4",children:e}),(0,t.jsx)("div",{className:"overflow-y-auto px-6 w-full pb-2",children:l.filter(e=>e?.name?.toLowerCase().includes(d?.toLowerCase())).map(e=>(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:e?.name,checked:a?.states.includes(e?.name),onChange:e=>{u(e,a,r)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(F.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal",children:(0,E.makeTitleCase)(e?.name)})]},"state"+e?._id))}),(0,t.jsxs)("div",{className:"flex justify-between px-6 py-4 bg-gray-50 w-full",children:[(0,t.jsx)("button",{onClick:()=>{m(r,n,i,!0)},className:"text-sm primary-text hover:underline",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{i(),o(!1)},className:"text-xs font-medium fill-button py-[6px] px-3 rounded-full",children:"Show Products"})]})]})})]})};e.s(["default",0,function({children:e,active:A,setActive:E,isSortByOpen:T,setIsSortByOpen:F,options:D,handleSort:O,toggleDrawer:P,customFilterListData:V,setQueryValues:G,handleClearAll:B,subCategoryList:z,weightList:W,filterData:$,provider:I,brandList:U,todaysSpecialsValue:M,adCategories:Y,isBrand:H=!1}){let{secondaryFilterList:_,setSecondaryFilterList:X,setSelectedSort:Z,handleSubmitFilter:q}=(0,f.default)(),{commonCMSData:Q}=(0,r.useGlobalStore)(),K=Q?.ediblesWeightDisplayEnabled===!0,[J,ee]=(0,s.use
1State)([]),[et,es]=(0,s.useState)([]),[el,ea]=(0,s.useState)([]),[er,ei]=(0,s.useState)(!1),[en,ec]=(0,s.useState)([0,g.PRICEMAX]),[eo,ed]=(0,s.useState)([0,100]),[ex,eu]=(0,s.useState)([0,100]),[em,eh]=(0,s.useState)([]),ep=(0,v.isMobileViewport)();(0,s.useEffect)(()=>{X({...$})},[$]),(0,s.useEffect)(()=>{$?.sort?.label&&Z($?.sort?.label)},[$?.sort]),(0,s.useEffect)(()=>{ee([...z])},[z]),(0,s.useEffect)(()=>{es([...W])},[W]),(0,s.useEffect)(()=>{ea([...U])},[U]),(0,s.useEffect)(()=>{eh([...M])},[M]),(0,s.useEffect)(()=>{_?.price&&_?.price?.length&&ec(_?.price)},[_?.price]),(0,s.useEffect)(()=>{_?.potencyThcValue&&_?.potencyThcValue?.length&&ed(_?.potencyThcValue)},[_?.potencyThcValue]),(0,s.useEffect)(()=>{_?.potencyCbdValue&&_?.potencyCbdValue?.length&&eu(_?.potencyCbdValue)},[_?.potencyCbdValue]);let ef=(0,y.isProviderShowcase)(I??null);return(0,t.jsxs)("div",{className:"md:grid grid-cols-4 gap-3",id:"category-products",children:[(0,t.jsx)("div",{className:"col-span-1 max-md:hidden ps-3",children:(0,t.jsx)(l.default,{customFilterListData:V,filterData:$,setQueryValues:G,handleClearAll:B,subCategoryList:z,weightList:W,handleSort:O,setIsSortByOpen:F,price:en,setPrice:ec,potencyThcValue:eo,setPotencyThcValue:ed,potencyCbdValue:ex,setPotencyCbdValue:eu,provider:I,brandList:U,todaySpecialsValue:M})}),(0,t.jsxs)("div",{className:"col-span-3",children:[!H&&(0,t.jsxs)("div",{className:"p-3 flex justify-between max-md:hidden",children:[!ep&&(0,t.jsx)("h2",{className:"text-2xl font-bold global-heading-color",children:"All Products"}),(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("div",{onClick:()=>E(1),className:`${1===A?"primary-background text-white":"bg-[#f3f4f6] text-black"}  text-[#A0A0A0]  p-1 rounded-full w-10 h-10 cursor-pointer flex items-center justify-center`,children:(0,t.jsx)(C.SquaresFour,{weight:"fill",size:18})}),(0,t.jsx)("div",{onClick:()=>E(2),className:`${2===A?"primary-background text-white":"bg-[#f3f4f6] text-black"} text-[#A0A0A0]  p-1 rounded-full w-10 h-10  cursor-pointer flex items-center justify-center`,children:(0,t.jsx)(k.List,{size:20})})]})]}),(0,t.jsxs)("div",{className:(0,L.cn)("md:hidden",H?"p-2":""),children:[ep&&!H&&(0,t.jsx)("h2",{className:"font-semibold text-base mb-3 global-heading-color",children:"Shop all Products"}),(0,t.jsxs)("div",{className:"flex items-center justify-between gap-2 mb-3",children:[(0,t.jsx)("div",{className:"w-full overflow-x-auto no-scrollbar",children:(0,t.jsxs)("ul",{className:"w-full max-w-[1000px] flex items-center gap-3",children:[(0,t.jsx)("li",{children:(0,t.jsx)(i.default,{filterName:"Category",filterOpt:V?.category,alignment:"",secondaryFilterList:_,setSecondaryFilterList:X,handleSubmitFilter:q,tempSubCategoryList:J,setTempSubCategoryList:ee,tempWeightList:et,setTempWeightList:es,setTempBrandList:ea,setNewSubCategoryAndWeightLoader:ei,filterData:$,setTempSpecialsValues:eh})}),er?(0,t.jsx)("div",{className:"relative",children:(0,t.jsx)("div",{className:"px-3 h-6 w-24 py-4 text-sm bg-gray-200 flex items-center gap-1 border rounded-full border-gray-300 animate-pulse"})}):(0,t.jsx)(t.Fragment,{children:_?.categories?.length>0&&J?.length>0?(0,t.jsx)("li",{children:(0,t.jsx)(n.default,{filterName:"Sub Category",filterOpt:J,alignment:"",secondaryFilterList:_,setSecondaryFilterList:X,handleSubmitFilter:q,filterData:$})}):(0,t.jsx)(t.Fragment,{})}),er?(0,t.jsx)("div",{className:"relative",children:(0,t.jsx)("div",{className:"px-3 h-6 w-24 py-4 text-sm bg-gray-200 flex items-center gap-1 border rounded-full border-gray-300 animate-pulse"})}):(0,t.jsx)(t.Fragment,{children:(K||!(0,p.isEdiblesCategorySelected)($?.categories))&&_?.categories?.length>0&&!(0,p.isInvalidCategoryForShowingWeight)($?.categories)&&et?.length>0?(0,t.jsx)("li",{children:(0,t.jsx)(c.default,{filterName:"Weight",filterOpt:et,alignment:"",secondaryFilterList:_,setSecondaryFilterList:X,handleSubmitFilter:q,filterData:$})}):(0,t.jsx)(t.Fragment,{})}),!ef&&(0,t.jsx)("li",{children:(0,t.jsx)(o.default,{filterName:"Brand",filterOpt:el,alignment:"",secondaryFilterList:_,setSecondaryFilterList:X,handleSubmitFilter:q,filterData:$,setTempSpecialsValues:eh})}),(0,t.jsx)("li",{children:(0,t.jsx)(d.default,{filterName:"Strain",filterOpt:V?.strainType,alignment:"",secondaryFilterList:_,setSecondaryFilterList:X,handleSubmitFilter:q,filterData:$})}),(0,t.jsx)("li",{children:(0,t.jsx)(x.default,{filterName:"Effect",filterOpt:V?.effects,alignment:"",secondaryFilterList:_,setSecondaryFilterList:X,handleSubmitFilter:q,filterData:$})}),(0,y.isEcommerceOrPortfolioProvider)(I??"")&&(0,t.jsx)("li",{children:(0,t.jsx)(j.default,{filterName:"Tag",filterOpt:V?.productTag,alignment:"",secondaryFilterList:_,setSecondaryFilterList:X,handleSubmitFilter:q,filterData:$})}),(0,t.jsx)("li",{children:(0,t.jsx)(u.default,{filterName:"Special",filterOpt:em,alignment:"",secondaryFilterList:_,setSecondaryFilterList:X,handleSubmitFilter:q,filterData:$})}),(0,t.jsx)("li",{children:(0,t.jsx)(b.default,{filterName:"Price",alignment:"",secondaryFilterList:_,setSecondaryFilterList:X,handleSubmitFilter:q,price:en,setPrice:ec})}),!(0,y.isEcommerceOrPortfolioProvider)(I??"")&&(0,t.jsx)("li",{children:(0,t.jsx)(m.default,{filterName:"Potency",setSecondaryFilterList:X,handleSubmitFilter:q,potencyThcValue:eo,setPotencyThcValue:ed,potencyCbdValue:ex,setPotencyCbdValue:eu})}),ef&&(0,t.jsx)("li",{children:(0,t.jsx)(R,{filterName:"States",filterOpt:V?.states,alignment:"",secondaryFilterList:_,setSecondaryFilterList:X,handleSubmitFilter:q,filterData:$})})]})}),!H&&(0,t.jsx)("div",{children:(0,t.jsx)("div",{className:"flex items-center gap-4",children:(0,t.jsx)(h.default,{filterName:"View",filterOpt:["List View","Grid View"],alignment:"right-0",active:A,setActive:E,shopFilterV3:!0})})})]}),(0,t.jsxs)("div",{className:" flex items-center justify-between",children:[(0,t.jsxs)("div",{className:"flex items-center",children:[(0,t.jsx)("p",{className:"text-sm font-medium global-body-color",children:"Sort:"}),(0,t.jsx)("div",{children:(0,t.jsx)(a.default,{onClickOutside:()=>F(!1),children:(0,t.jsxs)("div",{className:"relative",children:[(0,t.jsxs)("div",{onClick:()=>F(e=>!e),className:"flex items-center gap-2 text-xs font-medium rounded-md py-2 px-3 cursor-pointer w-max global-body-color",children:[(0,t.jsx)("span",{children:$?.sort?.label?$?.sort?.label:"Sort By"}),(0,t.jsx)(w.CaretDown,{size:16})]}),(0,t.jsx)("div",{className:`absolute right py-3 min-w-48 ${T?"top-12":"top-8 opacity-0 invisible"} border rounded-2xl shadow-md bg-white transition-all z-50`,children:D.map((e,s)=>(0,t.jsx)("div",{className:"hover:bg-green-50 p-2 my-1 cursor-pointer",onClick:()=>{O&&(O(e),F(!1))},children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"radio",name:"sort-by-mobile-v3",value:e.value,checked:$?.sort?.label===e.label,readOnly:!0,className:"peer relative h-5 w-5 appearance-none rounded-full transition-all border-2 checked:border-[4px] checked:border-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2 website-cards-text-color",children:e.label})]})}
1,"sort-filter"+s))})]})})})]}),(0,t.jsxs)("div",{className:"flex items-center gap-2 cursor-pointer",onClick:P,children:[(0,t.jsx)(S.Faders,{className:"global-body-color"}),(0,t.jsx)("span",{className:"text-sm font-medium global-body-color",children:"Filter"})]})]})]}),(0,t.jsx)(N.default,{category:Y}),e]})]})}],150814)},466492,e=>{"use strict";var t=e.i(843476),s=e.i(411087),l=e.i(809991),a=e.i(899346),r=e.i(271645),i=e.i(815330),n=e.i(331991),c=e.i(201796),o=e.i(577854),d=e.i(525209),x=e.i(974559),u=e.i(898742),m=e.i(701973);let h=({index:e,style:s,data:l})=>{let a=l?.filteredItems?.[e];return(0,t.jsx)("div",{style:s,className:"mb-2",children:(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:a?.urlSlug||(0,m.urlSlug)(a?.brandName),checked:l.filterData?.brandIds?.includes("all")||l.filterData?.brandIds?.includes(a?.urlSlug||(0,m.urlSlug)(a?.brandName)),onChange:e=>l.handleBrandChange(e,l?.filterData,l?.setSecondaryFilterList,l?.setTempSpecialsValues),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(c.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal",children:a?.name})]},a?.id)},`specials-brand-drawer-${e}`)};e.s(["default",0,({filterName:e,filterOpt:m,secondaryFilterList:p,setSecondaryFilterList:f,handleSubmitFilter:b,filterData:g,setTempSpecialsValues:y})=>{let{isOpen:j,mounted:v,slideIn:N,openDrawer:w,closeDrawer:C}=(0,a.useMobileFilterDrawerTransition)(),[k,S]=(0,r.useState)(""),L=(0,l.default)(k,300),{handleBrandChange:A,handleBrandAllChange:E,handleClearBrand:T}=(0,s.default)(),F=m.filter(e=>e?.name?.toLowerCase().includes(L?.toLowerCase()));return(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("button",{onClick:w,className:`px-3 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${j||p?.brandIds.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),p?.brandIds.length>0?(0,t.jsx)("p",{className:"min-w-5 h-5 py-1 px-1.5 fill-button rounded-full flex items-center justify-center text-xs font-light",children:p?.brandIds?.includes("all")?m?.length:p?.brandIds?.filter(e=>"all"!==e)?.length||0}):j?(0,t.jsx)(n.CaretUp,{fontWeight:"300"}):(0,t.jsx)(i.CaretDown,{fontWeight:"300"})]}),v&&(0,t.jsx)("div",{className:`fixed inset-0 flex items-end justify-center z-[60] transition-opacity duration-500 ${N?"bg-black bg-opacity-50":"bg-black bg-opacity-0"}`,children:(0,t.jsxs)("div",{className:`w-full max-h-[466px] bg-white pt-4 rounded-t-xl flex flex-col items-start justify-between shadow-lg transition-transform duration-500 ease-in-out transform ${N?"translate-y-0":"translate-y-full"}`,children:[(0,t.jsxs)("div",{className:"flex justify-between items-center px-6 w-full border-b pb-4",children:[(0,t.jsx)("h2",{className:"text-lg font-semibold text-center flex-1",children:e}),(0,t.jsx)("button",{onClick:C,className:"text-gray-500 hover:text-black",children:(0,t.jsx)(o.X,{size:24})})]}),(0,t.jsxs)("div",{className:"relative w-full px-6 my-3",children:[(0,t.jsx)("input",{type:"text",value:k,onChange:e=>{S(e.target.value)},placeholder:"Search Brand",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(d.MagnifyingGlass,{className:"absolute top-1/2 right-8 -translate-y-1/2"})]}),(0,t.jsxs)("div",{className:"px-6 w-full pb-2",children:[(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",checked:p?.brandIds?.includes("all"),value:"all",onChange:e=>{E(e,p,f,m,y)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(c.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal",children:"All Brands"})]}),(0,t.jsx)("div",{className:"flex-1",children:(0,t.jsx)(u.default,{disableHeight:!0,children:({width:e})=>(0,t.jsx)(x.FixedSizeList,{className:"sb",height:250,itemCount:F.length,itemSize:27,width:e,itemData:{filteredItems:F,filterData:p,handleBrandChange:A,setSecondaryFilterList:f,setTempSpecialsValues:y},children:h})})})]}),(0,t.jsxs)("div",{className:"flex justify-between px-6 py-4 bg-gray-50 w-full",children:[(0,t.jsx)("button",{disabled:!(p?.brandIds?.length>0),onClick:()=>T(f,g,b,!0,y),className:"text-sm primary-text hover:underline disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{b(),C()},className:"text-xs font-medium fill-button py-[6px] px-3 rounded-full",children:"Show Products"})]})]})})]})}])},715628,e=>{"use strict";var t=e.i(843476),s=e.i(375677),l=e.i(411087),a=e.i(899346),r=e.i(271645),i=e.i(815330),n=e.i(331991),c=e.i(201796),o=e.i(577854),d=e.i(525209);e.s(["default",0,({filterName:e,filterOpt:x,secondaryFilterList:u,setSecondaryFilterList:m,handleSubmitFilter:h,setTempSubCategoryList:p,setTempWeightList:f,setTempBrandList:b,setTempSpecialsValues:g,setNewSubCategoryAndWeightLoader:y,filterData:j})=>{let{isOpen:v,mounted:N,slideIn:w,openDrawer:C,closeDrawer:k}=(0,a.useMobileFilterDrawerTransition)(),[S,L]=(0,r.useState)(""),{handleCategoryChange:A,handleClearCategory:E}=(0,l.default)(),{displayCategoryName:T}=(0,s.default)();return(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("button",{onClick:C,className:`px-3 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${v||u?.categories.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),u?.categories?.length>0?(0,t.jsx)("p",{className:"min-w-5 h-5 py-1 px-1.5 fill-button rounded-full flex items-center justify-center text-xs font-light",children:u?.categories?.includes("ALL CATEGORY")?x?.filter(e=>(e?.categoryName||e)?.toUpperCase()!=="ALL CATEGORY")?.length||0:u?.categories?.filter(e=>"ALL CATEGORY"!==e)?.length}):v?(0,t.jsx)(n.CaretUp,{fontWeight:"300"}):(0,t.jsx)(i.CaretDown,{fontWeight:"300"})]}),N&&(0,t.jsx)("div",{className:`fixed inset-0 flex items-end justify-center z-[60] transition-opacity duration-500 ${w?"bg-black bg-opacity-50":"bg-black bg-opacity-0"}`,children:(0,t.jsxs)("div",{className:`w-full max-h-[466px] bg-white pt-4 rounded-t-xl flex flex-col items-start justify-between shadow-lg transition-transform duration-500 ease-in-out transform ${w?"translate-y-0":"translate-y-full"}`,children:[(0,t.jsxs)("div",{className:"flex justify-between items-center px-6 w-full border-b pb-4",children:[(0,t.jsx)("h2",{className:"text-lg font-semibold text-center flex-1",children:e}),(0,t.jsx)("button",{onClick:k,className:"text-gray-500 hover:text-black",children:(0,t.jsx)(o.X,{size:24})})]}),(0,t.jsxs)("div",{className:"relative w-full px-6 my-3",children:[(0,t.jsx)("input",{type:"text",value:S,onChange:e=>{L(e.target.value)},placeholder:"Search Category",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(d.MagnifyingGlass,{className:"absolute top-1/2 right-8 -translate-y-1/2"})]}),(0,t.jsxs)("div",{className:"overflow-y-auto px-6 w-full pb-2",children:[(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:"ALL CATEGORY",checked:u?.categories.includes("ALL CATEGORY")||x?.length>0&&x.filter(e=>(e?.categoryName||e)?.toUpperCase()!=="ALL CATEGORY").every(e=>u?.categories.includes(e?.categoryName||e)),onChange:e=>A(e,u,m,y,p,f,b,g,x),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(c.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal",children:"All Categories"})]}),x.filter(e=>(e?.categoryName||e)?.toUpperCase()!=="ALL CATEGORY"&&T(e)?.toLowerCase()?.includes(S?.toLowerCase())).map(e=>(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:e?.categoryName||e,checked:u?.categories.includes("ALL CATEGORY")||u?.categories.includes(e?.categoryName||e),onChange:e=>A(e,u,m,y,p,f,b,g,x),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(c.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal",children:T(e)})]},e?.categoryName||e))]}),(0,t.jsxs)("div",{className:"flex justify-between px-6 py-4 bg-gray-50 w-full",children:[(0,t.jsx)("button",{disabled:!(u?.categories?.length>0),onClick:()=>E(j,m,p,f,h,!0,b,g),className:"text-sm primary-text hover:underline disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{h(),k()},className:"text-xs font-medium fill-button py-[6px] px-3 rounded-full",children:"Show Products"})]})]})})]})}])},111942,578546,247132,e=>{"use strict";var t=e.i(843476),s=e.i(411087),l=e.i(899346),a=e.i(701973),r=e.i(271645),i=e.i(815330),n=e.i(331991),c=e.i(201796),o=e.i(577854),d=e.i(525209);e.s(["default",0,({filterName:e,filterOpt:x,secondaryFilterList:u,setSecondaryFilterList:m,handleSubmitFilter:h,filterData:p})=>{let{isOpen:f,mounted:b,slideIn:g,openDrawer:y,closeDrawer:j}=(0,l.useMobileFilterDrawerTransition)(),[v,N]=(0,r.useState)(""),{handleEffcetChange:w,handleClearEffects:C}=(0,s.default)();return(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("button",{onClick:y,className:`px-3 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${f||u?.effects?.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),u?.effects?.length>0?(0,t.jsx)("p",{className:"min-w-5 h-5 py-1 px-1.5 fill-button rounded-full flex items-center justify-center text-xs font-light",children:u?.effects?.length}):f?(0,t.jsx)(n.CaretUp,{fontWeight:"300"}):(0,t.jsx)(i.CaretDown,{fontWeight:"300"})]}),b&&(0,t.jsx)("div",{className:`fixed inset-0 flex items-end justify-center z-[60] transition-opacity duration-500 ${g?"bg-black bg-opacity-50":"bg-black bg-opacity-0"}`,children:(0,t.jsxs)("div",{className:`w-full max-h-[466px] bg-white pt-4 rounded-t-xl flex flex-col items-start justify-between shadow-lg transition-transform duration-500 ease-in-out transform ${g?"translate-y-0":"translate-y-full"}`,children:[(0,t.jsxs)("div",{className:"flex justify-between items-center px-6 w-full border-b pb-4",children:[(0,t.jsx)("h2",{className:"text-lg font-semibold text-center flex-1",children:e}),(0,t.jsx)("button",{onClick:j,className:"text-gray-500 hover:text-black",children:(0,t.jsx)(o.X,{size:24})})]}),(0,t.jsxs)("div",{className:"relative w-full px-6 my-3",children:[(0,t.jsx)("input",{type:"text",value:v,onCh
1ange:e=>{N(e.target.value)},placeholder:"Search Effect",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(d.MagnifyingGlass,{className:"absolute top-1/2 right-8 -translate-y-1/2"})]}),(0,t.jsx)("div",{className:"overflow-y-auto px-6 w-full pb-2",children:x.filter(e=>e?.effects?.toLowerCase().includes(v?.toLowerCase())).map(e=>(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:e?.effects,checked:u?.effects.includes(e?.effects),onChange:e=>{w(e,u,m)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(c.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal",children:(0,a.makeTitleCase)(e?.effects)})]},"effect"+e?._id))}),(0,t.jsxs)("div",{className:"flex justify-between px-6 py-4 bg-gray-50 w-full",children:[(0,t.jsx)("button",{disabled:!(u?.effects?.length>0),onClick:()=>{C(m,p,h,!0)},className:"text-sm primary-text hover:underline disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{h(),j()},className:"text-xs font-medium fill-button py-[6px] px-3 rounded-full",children:"Show Products"})]})]})})]})}],111942);var x=e.i(898742),u=e.i(974559);let m=({index:e,style:s,data:l})=>{let a=l.todaySpecialsValue[e];return(0,t.jsx)("div",{style:s,className:"mb-2",children:(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",checked:l?.filterData?.dailyDealsValue.includes("all")||l?.filterData?.dailyDealsValue.includes(a.urlSlug),value:a.urlSlug,onChange:e=>{l.handleTodaySpecialChange(e,l?.filterData,l.setSecondaryFilterList)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(c.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal truncate",children:a?.name})]},a?.id)},`specials-filter-drawer-${e}`)};e.s(["default",0,({filterName:e,filterOpt:a,secondaryFilterList:h,setSecondaryFilterList:p,handleSubmitFilter:f,filterData:b})=>{let{isOpen:g,mounted:y,slideIn:j,openDrawer:v,closeDrawer:N}=(0,l.useMobileFilterDrawerTransition)(),[w,C]=(0,r.useState)(""),{handleTodaySpecialChange:k,handleClearSpecial:S}=(0,s.default)(),L=a?.filter(e=>e?.name?.toLowerCase().includes(w?.toLowerCase()));return(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("button",{onClick:v,className:`px-3 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${g||h?.dailyDealsValue?.length?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),h?.dailyDealsValue?.length>0?(0,t.jsx)("p",{className:"min-w-5 h-5 py-1 px-1.5 fill-button rounded-full flex items-center justify-center text-xs font-light",children:h?.dailyDealsValue?.includes("all")?a?.length:h?.dailyDealsValue?.filter(e=>"all"!==e)?.length}):g?(0,t.jsx)(n.CaretUp,{fontWeight:"300"}):(0,t.jsx)(i.CaretDown,{fontWeight:"300"})]}),y&&(0,t.jsx)("div",{className:`fixed inset-0 flex items-end justify-center z-[60] transition-opacity duration-500 ${j?"bg-black bg-opacity-50":"bg-black bg-opacity-0"}`,children:(0,t.jsxs)("div",{className:`w-full max-h-[466px] bg-white pt-4 rounded-t-xl flex flex-col items-start justify-between shadow-lg transition-transform duration-500 ease-in-out transform ${j?"translate-y-0":"translate-y-full"}`,children:[(0,t.jsxs)("div",{className:"flex justify-between items-center px-6 w-full border-b pb-4",children:[(0,t.jsx)("h2",{className:"text-lg font-semibold text-center flex-1",children:e}),(0,t.jsx)("button",{onClick:N,className:"text-gray-500 hover:text-black",children:(0,t.jsx)(o.X,{size:24})})]}),(0,t.jsxs)("div",{className:"relative w-full px-6 my-3",children:[(0,t.jsx)("input",{type:"text",value:w,onChange:e=>{C(e.target.value)},placeholder:"Search Special",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(d.MagnifyingGlass,{className:"absolute top-1/2 right-8 -translate-y-1/2"})]}),(0,t.jsxs)("div",{className:"px-6 w-full pb-2",children:[(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",name:"todayspecialAll",checked:h?.dailyDealsValue.includes("all"),value:"all",onChange:e=>{k(e,h,p)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(c.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal",children:"All Specials"})]}),(0,t.jsx)("div",{className:"flex-1",children:(0,t.jsx)(x.default,{disableHeight:!0,children:({width:e})=>L?.length>0?(0,t.jsx)(u.FixedSizeList,{className:"sb",height:250,itemCount:L?.length,itemSize:27,width:e,itemData:{todaySpecialsValue:L,filterData:h,handleTodaySpecialChange:k,setSecondaryFilterList:p},children:m}):(0,t.jsx)("div",{className:"h-[250px] w-full flex items-center justify-center text-gray-700 text-sm",style:{width:e},children:"No specials found"})})})]}),(0,t.jsxs)("div",{className:"flex justify-between px-6 py-4 bg-gray-50 w-full",children:[(0,t.jsx)("button",{disabled:!(h?.dailyDealsValue?.length>0),onClick:()=>S(p,b,f,!0),className:"text-sm primary-text hover:underline disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{f(),N()},className:"text-xs font-medium fill-button py-[6px] px-3 rounded-full",children:"Show Products"})]})]})})]})}],578546);var h=e.i(507127);e.s(["default",0,({filterName:e,setSecondaryFilterList:a,handleSubmitFilter:c,potencyThcValue:d,setPotencyThcValue:x,potencyCbdValue:u,setPotencyCbdValue:m})=>{let{isOpen:p,mounted:f,slideIn:b,openDrawer:g,closeDrawer:y}=(0,l.useMobileFilterDrawerTransition)(),{handlePotencyThcChange:j,handlePotencyThcDrag:v,handlePotencyCbdChange:N,handlePotencyCbdDrag:w,handleClearPotency:C}=(0,s.default)(),[k]=(0,r.useState)(void 0),S=+((d?.[0]??0)!==0||(d?.[1]??100)!==100)+ +((u?.[0]??0)!==0||(u?.[1]??100)!==100);return(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("button",{onClick:g,className:`px-3 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${p||S>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),S>0?(0,t.jsx)("p",{className:"min-w-5 h-5 py-1 px-1.5 fill-button rounded-full flex items-center justify-center text-xs font-light",children:S}):p?(0,t.jsx)(n.CaretUp,{fontWeight:"300"}):(0,t.jsx)(i.CaretDown,{fontWeight:"300"})]}),f&&(0,t.jsx)("div",{className:`fixed inset-0 flex items-end justify-center z-[60] transition-opacity duration-500 ${b?"bg-black bg-opacity-50":"bg-black bg-opacity-0"}`,children:(0,t.jsxs)("div",{className:`w-full max-h-[466px] bg-white pt-4 rounded-t-xl flex flex-col items-start justify-between shadow-lg transition-transform duration-500 ease-in-out transform ${b?"translate-y-0":"translate-y-full"}`,children:[(0,t.jsxs)("div",{className:"flex justify-between items-center px-6 w-full border-b pb-4",children:[(0,t.jsx)("h2",{className:"text-lg font-semibold text-center flex-1",children:e}),(0,t.jsx)("button",{onClick:y,className:"text-gray-500 hover:text-black",children:(0,t.jsx)(o.X,{size:24})})]}),(0,t.jsxs)("div",{className:"overflow-y-auto px-6 w-full pb-2",children:[(0,t.jsxs)("div",{className:"max-h-[200px] overflow-y-auto mt-4 px-4",children:[(0,t.jsxs)("p",{className:"text-base font-medium",children:["THC : ",d?.[0],"% - ",d?.[1],"%"]}),(0,t.jsx)(h.Range,{values:d,step:1,min:0,max:100,rtl:k,onFinalChange:e=>{v(e,a)},onChange:e=>{j(e,x)},renderTrack:({props:e,children:s})=>(0,t.jsx)("div",{onMouseDown:e.onMouseDown,onTouchStart:e.onTouchStart,style:{...e.style,height:"36px",display:"flex",width:"100%"},children:(0,t.jsx)("div",{ref:e.ref,style:{height:"7px",width:"100%",borderRadius:"4px",background:(0,h.getTrackBackgroun
1d)({values:d,colors:["#E5E7EB","#212322","#E5E7EB"],min:0,max:100,rtl:k}),alignSelf:"center"},children:s})}),renderThumb:({props:e,isDragged:t})=>(0,r.createElement)("div",{...e,key:e.key,style:{...e.style,height:"15px",width:"15px",borderRadius:"50%",backgroundColor:"#fff",display:"flex",justifyContent:"center",border:"2px solid #fff",alignItems:"center",boxShadow:"0px 0.5px 3px #111"}})})]}),(0,t.jsxs)("div",{className:"max-h-[200px] overflow-y-auto mt-4 px-4",children:[(0,t.jsxs)("p",{className:"text-base font-medium",children:["CBD : ",u?.[0],"%- ",u?.[1],"%"]}),(0,t.jsx)(h.Range,{values:u,step:1,min:0,max:100,rtl:k,onFinalChange:e=>{w(e,a)},onChange:e=>{N(e,m)},renderTrack:({props:e,children:s})=>(0,t.jsx)("div",{onMouseDown:e.onMouseDown,onTouchStart:e.onTouchStart,style:{...e.style,height:"36px",display:"flex",width:"100%"},children:(0,t.jsx)("div",{ref:e.ref,style:{height:"7px",width:"100%",borderRadius:"4px",background:(0,h.getTrackBackground)({values:u,colors:["#E5E7EB","#212322","#E5E7EB"],min:0,max:100,rtl:k}),alignSelf:"center"},children:s})}),renderThumb:({props:e})=>(0,r.createElement)("div",{...e,key:e.key,style:{...e.style,height:"15px",width:"15px",borderRadius:"50%",backgroundColor:"#fff",display:"flex",justifyContent:"center",border:"2px solid #fff",alignItems:"center",boxShadow:"0px 0.5px 3px #111"}})})]})]}),(0,t.jsxs)("div",{className:"flex justify-between px-6 py-4 bg-gray-50 w-full",children:[(0,t.jsx)("button",{disabled:!(S>0),onClick:()=>{C(a)},className:"text-sm primary-text hover:underline disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{c(),y()},className:"text-xs font-medium fill-button py-[6px] px-3 rounded-full",children:"Show Products"})]})]})})]})}],247132)},29507,e=>{"use strict";var t=e.i(843476),s=e.i(271645),l=e.i(411087),a=e.i(899346),r=e.i(815330),i=e.i(331991),n=e.i(577854),c=e.i(507127),o=e.i(430494);e.s(["default",0,({filterName:e,secondaryFilterList:d,setSecondaryFilterList:x,handleSubmitFilter:u,price:m,setPrice:h})=>{let{isOpen:p,mounted:f,slideIn:b,openDrawer:g,closeDrawer:y}=(0,a.useMobileFilterDrawerTransition)(),[j,v]=(0,s.useState)([]),{handlePriceChange:N,handlePriceDrag:w,handleClearPrice:C}=(0,l.default)(),[k,S]=(0,s.useState)(void 0),L=m?.length&&(0!==m[0]||m[1]!==o.PRICEMAX);return(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("button",{onClick:g,className:`px-3 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${p||j.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),j.length>0?(0,t.jsx)("p",{className:"min-w-5 h-5 py-1 px-1.5 fill-button rounded-full flex items-center justify-center text-xs font-light",children:j.length}):p?(0,t.jsx)(i.CaretUp,{fontWeight:"300"}):(0,t.jsx)(r.CaretDown,{fontWeight:"300"})]}),f&&(0,t.jsx)("div",{className:`fixed inset-0 flex items-end justify-center z-[60] transition-opacity duration-500 ${b?"bg-black bg-opacity-50":"bg-black bg-opacity-0"}`,children:(0,t.jsxs)("div",{className:`w-full max-h-[466px] bg-white pt-4 rounded-t-xl flex flex-col items-start justify-between shadow-lg transition-transform duration-500 ease-in-out transform ${b?"translate-y-0":"translate-y-full"}`,children:[(0,t.jsxs)("div",{className:"flex justify-between items-center px-6 w-full border-b pb-4",children:[(0,t.jsx)("h2",{className:"text-lg font-semibold text-center flex-1",children:e}),(0,t.jsx)("button",{onClick:y,className:"text-gray-500 hover:text-black",children:(0,t.jsx)(n.X,{size:24})})]}),(0,t.jsx)("div",{className:"overflow-y-auto px-6 w-full pb-2",children:(0,t.jsxs)("div",{className:"max-h-[200px] overflow-y-auto mt-4 px-4",children:[(0,t.jsxs)("p",{className:"text-base font-medium",children:["Price : $",m?.[0]," - $",m?.[1]]}),(0,t.jsx)(c.Range,{values:m,step:1,min:0,max:o.PRICEMAX,rtl:k,onFinalChange:e=>{w(e,x)},onChange:e=>{N(e,h)},renderTrack:({props:e,children:s})=>(0,t.jsx)("div",{onMouseDown:e.onMouseDown,onTouchStart:e.onTouchStart,style:{...e.style,height:"36px",display:"flex",width:"100%"},children:(0,t.jsx)("div",{ref:e.ref,style:{height:"7px",width:"100%",borderRadius:"4px",background:(0,c.getTrackBackgroun
1d)({values:m,colors:["#E5E7EB","#212322","#E5E7EB"],min:0,max:o.PRICEMAX,rtl:k}),alignSelf:"center"},children:s})}),renderThumb:({props:e})=>(0,s.createElement)("div",{...e,key:e.key,style:{...e.style,height:"15px",width:"15px",borderRadius:"50%",backgroundColor:"#fff",display:"flex",justifyContent:"center",border:"2px solid #fff",alignItems:"center",boxShadow:"0px 0.5px 3px #111"}})})]})}),(0,t.jsxs)("div",{className:"flex justify-between px-6 py-4 bg-gray-50 w-full",children:[(0,t.jsx)("button",{disabled:!L,onClick:()=>{C(x,d,u,!0)},className:"text-sm primary-text hover:underline disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{u(),y()},className:"text-xs font-medium fill-button py-[6px] px-3 rounded-full",children:"Show Products"})]})]})})]})}])},396565,e=>{"use strict";var t=e.i(843476),s=e.i(411087),l=e.i(701973),a=e.i(271645),r=e.i(815330),i=e.i(331991),n=e.i(201796),c=e.i(577854);e.s(["default",0,({filterName:e,filterOpt:o,secondaryFilterList:d,setSecondaryFilterList:x,handleSubmitFilter:u,filterData:m})=>{let[h,p]=(0,a.useState)(!1),{handleTagChange:f,handleClearProductTag:b}=(0,s.default)();return(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("button",{onClick:()=>p(!0),className:`px-3 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${h||d?.productTag?.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),d?.productTag?.length>0?(0,t.jsx)("p",{className:"bg-teal-800 p-1 text-white rounded-full w-4 h-4 flex items-center justify-center text-xs font-light",children:d?.productTag?.length}):h?(0,t.jsx)(i.CaretUp,{fontWeight:"300"}):(0,t.jsx)(r.CaretDown,{fontWeight:"300"})]}),h&&(0,t.jsx)("div",{className:"fixed inset-0 flex items-end justify-center bg-black bg-opacity-50 z-[60]",children:(0,t.jsxs)("div",{className:`w-full max-h-[466px] bg-white pt-8 rounded-t-xl flex flex-col items-start justify-between shadow-lg transition-transform duration-500 ease-in-out transform ${h?"translate-y-0":"translate-y-full"}`,children:[(0,t.jsxs)("div",{className:"flex justify-between items-center px-6 w-full",children:[(0,t.jsxs)("h2",{className:"text-lg font-semibold text-center flex-1",children:["Filter By ",e]}),(0,t.jsx)("button",{onClick:()=>p(!1),className:"text-gray-500 hover:text-black",children:(0,t.jsx)(c.X,{size:24})})]}),(0,t.jsx)("div",{className:"px-6 py-4",children:e}),(0,t.jsx)("div",{className:"overflow-y-auto px-6 w-full pb-2",children:o?.map((e,s)=>(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:e?.name,checked:d?.productTag.includes(e?.name),onChange:e=>{f(e,d,x)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(n.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal",children:(0,l.makeTitleCase)(e?.name)})]},"effect"+s))}),(0,t.jsxs)("div",{className:"flex justify-between px-6 py-4 bg-gray-50 w-full",children:[(0,t.jsx)("button",{onClick:()=>{b(x,m,u,!0)},className:"text-sm primary-text hover:underline",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{u(),p(!1)},className:"text-xs font-medium fill-button py-[6px] px-3 rounded-full",children:"Show Products"})]})]})})]})}])},944089,e=>{"use strict";var t=e.i(843476),s=e.i(411087),l=e.i(899346),a=e.i(701973),r=e.i(271645),i=e.i(815330),n=e.i(331991),c=e.i(201796),o=e.i(577854),d=e.i(525209);e.s(["default",0,({filterName:e,filterOpt:x,secondaryFilterList:u,setSecondaryFilterList:m,handleSubmitFilter:h,filterData:p})=>{let{isOpen:f,mounted:b,slideIn:g,openDrawer:y,closeDrawer:j}=(0,l.useMobileFilterDrawerTransition)(),[v,N]=(0,r.useState)(""),{handleSubCategoryChange:w,handleClearSubCategory:C}=(0,s.default)();return(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("button",{onClick:y,className:`whitespace-nowrap px-3 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${f||u?.subcategories.filter(e=>"ALL SUBCATEGORY"!==e)?.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),u?.subcategories.filter(e=>"ALL SUBCATEGORY"!==e)?.length>0?(0,t.jsx)("p",{className:"min-w-5 h-5 py-1 px-1.5 fill-button rounded-full flex items-center justify-center text-xs font-light",children:u?.subcategories.filter(e=>"ALL SUBCATEGORY"!==e)?.length}):f?(0,t.jsx)(n.CaretUp,{fontWeight:"300"}):(0,t.jsx)(i.CaretDown,{fontWeight:"300"})]}),b&&(0,t.jsx)("div",{className:`fixed inset-0 flex items-end justify-center z-[60] transition-opacity duration-500 ${g?"bg-black bg-opacity-50":"bg-black bg-opacity-0"}`,children:(0,t.jsxs)("div",{className:`w-full max-h-[466px] bg-white pt-4 rounded-t-xl flex flex-col items-start justify-between shadow-lg transition-transform duration-500 ease-in-out transform ${g?"translate-y-0":"translate-y-full"}`,children:[(0,t.jsxs)("div",{className:"flex justify-between items-center px-6 w-full border-b pb-4",children:[(0,t.jsx)("h2",{className:"text-lg font-semibold text-center flex-1",children:e}),(0,t.jsx)("button",{onClick:j,className:"text-gray-500 hover:text-black",children:(0,t.jsx)(o.X,{size:24})})]}),(0,t.jsxs)("div",{className:"relative w-full px-6 my-3",children:[(0,t.jsx)("input",{type:"text",value:v,onCh
1ange:e=>{N(e.target.value)},placeholder:"Search Subcategory",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(d.MagnifyingGlass,{className:"absolute top-1/2 right-8 -translate-y-1/2"})]}),(0,t.jsxs)("div",{className:"overflow-y-auto px-6 w-full pb-2",children:[(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:"ALL SUBCATEGORY",checked:u?.subcategories.includes("ALL SUBCATEGORY")&&u?.subcategories.length>1||x?.length>0&&x.every(e=>u?.subcategories.includes(e)),onChange:e=>w(e,u,m,x),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(c.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal",children:"All Sub Categories"})]}),x.filter(e=>e?.toLowerCase().includes(v?.toLowerCase())).map(e=>(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:e,checked:u?.subcategories.includes("ALL SUBCATEGORY")||u?.subcategories.includes(e),onChange:e=>{w(e,u,m,x)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(c.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal",children:(0,a.makeTitleCase)(e)})]},e))]}),(0,t.jsxs)("div",{className:"flex justify-between px-6 py-4 bg-gray-50 w-full",children:[(0,t.jsx)("button",{disabled:!(u?.subcategories?.filter(e=>"ALL SUBCATEGORY"!==e)?.length>0),onClick:()=>{C(m,p,h,!0)},className:"text-sm primary-text hover:underline disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{h(u.subcategories.includes("ALL SUBCATEGORY")?{...u,subcategories:x}:void 0),j()},className:"text-xs font-medium fill-button py-[6px] px-3 rounded-full",children:"Show Products"})]})]})})]})}])},739875,e=>{"use strict";var t=e.i(843476),s=e.i(447689),l=e.i(955135);e.s(["default",0,({active:e,setActive:a})=>(0,t.jsxs)("div",{className:"flex items-center rounded-lg border p-1",children:[(0,t.jsx)("button",{type:"button","aria-label":"Grid view",onClick:()=>a(1),className:`p-1 rounded-md transition-all ${1===e?"fill-button shadow-sm":"bg-transparent"}`,children:(0,t.jsx)(s.GridFour,{size:20})}),(0,t.jsx)("button",{type:"button","aria-label":"List view",onClick:()=>a(2),className:`p-1 rounded-md transition-all ${2===e?"fill-button shadow-sm":"bg-transparent"}`,children:(0,t.jsx)(l.ListDashes,{size:20})})]})])},831569,e=>{"use strict";var t=e.i(843476),s=e.i(411087),l=e.i(899346),a=e.i(258288),r=e.i(701973),i=e.i(310160),n=e.i(271645),c=e.i(201796),o=e.i(577854),d=e.i(525209),x=e.i(898742),u=e.i(974559),m=e.i(815330),h=e.i(331991);let p=({index:e,style:s,data:l})=>{let a=l?.filteredItems?.[e];return(0,t.jsx)("div",{style:s,className:"mb-2",children:(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",name:"weight",value:a,checked:l.filterData?.weights?.includes("ALL WEIGHT")||l.filterData?.weights?.includes(a),onChange:e=>l.handleWeightChange(e,l?.filterData,l.setSecondaryFilterList,l.filterOpt),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(c.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal",children:(0,r.makeTitleCase)(a)})]},a)},`specials-weight-drawer-${e}`)};e.s(["default",0,({filterName:e,filterOpt:r,secondaryFilterList:f,setSecondaryFilterList:b,handleSubmitFilter:g,filterData:y})=>{let{isOpen:j,mounted:v,slideIn:N,openDrawer:w,closeDrawer:C}=(0,l.useMobileFilterDrawerTransition)(),{handleWeightChange:k,handleClearWeights:S}=(0,s.default)(),{commonCMSData:L}=(0,a.useGlobalStore)(),A=L?.ediblesWeightDisplayEnabled===!0||!(0,i.isEdiblesCategorySelected)(f?.categories),[E,T]=(0,n.use
1State)(""),F=r.filter(e=>e?.toLowerCase().includes(E?.toLowerCase()));return A?(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("button",{onClick:w,className:`px-3 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${j||f?.weights.filter(e=>"ALL WEIGHT"!==e)?.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsxs)("span",{children:[" ",e]}),f?.weights.filter(e=>"ALL WEIGHT"!==e)?.length>0?(0,t.jsx)("p",{className:"min-w-5 h-5 py-1 px-1.5 fill-button rounded-full flex items-center justify-center text-xs font-light",children:f?.weights.filter(e=>"ALL WEIGHT"!==e)?.length}):j?(0,t.jsx)(h.CaretUp,{fontWeight:"300"}):(0,t.jsx)(m.CaretDown,{fontWeight:"300"})]}),v&&(0,t.jsx)("div",{className:`fixed inset-0 flex items-end justify-center z-[60] transition-opacity duration-500 ${N?"bg-black bg-opacity-50":"bg-black bg-opacity-0"}`,children:(0,t.jsxs)("div",{className:`w-full max-h-[466px] bg-white pt-4 rounded-t-xl flex flex-col items-start justify-between shadow-lg transition-transform duration-500 ease-in-out transform ${N?"translate-y-0":"translate-y-full"}`,children:[(0,t.jsxs)("div",{className:"flex justify-between items-center px-6 w-full border-b pb-4",children:[(0,t.jsx)("h2",{className:"text-lg font-semibold text-center flex-1",children:e}),(0,t.jsx)("button",{onClick:C,className:"text-gray-500 hover:text-black",children:(0,t.jsx)(o.X,{size:24})})]}),(0,t.jsxs)("div",{className:"relative w-full px-6 my-3",children:[(0,t.jsx)("input",{type:"text",value:E,onChange:e=>{T(e.target.value)},placeholder:"Search Weight",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(d.MagnifyingGlass,{className:"absolute top-1/2 right-8 -translate-y-1/2"})]}),(0,t.jsxs)("div",{className:"px-6 w-full pb-2",children:[(0,t.jsxs)("label",{className:"w-max relative flex mb-2 gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:"ALL WEIGHT",checked:f?.weights.includes("ALL WEIGHT")&&f?.weights.length>1||r?.length>0&&r.every(e=>f?.weights.includes(e)),onChange:e=>k(e,f,b,r),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(c.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-sm text-gray-800 font-normal",children:"All Weights"})]}),(0,t.jsx)(x.default,{disableHeight:!0,children:({width:e})=>(0,t.jsx)(u.FixedSizeList,{className:"sb",height:230,itemCount:F.length,itemSize:27,width:e,itemData:{filteredItems:F,filterData:f,handleWeightChange:k,setSecondaryFilterList:b,filterOpt:r},children:p})})]}),(0,t.jsxs)("div",{className:"flex justify-between px-6 py-4 bg-gray-50 w-full",children:[(0,t.jsx)("button",{disabled:!(f?.weights?.filter(e=>"ALL WEIGHT"!==e)?.length>0),onClick:()=>{S(b,y,g,!0)},className:"text-sm primary-text hover:underline disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{g(f.weights.includes("ALL WEIGHT")?{...f,weights:r}:void 0),C()},className:"text-xs font-medium fill-button py-[6px] px-3 rounded-full",children:"Show Products"})]})]})})]}):null}])},381277,e=>{"use strict";var t=e.i(843476),s=e.i(271645),l=e.i(411087),a=e.i(815330),r=e.i(331991),i=e.i(507127),n=e.i(430494);e.s(["default",0,({filterName:e,alignment:c,secondaryFilterList:o,setSecondaryFilterList:d,handleSubmitFilter:x,price:u,setPrice:m})=>
1{let[h,p]=(0,s.useState)(!1),f=(0,s.useRef)(null),{handlePriceChange:b,handlePriceDrag:g,handleClearPrice:y}=(0,l.default)(),j=u?.length&&(0!==u[0]||u[1]!==n.PRICEMAX);return(0,s.useEffect)(()=>{let e=e=>{f.current&&!f.current.contains(e.target)&&p(!1)};return h?document.addEventListener("mousedown",e):document.removeEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[h]),(0,t.jsxs)("div",{className:"relative",ref:f,children:[(0,t.jsxs)("button",{onClick:()=>{p(!h)},className:`px-4 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${h||j?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),j?(0,t.jsx)("p",{className:"fill-button py-1 px-1.5 rounded-full min-w-5 h-5 flex items-center justify-center text-xs font-light",children:"1"}):h?(0,t.jsx)(r.CaretUp,{fontWeight:"300"}):(0,t.jsx)(a.CaretDown,{fontWeight:"300"})]}),h&&(0,t.jsx)("div",{className:`absolute pt-4 z-20  w-[305px] mt-2 bg-gray-50 border shadow-sm rounded-lg ${c}`,children:(0,t.jsxs)("div",{className:"flex flex-col justify-between h-full",children:[(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)("div",{className:"px-4 flex items-center justify-between mb-4",children:(0,t.jsx)("h3",{className:"text-gray-800 text-base font-medium",children:e})}),(0,t.jsxs)("div",{className:"max-h-[320px] overflow-y-auto mt-4 px-4",children:[(0,t.jsxs)("p",{className:"text-base font-medium website-cards-text-color",children:["Price : $",u?.[0]," - $",u?.[1]]}),(0,t.jsx)(i.Range,{values:u,step:1,min:0,max:n.PRICEMAX,onFinalChange:e=>{g(e,d)},onChange:e=>{b(e,m)},renderTrack:({props:e,children:s})=>(0,t.jsx)("div",{onMouseDown:e.onMouseDown,onTouchStart:e.onTouchStart,style:{...e.style,height:"36px",display:"flex",width:"100%"},children:(0,t.jsx)("div",{ref:e.ref,style:{height:"7px",width:"100%",borderRadius:"4px",background:(0,i.getTrackBackground)({values:u,colors:["#E5E7EB","#212322","#E5E7EB"],min:0,max:n.PRICEMAX}),alignSelf:"center"},children:s})}),renderThumb:({props:e})=>(0,s.createElement)("div",{...e,key:e.key,style:{...e.style,height:"15px",width:"15px",borderRadius:"50%",backgroundColor:"#fff",display:"flex",justifyContent:"center",border:"2px solid #fff",alignItems:"center",boxShadow:"0px 0.5px 3px #111"}})})]})]}),(0,t.jsxs)("div",{className:"p-4 flex items-center justify-between border-t border-t-gray-200",children:[(0,t.jsx)("button",{disabled:!j,onClick:()=>{y(d,o,x,!0)},className:"text-sm font-medium primary-text disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{x(),p(!1)},className:"text-sm font-semibold fill-button py-[6px] px-4 rounded-full",children:"Show Products"})]})]})})]})}])},106490,e=>{"use strict";var t=e.i(843476),s=e.i(411087),l=e.i(701973),a=e.i(271645),r=e.i(815330),i=e.i(331991),n=e.i(201796),c=e.i(525209);e.s(["default",0,({filterName:e,filterOpt:o,alignment:d,secondaryFilterList:x,setSecondaryFilterList:u,handleSubmitFilter:m,filterData:h})=>{let[p,f]=(0,a.useState)(!1),[b,g]=(0,a.useState)(""),y=(0,a.useRef)(null),{handleTagChange:j,handleClearProductTag:v}=(0,s.default)();return(0,a.useEffect)(()=>{let e=e=>{y.current&&!y.current.contains(e.target)&&f(!1)};return p?document.addEventListener("mousedown",e):document.removeEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[p]),(0,t.jsxs)("div",{className:"relative",ref:y,children:[(0,t.jsxs)("button",{onClick:()=>{f(!p)},className:`px-4 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${p||x?.productTag?.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),x?.productTag?.length>0?(0,t.jsx)("p",{className:"bg-teal-800 p-1 text-white rounded-full w-4 h-4 flex items-center justify-center text-xs font-light",children:x?.productTag?.length}):p?(0,t.jsx)(i.CaretUp,{fontWeight:"300"}):(0,t.jsx)(r.CaretDown,{fontWeight:"300"})]}),p&&(0,t.jsx)("div",{className:`absolute pt-4 z-20 h-[380px] w-[305px] mt-2 bg-gray-50 border shadow-sm rounded-lg ${d}`,children:(0,t.jsxs)("div",{className:"flex flex-col justify-between h-full",children:[(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)("div",{className:"px-4 flex items-center justify-between mb-4",children:(0,t.jsx)("h3",{className:"text-gray-800 text-base font-medium",children:e})}),(0,t.jsxs)("div",{className:"relative w-full px-4",children:[(0,t.jsx)("input",{type:"text",value:b,onChange:e=>{g(e.target.value)},placeholder:"Search Effect",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(c.MagnifyingGlass,{className:"absolute top-1/2 right-6 -translate-y-1/2"})]}),(0,t.jsx)("div",{className:"max-h-[200px] overflow-y-auto mt-4 px-4",children:o.filter(e=>e?.name?.toLowerCase()?.includes(b?.toLowerCase())).map((e,s)=>(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:e?.name,checked:x?.productTag.includes(e?.name),onChange:e=>{j(e,x,u)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(n.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2 website-cards-text-color",children:(0,l.makeTitleCase)(e?.name)})]})},s))})]}),(0,t.jsxs)("div",{className:"p-4 flex items-center justify-between border-t border-t-gray-200",children:[(0,t.jsx)("button",{onClick:()=>{v(u,h,m,!0)},className:"text-xs font-medium primary-text",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{m(),f(!1)},className:"text-xs font-medium fill-button py-[6px] px-3 rounded-full",children:"Show Products"})]})]})})]})}])},378278,e=>{"use strict";var t=e.i(843476),s=e.i(411087),l=e.i(271645),a=e.i(815330),r=e.i(331991),i=e.i(201796),n=e.i(525209);e.s(["default",0,({filterName:e,filterOpt:c,alignment:o,secondaryFilterList:d,setSecondaryFilterList:x,handleSubmitFilter:u,filterData:m})=>{let[h,p]=(0,l.useState)(!1),[f,b]=(0,l.useState)(""),g=(0,l.useRef)(null),{handleTodaySpecialChange:y,handleClearSpecial:j}=(0,s.default)();return(0,l.useEffect)(()=>{let e=e=>{g.current&&!g.current.contains(e.target)&&p(!1)};return h?document.addEventListener("mousedown",e):document.removeEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[h]),(0,t.jsxs)("div",{className:"relative",ref:g,children:[(0,t.jsxs)("button",{onClick:()=>{p(!h)},className:`px-4 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${h||d?.dailyDealsValue?.length?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),d?.dailyDealsValue.length>0?(0,t.jsx)("p",{className:"fill-button py-1 px-1.5 rounded-full max-w-5 h-5 flex items-center justify-center text-xs font-light",children:d?.dailyDealsValue.includes("all")?c?.length:d?.dailyDealsValue?.filter(e=>"all"!==e)?.length}):h?(0,t.jsx)(r.CaretUp,{fontWeight:"300"}):(0,t.jsx)(a.CaretDown,{fontWeight:"300"})]}),h&&(0,t.jsx)("div",{className:`absolute pt-4 z-20  w-[305px] mt-2 bg-gray-50 border shadow-sm rounded-lg ${o}`,children:(0,t.jsxs)("div",{className:"flex flex-col justify-between h-full",children:[(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)("div",{className:"px-4 flex items-center justify-between mb-4",children:(0,t.jsx)("h3",{className:"text-gray-800 text-base font-medium",children:e})}),(0,t.jsxs)("div",{className:"relative w-full px-4",children:[(0,t.jsx)("input",{type:"text",value:f,onChange:e=>{b(e.target.value)},placeholder:"Search Special",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(n.MagnifyingGlass,{className:"absolute top-1/2 right-6 -translate-y-1/2"})]}),(0,t.jsxs)("div",{className:"max-h-[320px] overflow-y-auto mt-4 px-4",children:[(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",name:"todayspecialAll",checked:d?.dailyDealsValue.includes("all"),value:"all",onChange:e=>{y(e,d,x)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(i.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2 website-cards-text-color",children:"All Specials"})]})}),c.filter(e=>e?.name?.toLowerCase()?.includes(f?.toLowerCase())).map(e=>(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",name:"todayspecial"+e?.urlSlug,checked:d?.dailyDealsValue.includes("all")||d?.dailyDealsValue.includes(e?.urlSlug),value:e.urlSlug,onChange:e=>{y(e,d,x)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(i.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2 website-cards-text-color",children:e?.name})]})},e?.id))]})]}),(0,t.jsxs)("div",{className:"p-4 flex items-center justify-between border-t border-t-gray-200",children:[(0,t.jsx)("button",{disabled:!(d?.dailyDealsValue?.length>0),onClick:()=>j(x,m,u,!0),className:"text-sm font-medium primary-text disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{u(),p(!1)},className:"text-sm font-semibold fill-button py-[6px] px-4 roun
1ded-full",children:"Show Products"})]})]})})]})}])},8445,e=>{"use strict";var t=e.i(843476),s=e.i(64722),l=e.i(763963),a=e.i(271645),r=e.i(447689),i=e.i(815330),n=e.i(331991);e.s(["default",0,({filterName:e,filterOpt:c,alignment:o,active:d,setActive:x,shopFilterV3:u=!1})=>{let[m,h]=(0,a.useState)(!1),[p,f]=(0,a.useState)(""),b=(0,a.useRef)(null),[g,y]=(0,a.useState)(c[0]),j=()=>{h(!m)},v=e=>{let t=e.target.value;"List View"==t?x(2):x(1),y(t),h(!1)};return(0,a.useEffect)(()=>{1==d?y(c[1]):y(c[0])},[d]),(0,a.useEffect)(()=>{let e=e=>{b.current&&!b.current.contains(e.target)&&h(!1)};return m?document.addEventListener("mousedown",e):document.removeEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[m]),(0,t.jsxs)("div",{className:"relative",ref:b,children:[u?(0,t.jsx)(r.GridFour,{onClick:j,className:"text-gray-700 cursor-pointer global-body-color"}):(0,t.jsxs)("button",{onClick:j,className:`px-4 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 text-nowrap ${m?"border border-teal-800 text-teal-800":"border border-gray-200"}`,children:[(0,t.jsxs)("span",{children:[e,": ",g]}),m?(0,t.jsx)(n.CaretUp,{fontWeight:"300"}):(0,t.jsx)(i.CaretDown,{fontWeight:"300"})]}),(0,t.jsx)(s.default,{onClickOutside:()=>h(!1),children:m&&(0,t.jsx)("div",{className:`absolute z-20 max-h-[210px] w-[220px] mt-2 bg-white border shadow-sm rounded-lg ${o}`,children:(0,t.jsx)("div",{className:"flex flex-col justify-between h-full",children:(0,t.jsx)("div",{className:"",children:(0,t.jsx)("div",{className:"max-h-[200px] overflow-y-auto p-4",children:(0,t.jsx)("div",{className:"flex items-start flex-col gap-2",children:c.filter(e=>e?.toLowerCase().includes(p?.toLowerCase())).map(e=>(0,t.jsx)("div",{className:"flex items-start gap-2 py-1",children:(0,t.jsx)(l.default,{name:"filterOption",value:e,checked:g==e,onChange:v,label:e,labelClassName:"text-sm font-normal line-clamp-1 website-cards-text-color"})},e))})})})})})})]})}])},526586,e=>{"use strict";var t=e.i(843476),s=e.i(271645),l=e.i(426676),a=e.i(693012),r=e.i(258288),i=e.i(99779),n=e.i(451163),c=e.i(445650),o=e.i(70446),d=e.i(662625),x=e.i(193437),u=e.i(8445),m=e.i(378278),h=e.i(759604),p=e.i(466492),f=e.i(944089),b=e.i(715628),g=e.i(836133),y=e.i(111942),j=e.i(578546),v=e.i(247132),N=e.i(739875),w=e.i(663362),C=e.i(831569),k=e.i(375677),S=e.i(381277),L=e.i(29507),A=e.i(430494),E=e.i(808340),T=e.i(106490),F=e.i(396565),D=e.i(811134);let R=()=>(0,t.jsx)("div",{className:"relative",children:(0,t.jsx)("div",{className:"px-3 h-6 w-24 py-4 text-sm bg-gray-200 flex items-center gap-1 border rounded-full border-gray-300 animate-pulse"})});var O=e.i(411087),P=e.i(815330),V=e.i(331991),G=e.i(201796),B=e.i(525209);let z=({filterName:e,filterOpt:l,alignment:a,secondaryFilterList:r,setSecondaryFilterList:i,handleSubmitFilter:n,filterData:c})=>{let[o,d]=(0,s.useState)(!1),[x,u]=(0,s.useState)(""),m=(0,s.useRef)(null),{handleStateChange:h,handleClearStates:p}=(0,O.default)();return(0,s.useEffect)(()=>{let e=e=>{m.current&&!m.current.contains(e.target)&&d(!1)};return o?document.addEventListener("mousedown",e):document.removeEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[o]),(0,t.jsxs)("div",{className:"relative",ref:m,children:[(0,t.jsxs)("button",{onClick:()=>{d(!o)},className:`px-4 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${o||r?.states?.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),r?.states?.length>0?(0,t.jsx)("p",{className:"bg-teal-800 p-1 text-white rounded-full w-4 h-4 flex items-center justify-center text-xs font-light",children:r?.states?.length}):o?(0,t.jsx)(V.CaretUp,{fontWeight:"300"}):(0,t.jsx)(P.CaretDown,{fontWeight:"300"})]}),o&&(0,t.jsx)("div",{className:`absolute pt-4 z-20 h-[380px] w-[305px] mt-2 bg-gray-50 border shadow-sm rounded-lg ${a}`,children:(0,t.jsxs)("div",{className:"flex flex-col justify-between h-full",children:[(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)("div",{className:"px-4 flex items-center justify-between mb-4",children:(0,t.jsx)("h3",{className:"text-gray-800 text-base font-medium",children:e})}),(0,t.jsxs)("div",{className:"relative w-full px-4",children:[(0,t.jsx)("input",{type:"text",value:x,onChange:e=>{u(e.target.value)},placeholder:"Search State",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(B.MagnifyingGlass,{className:"absolute top-1/2 right-6 -translate-y-1/2"})]}),(0,t.jsx)("div",{className:"max-h-[200px] overflow-y-auto mt-4 px-4",children:l.filter(e=>e?.name?.toLowerCase()?.includes(x?.toLowerCase())).map(e=>(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:e?.name,checked:r?.states?.includes(e?.name),onChange:e=>{h(e,r,i)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(G.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2 website-cards-text-color",children:e?.name})]})},e?._id))})]}),(0,t.jsxs)("div",{className:"p-4 flex items-center justify-between border-t border-t-gray-200",children:[(0,t.jsx)("button",{onClick:()=>{p(i,c,n,!0)},className:"text-xs font-medium primary-text",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{n(),d(!1)},className:"text-xs font-medium fill-button py-[6px] px-3 rounded-full",children:"Show Products"})]})]})})]})};var W=e.i(940157),$=e.i(618566),I=e.i(310160);e.s(["default",0,function({children:e,active:O,setActive:P,customFilterListData:V,filterData:G,handleClearAll:B,subCategoryList:U,weightList:M,brandList:Y,provider:H,todaySpecialsValue:_,adCategories:X,isBrand:Z=!1,filterResult:q,currentSelectedPage:Q=0,showProductSkeleton:K=!1}){let{specialOfferLoader:J,commonCMSData:ee}=(0,r.useGlobalStore)(),et=ee?.ediblesWeightDisplayEnabled===!0,[es,el]=(0,s.use
1State)(!1),{secondaryFilterList:ea,setSecondaryFilterList:er,selectedSort:ei,setSelectedSort:en,handleSubmitFilter:ec}=(0,k.default)();(0,s.useEffect)(()=>{G?.sort?.label&&en(G?.sort?.label)},[G?.sort]);let[eo,ed]=(0,s.useState)([]),[ex,eu]=(0,s.useState)([]),[em,eh]=(0,s.useState)([]),[ep,ef]=(0,s.useState)([]),[eb,eg]=(0,s.useState)(!1),ey=(0,$.useSearchParams)(),ej=(0,$.usePathname)(),ev=ey?.get("strainTypes")??"",eN=s.default.useRef(!1),ew=s.default.useRef(null),eC=s.default.useCallback(e=>{eN.current=!0,er(e)},[er]),ek=!K&&q?(0,I.getShopProductRangeDisplay)({currentPage:Q,pageCount:q.pageCount??0,productCount:q.productCount??0,pageSize:q.pageSize??A.SHOP_PRODUCTS_PAGE_SIZE_MOBILE}):null;(0,s.useEffect)(()=>{let e=(0,I.parseStrainTypesFromUrl)(ev),t=e.length>0?(0,I.normalizeSelectedFilterOptions)(e,V?.strainType):(0,I.normalizeSelectedFilterOptions)(G?.strainTypes,V?.strainType);ej!==ew.current&&(ew.current=ej,eN.current=!1);let s=G?.categories||[];if(!eN.current){let e=ej?.match(/\/category\/([^?]+)/);if(e){let t=decodeURIComponent(e[1]);if("all-category"===t)s=["ALL CATEGORY"];else{let e=t.split("+").filter(Boolean),l=(V?.category||[]).map(e=>e?.categoryName||e);s=e.map(e=>l.find(t=>t?.toLowerCase()?.replace(/[\s_]+/g,"-")?.replace(/[^a-z0-9-]/g,"")===e||t?.toLowerCase()===e||t?.toLowerCase().replace(/_/g,"-")===e)??e)}}}er(e=>({...e,...G,categories:eN.current?e.categories:s,strainTypes:t}))},[G,ev,V?.strainType,V?.category,ej]),(0,s.useEffect)(()=>{ed([...U])},[U]),(0,s.useEffect)(()=>{eu([...M])},[M]),(0,s.useEffect)(()=>{eh([...Y])},[Y]),(0,s.useEffect)(()=>{ef([..._])},[_]);let[eS,eL]=(0,s.useState)([0,A.PRICEMAX]),[eA,eE]=(0,s.useState)([0,100]),[eT,eF]=(0,s.use
1State)([0,100]);(0,s.useEffect)(()=>{ea?.price&&ea?.price?.length&&eL(ea?.price)},[ea?.price]),(0,s.useEffect)(()=>{ea?.potencyThcValue&&ea?.potencyThcValue?.length&&eE(ea?.potencyThcValue)},[ea?.potencyThcValue]),(0,s.useEffect)(()=>{ea?.potencyCbdValue&&ea?.potencyCbdValue?.length&&eF(ea?.potencyCbdValue)},[ea?.potencyCbdValue]);let eD=s.default.useCallback(()=>{eN.current=!1,er((0,I.getDefaultShopFilterState)()),ed([]),eu([]),eh([...Y||[]]),ef([..._||[]]),eL([0,A.PRICEMAX]),eE([0,100]),eF([0,100]),en("Popular"),B?.()},[Y,_,B,er,en]),eR=(0,E.isProviderShowcase)(H??null),eO=(0,s.useMemo)(()=>{let e;return ea?(e=0+(ea.categories?.includes("ALL CATEGORY")?V?.category?.filter(e=>(e?.categoryName||e)?.toUpperCase()!=="ALL CATEGORY")?.length||0:ea.categories?.length||0)+(ea.brandIds?.includes("all")?em?.length||0:ea.brandIds?.filter(e=>"all"!==e)?.length||0)+(ea.subcategories?.filter(e=>"ALL SUBCATEGORY"!==e)?.length||0)+(ea.weights?.filter(e=>"ALL WEIGHT"!==e)?.length||0)+(ea.strainTypes?.filter(e=>"all"!==e)?.length||0)+(ea.effects?.length||0)+(ea.dailyDealsValue?.includes("all")?ep?.length||0:ea.dailyDealsValue?.filter(e=>"all"!==e)?.length||0)+(ea.productTag?.length||0)+(ea.states?.length||0),ea.price?.length&&(0!==ea.price[0]||ea.price[1]!==A.PRICEMAX)&&e++,(ea.potencyThcValue?.length&&(0!==ea.potencyThcValue[0]||100!==ea.potencyThcValue[1])||ea.potencyCbdValue?.length&&(0!==ea.potencyCbdValue[0]||100!==ea.potencyCbdValue[1]))&&e++,e):0},[ea,em,ep,V]),eP=eO>0;return(0,t.jsx)("div",{className:"md:grid gap-3",id:"category-products",children:(0,t.jsxs)("div",{className:"col-span-3",children:[(0,t.jsx)("div",{className:"md:block hidden sticky top-0 z-20 bg-white min-h-[3rem]",children:(0,t.jsxs)("div",{className:"flex items-center gap-6 py-3 justify-between",children:[(0,t.jsxs)("div",{className:"flex items-center gap-4",children:[(0,t.jsxs)("div",{className:"relative",children:[(0,t.jsx)("div",{className:"h-9 w-9 rounded-full outlined-button-hover flex items-center justify-center cursor-pointer",onClick:()=>el(!0),children:(0,t.jsx)(W.Sliders,{size:16})}),eO>0&&(0,t.jsx)("div",{className:"absolute -top-1 -right-1 fill-button py-1 px-1.5 text-[10px] font-bold rounded-full min-w-5 h-5 flex items-center justify-center",children:eO})]}),(0,t.jsxs)("ul",{className:"flex items-center gap-3",children:[(0,t.jsx)("li",{children:(0,t.jsx)(a.default,{filterName:"Category",filterOpt:V?.category,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:eC,handleSubmitFilter:ec,setTempSubCategoryList:ed,setTempWeightList:eu,setTempBrandList:eh,setTempSpecialsValues:ef,setNewSubCategoryAndWeightLoader:eg,filterData:G})}),eb?(0,t.jsx)("div",{className:"relative",children:(0,t.jsx)("div",{className:"px-3 h-6 w-24 py-4 text-sm bg-gray-200 flex items-center gap-1 border rounded-full border-gray-300 animate-pulse"})}):(0,t.jsx)(t.Fragment,{children:ea?.categories?.length>0&&eo?.length>0?(0,t.jsx)("li",{children:(0,t.jsx)(o.default,{filterName:"Sub Category",filterOpt:eo,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})}):(0,t.jsx)(t.Fragment,{})}),eb?(0,t.jsx)("div",{className:"relative",children:(0,t.jsx)("div",{className:"px-3 h-6 w-24 py-4 text-sm bg-gray-200 flex items-center gap-1 border rounded-full border-gray-300 animate-pulse"})}):(0,t.jsx)(t.Fragment,{children:(et||!(0,I.isEdiblesCategorySelected)(ea?.categories))&&ea?.categories?.length>0&&ex?.length>0?(0,t.jsx)("li",{children:(0,t.jsx)(d.default,{filterName:"Weights",filterOpt:ex,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})}):(0,t.jsx)(t.Fragment,{})}),!eR&&(0,t.jsx)("li",{children:(0,t.jsx)(i.default,{filterName:"Brand",filterOpt:em,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G,setTempSpecialsValues:ef})}),(0,t.jsx)("li",{children:(0,t.jsx)(n.default,{filterName:"Strain",filterOpt:V?.strainType,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})}),(0,t.jsx)("li",{children:(0,t.jsx)(c.default,{filterName:"Effect",filterOpt:V?.effects,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})}),(0,E.isEcommerceOrPortfolioProvider)(H??"")&&(0,t.jsx)("li",{children:(0,t.jsx)(T.default,{filterName:"Tag",filterOpt:V?.productTag,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})}),J?(0,t.jsx)(R,{}):(0,t.jsx)("li",{children:(0,t.jsx)(m.default,{filterName:"Special",filterOpt:ep,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})}),(0,t.jsx)("li",{children:(0,t.jsx)(S.default,{filterName:"Price",alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,price:eS,setPrice:eL})}),!(0,E.isEcommerceOrPortfolioProvider)(H??"")&&(0,t.jsx)("li",{children:(0,t.jsx)(x.default,{filterName:"Potency",alignment:"",setSecondaryFilterList:er,handleSubmitFilter:ec,potencyThcValue:eA,setPotencyThcValue:eE,potencyCbdValue:eT,setPotencyCbdValue:eF})}),eR&&V?.states?.length>0&&(0,t.jsx)("li",{children:(0,t.jsx)(z,{filterName:"States",filterOpt:V?.states,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})})]})]}),(0,t.jsxs)("ul",{className:"flex items-center gap-4",children:[(0,t.jsx)("li",{children:(0,t.jsx)(h.default,{filterName:"Sort By",filterOpt:["Popular","Brand","Recently Added","THC Low-High","THC High-Low","Price Low-High","Price High-Low","Name A-Z","Name Z-A"],alignment:"right-0",selectedSort:ei,setSelectedSort:en})}),!Z&&(0,t.jsx)("li",{children:(0,t.jsx)(u.default,{filterName:"View",filterOpt:["List View","Grid View"],alignment:"right-0",active:O,setActive:P})})]})]})}),(0,t.jsxs)("div",{className:"md:hidden block ",children:[(0,t.jsxs)("div",{className:"flex items-center gap-2 py-3",children:[(0,t.jsxs)("div",{className:"relative",children:[(0,t.jsx)("div",{className:"h-9 w-9 rounded-full fill-button-hover flex items-center justify-center cursor-pointer",onClick:()=>el(!0),children:(0,t.jsx)(W.Sliders,{size:16})}),eO>0&&(0,t.jsx)("div",{className:"absolute -top-1 -right-1 min-w-5 h-5 py-1 px-1.5 fill-button text-[10px] font-bold rounded-full flex items-center justify-center",children:eO})]}),(0,t.jsx)("div",{className:"w-full overflow-x-auto no-scrollbar",children:(0,t.jsxs)("ul",{className:"w-full max-w-[1000px] flex items-center gap-3",children:[(0,t.jsx)("li",{children:(0,t.jsx)(b.default,{filterName:"Category",filterOpt:V?.category,al
1ignment:"",secondaryFilterList:ea,setSecondaryFilterList:eC,handleSubmitFilter:ec,tempSubCategoryList:eo,setTempSubCategoryList:ed,tempWeightList:ex,setTempWeightList:eu,setTempBrandList:eh,setTempSpecialsValues:ef,setNewSubCategoryAndWeightLoader:eg,filterData:G})}),eb?(0,t.jsx)("div",{className:"relative",children:(0,t.jsx)("div",{className:"px-3 h-6 w-24 py-4 text-sm bg-gray-200 flex items-center gap-1 border rounded-full border-gray-300 animate-pulse"})}):(0,t.jsx)(t.Fragment,{children:ea?.categories?.length>0&&eo?.length>0?(0,t.jsx)("li",{children:(0,t.jsx)(f.default,{filterName:"Sub Category",filterOpt:eo,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})}):(0,t.jsx)(t.Fragment,{})}),eb?(0,t.jsx)("div",{className:"relative",children:(0,t.jsx)("div",{className:"px-3 h-6 w-24 py-4 text-sm bg-gray-200 flex items-center gap-1 border rounded-full border-gray-300 animate-pulse"})}):(0,t.jsx)(t.Fragment,{children:(et||!(0,I.isEdiblesCategorySelected)(ea?.categories))&&ea?.categories?.length>0&&ex?.length>0?(0,t.jsx)("li",{children:(0,t.jsx)(C.default,{filterName:"Weight",filterOpt:ex,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})}):(0,t.jsx)(t.Fragment,{})}),!eR&&(0,t.jsx)("li",{children:(0,t.jsx)(p.default,{filterName:"Brand",filterOpt:em,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G,setTempSpecialsValues:ef})}),!(0,E.isEcommerceOrPortfolioProvider)(H??"")&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("li",{children:(0,t.jsx)(g.default,{filterName:"Strain",filterOpt:V?.strainType,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})}),(0,t.jsx)("li",{children:(0,t.jsx)(y.default,{filterName:"Effect",filterOpt:V?.effects,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})})]}),(0,E.isEcommerceOrPortfolioProvider)(H??"")&&(0,t.jsx)("li",{children:(0,t.jsx)(F.default,{filterName:"Tag",filterOpt:V?.productTag,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})}),(0,t.jsx)("li",{children:(0,t.jsx)(j.default,{filterName:"Special",filterOpt:ep,alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,filterData:G})}),(0,t.jsx)("li",{children:(0,t.jsx)(L.default,{filterName:"Price",alignment:"",secondaryFilterList:ea,setSecondaryFilterList:er,handleSubmitFilter:ec,price:eS,setPrice:eL})}),(0,t.jsx)("li",{children:(0,t.jsx)(v.default,{filterName:"Potency",setSecondaryFilterList:er,handleSubmitFilter:ec,potencyThcValue:eA,setPotencyThcValue:eE,potencyCbdValue:eT,setPotencyCbdValue:eF})})]})})]}),(0,t.jsxs)("div",{className:"flex items-center justify-between w-full py-2",children:[(0,t.jsx)(w.default,{filterName:"Sort By",filterOpt:["Popular","Brand","Recently Added","THC Low-High","THC High-Low","Price Low-High","Price High-Low","Name A-Z","Name Z-A"],alignment:"left-0",selectedSort:ei,setSelectedSort:en}),!Z&&(0,t.jsx)(N.default,{filterName:"View",filterOpt:["List View","Grid View"],alignment:"right-0",active:O,setActive:P})]})]}),(0,t.jsx)(D.default,{category:X}),(0,t.jsx)(l.default,{isOpen:es,onClose:()=>el(!1),filterData:G,secondaryFilterList:ea,setSecondaryFilterList:eC,categoryList:V?.category,tempSubCategoryList:eo,setTempSubCategoryList:ed,tempWeightList:ex,setTempWeightList:eu,handleSubmitFilter:ec,brandList:em,setTempBrandList:eh,setTempSpecialsValues:ef,todaySpecialList:ep,strainList:V?.strainType,effectList:V?.effects,productTag:V?.productTag,newSubCategoryAndWeightLoader:eb,setNewSubCategoryAndWeightLoader:eg,handleClearAll:eD,price:eS,setPrice:eL,potencyThcValue:eA,setPotencyThcValue:eE,potencyCbdValue:eT,setPotencyCbdValue:eF,provider:H}),(0,t.jsxs)("div",{className:"flex items-center justify-between py-2",children:[ek&&(0,t.jsxs)("p",{className:"text-sm global-body-color whitespace-nowrap",children:[ek.total.toLocaleString()," products"]}),eP&&(0,t.jsx)("div",{className:"flex items-center gap-2 cursor-pointer",onClick:eD,children:(0,t.jsx)("p",{className:"text-xs font-medium text-gray-400 hover:text-gray-700 hover:text-[var(--global-body-color)]",children:"Clear All"})})]}),e]})})}],526586)},426676,693012,99779,445650,70446,662625,193437,e=>{"use strict";var t=e.i(843476),s=e.i(271645),l=e.i(64722),a=e.i(411087),r=e.i(701973),i=e.i(507127),n=e.i(430494),c=e.i(375677);let o=()=>(0,t.jsx)("div",{className:"w-full text-left border-b border-gray-300 md:px-8 px-3 md:py-5 py-3",children:(0,t.jsx)("div",{className:"px-3 h-6 w py-12 text-sm bg-gray-200 flex items-center gap-1 border-gray-300 animate-pulse"})});var d=e.i(258288),x=e.i(808340),u=e.i(310160),m=e.i(577854),h=e.i(201796),p=e.i(590961),f=e.i(525209),b=e.i(268817),g=e.i(815330),y=e.i(331991);e.s(["default",0,({isOpen:e,onClose:j,filterData:v,secondaryFilterList:N,setSecondaryFilterList:w,categoryList:C,tempSubCategoryList:k,setTempSubCategoryList:S,tempWeightList:L,setTempWeightList:A,handleSubmitFilter:E,brandList:T,todaySpecialList:F,strainList:D,effectList:R,productTag:O,newSubCategoryAndWeightLoader:P,setNewSubCategoryAndWeightLoader:V,handleClearAll:G,price:B,setPrice:z,potencyThcValue:W,setPotencyThcValue:$,potencyCbdValue:I,setPotencyCbdValue:U,provider:M,setTempBrandList:Y,setTempSpecialsValues:H})=>
1{let[_,X]=(0,s.useState)(!1),[Z,q]=(0,s.useState)(!1),[Q,K]=(0,s.useState)(""),{handleTodaySpecialChange:J,handleEffcetChange:ee,handleTagChange:et,handleClearEffects:es,handleClearProductTag:el,handleStrainChange:ea,handleClearStrainType:er,handlePotencyThcChange:ei,handlePotencyThcDrag:en,handlePotencyCbdChange:ec,handlePotencyCbdDrag:eo,handleClearPotency:ed,handleCategoryChange:ex,handleClearCategory:eu,handleSubCategoryChange:em,handleClearSubCategory:eh,handleWeightChange:ep,handleClearWeights:ef,handleBrandChange:eb,handleBrandAllChange:eg,handlePriceChange:ey,handlePriceDrag:ej,handleClearPrice:ev}=(0,a.default)(),{specialOfferLoader:eN,commonCMSData:ew}=(0,d.useGlobalStore)(),eC=ew?.ediblesWeightDisplayEnabled===!0,{displayCategoryName:ek}=(0,c.default)(),[eS,eL]=(0,s.useState)(),eA=e=>{eL(t=>t===e?null:e)};(0,s.useEffect)(()=>{e?document.body.style.overflow="hidden":document.body.style.overflow="auto"},[e]),(0,s.useEffect)(()=>{(Z||_)&&K("")},[Z,_]);let eE=F.filter(e=>e?.name?.toLowerCase().includes(Q?.toLowerCase())),eT=(N?.categories?.includes("ALL CATEGORY")?C?.filter(e=>(e?.categoryName||e)?.toUpperCase()!=="ALL CATEGORY")?.length||0:N?.categories?.filter(e=>"ALL CATEGORY"!==e)?.length||0)+(N?.subcategories?.length||0)+(N?.weights?.length||0)+(N?.brandIds?.includes("all")?T?.length||0:N?.brandIds?.filter(e=>"all"!==e)?.length||0)+(N?.strainTypes?.filter(e=>"all"!==e)?.length||0)+(N?.effects?.length||0)+(N?.dailyDealsValue?.includes("all")?F?.length||0:N?.dailyDealsValue?.filter(e=>"all"!==e)?.length||0)+(N?.productTag?.length||0)+(N?.states?.length||0)+(N?.price?.length&&(N?.price[0]!==0||N?.price[1]!==n.PRICEMAX)?1:0)+(N?.potencyThcValue?.length&&(N?.potencyThcValue[0]!==0||N?.potencyThcValue[1]!==100)||N?.potencyCbdValue?.length&&(N?.potencyCbdValue[0]!==0||N?.potencyCbdValue[1]!==100)?1:0),eF=N?.categories?.includes("ALL CATEGORY")?C?.filter(e=>(e?.categoryName||e)?.toUpperCase()!=="ALL CATEGORY")?.length||0:N?.categories?.filter(e=>"ALL CATEGORY"!==e)?.length||0,eD=N?.categories?.length>0,eR=N?.subcategories?.length>0,eO=N?.weights?.length>0,eP=N?.strainTypes?.length>0,eV=N?.effects?.length>0,eG=B?.length&&(0!==B[0]||B[1]!==n.PRICEMAX),eB=W?.length&&(0!==W[0]||100!==W[1])||I?.length&&(0!==I[0]||100!==I[1]),ez=e=>`max-md:hidden text-xs font-normal text-gray-800 transition-all ${e?"cursor-pointer hover:text-red-600":"opacity-50 cursor-not-allowed"}`,eW=(0,x.isProviderShowcase)(M);return e?(0,t.jsx)(l.default,{onClickOutside:j,children:(0,t.jsx)("div",{className:"fixed inset-0 flex items-center justify-center bg-black bg-opacity-50 z-50",children:(0,t.jsxs)("div",{className:"bg-white w-full md:max-w-[730px] max-h-[90vh] max-w-full overflow-hidden rounded-lg relative shadow-md mx-3",children:[(0,t.jsxs)("div",{className:`md:px-8 px-3 md:py-5 py-3 border-b border-gray-300 top-0 sticky ${_||Z?"hidden":"flex justify-between items-center"}`,children:[(0,t.jsx)("h2",{className:"md:text-base text-sm text-gray-900 font-semibold",children:_?"Brands":"All Filter"}),(0,t.jsx)("button",{onClick:j,className:"text-gray-400 hover:text-gray-600",children:(0,t.jsx)(m.X,{size:20})})]}),(0,t.jsx)("div",{className:"",children:_||Z?(0,t.jsxs)("div",{children:[(0,t.jsxs)("div",{className:"flex items-center md:px-8 px-3 md:py-5 py-3 border-b border-gray-300 top-0 sticky",children:[(0,t.jsx)("button",{onClick:()=>{X(!1),q(!1)},className:"mr-2 text-gray-600 hover:text-gray-800",children:(0,t.jsx)(p.CaretLeft,{className:"md:text-base text-sm"})}),!eW&&(0,t.jsxs)("div",{className:"flex-1",children:[_&&(0,t.jsx)("h3",{className:"md:text-base text-sm font-semibold block text-center",children:"Brands"}),Z&&(0,t.jsx)("h3",{className:"md:text-base text-sm font-semibold block text-center",children:"Today's Specials"})]})]}),(0,t.jsxs)("div",{className:"md:px-8 px-3 mb-6 md:h-[630px] h-[430px]",children:[(0,t.jsxs)("div",{className:"w-full md:py-6 py-3 bg-white sticky top-0 z-40",children:[(0,t.jsx)("input",{type:"text",value:Q,onChange:e=>K(e.target.value),placeholder:`Search ${Z?"Specials":"Brands"}`,className:"w-full md:text-base text-sm text-[#6B7280] font-normal md:py-[14px] py-2 px-4 border rounded-full md:pl-11 pl-9 focus:outline-none focus:border-teal-800"}),(0,t.jsx)(f.MagnifyingGlass,{className:"absolute top-1/2 left-4 -translate-y-1/2 text-[#6B7280] max-md:text-sm"})]}),Z&&(0,t.jsxs)("div",{className:"block",children:[(0,t.jsx)("div",{className:"flex items-center md:mb-6 mb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",name:"todayspecialAll",checked:N?.dailyDealsValue.includes("all"),value:"all",onChange:e=>{J(e,N,w)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{size:12})}),(0,t.jsx)("span",{className:"line-clamp-1 md:text-sm text-xs",children:N?.dailyDealsValue.includes("all")?"Unselect All":"All"})]})}),(0,t.jsx)("div",{className:"h-[calc(48vh-20px)] overflow-y-auto sb",children:eE.map(e=>(0,t.jsx)("div",{className:"flex items-center md:mb-6 mb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",name:"todayspecial"+e?.urlSlug,checked:N?.dailyDealsValue.includes("all")||N?.dailyDealsValue.includes(e?.urlSlug),value:e.urlSlug,onChange:e=>{J(e,N,w)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{size:12})}),(0,t.jsx)("span",{className:"line-clamp-1 md:text-sm text-xs",children:e?.name})]})},e?.id||e?.urlSlug))})]}),_&&(0,t.jsxs)("div",{className:"block",children:[(0,t.jsx)("div",{className:"flex items-center md:mb-6 mb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",name:"brandAll",checked:N?.brandIds?.includes("all"),value:"all",onChange:e=>{eg(e,N,w,T,H)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{size:12})}),(0,t.jsx)("span",{className:"line-clamp-1 md:text-sm text-xs",children:N?.brandIds?.includes("all")?"Unselect All":"All"})]})}),(0,t.jsx)("div",{className:"h-[calc(48vh-20px)] overflow-y-auto sb",children:T.filter(e=>e?.name?.toLowerCase()?.includes(Q?.toLowerCase())).map(e=>(0,t.jsx)("div",{className:"flex items-center md:mb-6 mb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex gap-2 items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:e?.urlSlug||(0,r.urlSlug)(e?.brandName),checked:N?.brandIds?.includes("all")||N?.brandIds?.includes(e?.urlSlug||(0,r.urlSlug)(e?.brandName)),onChange:e=>eb(e,N,w,H),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{size:12})}),(0,t.jsx)("span",{className:"line-clamp-1 md:text-sm text-xs",children:e?.name})]})},e?.id))})]})]})]}):(0,t.jsxs)("div",{className:"h-[64vh] overflow-y-scroll",children:[eN?(0,t.jsx)(o,{}):(0,t.jsx)("div",{children:(0,t.jsxs)("button",{onClick:()=>q(!0),className:"w-full md:text-base text-sm text-gray-900 font-semibold text-left border-b border-gray-300 md:px-8 px-3 md:py-5 py-3 flex items-center justify-between",children:["Today's Specials",(0,t.jsx)(b.CaretRight,{className:"md:text-base text-sm"})]})}),!eW&&(0,t.jsx)("div",{children:(0,t.jsxs)("button",{onClick:()=>X(!0),className:"w-full md:text-base text-sm text-gray-900 font-semibold text-left border-b border-gray-300  md:px-8 px-3 md:py-5 py-3 flex items-center justify-between",children:["Brands",(0,t.jsx)(b.CaretRight,{className:"md:text-base text-sm"})]})}),(0,t.jsxs)("ul",{children:[(0,t.jsx)("li",{children:(0,t.jsxs)("div",{className:"w-full text-left border-b border-gray-300 md:px-8 px-3 md:py-5 py-3",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsx)("p",{className:"md:text-base text-sm text-gray-900 font-semibold",children:"Category"}),(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("small",{onClick:()=>{eD&&eu(v,w,S,A,E,!1,Y,H)},className:ez(eD),children:`Clear (${eF})`}),(0,t.jsx)("div",{className:"cursor-pointer text-xs md:hidden block",onClick:()=>eA("strains"),children:eS?(0,t.jsx)(y.CaretUp,{}):(0,t.jsx)(g.CaretDown,{})})]})]}),(0,t.jsx)("ul",{className:"flex items-center gap-2 md:gap-3 flex-wrap md:mt-4 mt-3",children:C.map(e=>{let s=(e?.categoryName||e)?.toUpperCase()==="ALL CATEGORY",l=s?C.filter(e=>(e?.categoryName||e)?.toUpperCase()!=="ALL CATEGORY"):[],a=s?N?.categories.includes("ALL CATEGORY")||l.length>0&&l.every(e=>N?.categories.includes(e?.categoryName||e)):N?.categories.includes("ALL CATEGORY")||N?.categories.includes(e?.categoryName||e);return(0,t.jsx)("li",{value:e?.categoryName||e,onClick:()=>ex(e?.categoryName||e,N,w,V,S,A,Y,H,C),className:`max-md:text-sm max-md:font-medium md:w-fit text-center border md:py-2 py-1 px-3 md:px-5 rounded-full cursor-pointer transition-all ${a?"fill-button":"border-gray-200 outlined-button-hover"}`,children:(0,t.jsxs)("div",{className:"flex items-center justify-center gap-2",children:[a&&(0,t.jsx)(h.Check,{weight:"bold",className:"pointer-events-none"}),(0,t.jsx)("p",{className:"text-sm font-medium pointer-events-none",children:ek(e)})]})},e?.categoryName||e)})})]})}),P?(0,t.jsx)(o,{}):(0,t.jsx)(t.Fragment,{children:N?.categories?.length>0&&k?.length>0?(0,t.jsx)("li",{children:(0,t.jsxs)("div",{className:"w-full text-left border-b border-gray-300 md:px-8 px-3 md:py-5 py-3",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsx)("p",{className:"md:text-base text-sm text-gray-900 font-semibold",children:"Sub Category"}),(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("small",{onClick:()=>{eR&&eh(w,v,E,!1)},className:ez(eR),children:`Clear (${N?.subcategories?.length||0})`}),(0,t.jsx)("div",{className:"cursor-pointer text-xs md:hidden block",onClick:()=>eA("strains"),children:eS?(0,t.jsx)(g.CaretDown,{}):(0,t.jsx)(y.CaretUp,{})})]})]}),(0,t.jsxs)("ul",{className:"flex items-center gap-2 md:gap-3 flex-wrap md:mt-4 mt-3",children:[(0,t.jsx)("li",{value:"ALL SUBCATEGORY",onClick:()=>em({target:{value:"ALL SUBCATEGORY"}},N,w,k),className:`max-md:text-sm max-md:font-medium md:w-fit text-center border md:py-2 py-1 px-3 md:px-5 rounded-full cursor-pointer transition-all ${N?.subcategories.includes("ALL SUBCATEGORY")||k?.length>0&&k.every(e=>N?.subcategories.includes(e))?"fill-button":"border-gray-200 outlined-button-hover"}`,children:(0,t.jsxs)("div",{className:"flex items-center justify-center gap-2",children:[(N?.subcategories.includes("ALL SUBCATEGORY")||k?.length>0&&k.every(e=>N?.subcategories.includes(e)))&&(0,t.jsx)(h.Check,{weight:"bold",className:"pointer-events-none"}),(0,t.jsx)("p",{className:"text-sm font-medium pointer-events-none",children:"All Sub Categories"})]})}),k.map(e=>(0,t.jsx)("li",{value:e,onClick:()=>em(e,N,w,k),className:`max-md:text-sm max-md:font-medium md:w-fit text-center border md:py-2 py-1 px-3 md:px-5 rounded-full cursor-pointer transition-all ${N?.subcategories.includes(e)?"fill-button":"border-gray-200 outlined-button-hover"}`,children:(0,t.jsxs)("div",{className:"flex items-center justify-center gap-2",children:[N?.subcategories.includes(e)&&(0,t.jsx)(h.Check,{weight:"bold",className:"pointer-events-none"}),(0,t.jsx)("p",{className:"text-sm font-medium pointer-events-none",children:(0,r.makeTitleCase)(e)})]})},e))]})]})}):(0,t.jsx)(t.Fragment,{})}),P?(0,t.jsx)(o,{}):(0,t.jsx)(t.Fragment,{children:(eC||!(0,u.isEdiblesCategorySelected)(N?.categories))&&N?.categories?.length>0&&L?.length>0?(0,t.jsx)("li",{children:(0,t.jsxs)("div",{className:"w-full text-left border-b border-gray-300 md:px-8 px-3 md:py-5 py-3",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsx)("p",{className:"md:text-base text-sm text-gray-900 font-semibold",children:"Weight"}),(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("small",{onClick:()=>{eO&&ef(w,v,E,!1)},className:ez(eO),children:`Clear (${N?.weights?.length||0})`}),(0,t.jsx)("div",{className:"cursor-pointer text-xs md:hidden block",onClick:()=>eA("strains"),children:eS?(0,t.jsx)(g.CaretDown,{}):(0,t.jsx)(y.CaretUp,{})})]})]}),(0,t.jsx)("ul",{className:"flex items-center gap-2 md:gap-3 flex-wrap md:mt-4 mt-3",children:L.map(e=>(0,t.jsx)("li",{value:e,onClick:()=>ep(e,N,w),className:`max-md:text-sm max-md:font-medium md:w-fit text-center border md:py-2 py-1 px-3 md:px-5 rounded-full cursor-pointer transition-all ${N?.weights.includes(e)?"fill-button":"border-gray-200 outlined-button-hover"}`,children:(0,t.jsxs)("div",{className:"flex items-center justify-center gap-2",children:[N?.weights.includes(e)&&(0,t.jsx)(h.Check,{weight:"bold",className:"pointer-events-none"}),(0,t.jsx)("p",{className:"text-sm font-medium pointer-events-none",children:(0,r.makeTitleCase)(e)})]})},e))})]})}):(0,t.jsx)(t.Fragment,{})}),!(0,x.isEcommerceOrPortfolioProvider)(M)&&(0,t.jsx)("li",{children:(0,t.jsxs)("div",{className:"w-full text-left border-b border-gray-300 md:px-8 px-3 md:py-5 py-3",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsx)("p",{className:"md:text-base text-sm text-gray-900 font-semibold",children:"Strain Types"}),(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("small",{onClick:()=>{eP&&er(w,v,E,!1)},className:ez(eP),children:`Clear (${N?.strainTypes?.filter(e=>"all"!==e)?.length||0})`}),(0,t.jsx)("div",{className:"cursor-pointer text-xs md:hidden block",onClick:()=>eA("strains"),children:eS?(0,t.jsx)(g.CaretDown,{}):(0,t.jsx)(y.CaretUp,{})})]})]}),(0,t.jsx)("ul",{className:"flex items-center gap-2 md:gap-3 flex-wrap md:mt-4 mt-3",children:D.map(e=>(0,t.jsx)("li",{value:e,onClick:()=>ea(e,N,w),className:`max-md:text-sm max-md:font-medium md:w-fit text-center border md:py-2 py-1 px-3 md:px-5 rounded-full cursor-pointer transition-all ${N?.strainTypes.includes(e)?"fill-button":"border-gray-200 outlined-button-hover"}`,children:(0,t.jsxs)("div",{className:"flex items-center justify-center gap-2",children:[N?.strainTypes.includes(e)&&(0,t.jsx)(h.Check,{weight:"bold",className:"pointer-events-none"}),(0,t.jsx)("p",{className:"text-sm font-medium pointer-events-none",children:(0,r.makeTitleCase)(e)})]})},e))})]})}),(0,t.jsx)("li",{children:(0,t.jsxs)("div",{className:"w-full  text-left border-b border-gray-300 md:px-8 px-3 md:py-5 py-3",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between md:mb-4 mb-3",children:[(0,t.jsx)("p",{className:"md:text-base text-sm text-gray-900 font-semibold",children:"Price"}),(0,t.jsx)("small",{onClick:()=>{eG&&ev(w,N,E,!1)},className:ez(!!eG),children:eG?"Clear (1)":"Clear"})]}),(0,t.jsx)("div",{className:"flex items-center gap-6",children:(0,t.jsx)("div",{className:"w-full",children:(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("p",{className:"text-sm font-medium mb-2 global-body-color",children:["Price : $",B?.[0]," - $",B?.[1]]}),(0,t.jsx)(i.Range,{values:B,step:1,min:0,max:n.PRICEMAX,onFinalChange:e=>{ej(e,w)},onChange:e=>{ey(e,z)},renderTrack:({props:e,children:s})=>(0,t.jsx)("div",{onMouseDown:e.onMouseDown,onTouchStart:e.onTouchStart,style:{...e.style,height:"36px",display:"flex",width:"100%"},children:(0,t.jsx)("div",{ref:e.ref,style:{height:"7px",width:"100%",borderRadius:"4px",background:(0,i.getTrackBackgroun
1d)({values:B,colors:["#E5E7EB","#212322","#E5E7EB"],min:0,max:n.PRICEMAX}),alignSelf:"center"},children:s})}),renderThumb:({props:e})=>(0,s.createElement)("div",{...e,key:e.key,style:{...e.style,height:"15px",width:"15px",borderRadius:"50%",backgroundColor:"#fff",display:"flex",justifyContent:"center",border:"2px solid #fff",alignItems:"center",boxShadow:"0px 0.5px 3px #111"}})})]})})})]})}),!(0,x.isEcommerceOrPortfolioProvider)(M)&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("li",{children:(0,t.jsxs)("div",{className:"w-full  text-left border-b border-gray-300 md:px-8 px-3 md:py-5 py-3",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between md:mb-4 mb-3",children:[(0,t.jsx)("p",{className:"md:text-base text-sm text-gray-900 font-semibold",children:"Potency"}),(0,t.jsx)("small",{onClick:()=>{eB&&ed(w)},className:ez(!!eB),children:eB?"Clear (1)":"Clear"})]}),(0,t.jsxs)("div",{className:"flex items-center gap-6",children:[(0,t.jsx)("div",{className:"w-1/2",children:(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("p",{className:"text-sm font-medium mb-2 global-body-color",children:["THC : ",W[0],"% -"," ",W[1],"%"]}),(0,t.jsx)(i.Range,{values:W,step:1,min:0,max:100,onFinalChange:e=>{en(e,w)},onChange:e=>{ei(e,$)},renderTrack:({props:e,children:s})=>(0,t.jsx)("div",{onMouseDown:e.onMouseDown,onTouchStart:e.onTouchStart,style:{...e.style,height:"36px",display:"flex",width:"100%"},children:(0,t.jsx)("div",{ref:e.ref,style:{height:"7px",width:"100%",borderRadius:"4px",background:(0,i.getTrackBackground)({values:W,colors:["#E5E7EB","#212322","#E5E7EB"],min:0,max:100}),alignSelf:"center"},children:s})}),renderThumb:({props:e})=>(0,s.createElement)("div",{...e,key:e.key,style:{...e.style,height:"15px",width:"15px",borderRadius:"50%",backgroundColor:"#fff",display:"flex",justifyContent:"center",border:"2px solid #fff",alignItems:"center",boxShadow:"0px 0.5px 3px #111"}})})]})}),(0,t.jsx)("div",{className:"w-1/2",children:(0,t.jsxs)("div",{className:"",children:[(0,t.jsxs)("p",{className:"text-sm font-medium mb-2 global-body-color",children:["CBD : ",I[0],"%-"," ",I[1],"%"]}),(0,t.jsx)(i.Range,{values:I,step:1,min:0,max:100,onFinalChange:e=>{eo(e,w)},onChange:e=>{ec(e,U)},renderTrack:({props:e,children:s})=>(0,t.jsx)("div",{onMouseDown:e.onMouseDown,onTouchStart:e.onTouchStart,style:{...e.style,height:"36px",display:"flex",width:"100%"},children:(0,t.jsx)("div",{ref:e.ref,style:{height:"7px",width:"100%",borderRadius:"4px",background:(0,i.getTrackBackground)({values:I,colors:["#E5E7EB","#212322","#E5E7EB"],min:0,max:100}),alignSelf:"center"},children:s})}),renderThumb:({props:e})=>(0,s.createElement)("div",{...e,key:e.key,style:{...e.style,height:"15px",width:"15px",borderRadius:"50%",backgroundColor:"#fff",display:"flex",justifyContent:"center",border:"2px solid #fff",alignItems:"center",boxShadow:"0px 0.5px 3px #111"}})})]})})]})]})}),(0,t.jsx)("li",{children:(0,t.jsxs)("div",{className:"w-full text-left border-b border-gray-300 md:px-8 px-3 md:py-5 py-3",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsx)("p",{className:"md:text-base text-sm text-gray-900 font-semibold",children:"Effects"}),(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("small",{onClick:()=>{eV&&es(w,v,E,!0)},className:ez(eV),children:`Clear (${N?.effects?.length||0})`}),(0,t.jsx)("div",{className:"cursor-pointer text-xs md:hidden block",onClick:()=>eA("effects"),children:eS?(0,t.jsx)(g.CaretDown,{}):(0,t.jsx)(y.CaretUp,{})})]})]}),(0,t.jsx)("ul",{className:"flex items-center gap-2 md:gap-3 flex-wrap md:mt-4 mt-3",children:R.map(e=>(0,t.jsx)("li",{value:e?.effects,onClick:()=>ee(e?.effects,N,w),className:`max-md:text-sm max-md:font-medium md:w-fit text-center border md:py-2 py-1 px-3 md:px-5 rounded-full cursor-pointer transition-all ${N?.effects.includes(e?.effects)?"fill-button":"border-gray-200 outlined-button-hover"}`,children:(0,t.jsxs)("div",{className:"flex items-center justify-center gap-2",children:[N?.effects.includes(e?.effects)&&(0,t.jsx)(h.Check,{weight:"bold",className:"pointer-events-none"}),(0,t.jsx)("p",{className:"text-sm font-medium pointer-events-none",children:(0,r.makeTitleCase)(e?.effects)})]})},e?.id))})]})})]}),(0,x.isEcommerceOrPortfolioProvider)(M)&&(0,t.jsx)(t.Fragment,{children:(0,t.jsx)("li",{children:(0,t.jsxs)("div",{className:"w-full text-left border-b border-gray-300 md:px-8 px-3 md:py-5 py-3",children:[(0,t.jsxs)("div",{className:"flex items-center justify-between",children:[(0,t.jsx)("p",{className:"md:text-base text-sm text-gray-900 font-semibold",children:"Tags"}),(0,t.jsxs)("div",{className:"flex items-center gap-3",children:[(0,t.jsx)("small",{onClick:()=>{el(w,v,E,!0)},className:"max-md:hidden cursor-pointer text-xs font-normal text-gray-800 hover:text-red-600 transition-all",children:`Clear (${N?.productTag?.length||0})`}),(0,t.jsx)("div",{className:"cursor-pointer text-xs md:hidden block",onClick:()=>eA("effects"),children:eS?(0,t.jsx)(g.CaretDown,{}):(0,t.jsx)(y.CaretUp,{})})]})]}),(0,t.jsx)("ul",{className:"flex items-center gap-2 md:gap-3 flex-wrap md:mt-4 mt-3",children:O?.map((e,s)=>(0,t.jsx)("li",{value:e?.name,onClick:()=>et(e?.name,N,w),className:`max-md:text-sm max-md:font-medium md:w-fit text-center border md:py-2 py-1 px-3 md:px-5 rounded-full cursor-pointer transition-all ${N?.productTag?.includes(e?.name)?"fill-button":"border-gray-200 outlined-button-hover"}`,children:(0,t.jsx)("p",{className:"text-sm font-medium",children:(0,r.makeTitleCase)(e?.name)})},s))})]})})})]})]})}),(0,t.jsxs)("div",{className:"sticky bottom-0 flex justify-between items-center bg-gray-50 md:px-8 px-3 md:py-5 py-3 shadow-lg",children:[(0,t.jsx)("p",{onClick:()=>{0!==eT&&(G(),j())},className:`max-md:text-sm primary-text ${eT>0?"cursor-pointer":"opacity-50 cursor-not-allowed"}`,children:`Clear Filter${eT>0?` (${eT})`:""}`}),(0,t.jsx)("button",{onClick:()=>{E(),j()},className:"max-md:text-sm fill-button md:py-3 py-2 md:px-20 px-6 rounded-full ",children:"Show Products"})]})]})})}):null}],426676),e.s(["default",0,({filterName:e,filterOpt:l,alignment:r,secondaryFilterList:i,setSecondaryFilterList:n,handleSubmitFilter:o,setTempSubCategoryList:d,setTempWeightList:x,setTempBrandList:u,setTempSpecialsValues:m,setNewSubCategoryAndWeightLoader:p,filterData:b})=>
1{let[j,v]=(0,s.useState)(!1),[N,w]=(0,s.useState)(""),C=(0,s.useRef)(null),{handleCategoryChange:k,handleClearCategory:S}=(0,a.default)(),{displayCategoryName:L}=(0,c.default)();return(0,s.useEffect)(()=>{let e=e=>{C.current&&!C.current.contains(e.target)&&v(!1)};return j?document.addEventListener("mousedown",e):document.removeEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[j]),(0,t.jsxs)("div",{className:"relative",ref:C,children:[(0,t.jsxs)("button",{onClick:()=>{v(!j)},className:`px-4 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${j||i?.categories?.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),i?.categories?.length>0?(0,t.jsx)("p",{className:"fill-button py-1 px-1.5 rounded-full min-w-5 h-5 flex items-center justify-center text-xs font-light",children:i?.categories?.includes("ALL CATEGORY")?l?.filter(e=>(e?.categoryName||e)?.toUpperCase()!=="ALL CATEGORY")?.length||0:i?.categories?.filter(e=>"ALL CATEGORY"!==e)?.length}):j?(0,t.jsx)(y.CaretUp,{fontWeight:"300"}):(0,t.jsx)(g.CaretDown,{fontWeight:"300"})]}),j&&(0,t.jsx)("div",{className:`absolute pt-4 z-20 w-[305px] mt-2 bg-gray-50 border shadow-sm rounded-lg ${r}`,children:(0,t.jsxs)("div",{className:"flex flex-col justify-between h-full",children:[(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)("div",{className:"px-4 flex items-center justify-between mb-4",children:(0,t.jsx)("h3",{className:"text-gray-800 text-base font-medium",children:e})}),(0,t.jsxs)("div",{className:"relative w-full px-4",children:[(0,t.jsx)("input",{type:"text",value:N,onChange:e=>{w(e.target.value)},placeholder:"Search Category",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(f.MagnifyingGlass,{className:"absolute top-1/2 right-6 -translate-y-1/2"})]}),(0,t.jsxs)("div",{className:"max-h-[320px] overflow-y-auto mt-4 px-4",children:[(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:"ALL CATEGORY",checked:i?.categories.includes("ALL CATEGORY")||l?.length>0&&l.filter(e=>(e?.categoryName||e)?.toUpperCase()!=="ALL CATEGORY").every(e=>i?.categories.includes(e?.categoryName||e)),onChange:e=>k(e,i,n,p,d,x,u,m,l),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2 website-cards-text-color",children:"All Categories"})]})}),l.filter(e=>(e?.categoryName||e)?.toUpperCase()!=="ALL CATEGORY"&&L(e)?.toLowerCase().includes(N?.toLowerCase())).map(e=>(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:e?.categoryName||e,checked:i?.categories.includes("ALL CATEGORY")||i?.categories.includes(e?.categoryName||e),onChange:e=>k(e,i,n,p,d,x,u,m,l),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2 website-cards-text-color",children:L(e)})]})},e?.categoryName))]})]}),(0,t.jsxs)("div",{className:"p-4 flex items-center justify-between border-t border-t-gray-200",children:[(0,t.jsx)("button",{disabled:!(i?.categories?.length>0),onClick:()=>S(b,n,d,x,o,!0,u,m),className:"text-sm font-medium primary-text disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{o(),v(!1)},className:"text-sm font-semibold fill-button py-[6px] px-4 roun
1ded-full",children:"Show Products"})]})]})})]})}],693012);var j=e.i(809991);e.s(["default",0,({filterName:e,filterOpt:l,alignment:i,secondaryFilterList:n,setSecondaryFilterList:c,handleSubmitFilter:o,filterData:d,setTempSpecialsValues:x})=>{let[u,m]=(0,s.useState)(!1),[p,b]=(0,s.useState)(""),v=(0,j.default)(p,300),N=(0,s.useRef)(null),{handleBrandChange:w,handleBrandAllChange:C,handleClearBrand:k}=(0,a.default)();return(0,s.useEffect)(()=>{let e=e=>{N.current&&!N.current.contains(e.target)&&m(!1)};return u?document.addEventListener("mousedown",e):document.removeEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[u]),(0,t.jsxs)("div",{className:"relative",ref:N,children:[(0,t.jsxs)("button",{onClick:()=>{m(!u)},className:`px-4 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${u||n?.brandIds.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),n?.brandIds.length>0?(0,t.jsx)("p",{className:"fill-button py-1 px-1.5 rounded-full min-w-5 h-5 flex items-center justify-center text-xs font-light",children:n?.brandIds?.includes("all")?l?.length:n?.brandIds?.filter(e=>"all"!==e)?.length||0}):u?(0,t.jsx)(y.CaretUp,{fontWeight:"300"}):(0,t.jsx)(g.CaretDown,{fontWeight:"300"})]}),u&&(0,t.jsx)("div",{className:`absolute pt-4 z-20  w-[305px] mt-2 bg-gray-50 border shadow-sm rounded-lg ${i}`,children:(0,t.jsxs)("div",{className:"flex flex-col justify-between h-full",children:[(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)("div",{className:"px-4 flex items-center justify-between mb-4",children:(0,t.jsx)("h3",{className:"text-gray-800 text-base font-medium",children:e})}),(0,t.jsxs)("div",{className:"relative w-full px-4",children:[(0,t.jsx)("input",{type:"text",value:p,onChange:e=>{b(e.target.value)},placeholder:"Search Brand",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(f.MagnifyingGlass,{className:"absolute top-1/2 right-6 -translate-y-1/2"})]}),(0,t.jsxs)("div",{className:"max-h-[320px] overflow-y-auto mt-4 px-4",children:[(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",checked:n?.brandIds?.includes("all"),value:"all",onChange:e=>C(e,n,c,l,x),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2 website-cards-text-color",children:"All Brands"})]})}),l.filter(e=>e?.name?.toLowerCase().includes(v?.toLowerCase())).map(e=>(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:e?.urlSlug||(0,r.urlSlug)(e?.brandName),checked:n?.brandIds?.includes("all")||n?.brandIds?.includes(e?.urlSlug||(0,r.urlSlug)(e?.brandName)),onChange:e=>w(e,n,c,x),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2 website-cards-text-color",children:e?.name})]})},e?.id))]})]}),(0,t.jsxs)("div",{className:"p-4 flex items-center justify-between border-t border-t-gray-200",children:[(0,t.jsx)("button",{disabled:!(n?.brandIds?.length>0),onClick:()=>k(c,d,o,!0,x),className:"text-sm font-medium primary-text disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{o(),m(!1)},className:"text-sm font-semibold fill-button py-[6px] px-4 roun
1ded-full",children:"Show Products"})]})]})})]})}],99779),e.s(["default",0,({filterName:e,filterOpt:l,alignment:i,secondaryFilterList:n,setSecondaryFilterList:c,handleSubmitFilter:o,filterData:d})=>{let[x,u]=(0,s.useState)(!1),[m,p]=(0,s.useState)(""),b=(0,s.useRef)(null),{handleEffcetChange:j,handleClearEffects:v}=(0,a.default)();return(0,s.useEffect)(()=>{let e=e=>{b.current&&!b.current.contains(e.target)&&u(!1)};return x?document.addEventListener("mousedown",e):document.removeEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[x]),(0,t.jsxs)("div",{className:"relative",ref:b,children:[(0,t.jsxs)("button",{onClick:()=>{u(!x)},className:`px-4 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${x||n?.effects?.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),n?.effects?.length>0?(0,t.jsx)("p",{className:"fill-button py-1 px-1.5 rounded-full min-w-5 h-5 flex items-center justify-center text-xs font-light",children:n?.effects?.length}):x?(0,t.jsx)(y.CaretUp,{fontWeight:"300"}):(0,t.jsx)(g.CaretDown,{fontWeight:"300"})]}),x&&(0,t.jsx)("div",{className:`absolute pt-4 z-20  w-[305px] mt-2 bg-gray-50 border shadow-sm rounded-lg ${i}`,children:(0,t.jsxs)("div",{className:"flex flex-col justify-between h-full",children:[(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)("div",{className:"px-4 flex items-center justify-between mb-4",children:(0,t.jsx)("h3",{className:"text-gray-800 text-base font-medium",children:e})}),(0,t.jsxs)("div",{className:"relative w-full px-4",children:[(0,t.jsx)("input",{type:"text",value:m,onChange:e=>{p(e.target.value)},placeholder:"Search Effect",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(f.MagnifyingGlass,{className:"absolute top-1/2 right-6 -translate-y-1/2"})]}),(0,t.jsx)("div",{className:"max-h-[320px] overflow-y-auto mt-4 px-4",children:l.filter(e=>e?.effects?.toLowerCase()?.includes(m?.toLowerCase())).map(e=>(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:e?.effects,checked:n?.effects.includes(e?.effects),onChange:e=>{j(e,n,c)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2 website-cards-text-color",children:(0,r.makeTitleCase)(e?.effects)})]})},e?._id))})]}),(0,t.jsxs)("div",{className:"p-4 flex items-center justify-between border-t border-t-gray-200",children:[(0,t.jsx)("button",{disabled:!(n?.effects?.length>0),onClick:()=>{v(c,d,o,!0)},className:"text-sm font-medium primary-text disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{o(),u(!1)},className:"text-sm font-semibold fill-button py-[6px] px-4 rounded-full",children:"Show Products"})]})]})})]})}],445650),e.s(["default",0,({filterName:e,filterOpt:l,alignment:i,secondaryFilterList:n,setSecondaryFilterList:c,handleSubmitFilter:o,filterData:d})=>{let[x,u]=(0,s.useState)(!1),[m,p]=(0,s.useState)(""),b=(0,s.useRef)(null),{handleSubCategoryChange:j,handleClearSubCategory:v}=(0,a.default)();return(0,s.useEffect)(()=>{let e=e=>{b.current&&!b.current.contains(e.target)&&u(!1)};return x?document.addEventListener("mousedown",e):document.removeEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[x]),(0,t.jsxs)("div",{className:"relative",ref:b,children:[(0,t.jsxs)("button",{onClick:()=>{u(!x)},className:`px-4 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 text-nowrap ${x||n?.subcategories?.filter(e=>"ALL SUBCATEGORY"!==e)?.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),n?.subcategories?.filter(e=>"ALL SUBCATEGORY"!==e)?.length>0?(0,t.jsx)("p",{className:"fill-button py-1 px-1.5 rounded-full min-w-5 h-5 flex items-center justify-center text-xs font-light",children:n?.subcategories?.filter(e=>"ALL SUBCATEGORY"!==e)?.length}):x?(0,t.jsx)(y.CaretUp,{fontWeight:"300"}):(0,t.jsx)(g.CaretDown,{fontWeight:"300"})]}),x&&(0,t.jsx)("div",{className:`absolute pt-4 z-20  w-[305px] mt-2 bg-gray-50 border shadow-sm rounded-lg ${i}`,children:(0,t.jsxs)("div",{className:"flex flex-col justify-between h-full",children:[(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)("div",{className:"px-4 flex items-center justify-between mb-4",children:(0,t.jsx)("h3",{className:"text-gray-800 text-base font-medium",children:e})}),(0,t.jsxs)("div",{className:"relative w-full px-4",children:[(0,t.jsx)("input",{type:"text",value:m,onChange:e=>{p(e.target.value)},placeholder:"Search Subcategory",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(f.MagnifyingGlass,{className:"absolute top-1/2 right-6 -translate-y-1/2"})]}),(0,t.jsxs)("div",{className:"max-h-[320px] overflow-y-auto mt-4 px-4",children:[(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:"ALL SUBCATEGORY",checked:n?.subcategories.includes("ALL SUBCATEGORY")&&n?.subcategories.length>1||l?.length>0&&l.every(e=>n?.subcategories.includes(e)),onChange:e=>j(e,n,c,l),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2 website-cards-text-color",children:"All Sub Categories"})]})}),l.filter(e=>e?.toLowerCase().includes(m?.toLowerCase())).map(e=>(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:e,checked:n?.subcategories.includes("ALL SUBCATEGORY")||n?.subcategories.includes(e),onChange:e=>{j(e,n,c,l)},className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2",children:(0,r.makeTitleCase)(e)})]})},e))]})]}),(0,t.jsxs)("div",{className:"p-4 flex items-center justify-between border-t border-t-gray-200",children:[(0,t.jsx)("button",{disabled:!(n?.subcategories?.filter(e=>"ALL SUBCATEGORY"!==e)?.length>0),onClick:()=>{v(c,d,o,!0)},className:"text-sm font-medium primary-text disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{o(n.subcategories.includes("ALL SUBCATEGORY")?{...n,subcategories:l}:void 0),u(!1)},className:"text-sm font-semibold fill-button py-[6px] px-4 roun
1ded-full",children:"Show Products"})]})]})})]})}],70446),e.s(["default",0,({filterName:e,filterOpt:l,alignment:i,secondaryFilterList:n,setSecondaryFilterList:c,handleSubmitFilter:o,filterData:x})=>{let[m,p]=(0,s.useState)(!1),[b,j]=(0,s.useState)(""),v=(0,s.useRef)(null),{handleWeightChange:N,handleClearWeights:w}=(0,a.default)(),{commonCMSData:C}=(0,d.useGlobalStore)(),k=C?.ediblesWeightDisplayEnabled===!0||!(0,u.isEdiblesCategorySelected)(n?.categories);return((0,s.useEffect)(()=>{let e=e=>{v.current&&!v.current.contains(e.target)&&p(!1)};return m?document.addEventListener("mousedown",e):document.removeEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[m]),k)?(0,t.jsxs)("div",{className:"relative",ref:v,children:[(0,t.jsxs)("button",{onClick:()=>{p(!m)},className:`px-4 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${m||n?.weights?.filter(e=>"ALL WEIGHT"!==e)?.length>0?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),n?.weights?.filter(e=>"ALL WEIGHT"!==e)?.length>0?(0,t.jsx)("p",{className:"fill-button py-1 px-1.5 rounded-full min-w-5 h-5 flex items-center justify-center text-xs font-light",children:n?.weights?.filter(e=>"ALL WEIGHT"!==e)?.length}):m?(0,t.jsx)(y.CaretUp,{fontWeight:"300"}):(0,t.jsx)(g.CaretDown,{fontWeight:"300"})]}),m&&(0,t.jsx)("div",{className:`absolute pt-4 z-20  w-[305px] mt-2 bg-gray-50 border shadow-sm rounded-lg ${i}`,children:(0,t.jsxs)("div",{className:"flex flex-col justify-between h-full",children:[(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)("div",{className:"px-4 flex items-center justify-between mb-4",children:(0,t.jsx)("h3",{className:"text-gray-800 text-base font-medium",children:e})}),(0,t.jsxs)("div",{className:"relative w-full px-4",children:[(0,t.jsx)("input",{type:"text",value:b,onChange:e=>{j(e.target.value)},placeholder:"Search Weight",className:"w-full px-5 py-2 pr-8 text-sm text-gray-500 font-normal border border-gray-300 rounded-full focus:outline-none focus:ring-1 focus:ring-teal-800"}),(0,t.jsx)(f.MagnifyingGlass,{className:"absolute top-1/2 right-6 -translate-y-1/2"})]}),(0,t.jsxs)("div",{className:"max-h-[320px] overflow-y-auto mt-4 px-4",children:[(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",value:"ALL WEIGHT",checked:n?.weights.includes("ALL WEIGHT")&&n?.weights.length>1||l?.length>0&&l.every(e=>n?.weights.includes(e)),onChange:e=>N(e,n,c,l),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2 website-cards-text-color",children:"All Weights"})]})}),l.filter(e=>e?.toLowerCase().includes(b?.toLowerCase())).map(e=>(0,t.jsx)("div",{className:"flex gap-2 items-center pb-4",children:(0,t.jsxs)("label",{className:"w-max relative flex items-center cursor-pointer",children:[(0,t.jsx)("input",{type:"checkbox",name:"weight",value:e,checked:n?.weights.includes("ALL WEIGHT")||n?.weights.includes(e),onChange:e=>N(e,n,c,l),className:"peer relative h-5 w-5 appearance-none rounded transition-all border-2 checked:border-[#34A203] checked:bg-[#34A203] cursor-pointer"}),(0,t.jsx)("span",{className:"absolute left-1 text-white transition-opacity opacity-0 peer-checked:opacity-100",children:(0,t.jsx)(h.Check,{fontSize:"12px"})}),(0,t.jsx)("span",{className:"text-xs text-primary_text font-medium ml-2",children:(0,r.makeTitleCase)(e)})]})},e))]})]}),(0,t.jsxs)("div",{className:"p-4 flex items-center justify-between border-t border-t-gray-200",children:[(0,t.jsx)("button",{disabled:!(n?.weights?.filter(e=>"ALL WEIGHT"!==e)?.length>0),onClick:()=>{w(c,x,o,!0)},className:"text-sm font-medium primary-text disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{o(n.weights.includes("ALL WEIGHT")?{...n,weights:l}:void 0),p(!1)},className:"text-sm font-semibold fill-button py-[6px] px-4 roun
1ded-full",children:"Show Products"})]})]})})]}):null}],662625),e.s(["default",0,({filterName:e,alignment:l,setSecondaryFilterList:r,handleSubmitFilter:n,potencyThcValue:c,setPotencyThcValue:o,potencyCbdValue:d,setPotencyCbdValue:x})=>{let[u,m]=(0,s.useState)(!1),h=(0,s.useRef)(null),{handlePotencyThcChange:p,handlePotencyThcDrag:f,handlePotencyCbdChange:b,handlePotencyCbdDrag:j,handleClearPotency:v}=(0,a.default)(),N=c?.length&&(0!==c[0]||100!==c[1])||d?.length&&(0!==d[0]||100!==d[1]);return(0,s.useEffect)(()=>{let e=e=>{h.current&&!h.current.contains(e.target)&&m(!1)};return u?document.addEventListener("mousedown",e):document.removeEventListener("mousedown",e),()=>{document.removeEventListener("mousedown",e)}},[u]),(0,t.jsxs)("div",{className:"relative",ref:h,children:[(0,t.jsxs)("button",{onClick:()=>{m(!u)},className:`px-4 py-2 text-sm font-medium outlined-button-hover rounded-full flex items-center gap-1 ${u||N?"border border-teal-800 ":"border border-gray-200"}`,children:[(0,t.jsx)("span",{children:e}),N?(0,t.jsx)("p",{className:"fill-button py-1 px-1.5 rounded-full min-w-5 h-5 flex items-center justify-center text-xs font-light",children:"1"}):u?(0,t.jsx)(y.CaretUp,{fontWeight:"300"}):(0,t.jsx)(g.CaretDown,{fontWeight:"300"})]}),u&&(0,t.jsx)("div",{className:`absolute pt-4 z-20  w-[305px] mt-2 bg-gray-50 border shadow-sm rounded-lg ${l}`,children:(0,t.jsxs)("div",{className:"flex flex-col justify-between h-full",children:[(0,t.jsxs)("div",{className:"",children:[(0,t.jsx)("div",{className:"px-4 flex items-center justify-between mb-4",children:(0,t.jsx)("h3",{className:"text-gray-800 text-base font-medium",children:e})}),(0,t.jsxs)("div",{className:"max-h-[320px] overflow-y-auto mt-4 px-4",children:[(0,t.jsxs)("p",{className:"text-base font-medium website-cards-text-color",children:["THC : ",c?.[0],"% - ",c?.[1],"%"]}),(0,t.jsx)(i.Range,{values:c,step:1,min:0,max:100,onFinalChange:e=>{f(e,r)},onChange:e=>{p(e,o)},renderTrack:({props:e,children:s})=>(0,t.jsx)("div",{onMouseDown:e.onMouseDown,onTouchStart:e.onTouchStart,style:{...e.style,height:"36px",display:"flex",width:"100%"},children:(0,t.jsx)("div",{ref:e.ref,style:{height:"7px",width:"100%",borderRadius:"4px",background:(0,i.getTrackBackground)({values:c,colors:["#E5E7EB","#212322","#E5E7EB"],min:0,max:100}),alignSelf:"center"},children:s})}),renderThumb:({props:e})=>(0,s.createElement)("div",{...e,key:e.key,style:{...e.style,height:"15px",width:"15px",borderRadius:"50%",backgroundColor:"#fff",display:"flex",justifyContent:"center",border:"2px solid #fff",alignItems:"center",boxShadow:"0px 0.5px 3px #111"}})})]}),(0,t.jsxs)("div",{className:"max-h-[200px] overflow-y-auto mt-4 px-4",children:[(0,t.jsxs)("p",{className:"text-base font-medium website-cards-text-color",children:["CBD : ",d?.[0],"%- ",d?.[1],"%"]}),(0,t.jsx)(i.Range,{values:d,step:1,min:0,max:100,onFinalChange:e=>{j(e,r)},onChange:e=>{b(e,x)},renderTrack:({props:e,children:s})=>(0,t.jsx)("div",{onMouseDown:e.onMouseDown,onTouchStart:e.onTouchStart,style:{...e.style,height:"36px",display:"flex",width:"100%"},children:(0,t.jsx)("div",{ref:e.ref,style:{height:"7px",width:"100%",borderRadius:"4px",background:(0,i.getTrackBackground)({values:d,colors:["#E5E7EB","#212322","#E5E7EB"],min:0,max:100}),alignSelf:"center"},children:s})}),renderThumb:({props:e})=>(0,s.createElement)("div",{...e,key:e.key,style:{...e.style,height:"15px",width:"15px",borderRadius:"50%",backgroundColor:"#fff",display:"flex",justifyContent:"center",border:"2px solid #fff",alignItems:"center",boxShadow:"0px 0.5px 3px #111"}})})]})]}),(0,t.jsxs)("div",{className:"p-4 flex items-center justify-between border-t border-t-gray-200",children:[(0,t.jsx)("button",{disabled:!N,onClick:()=>{v(r)},className:"text-sm font-medium primary-text disabled:opacity-50 disabled:cursor-not-allowed",children:"Clear Filter"}),(0,t.jsx)("button",{onClick:()=>{n(),m(!1)},className:"text-sm font-semibold fill-button py-[6px] px-4 rounded-full",children:"Show Products"})]})]})})]})}],193437)},318587,e=>{"use strict";var t=e.i(843476),s=e.i(271645),l=e.i(585965),a=e.i(512057),r=e.i(258288),i=e.i(701973),n=e.i(507127),c=e.i(852617),o=e.i(898742),d=e.i(974559),x=e.i(390950),u=e.i(230097),m=e.i(310160),h=e.i(231785),p=e.i(809991),f=e.i(430494),b=e.i(808340),g=e.i(375677),y=e.i(201796),j=e.i(525209);e.s(["default",0,({customFilterListData:e,filterData:v,setQueryValues:N,handleClearAll:w,subCategoryList:C,weightList:k,brandList:S,provider:L,todaysSpecialsValue:A,isBottomDrawer:E=!1,deferSubmit:T=!1,unifiedScroll:F=!1})=>{let{customFilterDataLoader:D,specialOfferLoader:R,brandLoader:O,subCategoryAndWeightLoader:P,commonCMSData:V}=(0,r.useGlobalStore)(),{handleStrainQuery:G,handleEffectsQuery:B,handleTagsQuery:z,handleTodaySpecialsQuery:W,handlePotencyThcDrag:$,handlePotencyThcChange:I,handlePotencyCbdChange:U,handlePotencyCbdDrag:M,handleWeightQuery:Y,handleSubCategoryQuery:H,handleCategoryQuery:_,brandFilterValue:X,handleBrandFilterValue:Z,handleBrandQuery:q,handlePriceDrag:Q,handlePriceChange:K,handleStatesQuery:J}=(0,h.default)(S,!T),{displayCategoryName:ee}
1=(0,g.default)(),[et,es]=(0,s.useState)([]),el=(0,p.default)(X,300);(0,s.useEffect)(()=>{if(!S?.length)return void es([]);if(!el)return void es([...S]);let e=el.toUpperCase();es(S.filter(t=>t?.name?.toUpperCase().includes(e)))},[S,el]);let[ea,er]=(0,s.useState)([0,300]),[ei,en]=(0,s.useState)([0,100]),[ec,eo]=(0,s.useState)([0,100]);(0,s.useEffect)(()=>{v?.price&&v?.price?.length&&er(v?.price)},[v?.price]),(0,s.useEffect)(()=>{v?.potencyThcValue&&v?.potencyThcValue?.length&&en(v?.potencyThcValue)},[v?.potencyThcValue]),(0,s.useEffect)(()=>{v?.potencyCbdValue&&v?.potencyCbdValue?.length&&eo(v?.potencyCbdValue)},[v?.potencyCbdValue]);let ed=(0,b.isProviderShowcase)(L),ex=(0,s.useRef)({}),eu=(0,s.useRef)(null),em=(0,s.useCallback)(e=>ex.current[e]??40,[]),eh=(0,s.useCallback)((e,t)=>{ex.current[e]!==t&&(ex.current[e]=t,eu.current?.resetAfterIndex(e,!1))},[]),ep=(0,m.hasActiveShopFilters)(v),ef=E?{expandFull:!1,variant:"drawer",titleClass:"py-3"}:{},eb=E?(0,t.jsx)("div",{className:"border-b border-[#E5E5E5]"}):(0,t.jsx)("hr",{className:"my-5"}),eg=E||F?"mt-3":"h-52 mt-3 overflow-y-auto",ey=E||F?"mt-3":"max-h-48 mt-3 overflow-y-auto",ej=E||F?void 0:"overflow-hidden",ev=v?.dailyDealsValue?.length??0,eN=(0,m.countFilterListSelection)(v?.categories,["ALL CATEGORY"]),ew=(0,m.countFilterListSelection)(v?.subcategories,["ALL SUBCATEGORY"]),eC=(0,m.countFilterListSelection)(v?.weights,["ALL WEIGHT"]),ek=V?.ediblesWeightDisplayEnabled===!0,eS=v?.brandIds?.length??0,eL=(0,m.countFilterListSelection)(v?.strainTypes,["all"]),eA=(0,m.countActiveRangeSelection)(v?.price,0,f.PRICEMAX),eE=(0,m.countActiveRangeSelection)(v?.potencyThcValue,0,100)+(0,m.countActiveRangeSelection)(v?.potencyCbdValue,0,100),eT=v?.effects?.length??0,eF=v?.productTag?.length??0,eD=v?.states?.length??0;return(0,t.jsxs)("div",{children:[(0,t.jsxs)("div",{className:"md:flex justify-between items-center py-3 px-2 hidden sticky top-0 z-20 bg-white border-b border-[#E5E5E5] min-h-[4rem]",children:[(0,t.jsx)("p",{className:"text-sm font-bold global-body-color",children:"FILTERS"}),ep&&(0,t.jsx)("div",{className:"flex items-center gap-2 cursor-pointer",onClick:w,children:(0,t.jsx)("p",{className:"text-xs font-medium text-gray-400 hover:text-gray-700 hover:text-[var(--global-body-color)]",children:"Clear All"})})]}),(0,t.jsx)(l.default,{...ef,title:"Today's Specials",selectionCount:ev,default:!0,contentClass:ej,children:(0,t.jsx)("div",{className:`${eg} flex flex-col`,children:R?(0,t.jsx)(c.default,{}):(0,t.jsx)(t.Fragment,{children:A?.length>0?(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"mb-2",children:(0,t.jsxs)("label",{className:"relative flex items-start cursor-pointer overflow-hidden",htmlFor:"all-special",children:[(0,t.jsxs)("div",{className:"relative shrink-0 mt-0.5",children:[(0,t.jsx)("input",{id:"all-special",name:"specials-radio",onChange:e=>{W(e,v,N,A)},type:"checkbox",value:"all",checked:v?.dailyDealsValue.includes("all"),className:"peer h-5 w-5 appearance-none transition-all border-2 checked:border-normal checked:bg-[#34A203] border-gray-300 cursor-pointer rounded-lg"}),(0,t.jsx)(y.Check,{className:"absolute left-0.5 top-0.5 text-white transition-opacity opacity-0 pointer-events-none peer-checked:opacity-100",size:14})]}),(0,t.jsx)("span",{className:"text-sm font-medium ml-2 global-body-color",children:"All Specials"})]})}),(0,t.jsx)("div",{className:"flex-1",children:F?A.map((e,s)=>(0,t.jsx)(x.default,{index:s,style:{},data:{todaySpecialsValue:A,filterData:v,setQueryValues:N,handleTodaySpecialsQuery:W}},`specials-filter-${s}`)):(0,t.jsx)(o.default,{disableHeight:!0,children:({width:e})=>(0,t.jsx)(d.VariableSizeList,{ref:eu,className:"sb",height:170,itemCount:A?.length||0,itemSize:em,width:e,itemData:{todaySpecialsValue:A,filterData:v,setQueryValues:N,handleTodaySpecialsQuery:W,onItemMeasured:eh},children:x.default})})})]}):(0,t.jsx)("span",{className:"text-sm text-primary_text font-medium block mx-auto text-center global-body-color",children:"No Specials Data Found!"})})})}),eb,(0,t.jsx)(l.default,{...ef,title:"Categories",selectionCount:eN,default:!0,children:(0,t.jsx)("div",{className:eg,children:(0,t.jsx)("div",{className:"flex flex-col gap-2",children:D?(0,t.jsx)(c.default,{}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"mb-2",children:(0,t.jsx)(a.default,{label:"All Categories",className:"text-[#4B5563]",value:"ALL CATEGORY",onChange:t=>_(t,v,N,e?.category),checked:v?.categories.includes("ALL CATEGORY")})}),e?.category?.filter(e=>(e?.categoryName||e)?.toUpperCase()!=="ALL CATEGORY")?.map((s,l)=>(0,t.jsx)(a.default,{label:ee(s),className:"text-[#4B5563]",value:s?.categoryName||s,onChange:t=>_(t,v,N,e?.category),checked:v?.categories.includes("ALL CATEGORY")||v?.categories?.some(e=>e?.toLowerCase()===(s?.categoryName||s)?.toLowerCase())},"category-filter"+l))]})})})}),v?.categories?.length>0&&C?.length>0?(0,t.jsxs)(t.Fragment,{children:[eb,(0,t.jsx)(l.default,{...ef,title:"Sub Categories",selectionCount:ew,default:!0,children:(0,t.jsx)("div",{className:eg,children:(0,t.jsx)("div",{className:"flex flex-col gap-2",children:P?(0,t.jsx)(c.default,{}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"mb-2",children:(0,t.jsx)(a.default,{label:"All Subcategories",className:"text-[#4B5563]",value:"ALL SUBCATEGORY",onChange:e=>H(e,v,N,C),checked:v?.subcategories.includes("ALL SUBCATEGORY")})}),C?.map((e,s)=>(0,t.jsx)(a.default,{label:(0,i.makeTitleCase)(e),className:"text-[#4B5563]",value:e,onCh
1ange:e=>H(e,v,N,C),checked:v?.subcategories.includes("ALL SUBCATEGORY")||v?.subcategories?.some(t=>t?.toLowerCase()===e?.toLowerCase())},"subcategory-filter"+s))]})})})})]}):(0,t.jsx)(t.Fragment,{}),v?.categories?.length>0&&!(0,m.isInvalidCategoryForShowingWeight)(v?.categories)&&(ek||!(0,m.isEdiblesCategorySelected)(v?.categories))&&k?.length>0?(0,t.jsxs)(t.Fragment,{children:[eb,(0,t.jsx)(l.default,{...ef,title:"Weights",selectionCount:eC,default:!0,children:(0,t.jsx)("div",{className:eg,children:(0,t.jsx)("div",{className:"flex flex-col gap-2",children:P?(0,t.jsx)(c.default,{}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"mb-2",children:(0,t.jsx)(a.default,{label:"All Weights",className:"text-[#4B5563]",value:"ALL WEIGHT",onChange:e=>Y(e,v,N,k),checked:v?.weights.includes("ALL WEIGHT")})}),k?.map((e,s)=>(0,t.jsx)(a.default,{label:(0,i.makeTitleCase)(e),className:"text-[#4B5563]",value:e,onChange:e=>Y(e,v,N),checked:v?.weights.includes("ALL WEIGHT")||v?.weights.includes(e)},"weight-filter"+s))]})})})})]}):(0,t.jsx)(t.Fragment,{}),!ed&&(0,t.jsxs)(t.Fragment,{children:[eb,(0,t.jsx)(l.default,{...ef,title:"Brands",selectionCount:eS,default:!0,contentClass:ej,children:(0,t.jsxs)("div",{className:eg,children:[(0,t.jsx)("div",{className:"mr-3",children:(0,t.jsxs)("div",{className:"w-full relative flex mb-3",children:[(0,t.jsx)("input",{value:X,onChange:Z,placeholder:"Find a brand",type:"text",className:"border border-gray-200 rounded-[10px] p-3 w-full focus:outline-gray-300 focus:outline-[1px]"}),(0,t.jsx)(j.MagnifyingGlass,{size:24,className:"absolute right-3 top-3 cursor-pointer"})]})}),(0,t.jsx)("div",{className:"flex flex-col gap-2",children:O&&P?(0,t.jsx)(c.default,{}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"mb-2",children:(0,t.jsx)(a.default,{label:"All Brands",className:"text-[#4B5563]",value:"all",onChange:e=>q(e,{urlSlug:"all"},v,N),checked:v?.brandIds.includes("all")})}),(0,t.jsx)("div",{className:"flex-1",children:F?et.map((e,s)=>(0,t.jsx)(u.default,{index:s,style:{},data:{localBrandList:et,filterData:v,setQueryValues:N,handleBrandQuery:q}},`brands-filter-${s}`)):(0,t.jsx)(o.default,{disableHeight:!0,children:({width:e})=>(0,t.jsx)(d.FixedSizeList,{className:"sb",height:147,itemCount:et?.length||0,itemSize:30,width:e,itemData:{localBrandList:et,filterData:v,setQueryValues:N,handleBrandQuery:q},children:u.default})})})]})})]})})]}),(0,t.jsxs)(t.Fragment,{children:[eb,(0,t.jsx)(l.default,{...ef,title:"Strain Types",selectionCount:eL,titleClass:"text-xl 2xl:text-2xl !font-semibold !text-[#057A55]",default:!0,children:(0,t.jsx)("div",{className:eg,children:(0,t.jsx)("div",{className:"flex flex-col gap-2",children:D?(0,t.jsx)(c.default,{}):(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)("div",{className:"mb-2",children:(0,t.jsx)(a.default,{label:"All Strains",className:"text-[#4B5563]",value:"all",onChange:t=>{G(t,"all",v,N,e?.strainType)},checked:v?.strainTypes.includes("all")})}),e?.strainType?.map((s,l)=>(0,t.jsx)(a.default,{label:(0,i.makeTitleCase)(s),className:"text-[#4B5563]",onChange:t=>{G(t,s,v,N,e?.strainType)},value:s,checked:v?.strainTypes.includes("all")||v?.strainTypes.includes(s)},"strain-filter"+l))]})})})})]}),eb,(0,t.jsxs)(l.default,{...ef,title:"Price",selectionCount:eA,titleClass:"text-xl 2xl:text-2xl !font-semibold !text-[#057A55]",default:!0,children:[(0,t.jsxs)("div",{className:"mt-3",children:[(0,t.jsxs)("p",{className:"text-sm font-medium mb-2 global-body-color",children:["Price : $",ea?.[0]," - $",ea?.[1]]}),(0,t.jsx)(n.Range,{values:ea,step:1,min:0,max:f.PRICEMAX,onFinalChange:e=>{Q(e,N)},onChange:e=>{K(e,er)},renderTrack:({props:e,children:s})=>(0,t.jsx)("div",{onMouseDown:e.onMouseDown,onTouchStart:e.onTouchStart,style:{...e.style,height:"36px",display:"flex",marginLeft:"10px",width:"80%"},children:(0,t.jsx)("div",{ref:e.ref,style:{height:"7px",width:"100%",borderRadius:"4px",background:(0,n.getTrackBackground)({values:ea,colors:["#d1d5db","var(--primary-text-color)","#d1d5db"],min:0,max:f.PRICEMAX}),alignSelf:"center"},children:s})}),renderThumb:({props:e})=>(0,s.createElement)("div",{...e,key:e.key,style:{...e.style,height:"20px",width:"20px",borderRadius:"50%",backgroundColor:"#212322",display:"flex",justifyContent:"center",border:"2px s
1olid #fff",alignItems:"center",boxShadow:"0px 2px 6px #fff",cursor:"pointer"}})})]}),(0,t.jsx)("br",{})]}),!(0,b.isEcommerceOrPortfolioProvider)(L)&&(0,t.jsxs)(t.Fragment,{children:[eb,(0,t.jsxs)(l.default,{...ef,title:"Potency",selectionCount:eE,titleClass:"text-xl 2xl:text-2xl !font-semibold !text-[#057A55]",default:!0,children:[(0,t.jsxs)("div",{className:"mt-3",children:[(0,t.jsxs)("p",{className:"text-sm font-medium mb-2 global-body-color",children:["THC : ",ei?.[0],"% - ",ei?.[1],"%"]}),(0,t.jsx)(n.Range,{values:ei,step:1,min:0,max:100,onFinalChange:e=>{$(e,N)},onChange:e=>{I(e,en)},renderTrack:({props:e,children:s})=>(0,t.jsx)("div",{onMouseDown:e.onMouseDown,onTouchStart:e.onTouchStart,style:{...e.style,height:"36px",display:"flex",marginLeft:"10px",width:"80%"},children:(0,t.jsx)("div",{ref:e.ref,style:{height:"7px",width:"100%",borderRadius:"4px",background:(0,n.getTrackBackground)({values:ei,colors:["#d1d5db","var(--primary-text-color)","#d1d5db"],min:0,max:100}),alignSelf:"center"},children:s})}),renderThumb:({props:e})=>(0,s.createElement)("div",{...e,key:e.key,style:{...e.style,height:"20px",width:"20px",borderRadius:"50%",backgroundColor:"#212322",display:"flex",justifyContent:"center",border:"2px solid #fff",alignItems:"center",boxShadow:"0px 2px 6px #fff",cursor:"pointer"}})})]}),(0,t.jsx)("br",{}),(0,t.jsxs)("div",{className:"mt-3",children:[(0,t.jsxs)("p",{className:"text-sm font-medium mb-2 global-body-color",children:["CBD : ",ec?.[0],"% - ",ec?.[1],"%"]}),(0,t.jsx)(n.Range,{values:ec,step:1,min:0,max:100,onFinalChange:e=>{M(e,N)},onChange:e=>{U(e,eo)},renderTrack:({props:e,children:s})=>(0,t.jsx)("div",{onMouseDown:e.onMouseDown,onTouchStart:e.onTouchStart,style:{...e.style,height:"36px",display:"flex",marginLeft:"10px",width:"80%"},children:(0,t.jsx)("div",{ref:e.ref,style:{height:"7px",width:"100%",borderRadius:"4px",background:(0,n.getTrackBackground)({values:ec,colors:["#d1d5db","var(--primary-text-color)","#d1d5db"],min:0,max:100}),alignSelf:"center"},children:s})}),renderThumb:({props:e})=>(0,s.createElement)("div",{...e,key:e.key,style:{...e.style,height:"20px",width:"20px",borderRadius:"50%",backgroundColor:"#212322",display:"flex",justifyContent:"center",border:"2px solid #fff",alignItems:"center",boxShadow:"0px 2px 6px #fff",cursor:"pointer"}})})]}),(0,t.jsx)("br",{})]})]}),eb,(0,t.jsx)(l.default,{...ef,title:"Effects",selectionCount:eT,titleClass:"text-xl 2xl:text-2xl !font-semibold !text-[#057A55]",default:!0,children:(0,t.jsx)("div",{className:ey,children:(0,t.jsx)("div",{className:"flex flex-col gap-2",children:D?(0,t.jsx)(c.default,{}):(0,t.jsx)(t.Fragment,{children:e?.effects?.map((e,s)=>(0,t.jsx)(a.default,{label:(0,i.makeTitleCase)(e?.effects),className:"text-[#4B5563]",onChange:t=>{B(t,e?.effects,v,N)},value:e?.effects,checked:v?.effects.includes(e?.effects)},"effects-filter"+s))})})})}),(0,b.isEcommerceOrPortfolioProvider)(L)&&(0,t.jsxs)(t.Fragment,{children:[eb,(0,t.jsx)(l.default,{...ef,title:"Tags",selectionCount:eF,titleClass:"text-xl 2xl:text-2xl !font-semibold !text-[#057A55]",default:!0,children:(0,t.jsx)("div",{className:ey,children:(0,t.jsx)("div",{className:"flex flex-col gap-2",children:D?(0,t.jsx)(c.default,{}):(0,t.jsx)(t.Fragment,{children:e?.productTag?.map((e,s)=>(0,t.jsx)(a.default,{label:(0,i.makeTitleCase)(e?.name),className:"text-[#4B5563]",onChange:t=>{z(t,e?.name,v,N)},value:e?.name,checked:v?.productTag.includes(e?.name)},"tags-filter"+s))})})})})]}),(0,b.isProviderShowcase)(L)&&e?.states?.length>0&&(0,t.jsxs)(t.Fragment,{children:[eb,(0,t.jsx)(l.default,{...ef,title:"States",selectionCount:eD,titleClass:"text-xl 2xl:text-2xl !font-semibold !text-[#057A55]",default:!0,children:(0,t.jsx)("div",{className:ey,children:(0,t.jsx)("div",{className:"flex flex-col gap-2",children:D?(0,t.jsx)(c.default,{}):(0,t.jsx)(t.Fragment,{children:e?.states?.map((e,s)=>(0,t.jsx)(a.default,{label:(0,i.makeTitleCase)(e?.name),className:"text-[#4B5563]",onChange:t=>{J(t,e?.name,v,N)},value:e?.name,checked:v?.states?.includes(e?.name)||!1},"states-filter"+s))})})})})]})]})}])},843066,e=>{"use strict";var t=e.i(843476),s=e.i(271645),l=e.i(585965),a=e.i(318587),r=e.i(310160),i=e.i(577854),n=e.i(137963);let c=e=>e?{...e,dailyDealsValue:[...e.dailyDealsValue??[]],brandIds:[...e.brandIds??[]],categories:[...e.categories??[]],subcategories:[...e.subcategories??[]],strainTypes:[...e.strainTypes??[]],effects:[...e.effects??[]],productTag:[...e.productTag??[]],weights:[...e.weights??[]],states:[...e.states??[]],sort:e.sort?{...e.sort}:(0,r.getDefaultShopFilterState)().sort,potencyThcValue:[...e.potencyThcValue??[0,100]],potencyCbdValue:[...e.potencyCbdValue??[0,100]],price:[...e.price??(0,r.getDefaultShopFilterState)().price]}:(0,r.getDefaultShopFilterState)();e.s(["default",0,({isOpen:e,onClose:o,handleClearAll:d,handleSubmitFilter:x,setQueryValues:u,options:m=[],filterData:h,...p})=>
1{let f=h??p.filterData,[b,g]=(0,s.useState)(()=>c(f));(0,s.useEffect)(()=>{e&&g(c(f))},[e]);let y=(0,r.hasActiveShopFilters)(b),j=b?.sort?.label??"Popular";return(0,t.jsx)("div",{className:`bottom-drawer site-bg-color ${e?"open":""}`,children:(0,t.jsxs)("div",{className:"flex h-full max-h-[100dvh] flex-col",children:[(0,t.jsxs)("header",{className:"relative shrink-0 border-b border-[#E5E5E5] px-4 py-4",children:[(0,t.jsx)("h2",{className:"text-center text-base font-semibold global-heading-color",children:"Filters"}),(0,t.jsx)("button",{type:"button",onClick:()=>{o()},className:"absolute right-4 top-1/2 -translate-y-1/2","aria-label":"Close filters",children:(0,t.jsx)(i.X,{size:24,className:"global-body-color"})})]}),(0,t.jsxs)("div",{className:"min-h-0 flex-1 overflow-y-auto px-4 py-2 special-scrollbar",children:[m.length>0&&(0,t.jsxs)(t.Fragment,{children:[(0,t.jsx)(l.default,{title:`Sort By (${j})`,default:!0,variant:"drawer",expandFull:!0,titleClass:"py-3",children:(0,t.jsx)("div",{className:"mt-2 flex flex-col",children:m.map((e,s)=>(0,t.jsxs)("label",{className:"flex cursor-pointer items-center gap-3 py-2",children:[(0,t.jsx)("input",{type:"radio",name:"drawer-sort-by",value:e.label,checked:j===e.label,onChange:()=>{g(t=>({...t,sort:{direction:e.direction??t?.sort?.direction??"DESC",key:e.key??t?.sort?.key??"POPULAR",label:e.label}}))},className:"h-5 w-5 shrink-0 cursor-pointer appearance-none rounded-full border-2 border-gray-300 checked:border-[5px] checked:border-black"}),(0,t.jsx)("span",{className:"text-sm global-body-color",children:e.label})]},`drawer-sort-${e.label}-${s}`))})}),(0,t.jsx)("div",{className:"border-b border-[#E5E5E5]"})]}),(0,t.jsx)(a.default,{...p,filterData:b,setQueryValues:g,isBottomDrawer:!0,deferSubmit:!0})]}),(0,t.jsx)("footer",{className:"sticky bottom-0 shrink-0 border-t border-[#E5E5E5] bg-white px-4 py-4",children:(0,t.jsxs)("div",{className:"flex items-center justify-between gap-4",children:[(0,t.jsx)("button",{type:"button",onClick:()=>{d(),g(e=>({...e,...(0,r.getDefaultShopFilterState)()}))},className:(0,n.cn)("text-sm font-medium",y?"global-body-color":"text-gray-400",!y&&"cursor-not-allowed"),disabled:!y,children:"Clear all"}),(0,t.jsx)("button",{type:"button",onClick:()=>{u(b),x(b),o()},className:(0,n.cn)("rounded-full bg-black py-3 text-sm font-medium text-white px-10 shrink-0 min-w-[140px]",!y&&"ml-auto"),children:"Apply"})]})})]})})}])}]);

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.