ProfileDetail.vue 1.9 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899
  1. <template>
  2. <div class="profile-detail">
  3. <div class="header">
  4. <div class="back" @click="goBack">
  5. <img src="@/assets/back.png" alt="">
  6. </div>
  7. <div class="title">个人详情</div>
  8. </div>
  9. <div class="content">
  10. <div class="info-item">
  11. <span class="label">用户名</span>
  12. <span class="value">张三</span>
  13. </div>
  14. <div class="info-item">
  15. <span class="label">手机号</span>
  16. <span class="value">138****8888</span>
  17. </div>
  18. <div class="info-item">
  19. <span class="label">注册时间</span>
  20. <span class="value">2024-03-20</span>
  21. </div>
  22. <div class="info-item">
  23. <span class="label">账户余额</span>
  24. <span class="value">¥ 1,000.00</span>
  25. </div>
  26. </div>
  27. </div>
  28. </template>
  29. <script>
  30. export default {
  31. name: 'ProfileDetail',
  32. methods: {
  33. goBack() {
  34. this.$router.go(-1)
  35. }
  36. }
  37. }
  38. </script>
  39. <style lang="scss" scoped>
  40. .profile-detail {
  41. min-height: 100vh;
  42. background-color: #f5f5f5;
  43. .header {
  44. position: relative;
  45. height: 44px;
  46. background-color: #fff;
  47. display: flex;
  48. align-items: center;
  49. justify-content: center;
  50. border-bottom: 1px solid #eee;
  51. .back {
  52. position: absolute;
  53. left: 15px;
  54. font-size: 20px;
  55. img{
  56. width: 20px;
  57. height: 20px;
  58. }
  59. }
  60. .title {
  61. font-size: 18px;
  62. font-weight: 500;
  63. }
  64. }
  65. .content {
  66. padding: 15px;
  67. background-color: #fff;
  68. margin-top: 10px;
  69. .info-item {
  70. display: flex;
  71. justify-content: space-between;
  72. padding: 15px 0;
  73. border-bottom: 1px solid #eee;
  74. &:last-child {
  75. border-bottom: none;
  76. }
  77. .label {
  78. color: #666;
  79. font-size: 16px;
  80. }
  81. .value {
  82. color: #333;
  83. font-size: 16px;
  84. }
  85. }
  86. }
  87. }
  88. </style>