Skip to content

Commit

Permalink
Merge pull request #586 from belong112/feat/show-join-date#412
Browse files Browse the repository at this point in the history
feat(Profile page): show join date
  • Loading branch information
MrOrz authored Dec 18, 2024
2 parents 419a0d0 + 284b18a commit d5a4be4
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 0 deletions.
1 change: 1 addition & 0 deletions components/ProfilePage/ProfilePage.js
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,7 @@ const LOAD_USER = gql`
query LoadProfilePage($id: String, $slug: String) {
GetUser(id: $id, slug: $slug) {
id
createdAt
...UserHeaderData
contributions {
date
Expand Down
4 changes: 4 additions & 0 deletions components/ProfilePage/UserPageHeader.js
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ import Ribbon from 'components/Ribbon';
import LevelIcon from 'components/LevelIcon';
import LevelProgressBar from 'components/AppLayout/Widgets/LevelProgressBar';
import Avatar from 'components/AppLayout/Widgets/Avatar';
import TimeInfo from 'components/Infos/TimeInfo';
import Stats from './Stats';
import EditIcon from '@material-ui/icons/Edit';
import EditProfileDialog from './EditProfileDialog';
Expand Down Expand Up @@ -250,6 +251,9 @@ function UserPageHeader({ user, isSelf, stats }) {
{editButtonElem}
</Hidden>
</div>
<TimeInfo time={user.createdAt}>
{timeAgo => t`Join date : ${timeAgo}`}
</TimeInfo>
<div className={classes.progress}>
<LevelProgressBar user={user} />
<Typography variant="caption">
Expand Down
5 changes: 5 additions & 0 deletions i18n/zh_TW.po
Original file line number Diff line number Diff line change
Expand Up @@ -965,6 +965,11 @@ msgstr "編輯"
msgid "Cofacts chatbot"
msgstr "Cofacts 真的假的聊天機器人"

#: components/ProfilePage/UserPageHeader.js:256
#, javascript-format
msgid "Join date : ${ timeAgo }"
msgstr "註冊日期 : ${ timeAgo }"

#: components/ProfilePage/UserPageHeader.js:256
msgid "EXP"
msgstr "公道值"
Expand Down

0 comments on commit d5a4be4

Please sign in to comment.