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

Add clouds to login, guest-login, portal, and application forms #511

Open
wants to merge 5 commits into
base: main
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
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
8 changes: 8 additions & 0 deletions apps/site/src/app/(main)/guest-login/GuestLogin.tsx
Original file line number Diff line number Diff line change
@@ -1,8 +1,11 @@
import Image from "next/image";
import { redirect } from "next/navigation";

import GuestLoginVerificationForm from "./components/GuestLoginVerificationForm";
import getUserIdentity from "@/lib/utils/getUserIdentity";

import clouds from "@/assets/images/starry_clouds.png";

async function GuestLogin({
searchParams,
}: {
Expand All @@ -20,6 +23,11 @@ async function GuestLogin({

return (
<div className="min-h-screen flex flex-col items-center justify-center">
<Image
src={clouds}
alt="Background clouds"
className="absolute top-0 min-w-[1500px] xl:min-w-[100vw] xl:w-[100vw] z-[-1] h-[200vh]"
/>
<h1 className="font-display text-3xl md:text-5xl mb-20">
Enter Passphrase
</h1>
Expand Down
9 changes: 8 additions & 1 deletion apps/site/src/app/(main)/login/Login.tsx
Original file line number Diff line number Diff line change
@@ -1,6 +1,8 @@
import Image from "next/image";
import { redirect } from "next/navigation";
import getUserIdentity from "@/lib/utils/getUserIdentity";
import LoginForm from "./components/LoginForm";
import clouds from "@/assets/images/starry_clouds.png";

async function Login({
searchParams,
Expand All @@ -17,7 +19,12 @@ async function Login({
}

return (
<div className="min-h-screen flex flex-col items-center justify-center">
<div className="min-h-screen flex flex-col items-center justify-center overflow-hidden">
<Image
src={clouds}
alt="Background clouds"
className="absolute top-0 min-w-[1500px] xl:min-w-[100vw] xl:w-[100vw] z-[-1] h-[200vh]"
/>
<h1 className="font-display text-3xl md:text-5xl mb-20">Log In</h1>
<LoginForm return_to={return_to} />
</div>
Expand Down
14 changes: 11 additions & 3 deletions apps/site/src/app/(main)/portal/@applicant/ApplicantPortal.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import Image from "next/image";
import { redirect } from "next/navigation";

import getUserIdentity from "@/lib/utils/getUserIdentity";
Expand All @@ -8,6 +9,7 @@ import SignWaiver from "./components/SignWaiver";
import ReturnHome from "./components/ReturnHome";
import VerticalTimeline from "./components/timeline/VerticalTimeline";
import BackgroundStars from "./components/BackgroundStars";
import clouds from "@/assets/images/starry_clouds.png";

// TODO: use common Status enum from userRecord.ts

Expand Down Expand Up @@ -46,8 +48,15 @@ async function Portal() {
const rejected = status === PortalStatus.rejected;

return (
<div className="relative">
<BackgroundStars className="left-[-15%] top-[21%]" />
<div>
<Image
src={clouds}
alt="Background clouds"
className="absolute top-0 min-w-[1500px] xl:min-w-[100vw] xl:w-[100vw] z-[-1] h-[200vh]"
/>
<BackgroundStars className="absolute left-[6%] top-[45%]" />
<BackgroundStars className="right-[6%] bottom-[12%]" />

<div className="bg-transparent text-black max-w-6xl rounded-2xl p-6 flex flex-col mb-24 w-full">
<h2 className="font-bold font-display text-[var(--color-white)] mb-4 md:mb-[42px] text-[15px] sm:text-2xl md:text-[40px] md:leading-10">
{roleToDisplay} Application Status
Expand All @@ -60,7 +69,6 @@ async function Portal() {
)}
{rejected && <ReturnHome />}
</div>
<BackgroundStars className="right-[-15%] bottom-[21%]" />
</div>
);
}
Expand Down
7 changes: 7 additions & 0 deletions apps/site/src/lib/components/forms/shared/ApplicationFlow.tsx
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
import Image from "next/image";
import { PropsWithChildren } from "react";
import { redirect } from "next/navigation";

Expand All @@ -8,6 +9,7 @@ import ApplicationsClosed from "./ApplicationsClosed/ApplicationsClosed";
import ApplyConfirm from "./ApplyConfirmation/ApplyConfirm";
import Title from "./Title/Title";
import getUserIdentity from "@/lib/utils/getUserIdentity";
import clouds from "@/assets/images/starry_clouds.png";

export const revalidate = 60;

Expand Down Expand Up @@ -48,6 +50,11 @@ export default async function ApplicationFlow({
);
return (
<div className="flex flex-col items-center justify-center gap-10 min-h-screen">
<Image
src={clouds}
alt="Background clouds"
className="absolute top-0 min-w-[1500px] xl:min-w-[100vw] xl:w-[100vw] z-[-1] h-[200vh]"
/>
{!applicationsOpened || deadlinePassed ? (
<ApplicationsClosed />
) : (
Expand Down
Loading