Skip to content

Commit

Permalink
[fix] ✨ Fix translation for member page
Browse files Browse the repository at this point in the history
```
  • Loading branch information
steward379 committed Mar 4, 2024
1 parent b9a31d6 commit d37d86f
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
7 changes: 5 additions & 2 deletions public/locales/en-US/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -200,13 +200,13 @@
"member-center":"Member Center",
"welcome":"Welcome,",
"welcome-visit":"You are visiting:",
"member-map":"View Maps Board",
"member-map":"View Maps",
"follow": "Follow",
"cancel-follow":"UnFollow",
"member-owned-email":"Your Email:",
"change-photo":"Change Profile",
"change-username":"Change Username",
"save-profile-edit":"Save Profile",
"save-profile-edit":"Save",
"logout":"Logout",
"already-follow":"Following",
"followed-by":"Followed By",
Expand All @@ -224,6 +224,9 @@
"test-api-title":"Google Places API Test Page",
"fetch-places":"Fetch nearby places",
"fetch-no-results":"No Results Found",
"member-qualifier": "",
"edit-profile":"Edit Profile",
"cancel-edit-profile":"Cancel",


"":""
Expand Down
1 change: 1 addition & 0 deletions public/locales/zh-TW/common.json
Original file line number Diff line number Diff line change
Expand Up @@ -227,6 +227,7 @@
"test-api-title":"Google Places API 測試頁面",
"fetch-places":"抓取附近景點",
"fetch-no-results":"沒有任何景點",
"member-qualifier": "",


"":""
Expand Down
4 changes: 2 additions & 2 deletions src/pages/member/[userId].tsx
Original file line number Diff line number Diff line change
Expand Up @@ -338,7 +338,7 @@ const MemberPage = ({ initialMemberData }) => {
}
return (
<div>
<h3 className="text-lg font-semibold"><span> {list.length}</span> {title} </h3>
<h3 className="text-lg font-semibold"><span> {list.length}{t('member-qualifier')} </span> {title} </h3>
<div className="flex flex-wrap">
{list.map((userId) => (
userDetails[userId] && (
Expand Down Expand Up @@ -372,7 +372,7 @@ const MemberPage = ({ initialMemberData }) => {
src={memberData.avatar ? memberData.avatar : '/images/marker-icon.png' } width="100" height="100" />
</div>
<h3 className="text-lg font-medium px-2">
{user && user.uid === userId ? <span>{t('welcome')}</span> : <span>{t('welcome-visit')}</span>}
{user && user.uid === userId ? <span>{t('welcome')} </span> : <span>{t('welcome-visit')} </span>}
{memberData.name}
</h3>
</div>
Expand Down

1 comment on commit d37d86f

@vercel
Copy link

@vercel vercel bot commented on d37d86f Mar 4, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.