1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[58757],{58757:function(e,l,a){"use strict";a.d(l,{i:function(){return N}});var s=a(85893),i=a(69368),o=a(50480),t=a(88078),r=a(21023),n=a(9473),d=a(61009),c=a(90159),_=a(71353),u=a(6585),p=a(84331),h=a.n(p),v=a(14924),m=a(5148),x=a(11163),S=a(36609),g=a(50594),j=a(67294),b=a(47041),w=a(14854),y=a(4422);a(12868);var f=a(7534);let N=e=>{let{setSearchTerm:l,setIsSearchOpen:a,compareDrawer:p,searchTerm:N,comparePageFlag:C,maxCompare:k=5,mobileCompareDrawer:L=!1,setStoredCompareData:Z,onCloseSearchUI:P}=e,D=(0,n.I0)();(0,x.useRouter)();let[R,M]=(0,j.useState)(!0),B=(0,n.v9)(e=>{var l,a;return(null===(l=e.propertySlice)||void 0===l?void 0:l.compareSearchData)?null===(a=e.propertySlice)||void 0===a?void 0:a.compareSearchData:[]}),I=(0,n.v9)(e=>{var l,a;return null!==(l=e.propertySlice)&&void 0!==l&&!!l.compareSearchLoader&&(null===(a=e.propertySlice)||void 0===a?void 0:a.compareSearchLoader)}),G=(0,n.v9)(e=>{var l,a;return(null===(l=e.DetailsPageSlice)||void 0===l?void 0:l.propertyDetailDataCon)?null===(a=e.DetailsPageSlice)||void 0===a?void 0:a.propertyDetailDataCon:{}}),A=(0,n.v9)(e=>{var l,a;return(null===(l=e.profilesliceData)||void 0===l?void 0:l.login_details)?null===(a=e.profilesliceData)||void 0===a?void 0:a.login_details:""}),W=(0,n.v9)(e=>{var l,a;return(null===(l=e.profilesliceData)||void 0===l?void 0:l.token)?null===(a=e.profilesliceData)||void 0===a?void 0:a.token:""}),E=(0,n.v9)(e=>e.propertySlice.comparePropertyData?e.propertySlice.comparePropertyData:{}),F=(0,j.useMemo)(()=>new Set((Array.isArray(E)?E:[]).map(e=>null==e?void 0:e.ML_Number)),[E]);(0,n.v9)(e=>!!e.propertySlice.comparePropertyData&&e.propertySlice.comparePropertyData.find(e=>(null==e?void 0:e.ML_Number)===(null==G?void 0:G.ML_Number))),(0,n.v9)(e=>{var l,a;return null!==(l=e.propertySlice)&&void 0!==l&&!!l.addCompareState&&(null===(a=e.propertySlice)||void 0===a?void 0:a.addCompareState)});let T=(0,b.hasCookie)("ip_info")?JSON.parse((0,b.getCookie)("ip_info")):null;(0,b.hasCookie)("userinfo")&&JSON.parse((0,b.getCookie)("userinfo"))._id,(0,n.v9)(e=>{var l,a,s,i;return(null===(l=e.profilesliceData)||void 0===l?void 0:null===(a=l.login_details)||void 0===a?void 0:a.ip_info)?null===(s=e.profilesliceData)||void 0===s?void 0:null===(i=s.login_details)||void 0===i?void 0:i.ip_info:null}),(0,n.v9)(e=>{var l,a;return(null===(l=e.propertySlice)||void 0===l?void 0:l.compareAllData)?null===(a=e.propertySlice)||void 0===a?void 0:a.compareAllData:{}});let z=e=>{let s=JSON.parse(localStorage.getItem("comparePropertyData"))||[],i=s.some(l=>l.ML_Number===e.ML_Number);if(i||s.length>=k)return;let o=[e,...s];localStorage.setItem("comparePropertyData",JSON.stringify(o)),Z&&Z(o);let t=o.map(e=>e.ML_Number);D((0,v.jF)({property:e,checkstate:!0}));let r=(0,w.n)(A);D((0,v.VT)({ML_Numbers:t,user_id:r,ip_info:T})),p||(D((0,v.xC)(!1)),l("")),a(p)},O=e=>{e.stopPropagation()},J=(e,l,a)=>{E.length<k&&D((0,v.jF)({property:e,checkstate:l}))};return(0,j.useEffect)(()=>{N>2&&B.length>0&&M(!0)},[B]),(0,j.useEffect)(()=>{N?M(!0):(M(!1),(0,v.Fk)([]))},[N,D]),(0,j.useEffect)(()=>()=>{D((0,v.Fk)([])),D((0,v.xC)(!1))},[D]),(0,j.useEffect)(()=>{},[B]),(0,s.jsx)(s.Fragment,{children:R&&(I||(null==B?void 0:B.length)>0)&&(0,s.jsxs)("div",{className:"compare_search_results home_compare_drawer",children:[!C&&(0,s.jsxs)("div",{className:"compareSearchCrossIcon",children:[(0,s.jsxs)("span",{children:["Searched Results (",I?(0,s.jsx)(t.Z,{variant:"text",width:20,height:25,sx:{display:"inline-block"}}):null==B?void 0:B.length,")"]}),(0,s.jsxs)("span",{children:[" ",(0,s.jsx)(g.Z,{onClick:e=>{e.preventDefault(),e.stopPropagation(),M(!1),l(""),L&&(a(!1),D((0,v.xC)(!1)),P&&P())}})," "]})]}),I?(0,s.jsx)(c.Z,{comparePageFlag:C}):B&&B.length>0&&(null==B?void 0:B.map((e,l)=>{var a,t;let n=(null==e?void 0:e.Last_Status_Show)==="Sold",c=n&&!W;if(L)return(0,s.jsx)("div",{className:"comp_card_blk_main_wrpr",children:(0,s.jsxs)("div",{className:"comp_card_blk white_bg ".concat(h().blur_container),onClick:()=>!c&&z(e),style:{cursor:c?"not-allowed":"pointer"},children:[c&&(0,s.jsx)("div",{className:h().login_overlay,children:(0,s.jsx)("span",{className:h().login_btn,onClick:e=>{e.stopPropagation(),D((0,m.om)(!0))},children:"Login To Add"})}),(0,s.jsxs)("div",{className:"comp_card_blk_img",children:[(null==e?void 0:e.Last_Status_
1Show)&&(0,s.jsx)("div",{className:"".concat(h().status_txt," status_field status_show ").concat((null==e?void 0:e.Last_Status_Show)==="For Sale"||(null==e?void 0:e.Last_Status_Show)==="For Rent"||"Extension"===e.Last_Status_Show||"New"===e.Last_Status_Show||"Price Change"===e.Last_Status_Show?"for_sale_txt":(null==e?void 0:e.Last_Status_Show)==="Leased"||(null==e?void 0:e.Last_Status_Show)==="Sold"?"Leased_txt":(null==e?void 0:e.Last_Status_Show)==="Sold Conditional"||(null==e?void 0:e.Last_Status_Show)==="Leased Conditional"||(null==e?void 0:e.Last_Status_Show)==="Leased Conditional With Escape Clause"||(null==e?void 0:e.Last_Status_Show)==="Sold Conditional With Escape Clause"?"sold_cond_txt":"terminated_text"," "),children:(0,s.jsx)(r.Z,{title:"".concat(null==e?void 0:e.Last_Status_Show," "),TransitionComponent:u.Z,followCursor:!0,children:(0,s.jsx)("h4",{className:"status_show_fontColor",children:null==e?void 0:e.Last_Status_Show})})}),(0,s.jsx)("span",{className:"defultLazyIMG ".concat(c?"blurred_image":""),children:(0,s.jsx)(_.Z,{src:(null==e?void 0:e.image)&&(null==e?void 0:e.image.length)>0?null==e?void 0:e.image:(null==e?void 0:e.images)&&(null==e?void 0:null===(t=e.images)||void 0===t?void 0:t.length)>0?null==e?void 0:e.images[0]:"",alt:"broko_img",customStyle:"compare_drwawer_comingsoon"})})]}),(0,s.jsxs)("div",{className:"comp_card_blk_text",children:[(0,s.jsxs)("div",{className:"mob_comp_price_row",children:[(0,s.jsxs)("h3",{children:[(0,s.jsx)("span",{className:(null==e?void 0:e.Sold_Price)&&(null==e?void 0:e.Sold_Price)>0||(0,y.Cr)(e)?"cross_listed_price":"",children:(0,s.jsx)(d.Z,{proData:null==e?void 0:e.List_Price})}),(null==e?void 0:e.Sold_Price)&&(null==e?void 0:e.Sold_Price)>0&&(0,s.jsx)("span",{className:"sold_prices",children:(0,s.jsx)(d.Z,{proData:null==e?void 0:e.Sold_Price})})]}),(0,s.jsxs)("div",{className:"mob_comp_icons",children:[(null==e?void 0:e.Bedrooms)!==null&&(null==e?void 0:e.Bedrooms)>0&&(0,s.jsxs)("div",{className:h().rcent_bd_bth_inner,children:[(0,s.jsx)(f.Z,{type:"bed",alt:"bedroomIcon"}),(0,s.jsxs)("span",{children:[" ",null==e?void 0:e.Bedrooms]}),(null==e?void 0:e.Bedrooms_)!==null&&(null==e?void 0:e.Bedrooms_)>0&&(0,s.jsxs)("span",{children:["+",null==e?void 0:e.Bedrooms_]})]}),(null==e?void 0:e.Washrooms)!==null&&(null==e?void 0:e.Washrooms)>0&&(0,s.jsxs)("div",{className:h().rcent_bd_bth_inner,children:[(0,s.jsx)(f.Z,{type:"bath",alt:"washroomIcon"}),(0,s.jsx)("span",{children:e.Washrooms})]}),(0,s.jsxs)("div",{className:h().rcent_bd_bth_inner,children:[(0,s.jsx)(f.Z,{type:"garage",alt:"garageIcon"}),(0,s.jsx)("span",{children:(null==e?void 0:e.Garage_Spaces)!==void 0&&(null==e?void 0:e.Garage_Spaces)!==null?e.Garage_Spaces:(null==e?void 0:e.Garage_Park_Spaces)!==void 0&&(null==e?void 0:e.Garage_Park_Spaces)!==null?e.Garage_Park_Spaces:0})]})]})]}),(0,s.jsxs)("h4",{className:"compareSearchdrawer_address mobile_compare_drawer_address",children:[(null==e?void 0:e.Apt_Unit)?"".concat(null==e?void 0:e.Apt_Unit," - "):"",(null==e?void 0:e.Address)||"",(null==e?void 0:e.Community)?", ".concat(null==e?void 0:e.Community):"",(null==e?void 0:e.Municipality)?", ".concat(null==e?void 0:e.Municipality):""]}),(0,s.jsxs)("p",{className:"comparedrawer_type",children:[(null==e?void 0:e.translated_Type)||(null==e?void 0:e.Type),(null==e?void 0:e.Style)?" ⢠".concat(null==e?void 0:e.Style):""]})]})]})},l);let v=(0,s.jsxs)("div",{className:"expand_flx_two home_autocom_img compareSearch_home_autocom_img white_bg ".concat(h().blur_container),onClick:()=>!c&&z(e),style:{cursor:c?"not-allowed":"pointer"},children:[c&&(0,s.jsx)("div",{className:h().login_overlay,children:(0,s.jsx)("span",{className:h().login_btn,onClick:e=>{e.stopPropagation(),D((0,m.om)(!0))},children:"Login To Add"})}),(0,s.jsxs)("div",{className:"expnd_sub_flx ".concat(c?h().blurred:""," "),children:[(0,s.jsxs)("div",{className:"expand_img_blk",children:[(null==e?void 0:e.Last_Status_Show)&&(0,s.jsx)("div",{className:"".concat(h().status_txt," status_field status_show ").concat((null==e?void 0:e.Last_Status_Show)==="For Sale"||(null==e?void 0:e.Last_Status_
1Show)==="For Rent"||"Extension"===e.Last_Status_Show||"New"===e.Last_Status_Show||"Price Change"===e.Last_Status_Show?"for_sale_txt":(null==e?void 0:e.Last_Status_Show)==="Leased"||(null==e?void 0:e.Last_Status_Show)==="Sold"?"Leased_txt":(null==e?void 0:e.Last_Status_Show)==="Sold Conditional"||(null==e?void 0:e.Last_Status_Show)==="Leased Conditional"||(null==e?void 0:e.Last_Status_Show)==="Leased Conditional With Escape Clause"||(null==e?void 0:e.Last_Status_Show)==="Sold Conditional With Escape Clause"?"sold_cond_txt":"terminated_text"," "),children:(0,s.jsx)(r.Z,{title:"".concat(null==e?void 0:e.Last_Status_Show," "),TransitionComponent:u.Z,followCursor:!0,children:(0,s.jsx)("h4",{className:"status_show_fontColor",children:null==e?void 0:e.Last_Status_Show})})}),(0,s.jsx)("span",{className:"defultLazyIMG",children:(0,s.jsx)(_.Z,{src:(null==e?void 0:e.image)&&(null==e?void 0:e.image.length)>0?null==e?void 0:e.image:(null==e?void 0:e.images)&&(null==e?void 0:null===(a=e.images)||void 0===a?void 0:a.length)>0?null==e?void 0:e.images[0]:"",alt:"broko_img",customStyle:"comparePage_comingsoon"})})]}),(0,s.jsxs)("div",{className:"expand_img_rt_txt",children:[(0,s.jsxs)("h3",{children:[(0,s.jsx)("span",{className:(null==e?void 0:e.Sold_Price)&&(null==e?void 0:e.Sold_Price)>0||(0,y.Cr)(e)?"cross_listed_price":"",children:(0,s.jsx)(d.Z,{proData:null==e?void 0:e.List_Price})}),(null==e?void 0:e.Sold_Price)&&(null==e?void 0:e.Sold_Price)>0&&(0,s.jsx)("span",{className:"sold_prices",children:(0,s.jsx)(d.Z,{proData:null==e?void 0:e.Sold_Price})})]}),(0,s.jsxs)("h4",{className:"compareSearchdrawer_address",children:[(null==e?void 0:e.Apt_Unit)&&(0,s.jsx)("span",{children:"".concat(null==e?void 0:e.Apt_Unit,"-")}),null==e?void 0:e.Address,", ",null==e?void 0:e.Area]}),(0,s.jsx)("h5",{className:"compareSearchdrawer_municipality",children:null==e?void 0:e.Municipality}),p&&(0,s.jsx)(s.Fragment,{children:(0,s.jsxs)("div",{className:"compareResultsBedBath",children:[(0,s.jsxs)("div",{className:h().rcent_bd_bth_flex,children:[(null==e?void 0:e.Bedrooms)!==null&&(null==e?void 0:e.Bedrooms)>0&&(0,s.jsxs)("div",{className:h().rcent_bd_bth_inner,children:[(0,s.jsx)(f.Z,{type:"bed",alt:"bedroomIcon"}),(0,s.jsxs)("span",{children:[" ",null==e?void 0:e.Bedrooms]}),(null==e?void 0:e.Bedrooms_)!==null&&(null==e?void 0:e.Bedrooms_)>0&&(0,s.jsxs)("span",{children:["+",null==e?void 0:e.Bedrooms_]})]}),(null==e?void 0:e.Washrooms)!==null&&(null==e?void 0:e.Washrooms)>0&&(0,s.jsxs)("div",{className:h().rcent_bd_bth_inner,children:[(0,s.jsx)(f.Z,{type:"bath",alt:"washroomIcon"}),(0,s.jsx)("span",{children:e.Washrooms})]}),(0,s.jsxs)("div",{className:h().rcent_bd_bth_inner,children:[(0,s.jsx)(f.Z,{type:"garage",alt:"garageIcon"}),(0,s.jsx)("span",{children:(null==e?void 0:e.Garage_Spaces)!==void 0&&(null==e?void 0:e.Garage_Spaces)!==null?e.Garage_Spaces:(null==e?void 0:e.Garage_Park_Spaces)!==void 0&&(null==e?void 0:e.Garage_Park_Spaces)!==null?e.Garage_Park_Spaces:0})]})]}),(0,s.jsx)("div",{className:"sizeOfBungalowG compare_wrpr ".concat(h().sizeOfBungalow),children:(0,s.jsx)(o.Z,{id:"".concat(null==e?void 0:e._id,"-CompareInput"),className:"compare",onClick:e=>O(e),onChange:l=>J(e,l.target.checked,"".concat(e._id,"-CompareInput")),control:(0,s.jsx)(i.Z,{checked:F.has(null==e?void 0:e.ML_Number)}),label:(0,S.t)("Compare")})})]})})]})]})]},l);return L?(0,s.jsx)("div",{className:"comp_card_blk_main_wrpr",children:v},l):v}))]})})}},90159:function(e,l,a){"use strict";var s=a(85893),i=a(88078),o=a(51233);a(67294);var t=a(72890),r=a.n(t);l.Z=e=>{let{comparePageFlag:l=!1}=e;return l?(0,s.jsx)("div",{className:r().searchedSkeletonRoot,children:(0,s.jsx)(o.Z,{spacing:1,children:[1,2,3].map((e,l)=>(0,s.jsx)("div",{className:"comp_card_blk_main_wrpr",children:(0,s.jsxs)("div",{className:"comp_card_blk white_bg",style:{display:"flex",alignItems:"center",gap:"8px",padding:"5px 6px",borderRadius:"8px",position:"relative",border:"1px solid #e5e7eb",background:"#ffffff",boxSizing:"border-box"},children:[(0,s.jsx)("div",{className:"comp_card_blk_img",style:{width:"68px",minWidth:"68px",maxWidth:"68px",height:"56px",minHeight:"56px",maxHeight:"56px",borderRadius:"6px",overflow:"hidden",flexShrink:0},children:(0,s.jsx)(i.Z,{variant:"rectangular",width:"100%",height:"100%",style:{borderRadius:"6px"}})}),(0,s.jsxs)("div",{className:"comp_card_blk_text",style:{flex:1,display:"flex",flexDirection:"column",justifyContent:"center",gap:"3px",minWidth:0,margin:0,padding:0},children:[(0,s.jsxs)("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",width:"100%"},children:[(0,s.jsx)(i.Z,{variant:"text",width:"45%",height:14}),(0,s.jsx)(i.Z,{variant:"rectangular",width:40,height:10,style:{borderRadius:"3px"}})]}),(0,s.jsx)(i.Z,{variant:"text",width:"85%",height:12}),(0,s.jsx)(i.Z,{variant:"text",width:"60%",height:10})]})]})},l))})}):(0,s.jsx)("div",{className:r().searchedSkeletonRoot,children:(0,s.jsx)(o.Z,{spacing:1.5,children:[1,2,3].map((e,l)=>(0,s.jsx)("div",{className:"comp_card_blk_main_wrpr",children:(0,s.jsxs)("div",{className:"comp_card_blk white_bg",style:{display:"flex",gap:"12px",padding:"10px",borderRadius:"12px",position:"relative"},children:[(0,s.jsx)("div",{className:"comp_card_blk_img",style:{width:"135px",height:"95px",borderRadius:"10px",overflow:"hidden",flexShrink:0},children:(0,s.jsx)(i.Z,{variant:"rectangular",width:"100%",height:"100%",style:{borderRadius:"10px"}})}),(0,s.jsxs)("div",{className:"comp_card_blk_text",style:{flex:1,display:"flex",flexDirection:"column",justifyContent:"space-between",minWidth:0},children:[(0,s.jsxs)("div",{style:{width:"100%"},children:[(0,s.jsx)(i.Z,{variant:"text",width:"60%",height:22}),(0,s.jsx)(i.Z,{variant:"text",width:"35%",height:14,style:{marginTop:"2px"}}),(0,s.jsx)(i.Z,{variant:"text",width:"85%",height:16,style:{marginTop:"4px"}})]}),(0,s.jsxs)("div",{style:{display:"flex",justifyContent:"space-between",alignItems:"center",marginTop:"6px",width:"100%"},children:[(0,s.jsx)(i.Z,{variant:"rectangular",width:80,height:16,style:{borderRadius:"4px"}}),(0,s.jsx)(i.Z,{variant:"rectangular",width:75,height:24,style:{borderRadius:"6px"}})]})]})]})},l))})})}},84331:function(e){e.exports={sizeOfBungalow:"CompareMoreSearchResults_sizeOfBungalow__ir7K7",rcent_bd_bth_flex:"CompareMoreSearchResults_rcent_bd_bth_flex__7RenR",rcent_bd_bth_inner:"CompareMoreSearchResults_rcent_bd_bth_inner__8oJYK",status_txt:"CompareMoreSearchResults_status_txt__7fEiU",blur_container:"CompareMoreSearchResults_blur_container__cABZR",blurred:"CompareMoreSearchResults_blurred__GUpKt",login_overlay:"CompareMoreSearchResults_login_overlay__bJ_Ym",login_btn:"CompareMoreSearchResults_login_btn__rLxcz"}},72890:function(e){e.exports={searchedSkeletonRoot:"SearchedSkeleton_searchedSkeletonRoot__k18gw"}}}]);
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.