Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions lib/Common_widgets/Custom_Box.dart
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,8 @@ class Custom_Box extends StatefulWidget {
final double left;
final double right;
final double bottom;

Custom_Box({super.key, required this.controller,required this.prefixicon, this.prefixIconColor=Colors.blueAccent, required this.hintText,this.top=2.0, this.left=7, this.right=10,this.bottom=11});
final TextStyle style;
Custom_Box({super.key, required this.controller,required this.prefixicon, this.prefixIconColor=Colors.blueAccent, required this.hintText,this.top=2.0, this.left=7, this.right=10,this.bottom=11,this.style = const TextStyle()});

@override
State<Custom_Box> createState() => _Custom_BoxState();
Expand Down
8 changes: 6 additions & 2 deletions lib/Screens/Login.dart
Original file line number Diff line number Diff line change
Expand Up @@ -50,14 +50,18 @@ class _LoginState extends State<Login> {
prefixIconColor: Colors.blueAccent.shade700,
controller:Usernamecontroller,
prefixicon:Icon(Icons.person,size:35),
hintText:'Username'),
hintText:'Username',
style: TextStyle(color:Colors.red)
),

Custom_Box(
top: 20,
prefixIconColor: Colors.blueAccent.shade700,
controller:passwordcontroller,
prefixicon:Icon(Icons.password,size:35),
hintText:'Password '),
hintText:'Password ',
style: TextStyle(color:Colors.red)
),
SizedBox(
height: 40,
),
Expand Down
20 changes: 15 additions & 5 deletions lib/Screens/SignUp.dart
Original file line number Diff line number Diff line change
Expand Up @@ -58,28 +58,38 @@ class _SignUpState extends State<SignUp> {
prefixIconColor: Colors.blueAccent.shade700,
controller:nameController,
prefixicon:Icon(Icons.person,size:35),
hintText:'Name'),
hintText:'Name',
style: TextStyle(color:Colors.red)
),

Custom_Box(
prefixIconColor: Colors.blueAccent.shade700,
controller:usernameController,
prefixicon:Icon(Icons.account_box_outlined,size:35),
hintText:'Username'),
hintText:'Username',
style: TextStyle(color:Colors.red)
),
Custom_Box(
prefixIconColor: Colors.blueAccent.shade700,
controller:emailController,
prefixicon:Icon(Icons.email_sharp,size:35),
hintText:'Email'),
hintText:'Email',
style: TextStyle(color:Colors.red)
),
Custom_Box(
prefixIconColor: Colors.blueAccent.shade700,
controller:passwordController,
prefixicon:Icon(Icons.password,size:35),
hintText:'Password'),
hintText:'Password',
style: TextStyle(color:Colors.red)
),
Custom_Box(
prefixIconColor: Colors.blueAccent.shade700,
controller:confirmPasswordController,
prefixicon:Icon(Icons.password,size:35),
hintText:'Confirm Password'),
hintText:'Confirm Password',
style: TextStyle(color:Colors.red)
),
SizedBox(
height:9,
),
Expand Down
3 changes: 2 additions & 1 deletion lib/Screens/chat_screen.dart
Original file line number Diff line number Diff line change
Expand Up @@ -54,10 +54,11 @@ class _chat_screenState extends State<chat_screen> {
Widget build(BuildContext context) {
return
Scaffold(
backgroundColor: Colors.blueGrey,
appBar: AppBar(
backgroundColor: Colors.blueGrey,
automaticallyImplyLeading: false,
title: Text('Chat Screen'),
backgroundColor: Colors.blueGrey,
),
body: ListView.builder(
itemCount: chats.length,
Expand Down
3 changes: 2 additions & 1 deletion lib/Screens/individual_chat.dart
Original file line number Diff line number Diff line change
Expand Up @@ -104,7 +104,8 @@ class _Individual_chatState extends State<Individual_chat> {
suffixIcon: Row(
mainAxisSize: MainAxisSize.min,//kya jadu
children: [
IconButton(onPressed: (){}, icon: Icon(Icons.attach_file))
IconButton(onPressed: (){}, icon: Icon(Icons.attach_file)),
IconButton(onPressed: (){}, icon: Icon(Icons.send)),
],
),
hintText: 'Type a message',
Expand Down
31 changes: 31 additions & 0 deletions lib/Screens/splash_screen.dart
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
import 'package:flutter/material.dart';

class SplashScreen extends StatefulWidget {
const SplashScreen({super.key});

@override
_SplashScreenState createState() => _SplashScreenState();
}

class _SplashScreenState extends State<SplashScreen> {
@override
void initState() {
super.initState();
_navigateToLogin();
}

_navigateToLogin() async {
// You can replace this with a future that fetches data from Firebase or API
await Future.delayed(Duration(seconds: 2), () {});
Navigator.of(context).pushReplacementNamed('/');
}

@override
Widget build(BuildContext context) {
return Scaffold(
body: Center(
child: Text('Loading...'),
),
);
}
}
3 changes: 3 additions & 0 deletions lib/main.dart
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
import 'package:connectify/Screens/Login.dart';
import 'package:connectify/Screens/MainPage.dart';
import 'package:connectify/Screens/SignUp.dart';
import 'package:connectify/Screens/splash_screen.dart';
import 'package:flutter/material.dart';

void main() {
Expand All @@ -15,9 +16,11 @@ class MyApp extends StatelessWidget {
Widget build(BuildContext context) {
return MaterialApp(
debugShowCheckedModeBanner: false,
initialRoute: '/splash',


routes: {
'/splash': (context) => SplashScreen(),

"/" :(context) => Login(),
"/SignUp":(context)=>SignUp(),
Expand Down