fix: remove double <form> element from 2FA form (#9851)

This commit is contained in:
Phsm Qwerty 2024-12-02 09:08:26 +01:00 committed by GitHub
parent 8a1da3804c
commit 58138f2da3
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -17,41 +17,39 @@
<template>
<div class="center">
<a-form>
<img
v-if="$config.banner"
:src="$config.banner"
class="user-layout-logo"
alt="logo">
<h1 style="text-align: center; font-size: 24px; color: gray"> {{ $t('label.two.factor.authentication') }} </h1>
<p v-if="$store.getters.twoFaProvider === 'totp'" style="text-align: center; font-size: 16px;" v-html="$t('message.two.fa.auth.totp')"></p>
<p v-if="$store.getters.twoFaProvider === 'staticpin'" style="text-align: center; font-size: 16px;" v-html="$t('message.two.fa.auth.staticpin')"></p>
<br />
<a-form
:ref="formRef"
:model="form"
:rules="rules"
@finish="handleSubmit"
layout="vertical">
<a-form-item name="code" ref="code" style="text-align: center;">
<a-input-password
style="width: 500px"
v-model:value="form.code"
placeholder="xxxxxx" />
</a-form-item>
<br/>
<div :span="24" class="center-align top-padding">
<a-button
:loading="loading"
ref="submit"
type="primary"
:disabled="buttonstate"
class="center-align"
@click="handleSubmit">{{ $t('label.verify') }}
</a-button>
</div>
<img
v-if="$config.banner"
:src="$config.banner"
class="user-layout-logo"
alt="logo">
<h1 style="text-align: center; font-size: 24px; color: gray"> {{ $t('label.two.factor.authentication') }} </h1>
<p v-if="$store.getters.twoFaProvider === 'totp'" style="text-align: center; font-size: 16px;" v-html="$t('message.two.fa.auth.totp')"></p>
<p v-if="$store.getters.twoFaProvider === 'staticpin'" style="text-align: center; font-size: 16px;" v-html="$t('message.two.fa.auth.staticpin')"></p>
<br />
<a-form
:ref="formRef"
:model="form"
:rules="rules"
@finish="handleSubmit"
layout="vertical">
<a-form-item name="code" ref="code" style="text-align: center;">
<a-input-password
style="width: 500px"
v-model:value="form.code"
placeholder="xxxxxx" />
</a-form-item>
<br/>
<div :span="24" class="center-align top-padding">
<a-button
:loading="loading"
ref="submit"
type="primary"
:disabled="buttonstate"
class="center-align"
@click="handleSubmit">{{ $t('label.verify') }}
</a-button>
</div>
</a-form>
</a-form>
</div>
</template>