comments added for better understanding
This commit is contained in:
parent
e2e9f78705
commit
28122fa003
@ -1,3 +1,5 @@
|
||||
/// All the named routes are mentioned here
|
||||
|
||||
class AppRoutes {
|
||||
static const splash = '/splash';
|
||||
static const intro = '/intro';
|
||||
|
@ -12,6 +12,10 @@ import 'package:simplex_chat/views/scan_invitation/scan_invitation_view.dart';
|
||||
import 'package:simplex_chat/views/setup_profile_view.dart';
|
||||
import 'package:simplex_chat/views/splash_screen.dart';
|
||||
|
||||
|
||||
/// Basic Structure is setup on [Providers]
|
||||
/// Navigations are [namedRoutes]
|
||||
|
||||
void main() {
|
||||
WidgetsFlutterBinding.ensureInitialized();
|
||||
runApp(const MyApp());
|
||||
|
@ -3,6 +3,8 @@ import 'package:qr_code_scanner/qr_code_scanner.dart';
|
||||
import 'package:simplex_chat/constants.dart';
|
||||
import 'package:simplex_chat/widgets/custom_btn.dart';
|
||||
|
||||
/// Tap in the middle of QR Code to see the flow of contact being added in the Chat View
|
||||
|
||||
class QRCodeDetailsView extends StatelessWidget {
|
||||
final Barcode barcode;
|
||||
const QRCodeDetailsView({
|
||||
|
@ -5,6 +5,10 @@ import 'package:simplex_chat/views/conversation/contact_detail_conversation.dart
|
||||
import 'package:simplex_chat/views/conversation/group_detail_conversation.dart';
|
||||
import 'package:simplex_chat/widgets/message_bubble.dart';
|
||||
|
||||
/// View the details of group by tapping the [appBar]
|
||||
/// Viwe the details of chat by tapping the [appBar]
|
||||
/// Generate [Fake Messages] by tapping the [Message Icon]
|
||||
|
||||
class ConversationView extends StatefulWidget {
|
||||
// ignore: prefer_typing_uninitialized_variables
|
||||
final data;
|
||||
|
@ -2,7 +2,6 @@ import 'package:flutter/material.dart';
|
||||
import 'package:flutter_svg/flutter_svg.dart';
|
||||
import 'package:provider/provider.dart';
|
||||
import 'package:shared_preferences/shared_preferences.dart';
|
||||
import 'package:simplex_chat/constants.dart';
|
||||
import 'package:simplex_chat/providers/drawer_providers.dart';
|
||||
|
||||
class MyDrawer extends StatelessWidget {
|
||||
@ -49,6 +48,7 @@ class MyDrawer extends StatelessWidget {
|
||||
);
|
||||
}
|
||||
|
||||
// remove the locally stored user data
|
||||
void _switchProfile(BuildContext context) async {
|
||||
SharedPreferences prefs = await SharedPreferences.getInstance();
|
||||
|
||||
|
@ -12,6 +12,8 @@ import 'package:simplex_chat/views/home/drawer.dart';
|
||||
import 'package:simplex_chat/views/invitations/invitation_view.dart';
|
||||
import 'package:simplex_chat/views/profile/profile_view.dart';
|
||||
|
||||
/// Generate [Fake Contacts] by tapping the [Bug Icon]
|
||||
|
||||
class HomeView extends StatefulWidget {
|
||||
final double maxSlide;
|
||||
const HomeView({Key? key, required this.maxSlide}) : super(key: key);
|
||||
|
@ -161,7 +161,7 @@ class _SetupProfileViewState extends State<SetupProfileView> {
|
||||
);
|
||||
}
|
||||
|
||||
// create profile and store in local
|
||||
// create profile and save the data locally to access across the app
|
||||
Future<void> _createProfile() async {
|
||||
SharedPreferences prefs = await SharedPreferences.getInstance();
|
||||
await prefs.setString('displayName', _displayNameController.text.trim());
|
||||
|
@ -39,10 +39,7 @@ class _SplashScreenState extends State<SplashScreen> {
|
||||
EntranceFader(
|
||||
duration: const Duration(seconds: 1),
|
||||
offset: const Offset(0, 15),
|
||||
child: SvgPicture.asset(
|
||||
'assets/logo.svg',
|
||||
height: 85,
|
||||
),
|
||||
child: SvgPicture.asset('assets/logo.svg', height: 85),
|
||||
),
|
||||
EntranceFader(
|
||||
offset: const Offset(0, 0),
|
||||
|
Loading…
Reference in New Issue
Block a user