pleroma-fe/src/components/mfa_form/recovery_form.vue

73 lines
1.7 KiB
Vue
Raw Normal View History

<template>
2019-07-05 09:17:44 +02:00
<div class="login panel panel-default">
<!-- Default panel contents -->
2019-07-05 09:17:44 +02:00
<div class="panel-heading">
{{ $t('login.heading.recovery') }}
</div>
2019-07-05 09:17:44 +02:00
<div class="panel-body">
<form
class="login-form"
@submit.prevent="submit"
>
<div class="form-group">
<label for="code">{{ $t('login.recovery_code') }}</label>
<input
id="code"
v-model="code"
class="form-control"
>
</div>
2019-07-05 09:17:44 +02:00
<div class="form-group">
<div class="login-bottom">
<div>
<button
class="button-unstyled -link"
type="button"
2021-02-25 13:32:21 +01:00
@click.prevent="requireTOTP"
2019-07-05 09:17:44 +02:00
>
{{ $t('login.enter_two_factor_code') }}
</button>
2019-07-05 09:17:44 +02:00
<br>
<button
class="button-unstyled -link"
type="button"
2021-02-25 13:32:21 +01:00
@click.prevent="abortMFA"
2019-07-05 09:17:44 +02:00
>
{{ $t('general.cancel') }}
</button>
2019-07-05 09:17:44 +02:00
</div>
<button
type="submit"
class="btn button-default"
2019-07-05 09:17:44 +02:00
>
{{ $t('general.verify') }}
</button>
</div>
</div>
2019-07-05 09:17:44 +02:00
</form>
</div>
2019-07-05 09:17:44 +02:00
<div
v-if="error"
class="form-group"
>
<div class="alert error">
{{ error }}
<button
class="button-unstyled"
2019-07-05 09:17:44 +02:00
@click="clearError"
>
<FAIcon
class="fa-scale-110 fa-old-padding"
icon="times"
/>
</button>
2019-07-05 09:17:44 +02:00
</div>
</div>
</div>
</template>
2022-07-31 11:35:48 +02:00
<script src="./recovery_form.js"></script>