1(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[58151],{753817:function(e,t,l){"use strict";l.r(t);var r=l(785893),a=l(386010),i=l(98066),o=l.n(i),n=l(667294),c=l(901552),s=l.n(c),d=l(996104),m=l(579184),u=l(85944),x=l(174315),p=l(873292),h=l(905918),v=l(365820),b=l(440176),f=l(194829);let g={visible:{opacity:1},hidden:{opacity:0}};t.default=e=>{var t;let{wrapperClassName:l,placeholder:i="Type here",dataField:c,queryArr:y,inputState:w=!0,inputToggler:k,queryArrSetter:P,isColorTheme:T}=e,j=(0,n.useRef)(null),_=(0,n.useRef)(null),N=(0,f.Z)("screen and (min-width: 1024px)",!0),[C,E]=(0,n.useState)(!1),[D,Z]=(0,n.useState)(""),I=c.filter(e=>{var t;let l=e.text.toLowerCase();if(l.includes(null!==(t=null==D?void 0:D.toLowerCase())&&void 0!==t?t:""))return!0}),S=(0,h.O3)(e=>{var t,l,r,a;(null==e?void 0:null===(r=e.parentElement)||void 0===r?void 0:null===(l=r.parentElement)||void 0===l?void 0:null===(t=l.children)||void 0===t?void 0:t[0].id)==="input-container"||(null===(a=document.activeElement)||void 0===a?void 0:a.classList.contains(s()["chip--delete"]))||k(!1)}),scrollWithButton=e=>{let t=document.getElementById("input-container");t&&("up"===e?t.scrollTop-=24:t.scrollTop+=24)};return(0,n.useEffect)(()=>{let e;let t=j.current;if(null!==t)return!1==w&&(t.value=""),0===y.length?t.placeholder=i:w||0===y.length||(e=setTimeout(()=>{1==y.length&&(t.placeholder=y[0].text),2==y.length&&(t.placeholder=y[0].text+" & "+y[1].text),y.length>2&&(t.placeholder=y[0].text+", "+y[1].text+", & "+(y.length-2).toString()+" more")},100)),()=>{clearTimeout(e)}},[w,y]),(0,n.useEffect)(()=>{var e;let handleScrollChange=()=>{let e=_.current;e&&E(e.scrollHeight>e.clientHeight)};return null===(e=_.current)||void 0===e||e.addEventListener("scroll",handleScrollChange),window.addEventListener("resize",handleScrollChange),()=>{var e;null===(e=_.current)||void 0===e||e.removeEventListener("scroll",handleScrollChange),window.removeEventListener("resize",handleScrollChange)}},[_]),(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("p",{className:(0,a.Z)("mb-[0.125rem] font-primary text-[0.625rem] text-white transition-opacity duration-150 sm:text-[0.75rem] sm:leading-[0.875rem] md:mb-1 md:leading-5",{"!text-transparent":!w&&0===y.length}),children:"Cities"}),(0,r.jsxs)("div",{className:"relative flex",children:[(0,r.jsxs)("div",{tabIndex:0,role:"tab",className:(0,a.Z)(" w-full"),children:[(0,r.jsxs)("div",{ref:_,id:"input-container",className:(0,a.Z)(s()["input-wrapper"],l),onClick:e=>{Z(""),e.currentTarget.getElementsByTagName("input")[0].click(),e.currentTarget.getElementsByTagName("input")[0].focus()},children:[0!==y.length&&w&&y.map(e=>(0,r.jsx)(v.M,{children:(0,r.jsx)(b.E.div,{initial:"hidden",animate:"visible",exit:"hidden",variants:g,className:(0,a.Z)(s().chip,{"!bg-colorPalette-color5":!T("default-real"),"!bg-colorPalette-color6":T("real")}),children:(0,r.jsxs)("div",{className:(0,a.Z)("mt-[-0.0625rem] flex items-center justify-center font-primary text-etherealTemplate-primaryBlack",{"!text-colorPalette-textTitleDark":!T("default")}),children:[(0,r.jsx)("span",{className:(0,a.Z)("pt-[0.125rem] text-xxs leading-[0.5rem]",{"!text-colorPalette-textTitleDark":!T("default")}),children:e.text})," ",(0,r.jsx)("button",{className:(0,a.Z)(s()["chip--delete"],{[s().themed]:!T("default")}),"aria-label":"Remove ".concat(e.text," from filter"),onClick:t=>{var l,r,a;null===(a=t.currentTarget.parentElement)||void 0===a||null===(r=a.parentElement)||void 0===r||null===(l=r.parentElement)||void 0===l||l.getElementsByTagName("input")[0].click(),P(y.filter(t=>t!==e))},children:(0,r.jsx)(u.Z,{"aria-hidden":!0,role:"img"})})]})})})),(0,r.jsx)("label",{htmlFor:"search-city-input",className:"sr-only",children:"Find a city"}),(0,r.jsx)("input",{ref:j,"aria-label":(null===(t=j.current)||void 0===t?void 0:t.placeholder)?void 0:"Find a city",id:"search-city-input",autoComplete:"off",className:(0,a.Z)(s()["input-field"],"!py-0",{"!w-full":!w||w&&0===y.length,[s()["input-field--inactive"]]:!w&&0!==y.length,[s()["input-field--with-value"]]:w&&0!==y.length}),type:"text",onChange:e=>{if(Z(e.currentTarget.value),0===e.currentTarget.value.length){e.currentTarget.size=10;return}e.currentTarget.size=e.currentTarget.value.length+2},onKeyDown:()=>{k(!0)},onClick:e=>{k(e=>!e);let t=e.target;t.addEventListener("focusout",e=>{var t;let l=null===(t=e.currentTarget.parentElement)||void 0===t?void 0:t.parentElement;o()(()=>{var e,t,r;l.contains(document.activeElement)||(null===(e=document.activeElement)||void 0===e?void 0:e.id)==="btn-arrow--down"||(null===(t=document.activeElement)||void 0===t?void 0:t.id)==="scroll-up"||(null===(r=document.activeElement)||void 0===r?void 0:r.id)==="scroll-down"||k(!1)},50)})},onFocus:e=>{e.currentTarget.size=2;let t=e.target;t.addEventListener("focusout",e=>{var t;let l=null===(t=e.currentTarget.parentElement)||void 0===t?void 0:t.parentElement;o()(()=>{var e,t,r;l.contains(document.activeElement)||(null===(e=document.activeElement)||void 0===e?void 0:e.id)==="btn-arrow--down"||(null===(t=document.activeElement)||void 0===t?void 0:t.id)==="scroll-up"||(null===(r=document.activeElement)||void 0===r?void 0:r.id)==="scroll-down"||k(!1)},50)})}})]}),(0,r.jsxs)("div",{tabIndex:0,role:"button",className:(0,a.Z)("absolute z-30 mt-1 flex max-h-[17rem] w-full flex-col overflow-y-auto bg-neutral-100 p-4 shadow-sh3",s()["data-dropdown"],{hidden:!w,"!bg-colorPalette-color5":!T("default-real"),"!bg-colorPalette-color6":T("real")}),onClick:e=>{var t;null===(t=e.currentTarget.parentElement)||void 0===t||t.getElementsByTagName("input")[0].focus()},children:[c&&0!==c.length&&I.map(e=>(0,r.jsx)("button",{className:(0,a.Z)(s()["item--data-filter"],{[s()["item--data-filter__active"]]:y.includes(e),"!text-colorPalette-textTitleDark hover:!bg-colorPalette-color1 hover:!text-colorPalette-textTitleLight":!(null==T?void 0:T("default"))&&!y.includes(e),"!bg-colorPalette-color5":!T("default-real")&&!y.includes(e),"!bg-colorPalette-color6":T("real")&&!y.includes(e),"!bg-colorPalette-color1 !text-colorPalette-textTitleLight":!(null==T?void 0:T("default"))&&y.includes(e)}),onClick:t=>{var l,r,a,i;y.includes(e)?P(y.filter(t=>t!==e)):(P([...y,e]),Z(""),j.current&&(j.current.value=""));let o=null===(r=t.currentTarget)||void 0===r?void 0:null===(l=r.parentElement)||void 0===l?void 0:l.parentElement;if(o){o.getElementsByTagName("input")[0].focus();let e=null!==(i=null===(a=o.getElementsByTagName("input")[0].parentElement)||void 0===a?void 0:a.scrollHeight)&&void 0!==i?i:24;setTimeout(()=>
1{let t=o.getElementsByTagName("input")[0].parentElement;null!==t&&(t.scrollTop=e)},100)}},children:e.text})),0===I.length&&(0,r.jsx)("div",{className:(0,a.Z)("px-8 py-[0.8125rem] font-primary text-[0.875rem]",{"text-etherealTemplate-primaryBlack":T("default"),"text-colorPalette-textTitleDark":!T("default")}),children:"No Result"})]})]}),(0,r.jsxs)("div",{className:"flex h-6 items-center border-b-[0.0625rem] border-white",children:[0!==y.length&&(0,r.jsxs)("div",{className:"flex items-center",children:[w&&C&&N&&(0,r.jsxs)("div",{ref:S,className:s()["scroll-buttons"],children:[(0,r.jsx)("button",{id:"scroll-up",className:"h-full w-full","aria-label":"scroll up",onClick:()=>scrollWithButton("up"),children:(0,r.jsx)(p.Z,{"aria-hidden":!0,role:"img"})}),(0,r.jsx)("button",{id:"scroll-down",className:"h-full w-full","aria-label":"scroll down",onClick:()=>scrollWithButton("down"),children:(0,r.jsx)(x.Z,{"aria-hidden":!0,role:"img"})})]}),(0,r.jsx)(m.Z,{role:"button",alt:"cross icon","aria-label":"reset input field",className:"ml-1 w-[0.575rem] fill-white",onClick:()=>{P([]);let e=j.current;if(null===e)return}})]}),(0,r.jsx)(d.Z,{role:"button",alt:"triangle icon","aria-label":"interact with input field",tabIndex:0,id:"btn-arrow--down",className:(0,a.Z)(s()["btn-arrow"],"transition",{"rotate-180":w}),onClick:()=>{var e;null===(e=document.getElementById("input-container"))||void 0===e||e.click()}})]})]})]})}},260256:function(e,t,l){"use strict";l.r(t);var r=l(785893),a=l(667294),i=l(386010),o=l(98066),n=l.n(o),c=l(753817),s=l(996104),d=l(466545),m=l(538054),u=l(621133),x=l(484577),p=l.n(x),h=l(194829),v=l(905918),b=l(120749);let formatPrice=e=>e.toLocaleString("en-US",{style:"currency",currency:"USD",maximumFractionDigits:0}),f=[{remarks:"City",text:"House",value:"SFR",type:"string"},{remarks:"City",text:"Condo",value:"CND",type:"string"},{remarks:"City",text:"Lots/Land",value:"LL",type:"string"},{remarks:"City",text:"Multi-Unit Residential",value:"RI",type:"string"},{remarks:"City",text:"Mobile Home",value:"MH",type:"string"},{remarks:"City",text:"Rental",value:"RNT",type:"string"},{remarks:"City",text:"Commercial",value:"COM",type:"string"}],g=[{remarks:"City",value:"47",text:"Auburn",type:"cityId[]"},{remarks:"City",value:"119",text:"Cameron Park",type:"cityId[]"},{remarks:"City",value:"155",text:"Citrus Heights",type:"cityId[]"},{remarks:"City",value:"236",text:"Discovery Bay",type:"cityId[]"},{remarks:"City",value:"261",text:"El Dorado",type:"cityId[]"},{remarks:"City",value:"262",text:"El Dorado Hills",type:"cityId[]"},{remarks:"City",value:"271",text:"Elk Grove",type:"cityId[]"},{remarks:"City",value:"343",text:"Grass Valley",type:"cityId[]"},{remarks:"City",value:"6848",text:"Mountain House",type:"cityId[]"},{remarks:"City",value:"23351",text:"Murphys",type:"cityId[]"},{remarks:"City",value:"720",text:"Placerville",type:"cityId[]"},{remarks:"City",value:"781",text:"Rocklin",type:"cityId[]"},{remarks:"City",value:"791",text:"Roseville",type:"cityId[]"},{remarks:"City",value:"887",text:"Sonora",type:"cityId[]"},{remarks:"City",value:"954",text:"Twain Harte",type:"cityId[]"}],y=[[18e4,2e5],[3e5,4e5],[4e5,5e5],[5e5,6e5],[6e5,7e5],[7e5,8e5],[8e5,9e5],[1e6,18e5]];t.default=e=>{var t;let[l,o]=(0,a.useState)([]),{urlComponents:x,website:w,get:k,isColorTheme:P,isDefaultTheme:T}=(0,v.Q$)(e.props),[j,_]=(0,a.useState)(!1),[N,C]=(0,a.useState)(!1),[E,D]=(0,a.useState)(!1),[Z,I]=(0,a.useState)(!1),[S,B]=(0,a.useState)(!1),[L,M]=(0,a.useState)(""),[G,H]=(0,a.useState)([]),[F,R]=(0,a.useState)([]),[z,K]=(0,a.useState)(["active"]),[X,A]=(0,a.useState)({minPrice:0,maxPrice:0,bed:0,bath:0}),[Q,U]=(0,a.useState)(),q=(null==w?void 0:null===(t=w.pages.find(e=>"property-search"===e.path))||void 0===t?void 0:t.externalPath)||"property-search",W=(0,h.Z)("screen and (min-width: 1024px)",!0),renderBedsBaths=e=>{let{label:t,key:l,className:a}=e;return(0,r.jsxs)("div",{children:[(0,r.jsx)("label",{className:(0,i.Z)(!T&&"text-colorPalette-textBodyDark"),children:t}),(0,r.jsx)("div",{className:a,children:[0,1,2,3,4,5].map((e,t)=>(0,r.jsx)("button",{className:(0,i.Z)("h-8 border-[0.0625rem] border-solid border-black px-2 py-[0.375rem] text-center font-primary text-xs leading-5 text-royaleTemplate-darkGray",p()["item--data-filter"],{"!bg-royaleTemplate-darkGray !text-white":T&&X[l]===e," border-l-[0]":0!==t,"!border-colorPalette-color1 hover:!bg-colorPalette-color1 hover:!text-colorPalette-textTitleLight":!T,"!bg-colorPalette-color1 !text-colorPalette-textTitleLight":!T&&X[l]===e}),onClick:()=>{A(t=>({...t,[l]:e}))},children:0!==e?e+"+":"ANY"},e))})]})},renderStatusDropdown=()=>["Active","Pending","Sold"].map(e=>{let t=e.toLocaleLowerCase();return(0,r.jsxs)("button",{className:(0,i.Z)(p()["btn--checkbox"],p()["item--data-filter"],{[p()["item--data-filter__active"]]:z.includes(t),...radioBtnThemeClass(z.includes(t))}),"aria-label":"Toggle IDX Status Filter for ".concat(e),onClick:()=>{z.includes(t)?K(z.filter(e=>e!==t)):K([...z,t])},children:[(0,r.jsxs)("div",{className:(0,i.Z)(p()["icon-wrapper"],{[p()["icon-wrapper--active"]]:z.includes(t)}
1),children:[(0,r.jsx)(m.Z,{role:"img","aria-hidden":!0,className:"w-[0.9163rem]"}),(0,r.jsx)("span",{className:"sr-only",children:e})]}),e]},e)});(0,a.useEffect)(()=>{U(()=>{var e,t,l,r;let a=new URLSearchParams,i=G.map(e=>e.value).join(","),o=z.map(e=>e).join(","),n=F.map(e=>e.value).join(",");return[[i,"cityId"],[o,"status"],[n,"propertyType"],[null!==(e=X.maxPrice)&&void 0!==e?e:"","maxListPrice"],[null!==(t=X.minPrice)&&void 0!==t?t:"","minListPrice"],[null!==(l=X.bed)&&void 0!==l?l:"","bedrooms"],[null!==(r=X.bath)&&void 0!==r?r:"","bathCount"]].map(e=>{a.append(e[1].toString(),"number"==typeof e[0]?e[0].toString():e[0])}),a.toString().replace(/%2C/g,",")})},[G,X,F,z]),(0,a.useEffect)(()=>{_(!1)},[S,E,N]);let handleDropdown=(e,t,l)=>{t(e=>!e);let r=e.target.nextElementSibling;n()(()=>{r.focus()},50),r.addEventListener("focusout",e=>{let r=e.currentTarget.parentElement;n()(()=>{!r.contains(document.activeElement)&&(t(!1),l&&l(""))},50)})},O=(0,v.GK)(e=>e.idxClient),radioBtnThemeClass=e=>({[p()["btn--checkbox__theme"]]:!T&&!e,[p()["btn--checkbox__theme--active"]]:!T&&e,[p().real]:!T&&P("real")});return((0,a.useEffect)(()=>{if((null==O?void 0:O.activationToken.toUpperCase())!=="BC20B830-DD11-2A4A-E4AB181F1C2B1E42"){var e;(0,b.r)(null!==(e=null==O?void 0:O.clientId)&&void 0!==e?e:"").then(e=>{let t=e.map(e=>({remarks:"City",value:e.value,text:e.text,type:"cityId[]"}));o(t)})}else o(g)},[O]),O&&"false"!==k("IDXHeader"))?(0,r.jsxs)("section",{id:"idx-header",className:(0,i.Z)("relative z-[21] flex w-full flex-col items-center justify-center lg:py-2 xl:py-6",{"pointer-events-none":"builder"===e.props.mode,"bg-black":T,"bg-colorPalette-color1":!T}),children:[(0,r.jsxs)("div",{className:"w-full max-w-[82.8125rem] flex-col items-start justify-start p-4 pb-2 tablet-sm:flex tablet-sm:flex-row md:h-[4.5rem]",children:[(0,r.jsx)("div",{className:"relative w-full lg:max-w-[46.0625rem]",children:(0,r.jsx)(c.default,{placeholder:"Find a city",dataField:l,inputState:j,inputToggler:_,queryArr:G,queryArrSetter:H,isColorTheme:P})}),(0,r.jsx)("div",{className:"mx-3 hidden h-12 w-[0.0625rem] bg-neutral-100 tablet-sm:flex lg:mx-4"}),W&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsxs)("div",{className:"relative self-center",children:[(0,r.jsxs)("button",{className:(0,i.Z)(p()["main--btn-filter"],{"bg-royaleTemplate-darkGray":N,"!bg-colorPalette-color5 !text-colorPalette-textTitleDark [&>svg]:!fill-colorPalette-textTitleDark":!P("default-real")&&N,"!bg-colorPalette-color6 !text-colorPalette-textTitleDark [&>svg]:!fill-colorPalette-textTitleDark":P("real")&&N}),"aria-label":"Status Dropdown",onClick:e=>handleDropdown(e,C),children:["Status"," ",(0,r.jsx)(s.Z,{role:"img","aria-hidden":!0,className:"pointer-events-none ml-3 mr-1 w-[0.375rem] fill-white"})]}),(0,r.jsx)("div",{tabIndex:0,role:"tab",className:(0,i.Z)("absolute right-4 top-[2.8125rem] w-[12.5625rem] bg-neutral-100 p-4 shadow-sh3 lg:top-[3.4375rem]",{hidden:!1===N,"!bg-colorPalette-color5":!T&&!P("real"),"!bg-colorPalette-color6":P("real")}),children:renderStatusDropdown()})]}),(0,r.jsxs)("div",{className:"relative self-center",children:[(0,r.jsxs)("button",{className:(0,i.Z)(p()["main--btn-filter"],{"bg-royaleTemplate-darkGray":E,"!bg-colorPalette-color5 !text-colorPalette-textTitleDark [&>svg]:!fill-colorPalette-textTitleDark":!T&&!P("real")&&E,"!bg-colorPalette-color6 !text-colorPalette-textTitleDark [&>svg]:!fill-colorPalette-textTitleDark":P("real")&&E}),"aria-label":"Price Dropdown",onClick:e=>{handleDropdown(e,D,M)},children:["Price",(0,r.jsx)(s.Z,{role:"img","aria-hidden":!0,className:"pointer-events-none ml-3 mr-1 w-[0.375rem] fill-white"})]}),(0,r.jsx)("div",{tabIndex:0,role:"tab",className:(0,i.Z)("absolute right-4 top-[3.125rem] flex w-[21.4375rem] items-center justify-center bg-neutral-100 p-4 shadow-sh3 lg:top-[3.4375rem]",{hidden:!1===E,"!bg-colorPalette-color5":!T&&!P("real"),"!bg-colorPalette-color6":P("real")}),children:["Min","separator","Max"].map(e=>{let t="Max"===e?"maxPrice":"minPrice",l="".concat(e.toLowerCase(),"price-wrapper"),a=formatPrice(X[t]);return"separator"===e?(0,r.jsx)("div",{className:(0,i.Z)("mx-2 h-[0.125rem] min-w-[0.5rem] max-w-[0.5rem]",{'bg-royaleTemplate-darkGray"':T,"bg-black":!T})}):(0,r.jsxs)("div",{className:"relative w-full",children:[(0,r.jsxs)("button",{id:l,className:(0,i.Z)("flex w-full items-center justify-between border-[0.0625rem] border-solid border-black px-4 py-[0.8125rem] text-start font-primary text-[0.875rem] leading-[1.375rem] text-royaleTemplate-darkGray transition-colors duration-150",{"border-royaleTemplate-darkGray bg-royaleTemplate-darkGray !text-white":L===e&&T,"!bg-colorPalette-color1 !text-colorPalette-textTitleLight !text-white":!T&&L===e}),"aria-label":"Price ".concat(0!==X[t]?a[0]+" "+a.substring(1):e," Dropdown"),onClick:()=>{M(()=>L===e?"":e)},children:[(0,r.jsxs)("span",{children:[0!==X[t]?a[0]+" "+a.substring(1):e," "]}
1),(0,r.jsx)(s.Z,{role:"img","aria-hidden":!0,className:(0,i.Z)("mr-1 w-[0.375rem] fill-royaleTemplate-darkGray",{"!fill-white":L===e})})]}),(0,r.jsxs)("div",{className:(0,i.Z)("absolute left-0 top-[3.4375rem] hidden w-full flex-col shadow-sh3",{"!flex ":L===e}),children:[(0,r.jsx)("button",{className:(0,i.Z)("bg-white px-4 py-[0.8125rem] text-start text-[0.875rem] uppercase",p()["item--data-filter"],p()["price-filter"],{"!bg-colorPalette-color5 !text-colorPalette-textTitleDark hover:!bg-colorPalette-color1 hover:!text-colorPalette-textTitleLight":!(null==P?void 0:P("default")),"!bg-colorPalette-color6":null==P?void 0:P("real")}),onClick:()=>{var e,r;A({...X,[t]:0}),null===(e=document.getElementById(l))||void 0===e||e.focus(),null===(r=document.getElementById(l))||void 0===r||r.click()},children:"No ".concat(e)}),y.map(a=>{var o,n;let c=formatPrice("Min"===e?a[0]:a[1]);return"Max"===e&&(null!==(o=X.minPrice)&&void 0!==o?o:0)>a[1]&&0!==a[1]||"Min"===e&&0!==X.maxPrice&&a[0]>(null!==(n=X.maxPrice)&&void 0!==n?n:0)?(0,r.jsx)(r.Fragment,{}):(0,r.jsx)("button",{className:(0,i.Z)("bg-white px-4 py-[0.8125rem] text-start font-primary text-[0.875rem]",p()["item--data-filter"],p()["price-filter"],{[p()["item--data-filter__active"]]:X[t]==a["Max"===e?1:0],"!bg-colorPalette-color5 !text-colorPalette-textTitleDark hover:!bg-colorPalette-color1 hover:!text-colorPalette-textTitleLight":!T&&X[t]!=a["Max"===e?1:0],"!bg-colorPalette-color6":(null==P?void 0:P("real"))&&X[t]!=a["Max"===e?1:0],"!bg-colorPalette-color1 !text-colorPalette-textTitleLight":!T&&X[t]==a["Max"===e?1:0]}),onClick:()=>{var r,i;A({...X,[t]:"Min"===e?a[0]:a[1]}),null===(r=document.getElementById(l))||void 0===r||r.focus(),null===(i=document.getElementById(l))||void 0===i||i.click()},children:("Min"===e?a[0]:a[1])!==0&&c[0]+" "+c.substring(1)},e+"-"+a)})]})]},e)})})]})]}),(0,r.jsxs)("div",{className:"relative flex justify-end self-center pt-4 tablet-sm:pt-0 md:h-full",children:[(0,r.jsxs)("div",{className:"self-center tablet-sm:relative",children:[(0,r.jsxs)("button",{className:(0,i.Z)(p()["main--btn-filter"],{"bg-royaleTemplate-darkGray":S&&T,"!bg-colorPalette-color5 !text-colorPalette-textTitleDark [&>svg]:!fill-colorPalette-textTitleDark":!T&&!P("real")&&S,"!bg-colorPalette-color6 !text-colorPalette-textTitleDark [&>svg]:!fill-colorPalette-textTitleDark":P("real")&&S}),"aria-label":"Filters Dropdown",onClick:e=>handleDropdown(e,B),children:[(0,r.jsx)(d.Z,{role:"img","aria-hidden":!0,className:"pointer-events-none mr-2 w-[0.875rem] fill-white"}),"Filters"]}),(0,r.jsxs)("div",{tabIndex:0,role:"tab",className:(0,i.Z)("absolute left-[50%] top-[3.625rem] flex w-[17.6875rem] translate-x-[-50%] flex-col items-start justify-center bg-neutral-100 p-4 font-primary shadow-sh3 tablet-sm:left-auto tablet-sm:right-4 tablet-sm:top-[2.8125rem] tablet-sm:translate-x-0 md:right-2 lg:right-4 lg:top-[3.4375rem]",{hidden:!1===S,"!bg-colorPalette-color5":!T&&!P("real"),"!bg-colorPalette-color6":P("real")}),children:[!W&&(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("p",{className:(0,i.Z)("mb-2 w-full text-left font-primary text-base font-semibold",{"text-royaleTemplate-darkGray":T,"text-colorPalette-textTitleDark":!T}),children:"Status"}),(0,r.jsxs)("div",{className:"relative z-50 mb-6 w-full ",children:[(0,r.jsxs)("button",{className:(0,i.Z)("flex w-full items-center justify-between border-[0.0625rem] border-solid border-black px-4 py-[0.8125rem] text-left font-primary text-[0.875rem]",{"border-royaleTemplate-darkGray !bg-royaleTemplate-darkGray !text-white":N&&T,"!bg-colorPalette-color1 !text-colorPalette-textTitleLight !text-white":!T&&N}),"aria-label":"Mobile Status Dropdown",onClick:e=>{C(e=>!e);let t=e.target.nextElementSibling;n()(()=>{t.focus()},100),n()(()=>{t.addEventListener("focusout",e=>{let t=e.currentTarget.parentElement;n()(()=>{t.contains(document.activeElement)||C(!1)},50)})},100)},children:[(0,r.jsx)("span",{children:"Choose status"}),(0,r.jsx)(s.Z,{role:"img","aria-hidden":!0,className:(0,i.Z)("mr-1 w-[0.375rem] fill-royaleTemplate-darkGray",{"!fill-white":N})})]}),(0,r.jsx)("div",{tabIndex:0,role:"tab",className:(0,i.Z)("absolute left-0 top-[3.75rem] flex w-full flex-col bg-white p-2 shadow-sh3",{hidden:!1===N}),children:renderStatusDropdown()})]}),(0,r.jsx)("p",{className:"mb-2 w-full text-left font-primary text-base font-semibold text-royaleTemplate-darkGray",children:"Price"}),(0,r.jsx)("div",{className:"relative mb-6 w-full ",children:["Min","Max"].map((e,t)=>{let l="Max"===e?"maxPrice":"minPrice",a="".concat(e.toLowerCase(),"price-wrapper"),o=formatPrice(X[l]);return(0,r.jsx)("div",{tabIndex:0,role:"tab",className:(0,i.Z)("relative flex w-full flex-col items-center justify-center bg-neutral-100 shadow-sh3"),children:(0,r.jsxs)("div",{className:(0,i.Z)("relative mb-2 w-full",{"z-20":0===t,"z-10":1===t}),children:[(0,r.jsxs)("button",{id:a,className:(0,i.Z)("flex w-full items-center justify-between border-[0.0625rem] border-solid border-black px-4 py-[0.8125rem] text-start font-primary text-[0.875rem] leading-[1.375rem] text-royaleTemplate-darkGray transition-colors duration-150",{"border-royaleTemplate-darkGray bg-royaleTemplate-darkGray !text-white":L===e&&T,"!bg-colorPalette-color1 !text-colorPalette-textTitleLight !text-white":!T&&L===e}),"aria-label":"Set price filter to ".concat(0!==X[l]?o[0]+" "+o.substring(1):e),onClick:t=>{M(()=>L===e?"":e);let l=t.target.nextElementSibling;n()(()=>{l.focus()},100),n()(()=>{l.addEventListener("focusout",e=>{let t=e.currentTarget;n()(()=>{var e;(null===(e=t.parentElement)||void 0===e?void 0:e.contains(document.activeElement))||M("")},50)})},100)},children:[(0,r.jsx)("span",{children:0!==X[l]?o[0]+" "+o.substring(1):e}
1)," ",(0,r.jsx)(s.Z,{role:"img","aria-hidden":!0,className:(0,i.Z)("mr-1 w-[0.375rem] fill-royaleTemplate-darkGray",{"!fill-white":L===e})})]}),(0,r.jsxs)("div",{tabIndex:0,role:"tab",className:(0,i.Z)("absolute left-0 top-[58px] hidden w-full flex-col bg-white ",{"!flex ":L===e}),children:[(0,r.jsx)("button",{className:(0,i.Z)("bg-white px-4 py-[0.8125rem] text-start font-primary text-[0.875rem]",p()["item--data-filter"],p()["price-filter"],{"hover:!bg-colorPalette-color1 ":!(null==P?void 0:P("default"))}),onClick:()=>{var e,t;A({...X,[l]:0}),null===(e=document.getElementById(a))||void 0===e||e.focus(),null===(t=document.getElementById(a))||void 0===t||t.click()},children:"No ".concat(e)}),y.map(t=>{var o,n;let c=formatPrice("Min"===e?t[0]:t[1]);return"Max"===e&&(null!==(o=X.minPrice)&&void 0!==o?o:0)>t[1]&&0!==t[1]||"Min"===e&&0!==X.maxPrice&&t[0]>(null!==(n=X.maxPrice)&&void 0!==n?n:0)?(0,r.jsx)(r.Fragment,{}):(0,r.jsx)("button",{className:(0,i.Z)("bg-white px-4 py-[0.8125rem] text-start font-primary text-[0.875rem]",p()["item--data-filter"],p()["price-filter"],{[p()["item--data-filter__active"]]:X[l]==t["Max"===e?1:0],"!bg-colorPalette-color5 !text-colorPalette-textTitleDark hover:!bg-colorPalette-color1 hover:!text-colorPalette-textTitleLight":!T&&X[l]!=t["Max"===e?1:0],"!bg-colorPalette-color6":(null==P?void 0:P("real"))&&X[l]!=t["Max"===e?1:0],"!bg-colorPalette-color1 !text-colorPalette-textTitleLight":!T&&X[l]==t["Max"===e?1:0]}),onClick:()=>{var r,i;A({...X,[l]:"Min"===e?t[0]:t[1]}),null===(r=document.getElementById(a))||void 0===r||r.focus(),null===(i=document.getElementById(a))||void 0===i||i.click()},children:("Min"===e?t[0]:t[1])!==0&&c[0]+" "+c.substring(1)})})]})]})},t)})})]}),(0,r.jsx)("p",{className:(0,i.Z)("mb-2 w-full text-left font-primary text-base font-semibold",{"text-royaleTemplate-darkGray":T,"text-colorPalette-textTitleDark":!T}),children:"Beds & Baths"}),renderBedsBaths({label:"Bedrooms",key:"bed",className:"mb-2"}),renderBedsBaths({label:"Bathrooms",key:"bath",className:"mb-6"}),(0,r.jsx)("p",{className:(0,i.Z)("mb-2 w-full text-left font-primary text-base font-semibold",{"text-royaleTemplate-darkGray":T,"text-colorPalette-textTitleDark":!T}),children:"Property Type"}),(0,r.jsxs)("div",{className:"relative w-full",children:[(0,r.jsxs)("button",{className:(0,i.Z)("flex w-full items-center justify-between border-[0.0625rem] border-solid border-black px-4 py-[0.8125rem] text-left font-primary text-[0.875rem]",{"border-royaleTemplate-darkGray bg-royaleTemplate-darkGray !text-white":Z&&T,"bg-colorPalette-color1 !text-colorPalette-textTitleLight !text-white":!T&&Z}),"aria-label":"toggle property dropdown",onClick:e=>{I(e=>!e);let t=e.target.nextElementSibling;n()(()=>{t.focus()},100),n()(()=>{t.addEventListener("focusout",e=>{let t=e.currentTarget.parentElement;n()(()=>{t.contains(document.activeElement)||I(!1)},50)})},100)},children:[(0,r.jsx)("span",{children:"Choose property type"})," ",(0,r.jsx)(s.Z,{role:"img","aria-hidden":!0,className:(0,i.Z)("mr-1 w-[0.375rem] fill-royaleTemplate-darkGray outline-none",{"!fill-white":Z,"!fill-colorPalette-color1 hover:!fill-colorPalette-textTitleDark":!P("default")})})]}),(0,r.jsx)("div",{tabIndex:0,role:"tab",className:(0,i.Z)("absolute left-[50%] top-[3.75rem] flex w-full translate-x-[-50%] flex-col bg-white p-2 shadow-sh3",{hidden:!1===Z,"!bg-colorPalette-color5":!T&&!P("real"),"!bg-colorPalette-color6":P("real")}),children:f.map(e=>(0,r.jsxs)("button",{className:(0,i.Z)(p()["btn--checkbox"],p()["item--data-filter"],{[p()["item--data-filter__active"]]:F.includes(e),...radioBtnThemeClass(F.includes(e))}),onClick:()=>{F.includes(e)?R(F.filter(t=>t!==e)):R([...F,e])},children:[(0,r.jsx)("div",{className:(0,i.Z)(p()["icon-wrapper"],{[p()["icon-wrapper--active"]]:F.includes(e)}),children:(0,r.jsx)(m.Z,{"aria-hidden":!0,role:"img",className:"w-[0.9163rem]"})}),e.text]},e.type))})]})]})]}),(0,r.jsx)("div",{className:"self-center",children:(0,r.jsx)("button",{className:(0,i.Z)(p()["main--btn-filter"]),onClick:()=>{_(!1),H([]),K([]),R([]),A({minPrice:0,maxPrice:0,bed:0,bath:0}),document.getElementById("search-city-input").placeholder="Find a city"},children:"Reset"})}),(0,r.jsx)("div",{className:"self-center",children:(0,r.jsxs)("a",{className:(0,i.Z)(p()["main--btn-filter"],p()["main--btn-filter_search"],{"!text-colorPalette-textTitleDark [&>svg]:!fill-colorPalette-textTitleDark":!T,"!bg-colorPalette-color5":!T&&!P("real"),"!bg-colorPalette-color6":P("real")}),"aria-label":"redirect to search page",href:x.asPath("".concat(q,"?").concat(Q)),children:[(0,r.jsx)(u.Z,{role:"img","aria-hidden":!0,
1className:"pointer-events-none mr-2 w-[0.875rem] fill-royaleTemplate-darkGray"}),"Search"]})})]})]}),(0,r.jsx)("div",{className:"w-full max-w-[82.8125rem] p-4 pt-0 text-right font-primary text-xs leading-5 text-royaleTemplate-extraLightGrey",children:"Real Estate IDX Powered by iHomeFinder"})]}):(0,r.jsx)(r.Fragment,{})}},858151:function(e,t,l){"use strict";l.r(t);var r=l(785893),a=l(905918),i=l(667294),o=l(260256),n=l(386010),c=l(425675),s=l.n(c),d=l(194829);t.default=e=>{let{get:t,isHidden:l,isBuilder:i,isColorTheme:c}=(0,a.Q$)(e),m=(0,d.Z)("screen and (max-width: 641px)",!1),u=(0,a.KE)(),x=(0,a.GK)(e=>e.idxClient),p=t("widgetType");return l()||!x?(0,r.jsx)(r.Fragment,{}):"default in-house"===p?(0,r.jsx)(o.default,{props:e}):(0,r.jsx)("div",{className:(0,n.Z)("pt-1",{"bg-royaleTemplate-black":c("default"),"bg-colorPalette-color1":!c("default")}),children:i||"builder"===e.mode||u?(0,r.jsx)("div",{className:"flex items-center justify-center pb-8 pt-7",children:(0,r.jsx)(s(),{src:m?"/static/image/ihf-widget-placeholder-mobile.png":"/static/image/ihf-widget-placeholder.png",alt:"IHF Widget Preview",width:m?340:719,height:m?264:240})}):(0,r.jsx)(IDXSearch,{widgetType:p.toLowerCase(),bgClass:{"bg-royaleTemplate-black":c("default"),"bg-colorPalette-color1":!c("default")}})})};let IDXSearch=e=>{let t=i.useRef(null),l=(0,a.GK)(e=>e.idxClient),renderIDX=()=>{var l;let r=window;if(!r.ihfKestrel)return;let a=null===(l=r.ihfKestrel)||void 0===l?void 0:l.render({component:"quickSearchWidget",style:e.widgetType});if(t&&(null==t?void 0:t.current)){let e=t.current;e.children[0]&&e.children[0].remove(),null==e||e.appendChild(a)}};return(i.useEffect(()=>{let e=0,t=setInterval(()=>{var l;let r=window;(null===(l=r.ihfKestrel)||void 0===l?void 0:l.render)&&(renderIDX(),clearInterval(t)),++e>5&&clearInterval(t)},300);return()=>clearInterval(t)},[e.widgetType]),null==l?void 0:l.activationToken)?(0,r.jsxs)(r.Fragment,{children:[(0,r.jsx)("div",{ref:t,id:"IHFQuickSearch",className:(0,n.Z)("relative z-50 mx-auto max-w-[1440px] px-4 pt-7 font-primary text-etherealTemplate-primaryBlack tablet-sm:px-5 lg:px-[3.75rem]",{"lg:max-w-[80rem]":"universal"===e.widgetType})}),(0,r.jsx)("div",{className:(0,n.Z)("z-50 mx-auto max-w-[1440px] px-4 pt-2 text-right font-primary text-xs font-light tracking-[1.2] text-white tablet-sm:px-5 lg:px-[3.75rem]",{"pb-7":"twoline"!==e.widgetType,"pb-8 tablet-sm:-mt-7 ":"twoline"===e.widgetType,"lg:max-w-[80rem]":"universal"===e.widgetType},e.bgClass),children:"Real Estate IDX Powered by iHomeFinder"})]}):(0,r.jsx)(r.Fragment,{})}},901552:function(e){e.exports={"input-field":"DropDownInput_input-field__Fdo1x","input-field--inactive":"DropDownInput_input-field--inactive__i4Qfk","input-field--with-value":"DropDownInput_input-field--with-value__GeDD8","input-wrapper":"DropDownInput_input-wrapper__MsKy9","btn-arrow":"DropDownInput_btn-arrow__Ts3QE","item--data-filter":"DropDownInput_item--data-filter__O3IQr","item--data-filter__active":"DropDownInput_item--data-filter__active__H3p4N","data-dropdown":"DropDownInput_data-dropdown__wSX5y",chip:"DropDownInput_chip__P6MC_","chip--delete":"DropDownInput_chip--delete__bBlgi",themed:"DropDownInput_themed__sRkp8","scroll-buttons":"DropDownInput_scroll-buttons__YPbB5"}},484577:function(e){e.exports={"item--data-filter":"Header_item--data-filter__r3pr_","item--data-filter__active":"Header_item--data-filter__active__qqUnt","price-filter":"Header_price-filter__KbAi2","main--btn-filter":"Header_main--btn-filter__qE3zE","main--btn-filter_search":"Header_main--btn-filter_search__xwUIs","btn--checkbox":"Header_btn--checkbox__KE8G8","icon-wrapper":"Header_icon-wrapper__X4TgV","icon-wrapper--active":"Header_icon-wrapper--active__H4Ln1","btn--checkbox__theme":"Header_btn--checkbox__theme__eEi3Q","btn--checkbox__theme--active":"Header_btn--checkbox__theme--active__Rxnzs",real:"Header_real__iX9er"}}}]);
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.