D3vugu-components/components/navigation/pagination.vugu
David Vogel e722ae1d2b Add pagination component
- Add and update example pages
- Add example address component
- Add vugu data tags to struct fields
- Fix some button padding values
- Remove debug log line
- Fix background color of the sidebar menu
2023-05-16 18:10:24 +02:00

53 lines
1.4 KiB
Plaintext

<div vg-attr='utils.AttributesAppend{AttrMap: c.AttrMap, Classes: "d3c-1684167638"}'>
<button @click="c.handleClickPrev(event)"><icons:LChevronLeft></icons:LChevronLeft></button>
<button @click="c.handleClickNext(event)"><icons:LChevronRight></icons:LChevronRight></button>
<button vg-for='_, button := range c.buttons' :class="button.Class" vg-content="button.Page" @click="c.handleClickPage(event, button.Page)"></button>
</div>
<style>
.d3c-1684167638 {
display: flex;
flex-wrap: wrap;
gap: 0.5em;
margin: 0.5em 0;
/*border-radius: 4px;
border: 1px solid RGBA(127, 127, 127, 0.2);*/
/*width: min-content;*/
overflow: hidden;
}
.d3c-1684167638 button {
padding: 0;
background-color: white;
white-space: nowrap;
font-size: 1em;
font-family: "Segoe UI", sans-serif;
border-radius: 4px;
border: 1px solid RGBA(127, 127, 127, 0.2);
background-color: white;
user-select: none;
min-width: 2em;
height: 2em;
}
.d3c-1684167638 button:hover {
background-color: RGBA(127, 127, 127, 0.1);
}
.d3c-1684167638 button:active {
background-color: RGBA(127, 127, 127, 0.2);
}
.d3c-1684167638-selected {
background-color: RGBA(64, 100, 188, 1) !important;
color: white;
}
</style>
<script type="application/x-go">
import (
"git.d3nexus.de/Dadido3/D3vugu-components/icons"
"git.d3nexus.de/Dadido3/D3vugu-components/utils"
)
</script>