msg.vue 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133
  1. <template>
  2. <view class="msg">
  3. <!-- 搜索框 -->
  4. <view class="search">
  5. <u-input placeholder="搜索" border='none'>
  6. <template slot="suffix" style='margin-right:40rpx;'>
  7. <u-image :showLoading="true" :showError='true' src="/static/icon/search.png" width="40rpx"
  8. height="32rpx"></u-image>
  9. </template>
  10. </u-input>
  11. </view>
  12. <!-- 消息列表 -->
  13. <view class="msgListBox">
  14. <view class="childBox" v-for="item in 4">
  15. <view >活动通知</view>
  16. <view >
  17. <text>你关注的活动已经开始了</text>
  18. <image src="/static/icon/right.png" ></image>
  19. </view>
  20. <view >028-329230</view>
  21. </view>
  22. </view>
  23. <!-- 底部导航栏 -->
  24. <view style="height: 140rpx; width: 100%;"></view>
  25. <tab-bar checked="msg"></tab-bar>
  26. </view>
  27. </template>
  28. <script>
  29. import TabBar from '../../components/TabBar/tabbar.vue'
  30. export default {
  31. components: {
  32. TabBar
  33. },
  34. data() {
  35. return {};
  36. },
  37. methods: {
  38. },
  39. }
  40. </script>
  41. <style lang="scss" scoped>
  42. $pageColor:#F9F9F9;
  43. $bgColor:#FFFFFF;
  44. // flex布局居中对齐
  45. @mixin flexlayout {
  46. display: flex;
  47. align-items: center;
  48. justify-content: center;
  49. }
  50. .msg {
  51. height: 100%;
  52. background-color: $pageColor;
  53. }
  54. // 搜索
  55. .search {
  56. padding: 0 30rpx;
  57. height: 124rpx;
  58. background-color: $bgColor;
  59. box-shadow: 0px 4rpx 8rpx 0px rgba(0, 0, 0, 0.04);
  60. @include flexlayout;
  61. ::v-deep .u-input {
  62. width: 690rpx !important;
  63. height: 68rpx !important;
  64. background: #F1F1F1;
  65. border-radius: 74rpx;
  66. }
  67. ::v-deep .u-input__content__field-wrapper {
  68. padding-left: 36rpx;
  69. }
  70. }
  71. // 消息列表
  72. .msgListBox {
  73. padding: 0 30rpx;
  74. margin-top: 24rpx;
  75. background: $bgColor;
  76. box-shadow: 0rpx 4rpx 24rpx -10rpx rgba(101, 95, 90, 0.3);
  77. border-radius: 12rpx;
  78. .childBox {
  79. width: 690rpx;
  80. height: 202rpx;
  81. border-bottom: 1rpx solid #F0F0F0;
  82. padding-top: 40rpx;
  83. box-sizing: border-box;
  84. view:nth-child(n+0) {
  85. font-size: 32rpx;
  86. font-family: PingFang-SC-Bold, PingFang-SC;
  87. font-weight: bold;
  88. color: #333333;
  89. margin-bottom: 24rpx;
  90. }
  91. view:nth-child(n+1) {
  92. margin-bottom: 12rpx;
  93. position: relative;
  94. text{
  95. font-size: 28rpx;
  96. font-family: PingFang-SC-Medium, PingFang-SC;
  97. font-weight: 500;
  98. color: #333333;
  99. }
  100. image{
  101. width:12rpx ;
  102. height:20rpx;
  103. position: absolute;
  104. top:12rpx;
  105. right:24rpx;
  106. }
  107. }
  108. view:nth-child(n+2) {
  109. font-size: 26rpx;
  110. font-family: PingFang-SC-Medium, PingFang-SC;
  111. font-weight: 500;
  112. color: #999999;
  113. }
  114. }
  115. }
  116. </style>