FLUTTER ECOSYSTEM

shivamshashank/authentication_buttons

Flutter 인증 버튼 패키지

authentication_buttons 프로젝트 이미지
Stars
1
Forks
0
최근 푸시(UTC)
2023. 8. 7.
프로젝트 상태
활성
Shivam Shashank GitHub avatar
GITHUB User

Shivam Shashank ↗

Cloud Engineer @ HPE → DevOps & SRE Kubernetes, CI/CD, Observability, Multi-cloud Building AI tools for production systems (LogDoctor)

HPEUnited Kingdom공식 웹사이트 ↗
언어DartCMakeShellCObjective-CJavaC++Swift

이 저장소가 배포한 패키지

사용 중인 의존성

의존성 목록 3 개
  • flutter{"sdk":"flutter"}
  • flutter_test개발 의존성{"sdk":"flutter"}
  • flutter_lints개발 의존성^2.0.2

원본 README

아래는 영문 원문 스냅샷입니다. 최신 내용은 GitHub에서 확인하세요.

README 펼치기 / 접기

pub package pub points LinkedIn

Authentication Buttons

Authentication Buttons allows users to build social media authentication buttons for all popular SSO systems.

Usage

Add the dependency in pubsec.yaml file.

  dependencies:
    flutter:
      sdk: flutter
    authentication_buttons: 0.0.5

How to Use

  AuthenticationButton(
    authenticationMethod: AuthenticationMethod.google,
    onPressed: () {},
  )

Additional parameters that you might supply include:

  • AuthenticationMethod

    • google
    • apple
    • microsoft
    • facebook
    • reddit
    • twitter
    • linkedin
    • github
    • medium
    • dribbble
    • spotify
    • pinterest
  • ButtonSize

    • small
    • large
  • ShowLoader

    • true
    • false

Below is the example with all arguments supplied:

  AuthenticationButton(
    authenticationMethod: AuthenticationMethod.apple,
    onPressed: () {},
    showLoader: true,
  ),

Screenshots

demo screenshot_1 screenshot_2

Example

import 'package:authentication_buttons/src/authentication_button.dart';
import 'package:authentication_buttons/src/utils/enums/authentication_method.dart';
import 'package:authentication_buttons/src/utils/enums/button_size.dart';
import 'package:flutter/material.dart';

void main() => runApp(
      const MaterialApp(
        title: 'Authentication Buttons',
        home: AuthenticationButtonsExample(),
      ),
    );

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

  @override
  Widget build(BuildContext context) {
    return Scaffold(
      appBar: AppBar(
        title: const Text(
          'Authentication Buttons',
        ),
      ),
      body: Column(
        mainAxisAlignment: MainAxisAlignment.spaceEvenly,
        children: [
          AuthenticationButton(
            authenticationMethod: AuthenticationMethod.google,
            onPressed: () {},
          ),
          AuthenticationButton(
            authenticationMethod: AuthenticationMethod.pinterest,
            onPressed: () {},
            showLoader: true,
          ),
          AuthenticationButton(
            authenticationMethod: AuthenticationMethod.microsoft,
            onPressed: () {},
            showLoader: true,
          ),
          Row(
            mainAxisAlignment: MainAxisAlignment.spaceEvenly,
            children: [
              AuthenticationButton(
                authenticationMethod: AuthenticationMethod.twitter,
                onPressed: () {},
                buttonSize: ButtonSize.small,
              ),
              AuthenticationButton(
                authenticationMethod: AuthenticationMethod.dribbble,
                onPressed: () {},
                buttonSize: ButtonSize.small,
                showLoader: true,
              ),
              AuthenticationButton(
                authenticationMethod: AuthenticationMethod.spotify,
                onPressed: () {},
                buttonSize: ButtonSize.small,
              ),
            ],
          ),
        ],
      ),
    );
  }
}

Contributing

Pull requests are welcome 🙏

For major changes, please open an issue on github