infoCard.vue 2.8 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127
  1. <template>
  2. <view class="info-card-detail">
  3. <view class="name-author">
  4. <view class="author-img">
  5. <view class="img-box">
  6. <image src="https://hzchart.oss-cn-shanghai.aliyuncs.com/T2ddwIIaULVdkGM6gVMuNxBSft8Y.png"></image>
  7. </view>
  8. <view class="set-btn"> + 关注</view>
  9. </view>
  10. <view class="name-box">
  11. <text>专栏名称专栏名称专栏名称</text>
  12. <text>作者昵称作者昵称</text>
  13. </view>
  14. </view>
  15. <view class="info-card-lable">
  16. <text>专栏名称专1</text>
  17. <text>专栏名称专2</text>
  18. <text>专栏名称专3</text>
  19. <text>专栏名称专3</text>
  20. <text>专栏名称专3</text>
  21. <text>专栏名称专3</text>
  22. </view>
  23. <view class="info-card-fans">
  24. <text>12</text>
  25. <text>文章</text>
  26. <text>24</text>
  27. <text>被收藏</text>
  28. <text>36</text>
  29. <text>粉丝</text>
  30. </view>
  31. </view>
  32. </template>
  33. <script>
  34. export default {
  35. data() {
  36. return {};
  37. },
  38. methods: {},
  39. };
  40. </script>
  41. <style lang="scss" scope>
  42. .info-card-detail {
  43. border-radius: 16rpx;
  44. background-image: url(https://hzchart.oss-cn-shanghai.aliyuncs.com/cygx/Maskgroupbg.png);
  45. background-size: 100% 100%;
  46. // 上面的那个盒子用就把上面的样式去掉
  47. width: 100%;
  48. padding: 40rpx 35rpx;
  49. background-repeat: no-repeat;
  50. color: #fff;
  51. .name-author {
  52. display: flex;
  53. .author-img {
  54. position: relative;
  55. display: flex;
  56. justify-content: center;
  57. width: 126rpx;
  58. height: 138rpx;
  59. text-align: center;
  60. .img-box {
  61. width: 110rpx;
  62. height: 110rpx;
  63. border-radius: 50%;
  64. overflow: hidden;
  65. image {
  66. width: 160rpx;
  67. height: 160rpx;
  68. }
  69. }
  70. .set-btn {
  71. position: absolute;
  72. display: flex;
  73. justify-content: center;
  74. align-items: center;
  75. left: 0;
  76. bottom: 0;
  77. width: 126rpx;
  78. height: 48rpx;
  79. border-radius: 150rpx;
  80. background-color: #376cbb;
  81. color: #fff;
  82. }
  83. }
  84. .name-box {
  85. margin-left: 20rpx;
  86. text:nth-child(1) {
  87. font-size: 36rpx;
  88. font-weight: 500;
  89. line-height: 50rpx;
  90. padding: 20rpx 0;
  91. }
  92. text:nth-child(2) {
  93. font-size: 28rpx;
  94. font-weight: 400;
  95. line-height: 39rpx;
  96. }
  97. }
  98. }
  99. .info-card-lable {
  100. display: flex;
  101. flex-wrap: wrap;
  102. text {
  103. height: 45rpx;
  104. padding: 6rpx 12rpx 6rpx 12rpx;
  105. border-radius: 150rpx;
  106. background-color: #8994a1;
  107. margin: 20rpx 20rpx 0rpx 0;
  108. }
  109. }
  110. .info-card-fans {
  111. margin-top: 20rpx;
  112. display: flex;
  113. align-items: center;
  114. text:nth-child(2n + 1) {
  115. color: #ffe8a8;
  116. font-size: 38rpx;
  117. font-weight: 500;
  118. }
  119. text:nth-child(2n) {
  120. margin: 0 40rpx 0 5rpx;
  121. }
  122. }
  123. }
  124. </style>