Skip to content

Commit

Permalink
Add pagination component (#44)
Browse files Browse the repository at this point in the history
* Add pagination component

* Update README.md

* Add focus points to the snippets

* Update package version
  • Loading branch information
simonwhatley authored Jul 21, 2022
1 parent 1459c68 commit 435c512
Show file tree
Hide file tree
Showing 4 changed files with 53 additions and 1 deletion.
5 changes: 5 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,8 @@
# 1.8.0

- Added pagination component
- Fixed paragraph snippet

# 1.7.0

- Added notification banner component
Expand Down
2 changes: 2 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,8 @@ This extension for Visual Studio Code includes snippets to help in the building
|[Breadcrumbs](https://design-system.service.gov.uk/components/breadcrumbs/)|`govuk-breadcrumbs`||
|[Footer](https://design-system.service.gov.uk/components/footer/)|`govuk-footer`||
|[Header](https://design-system.service.gov.uk/components/header/)|`govuk-header`||
|[Pagination](https://design-system.service.gov.uk/components/pagination/)|`govuk-pagination`||
|[Previous/next navigation](https://design-system.service.gov.uk/components/pagination/)|`govuk-previous-next`||
|[Skip link](https://design-system.service.gov.uk/components/skip-link/)|`govuk-skip-link`||

## Dependencies
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "govuk-design-system-snippets",
"version": "1.7.0",
"version": "1.8.0",
"publisher": "simonwhatley",
"displayName": "GOV.UK Design System snippets",
"description": "GOV.UK Design System snippets for Nunjucks by Simon Whatley",
Expand Down
45 changes: 45 additions & 0 deletions snippets/snippets.json
Original file line number Diff line number Diff line change
Expand Up @@ -1021,5 +1021,50 @@
"}) }}$0"
],
"description": "Warning text – GOV.UK Design System"
},
"Pagination": {
"prefix": "govuk-pagination",
"body": [
"{{ govukPagination({",
"\tprevious: {",
"\t\thref: \"${1:#}\"",
"\t},",
"\tnext: {",
"\t\thref: \"${2:#}\"",
"\t},",
"\titems: [",
"\t\t{",
"\t\t\tnumber: 1,",
"\t\t\thref: \"#\"",
"\t\t},",
"\t\t{",
"\t\t\tnumber: 2,",
"\t\t\tcurrent: true,",
"\t\t\thref: \"#\"",
"\t\t},",
"\t\t{",
"\t\t\tnumber: 3,",
"\t\t\thref: \"#\"",
"\t\t}",
"\t]",
"}) }}$0"
],
"description": "Pagination – GOV.UK Design System"
},
"Previous/next navigation": {
"prefix": "govuk-previous-next",
"body": [
"{{ govukPagination({",
"\tprevious: {",
"\t\tlabelText: \"${1:Label text}\",",
"\t\thref: \"${2:#}\"",
"\t},",
"\tnext: {",
"\t\tlabelText: \"${3:Label text}\",",
"\t\thref: \"${4:#}\"",
"\t}",
"}) }}$0"
],
"description": "Previous/next navigation – GOV.UK Design System"
}
}

0 comments on commit 435c512

Please sign in to comment.