UNPKG

7.59 kBMarkdownView Raw
1## >= 9.0.0 (WIP)
2
3- Removed support for depecrated `extraAriaContext` (please use `ariaLabelBuilder` instead)
4
5## >= 8.0.0
6
7- Remove button role for links with an href (see: https://github.com/AdeleD/react-paginate/pull/390)
8- Add a rel attribute on previous page, current page and next page controls. They are respectivement customizable thanks to props `prevPageRel`, `selectedPageRel` and `nextPageRel`. To disable the rel attribute, set them to `null`. (see: https://github.com/AdeleD/react-paginate/pull/391)
9- A new prop `disabledLinkClassName` has been added. It allows to add a custom class on disabled `previous` and `next` controls. Default to `undefined` (no class added).
10- `tabindex` is now set to `-1` on disabled controls (disable previous/next buttons; active page button). (see: https://github.com/AdeleD/react-paginate/issues/219)
11- Add a warning when providing an `initialPage` prop value that is greater than the maximum page index from `pageCount` prop.
12- Add a warning when providing a `forcePage` prop value that is greater than the maximum page index from `pageCount` prop.
13- The `href` generated from `hrefBuilder` prop is now also set on active page control `<a>` tag. (see #242)
14- A new prop `hrefAllControls` has been added. It allows to enable `hrefBuilder` for all controls.
15- Fix page range of 2 when first page is selected. (see https://github.com/AdeleD/react-paginate/issues/307)
16- Fix the breaking algorithm to not create breaks for only one page (see: https://github.com/AdeleD/react-paginate/issues/270)
17
18## >= 7.1.5
19
20- Fix the Webpack build to work for both browser and Node (see: https://github.com/AdeleD/react-paginate/issues/389)
21- Add a warning when providing both `initialPage` and `forcePage` props. You should only provides `forcePage` when the component is [controlled](https://reactjs.org/docs/forms.html#controlled-components). (see: https://github.com/AdeleD/react-paginate/pull/290)
22
23## >= 7.1.4
24
25- A new prop `renderOnZeroPageCount` has been added. It allows to define what to display when `pageCount` is zero. By default, it lets the main pagination boxes be displayed (Previous / Next). To display nothing, just provides `renderOnZeroPageCount={null}`. (see: https://github.com/AdeleD/react-paginate/pull/377)
26- A new prop `className` has been added, which is an alias to `containerClassName` and is usefull for integration with CSS-in-JS frameworks like styled-components. (see: https://github.com/AdeleD/react-paginate/issues/321)
27- Fix the Webpack build by providing a `web` target (see: https://github.com/AdeleD/react-paginate/issues/317)
28- Add a warning when a non integer is provided for `pageCount`
29
30## >= 7.1.3
31
32- Remove react-hot-loader from production build.
33
34## >= 7.1.2
35
36- A new prop `pageLabelBuilder` has been added. It allows to customize pages labels of the component. By default, the page number is displayed (see: https://github.com/AdeleD/react-paginate/pull/334).
37
38## >= 7.1.1
39
40- Add an onPageActive callback (see: https://github.com/AdeleD/react-paginate/pull/349).
41
42## >= 7.1.0
43
44- Compatibility with React v17.0
45
46## >= 7.0.0
47
48- Add a rel attribute on previous/next buttons. Rel attributes are customizable thanks to props 'prevRel' and 'nextRel' (see: https://github.com/AdeleD/react-paginate/pull/326).
49- Upgrade devDependencies packages jest-cli and webpack-cli.
50
51## >= 6.5.0
52
53- Add a prop 'eventListener' to let users use a custom event listener on prev/next buttons, pages and break views.
54
55## >= 6.4.0
56
57- Two properties have been added to extend accessibility support (see https://github.com/AdeleD/react-paginate/pull/164).
58 - nextAriaLabel: defines the aria-label html property for the 'Next page' button (default: 'Next page').
59 - previousAriaLabel: defines the aria-label html property for the 'Previous page' button (default: 'Previous page').
60- Upgrade devDependencies packages (see: https://github.com/AdeleD/react-paginate/pull/314).
61
62## >= 6.3.2
63
64- Bump dependency 'mixin-deep' from 1.3.1 to 1.3.2 (see: https://github.com/AdeleD/react-paginate/pull/283).
65
66## >= 6.3.1
67
68- Handle 'forcePage' value if set from outside (see: https://github.com/AdeleD/react-paginate/pull/272).
69
70## >= 6.3.0
71
72- Add the ariaLabelBuilder feature to customize aria-label attributes (see: https://github.com/AdeleD/react-paginate/pull/260).
73
74## >= 6.2.1
75
76- Fix the breakLabel prop type in the BreakView component (see: https://github.com/AdeleD/react-paginate/pull/257).
77
78## >= 6.2.0
79
80- Add the breakLinkClassName prop.
81
82## >= 6.1.0
83
84- Add aria-disabled prop to anchors for accessibility (https://github.com/AdeleD/react-paginate/pull/254)
85- Setup eslint and prettier for dev
86
87## >= 6.0.0
88
89- Implement forward/backward jump when clicking on a breakview (ellipsis).
90- The 'breakLabel' prop should not receive an `<a>` tag anymore. Otherwise, a warning will appear in the JS console: `validateDOMNesting(...): <a> cannot appear as a descendant of <a>.`
91
92## >= 5.3.1
93
94- Tests improvements + fix package release (https://github.com/AdeleD/react-paginate/issues/245).
95
96## >= 5.3.0
97
98- Add the activeLinkClassName property.
99
100## >= 5.2.5
101
102- Upgrade webpack dev dependencies (Fix "Cannot read property 'properties' of undefined" from webpack-cli).
103
104## >= 5.2.4
105
106- Use ES6 export in react_components/index.js (https://github.com/AdeleD/react-paginate/pull/203).
107
108## >= 5.2.3
109
110- Add a role="button" on `<a>` tags to let screen readers know explicitly that links (without href) are intended to be interactive elements (https://github.com/AdeleD/react-paginate/issues/212).
111
112## >= 5.2.2
113
114- Remove the useless node_modules folder from the previous release (https://github.com/AdeleD/react-paginate/issues/208).
115
116## >= 5.2.1
117
118- Fix `disabledClassName` not used in previous and next classnames (https://github.com/AdeleD/react-paginate/issues/204).
119
120## >= 5.2.0
121
122- Delete the dependency on `react-addons-create-fragment`.
123- Delete the dependency on `classnames`.
124
125## >= 5.1.0
126
127- Refactor using destructuring.
128- Upgrade react-hot-loader to version 3.0.0 (dev dependency).
129
130## >= 5.0.0
131
132- Compatibility with React v16.0
133
134## >= 4.3.0
135
136- The HTML attribute `aria-label` has been added.
137- A new prop `extraAriaContext` allows to add some extra text to the end of the `aria-label` to provide additional context to the users.
138
139## >= 4.2.0
140
141- A new prop `hrefBuilder` has been added. It allows to add custom `href` attributes on `<a>` tags of the component.
142- Packages `react` and `react-addons-create-fragment` are now dependencies (see package.json).
143
144## >= 4.0.0
145
146- Some variable have been renamed:
147
148 - `clickCallback` -> `onPageChange`
149 - `initialSelected` -> `initialPage`
150 - `forceSelected` -> `forcePage`
151 - `pageNum` -> `pageCount`
152
153- `onClick` events have been moved on `<a>` tags (previously on `<li>`s).
154
155## >= 3.0.0
156
157`clickCallback` (`onPageChange`) isn't called during initialization anymore.
158
159## >= 1.0.0
160
161HTML Structure:
162
163```html
164<ul class="pagination">
165 <li class="disabled">
166 <a href="#"><span>«</span></a>
167 </li>
168 <li class="active"><a href="#">1</a></li>
169 <li><a href="#">2</a></li>
170 <li><a href="#">3</a></li>
171 <li><a href="#">4</a></li>
172 <li><a href="#">5</a></li>
173 <li>
174 <a href="#"><span>»</span></a>
175 </li>
176</ul>
177```
178
179## <= 0.5.7
180
181HTML Structure:
182
183```html
184<ul>
185 <li class="disabled">
186 <a href="#"><span>«</span></a>
187 </li>
188 <li>
189 <ul>
190 <li class="active"><a href="#">1</a></li>
191 <li><a href="#">2</a></li>
192 <li><a href="#">3</a></li>
193 <li><a href="#">4</a></li>
194 <li><a href="#">5</a></li>
195 </ul>
196 </li>
197 <li>
198 <a href="#"><span>»</span></a>
199 </li>
200</ul>
201```