From 213c58e5c5157e18eda68f3ef840740a64cfd282 Mon Sep 17 00:00:00 2001 From: duanshuwen Date: Fri, 7 Nov 2025 21:15:28 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20=E8=B0=83=E6=95=B4=E7=9B=B8=E5=85=B3?= =?UTF-8?q?=E5=95=86=E5=93=81?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/SwipeCards/index.vue | 214 +++++++++++------- .../DetailCardGoodsContentList/index.vue | 2 +- 2 files changed, 130 insertions(+), 86 deletions(-) diff --git a/src/components/SwipeCards/index.vue b/src/components/SwipeCards/index.vue index db6c08a..4bb8745 100644 --- a/src/components/SwipeCards/index.vue +++ b/src/components/SwipeCards/index.vue @@ -1,13 +1,13 @@ @@ -163,15 +204,18 @@ function cardStyle(index, card) { height: 320px; display: flex; justify-content: center; - padding: 6px 6px 12px 6px; + padding: 6px 0 12px; + will-change: transform; // 启用硬件加速 } .card { position: absolute; - width: calc(100% - 12px); + width: 100%; height: calc(100% - 30px); border-radius: 20px; box-shadow: 0 8px 8px rgba(0, 0, 0, 0.08); background: #fff; + will-change: transform, opacity; // 启用硬件加速 + backface-visibility: hidden; // 减少重绘 } diff --git a/src/pages/index/components/module/DetailCardGoodsContentList/index.vue b/src/pages/index/components/module/DetailCardGoodsContentList/index.vue index 6e76781..d23a370 100644 --- a/src/pages/index/components/module/DetailCardGoodsContentList/index.vue +++ b/src/pages/index/components/module/DetailCardGoodsContentList/index.vue @@ -6,7 +6,7 @@