Add app source and tests
Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
This commit is contained in:
33
lib/main.dart
Normal file
33
lib/main.dart
Normal file
@@ -0,0 +1,33 @@
|
||||
import 'package:flutter/material.dart';
|
||||
|
||||
import 'Peach/configs/ThemeController.dart';
|
||||
import 'Peach/designs/Backdrop.dart';
|
||||
import 'Peach/see/splash/Splash.dart';
|
||||
import 'Peach/utils/Colors.dart';
|
||||
|
||||
void main() {
|
||||
runApp(const Peach());
|
||||
}
|
||||
|
||||
/// The app shell: theme, the glow backdrop, and the splash that loads stored
|
||||
/// state before handing over to Home. Everything else lives under
|
||||
/// `lib/Peach/see/` as a four-file screen.
|
||||
class Peach extends StatelessWidget {
|
||||
const Peach({super.key});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return ValueListenableBuilder<ThemeMode>(
|
||||
valueListenable: ThemeController.mode,
|
||||
builder: (context, mode, child) => MaterialApp(
|
||||
title: 'Peach',
|
||||
debugShowCheckedModeBanner: false,
|
||||
theme: PeachTheme.light(),
|
||||
darkTheme: PeachTheme.dark(),
|
||||
themeMode: mode,
|
||||
builder: (context, child) => Backdrop(child: child ?? const SizedBox()),
|
||||
home: const Splash(),
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user