import{r as n,a as i,h as t,F as r}from"./p-5b224066.js";import{n as e}from"./p-6726835b.js";const s=class{constructor(t){n(this,t),this.inProgress=i(this,"inProgress",7),this.signInInProgress=!1}async signUserIn(){this.inProgress.emit(!0),this.signInInProgress=!0,await e({onSuccess:this.signInSuccess,onError:this.signInError})}render(){return t(r,null,t("div",{class:"actions"},this.renderAction()),this.renderTerms())}renderAction(){return this.signInInProgress?t("ion-spinner",{color:"medium"}):t("ion-button",{shape:"round",color:"dark",onClick:async()=>await this.signUserIn()},t("ion-icon",{src:`${this.config.globalAssetsUrl}/icons/dfinity.svg`,"aria-label":"","aria-hidden":!0,slot:"start",lazy:!0}),t("ion-label",null,this.i18n.sign_in.internet_identity))}renderTerms(){return t("p",{class:"ion-text-center ion-margin terms"},"By continuing, you are indicating that you accept our"," ",t("a",{href:"https://deckdeckgo.com/terms",rel:"noopener norefferer",target:"_blank"},t("ion-label",null,this.i18n.links.terms_of_use))," ","and"," ",t("a",{href:"https://deckdeckgo.com/privacy",rel:"noopener norefferer",target:"_blank"},t("ion-label",null,this.i18n.links.privacy_policy)),".")}};s.style="deckgo-ic-signin div.actions{display:flex;justify-content:center;align-content:center;padding:8px 16px}deckgo-ic-signin p.terms{font-size:var(--font-size-very-small);max-width:220px;margin-left:auto;margin-right:auto}";export{s as deckgo_ic_signin}