feat: Initialize Flutter app with authentication and scheduling features
- Removed TypeScript configuration file (tsconfig.json). - Added Flutter plugin dependencies for secure storage. - Implemented main application structure with routing for login, profile, and schedule screens. - Developed LoginScreen with authentication logic and user feedback. - Created ProfileScreen to display user profile information and logout functionality. - Built ScheduleScreen to show weekly work schedule with navigation controls. - Integrated AuthService for handling authentication, token storage, and API interactions. - Updated pubspec.yaml with necessary dependencies for the Flutter project.
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 'package:provider/provider.dart';
|
||||
|
||||
import 'screens/login_screen.dart';
|
||||
import 'screens/profile_screen.dart';
|
||||
import 'screens/schedule_screen.dart';
|
||||
import 'services/auth_service.dart';
|
||||
|
||||
void main() {
|
||||
runApp(MyApp());
|
||||
}
|
||||
|
||||
class MyApp extends StatelessWidget {
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
return ChangeNotifierProvider(
|
||||
create: (_) => AuthService(),
|
||||
child: MaterialApp(
|
||||
title: 'ISO Flutter',
|
||||
theme: ThemeData.dark().copyWith(
|
||||
primaryColor: Color(0xFFA24BFA),
|
||||
scaffoldBackgroundColor: Color(0xFF0c0a0a),
|
||||
),
|
||||
initialRoute: '/',
|
||||
routes: {
|
||||
'/': (context) => LoginScreen(),
|
||||
'/profile': (context) => ProfileScreen(),
|
||||
'/schedule': (context) => ScheduleScreen(),
|
||||
},
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user