瑶都万能墙
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

106 lines
1.7 KiB

4 months ago
3 months ago
4 months ago
3 months ago
3 months ago
4 months ago
3 months ago
4 months ago
  1. <template>
  2. <view class="item"
  3. @click="$emit('click', item)">
  4. <image class="image" :src="images[0]" mode="aspectFill"></image>
  5. <view class="info">
  6. <view class="title">
  7. {{ item.title }}
  8. </view>
  9. <view class="text">
  10. {{ item.home }} {{ item.crm }}m2 | {{ item.face }}
  11. </view>
  12. <view class="tags">
  13. <view class="tag"
  14. v-if="item.isGood">
  15. {{ item.isGood }}
  16. </view>
  17. <view class="tag"
  18. v-if="item.isMinPrice">
  19. {{ item.isMinPrice }}
  20. </view>
  21. </view>
  22. <view class="price">
  23. <text>{{ item.money }}</text>/
  24. </view>
  25. </view>
  26. </view>
  27. </template>
  28. <script>
  29. export default {
  30. props : {
  31. item : {},
  32. },
  33. computed : {
  34. images(){
  35. if(!this.item.image){
  36. return []
  37. }
  38. return this.item.image.split(',')
  39. }
  40. },
  41. data() {
  42. return {
  43. }
  44. },
  45. methods: {
  46. }
  47. }
  48. </script>
  49. <style scoped lang="scss">
  50. .item{
  51. display: flex;
  52. padding: 20rpx;
  53. font-size: 24rpx;
  54. border-radius: 20rpx;
  55. box-shadow: 0 0 6rpx 6rpx #00000011;
  56. margin: 24rpx;
  57. position: relative;
  58. background-color: #fff;
  59. image{
  60. width: 180rpx;
  61. height: 180rpx;
  62. border-radius: 20rpx;
  63. margin-right: 20rpx;
  64. flex-shrink: 0;
  65. }
  66. .info{
  67. gap: 10rpx;
  68. display: flex;
  69. flex-direction: column;
  70. justify-content: space-between;
  71. .title{
  72. font-size: 28rpx;
  73. }
  74. .text{
  75. color: #777;
  76. }
  77. .tags{
  78. display: flex;
  79. gap: 10rpx;
  80. .tag{
  81. background-color: #eee;
  82. padding: 10rpx;
  83. border-radius: 10rpx;
  84. font-size: 22rpx;
  85. color: #777;
  86. // &:nth-child(1){
  87. background-color: rgba($uni-color, 0.1);
  88. color: $uni-color;
  89. // }
  90. }
  91. }
  92. .price{
  93. color: #f40;
  94. text{
  95. font-size: 30rpx;
  96. }
  97. }
  98. }
  99. }
  100. </style>