activity-recommend.vue 2.2 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101
  1. <template>
  2. <view class="activity-recommend">
  3. <view class="activity-list">
  4. <template v-for="(item, index) in [1, 2, 3]">
  5. <view class="activity-item" :key="index" @click="onClickActivity(item)">
  6. <view class="activity-title">KOSHINE 新品上线,解锁防脱生发新方式</view>
  7. <view class="activity-time">2024年03月20日 | E1馆二楼M16会议室</view>
  8. <view class="activity-summary">
  9. <view class="text">Kostal推出第四种机型的太阳能并网逆变器 2008年7月5日:KOSTAL公司原来只有PIKO系列太阳能并网逆变器10.1和5.5,中间没有其他功率段的产品。</view>
  10. <van-button class="btn-to-detail" type="primary">
  11. <template>
  12. <view>了解详情</view> <view class="arrow iconfont icon-right-s"></view>
  13. </template>
  14. </van-button>
  15. </view>
  16. </view>
  17. </template>
  18. </view>
  19. </view>
  20. </template>
  21. <script>
  22. export default {
  23. options: {
  24. styleIsolation: 'shared'
  25. },
  26. components: {
  27. },
  28. props: {},
  29. data() {
  30. return {
  31. }
  32. },
  33. created() {
  34. },
  35. methods: {
  36. onClickActivity() {
  37. this.navigateTo(this.$store.getters.website_url + '/mini-pro-activity?v=' + this.$store.getters.version)
  38. }
  39. }
  40. }
  41. </script>
  42. <style lang="scss">
  43. .activity-list{
  44. display: grid;
  45. grid-template-columns: 1fr;
  46. grid-row-gap: 18rpx;
  47. margin-top: 28rpx;
  48. }
  49. .activity-item{
  50. display: flex;
  51. flex-direction: column;
  52. height: 210rpx;
  53. background-color: #F6F6F6;
  54. border-radius: 10rpx;
  55. padding: 24rpx 30rpx;
  56. }
  57. .activity-title{
  58. @include text-ellipsis-line;
  59. font-family: Arial, Arial;
  60. font-weight: bold;
  61. font-size: $fontSize3;
  62. line-height: 35rpx;
  63. }
  64. .activity-time{
  65. font-size: $fontSize2;
  66. color: #333333;
  67. margin: 12rpx 0;
  68. }
  69. .activity-summary{
  70. display: flex;
  71. align-items: center;
  72. font-size: $fontSize1;
  73. line-height: 25rpx;
  74. .btn-to-detail{
  75. flex-shrink: 0;
  76. .van-button__text{
  77. display: flex!important;
  78. align-items: center;
  79. font-size: $fontSize0;
  80. }
  81. }
  82. .text{
  83. padding-right: 30rpx;
  84. color: #555555;
  85. @include text-ellipsis-line;
  86. -webkit-line-clamp: 2;
  87. }
  88. .arrow{
  89. margin-left: 12rpx;
  90. font-size: $fontSize0;
  91. }
  92. }
  93. .activity-tab{
  94. van-button{
  95. margin-right: 13rpx;
  96. }
  97. }
  98. </style>