index.vue 4.6 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186
  1. <template>
  2. <view class="circle-box">
  3. <view class="circle-title" :style="[{ 'margin-top': statusBarH + 'px'}]">
  4. <view class="title-left">
  5. <view class="title-text sys-height-44 sys-color-gray-9 sys-weight-400" @click="setTitleTag(0)" :class="{'title-text-default':tagNum===0}">好友</view>
  6. <view class="title-text sys-height-44 sys-color-gray-9 sys-weight-400" @click="setTitleTag(1)" :class="{'title-text-default':tagNum===1}">附近</view>
  7. <view class="title-text sys-height-44 sys-color-gray-9 sys-weight-400" @click="setTitleTag(2)" :class="{'title-text-default':tagNum===2}">推荐</view>
  8. </view>
  9. <view class="title-right">
  10. <view class="title-icon">
  11. <image class="title-img" src="/static/img/circle/Group-100345@2x.png"></image>
  12. </view>
  13. <view class="title-icon">
  14. <image class="title-img" src="/static/img/circle/Group-100344@2x.png"></image>
  15. </view>
  16. </view>
  17. </view>
  18. <view class="circle-content" >
  19. <scroll-view :scroll-y="true" :style="{'height':'calc(100vh - '+navHeight+'rpx - var(--window-bottom))'}">
  20. <my-praise></my-praise>
  21. </scroll-view>
  22. </view>
  23. <view class="circle-add sys-background-yellow">
  24. <image class="circle-add-img" src="/static/img/circle/cancel-icon-2@2x.png"></image>
  25. </view>
  26. </view>
  27. </template>
  28. <script>
  29. import EnNav from "@/components/en-utils/en-nav/en-nav";
  30. import MyPraise from "@/pages/my/model/my-praise";
  31. export default {
  32. components: {MyPraise, EnNav},
  33. data() {
  34. return {
  35. statusBarH:0,
  36. tagNum:0,
  37. navHeight:44
  38. }
  39. },
  40. methods: {
  41. setTitleTag(num){
  42. if(num!==this.tagNum){
  43. this.tagNum=num
  44. }
  45. }
  46. },
  47. created() {
  48. uni.getSystemInfo({
  49. success: (e) =>{
  50. console.log(e.safeArea.bottom)
  51. this.statusBarH = e.statusBarHeight
  52. this.navHeight=(50+this.statusBarH)*2
  53. //e.safeArea.bottom 底部安全距离
  54. }
  55. })
  56. //#ifdef MP-WEIXIN
  57. this.isXcx=true
  58. //#endif
  59. }
  60. }
  61. </script>
  62. <style scoped lang="scss">
  63. .circle-box{
  64. .circle-title{
  65. display: flex;
  66. justify-content: space-between;
  67. padding:22rpx 36rpx;
  68. .title-left{
  69. display: flex;
  70. justify-content: flex-start;
  71. .title-text{
  72. font-size: 32rpx;
  73. margin-right: 56rpx;
  74. }
  75. .title-text-default{
  76. font-weight: 600;
  77. color: #141414;
  78. }
  79. }
  80. .title-right{
  81. display: flex;
  82. justify-content: flex-end;
  83. .title-img{
  84. width: 44rpx;
  85. height: 44rpx;
  86. margin-left: 40rpx;
  87. }
  88. }
  89. }
  90. .circle-content{
  91. padding: 0 32rpx;
  92. .circle-item{
  93. margin-top: 32rpx;
  94. margin-bottom: 8rpx;
  95. display: flex;
  96. justify-content: space-between;
  97. .item-left{
  98. width: 80rpx;
  99. height: 80rpx;
  100. position: relative;
  101. .item-head{
  102. width: 80rpx;
  103. height: 80rpx;
  104. border-radius: 50%;
  105. }
  106. .item-auth{
  107. width: 18rpx;
  108. height: 18rpx;
  109. position: absolute;
  110. bottom: 0;
  111. right: 8rpx;
  112. z-index: 10;
  113. }
  114. }
  115. .item-right{
  116. padding-left: 20rpx;
  117. width: calc(100vw - 144rpx);
  118. .circle-top-data{
  119. display: flex;
  120. justify-content: space-between;
  121. .circle-top-left{
  122. .circle-top-left-title{
  123. display: flex;
  124. justify-content: flex-start;
  125. align-items: center;
  126. .left-title-text{
  127. font-size: 32rpx;
  128. margin-right: 8rpx;
  129. }
  130. .left-title-vip-img{
  131. height: 28rpx;
  132. }
  133. }
  134. .left-title-time{
  135. margin-top: 8rpx;
  136. line-height: 34rpx;
  137. font-size: 24rpx;
  138. }
  139. }
  140. .circle-top-right{
  141. height: 40rpx;
  142. border-radius: 200rpx;
  143. border: 2rpx solid #141414;
  144. padding: 8rpx 16rpx;
  145. display: flex;
  146. justify-content: space-between;
  147. .circle-top-right-img{
  148. width: 40rpx;
  149. height: 40rpx;
  150. margin-right: 8rpx;
  151. }
  152. .circle-top-right-text{
  153. font-size: 28rpx;
  154. line-height: 40rpx;
  155. }
  156. }
  157. }
  158. }
  159. }
  160. }
  161. .circle-add{
  162. position: absolute;
  163. bottom: 70rpx;
  164. right: 22rpx;
  165. border-radius: 50%;
  166. width: 88rpx;
  167. height: 88rpx;
  168. display: flex;
  169. justify-content: center;
  170. align-items: center;
  171. .circle-add-img{
  172. width: 40rpx;
  173. height: 40rpx;
  174. }
  175. }
  176. }
  177. </style>