Skip to content

A flutter plugin to show beautiful pin code view.

License

Notifications You must be signed in to change notification settings

KomodoPlatform/pin_code_view

 
 

Repository files navigation

pin_code_view

A beautiful looking pin_code_view for flutter apps, customizable and fluid. Pull requests are always welcomed.

Installation

In the dependencies: section of your pubspec.yaml, add the following line:

  pin_code_view: 0.2.1

Usage

import 'package:pin_code_view/pin_code_view.dart';

class MyWidget extends StatelessWidget {
  Widget build(BuildContext context) {
    return PinCode(
      title: Text(
        "Lock Screen",
        style: TextStyle(
            color: Colors.white, fontSize: 25.0, fontWeight: FontWeight.bold),
      ),
      
      subTitle: Text(
        "Enter the pin code",
        style: TextStyle(color: Colors.white),
      ),
      codeLength: 6,
      // you may skip correctPin and plugin will give you pin as
      // call back of [onCodeFail] before it clears pin
      correctPin: "1234",
      onCodeSuccess: (code) {
        print(code); 
      },
      onCodeFail: (code) {
        print(code); 
      }, 
    );
  }
}

About

A flutter plugin to show beautiful pin code view.

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Dart 92.3%
  • Java 4.3%
  • Objective-C 3.4%