password_strength_checker 1.1.0+2 copy "password_strength_checker: ^1.1.0+2" to clipboard
password_strength_checker: ^1.1.0+2 copied to clipboard

Check the strength of the password in a visual way, with an animation when the strength changes according to the settings given by the user. You can also use it for form validation

example/password_strength_checker_example.dart

import 'package:flutter/material.dart';
import 'package:password_strength_checker/password_strength_checker.dart';

class HomePage extends StatelessWidget {
  const HomePage({Key? key}) : super(key: key);

  @override
  Widget build(BuildContext context) {
    final passNotifier = ValueNotifier<PasswordStrength?>(null);

    return Scaffold(
      body: Padding(
        padding: const EdgeInsets.all(8.0),
        child: Column(
          mainAxisAlignment: MainAxisAlignment.center,
          children: [
            TextField(
              decoration: const InputDecoration(
                border: OutlineInputBorder(),
                labelText: 'Password',
              ),
              onChanged: (value) {
                passNotifier.value = PasswordStrength.calculate(text: value);
              },
            ),
            const SizedBox(height: 20),
            PasswordStrengthChecker(
              strength: passNotifier,
            ),
          ],
        ),
      ),
    );
  }
}
33
likes
0
pub points
92%
popularity

Publisher

unverified uploader

Check the strength of the password in a visual way, with an animation when the strength changes according to the settings given by the user. You can also use it for form validation

Repository (GitHub)
View/report issues

License

unknown (license)

Dependencies

flutter

More

Packages that depend on password_strength_checker