Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Development #394

Open
wants to merge 360 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
360 commits
Select commit Hold shift + click to select a range
b21babb
feat: not showing user massage in notificaiton email
pauljaijai Jan 16, 2024
e75a26d
test: temp remove test
pauljaijai Jan 16, 2024
67abfd1
feat: mobile friendly main page ui (#303)
Pjaijai Jan 17, 2024
0733715
style: update char message card ui (#304)
Pjaijai Jan 17, 2024
fc722ca
test: fix message card test
pauljaijai Jan 17, 2024
8daa050
Feature/mobile menu (#305)
marukosy124 Jan 20, 2024
1331934
Merge branch 'development' of https://github.com/Pjaijai/Referalah in…
pauljaijai Jan 20, 2024
4b32381
Feature/translation (#306)
Pjaijai Jan 20, 2024
4361f44
Merge branch 'development' of https://github.com/Pjaijai/Referalah in…
pauljaijai Jan 20, 2024
17e1bc4
Feature/mobile no message handling (#307)
Pjaijai Jan 21, 2024
19d5c8e
fix: fix password email invalid text
pauljaijai Jan 21, 2024
ffa172f
Merge branch 'development' of https://github.com/Pjaijai/Referalah in…
pauljaijai Jan 21, 2024
aca4992
Feature/style house keep (#308)
Pjaijai Jan 21, 2024
1b952f3
Feature/replace magic link with one time passcode (#309)
Pjaijai Jan 21, 2024
3a7279a
style: fix opt verfication max width
pauljaijai Jan 21, 2024
3453910
feat: message display clickable link (#310)
Pjaijai Jan 22, 2024
5d21da4
fix: fix copy
pauljaijai Jan 22, 2024
add2981
fix: fix message icon in site header not redirect
pauljaijai Jan 23, 2024
077c43d
chore(release): 1.8.0
pauljaijai Jan 24, 2024
9ef35be
style: email style
pauljaijai Jan 25, 2024
a0425a7
fix: fix email link
pauljaijai Jan 25, 2024
fc721e2
fix: fix copy
pauljaijai Jan 25, 2024
5520567
fix: fix copy
pauljaijai Jan 25, 2024
606dded
style: profile buttons container style
pauljaijai Jan 25, 2024
644a187
feat: implement bottleneck
pauljaijai Jan 26, 2024
6eb169e
fix: fix copies
pauljaijai Jan 28, 2024
c5aece5
fix: fix copy
pauljaijai Jan 28, 2024
2bbfd7b
chore: house keep
pauljaijai Feb 3, 2024
ed0ccce
chore: house keep
pauljaijai Feb 7, 2024
b253fdd
fix(fix en-ca copy): fix en-ca copy
pauljaijai Feb 7, 2024
b669e9d
Merge remote-tracking branch 'origin/main' into development
pauljaijai Feb 9, 2024
5c7cc48
feat: optimize notify unseen conversation function (#314)
Pjaijai Feb 10, 2024
fa81c44
Feature/api-ssg (#312)
Pjaijai Feb 10, 2024
8a88cda
feat: install speed insights
pauljaijai Feb 10, 2024
63e3511
chore(release): 1.9.0
pauljaijai Feb 10, 2024
a556e27
Merge branch 'main' into development
pauljaijai Feb 10, 2024
200ea77
feat: fix sign in link in sign up page
pauljaijai Feb 14, 2024
1140d3c
feat: invalidate instead of refech (#317)
Pjaijai Feb 17, 2024
2f33cf7
Feature/password eye icon (#316)
Pjaijai Feb 17, 2024
9a56540
chore(release): 1.10.0
pauljaijai Feb 17, 2024
aa9499c
fix: hotfix conversatio per page
pauljaijai Feb 20, 2024
e911fda
Merge branch 'main' into development
pauljaijai Feb 20, 2024
c0a4000
chore(release): 1.10.1
pauljaijai Feb 20, 2024
8bf3cf5
Feature/revamp user profile (#320)
Pjaijai Feb 22, 2024
c35c81f
Merge branch 'main' into development
pauljaijai Feb 22, 2024
02570e6
chore(release): 1.10.2
pauljaijai Feb 22, 2024
092673f
chore(release): 1.10.3
pauljaijai Feb 22, 2024
38bfad3
fix: fixtype
pauljaijai Feb 22, 2024
4416df9
feat: post prefech cache
pauljaijai Feb 24, 2024
9f4e651
Merge branch 'main' into development
Pjaijai Feb 24, 2024
7871b45
style: fix profile info card ui padding
pauljaijai Feb 24, 2024
18ec5e1
feat: combine providers
pauljaijai Feb 24, 2024
01d4e27
Feature/style enhancement (#325)
Pjaijai Feb 27, 2024
ee78bf7
Featurel/make post sharable (#326)
Pjaijai Mar 1, 2024
3fb0f94
Feature/make post sharable (#327)
Pjaijai Mar 1, 2024
991e72c
chore(release): 1.11.0
pauljaijai Mar 1, 2024
40a8d03
Merge branch 'main' into development
pauljaijai Mar 1, 2024
a919a54
feat: post preview on main page (#329)
Pjaijai Mar 2, 2024
025cdc8
chore(release): 1.12.0
pauljaijai Mar 2, 2024
5c2d396
chore(release): 1.12.1
pauljaijai Mar 3, 2024
e2a83c3
fix: fix carousel
pauljaijai Mar 3, 2024
8a11e11
chore(release): 1.12.2
pauljaijai Mar 3, 2024
43ea59a
Merge branch 'main' into development
pauljaijai Mar 3, 2024
9beec7c
fix: fix toast not showing
pauljaijai Mar 7, 2024
37f832b
chore(release): 1.12.3
pauljaijai Mar 7, 2024
1e88183
Merge branch 'main' into development
pauljaijai Mar 7, 2024
5d75a7d
Feature/support sending pdf (#333)
Pjaijai Mar 19, 2024
e32a3ae
Feature/support sending pdf (#334)
Pjaijai Mar 19, 2024
29d771d
fix: fix yoe in referral post card
pauljaijai Mar 19, 2024
d3ba81d
fix: remove github in header
pauljaijai Mar 19, 2024
6b2feae
fix: replace reset icon with copy
pauljaijai Mar 19, 2024
6d89fd5
fix: fix infinite scroll infinite loading problem
pauljaijai Mar 19, 2024
7fd3e79
fix: fix copy
pauljaijai Mar 19, 2024
10b3583
fix: fix word break
pauljaijai Mar 19, 2024
d890b8c
fix: fix typo
pauljaijai Mar 19, 2024
41a113f
feat: add fancy background (#335)
Pjaijai Mar 21, 2024
0cdc69b
fix: fix fancy background showing logic
pauljaijai Mar 21, 2024
b00f11e
Feature/ Create message record (#336)
Pjaijai Mar 23, 2024
6f720a3
Feature/increase document maximum size (#337)
Pjaijai Mar 24, 2024
16f38db
try seed migration
pauljaijai Mar 24, 2024
4150636
Revert "try seed migration"
pauljaijai Mar 24, 2024
6c0ea5a
Feature/add new locations (#338)
Pjaijai Mar 29, 2024
70b798c
fix: fix ui (#339)
Pjaijai Mar 29, 2024
a3ff334
chore(release): 1.13.0
pauljaijai Mar 29, 2024
57e41a1
Feature/update notify unseen conversation (#341)
Pjaijai Mar 29, 2024
e586119
Merge branch 'development' of https://github.com/Pjaijai/Referalah in…
pauljaijai Mar 29, 2024
ccb01da
Merge branch 'main' into development
pauljaijai Mar 29, 2024
6f0e172
feat: update clean storage api logic
pauljaijai Mar 30, 2024
3c477fb
refactor: house keep
pauljaijai Mar 31, 2024
c976891
chore(release): 1.14.0
pauljaijai Mar 31, 2024
919b022
refactor: house keep
pauljaijai Mar 31, 2024
e21b4cc
Merge branch 'main' into development
pauljaijai Mar 31, 2024
b395c0c
fix: remove cache
pauljaijai Mar 31, 2024
66b0440
Merge branch 'main' into development
pauljaijai Mar 31, 2024
f56a089
fix: add back location cache
pauljaijai Mar 31, 2024
05babcf
Merge branch 'main' into development
pauljaijai Mar 31, 2024
109ffe5
fix: cache options for 60 seconds
pauljaijai Mar 31, 2024
c1f05b6
Merge branch 'main' into development
pauljaijai Mar 31, 2024
f94eacb
no cache
pauljaijai Mar 31, 2024
962364d
Merge branch 'main' into development
pauljaijai Mar 31, 2024
6ec2f84
fix: profile apis no store
pauljaijai Mar 31, 2024
4a3a43a
Merge branch 'main' into development
pauljaijai Mar 31, 2024
c694c18
Feature/revamp search (#348)
Pjaijai Apr 8, 2024
3e156ef
Feature/revamp search (#349)
Pjaijai Apr 8, 2024
1f4db73
BugFix/fix search drawer ui (#350)
Pjaijai Apr 9, 2024
06510bd
Feature: Revamp post search ux (#351)
Pjaijai Apr 22, 2024
6103192
fix: fix inistial post search type (#352)
Pjaijai Apr 22, 2024
cb48248
caching (#353)
Pjaijai Apr 22, 2024
657105b
feat: prefrech to edit post
pauljaijai Apr 22, 2024
103cfc9
Merge branch 'main' into development
pauljaijai Apr 22, 2024
92f235c
chore(release): 1.15.0
pauljaijai Apr 22, 2024
18730fd
try edti post cache 1 second
pauljaijai Apr 22, 2024
1ae3fbf
Merge branch 'main' into development
pauljaijai Apr 22, 2024
a0c1d44
remove default cache
pauljaijai Apr 22, 2024
f0596e3
Merge branch 'main' into development
pauljaijai Apr 22, 2024
ef2c0c2
feat: revalidate location options one day
pauljaijai Apr 22, 2024
8756131
Merge branch 'main' into development
pauljaijai Apr 22, 2024
916fd27
fix: fix edit post title
pauljaijai Apr 22, 2024
a10648f
Merge branch 'main' into development
pauljaijai Apr 22, 2024
3648346
chore(release): 1.16.0
pauljaijai Apr 22, 2024
60e0229
fix: fix post history card
pauljaijai Apr 22, 2024
b9ac022
Merge branch 'main' into development
pauljaijai Apr 22, 2024
33622b3
fix: fix post nav description
pauljaijai Apr 22, 2024
621f5db
fix: fix post referee title
pauljaijai Apr 22, 2024
c50cbb3
Merge branch 'main' into development
pauljaijai Apr 22, 2024
17cc97b
fix: fix typo
pauljaijai Apr 22, 2024
06fb606
Merge branch 'main' into development
pauljaijai Apr 22, 2024
025eefb
fix: fothix edge function get user null problem
pauljaijai Apr 23, 2024
57241ec
chore(release): 1.16.2
pauljaijai Apr 23, 2024
f4335a8
Merge branch 'main' into development
pauljaijai Apr 23, 2024
b560060
chore: house keep
pauljaijai Apr 24, 2024
a0259b8
feat: create message uuid col for history tbale
pauljaijai Apr 24, 2024
013fa6d
Feature/revamp member page (#363)
Pjaijai Apr 28, 2024
7b630d9
style: referral card avatar
pauljaijai Apr 28, 2024
5b97b76
chore(release): 1.17.0
pauljaijai Apr 28, 2024
8a0178e
Merge branch 'main' into development
pauljaijai Apr 28, 2024
15b16dd
fix: remove member type checking in contact referral
pauljaijai Apr 29, 2024
1d1e727
chore(release): 1.17.1
pauljaijai Apr 29, 2024
1f47cdd
Merge branch 'main' into development
pauljaijai Apr 29, 2024
3f2d59d
Feature/list most latest contact request on laning page (#366)
Pjaijai May 7, 2024
bde718e
feat: add links to contact request list
pauljaijai May 7, 2024
baa7165
chore: house keep highlighted link
pauljaijai May 7, 2024
d1c8eae
chore(release): 1.18.0
pauljaijai May 7, 2024
c270531
style: fix contact request carousel
pauljaijai May 7, 2024
2695218
style: fix style
pauljaijai May 7, 2024
23dcaa3
Merge branch 'main' into development
pauljaijai May 7, 2024
6069abc
fix: fix main page cache
pauljaijai May 7, 2024
9e34d4c
style: fix contact request style
pauljaijai May 7, 2024
8bb4131
fix: fix view post link in contact request carousel
pauljaijai May 7, 2024
633cc5b
style: fix style
pauljaijai May 8, 2024
8093fcb
feat: remove message icon in site header
pauljaijai May 8, 2024
11734d8
refactor: house keep useCheckHasConversationUnseen
pauljaijai May 8, 2024
51b2467
style: update main page Carousel
pauljaijai May 8, 2024
06ce871
style: update style
pauljaijai May 8, 2024
64b3b3d
feat: replace FormTextInput with FormTextArea
pauljaijai May 8, 2024
d206ae3
Feature/request count for post and user (#368)
Pjaijai May 9, 2024
c7d7ca3
Merge branch 'development' of https://github.com/Pjaijai/Referalah in…
pauljaijai May 9, 2024
cae14d3
chore(release): 1.19.0
pauljaijai May 9, 2024
4f9a48e
Merge branch 'main' into development
pauljaijai May 9, 2024
c0540aa
feat: update user table access
pauljaijai May 9, 2024
c1bb81a
feat: display the count
pauljaijai May 9, 2024
311ab52
fix: fix ContactRequestCount count text
pauljaijai May 9, 2024
d447968
style: fix coffee icon size
pauljaijai May 9, 2024
66f7be7
Merge branch 'main' into development
pauljaijai May 9, 2024
7405e9a
fix: fix user card count position
pauljaijai May 9, 2024
62b9f79
style(fix count style): fix count style on referral card
pauljaijai May 9, 2024
96cfabe
chore(release): 1.20.0
pauljaijai May 9, 2024
7ec8cb2
Merge branch 'main' into development
pauljaijai May 9, 2024
2ad36d2
fix: fix request count on post detail page
pauljaijai May 9, 2024
20b7fff
fix: remove fancy stuff (#372)
Pjaijai May 13, 2024
59464cc
fix: fix list latest contact request post uuid
pauljaijai May 13, 2024
6d44192
Merge branch 'development' of https://github.com/Pjaijai/Referalah in…
pauljaijai May 13, 2024
7fbbf4d
Merge branch 'main' into development
pauljaijai May 13, 2024
2caa1e1
chore(release): 1.20.1
pauljaijai May 13, 2024
8f0f679
fix: fix message covered my text input form (#374)
Pjaijai May 14, 2024
9913b7a
Merge branch 'main' into development
pauljaijai May 14, 2024
c93daec
chore(release): 1.20.2
pauljaijai May 14, 2024
eb8a02d
Merge branch 'main' into development
Pjaijai May 14, 2024
4b9f7ec
Merge branch 'development' of https://github.com/Pjaijai/Referalah in…
pauljaijai May 14, 2024
6eeec48
chore: house keep
pauljaijai May 17, 2024
d06ce79
fix: fix post title and company limit to 100
pauljaijai May 17, 2024
a2745d6
chore(release): 1.20.3
pauljaijai May 17, 2024
90308f6
Merge branch 'main' into development
pauljaijai May 17, 2024
7d4b208
Feature/add collaboration type to post (#377)
Pjaijai May 26, 2024
c524e84
Feature/block user to send chat request or crud post (#378)
Pjaijai May 30, 2024
d1b2350
fix: fix messsage post user banned problem
pauljaijai May 30, 2024
74f0d46
chore(release): 1.20.4
pauljaijai May 30, 2024
b96787c
Merge branch 'main' into development
pauljaijai May 30, 2024
d3e7d4f
fix: fix view post title tag
pauljaijai Jun 1, 2024
193e9cb
style: fix request count styles
pauljaijai Jun 1, 2024
6bc994b
fix: hot fix post update count
pauljaijai Jun 1, 2024
0960a07
chore(release): 1.20.5
pauljaijai Jun 1, 2024
647f812
Merge branch 'main' into development
pauljaijai Jun 1, 2024
41e88e7
style: fis request count style
pauljaijai Jun 2, 2024
be7fa9f
fix: force need help post to have link
pauljaijai Jun 3, 2024
fd35751
fix: not posting need help link in main page
pauljaijai Jun 3, 2024
3c6717f
chore(release): 1.20.6
pauljaijai Jun 3, 2024
84273a1
Merge branch 'main' into development
pauljaijai Jun 3, 2024
3a41cb4
fix: fix conversation bug
pauljaijai Jun 9, 2024
b71609a
fix: fix back post reset problem
pauljaijai Jun 9, 2024
7cf54e0
Merge branch 'main' into development
pauljaijai Jun 9, 2024
04a3380
chore(release): 1.20.7
pauljaijai Jun 9, 2024
55ae648
fix: try fix auto zoom
pauljaijai Jun 10, 2024
e15f03c
Feature/revamp UI (#385)
Pjaijai Sep 27, 2024
6e7dcb1
feat: them remove theme toggle (#386)
Pjaijai Sep 27, 2024
7773730
fix: fix ContactRequestCarousel time
pauljaijai Sep 27, 2024
fd4e347
style: fix footer style
pauljaijai Sep 28, 2024
42b99d5
feat: fix main page style
pauljaijai Sep 28, 2024
1bab442
style: default light mode
pauljaijai Sep 28, 2024
949ba06
fix: disable system style
pauljaijai Sep 29, 2024
092a111
fix: fix post page title
pauljaijai Oct 1, 2024
56bbb75
Feature/loading balls (#387)
Pjaijai Oct 2, 2024
58fc228
style: fix loading ball magin top
pauljaijai Oct 2, 2024
18b224c
Feature/update user history page (#388)
Pjaijai Oct 9, 2024
b71718c
feat: add back button in history post page
pauljaijai Oct 9, 2024
8b2fd2f
House keep and add unit test (#389)
Pjaijai Oct 15, 2024
a992b63
Feature/Update user edit profile (#390)
Pjaijai Nov 13, 2024
2ce651e
style: fix style (#391)
Pjaijai Nov 13, 2024
7eb683b
Feature/update user profile (#392)
Pjaijai Nov 25, 2024
40b48b9
fix: fix profile upload failed handling
pauljaijai Nov 25, 2024
01c67bb
fix: fix message referral cungion
pauljaijai Nov 25, 2024
8bb33ca
style: fix style
pauljaijai Nov 25, 2024
9b83418
fix: fix
pauljaijai Nov 25, 2024
cf48094
style: fix probile bottom bar buttons style and copy
pauljaijai Nov 26, 2024
1a54c0d
style: fix post card style
pauljaijai Nov 30, 2024
472b565
fix: fix contact function email subject
pauljaijai Dec 3, 2024
506b4af
style: fix main page count style
pauljaijai Dec 3, 2024
eb06c50
style: fix message form auto height
pauljaijai Dec 3, 2024
df5d50c
style(fix stylesss): fix stylesss
pauljaijai Dec 5, 2024
926e6f3
style: fix slider
pauljaijai Dec 5, 2024
20ff2d6
style: fix icons and select style
pauljaijai Dec 9, 2024
754eca8
Feature/message notification (#393)
Pjaijai Dec 13, 2024
8fa8087
fix: fix table and add policy
pauljaijai Dec 13, 2024
b2309d0
fix: fix migration
pauljaijai Dec 13, 2024
9e73f24
fix: fix miration again
pauljaijai Dec 13, 2024
98c7da9
fix: recreate table
pauljaijai Dec 13, 2024
ef85821
fix: fix again
pauljaijai Dec 13, 2024
2302bc7
fix: drop and recreate table
pauljaijai Dec 13, 2024
7673df8
fix: fix
pauljaijai Dec 13, 2024
14fef3b
feat: add low level rule to log table
pauljaijai Dec 13, 2024
f311533
feat: add type col to notification log table
pauljaijai Dec 13, 2024
808696c
style: fix post search sort style
pauljaijai Dec 13, 2024
f296d5e
fix: fix profile button showing logic
pauljaijai Dec 13, 2024
1bdc2b4
style: fix view profile sytle
pauljaijai Dec 13, 2024
5a995be
Merge branch 'main' into development
pauljaijai Dec 14, 2024
912cd11
fix: fix edit profile page copies
pauljaijai Dec 14, 2024
e19f0e0
fix: fix search sheet auto focus input
pauljaijai Dec 18, 2024
c5dabb4
feat: main page server side actions
pauljaijai Dec 23, 2024
a3bbd3a
fix: fix build error
pauljaijai Dec 23, 2024
f831a58
fix: fix main page meta data
pauljaijai Dec 23, 2024
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
53 changes: 0 additions & 53 deletions client/app/[locale]/about/page.tsx

This file was deleted.

5 changes: 4 additions & 1 deletion client/app/[locale]/auth/email-verification/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@ import CommonPageLayout from "@/components/layouts/common"
const EmailVerificationPage = async () => {
const t = await getI18n()
return (
<CommonPageLayout title={t("page.email_verification")}>
<CommonPageLayout
title={t("page.email_verification")}
titlePosition="middle"
>
<EmailVerificationPageTemplate />
</CommonPageLayout>
)
Expand Down
2 changes: 1 addition & 1 deletion client/app/[locale]/auth/forgot-password/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export const metadata = siteConfig.page.forgetPassword.metadata
const ForgotPasswordPage = async () => {
const t = await getI18n()
return (
<CommonPageLayout title={t("page.forgot_password")}>
<CommonPageLayout title={t("page.forgot_password")} titlePosition="middle">
<ForgotPasswordPageTemplate />
</CommonPageLayout>
)
Expand Down
2 changes: 1 addition & 1 deletion client/app/[locale]/auth/reset-password/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ export const metadata = siteConfig.page.resetPassword.metadata
const ResetPasswordPage = async () => {
const t = await getI18n()
return (
<CommonPageLayout title={t("page.reset_password")}>
<CommonPageLayout title={t("page.reset_password")} titlePosition="middle">
<ResetPasswordPageTemplate />
</CommonPageLayout>
)
Expand Down
9 changes: 6 additions & 3 deletions client/app/[locale]/auth/sign-in/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,18 @@ import { getI18n } from "@/utils/services/internationalization/server"

import { siteConfig } from "@/config/site"
import CommonPageLayout from "@/components/layouts/common"
import NotAuthOnlyWrapper from "@/components/wrappers/not-auth-only/not-auth-only"

export const metadata = siteConfig.page.signIn.metadata

const SignInPage = async () => {
const t = await getI18n()
return (
<CommonPageLayout title={t("page.sign_in")}>
<SignInPageTemplate />
</CommonPageLayout>
<NotAuthOnlyWrapper>
<CommonPageLayout title={t("page.sign_in")} titlePosition="middle">
<SignInPageTemplate />
</CommonPageLayout>
</NotAuthOnlyWrapper>
)
}
export default SignInPage
5 changes: 4 additions & 1 deletion client/app/[locale]/auth/sign-up-confirmation/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@ export const metadata = siteConfig.page.signUpConfirmation.metadata
const SignUpConfirmationPage = async () => {
const t = await getI18n()
return (
<CommonPageLayout title={t("page.sign_up_confirmation")}>
<CommonPageLayout
title={t("page.sign_up_confirmation")}
titlePosition="middle"
>
<SignUpConfirmationPageTemplate />
</CommonPageLayout>
)
Expand Down
9 changes: 6 additions & 3 deletions client/app/[locale]/auth/sign-up/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,18 @@ import { getI18n } from "@/utils/services/internationalization/server"

import { siteConfig } from "@/config/site"
import CommonPageLayout from "@/components/layouts/common"
import NotAuthOnlyWrapper from "@/components/wrappers/not-auth-only/not-auth-only"

export const metadata = siteConfig.page.signUp.metadata

const SignUpPage = async () => {
const t = await getI18n()
return (
<CommonPageLayout title={t("page.sign_up")}>
<SignUpPageTemplate />
</CommonPageLayout>
<NotAuthOnlyWrapper>
<CommonPageLayout title={t("page.sign_up")} titlePosition="middle">
<SignUpPageTemplate />
</CommonPageLayout>
</NotAuthOnlyWrapper>
)
}

Expand Down
5 changes: 4 additions & 1 deletion client/app/[locale]/auth/verify-one-time-password/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,10 @@ export const metadata = siteConfig.page.verifyOneTimePassword.metadata
const VerifyOneTimePassword = async () => {
const t = await getI18n()
return (
<CommonPageLayout title={t("page.verify_one_time_password")}>
<CommonPageLayout
title={t("page.verify_one_time_password")}
titlePosition="middle"
>
<VerifyEmailOneTimePasswordPageTemplate />
</CommonPageLayout>
)
Expand Down
2 changes: 1 addition & 1 deletion client/app/[locale]/chat/page.tsx
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from "react"
import ChatPageTemplate from "@/modules/chat/template"

import AuthenticatedPageWrapper from "@/components/wrappers/authenticated"
import AuthenticatedPageWrapper from "@/components/wrappers/authenticated/authenticated"

const ChatPage = () => {
return (
Expand Down
14 changes: 8 additions & 6 deletions client/app/[locale]/layout.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ export const metadata: Metadata = {
],
manifest: "../manifest.json",
title: {
default: `${siteConfig.name} | 海外港人搵Referral平台`,
default: `${siteConfig.name} | 海外港人平台`,
template: `%s - ${siteConfig.name}`,
},
description: siteConfig.description,
Expand All @@ -53,21 +53,23 @@ export default async function RootLayout({
}: RootLayoutProps) {
return (
<html lang={locale} suppressHydrationWarning>
<meta
name="viewport"
content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0"
/>
<head />
<body
className={cn(
"min-h-screen bg-background font-sans antialiased",
"min-h-screen bg-slate-50 font-openSans antialiased",
fontSans.variable
)}
>
<GoogleAnalytics />

<Provider locale={locale}>
<div className="flex min-h-screen flex-col">
<div className="flex min-h-screen flex-col ">
<SiteHeader />
<div className="flex-1 overflow-y-auto overflow-x-hidden ">
{children}
</div>
<div className="flex-1 overflow-hidden">{children}</div>
<NavFooter />
</div>
<Analytics />
Expand Down
40 changes: 26 additions & 14 deletions client/app/[locale]/page.tsx
Original file line number Diff line number Diff line change
@@ -1,29 +1,41 @@
import { Suspense } from "react"
import MainPageTemplate from "@/modules/main/template"
import {
getUserCount,
listLatestContactRequest,
searchPostApi,
searchPost,
} from "@/utils/common/api"

import { EPostType } from "@/types/common/post-type"
import CommonPageLayout from "@/components/layouts/common"

import Loading from "./loading"

// cache for 1 hours
export const revalidate = 60 * 60

export default async function IndexPage() {
const count = await getUserCount()
const posts = await searchPostApi({
numberOfDataPerPage: 8,
page: 0,
sortingType: "createdAt,dec",
companyName: "",
jobTitle: "",
maxYearOfExperience: 100,
minYearOfExperience: 0,
types: [EPostType.REFERRER, EPostType.HIRING, EPostType.COLLABORATION],
})
return (
<CommonPageLayout>
<Suspense fallback={<Loading />}>
<MainPageContent />
</Suspense>
</CommonPageLayout>
)
}

const list = await listLatestContactRequest()
async function MainPageContent() {
const [count, posts, list] = await Promise.all([
getUserCount(),
searchPost({
keywords: "",
numberOfDataPerPage: 8,
experience: 0,
page: 0,
type: EPostType.ALL,
sortingType: "createdAt,dec",
}),
listLatestContactRequest(),
])

return <MainPageTemplate count={count} posts={posts} contactList={list} />
}
2 changes: 1 addition & 1 deletion client/app/[locale]/post/create/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ import { getI18n } from "@/utils/services/internationalization/server"

import { siteConfig } from "@/config/site"
import CommonPageLayout from "@/components/layouts/common"
import AuthenticatedPageWrapper from "@/components/wrappers/authenticated"
import AuthenticatedPageWrapper from "@/components/wrappers/authenticated/authenticated"

export const metadata = siteConfig.page.createPost.metadata

Expand Down
3 changes: 1 addition & 2 deletions client/app/[locale]/post/view/[uuid]/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,7 @@ export async function generateMetadata({

// Define type title based on post type
let typeTitle: string = ""

switch (postType) {
case EPostType.HIRING:
typeTitle = t("post.type.hiring.title")
Expand All @@ -30,8 +31,6 @@ export async function generateMetadata({
break
case EPostType.REFERRER:
typeTitle = t("post.type.referer.title")
case EPostType.REFERRER:
typeTitle = t("post.type.collaboration.title")
break
case EPostType.COLLABORATION:
typeTitle = t("post.type.collaboration.title")
Expand Down
7 changes: 4 additions & 3 deletions client/app/[locale]/profile/edit/page.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,10 @@ import {
getIndustryList,
getProvinceList,
} from "@/utils/common/api"
import { getI18n } from "@/utils/services/internationalization/server"

import CommonPageLayout from "@/components/layouts/common"
import AuthenticatedPageWrapper from "@/components/wrappers/authenticated"
import AuthenticatedPageWrapper from "@/components/wrappers/authenticated/authenticated"

export const revalidate = 60 * 60 * 24

Expand All @@ -17,10 +18,10 @@ const EditProfilePage = async () => {
const provinceList = await getProvinceList()
const cityList = await getCityList()
const industryList = await getIndustryList()

const t = await getI18n()
return (
<AuthenticatedPageWrapper>
<CommonPageLayout>
<CommonPageLayout title={t("page.edit_profile")}>
<EditProfileTemplate
cityList={cityList}
countryList={countryList}
Expand Down
47 changes: 47 additions & 0 deletions client/components/__tests__/theme-provider.test.tsx
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
/**
* ThemeProvider component test
*
* @group unit
*/

import React from "react"
import { render } from "@testing-library/react"
import { useTheme } from "next-themes"

import { ThemeProvider } from "@/components/theme-provider"

// Mock the next-themes library
jest.mock("next-themes", () => ({
ThemeProvider: jest.fn(({ children }) => (
<div data-testid="mock-theme-provider">{children}</div>
)),
useTheme: jest.fn(),
}))

describe("ThemeProvider", () => {
it("renders children without crashing", () => {
const { getByText } = render(
<ThemeProvider>
<div>Test Child</div>
</ThemeProvider>
)
expect(getByText("Test Child")).toBeInTheDocument()
})

it("provides theme context to children", () => {
const MockChild = () => {
const { theme } = useTheme()
return <div>{theme}</div>
}

;(useTheme as jest.Mock).mockReturnValue({ theme: "light" })

const { getByText } = render(
<ThemeProvider>
<MockChild />
</ThemeProvider>
)

expect(getByText("light")).toBeInTheDocument()
})
})
Loading
Loading