Skip to content

Commit

Permalink
feat: fix pagination for fills (#5228)
Browse files Browse the repository at this point in the history
* feat: fix pagination for fills

* fix: remove unnecessary tag
  • Loading branch information
anxolin authored Dec 19, 2024
1 parent 9b57e6c commit 9563df4
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ type Props = {
}

export const FillsTableWithData: React.FC<Props> = ({ areTokensLoaded, order, isPriceInverted, invertPrice }) => {
const { trades, tableState } = useContext(FillsTableContext)
const { data: trades, tableState } = useContext(FillsTableContext)
const isFirstRender = useFirstRender()

return isFirstRender || !areTokensLoaded ? (
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ import { Trade } from 'api/operator'
import { TableState, TableStateSetters } from '../../../../explorer/components/TokensTableWidget/useTable'

type CommonState = {
trades: Trade[]
data: Trade[]
isLoading: boolean
tableState: TableState
} & TableStateSetters
Expand Down
4 changes: 2 additions & 2 deletions apps/explorer/src/components/orders/OrderDetails/index.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@ export type Props = {

export enum TabView {
OVERVIEW = 1,
FILLS,
FILLS = 2,
}

const DEFAULT_TAB = TabView[1]
Expand Down Expand Up @@ -225,7 +225,7 @@ export const OrderDetails: React.FC<Props> = (props) => {
))}
<FillsTableContext.Provider
value={{
trades,
data: trades,
isLoading: areTradesLoading,
tableState,
setPageSize,
Expand Down

0 comments on commit 9563df4

Please sign in to comment.