main_auth 0.0.9 copy "main_auth: ^0.0.9" to clipboard
main_auth: ^0.0.9 copied to clipboard

This package provides a customizable **Login** and **Sign-Up** screen for Flutter applications. It allows easy integration of login forms, social login buttons, and customization of titles, styles, an [...]

example/lib/main.dart

import 'package:flutter/material.dart';
import 'package:main_auth/main_auth.dart';
import 'package:smart_localize/smart_localize.dart';

void main() {
  runApp(const MyApp());
}

class MyApp extends StatelessWidget {
  const MyApp({super.key});

  // This widget is the root of your application.
  @override
  Widget build(BuildContext context) {
    return MaterialApp(
      debugShowCheckedModeBanner: false,
      supportedLocales: const [
        Locale('en'),
        Locale('ar'),
      ],
      locale: const Locale('ar'),
      localeResolutionCallback: (locale, supportedLocales) =>
          locale ?? const Locale('ar'),
      localizationsDelegates: context.smartLocalizeDelegates,
      title: 'Flutter Demo',
      theme: ThemeData(
        colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple),
        useMaterial3: true,
      ),
      home: const MyHomePage(),
    );
  }
}

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

  @override
  State<MyHomePage> createState() => _MyHomePageState();
}

class _MyHomePageState extends State<MyHomePage> {
  @override
  Widget build(BuildContext context) {
    return const Scaffold(
      body: SafeArea(
        child: Column(
          children: [
            ForgotPasswordWidget(),
          ],
        ),
      ),
    );
    // return MainAuth(
    //   loginModel: AuthModel(
    //     hideAppBar: true,
    //     isLoading: true,
    //     onPressed: (email, password, phone, name) =>
    //         log('$email, $password,$phone'),
    //     socialModel: SocialModel(
    //       onTapFacebook: () => log('facebook'),
    //       onTapGoogle: () => log('google'),
    //       onTapApple: () => log('apple'),
    //       onTapX: () => log('x'),
    //       // hideSocialAuth: true,
    //       socialButtonType: SocialButtonType.defaultType,
    //       // hideSocialAuth: true,
    //       socialAuthList: const [
    //         SocialAuth.apple,
    //         SocialAuth.google,
    //         SocialAuth.facebook,
    //         SocialAuth.x,
    //       ],
    //     ),
    //   ),
    //   signUpModel: AuthModel(
    //     hideAppBar: true,
    //     isLoading: true,
    //     onPressed: (email, password, phone, name) =>
    //         log('$email, $password,$phone '),
    //     socialModel: SocialModel(
    //       onTapFacebook: () => log('facebook'),
    //       onTapGoogle: () => log('google'),
    //       onTapApple: () => log('apple'),
    //       onTapX: () => log('x'),
    //
    //       socialButtonType: SocialButtonType.icon,
    //       // hideSocialAuth: true,
    //       // hideSocialAuth: true,
    //       socialAuthList: const [
    //         SocialAuth.apple,
    //         SocialAuth.google,
    //         SocialAuth.facebook,
    //         SocialAuth.x,
    //       ],
    //     ),
    //   ),
    // );
  }
}
4
likes
0
points
213
downloads

Publisher

verified publisherabdelrahman.ghanem.eg

Weekly Downloads

This package provides a customizable **Login** and **Sign-Up** screen for Flutter applications. It allows easy integration of login forms, social login buttons, and customization of titles, styles, and layouts.

Homepage
Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter, flutter_svg, main_button, main_text_field, smart_localize

More

Packages that depend on main_auth