{{ctx.Locale.Tr "settings.twofa"}}

{{ctx.Locale.Tr "settings.twofa_desc"}}

{{if .TOTPEnrolled}}

{{ctx.Locale.Tr "settings.twofa_is_enrolled"}}

{{ctx.Locale.Tr "settings.twofa_reenroll.description"}}

{{ctx.Locale.Tr "settings.twofa_reenroll"}}
{{.CsrfTokenHtml}}

{{ctx.Locale.Tr "settings.regenerate_scratch_token_desc"}}

{{if .SignedUser.MustHaveTwoFactor}}

{{ctx.Locale.Tr "settings.twofa_unroll_unavailable"}}

{{else}}
{{.CsrfTokenHtml}}

{{ctx.Locale.Tr "settings.twofa_disable_note"}}

{{end}} {{else}} {{/* The recovery tip is there as a means of encouraging a user to enroll */}}

{{ctx.Locale.Tr "settings.twofa_recovery_tip"}}

{{ctx.Locale.Tr "settings.twofa_not_enrolled"}}

{{ctx.Locale.Tr "settings.twofa_enroll"}}
{{end}}