1"use strict";(self.webpackChunkbarratt_rebuild=self.webpackChunkbarratt_rebuild||[]).push([[551],{23150(t,e,s){s.d(e,{A:()=>i});var o=s(57756),a=s(62223),r=s(48768);const i={name:"PlotSummary",filters:{toSentenceCase:t=>(0,r.A)(t)},props:{title:{type:String,default:"Build Complete"},subTitle:{type:String,default:"Your new home is ready and waiting!"},description:{type:String,default:""}},data:()=>({instanceKey:0,plot:{},isLoading:!0}),computed:{address(){return(0,a.A)(this.plot)},isComplete(){return this.plot.buildStage&&4===this.plot.buildStage},plotTitle(){return this.isComplete?this.title:`Plot ${this.plot.plotNumber}`}},created(){this.setPlotData(),window.addEventListener("storage",()=>{this.setPlotData(),this.instanceKey=this.instanceKey++})},methods:{setPlotData(){const t=(0,o.NF)();t&&(this.plot=t,this.isLoading=!1)}}}},5448(t,e,s){s.d(e,{X:()=>o,Y:()=>a});var o=function(){var t=this,e=t._self._c;return t.isLoading?t._e():e("div",{key:t.instanceKey,staticClass:"plot-summary"},[e("div",{staticClass:"plot-summary__container"},[e("div",{staticClass:"plot-summary__thumbnail"},[e("div",{staticClass:"plot-summary__image-container image"},[t.isComplete?e("div",{staticClass:"plot-summary__image-disclaimer"},[t._v("\n For illustration purposes only\n ")]):t._e(),t._v(" "),e("img",{staticClass:"plot-summary__image image__lazy loaded",attrs:{draggable:"false",src:t.plot.thumbnailImageSrc,alt:t.plot.plotNumber}}),t._v(" "),t.plot.imageLabel?e("div",{staticClass:"plot-summary__image-label"},[t._v("\n "+t._s(t.plot.imageLabel)+"\n ")]):t._e()])]),t._v(" "),e("div",{staticClass:"plot-summary__content"},[e("h4",{staticClass:"plot-summary__sub-title",class:{"plot-summary__sub-title--upper":t.isComplete}},[t._v("\n "+t._s(t.plotTitle)+"\n ")]),t._v(" "),t.address&&!t.isComplete?e("h3",{staticClass:"plot-summary__title"},[t._v("\n "+t._s(t.address)+"\n ")]):t._e(),t._v(" "),t.subTitle&&t.isComplete?e("h3",{staticClass:"plot-summary__title"},[t._v("\n "+t._s(t.subTitle)+"\n ")]):t._e(),t._v(" "),t.plot.numbeOfBedrooms&&!t.isComplete?e("div",{staticClass:"plot-summary__detail"},[t._v("\n "+t._s(t.plot.numbeOfBedrooms)+" bedroom"+t._s(t.plot.numbeOfBedrooms>1?"s":"")+"\n "),t.plot.plotConfiguration?e("span",[e("span",{attrs:{"aria-hidden":"true"}},[t._v(" ⢠")]),t._v(t._s(t._f("toSentenceCase")(t.plot.plotConfiguration))+" ")]):t._e()]):t._e(),t._v(" "),t.isComplete&&t.description?e("div",{staticClass:"plot-summary__detail"},[t._v("\n "+t._s(t.description)+"\n ")]):t._e()])])])},a=[];o._withStripped=!0},98571(t,e,s){s.d(e,{default:()=>l});var o=s(30201),a=s(64467),r=s(62893),i=s(11110);const l=class{constructor(t){(0,a.A)(this,"initVueInstance",()=>{const t=this._context.dataset.model,e=JSON.parse(t);new this.AppRoot({el:this._context,propsData:(0,o.A)({},e)})}),this._context=t,this.AppRoot=r.default.extend(i.A),this.initVueInstance()}};(Object.getOwnPropertyDescriptor(l,"name")||{}).writable||Object.defineProperty(l,"name",{value:"default",configurable:!0})},62223(t,e,s){s.d(e,{A:()=>a});var o=s(4345);function a(t){try{const e=t.addressLine1?(0,o.A)(t.addressLine1):null,s=t.city?(0,o.A)(t.city):null,a=t.postCode?t.postCode.trim().toUpperCase():null;if(!e||!a)throw new Error("Missing required address fields");const r=[e];return s&&r.push(s),a&&r.push(a),r.join(", ")}catch(e){return console.error("Error formatting plot address:",e),(0,o.A)(t.addressLine1)||(0,o.A)(t.city)||t.postCode?.trim().toUpperCase()||"Address not available"}}},57756(t,e,s){s.d(e,{Gu:()=>p,N3:()=>r,NF:()=>a,au:()=>i,cn:()=>d,f3:()=>u,mZ:()=>m,oq:()=>l});var o=s(30201);const a=()=>{const t=localStorage.getItem("plots"),e=localStorage.getItem("selectedPlotIndex");return t&&e||n(),JSON.parse(t)[e]},r=()=>{const t=a();if(t)return t.buildStage},i=()=>{const t=a();if(t)return t.plotId},l=()=>{const t=localStorage.getItem("plots");return JSON.parse(t)},n=()=>{console.error("Failed to retrieve valid plot data"),window.location="/"},p=t=>{t&&localStorage.setItem("plots",JSON.stringify(t))},c=(t,e)=>{const s=l(),a=(0,o.A)({},s[t],e);s[t]=a,localStorage.setItem("plots",JSON.stringify(s))},d=async(t,e)=>{localStorage.setItem("selectedPlotIndex",t),c(t,e);const s=m();s&&(document.cookie=`brand=${s};path=/`)},u=()=>Number(localStorage.getItem("selectedPlotIndex")),m=()=>{const t=a();if(t)return t.brand}},4345(t,e,s){s.d(e,{A:()=>
1o});const o=t=>{let e=t.trim();const s=[];if(e&&"string"!=typeof e)return;return e.split(" ").forEach(t=>{(t=t.toLowerCase().split(""))[0]=t[0].toUpperCase(),s.push(t.join(""))}),s.join(" ")};(Object.getOwnPropertyDescriptor(o,"name")||{}).writable||Object.defineProperty(o,"name",{value:"default",configurable:!0})},11110(t,e,s){s.d(e,{A:()=>r});var o=s(10327),a=s(43747);const r=(0,s(14486).A)(a.A,o.X,o.Y,!1,null,null,null).exports},43747(t,e,s){s.d(e,{A:()=>o});const o=s(23150).A},10327(t,e,s){s.d(e,{X:()=>o.X,Y:()=>o.Y});var o=s(5448)},30201(t,e,s){s.d(e,{A:()=>a});var o=s(64467);function a(t){for(var e=1;e<arguments.length;e++){var s=null!=arguments[e]?Object(arguments[e]):{},a=Object.keys(s);"function"==typeof Object.getOwnPropertySymbols&&a.push.apply(a,Object.getOwnPropertySymbols(s).filter(function(t){return Object.getOwnPropertyDescriptor(s,t).enumerable})),a.forEach(function(e){(0,o.A)(t,e,s[e])})}return t}}}]);
Line numbers count LF bytes from the start of the resource, as the search results do. Vendor segments are library code the classifier recognised; they are stored but not indexed. Bytes are shown as Latin1 characters, one per byte.