Merge pull request #17292 from archy-bold/master

Definitions for react-paginate 4.3.
This commit is contained in:
Nathan Shively-Sanders
2017-06-20 13:15:27 -07:00
committed by GitHub
2 changed files with 11 additions and 2 deletions

View File

@@ -1,6 +1,9 @@
// Type definitions for react-paginate 4.2
// Type definitions for react-paginate 4.3
// Project: https://github.com/AdeleD/react-paginate
// Definitions by: Simon Hartcher <https://github.com/deevus>, Wouter Hardeman <https://github.com/wouterhardeman>, pegel03 <https://github.com/pegel03>
// Definitions by: Simon Hartcher <https://github.com/deevus>
// Wouter Hardeman <https://github.com/wouterhardeman>
// pegel03 <https://github.com/pegel03>
// Simon Archer <https://github.com/archy-bold>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// TypeScript Version: 2.1
@@ -111,6 +114,11 @@ interface ReactPaginateProps {
* The method is called to generate the href attribute value on tag a of each page element.
*/
hrefBuilder?(pageIndex: number): void;
/**
* Extra context to add to the aria-label HTML attribute.
*/
extraAriaContext?: string;
}
declare const ReactPaginate: React.ComponentClass<ReactPaginateProps>;

View File

@@ -26,6 +26,7 @@ class Test extends React.Component<{}, {}> {
nextLinkClassName={'next-a'}
disabledClassName={'disabled'}
hrefBuilder={(pageIndex: number) => null}
extraAriaContext={'aria'}
/>
);
}