Skip to content

Commit 7a67b37

Browse files
authored
Merge pull request #13 from Solstice-Hosting/alexx-partners-260424-2133
Some mobile fixes. Signup has better error messaging.
2 parents ce82b52 + 0e3ada7 commit 7a67b37

File tree

4 files changed

+27
-14
lines changed

4 files changed

+27
-14
lines changed

pages/partners/dashboard.js

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -54,12 +54,13 @@ export default function PartnerDashboard() {
5454
return (
5555
<>
5656
<Header />
57-
<main className="min-h-screen w-screen bg-gray-950 flex gap-8 flex-col p-24">
57+
<main className="min-h-screen w-screen bg-gray-950 flex gap-8 flex-col p-8 lg:p-24">
5858
<Suspense fallback="Loading...">
5959
{partnerInfo.length > 0 && (
6060
<>
6161
<div className="w-10/12 flex flex-col gap-6">
62-
<h1 className="text-white font-extrabold text-4xl">Edit your Partnership Information</h1>
62+
<h1 className="text-white font-extrabold text-4xl hidden lg:block">Edit your Partnership Information</h1>
63+
<h1 className="text-white font-extrabold text-4xl block lg:hidden text-center w-full">Edit Info</h1>
6364
</div>
6465
<div className="flex flex-col gap-8 text-white">
6566
{partnerInfo.map((partner) => (
@@ -111,9 +112,9 @@ function PartnerComp({ key, partner }) {
111112
return (
112113
<>
113114
<div className="w-full bg-gray-800 min-h-content rounded-lg border-2 border-gray-700 p-4 flex flex-col gap-8">
114-
<div className="flex w-full justify-between items-center">
115+
<div className="flex w-full justify-between items-center flex-col lg:flex-row">
115116
<input
116-
className="bg-gray-700 rounded-lg text-white outline-none p-4 text-2xl font-extrabold w-1/2 border-2 border-gray-600"
117+
className="bg-gray-700 rounded-lg text-white outline-none p-4 text-2xl font-extrabold w-1/2 border-2 border-gray-600 text-center lg:text-left"
117118
value={partnerName}
118119
onChange={(e) => setPartnerName(e.target.value)}
119120
/>
@@ -131,7 +132,7 @@ function PartnerComp({ key, partner }) {
131132

132133
</textarea>
133134
</div>
134-
<div className="flex gap-4">
135+
<div className="flex gap-4 flex-col lg:flex-row">
135136
<div className="flex flex-col gap-2 w-full">
136137
<span className="font-bold flex gap-4 items-center">Website <span className="font-normal text-gray-400">(optional)</span></span>
137138
<input

pages/partners/index.js

Lines changed: 7 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -39,13 +39,13 @@ export default function PartnerPage() {
3939
<Header />
4040
<main className="min-h-[80vh] w-full bg-gray-950">
4141
<div className="flex flex-col gap-2 items-center p-4 lg:p-10 text-center">
42-
<h1 className="font-extrabold text-5xl text-gray-100 whitespace-nowrap">
42+
<h1 className="font-extrabold text-3xl lg:text-5xl text-gray-100 whitespace-nowrap">
4343
<span className="hidden lg:block">Our</span>
4444
<span className="bg-gradient-to-r from-orange-400 transition-all duration-200 to-purple-500 bg-clip-text text-transparent hover:saturate-150 hover:to-orange-400 hover:from-purple-500">
4545
Partners
4646
</span>
4747
</h1>
48-
<span className="text-2xl text-gray-50">All of the friends we&apos;ve made along the way.</span>
48+
<span className="text-lg lg:text-2xl text-gray-50">All of the friends we&apos;ve made along the way.</span>
4949
</div>
5050
<div
5151
className="flex flex-col gap-10 px-10"
@@ -60,13 +60,14 @@ export default function PartnerPage() {
6060
alt={partner.title}
6161
/>
6262
<div className="w-full flex flex-col justify-between h-full items-start gap-4">
63-
<h3 className="text-3xl font-extrabold text-white w-full flex gap-12 items-end">
64-
{partner.title} {(partner.account).includes(userId) && (<span className="font-semibold text-gray-400 text-lg italic"> Pssst... this is you!</span>)}
65-
</h3>
63+
<h3 className="text-3xl font-extrabold text-white w-full items-center flex gap-x-12 lg:items-end flex-col lg:flex-row">
64+
{partner.title}
65+
{(partner.account).includes(userId) && (<span className="font-semibold text-gray-400 text-lg italic"> Pssst... this is you!</span>)}
66+
</h3>
6667
<p className="w-full whitespace-pre-wrap text-white">
6768
{partner.memo}
6869
</p>
69-
<div className="flex gap-4">
70+
<div className="flex gap-4 w-full justify-center lg:justify-start">
7071
{partner.site &&
7172
(<Link href={`${partner.site ? partner.site : ''}`} target="_blank">
7273
<Button className="bg-gray-800 hover:bg-gray-700 h-full w-40">

pages/signup.js

Lines changed: 13 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -48,14 +48,25 @@ export default function Login() {
4848
}
4949
}
5050
catch (e) {
51-
setProperError("An account with this email already exists.");
51+
setProperError("An error occured whilst creating your account. Are your passwords the same?");
5252
}
5353

5454
}
5555
else {
5656
setProperError(null);
5757
setSuccess(null);
58-
setInfo('Username, Password or Email invalid.')
58+
if (!emailRegex.test(email)) {
59+
setInfo("Email address invalid.");
60+
}
61+
else if (password.length <= 2) {
62+
setInfo("Password is too short.");
63+
}
64+
else if (username.length <= 2) {
65+
setInfo("Username is too short.");
66+
}
67+
else {
68+
setInfo("An unknown error occured.");
69+
}
5970
}
6071
}
6172

pages/store/[page].js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -55,7 +55,7 @@ export default function StorePage() {
5555
<Header />
5656
<div className="w-full flex items-center p-12 flex-col bg-gray-950 gap-8 min-h-screen">
5757
<div className="flex flex-col gap-2 items-center p-4 lg:p-10 text-center">
58-
<h1 className="font-extrabold text-5xl text-gray-100 whitespace-nowrap">
58+
<h1 className="font-extrabold text-5xl text-gray-100 whitespace-wrap">
5959
<span className="hidden lg:block">{categoryInformation?.categoryWhamWord}</span>
6060
<span className="bg-gradient-to-r from-orange-400 transition-all duration-200 to-purple-500 bg-clip-text text-transparent hover:saturate-150 hover:to-orange-400 hover:from-purple-500">
6161
{categoryInformation?.categoryNameLong}

0 commit comments

Comments
 (0)