introduction.vue 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293
  1. <template>
  2. <view>
  3. <view class="bg-img flex align-center" style="background-image: url('/static/userBgImg.png');height: 450upx;"></view>
  4. <view class="container" style="margin: -60upx 20upx 20upx 20upx;">
  5. <view class="text-center">
  6. <view class="cu-avatar avatar round" :style="[{backgroundImage:'url('+ detail.cover +')'}]"></view>
  7. <view class="padding-tb-xs" style="font-size: 38upx;font-family: PingFang SC;font-weight: 800;color: #222222;">{{detail.personName}}</view>
  8. <view class="flex justify-center align-center">
  9. <view class="padding-right-sm" style="font-size: 30upx;font-family: PingFang SC;font-weight: 800;color: #222222;">{{+detail.hotValue}}</view>
  10. <!-- <view class="tag">
  11. <image src="/static/crown.png" style="width: 22upx;height: 19upx;margin-right: 10upx;"></image>
  12. <view class="text-sm text-white">热力榜第1</view>
  13. </view> -->
  14. </view>
  15. </view>
  16. <view style="padding: 0 60upx;">
  17. <view>{{detail.introduce}}</view>
  18. </view>
  19. <view class="flex justify-around padding">
  20. <button class="theme-bg-color text-white round cu-btn" style="width: 200upx;height: 70upx;">转发好友</button>
  21. <button class="theme-bg-color text-white round cu-btn" style="width: 200upx;height: 70upx;">生成海报</button>
  22. </view>
  23. </view>
  24. <view class="container margin-sm">
  25. <block v-for="(item, index) in boostList" :key="index">
  26. <view class="flex align-center justify-between padding-lr-sm">
  27. <view class="flex align-center" style="width: 40%;">
  28. <view class="padding-sm">
  29. <u-avatar :src="item.image" size="82"></u-avatar>
  30. </view>
  31. <view class="name">{{item.name}}</view>
  32. </view>
  33. <view class="text-sm" style="color: #757575;">{{item.type}}</view>
  34. <view class="name padding-right flex justify-end" style="width: 180upx;">{{item.hotValue}}热力值</view>
  35. </view>
  36. </block>
  37. </view>
  38. </view>
  39. </template>
  40. <script>
  41. export default {
  42. data() {
  43. return {
  44. avatar: '/static/avatar.png',
  45. detail: {},
  46. boostList: [
  47. {image: '/static/avatar.png', name: '易烊千玺', time: '2021-6-7 10:28:46', type: '打榜', hotValue: '12'},
  48. {image: '/static/avatar2.png', name: '许嵩', time: '2021-6-7 10:28:46', type: '礼物', hotValue: '13'},
  49. {image: '/static/avatar.png', name: '林俊杰', time: '2021-6-7 10:28:46', type: '打榜', hotValue: '188'},
  50. {image: '/static/avatar2.png', name: '沈以诚', time: '2021-6-7 10:28:46', type: '打榜', hotValue: '88'},
  51. {image: '/static/avatar.png', name: '颜人中', time: '2021-6-7 10:28:46', type: '礼物', hotValue: '13'},
  52. {image: '/static/avatar.png', name: '毛不易', time: '2021-6-7 10:28:46', type: '转发', hotValue: '1'},
  53. {image: '/static/avatar2.png', name: '陈奕迅', time: '2021-6-7 10:28:46', type: '打榜', hotValue: '5'}
  54. ],
  55. }
  56. },
  57. onLoad(options) {
  58. this.detail= JSON.parse(options.detail);
  59. },
  60. methods: {
  61. }
  62. }
  63. </script>
  64. <style>
  65. .container {
  66. background-color: #ffffff;
  67. border-radius: 30upx;
  68. box-shadow: 10upx 10upx 60upx #d0d0d0;
  69. }
  70. .avatar {
  71. width: 145upx;
  72. height: 145upx;
  73. margin-top: -60upx;
  74. }
  75. .tag {
  76. padding: 0 10upx;
  77. display: flex;
  78. align-items: center;
  79. justify-content: center;
  80. background: linear-gradient(90deg, #7355F4 0%, #573BE5 100%);
  81. margin-top: 8upx;
  82. border-radius: 30upx;
  83. }
  84. .name {
  85. font-size: 26upx;
  86. font-family: PingFang SC;
  87. font-weight: bold;
  88. color: #111111;
  89. }
  90. </style>