Skip to content

Commit 7fffa4f

Browse files
committed
feat: branding + hero page
1 parent 5c8535f commit 7fffa4f

File tree

12 files changed

+182
-20
lines changed

12 files changed

+182
-20
lines changed

.env.example

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,3 +15,9 @@ NEXTAUTH_URL=https://your-site.example
1515

1616
# analytics (posthog)
1717
POSTHOG_UI_HOST=https://eu.posthog.com
18+
POSTHOG_KEY=phc_xxxx
19+
20+
# branding
21+
NEXT_PUBLIC_SIGNIN_TITLE="Eloop"
22+
NEXT_PUBLIC_SIGNIN_SUBTITLE="Sign up to your event"
23+
NEXT_PUBLIC_SIGNIN_IMAGE="/signin-hero.svg"

README.md

Lines changed: 8 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,11 +1,14 @@
1-
# eloop by HSP — Event Management Platform
1+
# [eloop](https://hsp-ec.xyz/eloop) — An Event Management Platform
22

3-
Eventloop (eloop) is a serverless event management app built with Next.js and Turso. It supports hierarchical roles, dynamic registration forms, and QR-based check-ins.
3+
Eventloop (eloop) is a serverless event management app built with Next.js and Turso. It supports hierarchical roles, dynamic registration forms, and QR-based check-ins at hackathons!
4+
5+
> This is a project maintained by [HSP](https://hsp-ec.xyz)
46
57
[![Deploy with Vercel](https://vercel.com/button)](https://vercel.com/new/clone?repository-url=https%3A%2F%2Fgithub.com%2Fpolarhive%2Feloop-serverless-spin&env=QR_SECRET,GOOGLE_CLIENT_SECRET,TURSO_AUTH_TOKEN,NEXTAUTH_SECRET,ADMIN_EMAIL,TURSO_DATABASE_URL,GOOGLE_CLIENT_ID,NEXTAUTH_URL)
68

9+
710
<details>
8-
<summary>Required environment variables</summary>
11+
<summary>Documentation</summary>
912

1013
## On clicking Deploy to Vercel
1114

@@ -66,6 +69,8 @@ The application automatically checks for the database tables on startup and init
6669

6770
> **Note:** (eloop-turso) is based on the concept and architecture of the original [eventloop](https://github.com/homebrew-ec-foss/eventloop) backend system at HSP. Reimagined as a modern Next.js frontend with serverless capabilities.
6871
72+
Read more: https://homebrew.hsp-ec.xyz/posts/tilde-4.0-eventloop
73+
6974
## Features
7075

7176
- **Role-Based Access Control**: Admin, Organizer, Volunteer, Participant, and Applicant roles with hierarchical permissions

instrumentation-client.ts

Lines changed: 23 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,25 @@
11
import posthog from "posthog-js"
22

3-
posthog.init(process.env.POSTHOG_KEY!, {
4-
api_host: "/blob",
5-
ui_host: process.env.POSTHOG_UI_HOST || "https://eu.posthog.com",
6-
defaults: '2025-05-24',
7-
person_profiles: 'always',
8-
capture_exceptions: true, // This enables capturing exceptions using Error Tracking, set to false if you don't want this
9-
debug: process.env.NODE_ENV === "development",
10-
})
3+
const POSTHOG_KEY = (process.env.NEXT_PUBLIC_POSTHOG_KEY as string) || process.env.POSTHOG_KEY
4+
const POSTHOG_UI_HOST = (process.env.NEXT_PUBLIC_POSTHOG_UI_HOST as string) || process.env.POSTHOG_UI_HOST || "https://eu.posthog.com"
5+
6+
if (typeof window !== "undefined") {
7+
if (POSTHOG_KEY) {
8+
posthog.init(POSTHOG_KEY, {
9+
api_host: "/blob",
10+
ui_host: POSTHOG_UI_HOST,
11+
defaults: '2025-05-24',
12+
person_profiles: 'always',
13+
capture_exceptions: true, // This enables capturing exceptions using Error Tracking, set to false if you don't want this
14+
debug: process.env.NODE_ENV === "development",
15+
})
16+
// Helpful debug to confirm initialization in the browser console
17+
if (process.env.NODE_ENV === "development") {
18+
console.debug("PostHog initialized", { POSTHOG_KEY: POSTHOG_KEY ? "<present>" : "<missing>", POSTHOG_UI_HOST })
19+
}
20+
} else {
21+
if (process.env.NODE_ENV === "development") {
22+
console.debug("PostHog not initialized: POSTHOG key missing on client")
23+
}
24+
}
25+
}

next.config.ts

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,16 @@ import type { NextConfig } from "next";
22

33
const nextConfig: NextConfig = {
44
/* config options here */
5+
images: {
6+
remotePatterns: [
7+
{
8+
protocol: 'https',
9+
hostname: 'hsp-ec.xyz',
10+
port: '',
11+
pathname: '/**',
12+
},
13+
],
14+
},
515

616
// Configure webpack to ignore LICENSE files
717
webpack: (config) => {

package-lock.json

Lines changed: 36 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -16,6 +16,7 @@
1616
"@heroicons/react": "^2.2.0",
1717
"@libsql/client": "^0.15.15",
1818
"@vercel/analytics": "^1.5.0",
19+
"@vercel/speed-insights": "^1.2.0",
1920
"@yudiel/react-qr-scanner": "^2.3.1",
2021
"@zxing/browser": "^0.1.5",
2122
"dotenv": "^17.2.2",

public/favicon.svg

Lines changed: 14 additions & 0 deletions
Loading

public/manifest.json

Lines changed: 16 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6,12 +6,24 @@
66
"scope": "/",
77
"display": "standalone",
88
"background_color": "#ffffff",
9-
"theme_color": "#4f46e5",
9+
"theme_color": "#6d28d9",
1010
"icons": [
1111
{
12-
"src": "/favicon.ico",
13-
"sizes": "256x256",
14-
"type": "image/x-icon",
12+
"src": "/favicon.svg",
13+
"sizes": "any",
14+
"type": "image/svg+xml",
15+
"purpose": "any"
16+
},
17+
{
18+
"src": "/favicon-192.png",
19+
"sizes": "192x192",
20+
"type": "image/png",
21+
"purpose": "any"
22+
},
23+
{
24+
"src": "/favicon-512.png",
25+
"sizes": "512x512",
26+
"type": "image/png",
1527
"purpose": "any"
1628
}
1729
]

public/signin-hero.svg

Lines changed: 10 additions & 0 deletions
Loading

src/app/auth/signin/page.tsx

Lines changed: 53 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,13 +16,32 @@ function SignInContent() {
1616
await signIn(provider, { callbackUrl });
1717
};
1818

19+
// Read hero image env var (trim to avoid whitespace-only values)
20+
const heroImage = (process.env.NEXT_PUBLIC_SIGNIN_IMAGE || "").trim();
21+
1922
return (
2023
<div className="flex min-h-screen flex-col items-center justify-center p-6 bg-gray-50">
2124
<div className="w-full max-w-md p-8 space-y-8 bg-white rounded-lg shadow-md">
2225
<div className="text-center">
23-
<h1 className="text-3xl font-bold">Welcome to eloop</h1>
26+
{/* Optional hero image (kept at top) - only render if an image is configured */}
27+
{heroImage ? (
28+
<div className="mx-auto mb-4 w-40 h-24 relative">
29+
<Image
30+
src={heroImage}
31+
alt={process.env.NEXT_PUBLIC_SIGNIN_TITLE || "Sign in"}
32+
fill
33+
sizes="160px"
34+
style={{ objectFit: "contain" }}
35+
/>
36+
</div>
37+
) : null}
38+
39+
<h1 className="text-3xl font-bold">
40+
{process.env.NEXT_PUBLIC_SIGNIN_TITLE || "Welcome to eloop"}
41+
</h1>
2442
<p className="mt-2 text-gray-600">
25-
Sign in to access our event management system
43+
{process.env.NEXT_PUBLIC_SIGNIN_SUBTITLE ||
44+
"Sign in to access our event management system"}
2645
</p>
2746
</div>
2847

@@ -44,6 +63,38 @@ function SignInContent() {
4463
<span>Sign in with Google</span>
4564
</button>
4665
</div>
66+
67+
{/* Powered by footer */}
68+
<div className="mt-6 text-center text-sm text-gray-500 flex items-center justify-center gap-2">
69+
<span className="text-gray-400">powered by</span>
70+
71+
<a
72+
href="https://github.com/homebrew-ec-foss/eloop"
73+
target="_blank"
74+
rel="noopener noreferrer"
75+
className="font-semibold text-gray-800 hover:text-indigo-600"
76+
aria-label="Eloop on GitHub"
77+
>
78+
eloop:
79+
</a>
80+
<a
81+
href="https://hsp-ec.xyz"
82+
target="_blank"
83+
rel="noopener noreferrer"
84+
className="inline-flex items-center justify-center w-5 h-5 ml-0"
85+
aria-label="HSP site"
86+
>
87+
<div className="w-5 h-5 relative">
88+
<Image
89+
src={process.env.NEXT_PUBLIC_HSP_LOGO || "https://hsp-ec.xyz/static/images/hsplogo.svg"}
90+
alt={"HSP logo"}
91+
fill
92+
sizes="20px"
93+
style={{ objectFit: "contain" }}
94+
/>
95+
</div>
96+
</a>
97+
</div>
4798
</div>
4899
</div>
49100
);

0 commit comments

Comments
 (0)