feat: Stadium Elite Design, Rangliste, Profil-Team, User-Upsert & n8n Cronjob

- MatchCard + TipModal: Uhrzeit statt VS zwischen Flaggen, Gruppe zentriert
- LeaderboardPage: Podium (2./1./3.), DU-Badge, Trend-Pfeile, Team-Zeile, CTA-Card
- AdminPage: Stadium Elite Redesign mit Result-Bar und Inline-Spinner
- ProfilePage: Team-Feld inline editierbar (PATCH /api/profile/team)
- User-Upsert beim ersten App-Aufruf (Matches-Route) statt erst beim Tipp
- DB Migration 002: team-Spalte in users, Leaderboard View aktualisiert
- Leaderboard-Refresh automatisch nach Tipps-Auswertung
- n8n Workflow angelegt: stündlicher Sync + Auswertung (ID: t3SDspIGDXwkfOt3)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Ronny Mueller
2026-04-03 23:37:38 +02:00
parent e967f36f6c
commit e27a62a37b
20 changed files with 1515 additions and 297 deletions
+10
View File
@@ -39,6 +39,13 @@ export const api = {
getMyStats: () =>
request<UserStats>('/leaderboard/me'),
// Profile
updateTeam: (team: string) =>
request<{ success: boolean; team: string }>('/profile/team', {
method: 'PATCH',
body: JSON.stringify({ team }),
}),
// Admin
syncMatches: () =>
request<{ success: boolean; total: number; created: number; updated: number }>(
@@ -88,6 +95,7 @@ export interface MyTip {
export interface LeaderboardEntry {
user_id: string;
full_name: string;
team: string | null;
total_points: number;
tips_count: number;
exact_count: number;
@@ -98,6 +106,7 @@ export interface LeaderboardEntry {
export interface LeaderboardResponse {
entries: LeaderboardEntry[];
currentUserRank: number | null;
currentUserId: string | null;
totalParticipants: number;
lastUpdated: string;
}
@@ -105,6 +114,7 @@ export interface LeaderboardResponse {
export interface UserStats {
userId: string;
fullName: string;
team: string | null;
totalPoints: number;
rank: number | null;
tipsCount: number;