RecommendOriginal.vue 3.4 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150
  1. <template>
  2. <div class="container" id="recommends">
  3. <div class="title-icon">原厂推荐</div>
  4. <div class="hr-blue"></div>
  5. <ul class="recommend-list list-unstyled list-inline">
  6. <li class="recommend" v-for="(store, index) in stores">
  7. <a :href="'/store/' + store.uuid">
  8. <div class="img"><img :src="store.logoUrl || '/images/store/common/default.png'" /></div>
  9. <div class="content">
  10. <div class="name">
  11. <span :title="store.storeName">{{store.storeName}}</span>
  12. </div>
  13. <div class="subject" style="min-height: 5px;">
  14. </div>
  15. <div class="description">
  16. <strong>商家介绍</strong>:
  17. <span>{{store.description || '暂无简介'}}</span>
  18. </div>
  19. </div>
  20. </a>
  21. </li>
  22. </ul>
  23. </div>
  24. </template>
  25. <script>
  26. export default {
  27. name: 'recommend-original',
  28. computed: {
  29. stores () {
  30. return this.$store.state.provider.storeCms.recommendStore.data
  31. }
  32. }
  33. }
  34. </script>
  35. <style scoped>
  36. #recommends {
  37. width: 1190px;
  38. padding: 0px;
  39. }
  40. #recommends .title-icon {
  41. font-size: 24px;
  42. color: #323232;
  43. margin-top: 30px;
  44. margin-bottom: 10px;
  45. }
  46. #recommends .hr-blue {
  47. border-bottom: 2px solid #6493FF;
  48. border-right: 0px;
  49. border-top: 0px;
  50. border-left: 0px;
  51. width: 100%;
  52. margin-bottom: 20px;
  53. }
  54. #recommends .recommend-list {
  55. margin-bottom: 20px;
  56. margin: 0;
  57. }
  58. #recommends .recommend-list .recommend {
  59. width: 220px;
  60. height: 210px;
  61. border: 1px solid #D6D3CE;
  62. margin-right: 22.5px;
  63. margin-bottom: 22px;
  64. }
  65. #recommends .recommend-list .recommend:last-child{
  66. margin-right: 0px !important;
  67. }
  68. .margin-left-zero {
  69. margin-left: 0px !important;
  70. }
  71. #recommends .recommend-list .recommend a {
  72. text-decoration: none;
  73. }
  74. #recommends .recommend-list .recommend .img{
  75. width: 200px;
  76. height: 80px;
  77. display: inline-block;
  78. overflow: hidden;
  79. line-height: 80px;
  80. text-align: center;
  81. margin-top: 5px;
  82. }
  83. #recommends .recommend-list .recommend img{
  84. max-height: 75px;
  85. max-width: 200px;
  86. margin-top: 5px;
  87. }
  88. #recommends .recommend-list .recommend .content {
  89. margin: 0 10px;
  90. height: 108px;
  91. text-align: left;
  92. }
  93. #recommends .recommend-list .recommend .name {
  94. font-size: 16px;
  95. color: #383939;
  96. font-weight: 600;
  97. width: 200px;
  98. height: 30px;
  99. margin-top: 10px;
  100. overflow: hidden;
  101. text-overflow: ellipsis;
  102. white-space: nowrap;
  103. word-break: break-all;
  104. }
  105. /*#recommends .recommend-list .recommend:hover .name{*/
  106. /*width: auto;*/
  107. /*}*/
  108. #recommends .recommend-list .recommend .subject, #recommends .recommend-list .recommend .description {
  109. font-size: 12px;
  110. color: #797979;
  111. line-height: 18px;
  112. overflow: hidden;
  113. text-overflow: ellipsis;
  114. display: -webkit-box;
  115. -webkit-box-orient: vertical;
  116. -webkit-line-clamp: 2;
  117. max-height: 36px;
  118. }
  119. #recommends .recommend-list .recommend .description{
  120. margin-top: 5px;
  121. width: 200px;
  122. height: 35px;
  123. }
  124. #recommends .recommend-list .recommend .subject span {
  125. width: 204px;
  126. white-space: pre-wrap;
  127. word-wrap : break-word ;
  128. overflow: hidden;
  129. text-overflow: ellipsis;
  130. }
  131. #recommends .recommend-list .recommend:hover{
  132. border: #5078cb 1px solid;
  133. }
  134. #recommends .recommend-list .recommend .description span {
  135. word-break: keep-all;
  136. width: 204px;
  137. display: inline;
  138. overflow: hidden;
  139. text-overflow: ellipsis;
  140. white-space: pre-wrap;
  141. word-wrap : break-word ;
  142. }
  143. </style>