From 99dfd8a70a93bc02e7787785144c5037077c1e04 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?0o=E5=BC=A0=E4=B8=8D=E6=AD=AAo0?= Date: Fri, 24 Jun 2022 00:17:32 +0800 Subject: [PATCH] =?UTF-8?q?=F0=9F=90=9B(component):=20=F0=9F=90=9B(compone?= =?UTF-8?q?nt):=20=E4=BF=AE=E5=A4=8D=E8=BD=AE=E6=92=AD=E7=BB=84=E4=BB=B6?= =?UTF-8?q?=E7=94=B1=E4=BA=8EgetStyle=20Computed=E5=9C=A8=E7=BC=96?= =?UTF-8?q?=E8=AF=91=E4=B9=8B=E5=90=8E=E9=80=A0=E6=88=90=E7=9A=84=E9=94=99?= =?UTF-8?q?=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- package/component/src/component/carouselItem/index.vue | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/package/component/src/component/carouselItem/index.vue b/package/component/src/component/carouselItem/index.vue index 4099bbd1..8e6e685e 100644 --- a/package/component/src/component/carouselItem/index.vue +++ b/package/component/src/component/carouselItem/index.vue @@ -28,10 +28,10 @@ const getStyle = computed(() => { for (let index = 0; index < allChild.length; index++) { const element = allChild[index]; // @ts-ignore - if (element.__vnode.props["data-id"] === active.value) { + if (element.getAttribute("data-id") === active.value) { activeIndex = index; } - if (element.__vnode.props["data-id"] === props.id) { + if (element.getAttribute("data-id") === props.id) { currentIndex = index; } }