primevue-mirror/doc/scrolltop/BasicDoc.vue

50 lines
1.4 KiB
Vue
Raw Normal View History

2023-02-28 08:29:30 +00:00
<template>
<DocSectionText v-bind="$attrs">
<p>ScrollTop listens window scroll by default.</p>
</DocSectionText>
2024-05-20 12:14:38 +00:00
<div class="card flex flex-col items-center">
2023-02-28 08:29:30 +00:00
<p>Scroll down the page to display the ScrollTop component.</p>
2024-05-20 12:14:38 +00:00
<i class="pi pi-angle-down animate-fadeout animate-duration-1000 animate-infinite" style="fontsize: 2rem; margin-bottom: 30rem"></i>
2023-02-28 08:29:30 +00:00
<ScrollTop />
</div>
<DocSectionCode :code="code" />
</template>
<script>
export default {
data() {
return {
code: {
2023-09-22 12:54:14 +00:00
basic: `
2023-10-15 09:38:39 +00:00
<ScrollTop />
`,
2023-09-22 12:54:14 +00:00
options: `
<template>
2024-05-20 12:14:38 +00:00
<div class="card flex flex-col items-center" style="height: 2000px">
2023-02-28 08:29:30 +00:00
<p>Scroll down the page to display the ScrollTop component.</p>
2024-05-20 12:14:38 +00:00
<i class="pi pi-angle-down animate-fadeout animate-duration-1000 animate-infinite" style="fontsize: 2rem"></i>
2023-02-28 08:29:30 +00:00
<ScrollTop />
</div>
</template>
<script>
2023-10-15 09:38:39 +00:00
<\/script>
`,
2023-09-22 12:54:14 +00:00
composition: `
<template>
2024-05-20 12:14:38 +00:00
<div class="card flex flex-col items-center" style="height: 2000px">
2023-02-28 08:29:30 +00:00
<p>Scroll down the page to display the ScrollTop component.</p>
2024-05-20 12:14:38 +00:00
<i class="pi pi-angle-down animate-fadeout animate-duration-1000 animate-infinite" style="fontsize: 2rem"></i>
2023-02-28 08:29:30 +00:00
<ScrollTop />
</div>
</template>
<script setup>
2023-10-15 09:38:39 +00:00
<\/script>
`
2023-02-28 08:29:30 +00:00
}
};
}
};
</script>