An open API service indexing awesome lists of open source software.

https://github.com/feduke-nukem/flutter_captcha


https://github.com/feduke-nukem/flutter_captcha

Last synced: 5 months ago
JSON representation

Awesome Lists containing this project

README

          



#### Flutter Captcha

2
3

## Features

Provide any widget, and it will be automatically divided into parts that can be rotated and positioned. At any point, you can check the solution status to confirm if the user has successfully passed the captcha test.

## Getting started

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

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

@override
State createState() => _MyAppState();
}

class _MyAppState extends State {
final _controller = FlutterCaptchaController(
random: Random.secure(),
)..init();

@override
void dispose() {
_controller.dispose();
super.dispose();
}

@override
Widget build(BuildContext context) {
return MaterialApp(
title: 'Flutter Demo',
theme: ThemeData(
colorScheme: ColorScheme.fromSeed(seedColor: Colors.deepPurple),
useMaterial3: true,
),
home: Scaffold(
body: Center(
child: FlutterCaptcha(
controller: _controller,
crossLine: (color: Colors.white, width: 10),
fit: BoxFit.cover,
draggingBuilder: (_, child) => Opacity(opacity: 0.5, child: child),
child: Image.network(
'https://upload.wikimedia.org/wikipedia/commons/4/4f/Dash%2C_the_mascot_of_the_Dart_programming_language.png',
),
),
),
),
);
}
}
```

Try it out by [link](https://feduke-nukem.github.io/flutter_captcha/)