@meetelise/chat 1.71.0 → 1.72.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -5086,49 +5086,8 @@ xmlns="http://www.w3.org/2000/svg"
5086
5086
  .text-us-window__error {
5087
5087
  color: rgb(255, 49, 3);
5088
5088
  }
5089
- `],Hu([pe({attribute:!0})],zu.prototype,"buildingSlug",void 0),Hu([pe({attribute:!0})],zu.prototype,"orgSlug",void 0),Hu([pe({attribute:!1})],zu.prototype,"onCloseClicked",void 0),Hu([pe()],zu.prototype,"phoneNumberToCall",void 0),Hu([pe()],zu.prototype,"phoneNumberToText",void 0),Hu([pe({attribute:!1})],zu.prototype,"buildingId",void 0),Hu([pe({attribute:!1})],zu.prototype,"buildingName",void 0),Hu([pe({attribute:!0})],zu.prototype,"chatCallUsHeader",void 0),Hu([pe({attribute:!0})],zu.prototype,"hasCallUsEnabled",void 0),Hu([pe({attribute:!0})],zu.prototype,"hasTextUsEnabled",void 0),Hu([pe({attribute:!0})],zu.prototype,"currentLeadSource",void 0),Hu([pe({attribute:!0})],zu.prototype,"orgLegalName",void 0),Hu([pe({attribute:!1})],zu.prototype,"country",void 0),Hu([pe({attribute:!1})],zu.prototype,"buildingState",void 0),Hu([pe({attribute:!0})],zu.prototype,"leadSourceClient",void 0),Hu([pe({attribute:!0})],zu.prototype,"leadSourceMultitouchClient",void 0),Hu([fe()],zu.prototype,"hasSubmittedForm",void 0),Hu([fe()],zu.prototype,"hasPhoneNumberError",void 0),Hu([fe()],zu.prototype,"hasSubmissionError",void 0),Hu([fe()],zu.prototype,"submittingTextUsOption",void 0),Hu([pe({attribute:!1})],zu.prototype,"officeHoursTextInfo",void 0),zu=Hu([ce("call-us-window")],zu);const Gu=async(e,t,n,i,o,a,s)=>{const u="+1"+e.replace("(","").replace(")","").replace(" ","").replace("-",""),d=new URLSearchParams(window.location.search),c={building_id:t,lead_sources:o,phone_number:u,referrer:document.referrer,query_params:Object.fromEntries(d.entries()),conversation_tracking_id:a,tracking_params:l(n),lead_sources_with_timestamps:(null!=s?s:[]).map(e=>_r({...e}))};_o("textUsSubmitted",{phone:u,originatingSource:o.find(e=>"property-website"!==e)||null,conversationTrackingId:null!=a?a:null}),await r().post("https://app.meetelise.com/platformApi/state/create/textMe",c,{headers:{"building-slug":i,"org-slug":n,"X-SecurityKey":"webchatkey-wkjcWAKZjqhLStvP8L6SN8y4FbYmPhdE"}})};var Vu=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Wu=class extends ue{constructor(){super(...arguments),this.tooltip="",this.disabled=!1}render(){return H`
5090
- <div
5091
- class="tooltip-container ${this.disabled?"":"show-tooltip"}"
5092
- data-tooltip="${this.tooltip}"
5093
- >
5094
- <slot></slot>
5095
- </div>
5096
- `}};Wu.styles=p`
5097
- :host {
5098
- display: block;
5099
- position: relative;
5100
- width: 100%;
5101
- }
5102
-
5103
- .tooltip-container {
5104
- position: relative;
5105
- width: 100%;
5106
- }
5107
-
5108
- .tooltip-container.show-tooltip::after {
5109
- content: attr(data-tooltip);
5110
- position: absolute;
5111
- top: -30px;
5112
- left: 50%;
5113
- transform: translateX(-50%);
5114
- background-color: #333;
5115
- color: white;
5116
- padding: 5px 10px;
5117
- border-radius: 4px;
5118
- font-size: 12px;
5119
- white-space: nowrap;
5120
- opacity: 0;
5121
- visibility: hidden;
5122
- transition: opacity 0.3s, visibility 0.3s;
5123
- z-index: 1000;
5124
- }
5125
-
5126
- .tooltip-container.show-tooltip:hover::after {
5127
- opacity: 1;
5128
- visibility: visible;
5129
- }
5130
- `,Vu([pe({type:String})],Wu.prototype,"tooltip",void 0),Vu([pe({type:Boolean,reflect:!0})],Wu.prototype,"disabled",void 0),Wu=Vu([ce("simple-tooltip")],Wu);var Qu=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let qu=class extends ue{constructor(){super(...arguments),this.open=!1,this.inline=!1,this.onDocumentClick=e=>{!this.open||this.inline||e.composedPath().includes(this)||this.requestClose()},this.onKeydown=e=>{var t;this.open&&"Escape"===e.key&&!e.isComposing&&(e.preventDefault(),e.stopPropagation(),this.requestClose(),null===(t=this.querySelector('[slot="trigger"]'))||void 0===t||t.focus())}}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.onDocumentClick),this.addEventListener("keydown",this.onKeydown)}disconnectedCallback(){document.removeEventListener("click",this.onDocumentClick),this.removeEventListener("keydown",this.onKeydown),super.disconnectedCallback()}requestClose(){this.dispatchEvent(new CustomEvent("popover-close"))}render(){return H`<slot name="trigger"></slot>
5131
- <div class="panel" ?hidden=${!this.open}><slot></slot></div>`}};qu.styles=p`
5089
+ `],Hu([pe({attribute:!0})],zu.prototype,"buildingSlug",void 0),Hu([pe({attribute:!0})],zu.prototype,"orgSlug",void 0),Hu([pe({attribute:!1})],zu.prototype,"onCloseClicked",void 0),Hu([pe()],zu.prototype,"phoneNumberToCall",void 0),Hu([pe()],zu.prototype,"phoneNumberToText",void 0),Hu([pe({attribute:!1})],zu.prototype,"buildingId",void 0),Hu([pe({attribute:!1})],zu.prototype,"buildingName",void 0),Hu([pe({attribute:!0})],zu.prototype,"chatCallUsHeader",void 0),Hu([pe({attribute:!0})],zu.prototype,"hasCallUsEnabled",void 0),Hu([pe({attribute:!0})],zu.prototype,"hasTextUsEnabled",void 0),Hu([pe({attribute:!0})],zu.prototype,"currentLeadSource",void 0),Hu([pe({attribute:!0})],zu.prototype,"orgLegalName",void 0),Hu([pe({attribute:!1})],zu.prototype,"country",void 0),Hu([pe({attribute:!1})],zu.prototype,"buildingState",void 0),Hu([pe({attribute:!0})],zu.prototype,"leadSourceClient",void 0),Hu([pe({attribute:!0})],zu.prototype,"leadSourceMultitouchClient",void 0),Hu([fe()],zu.prototype,"hasSubmittedForm",void 0),Hu([fe()],zu.prototype,"hasPhoneNumberError",void 0),Hu([fe()],zu.prototype,"hasSubmissionError",void 0),Hu([fe()],zu.prototype,"submittingTextUsOption",void 0),Hu([pe({attribute:!1})],zu.prototype,"officeHoursTextInfo",void 0),zu=Hu([ce("call-us-window")],zu);const Gu=async(e,t,n,i,o,a,s)=>{const u="+1"+e.replace("(","").replace(")","").replace(" ","").replace("-",""),d=new URLSearchParams(window.location.search),c={building_id:t,lead_sources:o,phone_number:u,referrer:document.referrer,query_params:Object.fromEntries(d.entries()),conversation_tracking_id:a,tracking_params:l(n),lead_sources_with_timestamps:(null!=s?s:[]).map(e=>_r({...e}))};_o("textUsSubmitted",{phone:u,originatingSource:o.find(e=>"property-website"!==e)||null,conversationTrackingId:null!=a?a:null}),await r().post("https://app.meetelise.com/platformApi/state/create/textMe",c,{headers:{"building-slug":i,"org-slug":n,"X-SecurityKey":"webchatkey-wkjcWAKZjqhLStvP8L6SN8y4FbYmPhdE"}})};var Vu=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Wu=class extends ue{constructor(){super(...arguments),this.open=!1,this.inline=!1,this.onDocumentClick=e=>{!this.open||this.inline||e.composedPath().includes(this)||this.requestClose()},this.onKeydown=e=>{var t;this.open&&"Escape"===e.key&&!e.isComposing&&(e.preventDefault(),e.stopPropagation(),this.requestClose(),null===(t=this.querySelector('[slot="trigger"]'))||void 0===t||t.focus())}}connectedCallback(){super.connectedCallback(),document.addEventListener("click",this.onDocumentClick),this.addEventListener("keydown",this.onKeydown)}disconnectedCallback(){document.removeEventListener("click",this.onDocumentClick),this.removeEventListener("keydown",this.onKeydown),super.disconnectedCallback()}requestClose(){this.dispatchEvent(new CustomEvent("popover-close"))}render(){return H`<slot name="trigger"></slot>
5090
+ <div class="panel" ?hidden=${!this.open}><slot></slot></div>`}};Wu.styles=p`
5132
5091
  /* New element, from me-select's list surface and the picker's card border. */
5133
5092
  :host {
5134
5093
  display: inline-block;
@@ -5169,7 +5128,7 @@ xmlns="http://www.w3.org/2000/svg"
5169
5128
  [hidden] {
5170
5129
  display: none;
5171
5130
  }
5172
- `,Qu([pe({type:Boolean,reflect:!0})],qu.prototype,"open",void 0),Qu([pe({type:Boolean,reflect:!0})],qu.prototype,"inline",void 0),qu=Qu([ce("scheduler-popover")],qu);const Yu=p`
5131
+ `,Vu([pe({type:Boolean,reflect:!0})],Wu.prototype,"open",void 0),Vu([pe({type:Boolean,reflect:!0})],Wu.prototype,"inline",void 0),Wu=Vu([ce("scheduler-popover")],Wu);const Qu=p`
5173
5132
  :host {
5174
5133
  display: block;
5175
5134
  }
@@ -5282,7 +5241,7 @@ xmlns="http://www.w3.org/2000/svg"
5282
5241
  margin-right: 8px;
5283
5242
  }
5284
5243
  }
5285
- `,Ku=p`
5244
+ `,qu=p`
5286
5245
  :host {
5287
5246
  display: block;
5288
5247
  }
@@ -5459,12 +5418,12 @@ xmlns="http://www.w3.org/2000/svg"
5459
5418
  overflow-x: auto;
5460
5419
  }
5461
5420
  }
5462
- `,Xu=e=>({building_id:e.building_id,name:e.name,address:e.address,timezone:e.timezone,bedrooms:e.bedrooms}),Zu=e=>e?[e.line1,e.city,e.state].filter(Boolean).join(", "):"";class Ju extends Error{constructor(e,t,n){super(n),this.status=e,this.code=t,this.name="TourApiError"}}const ed=({orgSlug:e,buildingSlug:t,getSessionToken:n,host:i="https://app.meetelise.com"})=>{const o=`${i}/platformApi/webchat`,a=()=>{var i;return{"X-Session-Token":null!==(i=n())&&void 0!==i?i:"","org-slug":e,"building-slug":t}},s=async e=>{try{return(await e()).data}catch(e){throw(e=>{var t,n,i,r,o;const a=e,s=null===(n=null===(t=a.response)||void 0===t?void 0:t.data)||void 0===n?void 0:n.error;return new Ju(null!==(r=null===(i=a.response)||void 0===i?void 0:i.status)&&void 0!==r?r:0,null!==(o=null==s?void 0:s.code)&&void 0!==o?o:null,(null==s?void 0:s.message)||"Something went wrong. Please try again.")})(e)}};return{getCommunities:e=>s(()=>r().get(`${o}/tour-communities?${(e=>{const t=new URLSearchParams;return e.bedrooms.forEach(e=>t.append("bedrooms",String(e))),e.moveIn&&t.set("move_in",e.moveIn),null!==e.maxBudget&&t.set("max_budget",String(e.maxBudget)),e.extend&&(t.set("available_after",e.extend.availableAfter),t.set("tour_type",e.extend.tourType),t.set("near_building_id",String(e.extend.nearBuildingId)),e.extend.excludeBuildingIds.forEach(e=>t.append("exclude_building_ids",String(e)))),t})(e)}`,{headers:a()})),plan:e=>s(()=>r().post(`${o}/tour-itineraries/plan`,e,{headers:a()})),book:(e,t)=>s(()=>r().post(`${o}/tour-itineraries`,e,{headers:{...a(),"Idempotency-Key":t}}))}},td=e=>e.slice(0,10),nd=e=>e.slice(11,16),id=e=>{const[t,n]=e.split(":");return{hour:parseInt(t,10),minute:n}},rd=e=>e<12?"am":"pm",od=(e,t)=>`${e%12==0?12:e%12}:${t}`,ad=e=>{const{hour:t,minute:n}=id(e);return`${od(t,n)}${rd(t)}`},sd=e=>ad(nd(e)),ld=(e,t)=>{const n=id(nd(e)),i=id(nd(t));return`${rd(n.hour)===rd(i.hour)?od(n.hour,n.minute):ad(nd(e))}–${ad(nd(t))}`},ud=e=>{const[t,n,i]=e.split("-").map(e=>parseInt(e,10));return new Date(t,n-1,i)},dd=e=>ir(ud(e),"EEE, MMM d"),cd=e=>ir(ud(e),"MMM d"),hd=e=>ir(e,"yyyy-MM-dd"),pd={"escorted-tour":{heading:"Escorted Tour",subtitle:"With an agent",icon:pa},"live-virtual-tour":{heading:"Virtual Tour",subtitle:"Over video",icon:ca},"self-guided-tour":{heading:"Self-Guided Tour",subtitle:"On your own",icon:ha}},fd=["escorted-tour","live-virtual-tour","self-guided-tour"];var gd=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const md={bedrooms:[],moveIn:null,maxBudget:null},bd=[{value:0,label:"Studio"},{value:1,label:"1 bd"},{value:2,label:"2 bd"},{value:3,label:"3+ bd"}],yd=["bedrooms","moveIn","budget"];let vd=class extends ue{constructor(){super(...arguments),this.variant="select",this.load=null,this.initial=null,this.selected=[],this.maxSelectable=0,this.filters=md,this.openFilter=null,this.communities=[],this.loading=!1,this.error=null,this.mobile=Ir(),this.requestId=0}connectedCallback(){super.connectedCallback(),this.cleanupMobileListener=Nr(e=>this.mobile=e)}disconnectedCallback(){var e;null===(e=this.cleanupMobileListener)||void 0===e||e.call(this),super.disconnectedCallback()}get initialPage(){return yd.some(e=>this.isFilterActive(e))?null:this.initial}willUpdate(){const e=this.initialPage;!this.hasUpdated&&e&&(this.communities=e.communities)}firstUpdated(){this.initialPage||this.reload()}async reload(){if(!this.load)return;const e=++this.requestId;this.loading=!0,this.error=null;try{const t=await this.load(this.filters);if(e!==this.requestId)return;this.communities=t.communities}catch(t){if(e!==this.requestId)return;this.error=t.message}finally{e===this.requestId&&(this.loading=!1)}}setFilters(e){this.filters={...this.filters,...e},this.dispatchEvent(new CustomEvent("filters-change",{detail:{filters:this.filters},bubbles:!0,composed:!0})),this.reload()}isSelected(e){return this.selected.some(t=>t.building_id===e)}toggle(e){e.tourable&&(1===this.maxSelectable?this.emitSelection([Xu(e)]):this.isSelected(e.building_id)?this.emitSelection(this.selected.filter(t=>t.building_id!==e.building_id)):this.selected.length<this.maxSelectable&&this.emitSelection([...this.selected,Xu(e)]))}emitSelection(e){this.dispatchEvent(new CustomEvent("selection-change",{detail:{communities:e},bubbles:!0,composed:!0}))}heading(){return"extend"===this.variant?"Add Nearby Communities to Your Tour":this.maxSelectable>1?`Select Up to ${this.maxSelectable} Communities to Tour`:"Select a Community to Tour"}isFilterActive(e){const t=this.filters;return"bedrooms"===e?t.bedrooms.length>0:"moveIn"===e?!!t.moveIn:null!==t.maxBudget}filterLabel(e){const t=this.filters;return"bedrooms"===e?t.bedrooms.length?t.bedrooms.map(e=>{var t,n;return null!==(n=null===(t=bd.find(t=>t.value===e))||void 0===t?void 0:t.label)&&void 0!==n?n:`${e} bd`}).join(", "):"Bedrooms":"moveIn"===e?t.moveIn?`Move-in ${dd(t.moveIn)}`:"Move-In Date":null!==t.maxBudget?`Up to ${Br(t.maxBudget)}`:"Budget"}renderFilterPanel(e){var t;const n=this.filters;return"bedrooms"===e?H`<div
5421
+ `,Yu=e=>({building_id:e.building_id,name:e.name,address:e.address,timezone:e.timezone,bedrooms:e.bedrooms}),Ku=e=>e?[e.line1,e.city,e.state].filter(Boolean).join(", "):"";class Xu extends Error{constructor(e,t,n){super(n),this.status=e,this.code=t,this.name="TourApiError"}}const Zu=({orgSlug:e,buildingSlug:t,getSessionToken:n,host:i="https://app.meetelise.com"})=>{const o=`${i}/platformApi/webchat`,a=()=>{var i;return{"X-Session-Token":null!==(i=n())&&void 0!==i?i:"","org-slug":e,"building-slug":t}},s=async e=>{try{return(await e()).data}catch(e){throw(e=>{var t,n,i,r,o;const a=e,s=null===(n=null===(t=a.response)||void 0===t?void 0:t.data)||void 0===n?void 0:n.error;return new Xu(null!==(r=null===(i=a.response)||void 0===i?void 0:i.status)&&void 0!==r?r:0,null!==(o=null==s?void 0:s.code)&&void 0!==o?o:null,(null==s?void 0:s.message)||"Something went wrong. Please try again.")})(e)}};return{getCommunities:e=>s(()=>r().get(`${o}/tour-communities?${(e=>{const t=new URLSearchParams;return e.bedrooms.forEach(e=>t.append("bedrooms",String(e))),e.moveIn&&t.set("move_in",e.moveIn),null!==e.maxBudget&&t.set("max_budget",String(e.maxBudget)),e.extend&&(t.set("available_after",e.extend.availableAfter),t.set("tour_type",e.extend.tourType),t.set("near_building_id",String(e.extend.nearBuildingId)),e.extend.excludeBuildingIds.forEach(e=>t.append("exclude_building_ids",String(e)))),t})(e)}`,{headers:a()})),plan:e=>s(()=>r().post(`${o}/tour-itineraries/plan`,e,{headers:a()})),book:(e,t)=>s(()=>r().post(`${o}/tour-itineraries`,e,{headers:{...a(),"Idempotency-Key":t}}))}},Ju=e=>e.slice(0,10),ed=e=>e.slice(11,16),td=e=>{const[t,n]=e.split(":");return{hour:parseInt(t,10),minute:n}},nd=e=>e<12?"am":"pm",id=(e,t)=>`${e%12==0?12:e%12}:${t}`,rd=e=>{const{hour:t,minute:n}=td(e);return`${id(t,n)}${nd(t)}`},od=e=>rd(ed(e)),ad=(e,t)=>{const n=td(ed(e)),i=td(ed(t));return`${nd(n.hour)===nd(i.hour)?id(n.hour,n.minute):rd(ed(e))}–${rd(ed(t))}`},sd=e=>{const[t,n,i]=e.split("-").map(e=>parseInt(e,10));return new Date(t,n-1,i)},ld=e=>ir(sd(e),"EEE, MMM d"),ud=e=>ir(sd(e),"MMM d"),dd=e=>ir(e,"yyyy-MM-dd"),cd={"escorted-tour":{heading:"Escorted Tour",subtitle:"With an agent",icon:pa},"live-virtual-tour":{heading:"Virtual Tour",subtitle:"Over video",icon:ca},"self-guided-tour":{heading:"Self-Guided Tour",subtitle:"On your own",icon:ha}},hd=["escorted-tour","live-virtual-tour","self-guided-tour"];var pd=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const fd={bedrooms:[],moveIn:null,maxBudget:null},gd=[{value:0,label:"Studio"},{value:1,label:"1 bd"},{value:2,label:"2 bd"},{value:3,label:"3+ bd"}],md=["bedrooms","moveIn","budget"];let bd=class extends ue{constructor(){super(...arguments),this.variant="select",this.load=null,this.initial=null,this.selected=[],this.filters=fd,this.openFilter=null,this.communities=[],this.loading=!1,this.error=null,this.mobile=Ir(),this.requestId=0}connectedCallback(){super.connectedCallback(),this.cleanupMobileListener=Nr(e=>this.mobile=e)}disconnectedCallback(){var e;null===(e=this.cleanupMobileListener)||void 0===e||e.call(this),super.disconnectedCallback()}get initialPage(){return md.some(e=>this.isFilterActive(e))?null:this.initial}willUpdate(){const e=this.initialPage;!this.hasUpdated&&e&&(this.communities=e.communities)}firstUpdated(){this.initialPage||this.reload()}async reload(){if(!this.load)return;const e=++this.requestId;this.loading=!0,this.error=null;try{const t=await this.load(this.filters);if(e!==this.requestId)return;this.communities=t.communities}catch(t){if(e!==this.requestId)return;this.error=t.message}finally{e===this.requestId&&(this.loading=!1)}}setFilters(e){this.filters={...this.filters,...e},this.dispatchEvent(new CustomEvent("filters-change",{detail:{filters:this.filters},bubbles:!0,composed:!0})),this.reload()}isSelected(e){return this.selected.some(t=>t.building_id===e)}toggle(e){e.tourable&&this.emitSelection([Yu(e)])}emitSelection(e){this.dispatchEvent(new CustomEvent("selection-change",{detail:{communities:e},bubbles:!0,composed:!0}))}heading(){return"extend"===this.variant?"Add Nearby Communities to Your Tour":"Select a Community to Tour"}isFilterActive(e){const t=this.filters;return"bedrooms"===e?t.bedrooms.length>0:"moveIn"===e?!!t.moveIn:null!==t.maxBudget}filterLabel(e){const t=this.filters;return"bedrooms"===e?t.bedrooms.length?t.bedrooms.map(e=>{var t,n;return null!==(n=null===(t=gd.find(t=>t.value===e))||void 0===t?void 0:t.label)&&void 0!==n?n:`${e} bd`}).join(", "):"Bedrooms":"moveIn"===e?t.moveIn?`Move-in ${ld(t.moveIn)}`:"Move-In Date":null!==t.maxBudget?`Up to ${Br(t.maxBudget)}`:"Budget"}renderFilterPanel(e){var t;const n=this.filters;return"bedrooms"===e?H`<div
5463
5422
  class="floor-plan-selector-badges"
5464
5423
  role="group"
5465
5424
  aria-label="Bedrooms"
5466
5425
  >
