Commit 2db64725 authored by Uditha Prabhasha 's avatar Uditha Prabhasha

init project

parent 6c0f32f5
File added
<?xml version="1.0" encoding="UTF-8"?>
<module type="JAVA_MODULE" version="4">
<component name="NewModuleRootManager" inherit-compiler-output="true">
<exclude-output />
<content url="file://$MODULE_DIR$">
<sourceFolder url="file://$MODULE_DIR$/lib" isTestSource="false" />
<sourceFolder url="file://$MODULE_DIR$/test" isTestSource="true" />
<excludeFolder url="file://$MODULE_DIR$/.dart_tool" />
<excludeFolder url="file://$MODULE_DIR$/.idea" />
<excludeFolder url="file://$MODULE_DIR$/build" />
</content>
<orderEntry type="sourceFolder" forTests="false" />
<orderEntry type="library" name="Dart SDK" level="project" />
<orderEntry type="library" name="Flutter Plugins" level="project" />
<orderEntry type="library" name="Dart Packages" level="project" />
</component>
</module>
import 'package:awesome_dialog/awesome_dialog.dart';
import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart';
import 'package:jema_app/teacherhome.dart';
class AddClassroomPage extends StatefulWidget {
@override
_AddClassroomPageState createState() => _AddClassroomPageState();
}
final _formkey = GlobalKey<FormState>();
final _auth = FirebaseAuth.instance;
class _AddClassroomPageState extends State<AddClassroomPage> {
final TextEditingController classNameController = TextEditingController();
final TextEditingController roomCapacityController = TextEditingController();
final TextEditingController ratioController = TextEditingController();
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text('Add Classroom'),
),
body: Center(
child: Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.center,
mainAxisAlignment: MainAxisAlignment.center,
children: [
Image.asset(
'lib/assets/addclassroom.png',
height: 260,
width: 340,
fit: BoxFit.contain,
),
SizedBox(height: 20),
TextField(
controller: classNameController,
decoration: InputDecoration(
labelText: 'Classroom Name',
suffixIcon: Icon(Icons.school), // Classroom icon
),
),
SizedBox(height: 10),
TextField(
controller: roomCapacityController,
decoration: InputDecoration(
labelText: 'Room Capacity',
suffixIcon: Icon(Icons.people), // People icon
),
keyboardType: TextInputType.number,
),
SizedBox(height: 10),
TextField(
controller: ratioController,
decoration: InputDecoration(
labelText: 'Student to Staff Ratio',
suffixIcon: Icon(Icons.numbers), // Your ratio icon
),
keyboardType: TextInputType.number,
),
SizedBox(height: 20),
ElevatedButton(
onPressed: () {
postDetailsToFirestore(context);
},
child: Text('Create Classroom'),
),
],
),
),
),
);
}
postDetailsToFirestore(context) async {
FirebaseFirestore firebaseFirestore = FirebaseFirestore.instance;
var user = _auth.currentUser;
CollectionReference ref =
FirebaseFirestore.instance.collection('classroom');
print("class == : " + classNameController.text);
ref.doc(classNameController.text).set({
"className": classNameController.text,
'roomCapacity': roomCapacityController.text,
'ratio': ratioController.text,
'userId': user!.uid,
});
AwesomeDialog(
context: context,
dialogType: DialogType.success,
animType: AnimType.rightSlide,
title: 'Successfully Created',
desc: ' Go to Home page',
btnOkOnPress: () {
Navigator.pushReplacement(context,
MaterialPageRoute(builder: (context) => TeacherHomePage()));
},
)..show();
}
}
import 'package:flutter/material.dart';
class AddStudentPage extends StatefulWidget {
@override
_AddStudentPageState createState() => _AddStudentPageState();
}
class _AddStudentPageState extends State<AddStudentPage> {
String _selectedSex = 'Male';
bool _isSpecialNeedsChild = false;
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text('Add Student'),
),
body: Padding(
padding: const EdgeInsets.all(16.0),
child: SingleChildScrollView(
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: <Widget>[
CircleAvatar(
radius: 50,
// Add logic to handle profile image selection
// backgroundImage: AssetImage('path_to_profile_image'),
),
SizedBox(height: 16),
buildTextFormField('First Name', 'Enter first name'),
buildTextFormField('Last Name', 'Enter last name'),
buildDateOfBirthField(),
buildSexDropdown(),
buildMedicineFields(),
buildSpecialNeedsFields(),
SizedBox(height: 16),
ElevatedButton(
onPressed: () {
// Add logic to save student data
// Navigator.pop(context); // Navigate back after saving
},
child: Text('Save Student'),
),
],
),
),
),
);
}
Widget buildTextFormField(String label, String hint) {
return Padding(
padding: const EdgeInsets.symmetric(vertical: 8.0),
child: TextFormField(
decoration: InputDecoration(
labelText: label,
hintText: hint,
),
),
);
}
Widget buildDateOfBirthField() {
return Padding(
padding: const EdgeInsets.symmetric(vertical: 8.0),
child: TextFormField(
readOnly: true,
onTap: () async {
// Add logic to show date picker
// final DateTime picked = await showDatePicker(
// context: context,
// initialDate: DateTime.now(),
// firstDate: DateTime(2000),
// lastDate: DateTime(2101),
// );
// if (picked != null && picked != DateTime.now()) {
// // Handle the selected date
// }
},
decoration: InputDecoration(
labelText: 'Date of Birth',
hintText: 'Select date of birth',
),
),
);
}
Widget buildSexDropdown() {
return Padding(
padding: const EdgeInsets.symmetric(vertical: 8.0),
child: DropdownButtonFormField<String>(
value: _selectedSex,
onChanged: (value) {
setState(() {
_selectedSex = value!;
});
},
items: ['Male', 'Female'].map((sex) {
return DropdownMenuItem<String>(
value: sex,
child: Text(sex),
);
}).toList(),
decoration: InputDecoration(
labelText: 'Sex',
),
),
);
}
Widget buildMedicineFields() {
return Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
buildTextFormField('Doctor Name', 'Enter doctor name'),
buildTextFormField('Doctor Phone', 'Enter doctor phone'),
buildTextFormField('Allergies', 'Enter allergies'),
buildTextFormField('Medicine', 'Enter medicine'),
],
);
}
Widget buildSpecialNeedsFields() {
return Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
children: [
Text('Special Needs Child: '),
Checkbox(
value: _isSpecialNeedsChild,
onChanged: (value) {
setState(() {
_isSpecialNeedsChild = value!;
});
},
),
],
),
if (_isSpecialNeedsChild)
buildTextFormField('Special Note', 'Enter special note'),
],
);
}
}
void main() {
runApp(MaterialApp(
home: AddStudentPage(),
));
}
import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart';
import 'addstudent.dart';
class ClassroomViewPage extends StatelessWidget {
var documents;
late Future<List<DocumentSnapshot>> students = getStudentData();
late User? user;
ClassroomViewPage({super.key, required this.documents}) {
user = FirebaseAuth.instance.currentUser;
}
Future<List<DocumentSnapshot>> getStudentData() async {
QuerySnapshot querySnapshot =
await FirebaseFirestore.instance.collection('students').get();
return querySnapshot.docs;
}
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
leading: IconButton(
icon: Icon(Icons.arrow_back),
onPressed: () {
Navigator.pop(context);
},
),
title: Text('Class Room'),
),
body: SingleChildScrollView(
child: Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
documents, // Class name
style: TextStyle(
fontSize: 18,
fontWeight: FontWeight.bold,
),
),
SizedBox(height: 10),
ElevatedButton(
onPressed: () {
// Navigate to AddStudentPage
Navigator.push(
context,
MaterialPageRoute(builder: (context) => AddStudentPage()),
);
},
child: Text('Add Student'),
),
SizedBox(height: 10),
TextField(
decoration: InputDecoration(
hintText: 'Search...',
suffixIcon: Icon(Icons.search),
border: OutlineInputBorder(),
),
),
SizedBox(height: 10),
GridView.count(
crossAxisCount: 2,
childAspectRatio: (1 / 0.6),
shrinkWrap: true,
children: [
Padding(
padding: const EdgeInsets.all(10.0),
child: Container(
width: 170,
height: 85,
clipBehavior: Clip.antiAlias,
decoration: ShapeDecoration(
gradient: LinearGradient(
begin: Alignment(1.00, -0.01),
end: Alignment(-1, 0.01),
colors: [Color(0xFFA991D2), Color(0xFFF7C0E9)],
),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(4),
),
shadows: [
BoxShadow(
color: Color(0x3F000000),
blurRadius: 2,
offset: Offset(0, 1),
spreadRadius: 0,
)
],
),
child: Stack(
children: [
Positioned(
left: 9,
top: 23,
child: Container(
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
'Children',
style: TextStyle(
color: Colors.white,
fontSize: 16,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.06,
letterSpacing: -0.64,
),
),
const SizedBox(height: 10),
Padding(
padding: const EdgeInsets.all(8.0),
child: Text.rich(
TextSpan(
children: [
TextSpan(
text: 'All ',
style: TextStyle(
color: Colors.white,
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
height: 0.07,
letterSpacing: -0.56,
),
),
TextSpan(
text: '10',
style: TextStyle(
color: Colors.white,
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.07,
letterSpacing: -0.56,
),
),
],
),
),
),
],
),
),
),
// Add Image widget inside the Stack
Positioned(
right: 0,
bottom: 0,
child: Image.asset(
"lib/assets/Vector 2.png", // Replace with your image URL
width:
59, // Set the width as per your requirement
height:
81, // Set the height as per your requirement
fit: BoxFit
.cover, // Adjust the BoxFit property as needed
),
),
],
),
),
),
Padding(
padding: const EdgeInsets.all(10.0),
child: Container(
width: 170,
height: 85,
clipBehavior: Clip.antiAlias,
decoration: ShapeDecoration(
gradient: LinearGradient(
begin: Alignment(1.00, -0.01),
end: Alignment(-1, 0.01),
colors: [Color(0xFFEC6F9E), Color(0xFFEC8B6A)],
),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(4),
),
shadows: [
BoxShadow(
color: Color(0x3F000000),
blurRadius: 2,
offset: Offset(0, 1),
spreadRadius: 0,
)
],
),
child: Stack(
children: [
Positioned(
left: 8,
top: 23,
child: Container(
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
'Attendance',
style: TextStyle(
color: Colors.white,
fontSize: 16,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.06,
letterSpacing: -0.64,
),
),
const SizedBox(height: 8),
Padding(
padding: const EdgeInsets.all(8.0),
child: Text.rich(
TextSpan(
children: [
TextSpan(
text: 'Today ',
style: TextStyle(
color: Colors.white,
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w500,
height: 0.07,
letterSpacing: -0.56,
),
),
TextSpan(
text: '12',
style: TextStyle(
color: Colors.white,
fontSize: 14,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.07,
letterSpacing: -0.56,
),
),
],
),
),
),
],
),
),
),
Positioned(
right: 8,
bottom: 8,
child: Image.asset(
"lib/assets/Vector22.png", // Replace with your image URL
width: 59,
height: 81,
fit: BoxFit.cover,
),
),
],
),
),
),
Padding(
padding: const EdgeInsets.all(10.0),
child: Container(
width: 170,
height: 85,
clipBehavior: Clip.antiAlias,
decoration: ShapeDecoration(
gradient: LinearGradient(
begin: Alignment(1.00, -0.01),
end: Alignment(-1, 0.01),
colors: [Color(0xFF5670EC), Color(0xFF07BAFE)],
),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(4),
),
shadows: [
BoxShadow(
color: Color(0x3F000000),
blurRadius: 2,
offset: Offset(0, 1),
spreadRadius: 0,
)
],
),
child: Stack(
children: [
Positioned(
left: 8,
top: 35,
child: Container(
child: Column(
mainAxisSize: MainAxisSize.min,
mainAxisAlignment: MainAxisAlignment.start,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Text(
'Activities',
style: TextStyle(
color: Colors.white,
fontSize: 16,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.06,
letterSpacing: -0.64,
),
),
const SizedBox(height: 8),
],
),
),
),
Positioned(
right: 8,
bottom: 8,
child: Image.asset(
"lib/assets/Vector23.png", // Replace with your image URL
width: 59,
height: 81,
fit: BoxFit.cover,
),
),
],
),
),
),
]),
],
),
),
),
);
}
}
// File generated by FlutterFire CLI.
// ignore_for_file: lines_longer_than_80_chars, avoid_classes_with_only_static_members
import 'package:firebase_core/firebase_core.dart' show FirebaseOptions;
import 'package:flutter/foundation.dart'
show defaultTargetPlatform, kIsWeb, TargetPlatform;
class DefaultFirebaseOptions {
static FirebaseOptions get currentPlatform {
if (kIsWeb) {
return web;
}
switch (defaultTargetPlatform) {
case TargetPlatform.android:
return android;
case TargetPlatform.iOS:
return ios;
case TargetPlatform.macOS:
return macos;
case TargetPlatform.windows:
throw UnsupportedError(
'DefaultFirebaseOptions have not been configured for windows - '
'you can reconfigure this by running the FlutterFire CLI again.',
);
case TargetPlatform.linux:
throw UnsupportedError(
'DefaultFirebaseOptions have not been configured for linux - '
'you can reconfigure this by running the FlutterFire CLI again.',
);
default:
throw UnsupportedError(
'DefaultFirebaseOptions are not supported for this platform.',
);
}
}
static const FirebaseOptions web = FirebaseOptions(
apiKey: 'AIzaSyA-VNu0nraKLX921wfo0xlAETvSnezKCSA',
appId: '1:534654186450:web:6c63eb1660afd41fba8e0b',
messagingSenderId: '534654186450',
projectId: 'classroom-75d8f',
authDomain: 'classroom-75d8f.firebaseapp.com',
storageBucket: 'classroom-75d8f.appspot.com',
measurementId: 'G-R7676GHN7C',
);
static const FirebaseOptions android = FirebaseOptions(
apiKey: 'AIzaSyDuW4dw6QbPc9QJwYAHltnrDtvBTfUeB04',
appId: '1:534654186450:android:c1708c45dad3296cba8e0b',
messagingSenderId: '534654186450',
projectId: 'classroom-75d8f',
storageBucket: 'classroom-75d8f.appspot.com',
);
static const FirebaseOptions ios = FirebaseOptions(
apiKey: 'AIzaSyARBNc6IJnk7pHvfy8G0BHPX09fkmYUthM',
appId: '1:534654186450:ios:466e45c9dd7a6ef8ba8e0b',
messagingSenderId: '534654186450',
projectId: 'classroom-75d8f',
storageBucket: 'classroom-75d8f.appspot.com',
iosBundleId: 'com.example.jemaApp',
);
static const FirebaseOptions macos = FirebaseOptions(
apiKey: 'AIzaSyARBNc6IJnk7pHvfy8G0BHPX09fkmYUthM',
appId: '1:534654186450:ios:8ffcae2dcde0109fba8e0b',
messagingSenderId: '534654186450',
projectId: 'classroom-75d8f',
storageBucket: 'classroom-75d8f.appspot.com',
iosBundleId: 'com.example.jemaApp.RunnerTests',
);
}
import 'package:awesome_dialog/awesome_dialog.dart';
import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart';
import 'package:jema_app/teacherhome.dart';
class LoginPage extends StatefulWidget {
const LoginPage({Key? key, required this.backgroundColor}) : super(key: key);
final Color backgroundColor;
@override
_LoginPage createState() => _LoginPage(backgroundColor: backgroundColor);
}
class _LoginPage extends State<LoginPage> {
_LoginPage({Key? key, required this.backgroundColor});
final Color backgroundColor;
TextEditingController emailController = TextEditingController();
TextEditingController passwordController = TextEditingController();
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
backgroundColor: Colors.transparent,
elevation: 0,
leading: IconButton(
icon: const Icon(
Icons.arrow_back,
color: Color.fromARGB(255, 0, 0, 0),
),
onPressed: () {
Navigator.pop(context);
},
),
),
body: Container(
color: backgroundColor,
child: SafeArea(
child: SingleChildScrollView(
child: Center(
child: Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: <Widget>[
const SizedBox(height: 20),
Padding(
padding: const EdgeInsets.all(10.0),
child: Image.asset(
'lib/assets/teachersignin.png',
width: 290,
height: 250,
),
),
const SizedBox(height: 10),
const Text(
'Welcome back',
style: TextStyle(
color: Colors.purple,
fontSize: 20,
fontWeight: FontWeight.bold,
),
),
const SizedBox(height: 20),
Padding(
padding: const EdgeInsets.symmetric(horizontal: 20),
child: TextFormField(
controller: emailController,
style: const TextStyle(color: Colors.black),
decoration: InputDecoration(
labelText: 'Email',
labelStyle: TextStyle(color: Colors.black),
fillColor: Colors.grey[200],
filled: true,
border: OutlineInputBorder(
borderRadius: BorderRadius.circular(10.0),
borderSide: BorderSide.none,
),
suffixIcon: Icon(Icons.email, color: Colors.black),
),
validator: (value) {
RegExp regex = new RegExp(r'^.{6,}$');
if (value!.isEmpty) {
return "Password cannot be empty";
}
if (!regex.hasMatch(value)) {
return ("please enter valid password min. 6 character");
} else {
return null;
}
},
),
),
const SizedBox(height: 10),
Padding(
padding: const EdgeInsets.symmetric(horizontal: 20),
child: TextFormField(
controller: passwordController,
style: const TextStyle(color: Colors.black),
obscureText: true,
decoration: InputDecoration(
labelText: 'Password',
labelStyle: TextStyle(color: Colors.black),
fillColor: Colors.grey[200],
filled: true,
border: OutlineInputBorder(
borderRadius: BorderRadius.circular(10.0),
borderSide: BorderSide.none,
),
suffixIcon: Icon(Icons.lock, color: Colors.black),
),
),
),
const SizedBox(height: 20),
ElevatedButton(
onPressed: () {
signIn(emailController.text, passwordController.text,
context);
},
onLongPress: () {},
child: Container(
width: double.infinity,
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0),
color: Colors.green,
),
child: Center(
child: Padding(
padding: const EdgeInsets.all(10.0),
child: Text(
'Login',
style: TextStyle(color: Colors.black),
),
),
),
),
style: ElevatedButton.styleFrom(
primary: Colors.transparent,
elevation: 0,
),
),
],
),
),
),
),
),
),
);
}
void route(context) {
User? user = FirebaseAuth.instance.currentUser;
var kk = FirebaseFirestore.instance
.collection('users')
.doc(user!.uid)
.get()
.then((DocumentSnapshot documentSnapshot) {
if (documentSnapshot.exists) {
if (documentSnapshot.get('rool') == "teacher") {
AwesomeDialog(
context: context,
dialogType: DialogType.success,
animType: AnimType.rightSlide,
title: 'Successfully login',
desc: ' Go to your home page',
btnCancelOnPress: () {},
btnOkOnPress: () {
Navigator.pushReplacement(
context,
MaterialPageRoute(
builder: (context) => TeacherHomePage(),
),
);
},
)..show();
print("login teacher");
} else {
Navigator.pushReplacement(
context,
MaterialPageRoute(
builder: (context) => TeacherHomePage(),
),
);
}
} else {
AwesomeDialog(
context: context,
dialogType: DialogType.warning,
animType: AnimType.rightSlide,
title: 'Faild login',
desc: 'No user found for that email',
btnOkOnPress: () {},
)..show();
print('Document does not exist on the database');
}
});
}
void signIn(String email, String password, context) async {
try {
UserCredential userCredential =
await FirebaseAuth.instance.signInWithEmailAndPassword(
email: email,
password: password,
);
route(context);
} on FirebaseAuthException catch (e) {
if (e.code == 'user-not-found') {
AwesomeDialog(
context: context,
dialogType: DialogType.warning,
animType: AnimType.rightSlide,
title: 'Faild login',
desc: ' No user found for that email',
btnOkOnPress: () {},
)..show();
print('No user found for that email.');
} else if (e.code == 'wrong-password') {
AwesomeDialog(
context: context,
dialogType: DialogType.warning,
animType: AnimType.rightSlide,
title: 'Faild login',
desc: ' Wrong password',
btnOkOnPress: () {},
)..show();
print('Wrong password provided for that user.');
} else {
AwesomeDialog(
context: context,
dialogType: DialogType.error,
animType: AnimType.rightSlide,
title: 'Error',
desc: e.message,
btnOkOnPress: () {},
)..show();
}
}
}
}
void main() {
runApp(const MaterialApp(
home: LoginPage(
backgroundColor: Color.fromARGB(255, 225, 226, 226),
),
));
}
import 'dart:async';
import 'package:firebase_core/firebase_core.dart';
import 'package:flutter/material.dart';
import 'package:jema_app/sign_in_up.dart';
import 'firebase_options.dart';
void main() async {
WidgetsFlutterBinding.ensureInitialized();
await Firebase.initializeApp(
options: DefaultFirebaseOptions.currentPlatform,
);
runApp(const MyApp());
}
class MyApp extends StatelessWidget {
const MyApp({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Demo',
theme: ThemeData(
colorScheme:
ColorScheme.fromSeed(seedColor: Color.fromARGB(0, 255, 255, 255)),
useMaterial3: true,
textTheme: const TextTheme(
headlineMedium: TextStyle(
fontSize: 20.0,
fontWeight: FontWeight.w500,
color: Colors.white,
fontFamily: 'Poppins',
),
),
),
home: const MyHomePage(
title: '',
backgroundColor: Color.fromARGB(255, 0, 183, 255),
),
);
}
}
class MyHomePage extends StatefulWidget {
const MyHomePage(
{Key? key, required this.title, required this.backgroundColor})
: super(key: key);
final String title;
final Color backgroundColor;
@override
_MyHomePageState createState() => _MyHomePageState();
}
class _MyHomePageState extends State<MyHomePage> {
double scaleFactor = 1.0;
@override
void initState() {
super.initState();
Timer.periodic(Duration(milliseconds: 500), (timer) {
setState(() {
// Toggle between zoom in and zoom out
scaleFactor = scaleFactor == 1.0 ? 1.05 : 1.0;
});
});
Future.delayed(Duration(seconds: 3), () {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => SignInUpPage(
backgroundColor: const Color.fromARGB(255, 255, 255, 255))),
);
});
}
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: null,
body: Container(
color: widget.backgroundColor,
child: Center(
child: SingleChildScrollView(
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
children: <Widget>[
Padding(
padding: const EdgeInsets.all(10.0),
child: GestureDetector(
onTap: () {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => SignInUpPage(
backgroundColor:
const Color.fromARGB(255, 255, 255, 255))),
);
},
child: Transform.scale(
scale: scaleFactor,
child: Image.asset(
'lib/assets/landingimg.png',
width: 310,
height: 370,
),
),
),
),
Text(
'Welcome little explorer!',
style: Theme.of(context).textTheme.headlineMedium,
),
const Text(
"Let's dive into a world of fun and \nlearning together!",
style: TextStyle(
color: Colors.white,
fontFamily: 'Poppins',
),
textAlign: TextAlign.center,
),
],
),
),
),
),
);
}
}
import 'package:flutter/material.dart';
import 'login.dart';
class ParentTeacherPage extends StatelessWidget {
const ParentTeacherPage({Key? key, required this.backgroundColor}) : super(key: key);
final Color backgroundColor;
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
backgroundColor: Colors.transparent,
elevation: 0,
leading: IconButton(
icon: Icon(
Icons.arrow_back,
color: const Color.fromARGB(255, 0, 0, 0),
),
onPressed: () {
Navigator.pop(context);
},
),
),
body: Container(
color: backgroundColor,
child: SafeArea(
child: Center(
child: Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: <Widget>[
Padding(
padding: const EdgeInsets.all(10.0),
child: Image.asset(
'lib/assets/p_or_t.png',
width: 280,
height: 450,
),
),
const SizedBox(height: 20),
Text(
'Which Best Describe You ?',
style: TextStyle(
fontSize: 18,
fontWeight: FontWeight.bold,
color: Color.fromARGB(255, 105, 19, 145),
),
),
const SizedBox(height: 20),
ElevatedButton(
onPressed: () {
// logic for navigating to the parent login page
},
child: Container(
width: 200,
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0),
color: Color.fromARGB(220, 164, 68, 215),
),
child: Center(
child: Padding(
padding: const EdgeInsets.all(10.0),
child: Text(
'Parent',
style: TextStyle(color: Colors.white),
),
),
),
),
style: ElevatedButton.styleFrom(
primary: Colors.transparent,
elevation: 0,
),
),
const SizedBox(height: 20),
ElevatedButton(
onPressed: () {
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => LoginPage(
backgroundColor: backgroundColor,
),
),
);
},
child: Container(
width: 200,
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0),
color: Color.fromARGB(220, 164, 68, 215),
),
child: Center(
child: Padding(
padding: const EdgeInsets.all(10.0),
child: Text(
'Teacher',
style: TextStyle(color: Colors.white),
),
),
),
),
style: ElevatedButton.styleFrom(
primary: Colors.transparent,
elevation: 0,
),
),
],
),
),
),
),
),
);
}
}
import 'package:flutter/material.dart';
import 'package:jema_app/p_or_t.dart';
import 'package:jema_app/teachersignup.dart';
class SignInUpPage extends StatelessWidget {
const SignInUpPage({Key? key, required this.backgroundColor})
: super(key: key);
final Color backgroundColor;
@override
Widget build(BuildContext context) {
return Scaffold(
body: Container(
color: backgroundColor,
child: SafeArea(
child: Center(
child: Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
mainAxisAlignment: MainAxisAlignment.center,
crossAxisAlignment: CrossAxisAlignment.center,
children: <Widget>[
Padding(
padding: const EdgeInsets.all(10.0),
child: Image.asset(
'lib/assets/signinup.png',
width: 290,
height: 460,
),
),
const SizedBox(height: 20),
ElevatedButton(
onPressed: () {
// Navigate to the signup page (TeacherSignupPage)
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => TeacherSignupPage(),
),
);
},
child: Container(
width: 200,
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0),
color: Color.fromARGB(255, 96, 188, 99),
),
child: Center(
child: Padding(
padding: const EdgeInsets.all(10.0),
child: Text(
'Sign Up',
style: TextStyle(color: Colors.white),
),
),
),
),
style: ElevatedButton.styleFrom(
primary: Colors.transparent,
elevation: 0,
),
),
const SizedBox(height: 20),
ElevatedButton(
onPressed: () {
// Navigate to the sign in page (ParentTeacherPage)
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => ParentTeacherPage(
backgroundColor: backgroundColor,
),
),
);
},
child: Container(
width: 200,
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(10.0),
color: const Color.fromARGB(255, 213, 80, 236),
),
child: Center(
child: Padding(
padding: const EdgeInsets.all(10.0),
child: Text(
'Sign In',
style: TextStyle(color: Colors.white),
),
),
),
),
style: ElevatedButton.styleFrom(
primary: Colors.transparent,
elevation: 0,
),
),
],
),
),
),
),
),
);
}
}
void main() {
runApp(const MaterialApp(
home: SignInUpPage(
backgroundColor: Color.fromARGB(255, 225, 226, 226),
),
));
}
import 'package:flutter/material.dart';
class TeacherActivitiesPage extends StatelessWidget {
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text('Activities'),
),
body: Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
SizedBox(height: 20),
Text(
'Activities',
style: TextStyle(
color: Color(0xFF554994),
fontSize: 24,
fontFamily: 'Poppins',
fontWeight: FontWeight.w700,
height: 0.04,
letterSpacing: -0.96,
),
),
SizedBox(height: 20),
// Your activities widgets here
// ...
],
),
),
);
}
}
import 'package:flutter/material.dart';
class TeacherChatPage extends StatefulWidget {
@override
_TeacherChatPageState createState() => _TeacherChatPageState();
}
class _TeacherChatPageState extends State<TeacherChatPage> {
int _currentIndex = 1; // Set the default selected index to 'Chat'
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text('Chat'),
),
body: ChatList(),
bottomNavigationBar: BottomNavigationBar(
items: const [
BottomNavigationBarItem(
icon: Icon(Icons.home),
label: 'Home',
),
BottomNavigationBarItem(
icon: Icon(Icons.chat),
label: 'Chat',
),
BottomNavigationBarItem(
icon: Icon(Icons.person),
label: 'Profile',
),
],
selectedItemColor: Colors.blue,
currentIndex: _currentIndex,
onTap: (index) {
setState(() {
_currentIndex = index;
});
// Handle bottom navigation item tap
},
),
);
}
}
class ChatList extends StatelessWidget {
@override
Widget build(BuildContext context) {
return ListView.builder(
itemCount: 5, // Replace with the actual number of chats
itemBuilder: (context, index) {
return ChatItem(
profileImage:
'lib/assets/profile_image.png', // Replace with the actual image path
name: 'Student ${index + 1}',
lastMessage: 'Hello, how are you?',
time: '2:30 PM',
onTap: () {
// Handle chat item tap
},
);
},
);
}
}
class ChatItem extends StatelessWidget {
final String profileImage;
final String name;
final String lastMessage;
final String time;
final VoidCallback onTap;
const ChatItem({
required this.profileImage,
required this.name,
required this.lastMessage,
required this.time,
required this.onTap,
});
@override
Widget build(BuildContext context) {
return ListTile(
onTap: onTap,
leading: CircleAvatar(
backgroundImage: AssetImage(profileImage),
),
title: Text(name),
subtitle: Text(lastMessage),
trailing: Column(
crossAxisAlignment: CrossAxisAlignment.end,
children: [
Text(time),
SizedBox(height: 5),
// Add additional indicators (e.g., unread message count) if needed
],
),
);
}
}
void main() {
runApp(MaterialApp(
home: TeacherChatPage(),
));
}
import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart';
import 'package:jema_app/teacherchat.dart';
import 'package:jema_app/classroomview.dart';
import 'package:jema_app/addclassroom.dart'; // Import the AddClassroomPage file
class TeacherHomePage extends StatelessWidget {
late User? user;
late final Stream<QuerySnapshot> _usersStream;
TeacherHomePage() {
user = FirebaseAuth.instance.currentUser;
initializeStreams();
}
void initializeStreams() {
_usersStream = FirebaseFirestore.instance
.collection('classroom')
.where('userId', isEqualTo: user?.uid)
.snapshots();
}
@override
Widget build(BuildContext context) {
return WillPopScope(
onWillPop: () async {
// Disable the back button press
return false;
},
child: Scaffold(
appBar: AppBar(
leading: Flexible(
child: Image.asset(
'lib/assets/logo.png',
fit: BoxFit.contain,
),
),
actions: [
IconButton(
icon: Icon(Icons.notifications),
onPressed: () {
// Handle notification icon press
},
),
],
),
body: Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
SizedBox(height: 20),
Text(
'Explore, learn, and play in our magical world of wonder!',
style: TextStyle(
fontSize: 12,
),
),
SizedBox(height: 10),
Expanded(
child: Image.asset(
'lib/assets/teacherhome.png',
fit: BoxFit.contain,
),
),
SizedBox(height: 20),
TextButton(
onPressed: () {
// Navigate to the AddClassroomPage
Navigator.push(
context,
MaterialPageRoute(builder: (context) => AddClassroomPage()),
);
},
child: Text(
'Add Classroom',
style: TextStyle(
color: Colors.blue,
fontSize: 16,
fontWeight: FontWeight.bold,
),
),
),
Divider(),
SizedBox(height: 10),
Text(
'Class Rooms',
style: TextStyle(
fontSize: 16,
fontWeight: FontWeight.bold,
),
),
SizedBox(height: 10),
Expanded(
child: StreamBuilder<QuerySnapshot>(
stream: _usersStream,
builder: (context, snapshot) {
print("--------------------------------------");
print(snapshot.data!.docs.length);
if (snapshot.connectionState == ConnectionState.waiting) {
return CircularProgressIndicator();
}
if (snapshot.hasError) {
return Text('Error: ${snapshot.error}');
}
var itemcount = snapshot.data!.docs.length;
return ListView.builder(
itemCount: snapshot.data!.docs.length,
itemBuilder: (context, index) {
var document = snapshot.data!.docs[index];
var className = document['className'];
return ListTile(
leading: CircleAvatar(
backgroundImage: AssetImage('lib/assets/logo.png'),
),
title: Text(className),
trailing: ElevatedButton(
onPressed: () {
print(document);
// Handle view class button press
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => ClassroomViewPage(
documents: className,
),
),
);
},
child: Text('View'),
),
);
},
);
},
),
),
],
),
),
bottomNavigationBar: BottomNavigationBar(
items: const [
BottomNavigationBarItem(
icon: Icon(Icons.home),
label: 'Home',
),
BottomNavigationBarItem(
icon: Icon(Icons.chat),
label: 'Chat',
),
BottomNavigationBarItem(
icon: Icon(Icons.person),
label: 'Profile',
),
],
selectedItemColor: Colors.blue,
onTap: (index) {
// Handle bottom navigation item tap
if (index == 1) {
Navigator.push(
context,
MaterialPageRoute(builder: (context) => TeacherChatPage()),
);
}
},
),
),
);
}
}
import 'package:awesome_dialog/awesome_dialog.dart';
import 'package:cloud_firestore/cloud_firestore.dart';
import 'package:firebase_auth/firebase_auth.dart';
import 'package:flutter/material.dart';
import 'login.dart';
class TeacherSignupPage extends StatefulWidget {
const TeacherSignupPage({Key? key}) : super(key: key);
@override
_TeacherSignupPageState createState() => _TeacherSignupPageState();
}
class _TeacherSignupPageState extends State<TeacherSignupPage> {
// TextEditingController for text input fields
TextEditingController fullNameController = TextEditingController();
TextEditingController emailController = TextEditingController();
TextEditingController phoneNumberController = TextEditingController();
TextEditingController passwordController = TextEditingController();
// TextEditingController schoolNameController = TextEditingController();
// TextEditingController enrolmentCapacityController = TextEditingController();
// TextEditingController countryController = TextEditingController();
// TextEditingController stateRegionController = TextEditingController();
bool agreeTermsAndConditions = false;
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text('Teacher Signup'),
),
body: SingleChildScrollView(
child: Column(
children: [
Image.asset(
'lib/assets/tsignup1.png',
width: 240,
height: 270,
fit: BoxFit.cover,
),
Padding(
padding: const EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
_buildTextInputWithIcon(
controller: fullNameController,
labelText: 'Full Name',
icon: Icons.person,
),
const SizedBox(height: 10),
_buildTextInputWithIcon(
controller: emailController,
labelText: 'Email',
icon: Icons.email,
),
const SizedBox(height: 10),
_buildTextInputWithIcon(
controller: phoneNumberController,
labelText: 'Phone Number',
icon: Icons.phone,
),
const SizedBox(height: 10),
_buildTextInputWithIcon(
controller: passwordController,
labelText: 'Password',
icon: Icons.lock,
obscureText: true,
),
const SizedBox(height: 20),
ElevatedButton(
onPressed: () {
// Logic to navigate to the next page with additional information
Navigator.push(
context,
MaterialPageRoute(
builder: (context) => AdditionalInfoPage(
fullNameController: fullNameController,
emailController: emailController,
phoneNumberController: phoneNumberController,
passwordController: passwordController,
agreeTermsAndConditions: agreeTermsAndConditions,
),
),
);
},
child: Text('Next'),
),
],
),
),
],
),
),
);
}
Widget _buildTextInputWithIcon({
required TextEditingController controller,
required String labelText,
required IconData icon,
bool obscureText = false,
}) {
return TextFormField(
controller: controller,
obscureText: obscureText,
decoration: InputDecoration(
labelText: labelText,
suffixIcon: Icon(icon),
filled: true,
fillColor: Colors.grey[200], // Light gray background color
focusedBorder: OutlineInputBorder(
borderSide: BorderSide(
color: Colors.transparent), // No border color when focused
borderRadius: BorderRadius.circular(10.0),
),
enabledBorder: OutlineInputBorder(
borderSide: BorderSide(
color: Colors.transparent), // No border color when not focused
borderRadius: BorderRadius.circular(10.0),
),
),
);
}
}
class AdditionalInfoPage extends StatelessWidget {
AdditionalInfoPage(
{Key? key,
required this.fullNameController,
required this.emailController,
required this.phoneNumberController,
required this.passwordController,
required this.agreeTermsAndConditions})
: super(key: key);
bool showProgress = false;
bool visible = false;
final _formkey = GlobalKey<FormState>();
final _auth = FirebaseAuth.instance;
final TextEditingController fullNameController;
final TextEditingController emailController;
final TextEditingController phoneNumberController;
final TextEditingController passwordController;
TextEditingController schoolNameController = TextEditingController();
TextEditingController enrolmentCapacityController = TextEditingController();
TextEditingController countryController = TextEditingController();
TextEditingController stateRegionController = TextEditingController();
final bool agreeTermsAndConditions;
var rool = "teacher";
@override
Widget build(BuildContext context) {
return Scaffold(
appBar: AppBar(
title: Text('Additional Information'),
),
body: SingleChildScrollView(
padding: const EdgeInsets.all(16.0),
child: Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
_buildTextInputWithIcon(
controller: schoolNameController,
labelText: 'School Name',
icon: Icons.school,
),
const SizedBox(height: 10),
_buildTextInputWithIcon(
controller: enrolmentCapacityController,
labelText: 'Enrolment Capacity',
icon: Icons.people,
),
const SizedBox(height: 10),
_buildTextInputWithIcon(
controller: countryController,
labelText: 'Country',
icon: Icons.location_on,
),
const SizedBox(height: 10),
_buildTextInputWithIcon(
controller: stateRegionController,
labelText: 'State/Region',
icon: Icons.location_city,
),
const SizedBox(height: 20),
Row(
children: [
// Checkbox(
// value: agreeTermsAndConditions,
// onChanged: (value) {
// // Logic to update the checkbox value
// setState(() {
// agreeTermsAndConditions = value!;
// });
// },
// ),
Text(
'By checking the box you agree to our Terms and Conditions.',
style: TextStyle(fontSize: 12),
),
],
),
const SizedBox(height: 20),
ElevatedButton(
onPressed: () {
// Logic to finish the teacher registration
// You can add your own logic here
signUp(emailController.text, passwordController.text, rool,
context);
},
child: Text('Finish'),
),
],
),
),
);
}
void signUp(String email, String password, String rool, context) async {
CircularProgressIndicator();
await _auth
.createUserWithEmailAndPassword(email: email, password: password)
.then((value) => {postDetailsToFirestore(email, rool, context)})
.catchError((e) {
AwesomeDialog(
context: context,
dialogType: DialogType.error,
animType: AnimType.rightSlide,
title: 'Error',
desc: ' error',
btnOkOnPress: () {},
)..show();
});
}
postDetailsToFirestore(String email, String rool, context) async {
FirebaseFirestore firebaseFirestore = FirebaseFirestore.instance;
var user = _auth.currentUser;
CollectionReference ref = FirebaseFirestore.instance.collection('users');
print("user!.uid == : " + emailController.text);
ref.doc(user!.uid).set({
"fullName": fullNameController.text,
'email': emailController.text,
'phoneNo': phoneNumberController.text,
"school": schoolNameController.text,
"enrolmentCapacity": enrolmentCapacityController.text,
"country": countryController.text,
"state": stateRegionController.text,
"agreeTermsAndConditions": agreeTermsAndConditions,
'rool': rool
});
AwesomeDialog(
context: context,
dialogType: DialogType.success,
animType: AnimType.rightSlide,
title: 'Successfully Created',
desc: ' Go to Login page',
btnOkOnPress: () {
Navigator.pushReplacement(
context,
MaterialPageRoute(
builder: (context) => LoginPage(
backgroundColor: Color.fromARGB(255, 0, 183, 255),
)));
},
)..show();
}
Widget _buildTextInputWithIcon({
required TextEditingController controller,
required String labelText,
required IconData icon,
}) {
return TextFormField(
controller: controller,
decoration: InputDecoration(
labelText: labelText,
suffixIcon: Icon(icon),
filled: true,
fillColor: Colors.grey[200], // Light gray background color
focusedBorder: OutlineInputBorder(
borderSide: BorderSide(
color: Colors.transparent), // No border color when focused
borderRadius: BorderRadius.circular(10.0),
),
enabledBorder: OutlineInputBorder(
borderSide: BorderSide(
color: Colors.transparent), // No border color when not focused
borderRadius: BorderRadius.circular(10.0),
),
),
);
}
}
void main() {
runApp(MaterialApp(
home: TeacherSignupPage(),
));
}
# Generated by pub
# See https://dart.dev/tools/pub/glossary#lockfile
packages:
_flutterfire_internals:
dependency: transitive
description:
name: _flutterfire_internals
sha256: f5628cd9c92ed11083f425fd1f8f1bc60ecdda458c81d73b143aeda036c35fe7
url: "https://pub.dev"
source: hosted
version: "1.3.16"
async:
dependency: transitive
description:
name: async
sha256: "947bfcf187f74dbc5e146c9eb9c0f10c9f8b30743e341481c1e2ed3ecc18c20c"
url: "https://pub.dev"
source: hosted
version: "2.11.0"
awesome_dialog:
dependency: "direct main"
description:
name: awesome_dialog
sha256: "7da175ea284fa5da0a4d0cbdfe835c5b71d30c7b38c1770c0f27f48272ff5a08"
url: "https://pub.dev"
source: hosted
version: "3.1.0"
boolean_selector:
dependency: transitive
description:
name: boolean_selector
sha256: "6cfb5af12253eaf2b368f07bacc5a80d1301a071c73360d746b7f2e32d762c66"
url: "https://pub.dev"
source: hosted
version: "2.1.1"
characters:
dependency: transitive
description:
name: characters
sha256: "04a925763edad70e8443c99234dc3328f442e811f1d8fd1a72f1c8ad0f69a605"
url: "https://pub.dev"
source: hosted
version: "1.3.0"
clock:
dependency: transitive
description:
name: clock
sha256: cb6d7f03e1de671e34607e909a7213e31d7752be4fb66a86d29fe1eb14bfb5cf
url: "https://pub.dev"
source: hosted
version: "1.1.1"
cloud_firestore:
dependency: "direct main"
description:
name: cloud_firestore
sha256: cb978c7512624144f24f3d06e4312b2f4ac00b016f2fed62dc8f6d56b8585d78
url: "https://pub.dev"
source: hosted
version: "4.13.6"
cloud_firestore_platform_interface:
dependency: transitive
description:
name: cloud_firestore_platform_interface
sha256: fa177fa85f7665c76e1ebec252a5b280b4b47612b4d70fe286944814fff1d4f2
url: "https://pub.dev"
source: hosted
version: "6.0.10"
cloud_firestore_web:
dependency: transitive
description:
name: cloud_firestore_web
sha256: d0ebbf0927e627c0d7d2f3177d3b6f0050e5d811c08c2b646b0c746a2b502cb7
url: "https://pub.dev"
source: hosted
version: "3.8.10"
collection:
dependency: transitive
description:
name: collection
sha256: "4a07be6cb69c84d677a6c3096fcf960cc3285a8330b4603e0d463d15d9bd934c"
url: "https://pub.dev"
source: hosted
version: "1.17.1"
cupertino_icons:
dependency: "direct main"
description:
name: cupertino_icons
sha256: d57953e10f9f8327ce64a508a355f0b1ec902193f66288e8cb5070e7c47eeb2d
url: "https://pub.dev"
source: hosted
version: "1.0.6"
fake_async:
dependency: transitive
description:
name: fake_async
sha256: "511392330127add0b769b75a987850d136345d9227c6b94c96a04cf4a391bf78"
url: "https://pub.dev"
source: hosted
version: "1.3.1"
ffi:
dependency: transitive
description:
name: ffi
sha256: "7bf0adc28a23d395f19f3f1eb21dd7cfd1dd9f8e1c50051c069122e6853bc878"
url: "https://pub.dev"
source: hosted
version: "2.1.0"
firebase_auth:
dependency: "direct main"
description:
name: firebase_auth
sha256: "88f88d541a2c1903c023355e13d077835573a200bbf57e12a6a2c24bf99665a1"
url: "https://pub.dev"
source: hosted
version: "4.15.3"
firebase_auth_platform_interface:
dependency: transitive
description:
name: firebase_auth_platform_interface
sha256: "3c9cfaccb7549492edf5b0c67c6dd1c6727c7830891aa6727f2fb225f0226626"
url: "https://pub.dev"
source: hosted
version: "7.0.9"
firebase_auth_web:
dependency: transitive
description:
name: firebase_auth_web
sha256: c09515414c07c11bb133aec4baae9a74c6ff1f62bf05ace54564db82b8c87852
url: "https://pub.dev"
source: hosted
version: "5.8.12"
firebase_core:
dependency: "direct main"
description:
name: firebase_core
sha256: "96607c0e829a581c2a483c658f04e8b159964c3bae2730f73297070bc85d40bb"
url: "https://pub.dev"
source: hosted
version: "2.24.2"
firebase_core_platform_interface:
dependency: transitive
description:
name: firebase_core_platform_interface
sha256: c437ae5d17e6b5cc7981cf6fd458a5db4d12979905f9aafd1fea930428a9fe63
url: "https://pub.dev"
source: hosted
version: "5.0.0"
firebase_core_web:
dependency: transitive
description:
name: firebase_core_web
sha256: d585bdf3c656c3f7821ba1bd44da5f13365d22fcecaf5eb75c4295246aaa83c0
url: "https://pub.dev"
source: hosted
version: "2.10.0"
flutter:
dependency: "direct main"
description: flutter
source: sdk
version: "0.0.0"
flutter_lints:
dependency: "direct dev"
description:
name: flutter_lints
sha256: a25a15ebbdfc33ab1cd26c63a6ee519df92338a9c10f122adda92938253bef04
url: "https://pub.dev"
source: hosted
version: "2.0.3"
flutter_test:
dependency: "direct dev"
description: flutter
source: sdk
version: "0.0.0"
flutter_web_plugins:
dependency: transitive
description: flutter
source: sdk
version: "0.0.0"
graphs:
dependency: transitive
description:
name: graphs
sha256: aedc5a15e78fc65a6e23bcd927f24c64dd995062bcd1ca6eda65a3cff92a4d19
url: "https://pub.dev"
source: hosted
version: "2.3.1"
http:
dependency: transitive
description:
name: http
sha256: "759d1a329847dd0f39226c688d3e06a6b8679668e350e2891a6474f8b4bb8525"
url: "https://pub.dev"
source: hosted
version: "1.1.0"
http_parser:
dependency: transitive
description:
name: http_parser
sha256: "2aa08ce0341cc9b354a498388e30986515406668dbcc4f7c950c3e715496693b"
url: "https://pub.dev"
source: hosted
version: "4.0.2"
js:
dependency: transitive
description:
name: js
sha256: f2c445dce49627136094980615a031419f7f3eb393237e4ecd97ac15dea343f3
url: "https://pub.dev"
source: hosted
version: "0.6.7"
lints:
dependency: transitive
description:
name: lints
sha256: "0a217c6c989d21039f1498c3ed9f3ed71b354e69873f13a8dfc3c9fe76f1b452"
url: "https://pub.dev"
source: hosted
version: "2.1.1"
matcher:
dependency: transitive
description:
name: matcher
sha256: "6501fbd55da300384b768785b83e5ce66991266cec21af89ab9ae7f5ce1c4cbb"
url: "https://pub.dev"
source: hosted
version: "0.12.15"
material_color_utilities:
dependency: transitive
description:
name: material_color_utilities
sha256: d92141dc6fe1dad30722f9aa826c7fbc896d021d792f80678280601aff8cf724
url: "https://pub.dev"
source: hosted
version: "0.2.0"
meta:
dependency: transitive
description:
name: meta
sha256: "3c74dbf8763d36539f114c799d8a2d87343b5067e9d796ca22b5eb8437090ee3"
url: "https://pub.dev"
source: hosted
version: "1.9.1"
path:
dependency: transitive
description:
name: path
sha256: "8829d8a55c13fc0e37127c29fedf290c102f4e40ae94ada574091fe0ff96c917"
url: "https://pub.dev"
source: hosted
version: "1.8.3"
plugin_platform_interface:
dependency: transitive
description:
name: plugin_platform_interface
sha256: f4f88d4a900933e7267e2b353594774fc0d07fb072b47eedcd5b54e1ea3269f8
url: "https://pub.dev"
source: hosted
version: "2.1.7"
rive:
dependency: transitive
description:
name: rive
sha256: f2117a96a189758bc79bf7933865625c7a44a420ae537d2a8f6c492900136a71
url: "https://pub.dev"
source: hosted
version: "0.11.17"
rive_common:
dependency: transitive
description:
name: rive_common
sha256: e41f12917cb58e0c9376836490ebaa431e12744da0c67e19dad8d4bee9fedd46
url: "https://pub.dev"
source: hosted
version: "0.2.7"
sky_engine:
dependency: transitive
description: flutter
source: sdk
version: "0.0.99"
source_span:
dependency: transitive
description:
name: source_span
sha256: dd904f795d4b4f3b870833847c461801f6750a9fa8e61ea5ac53f9422b31f250
url: "https://pub.dev"
source: hosted
version: "1.9.1"
stack_trace:
dependency: transitive
description:
name: stack_trace
sha256: c3c7d8edb15bee7f0f74debd4b9c5f3c2ea86766fe4178eb2a18eb30a0bdaed5
url: "https://pub.dev"
source: hosted
version: "1.11.0"
stream_channel:
dependency: transitive
description:
name: stream_channel
sha256: "83615bee9045c1d322bbbd1ba209b7a749c2cbcdcb3fdd1df8eb488b3279c1c8"
url: "https://pub.dev"
source: hosted
version: "2.1.1"
string_scanner:
dependency: transitive
description:
name: string_scanner
sha256: "556692adab6cfa87322a115640c11f13cb77b3f076ddcc5d6ae3c20242bedcde"
url: "https://pub.dev"
source: hosted
version: "1.2.0"
term_glyph:
dependency: transitive
description:
name: term_glyph
sha256: a29248a84fbb7c79282b40b8c72a1209db169a2e0542bce341da992fe1bc7e84
url: "https://pub.dev"
source: hosted
version: "1.2.1"
test_api:
dependency: transitive
description:
name: test_api
sha256: eb6ac1540b26de412b3403a163d919ba86f6a973fe6cc50ae3541b80092fdcfb
url: "https://pub.dev"
source: hosted
version: "0.5.1"
typed_data:
dependency: transitive
description:
name: typed_data
sha256: facc8d6582f16042dd49f2463ff1bd6e2c9ef9f3d5da3d9b087e244a7b564b3c
url: "https://pub.dev"
source: hosted
version: "1.3.2"
vector_math:
dependency: transitive
description:
name: vector_math
sha256: "80b3257d1492ce4d091729e3a67a60407d227c27241d6927be0130c98e741803"
url: "https://pub.dev"
source: hosted
version: "2.1.4"
sdks:
dart: ">=3.0.1 <4.0.0"
flutter: ">=3.3.0"
name: jema_app
description: A new Flutter project.
# The following line prevents the package from being accidentally published to
# pub.dev using `flutter pub publish`. This is preferred for private packages.
publish_to: 'none' # Remove this line if you wish to publish to pub.dev
# The following defines the version and build number for your application.
# A version number is three numbers separated by dots, like 1.2.43
# followed by an optional build number separated by a +.
# Both the version and the builder number may be overridden in flutter
# build by specifying --build-name and --build-number, respectively.
# In Android, build-name is used as versionName while build-number used as versionCode.
# Read more about Android versioning at https://developer.android.com/studio/publish/versioning
# In iOS, build-name is used as CFBundleShortVersionString while build-number is used as CFBundleVersion.
# Read more about iOS versioning at
# https://developer.apple.com/library/archive/documentation/General/Reference/InfoPlistKeyReference/Articles/CoreFoundationKeys.html
# In Windows, build-name is used as the major, minor, and patch parts
# of the product and file versions while build-number is used as the build suffix.
version: 1.0.0+1
environment:
sdk: '>=3.0.1 <4.0.0'
# Dependencies specify other packages that your package needs in order to work.
# To automatically upgrade your package dependencies to the latest versions
# consider running `flutter pub upgrade --major-versions`. Alternatively,
# dependencies can be manually updated by changing the version numbers below to
# the latest version available on pub.dev. To see which dependencies have newer
# versions available, run `flutter pub outdated`.
dependencies:
flutter:
sdk: flutter
# The following adds the Cupertino Icons font to your application.
# Use with the CupertinoIcons class for iOS style icons.
cupertino_icons: ^1.0.2
firebase_core: ^2.24.2
firebase_auth: ^4.15.3
cloud_firestore: ^4.13.6
awesome_dialog: ^3.1.0
dev_dependencies:
flutter_test:
sdk: flutter
# The "flutter_lints" package below contains a set of recommended lints to
# encourage good coding practices. The lint set provided by the package is
# activated in the `analysis_options.yaml` file located at the root of your
# package. See that file for information about deactivating specific lint
# rules and activating additional ones.
flutter_lints: ^2.0.0
# For information on the generic Dart part of this file, see the
# following page: https://dart.dev/tools/pub/pubspec
# The following section is specific to Flutter packages.
flutter:
# The following line ensures that the Material Icons font is
# included with your application, so that you can use the icons in
# the material Icons class.
uses-material-design: true
# To add assets to your application, add an assets section, like this:
assets:
- lib/assets/teachersignin.png
- lib/assets/logo.png
- lib/assets/p_or_t.png
- lib/assets/teacherhome.png
- lib/assets/teachersignin.png
- lib/assets/tsignup1.png
- lib/assets/signinup.png
- lib/assets/landingimg.png
- lib/assets/addclassroom.png
- lib/assets/Vector 2.png
- lib/assets/Vector22.png
- lib/assets/Vector23.png
# An image asset can refer to one or more resolution-specific "variants", see
# https://flutter.dev/assets-and-images/#resolution-aware
# For details regarding adding assets from package dependencies, see
# https://flutter.dev/assets-and-images/#from-packages
# To add custom fonts to your application, add a fonts section here,
# in this "flutter" section. Each entry in this list should have a
# "family" key with the font family name, and a "fonts" key with a
# list giving the asset and other descriptors for the font. For
# example:
# fonts:
# - family: Schyler
# fonts:
# - asset: fonts/Schyler-Regular.ttf
# - asset: fonts/Schyler-Italic.ttf
# style: italic
# - family: Trajan Pro
# fonts:
# - asset: fonts/TrajanPro.ttf
# - asset: fonts/TrajanPro_Bold.ttf
# weight: 700
#
# For details regarding fonts from package dependencies,
# see https://flutter.dev/custom-fonts/#from-packages
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment