Skip to content

Commit d370019

Browse files
committed
feat: enhance pagination documentation with customization options and spacing adjustments
1 parent 4763b9c commit d370019

File tree

1 file changed

+35
-2
lines changed

1 file changed

+35
-2
lines changed

docs/components/pagination.md

Lines changed: 35 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -37,11 +37,44 @@ import { Pagination as CarouselPagination } from 'vue3-carousel'
3737
| --------------------------- | ------------------------- | ---------------------------------- |
3838
| `--vc-pgn-active-color` | `var(--vc-clr-primary)` | Active pagination button color |
3939
| `--vc-pgn-background-color` | `var(--vc-clr-secondary)` | Pagination button background color |
40-
| `--vc-pgn-border-radius` | `0` | Pagination button border radius |
40+
| `--vc-pgn-border-radius` | `10px` | Pagination button border radius |
41+
| `--vc-pgn-gap` | `6px` | Gap between pagination buttons |
4142
| `--vc-pgn-height` | `4px` | Pagination button height |
42-
| `--vc-pgn-margin` | `6px 5px` | Pagination button margin |
43+
| `--vc-png-bottom` | `10px` | Bottom spacing for pagination |
44+
| `--vc-png-left` | `10px` | Left spacing for vertical mode |
45+
| `--vc-png-right` | `10px` | Right spacing for vertical mode |
4346
| `--vc-pgn-width` | `16px` | Pagination button width |
4447

48+
### Customization Examples
49+
50+
There are two ways to customize the pagination appearance:
51+
52+
#### 1. Using CSS Custom Properties
53+
54+
```css
55+
.carousel {
56+
--vc-pgn-background-color: white;
57+
--vc-pgn-active-color: red;
58+
--vc-pgn-border-radius: 5px;
59+
--vc-pgn-height: 5px;
60+
--vc-pgn-width: 5px;
61+
}
62+
```
63+
64+
#### 2. Direct CSS Override
65+
66+
```css
67+
.carousel__pagination-button {
68+
height: 5px;
69+
width: 5px;
70+
border-radius: 5px;
71+
background-color: white;
72+
}
73+
.carousel__pagination-button--active {
74+
background-color: red;
75+
}
76+
```
77+
4578
## Accessibility
4679

4780
- Pagination buttons are properly labeled for screen readers

0 commit comments

Comments
 (0)