mirror of
https://github.com/nagisa77/OpenIsle.git
synced 2026-08-29 22:57:14 +00:00
feat: base input
This commit is contained in:
@@ -46,7 +46,6 @@ export default {
|
|||||||
border-radius: 10px;
|
border-radius: 10px;
|
||||||
border: 1px solid #ccc;
|
border: 1px solid #ccc;
|
||||||
gap: 10px;
|
gap: 10px;
|
||||||
margin-bottom: 20px;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.base-input-icon {
|
.base-input-icon {
|
||||||
|
|||||||
@@ -135,6 +135,7 @@ export default {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
gap: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.login-page-input {
|
.login-page-input {
|
||||||
|
|||||||
@@ -8,21 +8,17 @@
|
|||||||
<img :src="avatar" class="avatar-preview" />
|
<img :src="avatar" class="avatar-preview" />
|
||||||
<!-- 半透明蒙层:hover 时出现 -->
|
<!-- 半透明蒙层:hover 时出现 -->
|
||||||
<div class="avatar-overlay">更换头像</div>
|
<div class="avatar-overlay">更换头像</div>
|
||||||
<input
|
<input type="file" class="avatar-input" accept="image/*" @change="onAvatarChange" />
|
||||||
type="file"
|
|
||||||
class="avatar-input"
|
|
||||||
accept="image/*"
|
|
||||||
@change="onAvatarChange"
|
|
||||||
/>
|
|
||||||
</label>
|
</label>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-row">
|
<div class="form-row username-row">
|
||||||
<label>用户名</label>
|
<BaseInput icon="fas fa-user" v-model="username" placeholder="用户名" />
|
||||||
<BaseInput v-model="username" />
|
<div class="username-description">用户名是你在社区的唯一标识</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="form-row">
|
<div class="form-row">
|
||||||
<label>自我介绍</label>
|
<label>自我介绍</label>
|
||||||
<BaseInput v-model="introduction" textarea rows="3" />
|
<BaseInput v-model="introduction" textarea rows="3" />
|
||||||
|
<div class="introduction-description">自我介绍会出现在你的个人主页,可以简要介绍自己</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div v-if="role === 'ADMIN'" class="admin-section">
|
<div v-if="role === 'ADMIN'" class="admin-section">
|
||||||
@@ -141,35 +137,46 @@ export default {
|
|||||||
|
|
||||||
<style scoped>
|
<style scoped>
|
||||||
.settings-page {
|
.settings-page {
|
||||||
padding: 20px;
|
background-color: var(--background-color);
|
||||||
|
padding: 40px;
|
||||||
|
height: calc(100vh - var(--header-height) - 80px);
|
||||||
}
|
}
|
||||||
|
|
||||||
.settings-title {
|
.settings-title {
|
||||||
font-size: 20px;
|
font-size: 20px;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
margin-bottom: 20px;
|
margin-bottom: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.avatar-row {
|
.avatar-row {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
gap: 10px;
|
gap: 10px;
|
||||||
margin-bottom: 15px;
|
margin-bottom: 15px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.avatar-preview {
|
.avatar-preview {
|
||||||
width: 80px;
|
width: 80px;
|
||||||
height: 80px;
|
height: 80px;
|
||||||
border-radius: 40px;
|
border-radius: 40px;
|
||||||
object-fit: cover;
|
object-fit: cover;
|
||||||
}
|
}
|
||||||
|
|
||||||
.form-row {
|
.form-row {
|
||||||
margin-bottom: 15px;
|
margin-bottom: 15px;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
}
|
}
|
||||||
|
|
||||||
.admin-section {
|
.admin-section {
|
||||||
margin-top: 30px;
|
margin-top: 30px;
|
||||||
padding-top: 10px;
|
padding-top: 10px;
|
||||||
border-top: 1px solid #ccc;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.profile-section {
|
||||||
|
margin-bottom: 30px;
|
||||||
|
}
|
||||||
|
|
||||||
.buttons {
|
.buttons {
|
||||||
margin-top: 20px;
|
margin-top: 20px;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|||||||
@@ -223,6 +223,7 @@ export default {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
|
gap: 20px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.signup-page-input {
|
.signup-page-input {
|
||||||
|
|||||||
Reference in New Issue
Block a user