Browse Source

chore(gui-v2): update pagination margin

pull/3023/head
braks 2 years ago
parent
commit
7699bff550
  1. 29
      packages/nc-gui-v2/components/smartsheet/Pagination.vue
  2. 3
      packages/nc-gui-v2/pages/nc/[projectId]/index/index.vue

29
packages/nc-gui-v2/components/smartsheet/Pagination.vue

@ -15,37 +15,10 @@ const page = computed({
get: () => paginatedData?.value?.page ?? 1,
set: (p) => changePage?.(p),
})
/*
export default {
name: 'Pagination',
props: {
count: [Number, String],
value: [Number, String],
size: [Number, String],
},
data: () => ({
page: 1,
}),
watch: {
value(v) {
this.page = v
},
count(c) {
const page = Math.max(1, Math.min(this.page, Math.ceil(c / this.size)))
if (this.value !== page) {
this.$emit('input', page)
}
},
},
mounted() {
this.page = this.value
},
}
*/
</script>
<template>
<div class="flex items-center mb-2">
<div class="flex items-center">
<span v-if="count !== null && count !== Infinity" class="caption ml-2"> {{ count }} record{{ count !== 1 ? 's' : '' }} </span>
<div class="flex-1" />

3
packages/nc-gui-v2/pages/nc/[projectId]/index/index.vue

@ -129,7 +129,7 @@ function openQuickImportDialog(type: string) {
</a-tabs>
</div>
<NuxtPage class="px-4 py-2" />
<NuxtPage class="px-4 pt-2" />
</div>
<DlgTableCreate v-if="tableCreateDialog" v-model="tableCreateDialog" />
@ -140,6 +140,7 @@ function openQuickImportDialog(type: string) {
<style scoped>
.nc-container {
height: calc(100% - var(--header-height));
flex: 1 1 100%;
}

Loading…
Cancel
Save