5467
- ${bd.map(e=>H`<button
5426
+ ${gd.map(e=>H`<button
5468
5427
  class=${Ce({"floor-plan-badge":!0,selected:n.bedrooms.includes(e.value)})}
5469
5428
  aria-pressed=${String(n.bedrooms.includes(e.value))}
5470
5429
  @click=${()=>this.setFilters({bedrooms:n.bedrooms.includes(e.value)?n.bedrooms.filter(t=>t!==e.value):[...n.bedrooms,e.value].sort()})}
@@ -5491,7 +5450,7 @@ xmlns="http://www.w3.org/2000/svg"
5491
5450
  @change=${e=>{const t=parseInt(e.target.value,10);this.openFilter=null,this.setFilters({maxBudget:Number.isFinite(t)&&t>0?t:null})}}
5492
5451
  />
5493
5452
  </div>`}renderFilters(){const e=this.openFilter;return H`<div class="picker-toolbar" role="group" aria-label="Filters">
5494
- ${yd.map(t=>H`<scheduler-popover
5453
+ ${md.map(t=>H`<scheduler-popover
5495
5454
  ?open=${e===t}
5496
5455
  ?inline=${this.mobile}
5497
5456
  @popover-close=${()=>{this.openFilter===t&&(this.openFilter=null)}}
@@ -5509,44 +5468,41 @@ xmlns="http://www.w3.org/2000/svg"
5509
5468
  ${e===t?this.renderFilterPanel(t):""}
5510
5469
  </div>
5511
5470
  </scheduler-popover>`)}
5512
- ${yd.some(e=>this.isFilterActive(e))?H`<button
5471
+ ${md.some(e=>this.isFilterActive(e))?H`<button
5513
5472
  class="clear-filters"
5514
- @click=${()=>{this.openFilter=null,this.setFilters(md)}}
5473
+ @click=${()=>{this.openFilter=null,this.setFilters(fd)}}
5515
5474
  >
5516
5475
  Clear all
5517
5476
  </button>`:""}
5518
- </div>`}renderCard(e){var t;const n=this.isSelected(e.building_id),i=this.maxSelectable>1&&!n&&this.selected.length>=this.maxSelectable,r=e.next_available,o=!!r&&"extend"===this.variant,a=e.price_from?`${0===e.price_from.bedrooms?"Studio":`${e.price_from.bedrooms} BR`} from ${Br(e.price_from.amount)}`:"",s=H`<button
5519
- class=${Ce({"floorplan-image-card":!0,selected:n,disabled:!e.tourable||i})}
5520
- aria-pressed=${String(n)}
5521
- aria-disabled=${String(!e.tourable||i)}
5522
- @click=${()=>this.toggle(e)}
5523
- >
5524
- ${e.image_url?H`<span class="section-left"
5525
- ><img src=${e.image_url} alt=""
5526
- /></span>`:""}
5527
- <span class="section-right">
5528
- ${e.best_match||a||null!==e.distance_mi?H`<span class="card-tags">
5529
- ${e.best_match?H`<span class="floor-plan-badge">Best match</span>`:""}
5530
- ${a?H`<span class="floor-plan-badge">${a}</span>`:""}
5531
- ${null!==e.distance_mi?H`<span class="distance"
5532
- >${e.distance_mi.toFixed(1)} mi</span
5533
- >`:""}
5534
- </span>`:""}
5535
- <span class="image-card-title">${e.name}</span>
5536
- <span class="image-card-subtitle">${Zu(e.address)}</span>
5537
- ${e.tourable?r?H`<span class="next-available"
5538
- >Next available:
5539
- ${dd(r.date)}${"extend"===this.variant?` · ${ad(r.time)}`:""}</span
5540
- >`:"":H`<span class="image-card-subtitle"
5541
- >${null!==(t=e.unavailable_reason)&&void 0!==t?t:""}</span
5542
- >`}
5543
- ${o?H`<span class="same-day">Same day</span>`:""}
5544
- </span>
5545
- </button>`;return H`<li>
5546
- ${i&&e.tourable?H`<simple-tooltip
5547
- tooltip=${`You can choose up to ${this.maxSelectable}`}
5548
- >${s}</simple-tooltip
5549
- >`:s}
5477
+ </div>`}renderCard(e){var t;const n=this.isSelected(e.building_id),i=e.next_available,r=!!i&&"extend"===this.variant,o=e.price_from?`${0===e.price_from.bedrooms?"Studio":`${e.price_from.bedrooms} BR`} from ${Br(e.price_from.amount)}`:"";return H`<li>
5478
+ <button
5479
+ class=${Ce({"floorplan-image-card":!0,selected:n,disabled:!e.tourable})}
5480
+ aria-pressed=${String(n)}
5481
+ aria-disabled=${String(!e.tourable)}
5482
+ @click=${()=>this.toggle(e)}
5483
+ >
5484
+ ${e.image_url?H`<span class="section-left"
5485
+ ><img src=${e.image_url} alt=""
5486
+ /></span>`:""}
5487
+ <span class="section-right">
5488
+ ${e.best_match||o||null!==e.distance_mi?H`<span class="card-tags">
5489
+ ${e.best_match?H`<span class="floor-plan-badge">Best match</span>`:""}
5490
+ ${o?H`<span class="floor-plan-badge">${o}</span>`:""}
5491
+ ${null!==e.distance_mi?H`<span class="distance"
5492
+ >${e.distance_mi.toFixed(1)} mi</span
5493
+ >`:""}
5494
+ </span>`:""}
5495
+ <span class="image-card-title">${e.name}</span>
5496
+ <span class="image-card-subtitle">${Ku(e.address)}</span>
5497
+ ${e.tourable?i?H`<span class="next-available"
5498
+ >Next available:
5499
+ ${ld(i.date)}${"extend"===this.variant?` · ${rd(i.time)}`:""}</span
5500
+ >`:"":H`<span class="image-card-subtitle"
5501
+ >${null!==(t=e.unavailable_reason)&&void 0!==t?t:""}</span
5502
+ >`}
5503
+ ${r?H`<span class="same-day">Same day</span>`:""}
5504
+ </span>
5505
+ </button>
5550
5506
  </li>`}renderList(){return this.loading&&0===this.communities.length?H`<div class="community-grid" role="status">
5551
5507
  <span class="sr-only">Loading communities</span>
5552
5508
  ${[0,1,2,3].map(()=>H`<div class="unit-card-skeleton shimmer"></div>`)}
@@ -5588,7 +5544,7 @@ xmlns="http://www.w3.org/2000/svg"
5588
5544
  ${this.loading?"Loading communities":`${this.communities.length} communities`}
5589
5545
  </span>
5590
5546
  ${this.renderList()}
5591
- </div>`}};vd.styles=[Ko,Me,Ku,Yu,p`
5547
+ </div>`}};bd.styles=[Ko,Me,qu,Qu,p`
5592
5548
  /* New layout only: the filter chips and the card grid. */
5593
5549
  :host {
5594
5550
  display: block;
@@ -5774,45 +5730,7 @@ xmlns="http://www.w3.org/2000/svg"
5774
5730
  border-top: 1px solid #e7e7e7;
5775
5731
  padding-top: 24px;
5776
5732
  }
5777
- `],gd([pe({type:String})],vd.prototype,"variant",void 0),gd([pe({attribute:!1})],vd.prototype,"load",void 0),gd([pe({attribute:!1})],vd.prototype,"initial",void 0),gd([pe({attribute:!1})],vd.prototype,"selected",void 0),gd([pe({type:Number})],vd.prototype,"maxSelectable",void 0),gd([pe({attribute:!1})],vd.prototype,"filters",void 0),gd([fe()],vd.prototype,"openFilter",void 0),gd([fe()],vd.prototype,"communities",void 0),gd([fe()],vd.prototype,"loading",void 0),gd([fe()],vd.prototype,"error",void 0),gd([fe()],vd.prototype,"mobile",void 0),vd=gd([ce("community-picker")],vd);const wd=p`
5778
- .tray {
5779
- gap: 12px;
5780
- }
5781
-
5782
- .tray .floor-plan-selector-badges {
5783
- display: flex;
5784
- flex-wrap: wrap;
5785
- gap: 8px;
5786
- list-style: none;
5787
- margin: 0;
5788
- padding: 0;
5789
- }
5790
-
5791
- .tray .floor-plan-badge {
5792
- align-items: center;
5793
- background: #f3f3f3;
5794
- border: 1px solid #e7e7e7;
5795
- border-radius: 16px;
5796
- display: inline-flex;
5797
- font-size: 13px;
5798
- gap: 6px;
5799
- padding: 6px 12px;
5800
- white-space: nowrap;
5801
- }
5802
-
5803
- .remove {
5804
- background: none;
5805
- border: none;
5806
- cursor: pointer;
5807
- display: inline-flex;
5808
- padding: 0;
5809
- }
5810
-
5811
- .remove svg {
5812
- height: 9px;
5813
- width: 9px;
5814
- }
5815
- `,Cd=p`
5733
+ `],pd([pe({type:String})],bd.prototype,"variant",void 0),pd([pe({attribute:!1})],bd.prototype,"load",void 0),pd([pe({attribute:!1})],bd.prototype,"initial",void 0),pd([pe({attribute:!1})],bd.prototype,"selected",void 0),pd([pe({attribute:!1})],bd.prototype,"filters",void 0),pd([fe()],bd.prototype,"openFilter",void 0),pd([fe()],bd.prototype,"communities",void 0),pd([fe()],bd.prototype,"loading",void 0),pd([fe()],bd.prototype,"error",void 0),pd([fe()],bd.prototype,"mobile",void 0),bd=pd([ce("community-picker")],bd);const yd=p`
5816
5734
  .stops {
5817
5735
  list-style: none;
5818
5736
  margin: 0 0 12px;
@@ -5849,19 +5767,36 @@ xmlns="http://www.w3.org/2000/svg"
5849
5767
  font-size: 0.9rem;
5850
5768
  margin: 4px 0;
5851
5769
  }
5852
- `;var xd=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const $d=e=>({displayTime:sd(e),displayTimeZoned:sd(e),dateWithTimeZoneOffset:{datetime:e.slice(0,19),offset:e.slice(19)}}),Sd=(e,t,n)=>{e.dispatchEvent(new CustomEvent(t,{detail:n,bubbles:!0,composed:!0}))};let kd=class extends ue{constructor(){super(...arguments),this.stops=[],this.communities=new Map,this.problems=[],this.tourTypes=[],this.tourType=null,this.bookableDates=[],this.date=null,this.single=!1,this.canEditCommunities=!1,this.loading=!1,this.planned=!1,this.primaryColor=Zn,this.foregroundColorOnPrimaryBackgroundColor="white",this.editingTimeFor=null,this.dragIndex=null,this.dropIndex=null,this.refocusGripOf=null}get offersKnown(){return this.planned&&!this.loading}get selectedTypeOpensLink(){var e;return!!(null===(e=this.tourTypes.find(e=>e.id===this.tourType))||void 0===e?void 0:e.opensLink)}newStopIds(){return this.stops.filter(e=>!e.fixed).map(e=>e.building_id)}name(e){var t,n;return null!==(n=null===(t=this.communities.get(e))||void 0===t?void 0:t.name)&&void 0!==n?n:""}move(e,t){const n=this.newStopIds();if(t<0||t>=n.length||e===t)return;const[i]=n.splice(e,1);n.splice(t,0,i),Sd(this,"stops-reorder",{buildingIds:n})}newIndexAt(e){var t;const n=[...this.renderRoot.querySelectorAll(".stop-item[data-index]")],i=null!==(t=n.find(t=>e<t.getBoundingClientRect().bottom))&&void 0!==t?t:n[n.length-1];return i?Number(i.dataset.index):null}updated(e){var t;e.has("stops")&&null!==this.refocusGripOf&&(null===(t=this.renderRoot.querySelector(`.grip[data-building-id="${this.refocusGripOf}"]`))||void 0===t||t.focus(),this.refocusGripOf=null)}endDrag(e){e&&null!==this.dragIndex&&null!==this.dropIndex&&this.move(this.dragIndex,this.dropIndex),this.dragIndex=null,this.dropIndex=null}renderCommunity(){var e,t,n;if(!this.single)return"";const i=null===(e=this.stops.find(e=>!e.fixed))||void 0===e?void 0:e.building_id,r=void 0===i?void 0:this.communities.get(i);return H`<h2 class="journey-header">Community</h2>
5770
+ `,vd=(e="currentColor")=>z`<svg
5771
+ aria-hidden="true"
5772
+ focusable="false"
5773
+ width="16"
5774
+ height="16"
5775
+ viewBox="0 0 24 24"
5776
+ fill="none"
5777
+ xmlns="http://www.w3.org/2000/svg"
5778
+ >
5779
+ <path
5780
+ d="M4 20h4L19 9l-4-4L4 16v4z M13.5 6.5l4 4"
5781
+ stroke="${e}"
5782
+ stroke-width="1.75"
5783
+ stroke-linecap="round"
5784
+ stroke-linejoin="round"
5785
+ />
5786
+ </svg>`;var wd=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const Cd=e=>({displayTime:od(e),displayTimeZoned:od(e),dateWithTimeZoneOffset:{datetime:e.slice(0,19),offset:e.slice(19)}}),xd=(e,t,n)=>{e.dispatchEvent(new CustomEvent(t,{detail:n,bubbles:!0,composed:!0}))};let $d=class extends ue{constructor(){super(...arguments),this.stops=[],this.communities=new Map,this.problems=[],this.tourTypes=[],this.tourType=null,this.bookableDates=[],this.date=null,this.single=!1,this.canEditCommunities=!1,this.stopsOnly=!1,this.canAddStop=!1,this.loading=!1,this.planned=!1,this.primaryColor=Zn,this.foregroundColorOnPrimaryBackgroundColor="white",this.editingTimeFor=null,this.dragIndex=null,this.dropIndex=null,this.refocusGripOf=null}get offersKnown(){return this.planned&&!this.loading}get selectedTypeOpensLink(){var e;return!!(null===(e=this.tourTypes.find(e=>e.id===this.tourType))||void 0===e?void 0:e.opensLink)}newStopIds(){return this.stops.filter(e=>!e.fixed).map(e=>e.building_id)}name(e){var t,n;return null!==(n=null===(t=this.communities.get(e))||void 0===t?void 0:t.name)&&void 0!==n?n:""}move(e,t){const n=this.newStopIds();if(t<0||t>=n.length||e===t)return;const[i]=n.splice(e,1);n.splice(t,0,i),xd(this,"stops-reorder",{buildingIds:n})}newIndexAt(e){var t;const n=[...this.renderRoot.querySelectorAll(".stop-item[data-index]")],i=null!==(t=n.find(t=>e<t.getBoundingClientRect().bottom))&&void 0!==t?t:n[n.length-1];return i?Number(i.dataset.index):null}updated(e){var t;e.has("stops")&&null!==this.refocusGripOf&&(null===(t=this.renderRoot.querySelector(`.grip[data-building-id="${this.refocusGripOf}"]`))||void 0===t||t.focus(),this.refocusGripOf=null)}endDrag(e){e&&null!==this.dragIndex&&null!==this.dropIndex&&this.move(this.dragIndex,this.dropIndex),this.dragIndex=null,this.dropIndex=null}renderCommunity(){var e,t,n;if(!this.single)return"";const i=null===(e=this.stops.find(e=>!e.fixed))||void 0===e?void 0:e.building_id,r=void 0===i?void 0:this.communities.get(i);return H`<h2 class="journey-header">Community</h2>
5853
5787
  <div class="floorplan-image-card community">
5854
5788
  <div class="section-right">
5855
5789
  <p class="image-card-title">${null!==(t=null==r?void 0:r.name)&&void 0!==t?t:""}</p>
5856
5790
  <p class="image-card-subtitle">
5857
- ${Zu(null!==(n=null==r?void 0:r.address)&&void 0!==n?n:null)}
5791
+ ${Ku(null!==(n=null==r?void 0:r.address)&&void 0!==n?n:null)}
5858
5792
  </p>
5859
5793
  </div>
5860
5794
  ${this.canEditCommunities?H`<button
5861
- class="floor-plan-badge"
5862
- @click=${()=>Sd(this,"edit-communities",{})}
5795
+ class="icon-button change-community"
5796
+ aria-label="Change community"
5797
+ @click=${()=>xd(this,"edit-communities",{})}
5863
5798
  >
5864
- Change
5799
+ ${vd()}
5865
5800
  </button>`:""}
5866
5801
  </div> `}renderTourTypes(){return H`<h2 id="tour-type-heading" class="journey-header">Tour Type</h2>
5867
5802
  <div
@@ -5869,17 +5804,17 @@ xmlns="http://www.w3.org/2000/svg"
5869
5804
  role="radiogroup"
5870
5805
  aria-labelledby="tour-type-heading"
5871
5806
  >
5872
- ${this.tourTypes.map(({id:e})=>{const t=e===this.tourType,n=()=>Sd(this,"tour-type-change",{tourType:e});return H`<tour-type-option
5807
+ ${this.tourTypes.map(({id:e})=>{const t=e===this.tourType,n=()=>xd(this,"tour-type-change",{tourType:e});return H`<tour-type-option
5873
5808
  outlined
5874
- heading=${pd[e].heading}
5875
- subtitle=${pd[e].subtitle}
5809
+ heading=${cd[e].heading}
5810
+ subtitle=${cd[e].subtitle}
5876
5811
  .primaryColor=${this.primaryColor}
5877
5812
  .foregroundColorOnPrimaryBackgroundColor=${this.foregroundColorOnPrimaryBackgroundColor}
5878
5813
  ?selected=${t}
5879
5814
  @click=${n}
5880
5815
  @keydown=${e=>{[" ","Enter"].includes(e.key)&&(e.preventDefault(),n())}}
5881
5816
  >
5882
- ${pd[e].icon(t?this.primaryColor:oi)}
5817
+ ${cd[e].icon(t?this.primaryColor:oi)}
5883
5818
  </tour-type-option>`})}
5884
5819
  </div>
5885
5820
  ${0===this.tourTypes.length&&this.offersKnown?H`<p class="explanation">
@@ -5887,20 +5822,20 @@ xmlns="http://www.w3.org/2000/svg"
5887
5822
  </p>`:""}`}renderDatePicker(){var e;const t=null!==(e=this.date)&&void 0!==e?e:this.bookableDates[0];return H`<date-picker
5888
5823
  outlined
5889
5824
  .shownMonth=${null==t?void 0:t.slice(0,7)}
5890
- .availabilities=${Object.fromEntries(this.bookableDates.map(e=>[e,[ud(e)]]))}
5891
- .defaultDate=${this.date?ud(this.date):void 0}
5892
- @change=${e=>{const t=e.target.selectedDate;t&&hd(t)!==this.date&&Sd(this,"date-change",{date:hd(t)})}}
5825
+ .availabilities=${Object.fromEntries(this.bookableDates.map(e=>[e,[sd(e)]]))}
5826
+ .defaultDate=${this.date?sd(this.date):void 0}
5827
+ @change=${e=>{const t=e.target.selectedDate;t&&dd(t)!==this.date&&xd(this,"date-change",{date:dd(t)})}}
5893
5828
  ></date-picker>`}renderTimePicker(e){const t=[...new Set([e.start,...e.alternatives])].sort();return H`<time-picker
5894
5829
  selecteddateexists
5895
5830
  .timezone=${e.timezone}
5896
- .options=${t.map($d)}
5897
- .defaultSelectedTime=${$d(e.start)}
5898
- @change=${t=>{const n=t.target.selectedTime;if(!n)return void(t.target.defaultSelectedTime=$d(e.start));const i=`${n.dateWithTimeZoneOffset.datetime}${n.dateWithTimeZoneOffset.offset}`;this.editingTimeFor=null,i!==e.start&&Sd(this,"stop-time-change",{buildingId:e.building_id,start:i})}}
5831
+ .options=${t.map(Cd)}
5832
+ .defaultSelectedTime=${Cd(e.start)}
5833
+ @change=${t=>{const n=t.target.selectedTime;if(!n)return void(t.target.defaultSelectedTime=Cd(e.start));const i=`${n.dateWithTimeZoneOffset.datetime}${n.dateWithTimeZoneOffset.offset}`;this.editingTimeFor=null,i!==e.start&&xd(this,"stop-time-change",{buildingId:e.building_id,start:i})}}
5899
5834
  ></time-picker>`}renderLinkPrompt(){return H`<h2 class="journey-header">Date and Time</h2>
5900
5835
  <div id="dateAndTimeMenu">
5901
5836
  <button
5902
5837
  id="self-guided-redirect-bttn"
5903
- @click=${()=>Sd(this,"open-tour-link",{})}
5838
+ @click=${()=>xd(this,"open-tour-link",{})}
5904
5839
  >
5905
5840
  View Tour Times
5906
5841
  </button>
@@ -5914,7 +5849,7 @@ xmlns="http://www.w3.org/2000/svg"
5914
5849
  ${0===this.bookableDates.length&&this.offersKnown?"No tour times in the next 30 days.":""}
5915
5850
  </p>`}
5916
5851
  </div>
5917
- </div>`}renderStop(e,t){var n,i,r,o,a;const s=this.communities.get(e.building_id),l=this.newStopIds(),u=l.indexOf(e.building_id),d=this.editingTimeFor===e.building_id,c=!e.fixed&&l.length>1,h=!e.fixed&&e.alternatives.some(t=>t!==e.start),p=`${cd(td(e.start))} · ${ld(e.start,e.end)}`,f=null!==this.dragIndex;return H`<li
5852
+ </div>`}renderStop(e,t){var n,i,r,o,a;const s=this.communities.get(e.building_id),l=this.newStopIds(),u=l.indexOf(e.building_id),d=this.editingTimeFor===e.building_id,c=!e.fixed&&l.length>1,h=!e.fixed&&e.alternatives.some(t=>t!==e.start),p=`${ud(Ju(e.start))} · ${ad(e.start,e.end)}`,f=null!==this.dragIndex;return H`<li
5918
5853
  class=${Ce({"stop-item":!0,dragging:f&&this.dragIndex===u,"drop-target":f&&this.dropIndex===u&&this.dragIndex!==u})}
5919
5854
  data-index=${e.fixed?V:u}
5920
5855
  >
@@ -5960,7 +5895,7 @@ xmlns="http://www.w3.org/2000/svg"
5960
5895
  ${null!==(i=null==s?void 0:s.name)&&void 0!==i?i:""}
5961
5896
  </p>
5962
5897
  <p class="image-card-subtitle">
5963
- ${Zu(null!==(r=null==s?void 0:s.address)&&void 0!==r?r:null)}
5898
+ ${Ku(null!==(r=null==s?void 0:s.address)&&void 0!==r?r:null)}
5964
5899
  </p>
5965
5900
  ${h?H`<button
5966
5901
  class="stop-time edit-time"
@@ -5968,35 +5903,19 @@ xmlns="http://www.w3.org/2000/svg"
5968
5903
  aria-label=${`Change the time at ${null!==(o=null==s?void 0:s.name)&&void 0!==o?o:""}`}
5969
5904
  @click=${()=>this.editingTimeFor=d?null:e.building_id}
5970
5905
  >
5971
- ${p} ${((e="currentColor")=>z`<svg
5972
- aria-hidden="true"
5973
- focusable="false"
5974
- width="16"
5975
- height="16"
5976
- viewBox="0 0 24 24"
5977
- fill="none"
5978
- xmlns="http://www.w3.org/2000/svg"
5979
- >
5980
- <path
5981
- d="M4 20h4L19 9l-4-4L4 16v4z M13.5 6.5l4 4"
5982
- stroke="${e}"
5983
- stroke-width="1.75"
5984
- stroke-linecap="round"
5985
- stroke-linejoin="round"
5986
- />
5987
- </svg>`)()}
5906
+ ${p} ${vd()}
5988
5907
  </button>`:H`<p class="stop-time">
5989
5908
  ${p}
5990
5909
  ${e.fixed?H`<span class="floor-plan-badge selected">Booked</span>`:""}
5991
5910
  </p>`}
5992
5911
  ${d?this.renderTimePicker(e):""}
5993
5912
  </div>
5994
- ${!e.fixed&&(l.length>1||this.problems.length>0)?this.renderRemove(e.building_id,null!==(a=null==s?void 0:s.name)&&void 0!==a?a:""):""}
5913
+ ${!e.fixed&&(l.length>1||this.problems.length>0||this.stopsOnly)?this.renderRemove(e.building_id,null!==(a=null==s?void 0:s.name)&&void 0!==a?a:""):""}
5995
5914
  </div>
5996
5915
  </li>`}renderRemove(e,t){return H`<button
5997
5916
  class="icon-button remove"
5998
5917
  aria-label=${`Remove ${t}`}
5999
- @click=${()=>Sd(this,"stop-remove",{buildingId:e})}
5918
+ @click=${()=>xd(this,"stop-remove",{buildingId:e})}
6000
5919
  >
6001
5920
  ${((e="currentColor")=>z`<svg
6002
5921
  aria-hidden="true"
@@ -6028,19 +5947,25 @@ xmlns="http://www.w3.org/2000/svg"
6028
5947
  ${0===this.bookableDates.length&&this.offersKnown?H`<p class="explanation">
6029
5948
  These communities have no back-to-back tour times in the next 30
6030
5949
  days. Try removing one.
6031
- </p>`:""}`}renderItinerary(){return H`<h2 class="journey-header">
5950
+ </p>`:""}`}renderStops(){return H`<ol class="stops" aria-busy=${String(this.loading)}>
5951
+ ${this.stops.map((e,t)=>this.renderStop(e,t))}
5952
+ ${this.problems.map(e=>this.renderProblem(e))}
5953
+ </ol>`}renderItinerary(){return H`<h2 class="journey-header">
6032
5954
  Your Itinerary ${this.loading?H`<mini-loader></mini-loader>`:""}
6033
5955
  </h2>
6034
- <ol class="stops" aria-busy=${String(this.loading)}>
6035
- ${this.stops.map((e,t)=>this.renderStop(e,t))}
6036
- ${this.problems.map(e=>this.renderProblem(e))}
6037
- </ol>`}render(){const e=!this.selectedTypeOpensLink&&!this.single;return H`<div id="tour-type-menu-outer-container">
5956
+ ${this.renderStops()}`}render(){if(this.stopsOnly)return H`${this.renderStops()}
5957
+ ${this.canAddStop?H`<button
5958
+ class="floor-plan-badge add-stop"
5959
+ @click=${()=>xd(this,"add-stop",{})}
5960
+ >
5961
+ + Add another stop
5962
+ </button>`:""}`;const e=!this.selectedTypeOpensLink&&!this.single;return H`<div id="tour-type-menu-outer-container">
6038
5963
  ${this.renderCommunity()} ${this.renderTourTypes()}
6039
5964
  ${e?this.renderItineraryDate():""}
6040
5965
  </div>
6041
5966
  <div id="date-and-time-menu-outer-container">
6042
5967
  ${this.selectedTypeOpensLink?this.renderLinkPrompt():this.single?this.renderSingleDateAndTime():this.renderItinerary()}
6043
- </div>`}};kd.styles=[Ko,Me,Ku,Yu,Cd,p`
5968
+ </div>`}};$d.styles=[Ko,Me,qu,Qu,yd,p`
6044
5969
  /* New layout only: the stop list and the community card's actions. */
6045
5970
  :host {
6046
5971
  display: contents;
@@ -6070,6 +5995,15 @@ xmlns="http://www.w3.org/2000/svg"
6070
5995
  margin-top: 20px;
6071
5996
  }
6072
5997
 
5998
+ /* The pencil sits centred on the community card's right. */
5999
+ .icon-button.change-community {
6000
+ align-self: center;
6001
+ }
6002
+
6003
+ .add-stop {
6004
+ width: 100%;
6005
+ }
6006
+
6073
6007
  .community {
6074
6008
  background: #ffffff;
6075
6009
  border: 1px solid #e7e7e7;
@@ -6139,7 +6073,7 @@ xmlns="http://www.w3.org/2000/svg"
6139
6073
  font-size: 0.7rem;
6140
6074
  padding: 2px 8px;
6141
6075
  }
6142
- `],xd([pe({attribute:!1})],kd.prototype,"stops",void 0),xd([pe({attribute:!1})],kd.prototype,"communities",void 0),xd([pe({attribute:!1})],kd.prototype,"problems",void 0),xd([pe({attribute:!1})],kd.prototype,"tourTypes",void 0),xd([pe({attribute:!1})],kd.prototype,"tourType",void 0),xd([pe({attribute:!1})],kd.prototype,"bookableDates",void 0),xd([pe({attribute:!1})],kd.prototype,"date",void 0),xd([pe({type:Boolean})],kd.prototype,"single",void 0),xd([pe({type:Boolean})],kd.prototype,"canEditCommunities",void 0),xd([pe({type:Boolean})],kd.prototype,"loading",void 0),xd([pe({type:Boolean})],kd.prototype,"planned",void 0),xd([pe({attribute:!1})],kd.prototype,"primaryColor",void 0),xd([pe({attribute:!1})],kd.prototype,"foregroundColorOnPrimaryBackgroundColor",void 0),xd([fe()],kd.prototype,"editingTimeFor",void 0),xd([fe()],kd.prototype,"dragIndex",void 0),xd([fe()],kd.prototype,"dropIndex",void 0),kd=xd([ce("itinerary-editor")],kd);var Ad=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const Td={firstName:"",lastName:"",email:"",phone:"",phoneE164:null,phoneCountry:null,layout:null,moveIn:"",notes:"",leadSource:null};let Ed=class extends ue{constructor(){super(...arguments),this.values=Td,this.layoutOptions=[],this.bedroomsRequired=!1,this.leadSources=[],this.showLeadSourceDropdown=!1,this.currentLeadSource="",this.country=null,this.mobile=!1,this.phoneHasBlurred=!1}setValues(e){this.values={...this.values,...e},this.dispatchEvent(new CustomEvent("contact-change",{detail:{values:this.values},bubbles:!0,composed:!0}))}inputClasses(e={}){return Ce({"webchat-input":!0,"webchat-font__desktop":!this.mobile,"webchat-font__mobile":this.mobile,...e})}render(){var e,t;const n=this.values,i=!!n.email&&!Lr(n.email.trim()),r=this.phoneHasBlurred&&!n.phoneE164;return H`<div id="user-info-and-layout-menu-outer-container">
6076
+ `],wd([pe({attribute:!1})],$d.prototype,"stops",void 0),wd([pe({attribute:!1})],$d.prototype,"communities",void 0),wd([pe({attribute:!1})],$d.prototype,"problems",void 0),wd([pe({attribute:!1})],$d.prototype,"tourTypes",void 0),wd([pe({attribute:!1})],$d.prototype,"tourType",void 0),wd([pe({attribute:!1})],$d.prototype,"bookableDates",void 0),wd([pe({attribute:!1})],$d.prototype,"date",void 0),wd([pe({type:Boolean})],$d.prototype,"single",void 0),wd([pe({type:Boolean})],$d.prototype,"canEditCommunities",void 0),wd([pe({type:Boolean})],$d.prototype,"stopsOnly",void 0),wd([pe({type:Boolean})],$d.prototype,"canAddStop",void 0),wd([pe({type:Boolean})],$d.prototype,"loading",void 0),wd([pe({type:Boolean})],$d.prototype,"planned",void 0),wd([pe({attribute:!1})],$d.prototype,"primaryColor",void 0),wd([pe({attribute:!1})],$d.prototype,"foregroundColorOnPrimaryBackgroundColor",void 0),wd([fe()],$d.prototype,"editingTimeFor",void 0),wd([fe()],$d.prototype,"dragIndex",void 0),wd([fe()],$d.prototype,"dropIndex",void 0),$d=wd([ce("itinerary-editor")],$d);var Sd=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const kd={firstName:"",lastName:"",email:"",phone:"",phoneE164:null,phoneCountry:null,layout:null,moveIn:"",notes:"",leadSource:null};let Ad=class extends ue{constructor(){super(...arguments),this.values=kd,this.layoutOptions=[],this.bedroomsRequired=!1,this.leadSources=[],this.showLeadSourceDropdown=!1,this.currentLeadSource="",this.country=null,this.mobile=!1,this.phoneHasBlurred=!1}setValues(e){this.values={...this.values,...e},this.dispatchEvent(new CustomEvent("contact-change",{detail:{values:this.values},bubbles:!0,composed:!0}))}inputClasses(e={}){return Ce({"webchat-input":!0,"webchat-font__desktop":!this.mobile,"webchat-font__mobile":this.mobile,...e})}render(){var e,t;const n=this.values,i=!!n.email&&!Lr(n.email.trim()),r=this.phoneHasBlurred&&!n.phoneE164;return H`<div id="user-info-and-layout-menu-outer-container">
6143
6077
  <h2 class="journey-header">Your Information</h2>
6144
6078
  <div id="yourInformationMenu">
6145
6079
  <div class="namesWrapper">
@@ -6226,7 +6160,7 @@ xmlns="http://www.w3.org/2000/svg"
6226
6160
  @change=${e=>{var t;const n=null!==(t=e.target.value)&&void 0!==t?t:"";this.setValues({leadSource:n||null}),n&&this.dispatchEvent(new CustomEvent("lead-source-selected",{detail:{leadSource:n},bubbles:!0,composed:!0}))}}
6227
6161
  ></me-select>`:""}
6228
6162
  </div>
6229
- </div>`}};Ed.styles=[Ko,Me,p`
6163
+ </div>`}};Ad.styles=[Ko,Me,p`
6230
6164
  :host {
6231
6165
  display: contents;
6232
6166
  }
@@ -6241,7 +6175,7 @@ xmlns="http://www.w3.org/2000/svg"
6241
6175
  resize: vertical;
6242
6176
  width: 100%;
6243
6177
  }
6244
- `],Ad([pe({attribute:!1})],Ed.prototype,"values",void 0),Ad([pe({attribute:!1})],Ed.prototype,"layoutOptions",void 0),Ad([pe({type:Boolean})],Ed.prototype,"bedroomsRequired",void 0),Ad([pe({attribute:!1})],Ed.prototype,"leadSources",void 0),Ad([pe({type:Boolean})],Ed.prototype,"showLeadSourceDropdown",void 0),Ad([pe({type:String})],Ed.prototype,"currentLeadSource",void 0),Ad([pe({attribute:!1})],Ed.prototype,"country",void 0),Ad([pe({type:Boolean})],Ed.prototype,"mobile",void 0),Ad([fe()],Ed.prototype,"phoneHasBlurred",void 0),Ed=Ad([ce("contact-form")],Ed);var _d=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Od=class extends ue{constructor(){super(...arguments),this.stops=[],this.tourType=null,this.rescheduled=!1}heading(){const e=this.stops.filter(e=>"failed"!==e.status).length,t=this.rescheduled?"Rescheduled":"Booked";return 1===e?`Your Tour Is ${t}`:`Your Tours Are ${t}`}summary(){const e=this.stops.filter(e=>"failed"!==e.status),t=e[0];if(!t)return"";const n=[1===e.length?t.community.name:"",this.tourType?pd[this.tourType].heading:""];if(t.start){const i=t.community.timezone?` ${pr(t.community.timezone)}`:"";n.push(1===e.length?`${cd(td(t.start))} at ${sd(t.start)}${i}`:cd(td(t.start)))}return n.filter(Boolean).join(" · ")}renderStops(){return this.stops.length<2?"":H`<ol class="stops">
6178
+ `],Sd([pe({attribute:!1})],Ad.prototype,"values",void 0),Sd([pe({attribute:!1})],Ad.prototype,"layoutOptions",void 0),Sd([pe({type:Boolean})],Ad.prototype,"bedroomsRequired",void 0),Sd([pe({attribute:!1})],Ad.prototype,"leadSources",void 0),Sd([pe({type:Boolean})],Ad.prototype,"showLeadSourceDropdown",void 0),Sd([pe({type:String})],Ad.prototype,"currentLeadSource",void 0),Sd([pe({attribute:!1})],Ad.prototype,"country",void 0),Sd([pe({type:Boolean})],Ad.prototype,"mobile",void 0),Sd([fe()],Ad.prototype,"phoneHasBlurred",void 0),Ad=Sd([ce("contact-form")],Ad);var Td=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Ed=class extends ue{constructor(){super(...arguments),this.stops=[],this.tourType=null,this.rescheduled=!1}heading(){const e=this.stops.filter(e=>"failed"!==e.status).length,t=this.rescheduled?"Rescheduled":"Booked";return 1===e?`Your Tour Is ${t}`:`Your Tours Are ${t}`}summary(){const e=this.stops.filter(e=>"failed"!==e.status),t=e[0];if(!t)return"";const n=[1===e.length?t.community.name:"",this.tourType?cd[this.tourType].heading:""];if(t.start){const i=t.community.timezone?` ${pr(t.community.timezone)}`:"";n.push(1===e.length?`${ud(Ju(t.start))} at ${od(t.start)}${i}`:ud(Ju(t.start)))}return n.filter(Boolean).join(" · ")}renderStops(){return this.stops.length<2?"":H`<ol class="stops">
6245
6179
  ${this.stops.map((e,t)=>{var n;return H`<li>
6246
6180
  ${t>0?H`<p class="image-card-subtitle leg">
6247
6181
  ${null!==e.distanceFromPrevMi?H`${e.distanceFromPrevMi.toFixed(1)} mi<span
@@ -6258,14 +6192,14 @@ xmlns="http://www.w3.org/2000/svg"
6258
6192
  ${e.community.name}
6259
6193
  </p>
6260
6194
  <p class="image-card-subtitle">
6261
- ${Zu(e.community.address)}
6195
+ ${Ku(e.community.address)}
6262
6196
  </p>
6263
6197
  ${"failed"===e.status?H`<p class="error-message">
6264
6198
  <span class="sr-only">Not booked:</span>
6265
6199
  ${null!==(n=e.error)&&void 0!==n?n:"This tour couldn't be booked."}
6266
6200
  </p>`:e.start&&e.end?H`<p class="stop-time">
6267
- ${cd(td(e.start))} ·
6268
- ${ld(e.start,e.end)}
6201
+ ${ud(Ju(e.start))} ·
6202
+ ${ad(e.start,e.end)}
6269
6203
  </p>`:""}
6270
6204
  </div>
6271
6205
  </div>
@@ -6301,7 +6235,7 @@ xmlns="http://www.w3.org/2000/svg"
6301
6235
  </p>
6302
6236
  ${this.renderStops()}
6303
6237
  </div>
6304
- <slot></slot>`}};Od.styles=[Ko,Me,Yu,Cd,p`
6238
+ <slot></slot>`}};Ed.styles=[Ko,Me,Qu,yd,p`
6305
6239
  /* New layout only: the header and the list of stops. */
6306
6240
  :host {
6307
6241
  display: block;
@@ -6348,7 +6282,7 @@ xmlns="http://www.w3.org/2000/svg"
6348
6282
  align-items: center;
6349
6283
  min-width: 0;
6350
6284
  }
6351
- `],_d([pe({attribute:!1})],Od.prototype,"stops",void 0),_d([pe({attribute:!1})],Od.prototype,"tourType",void 0),_d([pe({type:Boolean})],Od.prototype,"rescheduled",void 0),Od=_d([ce("booking-confirmation")],Od);var Pd=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Id=class extends ue{constructor(){super(...arguments),this.size=64,this.spinSpeed=.8}updated(){this.style.setProperty("--mega-loader-size",`${this.size}px`),this.style.setProperty("--mega-loader-spin-speed",`${this.spinSpeed}s`)}render(){return H`<div class="spinner"></div>`}};Id.styles=p`
6285
+ `],Td([pe({attribute:!1})],Ed.prototype,"stops",void 0),Td([pe({attribute:!1})],Ed.prototype,"tourType",void 0),Td([pe({type:Boolean})],Ed.prototype,"rescheduled",void 0),Ed=Td([ce("booking-confirmation")],Ed);var _d=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Od=class extends ue{constructor(){super(...arguments),this.size=64,this.spinSpeed=.8}updated(){this.style.setProperty("--mega-loader-size",`${this.size}px`),this.style.setProperty("--mega-loader-spin-speed",`${this.spinSpeed}s`)}render(){return H`<div class="spinner"></div>`}};Od.styles=p`
6352
6286
  .spinner {
6353
6287
  border: 4px solid rgba(0, 0, 0, 0.2);
6354
6288
  border-top: 4px solid var(--primary-color, #c057ff);
@@ -6366,9 +6300,9 @@ xmlns="http://www.w3.org/2000/svg"
6366
6300
  transform: rotate(360deg);
6367
6301
  }
6368
6302
  }
6369
- `,Pd([pe({type:Number})],Id.prototype,"size",void 0),Pd([pe({type:Number})],Id.prototype,"spinSpeed",void 0),Id=Pd([ce("mega-loader")],Id);const Nd=(e="white")=>z`<svg aria-hidden="true" focusable="false" xmlns="http://www.w3.org/2000/svg" width="5" height="8" viewBox="0 0 5 8" fill="none">
6303
+ `,_d([pe({type:Number})],Od.prototype,"size",void 0),_d([pe({type:Number})],Od.prototype,"spinSpeed",void 0),Od=_d([ce("mega-loader")],Od);const Pd=(e="white")=>z`<svg aria-hidden="true" focusable="false" xmlns="http://www.w3.org/2000/svg" width="5" height="8" viewBox="0 0 5 8" fill="none">
6370
6304
  <path d="M3.68188 7L0.681885 4L3.68188 1" stroke="${e}" stroke-linecap="round" stroke-linejoin="round"/>
6371
- </svg>`,Md=e=>{const t=Object.fromEntries(e.buildingIds.slice(1).filter(t=>e.laterStarts[t]).map(t=>[String(t),e.laterStarts[t]])),n=e.existingEventIds[e.existingEventIds.length-1];return{building_ids:e.buildingIds,tour_type:e.tourType,date:e.date,start_time:e.firstStart,stop_starts:t,fixed_first:void 0===n?null:{calendar_event_id:n}}},Dd=({orgSlug:e,selectedLeadSource:t,currentLeadSource:n,touchpoints:i,search:r,referrer:o,googleReferral:a})=>{var s,l,u;const d=t||n||null,c=la(e);return{lead_sources:[...new Set(d?[d,c]:[c])],lead_sources_with_timestamps:i.map(e=>_r({...e})),query_params:Object.fromEntries(new URLSearchParams(r).entries()),referrer:o,google_rwg_token:null!==(s=null==a?void 0:a.rwgToken)&&void 0!==s?s:null,google_referral_building_id:null!==(l=null==a?void 0:a.buildingId)&&void 0!==l?l:null,google_environment:null!==(u=null==a?void 0:a.environment)&&void 0!==u?u:null}},Ld=e=>0===e?0:Math.floor(e/10),Rd=["Studio","One bedroom","Two bedroom","Three bedroom","Four bedroom","Five bedroom"],Bd=e=>{var t;return{value:10*e,label:null!==(t=Rd[e])&&void 0!==t?t:`${e} bedroom`}};var Ud=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const jd={bedrooms:[],moveIn:null,maxBudget:null},Fd={"escorted-tour":"WITH_AGENT","self-guided-tour":"SELF_GUIDED","live-virtual-tour":"VIRTUAL_SHOWING"};let Hd=class extends ue{constructor(){super(...arguments),this.orgSlug="",this.buildingSlug="",this.buildingId=0,this.orgId=0,this.buildingName="",this.sgtUrl="",this.selfGuidedToursTypeOffered="",this.escortedToursLink="",this.escortedToursTypeOffered="",this.virtualToursLink="",this.virtualToursTypeOffered="",this.tourTypeOptions=[],this.layoutOptions=[],this.currentLeadSource="",this.leadSources=[],this.featureFlagShowDropdown="",this.bedroomPreferenceRequired=!1,this.orgLegalName="",this.country=null,this.buildingState=null,this.primaryColor=Zn,this.foregroundColorOnPrimaryBackgroundColor="white",this.compactDesign=!1,this.leadSourceClient=null,this.leadSourceMultitouchClient=null,this.getSessionToken=()=>null,this.api=null,this.step="loading",this.loadError=null,this.mobile=Ir(),this.group=null,this.communities=new Map,this.selectedIds=[],this.picks=[],this.existingEventIds=[],this.tourType="escorted-tour",this.linkTourType=null,this.date=null,this.firstStart=null,this.laterStarts={},this.plan=null,this.planLoading=!1,this.planError=null,this.notice=null,this.contact=Td,this.preferences=jd,this.submitting=!1,this.bookingError=null,this.reschedulePrompt=null,this.confirmed=[],this.bookedTourType=null,this.bookedEventIds=[],this.extendInitial=null,this.extendFrom=null,this.extending=!1,this.rescheduled=!1,this.rescheduleCanceled=!1,this.planRequestId=0,this.idempotency=null,this.onKeydown=e=>{du(e,this),"Escape"!==e.key||e.defaultPrevented||e.isComposing||(e.stopPropagation(),this.close())},this.loadSelectCommunities=e=>this.client.getCommunities(e).then(this.rememberPage),this.loadExtendCommunities=e=>{const t=this.extendFrom;return t?this.client.getCommunities({...e,extend:t}).then(this.rememberPage):Promise.reject(new Error("No booking to extend"))},this.rememberPage=e=>(this.remember(e.communities),e),this.onFiltersChange=e=>{this.preferences=e.detail.filters},this.onPicksChange=e=>{this.picks=e.detail.communities}}connectedCallback(){super.connectedCallback(),this.hasAttribute("role")||this.setAttribute("role","dialog"),this.hasAttribute("aria-modal")||this.setAttribute("aria-modal","true"),this.hasAttribute("aria-label")||this.setAttribute("aria-label","Schedule a Tour"),this.cleanupMobileListener=Nr(e=>this.mobile=e),this.addEventListener("keydown",this.onKeydown)}disconnectedCallback(){var e;null===(e=this.cleanupMobileListener)||void 0===e||e.call(this),this.removeEventListener("keydown",this.onKeydown),super.disconnectedCallback()}close(){var e;null===(e=this.onCloseClicked)||void 0===e||e.call(this,new MouseEvent("click"))}get client(){return this.api||(this.api=ed({orgSlug:this.orgSlug,buildingSlug:this.buildingSlug,getSessionToken:()=>this.getSessionToken()})),this.api}willUpdate(e){if(e.has("primaryColor")||e.has("foregroundColorOnPrimaryBackgroundColor")){const e=this.primaryColor||Zn;this.style.setProperty("--primary-color",e),this.style.setProperty("--action-confirm-button-background",e),this.style.setProperty("--action-confirm-button-color",this.foregroundColorOnPrimaryBackgroundColor),this.style.setProperty("--on-primary-color",this.foregroundColorOnPrimaryBackgroundColor)}}firstUpdated(){this.start()}updated(e){var t;e.has("step")&&void 0===e.get("step")?lu(this):((e.has("step")||e.has("reschedulePrompt")||e.has("rescheduleCanceled"))&&(this.hasAttribute("tabindex")||this.setAttribute("tabindex","-1"),this.focus({preventScroll:!0})),e.has("notice")&&this.notice&&(null===(t=this.renderRoot.querySelector(".notice"))||void 0===t||t.scrollIntoView({block:"nearest"})))}async start(){this.step="loading",this.loadError=null;try{const e=await this.client.getCommunities(jd);if(this.group=e,this.remember(e.communities),e.anchor.is_general_building)return void this.goTo("pick");this.rememberOne({building_id:e.anchor.building_id,name:e.anchor.name,address:null,timezone:null}),this.startSchedule([e.anchor.building_id])}catch(e){if(e instanceof Ju&&"NOT_IN_GROUP"===e.code)return this.group=null,this.rememberOne({building_id:this.buildingId,name:this.buildingName,address:null,timezone:null}),void this.startSchedule([this.buildingId]);this.loadError=e.message,this.step="error",this.log("TOUR_SCHEDULER_V2_LOAD_ERROR",e)}}goTo(e){this.step=e,"pick"===e?this.picks=this.selectedIds.map(e=>this.communities.get(e)).filter(e=>!!e):"booked"===e&&(this.picks=[]),_o("tourSchedulerStepViewed",{step:"schedule"===e&&this.extending?"extend-schedule":e,buildingId:this.buildingId})}remember(e){const t=new Map(this.communities);e.forEach(e=>t.set(e.building_id,Xu(e))),this.communities=t}rememberOne(e){const t=this.communities.get(e.building_id);(null==t?void 0:t.address)||(this.communities=new Map(this.communities).set(e.building_id,e))}startSchedule(e){this.selectedIds=e,this.plan=null,this.firstStart=null,this.laterStarts={},this.linkTourType=null,this.notice=null,this.bookingError=null,this.reschedulePrompt=null,this.goTo("schedule"),this.runPlan()}choice(){var e;return{buildingIds:this.selectedIds,tourType:this.tourType,date:null!==(e=this.date)&&void 0!==e?e:hd(new Date),firstStart:this.firstStart,laterStarts:this.laterStarts,existingEventIds:this.existingEventIds}}async runPlan(e=!1){if(0===this.selectedIds.length)return;const t=++this.planRequestId;this.planLoading=!0,this.planError=null,e||(this.notice=null);try{let e=this.choice(),n=await this.client.plan(Md(e));for(let i=0;i<2&&t===this.planRequestId;i++){if(n.tour_types.includes(e.tourType)){if(!(n.bookable_dates.length>0)||n.bookable_dates.includes(e.date))break;this.date=n.bookable_dates[0]}else{if(0===n.tour_types.length)break;this.tourType=n.tour_types[0]}this.firstStart=null,this.laterStarts={},e=this.choice(),n=await this.client.plan(Md(e))}if(t!==this.planRequestId)return;this.plan=n,n.bookable_dates.includes(e.date)&&(this.date=e.date),n.changed.length>0&&(this.notice=n.changed.map(e=>e.text).join(" "))}catch(e){if(t!==this.planRequestId)return;this.planError=e.message,this.log("TOUR_SCHEDULER_V2_PLAN_ERROR",e)}finally{t===this.planRequestId&&(this.planLoading=!1)}}tourLink(e){if(!this.tourTypeOptions.map(e=>e.value).includes(Fd[e]))return null;const[t,n]={"self-guided-tour":[this.sgtUrl,this.selfGuidedToursTypeOffered],"escorted-tour":[this.escortedToursLink,this.escortedToursTypeOffered],"live-virtual-tour":[this.virtualToursLink,this.virtualToursTypeOffered]}[e];return t&&ba(0,n)?t:null}get bookingOwnBuildingAlone(){return 0===this.existingEventIds.length&&1===this.selectedIds.length&&this.selectedIds[0]===this.buildingId}openTourLink(e){const t=this.tourLink(e);if(!t)return;const n="self-guided-tour"===e&&52===this.orgId?So(t,$o()):t;window.open(n,"_blank")}tourTypeChoices(){var e,t;const n=null!==(t=null===(e=this.plan)||void 0===e?void 0:e.tour_types)&&void 0!==t?t:[];return fd.filter(e=>n.includes(e)||this.bookingOwnBuildingAlone&&!!this.tourLink(e)).map(e=>({id:e,opensLink:this.bookingOwnBuildingAlone&&!!this.tourLink(e)}))}get shownTourType(){var e;return this.linkTourType?this.linkTourType:(null===(e=this.plan)||void 0===e?void 0:e.tour_types.includes(this.tourType))?this.tourType:null}get activeLinkType(){const e=this.shownTourType;return e&&this.bookingOwnBuildingAlone&&this.tourLink(e)?e:null}onTourType(e){if(_o("tourTypeSelected",{tourType:e,buildingId:this.buildingId}),this.bookingOwnBuildingAlone&&this.tourLink(e))return this.linkTourType=e,void this.openTourLink(e);this.linkTourType=null,e!==this.tourType&&(this.tourType=e,this.firstStart=null,this.laterStarts={},this.runPlan())}onDate(e){e!==this.date&&(_o("tourDateSelected",{tourType:this.tourType,buildingId:this.buildingId}),this.date=e,this.firstStart=null,this.laterStarts={},this.runPlan())}onStopTime(e,t){const n=this.selectedIds.indexOf(e);if(n<0)return;_o("tourTimeSelected",{tourType:this.tourType,buildingId:this.buildingId,stopNumber:n+1});const i=this.selectedIds.slice(1,n);0===n?(this.firstStart=nd(t),this.laterStarts={}):this.laterStarts={...Object.fromEntries(i.filter(e=>this.laterStarts[e]).map(e=>[e,this.laterStarts[e]])),[e]:t},this.runPlan()}onReorder(e){_o("tourStopsReordered",{buildingId:this.buildingId,stopCount:e.length});const t=this.selectedIds.filter(t=>!e.includes(t));this.selectedIds=[...e,...t],this.firstStart=null,this.laterStarts={},this.runPlan()}onRemove(e){const t=this.selectedIds.filter(t=>t!==e);if(_o("tourStopRemoved",{buildingId:this.buildingId,stopCount:t.length}),0===t.length)return this.selectedIds=[],this.plan=null,void this.goTo(this.extending?"booked":"pick");this.selectedIds[0]===e&&(this.firstStart=null),this.selectedIds=t,this.laterStarts={},this.runPlan()}onEditCommunities(){this.goTo("pick")}onCommunitiesSelected(e,t){var n;if(e.forEach(e=>this.rememberOne(e)),_o("tourCommunitiesSelected",{buildingId:this.buildingId,count:e.length,mode:t}),this.extending="extend"===t,this.extending){this.existingEventIds=this.bookedEventIds,this.tourType=null!==(n=this.bookedTourType)&&void 0!==n?n:this.tourType;const e=this.confirmed.filter(e=>e.start).slice(-1)[0];this.date=(null==e?void 0:e.start)?td(e.start):this.date}else this.existingEventIds=[];this.startSchedule(e.map(e=>e.building_id))}async submit(e=!1){var t,n,i,r,o,a;const s=this.plan;if(!s||this.submitting)return;const l=this.choice(),u=this.formValues,d=this.showLeadSourceDropdown()?u.leadSource:null,c=(({choice:e,plan:t,contact:n,attribution:i,conversationTrackingId:r,cancelExistingTours:o})=>({tour_type:e.tourType,stops:[...e.existingEventIds.map(e=>({existing_calendar_event_id:e})),...t.stops.filter(e=>!e.fixed).map(e=>({building_id:e.building_id,start:e.start}))],...n?{contact:n}:{},lead_sources:i,conversation_tracking_id:r,cancel_existing_tours:o}))({choice:l,plan:s,contact:this.extending?null:{first_name:u.firstName.trim(),last_name:u.lastName.trim(),email:u.email.trim(),phone_e164:null!==(t=u.phoneE164)&&void 0!==t?t:"",bedrooms:null===u.layout?[]:[Ld(u.layout)],move_in:u.moveIn||null,notes:u.notes.trim()},attribution:Dd({orgSlug:this.orgSlug,selectedLeadSource:d,currentLeadSource:this.currentLeadSource,touchpoints:null!==(i=null===(n=this.leadSourceMultitouchClient)||void 0===n?void 0:n.getSafeLeadSourceTouchpointsWithDefault({includedUserSelectedLeadSource:d||null}))&&void 0!==i?i:[],search:window.location.search,referrer:document.referrer,googleReferral:ns()}),conversationTrackingId:null!==(o=null===(r=this.leadSourceClient)||void 0===r?void 0:r.chatId)&&void 0!==o?o:null,cancelExistingTours:e}),h=JSON.stringify({tour_type:c.tour_type,stops:c.stops,contact:c.contact,cancel_existing_tours:c.cancel_existing_tours});(null===(a=this.idempotency)||void 0===a?void 0:a.booking)!==h&&(this.idempotency={booking:h,key:gs()}),_o("scheduleTourSubmitted",{tourType:l.tourType,stopCount:c.stops.length,buildingId:this.buildingId}),this.submitting=!0,this.bookingError=null;try{const t=await this.client.book(c,this.idempotency.key);this.idempotency=null,this.rescheduled=e,this.onBooked(t,l.tourType,s)}catch(e){this.onBookingError(e)}finally{this.submitting=!1}}onBooked(e,t,n){var i,r,o,a,s,l;if(this.reschedulePrompt=null,e.stops.every(e=>"failed"===e.status))return this.notice=null!==(o=null===(r=null===(i=e.stops.find(e=>e.error))||void 0===i?void 0:i.error)||void 0===r?void 0:r.message)&&void 0!==o?o:"We couldn't book your tour. Please pick another time.",this.log("TOUR_SCHEDULER_V2_BOOKING_ERROR",e.stops),void this.runPlan(!0);const u=new Map(n.stops.map(e=>[e.building_id,e]));this.confirmed=e.stops.map(e=>{var t,n,i,r,o,a,s,l;const d=null!==(t=this.communities.get(e.building_id))&&void 0!==t?t:{building_id:e.building_id,name:"",address:null,timezone:null},c=null!==(r=null!==(n=d.timezone)&&void 0!==n?n:null===(i=u.get(e.building_id))||void 0===i?void 0:i.timezone)&&void 0!==r?r:null;return{community:{...d,timezone:c},start:e.start,end:e.end,status:e.status,error:null!==(a=null===(o=e.error)||void 0===o?void 0:o.message)&&void 0!==a?a:null,distanceFromPrevMi:null!==(l=null===(s=u.get(e.building_id))||void 0===s?void 0:s.distance_from_prev_mi)&&void 0!==l?l:null}});const d=e.stops.filter(e=>"failed"!==e.status&&null!==e.calendar_event_id);this.bookedEventIds=d.map(e=>e.calendar_event_id),this.bookedTourType=t,this.extending=!1,this.extendInitial=null,_o("tourItineraryBooked",{buildingId:this.buildingId,stopCount:d.length,failedCount:e.stops.length-d.length}),d.length>0&&(null===(a=this.leadSourceClient)||void 0===a||a.checkAndHandleForLogLeadSource({webchatAction:"tour-scheduler",stateId:null}),null===(s=this.leadSourceClient)||void 0===s||s.resetLeadSource(),null===(l=this.leadSourceMultitouchClient)||void 0===l||l.resetLeadSourceTouchpoints()),this.goTo("booked"),this.loadExtension()}extendQueryFromBooking(){const e=this.confirmed.filter(e=>"failed"!==e.status),t=e[e.length-1];return(null==t?void 0:t.end)&&this.bookedTourType?{availableAfter:t.end,tourType:this.bookedTourType,nearBuildingId:t.community.building_id,excludeBuildingIds:e.map(e=>e.community.building_id)}:null}stopsRemaining(){return 3-this.bookedEventIds.length}async loadExtension(){const e=this.extendQueryFromBooking();this.extendFrom=e;const t=this.stopsRemaining();if(this.group&&e&&!(t<=0))try{const n=await this.client.getCommunities({...jd,extend:e});this.remember(n.communities),n.communities.some(e=>e.tourable)&&(this.extendInitial=n,_o("tourExtensionOffered",{buildingId:this.buildingId,stopsRemaining:t}))}catch(e){this.log("TOUR_SCHEDULER_V2_EXTEND_LOAD_ERROR",e)}}onBookingError(e){const t=e instanceof Ju?e:new Ju(0,null,"Something went wrong. Please try again.");if("EXISTING_TOUR"!==t.code){if(this.reschedulePrompt=null,"SLOT_TAKEN"===t.code)return this.notice=t.message,void this.runPlan(!0);this.bookingError=t.message,this.log("TOUR_SCHEDULER_V2_BOOKING_ERROR",e)}else this.reschedulePrompt=t.message}showLeadSourceDropdown(){return this.featureFlagShowDropdown===bo.always||this.featureFlagShowDropdown===bo.onAttributionFailure&&0===this.currentLeadSource.length}log(e,t){ra({logTitle:e,logData:{error:t},logType:ia.error,buildingSlug:this.buildingSlug,orgSlug:this.orgSlug,error:t})}backStep(){return this.rescheduleCanceled?null:"schedule"===this.step?this.extending?"booked":this.group?"pick":null:"pick"===this.step&&this.group&&!this.group.anchor.is_general_building&&this.plan&&this.selectedIds.length>0?"schedule":null}problems(){var e,t;return null!==(t=null===(e=this.plan)||void 0===e?void 0:e.unchainable)&&void 0!==t?t:[]}isMultiStop(){return this.selectedIds.length>1||this.existingEventIds.length>0}canSubmit(){const e=this.plan;return!!e&&!this.planLoading&&!this.planError&&e.stops.some(e=>!e.fixed)&&0===e.unchainable.length&&null===this.activeLinkType&&(this.extending||(t=this.formValues,n=this.bedroomsRequired,(!!t.firstName.trim()||!!t.lastName.trim())&&Lr(t.email.trim())&&!!t.phoneE164&&(!n||null!==t.layout)));var t,n}get bedroomOptions(){const e=new Set(this.selectedIds.flatMap(e=>{var t,n;return null!==(n=null===(t=this.communities.get(e))||void 0===t?void 0:t.bedrooms)&&void 0!==n?n:[]}));return e.size>0?[...e].sort((e,t)=>e-t).map(Bd):this.layoutOptions}get preferredLayout(){const e=this.bedroomOptions.filter(e=>this.preferences.bedrooms.includes(Ld(e.value)));return 1===e.length?e[0].value:null}get formValues(){var e;return{...this.contact,layout:this.preferredLayout,moveIn:null!==(e=this.preferences.moveIn)&&void 0!==e?e:""}}onContactChange(e){this.contact=e;const t=this.formValues;e.layout!==t.layout&&(this.preferences={...this.preferences,bedrooms:null===e.layout?[]:[Ld(e.layout)]}),e.moveIn!==t.moveIn&&(this.preferences={...this.preferences,moveIn:e.moveIn||null})}get bedroomsRequired(){return this.bedroomPreferenceRequired&&this.bedroomOptions.length>0}disclaimer(){return Yo({buildingName:this.buildingName,phoneNumberInput:this.contact.phone,emailInput:this.contact.email,orgLegalName:this.orgLegalName,orgSlug:this.orgSlug,country:this.country,buildingState:this.buildingState,clickingButtonText:"schedule tour"})}container(e){return H`<div
6305
+ </svg>`,Id=e=>{const t=Object.fromEntries(e.buildingIds.slice(1).filter(t=>e.laterStarts[t]).map(t=>[String(t),e.laterStarts[t]])),n=e.existingEventIds[e.existingEventIds.length-1];return{building_ids:e.buildingIds,tour_type:e.tourType,date:e.date,start_time:e.firstStart,stop_starts:t,fixed_first:void 0===n?null:{calendar_event_id:n}}},Nd=({orgSlug:e,selectedLeadSource:t,currentLeadSource:n,touchpoints:i,search:r,referrer:o,googleReferral:a})=>{var s,l,u;const d=t||n||null,c=la(e);return{lead_sources:[...new Set(d?[d,c]:[c])],lead_sources_with_timestamps:i.map(e=>_r({...e})),query_params:Object.fromEntries(new URLSearchParams(r).entries()),referrer:o,google_rwg_token:null!==(s=null==a?void 0:a.rwgToken)&&void 0!==s?s:null,google_referral_building_id:null!==(l=null==a?void 0:a.buildingId)&&void 0!==l?l:null,google_environment:null!==(u=null==a?void 0:a.environment)&&void 0!==u?u:null}},Md=e=>0===e?0:Math.floor(e/10),Dd=["Studio","One bedroom","Two bedroom","Three bedroom","Four bedroom","Five bedroom"],Ld=e=>{var t;return{value:10*e,label:null!==(t=Dd[e])&&void 0!==t?t:`${e} bedroom`}};var Rd=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const Bd={bedrooms:[],moveIn:null,maxBudget:null},Ud={"escorted-tour":"WITH_AGENT","self-guided-tour":"SELF_GUIDED","live-virtual-tour":"VIRTUAL_SHOWING"};let jd=class extends ue{constructor(){super(...arguments),this.orgSlug="",this.buildingSlug="",this.buildingId=0,this.orgId=0,this.buildingName="",this.sgtUrl="",this.selfGuidedToursTypeOffered="",this.escortedToursLink="",this.escortedToursTypeOffered="",this.virtualToursLink="",this.virtualToursTypeOffered="",this.tourTypeOptions=[],this.layoutOptions=[],this.currentLeadSource="",this.leadSources=[],this.featureFlagShowDropdown="",this.bedroomPreferenceRequired=!1,this.orgLegalName="",this.country=null,this.buildingState=null,this.primaryColor=Zn,this.foregroundColorOnPrimaryBackgroundColor="white",this.compactDesign=!1,this.leadSourceClient=null,this.leadSourceMultitouchClient=null,this.getSessionToken=()=>null,this.api=null,this.step="loading",this.loadError=null,this.mobile=Ir(),this.group=null,this.communities=new Map,this.selectedIds=[],this.picks=[],this.addingStop=!1,this.existingEventIds=[],this.tourType="escorted-tour",this.linkTourType=null,this.date=null,this.firstStart=null,this.laterStarts={},this.plan=null,this.planLoading=!1,this.planError=null,this.notice=null,this.contact=kd,this.preferences=Bd,this.submitting=!1,this.bookingError=null,this.reschedulePrompt=null,this.confirmed=[],this.bookedTourType=null,this.bookedEventIds=[],this.extendInitial=null,this.extendFrom=null,this.extending=!1,this.rescheduled=!1,this.rescheduleCanceled=!1,this.planRequestId=0,this.idempotency=null,this.onKeydown=e=>{du(e,this),"Escape"!==e.key||e.defaultPrevented||e.isComposing||(e.stopPropagation(),this.close())},this.loadSelectCommunities=e=>this.client.getCommunities(e).then(this.rememberPage),this.loadExtendCommunities=e=>{const t=this.extendFrom;return t?this.client.getCommunities({...e,extend:t}).then(this.rememberPage):Promise.reject(new Error("No booking to extend"))},this.rememberPage=e=>(this.remember(e.communities),e),this.loadAddStopCommunities=e=>{const t=this.extendQueryFromPlan();return t?this.client.getCommunities({...e,extend:t}).then(this.rememberPage):Promise.reject(new Error("No stop to add after"))},this.onFiltersChange=e=>{this.preferences=e.detail.filters}}connectedCallback(){super.connectedCallback(),this.hasAttribute("role")||this.setAttribute("role","dialog"),this.hasAttribute("aria-modal")||this.setAttribute("aria-modal","true"),this.hasAttribute("aria-label")||this.setAttribute("aria-label","Schedule a Tour"),this.cleanupMobileListener=Nr(e=>this.mobile=e),this.addEventListener("keydown",this.onKeydown)}disconnectedCallback(){var e;null===(e=this.cleanupMobileListener)||void 0===e||e.call(this),this.removeEventListener("keydown",this.onKeydown),super.disconnectedCallback()}close(){var e;null===(e=this.onCloseClicked)||void 0===e||e.call(this,new MouseEvent("click"))}get client(){return this.api||(this.api=Zu({orgSlug:this.orgSlug,buildingSlug:this.buildingSlug,getSessionToken:()=>this.getSessionToken()})),this.api}willUpdate(e){if(e.has("primaryColor")||e.has("foregroundColorOnPrimaryBackgroundColor")){const e=this.primaryColor||Zn;this.style.setProperty("--primary-color",e),this.style.setProperty("--action-confirm-button-background",e),this.style.setProperty("--action-confirm-button-color",this.foregroundColorOnPrimaryBackgroundColor),this.style.setProperty("--on-primary-color",this.foregroundColorOnPrimaryBackgroundColor)}}firstUpdated(){this.start()}updated(e){var t;e.has("step")&&void 0===e.get("step")?lu(this):((e.has("step")||e.has("reschedulePrompt")||e.has("rescheduleCanceled"))&&(this.hasAttribute("tabindex")||this.setAttribute("tabindex","-1"),this.focus({preventScroll:!0})),e.has("notice")&&this.notice&&(null===(t=this.renderRoot.querySelector(".notice"))||void 0===t||t.scrollIntoView({block:"nearest"})))}async start(){this.step="loading",this.loadError=null;try{const e=await this.client.getCommunities(Bd);if(this.group=e,this.remember(e.communities),e.anchor.is_general_building)return void this.goTo("pick");this.rememberOne({building_id:e.anchor.building_id,name:e.anchor.name,address:null,timezone:null}),this.startSchedule([e.anchor.building_id])}catch(e){if(e instanceof Xu&&"NOT_IN_GROUP"===e.code)return this.group=null,this.rememberOne({building_id:this.buildingId,name:this.buildingName,address:null,timezone:null}),void this.startSchedule([this.buildingId]);this.loadError=e.message,this.step="error",this.log("TOUR_SCHEDULER_V2_LOAD_ERROR",e)}}goTo(e){this.step=e,"pick"===e?this.picks=this.selectedIds.map(e=>this.communities.get(e)).filter(e=>!!e):"booked"===e&&(this.picks=[]),_o("tourSchedulerStepViewed",{step:"schedule"===e&&this.extending?"extend-schedule":e,buildingId:this.buildingId})}remember(e){const t=new Map(this.communities);e.forEach(e=>t.set(e.building_id,Yu(e))),this.communities=t}rememberOne(e){const t=this.communities.get(e.building_id);(null==t?void 0:t.address)||(this.communities=new Map(this.communities).set(e.building_id,e))}startSchedule(e){this.selectedIds=e,this.plan=null,this.firstStart=null,this.laterStarts={},this.linkTourType=null,this.notice=null,this.bookingError=null,this.reschedulePrompt=null,this.goTo("schedule"),this.runPlan()}choice(){var e;return{buildingIds:this.selectedIds,tourType:this.tourType,date:null!==(e=this.date)&&void 0!==e?e:dd(new Date),firstStart:this.firstStart,laterStarts:this.laterStarts,existingEventIds:this.existingEventIds}}async runPlan(e=!1){if(this.addingStop=!1,0===this.selectedIds.length)return;const t=++this.planRequestId;this.planLoading=!0,this.planError=null,e||(this.notice=null);try{let e=this.choice(),n=await this.client.plan(Id(e));for(let i=0;i<2&&t===this.planRequestId;i++){if(n.tour_types.includes(e.tourType)){if(!(n.bookable_dates.length>0)||n.bookable_dates.includes(e.date))break;this.date=n.bookable_dates[0]}else{if(0===n.tour_types.length)break;this.tourType=n.tour_types[0]}this.firstStart=null,this.laterStarts={},e=this.choice(),n=await this.client.plan(Id(e))}if(t!==this.planRequestId)return;this.plan=n,n.bookable_dates.includes(e.date)&&(this.date=e.date),n.changed.length>0&&(this.notice=n.changed.map(e=>e.text).join(" "))}catch(e){if(t!==this.planRequestId)return;this.planError=e.message,this.log("TOUR_SCHEDULER_V2_PLAN_ERROR",e)}finally{t===this.planRequestId&&(this.planLoading=!1)}}tourLink(e){if(!this.tourTypeOptions.map(e=>e.value).includes(Ud[e]))return null;const[t,n]={"self-guided-tour":[this.sgtUrl,this.selfGuidedToursTypeOffered],"escorted-tour":[this.escortedToursLink,this.escortedToursTypeOffered],"live-virtual-tour":[this.virtualToursLink,this.virtualToursTypeOffered]}[e];return t&&ba(0,n)?t:null}get bookingOwnBuildingAlone(){return 0===this.existingEventIds.length&&1===this.selectedIds.length&&this.selectedIds[0]===this.buildingId}openTourLink(e){const t=this.tourLink(e);if(!t)return;const n="self-guided-tour"===e&&52===this.orgId?So(t,$o()):t;window.open(n,"_blank")}tourTypeChoices(){var e,t;const n=null!==(t=null===(e=this.plan)||void 0===e?void 0:e.tour_types)&&void 0!==t?t:[];return hd.filter(e=>n.includes(e)||this.bookingOwnBuildingAlone&&!!this.tourLink(e)).map(e=>({id:e,opensLink:this.bookingOwnBuildingAlone&&!!this.tourLink(e)}))}get shownTourType(){var e;return this.linkTourType?this.linkTourType:(null===(e=this.plan)||void 0===e?void 0:e.tour_types.includes(this.tourType))?this.tourType:null}get activeLinkType(){const e=this.shownTourType;return e&&this.bookingOwnBuildingAlone&&this.tourLink(e)?e:null}onTourType(e){if(_o("tourTypeSelected",{tourType:e,buildingId:this.buildingId}),this.bookingOwnBuildingAlone&&this.tourLink(e))return this.linkTourType=e,void this.openTourLink(e);this.linkTourType=null,e!==this.tourType&&(this.tourType=e,this.firstStart=null,this.laterStarts={},this.runPlan())}onDate(e){e!==this.date&&(_o("tourDateSelected",{tourType:this.tourType,buildingId:this.buildingId}),this.date=e,this.firstStart=null,this.laterStarts={},this.runPlan())}onStopTime(e,t){const n=this.selectedIds.indexOf(e);if(n<0)return;_o("tourTimeSelected",{tourType:this.tourType,buildingId:this.buildingId,stopNumber:n+1});const i=this.selectedIds.slice(1,n);0===n?(this.firstStart=ed(t),this.laterStarts={}):this.laterStarts={...Object.fromEntries(i.filter(e=>this.laterStarts[e]).map(e=>[e,this.laterStarts[e]])),[e]:t},this.runPlan()}onReorder(e){_o("tourStopsReordered",{buildingId:this.buildingId,stopCount:e.length});const t=this.selectedIds.filter(t=>!e.includes(t));this.selectedIds=[...e,...t],this.firstStart=null,this.laterStarts={},this.runPlan()}onRemove(e){const t=this.selectedIds.filter(t=>t!==e);if(_o("tourStopRemoved",{buildingId:this.buildingId,stopCount:t.length}),0===t.length)return this.selectedIds=[],this.plan=null,void this.goTo(this.extending?"booked":"pick");this.selectedIds[0]===e&&(this.firstStart=null),this.selectedIds=t,this.laterStarts={},this.runPlan()}onEditCommunities(){this.goTo("pick")}onCommunitiesSelected(e,t){var n;if(e.forEach(e=>this.rememberOne(e)),_o("tourCommunitiesSelected",{buildingId:this.buildingId,count:e.length,mode:t}),this.extending="extend"===t,this.extending){this.existingEventIds=this.bookedEventIds,this.tourType=null!==(n=this.bookedTourType)&&void 0!==n?n:this.tourType;const e=this.confirmed.filter(e=>e.start).slice(-1)[0];this.date=(null==e?void 0:e.start)?Ju(e.start):this.date}else this.existingEventIds=[];this.startSchedule(e.map(e=>e.building_id))}async submit(e=!1){var t,n,i,r,o,a;const s=this.plan;if(!s||this.submitting)return;const l=this.choice(),u=this.formValues,d=this.showLeadSourceDropdown()?u.leadSource:null,c=(({choice:e,plan:t,contact:n,attribution:i,conversationTrackingId:r,cancelExistingTours:o})=>({tour_type:e.tourType,stops:[...e.existingEventIds.map(e=>({existing_calendar_event_id:e})),...t.stops.filter(e=>!e.fixed).map(e=>({building_id:e.building_id,start:e.start}))],...n?{contact:n}:{},lead_sources:i,conversation_tracking_id:r,cancel_existing_tours:o}))({choice:l,plan:s,contact:this.extending?null:{first_name:u.firstName.trim(),last_name:u.lastName.trim(),email:u.email.trim(),phone_e164:null!==(t=u.phoneE164)&&void 0!==t?t:"",bedrooms:null===u.layout?[]:[Md(u.layout)],move_in:u.moveIn||null,notes:u.notes.trim()},attribution:Nd({orgSlug:this.orgSlug,selectedLeadSource:d,currentLeadSource:this.currentLeadSource,touchpoints:null!==(i=null===(n=this.leadSourceMultitouchClient)||void 0===n?void 0:n.getSafeLeadSourceTouchpointsWithDefault({includedUserSelectedLeadSource:d||null}))&&void 0!==i?i:[],search:window.location.search,referrer:document.referrer,googleReferral:ns()}),conversationTrackingId:null!==(o=null===(r=this.leadSourceClient)||void 0===r?void 0:r.chatId)&&void 0!==o?o:null,cancelExistingTours:e}),h=JSON.stringify({tour_type:c.tour_type,stops:c.stops,contact:c.contact,cancel_existing_tours:c.cancel_existing_tours});(null===(a=this.idempotency)||void 0===a?void 0:a.booking)!==h&&(this.idempotency={booking:h,key:gs()}),_o("scheduleTourSubmitted",{tourType:l.tourType,stopCount:c.stops.length,buildingId:this.buildingId}),this.submitting=!0,this.bookingError=null;try{const t=await this.client.book(c,this.idempotency.key);this.idempotency=null,this.rescheduled=e,this.onBooked(t,l.tourType,s)}catch(e){this.onBookingError(e)}finally{this.submitting=!1}}onBooked(e,t,n){var i,r,o,a,s,l;if(this.reschedulePrompt=null,e.stops.every(e=>"failed"===e.status))return this.notice=null!==(o=null===(r=null===(i=e.stops.find(e=>e.error))||void 0===i?void 0:i.error)||void 0===r?void 0:r.message)&&void 0!==o?o:"We couldn't book your tour. Please pick another time.",this.log("TOUR_SCHEDULER_V2_BOOKING_ERROR",e.stops),void this.runPlan(!0);const u=new Map(n.stops.map(e=>[e.building_id,e]));this.confirmed=e.stops.map(e=>{var t,n,i,r,o,a,s,l;const d=null!==(t=this.communities.get(e.building_id))&&void 0!==t?t:{building_id:e.building_id,name:"",address:null,timezone:null},c=null!==(r=null!==(n=d.timezone)&&void 0!==n?n:null===(i=u.get(e.building_id))||void 0===i?void 0:i.timezone)&&void 0!==r?r:null;return{community:{...d,timezone:c},start:e.start,end:e.end,status:e.status,error:null!==(a=null===(o=e.error)||void 0===o?void 0:o.message)&&void 0!==a?a:null,distanceFromPrevMi:null!==(l=null===(s=u.get(e.building_id))||void 0===s?void 0:s.distance_from_prev_mi)&&void 0!==l?l:null}});const d=e.stops.filter(e=>"failed"!==e.status&&null!==e.calendar_event_id);this.bookedEventIds=d.map(e=>e.calendar_event_id),this.bookedTourType=t,this.extending=!1,this.extendInitial=null,_o("tourItineraryBooked",{buildingId:this.buildingId,stopCount:d.length,failedCount:e.stops.length-d.length}),d.length>0&&(null===(a=this.leadSourceClient)||void 0===a||a.checkAndHandleForLogLeadSource({webchatAction:"tour-scheduler",stateId:null}),null===(s=this.leadSourceClient)||void 0===s||s.resetLeadSource(),null===(l=this.leadSourceMultitouchClient)||void 0===l||l.resetLeadSourceTouchpoints()),this.goTo("booked"),this.loadExtension()}extendQueryFromBooking(){const e=this.confirmed.filter(e=>"failed"!==e.status),t=e[e.length-1];return(null==t?void 0:t.end)&&this.bookedTourType?{availableAfter:t.end,tourType:this.bookedTourType,nearBuildingId:t.community.building_id,excludeBuildingIds:e.map(e=>e.community.building_id)}:null}stopsRemaining(){return 3-this.bookedEventIds.length}get canAddStop(){var e,t;return!this.planLoading&&!this.planError&&this.stopsRemaining()>this.selectedIds.length&&(null!==(t=null===(e=this.plan)||void 0===e?void 0:e.stops.length)&&void 0!==t?t:0)>0}extendQueryFromPlan(){var e,t;const n=null!==(t=null===(e=this.plan)||void 0===e?void 0:e.stops)&&void 0!==t?t:[],i=n[n.length-1];return i&&this.extendFrom?{...this.extendFrom,availableAfter:i.end,nearBuildingId:i.building_id,excludeBuildingIds:[...this.extendFrom.excludeBuildingIds,...this.selectedIds]}:null}onStopAdded(e){const t=e[0];t&&(this.rememberOne(t),_o("tourCommunitiesSelected",{buildingId:this.buildingId,count:1,mode:"extend"}),this.selectedIds=[...this.selectedIds,t.building_id],this.runPlan())}async loadExtension(){const e=this.extendQueryFromBooking();this.extendFrom=e;const t=this.stopsRemaining();if(this.group&&e&&!(t<=0))try{const n=await this.client.getCommunities({...Bd,extend:e});this.remember(n.communities),n.communities.some(e=>e.tourable)&&(this.extendInitial=n,_o("tourExtensionOffered",{buildingId:this.buildingId,stopsRemaining:t}))}catch(e){this.log("TOUR_SCHEDULER_V2_EXTEND_LOAD_ERROR",e)}}onBookingError(e){const t=e instanceof Xu?e:new Xu(0,null,"Something went wrong. Please try again.");if("EXISTING_TOUR"!==t.code){if(this.reschedulePrompt=null,"SLOT_TAKEN"===t.code)return this.notice=t.message,void this.runPlan(!0);this.bookingError=t.message,this.log("TOUR_SCHEDULER_V2_BOOKING_ERROR",e)}else this.reschedulePrompt=t.message}showLeadSourceDropdown(){return this.featureFlagShowDropdown===bo.always||this.featureFlagShowDropdown===bo.onAttributionFailure&&0===this.currentLeadSource.length}log(e,t){ra({logTitle:e,logData:{error:t},logType:ia.error,buildingSlug:this.buildingSlug,orgSlug:this.orgSlug,error:t})}backStep(){return this.rescheduleCanceled?null:"schedule"===this.step?this.extending?"booked":this.group?"pick":null:"pick"===this.step&&this.group&&!this.group.anchor.is_general_building&&this.plan&&this.selectedIds.length>0?"schedule":null}problems(){var e,t;return null!==(t=null===(e=this.plan)||void 0===e?void 0:e.unchainable)&&void 0!==t?t:[]}isMultiStop(){return this.selectedIds.length>1||this.existingEventIds.length>0}canSubmit(){const e=this.plan;return!!e&&!this.planLoading&&!this.planError&&e.stops.some(e=>!e.fixed)&&0===e.unchainable.length&&null===this.activeLinkType&&(this.extending||(t=this.formValues,n=this.bedroomsRequired,(!!t.firstName.trim()||!!t.lastName.trim())&&Lr(t.email.trim())&&!!t.phoneE164&&(!n||null!==t.layout)));var t,n}get bedroomOptions(){const e=new Set(this.selectedIds.flatMap(e=>{var t,n;return null!==(n=null===(t=this.communities.get(e))||void 0===t?void 0:t.bedrooms)&&void 0!==n?n:[]}));return e.size>0?[...e].sort((e,t)=>e-t).map(Ld):this.layoutOptions}get preferredLayout(){const e=this.bedroomOptions.filter(e=>this.preferences.bedrooms.includes(Md(e.value)));return 1===e.length?e[0].value:null}get formValues(){var e;return{...this.contact,layout:this.preferredLayout,moveIn:null!==(e=this.preferences.moveIn)&&void 0!==e?e:""}}onContactChange(e){this.contact=e;const t=this.formValues;e.layout!==t.layout&&(this.preferences={...this.preferences,bedrooms:null===e.layout?[]:[Md(e.layout)]}),e.moveIn!==t.moveIn&&(this.preferences={...this.preferences,moveIn:e.moveIn||null})}get bedroomsRequired(){return this.bedroomPreferenceRequired&&this.bedroomOptions.length>0}disclaimer(){return Yo({buildingName:this.buildingName,phoneNumberInput:this.contact.phone,emailInput:this.contact.email,orgLegalName:this.orgLegalName,orgSlug:this.orgSlug,country:this.country,buildingState:this.buildingState,clickingButtonText:"schedule tour"})}container(e){return H`<div
6372
6306
  id=${this.mobile?"mobile-body-container":"scheduler-container"}
6373
6307
  >
6374
6308
  ${e}
@@ -6377,45 +6311,43 @@ xmlns="http://www.w3.org/2000/svg"
6377
6311
  .load=${this.loadSelectCommunities}
6378
6312
  .initial=${this.group}
6379
6313
  .filters=${this.preferences}
6380
- .maxSelectable=${1}
6381
6314
  .selected=${this.picks}
6382
6315
  @filters-change=${this.onFiltersChange}
6383
6316
  @selection-change=${e=>this.onCommunitiesSelected(e.detail.communities,"select")}
6384
- ></community-picker>`)}renderTray(){return(({selected:e,mobile:t,onRemove:n,onContinue:i})=>0===e.length?"":H`<div
6385
- id="tour-scheduler-footer"
6386
- class=${Ce({tray:!0,stacked:t})}
6317
+ ></community-picker>`)}renderItineraryHeading(){return H`<div class="itinerary-heading">
6318
+ <h2>
6319
+ Create Your Tour Itinerary
6320
+ ${this.planLoading?H`<mini-loader></mini-loader>`:""}
6321
+ </h2>
6322
+ <p class="explanation">Add up to ${3} communities</p>
6323
+ </div>`}renderAddStop(){return H`<div class="add-stop-picker">
6324
+ <button
6325
+ class="close-add-stop"
6326
+ aria-label="Close nearby communities"
6327
+ @click=${()=>this.addingStop=!1}
6387
6328
  >
6388
- <ul
6389
- class="floor-plan-selector-badges"
6390
- aria-label="Selected communities"
6391
- >
6392
- ${e.map(e=>H`<li class="floor-plan-badge">
6393
- ${e.name}
6394
- <button
6395
- class="remove"
6396
- aria-label=${`Remove ${e.name}`}
6397
- @click=${()=>n(e.building_id)}
6398
- >
6399
- ${Kl("#737373")}
6400
- </button>
6401
- </li>`)}
6402
- </ul>
6403
- <action-confirm-button
6404
- id="continue-bttn"
6405
- text="Continue"
6406
- height="50px"
6407
- width=${t?"100%":"145px"}
6408
- .onClick=${i}
6409
- ></action-confirm-button>
6410
- </div>`)({selected:this.picks,mobile:this.mobile,onRemove:e=>this.picks=this.picks.filter(t=>t.building_id!==e),onContinue:()=>this.onCommunitiesSelected(this.picks,"extend")})}renderSchedule(){var e,t;if(null!==this.reschedulePrompt)return this.renderReschedulePrompt();const n=this.plan;return H`${this.container(H`
6329
+ ${Kl("#737373")}
6330
+ </button>
6331
+ <community-picker
6332
+ variant="extend"
6333
+ .load=${this.loadAddStopCommunities}
6334
+ .filters=${this.preferences}
6335
+ @filters-change=${this.onFiltersChange}
6336
+ @selection-change=${e=>this.onStopAdded(e.detail.communities)}
6337
+ ></community-picker>
6338
+ </div>`}renderSchedule(){var e,t;if(null!==this.reschedulePrompt)return this.renderReschedulePrompt();const n=this.plan;return H`${this.container(H`
6411
6339
  ${this.planError?H`<p class="error-message" role="alert">
6412
6340
  ${this.planError}
6413
6341
  <button class="link-button" @click=${()=>this.runPlan()}>
6414
6342
  Try again
6415
6343
  </button>
6416
6344
  </p>`:""}
6345
+ ${this.extending?this.renderItineraryHeading():""}
6417
6346
  ${this.notice?H`<p class="explanation notice" role="status">${this.notice}</p>`:""}
6418
- <div id="book-tour-journey-items">
6347
+ <div
6348
+ id="book-tour-journey-items"
6349
+ class=${Ce({itinerary:this.extending})}
6350
+ >
6419
6351
  <itinerary-editor
6420
6352
  .stops=${null!==(e=null==n?void 0:n.stops)&&void 0!==e?e:[]}
6421
6353
  .communities=${this.communities}
@@ -6425,6 +6357,8 @@ xmlns="http://www.w3.org/2000/svg"
6425
6357
  .bookableDates=${null!==(t=null==n?void 0:n.bookable_dates)&&void 0!==t?t:[]}
6426
6358
  .date=${this.date}
6427
6359
  ?single=${!this.isMultiStop()}
6360
+ ?stopsOnly=${this.extending}
6361
+ ?canAddStop=${this.extending&&!this.addingStop&&this.canAddStop}
6428
6362
  ?canEditCommunities=${null!==this.group&&!this.extending}
6429
6363
  ?loading=${this.planLoading}
6430
6364
  ?planned=${null!==n}
@@ -6436,6 +6370,7 @@ xmlns="http://www.w3.org/2000/svg"
6436
6370
  @stops-reorder=${e=>this.onReorder(e.detail.buildingIds)}
6437
6371
  @stop-remove=${e=>this.onRemove(e.detail.buildingId)}
6438
6372
  @edit-communities=${()=>this.onEditCommunities()}
6373
+ @add-stop=${()=>this.addingStop=!0}
6439
6374
  @open-tour-link=${()=>this.activeLinkType&&this.openTourLink(this.activeLinkType)}
6440
6375
  ></itinerary-editor>
6441
6376
  ${this.extending?"":H`<contact-form
@@ -6451,6 +6386,7 @@ xmlns="http://www.w3.org/2000/svg"
6451
6386
  @lead-source-selected=${e=>_o("tourLeadSourceSelected",{leadSource:e.detail.leadSource,buildingId:this.buildingId})}
6452
6387
  ></contact-form>`}
6453
6388
  </div>
6389
+ ${this.extending&&this.addingStop?this.renderAddStop():""}
6454
6390
  `)}
6455
6391
  <div
6456
6392
  id="tour-scheduler-footer"
@@ -6469,8 +6405,8 @@ xmlns="http://www.w3.org/2000/svg"
6469
6405
  .onClick=${()=>this.submit()}
6470
6406
  .isLoading=${this.submitting}
6471
6407
  height="50px"
6472
- width=${this.mobile?"100%":"145px"}
6473
- text=${this.isMultiStop()?"Schedule tours":"Schedule tour"}
6408
+ width=${this.mobile?"100%":this.extending?"200px":"145px"}
6409
+ text=${this.extending?"Confirm tour itinerary":this.isMultiStop()?"Schedule tours":"Schedule tour"}
6474
6410
  ?disabled=${!this.canSubmit()}
6475
6411
  ></action-confirm-button>
6476
6412
  </div>`}renderReschedulePrompt(){return H`${this.container(H`<div>
@@ -6526,13 +6462,10 @@ xmlns="http://www.w3.org/2000/svg"
6526
6462
  .load=${this.loadExtendCommunities}
6527
6463
  .initial=${this.extendInitial}
6528
6464
  .filters=${this.preferences}
6529
- .maxSelectable=${this.stopsRemaining()}
6530
- .selected=${this.picks}
6531
6465
  @filters-change=${this.onFiltersChange}
6532
- @selection-change=${this.onPicksChange}
6466
+ @selection-change=${e=>this.onCommunitiesSelected(e.detail.communities,"extend")}
6533
6467
  ></community-picker>`:""}
6534
- </booking-confirmation>`)}
6535
- ${this.extendInitial?this.renderTray():""}`}renderBody(){if(this.rescheduleCanceled)return this.renderRescheduleCanceled();switch(this.step){case"loading":return H`<div class="center-tour-not-avail" role="status">
6468
+ </booking-confirmation>`)}`}renderBody(){if(this.rescheduleCanceled)return this.renderRescheduleCanceled();switch(this.step){case"loading":return H`<div class="center-tour-not-avail" role="status">
6536
6469
  <h1>Searching for availabilities...</h1>
6537
6470
  <div class="loading-entire-tour-icon">
6538
6471
  <mega-loader size="48"></mega-loader>
@@ -6554,7 +6487,7 @@ xmlns="http://www.w3.org/2000/svg"
6554
6487
  aria-label="Back"
6555
6488
  @click=${()=>this.goTo(e)}
6556
6489
  >
6557
- ${Nd("#202020")}
6490
+ ${Pd("#202020")}
6558
6491
  </button>`:""}
6559
6492
  <h1 id="tour-header-title">Schedule a Tour</h1>
6560
6493
  </div>
@@ -6567,7 +6500,7 @@ xmlns="http://www.w3.org/2000/svg"
6567
6500
  </button>
6568
6501
  </div>
6569
6502
  ${this.renderBody()}
6570
- </div>`}};Hd.styles=[Ko,Me,wd,p`
6503
+ </div>`}};jd.styles=[Ko,Me,p`
6571
6504
  /* New layout only: the back button beside the title. */
6572
6505
  .title {
6573
6506
  align-items: center;
@@ -6596,6 +6529,45 @@ xmlns="http://www.w3.org/2000/svg"
6596
6529
  margin: 0 0 16px;
6597
6530
  }
6598
6531
 
6532
+ /* Adding stops: the design's one centred column of stops. */
6533
+ #book-tour-journey-items.itinerary {
6534
+ display: block;
6535
+ margin: 0 auto;
6536
+ max-width: 30rem;
6537
+ }
6538
+
6539
+ .itinerary-heading {
6540
+ margin-bottom: 16px;
6541
+ text-align: center;
6542
+ }
6543
+
6544
+ /* The pickers' heading size. */
6545
+ .itinerary-heading h2 {
6546
+ align-items: center;
6547
+ display: flex;
6548
+ font-size: 20px;
6549
+ font-weight: 400;
6550
+ gap: 8px;
6551
+ justify-content: center;
6552
+ margin: 0;
6553
+ }
6554
+
6555
+ .add-stop-picker {
6556
+ margin-top: 24px;
6557
+ position: relative;
6558
+ }
6559
+
6560
+ /* The extend picker's top rule and padding put its heading 24px down. */
6561
+ .close-add-stop {
6562
+ background: none;
6563
+ border: none;
6564
+ cursor: pointer;
6565
+ padding: 4px;
6566
+ position: absolute;
6567
+ right: 0;
6568
+ top: 24px;
6569
+ }
6570
+
6599
6571
  .link-button {
6600
6572
  background: none;
6601
6573
  border: none;
@@ -6604,7 +6576,7 @@ xmlns="http://www.w3.org/2000/svg"
6604
6576
  font: inherit;
6605
6577
  text-decoration: underline;
6606
6578
  }
6607
- `],Ud([pe({attribute:!0})],Hd.prototype,"orgSlug",void 0),Ud([pe({attribute:!0})],Hd.prototype,"buildingSlug",void 0),Ud([pe({type:Number})],Hd.prototype,"buildingId",void 0),Ud([pe({type:Number})],Hd.prototype,"orgId",void 0),Ud([pe({attribute:!1})],Hd.prototype,"buildingName",void 0),Ud([pe({attribute:!0})],Hd.prototype,"sgtUrl",void 0),Ud([pe({attribute:!0})],Hd.prototype,"selfGuidedToursTypeOffered",void 0),Ud([pe({attribute:!0})],Hd.prototype,"escortedToursLink",void 0),Ud([pe({attribute:!1})],Hd.prototype,"escortedToursTypeOffered",void 0),Ud([pe({attribute:!0})],Hd.prototype,"virtualToursLink",void 0),Ud([pe({attribute:!0})],Hd.prototype,"virtualToursTypeOffered",void 0),Ud([pe({attribute:!1})],Hd.prototype,"tourTypeOptions",void 0),Ud([pe({attribute:!1})],Hd.prototype,"layoutOptions",void 0),Ud([pe({attribute:!0})],Hd.prototype,"currentLeadSource",void 0),Ud([pe({attribute:!1})],Hd.prototype,"leadSources",void 0),Ud([pe({attribute:!0})],Hd.prototype,"featureFlagShowDropdown",void 0),Ud([pe({attribute:!1})],Hd.prototype,"bedroomPreferenceRequired",void 0),Ud([pe({attribute:!1})],Hd.prototype,"orgLegalName",void 0),Ud([pe({attribute:!1})],Hd.prototype,"country",void 0),Ud([pe({attribute:!1})],Hd.prototype,"buildingState",void 0),Ud([pe({attribute:!1})],Hd.prototype,"primaryColor",void 0),Ud([pe({attribute:!1})],Hd.prototype,"foregroundColorOnPrimaryBackgroundColor",void 0),Ud([pe({attribute:!1})],Hd.prototype,"compactDesign",void 0),Ud([pe({attribute:!1})],Hd.prototype,"leadSourceClient",void 0),Ud([pe({attribute:!1})],Hd.prototype,"leadSourceMultitouchClient",void 0),Ud([pe({attribute:!1})],Hd.prototype,"getSessionToken",void 0),Ud([fe()],Hd.prototype,"step",void 0),Ud([fe()],Hd.prototype,"loadError",void 0),Ud([fe()],Hd.prototype,"mobile",void 0),Ud([fe()],Hd.prototype,"group",void 0),Ud([fe()],Hd.prototype,"communities",void 0),Ud([fe()],Hd.prototype,"selectedIds",void 0),Ud([fe()],Hd.prototype,"picks",void 0),Ud([fe()],Hd.prototype,"existingEventIds",void 0),Ud([fe()],Hd.prototype,"tourType",void 0),Ud([fe()],Hd.prototype,"linkTourType",void 0),Ud([fe()],Hd.prototype,"date",void 0),Ud([fe()],Hd.prototype,"firstStart",void 0),Ud([fe()],Hd.prototype,"laterStarts",void 0),Ud([fe()],Hd.prototype,"plan",void 0),Ud([fe()],Hd.prototype,"planLoading",void 0),Ud([fe()],Hd.prototype,"planError",void 0),Ud([fe()],Hd.prototype,"notice",void 0),Ud([fe()],Hd.prototype,"contact",void 0),Ud([fe()],Hd.prototype,"preferences",void 0),Ud([fe()],Hd.prototype,"submitting",void 0),Ud([fe()],Hd.prototype,"bookingError",void 0),Ud([fe()],Hd.prototype,"reschedulePrompt",void 0),Ud([fe()],Hd.prototype,"confirmed",void 0),Ud([fe()],Hd.prototype,"bookedTourType",void 0),Ud([fe()],Hd.prototype,"bookedEventIds",void 0),Ud([fe()],Hd.prototype,"extendInitial",void 0),Ud([fe()],Hd.prototype,"extendFrom",void 0),Ud([fe()],Hd.prototype,"extending",void 0),Ud([fe()],Hd.prototype,"rescheduled",void 0),Ud([fe()],Hd.prototype,"rescheduleCanceled",void 0),Hd=Ud([ce("tour-scheduler-v2")],Hd);const zd=p`
6579
+ `],Rd([pe({attribute:!0})],jd.prototype,"orgSlug",void 0),Rd([pe({attribute:!0})],jd.prototype,"buildingSlug",void 0),Rd([pe({type:Number})],jd.prototype,"buildingId",void 0),Rd([pe({type:Number})],jd.prototype,"orgId",void 0),Rd([pe({attribute:!1})],jd.prototype,"buildingName",void 0),Rd([pe({attribute:!0})],jd.prototype,"sgtUrl",void 0),Rd([pe({attribute:!0})],jd.prototype,"selfGuidedToursTypeOffered",void 0),Rd([pe({attribute:!0})],jd.prototype,"escortedToursLink",void 0),Rd([pe({attribute:!1})],jd.prototype,"escortedToursTypeOffered",void 0),Rd([pe({attribute:!0})],jd.prototype,"virtualToursLink",void 0),Rd([pe({attribute:!0})],jd.prototype,"virtualToursTypeOffered",void 0),Rd([pe({attribute:!1})],jd.prototype,"tourTypeOptions",void 0),Rd([pe({attribute:!1})],jd.prototype,"layoutOptions",void 0),Rd([pe({attribute:!0})],jd.prototype,"currentLeadSource",void 0),Rd([pe({attribute:!1})],jd.prototype,"leadSources",void 0),Rd([pe({attribute:!0})],jd.prototype,"featureFlagShowDropdown",void 0),Rd([pe({attribute:!1})],jd.prototype,"bedroomPreferenceRequired",void 0),Rd([pe({attribute:!1})],jd.prototype,"orgLegalName",void 0),Rd([pe({attribute:!1})],jd.prototype,"country",void 0),Rd([pe({attribute:!1})],jd.prototype,"buildingState",void 0),Rd([pe({attribute:!1})],jd.prototype,"primaryColor",void 0),Rd([pe({attribute:!1})],jd.prototype,"foregroundColorOnPrimaryBackgroundColor",void 0),Rd([pe({attribute:!1})],jd.prototype,"compactDesign",void 0),Rd([pe({attribute:!1})],jd.prototype,"leadSourceClient",void 0),Rd([pe({attribute:!1})],jd.prototype,"leadSourceMultitouchClient",void 0),Rd([pe({attribute:!1})],jd.prototype,"getSessionToken",void 0),Rd([fe()],jd.prototype,"step",void 0),Rd([fe()],jd.prototype,"loadError",void 0),Rd([fe()],jd.prototype,"mobile",void 0),Rd([fe()],jd.prototype,"group",void 0),Rd([fe()],jd.prototype,"communities",void 0),Rd([fe()],jd.prototype,"selectedIds",void 0),Rd([fe()],jd.prototype,"picks",void 0),Rd([fe()],jd.prototype,"addingStop",void 0),Rd([fe()],jd.prototype,"existingEventIds",void 0),Rd([fe()],jd.prototype,"tourType",void 0),Rd([fe()],jd.prototype,"linkTourType",void 0),Rd([fe()],jd.prototype,"date",void 0),Rd([fe()],jd.prototype,"firstStart",void 0),Rd([fe()],jd.prototype,"laterStarts",void 0),Rd([fe()],jd.prototype,"plan",void 0),Rd([fe()],jd.prototype,"planLoading",void 0),Rd([fe()],jd.prototype,"planError",void 0),Rd([fe()],jd.prototype,"notice",void 0),Rd([fe()],jd.prototype,"contact",void 0),Rd([fe()],jd.prototype,"preferences",void 0),Rd([fe()],jd.prototype,"submitting",void 0),Rd([fe()],jd.prototype,"bookingError",void 0),Rd([fe()],jd.prototype,"reschedulePrompt",void 0),Rd([fe()],jd.prototype,"confirmed",void 0),Rd([fe()],jd.prototype,"bookedTourType",void 0),Rd([fe()],jd.prototype,"bookedEventIds",void 0),Rd([fe()],jd.prototype,"extendInitial",void 0),Rd([fe()],jd.prototype,"extendFrom",void 0),Rd([fe()],jd.prototype,"extending",void 0),Rd([fe()],jd.prototype,"rescheduled",void 0),Rd([fe()],jd.prototype,"rescheduleCanceled",void 0),jd=Rd([ce("tour-scheduler-v2")],jd);const Fd=p`
6608
6580
  :host {
6609
6581
  display: block;
6610
6582
  position: relative;
@@ -6916,7 +6888,7 @@ xmlns="http://www.w3.org/2000/svg"
6916
6888
  margin: 2px 0;
6917
6889
  }
6918
6890
  }
6919
- `;class Gd{constructor(e={}){var t,n,i,r,o,a;this.id=null!==(t=e.id)&&void 0!==t?t:"",this.description=null!==(n=e.description)&&void 0!==n?n:"",this.type=null!==(i=e.type)&&void 0!==i?i:"",this.rent=null!==(r=e.rent)&&void 0!==r?r:0,this.rentFrequency=null!==(o=e.rentFrequency)&&void 0!==o?o:"monthly",this.available=null!==(a=e.available)&&void 0!==a&&a,this.reservedUntil=e.reservedUntil?new Date(e.reservedUntil):void 0}}class Vd{constructor(e={}){var t,n,i,r,o;this.description=null!==(t=e.description)&&void 0!==t?t:"",this.type=null!==(n=e.type)&&void 0!==n?n:"",this.minAvailableItem=e.minAvailableItem?new Gd(e.minAvailableItem):void 0,this.maxAvailableItem=e.maxAvailableItem?new Gd(e.maxAvailableItem):void 0,this.allItems=(null!==(i=e.allItems)&&void 0!==i?i:[]).map(e=>new Gd(e)),this.rent=null!==(r=e.rent)&&void 0!==r?r:0,this.priceDescription=null!==(o=e.priceDescription)&&void 0!==o?o:""}get displayName(){return this.description}get itemDescription(){return this.description}}var Wd,Qd;!function(e){e.NEVER="NEVER",e.AS_NEEDED="AS_NEEDED",e.ONE_TIME="ONE_TIME",e.MONTHLY="MONTHLY",e.WEEKLY="WEEKLY",e.BI_WEEKLY="BI_WEEKLY",e.ANNUALLY="ANNUALLY",e.DAILY="DAILY"}(Wd||(Wd={})),function(e){e.Rent="Rent",e.Utility="Utility",e.ApplicationFee="ApplicationFee",e.Parking="Parking",e.Insurance="Insurance",e.Storage="Storage",e.PetFee="PetFee",e.PetRent="PetRent",e.PetDeposit="PetDeposit",e.SecurityDeposit="SecurityDeposit",e.MoveInFee="MoveInFee",e.Other="Other"}(Qd||(Qd={}));class qd{constructor(e={}){var t,n,i,r,o,a,s,l,u,d;this.id=null!==(t=e.id)&&void 0!==t?t:"",this.building_id=e.building_id,this.fee_name=null!==(n=e.fee_name)&&void 0!==n?n:"",this.amount=e.amount,this.amount_display=null!==(i=e.amount_display)&&void 0!==i?i:"",this.limit=null!==(r=e.limit)&&void 0!==r?r:null,this.min_estimate=e.min_estimate,this.max_estimate=e.max_estimate,this.percent_rent=e.percent_rent,this.percent_rent_min=e.percent_rent_min,this.percent_rent_max=e.percent_rent_max,this.frequency=null!==(o=e.frequency)&&void 0!==o?o:Wd.ONE_TIME,this.category=null!==(a=e.category)&&void 0!==a?a:Qd.Other,this.description=e.description,this.additional_info=e.additional_info,this.refundable=null!==(s=e.refundable)&&void 0!==s&&s,this.hidden_reason=e.hidden_reason,this.unit_ids=e.unit_ids,this.layout_ids=e.layout_ids,this.public_facing=null===(l=e.public_facing)||void 0===l||l,this.per_applicant=null!==(u=e.per_applicant)&&void 0!==u&&u,this.required_for_quotes=null!==(d=e.required_for_quotes)&&void 0!==d&&d,this.charge_code=e.charge_code,this.bundle_key=e.bundle_key,this.external_key=e.external_key}get displayFrequency(){return this.frequency.replace(/_/g," ").toLowerCase().replace(/\b\w/g,e=>e.toUpperCase())}get isOptional(){return!this.required_for_quotes}}const Yd=class{constructor(){this.params=new URLSearchParams}addSingle(e,t){return t?(this.params.append(e,t),this):this}addArray(e,t){return t?(t.forEach(t=>{t&&this.params.append(`${e}[]`,t)}),this):this}build(){return this.params.toString()?`?${this.params.toString()}`:""}},Kd=is,Xd=e=>new qd(e),Zd=e=>new Vd(e),Jd=async(e,t)=>{try{const n=(new Yd).addArray("layout_ids",null==t?void 0:t.map(e=>e.toString())),i=await r().get(`${Kd}/platformApi/webchat/${e}/marketable-fees?${n.build()}`);if(i.data){const e=Er(i.data);return{fees:e.fees.map(Xd),rentableItems:e.rentableItems.map(Zd),buildingIncentives:e.buildingIncentives}}}catch(t){ra({logType:ia.error,buildingSlug:e,logTitle:"[ERROR_GETTING_FEES]",logData:{error:t},error:t})}return{fees:[],rentableItems:[],buildingIncentives:[]}},ec=-1,tc=is,nc=async({buildingSlug:e,unitId:t,chargeInputs:n,rentableItems:i,leaseTerm:o,moveInDate:a},s)=>{try{const l=await r().post(`${tc}/platformApi/webchat/${e}/quote/calculate`,_r({unitId:t,chargeInputs:n,rentableItems:i,...Number.isFinite(o)?{leaseTerm:o}:{},moveInDate:a}),{signal:s});if(l.data){return Er(l.data)}}catch(t){const n=t;"ERR_CANCELED"!==n.code&&ra({logType:ia.error,buildingSlug:e,logTitle:"[ERROR_CALCULATING_QUOTE]",logData:{error:t},error:t});const i=(e=>{var t,n,i;const r=null===(n=null===(t=e.response)||void 0===t?void 0:t.data)||void 0===n?void 0:n.detail;if(422!==(null===(i=e.response)||void 0===i?void 0:i.status)||!Array.isArray(r))return null;const o=r.map(e=>Er(e));return o.length>0&&o.every(e=>"number"==typeof e.limit)?o:null})(n);return{quote:null,error:i?{type:"feeLimit",violations:i}:{type:"unknown"}}}return{quote:null,error:{type:"unknown"}}};function ic(e){return ir(e,"yyyy-MM-dd")}function rc(){return ic(Hr())}const oc=is,ac=async({buildingSlug:e,numBedrooms:t,moveInDateString:n,leaseTerm:i})=>{try{const a=(({numBedrooms:e,moveInDateString:t,leaseTerm:n})=>{const i=new Yd;return i.addArray("num_bedrooms",null==e?void 0:e.map(e=>e.toString())).addSingle("move_in_date_earliest",t).addSingle("move_in_date_latest",t).addSingle("lease_term_min",Number.isFinite(n)?null==n?void 0:n.toString():void 0),i.build()})({numBedrooms:t,moveInDateString:n,leaseTerm:i}),s=await r().get(`${oc}/platformApi/webchat/${e}/units${a}`);if(s.data){const e=Er(s.data);return o=e.map(e=>({...e,id:parseInt(e.id.toString().substring(1))})),[...o].sort((e,t)=>e.startingPrice-t.startingPrice||e.id-t.id)}}catch(r){ra({logType:ia.error,buildingSlug:e,logTitle:"[ERROR_GETTING_UNITS]",logData:{error:r,params:{numBedrooms:t,moveInDateString:n,leaseTerm:i}},error:r})}var o;return[]},sc=[Qd.PetFee,Qd.PetRent,Qd.PetDeposit];function lc(e){return`Up to ${e} ${1===e?"pet":"pets"} allowed`}const uc=({color:e="#347FF7",size:t=24}={})=>z`
6891
+ `;class Hd{constructor(e={}){var t,n,i,r,o,a;this.id=null!==(t=e.id)&&void 0!==t?t:"",this.description=null!==(n=e.description)&&void 0!==n?n:"",this.type=null!==(i=e.type)&&void 0!==i?i:"",this.rent=null!==(r=e.rent)&&void 0!==r?r:0,this.rentFrequency=null!==(o=e.rentFrequency)&&void 0!==o?o:"monthly",this.available=null!==(a=e.available)&&void 0!==a&&a,this.reservedUntil=e.reservedUntil?new Date(e.reservedUntil):void 0}}class zd{constructor(e={}){var t,n,i,r,o;this.description=null!==(t=e.description)&&void 0!==t?t:"",this.type=null!==(n=e.type)&&void 0!==n?n:"",this.minAvailableItem=e.minAvailableItem?new Hd(e.minAvailableItem):void 0,this.maxAvailableItem=e.maxAvailableItem?new Hd(e.maxAvailableItem):void 0,this.allItems=(null!==(i=e.allItems)&&void 0!==i?i:[]).map(e=>new Hd(e)),this.rent=null!==(r=e.rent)&&void 0!==r?r:0,this.priceDescription=null!==(o=e.priceDescription)&&void 0!==o?o:""}get displayName(){return this.description}get itemDescription(){return this.description}}var Gd,Vd;!function(e){e.NEVER="NEVER",e.AS_NEEDED="AS_NEEDED",e.ONE_TIME="ONE_TIME",e.MONTHLY="MONTHLY",e.WEEKLY="WEEKLY",e.BI_WEEKLY="BI_WEEKLY",e.ANNUALLY="ANNUALLY",e.DAILY="DAILY"}(Gd||(Gd={})),function(e){e.Rent="Rent",e.Utility="Utility",e.ApplicationFee="ApplicationFee",e.Parking="Parking",e.Insurance="Insurance",e.Storage="Storage",e.PetFee="PetFee",e.PetRent="PetRent",e.PetDeposit="PetDeposit",e.SecurityDeposit="SecurityDeposit",e.MoveInFee="MoveInFee",e.Other="Other"}(Vd||(Vd={}));class Wd{constructor(e={}){var t,n,i,r,o,a,s,l,u,d;this.id=null!==(t=e.id)&&void 0!==t?t:"",this.building_id=e.building_id,this.fee_name=null!==(n=e.fee_name)&&void 0!==n?n:"",this.amount=e.amount,this.amount_display=null!==(i=e.amount_display)&&void 0!==i?i:"",this.limit=null!==(r=e.limit)&&void 0!==r?r:null,this.min_estimate=e.min_estimate,this.max_estimate=e.max_estimate,this.percent_rent=e.percent_rent,this.percent_rent_min=e.percent_rent_min,this.percent_rent_max=e.percent_rent_max,this.frequency=null!==(o=e.frequency)&&void 0!==o?o:Gd.ONE_TIME,this.category=null!==(a=e.category)&&void 0!==a?a:Vd.Other,this.description=e.description,this.additional_info=e.additional_info,this.refundable=null!==(s=e.refundable)&&void 0!==s&&s,this.hidden_reason=e.hidden_reason,this.unit_ids=e.unit_ids,this.layout_ids=e.layout_ids,this.public_facing=null===(l=e.public_facing)||void 0===l||l,this.per_applicant=null!==(u=e.per_applicant)&&void 0!==u&&u,this.required_for_quotes=null!==(d=e.required_for_quotes)&&void 0!==d&&d,this.charge_code=e.charge_code,this.bundle_key=e.bundle_key,this.external_key=e.external_key}get displayFrequency(){return this.frequency.replace(/_/g," ").toLowerCase().replace(/\b\w/g,e=>e.toUpperCase())}get isOptional(){return!this.required_for_quotes}}const Qd=class{constructor(){this.params=new URLSearchParams}addSingle(e,t){return t?(this.params.append(e,t),this):this}addArray(e,t){return t?(t.forEach(t=>{t&&this.params.append(`${e}[]`,t)}),this):this}build(){return this.params.toString()?`?${this.params.toString()}`:""}},qd=is,Yd=e=>new Wd(e),Kd=e=>new zd(e),Xd=async(e,t)=>{try{const n=(new Qd).addArray("layout_ids",null==t?void 0:t.map(e=>e.toString())),i=await r().get(`${qd}/platformApi/webchat/${e}/marketable-fees?${n.build()}`);if(i.data){const e=Er(i.data);return{fees:e.fees.map(Yd),rentableItems:e.rentableItems.map(Kd),buildingIncentives:e.buildingIncentives}}}catch(t){ra({logType:ia.error,buildingSlug:e,logTitle:"[ERROR_GETTING_FEES]",logData:{error:t},error:t})}return{fees:[],rentableItems:[],buildingIncentives:[]}},Zd=-1,Jd=is,ec=async({buildingSlug:e,unitId:t,chargeInputs:n,rentableItems:i,leaseTerm:o,moveInDate:a},s)=>{try{const l=await r().post(`${Jd}/platformApi/webchat/${e}/quote/calculate`,_r({unitId:t,chargeInputs:n,rentableItems:i,...Number.isFinite(o)?{leaseTerm:o}:{},moveInDate:a}),{signal:s});if(l.data){return Er(l.data)}}catch(t){const n=t;"ERR_CANCELED"!==n.code&&ra({logType:ia.error,buildingSlug:e,logTitle:"[ERROR_CALCULATING_QUOTE]",logData:{error:t},error:t});const i=(e=>{var t,n,i;const r=null===(n=null===(t=e.response)||void 0===t?void 0:t.data)||void 0===n?void 0:n.detail;if(422!==(null===(i=e.response)||void 0===i?void 0:i.status)||!Array.isArray(r))return null;const o=r.map(e=>Er(e));return o.length>0&&o.every(e=>"number"==typeof e.limit)?o:null})(n);return{quote:null,error:i?{type:"feeLimit",violations:i}:{type:"unknown"}}}return{quote:null,error:{type:"unknown"}}};function tc(e){return ir(e,"yyyy-MM-dd")}function nc(){return tc(Hr())}const ic=is,rc=async({buildingSlug:e,numBedrooms:t,moveInDateString:n,leaseTerm:i})=>{try{const a=(({numBedrooms:e,moveInDateString:t,leaseTerm:n})=>{const i=new Qd;return i.addArray("num_bedrooms",null==e?void 0:e.map(e=>e.toString())).addSingle("move_in_date_earliest",t).addSingle("move_in_date_latest",t).addSingle("lease_term_min",Number.isFinite(n)?null==n?void 0:n.toString():void 0),i.build()})({numBedrooms:t,moveInDateString:n,leaseTerm:i}),s=await r().get(`${ic}/platformApi/webchat/${e}/units${a}`);if(s.data){const e=Er(s.data);return o=e.map(e=>({...e,id:parseInt(e.id.toString().substring(1))})),[...o].sort((e,t)=>e.startingPrice-t.startingPrice||e.id-t.id)}}catch(r){ra({logType:ia.error,buildingSlug:e,logTitle:"[ERROR_GETTING_UNITS]",logData:{error:r,params:{numBedrooms:t,moveInDateString:n,leaseTerm:i}},error:r})}var o;return[]},oc=[Vd.PetFee,Vd.PetRent,Vd.PetDeposit];function ac(e){return`Up to ${e} ${1===e?"pet":"pets"} allowed`}const sc=({color:e="#347FF7",size:t=24}={})=>z`
6920
6892
  <svg aria-hidden="true" focusable="false" width="${t}" height="${t}" viewBox="0 0 24 25" fill="none" xmlns="http://www.w3.org/2000/svg">
6921
6893
  <g id="Frame" clip-path="url(#clip0_18718_332018)">
6922
6894
  <path id="Vector" d="M3 12.5C3 13.6819 3.23279 14.8522 3.68508 15.9442C4.13738 17.0361 4.80031 18.0282 5.63604 18.864C6.47177 19.6997 7.46392 20.3626 8.55585 20.8149C9.64778 21.2672 10.8181 21.5 12 21.5C13.1819 21.5 14.3522 21.2672 15.4442 20.8149C16.5361 20.3626 17.5282 19.6997 18.364 18.864C19.1997 18.0282 19.8626 17.0361 20.3149 15.9442C20.7672 14.8522 21 13.6819 21 12.5C21 11.3181 20.7672 10.1478 20.3149 9.05585C19.8626 7.96392 19.1997 6.97177 18.364 6.13604C17.5282 5.30031 16.5361 4.63738 15.4442 4.18508C14.3522 3.73279 13.1819 3.5 12 3.5C10.8181 3.5 9.64778 3.73279 8.55585 4.18508C7.46392 4.63738 6.47177 5.30031 5.63604 6.13604C4.80031 6.97177 4.13738 7.96392 3.68508 9.05585C3.23279 10.1478 3 11.3181 3 12.5Z" stroke="${e}" stroke-linecap="round" stroke-linejoin="round"/>
@@ -6929,7 +6901,7 @@ xmlns="http://www.w3.org/2000/svg"
6929
6901
  </clipPath>
6930
6902
  </defs>
6931
6903
  </svg>
6932
- `,dc=p`
6904
+ `,lc=p`
6933
6905
  :host {
6934
6906
  display: block;
6935
6907
  margin-bottom: 20px;
@@ -6963,9 +6935,9 @@ xmlns="http://www.w3.org/2000/svg"
6963
6935
  color: #868e96;
6964
6936
  font-size: 0.8rem;
6965
6937
  }
6966
- `;var cc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let hc=class extends ue{constructor(){super(...arguments),this.promoAmount="0",this.promoDescription="",this.promoValidity=""}render(){return H`
6938
+ `;var uc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let dc=class extends ue{constructor(){super(...arguments),this.promoAmount="0",this.promoDescription="",this.promoValidity=""}render(){return H`
6967
6939
  <div class="promo-card">
6968
- <div class="icon-container">${uc()}</div>
6940
+ <div class="icon-container">${sc()}</div>
6969
6941
  <div class="content-container">
6970
6942
  <h2 class="promo-heading">
6971
6943
  ${this.promoAmount} ${this.promoDescription}
@@ -6973,7 +6945,7 @@ xmlns="http://www.w3.org/2000/svg"
6973
6945
  <div class="promo-subtitle">${this.promoValidity}</div>
6974
6946
  </div>
6975
6947
  </div>
6976
- `}};hc.styles=dc,cc([pe({type:String})],hc.prototype,"promoAmount",void 0),cc([pe({type:String})],hc.prototype,"promoDescription",void 0),cc([pe({type:String})],hc.prototype,"promoValidity",void 0),hc=cc([ce("promo-card")],hc);var pc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let fc=class extends ue{constructor(){super(...arguments),this.unit={},this.onUnitSelect=null,this.selected=!1}get bedAndBathText(){return`${0===this.unit.numberOfBedrooms?"studio":`${this.unit.numberOfBedrooms}bd`} | ${this.unit.numberOfBathrooms}ba`}get priceRange(){return this.unit.startingPrice===this.unit.maxPrice?`$${this.unit.startingPrice}`:`$${this.unit.startingPrice} - $${this.unit.maxPrice}`}handleOnUnitSelect(){var e;this.selected||(this.selected=!this.selected,null===(e=this.onUnitSelect)||void 0===e||e.call(this,this.unit))}handleOnImgClick(e){const t=e.target;window.open(t.src,"_blank")}render(){return H`
6948
+ `}};dc.styles=lc,uc([pe({type:String})],dc.prototype,"promoAmount",void 0),uc([pe({type:String})],dc.prototype,"promoDescription",void 0),uc([pe({type:String})],dc.prototype,"promoValidity",void 0),dc=uc([ce("promo-card")],dc);var cc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let hc=class extends ue{constructor(){super(...arguments),this.unit={},this.onUnitSelect=null,this.selected=!1}get bedAndBathText(){return`${0===this.unit.numberOfBedrooms?"studio":`${this.unit.numberOfBedrooms}bd`} | ${this.unit.numberOfBathrooms}ba`}get priceRange(){return this.unit.startingPrice===this.unit.maxPrice?`$${this.unit.startingPrice}`:`$${this.unit.startingPrice} - $${this.unit.maxPrice}`}handleOnUnitSelect(){var e;this.selected||(this.selected=!this.selected,null===(e=this.onUnitSelect)||void 0===e||e.call(this,this.unit))}handleOnImgClick(e){const t=e.target;window.open(t.src,"_blank")}render(){return H`
6977
6949
  <div class="floorplan-image-card ${this.selected?"selected":""}">
6978
6950
  <div class="section-left">
6979
6951
  ${this.unit.floorplanUrl?H`
@@ -6998,7 +6970,7 @@ xmlns="http://www.w3.org/2000/svg"
6998
6970
  </p>
6999
6971
  </div>
7000
6972
  </div>
7001
- `}};fc.styles=Yu,pc([pe({type:Object})],fc.prototype,"unit",void 0),pc([pe()],fc.prototype,"onUnitSelect",void 0),pc([pe({type:Boolean})],fc.prototype,"selected",void 0),fc=pc([ce("floorplan-image-card")],fc);var gc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let mc=class extends ue{constructor(){super(...arguments),this.buildingSlug="",this.layoutOptions=[],this.selectedLayoutIds=[ec],this.units=[],this.isLoading=!1,this.isLoadingLayouts=!1,this.onSelectLayout=null,this.onUnitSelect=null,this.onMoveInDateChange=null,this.onLeaseTermChange=null,this.moveInDate=Hr(),this.leaseTerm=12,this.selectedUnit=null,this.handleUnitSelect=e=>{var t;this.selectedUnit=e,null===(t=this.onUnitSelect)||void 0===t||t.call(this,e)},this.handleLayoutChange=e=>{var t;let n;e===ec?n=[ec]:this.selectedLayoutIds.includes(ec)?n=[e]:this.selectedLayoutIds.includes(e)?(n=this.selectedLayoutIds.filter(t=>t!==e),0===n.length&&(n=[ec])):n=[...this.selectedLayoutIds,e],this.selectedLayoutIds=n,null===(t=this.onSelectLayout)||void 0===t||t.call(this,this.selectedLayoutIds)},this.handleMoveInDateChange=e=>{var t;const n=e.target.value,i=Hr();if(n){const[e,t,r]=n.split("-").map(Number),o=new Date(e,t-1,r);if(Tr(o,i))return;this.moveInDate=o}else this.moveInDate=i;null===(t=this.onMoveInDateChange)||void 0===t||t.call(this,n||ic(i))},this.handleLeaseTermChange=e=>{var t;const n=parseInt(e.target.value);!Number.isInteger(n)||n<=0||(this.leaseTerm=n,null===(t=this.onLeaseTermChange)||void 0===t||t.call(this,this.leaseTerm))},this.renderUnitSelection=()=>{var e,t;return this.isLoading?H`
6973
+ `}};hc.styles=Qu,cc([pe({type:Object})],hc.prototype,"unit",void 0),cc([pe()],hc.prototype,"onUnitSelect",void 0),cc([pe({type:Boolean})],hc.prototype,"selected",void 0),hc=cc([ce("floorplan-image-card")],hc);var pc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let fc=class extends ue{constructor(){super(...arguments),this.buildingSlug="",this.layoutOptions=[],this.selectedLayoutIds=[Zd],this.units=[],this.isLoading=!1,this.isLoadingLayouts=!1,this.onSelectLayout=null,this.onUnitSelect=null,this.onMoveInDateChange=null,this.onLeaseTermChange=null,this.moveInDate=Hr(),this.leaseTerm=12,this.selectedUnit=null,this.handleUnitSelect=e=>{var t;this.selectedUnit=e,null===(t=this.onUnitSelect)||void 0===t||t.call(this,e)},this.handleLayoutChange=e=>{var t;let n;e===Zd?n=[Zd]:this.selectedLayoutIds.includes(Zd)?n=[e]:this.selectedLayoutIds.includes(e)?(n=this.selectedLayoutIds.filter(t=>t!==e),0===n.length&&(n=[Zd])):n=[...this.selectedLayoutIds,e],this.selectedLayoutIds=n,null===(t=this.onSelectLayout)||void 0===t||t.call(this,this.selectedLayoutIds)},this.handleMoveInDateChange=e=>{var t;const n=e.target.value,i=Hr();if(n){const[e,t,r]=n.split("-").map(Number),o=new Date(e,t-1,r);if(Tr(o,i))return;this.moveInDate=o}else this.moveInDate=i;null===(t=this.onMoveInDateChange)||void 0===t||t.call(this,n||tc(i))},this.handleLeaseTermChange=e=>{var t;const n=parseInt(e.target.value);!Number.isInteger(n)||n<=0||(this.leaseTerm=n,null===(t=this.onLeaseTermChange)||void 0===t||t.call(this,this.leaseTerm))},this.renderUnitSelection=()=>{var e,t;return this.isLoading?H`
7002
6974
  <div class="unit-selection">
7003
6975
  <div class="image-carousel">
7004
6976
  ${Array.from({length:3},()=>H`<div class="unit-card-skeleton shimmer"></div>`)}
@@ -7036,7 +7008,7 @@ xmlns="http://www.w3.org/2000/svg"
7036
7008
  </div>
7037
7009
  `)}
7038
7010
  </div>
7039
- `}get displayOptions(){const e=e=>{let t=e;return Object.entries({zero:"0",one:"1",two:"2",three:"3",four:"4",five:"5",six:"6",seven:"7",eight:"8",nine:"9",ten:"10",eleven:"11",twelve:"12"}).forEach(([e,n])=>{const i=new RegExp(`\\b${e}\\b`,"gi");t=t.replace(i,n)}),t};return[{value:ec,label:"All"},...this.layoutOptions].map(t=>({...t,label:e(t.label.replace(/bedroom/gi,"bd"))})).sort((e,t)=>e.value-t.value)}render(){return H`
7011
+ `}get displayOptions(){const e=e=>{let t=e;return Object.entries({zero:"0",one:"1",two:"2",three:"3",four:"4",five:"5",six:"6",seven:"7",eight:"8",nine:"9",ten:"10",eleven:"11",twelve:"12"}).forEach(([e,n])=>{const i=new RegExp(`\\b${e}\\b`,"gi");t=t.replace(i,n)}),t};return[{value:Zd,label:"All"},...this.layoutOptions].map(t=>({...t,label:e(t.label.replace(/bedroom/gi,"bd"))})).sort((e,t)=>e.value-t.value)}render(){return H`
7040
7012
  <div class="floor-plan-selector">
7041
7013
  <div class="floor-plan-selector-label">Select Floor Plan</div>
7042
7014
  ${this.renderBadges()}
@@ -7048,8 +7020,8 @@ xmlns="http://www.w3.org/2000/svg"
7048
7020
  <input
7049
7021
  type="date"
7050
7022
  placeholder="Select move in date"
7051
- min=${rc()}
7052
- .value=${this.moveInDate?ic(this.moveInDate):""}
7023
+ min=${nc()}
7024
+ .value=${this.moveInDate?tc(this.moveInDate):""}
7053
7025
  @input=${this.handleMoveInDateChange}
7054
7026
  />
7055
7027
  </div>
@@ -7068,7 +7040,7 @@ xmlns="http://www.w3.org/2000/svg"
7068
7040
  ${this.renderUnitSelection()}
7069
7041
  </div>
7070
7042
  </div>
7071
- `}};mc.styles=Ku,gc([pe({type:String})],mc.prototype,"buildingSlug",void 0),gc([pe({type:Array})],mc.prototype,"layoutOptions",void 0),gc([pe({type:Array})],mc.prototype,"selectedLayoutIds",void 0),gc([pe({type:Array})],mc.prototype,"units",void 0),gc([pe({type:Boolean})],mc.prototype,"isLoading",void 0),gc([pe({type:Boolean})],mc.prototype,"isLoadingLayouts",void 0),gc([pe()],mc.prototype,"onSelectLayout",void 0),gc([pe()],mc.prototype,"onUnitSelect",void 0),gc([pe()],mc.prototype,"onMoveInDateChange",void 0),gc([pe()],mc.prototype,"onLeaseTermChange",void 0),gc([fe()],mc.prototype,"moveInDate",void 0),gc([fe()],mc.prototype,"leaseTerm",void 0),gc([fe()],mc.prototype,"selectedUnit",void 0),mc=gc([ce("floor-plan-selector")],mc);const bc=p`
7043
+ `}};fc.styles=qu,pc([pe({type:String})],fc.prototype,"buildingSlug",void 0),pc([pe({type:Array})],fc.prototype,"layoutOptions",void 0),pc([pe({type:Array})],fc.prototype,"selectedLayoutIds",void 0),pc([pe({type:Array})],fc.prototype,"units",void 0),pc([pe({type:Boolean})],fc.prototype,"isLoading",void 0),pc([pe({type:Boolean})],fc.prototype,"isLoadingLayouts",void 0),pc([pe()],fc.prototype,"onSelectLayout",void 0),pc([pe()],fc.prototype,"onUnitSelect",void 0),pc([pe()],fc.prototype,"onMoveInDateChange",void 0),pc([pe()],fc.prototype,"onLeaseTermChange",void 0),pc([fe()],fc.prototype,"moveInDate",void 0),pc([fe()],fc.prototype,"leaseTerm",void 0),pc([fe()],fc.prototype,"selectedUnit",void 0),fc=pc([ce("floor-plan-selector")],fc);const gc=p`
7072
7044
  :host {
7073
7045
  display: block;
7074
7046
  width: 100%;
@@ -7114,7 +7086,7 @@ xmlns="http://www.w3.org/2000/svg"
7114
7086
  font-size: 1rem;
7115
7087
  align-self: center;
7116
7088
  }
7117
- `;var yc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let vc=class extends ue{constructor(){super(...arguments),this.feeQuote=null}get name(){var e,t;if(null===(e=this.feeQuote)||void 0===e?void 0:e.sourceRentableItem)return Rr(this.feeQuote.sourceRentableItem.description||"");const n=null===(t=this.feeQuote)||void 0===t?void 0:t.marketableFee;return(null==n?void 0:n.feeName)?Rr(n.feeName):""}get description(){var e,t,n,i;if(null===(e=this.feeQuote)||void 0===e?void 0:e.sourceRentableItem){return`${this.feeQuote.sourceRentableItem.id}`}return null!==(i=null===(n=null===(t=this.feeQuote)||void 0===t?void 0:t.marketableFee)||void 0===n?void 0:n.description)&&void 0!==i?i:""}get additionalInfo(){var e,t,n;return null!==(n=null===(t=null===(e=this.feeQuote)||void 0===e?void 0:e.marketableFee)||void 0===t?void 0:t.additionalInfo)&&void 0!==n?n:""}get triggeredEvent(){var e,t;const n=null===(t=null===(e=this.feeQuote)||void 0===e?void 0:e.marketableFee)||void 0===t?void 0:t.triggeredByEvent;if(!n)return"";return{APPLICATION_SUBMISSION:"Due at Application Submission",APPLICATION_APPROVAL:"Due at Application Approval",LEASE_SIGNING:"Due at Lease Signing",MOVE_IN:"Due at Move-In"}[n]||n}get amount(){var e;if(!this.feeQuote)return null;const t=null!==(e=this.feeQuote.amountRange.fixedValue)&&void 0!==e?e:0;return 0===t?null:Br(t,2)}render(){return this.feeQuote&&this.amount?H`
7089
+ `;var mc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let bc=class extends ue{constructor(){super(...arguments),this.feeQuote=null}get name(){var e,t;if(null===(e=this.feeQuote)||void 0===e?void 0:e.sourceRentableItem)return Rr(this.feeQuote.sourceRentableItem.description||"");const n=null===(t=this.feeQuote)||void 0===t?void 0:t.marketableFee;return(null==n?void 0:n.feeName)?Rr(n.feeName):""}get description(){var e,t,n,i;if(null===(e=this.feeQuote)||void 0===e?void 0:e.sourceRentableItem){return`${this.feeQuote.sourceRentableItem.id}`}return null!==(i=null===(n=null===(t=this.feeQuote)||void 0===t?void 0:t.marketableFee)||void 0===n?void 0:n.description)&&void 0!==i?i:""}get additionalInfo(){var e,t,n;return null!==(n=null===(t=null===(e=this.feeQuote)||void 0===e?void 0:e.marketableFee)||void 0===t?void 0:t.additionalInfo)&&void 0!==n?n:""}get triggeredEvent(){var e,t;const n=null===(t=null===(e=this.feeQuote)||void 0===e?void 0:e.marketableFee)||void 0===t?void 0:t.triggeredByEvent;if(!n)return"";return{APPLICATION_SUBMISSION:"Due at Application Submission",APPLICATION_APPROVAL:"Due at Application Approval",LEASE_SIGNING:"Due at Lease Signing",MOVE_IN:"Due at Move-In"}[n]||n}get amount(){var e;if(!this.feeQuote)return null;const t=null!==(e=this.feeQuote.amountRange.fixedValue)&&void 0!==e?e:0;return 0===t?null:Br(t,2)}render(){return this.feeQuote&&this.amount?H`
7118
7090
  <div class="fee-item">
7119
7091
  <div class="fee-info">
7120
7092
  <div class="fee-name">${this.name}</div>
@@ -7128,7 +7100,7 @@ xmlns="http://www.w3.org/2000/svg"
7128
7100
  </div>
7129
7101
  <div class="fee-amount">${this.amount}</div>
7130
7102
  </div>
7131
- `:H``}};vc.styles=bc,yc([pe({type:Object})],vc.prototype,"feeQuote",void 0),vc=yc([ce("fee-item")],vc);var wc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Cc=class extends ue{constructor(){super(...arguments),this.feeQuotes=[]}get itemType(){const e=this.feeQuotes[0];return(null==e?void 0:e.sourceRentableItem)?Rr(e.sourceRentableItem.description||""):""}get priceGroups(){const e=new Map;return this.feeQuotes.forEach(t=>{var n;const i=null!==(n=t.amountRange.fixedValue)&&void 0!==n?n:0;e.set(i,(e.get(i)||0)+1)}),Array.from(e.entries()).map(([e,t])=>({price:e,count:t})).sort((e,t)=>e.price-t.price)}get totalAmount(){const e=this.feeQuotes.reduce((e,t)=>{var n;return e+(null!==(n=t.amountRange.fixedValue)&&void 0!==n?n:0)},0);return Br(e,2)}get priceBreakdown(){const e=this.priceGroups;if(0===e.length)return"";const t=this.getUnitName();return e.map(e=>{return`${e.count} ${n=t,i=e.count,1===i?n:`${n}s`} @ ${Br(e.price,2)}/month`;var n,i}).join(" + ")}getUnitName(){var e;const t=this.feeQuotes[0];return function(e){const t=e.toLowerCase();return t.includes("garage")||t.includes("parking")?"space":t.includes("storage")?"unit":t.includes("locker")?"locker":t.includes("bike")?"spot":"unit"}((null===(e=null==t?void 0:t.sourceRentableItem)||void 0===e?void 0:e.description)||"")}render(){return this.feeQuotes.length&&this.totalAmount!==Br(0,2)?H`
7103
+ `:H``}};bc.styles=gc,mc([pe({type:Object})],bc.prototype,"feeQuote",void 0),bc=mc([ce("fee-item")],bc);var yc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let vc=class extends ue{constructor(){super(...arguments),this.feeQuotes=[]}get itemType(){const e=this.feeQuotes[0];return(null==e?void 0:e.sourceRentableItem)?Rr(e.sourceRentableItem.description||""):""}get priceGroups(){const e=new Map;return this.feeQuotes.forEach(t=>{var n;const i=null!==(n=t.amountRange.fixedValue)&&void 0!==n?n:0;e.set(i,(e.get(i)||0)+1)}),Array.from(e.entries()).map(([e,t])=>({price:e,count:t})).sort((e,t)=>e.price-t.price)}get totalAmount(){const e=this.feeQuotes.reduce((e,t)=>{var n;return e+(null!==(n=t.amountRange.fixedValue)&&void 0!==n?n:0)},0);return Br(e,2)}get priceBreakdown(){const e=this.priceGroups;if(0===e.length)return"";const t=this.getUnitName();return e.map(e=>{return`${e.count} ${n=t,i=e.count,1===i?n:`${n}s`} @ ${Br(e.price,2)}/month`;var n,i}).join(" + ")}getUnitName(){var e;const t=this.feeQuotes[0];return function(e){const t=e.toLowerCase();return t.includes("garage")||t.includes("parking")?"space":t.includes("storage")?"unit":t.includes("locker")?"locker":t.includes("bike")?"spot":"unit"}((null===(e=null==t?void 0:t.sourceRentableItem)||void 0===e?void 0:e.description)||"")}render(){return this.feeQuotes.length&&this.totalAmount!==Br(0,2)?H`
7132
7104
  <div class="fee-item">
7133
7105
  <div class="fee-info">
7134
7106
  <div class="fee-name">${this.itemType}</div>
@@ -7136,7 +7108,7 @@ xmlns="http://www.w3.org/2000/svg"
7136
7108
  </div>
7137
7109
  <div class="fee-amount">${this.totalAmount}</div>
7138
7110
  </div>
7139
- `:H``}};Cc.styles=bc,wc([pe({type:Array})],Cc.prototype,"feeQuotes",void 0),Cc=wc([ce("grouped-rentable-item")],Cc);const xc=p`
7111
+ `:H``}};vc.styles=gc,yc([pe({type:Array})],vc.prototype,"feeQuotes",void 0),vc=yc([ce("grouped-rentable-item")],vc);const wc=p`
7140
7112
  .fee-card-section-container {
7141
7113
  margin: 0 12px;
7142
7114
  border-radius: 4px;
@@ -7196,7 +7168,7 @@ xmlns="http://www.w3.org/2000/svg"
7196
7168
  margin: 12px;
7197
7169
  justify-content: space-between;
7198
7170
  }
7199
- `;var $c=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Sc=class extends ue{constructor(){super(...arguments),this.title="Fees",this.fees=[],this.buildingFeesToQuantity={},this.handleQuantityChange=(e,t)=>{this.buildingFeesToQuantity[e]=t,this.requestUpdate()}}get totalAmount(){const e=this.fees.reduce((e,t)=>{var n;return e+(null!==(n=t.amountRange.fixedValue)&&void 0!==n?n:0)},0);return Br(e,2)}get groupedRentableItems(){const e=this.fees.filter(e=>e.sourceRentableItem);e.sort((e,t)=>{var n,i;const r=(null===(n=e.sourceRentableItem)||void 0===n?void 0:n.description)||"",o=(null===(i=t.sourceRentableItem)||void 0===i?void 0:i.description)||"";return r.localeCompare(o,navigator.language,{numeric:!0})});const t={};return e.forEach(e=>{var n;const i=(null===(n=e.sourceRentableItem)||void 0===n?void 0:n.description)||"unknown";t[i]||(t[i]=[]),t[i].push(e)}),t}get nonRentableItems(){return this.fees.filter(e=>!e.sourceRentableItem)}render(){return H`
7171
+ `;var Cc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let xc=class extends ue{constructor(){super(...arguments),this.title="Fees",this.fees=[],this.buildingFeesToQuantity={},this.handleQuantityChange=(e,t)=>{this.buildingFeesToQuantity[e]=t,this.requestUpdate()}}get totalAmount(){const e=this.fees.reduce((e,t)=>{var n;return e+(null!==(n=t.amountRange.fixedValue)&&void 0!==n?n:0)},0);return Br(e,2)}get groupedRentableItems(){const e=this.fees.filter(e=>e.sourceRentableItem);e.sort((e,t)=>{var n,i;const r=(null===(n=e.sourceRentableItem)||void 0===n?void 0:n.description)||"",o=(null===(i=t.sourceRentableItem)||void 0===i?void 0:i.description)||"";return r.localeCompare(o,navigator.language,{numeric:!0})});const t={};return e.forEach(e=>{var n;const i=(null===(n=e.sourceRentableItem)||void 0===n?void 0:n.description)||"unknown";t[i]||(t[i]=[]),t[i].push(e)}),t}get nonRentableItems(){return this.fees.filter(e=>!e.sourceRentableItem)}render(){return H`
7200
7172
  <div class="fee-card-section-container">
7201
7173
  <div class="fee-card-section-header">
7202
7174
  <h1 class="section-title">${this.title}</h1>
@@ -7220,7 +7192,7 @@ xmlns="http://www.w3.org/2000/svg"
7220
7192
  </div>
7221
7193
  </div>
7222
7194
  </div>
7223
- `}};Sc.styles=xc,$c([pe({type:String})],Sc.prototype,"title",void 0),$c([pe({type:Array})],Sc.prototype,"fees",void 0),$c([fe()],Sc.prototype,"buildingFeesToQuantity",void 0),Sc=$c([ce("fee-card")],Sc);const kc=p`
7195
+ `}};xc.styles=wc,Cc([pe({type:String})],xc.prototype,"title",void 0),Cc([pe({type:Array})],xc.prototype,"fees",void 0),Cc([fe()],xc.prototype,"buildingFeesToQuantity",void 0),xc=Cc([ce("fee-card")],xc);const $c=p`
7224
7196
  :host {
7225
7197
  --transition-timing: 0.2s ease;
7226
7198
  display: flex;
@@ -7429,7 +7401,7 @@ xmlns="http://www.w3.org/2000/svg"
7429
7401
  font-weight: bold;
7430
7402
  color: #0066cc;
7431
7403
  }
7432
- `;var Ac;!function(e){e.NEVER="NEVER",e.ONE_TIME="ONE_TIME",e.MONTHLY="MONTHLY",e.WEEKLY="WEEKLY",e.BI_WEEKLY="BI_WEEKLY",e.ANNUALLY="ANNUALLY",e.DAILY="DAILY"}(Ac||(Ac={}));var Tc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const Ec=["num_cats","num_dogs","num_other_pets"];let _c=class extends ue{constructor(){super(...arguments),this.chargeInputs={base_rent:0,num_pets:0,num_vehicles:0,num_applicants:1,num_cats:0,num_dogs:0,num_other_pets:0},this.onChargeInputsChange=null,this.disabled=!1,this.maxPets=null,this.rentableItems=[],this.selectedRentableItems=[],this.onRentableItemAdd=null,this.onRentableItemRemove=null,this.handleRentableItemToggle=e=>{var t,n;if(this.selectedRentableItems.some(t=>t.type===e.type)){const n=this.selectedRentableItems.find(t=>t.type===e.type);n&&(null===(t=this.onRentableItemRemove)||void 0===t||t.call(this,n))}else{const t=e.minAvailableItem||e.allItems[0];if(t){const i={id:t.id,type:e.type};null===(n=this.onRentableItemAdd)||void 0===n||n.call(this,i)}}}}get totalPets(){var e,t,n;return(null!==(e=this.chargeInputs.num_cats)&&void 0!==e?e:0)+(null!==(t=this.chargeInputs.num_dogs)&&void 0!==t?t:0)+(null!==(n=this.chargeInputs.num_other_pets)&&void 0!==n?n:0)}isAtPetLimit(e){return null!==this.maxPets&&Ec.includes(e)&&this.totalPets>=this.maxPets}handleIncrement(e){var t,n;if(this.isAtPetLimit(e))return;const i=(null!==(t=this.chargeInputs[e])&&void 0!==t?t:0)+1;Ec.includes(e)?this.updatePetCount({[e]:i}):null===(n=this.onChargeInputsChange)||void 0===n||n.call(this,{[e]:i})}handleDecrement(e){var t,n;const i=null!==(t=this.chargeInputs[e])&&void 0!==t?t:0,r="num_applicants"===e?1:0,o=Math.max(r,i-1);Ec.includes(e)?this.updatePetCount({[e]:o}):null===(n=this.onChargeInputsChange)||void 0===n||n.call(this,{[e]:o})}updatePetCount(e){var t,n,i,r;const o={...this.chargeInputs,...e},a=(null!==(t=o.num_cats)&&void 0!==t?t:0)+(null!==(n=o.num_dogs)&&void 0!==n?n:0)+(null!==(i=o.num_other_pets)&&void 0!==i?i:0);null===(r=this.onChargeInputsChange)||void 0===r||r.call(this,{...e,num_pets:a})}getFieldLabel(e){return{base_rent:"Base Rent ($)",num_pets:"Pets",num_vehicles:"Vehicles",num_applicants:"Applicants",num_cats:"Cats",num_dogs:"Dogs",num_other_pets:"All Other Pets"}[e]||e}renderRentableItemRow(e){const t=this.selectedRentableItems.some(t=>t.type===e.type);return H`
7404
+ `;var Sc;!function(e){e.NEVER="NEVER",e.ONE_TIME="ONE_TIME",e.MONTHLY="MONTHLY",e.WEEKLY="WEEKLY",e.BI_WEEKLY="BI_WEEKLY",e.ANNUALLY="ANNUALLY",e.DAILY="DAILY"}(Sc||(Sc={}));var kc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};const Ac=["num_cats","num_dogs","num_other_pets"];let Tc=class extends ue{constructor(){super(...arguments),this.chargeInputs={base_rent:0,num_pets:0,num_vehicles:0,num_applicants:1,num_cats:0,num_dogs:0,num_other_pets:0},this.onChargeInputsChange=null,this.disabled=!1,this.maxPets=null,this.rentableItems=[],this.selectedRentableItems=[],this.onRentableItemAdd=null,this.onRentableItemRemove=null,this.handleRentableItemToggle=e=>{var t,n;if(this.selectedRentableItems.some(t=>t.type===e.type)){const n=this.selectedRentableItems.find(t=>t.type===e.type);n&&(null===(t=this.onRentableItemRemove)||void 0===t||t.call(this,n))}else{const t=e.minAvailableItem||e.allItems[0];if(t){const i={id:t.id,type:e.type};null===(n=this.onRentableItemAdd)||void 0===n||n.call(this,i)}}}}get totalPets(){var e,t,n;return(null!==(e=this.chargeInputs.num_cats)&&void 0!==e?e:0)+(null!==(t=this.chargeInputs.num_dogs)&&void 0!==t?t:0)+(null!==(n=this.chargeInputs.num_other_pets)&&void 0!==n?n:0)}isAtPetLimit(e){return null!==this.maxPets&&Ac.includes(e)&&this.totalPets>=this.maxPets}handleIncrement(e){var t,n;if(this.isAtPetLimit(e))return;const i=(null!==(t=this.chargeInputs[e])&&void 0!==t?t:0)+1;Ac.includes(e)?this.updatePetCount({[e]:i}):null===(n=this.onChargeInputsChange)||void 0===n||n.call(this,{[e]:i})}handleDecrement(e){var t,n;const i=null!==(t=this.chargeInputs[e])&&void 0!==t?t:0,r="num_applicants"===e?1:0,o=Math.max(r,i-1);Ac.includes(e)?this.updatePetCount({[e]:o}):null===(n=this.onChargeInputsChange)||void 0===n||n.call(this,{[e]:o})}updatePetCount(e){var t,n,i,r;const o={...this.chargeInputs,...e},a=(null!==(t=o.num_cats)&&void 0!==t?t:0)+(null!==(n=o.num_dogs)&&void 0!==n?n:0)+(null!==(i=o.num_other_pets)&&void 0!==i?i:0);null===(r=this.onChargeInputsChange)||void 0===r||r.call(this,{...e,num_pets:a})}getFieldLabel(e){return{base_rent:"Base Rent ($)",num_pets:"Pets",num_vehicles:"Vehicles",num_applicants:"Applicants",num_cats:"Cats",num_dogs:"Dogs",num_other_pets:"All Other Pets"}[e]||e}renderRentableItemRow(e){const t=this.selectedRentableItems.some(t=>t.type===e.type);return H`
7433
7405
  <div class="rentable-item-row">
7434
7406
  <div class="rentable-item-info">
7435
7407
  <div class="rentable-item-label">${e.description}</div>
@@ -7478,7 +7450,7 @@ xmlns="http://www.w3.org/2000/svg"
7478
7450
  ${["num_applicants","num_cats","num_dogs","num_other_pets"].map(e=>this.renderChargeInputRow(e))}
7479
7451
  ${null!==this.maxPets?H`
7480
7452
  <div class="charge-input-note">
7481
- ${lc(this.maxPets)}
7453
+ ${ac(this.maxPets)}
7482
7454
  </div>
7483
7455
  `:""}
7484
7456
  </div>
@@ -7490,7 +7462,7 @@ xmlns="http://www.w3.org/2000/svg"
7490
7462
  </div>
7491
7463
  `:""}
7492
7464
  </div>
7493
- `}};_c.styles=p`
7465
+ `}};Tc.styles=p`
7494
7466
  .charge-inputs-container {
7495
7467
  background: white;
7496
7468
  border-radius: 8px;
@@ -7624,7 +7596,7 @@ xmlns="http://www.w3.org/2000/svg"
7624
7596
  opacity: 0.5;
7625
7597
  cursor: not-allowed;
7626
7598
  }
7627
- `,Tc([pe({type:Object})],_c.prototype,"chargeInputs",void 0),Tc([pe()],_c.prototype,"onChargeInputsChange",void 0),Tc([pe({type:Boolean})],_c.prototype,"disabled",void 0),Tc([pe({type:Number})],_c.prototype,"maxPets",void 0),Tc([pe({type:Array})],_c.prototype,"rentableItems",void 0),Tc([pe({type:Array})],_c.prototype,"selectedRentableItems",void 0),Tc([pe()],_c.prototype,"onRentableItemAdd",void 0),Tc([pe()],_c.prototype,"onRentableItemRemove",void 0),_c=Tc([ce("charge-inputs")],_c);const Oc=p`
7599
+ `,kc([pe({type:Object})],Tc.prototype,"chargeInputs",void 0),kc([pe()],Tc.prototype,"onChargeInputsChange",void 0),kc([pe({type:Boolean})],Tc.prototype,"disabled",void 0),kc([pe({type:Number})],Tc.prototype,"maxPets",void 0),kc([pe({type:Array})],Tc.prototype,"rentableItems",void 0),kc([pe({type:Array})],Tc.prototype,"selectedRentableItems",void 0),kc([pe()],Tc.prototype,"onRentableItemAdd",void 0),kc([pe()],Tc.prototype,"onRentableItemRemove",void 0),Tc=kc([ce("charge-inputs")],Tc);const Ec=p`
7628
7600
  :host {
7629
7601
  --skeleton-bg-color: #eaeaea;
7630
7602
  --skeleton-highlight-color: #f5f5f5;
@@ -7638,8 +7610,8 @@ xmlns="http://www.w3.org/2000/svg"
7638
7610
  background-position: 200px 0;
7639
7611
  }
7640
7612
  }
7641
- `,Pc=p`
7642
- ${Oc}
7613
+ `,_c=p`
7614
+ ${Ec}
7643
7615
 
7644
7616
  :host {
7645
7617
  display: block;
@@ -7704,8 +7676,8 @@ xmlns="http://www.w3.org/2000/svg"
7704
7676
  margin-bottom: 10px;
7705
7677
  }
7706
7678
  }
7707
- `,Ic=p`
7708
- ${Oc}
7679
+ `,Oc=p`
7680
+ ${Ec}
7709
7681
 
7710
7682
  :host {
7711
7683
  display: block;
@@ -7727,23 +7699,23 @@ xmlns="http://www.w3.org/2000/svg"
7727
7699
  box-sizing: border-box;
7728
7700
  }
7729
7701
  }
7730
- `;var Nc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Mc=class extends ue{constructor(){super(...arguments),this.rows=2,this.header=!0}render(){return H`
7702
+ `;var Pc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Ic=class extends ue{constructor(){super(...arguments),this.rows=2,this.header=!0}render(){return H`
7731
7703
  <div class="skeleton-card">
7732
7704
  ${this.header?H`<div class="skeleton-header"></div>`:""}
7733
7705
  ${Array(this.rows).fill(0).map(()=>H`<div class="skeleton-row"></div>`)}
7734
7706
  </div>
7735
- `}};Mc.styles=Pc,Nc([pe({type:Number})],Mc.prototype,"rows",void 0),Nc([pe({type:Boolean})],Mc.prototype,"header",void 0),Mc=Nc([ce("skeleton-card")],Mc);var Dc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Lc=class extends ue{constructor(){super(...arguments),this.cards=3,this.rowsPerCard=[3,2,1]}render(){return H`
7707
+ `}};Ic.styles=_c,Pc([pe({type:Number})],Ic.prototype,"rows",void 0),Pc([pe({type:Boolean})],Ic.prototype,"header",void 0),Ic=Pc([ce("skeleton-card")],Ic);var Nc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Mc=class extends ue{constructor(){super(...arguments),this.cards=3,this.rowsPerCard=[3,2,1]}render(){return H`
7736
7708
  <div class="skeleton-loader">
7737
7709
  ${Array.from({length:this.cards},(e,t)=>{const n=Array.isArray(this.rowsPerCard)?this.rowsPerCard[t]||2:this.rowsPerCard;return H`<skeleton-card .rows=${n}></skeleton-card>`})}
7738
7710
  </div>
7739
- `}};Lc.styles=Ic,Dc([pe({type:Number})],Lc.prototype,"cards",void 0),Dc([pe({type:Array})],Lc.prototype,"rowsPerCard",void 0),Lc=Dc([ce("skeleton-loader")],Lc);var Rc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Bc=class extends ue{constructor(){super(...arguments),this.buildingSlug="",this.showSkeletonLoader=!1,this.selectedUnit=null,this.quote=null,this.quoteError=null,this.layoutOptions=[],this.selectedLayoutIds=[ec],this.groupedFees={[Wd.ONE_TIME]:[],[Wd.MONTHLY]:[],[Wd.WEEKLY]:[],[Wd.BI_WEEKLY]:[],[Wd.ANNUALLY]:[],[Wd.DAILY]:[],[Wd.AS_NEEDED]:[],[Wd.NEVER]:[]},this.rentableItems=[],this.units=[],this.isLoadingUnits=!1,this.isLoadingLayouts=!1,this.onSelectLayout=null,this.onUnitSelect=null,this.onMoveInDateChange=null,this.onLeaseTermChange=null,this.chargeInputs={base_rent:0,num_pets:0,num_vehicles:0,num_applicants:1},this.onChargeInputsChange=null,this.maxPets=null,this.selectedRentableItems=[],this.onRentableItemAdd=null,this.onRentableItemRemove=null}get rentAsFeeQuote(){var e,t;return(null===(e=this.quote)||void 0===e?void 0:e.rentCost)?{marketableFee:{id:"rent",buildingId:this.quote.buildingId||0,feeName:"Rent",amount:this.quote.rentCost,amountDisplay:Br(this.quote.rentCost,2),minEstimate:null,maxEstimate:null,percentRentMin:null,percentRentMax:null,percentRent:null,frequency:Ac.MONTHLY,category:"Rent",hiddenReason:null,description:`Unit ${null===(t=this.selectedUnit)||void 0===t?void 0:t.unitNumber}`,additionalInfo:null,refundable:!1,unitIds:null,layoutIds:null,startDate:null,endDate:null,triggeredByEvent:null,externalKey:null,chargeCode:null,bundleKey:null,source:null,publicFacing:!0,perApplicant:!1,prorated:null,syncActive:!0},amountRange:{fixedValue:this.quote.rentCost,minValue:null,maxValue:null},chargeInputs:{baseRent:this.quote.rentCost,numPets:0,numDogs:0,numCats:0,numOtherPets:0,numVehicles:0,numApplicants:1,unitId:this.quote.unitId,layoutId:null},isAddon:!1}:null}renderRecurringFeeSection(e,t){return(null==t?void 0:t.length)?H` <fee-card .fees=${t} title=${e}></fee-card> `:null}renderFeeSections(){var e,t;const n=[],i=[{freq:Ac.ANNUALLY,title:"Yearly Charges"},{freq:Ac.MONTHLY,title:"Monthly Charges"},{freq:Ac.BI_WEEKLY,title:"Bi-Weekly Charges"},{freq:Ac.WEEKLY,title:"Weekly Charges"},{freq:Ac.DAILY,title:"Daily Charges"},{freq:Ac.ONE_TIME,title:"One-Time"},{freq:Ac.NEVER,title:"No Charges"}],r=null===(e=this.quote)||void 0===e?void 0:e.feeQuotes;for(const{freq:e,title:o}of i){if(!(null==r?void 0:r.length)&&e!==Ac.MONTHLY)continue;let i=null!==(t=null==r?void 0:r.filter(t=>{var n,i;if((null===(n=t.marketableFee)||void 0===n?void 0:n.frequency)===e){if(e===Ac.ONE_TIME){return["APPLICATION_SUBMISSION","APPLICATION_APPROVAL","LEASE_SIGNING","MOVE_IN"].includes((null===(i=t.marketableFee)||void 0===i?void 0:i.triggeredByEvent)||"")}return!0}return!!t.sourceRentableItem&&("monthly"===t.sourceRentableItem.rentFrequency&&e===Ac.MONTHLY||"annually"===t.sourceRentableItem.rentFrequency&&e===Ac.ANNUALLY)}))&&void 0!==t?t:[];if(e===Ac.MONTHLY){const e=this.rentAsFeeQuote;e&&(i=[e,...i])}const a=this.renderRecurringFeeSection(o,i);a&&n.push(a)}return n}renderTotalCost(){var e;if(!(null===(e=this.quote)||void 0===e?void 0:e.totalMonthlyCost))return null;const t=this.quote.totalMonthlyCost.fixedValue;return t?H`
7711
+ `}};Mc.styles=Oc,Nc([pe({type:Number})],Mc.prototype,"cards",void 0),Nc([pe({type:Array})],Mc.prototype,"rowsPerCard",void 0),Mc=Nc([ce("skeleton-loader")],Mc);var Dc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Lc=class extends ue{constructor(){super(...arguments),this.buildingSlug="",this.showSkeletonLoader=!1,this.selectedUnit=null,this.quote=null,this.quoteError=null,this.layoutOptions=[],this.selectedLayoutIds=[Zd],this.groupedFees={[Gd.ONE_TIME]:[],[Gd.MONTHLY]:[],[Gd.WEEKLY]:[],[Gd.BI_WEEKLY]:[],[Gd.ANNUALLY]:[],[Gd.DAILY]:[],[Gd.AS_NEEDED]:[],[Gd.NEVER]:[]},this.rentableItems=[],this.units=[],this.isLoadingUnits=!1,this.isLoadingLayouts=!1,this.onSelectLayout=null,this.onUnitSelect=null,this.onMoveInDateChange=null,this.onLeaseTermChange=null,this.chargeInputs={base_rent:0,num_pets:0,num_vehicles:0,num_applicants:1},this.onChargeInputsChange=null,this.maxPets=null,this.selectedRentableItems=[],this.onRentableItemAdd=null,this.onRentableItemRemove=null}get rentAsFeeQuote(){var e,t;return(null===(e=this.quote)||void 0===e?void 0:e.rentCost)?{marketableFee:{id:"rent",buildingId:this.quote.buildingId||0,feeName:"Rent",amount:this.quote.rentCost,amountDisplay:Br(this.quote.rentCost,2),minEstimate:null,maxEstimate:null,percentRentMin:null,percentRentMax:null,percentRent:null,frequency:Sc.MONTHLY,category:"Rent",hiddenReason:null,description:`Unit ${null===(t=this.selectedUnit)||void 0===t?void 0:t.unitNumber}`,additionalInfo:null,refundable:!1,unitIds:null,layoutIds:null,startDate:null,endDate:null,triggeredByEvent:null,externalKey:null,chargeCode:null,bundleKey:null,source:null,publicFacing:!0,perApplicant:!1,prorated:null,syncActive:!0},amountRange:{fixedValue:this.quote.rentCost,minValue:null,maxValue:null},chargeInputs:{baseRent:this.quote.rentCost,numPets:0,numDogs:0,numCats:0,numOtherPets:0,numVehicles:0,numApplicants:1,unitId:this.quote.unitId,layoutId:null},isAddon:!1}:null}renderRecurringFeeSection(e,t){return(null==t?void 0:t.length)?H` <fee-card .fees=${t} title=${e}></fee-card> `:null}renderFeeSections(){var e,t;const n=[],i=[{freq:Sc.ANNUALLY,title:"Yearly Charges"},{freq:Sc.MONTHLY,title:"Monthly Charges"},{freq:Sc.BI_WEEKLY,title:"Bi-Weekly Charges"},{freq:Sc.WEEKLY,title:"Weekly Charges"},{freq:Sc.DAILY,title:"Daily Charges"},{freq:Sc.ONE_TIME,title:"One-Time"},{freq:Sc.NEVER,title:"No Charges"}],r=null===(e=this.quote)||void 0===e?void 0:e.feeQuotes;for(const{freq:e,title:o}of i){if(!(null==r?void 0:r.length)&&e!==Sc.MONTHLY)continue;let i=null!==(t=null==r?void 0:r.filter(t=>{var n,i;if((null===(n=t.marketableFee)||void 0===n?void 0:n.frequency)===e){if(e===Sc.ONE_TIME){return["APPLICATION_SUBMISSION","APPLICATION_APPROVAL","LEASE_SIGNING","MOVE_IN"].includes((null===(i=t.marketableFee)||void 0===i?void 0:i.triggeredByEvent)||"")}return!0}return!!t.sourceRentableItem&&("monthly"===t.sourceRentableItem.rentFrequency&&e===Sc.MONTHLY||"annually"===t.sourceRentableItem.rentFrequency&&e===Sc.ANNUALLY)}))&&void 0!==t?t:[];if(e===Sc.MONTHLY){const e=this.rentAsFeeQuote;e&&(i=[e,...i])}const a=this.renderRecurringFeeSection(o,i);a&&n.push(a)}return n}renderTotalCost(){var e;if(!(null===(e=this.quote)||void 0===e?void 0:e.totalMonthlyCost))return null;const t=this.quote.totalMonthlyCost.fixedValue;return t?H`
7740
7712
  <div class="total-cost-section">
7741
7713
  <div class="total-cost-row">
7742
7714
  <span class="total-cost-label">Total Monthly Cost:</span>
7743
7715
  <span class="total-cost-amount">${Br(t,2)}</span>
7744
7716
  </div>
7745
7717
  </div>
7746
- `:null}getQuoteErrorMessage(e){if("feeLimit"===e.type){return`${lc(Math.min(...e.violations.map(e=>e.limit)))}. Remove a pet to see your estimate.`}return"We couldn't calculate an estimate. Please adjust your selections or try again later."}renderFeesContent(){return this.selectedUnit?this.quoteError&&!this.showSkeletonLoader?H`
7718
+ `:null}getQuoteErrorMessage(e){if("feeLimit"===e.type){return`${ac(Math.min(...e.violations.map(e=>e.limit)))}. Remove a pet to see your estimate.`}return"We couldn't calculate an estimate. Please adjust your selections or try again later."}renderFeesContent(){return this.selectedUnit?this.quoteError&&!this.showSkeletonLoader?H`
7747
7719
  <div class="fees-container empty-state" role="alert">
7748
7720
  <p class="quote-error-message">
7749
7721
  ${this.getQuoteErrorMessage(this.quoteError)}
@@ -7799,7 +7771,7 @@ xmlns="http://www.w3.org/2000/svg"
7799
7771
 
7800
7772
  ${this.renderFeesContent()}
7801
7773
  </div>
7802
- `}};Bc.styles=kc,Rc([pe({type:String})],Bc.prototype,"buildingSlug",void 0),Rc([pe({type:Boolean})],Bc.prototype,"showSkeletonLoader",void 0),Rc([pe({type:Object})],Bc.prototype,"selectedUnit",void 0),Rc([pe({type:Object})],Bc.prototype,"quote",void 0),Rc([pe({type:Object})],Bc.prototype,"quoteError",void 0),Rc([pe({type:Array})],Bc.prototype,"layoutOptions",void 0),Rc([pe({type:Array})],Bc.prototype,"selectedLayoutIds",void 0),Rc([pe({type:Object})],Bc.prototype,"groupedFees",void 0),Rc([pe({type:Array})],Bc.prototype,"rentableItems",void 0),Rc([pe({type:Array})],Bc.prototype,"units",void 0),Rc([pe({type:Boolean})],Bc.prototype,"isLoadingUnits",void 0),Rc([pe({type:Boolean})],Bc.prototype,"isLoadingLayouts",void 0),Rc([pe()],Bc.prototype,"onSelectLayout",void 0),Rc([pe()],Bc.prototype,"onUnitSelect",void 0),Rc([pe()],Bc.prototype,"onMoveInDateChange",void 0),Rc([pe()],Bc.prototype,"onLeaseTermChange",void 0),Rc([pe({type:Object})],Bc.prototype,"chargeInputs",void 0),Rc([pe()],Bc.prototype,"onChargeInputsChange",void 0),Rc([pe({type:Number})],Bc.prototype,"maxPets",void 0),Rc([pe({type:Array})],Bc.prototype,"selectedRentableItems",void 0),Rc([pe()],Bc.prototype,"onRentableItemAdd",void 0),Rc([pe()],Bc.prototype,"onRentableItemRemove",void 0),Bc=Rc([ce("fee-calculator-layout")],Bc);var Uc,jc,Fc,Hc;!function(e){e.OneTime="OneTime",e.Daily="Daily",e.Weekly="Weekly",e.BiWeekly="BiWeekly",e.Monthly="Monthly",e.Yearly="Yearly",e.Unknown="Unknown"}(Uc||(Uc={})),function(e){e.Debit="Debit",e.Credit="Credit"}(jc||(jc={})),function(e){e.Fixed="Fixed",e.UsageBased="UsageBased",e.Varies="Varies"}(Fc||(Fc={})),function(e){e.AdminFee="AdminFee",e.ApplicationFee="ApplicationFee",e.Concession="Concession",e.Insurance="Insurance",e.LateFee="LateFee",e.Legal="Legal",e.NonSufficientFundFee="NSF",e.Other="Other",e.Parking="Parking",e.Penalty="Penalty",e.Pest="Pest",e.PetDeposit="PetDeposit",e.PetRent="PetRent",e.Refund="Refund",e.Relet="Relet",e.Rent="Rent",e.SecurityDeposit="SecurityDeposit",e.Storage="Storage",e.Trash="Trash",e.Utility="Utility",e.WaterSewer="WaterSewer"}(Hc||(Hc={}));const zc=p`
7774
+ `}};Lc.styles=$c,Dc([pe({type:String})],Lc.prototype,"buildingSlug",void 0),Dc([pe({type:Boolean})],Lc.prototype,"showSkeletonLoader",void 0),Dc([pe({type:Object})],Lc.prototype,"selectedUnit",void 0),Dc([pe({type:Object})],Lc.prototype,"quote",void 0),Dc([pe({type:Object})],Lc.prototype,"quoteError",void 0),Dc([pe({type:Array})],Lc.prototype,"layoutOptions",void 0),Dc([pe({type:Array})],Lc.prototype,"selectedLayoutIds",void 0),Dc([pe({type:Object})],Lc.prototype,"groupedFees",void 0),Dc([pe({type:Array})],Lc.prototype,"rentableItems",void 0),Dc([pe({type:Array})],Lc.prototype,"units",void 0),Dc([pe({type:Boolean})],Lc.prototype,"isLoadingUnits",void 0),Dc([pe({type:Boolean})],Lc.prototype,"isLoadingLayouts",void 0),Dc([pe()],Lc.prototype,"onSelectLayout",void 0),Dc([pe()],Lc.prototype,"onUnitSelect",void 0),Dc([pe()],Lc.prototype,"onMoveInDateChange",void 0),Dc([pe()],Lc.prototype,"onLeaseTermChange",void 0),Dc([pe({type:Object})],Lc.prototype,"chargeInputs",void 0),Dc([pe()],Lc.prototype,"onChargeInputsChange",void 0),Dc([pe({type:Number})],Lc.prototype,"maxPets",void 0),Dc([pe({type:Array})],Lc.prototype,"selectedRentableItems",void 0),Dc([pe()],Lc.prototype,"onRentableItemAdd",void 0),Dc([pe()],Lc.prototype,"onRentableItemRemove",void 0),Lc=Dc([ce("fee-calculator-layout")],Lc);var Rc,Bc,Uc,jc;!function(e){e.OneTime="OneTime",e.Daily="Daily",e.Weekly="Weekly",e.BiWeekly="BiWeekly",e.Monthly="Monthly",e.Yearly="Yearly",e.Unknown="Unknown"}(Rc||(Rc={})),function(e){e.Debit="Debit",e.Credit="Credit"}(Bc||(Bc={})),function(e){e.Fixed="Fixed",e.UsageBased="UsageBased",e.Varies="Varies"}(Uc||(Uc={})),function(e){e.AdminFee="AdminFee",e.ApplicationFee="ApplicationFee",e.Concession="Concession",e.Insurance="Insurance",e.LateFee="LateFee",e.Legal="Legal",e.NonSufficientFundFee="NSF",e.Other="Other",e.Parking="Parking",e.Penalty="Penalty",e.Pest="Pest",e.PetDeposit="PetDeposit",e.PetRent="PetRent",e.Refund="Refund",e.Relet="Relet",e.Rent="Rent",e.SecurityDeposit="SecurityDeposit",e.Storage="Storage",e.Trash="Trash",e.Utility="Utility",e.WaterSewer="WaterSewer"}(jc||(jc={}));const Fc=p`
7803
7775
  :host {
7804
7776
  display: block;
7805
7777
  --table-header-bg: white;
@@ -7867,7 +7839,48 @@ xmlns="http://www.w3.org/2000/svg"
7867
7839
  color: #888;
7868
7840
  font-style: italic;
7869
7841
  }
7870
- `,Gc=p`
7842
+ `;var Hc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let zc=class extends ue{constructor(){super(...arguments),this.tooltip="",this.disabled=!1}render(){return H`
7843
+ <div
7844
+ class="tooltip-container ${this.disabled?"":"show-tooltip"}"
7845
+ data-tooltip="${this.tooltip}"
7846
+ >
7847
+ <slot></slot>
7848
+ </div>
7849
+ `}};zc.styles=p`
7850
+ :host {
7851
+ display: block;
7852
+ position: relative;
7853
+ width: 100%;
7854
+ }
7855
+
7856
+ .tooltip-container {
7857
+ position: relative;
7858
+ width: 100%;
7859
+ }
7860
+
7861
+ .tooltip-container.show-tooltip::after {
7862
+ content: attr(data-tooltip);
7863
+ position: absolute;
7864
+ top: -30px;
7865
+ left: 50%;
7866
+ transform: translateX(-50%);
7867
+ background-color: #333;
7868
+ color: white;
7869
+ padding: 5px 10px;
7870
+ border-radius: 4px;
7871
+ font-size: 12px;
7872
+ white-space: nowrap;
7873
+ opacity: 0;
7874
+ visibility: hidden;
7875
+ transition: opacity 0.3s, visibility 0.3s;
7876
+ z-index: 1000;
7877
+ }
7878
+
7879
+ .tooltip-container.show-tooltip:hover::after {
7880
+ opacity: 1;
7881
+ visibility: visible;
7882
+ }
7883
+ `,Hc([pe({type:String})],zc.prototype,"tooltip",void 0),Hc([pe({type:Boolean,reflect:!0})],zc.prototype,"disabled",void 0),zc=Hc([ce("simple-tooltip")],zc);const Gc=p`
7871
7884
  :host {
7872
7885
  display: inline-flex;
7873
7886
  }
@@ -7972,7 +7985,7 @@ xmlns="http://www.w3.org/2000/svg"
7972
7985
  <span class="operator-sign">+</span>
7973
7986
  </button>
7974
7987
  </div>
7975
- `}};Qc.styles=Gc,Vc([pe({type:Object})],Qc.prototype,"rentableItem",void 0),Vc([pe()],Qc.prototype,"onQuantityChange",void 0),Vc([pe({type:Boolean,reflect:!0})],Qc.prototype,"disabled",void 0),Vc([pe({type:Number})],Qc.prototype,"quantity",void 0),Vc([pe({type:Set})],Qc.prototype,"selectedItemIds",void 0),Qc=Vc([ce("table-rentable-item-qty-selector")],Qc);var qc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Yc=class extends ue{constructor(){super(...arguments),this._addons=[],this.disabled=!1,this.onAddonSelect=null,this.onRentableItemAdd=null,this.onRentableItemRemove=null,this.quantities=new Map,this.selectedRentableItemIds=new Map,this.handleAddonQuantityChange=e=>{var t;const n=e.id;1!==e.quantities.length||Array.isArray(this.quantities.get(n))?this.quantities.set(n,e.quantities):this.quantities.set(n,e.quantities[0].quantity),this.requestUpdate("quantities"),null===(t=this.onAddonSelect)||void 0===t||t.call(this,e)},this.handleRentableItemQuantityChange=e=>{var t,n,i,r,o,a;const s=null!==(t=this.quantities.get(e.type))&&void 0!==t?t:0;this.quantities.set(e.type,e.quantity),this.requestUpdate("quantities");const l=this.addons.find(t=>t instanceof Vd&&t.type===e.type);if(!l)return;const u=null!==(n=this.selectedRentableItemIds.get(e.type))&&void 0!==n?n:new Set,d=(c=null!==(r=null===(i=l.allItems)||void 0===i?void 0:i.filter(e=>e.available))&&void 0!==r?r:[],[...c].sort((e,t)=>e.rent!==t.rent?e.rent-t.rent:e.id.localeCompare(t.id)));var c;if(e.quantity>s){const t=e.quantity-s;let n=0;const i=Math.min(d.length,10);if(u.size+t>i)return;for(const i of d){if(n>=t)break;u.has(i.id)||(u.add(i.id),null===(o=this.onRentableItemAdd)||void 0===o||o.call(this,{id:i.id,type:e.type}),n++)}}else if(e.quantity<s){const t=s-e.quantity;let n=0;const i=function(e){return[...e].sort((e,t)=>e.rent!==t.rent?t.rent-e.rent:t.id.localeCompare(e.id))}(d.filter(e=>u.has(e.id)));for(const r of i){if(n>=t)break;u.delete(r.id),null===(a=this.onRentableItemRemove)||void 0===a||a.call(this,{id:r.id,type:e.type}),n++}}this.selectedRentableItemIds.set(e.type,u),this.requestUpdate("selectedRentableItemIds")}}set addons(e){const t=this._addons;this._addons=e,e!==t&&this.initializeQuantities(),this.requestUpdate("addons",t)}get addons(){return this._addons}preserveExistingQuantity(e,t){const n=this.quantities.get(e);return null!=n?n:t}initializeRentableItemQuantity(e,t){const n=this.preserveExistingQuantity(e.type,0);t.set(e.type,n),this.selectedRentableItemIds.has(e.type)||this.selectedRentableItemIds.set(e.type,new Set)}initializeBuildingFeeQuantity(e,t){const n=e.id,i=this.preserveExistingQuantity(n,0);t.set(n,i)}initializeQuantities(){const e=new Map;this.addons.forEach(t=>{t instanceof Vd?this.initializeRentableItemQuantity(t,e):this.initializeBuildingFeeQuantity(t,e)}),this.quantities=e}getName(e){return e instanceof Vd?e.displayName:e.fee_name}getSortedAddons(){return[...this.addons].sort((e,t)=>{const n=this.getName(e),i=this.getName(t);return n.localeCompare(i,navigator.language,{numeric:!0})})}isRentableItemAvailable(e){var t,n;return!(e instanceof Vd)||(null!==(n=null===(t=e.allItems)||void 0===t?void 0:t.filter(e=>e.available).length)&&void 0!==n?n:0)>0}renderQtySelector(e){var t;if(e instanceof Vd){const n=null!==(t=this.quantities.get(e.type))&&void 0!==t?t:0;return H`
7988
+ `}};Qc.styles=Gc,Vc([pe({type:Object})],Qc.prototype,"rentableItem",void 0),Vc([pe()],Qc.prototype,"onQuantityChange",void 0),Vc([pe({type:Boolean,reflect:!0})],Qc.prototype,"disabled",void 0),Vc([pe({type:Number})],Qc.prototype,"quantity",void 0),Vc([pe({type:Set})],Qc.prototype,"selectedItemIds",void 0),Qc=Vc([ce("table-rentable-item-qty-selector")],Qc);var qc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Yc=class extends ue{constructor(){super(...arguments),this._addons=[],this.disabled=!1,this.onAddonSelect=null,this.onRentableItemAdd=null,this.onRentableItemRemove=null,this.quantities=new Map,this.selectedRentableItemIds=new Map,this.handleAddonQuantityChange=e=>{var t;const n=e.id;1!==e.quantities.length||Array.isArray(this.quantities.get(n))?this.quantities.set(n,e.quantities):this.quantities.set(n,e.quantities[0].quantity),this.requestUpdate("quantities"),null===(t=this.onAddonSelect)||void 0===t||t.call(this,e)},this.handleRentableItemQuantityChange=e=>{var t,n,i,r,o,a;const s=null!==(t=this.quantities.get(e.type))&&void 0!==t?t:0;this.quantities.set(e.type,e.quantity),this.requestUpdate("quantities");const l=this.addons.find(t=>t instanceof zd&&t.type===e.type);if(!l)return;const u=null!==(n=this.selectedRentableItemIds.get(e.type))&&void 0!==n?n:new Set,d=(c=null!==(r=null===(i=l.allItems)||void 0===i?void 0:i.filter(e=>e.available))&&void 0!==r?r:[],[...c].sort((e,t)=>e.rent!==t.rent?e.rent-t.rent:e.id.localeCompare(t.id)));var c;if(e.quantity>s){const t=e.quantity-s;let n=0;const i=Math.min(d.length,10);if(u.size+t>i)return;for(const i of d){if(n>=t)break;u.has(i.id)||(u.add(i.id),null===(o=this.onRentableItemAdd)||void 0===o||o.call(this,{id:i.id,type:e.type}),n++)}}else if(e.quantity<s){const t=s-e.quantity;let n=0;const i=function(e){return[...e].sort((e,t)=>e.rent!==t.rent?t.rent-e.rent:t.id.localeCompare(e.id))}(d.filter(e=>u.has(e.id)));for(const r of i){if(n>=t)break;u.delete(r.id),null===(a=this.onRentableItemRemove)||void 0===a||a.call(this,{id:r.id,type:e.type}),n++}}this.selectedRentableItemIds.set(e.type,u),this.requestUpdate("selectedRentableItemIds")}}set addons(e){const t=this._addons;this._addons=e,e!==t&&this.initializeQuantities(),this.requestUpdate("addons",t)}get addons(){return this._addons}preserveExistingQuantity(e,t){const n=this.quantities.get(e);return null!=n?n:t}initializeRentableItemQuantity(e,t){const n=this.preserveExistingQuantity(e.type,0);t.set(e.type,n),this.selectedRentableItemIds.has(e.type)||this.selectedRentableItemIds.set(e.type,new Set)}initializeBuildingFeeQuantity(e,t){const n=e.id,i=this.preserveExistingQuantity(n,0);t.set(n,i)}initializeQuantities(){const e=new Map;this.addons.forEach(t=>{t instanceof zd?this.initializeRentableItemQuantity(t,e):this.initializeBuildingFeeQuantity(t,e)}),this.quantities=e}getName(e){return e instanceof zd?e.displayName:e.fee_name}getSortedAddons(){return[...this.addons].sort((e,t)=>{const n=this.getName(e),i=this.getName(t);return n.localeCompare(i,navigator.language,{numeric:!0})})}isRentableItemAvailable(e){var t,n;return!(e instanceof zd)||(null!==(n=null===(t=e.allItems)||void 0===t?void 0:t.filter(e=>e.available).length)&&void 0!==n?n:0)>0}renderQtySelector(e){var t;if(e instanceof zd){const n=null!==(t=this.quantities.get(e.type))&&void 0!==t?t:0;return H`
7976
7989
  <table-rentable-item-qty-selector
7977
7990
  .rentableItem=${e}
7978
7991
  .quantity=${n}
@@ -8013,7 +8026,7 @@ xmlns="http://www.w3.org/2000/svg"
8013
8026
  </tbody>
8014
8027
  </table>
8015
8028
  </div>
8016
- `:H`<div class="empty-state">No add-ons available</div> `}};Yc.styles=zc,qc([pe({type:Array})],Yc.prototype,"addons",null),qc([pe({type:Boolean})],Yc.prototype,"disabled",void 0),qc([pe()],Yc.prototype,"onAddonSelect",void 0),qc([pe({attribute:!1})],Yc.prototype,"onRentableItemAdd",void 0),qc([pe({attribute:!1})],Yc.prototype,"onRentableItemRemove",void 0),qc([fe()],Yc.prototype,"quantities",void 0),qc([fe()],Yc.prototype,"selectedRentableItemIds",void 0),Yc=qc([ce("addon-table")],Yc);var Kc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Xc=class extends ue{constructor(){super(...arguments),this.id="",this.showChatAdditionalActions=!1,this.buildingWebchatView=null,this.primaryColor=null,this.backgroundColor=null,this.foregroundColorOnPrimaryBackgroundColor=null,this.foregroundColorOnSecondaryBackgroundColor=null,this.enabledChatWidgets={callDesktop:!1,chatDesktop:!1,emailDesktop:!1,textDesktop:!1,sstDesktop:!1},this.onClickMinimize=()=>{},this.onClickEmailOption=()=>{},this.onClickPhoneOption=()=>{},this.onClickSSTOption=()=>{},this.onClose=()=>{}}render(){var e,t,n;const i=this.primaryColor||Zn,r=this.backgroundColor||"#ffffff",o=this.buildingWebchatView&&ii(this.buildingWebchatView.orgId,this.buildingWebchatView.id)&&i!==Zn?ni(i,.6):"black";return H`
8029
+ `:H`<div class="empty-state">No add-ons available</div> `}};Yc.styles=Fc,qc([pe({type:Array})],Yc.prototype,"addons",null),qc([pe({type:Boolean})],Yc.prototype,"disabled",void 0),qc([pe()],Yc.prototype,"onAddonSelect",void 0),qc([pe({attribute:!1})],Yc.prototype,"onRentableItemAdd",void 0),qc([pe({attribute:!1})],Yc.prototype,"onRentableItemRemove",void 0),qc([fe()],Yc.prototype,"quantities",void 0),qc([fe()],Yc.prototype,"selectedRentableItemIds",void 0),Yc=qc([ce("addon-table")],Yc);var Kc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let Xc=class extends ue{constructor(){super(...arguments),this.id="",this.showChatAdditionalActions=!1,this.buildingWebchatView=null,this.primaryColor=null,this.backgroundColor=null,this.foregroundColorOnPrimaryBackgroundColor=null,this.foregroundColorOnSecondaryBackgroundColor=null,this.enabledChatWidgets={callDesktop:!1,chatDesktop:!1,emailDesktop:!1,textDesktop:!1,sstDesktop:!1},this.onClickMinimize=()=>{},this.onClickEmailOption=()=>{},this.onClickPhoneOption=()=>{},this.onClickSSTOption=()=>{},this.onClose=()=>{}}render(){var e,t,n;const i=this.primaryColor||Zn,r=this.backgroundColor||"#ffffff",o=this.buildingWebchatView&&ii(this.buildingWebchatView.orgId,this.buildingWebchatView.id)&&i!==Zn?ni(i,.6):"black";return H`
8017
8030
  <style>
8018
8031
  #${this.id}::after {
8019
8032
  border-right-color: ${o} !important;
@@ -8094,7 +8107,7 @@ xmlns="http://www.w3.org/2000/svg"
8094
8107
  }
8095
8108
  `;var Jc=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let eh=class extends ue{getFormattedEndDate(e){return new Date(e.endDate).toLocaleDateString("en-US",{month:"long",day:"numeric",year:"numeric"})}render(){return this.incentive?H`
8096
8109
  <div class="incentive-banner">
8097
- <div class="incentive-icon">${uc({size:32})}</div>
8110
+ <div class="incentive-icon">${sc({size:32})}</div>
8098
8111
  <div class="incentive-content">
8099
8112
  <h2 class="incentive-title">
8100
8113
  ${this.incentive.originalIncentiveString}
@@ -8105,7 +8118,7 @@ xmlns="http://www.w3.org/2000/svg"
8105
8118
  </p>
8106
8119
  </div>
8107
8120
  </div>
8108
- `:H``}};eh.styles=Zc,Jc([pe({type:Object})],eh.prototype,"incentive",void 0),eh=Jc([ce("incentive-banner")],eh);var th=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let nh=class extends ue{constructor(){super(...arguments),this.buildingSlug="",this.orgSlug="",this.primaryColor=Zn,this.backgroundColor=Jn,this.onCloseClicked=null,this.onClickEmailOption=null,this.onClickPhoneOption=null,this.onClickSSTOption=null,this.onClickTextUsOption=null,this.isCalculatingQuote=!1,this.isLoadingLayouts=!0,this.isExporting=!1,this.selectedLayoutIds=[ec],this.selectedUnit=null,this.chargeInputs={base_rent:0,num_pets:0,num_vehicles:0,num_applicants:1,num_cats:0,num_dogs:0,num_other_pets:0},this.desiredRentableItems=[],this.moveInDateString=rc(),this.leaseTerm=12,this.buildingWebchatView=null,this.incentives=[],this.quote=null,this.pdfUrl=null,this.quoteError=null,this.groupedFees={[Wd.ONE_TIME]:[],[Wd.MONTHLY]:[],[Wd.WEEKLY]:[],[Wd.BI_WEEKLY]:[],[Wd.ANNUALLY]:[],[Wd.DAILY]:[],[Wd.AS_NEEDED]:[],[Wd.NEVER]:[]},this.rentableItems=[],this.maxPets=null,this.units=[],this.isLoadingUnits=!0,this.quoteAbortController=null,this.quoteDebounceTimer=null,this.startQuoteApiCall=async()=>{var e;null===(e=this.quoteAbortController)||void 0===e||e.abort(),this.quoteAbortController=new AbortController,this.isCalculatingQuote=!0,await this.performQuoteCalculation(this.quoteAbortController.signal)},this.firstUpdated=async()=>{this.style.setProperty("--primary-color",this.primaryColor),this.style.setProperty("--background-color",this.backgroundColor),await Promise.allSettled([this.setupCalculator(),this.fetchUnits()])},this.setupCalculator=async()=>{if(!this.buildingSlug||!this.orgSlug)return void(this.isLoadingLayouts=!1);const e=ya(this.orgSlug,this.buildingSlug).then(e=>{e&&(this.buildingWebchatView=e)}).finally(()=>{this.isLoadingLayouts=!1}),t=Jd(this.buildingSlug).then(e=>{e&&(this.groupedFees=this.groupFees(e.fees),this.maxPets=function(e){const t=e.filter(e=>sc.includes(e.category)).map(e=>e.limit).filter(e=>"number"==typeof e);return t.length?Math.min(...t):null}(e.fees),this.rentableItems=e.rentableItems)});await Promise.allSettled([e,t])},this.requestQuoteCalculation=()=>{if(this.quoteDebounceTimer&&(clearTimeout(this.quoteDebounceTimer),this.quoteDebounceTimer=null),!this.selectedUnit||!this.moveInDateString)return this.clearQuote(),void(this.isCalculatingQuote=!1);this.quoteDebounceTimer=window.setTimeout(()=>{this.startQuoteApiCall(),this.quoteDebounceTimer=null},1e3)},this.handleUnitSelect=e=>{const t=!this.selectedUnit;if(this.selectedUnit=e,t)return this.quoteDebounceTimer&&(clearTimeout(this.quoteDebounceTimer),this.quoteDebounceTimer=null),this.isCalculatingQuote=!0,void this.startQuoteApiCall();this.requestQuoteCalculation()},this.handleMoveInDateChange=async e=>{this.moveInDateString=e,this.clearQuote(),await this.fetchUnits(),this.selectedUnit&&this.requestQuoteCalculation()},this.handleLeaseTermChange=async e=>{this.leaseTerm=e,this.clearQuote(),await this.fetchUnits(),this.selectedUnit&&this.requestQuoteCalculation()},this.handleChargeInputsChange=e=>{this.chargeInputs={...this.chargeInputs,...e},this.requestQuoteCalculation()},this.handleRentableItemAdd=e=>{this.desiredRentableItems.some(t=>t.id===e.id)||this.desiredRentableItems.push(e),this.requestQuoteCalculation()},this.handleRentableItemRemove=e=>{this.desiredRentableItems=this.desiredRentableItems.filter(t=>t.id!==e.id),this.requestQuoteCalculation()},this.groupFees=e=>e.reduce((e,t)=>{const n=t.frequency||Wd.ONE_TIME;return e[n]=[...e[n]||[],t],e},{}),this.handleClickEmailOption=e=>{this.handleClose(),this.onClickEmailOption&&this.onClickEmailOption(e)},this.handleClickPhoneOption=e=>{this.handleClose(),this.onClickPhoneOption&&this.onClickPhoneOption(e)},this.handleClickSSTOption=e=>{this.handleClose(),this.onClickSSTOption&&this.onClickSSTOption(e)},this.handleClickTextUsOption=e=>{this.handleClose(),this.onClickTextUsOption&&this.onClickTextUsOption(e)},this.handleClose=()=>{var e;null===(e=this.onCloseClicked)||void 0===e||e.call(this)},this.handleSelectLayout=async e=>{this.selectedLayoutIds=e,await this.fetchUnits()},this.handleShare=async()=>{var e,t;this.selectedUnit&&this.moveInDateString&&this.pdfUrl&&(_o("feeCalculatorPdfDownloaded",{buildingSlug:this.buildingSlug,quoteId:null!==(t=null===(e=this.quote)||void 0===e?void 0:e.id)&&void 0!==t?t:null}),window.open(this.pdfUrl,"_blank"))},this.fetchUnits=async()=>{let e;this.isLoadingUnits=!0,this.selectedLayoutIds.includes(ec)||(e=this.selectedLayoutIds.map(e=>Ld(e)));try{if(this.units=await ac({buildingSlug:this.buildingSlug,moveInDateString:this.moveInDateString,...e?{numBedrooms:e}:{},leaseTerm:this.leaseTerm}),this.selectedUnit){this.units.some(e=>{var t;return e.id===(null===(t=this.selectedUnit)||void 0===t?void 0:t.id)})||(this.selectedUnit=null,this.clearQuote())}}finally{this.isLoadingUnits=!1}}}clearQuote(){this.quote=null,this.pdfUrl=null,this.quoteError=null}async performQuoteCalculation(e){var t;if(!this.selectedUnit||!this.moveInDateString)return this.clearQuote(),void(this.isCalculatingQuote=!1);const n=this.moveInDateString,i=this.selectedUnit.id,r=this.leaseTerm;try{const o=await nc({buildingSlug:this.buildingSlug,unitId:i,chargeInputs:this.chargeInputs,rentableItems:this.desiredRentableItems,leaseTerm:r,moveInDate:n},e);if(e.aborted)return;this.quote=o.quote,this.pdfUrl=o.pdfUrl||null,this.quoteError=null!==(t=o.error)&&void 0!==t?t:null,this.quote&&_o("feeCalculatorQuoteGenerated",{buildingSlug:this.buildingSlug,unitId:i,leaseTerm:r})}catch(e){"AbortError"!==(null==e?void 0:e.name)&&(this.quote=null,this.pdfUrl=null,this.quoteError={type:"unknown"},this.isCalculatingQuote=!1,ra({logType:ia.error,buildingSlug:this.buildingSlug,logTitle:"[ERROR_CALCULATING_QUOTE]",logData:{error:e},error:e}))}finally{e.aborted||(this.isCalculatingQuote=!1)}}get layouts(){var e,t;return null!==(t=null===(e=this.buildingWebchatView)||void 0===e?void 0:e.layoutOptions)&&void 0!==t?t:[]}updated(e){(e.has("primaryColor")||e.has("backgroundColor"))&&(this.style.setProperty("--primary-color",this.primaryColor),this.style.setProperty("--background-color",this.backgroundColor))}disconnectedCallback(){var e;super.disconnectedCallback(),this.quoteDebounceTimer&&(clearTimeout(this.quoteDebounceTimer),this.quoteDebounceTimer=null),null===(e=this.quoteAbortController)||void 0===e||e.abort(),this.quoteAbortController=null}render(){var e,t;const n=this.isExporting||this.isCalculatingQuote||!this.selectedUnit||!this.moveInDateString||!this.pdfUrl;return H`
8121
+ `:H``}};eh.styles=Zc,Jc([pe({type:Object})],eh.prototype,"incentive",void 0),eh=Jc([ce("incentive-banner")],eh);var th=function(e,t,n,i){var r,o=arguments.length,a=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)a=Reflect.decorate(e,t,n,i);else for(var s=e.length-1;s>=0;s--)(r=e[s])&&(a=(o<3?r(a):o>3?r(t,n,a):r(t,n))||a);return o>3&&a&&Object.defineProperty(t,n,a),a};let nh=class extends ue{constructor(){super(...arguments),this.buildingSlug="",this.orgSlug="",this.primaryColor=Zn,this.backgroundColor=Jn,this.onCloseClicked=null,this.onClickEmailOption=null,this.onClickPhoneOption=null,this.onClickSSTOption=null,this.onClickTextUsOption=null,this.isCalculatingQuote=!1,this.isLoadingLayouts=!0,this.isExporting=!1,this.selectedLayoutIds=[Zd],this.selectedUnit=null,this.chargeInputs={base_rent:0,num_pets:0,num_vehicles:0,num_applicants:1,num_cats:0,num_dogs:0,num_other_pets:0},this.desiredRentableItems=[],this.moveInDateString=nc(),this.leaseTerm=12,this.buildingWebchatView=null,this.incentives=[],this.quote=null,this.pdfUrl=null,this.quoteError=null,this.groupedFees={[Gd.ONE_TIME]:[],[Gd.MONTHLY]:[],[Gd.WEEKLY]:[],[Gd.BI_WEEKLY]:[],[Gd.ANNUALLY]:[],[Gd.DAILY]:[],[Gd.AS_NEEDED]:[],[Gd.NEVER]:[]},this.rentableItems=[],this.maxPets=null,this.units=[],this.isLoadingUnits=!0,this.quoteAbortController=null,this.quoteDebounceTimer=null,this.startQuoteApiCall=async()=>{var e;null===(e=this.quoteAbortController)||void 0===e||e.abort(),this.quoteAbortController=new AbortController,this.isCalculatingQuote=!0,await this.performQuoteCalculation(this.quoteAbortController.signal)},this.firstUpdated=async()=>{this.style.setProperty("--primary-color",this.primaryColor),this.style.setProperty("--background-color",this.backgroundColor),await Promise.allSettled([this.setupCalculator(),this.fetchUnits()])},this.setupCalculator=async()=>{if(!this.buildingSlug||!this.orgSlug)return void(this.isLoadingLayouts=!1);const e=ya(this.orgSlug,this.buildingSlug).then(e=>{e&&(this.buildingWebchatView=e)}).finally(()=>{this.isLoadingLayouts=!1}),t=Xd(this.buildingSlug).then(e=>{e&&(this.groupedFees=this.groupFees(e.fees),this.maxPets=function(e){const t=e.filter(e=>oc.includes(e.category)).map(e=>e.limit).filter(e=>"number"==typeof e);return t.length?Math.min(...t):null}(e.fees),this.rentableItems=e.rentableItems)});await Promise.allSettled([e,t])},this.requestQuoteCalculation=()=>{if(this.quoteDebounceTimer&&(clearTimeout(this.quoteDebounceTimer),this.quoteDebounceTimer=null),!this.selectedUnit||!this.moveInDateString)return this.clearQuote(),void(this.isCalculatingQuote=!1);this.quoteDebounceTimer=window.setTimeout(()=>{this.startQuoteApiCall(),this.quoteDebounceTimer=null},1e3)},this.handleUnitSelect=e=>{const t=!this.selectedUnit;if(this.selectedUnit=e,t)return this.quoteDebounceTimer&&(clearTimeout(this.quoteDebounceTimer),this.quoteDebounceTimer=null),this.isCalculatingQuote=!0,void this.startQuoteApiCall();this.requestQuoteCalculation()},this.handleMoveInDateChange=async e=>{this.moveInDateString=e,this.clearQuote(),await this.fetchUnits(),this.selectedUnit&&this.requestQuoteCalculation()},this.handleLeaseTermChange=async e=>{this.leaseTerm=e,this.clearQuote(),await this.fetchUnits(),this.selectedUnit&&this.requestQuoteCalculation()},this.handleChargeInputsChange=e=>{this.chargeInputs={...this.chargeInputs,...e},this.requestQuoteCalculation()},this.handleRentableItemAdd=e=>{this.desiredRentableItems.some(t=>t.id===e.id)||this.desiredRentableItems.push(e),this.requestQuoteCalculation()},this.handleRentableItemRemove=e=>{this.desiredRentableItems=this.desiredRentableItems.filter(t=>t.id!==e.id),this.requestQuoteCalculation()},this.groupFees=e=>e.reduce((e,t)=>{const n=t.frequency||Gd.ONE_TIME;return e[n]=[...e[n]||[],t],e},{}),this.handleClickEmailOption=e=>{this.handleClose(),this.onClickEmailOption&&this.onClickEmailOption(e)},this.handleClickPhoneOption=e=>{this.handleClose(),this.onClickPhoneOption&&this.onClickPhoneOption(e)},this.handleClickSSTOption=e=>{this.handleClose(),this.onClickSSTOption&&this.onClickSSTOption(e)},this.handleClickTextUsOption=e=>{this.handleClose(),this.onClickTextUsOption&&this.onClickTextUsOption(e)},this.handleClose=()=>{var e;null===(e=this.onCloseClicked)||void 0===e||e.call(this)},this.handleSelectLayout=async e=>{this.selectedLayoutIds=e,await this.fetchUnits()},this.handleShare=async()=>{var e,t;this.selectedUnit&&this.moveInDateString&&this.pdfUrl&&(_o("feeCalculatorPdfDownloaded",{buildingSlug:this.buildingSlug,quoteId:null!==(t=null===(e=this.quote)||void 0===e?void 0:e.id)&&void 0!==t?t:null}),window.open(this.pdfUrl,"_blank"))},this.fetchUnits=async()=>{let e;this.isLoadingUnits=!0,this.selectedLayoutIds.includes(Zd)||(e=this.selectedLayoutIds.map(e=>Md(e)));try{if(this.units=await rc({buildingSlug:this.buildingSlug,moveInDateString:this.moveInDateString,...e?{numBedrooms:e}:{},leaseTerm:this.leaseTerm}),this.selectedUnit){this.units.some(e=>{var t;return e.id===(null===(t=this.selectedUnit)||void 0===t?void 0:t.id)})||(this.selectedUnit=null,this.clearQuote())}}finally{this.isLoadingUnits=!1}}}clearQuote(){this.quote=null,this.pdfUrl=null,this.quoteError=null}async performQuoteCalculation(e){var t;if(!this.selectedUnit||!this.moveInDateString)return this.clearQuote(),void(this.isCalculatingQuote=!1);const n=this.moveInDateString,i=this.selectedUnit.id,r=this.leaseTerm;try{const o=await ec({buildingSlug:this.buildingSlug,unitId:i,chargeInputs:this.chargeInputs,rentableItems:this.desiredRentableItems,leaseTerm:r,moveInDate:n},e);if(e.aborted)return;this.quote=o.quote,this.pdfUrl=o.pdfUrl||null,this.quoteError=null!==(t=o.error)&&void 0!==t?t:null,this.quote&&_o("feeCalculatorQuoteGenerated",{buildingSlug:this.buildingSlug,unitId:i,leaseTerm:r})}catch(e){"AbortError"!==(null==e?void 0:e.name)&&(this.quote=null,this.pdfUrl=null,this.quoteError={type:"unknown"},this.isCalculatingQuote=!1,ra({logType:ia.error,buildingSlug:this.buildingSlug,logTitle:"[ERROR_CALCULATING_QUOTE]",logData:{error:e},error:e}))}finally{e.aborted||(this.isCalculatingQuote=!1)}}get layouts(){var e,t;return null!==(t=null===(e=this.buildingWebchatView)||void 0===e?void 0:e.layoutOptions)&&void 0!==t?t:[]}updated(e){(e.has("primaryColor")||e.has("backgroundColor"))&&(this.style.setProperty("--primary-color",this.primaryColor),this.style.setProperty("--background-color",this.backgroundColor))}disconnectedCallback(){var e;super.disconnectedCallback(),this.quoteDebounceTimer&&(clearTimeout(this.quoteDebounceTimer),this.quoteDebounceTimer=null),null===(e=this.quoteAbortController)||void 0===e||e.abort(),this.quoteAbortController=null}render(){var e,t;const n=this.isExporting||this.isCalculatingQuote||!this.selectedUnit||!this.moveInDateString||!this.pdfUrl;return H`
8109
8122
  <div
8110
8123
  class="fee-calculator-container"
8111
8124
  @keydown=${e=>e.stopPropagation()}
@@ -8187,7 +8200,7 @@ xmlns="http://www.w3.org/2000/svg"
8187
8200
  </div>
8188
8201
  `:""}
8189
8202
  </div>
8190
- `}};nh.styles=zd,th([pe({attribute:!0})],nh.prototype,"buildingSlug",void 0),th([pe({attribute:!0})],nh.prototype,"orgSlug",void 0),th([pe({type:String})],nh.prototype,"primaryColor",void 0),th([pe({type:String})],nh.prototype,"backgroundColor",void 0),th([pe()],nh.prototype,"onCloseClicked",void 0),th([pe()],nh.prototype,"onClickEmailOption",void 0),th([pe()],nh.prototype,"onClickPhoneOption",void 0),th([pe()],nh.prototype,"onClickSSTOption",void 0),th([pe()],nh.prototype,"onClickTextUsOption",void 0),th([fe()],nh.prototype,"isCalculatingQuote",void 0),th([fe()],nh.prototype,"isLoadingLayouts",void 0),th([fe()],nh.prototype,"isExporting",void 0),th([fe()],nh.prototype,"selectedLayoutIds",void 0),th([fe()],nh.prototype,"selectedUnit",void 0),th([fe()],nh.prototype,"chargeInputs",void 0),th([fe()],nh.prototype,"desiredRentableItems",void 0),th([fe()],nh.prototype,"moveInDateString",void 0),th([fe()],nh.prototype,"leaseTerm",void 0),th([fe()],nh.prototype,"buildingWebchatView",void 0),th([fe()],nh.prototype,"incentives",void 0),th([fe()],nh.prototype,"quote",void 0),th([fe()],nh.prototype,"pdfUrl",void 0),th([fe()],nh.prototype,"quoteError",void 0),th([fe()],nh.prototype,"groupedFees",void 0),th([fe()],nh.prototype,"rentableItems",void 0),th([fe()],nh.prototype,"maxPets",void 0),th([fe()],nh.prototype,"units",void 0),th([fe()],nh.prototype,"isLoadingUnits",void 0),nh=th([ce("fee-calculator")],nh);const ih=p`
8203
+ `}};nh.styles=Fd,th([pe({attribute:!0})],nh.prototype,"buildingSlug",void 0),th([pe({attribute:!0})],nh.prototype,"orgSlug",void 0),th([pe({type:String})],nh.prototype,"primaryColor",void 0),th([pe({type:String})],nh.prototype,"backgroundColor",void 0),th([pe()],nh.prototype,"onCloseClicked",void 0),th([pe()],nh.prototype,"onClickEmailOption",void 0),th([pe()],nh.prototype,"onClickPhoneOption",void 0),th([pe()],nh.prototype,"onClickSSTOption",void 0),th([pe()],nh.prototype,"onClickTextUsOption",void 0),th([fe()],nh.prototype,"isCalculatingQuote",void 0),th([fe()],nh.prototype,"isLoadingLayouts",void 0),th([fe()],nh.prototype,"isExporting",void 0),th([fe()],nh.prototype,"selectedLayoutIds",void 0),th([fe()],nh.prototype,"selectedUnit",void 0),th([fe()],nh.prototype,"chargeInputs",void 0),th([fe()],nh.prototype,"desiredRentableItems",void 0),th([fe()],nh.prototype,"moveInDateString",void 0),th([fe()],nh.prototype,"leaseTerm",void 0),th([fe()],nh.prototype,"buildingWebchatView",void 0),th([fe()],nh.prototype,"incentives",void 0),th([fe()],nh.prototype,"quote",void 0),th([fe()],nh.prototype,"pdfUrl",void 0),th([fe()],nh.prototype,"quoteError",void 0),th([fe()],nh.prototype,"groupedFees",void 0),th([fe()],nh.prototype,"rentableItems",void 0),th([fe()],nh.prototype,"maxPets",void 0),th([fe()],nh.prototype,"units",void 0),th([fe()],nh.prototype,"isLoadingUnits",void 0),nh=th([ce("fee-calculator")],nh);const ih=p`
8191
8204
  #minimize-mobile {
8192
8205
  position: absolute;
8193
8206
  top: -12px;
@@ -8386,7 +8399,7 @@ xmlns="http://www.w3.org/2000/svg"
8386
8399
  class="inner-container"
8387
8400
  style=${Xn({background:this.primaryColor})}
8388
8401
  >
8389
- ${this.toExpand?ch("black"):Nd("black")}
8402
+ ${this.toExpand?ch("black"):Pd("black")}
8390
8403
  </div>
8391
8404
  </div>
8392
8405
  `}};ph.styles=[p`