Skip to content

adds homepage content and contact form#80

Merged
skuhlmann merged 1 commit into
mainfrom
dh-raid
Jun 4, 2026
Merged

adds homepage content and contact form#80
skuhlmann merged 1 commit into
mainfrom
dh-raid

Conversation

@skuhlmann

@skuhlmann skuhlmann commented Jun 4, 2026

Copy link
Copy Markdown
Contributor

Summary by CodeRabbit

  • New Features

    • Added a new contact page with an interactive contact form that collects user information and handles submissions with validation, error handling, and success confirmation messages.
  • Chores

    • Added a new client entry to the clients list.

@vercel

vercel Bot commented Jun 4, 2026

Copy link
Copy Markdown

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
website Ready Ready Preview, Comment Jun 4, 2026 5:41pm

Request Review

@coderabbitai

coderabbitai Bot commented Jun 4, 2026

Copy link
Copy Markdown

Review Change Stack

Caution

Review failed

The pull request is closed.

ℹ️ Recent review info
⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 7ec7fb57-c908-4976-96d2-210791520379

📥 Commits

Reviewing files that changed from the base of the PR and between 7c871ab and 6fe1a0e.

📒 Files selected for processing (8)
  • public/images/ship-front-c.webp
  • src/app/api/contact/route.ts
  • src/app/contact/page.tsx
  • src/components/ContactForm.tsx
  • src/lib/analytics.ts
  • src/lib/data/clients.ts
  • src/lib/server-analytics.ts
  • src/lib/validation.ts

📝 Walkthrough

Walkthrough

A new contact form feature is added, enabling users to submit contact requests. The implementation includes validation schemas, a client-side React form component, a new contact page layout, a server-side API endpoint with Discord and email notifications via SendGrid, and analytics instrumentation for tracking submissions and failures. A new client entry (daohaus) is also added to the client data.

Changes

Contact Form Feature

Layer / File(s) Summary
Validation schemas and types
src/lib/validation.ts
contactFormSchema defines email and automationNeeds fields; contactApiSchema and ContactFormData type are exported for use in form and API layers.
ContactForm component
src/components/ContactForm.tsx
Client-side form uses react-hook-form with Zod validation, submits to /api/contact, manages loading/success/error states, tracks analytics for submit attempts and outcomes, and displays error or success messaging.
Contact page layout
src/app/contact/page.tsx
New contact page with Next.js metadata, hero section with image, dynamically rendered engagement-steps list, embedded ContactForm component, and Footer.
API handler and notifications
src/app/api/contact/route.ts
POST endpoint validates submissions with contactApiSchema, constructs contact summary, formats and sends notifications concurrently to Discord (truncated) and SendGrid email (with HTML escaping and newline conversion), tracks server analytics for success/failure, handles exceptions, and returns appropriate HTTP status codes.
Analytics event definitions
src/lib/analytics.ts, src/lib/server-analytics.ts
Client-side analyticsEvents extended with contactFormSubmitAttempt, contactFormSubmitSuccess, and contactFormSubmitError; server-side serverAnalyticsEvents extended with contactSubmitted and contactSubmitFailed.
Client metadata
src/lib/data/clients.ts
New daohaus client entry added to clientData array with logo, sizing, title, description, and tags.

Sequence Diagram

sequenceDiagram
  participant Client
  participant ContactForm
  participant APIHandler
  participant Discord
  participant SendGrid
  participant Analytics
  Client->>ContactForm: submit form (email, automationNeeds)
  ContactForm->>APIHandler: POST /api/contact (JSON)
  Analytics->>Analytics: track contactFormSubmitAttempt
  APIHandler->>APIHandler: validate with contactApiSchema
  APIHandler->>Discord: POST message with summary
  APIHandler->>SendGrid: POST email with text+HTML
  Discord->>APIHandler: response (success or error)
  SendGrid->>APIHandler: response (success or error)
  APIHandler->>Analytics: track contactSubmitted or contactSubmitFailed
  APIHandler->>ContactForm: return 200 or 500
  ContactForm->>Analytics: track contactFormSubmitSuccess or contactFormSubmitError
  ContactForm->>Client: show success/error message
Loading

Estimated code review effort

🎯 3 (Moderate) | ⏱️ ~20 minutes

Poem

A contact form hops in, neat and clean,
With validation schemas in between,
Discord and email dance their part,
Analytics track every start,
The journey from submission to reply—
🐰 success tracking flies high!

✨ Finishing Touches
📝 Generate docstrings
  • Create stacked PR
  • Commit on current branch
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch dh-raid

Warning

There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure.

🔧 ESLint

If the error stems from missing dependencies, add them to the package.json file. For unrecoverable errors (e.g., due to private dependencies), disable the tool in the CodeRabbit configuration.

src/app/api/contact/route.ts

ESLint skipped: missing config or dependency (missing-dependency). The ESLint configuration references a package that is not available in the sandbox.

src/app/contact/page.tsx

ESLint skipped: the ESLint configuration for this file references a package that is not available in the sandbox.

src/components/ContactForm.tsx

ESLint skipped: the ESLint configuration for this file references a package that is not available in the sandbox.

  • 4 others

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@skuhlmann skuhlmann merged commit b930ae9 into main Jun 4, 2026
2 of 3 checks passed
@skuhlmann skuhlmann deleted the dh-raid branch June 4, 2026 17:42
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant