完成用户页面UI
This commit is contained in:
67
src/components/UserItem.vue
Normal file
67
src/components/UserItem.vue
Normal file
@@ -0,0 +1,67 @@
|
||||
<script setup>
|
||||
defineProps({
|
||||
title: {
|
||||
type: String,
|
||||
default: "",
|
||||
},
|
||||
value: {
|
||||
type: String,
|
||||
default: "",
|
||||
},
|
||||
customStyle: {
|
||||
type: Object,
|
||||
default: () => ({}),
|
||||
},
|
||||
});
|
||||
</script>
|
||||
|
||||
<template>
|
||||
<view class="user-item" :style="customStyle">
|
||||
<text>{{ title }}</text>
|
||||
<view>
|
||||
<text>{{ value }}</text>
|
||||
<button>
|
||||
<image src="../static/enter.png" mode="widthFix" />
|
||||
</button>
|
||||
</view>
|
||||
</view>
|
||||
</template>
|
||||
|
||||
<style scoped>
|
||||
.user-item {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
align-items: center;
|
||||
background-color: #fff;
|
||||
height: 55px;
|
||||
border-bottom: 1px solid #f5f5f5;
|
||||
}
|
||||
.user-item > text {
|
||||
margin-left: 15px;
|
||||
font-size: 14px;
|
||||
}
|
||||
.user-item > view {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
font-size: 13px;
|
||||
color: #999;
|
||||
margin-right: 10px;
|
||||
}
|
||||
.user-item > view button {
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
border: none;
|
||||
background: none;
|
||||
line-height: 1;
|
||||
outline: none;
|
||||
box-sizing: border-box;
|
||||
}
|
||||
.user-item > view button::after {
|
||||
border: none;
|
||||
}
|
||||
|
||||
.user-item > view image {
|
||||
width: 24px;
|
||||
height: 24px;
|
||||
}
|
||||
</style>
|
||||
Reference in New Issue
Block a user