Skip to content

Commit 8e3e351

Browse files
toadkickertmorehouse
authored andcommitted
docs(pagination): update documentation/package.json regarding slot definitions (#2160)
1 parent e0e1eee commit 8e3e351

File tree

3 files changed

+65
-9
lines changed

3 files changed

+65
-9
lines changed

src/components/pagination-nav/README.md

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -182,6 +182,18 @@ Ellipsis indicator(s) will only be ever shown at the front and/or end of
182182
the page number buttons. For `limit` values less than or equal to `3`, the ellipsis
183183
indicator(s) will never be shown for practical display reasons.
184184

185+
### Named slots
186+
187+
`<b-pagination-nav>` supports several slots that allow you to customize the appearance.
188+
189+
| Slot | Description
190+
|----- | -----------
191+
| `first-text` | The "goto first page" button text (html/sub-components supported)
192+
| `prev-text` | The "goto previous page" button text (html/sub-components supported)
193+
| `next-text` | The "goto next page" button text (html/sub-components supported)
194+
| `last-text` | The "goto last page" button text (html/sub-components supported)
195+
| `ellipsis-text` | the `...` indicator text (html/sub-components supported)
196+
185197
## Alignment
186198

187199
By default the pagination component is left aligned. Change the alignment to

src/components/pagination-nav/package.json

Lines changed: 23 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,28 @@
33
"version": "1.0.0",
44
"meta": {
55
"title": "Pagination Nav",
6-
"component": "bPaginationNav"
6+
"component": "bPaginationNav",
7+
"slots": [
8+
{
9+
"title": "first-text",
10+
"description": "The \"goto first page\" button text (html/sub-components supported)"
11+
},
12+
{
13+
"title": "prev-text",
14+
"description": "The \"goto previous page\" button text (html/sub-components supported)"
15+
},
16+
{
17+
"title": "next-text",
18+
"description": "The \"goto next page\" button text (html/sub-components supported)"
19+
},
20+
{
21+
"title": "last-text",
22+
"description": "The \"goto last page\" button text (html/sub-components supported)"
23+
},
24+
{
25+
"title": "ellipsis-text",
26+
"description": " | the `...` indicator text (html/sub-components supported)"
27+
}
28+
]
729
}
830
}

src/components/pagination/package.json

Lines changed: 30 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,14 +16,36 @@
1616
]
1717
},
1818
{
19-
"event": "change",
20-
"description": "when page changes via user interaction",
21-
"args": [
22-
{
23-
"arg": "page",
24-
"description": "Selected page number (starting with 1)"
25-
}
26-
]
19+
"event": "change",
20+
"description": "when page changes via user interaction",
21+
"args": [
22+
{
23+
"arg": "page",
24+
"description": "Selected page number (starting with 1)"
25+
}
26+
]
27+
}
28+
],
29+
"slots": [
30+
{
31+
"title": "first-text",
32+
"description": "The \"goto first page\" button text (html/sub-components supported)"
33+
},
34+
{
35+
"title": "prev-text",
36+
"description": "The \"goto previous page\" button text (html/sub-components supported)"
37+
},
38+
{
39+
"title": "next-text",
40+
"description": "The \"goto next page\" button text (html/sub-components supported)"
41+
},
42+
{
43+
"title": "last-text",
44+
"description": "The \"goto last page\" button text (html/sub-components supported)"
45+
},
46+
{
47+
"title": "ellipsis-text",
48+
"description": " | the `...` indicator text (html/sub-components supported)"
2749
}
2850
]
2951
}

0 commit comments

Comments
 (0)