feat. ScrollTop 버튼 추가

This commit is contained in:
clkim
2025-10-24 13:08:18 +09:00
parent 3729a2bcb7
commit 34605d606a
9 changed files with 226 additions and 10 deletions

View File

@@ -12,6 +12,8 @@ interface Props {
const props = defineProps<Props>()
const mainRef = ref<HTMLElement>()
// 템플릿 레지스트리 사용
const { getTemplateComponent } = useTemplateRegistry()
@@ -54,7 +56,7 @@ watchEffect(() => {
</script>
<template>
<main class="main">
<main ref="mainRef" class="main">
<template
v-for="(template, index) in visibleTemplates"
:key="template.template_code ?? index"
@@ -65,11 +67,15 @@ watchEffect(() => {
:page-ver-tmpl-seq="template.page_ver_tmpl_seq"
/>
</template>
<AtomsButtonScrollTop
v-if="pageData.use_top_btn ?? false"
:parent-ref="mainRef"
/>
</main>
</template>
<style scoped>
.main {
@apply pt-[48px] md:pt-[64px];
@apply relative pt-[48px] md:pt-[64px];
}
</style>