This repository has been archived on 2026-08-19. You can view files and clone it. You cannot open issues or pull requests or push a commit.
Files
melo-app/lib/utils/farb_theme.dart
T
Hermes (Server) 19e4aac62e Feature: Login-Effekte pro Person (Akzentfarbe + Sound + Begruessung)
- UserEffekt: Baka = rot + Fanfare, Tinker = tuerkis + Chime, Standard-Ping
- MeloTheme: dynamische Akzentfarbe via ValueNotifier (Theme wechselt live)
- Ausloeser: App-Start (wenn Token vorhanden) + nach erfolgreichem Login
- Assets: 3 kurze WAV-Sounds (assets/sounds/)
- Web: /whoami-Endpoint (Caddy) + Willkommens-Banner auf baka-net.de
2026-07-31 15:34:04 +02:00

52 lines
1.7 KiB
Dart
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
import 'package:flutter/material.dart';
class MeloTheme {
static const Color rot = Color(0xFFCC0000);
static const Color rotHell = Color(0x33CC0000);
static const Color schwarz = Color(0xFF0D0D0D);
static const Color dunkel1 = Color(0xFF1A1A1A);
static const Color dunkel2 = Color(0xFF2A2A2A);
static const Color textPrimaer = Color(0xFFFFFFFF);
static const Color textSekundaer = Color(0xFF888888);
/// Akzentfarbe wechselt pro angemeldeter Person (Login-Effekt).
/// UI hängt per ValueListenableBuilder an [akzentNotifier].
static final ValueNotifier<Color> akzentNotifier = ValueNotifier<Color>(rot);
static Color get akzent => akzentNotifier.value;
static set akzent(Color farbe) => akzentNotifier.value = farbe;
static ThemeData get theme => ThemeData(
brightness: Brightness.dark,
scaffoldBackgroundColor: schwarz,
colorScheme: ColorScheme.dark(
primary: akzent,
secondary: akzent,
surface: schwarz,
),
appBarTheme: const AppBarTheme(
backgroundColor: schwarz,
foregroundColor: textPrimaer,
elevation: 0,
),
bottomNavigationBarTheme: BottomNavigationBarThemeData(
backgroundColor: schwarz,
selectedItemColor: akzent,
unselectedItemColor: textSekundaer,
),
cardTheme: CardThemeData(
color: dunkel1,
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(14),
),
),
chipTheme: ChipThemeData(
backgroundColor: dunkel1,
selectedColor: akzent,
labelStyle: const TextStyle(color: textPrimaer),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(20),
),
),
);
}