Skip to content
Snippets Groups Projects
Commit 18d336e7 authored by Trirst's avatar Trirst
Browse files

Style pagination bar

parent 0e4881a3
No related branches found
No related tags found
No related merge requests found
......@@ -3,7 +3,11 @@
<button
v-for="(page, index) in pages"
:key="index"
class="mr-2 last:mr-0"
class="mr-2 last:mr-0 text-lg"
:class="{
'text-red-800': page === currentPage,
'font-bold': page === currentPage,
}"
@click="$emit('onPageChange', page)"
>
{{ page }}
......@@ -30,7 +34,7 @@ export default {
// 1 ... 3 [4] 5 ... 12 (4 is the selected page)
// [1] 2 ... 12
// 1 2 [3] 4 ... 12
// The bar always shows the first and last pages, the selected page and 2 pages
// The bar always shows the first and last pages, the selected page and 2 pages
// that are offset by 1 to the selected page
pages: function () {
return [
......@@ -45,4 +49,4 @@ export default {
},
},
};
</script>
\ No newline at end of file
</script>
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment