Flutter widget library containing buttons for authenticating with popular social networks: Apple, Google, Facebook, Twitter and Microsoft.

Overview

Flutter Auth Buttons

Build Status


This library is now in maintenance mode

I'm no longer actively using Flutter and don't have the time to keep this library maintained. No further changes will be made.

You are very welcome to fork and maintain this elsewhere. If you do that, please let me know and I can point people there.

Otherwise, there are some other libraries (such as this one) which seem more advanced and could be a good choice.


Flutter widget library containing buttons for authenticating with popular social networks: Apple, Google, Facebook, Twitter and Microsoft.

Screenshot

Usage

Add flutter_auth_buttons to your pubspec.yaml, then import the Dart file:

import 'package:flutter_auth_buttons/flutter_auth_buttons.dart';

Use the onPressed attribute to capture the button press and call your authentication logic within that. To disable the button, pass null or omit the attribute.

FacebookSignInButton(onPressed: () {
  // call authentication logic
});

Some buttons have a dark mode. Enable this with the optional parameter:

GoogleSignInButton(
  onPressed: () {/* ... */}, 
  darkMode: true, // default: false
)

You can adjust the border-radius of the buttons:

TwitterSignInButton(
  onPressed: () {},
  borderRadius: 10.0,
)

You can adjust the text style of the buttons:

TwitterSignInButton(
  onPressed: () {},
  textStyle: TextStyle(fontSize: 20, fontWeight: FontWeight.w700, fontFamily: "Roboto"),
)

You can adjust the splash color of the buttons:

GoogleSignInButton(
  onPressed: () {/* ... */}, 
  splashColor: Colors.white, 
  // setting splashColor to Colors.transparent will remove button ripple effect.
)

Buttons can be stretched like normal Material buttons. By default the button contents are left-aligned when stretched. You can choose to center the icon and text using the centered property.

TwitterSignInButton(
  onPressed: () {},
  centered: true,
)

See the documentation for API details: https://pub.dartlang.org/documentation/flutter_auth_buttons/latest/.

Contributions

Contributions are very welcome. I would recommend discussing large changes in an issue before you spend the time on them.

Good quality pull requests will win you commit rights.

Comments
  • Apple Sign in Button

    Apple Sign in Button

    Will the apple sign in button be supported in future updates? https://developer.apple.com/design/human-interface-guidelines/sign-in-with-apple/overview/

    enhancement 
    opened by OliverNarramore 5
  • Expose splashColor property for buttons.

    Expose splashColor property for buttons.

    This will allow the splashColor to be set. One major benefit to this is the ability remove the ripple effect from the buttons if desired. This can be done by setting splashColor to Colors.transparent. I also updated the tests and the README.

    opened by bitmoxy 4
  • Add expanded attribute for buttons

    Add expanded attribute for buttons

    Closes #31

    It looks terrible when all buttons have different sizes. This PR adds an attribute expanded to each of them that allows expansion along the horizontal axis to max.

    opened by romatallinn 3
  • Add Apple Sign In

    Add Apple Sign In

    This PR adds apple sign in button built according to the official guidelines - https://developer.apple.com/design/human-interface-guidelines/sign-in-with-apple/overview/ - some details were inexplicit and had to be estimated.

    Also, the example main.dart now has a container of SingleScrollChildView to prevent devices with smaller screens to overflow.

    opened by json469 3
  • Icon doesn't work on google button

    Icon doesn't work on google button

    I just tried version 0.5.0 in my project with a google button (dark) and I get no icon and this exception:

    I/flutter (24157): ══╡ EXCEPTION CAUGHT BY IMAGE RESOURCE SERVICE ╞════════════════════════════════════════════════════ I/flutter (24157): The following assertion was thrown resolving an image codec: I/flutter (24157): Unable to load asset: packages/flutter_auth_buttons/graphics/google-logo.png I/flutter (24157): I/flutter (24157): When the exception was thrown, this was the stack: I/flutter (24157): #0 PlatformAssetBundle.load (package:flutter/src/services/asset_bundle.dart:221:7) I/flutter (24157): I/flutter (24157): #1 AssetBundleImageProvider._loadAsync (package:flutter/src/painting/image_provider.dart:464:44) I/flutter (24157): I/flutter (24157): #2 AssetBundleImageProvider.load (package:flutter/src/painting/image_provider.dart:449:14) I/flutter (24157): #3 ImageProvider.resolve... (package:flutter/src/painting/image_provider.dart:315:48) I/flutter (24157): #4 ImageCache.putIfAbsent (package:flutter/src/painting/image_cache.dart:160:22) I/flutter (24157): #5 ImageProvider.resolve.. (package:flutter/src/painting/image_provider.dart:315:25) I/flutter (24157): (elided 13 frames from package dart:async) I/flutter (24157): I/flutter (24157): Image provider: AssetImage(bundle: null, name: I/flutter (24157): "packages/flutter_auth_buttons/graphics/google-logo.png") I/flutter (24157): Image key: AssetBundleImageKey(bundle: PlatformAssetBundle#833bd(), name: I/flutter (24157): "packages/flutter_auth_buttons/graphics/google-logo.png", scale: 1.0) I/flutter (24157): ════════════════════════════════════════════════════════════════════════════════════════════════════

    invalid 
    opened by UglyBob79 3
  • Introduced Github and Instagram Buttons

    Introduced Github and Instagram Buttons

    Was happy to come upon your flutter_auth_buttons package to use it in my own efforts. I did have to include two more buttons in my project, and felt maybe it could be included in this package.

    I couldn't readily find the 'button guidelines' you mentioned in the existing buttons however.

    Regardless, thanks for providing this package for use.

    Cheers.

    Greg

    opened by Andrious 3
  • Buttons can not be integrated into a SliverFillRemaining widget

    Buttons can not be integrated into a SliverFillRemaining widget

    The LayoutBuilder within StretchableButton will cause an error like this:

    I/flutter (23641): ══╡ EXCEPTION CAUGHT BY RENDERING LIBRARY ╞═════════════════════════════════════════════════════════
    I/flutter (23641): The following assertion was thrown during performLayout():
    I/flutter (23641): LayoutBuilder does not support returning intrinsic dimensions.
    I/flutter (23641): Calculating the intrinsic dimensions would require running the layout callback speculatively, which
    I/flutter (23641): might mutate the live render object tree.
    I/flutter (23641):
    I/flutter (23641): The relevant error-causing widget was:
    I/flutter (23641):   SliverFillRemaining
    I/flutter (23641):   
    lib/…/account/sign_in_screen.dart:69
    I/flutter (23641):
    I/flutter (23641): When the exception was thrown, this was the stack:
    
    needs-info 
    opened by ened 2
  • Increase the font and icon size for the Sign in with Apple button.

    Increase the font and icon size for the Sign in with Apple button.

    I increased the font and icon size for the Sign in with Apple button, so that it is the same as for the other sign in buttons. This is in response to Apple rejecting an update to my app because of the 'Sign in with Apple' button having a slightly smaller font than the buttons for the other social login providers.

    This is their exact response:

    Your app uses Sign in with Apple as a login option but does not use the appropriate Sign in with Apple button design, branding, and/or user interface elements as described in the Sign in With Apple Human Interface Guidelines. Specifically:
    
    - Your Sign in with Apple button is not displayed as prominently in your app as other sign in buttons.
    
    Next Steps
    
    To resolve this issue, revise the Sign in with Apple button design, branding and/or user interface elements in your app so that it follows all the Sign in With Apple Human Interface Guidelines.
    
    opened by itsMatoosh 1
  • Added attribute to center button contents

    Added attribute to center button contents

    Added a simple attribute to the StretchableButton widget to allow for centering of the button contents as the buttons expand.

    • I left the default behavior not centered and the attribute false to maintain compatibility.
    • I also updated the current library of auth buttons to work with this change.
    • Tested within my own project and behaves like original package with new functionality
    • Not sure if any documentation changes are needed as it is an easily found attribute for the widgets, open to discussion and revision of current documentation if needed.

    Fixes #31

    opened by Jwildsmith 1
  • New Facebook Icon

    New Facebook Icon

    The new facebook "f" icon is required according to the new branding guidelines:

    https://en.facebookbrand.com/facebookapp/assets/f-logo/?audience=advertisers https://developers.facebook.com/docs/facebook-login/userexperience/

    opened by chetan-cueclad 1
  • [Feature Request] Support RTL (for google button specifically)

    [Feature Request] Support RTL (for google button specifically)

    I'm currently using the Facebook and the Google button.

    While I can provider text for both, the alignment on the text with the icon is only correct for the Facebook one.

    The google button will align the text to the end (left side in an rtl) and the icon to the right, creating a large margin between them. The text should also be aligned to the right, right after the icon.

    duplicate 
    opened by matanshukry 1
Releases(v0.8.0)
Authentication API client with Flutter (Login, Register, Google Login, Facebook Login, Apple Login)

Flutter Auth App (Login, Register, Google Login, Facebook Login, Apple Login) To use this client, get the server up and running. Try it out now! App S

