Skip to content

Commit 7d97951

Browse files
committed
review pagination
1 parent 27dd3cf commit 7d97951

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

packages/tdb-dashboard/src/components/DiffView.js

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -229,13 +229,14 @@ export const DiffView = ({diffs, CRObject, changePage, start,frames}) => {
229229
let page = Math.ceil(start/5)
230230
return <React.Fragment>
231231
{elements}
232+
{Array.isArray(diffs) && diffs.length> 0 &&
232233
<div className="w-100 d-flex justify-content-center">
233234
<Pagination size={"ls"}>
234235
<Pagination.Prev {...prevActive} />
235236
<Pagination.Item active>{`Page ${page+1} -- Diff from ${start+1} to ${lastDiff}`}</Pagination.Item>
236237
<Pagination.Next {...nextActive} />
237238
</Pagination>
238-
</div>
239+
</div>}
239240
</React.Fragment>
240241
}
241242

0 commit comments

Comments
 (0)