1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
<template>
<div class="app-container">
<form v-show="loginShow" @submit.prevent="false">
<h3>登录账号</h3>
<input type="email" placeholder="请输入邮箱地址" required name="email" />
<input
type="password"
placeholder="请输入密码"
required
name="password"
/>
<button>登录</button>
<p>
<a>忘记密码</a>
<a href="javascript:void(0);" @click="loginShow = false">注册账号</a>
</p>
</form>
<form v-show="!loginShow" @submit.prevent="false">
<h3>注册账号</h3>
<input type="email" placeholder="请输入邮箱地址" required name="email" />
<input
type="password"
placeholder="请输入密码"
required
name="password"
/>
<input type="text" placeholder="请输入用户名" name="username" />
<button>注册</button>
<p>
<a href="javascript:void(0);" @click="loginShow = true"
>已有账号?马上登录</a
>
</p>
</form>
</div>
</template>
<script>
export default {
name: "AppAuth",
components: {},
data() {
return {
loginShow: true,
};
},
computed: {},
methods: {},
beforeMount() {},
};
</script>
<style lang="scss" scoped>
.app-container {
width: 100%;
height: 70vh;
display: flex;
flex-direction: column;
align-items: center;
justify-content: center;
& > form {
width: 100%;
max-width: 500px;
& > h3 {
font-size: 25px;
color: #4cd1e0;
text-align: center;
}
& > input {
width: 100%;
height: 50px;
line-height: 50px;
padding: 6px 12px;
margin: 10px 0px;
}
& > button {
background: #4cd1e0;
color: #fff;
margin: 10px 0 30px;
width: 100%;
height: 50px;
outline: none;
display: block;
font-size: 16px;
border: 0 none;
cursor: pointer;
text-align: center;
line-height: 50px;
resize: none;
font-family: "微软雅黑";
border-radius: 3px;
box-shadow: 0 15px 25px #bae4ec;
}
& > p {
color: #4cd1e0;
display: flex;
font-size: 13px;
flex-direction: row;
justify-content: space-between;
}
}
}
</style>