Skip to content

Commit

Permalink
match
Browse files Browse the repository at this point in the history
  • Loading branch information
ingawei committed Jul 31, 2024
1 parent 9565104 commit 999b6ff
Showing 1 changed file with 16 additions and 2 deletions.
18 changes: 16 additions & 2 deletions web/components/portfolio/portfolio-summary.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -28,12 +28,26 @@ export const PortfolioSummary = (props: { user: User; className?: string }) => {
{TWOMBA_ENABLED ? (
<TwombaPortfolioValueSection
user={user}
defaultTimePeriod={currentUser?.id === user.id ? 'weekly' : 'monthly'}
defaultTimePeriod={
isCreatedInLastWeek
? 'allTime'
: currentUser?.id === user.id
? 'weekly'
: 'monthly'
}
portfolio={portfolioData}
/>
) : (
<PortfolioValueSection
user={user}
defaultTimePeriod={currentUser?.id === user.id ? 'weekly' : 'monthly'}
defaultTimePeriod={
isCreatedInLastWeek
? 'allTime'
: currentUser?.id === user.id
? 'weekly'
: 'monthly'
}
portfolio={portfolioData}
/>
)}

Expand Down

0 comments on commit 999b6ff

Please sign in to comment.