Skip to content

Commit

Permalink
fix history
Browse files Browse the repository at this point in the history
  • Loading branch information
onnovisser committed Nov 15, 2023
1 parent c598211 commit b1487a6
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 12 deletions.
15 changes: 6 additions & 9 deletions centrifuge-app/src/components/Portfolio/Transactions.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,16 @@ import {
Stack,
Text,
usePagination,
VisualButton,
} from '@centrifuge/fabric'
import * as React from 'react'
import { Link } from 'react-router-dom'
import { TransactionTypeChip } from '../../components/Portfolio/TransactionTypeChip'
import { Spinner } from '../../components/Spinner'
import { formatDate } from '../../utils/date'
import { Dec } from '../../utils/Decimal'
import { getCSVDownloadUrl } from '../../utils/getCSVDownloadUrl'
import { usePools, useTransactionsByAddress } from '../../utils/usePools'
import { Column, DataTable, SortableTableHeader } from '../DataTable'
import { RouterLinkButton } from '../RouterLinkButton'

type TransactionsProps = {
onlyMostRecent?: boolean
Expand Down Expand Up @@ -170,13 +169,11 @@ export function Transactions({ onlyMostRecent, txTypes, address }: TransactionsP
page={pagination.page}
/>
{onlyMostRecent ? (
<Link to="/history">
<Box display="inline-block">
<VisualButton small variant="tertiary" icon={IconEye}>
View all
</VisualButton>
</Box>
</Link>
<Box display="inline-block">
<RouterLinkButton to="/history" small variant="tertiary" icon={IconEye}>
View all
</RouterLinkButton>
</Box>
) : (
<Shelf justifyContent="space-between">
{pagination.pageCount > 1 && (
Expand Down
6 changes: 3 additions & 3 deletions centrifuge-app/src/pages/Portfolio/TransactionHistory.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,13 @@ import * as React from 'react'
import { LayoutBase } from '../../components/LayoutBase'
import { BasePadding } from '../../components/LayoutBase/BasePadding'
import { Transactions } from '../../components/Portfolio/Transactions'
import { useAddress } from '../../utils/useAddress'

export default function TransactionHistoryPage() {
const address = useAddress()
return (
<LayoutBase>
<BasePadding>
<Transactions />
</BasePadding>
<BasePadding>{address ? <Transactions address={address} /> : null}</BasePadding>
</LayoutBase>
)
}

0 comments on commit b1487a6

Please sign in to comment.