fix: [디자인QA] 슬라이드 인덱스 전환 시 영상이 처음부터 재생되도록 적용

This commit is contained in:
clkim
2025-12-03 15:43:21 +09:00
parent 73adfc9769
commit fd479483bb
15 changed files with 179 additions and 138 deletions

View File

@@ -19,7 +19,6 @@ const props = defineProps<Props>()
const { locale } = useI18n()
const { sendLog, useAnalyticsLogDataDirect } = useAnalytics()
const slideThumbnailRef = ref<any>(null)
const playingSlideIndex = ref<number | null>(null)
let stopVideoTimeoutId: ReturnType<typeof setTimeout> | null = null
@@ -65,7 +64,7 @@ const handleVideoClick = (index: number) => {
)
}
const stopVideo = () => {
const handleSplideMove = () => {
// 이전 타이머 정리
if (stopVideoTimeoutId) {
clearTimeout(stopVideoTimeoutId)
@@ -104,14 +103,13 @@ onBeforeUnmount(() => {
class="title-md max-w-[944px]"
/>
<BlocksSlideThumbnail
ref="slideThumbnailRef"
:thumbnail-data="slideData"
variant="media"
class="mt-[24px] md:mt-[32px]"
:pagination-data="paginationData"
:arrows="slideData.length > 5"
@move="stopVideo"
@arrow-click="onArrowClick"
@move="handleSplideMove"
>
<SplideSlide
v-for="(item, index) in slideData"