diff --git a/apps/explorer/src/app/components/txs/tx-list-navigation.spec.tsx b/apps/explorer/src/app/components/txs/tx-list-navigation.spec.tsx index d08d3da52..c0a70bf1c 100644 --- a/apps/explorer/src/app/components/txs/tx-list-navigation.spec.tsx +++ b/apps/explorer/src/app/components/txs/tx-list-navigation.spec.tsx @@ -61,53 +61,4 @@ describe('TxsListNavigation', () => { expect(nextPageMock).toHaveBeenCalledTimes(1); }); - - it('disables "Older" button if hasMoreTxs is false', () => { - render( - - - - ); - - expect(screen.getByText('Older')).toBeDisabled(); - }); - - it('disables "Newer" button if hasPreviousPage is false', () => { - render( - - - - ); - - expect(screen.getByText('Newer')).toBeDisabled(); - }); - - it('disables both buttons when more and previous are false', () => { - render( - - - - ); - - expect(screen.getByText('Newer')).toBeDisabled(); - expect(screen.getByText('Older')).toBeDisabled(); - }); }); diff --git a/apps/explorer/src/app/components/txs/tx-list-navigation.tsx b/apps/explorer/src/app/components/txs/tx-list-navigation.tsx index 50ae37035..ff89aea52 100644 --- a/apps/explorer/src/app/components/txs/tx-list-navigation.tsx +++ b/apps/explorer/src/app/components/txs/tx-list-navigation.tsx @@ -10,7 +10,8 @@ export interface TxListNavigationProps { loading?: boolean; hasPreviousPage: boolean; hasMoreTxs: boolean; - children: React.ReactNode; + children?: React.ReactNode; + isEmpty?: boolean; } /** * Displays a list of transactions with filters and controls to navigate through the list. @@ -21,9 +22,8 @@ export const TxsListNavigation = ({ refreshTxs, nextPage, previousPage, - hasMoreTxs, - hasPreviousPage, children, + isEmpty, loading = false, }: TxListNavigationProps) => { return ( @@ -35,7 +35,6 @@ export const TxsListNavigation = ({