Denzel Giraldo 50 Jan 4, 2023
AI Library to create efficient Artificial Neural Networks. Computation uses SIMD (Single Instruction Multiple Data) to improve performance.

eneural_net eNeural.net / Dart is an AI Library for efficient Artificial Neural Networks. The library is portable (native, JS/Web, Flutter) and the co

null 21 Dec 29, 2022
KGE social login (google, facebook)

social_logain A new Flutter project. Getting Started This project is a starting point for a Flutter application. A few resources to get you started if

null 1 Dec 23, 2021
A Flutter plugin for authenticating users by using the native TwitterKit SDKs on Android & iOS.

flutter_twitter_login A Flutter plugin for using the native TwitterKit SDKs on Android and iOS. This plugin uses the new Gradle 4.1 and Android Studio

Iiro Krankka 83 Sep 15, 2022
Flutter plugin for authenticating a user with a web service

A Flutter plugin for authenticating a user with a web service, even if the web service is run by a third party. Most commonly used with OAuth2, but can be used with any web flow that can redirect to a custom scheme.

Linus Unnebäck 170 Jan 3, 2023
This is just the simplyfied Flutter Plugin use for one of the popular flutter plugin for social media login.

social_media_logins Flutter Plugin to login via Social Media Accounts. Available Social Media Logins: Facebook Google Apple Getting Started To use thi

Reymark Esponilla 3 Aug 24, 2022
A flutter plugin to get facebook deep links and log app events using the latest Facebook SDK to include support for iOS 14

Facebook Sdk For Flutter LinkedIn GitHub facebook_sdk_flutter allows you to fetch deep links, deferred deep links and log facebook app events. This wa

Saad Farhan 23 Dec 17, 2022
Facebook-redesign - An app developed that show a Facebook inspired UI design

Superbe Lecteur de Musique fait avec Flutter ! Captures d'Écran Construire depui

Youssef Marzouk 4 Jul 7, 2022
Maps for Flutter developers. Supports Apple, Bing, and Google APIs.

Overview Cross-platform geographic maps for Flutter applications. Pull requests are welcome! The packages are licensed under the Apache License 2.0. P

Dint 17 Oct 13, 2022
A lightweight flutter plugin to check if your app is up-to-date on Google Play Store or Apple App Store

App Version Checker this package is used to check if your app has a new version on playstore or apple app store. or you can even check what is the lat

Iheb Briki 6 Dec 14, 2022
A Flutter package for generating sign in buttons for different social media accounts.

Sign In Button A Flutter plugin for generating sign in buttons for different social media accounts. Getting Started You must add the library as a depe

null 42 Dec 8, 2022
Flutter library for Moyasar. Supports Apple Pay, STC Pay and Credit Card.

Flutter library for Moyasar. Supports Apple Pay, STC Pay and Credit Card.

null 12 Oct 22, 2022
Creating complete social media app like instagram, facebook using flutter dart.

instoo The social media application that allows user to check out new feed, like, comment and even check other user’s profile. It has search, follow,

Pratul Pant 9 Dec 1, 2022
Fluent System Icons are a collection of familiar, friendly and modern icons from Microsoft.

Fluent UI System Icons Fluent UI System Icons are a collection of familiar, friendly and modern icons from Microsoft. Icon List View the full list of

Microsoft 4.3k Dec 29, 2022
A Flutter library for work with Apple Wallet passes.

pass-flutter A Flutter library for work with Apple Wallet passes. How use it Getting pass from URL to internal memory import 'package:pass_flutter/pas

Alexey Lepskii 16 Dec 30, 2022
Implements Microsoft's Fluent Design System in Flutter.

fluent_ui Design beautiful native windows apps using Flutter Unofficial implementation of Fluent UI for Flutter. It's written based on the official do

Bruno D'Luka 1.8k Dec 29, 2022
flutter grpc video app && microsoft text to speech

flutter_video_app Getting Started Install dart protoc_plugin pub global activate protoc_plugin Clone WarpDriveProtocol git clone [email protected]

Liberxue 4 Sep 1, 2022
Most popular and easy to use open source UI library with 1000+ Widgets to build flutter app.

GetWidget is a 100% free Flutter open-source UI Kit library built with Flutter SDK to make Flutter development easier and more joyful than ever. GetWi

Ionicfirebaseapp 3.7k Jan 1, 2023
Most popular and easy to use open source UI library with 1000+ Widgets to build flutter app.

GetWidget is a 100% free Flutter open-source UI Kit library built with Flutter SDK to make Flutter development easier and more joyful than ever. GetWi

Ionicfirebaseapp 3.7k Jan 3, 2023