diff options
author | lonkaars <l.leblansch@gmail.com> | 2021-03-14 15:07:51 +0100 |
---|---|---|
committer | lonkaars <l.leblansch@gmail.com> | 2021-03-14 15:07:51 +0100 |
commit | 8a9060d5dcdc67d14fb5b1b6e856d9ea39ffb618 (patch) | |
tree | eeaf0178fdc2e90e85f3f0f89d4272618ab0f4db /pages | |
parent | f6e46892723059efe3ad7666f94d476c7d350c2c (diff) |
friend count + dutch grammar on /user
Diffstat (limited to 'pages')
-rw-r--r-- | pages/user.tsx | 12 |
1 files changed, 10 insertions, 2 deletions
diff --git a/pages/user.tsx b/pages/user.tsx index c963550..01a2d23 100644 --- a/pages/user.tsx +++ b/pages/user.tsx @@ -290,7 +290,11 @@ export default function AccountPage() { return memberSince; })() }/> - <InfoModule icon={<PeopleOutlineOutlinedIcon/>} label="2 vrienden"/> + <InfoModule icon={<PeopleOutlineOutlinedIcon/>} label={(() => { + var label = user?.friends.toString() + " "; + label += user?.friends == 1 ? "vriend" : "vrienden"; + return label; + })()}/> <InfoModule icon={<Icon size={1} path={mdiEarth}/>} label="Nederland"/> </InfoSection> <InfoSection> @@ -298,7 +302,11 @@ export default function AccountPage() { <InfoModule icon={<Icon size={1} path={mdiEqual}/>} label={ gameInfo?.totals.draw + " keer gelijkspel" }/> <InfoModule icon={<ArrowDownwardOutlinedIcon style={{ color: "var(--disk-a-text)" }}/>} label={ gameInfo?.totals.lose + " keer verloren" }/> <InfoModule icon={<Icon size={1} path={mdiClipboardTextOutline}/>} label="Score: 400"/> - <InfoModule icon={<Icon size={1} path={mdiGamepadSquareOutline}/>} label={ gameInfo?.totals.games + " potjes" }/> + <InfoModule icon={<Icon size={1} path={mdiGamepadSquareOutline}/>} label={(() => { + var label = gameInfo?.totals.games.toString() + " "; + label += gameInfo?.totals.games == 1 ? "potje" : "potjes"; + return label; + })()}/> </InfoSection> <Vierkant> <RecentGames games={gameInfo?.games}/> |