fix: 优化登录文案
This commit is contained in:
parent
9fc1a55def
commit
664bb39858
|
@ -37,16 +37,11 @@
|
||||||
:model="form"
|
:model="form"
|
||||||
class="login-form"
|
class="login-form"
|
||||||
@finish="onFinish"
|
@finish="onFinish"
|
||||||
|
:rules='rules'
|
||||||
>
|
>
|
||||||
<j-form-item
|
<j-form-item
|
||||||
label="账号"
|
label="账号"
|
||||||
name="username"
|
name="username"
|
||||||
:rules="[
|
|
||||||
{
|
|
||||||
required: true,
|
|
||||||
message: '请输入账号!',
|
|
||||||
},
|
|
||||||
]"
|
|
||||||
>
|
>
|
||||||
<j-input
|
<j-input
|
||||||
v-model:value="form.username"
|
v-model:value="form.username"
|
||||||
|
@ -57,12 +52,6 @@
|
||||||
<j-form-item
|
<j-form-item
|
||||||
label="密码"
|
label="密码"
|
||||||
name="password"
|
name="password"
|
||||||
:rules="[
|
|
||||||
{
|
|
||||||
required: true,
|
|
||||||
message: '请输入密码!',
|
|
||||||
},
|
|
||||||
]"
|
|
||||||
>
|
>
|
||||||
<j-input-password
|
<j-input-password
|
||||||
v-model:value="form.password"
|
v-model:value="form.password"
|
||||||
|
@ -75,12 +64,6 @@
|
||||||
class="verifyCode"
|
class="verifyCode"
|
||||||
label="验证码"
|
label="验证码"
|
||||||
name="verifyCode"
|
name="verifyCode"
|
||||||
:rules="[
|
|
||||||
{
|
|
||||||
required: true,
|
|
||||||
message: '请输入验证码!',
|
|
||||||
},
|
|
||||||
]"
|
|
||||||
>
|
>
|
||||||
<j-input
|
<j-input
|
||||||
v-model:value="form.verifyCode"
|
v-model:value="form.verifyCode"
|
||||||
|
@ -129,26 +112,26 @@
|
||||||
<div class="other">
|
<div class="other">
|
||||||
<j-divider plain>
|
<j-divider plain>
|
||||||
<div class="other-text">
|
<div class="other-text">
|
||||||
其他方式登录
|
其他登录方式
|
||||||
</div>
|
</div>
|
||||||
</j-divider>
|
</j-divider>
|
||||||
<div class="other-button">
|
<div class="other-button">
|
||||||
<j-button
|
<div
|
||||||
v-for="(item, index) in bindings"
|
class='other-button-item'
|
||||||
:key="index"
|
v-for="(item, index) in bindings"
|
||||||
type="link"
|
:key="index"
|
||||||
@Click="handleClickOther(item)"
|
@click="handleClickOther(item)"
|
||||||
>
|
>
|
||||||
<img
|
<img
|
||||||
style="width: 32px; height: 33px"
|
style="width: 32px; height: 32px"
|
||||||
:alt="item.name"
|
:alt="item.name"
|
||||||
:src="
|
:src="
|
||||||
item.logoUrl || iconMap.get(
|
item.logoUrl || iconMap.get(
|
||||||
item.provider,
|
item.provider,
|
||||||
) || defaultImg
|
) || defaultImg
|
||||||
"
|
"
|
||||||
/>
|
/>
|
||||||
</j-button>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
@ -214,6 +197,39 @@ const form = reactive({
|
||||||
verifyKey: '',
|
verifyKey: '',
|
||||||
});
|
});
|
||||||
|
|
||||||
|
const rules = {
|
||||||
|
username: [
|
||||||
|
{
|
||||||
|
validator(_: any, value: string) {
|
||||||
|
if (!value) {
|
||||||
|
return Promise.reject('请输入账号!')
|
||||||
|
}
|
||||||
|
return Promise.resolve()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
password: [
|
||||||
|
{
|
||||||
|
validator(_: any, value: string) {
|
||||||
|
if (!value) {
|
||||||
|
return Promise.reject('请输入密码!')
|
||||||
|
}
|
||||||
|
return Promise.resolve()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
],
|
||||||
|
verifyCode: [
|
||||||
|
{
|
||||||
|
validator(_: any, value: string) {
|
||||||
|
if (!value) {
|
||||||
|
return Promise.reject('请输入验证码!')
|
||||||
|
}
|
||||||
|
return Promise.resolve()
|
||||||
|
}
|
||||||
|
}
|
||||||
|
]
|
||||||
|
}
|
||||||
|
|
||||||
const codeUrl = ref('');
|
const codeUrl = ref('');
|
||||||
const codeConfig = ref(false);
|
const codeConfig = ref(false);
|
||||||
|
|
||||||
|
@ -445,6 +461,15 @@ screenRotation(screenWidth.value, screenHeight.value);
|
||||||
position: relative;
|
position: relative;
|
||||||
bottom: 10px;
|
bottom: 10px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
display: flex;
|
||||||
|
gap: 24px;
|
||||||
|
justify-content: center;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
|
||||||
|
.other-button-item {
|
||||||
|
cursor: pointer;
|
||||||
|
padding: 4px;
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -529,7 +554,8 @@ screenRotation(screenWidth.value, screenHeight.value);
|
||||||
}
|
}
|
||||||
|
|
||||||
.content {
|
.content {
|
||||||
padding: 32px 0 24px;
|
padding: 32px 0 24px !important;
|
||||||
|
margin-top: 12% !important;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
</style>
|
</style>
|
||||||
|
|
Loading…
Reference in New Issue