1!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},t=(new e.Error).stack;t&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[t]="e8b4f607-e65f-4d29-b6c0-f72dc0b2fd20",e._sentryDebugIdIdentifier="sentry-dbid-e8b4f607-e65f-4d29-b6c0-f72dc0b2fd20")}catch(e){}}();var _global="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{};_global.SENTRY_RELEASE={id:"88a9894b917f3c78b775b93656a9d0a952e3919c"},(self.webpackChunkkudos_portal=self.webpackChunkkudos_portal||[]).push([[7601],{19777:(e,t,l)=>{l.d(t,{B_:()=>m,Fg:()=>o,Fl:()=>s,Im:()=>c,KP:()=>r,NM:()=>p,VM:()=>a,Wo:()=>h,XT:()=>u,eF:()=>g,kh:()=>d,lV:()=>i,v1:()=>n});const a=302,r=283,o=128,i=56,n=2,s=11,c=93,d=116,p=159,u=96,g=19.5,m=12,h=2},28988:(e,t,l)=>{l.d(t,{xM:()=>h,XD:()=>g,Zo:()=>v,iP:()=>b,e1:()=>x,aL:()=>i,Qr:()=>k,lF:()=>u,dS:()=>n,D2:()=>s,r9:()=>w,_Q:()=>A});var a=l(37619),r=l(47950),o=l(12243);const i=[{id:"12",label:"Online shopping",categoryIds:["12"],swatch:"purple200",iconSlug:"ONLINE_SHOPPING"},{id:"41",label:"Apparel",categoryIds:["41"],swatch:"blue200",iconSlug:"SHIRT"},{id:"43",label:"Electronics",categoryIds:["43"],swatch:"green200",iconSlug:"MONITOR"},{id:"15",label:"Travel",categoryIds:["15"],swatch:"yellow300",iconSlug:"SUITCASE"},{id:"3",label:"Dining",categoryIds:["3"],swatch:"red200",iconSlug:"DINING"},{id:"4",label:"Entertainment",categoryIds:["4"],swatch:"gray300",iconSlug:"MICROPHONE"},{id:"47",label:"Health",categoryIds:["47"],swatch:"purple200",iconSlug:"HEART_RATE"},{id:"9",label:"Fitness",categoryIds:["9","90"],swatch:"blue200",iconSlug:"FITNESS"},{id:"45",label:"Home improvement",categoryIds:["45"],swatch:"green200",iconSlug:"HOME_IMPROVEMENT"},{id:"16",label:"Grocery",categoryIds:["16"],swatch:"yellow300",iconSlug:"SHOPPING_CART"},{id:"10",label:"Hotel",categoryIds:["10"],swatch:"red200",iconSlug:"HOTEL"},{id:"98",label:"Wireless",categoryIds:["98"],swatch:"gray300",iconSlug:"WIRELESS"},{id:"32",label:"Food delivery",categoryIds:["32"],swatch:"purple200",iconSlug:"SCOOTER"},{id:"44",label:"Office supplies",categoryIds:["44"],swatch:"blue200",iconSlug:"FOLDER"},{id:"1",label:"Airline",categoryIds:["1"],swatch:"green200",iconSlug:"PLANE"},{id:"5",label:"Drugstore",categoryIds:["5"],swatch:"yellow300",iconSlug:"PHARMACY"},{id:"34",label:"Streaming",categoryIds:["34"],swatch:"red200",iconSlug:"PLAY_BUTTON"},{id:"46",label:"Wholesale",categoryIds:["46"],swatch:"gray300",iconSlug:"WHOLESALE"},{id:"24",label:"Transportation",categoryIds:["24"],swatch:"purple200",iconSlug:"CAR"},{id:"8",label:"Gas",categoryIds:["8"],swatch:"blue200",iconSlug:"GAS_PUMP"},{id:"36",label:"Concert ticket",categoryIds:["36"],swatch:"green200",iconSlug:"TICKET"}],n=e=>i.find(t=>t.id===e),s=e=>{var t,l;return null!==(l=null===(t=n(e))||void 0===t?void 0:t.categoryIds)&&void 0!==l?l:[]};var c=l(40242),d=l(14041),p=l(76990);const u=(0,p.Ay)(a.Ay).attrs(()=>({menuPortalTarget:"undefined"!=typeof document?document.body:void 0,menuPosition:"fixed",menuPortalStyleOverrides:e=>Object.assign(Object.assign({},e),{zIndex:9999}),menuStyleOverrides:()=>({left:"auto",right:0,width:"max-content",minWidth:"100%",maxWidth:"min(360px, calc(100vw - 32px))"}),optionStyleOverrides:()=>({whiteSpace:"nowrap",overflow:"hidden",textOverflow:"ellipsis"})}))` 2 min-width: 160px; 3 @media ${c.z4.maxTablet} { 4 min-width: unset; 5 width: 100%; 6 max-width: 100%; 7 } 8`,g=(0,p.Ay)(r.Ye)` 9 align-items: center; 10 gap: 8px; 11 width: 100%; 12 overflow-x: auto; 13 overflow-y: clip; 14 min-height: 40px; 15 16 @media ${c.z4.maxTablet} { 17 flex-wrap: wrap; 18 } 19`,m=(0,p.Ay)(r.Ye)` 20 align-items: center; 21 gap: 8px; 22 flex: 1 0 0; 23 min-width: 0; 24`,h=(0,p.Ay)(r.Ye)` 25 align-items: center; 26 gap: 8px; 27 flex-shrink: 0; 28 29 @media ${c.z4.maxTablet} { 30 width: 100%; 31 > * { 32 flex: 1; 33 } 34 } 35`,b=p.Ay.div` 36 display: grid; 37 grid-template-columns: repeat(auto-fill, minmax(min(260px, 100%), 1fr)); 38 gap: 16px; 39`,f=p.Ay.button` 40 display: flex; 41 align-items: center; 42 justify-content: center; 43 padding: 10px 16px; 44 border-radius: 100px; 45 border: 1.5px solid ${({theme:e})=>e.colors.border.primary}; 46 background: ${({theme:e})=>e.colors.bg.primary}; 47 cursor: pointer; 48 white-space: nowrap; 49 flex-shrink: 0; 50 transition: background 0.1s, border-color 0.1s; 51 52 ${({$active:e,theme:t})=>e&&p.AH` 53 background: ${t.colors.bg.dark}; 54 border-color: ${t.colors.bg.dark}; 55 `} 56`,y=(0,p.Ay)(o.a6)` 57 ${({$active:e,theme:t})=>e&&p.AH` 58 color: ${t.colors.text.inverse}; 59 `}
60`,v=({value:e,onChange:t,allLabel:l,showCardLinkedOffers:a=!0})=>{const r=[{type:"all",label:l},{type:"flashBoost",label:"Flash Boost"},...a?[{type:"cardLinkedOffers",label:"Card-linked offers"}]:[]];return d.createElement(m,null,r.map(l=>d.createElement(f,{key:l.type,type:"button","aria-pressed":e===l.type,$active:e===l.type,onClick:()=>t(l.type)},d.createElement(y,{$active:e===l.type},l.label))))},x=250,w=()=>[{label:"All categories",value:""},...i.map(e=>({label:e.label,value:e.id}))],E=[{label:"Featured",value:"featured"},{label:"Alphabetical A-Z",value:"alphabetical"},{label:"Highest reward",value:"reward"}],$=(e,{filterType:t,categoryId:l,sort:a},r)=>{const o=e.filter(e=>!("flashBoost"===t&&!e.isFlashBoost)&&(!("cardLinkedOffers"===t&&!(e=>{var t;return Boolean(null===(t=e.activeCLOs)||void 0===t?void 0:t.some(e=>e.isCurrentlyEligible))})(e))&&((e,t)=>{var l,a;const r=s(t);return!r.length||r.includes(String(null===(l=e.categoryV2)||void 0===l?void 0:l.id))||r.includes(String(null===(a=e.categoryV2)||void 0===a?void 0:a.parentId))})(e,l)));return[...o].sort((e,t)=>{var l,o,i,n;return"alphabetical"===a?(e.name||"").localeCompare(t.name||""):"reward"===a?(null!==(o=null===(l=t.boostMultiplierV3)||void 0===l?void 0:l.amount)&&void 0!==o?o:0)-(null!==(n=null===(i=e.boostMultiplierV3)||void 0===i?void 0:i.amount)&&void 0!==n?n:0):r(e)-r(t)})},A=(e,t)=>{const[l,a]=(0,d.useState)("all"),[r,o]=(0,d.useState)(""),[i,n]=(0,d.useState)("featured"),s=(0,d.useMemo)(()=>$(e||[],{filterType:l,categoryId:r,sort:i},t),[e,l,r,i,t]);return{filterType:l,setFilterType:a,categoryId:r,setCategoryId:o,sort:i,setSort:n,visibleMerchants:s}},k=({filterType:e,categoryId:t,sort:l,onFilterTypeChange:a,onCategoryChange:r,onSortChange:o})=>{const i=w(),n=E.find(e=>e.value===l),s=n?{value:n.value,label:`Sort by: ${n.label}`}:null;return d.createElement(g,null,d.createElement(v,{value:e,onChange:a,allLabel:"All"}),d.createElement(h,null,i.length?d.createElement(u,{onChange:e=>r(e.value),hideSelectedOptions:!1,options:i,value:i.find(e=>(null==e?void 0:e.value)===t),placeholder:"All categories"}):null,d.createElement(u,{onChange:e=>o(e.value),hideSelectedOptions:!1,options:E,value:s,placeholder:"Sort by"})))}},30127:(e,t,l)=>{l.d(t,{$:()=>j,A:()=>Y});var a=l(50228),r=l(47950),o=l(48774),i=l(43143),n=l(89687),s=l(9704),c=l(97303),d=l(41845),p=l(12243),u=l(28109),g=l(78711),m=l(71190),h=l(79390),b=l(14041),f=l(76990),y=l(86133),v=l(19777);const x=f.Ay.div` 61 display: flex; 62 align-items: center; 63 gap: 4px; 64 box-sizing: border-box; 65 width: 100%; 66 height: 48px; 67 padding: 6px; 68 border-radius: 4px; 69 background-color: ${({theme:e})=>e.colors.bg.secondary}; 70`,w=f.Ay.img` 71 display: inline-block; 72 vertical-align: middle; 73 width: ${v.eF}px; 74 height: ${v.B_}px; 75 margin-right: 4px; 76 border-radius: ${v.Wo}px; 77 object-fit: cover; 78`,E=(0,f.Ay)(w)` 79 border-radius: 0; 80 object-fit: contain; 81`,$=(0,f.Ay)(p.OJ)` 82 display: -webkit-box; 83 -webkit-line-clamp: 2; 84 -webkit-box-orient: vertical; 85 overflow: hidden; 86`,A=({clause:e,className:t})=>e.cardThumbnailUri?b.createElement(w,{className:t,src:e.cardThumbnailUri,alt:""}):e.issuerLogoUri?b.createElement(E,{className:t,src:e.issuerLogoUri,alt:""}):null,k=({rewards:e,emptyLabel:t,className:l})=>e.length?b.createElement(x,{className:l},b.createElement($,{tertiary:!0},e.map((e,t)=>{var l;return b.createElement(b.Fragment,{key:t},t>0?" ⢠":null,null!==(l=e.icon)&&void 0!==l?l:b.createElement(A,{clause:e}),e.label)}))):b.createElement(x,{className:l},b.createElement(p.Uy,{inactive:!0},t));var S=l(74277),I=l(86406),T=l(86368),N=l(63357);const C=e=>Math.max(0,Math.ceil((new Date(e).getTime()-Date.now())/864e5)),O=f.Ay.div` 87 display: inline-flex; 88 align-items: center; 89 gap: 4px; 90 max-width: 100%; 91 /* The tighter left edge is for the badges that lead with an icon; text-only ones sit even. */ 92 padding: ${({$kind:e})=>"offerExpiring"===e||"offerNotActivated"===e?"2px 6px":"2px 6px 2px 3px"}; 93 border-radius: 16px; 94 border: 2px solid ${({theme:e})=>e.colors.bg.primary}; 95 background-color: ${({$kind:e,theme:t})=>"dealOfTheDay"===e?t.colors.bg.dark:"offerExpiring"===e?t.colors.primitives.red200:"offerNotActivated"===e?t.colors.primitives.yellow200:t.colors.border.accent.yellow}; 96`,L=(0,f.Ay)(p.OJ)` 97 min-width: 0; 98 overflow: hidden; 99 text-overflow: ellipsis; 100 white-space: nowrap; 101`,F=({badge:e,className:t})=>{const l=(0,f.DP)();return"dealOfTheDay"===e.kind?b.createElement(O,{$kind:"dealOfTheDay",className:t},b.createElement(o.A,{icon:S.A,size:16,color:l.colors.icon.inverse}),b.createElement(L,{inverse:!0},"Deal of the Day")):"offerNotActivated"===e.kind?b.createElement(O,{$kind:"offerNotActivated",className:t},b.createElement(L,{warning:!0},"Not activated")):"offerExpiring"===e.kind?b.createElement(O,{$kind:"offerExpiring",className:t},b.createElement(L,{danger:!0},(a=e.daysRemaining)?`Exp ${a} ${1===a?"day":"days"}`:"Expired")):b.createElement(O,{$kind:"flashBoost",className:t},b.createElement(o.A,{icon:I.A,size:16,color:l.colors.icon.warning}),b.createElement(L,{warning:!0},"Flash Boost"));var a},M=f.Ay.div` 102 position: relative; 103 box-sizing: border-box; 104 width: 100%; 105 height: ${v.VM}px; 106 overflow: hidden; 107 border: 1px solid ${({theme:e})=>e.colors.border.primary}; 108 border-radius: 8px; 109 background-color: ${({theme:e})=>e.colors.bg.primary}; 110 box-shadow: ${({theme:e})=>e.shadows.elevation.z1}; 111 cursor: pointer; 112 transition: border-color 100ms ease-out, box-shadow 100ms ease-out; 113 114 &:hover:not(:has(button:hover)) { 115 border-color: ${({theme:e})=>e.colors.border.secondary}; 116 box-shadow: ${({theme:e})=>e.shadows.elevation.z2}; 117 } 118`,D=f.Ay.div` 119 position: absolute; 120 top: -1px; 121 left: -1px; 122 right: -1px; 123 height: ${v.Fg}px; 124 overflow: hidden; 125 background-color: ${({theme:e})=>e.colors.bg.secondary}; 126 background-image: url(${({$imageUrl:e})=>e}); 127 background-size: cover; 128 background-position: center; 129 130 /* Darkens the foot of the hero so the logo and badge hold their edges against any artwork. */ 131 &::after { 132 content: ''; 133 position: absolute; 134 inset: 0; 135 background: linear-gradient(180deg, rgba(255, 255, 255, 0.01) 0%, rgba(0, 0, 0, 0.5) 95%); 136 } 137`,B=f.Ay.button` 138 position: absolute; 139 top: 12px; 140 right: 12px; 141 z-index: 1; 142 display: flex; 143 align-items: center; 144 justify-content: center; 145 width: 32px; 146 height: 32px; 147 padding: 0; 148 border-radius: 100px; 149 cursor: pointer; 150 background-color: ${({$active:e,theme:t})=>e?t.colors.bg.accent.purple:t.colors.bg.primary}; 151 border: ${({$active:e,theme:t})=>e?"1.5px solid transparent":`1.5px solid ${t.colors.border.secondary}`}; 152`,z=f.Ay.div` 153 position: absolute; 154 top: ${v.Im+v.v1}px; 155 left: ${v.Fl+v.v1}px; 156 border-radius: 50%; 157 border: ${v.v1}px solid ${({theme:e})=>e.colors.bg.primary}; 158 background-color: ${({theme:e})=>e.colors.bg.primary}; 159 160 /* MerchantAvatar contains its image by default, which leaves the square crop adrift in the circle. */ 161 img { 162 object-fit: cover; 163 } 164`,P=f.Ay.div` 165 position: absolute; 166 top: ${v.kh}px; 167 right: ${v.Fl}px; 168 max-width: calc(100% - ${2*v.Fl}px); 169`,_=f.Ay.div` 170 position: absolute; 171 top: ${v.NM}px; 172 left: ${v.Fl}px; 173 right: ${v.Fl}px; 174 height: ${v.XT}px; 175 display: flex; 176 flex-direction: column; 177 justify-content: center; 178 gap: 4px; 179`,R=(0,f.Ay)(p.aL)` 180 flex: 1 0 0; 181 min-width: 0; 182 overflow: hidden; 183 text-overflow: ellipsis; 184 white-space: nowrap; 185`,U=(0,f.Ay)(o.A)` 186 display: inline-flex; 187 vertical-align: middle; 188 margin-right: 4px; 189`,H=(0,f.Ay)(A)` 190 display: block; 191 flex-shrink: 0; 192 margin-right: 0; 193`,V=(0,f.Ay)(p.a6)` 194 min-width: 0; 195 overflow: hidden; 196 text-overflow: ellipsis; 197 white-space: nowrap; 198`,W=(0,f.Ay)(a.A)` 199 position: absolute; 200 left: ${v.Fl}px; 201 right: ${v.Fl}px; 202 bottom: ${v.Fl}px; 203 width: auto; 204 padding: 5px 10px; 205 border-radius: 4px; 206`,j=({className:e})=>b.createElement(M,{className:e,as:"div",style:{cursor:"default"}},b.createElement(D,{$imageUrl:""}),b.createElement(z,null,b.createElement(d.A,{width:v.lV-2*v.v1,height:v.lV-2*v.v1,circle:!0})),b.createElement(_,null,b.createElement("div",null,b.createElement(d.A,{width:"70%",height:24}),b.createElement(d.A,{width:"55%",height:20})),b.createElement(d.A,{width:"100%",height:48}))),Y=({merchant:e,onSeeDetails:t,isFavorite:l,onToggleFavorite:a,benef
206it:d,offer:x,className:w})=>{var E,$;const A=(0,f.DP)(),S=null!==($=null!=x?x:null===(E=e.activeCLOs)||void 0===E?void 0:E.find(e=>e.isCurrentlyEligible))&&void 0!==$?$:null,I=((e,t)=>{var l;if(t&&(0,T.Xv)(t))return{kind:"offerNotActivated"};if(null===(l=e.flashBoostSaleMetadata)||void 0===l?void 0:l.isFeatured)return{kind:"dealOfTheDay"};if(e.isFlashBoost)return{kind:"flashBoost"};const a=(null==t?void 0:t.expirationDate)?(0,N._)(t.expirationDate):null;return(null==a?void 0:a.isExpiringSoon)?{kind:"offerExpiring",daysRemaining:C(t.expirationDate)}:null})(e,S),O=(e=>{const t=(0,u.u8)(e,{showBoostLabel:!1,showUpTo:!0});return t?(null==e?void 0:e.displayType)===h.USB.Flat?`${t} with Boost`:`${t} Back with Boost`:""})(e.boostMultiplierV3),L=S?(e=>{var t,l,a,r,o;const i=(0,y.IK)(e.rewardType,null!==(t=e.amount)&&void 0!==t?t:null,e.rewardCurrencyType,null===(l=e.card)||void 0===l?void 0:l.currency);return{label:"Offer"===i?"Linked Offer":`Linked Offer: ${i.replace(/back$/,"Back")}`,cardThumbnailUri:(null===(a=e.card)||void 0===a?void 0:a.thumbnailUri)||(null===(r=e.card)||void 0===r?void 0:r.imageUri),issuerLogoUri:null===(o=e.issuer)||void 0===o?void 0:o.imageUri}})(S):null,j=O?{icon:b.createElement(U,{icon:i.A,size:18}),label:O}:null,Y=(L?[j,d]:[d]).filter(e=>null!=e),G=L?"Boost Rewards not available":"Card-Linked Offers not available";return b.createElement(M,{className:w,onClick:t},b.createElement(D,{$imageUrl:(0,g.hu)(e)},a?b.createElement(B,{type:"button",$active:Boolean(l),"aria-pressed":Boolean(l),"aria-label":l?`Remove ${e.name} from saved stores`:`Save ${e.name}`,onClick:e=>{e.stopPropagation(),a(e)}},b.createElement(o.A,{icon:n.A,size:20,color:l?A.colors.icon.inverse:A.colors.icon.primary})):null),b.createElement(z,null,b.createElement(c.A,{logoUrl:(0,m.h)(e),name:e.name||"",size:v.lV-2*v.v1})),I?b.createElement(P,null,b.createElement(F,{badge:I})):null,b.createElement(_,null,b.createElement("div",null,b.createElement(r.Ye,{gap:"8px",alignItems:"center"},b.createElement(R,{primary:!0},e.name),b.createElement(o.A,{icon:s.A,size:16,color:A.colors.icon.primary})),L?b.createElement(r.Ye,{gap:"4px",alignItems:"center"},b.createElement(H,{clause:L}),b.createElement(V,{secondary:!0},L.label)):O?b.createElement(r.Ye,{gap:"4px",alignItems:"center"},b.createElement(o.A,{icon:i.A,size:20}),b.createElement(p.a6,{secondary:!0},O)):null),b.createElement(k,{rewards:Y,emptyLabel:G})),b.createElement(W,{variant:"secondary",size:"32px",onClick:e=>{e.stopPropagation(),t()}},"See details"))}},63357:(e,t,l)=>{l.d(t,{_:()=>a});const a=e=>{if(!e)return{text:"",isExpiringSoon:!1};const t=new Date(e),l=new Date,a=t.getTime()-l.getTime(),r=Math.ceil(a/864e5);if(r<=0)return{text:"Expired",isExpiringSoon:!0};if(r<=30)return{text:`Expires in ${r} day${1===r?"":"s"}`,isExpiringSoon:!0};return{text:`Expires on ${t.toLocaleDateString("en-US",{month:"short",day:"numeric",year:"numeric"})}`,isExpiringSoon:!1}}},71190:(e,t,l)=>{l.d(t,{h:()=>a});const a=e=>e.logoThumbnailUri||e.logoImageUri||""},81092:(e,t,l)=>{l.d(t,{A:()=>y});var a=l(48774),r=l(12243),o=l(53970),i=l(14041),n=l(76990),s=l(94398);const c=n.Ay.div` 207 position: relative; 208 background-color: ${({theme:e})=>e.colors.bg.primary}; 209`,d=n.Ay.div` 210 display: flex; 211 align-items: center; 212 overflow-x: auto; 213 -webkit-overflow-scrolling: touch; 214 scrollbar-width: none; 215 216 &::-webkit-scrollbar {
217 display: none; 218 } 219`,p=n.Ay.button` 220 display: flex; 221 flex-direction: column; 222 align-items: center; 223 gap: 4px; 224 flex-shrink: 0; 225 margin-left: ${({$leading:e})=>e?"-25px":"0"}; 226 width: ${120}px; 227 height: ${100}px; 228 padding: 8px 0; 229 border: none; 230 background-color: transparent; 231 cursor: pointer; 232`,u=n.AH` 233 svg [stroke] { 234 vector-effect: non-scaling-stroke; 235 stroke-width: 1.5; 236 } 237`,g=n.Ay.div` 238 display: flex; 239 align-items: center; 240 justify-content: center; 241 flex-shrink: 0; 242 width: ${60}px; 243 height: ${60}px; 244 border-radius: ${60}px; 245 overflow: hidden; 246 background-color: ${({$swatch:e,theme:t})=>t.colors.primitives[e]}; 247 248 ${u} 249`,m=(0,n.Ay)(r.a6)` 250 max-width: 100%; 251 word-break: break-all; 252 color: ${({$selected:e,theme:t})=>e?t.colors.text.primary:t.colors.text.secondary}; 253 text-decoration: ${({$selected:e})=>e?"underline":"none"}; 254`,h=n.Ay.div` 255 position: absolute; 256 top: 0; 257 ${({$side:e})=>"left"===e?"left: 0;":"right: 0;"} 258 width: ${51}px; 259 height: 100%; 260 display: flex; 261 align-items: center; 262 justify-content: ${({$side:e})=>"left"===e?"flex-start":"flex-end"}; 263 pointer-events: none; 264 opacity: ${({$visible:e})=>e?1:0}; 265 /* Hidden rather than merely transparent, so a faded-out chevron leaves the tab order too. */ 266 visibility: ${({$visible:e})=>e?"visible":"hidden"}; 267 transition: opacity 0.2s ease-in-out, visibility 0.2s ease-in-out; 268 background: ${({$side:e,theme:t})=>`linear-gradient(to ${"left"===e?"right":"left"}, ${t.colors.bg.primary} 38.5%, transparent)`}; 269`,b=n.Ay.button` 270 pointer-events: auto; 271 display: flex; 272 align-items: center; 273 justify-content: center; 274 width: 32px; 275 height: 32px; 276 padding: 0; 277 border-radius: 100px; 278 border: 1.5px solid ${({theme:e})=>e.colors.border.secondary}; 279 background-color: ${({theme:e})=>e.colors.bg.primary}; 280 cursor: pointer; 281 282 &:hover { 283 background-color: ${({theme:e})=>e.colors.button.secondaryHover}; 284 } 285`,f=e=>e||"all-stores",y=({categories:e,selectedCategoryId:t,onSelect:l,className:r})=>{const n=(0,i.useRef)(null),u=(0,i.useRef)({}),y=(0,i.useRef)(!1),[v,x]=(0,i.useState)(!1),[w,E]=(0,i.useState)(!1),$=(0,i.useCallback)(()=>{const e=n.current;if(!e)return;const{scrollLeft:t,scrollWidth:l,clientWidth:a}=e;x(t>1),E(t+a<l-1)},[]);(0,i.useEffect)(()=>{const e=n.current;if(e)return $(),e.addEventListener("scroll",$),window.addEventListener("resize",$),()=>{e.removeEventListener("scroll",$),window.removeEventListener("resize",$)}},[$,e.length]);const A=e=>{var t;null===(t=n.current)||void 0===t||t.scrollBy({left:"left"===e?-360:360,behavior:"smooth"})};(0,i.useEffect)(()=>{if(y.current)return void(y.current=!1);const e=n.current,l=u.current[f(t)];if(!e||!l)return;if(l.offsetLeft>=e.scrollLeft&&l.offsetLeft+l.offsetWidth<=e.scrollLeft+e.clientWidth)return;const a=l.offsetLeft-(e.clientWidth-l.offsetWidth)/2,r=e.scrollWidth-e.clientWidth;e.scrollTo({left:Math.max(0,Math.min(a,r)),behavior:"smooth"})},[t,e.length]);const k=[{id:"",name:"All Stores",swatch:"pink400",iconSlug:"PRICE_TAG"},...e];return i.createElement(c,{className:r},i.createElement(d,{ref:n},k.map(e=>{const a=e.id===t;return i.createElement(p,{key:f(e.id),ref:t=>{u.current[f(e.id)]=t},type:"button",$leading:""===e.id,"aria-pressed":a,onClick:()=>{y.current=!0,l(e.id)}},i.createElement(g,{$swatch:e.swatch},i.createElement(o.A,{categoryIconSlug:e.iconSlug,size:40})),i.createElement(m,{lines:1,$selected:a},e.name))})),i.createElement(h,{$side:"left",$visible:v},i.createElement(b,{type:"button","aria-label":"Scroll categories left",onClick:()=>A("left")},i.createElement(a.A,{icon:s.A,size:14}))),i.createElement(h,{$side:"right",$visible:w},i.createElement(b,{type:"button","aria-label":"Scroll categories right",onClick:()=>A("right")},i.createElement(a.A,{flipHorizontal:!0,icon:s.A,size:14}))))}},90993:(e,t,l)=>{l.d(t,{Ay:()=>p,n7:()=>d});var a=l(12243),r=l(99420),o=l.n(r),i=l(14041),n=l(76990);const s=n.Ay.div` 286 display: inline-flex; 287 padding: 5px; 288 border-radius: 100000px; 289 border: 1px solid ${({theme:e})=>e.colors.bg.accent.yellowSecondary}; 290 background-color: ${({theme:e})=>e.colors.bg.accent.yellowSecondary}; 291`,c=n.Ay.div` 292 display: inline-flex; 293 align-items: center; 294 gap: 5px; 295 padding: 2px 12px; 296 border-radius: 1000px; 297 background-color: ${({theme:e})=>e.colors.bg.accent.yellow}; 298 white-space: nowrap; 299`,d=(e,t)=>{const l=(e=>{if(!e)return null;const t=o()(e);if(!t.isValid())return null;const l=t.diff(o()(),"days",!0);return l>0?Math.ceil(l):0})(e);return null==l?null:0===l?`${t} today`:`${t} in ${1===l?"1 day":`${l} days`}`},p=({label:e,withHalo:t=!1,className:l})=>{const r=i.createElement(c,{className:t?void 0:l},i.createElement(a.a6,{primary:!0},e));return t?i.createElement(s,{className:l},r):r}},91442:(e,t,l)=>{l.d(t,{A:()=>r});var a=l(14041);const r=(e,t)=>{const[l,r]=(0,a.useState)(e);return(0,a.useEffect)(()=>{const l=setTimeout(()=>r(e),t);return()=>clearTimeout(l)},[e,t]),l}},99046:(e,t,l)=>{l.d(t,{A:()=>U});var a=l(30571),r=l(64384),o=l(26105),i=l(50228),n=l(30127),s=l(12243),c=l(40242),d=l(79390),p=l(99420),u=l.n(p),g=l(57490),m=l(14041),h=l(76990),b=l(5902),f=l(90993);const y=l.p+"8dd8d65c82dd4a8e3a33.png",v=l.p+"1e62afa7a5a79a23ed3a.png",x=l.p+"5897477755d063fc3b98.png",w=l.p+"9d865309738700f045ba.png",E=l.p+"c516bd49e2a91e730779.png",$=l.p+"d7eb215a8a57ed2b7536.png",A=l.p+"9faa39d14f5c3d92b13f.png",k=l.p+"2aeeed2a1d7d57d9e7c8.png",S=l.p+"d0eff73fe2f126769ecb.png",I=l.p+"a727e8bd7e295df52990.png",T=l.p+"5095e551728d5e0219dc.png",N=[E,w,k,y,S,A,$,v,l.p+"e6595f1a050c555e7906.png",T,I,x],C=h.Ay.img` 300 flex-shrink: 0; 301 width: 245px; 302 height: 100px; 303 object-fit: contain; 304`,O=({endDate:e,className:t})=>{const l=e&&u()(e).isValid()?u()(e):u()(),a=N[l.month()];return a?m.createElement(C,{className:t,src:a,alt:""}):null};var L=l(28988),F=l(61553);const M=h.Ay.div` 305 display: flex; 306 flex-direction: column; 307 gap: 16px; 308 padding: 24px; 309 border-radius: 12px; 310 border: 1px solid ${({theme:e})=>e.colors.border.primary}; 311 background-color: ${({theme:e})=>e.colors.bg.secondary}; 312 313 @media ${c.z4.maxTablet} { 314 padding: 16px; 315 } 316`,D=h.Ay.div` 317 display: flex; 318 align-items: center; 319 justify-content: space-between; 320 gap: 16px; 321`,B=h.Ay.div` 322 display: flex; 323 flex-direction: column; 324 align-items: flex-start; 325 gap: 2px; 326`,z=(0,h.Ay)(O)` 327 @media ${c.z4.maxTablet} { 328 display: none; 329 } 330`,P=(0,h.Ay)(i.A)` 331 width: 100%;
332`,_=(0,h.Ay)(g.P.div)``,R={sort:{order:d.UAZ.Asc,sort:d.kPx.FeaturedSortOrder},pagination:{offset:0,limit:20}},U=({onSelectMerchant:e,onViewAllBoostStores:t,showFavorites:l=!0,viewAllLabel:i="See all stores",revealInPlace:c=!1,collapseLabel:d="See fewer stores"})=>{var p,g,h;const[y,v]=m.useState(!1),{isFavorite:x,toggleFavorite:w}=(0,F.e)(),{data:E,loading:$}=(0,a.IT)(o.ZDx,{variables:{searchMerchantArgs:Object.assign({filters:{isFlashBoost:!0,isBoostEligible:!0}},R)}}),A=null===(p=null==E?void 0:E.Merchants_searchMerchantsV3)||void 0===p?void 0:p.merchants,k=null===(h=null===(g=null==A?void 0:A.find(e=>{var t;return null===(t=e.flashBoostSaleMetadata)||void 0===t?void 0:t.endDate}))||void 0===g?void 0:g.flashBoostSaleMetadata)||void 0===h?void 0:h.endDate,S=`${(k?u()(k):u()()).format("MMMM")} Flash Boost`,I=(0,f.n7)(k,"Ends");if(!$&&!(null==A?void 0:A.length))return null;const T=null!=A?A:[],N=c?T.slice(0,6):T,C=c?T.slice(6):[],O=!c||C.length>0,U=t=>m.createElement(n.A,{key:t.id,merchant:t,isFavorite:l?x(t):void 0,onToggleFavorite:l?()=>w(t):void 0,onSeeDetails:()=>(t=>{b.KudosAnalytics.send("event",{type:r.sV.MERCHANT_PAGE_FEATURED_MERCHANT_CLICK,mixpanelData:{merchantId:t.id,merchantName:t.name,source:"flash-boost-list"}}),e(t)})(t)});return m.createElement(M,null,m.createElement(D,null,m.createElement(B,null,I?m.createElement(f.Ay,{label:I,withHalo:!0}):null,m.createElement(s.sx,null,S),m.createElement(s.a6,{secondary:!0},"Earn extra Cash Back all month long at select stores.")),m.createElement(z,{endDate:k})),m.createElement(L.iP,null,$?Array.from({length:6}).map((e,t)=>m.createElement(n.$,{key:t})):N.map(U),y?C.map((e,t)=>m.createElement(_,{key:e.id,initial:{opacity:0,y:-16},animate:{opacity:1,y:0},transition:{duration:.25,ease:"easeOut",delay:.04*Math.min(t,5)}},U(e))):null),O?m.createElement(P,{size:"48px",onClick:c?()=>v(!y):t},c&&y?d:i):null)}}}]); 333//# sourceMappingURL=7601.a8cfa310c32b2ce5ac67.js.map
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.