exploreProduct.vue 1.1 KB

12345678910111213141516171819202122232425262728293031323334353637383940
  1. <script lang='ts' setup>
  2. import {
  3. getFeatureListApi,
  4. } from '~/api/model/feature'
  5. import { PageSizeEnum } from '~/enums/sizeEnum'
  6. const list = ref<any>([])
  7. const page_size = ref(3)
  8. async function getFeatureList(pageNo = PageSizeEnum.PAGE, pageSize = page_size.value) {
  9. const params = {
  10. pageNo,
  11. pageSize,
  12. }
  13. const res: any = await getFeatureListApi(params)
  14. list.value = res.records
  15. }
  16. getFeatureList()
  17. </script>
  18. <template>
  19. <div class="w-1400px mx-auto mb-160px">
  20. <h2 class="!mb-60px fw-700 text-40px text-#363C40 text-center">
  21. Explore More Product Collections
  22. </h2>
  23. <div class="grid grid-cols-3 gap-x-106px gap-y-60px px-66px">
  24. <div v-for="item, index in list" :key="index">
  25. <common-featured-item2 :item />
  26. </div>
  27. </div>
  28. <!-- <div class="flex justify-center items-center cursor-pointer mt-60px">
  29. <div class="underline fw-500 text-24px hover:text-#CC9879">
  30. View All
  31. </div>
  32. <svgo-arrow class="!w-12px !h-12px ml-14px" />
  33. </div> -->
  34. </div>
  35. </template>
  36. <style lang='less' scoped>
  37. </style>