feat: initial commit for AeroTrack Flutter app
This commit is contained in:
@@ -0,0 +1,38 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'services/storage_service.dart';
|
||||
import 'screens/home_screen.dart';
|
||||
|
||||
void main() async {
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
final storageService = await StorageService.init();
|
||||
runApp(AeroTrackApp(storageService: storageService));
|
||||
}
|
||||
|
||||
class AeroTrackApp extends StatelessWidget {
|
||||
final StorageService storageService;
|
||||
|
||||
const AeroTrackApp({super.key, required this.storageService});
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return MaterialApp(
|
||||
title: 'AeroTrack 雾化记录',
|
||||
debugShowCheckedModeBanner: false,
|
||||
theme: ThemeData(
|
||||
colorScheme: ColorScheme.fromSeed(
|
||||
seedColor: const Color(0xFF2563EB),
|
||||
primary: const Color(0xFF2563EB),
|
||||
surface: Colors.white,
|
||||
),
|
||||
useMaterial3: true,
|
||||
scaffoldBackgroundColor: const Color(0xFFF8FAFC),
|
||||
appBarTheme: const AppBarTheme(
|
||||
backgroundColor: Colors.white,
|
||||
foregroundColor: Color(0xFF0F172A),
|
||||
elevation: 0,
|
||||
),
|
||||
),
|
||||
home: HomeScreen(storageService: storageService),
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user