PageSourceSearch

https://www.canvas-world.com/_next/static/chunks/2174-9443691733a019b9.js?dpl=dpl_DiFDNtPrVXcVpbqPBRZm44pbDs4h

js canvas-world.com collected 2026-10-04 12:38:28 UTC 70,881 bytes, 1 lines download raw bytes

1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[2174],{168:(e,a,t)=>{t.d(a,{j:()=>r});var l,r=((l={}).AvailableFrom="availableFrom",l.MoveInDate="moveInDate",l.Room="room",l.Floor="floor",l.Price="price",l.RoomFeatures="roomFeatures",l.SharingOption="sharingOption",l.SharingOptionForm="sharingOptionForm",l.Size="size",l)},3501:(e,a,t)=>{function l(e,a,t=!1){if(e<0)throw Error("Price cannot be negative");if(!t&&(a<0||a>100))return e;let r=t?a:e*a/100;return e>r&&r>0?Number(e-r):Number(e)}t.d(a,{$g:()=>r,Hl:()=>o,UN:()=>i,_M:()=>l});let r=(e,a)=>{if("number"==typeof e)return a?e.toFixed(a):Number.isInteger(e)?e.toString():e.toFixed(2);if(e&&!isNaN(Number(e))){let t=Number(e);return a?t.toFixed(a):Number.isInteger(t)?t.toString():t.toFixed(2)}return e},i=(e,a,t,l)=>{let i=r(e,l);return t?`${i}${a}`:`${a}${i}`},o=(e,a)=>e.toLocaleString("en-US",{minimumFractionDigits:a||2*(e%1!=0),maximumFractionDigits:a||2})},4780:(e,a,t)=>{function l(e){return(e??[]).map(e=>({label:e.fields?.label?.value||"",min:Number(e.fields?.minFloor?.value??0),max:Number(e.fields?.maxFloor?.value??0)})).filter(e=>""!==e.label&&e.max>0)}function r(e,a,t){let l=[],r=new Set;for(let t of e){let e=a.find(e=>t>=e.min&&t<=e.max);e&&!r.has(e.label)&&(r.add(e.label),l.push(e.label))}return{floorGroupLabels:l,searchFeatureLabels:l.map(e=>`${e} ${t}`)}}function i(e,a){if(!Number.isFinite(e))return null;let t=a.find(a=>e>=a.min&&e<=a.max);return t?t.label:null}t.d(a,{KO:()=>i,_W:()=>r,it:()=>l})},13157:(e,a,t)=>{function l(e){if(!e)return null;try{let a;if(e.startsWith("http://")||e.startsWith("https://"))return new URL(e);let t=(a="https://www.canvas-world.com".trim())?a.endsWith("/")?a.slice(0,-1):a:"http://localhost:3000";return new URL(e,`${t}/`)}catch{return null}}t.d(a,{D:()=>r,O:()=>l});let r=e=>{let a=e.replace(/[{}]/g,"");return/^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$/i.test(a)?a:/^[0-9a-f]{32}$/i.test(a)?`${a.substring(0,8)}-${a.substring(8,12)}-${a.substring(12,16)}-${a.substring(16,20)}-${a.substring(20)}`:e}},13746:(e,a,t)=>{t.d(a,{S:()=>c});
1var l=t(34146),r=t(93436),i=t(12115),o=t(28905);function n(e){if("string"==typeof e)return e;let a=new URLSearchParams;for(let[t,l]of Object.entries(e.query??{}))void 0!==l&&(Array.isArray(l)?l.forEach(e=>a.append(t,e)):a.append(t,l));let t=a.toString();return(e.pathname??"")+(t?`?${t}`:"")}function s(e){try{return new URL(n(e),window.location.href).pathname===window.location.pathname}catch{return!1}}function u(e){let a=e?.scroll;return"boolean"==typeof a?{scroll:a}:e?.shallow===!0?{scroll:!1}:void 0}function c(){let e=(0,l.useRouter)(),a=(0,l.usePathname)()??"",t=(0,l.useParams)(),c=(0,l.useSearchParams)(),d=c?.toString(),p=(0,i.useMemo)(()=>Object.fromEntries(c?.entries()??[]),[d]),f=(0,i.useMemo)(()=>d?`${a}?${d}`:a,[a,d]),m=(0,r.s9)(),_=m?.locale?.()||t?.locale,v=(0,i.useCallback)((a,t,l)=>(l?.client===!0&&s(a)?window.history.pushState(null,"",n(a)):((0,o.P5)(n(a)),e.push(n(a),u(l))),Promise.resolve()),[e]),b=(0,i.useCallback)((a,t,l)=>(l?.client===!0&&s(a)?window.history.replaceState(null,"",n(a)):((0,o.P5)(n(a)),e.replace(n(a),u(l))),Promise.resolve()),[e]),y=(0,i.useCallback)(()=>{(0,o.P5)(""),e.back()},[e]),g=(0,i.useCallback)(()=>{(0,o.P5)(""),e.forward()},[e]),h=(0,i.useCallback)(()=>e.refresh(),[e]),C=(0,i.useCallback)(a=>e.prefetch(a),[e]),I=o.bY;return(0,i.useMemo)(()=>({pathname:a,query:p,asPath:f,isReady:!0,locale:_,push:v,replace:b,back:y,forward:g,refresh:h,prefetch:C,events:I}),[a,p,f,_,v,b,y,g,h,C,I])}},28776:(e,a,t)=>{function l(e,a,t=!1){if(!e)return"";let r=e;return a.propertyid?r=r.replace("{propertyid}",a.propertyid):r.includes("{propertyid}")&&t&&(r=(r=r.replace("/property[id]","")).replace("/{propertyid}","")),a.myolepropertyid?r=r.replace("{myolepropertyid}",a.myolepropertyid):r.includes("{myolepropertyid}")&&t&&(r=(r=r.replace("/myOlePropertyId","")).replace("/{myolepropertyid}","")),a.gradeid?r=r.replace("{gradeid}",a.gradeid):r.includes("{gradeid}")&&t&&(r=(r=r.replace("/gradeid","")).replace("/{gradeid}","")),a.atid?r=r.replace("{atid}",a.atid):r.includes("{atid}")&&t&&(r=(r=r.replace("/atid","")).replace("/{atid}","")),a.floorplanid?r=r.replace("{floorplanid}",a.floorplanid):r.includes("{floorplanid}")&&t&&(r=(r=r.replace("/property_floorplan[id]","")).replace("/{floorplanid}","")),a.leasetermid?r=r.replace("{leasetermid}",a.leasetermid):r.includes("{leasetermid}")&&t&&(r=(r=r.replace("/lease_term_id","")).replace("/{leasetermid}","")),a.leasestartwindowid?r=r.replace("{leasestartwindowid}",a.leasestartwindowid):r.includes("{leasestartwindowid}")&&t&&(r=(r=r.replace("/lease_start_window_id","")).replace("/{leasestartwindowid}","")),a.spaceoptionid?r=r.replace("{spaceoptionid}",a.spaceoptionid):r.includes("{spaceoptionid}")&&t&&(r=(r=r.replace("/space_configuration_id","")).replace("/{spaceoptionid}","")),a.unitspaceid&&(r=r.replace("{unitspaceid}",a.unitspaceid)),""===a.unitspaceid&&t&&(r=(r=r.replace("/{unitspaceid}","")).replace("/unit_space[id]","")),a.lease_start_date&&""!==a.lease_start_date?r=r.replace(/%7Blease_start_date%7D|{lease_start_date}/gi,a.lease_start_date):r.match(/{lease_start_date}|%7Blease_start_date%7D/gi)&&t&&(r=i(r,"lease_start_date")),r}function r(e,a,t){if(!e)return e;let l=i(e,a);if(!t)return l;let r=l.includes("?")?"&":"?";return`${l}${r}${a}=${encodeURIComponent(t)}`}function i(e,a){if(!e||!a)return e;try{let t=new URL(e);return t.searchParams.delete(a),t.toString()}catch(i){let t=e.indexOf("?");if(-1===t)return e;let l=e.substring(0,t),r=e.substring(t+1).split("&").filter(e=>{let[t]=e.split("=");return t!==a});return r.length>0?`${l}?${r.join("&")}`:l}}t.d(a,{dG:()=>r,qm:()=>i,wA:()=>l})},28905:(e,a,t)=>{t.d(a,{K0:()=>c,P5:()=>s,bY:()=>n});var l=t(19749),r=t(34146),i=t(12115);let o={routeChangeStart:new Set,routeChangeComplete:new Set,routeChangeError:new Set},n={on(e,a){o[e]?.add(a)},off(e,a){o[e]?.delete(a)},emit(e,...a){o[e]?.forEach(e=>e(...a))}};function s(e){n.emit("routeChangeStart",e)}let u=null;function c(e){let a,t,o=(0,l.c)(5),s=void 0===e||e,c=(0,r.usePathname)(),d=(0,r.useSearchParams)();o[0]!==s||o[1]!==c||o[2]!==d?(a=()=>{if(!s)return;let e=`${c}?${d?.toString()??""}`;if(null===u){u=e;return}u!==e&&(u=e,n.emit("routeChangeComplete",e))},t=[c,d,s],o[0]=s,o[1]=c,o[2]=d,o[3]=a,o[4]=t):(a=o[3],t=o[4]),(0,i.useEffect)(a,t)}},41266:(e,a,t)=>{function l(e){return null!==e&&"object"==typeof e&&"results"in e&&Array.isArray(e.results)}function r(e){if(null==e||"object"!=typeof e)return e;if(Array.isArray(e))return e.map(e=>r(e));let a=e.fields;if(Array.isArray(a)&&a.every(e=>null!==e&&"object"==typeof e&&"name"in e&&"jsonValue"in e)){let t={};for(let a of Object.keys(e))"fields"!==a&&(t[a]=e[a]);for(let e of a)t[e.name]=function(e){if(Array.isArray(e))return{jsonValue:e};if(null!==e&&"object"==typeof e){let a=Object.keys(e);if(1===a.length&&"value"===a[0]){let a=e.value;if(null===a||"object"!=typeof a)return e}return{jsonValue:e}}return e}(e.jsonValue);return l(t.children)&&(t.children={...t.children,results:t.children.results.map(e=>r(e))}),t}let t={};for(let a of Object.keys(e))if("children"===a&&null!==e.children&&"object"==typeof e.children&&l(e.children)){let a=e.children.results;t.children={...e.children,results:a.map(e=>r(e))}}else t[a]=r(e[a]);return t}function i(e){return null==e?e:Array.isArray(e)?e.map(e=>r(e)):r(e)}t.d(a,{r:()=>i})},52671:(e,a,t)=>{t.d(a,{useIntegratedCard:()=>i});
1var l=t(12115),r=t(64716);let i=()=>{let e=(0,l.useContext)(r.IntegratedCardContext);if(!e)throw Error("useIntegratedCard must be used within an IntegratedCardProvider");return e}},59947:(e,a,t)=>{t.d(a,{DC:()=>m,J4:()=>d,MF:()=>c,N$:()=>n,Q0:()=>b,S4:()=>h,Tc:()=>g,b8:()=>r,eD:()=>f,hs:()=>u,m_:()=>v,sg:()=>p,uF:()=>_,xc:()=>y});var l=t(63977);let r=e=>{if(!e||!e.startsWith("/locations/"))return"NA";let a=e.split("/");return a.length<=2?"NA":a[2].split("-").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" ")},i=(e,a)=>{let t=e?.route??void 0,l=t?.fields?.selectProperty,r=l?.fields?.marketingName?.value;if(r)return r;if(a&&a.startsWith("/locations/")){let e=a.split("/").filter(e=>e)[2];if(e)return e.split("-").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" ")}return"NA"},o=e=>{if(!e||!e.startsWith("/locations/"))return"NA";let a=e.split("/").filter(e=>e);if(a.length>=4){let e=a[3];if(e)return e.split("-").map(e=>e.charAt(0).toUpperCase()+e.slice(1)).join(" ")}return"NA"},n=e=>{if(!e)return"NA";let a=e.split("/");if(a.length<=1)return"NA";let t=a[1];return t?t.charAt(0).toUpperCase()+t.slice(1):"NA"},s=e=>{if(!e)return"NA";let a=e.replace(/^\//,"").split("/");if(0===a.length||!a[0])return"NA";let t=a[0];return t.charAt(0).toUpperCase()+t.slice(1)},u=({eventLabel:e,componentName:a,language:t="",itemPath:s="",router:u,publicUrl:c="",country:d,sitecoreContext:p,audienceType:f})=>{let m=d||r(s),_=i(p,s),v=f||n(s),b=r(s),y=o(s);return{event:l.bk.CLICK.TAB,event_category:l.bk.EVENT_CATEGORY.BODY_INTERACTION,event_action:l.bk.EVENT_ACTION.CLICK,event_label:e,audience_type:v,country:m,component_name:`${l.bk.CLICK.TAB}-${a}`,language:t||"",property_name:_,apartment_type:y,location:b,page:{path:s||"",url:u?`${c}${u.asPath}`:""}}},c=({language:e="",itemPath:a="",router:t,publicUrl:r="",location:o,property_name:s,stayLength:u,budgetPrice:c,roomType:d,apartmentType:p,sitecoreContext:f,audienceType:m,bookingType:_})=>{let v=s||i(f,a),b=m||n(a);return{event:l.bk.CLICK.SEARCH_CLICK,event_category:l.bk.EVENT_CATEGORY.CUSTOM_EVENT,event_action:l.bk.EVENT_ACTION.SUBMIT,event_label:l.bk.EVENT_LABEL.SEARCH,audience_type:b,language:e||"NA",location:o||"NA",stay_length:u||"NA",budget_price:c||"NA",room_type:d||"NA",apartment_type:p||"NA",property_name:v,booking_type:_||"NA",page:{path:a||"",url:t?`${r}${t.asPath}`:""}}},d=({language:e="",itemPath:a="",router:t,publicUrl:r="",sharedBathroom:o,roomType:s,sitecoreContext:u,audienceType:c})=>{let d=i(u,a),p=c||n(a);return{event:l.bk.CLICK.ADJUST_PREFERENCE_CLICK,event_category:l.bk.EVENT_CATEGORY.CUSTOM_EVENT,event_action:l.bk.EVENT_ACTION.SUBMIT,event_label:l.bk.EVENT_LABEL.PREFERENCES,audience_type:p,shared_bathroom:o||"NA",room_type:s||"NA",property_name:d,language:e||"NA",page:{path:a||"",url:t?`${r}${t.asPath}`:""}}},p=({eventLabel:e,sectionName:a,language:t="",itemPath:s="",router:u,publicUrl:c="",country:d,componentName:p,propertyName:f,audienceType:m,apartmentType:_,location:v,sitecoreContext:b,extraParams:y})=>{let g=i(b,s),h=d||r(s),C=m||n(s),I=v||r(s),S=_||o(s);return{event:l.bk.CLICK.CLICK_CTA,event_category:l.bk.EVENT_CATEGORY.BODY_INTERACTION,event_action:l.bk.EVENT_ACTION.CLICK,event_label:e,component_name:`${l.bk.CLICK.CLICK_CTA}-${p}`,section_name:a||"",audience_type:C,country:h,language:t||"",property_name:f||g,apartment_type:S,location:I,...y,page:{path:s||"",url:u?`${c}${u.asPath}`:""}}},f=({eventLabel:e,language:a="",itemPath:t="",router:r,publicUrl:i="",componentName:o})=>({event:l.bk.CLICK.WHATSAPP_CHAT,event_category:l.bk.EVENT_CATEGORY.BODY_INTERACTION,event_action:l.bk.EVENT_ACTION.CLICK,event_label:e,component_name:`${l.bk.CLICK.WHATSAPP_CHAT}-${o}`,language:a||"",page:{path:t||"",url:r?`${i}${r.asPath}`:""}}),m=({filters:e,country:a,componentName:t,language:r,path:i,url:o,propertyName:s,audienceType:u})=>{let c=u||n(i);return{event:l.bk.CLICK.FILTER_TAB,event_category:l.bk.EVENT_CATEGORY.BODY_INTERACTION,event_action:l.bk.EVENT_ACTION.CLICK,event_label:e.length?e:["NA"],component_name:`${l.bk.CLICK.FILTER_TAB}-${t}`,audience_type:c,country:a,language:r,property_name:s||"NA",page:{path:i,url:o}}},_=({eventLabel:e,language:a="",itemPath:t="",router:i,publicUrl:o="",country:s,audienceType:u,componentName:c})=>{let d=s||r(t),p=u||n(t);
1return{event:l.bk.CLICK.BLOG_LOCATION_SELECTOR,event_category:l.bk.EVENT_CATEGORY.BODY_INTERACTION,event_action:l.bk.EVENT_ACTION.CLICK,event_label:e,audience_type:p,component_name:`${l.bk.CLICK.BLOG_LOCATION_SELECTOR}-${c}`,country:d,language:a||"",page:{path:t||"",url:i?`${o}${i.asPath}`:""}}},v=({eventLabel:e,language:a="",itemPath:t="",router:i,publicUrl:o="",country:n,componentName:s})=>{let u=n||r(t);return{event:l.bk.CLICK.BLOG_CLICK,event_category:l.bk.EVENT_CATEGORY.BODY_INTERACTION,event_action:l.bk.EVENT_ACTION.CLICK,event_label:e,country:u,component_name:`${l.bk.CLICK.BLOG_CLICK}-${s}`,language:a||"",page:{path:t||"",url:i?`${o}${i.asPath}`:""}}},b=({eventLabel:e,language:a="",itemPath:t="",router:i,publicUrl:o="",country:n,subcountry:s,componentName:u,formId:c,propertyName:d,audience_field:p,lead_source:f,enquiries_type:m,stayLength:_,location:v,roomType:b,apartmentType:y,dynamicFields:g})=>{let h=n||r(t),C={event:l.bk.CLICK.SUBMIT_FORM,event_category:l.bk.EVENT_CATEGORY.CUSTOM_EVENT,event_action:l.bk.EVENT_ACTION.SUBMIT,event_label:e,country:h,subcountry:s||"NA",property_name:d||"NA",stay_length:_||"NA",location:v||"NA",room_type:b||"NA",apartment_type:y||"NA",component_name:u,audience_field:p||"NA",lead_source:f||"NA",enquiries_type:m||"NA",form_id:c,language:a||"",page:{path:t||"",url:i?`${o}${i.asPath}`:""}};return g&&"object"==typeof g?{...C,...g}:C},y=({eventLabel:e,language:a="",itemPath:t="",router:o,publicUrl:n="",country:u,menuCat1:c="NA",menuCat2:d="NA",menuCat3:p="NA",audienceType:f,destinationUrl:m,sitecoreContext:_})=>{let v=u||r(t),b=i(_,t),y=f||s(m);return{event:l.bk.CLICK.HEADER_CLICK,event_category:l.bk.EVENT_CATEGORY.HEADER_INTERACTION,event_action:l.bk.EVENT_ACTION.CLICK,event_label:e,country:v,menu_cat1:c,menu_cat2:d,menu_cat3:p,audience_type:y,property_name:b,language:a||"",page:{path:t||"",url:o?`${n}${o.asPath}`:""}}},g=({eventLabel:e,language:a="",itemPath:t="",router:o,publicUrl:n="",country:u,menuCat1:c="NA",menuCat2:d="NA",audienceType:p,destinationUrl:f,sitecoreContext:m})=>{let _=u||r(t),v=i(m,t),b=p||s(f);return{event:l.bk.CLICK.FOOTER_CLICK,event_category:l.bk.EVENT_CATEGORY.FOOTER_INTERACTION,event_action:l.bk.EVENT_ACTION.CLICK,event_label:e,audience_type:b,country:_,menu_cat1:c,menu_cat2:d,property_name:v,language:a||"",page:{path:t||"",url:o?`${n}${o.asPath}`:""}}},h=({eventLabel:e,router:a,componentName:t,budgetMatch:r,sitecoreContext:i})=>{let o=i?.language??"",n=i?.itemPath??"";return{event:l.bk.CLICK.AFFORDABILITY_CLICK,event_category:l.bk.EVENT_CATEGORY.CUSTOM_EVENT,event_action:l.bk.EVENT_ACTION.SUBMIT,event_label:e,component_name:`${l.bk.CLICK.AFFORDABILITY_CLICK}-${t}`,language:o||"",budget_match:r?"yes":"no",page:{path:n||"",url:a?`https://www.canvas-world.com${a.asPath}`:""}}}},63977:(e,a,t)=>{t.d(a,{B4:()=>v,EO:()=>f,Fd:()=>m,Gv:()=>n,Rr:()=>u,bk:()=>_,bu:()=>d,en:()=>y,eu:()=>r,jv:()=>s,mV:()=>c,r:()=>o,rA:()=>i,xj:()=>b,yF:()=>p});var l=t(66327);t(87358).env.NEXT_PUBLIC_MIDDLEWARE_ENDPOINT;let r={THEME:"greystar-selected-theme"},i={CanvasWorld:"",CanvasProfessional:"professional"},o={CanvasWorld:"student",CanvasProfessional:"professionals"},n=(0,l.UO)(o),s={SEARCH_CONTAINER:"search-container",PRE_REGISTRATION_FORM_CONTAINER:"pre-registration-form-container",INTEGRATED_CARD_NO_RESULT_CONTAINER:"integrated-card-no-result-container"},u={variants:{accordion:{default_accordion_variant:"Default",accordion_without_title_and_description:"AccordionWithoutTitleAndDescription"},ContentComponent:{default:"Default",tonalbg:"TonalBGContentComponent"},footer:{default:"Default",location_with_title_footer:"LocationWithTitleFooter"},propertyCards:{default:"Default",verticallyStackedCards:"VerticallyStackedCards"},CTAComponent:{default:"Default",ColoredCTAComponent:"ColoredCTAComponent"},amenities:{default:"Default",darkVariant:"DarkVariant"},iconGrid:{default:"Default",tonal:"TonalBGVariant"},ContentBanner:{default:"Default",darkVariant:"DarkVariant",searchVariant:"SearchVariant"},AnchorNavigation:{default:"Default",Locationbg:"Locationbg"}
1,Hero:{default:"Default",BackgroundVideoHero:"BackgroundVideoHero"}},integratedCard:{availabilityStatus:{available:"available",unavailable:"unavailable",upcoming:"NA"},API_DATA:{YARDI_BTR:"Yardi-BTR",YARDI_IQ:"Yardi-IQ",ENTRATA:"Entrata",STARREZ:"StarRez"}},forms:{recaptchaAction:{globalForm:"global_form_submit",contactForm:"contact_form_submit",formSubmit:"form_submit"}},modalIds:{Search:"Search",IC:"integrated-cards"},date_format:"dd.MM.yyyy",flexibleStaysPlaceholder:"flexibleStaysPlaceholder",priceFrequencies:{WEEK:"week",MONTH:"month"},loadingIds:{SEARCH_API_LOADING:"search-listing-api"}},c={AdjustPreferences:"AdjustPreferences",AllProperties:"AllProperties",ClearPreferences:"ClearPreferences",DollarLabel:"DollarLabel",PoundLabel:"PoundLabel",INRLabel:"INRLabel",ShowLabel:"ShowLabel",HideLabel:"HideLabel",PerWeek:"PerWeek",PriceFrom:"PriceFrom",PropertiesLabel:"PropertiesLabel",PropertyLabel:"PropertyLabel",WhatsnearbyLabel:"WhatsnearbyLabel",StayedAtLabel:"StayedAtLabel",AllInclusive:"AllInclusive",Features:"Features",SelectBudgetTitle:"SelectBudget",SelectPreferencesTitle:"SelectPreferences",BudgetLabel:"BudgetLabel",PreferencesLabel:"PreferencesLabel",ClearFilters:"ClearFilters",SoldOut:"SoldOut",SQMLabel:"SQMLabel",RentNow:"RentNow",NewMessage:"NewMessage",ComingSoon:"ComingSoonLabel",AllLabel:"AllLabel",ArticlesLabel:"ArticlesLabel",AllLocations:"AllLocations",ShowMoreLabel:"ShowMoreLabel",ShowMore:"ShowMore",ReadMore:"ReadMore",Save:"Save",AllCategories:"AllCategories",StudentToggle:"StudentToggle",ProfessionalToggle:"ProfessionalToggle",GoogleReviewsLabel:"GoogleReviewsLabel",Stars:"Stars",Reviews:"Reviews",Find:"Find",AvailableFrom
1:"AvailableFrom",AvailableLabel:"AvailableLabel",SharingLabel:"SharingLabel",SharingPreferenceLabel:"SharingPreferenceLabel",PrivateSharingLabel:"PrivateSharingLabel",AvailableNow:"AvailableNow",PerAnnum:"PerAnnum",PerMonth:"PerMonth",FloorLabel:"FloorLabel",SQFT:"SQFT",PriceRange:"PriceRange",Error406:"406",LeadSourceSelectPlaceholder:"LeadSourceSelectPlaceholder",SortByLabel:"SortBy",ResetResultLabel:"ResetResultLabel",From:"From",Label3D:"3DLabel",Floorplan:"Floorplan",SubmittingLabel:"SubmittingLabel",MinRead:"MinRead",PriceBreakdownLabel:"priceBreakdownLabel",NextLabel:"NextLabel",BackLabel:"BackLabel",SendLabel:"SendLabel",OfLabel:"OfLabel",FloorplanLabel:"FloorplanLabel",FloorplanDisclaimer:"FloorplanDisclaimer",GalleryLabel:"GalleryLabel",GalleryDisclaimer:"GalleryDisclaimer",VirtualTourLabel:"VirtualTourLabel",VirtualTourDisclaimer:"VirtualTourDisclaimer",VideoLabel:"VideoLabel",VideoDisclaimer:"VideoDisclaimer",SelectYourRoomLabel:"SelectYourRoomLabel",AvailabilityLabel:"AvailabilityLabel",SearchStudentTabLabel:"SearchStudentTabLabel",SearchProfessionalTabLabel:"SearchProfessionalTabLabel",SearchSelectCityLabel:"SearchSelectCityLabel",IntegratedCard_SelectBookingType:"IntegratedCard_SelectBookingType",IntegratedCard_StayingDurationTitle:"IntegratedCard_StayingDurationTitle",IntegratedCard_ChooseYourRoom:"IntegratedCard_ChooseYourRoom",ContentBanner_Modal3DLabel:"ContentBanner_Modal3DLabel",FaqSearch_ErrorMessage:"FaqSearch_ErrorMessage",Form_SubmitButtonLabel:"Form_SubmitButtonLabel",Highlight_ModalCtaText:"Highlight_ModalCtaText",RelatedBlog_Title:"RelatedBlog_Title",RoomFeatures:"RoomFeatures",RoomNumber:"RoomNumber",Price:"Price",SizeLabel:"SizeLabel",Floor:"Floor",UnderLabel:"UnderLabel",ShowPricePer:"ShowPricePer",WeekToggle:"WeekToggle",MonthToggle:"MonthToggle",TotalCost:"TotalCost",AllBillsIncludedNoHiddenCosts:"AllBillsIncludedNoHiddenCosts",ContinueBooking:"ContinueBooking",LengthOfStay:"LengthOfStay",PaymentOptions:"PaymentOptions",PreBookingFloorLabel:"Floor",PreBookingRoomLabel:"Room",TooltipMoveInDateTitle:"TooltipMoveInDateTitle",DesireMoveInDate:"DesireMoveInDate",MoveInValuePrefix:"MoveIn",MoveInDateTitle:"MoveInDateTitle",MoveInDatePlaceholder:"MoveInDatePlaceholder",DestinationAtMapTab:"DestinationAtMapTab",PostcodePlaceholderAtMapSearch:"PostcodePlaceholderAtMapSearch",JourneyDetails:"JourneyDetails",ContinueToAvailabilityLabel:"ContinueToAvailabilityLabel",Cancel:"Cancel",Minutes:"Minutes",Miles:"Miles",Kilometers:"Kilometers",CoveoSearch_Filter:"Coveo_Filter",CoveoSearch_ClearAll:"Coveo_ClearAll",CoveoSearch_SelectAll:"Coveo_SelectAll",CoveoSearch_Apply:"Coveo_Apply",CoveoSearch_LongStay:"Coveo_LongStay",CoveoSearch_ShortStay:"Coveo_ShortStay",CoveoSearch_StartYourSearch:"Coveo_StartYourSearch",CoveoSearch_SelectCityLabel:"Coveo_SelectCityLabel",CoveoSearch_FloorChipLabel:"Coveo_FloorChipLabel",CoveoSearch_SpecificMoveInDate:"Coveo_SpecificMoveInDate",CoveoSearch_FlexibleMoveInDate:"Coveo_FlexibleMoveInDate",CoveoSearch_MoveInApplySelection:"Coveo_MoveInApplySelection",CoveoSearch_MoveInHeading:"Coveo_MoveInHeading",CoveoSearch_MoveInHelperText:"Coveo_MoveInHelperText",CoveoSearch_SelectDate:"Coveo_SelectDate",CoveoSearch_MoveInClear:"Coveo_MoveInClear",CoveoSearch_LoadMore:"Coveo_LoadMore",CoveoSearch_LowResultsHeading:"Coveo_LowResultsHeading",CoveoSearch_LowResultsApplyFilters:"Coveo_LowResultsApplyFilters",GenderPrefMaleOnly:"GenderPrefMaleOnly",GenderPrefFemaleOnly:"GenderPrefFemaleOnly",GenderPrefDynamic:"GenderPrefDynamic",GenderPrefMix:"GenderPrefMix",GenderPrefNeutralOnly:"GenderPrefNeutralOnly"},d={MAX_YEAR:5,DEFAULT_DATE_FORMAT:"MM/dd/yyyy"},p={MAX_YEAR:5,DEFAULT_DATE_FORMAT:"dd/MM/yyyy"},f="0001-01-01T00:00:00Z",m={AES_KEY:"wo+ZEyI6QXnUciphMicoDbsEVpQY+4VvrjCWGBfvLFU="},_={CLICK:{TAB:"click_tab",MAP_TAB:"map_filter_click",WECHAT_CLICK:"wechat_click",FIND_LINK_CLICK:"find_link_click",BOOKING_SELECTION:"booking_selection",DATE_SELECTION:"date_selection",QUICK_LINKS:"quick_links",CLICK_CTA:"click_cta",AFFORDABILITY_CLICK:"affordability_click",WHATSAPP_CHAT:"whatsapp_chat",LIVE_CHAT:"live_chat",SUBMIT_FORM:"submit_form",FILTER_TAB:"filter_tab",BLOG_LOCATION_
1SELECTOR:"blog_location_selector",BLOG_CLICK:"blog_click",PROFESSION_TOGGLE:"profession_toggle",SEARCH_CLICK:"search_click",ADJUST_PREFERENCE_CLICK:"adjust_preferences",HEADER_CLICK:"header_click",FOOTER_CLICK:"footer_click"},EVENT_CATEGORY:{BODY_INTERACTION:"body_interaction",HEADER_INTERACTION:"header_interaction",FOOTER_INTERACTION:"footer_interaction",CUSTOM_EVENT:"custom_event"},EVENT_ACTION:{CLICK:"click",SUBMIT:"submit"},EVENT_LABEL:{SEARCH:"search popup",PREFERENCES:"preferences popup"},COMPONENT_NAME:{CONTACT_US_FORM:"Contact Us",BUILDING_SAFETY_ACT_FORM:"Building Safety Act",REFUND_FORM:"Refund",PRE_REGISTRATION_FORM:"Pre Registration",BEGIN_APPLICATION:"Begin Application"},FORM_NAME:{PRE_REGISTRATION:"Pre-registration"}},v={PERSONALIZATION_MODE_DATA_PATH:e=>"CanvasWorld"===e?"/sitecore/content/Greystar/Canvas/CanvasWorld/Data/Global Datasource/Personalization Mode":`/sitecore/content/Greystar/${e}/Data/Global Datasource/Personalization Mode`,PERSONALIZATION_MODE_DATA_NAME:"Personalization Mode",SELECT_MODE_LABEL:"Select Mode",WHERE_MODE_IS_LABEL:"Where mode is",EXCEPT_WHERE_MODE_IS_LABEL:"Except where mode is",PERSONALIZATION_PROPERTIES_DATA_PATH:e=>"CanvasWorld"===e?"/sitecore/Content/Greystar/Canvas/CanvasWorld/Data/PMS/Property":`/sitecore/Content/Greystar/${e||"CanvasWorld"}/Data/PMS/Property`,PERSONALIZATION_PROPERTIES_DATA_NAME:"Property",SELECT_PROPERTIES_LABEL:"Select Properties",WHERE_PROPERTIES_ARE_LABEL:"Where properties are",EXCEPT_WHERE_PROPERTIES_ARE_LABEL:"Except where properties are",WHERE_PROPERTIES_EXIST_LABEL:"Where properties are set",WHERE_PROPERTIES_EMPTY_LABEL:"Where no properties are set",PERSONALIZATION_PROPERTIES_QUERY_PARAM:"properties",PERSONALIZATION_PROPERTIES_TEMPLATE_ID:"{B11C8112-7359-46A2-9AF3-FE17B550C34A}"},b={TOTAL_AVAILABLE_FLOORPLANS:"totalAvailableFloorplans",SEARCH_LISTING_SELECTED_BUDGET_TITLES:"searchListingSelectedBudgetTitles"},y={fields:{template_type:"gs_template_type",property_id:"gs_property_id",property_name:"gs_property_name",language:"gs_language",payload:"gs_payload",category_id:"gs_category_id",category_sitecore_id:"gs_category_sitecore_id",room_option_ids:"gs_room_option_ids",room_option_labels:"gs_room_option_labels",unit_type_path:"gs_unit_type_path",unit_type_label_path:"gs_unit_type_label_path",unit_subtype_path:"gs_unit_subtype_path",unit_subtype_label_path:"gs_unit_subtype_label_path",preferences:"gs_preferences",price:"gs_price",is_available:"gs_is_available",offer_id:"gs_offer_id",has_offer:"gs_has_offer",floor_number:"gs_floor_number",floor_group:"gs_floor_group",university_ids:"gs_university_ids",lease_term_item_id:"gs_lease_term_item_id",global_lease_term_id:"gs_global_lease_term_id",global_lease_term_item_id:"gs_global_lease_term_item_id",global_lease_term_label:"gs_global_lease_term_label",lease_term_year_group:"gs_lease_term_year_group",lease_term_order:"gs_lease_term_order",earliest_available:"gs_earliest_available",unit_features:"gs_unit_features",unit_aspect:"gs_unit_aspect",unit_price:"gs_price",unit_original_price:"gs_unit_original_price",unit_discount:"gs_unit_discount",unit_available_date:"gs_unit_available_date",parent_floor_plan_id:"gs_parent_floor_plan_id"},templates:{FLOOR_PLAN_LT:"FloorPlanLT",LEASE_TERM:"LeaseTerm",CATEGORY:"Category"},facetKeyMap:{category:"categoryFacet",leaseterm:"leaseTermFacet",unitType:"unitTypeMapFacet",unitSubtype:"unitSubtypeMapFacet",offer:"offerFacet",genderPreference:"genderPreferenceFacet",university:"universityFacet",roomOption:"roomOptionFacet",property:"propertyFacet",unitFeatures:"unitFeaturesFacet",aspect:"aspectFacet"},facetAliases:{floor:"floorGroup"},searchBarFacets:["category","leaseterm"],defaultFacetPriority:[{id:"unitType",label:"CoveoSearch_FacetUnitType"},{id:"category",label:"CoveoSearch_FacetCategory"},{id:"property",label:"CoveoSearch_FacetProperty"},{id:"price",label:"CoveoSearch_FacetPriceRange"},{id:"floor",label:"CoveoSearch_FacetFloor"},{id:"genderPreference",label:"CoveoSearch_FacetViewPreference"},{id:"university",label:"CoveoSearch_FacetUniversity"},{id:"offer",label:"CoveoSearch_FacetSpecificOffer"},{id:"hasOffer",label:"CoveoSearch_FacetHasOffer"},{id:"availability",label:"CoveoSearch_FacetAvailability"},{id:"unitSubtype",label:"CoveoSearch_FacetUnitSubtype"}],numericFacets:{price:{facetId:"fp_price",field:"gs_price",numberOfValues:12}},unitFacets:[{key:"floorGroup",facetId:"unit_floor_group",field:"gs_unit_floor_group",numberOfValues:10,floorPlanFallback:{facetId:"fp_floor_group",field:"gs_floor_group"}},{key:"availability",facetId:"unit_available",field:"gs_unit_is_available",numberOfValues:2,floorPlanFallback:{facetId:"fp_available",field:"gs_is_available"}},{key:"bathroomPreference",facetId:"unit_bathroom_preference",field:"gs_unit_bathroom_preference",numberOfValues:2,floorPlanFallback:null},{key:"unitFeatures",facetId:"unit_features",field:"gs_unit_features",numberOfValues:30,floorPlanFallback:{facetId:"fp_unit_features",field:"gs_unit_features"}},{key:"aspect",facetId:"unit_aspect",field:"gs_unit_aspect",numberOfValues:30,floorPlanFallback:{facetId:"fp_unit_aspect",field:"gs_unit_aspect"}}],toggleFacets:[{id:"hasOffer",field:"gs_offer_id",aqOp:"exists",visibilityFacetControllerKey:"hasOfferFacet",visibilityMatchValue:"1"},{id:"accessible",field:"gs_is_accessible",aqOp:"eqNum1",visibilityFacetControllerKey:"accessibleFacet",visibilityMatchValue:"1"}],unitMirroredFpFacets:[{id:"unitType",fieldKey:"unit_type_path",labelFieldKey:"unit_type_label_path",countFacetId:"unit_type_map_count",countControllerKey:"unitTypeMapCountFacet",primaryFacetId:"fp_unit_type_map",primaryNumberOfValues:200},{id:"unitSubtype",fieldKey:"unit_subtype_path",labelFieldKey:"unit_subtype_label_path",countFacetId:"unit_subtype_map_count",countControllerKey:"unitSubtypeMapCountFacet",primaryFacetId:"fp_unit_subtype_map",primaryNumberOfValues:200},{id:"category",fieldKey:"category_sitecore_id",countFacetId:"unit_category_count",countControllerKey:"categoryCountFacet",primaryFacetId:"fp_category",primaryNumberOfValues:30},{id:"roomOption",fieldKey:"room_option_ids",labelFieldKey:"room_option_labels",countFacetId:"unit_room_option_count",countControllerKey:"roomOptionCountFacet",primaryFacetId:"fp_room_option",primaryNumberOfValues:50},{id:"university",fieldKey:"university_ids",countFacetId:"unit_university_count",countControllerKey:"universityCountFacet",primaryFacetId:"fp_university",primaryNumberOfValues:100},{id:"property",fieldKey:"property_id",labelFieldKey:"property_name",scopedLabelLookup:!0,countFacetId:"unit_property_count",countControllerKey:"propertyCountFacet",primaryFacetId:"fp_property",primaryNumberOfValues:100}],histogramMirrorFacets:[{controllersKey:"offerFacet",facetId:"fp_offer",field:"gs_offer_id",numberOfValues:50},{controllersKey:"hasOfferFacet",facetId:"fp_has_offer",field:"gs_has_offer",numberOfValues:2},{controllersKey:"accessibleFacet",facetId:"fp_accessible",field:"gs_is_accessible",numberOfValues:2},{controllersKey:"leaseTermFacet",facetId:"fp_lease_term",field:"gs_global_lease_term_item_id",numberOfValues:30},{controllersKey:"genderPreferenceFacet",facetId:"fp_preference",field:"gs_preferences",numberOfValues:30},{controllersKey:"availabilityFacet",facetId:"fp_available",field:"gs_is_available",numberOfValues:2}
1,{controllersKey:"floorNumberFacet",facetId:"fp_floor",field:"gs_floor_number",numberOfValues:20},{controllersKey:"floorGroupFacet",facetId:"fp_floor_group",field:"gs_floor_group",numberOfValues:10},{controllersKey:"unitFeaturesFacet",facetId:"fp_unit_features",field:"gs_unit_features",numberOfValues:30},{controllersKey:"aspectFacet",facetId:"fp_unit_aspect",field:"gs_unit_aspect",numberOfValues:30}],standardFacets:{offer:{facetId:"fp_offer",field:"gs_offer_id",numberOfValues:50},hasOffer:{facetId:"fp_has_offer",field:"gs_has_offer",numberOfValues:2},category:{facetId:"fp_category",field:"gs_category_sitecore_id",numberOfValues:30},roomOption:{facetId:"fp_room_option",field:"gs_room_option_ids",numberOfValues:50},unitTypeMap:{facetId:"fp_unit_type_map",field:"gs_unit_type_path",numberOfValues:200},unitSubtypeMap:{facetId:"fp_unit_subtype_map",field:"gs_unit_subtype_path",numberOfValues:200},preference:{facetId:"fp_preference",field:"gs_preferences",numberOfValues:30},availability:{facetId:"fp_available",field:"gs_is_available",numberOfValues:2},floorNumber:{facetId:"fp_floor",field:"gs_floor_number",numberOfValues:20},floorGroup:{facetId:"fp_floor_group",field:"gs_floor_group",numberOfValues:10},university:{facetId:"fp_university",field:"gs_university_ids",numberOfValues:100},property:{facetId:"fp_property",field:"gs_property_id",numberOfValues:100}},aq:{FLOOR_PLAN_LT_TYPE:'@gs_template_type=="FloorPlanLT"',LEASE_TERM_TYPE:'@gs_template_type=="LeaseTerm"',AVAILABILITY_CHECK:"@gs_is_available==1",HAS_OFFER_CHECK:"@gs_offer_id"},defaultLowResultsThreshold:5,defaultSearchHub:"GreystarSearch",pager:{numberOfPages:5},sort:{defaultCriteria:"Relevance"}}},64716:(e,a,t)=>{t.d(a,{IntegratedCardContext:()=>l});let l=(0,t(12115).createContext)(void 0)},66327:(e,a,t)=>{function l(e,a,t){let l=((e,a,t=!1)=>{let l=[],r=[];return!function e(i){if(null!=i&&(!0!==a(i)||(r.push(i),!t)))for(let a of Object.keys(i)){let t=i[a];t&&"object"==typeof t&&!l.find(e=>e===t)&&(l.push(t),e(t))}}(e),r})(e,e=>e.componentName===a&&"string"==typeof e.uid),r=new Set;return l.filter(e=>{if(!e?.uid||r.has(e.uid))return!1;if(r.add(e.uid),t&&e.fields?.Rules&&"value"in e.fields.Rules)try{let a=e.fields.Rules,l=a.value?.trim(),r=l?JSON.parse(l):[],i=t.evaluateRules(r,t.inputs);if(i)return!0===i.show;if(e.fields?.HideDefaultContent&&"value"in e.fields.HideDefaultContent){let a=e.fields.HideDefaultContent;if(!0===a.value)return!1}}catch(e){console.error("Error evaluating personalization rules:",e)}return(!e.fields?.HideDefaultContent||!("value"in e.fields.HideDefaultContent)||!0!==e.fields.HideDefaultContent.value)&&!0})}function r({str:e,valueParser:a,keyParser:t,reverse:l,separator:i="&",splitBy:o="="}){return e?.split(i).reduce((e,r)=>{let[i,n]=r.split(o);if(i&&!l){let l=a?a(n):n;e[t?t(i):i]=l}if(i&&l){let l=a?a(i):i;e[t?t(n):n]=l}return e},{})}t.d(a,{TJ:()=>r,Tn:()=>l,UO:()=>i,c0:()=>o});let i=e=>Object.fromEntries(Object.entries(e).map(([e,a])=>[a,e])),o=(e,a)=>({path:e,goalId:a})},67636:(e,a,t)=>{t.d(a,{D2:()=>o,SF:()=>n,oF:()=>s});var l=t(95155),r=t(12115);let i=(0,r.createContext)(void 0),o=({children:e,initialValues:a={}})=>{let[t,o]=(0,r.useState)(a),[n,s]=(0,r.useState)({}),u=r.useRef(t);u.current=t;let c="default",d=(0,r.useCallback)((e,a,t)=>{let l=a||c;(n[l]?.[e]||[]).forEach(a=>{try{a.callback(t)}catch(a){console.error(`Error in subscriber callback for key "${e}" in namespace "${l}":`,a)}})},[n]),p=(0,r.useCallback)((e,a,t)=>{if(!e||"string"!=typeof e)return void console.warn("GlobalContext: setValue requires a valid string key");let l=t||c;o(t=>{let r={...t,[l]:{...t[l],[e]:a}};return u.current=r,queueMicrotask(()=>{d(e,l,a)}),r})},[d]),f=(0,r.useCallback)((e,a)=>e&&"string"==typeof e?u.current[a||c]?.[e]:void console.warn("GlobalContext: getValue requires a valid string key"),[]),m=(0,r.useCallback)((e,a,t)=>{if(!e||"string"!=typeof e)return void console.warn("GlobalContext: updateValue requires a valid string key");let l=t||c;o(t=>{let r=t[l]?.[e],i="function"==typeof a?a(r):a,o={...t,[l]:{...t[l],[e]:i}};return u.current=o,queueMicrotask(()=>{d(e,l,i)}),o})},[d]),_=(0,r.useCallback)((e,a,t)=>{if(!e||"string"!=typeof e){console.warn("GlobalContext: removeValue requires a valid string key"),t&&queueMicrotask(t);return}let l=a||c;o(a=>
1{if(!a[l]||!(e in a[l]))return t&&queueMicrotask(t),a;let r={...a,[l]:{...a[l]}};return delete r[l][e],u.current=r,queueMicrotask(()=>{d(e,l,void 0),t&&t()}),r})},[d]),v=(0,r.useCallback)((e,a)=>{if(!e||"string"!=typeof e)return!1;let l=a||c;return void 0!==t[l]&&e in t[l]},[t]),b=(0,r.useCallback)(e=>{let a=e||c;return t[a]?Object.keys(t[a]):[]},[t]),y=(0,r.useCallback)(e=>{let a=e||c;o(e=>{if(!e[a])return e;let t=Object.keys(e[a]),l={...e,[a]:{}};return u.current=l,queueMicrotask(()=>{t.forEach(e=>{d(e,a,void 0)})}),l})},[d]),g=(0,r.useCallback)(()=>{let e=[];Object.keys(t).forEach(a=>{Object.keys(t[a]||{}).forEach(t=>{e.push({key:t,namespace:a})})}),o(()=>(u.current={},{})),queueMicrotask(()=>{e.forEach(({key:e,namespace:a})=>{d(e,a,void 0)})})},[t,d]),h=(0,r.useCallback)(e=>{let a=e||c;return t[a]?{...t[a]}:{}},[t]),C=(0,r.useCallback)((e,a,t)=>{if(!e||"string"!=typeof e)return console.warn("GlobalContext: subscribe requires a valid string key"),()=>{};let l=t||c;return s(t=>({...t,[l]:{...t[l],[e]:[...t[l]?.[e]||[],{callback:a,namespace:l}]}})),a(f(e,t)),()=>{s(t=>{if(!t[l]?.[e])return t;let r={...t,[l]:{...t[l],[e]:t[l][e].filter(e=>e.callback!==a)}};return 0===r[l][e].length&&delete r[l][e],r})}},[f]),I=(0,r.useMemo)(()=>({setValue:p,getValue:f,updateValue:m,removeValue:_,hasValue:v,getKeys:b,clearNamespace:y,clearAll:g,getAllValues:h,subscribe:C}),[p,f,m,_,v,b,y,g,h,C]);return(0,l.jsx)(i.Provider,{value:I,children:e})},n=()=>{let e=(0,r.useContext)(i);if(void 0===e)throw Error("useGlobalContext must be used within a GlobalProvider");return e},s=(e,a)=>{let t=n(),l=r.useRef(t);l.current=t;let i=r.useCallback(t=>l.current.subscribe(e,()=>t(),a),[e,a]),o=r.useCallback(()=>l.current.getValue(e,a),[e,a]);return r.useSyncExternalStore(i,o,o)}},70590:(e,a,t)=>{t.d(a,{Cg:()=>S,rA:()=>_,o5:()=>m,Zk:()=>P,Jd:()=>E,J_:()=>T,Qe:()=>b,SZ:()=>v,fj:()=>h,$W:()=>g,q7:()=>C,mG:()=>y,C7:()=>A,dI:()=>f});var l=t(63977),r=t(168),i=t(28776),o=t(66327),n=t(13157),s=t(74469),u=t(3501),c=t(41266),d=t(4780);let p={"unit-type":"unit-type","unit-subtype-private":"unit-type-private","unit-subtype-shared":"unit-type-shared"};function f(e){let a=[];if(e.FloorPlans?.results){let t=e=>"FloorplanSubCategory"===e.__typename,l=e.FloorPlans.results.filter(e=>!t(e)),r=e.FloorPlans.results.filter(t),i={name:"Floor Plan",children:{results:l.map(e=>({...(0,c.r)(e),children:e.children||{results:[]}}))}};a.push(i);let o={name:"Unit Sub Category",children:{results:r.map(e=>({...(0,c.r)(e),children:e.children||{results:[]}}))}};a.push(o)}if(e.LeaseTerms?.results){let t={name:"Lease Terms",children:{results:(0,c.r)(e.LeaseTerms.results)}};a.push(t)}return a}function m({leaseStartDate:e,leaseEndDate:a,windowDays:t,currentDate:l}){let r=e?new Date(Math.max(e.getTime(),l.getTime()+864e5)):l,i=e?t?new Date(r.getTime()+(t-1)*864e5):a??l:l;return{windowDays:t,windowEndDate:a?new Date(Math.min(a.getTime(),i.getTime())):i,windowStartDate:r}}function _({data:e,property:a,useGlobalLeaseTerm:t=!0,moveInWindowDays:r="0"}){let i=(0,n.D)(a?.id||""),o=a?.fields?.propertyPMS,s=a?.fields?.hideLeaseTerms?.value===!0,u=e.find(e=>"Lease Terms"===e.name);return u?.children?.results?u.children.results.reduce((e,a)=>{let u=t?a?.globalLeaseTerm?.jsonValue:null,c=a?.isWebVisibility?.value?.toString()==="1"||a?.isWebVisibility?.value===!0||o?.fields?.itemName?.value===l.Rr.integratedCard.API_DATA.YARDI_IQ,d=a.selectInstallments?.jsonValue,p=a?.hideFloorPlans?.jsonValue,f=Array.isArray(p)?p.map(e=>e?.fields?.itemId?.value||""):[],_=a?.applyOffer?.jsonValue,v=Array.isArray(_)?_.map(e=>(e?.id||"").toString().replace(/[\s-]/g,"").toUpperCase()):[],b=a?.applyDiscount?.jsonValue,y=Array.isArray(b)?b.map(e=>(e?.id||"").toString().replace(/[\s-]/g,"").toUpperCase()):[],g=a?.isFlatDiscount?.value?.toString()==="1"||a?.isFlatDiscount?.value===!0,h=null;a?.offer?.jsonValue&&(h=a.offer.jsonValue);let C=new Date,I=o?.fields?.itemName?.value===l.Rr.integratedCard.API_DATA.STARREZ,S=!!a?.startDate?.value&&new Date(a?.startDate?.value)<C,T=S?C:a?.startDate?.value?new Date(a?.startDate?.value):null,A=a?.endDate?.value?new Date(a?.endDate?.value):null,
1L=new Intl.DateTimeFormat("en-GB",{year:"numeric",month:"numeric",day:"numeric"}),P=L.format(C),E=null==A||isNaN(A.getTime())?"":L.format(A),N=I&&S?`${P} - ${E}`:a?.itemName?.value,D=function(e){let a=e;if("string"==typeof e)try{a=JSON.parse(e)}catch{return}if(!a||"object"!=typeof a)return;let t=a,l=t.id;if(l)return{id:l,label:t.fields?.itemName?.value??t.displayName??t.name??"",orderNumber:"number"==typeof t.fields?.orderNumber?.value?t.fields.orderNumber.value:999}}(a?.leaseTermYearGroup?.jsonValue),O=m({leaseStartDate:a?.startDate?.value?new Date(a.startDate.value):null,leaseEndDate:a?.endDate?.value?new Date(a?.endDate?.value):null,windowDays:r?parseInt(r.toString(),10):0,currentDate:C});return c&&e.push({title:a?.title?.value||"",hideFloorPlanIds:f,itemId:a?.itemId?.value||"",itemName:N||"",leaseTermOverwriteName:a?.leaseTermOverwriteName?.value?.trim()||"",isWebVisibility:a?.isWebVisibility?.value||"",leaseStartWindowId:a?.children?.results?.[0]?.Id?.value||"",isVisible:c,discount:a?.discount?.value?parseFloat(a?.discount?.value):null,isLeaseTermFlatDiscount:g||!1,offer:h||null,leaseTermSitecoreId:(0,n.D)(a?.LeaseTermSitecoreID||""),applyOfferOnFloorPlanIds:v,applyDiscountOnFloorPlanIds:y,hideAllLeaseTerms:s,hideLeaseTermChip:s||a?.hideLeaseTermChip?.value||!1,hideLeaseDate:a?.hideLeaseDate?.value||!1,showCustomSoldOutLabel:a?.showCustomSoldOutLabel?.value||!1,customSoldOutLabel:a?.customSoldOutLabel?.value||"",leaseTermYearGroupInfo:D??void 0,startDate:{value:a?.startDate?.value||""},endDate:{value:a?.endDate?.value||""},startDateToCompare:T,globalLeaseTerm:u||null,leaseStartWindowData:{Id:a?.children?.results?.[0]?.Id?.value||"",startDate:a?.children?.results?.[0]?.startDate?.value?new Date(a?.children?.results?.[0]?.startDate?.value||""):null,endDate:a?.children?.results?.[0]?.endDate?.value?new Date(a?.children?.results?.[0]?.endDate?.value||""):null},moveInWindowData:O,installments:d,propertySitecoreId:i,children:a?.children?.results?.map(e=>{let a=e?.startDate?.value&&new Date(e?.startDate?.value)<C?C:e?.startDate?.value?new Date(e?.startDate?.value):null,t=e?.hideFloorPlans?.jsonValue,r=Array.isArray(t)?t.map(e=>e?.fields?.itemId?.value||""):[],u=e?.isWebVisibility?.value.toString()==="1"||e?.isWebVisibility?.value===!0||o?.fields?.itemName?.value===l.Rr.integratedCard.API_DATA.YARDI_IQ,c=e?.isFlatDiscount?.value?.toString()==="1"||e?.isFlatDiscount?.value===!0,d=null;e?.offer?.jsonValue&&(d=e.offer.jsonValue);let p=e?.applyOffer?.jsonValue,f=Array.isArray(p)?p.map(e=>(e?.id||"").toString().replace(/[\s-]/g,"").toUpperCase()):[],m=e?.applyDiscount?.jsonValue,_=Array.isArray(m)?m.map(e=>(e?.id||"").toString().replace(/[\s-]/g,"").toUpperCase()):[];return{title:e?.title?.value||"",hideFloorPlanIds:r,itemId:e?.itemId?.value||"",itemName:e?.itemName?.value||"",leaseTermOverwriteName:e?.leaseTermOverwriteName?.value||"",isWebVisibility:e?.isWebVisibility?.value||"",leaseStartWindowId:e?.children?.results?.[0]?.Id?.value||"",isVisible:u,discount:e?.discount?.value?parseFloat(e?.discount?.value):null,isLeaseTermFlatDiscount:c||!1,offer:d,propertySitecoreId:i,leaseTermSitecoreId:(0,n.D)(e?.LeaseTermSitecoreID||""),applyOfferOnFloorPlanIds:f,applyDiscountOnFloorPlanIds:_,startDateToCompare:a,hideAllLeaseTerms:s,hideLeaseTermChip:s||e?.hideLeaseTermChip?.value||!1,hideLeaseDate:e?.hideLeaseDate?.value||!1,showCustomSoldOutLabel:e?.showCustomSoldOutLabel?.value||!1,customSoldOutLabel:e?.customSoldOutLabel?.value||"",startDate:{value:e?.startDate?.value||""},children:e?.children?.results,Id:{value:e?.itemId?.value||""},leaseStartWindowData:{Id:e?.children?.results?.[0]?.Id?.value||"",startDate:e?.children?.results?.[0]?.startDate?.value?new Date(e?.children?.results?.[0]?.startDate?.value||""):null,endDate:e?.children?.results?.[0]?.endDate?.value?new Date(e?.children?.results?.[0]?.endDate?.value||""):null},installments:e?.selectInstallments?.jsonValue}})||[]}),e},[]):[]}function v(e,a){if(!e?.length)return{groups:[],showYearGroupTabs:!1,yearGroupTabsToShow:[]};let t=new Map;for(let a of e){let e=a.leaseTermYearGroupInfo?.id??"";t.has(e)||t.set(e,[]),t.get(e).push(a)}let l=Array.from(t.entries()).map(([e,a])=>({key:e,label:a[0]?.leaseTermYearGroupInfo?.label??"Other",orderNumber:a[0]?.leaseTermYearGroupInfo?.orderNumber??999,terms:a}));l.sort((e,a)=>e.orderNumber-a.orderNumber);let r=l.filter(e=>""!==e.key);return{groups:l,showYearGroupTabs:!0===a,yearGroupTabsToShow:r}}function b(e,a,t,l){if(!e?.length)return[];if(!a)return e;if(!l){let e=t.find(e=>""!==e.key);return e?.terms??[]}let r=t.find(e=>e.key===l);return r?.terms??[]}function y(e,a,t=!0){if(!e)return{};let l={};for(let r of e.split("&").map(e=>
1e.trim()).filter(Boolean)){let[e,i]=r.split("=");if(e&&i){let r=parseFloat(i.replace(/,|%2C/g,""));l[e]=(0,s.GR)(r,a,t)}}return l}function g(e){return e&&0!==e.length&&Array.isArray(e)?e.reduce((e,a)=>((a?.fields?.selectLeaseTerm?.length||0)>0?a?.fields?.selectLeaseTerm?.forEach(t=>{let l=(0,n.D)(t?.id||"000").toUpperCase();e[l]||(e[l]={discountValue:a?.fields?.discountValue?.value?parseFloat(a?.fields?.discountValue?.value):null,isFlatDiscount:a?.fields?.isFlatDiscount?.value||!1})}):e["000"]={discountValue:a?.fields?.discountValue?.value?parseFloat(a?.fields?.discountValue?.value):null,isFlatDiscount:a?.fields?.isFlatDiscount?.value||!1},e),{}):{}}function h(e){return e?e.split("&").reduce((e,a)=>{let[t,l]=a.split("=");return t&&l&&(e[t]=l),e},{}):{}}function C(e){return e?e.reduce((e,a)=>(a.id&&(e[a.id?.toString().toUpperCase()]=a),e),{}):{}}function I(e,a){let t={...e,pricesByLeaseTermId:{...e.pricesByLeaseTermId},availabilityStatusByLeaseTermId:{...e.availabilityStatusByLeaseTermId}};Object.keys(a.pricesByLeaseTermId||{}).forEach(e=>{let l=a.pricesByLeaseTermId?.[e];if(null!=l&&l>0){let a=t.pricesByLeaseTermId?.[e];(null==a||0===a||l<a)&&(t.pricesByLeaseTermId||(t.pricesByLeaseTermId={}),t.pricesByLeaseTermId[e]=l)}});let l=a.earliestUnitAvailableDate;if(l){let e=t.earliestUnitAvailableDate;if(e){let a=new Date(l),r=new Date(e);isNaN(a.getTime())||isNaN(r.getTime())?isNaN(a.getTime())||(t.earliestUnitAvailableDate=l):a<r&&(t.earliestUnitAvailableDate=l)}else t.earliestUnitAvailableDate=l}return t.floorplanImages=t.floorplanImages?.concat(a.floorplanImages||[]),t}function S({data:e,currencySymbol:a,propertyData:t,categoryTabToShow:r,locationSelection:u,floorLabel:c,floorChipLabel:f,mapping3DEntries:m}){let _=t?.fields,v=u??_?.locationSelection,b={primaryButton:_?.primaryCTA??null,secondaryButton:_?.secondaryCTA??null},C=_?.selectUniversity??[],T=Array.isArray(C)?C.map(e=>e?.id||""):[],E=_?.areaUnitType,N=_?.isExtraServiceCharge?.value??!1,D=_?.disableUnitPopup?.value??!1,O=_?.propertyID?.value??"",F=_?.availabilityURL?.value??"",R=_?.mergeProperty?.value??!1,w=_?.enableComingSoonBanner?.value??!1,k=_?.enablePreRegistrationPopup?.value??!1,M=_?.propertyPMS,V=_?.priceFrequency,B=_?.showArea?.value??!1,U=_?.showCurrencyCodeAtEnd?.value??!1,K=_?.propertyName?.value??"",j=_?.marketingName?.value??"",G=_?.staticAvailabilityURL?.value??"",$=_?.useStaticAvailabilityURL?.value??!1,x=_?.openInSameTab?.value??!1,W=_?.enableAvailableFrom?.value??!1,H=_?.showAvailableDateOnFloorPlan?.value??!1,Y=_?.hideFloorPlan?.value??!1,q=_?.hideFloorPlanImage?.value??!1,Q=_?.hidePriceFrequencyToggle?.value===!0,J=_?.show3DModal?.value??!1,Z=_?.modal3DId?.value??"",z=_?.showProperty3DModal?.value??!1,X=_?.propertyModal3DId?.value??"",ee=(0,d.it)(_?.floorRanges),ea=m?function(e){let a={};for(let t of e){let e=p[t.mappingId]??t.mappingId;if(e)for(let l of t.floorplanIds){let r=(0,n.D)(l||"").toUpperCase();r&&((a[r]??={})[e]=t.value)}}return a}(m):{},et=new Set,el=P(_?.selectTooltipItems),er=!M||M?.fields?.itemName?.value===l.Rr.integratedCard.API_DATA.ENTRATA,ei=M?.fields?.itemName?.value===l.Rr.integratedCard.API_DATA.YARDI_IQ,eo=M?.fields?.itemName?.value===l.Rr.integratedCard.API_DATA.YARDI_BTR,en=_?.SelectPriceBreakdownContent,es=_?.useSubCategoryStructure?.value??!1,eu=es?"Unit Sub Category":"Floor Plan",ec=e.find(e=>e.name===eu);if(!ec?.children?.results)return{floorPlans:[],categories:[]};let ed=ec.children.results,ep=new Map;return{floorPlans:ed.map(e=>{let t=ea[(0,n.D)(e?.FloorPlanSitecoreID)||""]??{},l={pricesByLeaseTermId:{},availabilityStatusByLeaseTermId:{},earliestUnitAvailableDate:"",floorplanImages:[]},u=[],{extraServiceCharge:p,isServiceChargeInPercent:m}=(0,s.O)(e,N);if(es&&e?.selectFloorplans?.jsonValue?.length>0){let a=e?.selectFloorplans?.jsonValue||[];a?.forEach(e=>{let a=L({fp:{...e?.fields,FloorPlanSitecoreID:e?.id},extraServiceCharge:p??0,isServiceChargeInPercent:m,baseAvailabilityURL:F,propertyId:O});l=I(l,a),u=[...u,{availabilityURL:a.availabilityURL,floorPlanSitecoreId:a.floorPlanSitecoreId,floorplanImages:a.floorplanImages,earliestUnitAvailableDate:a.earliestUnitAvailableDate}]})}let C=e?.discount?.jsonValue?g(e?.discount?.jsonValue):{},S=null,P=null,eu=null;if(e.selectFloorPlanCategory?.jsonValue){let a=e.selectFloorPlanCategory.jsonValue;eu={id:a?.id||"",name:a?.fields?.itemName?.value||"",orderNumber:a?.fields?.orderNumber?.value?Number(a.fields.orderNumber.value):void 0,image:a?.fields?.image},(r&&r.id===eu.id||!r&&eu?.id&&!ep.has(eu.id))&&ep.set(eu.id,eu)}let ec=es?l.earliestUnitAvailableDate:e?.earliestUnitAvailableDate?.value||"",ed=es?l.pricesByLeaseTermId||{}:y(e?.price?.value||"",p,m),ef=y(e?.overwritePrice?.value||"",p,m),em=es?l.availabilityStatusByLeaseTermId||{}:h(e?.availabilityStatus?.value||""),e_=e?.galleryImages?.jsonValue?.map(e=>e?.fields?.image)||[],ev=e.preferences?.jsonValue?e.preferences.jsonValue?.map(e=>e?.fields?.title?.value||""):[],eb=e.accessiblePreferences?.jsonValue,ey=!!Array.isArray(eb)&&eb.some(e=>e?.id&&"abaa4f7d09c44fac988a8968bce629ce"===e.id.replace(/[{}\-]/g,"").toLowerCase()),eg=e.features?.jsonValue?e.features.jsonValue?.map(e=>e?.fields?.featureTitle?.value||""):[],eh=e?.roomOptions?.jsonValue,eC=Array.isArray(eh)?eh.map(e=>({itemId:String(e.fields?.itemId?.value??e.itemId?.value??e.id??""),itemName:String(e.fields?.itemName?.value??e.itemName?.value??e.name??"")})).filter(e=>e.itemName):eh?[{itemId:String(eh.fields?.itemId?.value??eh.itemId?.value??eh.id??""),itemName:String(eh.fields?.itemName?.value??eh.itemName?.value??eh.name??"")}].filter(e=>e.itemName):[],eI=e.selectFloorplanSubCategory?.jsonValue,eS=Array.isArray(eI)?eI.map(e=>({itemId:String(e.fields?.itemId?.value??e.itemId?.value??e.id??""),itemName:String(e.fields?.itemName?.value??e.itemName?.value??e.name??"")})).filter(e=>e.itemName):eI?[{itemId:String(eI.fields?.itemId?.value??eI.itemId?.value??eI.id??""),itemName:String(eI.fields?.itemName?.value??eI.itemName?.value??eI.name??"")}].filter(e=>e.itemName):[],eT={};e.offer?.value&&e.offer?.value.toString().trim()!==""&&(eT=(0,o.TJ)({str:e.offer.value.toString(),valueParser:e=>e.replace(/%7B|%7D/gi,""),keyParser:e=>e?e.replace(/%257B|%257D/gi,""):"000",reverse:!0,separator:"%26",splitBy:"%3d"}));let eA=e.floorplanImage&&e.floorplanImage?.jsonValue?.length>0?e.floorplanImage?.jsonValue:e.floorplanDynamicImages?.jsonValue,eL=es?l.floorplanImages:A({floorPlanImages:eA,title:""}),eP=(e,a)=>{if(!e||!(a in e))return null;let t=e[a],l=t?.value;if(null==l)return null;let r=Number(l);return isNaN(r)?null:r},eE=eP(e,"vatCharge"),eN=eP(e,"monthlyServiceCharge"),eD={cmsData:en,dynamicData:{monthlyServiceCharge:eN,vatPercentage:en?.fields?.monthlyVATLabel?.value?eE:null,monthlyWiFi:eP(e,"wiFiCharge"),tokensToReplace:(e=>{if(!e||!("tokensToReplace"in e))return null;let a=e.tokensToReplace?.value;return a?(0,o.TJ)({str:a,valueParser:e=>e.replace(/%7B|%7D/gi,""),keyParser:e=>`{${e.replace(/%257B|%257D/gi,"")}}`}):null})(e),totalMonthlyRent:null,monthlyRent:null,monthlyVAT:null},showPriceBreakdownButton:!!en?.fields?.title?.value,showPriceBreakdownError:null===eN||0===eN}
1,eO={autoPlayDuration:e?.autoPlayDuration?.value||0,isAutoPlay:e?.isAutoPlay?.value,galleryTabHeading:e?.galleryTabHeading?.value||"",galleryTabNote:e?.galleryTabNote?.value||"",floorPlanTabHeading:e?.floorPlanTabHeading?.value||"",floorPlanTabNote:e?.floorPlanTabNote?.value||"",videoTabHeading:e?.videoTabHeading?.value||"",videoTabNote:e?.videoTabNote?.value||"",videoComponent:e?.videoId?.value?.toString().trim()!==""?{fields:{videoId:e?.videoId||"",playButtonIcon:e?.playButtonIcon?.jsonValue||""}}:null,virtualTourTabHeading:e?.virtualTourTabHeading?.value||"",virtualTourTabNote:e?.virtualTourDisclaimerText?.value||"",virtualTourIframe:e?.virtualTourIframe?.value||"",floorPlanImages:eL},eF=e?.children?.results?.map(e=>e.children?.results||[]),eR={textBlockDescription:_?.showMoveInDate?.value&&_?.moveInDateDisclaimer?.value||"",modalSecondaryTitle:e?.selectYourRoomLabel?.value||"",rooms:[],unitModelNote:e?.unitModalNote?.value||""};eF&&eF.length>0&&(ei&&e.children.results&&null===S&&(S=e.children.results.some(e=>!!e?.availabilityURL?.value&&(S=e.availabilityURL.value,!0))?S:null),(er||eo)&&e.children.results.forEach(e=>{let a=e.floorNumber?.value||"",t=parseInt(a,10);if(isNaN(t)||et.add(t),eo){let t={floorNumber:a,unitNumber:e.unitNumber?.value||"",unitSpaceId:e.unitId?.value||"",features:e.features?.value?e.features.value.replace(/\^/g,", "):"",pricesByLeaseTermId:{},finalPrice:null,originalPrice:null,discount:null,isDiscountApplied:!1,priceFrequency:V,availabilityURL:e?.availabilityURL?.value||"",finalAvailabilityStatus:!0,area:e.area?.value||null};null===P&&(P=(0,i.qm)(e?.availabilityURL?.value||"","UnitID")),eR.rooms=[...eR.rooms,t]}if(er){let t=e.children?.results||[];if(t&&t.length>0){let e=t.map(e=>{let t=y(e.price?.value||"",p,m);return{floorNumber:a,unitNumber:e.unitNumber?.value||"",unitSpaceId:e.unitSpaceId?.value||"",features:e.features?.value?e.features.value.replace(/\^/g,", "):"",pricesByLeaseTermId:t,finalPrice:null,originalPrice:null,discount:null,isDiscountApplied:!1,availabilityURL:null,priceFrequency:V,finalAvailabilityStatus:null,area:e.area?.value||null}});eR.rooms=[...eR.rooms,...e]}}}));let ew=ei?S:F,ek=(0,i.wA)(ew||"",{propertyid:O,floorplanid:R?"":e?.itemId?.value||"",spaceoptionid:R?"":e?.spaceOptionId?.value||"",myolepropertyid:O||"",gradeid:e?.itemId?.value||"",floorplans:e?.itemId?.value||""}),{floorGroupLabels:eM,searchFeatureLabels:eV}=(0,d._W)(et,ee,f??c),eB=[...eV,...eg];return{uid:e?.FloorPlanSitecoreID||"",floorPlanSitecoreId:e?.FloorPlanSitecoreID||"",id:e?.itemId?.value||"",name:e?.itemName?.value||"",eyebrowText:e?.eyebrow?.value||"",displayName:e?.overwriteName?.value||e?.itemName?.value||"",category:eu,inclusions:e?.floorPlanInclusions?.value||"",roomType:e?.floorRoomType?.value||"",area:e?.floorPlanArea?.value||"",pricesByLeaseTermId:ed,overwritePricesByLeaseTermId:ef,floorNumbersList:Array.from(et),finalPrice:null,originalPrice:null,priceFrequency:V,discount:null,discountByLeaseTermId:C,offerByLeaseTermId:eT,isFloorPlanFlatDiscount:!1,galleryImages:e_,preferences:ev,isAccessible:ey,features:eg,floorGroupLabels:eM,propertyFloorRanges:ee,searchFeatures:eB,offer:null,availabilityStatusByLeaseTermId:em,finalAvailabilityStatus:!!eo||!!ei||null,disableUnitPopup:D,buttons:{exploreRooms:e?.exploreRoomsLabel?.value||"",availability:e?.availabilityLabel?.value||"",bookNow:e?.bookNowLabel?.value||"",waitlist:e?.waitlistCTA?.jsonValue,bookATour:e?.bookATourCTA?.jsonValue},currencySymbol:a,exploreRoomModal:eO,selectUnitModal:eR,availabilityURL:eo&&!D?P||"":ek,rentNowURL:eo&&!D?P||"":(0,i.wA)(ek,{unitspaceid:""},!0),isUpcoming:!1,isDiscountApplied:!1,extraServiceCharge:p,isServiceChargeInPercent:m,showUnitArea:B,showCurrencyCodeAtEnd:U,propertyPMS:M,isMergeProperty:R,showAvailableFrom
1:W,show3DModal:J,modal3DId:Z,modal3DMappings:t,showProperty3DModal:z,propertyModal3DId:X,selectedLeaseTerm:null,enableComingSoonBanner:w,propertyName:K,staticAvailabilityURL:G,useStaticAvailabilityURL:$,enablePreRegistrationPopup:k,requiredUrlParams:{PropertyID:O,propertyName:j},selectSorting:_?.selectSorting||null,selectSharingOptions:_?.selectSharingOptions||[],enableSharingOptions:e?.enableSharingPreference?.value,textBlockTitle:e?.textBlockTitle?.value||"",textBlockDescription:e?.textBlockDescription?.value||"",earliestUnitAvailableDate:ec,showSoldOut:!!e?.showSoldOut?.value,floorPlanShowCustomSoldOutLabel:!!e?.showCustomSoldOutLabel?.value,customSoldOutMultilist:e.customSoldOut?.jsonValue,showAvailableDateOnFloorPlan:H,universitySitecoreIds:T,hideFloorColumn:Y,hideFloorPlanImage:q,hidePriceFrequencyToggle:Q,subCategoryFloorPlans:u,areaUnit:E,priceBreakdownModal:eD,openInSameTab:x,locationSelection:v,preRegistrationFields:b,toolTipConfigurations:el,roomOptions:eC,roomSubCategoryOptions:eS}}),categories:Array.from(ep.values())}}function T({floorPlansData:e,propertyData:a,leaseTerms:t,categoryCardFloorplanCategoryId:l}){let r=a?.fields?.isExtraServiceCharge?.value??!1,i=e.reduce((e,i)=>{if(i.selectFloorPlanCategory?.jsonValue){let o=i.selectFloorPlanCategory.jsonValue;if(o?.id!==l)return e;let{extraServiceCharge:c,isServiceChargeInPercent:d}=(0,s.O)({extraServiceCharge:i?.extraServiceCharge,isServiceChargeInPercent:i?.isServiceChargeInPercent},r),{lowestPriceWithCharge:p,lowestPriceWithChargeDiscount:f}=function({extraServiceCharge:e,isServiceChargeInPercent:a,leaseTerms:t,floorPlan:l,propertyData:r}){let i=l.FloorPlanSitecoreID||"",o=l.price?.value??"",s=l.overwritePrice?.value??"",c=r?.fields?.useSubCategoryStructure?.value??!1,d={pricesByLeaseTermId:{},availabilityStatusByLeaseTermId:{}};c&&l?.selectFloorplans?.targetItems?.length>0&&(l?.selectFloorplans?.targetItems||[]).forEach(t=>{let l=L({fp:{...t,FloorPlanSitecoreID:t?.id},extraServiceCharge:e??0,isServiceChargeInPercent:a,baseAvailabilityURL:"",propertyId:r?.fields?.propertyID?.value??""});d=I(d,l)});let p=y(s,e,a),f={...c?d.pricesByLeaseTermId||{}:y(o,e,a),...p},m=t.reduce((e,a)=>(e[a?.itemId?.value||""]=a,e),{}),_=g(l.discount?.jsonValue),v=Object.keys(f).reduce((e,a)=>{let t=f[a]??null;if(null===t)return e;let l=(0,n.D)(m[a]?.LeaseTermSitecoreID||"").toUpperCase(),r=m[a],o=m[a]?.applyDiscount?.jsonValue,s=Array.isArray(o)?o.map(e=>(0,n.D)(e?.id||"000").toUpperCase()):[],c=r?_[l]??null:Object.values(_)[0]??null,d=c?.discountValue||null,p=c?.isFlatDiscount||!1;null===d&&s.includes((0,n.D)(i).toUpperCase())&&m[a]?.discount?.value!==null&&(d=m[a]?.discount?.value?.toString()?parseFloat(m[a]?.discount?.value?.toString()??""):null,p=m[a]?.isFlatDiscount?.value??!1);let v=d?(0,u._M)(t,d,p):t;return null!==v&&0!==v&&e.push({lowestPriceWithCharge:t,lowestPriceWithChargeDiscount:v}),e},[]);return{lowestPriceWithCharge:(v.length>0?Math.min(...v.map(e=>e.lowestPriceWithCharge)):null)??0,lowestPriceWithChargeDiscount:(v.length>0?Math.min(...v.map(e=>e.lowestPriceWithChargeDiscount)):null)??0}}({extraServiceCharge:c??0,isServiceChargeInPercent:d,leaseTerms:t,floorPlan:i,propertyData:a});null!==p&&0!==p&&e.push({minPrice:p,minPriceAfterDiscount:f})}return e},[]);return{minPrice:i.length>0?Math.min(...i.map(e=>e.minPrice)):0,minPriceAfterDiscount:i.length>0?Math.min(...i.map(e=>e.minPriceAfterDiscount)):0}}function A({floorPlanImages:e,title:a}){let t=Array.isArray(e)?e:e?[e]:[];if(0===t.length)return[];let l=t?.map(e=>({value:e?.fields?.floorPlanMediaImage,title:a||""})),r=l.filter(e=>""!==e.title.trim());return 0===r.length&&(r=[l[0]]),r}function L({fp:e,extraServiceCharge:a,isServiceChargeInPercent:t,baseAvailabilityURL:l,propertyId:r}){let{price:o,availabilityStatus:n,spaceOptionId:s,floorplanImage:u,earliestUnitAvailableDate:c,itemId:d,floorplanDynamicImages:p}=e,f=u&&u?.length>0?u:p,m=(0,i.wA)(l||"",{propertyid:r,floorplanid:d?.value||"",spaceoptionid:s?.value||"",gradeid:d?.value||"",floorplans:d?.value||""});return{id:d?.value??"",availabilityURL:m??"",floorPlanSitecoreId:e.FloorPlanSitecoreID||"",spaceOptionId:s?.value??"",floorplanImages:A({floorPlanImages:f??[],title:e.floorPlanTabHeading?.value??""}),pricesByLeaseTermId:y(o?.value??"",a,t),availabilityStatusByLeaseTermId:h(n?.value??""),earliestUnitAvailableDate:c?.value??""}}function P(e){return Array.isArray(e)?e.reduce((e,a)=>{let t=a.fields?.tooltipKey?.fields?.Value?.value;return t&&Object.values(r.j).includes(t)&&a.fields?.hideTooltip?.value!==!0&&(e[t]={hideTooltip:a.fields?.hideTooltip?.value??!1,value:a.fields?.tooltipContent?.value??""}),e},{}):{}}function E(e,a,t){if(!e?.trim())return"";
1let l=a&&a?.fields?.itemName?.value?.trim()?a?.fields?.itemName?.value?.trim():a&&a?.fields?.itemShortName?.value?.trim()?a?.fields?.itemShortName?.value?.trim():t;return`${e} ${l}`}},74469:(e,a,t)=>{t.d(a,{G9:()=>I,GR:()=>c,L9:()=>C,O:()=>u,PQ:()=>_,SR:()=>v,W5:()=>y,Wr:()=>s,YB:()=>b,cU:()=>n,ng:()=>h,qS:()=>g,vP:()=>f});var l=t(63977),r=t(28776),i=t(3501),o=t(70590);function n(e,a){return Array.isArray(e)&&0!==e.length?e.map(e=>({title:e.fields.title.value.replaceAll("{currency}",a),minValue:e.fields.minValue?.value,maxValue:e.fields.maxValue?.value,isSelected:!1,order:parseInt(e.fields.order?.value.toString()||"0")})).sort((e,a)=>e.order-a.order):[]}function s(e){return Array.isArray(e)&&0!==e.length?e.map(e=>({title:e.fields.title.value,isSelected:!1})):[]}function u(e,a){return{extraServiceCharge:a&&e?.extraServiceCharge?.value?parseFloat(e.extraServiceCharge.value):null,isServiceChargeInPercent:e?.isServiceChargeInPercent?.value?.toString()==="1"||e?.isServiceChargeInPercent?.value===!0}}function c(e,a,t=!0){if(e>0&&null!=a)if(t)return e+e*a/100;else return e+a;return e}function d(e){let a=e.filter(e=>null!=e);return a.length>0?Math.min(...a):null}function p(e,a,t){return a?.length?a.map(a=>e[t][a.itemId]).filter(e=>null!=e):[]}function f(e,a,t){let l=t?e?.discountByLeaseTermId?.[t?.leaseTermSitecoreId]??null:Object.values(e?.discountByLeaseTermId??{})[0]??null,r=l?.discountValue||null,i=l?.isFlatDiscount||!1,o=a[e?.offerByLeaseTermId?.[t?.leaseTermSitecoreId||"000"]??""]??null;return null==r&&t?.applyOfferOnFloorPlanIds?.includes(e?.floorPlanSitecoreId||"")&&t?.offer&&(o=t.offer),null==r&&t?.applyDiscountOnFloorPlanIds?.includes(e?.floorPlanSitecoreId||"")&&(r=t?.discount||null,i=t?.isLeaseTermFlatDiscount||!1),{discount:r,isFlatDiscount:i,offer:o}}function m(e,a,t,l,i){let o=new Date,n=a.children?.[0]?.startDate?.value?new Date(a.children[0].startDate.value):null,s=n&&n>=o,u=e.earliestUnitAvailableDate?new Date(e.earliestUnitAvailableDate):null,c=u?I(u):"",d=(null===s||!s)&&(u&&u>=o||!i)?{lease_start_date:i?c:"{lease_start_date}"}:{},p=Object.keys(d).length>0&&e.availabilityURL?`${e.availabilityURL}?${new URLSearchParams(d).toString()}`:e.availabilityURL,f=(0,r.wA)(p||"",{leasetermid:t?"":a.itemId,leasestartwindowid:s?a.leaseStartWindowId:"",atid:a.itemId,lease_start_date:d.lease_start_date},!t);return{availabilityURL:f,availabilityURLWithoutUnitSpaceId:l?(0,r.wA)(f,{unitspaceid:"",lease_start_date:c},!0):f}}function _({fp:e,selectedLeaseTerm:a,selectedLeaseTermChildren:t,offerList:l,isMergeProperty:r,requiredRoomFeatures:o,urlConfig:n={removeUnitSpaceId:!1,getAvailabilityDateFromFloorPlan:!1},propertyShowSoldOut:s=!1,moveInDate:u}){var c;let v;if(a?.hideFloorPlanIds?.includes(e.id))return e;r?null===(v=d(p(e,t,"overwritePricesByLeaseTermId")))&&(v=d(p(e,t,"pricesByLeaseTermId"))):null===(v=e.overwritePricesByLeaseTermId[a.itemId]??null)&&(v=e.pricesByLeaseTermId[a.itemId]||null);let{discount:b,isFlatDiscount:y,offer:g}=f(e,l,a),C=v,I=(c=v=C?b?(0,i._M)(C,b,y):C:null,c&&C&&c<C?b:null),S=!!(v&&v>0),T=!s&&!e.showSoldOut&&S,{availabilityURL:A,availabilityURLWithoutUnitSpaceId:L}=m(e,a,r,n.removeUnitSpaceId,n.getAvailabilityDateFromFloorPlan),P=e.subCategoryFloorPlans?.map(e=>{let{availabilityURL:t}=m(e,a,r,n.removeUnitSpaceId,n.getAvailabilityDateFromFloorPlan);return{...e,availabilityURL:t}}),E=e.floorPlanCardObject,N=v?h(e,v):e.priceBreakdownModal;return{...e,moveInDate:u,discount:I,isFloorPlanFlatDiscount:y,isDiscountApplied:null!==I,offer:g,finalPrice:v,originalPrice:C,finalAvailabilityStatus:T,propertyShowSoldOut:s,availabilityURL:A,rentNowURL:L,selectedLeaseTerm:a,requiredRoomFeatures:o,floorPlanCardData:E?Object.values(E):void 0,requiredUrlParams:{...e.requiredUrlParams,...{TermID:a.itemId}},subCategoryFloorPlans:P,priceBreakdownModal:N}}function v({floorPlans:e,selectedLeaseTerm:a,showSoldOutProperties:t=!0,requiredRoomFeatures:r,universityIdsToFilterFloorPlans:n,propertyData:s,moveInDate:u}){let c=!!s?.fields?.showSoldOut?.value,d=s?.fields?.showMoveInDate?.value?u:void 0,p=a?.children||null,m=s?.fields?.mergeProperty?.value??!1,b=s?.fields?.propertyPMS,y=s?.fields?.selectOffers?.fields?.selectOffers??s?.fields?.selectOffers?.jsonValue?.fields?.selectOffers??[],g=(0,o.q7)(y);return s?.fields?.showComingSoon?.value?e.map(e=>({...e,isUpcoming:!0})).filter(e=>{let a=e.category?.id,l=!n||0===n.length||e.universitySitecoreIds.some(e=>n?.includes(e));
1return t?a&&l:(e.finalAvailabilityStatus||e.isUpcoming)&&a&&l}):b?.fields?.itemName?.value===l.Rr.integratedCard.API_DATA.YARDI_BTR?e.map(e=>{let t=a?.itemId||"000",o=e.overwritePricesByLeaseTermId[t]??e.pricesByLeaseTermId[t]??null,{isFlatDiscount:n,discount:s}=f(e,g,a),u=a?f(e,g,a).offer:g[Object.values(e.offerByLeaseTermId)[0]]||null,p=o?s?(0,i._M)(o,s,n):o:null,m=p&&o&&p<o?s:null,_=!!p&&p>0,v=!c&&!e.showSoldOut&&_,y=e.availabilityStatusByLeaseTermId[t]==l.Rr.integratedCard.availabilityStatus.upcoming,C=p?h(e,p):e.priceBreakdownModal;return{...e,finalPrice:p,originalPrice:o,finalAvailabilityStatus:v,propertyShowSoldOut:c,isUpcoming:y,offer:u,discount:m,isFloorPlanFlatDiscount:n,isDiscountApplied:null!==m,propertyPMS:b,selectedLeaseTerm:a,requiredRoomFeatures:r,priceBreakdownModal:C,moveInDate:d}}).filter(e=>{let a=e.category?.id,l=!n||0===n.length||e.universitySitecoreIds.some(e=>n?.includes(e));return t?a&&l:(e.finalAvailabilityStatus||e.isUpcoming)&&a&&l}).sort((e,a)=>e.finalAvailabilityStatus&&!a.finalAvailabilityStatus?-1:!e.finalAvailabilityStatus&&a.finalAvailabilityStatus?1:e.isUpcoming&&!a.isUpcoming?-1:!e.isUpcoming&&a.isUpcoming?1:0):a?e.map(e=>_({fp:e,selectedLeaseTerm:a,selectedLeaseTermChildren:p,offerList:g,isMergeProperty:m,requiredRoomFeatures:r,propertyShowSoldOut:c,urlConfig:{removeUnitSpaceId:!0,getAvailabilityDateFromFloorPlan:e.disableUnitPopup},moveInDate:d})).filter(e=>{if(a?.hideFloorPlanIds?.includes(e.id))return!1;let l=e.category?.id,r=!n||0===n.length||e.universitySitecoreIds.some(e=>n?.includes(e));return t?l&&r:(e.finalAvailabilityStatus||e.isUpcoming)&&l&&r}).sort((e,a)=>e.finalAvailabilityStatus&&!a.finalAvailabilityStatus?-1:!e.finalAvailabilityStatus&&a.finalAvailabilityStatus?1:0):t?e.map(e=>({...e,propertyShowSoldOut:c,finalPrice:null,finalAvailabilityStatus:null,moveInDate:d})):[]}function b(e,a){return a?e.filter(e=>e.category?.id===a.id):[]}function y(e,a,t,l,r){let i=a.filter(e=>e.isSelected),o=t?.filter(e=>e.isSelected)||[];if(0===i.length&&0===o.length)return e;let n=e;return i.length>0&&(n=n.filter(e=>null!==e.finalPrice&&(!l||!e.finalPrice||!(e.finalPrice>l)||!(l>0))&&(!r||!e.finalPrice||!(e.finalPrice<r)||!(r>0))&&i.some(a=>{let t=a.minValue?parseFloat(a.minValue):null,l=a.maxValue?parseFloat(a.maxValue):null;return!!e.finalAvailabilityStatus&&(null!==t&&null!==l?e.finalPrice>=t&&e.finalPrice<=l:null!==t?e.finalPrice>=t:null!==l&&e.finalPrice<=l)}))),o.length>0&&(n=n.filter(e=>o.some(a=>e?.preferences?.includes(a.title)))),n}function g(e){return{id:e.id,name:e.fields?.itemName?.value||"",orderNumber:e.fields?.orderNumber?.value||0,image:e.fields?.image}}function h(e,a){if(!a)return e.priceBreakdownModal;let t=a?(a+(e.priceBreakdownModal?.dynamicData?.monthlyServiceCharge??0))*(e.priceBreakdownModal?.dynamicData?.vatPercentage??0)/100:null,l=(t??0)+(a??0)+(e.priceBreakdownModal?.dynamicData?.monthlyServiceCharge??0);return{...e.priceBreakdownModal,dynamicData:{...e.priceBreakdownModal?.dynamicData,monthlyRent:a,monthlyVAT:t,totalMonthlyRent:l}}}function C(e){return e?.itemId&&e?.itemId?.trim()!==""?e.globalLeaseTerm?.fields?.leaseLengthLabel?.value||e.globalLeaseTerm?.fields?.itemName?.value||e.leaseTermOverwriteName||e.itemName||e.title:""}function I(e){return e?`${(e.getMonth()+1).toString().padStart(2,"0")}/${e.getDate().toString().padStart(2,"0")}/${e.getFullYear()}`:""}},76548:(e,a,t)=>{t.d(a,{IntegratedCardProvider:()=>f});var l=t(95155),r=t(12115),i=t(64716),o=t(70590),n=t(74469),s=t(59947),u=t(13746),c=t(79363),d=t(63977),p=t(67636);let f=({children:e,data:a,currencySymbol:t,floorLabel:f,propertyData:m,selectFloorplanCategory:_})=>{let{page:v}=(0,c.useSitecore)(),{language:b,itemPath:y,SiteSettings:g}=v?.layout?.sitecore?.context||{},h=(0,u.S)(),C=(0,r.useRef)(!0),{selectBudgetFilters:I,selectPreferenceFilters:S,propertyPMS:T,marketingName:A,hideBudgetFilters:L}=m?.fields||{},P=m?.fields?.enableLeaseTermYearGrouping?.value===!0||"1"===String(m?.fields?.enableLeaseTermYearGrouping?.value),E=!!m?.fields?.showMoveInDate?.value,N=m?.fields?.showSoldOut?.value===!0,D=m?.fields?.showComingSoon?.value!==!0&&!N,O=m?.fields?.hideLeaseTerms?.value===!0,F=A?.value??"",R=L?.value?[]:I,w=g?.leaseWindowDays||"0",{setValue:k}=(0,p.SF)(),M=(0,r.useMemo)(()=>(0,o.rA)({data:a,property:m,useGlobalLeaseTerm:!1,moveInWindowDays:w}),[a,m]),V=(0,r.useMemo)(()=>!O&&M.length>0,[T?.fields?.itemName?.value,M.length]),[B,U]=(0,r.useState)(null);(0,r.useEffect)(()=>
1{if(M.length>0){let{showYearGroupTabs:e,yearGroupTabsToShow:a,groups:t}=(0,o.SZ)(M,P);U((0,o.Qe)(M,e,t,a[0]?.key??null)[0]??M[0])}else U(null)},[M,P]);let{floorPlans:K,categories:j}=(0,r.useMemo)(()=>(0,o.Cg)({data:a,currencySymbol:t,propertyData:m,categoryTabToShow:_,floorLabel:f}),[a,t,m,_]),[G,$]=(0,r.useState)(_||(j.length>0?j[0]:null)),x=(0,r.useRef)(!1),W=(0,r.useMemo)(()=>JSON.stringify(R),[R]),H=(0,r.useMemo)(()=>D?(0,n.cU)(R,t):[],[W,t]),[Y,q]=(0,r.useState)(H);(0,r.useEffect)(()=>{q(H)},[H]);let[Q,J]=(0,r.useState)(()=>(0,n.Wr)(S));(0,r.useEffect)(()=>{J((0,n.Wr)(S))},[S]);let[Z,z]=(0,r.useState)(void 0),[X,ee]=(0,r.useState)([]),[ea,et]=(0,r.useState)(!1),el=(0,r.useMemo)(()=>(0,n.SR)({floorPlans:K,selectedLeaseTerm:B,propertyData:m,showSoldOutProperties:!0,moveInDate:Z}),[K,B,m,Z]),er=(0,r.useMemo)(()=>j.reduce((e,a)=>{let t=(0,n.YB)(el,a),l=t.filter(e=>!0===e.finalAvailabilityStatus).length,r={...a,availableFloorPlans:l};return C&&l>0&&(C.current=!1),a.availableFloorPlans=l,e[a.id]={category:r,floorPlans:t},e},{}),[el,j]),ei=(0,r.useMemo)(()=>{let e=Object.values(er).map(e=>e.category),a=e.findIndex(e=>e?.availableFloorPlans&&e.availableFloorPlans>0),t=0===(e[0]?.availableFloorPlans||0),l=[...e];if(t&&a>0){let t=l[a];l.splice(a,1),l.unshift(t);let r=e.slice(0,a);r.forEach(()=>{l.splice(1,1)}),l.push(...r)}return l},[er]),eo=(0,r.useMemo)(()=>{if(!(Y.some(e=>e.isSelected)||Q.some(e=>e.isSelected))||x.current)return G;let e=er[G?.id||""]?.floorPlans||[];return(0,n.W5)(e,Y,Q).length>0?G:ei.find(e=>{let a=er[e.id]?.floorPlans||[];return(0,n.W5)(a,Y,Q).length>0})||G},[G,Y,Q,ei,er]);(0,r.useEffect)(()=>{!x.current&&eo&&eo.id!==G?.id&&$(eo),x.current=!1},[eo,G?.id]);let en=(0,r.useMemo)(()=>er[eo?.id||""]?.floorPlans||[],[er,eo]);(0,r.useEffect)(()=>{if(ei.length>0&&!x.current){let e=ei.find(e=>e?.availableFloorPlans&&e?.availableFloorPlans>0);k(d.xj.TOTAL_AVAILABLE_FLOORPLANS,e?e?.availableFloorPlans:ei[0]?.availableFloorPlans||0),$(e||ei[0])}},[er,ei]);let es=(0,r.useMemo)(()=>(0,n.W5)(en,Y,Q),[en,Y,Q]);(0,r.useEffect)(()=>{let e=[...Y.filter(e=>e.isSelected).map(e=>({value:e.title,type:"budget",data:e})),...Q.filter(e=>e.isSelected).map(e=>({value:e.title,type:"preference",data:e}))];if(ee(e),x.current=!1,!ea)return;let a=e.filter(e=>"budget"===e.type).map(e=>e.value).filter(Boolean),t=e.filter(e=>"preference"===e.type).map(e=>e.value).filter(Boolean),l=(0,s.DC)({filters:[...a,...t],country:(0,s.b8)(y),language:b||"",path:y||"",url:`https://www.canvas-world.com${h?.asPath}`,componentName:"IntegratedCard",propertyName:F||"NA"});window&&window.dataLayer&&window.dataLayer.push(l),et(!1)},[Y,Q]);let eu=(0,r.useCallback)(()=>{ei.length>0&&(x.current=!1,$(ei.find(e=>e?.availableFloorPlans&&e?.availableFloorPlans>0)||ei[0]))},[ei,$]),ec=(0,r.useCallback)(()=>{z(void 0),q(e=>e.map(e=>({...e,isSelected:!1}))),J(e=>e.map(e=>({...e,isSelected:!1})))},[q,J]),ed=(0,r.useCallback)(e=>{ec(),eu(),U(e)},[ec,eu,U]),ep=(0,r.useCallback)(e=>{x.current=!0,$(e)},[$]),ef=(0,r.useCallback)(e=>{et(!0),q(a=>a.map(a=>a.title===e.title?{...a,isSelected:!a.isSelected}:a))},[q]),em=(0,r.useCallback)(e=>{et(!0),J(a=>a.map(a=>a.title===e.title?{...a,isSelected:!a.isSelected}:a))},[J]),e_=(0,r.useCallback)(e=>{"budget"===e.type?q(a=>a.map(a=>a.title===e.data.title?{...a,isSelected:!1}:a)):"preference"===e.type&&J(a=>a.map(a=>a.title===e.data.title?{...a,isSelected:!1}:a)),et(!0)},[q,J]);(0,r.useEffect)(()=>{let{exploreRoom:e,selectUnit:a}=h.query;if(!e&&!a)return;let t=e||a,l=Array.isArray(t)?t[0]:t,r=l?decodeURIComponent(l):"";if(r&&el){let e=el.find(e=>e.name===r||e.id===r);e?.category&&$(e.category)}},[h.query,el,$]);let ev=(0,r.useMemo)(()=>({leaseTerms:M,showLeaseTermsSelector:V,propertyPMS:T,selectedLeaseTerm:B,selectLeaseTerm:ed,budgetFilters:Y,toggleBudgetFilter:ef,preferenceFilters:Q,togglePreferenceFilter:em,activeFilters:X,removeFilter:e_,clearAllFilters:ec,floorPlans:es,processedFloorPlans:el,floorPlanCategories:ei,selectedCategory:G,selectCategory:ep,hideCategoryTabs:!!_,enableLeaseTermYearGrouping:P,showMoveInDateFilter:E,moveInDate:Z,setMoveInDate:z,isAllFloorplansUnavailable:C.current}),[T,ep,ed,ec,e_,ef,em,M,V,B,Y,Q,X,es,el,ei,G,P,E,Z,z]);return(0,l.jsx)(i.IntegratedCardContext.Provider,{value:ev,children:e})}}}]);

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.