This repository was archived by the owner on Aug 29, 2025. It is now read-only.
File tree Expand file tree Collapse file tree 3 files changed +9
-8
lines changed Expand file tree Collapse file tree 3 files changed +9
-8
lines changed Original file line number Diff line number Diff line change @@ -903,11 +903,11 @@ export default class ControlledTable extends PureComponent<ControlledTableProps>
903
903
>
904
904
</ input >
905
905
906
- { lastPage !== undefined ? ' / ' : '' }
906
+ { lastPage ? ' / ' : '' }
907
907
908
- < div className = 'last-page' >
909
- { lastPage !== undefined ? lastPage + 1 : '' }
910
- </ div >
908
+ { lastPage ? < div className = 'last-page' >
909
+ { lastPage ? lastPage + 1 : '' }
910
+ </ div > : '' }
911
911
</ div >
912
912
913
913
< button
@@ -920,7 +920,7 @@ export default class ControlledTable extends PureComponent<ControlledTableProps>
920
920
< button
921
921
className = 'last-page'
922
922
onClick = { this . loadLast }
923
- disabled = { this . props . page_current === lastPage || lastPage === undefined } >
923
+ disabled = { this . props . page_current === lastPage || ! lastPage } >
924
924
< FontAwesomeIcon icon = 'angle-double-right' />
925
925
</ button >
926
926
</ div >
Original file line number Diff line number Diff line change @@ -161,7 +161,7 @@ input.current-page, input.current-page::placeholder {
161
161
color : black ;
162
162
border : none ;
163
163
width :30px ;
164
- text-align :right ;
164
+ text-align :center ;
165
165
font-family : monospace ;
166
166
font-size : 10pt ;
167
167
margin : 0.5em ;
@@ -170,6 +170,7 @@ input.current-page, input.current-page::placeholder {
170
170
.page-number > .last-page {
171
171
min-width : 30px ;
172
172
display : inline-block ;
173
+ text-align : center ;
173
174
margin : 0.5em ;
174
175
}
175
176
Original file line number Diff line number Diff line change @@ -44,7 +44,7 @@ function getBackEndPagination(
44
44
setProps ( { page_current, ...clearSelection } ) ;
45
45
} ,
46
46
loadLast : ( ) => {
47
- if ( max_page_count !== undefined ) {
47
+ if ( max_page_count ) {
48
48
page_current = max_page_count ;
49
49
setProps ( { page_current, ...clearSelection } ) ;
50
50
}
@@ -66,7 +66,7 @@ function getBackEndPagination(
66
66
return ;
67
67
}
68
68
69
- if ( max_page_count !== undefined && page > max_page_count ) {
69
+ if ( max_page_count && page > max_page_count ) {
70
70
page_current = max_page_count ;
71
71
setProps ( { page_current, ...clearSelection } ) ;
72
72
return ;
You can’t perform that action at this time.
0 commit comments