1"use strict";(self.webpackChunk_N_E=self.webpackChunk_N_E||[]).push([[1354],{51354:(e,t,a)=>{a.r(t),a.d(t,{YieldCalculatorDuplex:()=>d});var l=a(85664),n=a(34989),r=a(81072),s=a(91745),i=a(15179);function d(e){let{price:t}=e,{annualRent:a,expenses:d,expensesSet:o,rent:x,rentalYield:c,rentSet:u,value:p,valueSet:m}=(0,s.$)(t);return(0,l.jsx)("div",{className:"relative pt-39",children:(0,l.jsx)("div",{className:(0,n.c)({theme:"duplex"}),children:(0,l.jsxs)("div",{className:"-mx-12 flex flex-wrap",children:[(0,l.jsx)("div",{className:"mb-10 w-full px-12 md:mb-0 md:w-1/2",children:(0,l.jsxs)("div",{className:"flex h-full flex-col justify-center rounded-30 bg-white p-24 shadow-testimonial",children:[(0,l.jsx)("div",{className:"",children:(0,l.jsx)(r.p,{label:"Property Value (\xa3)",onChange:e=>{m(""===e.target.value?"":Number(e.target.value))},onFocus:e=>{e.target.select()},theme:"duplex",type:"number",value:p})}),(0,l.jsx)("div",{className:"mt-20",children:(0,l.jsx)(r.p,{label:"Monthly Rent (\xa3)",onChange:e=>{u(""===e.target.value?"":Number(e.target.value))},onFocus:e=>{e.target.select()},theme:"duplex",type:"number",value:x})}),(0,l.jsx)("div",{className:"mt-20",children:(0,l.jsx)(r.p,{label:"Annual Expenses/Loss (\xa3)",onChange:e=>{o(""===e.target.value?"":Number(e.target.value))},onFocus:e=>{e.target.select()},theme:"duplex",type:"number",value:d})})]})}),(0,l.jsx)("div",{className:"w-full px-12 md:w-1/2",children:(0,l.jsxs)("div",{className:"relative flex h-full flex-col justify-between overflow-hidden rounded-30 border-3 border-white bg-white px-45 py-35 shadow-testimonial",children:[(0,l.jsx)("div",{className:"absolute inset-0 bg-primary opacity-100"}),(0,l.jsxs)("div",{className:"relative text-white",children:[(0,l.jsx)("h3",{className:"mb-0 text-balance font-semibold text-20 text-white leading-snug tracking-[0.08px] md:text-24 lg:text-28 xl:text-32",children:"Results"}),(0,l.jsx)("div",{className:"mt-30 text-16 leading-normal tracking-[0.04px]",children:"Estimated Annual Rent (\xa3)"}),(0,l.jsxs)("div",{className:"font-bold text-28 leading-none tracking-[0.1px] md:text-32 lg:text-42",children:[(0,i.$g)(a)," /year."]}),(0,l.jsx)("div",{className:"mt-30 text-16 leading-normal tracking-[0.04px]",children:"Estimated Rental Yield (%)"}),(0,l.jsxs)("div",{className:"font-bold text-28 leading-none tracking-[0.1px] md:text-32 lg:text-42",children:[c.toFixed(2),"%"]})]})]})})]})})})}},81072:(e,t,a)=>{a.d(t,{p:()=>i,r:()=>s});var l=a(85664),n=a(88253),r=a(96777);let s=(0,n.F)(["relative block w-full tracking-[0.4px] shadow-none outline-none transition-all duration-300 focus:z-20 focus:outline-none","form-input border-2 bg-absolute-white text-left text-black placeholder:text-placeholder"],{compoundVariants:[{class:"border-bordergray ring-0 ring-green-1/20 hover:border-green-1 hover:ring-2 focus:border-green-2 focus:ring-4 focus:ring-green-1/20",hasError:!1,theme:["beam","apex","chalet","duplex","fascia","gable"]},{class:"border-warning/40 ring-2 ring-warning/20 focus:border-warning/60 focus:ring-4 focus:ring-warning/20",hasError:!0,theme:["beam","apex","chalet","duplex","fascia","gable"]}],variants:{hasError:{false:"",true:""},theme:{apex:"px-14 py-10 text-18 leading-[28px]",beam:"rounded-8 px-14 py-10 text-16 leading-[24px]",chalet:"px-14 py-10 text-18 leading-[28px]",duplex:"rounded-10 pt-29 pr-12 pb-7 pl-14 text-15",estate:"",fascia:"px-14 py-10 text-18 leading-[34px]",gable:"px-14 py-10 text-18 leading-[28px]"}}}),i=e=>{let{className:t,error:a,label:n,placeholder:i,theme:d="beam",type:o="text",ref:x,...c}=e;return(0,l.jsxs)("div",{className:(0,r.cn)("relative transition-all",a?"mb-38":"mb-2"),children:[(0,l.jsx)("div",{className:(0,r.cn)("group absolute flex items-center justify-between border-warning/10 border-x border-b bg-warning/5 px-10 py-5 text-11 text-warning shadow-sm transition-all duration-300",a&&"visible top-full opacity-100",!a&&"invisible top-0 opacity-0","beam"===d?"left-10 rounded-b-6":"inset-x-0",t),children:null!=a?a:""}),(0,l.jsxs)("div",{className:"relative",children:[(0,l.jsx)("input",{className:s({hasError:!!a,theme:d}),placeholder:null!=i?i:n,ref:x,type:o,...c}),"duplex"===d&&(0,l.jsx)("span",{className:"pointer-events-none absolute inset-x-16 top-0 z-20 pt-10 font-semibold text-12 text-black tracking-[0.3px]",dangerouslySetInnerHTML:{__html:n}})]})]})};i.displayName="Input"},91745:(e,t,a)=>{a.d(t,{$:()=>n});var l=a(63276);
1function n(e){let[t,a]=(0,l.useState)(e),[n,r]=(0,l.useState)(0),[s,i]=(0,l.useState)(0),[d,o]=(0,l.useState)(0),[x,c]=(0,l.useState)(0);return(0,l.useEffect)(()=>{o(12*("number"==typeof n?n:0))},[n]),(0,l.useEffect)(()=>{let e="number"==typeof s?s:0,a="number"==typeof t?t:0;a>0?c((d-e)/a*100):c(0)},[t,d,s]),{annualRent:d,expenses:s,expensesSet:i,rent:n,rentalYield:x,rentSet:r,value:t,valueSet:a}}}}]);
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.