Files
webapp/app/components/PaginationLoadMore.vue
Ruslan Bakiev 479412d901
All checks were successful
Build Docker Image / build (push) Successful in 5m27s
Hide duplicate counter in pagination when search bar is present
Add hideCounter prop to PaginationLoadMore and use it on hubs page
2026-01-14 12:57:58 +07:00

32 lines
639 B
Vue

<template>
<Stack v-if="total > 0" gap="2" align="center" justify="center">
<Text v-if="!hideCounter" tone="muted">
{{ t('common.pagination.showing', { shown, total }) }}
</Text>
<Button
v-if="canLoadMore"
variant="outline"
@click="$emit('load-more')"
:disabled="loading"
>
{{ t('common.actions.load_more') }}
</Button>
</Stack>
</template>
<script setup lang="ts">
const props = defineProps<{
shown: number
total: number
canLoadMore: boolean
loading?: boolean
hideCounter?: boolean
}>()
defineEmits<{
(e: 'load-more'): void
}>()
const { t } = useI18n()
</script>