PageSourceSearch

https://portal.homnifi.com/static/js/4612.3f834a39.chunk.js

js homnifi.com collected 2026-10-06 12:47:36 UTC 10,111 bytes, 2 lines download raw bytes

1"use strict";(globalThis.webpackChunkplatform_homnifi_com||=[]).push([[4612],{41701(e,t,r){r.d(t,{A:()=>u});var a,s=r(65043);function l(){return l=Object.assign?Object.assign.bind():function(e){for(var t=1;t<arguments.length;t++){var r=arguments[t];for(var a in r)({}).hasOwnProperty.call(r,a)&&(e[a]=r[a])}return e},l.apply(null,arguments)}function i(e,t){let{title:r,titleId:i,...n}=e;return s.createElement("svg",l({width:21,height:21,viewBox:"0 0 21 21",fill:"none",xmlns:"http://www.w3.org/2000/svg",ref:t,"aria-labelledby":i},n),r?s.createElement("title",{id:i},r):null,a||(a=s.createElement("path",{d:"M5.81523 3H5.08398C4.5867 3 4.10979 3.19754 3.75816 3.54918C3.40653 3.90081 3.20898 4.37772 3.20898 4.875V17.375C3.20898 17.8723 3.40653 18.3492 3.75816 18.7008C4.10979 19.0525 4.5867 19.25 5.08398 19.25H8.34898V18H5.08398C4.91822 18 4.75925 17.9342 4.64204 17.8169C4.52483 17.6997 4.45898 17.5408 4.45898 17.375V4.875C4.45898 4.70924 4.52483 4.55027 4.64204 4.43306C4.75925 4.31585 4.91822 4.25 5.08398 4.25H5.81523C5.94454 4.61572 6.18409 4.93234 6.50087 5.15622C6.81765 5.38009 7.19608 5.5002 7.58398 5.5H11.334C11.7219 5.5002 12.1003 5.38009 12.4171 5.15622C12.7339 4.93234 12.9734 4.61572 13.1027 4.25H13.834C13.9997 4.25 14.1587 4.31585 14.2759 4.43306C14.3931 4.55027 14.459 4.70924 14.459 4.875V6.75H15.709V4.875C15.709 4.37772 15.5114 3.90081 15.1598 3.54918C14.8082 3.19754 14.3313 3 13.834 3H13.1027C12.9734 2.63428 12.7339 2.31766 12.4171 2.09379C12.1003 1.86991 11.7219 1.7498 11.334 1.75H7.58398C7.19608 1.7498 6.81765 1.86991 6.50087 2.09379C6.18409 2.31766 5.94454 2.63428 5.81523 3ZM6.95898 3.625C6.95898 3.45924 7.02483 3.30027 7.14204 3.18306C7.25925 3.06585 7.41822 3 7.58398 3H11.334C11.4997 3 11.6587 3.06585 11.7759 3.18306C11.8931 3.30027 11.959 3.45924 11.959 3.625C11.959 3.79076 11.8931 3.94973 11.7759 4.06694C11.6587 4.18415 11.4997 4.25 11.334 4.25H7.58398C7.41822 4.25 7.25925 4.18415 7.14204 4.06694C7.02483 3.94973 6.95898 3.79076 6.95898 3.625ZM11.334 8C10.8367 8 10.3598 8.19754 10.0082 8.54917C9.65653 8.90081 9.45898 9.37772 9.45898 9.875V17.375C9.45898 17.8723 9.65653 18.3492 10.0082 18.7008C10.3598 19.0525 10.8367 19.25 11.334 19.25H16.334C16.8313 19.25 17.3082 19.0525 17.6598 18.7008C18.0114 18.3492 18.209 17.8723 18.209 17.375V9.875C18.209 9.37772 18.0114 8.90081 17.6598 8.54917C17.3082 8.19754 16.8313 8 16.334 8H11.334ZM10.709 9.875C10.709 9.70924 10.7748 9.55027 10.892 9.43306C11.0093 9.31585 11.1682 9.25 11.334 9.25H16.334C16.4997 9.25 16.6587 9.31585 16.7759 9.43306C16.8931 9.55027 16.959 9.70924 16.959 9.875V17.375C16.959 17.5408 16.8931 17.6997 16.7759 17.8169C16.6587 17.9342 16.4997 18 16.334 18H11.334C11.1682 18 11.0093 17.9342 10.892 17.8169C10.7748 17.6997 10.709 17.5408 10.709 17.375V9.875Z",fill:"#7D7D7D"})))}const n=s.forwardRef(i);r.p;var o=r(70579);const u=e=>{let{cb:t,name:r,onBlur:a,onChange:l,setIsDisable:i,clearOTP:u,setClearOTP:c}=e;const d=s.useRef(Array(6).fill(null)),[m,h]=s.useState(Array.from({length:6},()=>"")),[f,p]=s.useState([]),x=(e,r)=>{if(isNaN(Number(r)))return;if(!/^\d?$/.test(r))return;const a=[...m];var s,l;(a[e]=r,h(a),t&&(6===a.join("").length?(i&&i(!1),t(a.join(""))):i&&i(!0)),r&&e<m.length-1)?null===(s=d.current[e+1])||void 0===s||s.focus():null===(l=d.current[e])||void 0===l||l.focus()},C=e=>{const r=e.clipboardData.getData("text").slice(0,6).split("").map(e=>isNaN(Number(e))?"":e);var a;(h(r),t)&&(6===r.join("").length&&(t(r.join("")),null===(a=d.current[r.length-1])||void 0===a||a.focus()))};return(0,s.useEffect)(()=>{u&&c&&(h(Array.from({length:6},()=>"")),c(!1))},[u,c]),(0,s.useEffect)(()=>{var e;null===(e=d.current[0])||void 0===e||e.focus()},[]),(0,o.jsxs)("div",{className:"flex items-center justify-center sm:gap-4 gap-2 w-full",children:[Array.from({length:6},(e,t)=>(0,o.jsx)("input",{name:r,type:"number",maxLength:1,className:"no-arrows border border-borderBlue focus:border-primary focus:shadow-lg focus:shadow-primary/20 sm:w-12 sm:h-16 w-10 h-14 text-xl text-center outline-none bg-transparent sm:py-2 sm:px-4 px-2 rounded-full "+(f.includes(t)&&""===m[t]?"border-redDanger":"border-blueGrey"),ref:e=>d.current[t]=e,value:m[t],onChange:e=>{(0===m[t].length&&e.target.value||1===m[t].length&&!e.target.value)&&(x(t,e.target.value),l&&l(e)),1===m[t].length&&e.target.value&&t<5&&(x(t+1,(Number(e.target.value)%10).toString()),l&&l(e))},onPaste:C,onKeyDown:e=>((e,t)=>{if("Backspace"===t.key&&e>0){var r;t.preventDefault();const a=[...m];a[e]="",h(a);const s=Array.from({length:6},(e,t)=>t);p(s),null===(r=d.current[e-1])||void 0===r||r.focus()}})(t,e),placeholder:"-"},t)),(0,o.jsx)("button",{onClick:async()=>{try{const r=(await navigator.clipboard.readText()).slice(0,6).split("").map(e=>isNaN(Number(e))?"":e);var e;if(h(r),t)if(6===r.join("").length)t(r.join("")),null===(e=d.current[r.length-1])||void 0===e||e.focus()}catch(r){console.error("Failed to read clipboard contents: ",r)}},type:"button",children:(0,o.jsx)(n,{})})]})}},94612(e,t,r){r.r(t);var a=r(30423),s=r(65043),l=r(96312),i=r(91036),n=r(41701),o=r(5900),u=r(69747),c=r(63045),d=r(39928),m=r(2
11651),h=r(72686),f=r(70579);const p=()=>{const[e,t]=(0,s.useState)(!0);(0,s.useEffect)(()=>{setTimeout(()=>t(!1),700)},[]);const{getTOtp:r,postOtp:p}=(0,d.g)(),[x,C]=s.useState(!0),[v,g]=s.useState(!1),[j,w]=(0,s.useState)(!1),b=(0,s.useRef)(null),[y,q]=s.useState(""),[N,T]=s.useState(""),[V,A]=(0,s.useState)("");(0,s.useEffect)(()=>{(async()=>{try{const e=await r();e.data.url&&(q(e.data.url),T(e.data.secret))}catch(e){console.error({error:e})}})()},[]);const P=(0,a.Wx)({initialValues:{otpValue:""},validationSchema:h.b9,onSubmit:async e=>{}});(0,s.useEffect)(()=>()=>{b.current&&clearTimeout(b.current)},[]);const[Y,k]=s.useState(!1),{writeClipboardText:M}=(0,u.A)();return(0,f.jsxs)("div",{className:"w-full p-4 flex flex-col gap-10",children:[(0,f.jsxs)("div",{className:"flex flex-col gap-2",children:[(0,f.jsx)("div",{className:"font-baumans text-2xl",children:"Enable 2FA"}),(0,f.jsx)("span",{className:"text-sm text-primaryGrey",children:"After scanning the QR code, the app will display a digit code that you can enter below."})]}),(0,f.jsxs)("div",{className:"flex flex-col gap-2 items-center justify-center",children:[(0,f.jsx)("div",{className:"w-[30%] flex justify-center self-center",children:e?(0,f.jsx)("div",{className:"flex justify-center items-center h-24",children:(0,f.jsx)(m.h,{className:"animate-spin h-10 text-primary"})}):(0,f.jsx)(l.A,{size:50,style:{height:"auto",maxWidth:"100%",width:"100%"},value:y,viewBox:"0 0 50 50"})}),(0,f.jsxs)("button",{className:"flex items-center justify-center gap-1 border px-4 py-1 rounded-lg border-borderBlue text-xs",onClick:()=>{M(N||""),i.oR.success("Auth Code Copied!"),k(!0),setTimeout(()=>{k(!1)},5e3)},children:[(0,f.jsx)("span",{children:"Copy Google Auth Key"}),Y?(0,f.jsx)(c.ym,{width:12,height:12}):(0,f.jsx)(c.Td,{width:12,height:12})]})]}),(0,f.jsxs)("div",{className:"w-full flex flex-col gap-2",children:[(0,f.jsx)(n.A,{setIsDisable:C,cb:async e=>{try{g(!0);422===(await p({totpOtp:e})).status&&A("Invalid OTP")}catch(t){console.error(t)}finally{g(!1)}},name:"otpValue",onBlur:(e,t)=>{P.handleBlur(e)},isError:!(!P.touched.otpValue||!P.errors.otpValue),value:P.values.otpValue,onChange:e=>{w(!0),A(""),b.current&&clearTimeout(b.current),b.current=setTimeout(()=>{w(!1)},2e3),P.handleChange(e)}}),P.touched.otpValue&&P.errors.otpValue&&!j&&(0,f.jsx)("div",{className:"text-red-500 text-xs  w-full flex justify-center",children:P.errors.otpValue}),V&&(0,f.jsx)("div",{className:"text-red-500 text-xs text-center mt-4",children:V})]}),(0,f.jsx)(o.A,{text:"Continue",loading:v,disabled:x})]})};r.d(t,["default",0,p])},72686(e,t,r){var a=r(26044),s=r(9320);const l=a.Ik().shape({email:a.Yj().required("Username is Required"),password:a.Yj().required("Password is required"),rememberMe:a.zM().optional(),captchaToken:"DEV"===s.Kk?a.Yj().optional():a.Yj().required()}),i=a.Ik().shape({email:a.Yj().required("Email Required"),confirmEmail:a.Yj().oneOf([a.KR("email"),void 0],"Email must be match").required("Confirm email is required"),username:a.Yj().min(6,"Username should have atleast 6 chars minimum.").matches(/^[a-zA-Z0-9.+_-]+$/,"Invalid username").required("Username is required"),password:a.Yj().min(8,"Must be at least 8 characters").matches(/[a-z]/,"Must have at least 1 lowercase letter").matches(/[A-Z]/,"Must have at least 1 uppercase letter").matches(/[0-9]/,"Must have at least 1 number").matches(/^[A-Za-z0-9!@#$%^&*]+$/,"Password must only contain specified characters !@#$%^&*").matches(/[!@#$%^&*]/,"Must have at least 1 symbol").required("Password is required"),confirmPassword:a.Yj().oneOf([a.KR("password"),void 0],"Passwords must match").required("Confirm Password is required"),referralCode:a.Yj().required("Referral code is required."),country:a.Yj().required("Country is required!"),acceptTerms:a.zM().oneOf([!0],"Accept Terms & Conditions is required"),captchaToken:"DEV"===s.Kk?a.Yj().optional():a.Yj().required()}),n=a.Ik().shape({acceptTerms:a.zM().oneOf([!0],"Accept Terms & Conditions is required").required("required")}),o=a.Ik().shape({referralUpline:a.Yj().required("Refferal code is required")}),u=a.Ik().shape({email:a.Yj().email("Invalid email").required("Email Required"),
1captchaToken:"DEV"===s.Kk?a.Yj().optional():a.Yj().required()}),c=a.Ik().shape({otpValue:a.Yj().min(6,"Invalid OTP").required("OTP is required")}),d=a.Ik().shape({newPassword:a.Yj().min(8,"Password must be at least 8 characters long").matches(/[a-z]/,"Must have at least 1 lowercase letter").matches(/[A-Z]/,"Must have at least 1 uppercase letter").matches(/[0-9]/,"Must have at least 1 number").matches(/^[A-Za-z0-9!@#$%^&*]+$/,"Password must only contain specified characters !@#$%^&*").matches(/[!@#$%^&*]/,"Must have at least 1 symbol").required("Password is required"),confirmPassword:a.Yj().oneOf([a.KR("newPassword")],"Passwords must match").required("Confirm Password is required"),logout:a.zM()});r.d(t,["IR",0,l,"Ie",0,u,"O5",0,i,"Rp",0,n,"b9",0,c,"oW",0,d,"vQ",0,o])}}]);
2//# sourceMappingURL=4612.3f834a39.chunk.js.map

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.