add page selector

This commit is contained in:
Mutasem 2022-04-06 13:46:39 +02:00
parent 6705afbf08
commit f24064ceb9

View file

@ -190,6 +190,18 @@
layout="prev, pager, next" layout="prev, pager, next"
:total="dataCount"> :total="dataCount">
</el-pagination> </el-pagination>
<div :class="$style.pageSizeSelector">
<n8n-select size="mini" v-model="pageSize">
<template slot="prepend">{{ $locale.baseText('node.output.items') }}</template>
<n8n-option
v-for="size in pageSizes"
:key="size"
:label="size"
:value="size">
</n8n-option>
</n8n-select>
</div>
</div> </div>
</div> </div>
@ -274,6 +286,7 @@ export default mixins(
MAX_DISPLAY_ITEMS_AUTO_ALL, MAX_DISPLAY_ITEMS_AUTO_ALL,
currentPage: 1, currentPage: 1,
pageSize: 10, pageSize: 10,
pageSizes: [10, 25, 50, 100],
}; };
}, },
mounted() { mounted() {
@ -868,6 +881,7 @@ export default mixins(
width: 100%; width: 100%;
display: flex; display: flex;
justify-content: center; justify-content: center;
align-items: center;
bottom: 0; bottom: 0;
padding: 5px; padding: 5px;
} }
@ -934,6 +948,11 @@ export default mixins(
word-wrap: break-word; word-wrap: break-word;
} }
.pageSizeSelector {
text-transform: capitalize;
max-width: 120px;
}
</style> </style>
<style lang="scss"> <style lang="scss">