weiterer fortschritt mit tamagui und dem neuen mobile event admin

This commit is contained in:
Codex Agent
2025-12-10 20:01:47 +01:00
parent 73e550ee87
commit 7b01a77083
26 changed files with 761 additions and 139 deletions

View File

@@ -5,14 +5,12 @@ import { Bell, RefreshCcw } from 'lucide-react';
import { YStack, XStack } from '@tamagui/stacks';
import { SizableText as Text } from '@tamagui/text';
import { Pressable } from '@tamagui/react-native-web-lite';
import { MobileScaffold } from './components/Scaffold';
import { MobileShell } from './components/MobileShell';
import { MobileCard, PillBadge } from './components/Primitives';
import { BottomNav } from './components/BottomNav';
import { GuestNotificationSummary, listGuestNotifications } from '../api';
import { isAuthError } from '../auth/tokens';
import { getApiErrorMessage } from '../lib/apiError';
import toast from 'react-hot-toast';
import { useMobileNav } from './hooks/useMobileNav';
import { MobileSheet } from './components/Sheet';
import { getEvents, TenantEvent } from '../api';
@@ -47,7 +45,6 @@ export default function MobileAlertsPage() {
const [alerts, setAlerts] = React.useState<AlertItem[]>([]);
const [loading, setLoading] = React.useState(true);
const [error, setError] = React.useState<string | null>(null);
const { go } = useMobileNav(slug ?? null);
const [events, setEvents] = React.useState<TenantEvent[]>([]);
const [showEventPicker, setShowEventPicker] = React.useState(false);
@@ -84,17 +81,15 @@ export default function MobileAlertsPage() {
}, []);
return (
<MobileScaffold
<MobileShell
activeTab="home"
title={t('alerts.title', 'Alerts')}
onBack={() => navigate(-1)}
rightSlot={
headerActions={
<Pressable onPress={() => reload()}>
<RefreshCcw size={18} color="#0f172a" />
</Pressable>
}
footer={
<BottomNav active="home" onNavigate={go} />
}
>
{error ? (
<MobileCard>
@@ -192,6 +187,6 @@ export default function MobileAlertsPage() {
)}
</YStack>
</MobileSheet>
</MobileScaffold>
</MobileShell>
);
}