https://www.accommodationforstudents.com/_next/static/chunks/pages/student-perks-ca1556eab24ef652.js
1 2!function(){try{var e="undefined"!=typeof window?window:"undefined"!=typeof global?global:"undefined"!=typeof globalThis?globalThis:"undefined"!=typeof self?self:{},n=(new e.Error).stack;n&&(e._sentryDebugIds=e._sentryDebugIds||{},e._sentryDebugIds[n]="36d77d7c-257e-55a9-8a8c-f73bdfedf48e")}catch(e){}}(); 3(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[33485],{1711:(e,t,r)=>{"use strict";r.d(t,{A:()=>c});var a=r(37876),s=r(36228),n=r.n(s),l=r(74355),o=r(79867),i=r(9106),d=r.n(i);let c=({metaData:e,svgName:t="error",heading:r,text:s,buttons:i,helpOverlay:c})=>(0,a.jsxs)(o.A,{wrapperClassName:d().wrapper,metaData:e,headerProps:c?{showNavigation:!1,children:c}:void 0,"data-sentry-element":"Layout","data-sentry-component":"ErrorStatusTemplate","data-sentry-source-file":"index.tsx",children:[(0,a.jsx)(l.A,{className:d().image,type:"pictograms",name:t,size:64,"data-sentry-element":"Svg","data-sentry-source-file":"index.tsx"}),(0,a.jsx)(n(),{className:d().heading,level:1,"data-sentry-element":"Heading","data-sentry-source-file":"index.tsx",children:r}),"string"==typeof s?(0,a.jsx)("p",{className:d().text,children:s}):s,(0,a.jsx)("div",{className:d().buttons,children:i})]})},4459:(e,t,r)=>{"use strict";r.d(t,{A:()=>o});var a=r(37876),s=r(14232),n=r(15039),l=r.n(n);r(40959);let o=({className:e,alt:t,dataSrc:r,dataSizes:n="auto",dataSrcSet:o,errorImageSrc:i,onError:d,eager:c=!1,...u})=>{let[m,p]=(0,s.useState)(!1),[g,f]=(0,s.useState)(!1);(0,s.useEffect)(()=>{c||p(!0)},[]);let h=m?l()("lazyload",e).trim():l()("not-mounted",e).trim(),x=e=>{i&&f(!0),d?.(e)};return g?(0,a.jsx)("img",{className:e,src:i,...u,alt:"Broken image link"},`${r}-error`):c?(0,a.jsx)("img",{className:e,alt:t,src:r,srcSet:o||void 0,onError:x,...u}):(0,a.jsx)("img",{className:h,alt:t,"data-src":r,"data-sizes":n,"data-srcset":o||void 0,onError:x,...u,"data-sentry-component":"LazyImage","data-sentry-source-file":"index.tsx"},r)}},9106:e=>{e.exports={wrapper:"ErrorStatusTemplate__wrapper--807ad",heading:"ErrorStatusTemplate__heading--73074",image:"ErrorStatusTemplate__image--738c8",text:"ErrorStatusTemplate__text--eb925",buttons:"ErrorStatusTemplate__buttons--58057"}},22852:e=>{e.exports={card:"PartnerOfferCard__card--69e13",logoPanel:"PartnerOfferCard__logoPanel--3d1c4",backgroundImage:"PartnerOfferCard__backgroundImage--d77b0",logo:"PartnerOfferCard__logo--e96dd",logoTinted:"PartnerOfferCard__logoTinted--575bc",body:"PartnerOfferCard__body--b1e80",tag:"PartnerOfferCard__tag--51a78",tagIcon:"PartnerOfferCard__tagIcon--fdfb2",title:"PartnerOfferCard__title--2d156",description:"PartnerOfferCard__description--d226c",cta:"PartnerOfferCard__cta--42b37",arrow:"PartnerOfferCard__arrow--23210"}},26302:(e,t,r)=>{"use strict";r.d(t,{p:()=>a});let a=e=>{if(!Number.isInteger(e)||e<=0)throw Error(`Breadcrumb position must be a positive integer, received: ${e}`);return e}},27938:(e,t,r)=>{"use strict";r.d(t,{j:()=>a});let a=e=>e.replace(/&#(\d+);/g,(e,t)=>String.fromCodePoint(Number(t))).replace(/&#x([0-9a-fA-F]+);/g,(e,t)=>String.fromCodePoint(parseInt(t,16))).replace(/ /g," ").replace(/"/g,'"').replace(/'/g,"'").replace(/</g,"<").replace(/>/g,">").replace(/&/g,"&")},29627:(e,t,r)=>{"use strict";r.d(t,{A:()=>d});var a=r(37876),s=r(32444),n=r(10164),l=r(1711),o=r(37974),i=r.n(o);let d=({relativeUrl:e})=>(0,a.jsx)(l.A,{metaData:{title:"Something went wrong | Accommodation for Students",description:"An error occurred while loading the page. Please try again later.",robots:"noindex, follow",relativeUrl:e},svgName:"error",heading:"Oops!",text:(0,a.jsxs)("p",{className:i().text,children:["Something went wrong."," ",(0,a.jsxs)("span",{children:["If the problem persists, please"," ",(0,a.jsx)(n.A,{className:i().link,to:"/contact-us",children:"get in touch"}),"."]})]}),buttons:(0,a.jsx)(s.A,{primary:!0,to:"/",size:"medium",children:"Return to Homepage"}),"data-sentry-element":"ErrorStatusTemplate","data-sentry-component":"ErrorPage","data-sentry-source-file":"index.tsx"})},31007:e=>{e.exports={breadcrumbWrapper:"Breadcrumb__breadcrumbWrapper--a4d36",breadcrumbWrapperWithBreadcrumbsRendered:"Breadcrumb__breadcrumbWrapperWithBreadcrumbsRendered--cb349",list:"Breadcrumb__list--a2b4e",listItem:"Breadcrumb__listItem--191d2",listItemDropdown:"Breadcrumb__listItemDropdown--15a7c",lastListItem:"Breadcrumb__lastListItem--a536a",listLink:"Breadcrumb__listLink--8cabe",dropdownButton:"Breadcrumb__dropdownButton--489c2",active:"Breadcrumb__active--8beb0",dropdownIcon:"Breadcrumb__dropdownIcon--1ffb2",dropdownWrapper:"Breadcrumb__dropdownWrapper--1b486",dropdownLink:"Breadcrumb__dropdownLink--6560e",visuallyHidden:"Breadcrumb__visuallyHidden--8dc2e"}},37974:e=>{e.exports={link:"ErrorPage__link--00fa1",text:"ErrorPage__text--75d11"}},55556:(e,t,r)=>{"use strict";r.r(t),r.d(t,{__N_SSP:()=>el,default:()=>ei,studentPerksGetServerSideProps:()=>eo});var a,s,n,l,o,i,d,c=r(37876),u=r(35543),m=r(57078),p=r(14232),g=r(15039),f=r.n(g),h=r(79867),x=r(76603),b=r(26302),v=r(4459);function w(){return(w=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var a in r)({}).hasOwnProperty.call(r,a)&&(e[a]=r[a])}return e}).apply(null,arguments)}let _=e=>p.createElement("svg",w({xmlns:"http://www.w3.org/2000/svg",width:16,height:16,fill:"none",viewBox:"0 0 16 16"},e),a||(a=p.createElement("path",{stroke:"currentColor",strokeLinejoin:"round",strokeWidth:1.4,d:"M2 2.75A.75.75 0 0 1 2.75 2H8c.4 0 .78.16 1.06.44l4.5 4.5a1.5 1.5 0 0 1 0 2.12l-4.5 4.5a1.5 1.5 0 0 1-2.12 0l-4.5-4.5a1.5 1.5 0 0 1-.44-1z"})),s||(s=p.createElement("circle",{cx:5.4,cy:5.4,r:1,fill:"currentColor"})));function y(){return(y=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var a in r)({}).hasOwnProperty.call(r,a)&&(e[a]=r[a])}return e}).apply(null,arguments)}let k=e=>p.createElement("svg",y({xmlns:"http://www.w3.org/2000/svg",width:16,height:16,fill:"none",viewBox:"0 0 16 16"},e),n||(n=p.createElement("path",{stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.6,d:"M2.5 8h10M9 4.5 12.5 8 9 11.5"})));var P=r(22852),j=r.n(P);let S=({offer:e,onClick:t})=>
3{let{title:r,description:a,tagText:s,offerType:n,logo:l,logoBackgroundColour:o,logoTintColour:i,backgroundImage:d,partnerName:u,ctaUrl:m,ctaOpenInNewTab:p}=e;return(0,c.jsxs)("a",{className:j().card,href:m||"#",target:p?"_blank":void 0,rel:p?"noopener noreferrer":void 0,onClick:t,"data-sentry-component":"PartnerOfferCard","data-sentry-source-file":"index.tsx",children:[d?.url?(0,c.jsx)(v.A,{className:j().backgroundImage,dataSrc:d.url,alt:d.alt||u}):(0,c.jsx)("div",{className:j().logoPanel,style:o?{backgroundColor:o}:{},children:l?.url&&(i?(0,c.jsx)("span",{className:j().logoTinted,style:{"--logo-src":l?.url?`url("${l.url}")`:void 0,"--logo-tint":i,"--logo-aspect":l?.width&&l?.height?`${l.width} / ${l.height}`:void 0},role:"img","aria-label":l.alt||u}):(0,c.jsx)(v.A,{className:j().logo,dataSrc:l.url,alt:l.alt||u}))}),(0,c.jsxs)("div",{className:j().body,children:[s?(0,c.jsxs)("p",{className:j().tag,children:["discount"===n?(0,c.jsx)(_,{className:j().tagIcon,"aria-hidden":!0}):null,(0,c.jsx)("span",{children:s})]}):null,(0,c.jsx)("h3",{className:j().title,children:r}),a?(0,c.jsx)("p",{className:j().description,children:a}):null,(0,c.jsxs)("span",{className:j().cta,children:["Find out more",(0,c.jsx)(k,{className:j().arrow,"aria-hidden":!0,"data-sentry-element":"ArrowIcon","data-sentry-source-file":"index.tsx"})]})]})]})};var N=r(75536),C=r(76996),L=r(93954),E=r(84949);function I(){return(I=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var a in r)({}).hasOwnProperty.call(r,a)&&(e[a]=r[a])}return e}).apply(null,arguments)}let B=e=>p.createElement("svg",I({xmlns:"http://www.w3.org/2000/svg",width:16,height:16,fill:"none",viewBox:"0 0 16 16"},e),l||(l=p.createElement("path",{stroke:"currentColor",strokeLinejoin:"round",strokeWidth:1.3,d:"m8 1.8 1.76 3.57 3.94.57-2.85 2.78.67 3.92L8 10.96l-3.52 1.85.67-3.92L2.3 6.11l3.94-.57z"})));function O(){return(O=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var a in r)({}).hasOwnProperty.call(r,a)&&(e[a]=r[a])}return e}).apply(null,arguments)}let A=e=>p.createElement("svg",O({xmlns:"http://www.w3.org/2000/svg",width:18,height:18,fill:"none",viewBox:"0 0 18 18"},e),o||(o=p.createElement("path",{stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.6,d:"m6.75 4.5 4.5 4.5-4.5 4.5"})));function T(){return(T=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var a in r)({}).hasOwnProperty.call(r,a)&&(e[a]=r[a])}return e}).apply(null,arguments)}let W=e=>p.createElement("svg",T({xmlns:"http://www.w3.org/2000/svg",width:20,height:20,fill:"none",viewBox:"0 0 20 20"},e),i||(i=p.createElement("path",{stroke:"currentColor",strokeLinecap:"round",strokeWidth:1.6,d:"M3 5h9m-9 5h6m-6 5h3"})),d||(d=p.createElement("path",{stroke:"currentColor",strokeLinecap:"round",strokeLinejoin:"round",strokeWidth:1.6,d:"M15 4v9m0 0 2.2-2.2M15 13l-2.2-2.2"})));var M=r(76850),$=r.n(M);let F=[{value:"featured",label:"Featured"},{value:"az",label:"AâZ"}],U=({viewModel:e})=>{let{relativeUrl:t,offers:r,categories:a}=e;(0,L.u)(()=>void(0,E.$)("Visit Student Perks Page"));let[s,n]=(0,p.useState)("all"),[l,o]=(0,p.useState)("featured"),i=(0,p.useRef)(null),{showPrev:d,showNext:u}=(0,C.A)(i),[m,g]=(0,p.useState)(!1),v=()=>g(!1),{componentRef:w,handleBlur:_}=(0,N.A)({callback:v,isOpen:m}),y=e=>i.current?.scrollBy({left:240*e,behavior:"smooth"}),k=e=>{n(e.slug),(({category:e})=>{(0,E.$)("Filter Student Perks",{Category:e})})({category:e.name})},P=[{title:"Home",href:"/",position:(0,b.p)(1)},{title:"Student perks",href:t,position:(0,b.p)(2)}],j=(0,p.useMemo)(()=>{let e="all"===s?r:r.filter(e=>e.category?.slug===s);return"az"===l?[...e].sort((e,t)=>e.title.localeCompare(t.title)):e},[r,s,l]),I="all"===s?"All perks":a.find(e=>e.slug===s)?.name||"Perks",O=j.length;return(0,c.jsxs)(h.A,{metaData:{relativeUrl:t,title:"Student perks â exclusive offers from our trusted partners",description:"Explore exclusive offers and benefits from our trusted partners â bills, guarantors, moving, food and more, all in one place.",robots:"index, follow"},mainClassName:$().main,"data-sentry-element":"Layout","data-sentry-component":"StudentPerksPage","data-sentry-source-file":"index.tsx",children:[(0,c.jsx)("section",{className:$().intro,children:(0,c.jsxs)("div",{className:$().inner,children:[(0,c.jsx)(x.A,{breadcrumbData:P,className:$().breadcrumb,"data-sentry-element":"Breadcrumb","data-sentry-source-file":"index.tsx"}),(0,c.jsxs)("div",{className:$().introText,children:[(0,c.jsx)("h1",{className:$().heading,children:"Student perks"}),(0,c.jsx)("p",{className:$().subtitle,children:"Explore exclusive offers and benefits from our trusted partners"})]}),(0,c.jsx)("div",{className:$().illustration,"aria-hidden":"true",children:(0,c.jsx)("img",{className:$().illustrationImg,src:"/media/student-perks-discount-tag.png",alt:""})})]})}),a.length>0?(0,c.jsx)("section",{className:$().filterBar,"aria-label":"Filter perks by category",children:(0,c.jsx)("div",{className:$().inner,children:(0,c.jsxs)("div",{className:$().pillsWrap,children:[(0,c.jsxs)("div",{className:$().pills,ref:i,children:[(0,c.jsx)("button",{type:"button","aria-pressed":"all"===s,className:f()($().pill,{[$().pillActive]:"all"===s}),onClick:()=>k({slug:"all",name:"All"}),children:"All"}),a.map(e=>{let t=s===e.slug;return(0,c.jsxs)("button",{type:"button","aria-pressed":t,className:f()($().pill,{[$().pillActive]:t}),onClick:()=>k(e),children:[(0,c.jsx)(B,{"aria-hidden":!0}),(0,c.jsx)("span",{children:e.name})]},e.slug)})]}),d?(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)("div",{className:$().pillsFadeLeft,"aria-hidden":"true"}),(0,c.jsx)("button",{type:"button",className:$().pillsScrollPrev,"aria-label":"Show previous categories",onClick:()=>y(-1),children:(0,c.jsx)("span",{className:$().flip,children:(0,c.jsx)(A,{"aria-hidden":!0})})})]}):null,u?(0,c.jsxs)(c.Fragment,{children:[(0,c.jsx)("div",{className:$().pillsFadeRight,"aria-hidden":"true"}),(0,c.jsx)("button",{type:"button",className:$().pillsScrollNext,"aria-label":"Show more categories",onClick:()=>y(1),children:(0,c.jsx)(A,{"aria-hidden":!0})})]}):null]})})}):null,(0,c.jsx)("section",{className:$().results,children:(0,c.jsxs)("div",{className:$().inner,children:[(0,c.jsxs)("div",{className:$().resultsHeader,children:[(0,c.jsxs)("div",{className:$().resultsHeading,children:[(0,c.jsx)("h2",{className:$().resultsTitle,children:I}),(0,c.jsxs)("p",{className:$().resultsCount,children:[O," ",1===O?"result":"results","all"===s?" available":" based on your filter"]})]}),(0,c.jsxs)("div",{className:$().sort,ref:w,children:[(0,c.jsxs)("button",{type:"button",className:$().sortButton,"aria-haspopup":"true","aria-controls":"perks-sort-menu","aria-expanded":m,onClick:()=>g(e=>!e),onBlur:_,children:[(0,c.jsx)(W,{"aria-hidden":!0,"data-sentry-element":"SortIcon","data-sentry-source-file":"index.tsx"}
3),(0,c.jsx)("span",{className:$().sortLabel,children:"Sort"})]}),(0,c.jsx)("ul",{className:f()($().sortMenu,{[$().sortMenuOpen]:m}),id:"perks-sort-menu",role:"radiogroup","aria-label":"Sort perks by",onBlur:_,children:F.map(e=>(0,c.jsxs)("li",{role:"none",children:[(0,c.jsx)("input",{className:$().sortInput,id:`perks-sort-${e.value}`,name:"perksSort",value:e.value,type:"radio",checked:l===e.value,"aria-label":`Sort by ${e.label}`,onChange:()=>{o(e.value),(({sortBy:e})=>{(0,E.$)("Sort Student Perks",{"Sort By":e})})({sortBy:e.label}),v()}}),(0,c.jsx)("label",{className:$().sortOption,htmlFor:`perks-sort-${e.value}`,children:e.label})]},e.value))})]})]}),O>0?(0,c.jsx)("div",{className:$().grid,id:"perks-grid",children:j.map(e=>(0,c.jsx)(S,{offer:e,onClick:()=>(({partner:e,offer:t,category:r})=>{(0,E.$)("Click Student Perk Offer",{Partner:e,Offer:t,Category:r})})({partner:e.partnerName,offer:e.title,category:e.category?.name||"Uncategorised"})},e.id))}):(0,c.jsx)("p",{className:$().empty,children:"No perks match this filter just yet."})]})})]})};var D=r(18334),R=r(5149),z=r(49088),H=r(93784),G=r(85116),q=r(28754);let Q={students:"students",landlords:"landlords"},V=Object.values(Q),X=e=>V.includes(e);var Z=r(56611);(0,G.UG)(` 4 query GetPartnerOffers($first: Int = 100) { 5 partnerOffers( 6 first: $first 7 where: { status: PUBLISH, orderby: { field: DATE, order: DESC } } 8 ) { 9 nodes { 10 databaseId 11 title 12 offerType 13 tagText 14 description 15 ctaUrl 16 ctaOpenInNewTab 17 audience 18 partnerCategories: partnercategories { 19 nodes { 20 name 21 slug 22 parent { 23 node { 24 name 25 slug 26 } 27 } 28 } 29 } 30 partner { 31 node { 32 title 33 websiteUrl 34 logoBackgroundColour 35 offerLogoColour 36 logo { 37 node { 38 sourceUrl 39 altText 40 mediaDetails { 41 width 42 height 43 } 44 } 45 } 46 offerBackgroundImage { 47 node { 48 sourceUrl 49 altText 50 } 51 } 52 partnerCategories: partnercategories { 53 nodes { 54 name 55 slug 56 parent { 57 node { 58 name 59 slug 60 } 61 } 62 } 63 } 64 } 65 } 66 } 67 } 68 } 69`);let K=(0,R.y)(q.$$),J=e=>{let t=e.partner?.node??null,r=t?.logo?.node??null,a=t?.offerBackgroundImage?.node??null;return{id:e.databaseId,title:e.title||"",offerType:"discount"===e.offerType?"discount":"partnerAdvertisement",tagText:e.tagText||"",description:(0,Z._)(e.description||""),ctaUrl:e.ctaUrl||t?.websiteUrl||"",ctaOpenInNewTab:!!e.ctaOpenInNewTab,logo:r?{url:r.sourceUrl||"",alt:r.altText||t?.title||"",width:r.mediaDetails?.width??null,height:r.mediaDetails?.height??null}:null,logoBackgroundColour:t?.logoBackgroundColour||"",logoTintColour:t?.offerLogoColour||"",backgroundImage:a?{url:a.sourceUrl||"",alt:a.altText||t?.title||"",width:null,height:null}:null,partnerName:t?.title||"",category:((...e)=>{for(let t of e){let e=t?.nodes?.[0];if(e)return{name:e.name||"",slug:e.slug||"",familyName:e.parent?.node?.name||"",familySlug:e.parent?.node?.slug||""}}return null})(e.partnerCategories,t?.partnerCategories),audience:(e.audience||[]).filter(X)}},Y=e=>!!e.title,ee=async(e=!1)=>{try{let t,r=await (0,z.Fv)(K,void 0,e?{cache:"no-store",headers:{"Cache-Control":"no-cache"}}:void 0,e?{cacheBust:!0}:void 0);if(!r.success)return console.error("[partnerOffersWpApi] GraphQL error:",r.error),{success:!1,error:r.error,offers:null};let a=r.data?.errors;if(Array.isArray(a)&&a.length>0)return D.wd("GraphQL error fetching partner offers",{level:"warning",tags:{service:"wordpress",endpoint:"GetPartnerOffers"},extra:{errors:a}}),{success:!1,error:new H.h("GraphQL error fetching partner offers",502),offers:null};return{success:!0,offers:(t=r.data?.data,(t.partnerOffers?.nodes||[]).filter(e=>!!e).filter(Y).map(J)),error:void 0}}catch(e){return{success:!1,error:e,offers:null}}};var et=r(99474);let er=e=>{let t,r;return t=e.audience,r=Q.students,t.includes(r)},ea=e=>({isError:!0,relativeUrl:e,offers:[],categories:[]}),es=async({country:e,relativeUrl:t,noCache:r})=>{let a=`partner-offers-${e}`.toLowerCase(),s=async()=>{try{let e,a,s=await ee(r);if(!s.success)return ea(t);let n=s.offers.filter(er);
69return e=new Map,n.forEach(t=>{let{category:r}=t;if(!r?.slug)return;let a=e.get(r.slug);a?a.count+=1:e.set(r.slug,{slug:r.slug,name:r.name,count:1})}),a=Array.from(e.values()).sort((e,t)=>e.name.localeCompare(t.name)),{isError:!1,relativeUrl:t,offers:n,categories:a}}catch(e){return console.error("[StudentPerks buildViewModel] failed:",e),ea(t)}};return r?s():(0,et.rw)(a,s,1800)};var en=r(29627),el=!0;async function eo({query:e}){if("production"===m.A.runtimeEnvironment)return{notFound:!0};let t="/student-perks",r=e?.noCache==="true",{country:a}=(0,u.UW)({country:e?.country});return{props:{viewModel:await es({country:a,relativeUrl:t,noCache:r}),relativeUrl:t}}}let ei=({viewModel:e,relativeUrl:t})=>e.isError?(0,c.jsx)(en.A,{relativeUrl:t}):(0,c.jsx)(U,{viewModel:e,"data-sentry-element":"StudentPerksPage","data-sentry-component":"StudentPerksRoute","data-sentry-source-file":"student-perks.tsx"})},56611:(e,t,r)=>{"use strict";r.d(t,{_:()=>s});var a=r(27938);let s=e=>(0,a.j)(e.replace(/<[^>]*>/g," ")).replace(/\s+/g," ").trim()},65546:(e,t,r)=>{"use strict";let a=r(45972);r.g.nodeCache||(r.g.nodeCache=new a),e.exports={cache:r.g.nodeCache}},69411:(e,t,r)=>{"use strict";function a(e,t){let r,a,s=(...s)=>{a=s,r&&clearTimeout(r),r=setTimeout(()=>{r=void 0,e(...a)},t)};return s.cancel=()=>{r&&clearTimeout(r),r=void 0,a=void 0},s}r.d(t,{s:()=>a})},70862:e=>{e.exports={header:"Layout__header--35b95",siteMain:"Layout__siteMain--88b24",siteMainFullBleed:"Layout__siteMainFullBleed--d8a28",siteWrapper:"Layout__siteWrapper--aa4d3"}},75536:(e,t,r)=>{"use strict";r.d(t,{A:()=>n});var a=r(14232),s=r(87541);let n=({callback:e,outsideClickAllowedElementId:t,isOpen:r})=>{let n=(0,a.useRef)(null),l=()=>s.A&&t?window.document.getElementById(t):null,o=t=>{("Escape"===t.code||27===t.keyCode)&&e()},i=t=>{let r=l(),a=n.current&&!n.current.contains(t.target),s=!!r&&r.contains(t.target);a&&!s&&e()};return(0,a.useEffect)(()=>(window.addEventListener("keydown",o),window.addEventListener("mousedown",i),window.addEventListener("touchstart",i),()=>{window.removeEventListener("keydown",o),window.removeEventListener("mousedown",i),window.removeEventListener("touchstart",i)}),[r,t,e]),{componentRef:n,handleBlur:t=>{let r=l(),a=n.current&&!n.current.contains(t.relatedTarget)&&null!==t.relatedTarget,s=!!r&&r.contains(t.relatedTarget)&&null!==t.relatedTarget;a&&!s&&e()}}}},76603:(e,t,r)=>{"use strict";r.d(t,{A:()=>N});var a,s,n,l=r(37876),o=r(14232),i=r(15039),d=r.n(i),c=r(69411);let u={breakpoints:{mobile:{width:480,itemsBeforeCollapse:0},desktop:{width:1/0,itemsBeforeCollapse:1}}},m={itemProp:"name"},p={itemProp:"itemListElement",itemScope:!0,itemType:"https://schema.org/ListItem"},g=e=>{let t=e.slice(0,e.length-1),r=e[e.length-1];return(t.map(e=>e.title).join("").length+Math.ceil(r.title.length/3))*12+35*t.length};var f=r(75536),h=r(48230),x=r.n(h);function b(){return(b=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var a in r)({}).hasOwnProperty.call(r,a)&&(e[a]=r[a])}return e}).apply(null,arguments)}let v=e=>o.createElement("svg",b({xmlns:"http://www.w3.org/2000/svg",width:24,height:24,fill:"none",viewBox:"0 0 24 24"},e),a||(a=o.createElement("circle",{cx:5,cy:12,r:1.75,fill:"currentColor"})),s||(s=o.createElement("circle",{cx:12,cy:12,r:1.75,fill:"currentColor"})),n||(n=o.createElement("circle",{cx:19,cy:12,r:1.75,fill:"currentColor"})));var w=r(31007),_=r.n(w);let y=({listItemClassName:e,componentClassName:t,item:r})=>(0,l.jsxs)("li",{className:e,...p,"data-sentry-component":"LinkItem","data-sentry-source-file":"Components.tsx",children:[(0,l.jsx)(x(),{className:t,href:r.href,scroll:!0,...{itemScope:!0,itemType:"https://schema.org/WebPage",itemProp:"item",itemID:r.href},"data-sentry-element":"Link","data-sentry-source-file":"Components.tsx",children:(0,l.jsx)("span",{...m,children:r.title})}),(0,l.jsx)("meta",{itemProp:"position",content:`${r.position}`,"data-sentry-element":"meta","data-sentry-source-file":"Components.tsx"})]}),k=({listItemClassName:e,componentClassName:t,item:r})=>(0,l.jsx)("li",{className:e,"data-sentry-component":"PlainTextItem","data-sentry-source-file":"Components.tsx",children:(0,l.jsx)("span",{className:t,children:r.title})}),P=({listItemClassName:e,componentClassName:t,item:r})=>(0,l.jsxs)("li",{className:e,...p,"data-sentry-component":"LastItem","data-sentry-source-file":"Components.tsx",children:[(0,l.jsx)("p",{className:t,children:(0,l.jsx)("span",{...m,children:r.title})}),(0,l.jsx)("meta",{itemProp:"position",content:`${r.position}`,"data-sentry-element":"meta","data-sentry-source-file":"Components.tsx"})]}),j=({breadcrumbData:e,item:t})=>null===t.href?(0,l.jsx)(k,{item:t,listItemClassName:_().listItem,componentClassName:_().lastListItem}):e.length===t.position?(0,l.jsx)(P,{item:t,listItemClassName:_().listItem,componentClassName:_().lastListItem,"data-sentry-element":"LastItem","data-sentry-component":"Item","data-sentry-source-file":"Components.tsx"}):(0,l.jsx)(y,{item:t,listItemClassName:_().listItem,componentClassName:_().listLink,"data-sentry-element":"LinkItem","data-sentry-component":"Item","data-sentry-source-file":"Components.tsx"}),S=(0,o.forwardRef)(({dropdownItems:e,dropdownId:t,isDropdownOpen:r,handleClick:a},s)=>(0,l.jsxs)("li",{className:d()(_().listItem,_().listItemDropdown),children:[(0,l.jsxs)("button",{onClick:a,className:d()(_().dropdownButton,{[_().active]:r}),"aria-haspopup":"true","aria-expanded":r,"aria-controls":t,children:[(0,l.jsx)(v,{className:_().dropdownIcon}),(0,l.jsx)("span",{className:_().visuallyHidden,children:"Breadcrumb dropdown"})]}),(0,l.jsx)("ol",{ref:s,className:d()(_().dropdownWrapper,{[_().active]:r}),id:t,"aria-hidden":!r,children:e.map(e=>(0,l.jsx)(y,{componentClassName:_().dropdownLink,item:e},e.position))})]})),N=({breadcrumbData:e,className:t,settings:r=u})=>{let[a,s]=(0,o.useState)(!1),[n,i]=(0,o.useState)([]),[m,p]=(0,o.useState)(e),[h,x]=(0,o.useState)([]),[b,v]=(0,o.useState)(!1),w=(0,o.useRef)(null),{componentRef:y}=(0,f.A)({callback:()=>v(!1),isOpen:b});return(0,o.useEffect)(()=>{let t=()=>{if(!w.current)return;a||s(!0);let{visibleItemsBeforeDropdown:t,visibleItemsAfterDropdown:n,dropdownItems:l}=((e,t,r,a)=>{let s=[],n=[...t],l=[],o=g(t);if(o<=a||0===a)return{visibleItemsBeforeDropdown:s,visibleItemsAfterDropdown:n,dropdownItems:l};let{itemsBeforeCollapse:i}=((e,t)=>{let r=u.breakpoints.desktop;for(let a in e.breakpoints){let s=e.breakpoints[a];if(t<=s.width){r=s;break}}return r})(e,r);for(i>0&&(s=n.slice(0,i),n=n.slice(i,n.length));o>a&&n.length>1;){let e=n.shift();l.push(e),o=g([...s,...n])}return{visibleItemsBeforeDropdown:s,visibleItemsAfterDropdown:n,dropdownItems:l}})(r,e,window.innerWidth,w.current.offsetWidth);i(t),p(n),x(l)};t();let n=(0,c.s)(t,100);
69return window.addEventListener("resize",n),()=>{window.removeEventListener("resize",n),n.cancel()}},[e,r]),(0,l.jsx)("nav",{"aria-label":"Breadcrumb",className:d()(_().breadcrumbWrapper,{[_().breadcrumbWrapperWithBreadcrumbsRendered]:a},t),"data-sentry-component":"Breadcrumb","data-sentry-source-file":"index.tsx",children:(0,l.jsxs)("ol",{ref:w,className:_().list,itemScope:!0,itemType:"https://schema.org/BreadcrumbList",children:[n.map(t=>(0,l.jsx)(j,{breadcrumbData:e,item:t},t.position)),h.length>0?(0,l.jsx)(S,{dropdownId:"drop-down-list",ref:y,dropdownItems:h,isDropdownOpen:b,handleClick:()=>{v(e=>!e)}}):null,m.map(t=>(0,l.jsx)(j,{breadcrumbData:e,item:t},t.position))]})})}},76850:e=>{e.exports={main:"StudentPerksPage__main--68f14",inner:"StudentPerksPage__inner--e0124",intro:"StudentPerksPage__intro--ee4f4",breadcrumb:"StudentPerksPage__breadcrumb--cab62",introText:"StudentPerksPage__introText--cbebe",heading:"StudentPerksPage__heading--f664c",subtitle:"StudentPerksPage__subtitle--e76a6",illustration:"StudentPerksPage__illustration--24094",illustrationImg:"StudentPerksPage__illustrationImg--64a08",filterBar:"StudentPerksPage__filterBar--bd8a3",pillsWrap:"StudentPerksPage__pillsWrap--acb56",pills:"StudentPerksPage__pills--dc30e",pillsFadeLeft:"StudentPerksPage__pillsFadeLeft--4dab4",pillsFadeRight:"StudentPerksPage__pillsFadeRight--1420d",pillsScrollNext:"StudentPerksPage__pillsScrollNext--0a0f7",pillsScrollPrev:"StudentPerksPage__pillsScrollPrev--7d0c4",flip:"StudentPerksPage__flip--534b6",pill:"StudentPerksPage__pill--23db6",pillActive:"StudentPerksPage__pillActive--8d796",results:"StudentPerksPage__results--71352",resultsHeader:"StudentPerksPage__resultsHeader--a3fcf",resultsHeading:"StudentPerksPage__resultsHeading--d0bda",resultsTitle:"StudentPerksPage__resultsTitle--90257",resultsCount:"StudentPerksPage__resultsCount--0a124",sort:"StudentPerksPage__sort--fb148",sortButton:"StudentPerksPage__sortButton--557cf",sortLabel:"StudentPerksPage__sortLabel--6b9ef",sortMenu:"StudentPerksPage__sortMenu--f6878",sortMenuOpen:"StudentPerksPage__sortMenuOpen--315f6",sortInput:"StudentPerksPage__sortInput--4254f",sortOption:"StudentPerksPage__sortOption--adbb3",grid:"StudentPerksPage__grid--50cb7",empty:"StudentPerksPage__empty--0817b"}},76996:(e,t,r)=>{"use strict";r.d(t,{A:()=>s});var a=r(14232);let s=e=>{let[t,r]=(0,a.useState)(!1),[s,n]=(0,a.useState)(!1);return(0,a.useEffect)(()=>{let t,a=e.current;if(!a)return;let s=!1,l=()=>{let e=a.scrollWidth-a.clientWidth,t=e>1;r(t&&a.scrollLeft>1),n(t&&a.scrollLeft<e-1)},o=(t=!1,(...e)=>{t||(t=!0,requestAnimationFrame(()=>{t=!1,l(...e)}))}),i=requestAnimationFrame(l),d="u">typeof ResizeObserver?new ResizeObserver(l):null;return d?.observe(a),a.addEventListener("scroll",o,{passive:!0}),window.addEventListener("resize",l),document.fonts?.ready.then(()=>{s||l()}),()=>{s=!0,cancelAnimationFrame(i),d?.disconnect(),a.removeEventListener("scroll",o),window.removeEventListener("resize",l)}},[e]),{showPrev:t,showNext:s}}},79867:(e,t,r)=>{"use strict";r.d(t,{A:()=>h});var a=r(37876),s=r(15039),n=r.n(s),l=r(57078),o=r(17082),i=r.n(o),d=r(519),c=r(50796),u=r(35543),m=r(28463),p=r(10164),g=r(70862),f=r.n(g);let h=({children:e,aboveHeader:t,belowHeader:r,headerClassName:s,mainClassName:o,wrapperClassName:g,footerClassName:h,footerVariant:x,headerProps:b={},metaData:v,fullBleed:w=!1,hideFooter:_=!1,dataTestId:y})=>{let k=n()(f().header,s),P=n()(w?f().siteMainFullBleed:f().siteMain,o),j=n()(f().siteWrapper,g);return(0,a.jsxs)(a.Fragment,{children:[(0,a.jsx)(c.A,{title:v.title,description:v.description,imageUrl:v.imageUrl,absoluteUrl:v.absoluteUrl??`${l.A.baseUrl}${v.relativeUrl??""}`,ogContentType:v.ogContentType,robots:v.robots,canonical:v.canonical,hreflangLinks:v.hreflangLinks,"data-sentry-element":"MetaTags","data-sentry-source-file":"index.tsx",children:v.children}),t,(0,a.jsx)(m.A,{...b,className:k,"data-sentry-element":"Header","data-sentry-source-file":"index.tsx"}),r,(0,a.jsx)("main",{className:P,children:w?e:(0,a.jsx)("div",{className:j,children:e})}),!_&&(0,a.jsx)(i(),{className:h,variant:x,useCountryContext:u.$D,project:d.Project.FE_WEBSITE,LinkComponent:p.A,studentBlogsLink:u.IZ,studentGuidesLink:u.Kd})]})}},84949:(e,t,r)=>{"use strict";r.d(t,{$:()=>s});var a=r(87541);let s=(e,t={})=>{void 0!==window.mixpanel&&mixpanel.track(e,t),a.A&&"www.accommodationforstudents.c
69om"!==window.location.hostname&&console.log(t,e)}},88696:(e,t,r)=>{(window.__NEXT_P=window.__NEXT_P||[]).push(["/student-perks",function(){return r(55556)}])},93954:(e,t,r)=>{"use strict";r.d(t,{u:()=>n});var a=r(14232),s=r(92875);let n=e=>{let{isMixpanelAvailable:t}=(0,s.A)();(0,a.useEffect)(()=>{t&&e()},[t])}},99474:(e,t,r)=>{"use strict";r.d(t,{Si:()=>i,rw:()=>l});var a=r(65546),s=r(87541);let n=600,l=async(e,t,r=n)=>{let l,o,i=a.cache.get(e);if(void 0!==i)return Promise.resolve(i);if(void 0===(i=await t())||"object"==typeof i&&i.isError)return i;a.cache.set(e,i,r);let d=(o=(l=new Date).toISOString(),l.setTime(l.getTime()+1e3*r),{start:o,expiry:l.toISOString()});return s.A||console.log(`${d.start}: ${e} not found in cache, now set until ${d.expiry}`),i},o=new Map,i=(e,t,r=n)=>{let a=o.get(e);if(a)return a;let s=l(e,t,r).finally(()=>{o.delete(e)});return o.set(e,s),s}}},e=>{e.O(0,[85607,83806,94498,45972,99962,85116,90636,46593,38792],()=>e(e.s=88696)),_N_E=e.O()}]); 70//# debugId=36d77d7c-257e-55a9-8a8c-f73bdfedf48e
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.