react-bootstrap-table / react-bootstrap-table2

Next Generation of react-bootstrap-table
https://react-bootstrap-table.github.io/react-bootstrap-table2/
MIT License
1.27k stars 430 forks source link

Pagination: Different text/language #1790

Closed konrad111 closed 1 year ago

konrad111 commented 1 year ago

hello everyone,

in pagination we can have our own text for the buttons "nextPageText" etc. But what if i set "showTotal" to true? I will always get something like "Showing rows 1 to 10 of 16". I would prefer "1 to 10 / 16" or something in a different language. Is it possible to change?

Thanks in advance!

konrad111 commented 1 year ago

I just found a solution. In paginationFactory:

paginationTotalRenderer: pageInfo,

And the code:

const pageInfo = (from, to, size) => ( <span className="react-bootstrap-table-pagination-total"> <font size="2"> <b> {from} bis {to} / {size} </b> </font> </span> );