Feat(WEB-359): Update section link for mobile Approved-by: Chuma Mcphoy (We Ahead) Approved-by: Arvid Norlin
30 lines
886 B
TypeScript
30 lines
886 B
TypeScript
import { serverClient } from "@/lib/trpc/server"
|
|
|
|
import SectionContainer from "@/components/Section/Container"
|
|
import SectionHeader from "@/components/Section/Header"
|
|
import SectionLink from "@/components/Section/Link"
|
|
|
|
import ClientEarnAndBurn from "./Client"
|
|
|
|
import type { AccountPageComponentProps } from "@/types/components/myPages/myPage/accountPage"
|
|
|
|
export default async function EarnAndBurn({
|
|
lang,
|
|
link,
|
|
subtitle,
|
|
title,
|
|
}: AccountPageComponentProps) {
|
|
const initialTransactions =
|
|
await serverClient().user.transaction.friendTransactions({ limit: 5 })
|
|
if (!initialTransactions) {
|
|
return null
|
|
}
|
|
return (
|
|
<SectionContainer>
|
|
<SectionHeader title={title} link={link} subtitle={subtitle} />
|
|
<ClientEarnAndBurn initialData={initialTransactions} lang={lang} />
|
|
<SectionLink link={link} variant="mobile" />
|
|
</SectionContainer>
|
|
)
|
|
}
|