feat. ScrollTop 버튼 추가
This commit is contained in:
@@ -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>
|
||||
|
||||
Reference in New Issue
Block a user