1
0
mirror of https://github.com/elk-zone/elk synced 2024-12-20 01:28:01 +09:00
elk/components/notification/NotificationPaginator.client.vue

19 lines
529 B
Vue
Raw Normal View History

2022-11-16 06:21:54 +09:00
<script setup lang="ts">
import type { Notification, Paginator } from 'masto'
const { paginator } = defineProps<{
paginator: Paginator<any, Notification[]>
}>()
2022-11-17 01:11:08 +09:00
const { items: notifications, state, endAnchor } = usePaginator(paginator)
2022-11-16 06:21:54 +09:00
</script>
<template>
2022-11-17 01:11:08 +09:00
<CommonPaginator :state="state">
<template v-for="notification of notifications" :key="notification.id">
<NotificationCard :notification="notification" border="t border" pt-4 />
</template>
<div ref="endAnchor" />
</CommonPaginator>
2022-11-16 06:21:54 +09:00
</template>