From 6c114c6f1492bc56aa04987e6eee31c1c21fa4b5 Mon Sep 17 00:00:00 2001 From: Ayo Date: Sat, 21 Jan 2023 20:00:48 +0100 Subject: [PATCH] refactor: don't pass down context --- components/common/CommonPaginator.vue | 6 ++---- components/timeline/TimelinePaginator.vue | 2 +- composables/paginator.ts | 7 +++---- composables/timeline.ts | 2 +- 4 files changed, 7 insertions(+), 10 deletions(-) diff --git a/components/common/CommonPaginator.vue b/components/common/CommonPaginator.vue index 2961a7e7..1ef7dd70 100644 --- a/components/common/CommonPaginator.vue +++ b/components/common/CommonPaginator.vue @@ -11,15 +11,13 @@ const { virtualScroller = false, eventType = 'update', preprocess, - context = 'public', } = defineProps<{ paginator: Paginator keyProp?: keyof T virtualScroller?: boolean stream?: Promise eventType?: 'notification' | 'update' - preprocess?: (items: (U | T)[], context?: mastodon.v2.FilterContext) => U[] - context?: mastodon.v2.FilterContext + preprocess?: (items: (U | T)[]) => U[] }>() defineSlots<{ @@ -44,7 +42,7 @@ defineSlots<{ const { t } = useI18n() -const { items, prevItems, update, state, endAnchor, error } = usePaginator(paginator, $$(stream), eventType, preprocess, context) +const { items, prevItems, update, state, endAnchor, error } = usePaginator(paginator, $$(stream), eventType, preprocess)