feat: Phase 1 foundation - core infrastructure and navigation
Clean Architecture structure: - core/config - Environment configuration - core/theme - Material 3 theming with FlexColorScheme - core/error - Typed exception hierarchy - core/api - Dio HTTP clients with interceptors - core/auth - Authentication state management - routing - go_router with shell navigation - shared/layouts - Adaptive scaffold Dependencies added: - flutter_riverpod, riverpod_annotation, riverpod_generator - freezed, freezed_annotation, json_serializable - dio, go_router, shared_preferences - flex_color_scheme, flutter_adaptive_scaffold Features: - Responsive navigation (rail on desktop, bottom on mobile) - Dashboard placeholder with welcome card - Theme switching infrastructure - API client ready for Core API and Tatlock API 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude Opus 4.5 <noreply@anthropic.com>
This commit is contained in:
@@ -0,0 +1,40 @@
|
||||
/// Application configuration from compile-time environment variables.
|
||||
///
|
||||
/// Set via: flutter build --dart-define=API_URL=https://...
|
||||
class AppConfig {
|
||||
AppConfig._();
|
||||
|
||||
/// Core API base URL
|
||||
static const coreApiUrl = String.fromEnvironment(
|
||||
'CORE_API_URL',
|
||||
defaultValue: 'https://api.schweitz.net',
|
||||
);
|
||||
|
||||
/// Tatlock API base URL
|
||||
static const tatlockApiUrl = String.fromEnvironment(
|
||||
'TATLOCK_API_URL',
|
||||
defaultValue: 'https://tatlock.schweitz.net',
|
||||
);
|
||||
|
||||
/// Authentik OIDC discovery URL
|
||||
static const authDiscoveryUrl = String.fromEnvironment(
|
||||
'AUTH_DISCOVERY_URL',
|
||||
defaultValue:
|
||||
'https://auth.schweitz.net/application/o/tatlock-ui/.well-known/openid-configuration',
|
||||
);
|
||||
|
||||
/// Authentik client ID
|
||||
static const authClientId = String.fromEnvironment(
|
||||
'AUTH_CLIENT_ID',
|
||||
defaultValue: 'tatlock-ui',
|
||||
);
|
||||
|
||||
/// Authentik redirect URI scheme
|
||||
static const authRedirectScheme = String.fromEnvironment(
|
||||
'AUTH_REDIRECT_SCHEME',
|
||||
defaultValue: 'net.schweitz.tatlock',
|
||||
);
|
||||
|
||||
/// Whether running in debug mode
|
||||
static const isDebug = bool.fromEnvironment('DEBUG', defaultValue: false);
|
||||
}
|
||||
Reference in New Issue
Block a user