dashatar_flutter 0.1.0
dashatar_flutter: ^0.1.0 copied to clipboard
A Flutter package for using Dashatars in Flutter projects
Dashatar Flutter #
A Flutter package that provides an API for using Dashatars in Flutter projects.
Try it out in the example app.
Features #
- Generate Dash avatars (Dashatars)
- Choose from different dashatar types (Silhouette, Basic, Designer, Developer, Manager)
- Use random or specific dashatar variants
- Customize size and background color
- Simple and flexible API
Usage #
Basic Usage #
import 'package:dashatar_flutter/dashatar_flutter.dart';
// Basic usage - create a Developer dashatar
Dashatar(
index: 5, // Variant index (0-48)
type: DashatarType.developer,
)
// Create a random dashatar
Dashatar.random()
// Create a basic dashatar (middle style)
Dashatar.basic()
// Create a silhouette
Dashatar.silhouette()
Customization #
// Custom size and background color
Dashatar(
index: 12,
type: DashatarType.manager,
size: 100,
backgroundColor: Colors.blue.shade100,
)
Example #
Check out the included example app for a complete demonstration of the package features.
Run the example with:
cd example
flutter run
Attribution #
The dashatar images were originally created by the Persian Flutter community and are used with permission:
- Repository: https://github.com/PersianFlutter/dashatars