diff --git a/packages/explorer-2.0/components/CampaignView/index.tsx b/packages/explorer-2.0/components/CampaignView/index.tsx index 9c424245b..16e1f2390 100644 --- a/packages/explorer-2.0/components/CampaignView/index.tsx +++ b/packages/explorer-2.0/components/CampaignView/index.tsx @@ -3,8 +3,11 @@ import * as Utils from 'web3-utils' import Card from '../Card' import { abbreviateNumber } from '../../lib/utils' import { Box } from 'theme-ui' +import { MdCheck, MdClose } from 'react-icons/md' +import ReactTooltip from 'react-tooltip' +import Help from '../../public/img/help.svg' -export default ({ transcoder }) => { +export default ({ currentRound, transcoder }) => { const callsMade = transcoder.pools.filter(r => r.rewardTokens != null).length return ( @@ -119,6 +122,59 @@ export default ({ transcoder }) => { } /> + + Last Reward Round + + + + + + } + subtitle={ + + + {transcoder.lastRewardRound.id}{' '} + {transcoder.active && ( + + {transcoder.lastRewardRound.id === currentRound.id ? ( + + ) : ( + + )} + + )} + + + } + /> diff --git a/packages/explorer-2.0/components/HistoryView/index.tsx b/packages/explorer-2.0/components/HistoryView/index.tsx index 6d284d713..9abd20827 100644 --- a/packages/explorer-2.0/components/HistoryView/index.tsx +++ b/packages/explorer-2.0/components/HistoryView/index.tsx @@ -61,26 +61,30 @@ export default () => { sx={{ overflow: 'hidden !important' }} scrollThreshold={0.5} dataLength={data && data.transactions.length} - next={() => { + next={async () => { stopPolling() if (!loading && data.transactions.length >= 10) { - fetchMore({ - variables: { - skip: data.transactions.length, - }, - updateQuery: (previousResult: any, { fetchMoreResult }: any) => { - if (!fetchMoreResult) { - return previousResult - } - return { - ...previousResult, - transactions: [ - ...previousResult.transactions, - ...fetchMoreResult.transactions, - ], - } - }, - }) + try { + await fetchMore({ + variables: { + skip: data.transactions.length, + }, + updateQuery: (previousResult: any, { fetchMoreResult }: any) => { + if (!fetchMoreResult) { + return previousResult + } + return { + ...previousResult, + transactions: [ + ...previousResult.transactions, + ...fetchMoreResult.transactions, + ], + } + }, + }) + } catch (e) { + return e + } } }} hasMore={true} diff --git a/packages/explorer-2.0/pages/accounts/[account]/[slug].tsx b/packages/explorer-2.0/pages/accounts/[account]/[slug].tsx index ab72c12ce..4610b1dad 100644 --- a/packages/explorer-2.0/pages/accounts/[account]/[slug].tsx +++ b/packages/explorer-2.0/pages/accounts/[account]/[slug].tsx @@ -155,7 +155,12 @@ const Account = () => { transcoder={data.transcoder} /> - {slug == 'campaign' && } + {slug == 'campaign' && ( + + )} {slug == 'fees' && (