import React from 'react'; import { useNavigate } from 'react-router-dom'; import { useTranslation } from 'react-i18next'; import { HelpCircle, Mail, ShieldCheck } from 'lucide-react'; import { YStack, XStack } from '@tamagui/stacks'; import { SizableText as Text } from '@tamagui/text'; import { Button } from '@tamagui/button'; import { ADMIN_LOGIN_PATH } from '../constants'; import { MobileCard, CTAButton } from './components/Primitives'; import { ADMIN_GRADIENTS, useAdminTheme } from './theme'; import { useDocumentTitle } from './hooks/useDocumentTitle'; type FaqItem = { question: string; answer: string; }; export default function PublicHelpPage() { const { t } = useTranslation('auth'); const navigate = useNavigate(); const { text, muted, surface, border, accentSoft, primary } = useAdminTheme(); const faqItems = t('login.help_faq_items', { returnObjects: true, defaultValue: [ { question: 'I did not receive an invite.', answer: 'Please check spam and ask your event team to resend the invitation.', }, { question: 'I cannot sign in.', answer: 'Sign-in works only with your email address. Your username equals your email.', }, { question: 'My event is not visible.', answer: 'Make sure the event is published. Ask the owner to adjust the status.', }, { question: 'Uploads are slow or stuck.', answer: 'Wait a moment and check the connection. If it persists, contact support.', }, ], }) as FaqItem[]; const safeAreaStyle: React.CSSProperties = { paddingTop: 'calc(env(safe-area-inset-top, 0px) + 16px)', paddingBottom: 'calc(env(safe-area-inset-bottom, 0px) + 16px)', }; useDocumentTitle(t('login.help_title', 'Help for event admins')); return ( {t('login.help_title', 'Hilfe fuer Event-Admins')} {t( 'login.help_intro', 'Hier findest du schnelle Antworten rund um Login, Zugriff und erste Schritte - auch ohne Anmeldung.', )} {t('login.help_faq_title', 'Haeufige Fragen vor dem Login')} {faqItems.map((item, index) => ( {item.question} {item.answer} ))} {t('login.help_support_title', 'Support kontaktieren')} {t('login.help_support_copy', 'Schreib uns bei Fragen an')}{' '} support@fotospiel.app { window.location.href = 'mailto:support@fotospiel.app'; }} /> ); }