community-recommend.vue 1.4 KB

12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455
  1. <template>
  2. <view :class="['community-recommend bg-white']">
  3. <view class="active-hd flex row-between" v-if="title">
  4. <view class="xxl bold">{{title}}</view>
  5. <router-link :to="url" navType="pushTab">
  6. <view class="sm">发现好物 <u-icon name="arrow-right"></u-icon>
  7. </view>
  8. </router-link>
  9. </view>
  10. <scroll-view style="white-space: nowrap;" :scroll-x="true">
  11. <view class="community-wrap">
  12. <community-list type="index" :list="list"></community-list>
  13. </view>
  14. </scroll-view>
  15. </view>
  16. </template>
  17. <script>
  18. export default {
  19. name: "community-recommend",
  20. props: {
  21. title: String,
  22. url: String,
  23. list: {
  24. type: Array,
  25. default: () => ([])
  26. },
  27. }
  28. }
  29. </script>
  30. <style lang="scss" scoped>
  31. .community-recommend {
  32. background-size: 100% auto;
  33. background-repeat: no-repeat;
  34. border-radius: 14rpx;
  35. overflow: hidden;
  36. background-image: url(../../static/images/index_community_bg.png);
  37. .active-hd {
  38. padding: 24rpx 20rpx;
  39. }
  40. .community-wrap {
  41. padding: 0 20rpx 20rpx;
  42. display: inline-block;
  43. }
  44. .more {
  45. height: 80rpx;
  46. border-top: $-solid-border;
  47. }
  48. }
  49. </style>