Selaa lähdekoodia

fix: bug修复阶段v2.7

chenpeng 1 viikko sitten
vanhempi
commit
05c70901b4

+ 2 - 1
components/business/categories/list.vue

@@ -4,6 +4,7 @@
 import templateTwo from './comp/temp2.vue'
 import templateOne from './comp/temp1.vue'
 import { Api } from '@/api/model/url'
+
 const config = useRuntimeConfig()
 const baseURL = config.public.apiBaseSiteUrl
 
@@ -27,7 +28,7 @@ list_column_three.value = categoryList.value.slice(5, 8)
 <template>
   <div class="bg-#fff py-120px">
     <div class="w-1200-auto text-center">
-      <h2 class="text-36px fw-800 text-#333 !mb-20px custom-title-font">
+      <h2 id="catalogs-list" class="text-36px fw-800 text-#333 !mb-20px custom-title-font">
         Access Category-Driven <span class="custom-title-bg">Solutions</span>
       </h2>
       <div class="text-#999 text-22px mb-80px">

+ 3 - 3
components/common/category/item.vue

@@ -7,14 +7,14 @@ defineProps({
 <template>
   <div>
     <div class="custom-main mx-auto  overflow-hidden pos-relative">
-      <h2 class="!mb-20px text-30px fw-800 text-#333 line-clamp-1">
+      <h2 class="!mb-16px text-30px lh-32px fw-800 text-#333">
         {{ item.contentTitle }}
       </h2>
       <img
         :src="item.bannerImg"
         alt=""
         srcset=""
-        class="w-260px h-260px object-cover"
+        class="w-260px h-260px object-cover mx-auto"
       >
     </div>
   </div>
@@ -27,7 +27,7 @@ defineProps({
   width: 360px;
   height: 360px;
   border-radius: 10px;
-  padding: 20px 50px;
+  padding: 20px 0px;
   box-shadow: 0px 8px 32px 0px rgba(0, 0, 0, 0.16);
 }
 </style>

+ 6 - 2
pages/categories/index.vue

@@ -1,5 +1,9 @@
 <script lang='ts' setup>
-
+function scrollToCatalogs() {
+  const catalogs = document.getElementById('catalogs-list')
+  if (catalogs)
+    catalogs.scrollIntoView({ behavior: 'smooth', block: 'start' })
+}
 </script>
 
 <template>
@@ -11,7 +15,7 @@
             Discover, Download,<br>
             Delight!
           </h1>
-          <el-button class="mt-30px !bg-#fff !text-#9B6CFF !w-160px !h-40px !b-0px !b-rd-200px" round>
+          <el-button class="mt-30px !bg-#fff !text-#9B6CFF !w-160px !h-40px !b-0px !b-rd-200px" round @click="scrollToCatalogs">
             View Catalogs
           </el-button>
         </div>