diff --git a/src/components/NodesTable/components/NodesTableBody/Rows/AuctionListRow.tsx b/src/components/NodesTable/components/NodesTableBody/Rows/AuctionListRow.tsx index 0d806c429..8ddf98184 100644 --- a/src/components/NodesTable/components/NodesTableBody/Rows/AuctionListRow.tsx +++ b/src/components/NodesTable/components/NodesTableBody/Rows/AuctionListRow.tsx @@ -3,6 +3,7 @@ import { useGetSort } from 'hooks'; import { NodeType, SortOrderEnum, WithClassnameType } from 'types'; import { AuctionListBaseRow } from './AuctionListBaseRow'; +import { AuctionListExpandRow } from './AuctionListExpandRow'; import { AuctionListTresholdRow } from './AuctionListTresholdRow'; export interface AuctionListRowUIType extends WithClassnameType { @@ -10,22 +11,44 @@ export interface AuctionListRowUIType extends WithClassnameType { showTresholdRow?: boolean; expandRowDetails?: ExpandRowDetailsType; index?: number; + showPosition?: boolean; } export const AuctionListRow = ({ nodeData, showTresholdRow, - index + index, + showPosition, + expandRowDetails }: AuctionListRowUIType) => { const { sort, order } = useGetSort(); const isSortDesc = sort === 'auctionPosition' && order === SortOrderEnum.desc; + const hasExpand = Boolean( + expandRowDetails?.qualifiedExpandPosition || + expandRowDetails?.dangerZoneExpandPosition || + expandRowDetails?.notQualifiedExpandPosition + ); + return ( <> {isSortDesc && showTresholdRow && ( )} - + {hasExpand && index && expandRowDetails ? ( + + ) : ( + + )} {!isSortDesc && showTresholdRow && ( )}