Files
crosscode-platform/apps/events/frontend/src/content/help/general.tsx
T
joshuaandClaude Sonnet 5 5c2e29ed1b Full site redesign, help system, and dashboard stats fixes
Multi-phase visual facelift (design tokens, dashboards, sidebar/navbar
shell, per-page help guides, and a layout/content pass across every
remaining page) plus backend fixes to the dashboard KPI stats:

- Admin/Supervisor dashboard KPIs (revenue, donations, registrations,
  tickets sold) now use a rolling trailing-month window (today back one
  calendar month, e.g. 9 May - 8 June if today is 8 June) instead of
  calendar month-to-date, which under-counted for most of the month.
  The comparison window shifts the same way, so like is still compared
  with like.
- Reports deep-links from those stat tiles now match the same window
  (range=trailing_month, replacing range=this_month).
- Design tokens (brand-* Tailwind scale + shadcn CSS variables), a
  site-wide contextual help button, fixed dashboard sidebar/navbar,
  Admin/Supervisor/Staff/User dashboard rebuilds backed by a new
  GET /api/stats/overview endpoint, a dedicated Contact page, Site
  Settings restyle with WhatsApp config folded in, and an Account
  activity feed backed by a new SecurityEvent model.
- Every remaining page (home, events, registration flow, auth, legal,
  payment results, and every Admin/Supervisor/Staff/User tool page)
  restyled onto the same design tokens, several with real layout
  upgrades (home hero, events list/detail, donate page, auth pages).
- 20+ new dedicated help guides so the whole site has page-specific
  help content instead of falling back to a generic guide.
- Assorted fixes surfaced along the way: donation-leg double-counting
  in payment stats, donations not counting toward revenue, refund
  netting in per-method report breakdowns, and donation
  over-allocation after a refund.

Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>
2026-08-06 15:00:10 +02:00

99 lines
4.7 KiB
TypeScript

import React from "react";
import { Search, UserPlus, CreditCard, Calendar, Ticket, LogIn, KeyRound, MessageCircleQuestion, Phone } from "lucide-react";
import { GuideItem } from "@/components/shared/GuideItem";
import type { HelpContent } from "./types";
/**
* Baseline help content shown on any page without its own dedicated guide
* (all public pages, and the ultimate fallback everywhere else). Covers the
* things every visitor needs to know: how to register for an event
* (with or without an account), and how to find/manage a registration
* afterwards.
*/
export const generalHelpContent: HelpContent = {
title: "Need a hand?",
subtitle: "Here's how booking and managing your tickets works.",
quickLinks: [
{ label: "Browse events", href: "/events", icon: Calendar },
{ label: "Log in", href: "/login", icon: LogIn },
{ label: "Create an account", href: "/register", icon: UserPlus },
{ label: "View my tickets", href: "/dashboard/user", icon: Ticket },
{ label: "Contact us", href: "/contact", icon: Phone },
],
tabs: [
{
key: "register",
label: "Booking a ticket",
icon: Calendar,
content: (
<div className="space-y-4">
<p>Booking a spot at an event only takes a few minutes:</p>
<div className="space-y-4">
<GuideItem icon={Search} title="Browse events" tone="brand">
Head to the Events page to see what&apos;s coming up.
</GuideItem>
<GuideItem icon={UserPlus} title="Register" tone="green">
Open an event and tap Register to reserve your spot with your details. Some events let you register as a guest, others ask you to sign in first — see the &quot;Accounts &amp; login&quot; tab for the difference.
</GuideItem>
<GuideItem icon={CreditCard} title="Pay if required" tone="amber">
Some events need payment to confirm your spot — pay securely online, or come back and pay later from your dashboard.
</GuideItem>
</div>
</div>
),
},
{
key: "accounts",
label: "Accounts & login",
icon: LogIn,
content: (
<div className="space-y-4">
<p>Whether you need an account depends on the event — the registration form always makes it clear which applies.</p>
<div className="space-y-4">
<GuideItem icon={Ticket} title="Guest registration" tone="green">
For some events you can register with just your name and email address — no password, no account. You&apos;ll get your tickets by email (or WhatsApp, if you provide a number).
</GuideItem>
<GuideItem icon={KeyRound} title="Account required" tone="amber">
Other events ask you to sign in or create a free account before you can register. If you see this, use the &quot;Log in&quot; or &quot;Create an account&quot; quick link above — it only takes a minute.
</GuideItem>
<GuideItem icon={LogIn} title="Why create an account?" tone="brand">
An account puts every registration and ticket you&apos;ve ever booked in one place (your dashboard), and you won&apos;t need to retype your details next time. It&apos;s also required to view or manage a registration after you&apos;ve made it, even if that specific event allowed guest booking.
</GuideItem>
</div>
</div>
),
},
{
key: "manage",
label: "Your tickets & registrations",
icon: Ticket,
content: (
<div className="space-y-4">
<p>Once you&apos;re registered, sign in and go to your dashboard to view and manage everything — you&apos;ll need to be logged in to see this, even if you registered as a guest.</p>
<div className="space-y-4">
<GuideItem icon={Calendar} title="My Events" tone="brand">
Your dashboard shows every registration and upcoming event in one place.
</GuideItem>
<GuideItem icon={Ticket} title="Tickets" tone="violet">
Each ticket has a QR code — print it, email it to yourself, or send it via WhatsApp.
</GuideItem>
<GuideItem icon={CreditCard} title="Payments" tone="green">
Check what you&apos;ve paid and what&apos;s still outstanding right from your dashboard.
</GuideItem>
</div>
</div>
),
},
{
key: "help",
label: "Still need help?",
icon: MessageCircleQuestion,
content: (
<div className="space-y-4">
<p>If you can&apos;t find what you&apos;re looking for, reach out — use the Contact link at the top of the site, or the Contact page linked above.</p>
</div>
),
},
],
};