Skip to content

Commit 852e0a7

Browse files
committed
Responsive work for the onboarding screens
1 parent bf736a7 commit 852e0a7

File tree

3 files changed

+12
-16
lines changed

3 files changed

+12
-16
lines changed

apps/webapp/app/components/BackgroundWrapper.tsx

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -5,10 +5,9 @@ import blurredDashboardBackgroundTable from "~/assets/images/blurred-dashboard-b
55

66
export function BackgroundWrapper({ children }: { children: ReactNode }) {
77
return (
8-
<div className="relative h-full w-full overflow-hidden">
9-
{/* Left menu top background - fixed width 260px, maintains aspect ratio */}
8+
<div className="relative h-full w-full overflow-hidden bg-background-dimmed lg:bg-transparent">
109
<div
11-
className="absolute left-0 top-0 w-[260px] bg-contain bg-left-top bg-no-repeat"
10+
className="absolute left-0 top-0 hidden w-[260px] bg-contain bg-left-top bg-no-repeat lg:block"
1211
style={{
1312
backgroundImage: `url(${blurredDashboardBackgroundMenuTop})`,
1413
aspectRatio: "auto",
@@ -17,9 +16,8 @@ export function BackgroundWrapper({ children }: { children: ReactNode }) {
1716
}}
1817
/>
1918

20-
{/* Left menu bottom background - fixed width 260px, maintains aspect ratio */}
2119
<div
22-
className="absolute bottom-0 left-0 w-[260px] bg-contain bg-left-bottom bg-no-repeat"
20+
className="absolute bottom-0 left-0 hidden w-[260px] bg-contain bg-left-bottom bg-no-repeat lg:block"
2321
style={{
2422
backgroundImage: `url(${blurredDashboardBackgroundMenuBottom})`,
2523
aspectRatio: "auto",
@@ -28,9 +26,8 @@ export function BackgroundWrapper({ children }: { children: ReactNode }) {
2826
}}
2927
/>
3028

31-
{/* Right table background - fixed width 2000px, positioned next to menu */}
3229
<div
33-
className="absolute top-0 bg-left-top bg-no-repeat"
30+
className="absolute top-0 hidden bg-left-top bg-no-repeat lg:block"
3431
style={{
3532
left: "260px",
3633
backgroundImage: `url(${blurredDashboardBackgroundTable})`,
@@ -41,7 +38,6 @@ export function BackgroundWrapper({ children }: { children: ReactNode }) {
4138
}}
4239
/>
4340

44-
{/* Content layer */}
4541
<div className="relative z-10 h-full w-full">{children}</div>
4642
</div>
4743
);

apps/webapp/app/components/LoginPageLayout.tsx

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -46,10 +46,10 @@ export function LoginPageLayout({ children }: { children: React.ReactNode }) {
4646
}, []);
4747

4848
return (
49-
<main className="grid h-full grid-cols-1 md:grid-cols-2">
50-
<div className="border-r border-grid-bright bg-background-bright">
51-
<div className="flex h-full flex-col items-center justify-between p-6">
52-
<div className="flex w-full items-center justify-between">
49+
<main className="grid h-full grid-cols-1 lg:grid-cols-2">
50+
<div className="bg-background-dimmed lg:border-r lg:border-grid-bright lg:bg-background-bright">
51+
<div className="flex h-full flex-col items-center justify-center p-6 lg:justify-between">
52+
<div className="hidden w-full items-center justify-between lg:flex">
5353
<a href="https://trigger.dev">
5454
<LogoType className="w-36" />
5555
</a>
@@ -62,13 +62,13 @@ export function LoginPageLayout({ children }: { children: React.ReactNode }) {
6262
</LinkButton>
6363
</div>
6464
<div className="flex h-full max-w-sm items-center justify-center">{children}</div>
65-
<Paragraph variant="small" className="text-center">
65+
<Paragraph variant="small" className="hidden text-center lg:block">
6666
Having login issues? <TextLink href="https://@trigger.dev/contact">Email us</TextLink>{" "}
6767
or <TextLink href="https://trigger.dev/discord">ask us in Discord</TextLink>
6868
</Paragraph>
6969
</div>
7070
</div>
71-
<div className="hidden grid-rows-[1fr_auto] pb-6 md:grid">
71+
<div className="hidden grid-rows-[1fr_auto] pb-6 lg:grid">
7272
<div className="flex h-full flex-col items-center justify-center px-16">
7373
<Header3 className="relative text-center text-2xl font-normal leading-8 text-text-dimmed transition before:relative before:right-1 before:top-0 before:text-6xl before:text-charcoal-750 before:content-['❝'] lg-height:text-xl md-height:text-lg">
7474
{randomQuote?.quote}

apps/webapp/app/components/layout/AppLayout.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,8 +65,8 @@ export function MainCenteredContainer({
6565
className?: string;
6666
}) {
6767
return (
68-
<div className="h-full w-full overflow-y-auto scrollbar-thin scrollbar-track-transparent scrollbar-thumb-charcoal-600">
69-
<div className={cn("mx-auto mt-6 max-w-xs overflow-y-auto p-1 md:mt-[22vh]", className)}>
68+
<div className="flex h-full w-full items-center justify-center overflow-y-auto p-4 scrollbar-thin scrollbar-track-transparent scrollbar-thumb-charcoal-600 lg:items-start lg:p-0">
69+
<div className={cn("mx-auto max-w-xs overflow-y-auto p-1 lg:mt-[22vh]", className)}>
7070
{children}
7171
</div>
7272
</div>

0 commit comments

Comments
 (0)