Add password reset (#1)

This commit is contained in:
konrad 2018-11-01 21:34:29 +00:00 committed by Gitea
parent 17d5738aa3
commit c0d5f6e99a
8 changed files with 260 additions and 63 deletions

View file

@ -1,33 +1,30 @@
<template>
<div class="container has-text-centered">
<div class="column is-4 is-offset-4">
<img src="images/logo-full.svg"/>
<h2 class="title">Login</h2>
<div class="box">
<form id="loginform" @submit.prevent="submit">
<div class="field">
<div class="control">
<input type="text" class="input" name="username" placeholder="Username" v-model="credentials.username" required>
</div>
<div>
<h2 class="title">Login</h2>
<div class="box">
<form id="loginform" @submit.prevent="submit">
<div class="field">
<div class="control">
<input type="text" class="input" name="username" placeholder="Username" v-model="credentials.username" required>
</div>
<div class="field">
<div class="control">
<input type="password" class="input" name="password" placeholder="Password" v-model="credentials.password" required>
</div>
</div>
<div class="field">
<div class="control">
<input type="password" class="input" name="password" placeholder="Password" v-model="credentials.password" required>
</div>
</div>
<div class="field is-grouped">
<div class="control">
<button type="submit" class="button is-primary" v-bind:class="{ 'is-loading': loading}">Login</button>
<router-link :to="{ name: 'register' }" class="button">Register</router-link>
</div>
<div class="field is-grouped">
<div class="control">
<button type="submit" class="button is-primary" v-bind:class="{ 'is-loading': loading}">Login</button>
<router-link :to="{ name: 'register' }" class="button">Register</router-link>
<router-link :to="{ name: 'getPasswordReset' }" class="reset-password-link">Reset your password</router-link>
</div>
<div class="notification is-danger" v-if="error">
{{ error }}
</div>
</form>
</div>
</div>
<div class="notification is-danger" v-if="error">
{{ error }}
</div>
</form>
</div>
</div>
</template>
@ -72,4 +69,9 @@
.button {
margin: 0 0.4em 0 0;
}
.reset-password-link{
display: inline-block;
padding-top: 5px;
}
</style>