import{c as g,h as L,o as T,b as o,i as p,eu as A,e7 as C,H as x,l as I,v as w,k as F,a as _,t as k}from"./index-6Jqoo2rk.js";import{u as D,M as y}from"./actions-D_EjVM7_.js";import{S as M}from"./settingsTabLottieAnimation-CjBbsXGV.js";import{a0 as N,ap as R}from"./appDialogsManager-DnVhdlim.js";import{S as u}from"./space-DBcSn32d.js";import{c as $}from"./common.module-Cpg1ZUiO.js";import"./mediaHeader-B5k-4_FU.js";import"./emailSetup-CFcJlzt-.js";import"./iconTsx-Cr8T7ZIv.js";import"./bootstrapIm-BS8HLnlI.js";import"./transition-DuxZkCEv.js";import"./animations-O3syBkMX.js";import"./accumulate-BydAFozl.js";import"./browser-BlRx6CLO.js";import"./_commonjsHelpers-DsqdWQfm.js";import"./putPreloader-WBjcuDFX.js";import"./htmlToSpan-DhAls8qz.js";import"./anchorCallback-DsA1XczG.js";import"./toast-B3QB1-N7.js";import"./paintQrCode-u2FNs0A8.js";import"./fastBlur-Co-79rP4.js";import"./telInputField-Fj4gE689.js";import"./readBlobAsDataURL-DL2tTmc_.js";import"./tracking-CIK7NCFD.js";import"./getInputPasskeyResponse-RiY9Fe0r.js";import"./base64ToBytes-B7rMxzcy.js";import"./sha256-BMgYLqDy.js";import"./bytesCmp-DgkPox5J.js";const H=k('<form action=""autocomplete=off><div></div><div><button type=submit class="btn-primary btn-color-primary btn-large">'),dt=()=>{const[i]=N(),P=D();let r;const[a,c]=g(""),[h,d]=g(!1);L(()=>{a(),d(!1)}),setTimeout(()=>{r.input.focus()},400),T(()=>{c(""),r.input.value=""});const f=()=>a()&&a().length<=y;let s=!1;async function E(e){if(e.preventDefault(),!(!f()||s)){s=!0;try{await i.payload.onSubmit(a(),i,P)}catch{d(!0)}finally{s=!1}}}return o(R,{caption:"PasscodeLock.Notice",get children(){return[o(M,{name:"UtyanPasscode"}),o(u,{amount:"1.125rem"}),(()=>{const e=H(),n=e.firstChild,m=n.nextSibling,l=m.firstChild;return e.addEventListener("submit",E),p(n,o(A,{InputFieldClass:C,instanceRef:t=>{r=t},maxLength:y,autocomplete:"off",get value(){return a()},get errorLabel(){return h()?"PasscodeLock.PasscodesDontMatch":void 0},get label(){return i.payload.inputLabel},onRawInput:c})),p(e,o(u,{amount:"1rem"}),m),x(I,l,()=>!0),p(l,()=>w(i.payload.buttonText)),F(t=>{const v=$.AdditionalPadding,b=$.AdditionalPadding,S=!f();return v!==t._v$&&_(n,t._v$=v),b!==t._v$2&&_(m,t._v$2=b),S!==t._v$3&&(l.disabled=t._v$3=S),t},{_v$:void 0,_v$2:void 0,_v$3:void 0}),e})(),o(u,{amount:"1rem"})]}})};export{dt as default};
//# sourceMappingURL=enterPasswordTab-B9L_9FDO.js.map
