-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
47023a4
commit 3c51898
Showing
15 changed files
with
530 additions
and
21 deletions.
There are no files selected for viewing
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
File renamed without changes.
File renamed without changes.
File renamed without changes.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
import 'package:flutter/material.dart'; | ||
import 'package:minly_media_mobile/presentation/screens/login.dart'; | ||
import 'package:minly_media_mobile/presentation/screens/signup.dart'; | ||
|
||
class LoginOrRegister extends StatefulWidget { | ||
const LoginOrRegister({super.key}); | ||
|
||
@override | ||
State<LoginOrRegister> createState() => _LoginOrRegisterState(); | ||
} | ||
|
||
class _LoginOrRegisterState extends State<LoginOrRegister> { | ||
bool showLoginPage = true; | ||
|
||
// toggle between login and register page | ||
void togglePages() { | ||
setState(() { | ||
showLoginPage = !showLoginPage; | ||
}); | ||
} | ||
|
||
@override | ||
Widget build(BuildContext context) { | ||
if (showLoginPage) { | ||
return LoginPage( | ||
onTap: togglePages, | ||
); | ||
} else { | ||
return SignupPage( | ||
onTap: togglePages, | ||
); | ||
} | ||
} | ||
} |
Oops, something went wrong.