pub.dev Dart CI Stars Issues MIT License

Blockies

A tiny library for generating blocky identicons. Direct port of JavaScript library @download/blockies.

Introduction

Blockies library generates a variety of an Identicon which is a visual representation of a hash value (eg. blockchain address), that serves to identify a user of a computer system as a form of avatar while protecting the user's privacy.

By default the generated identicon is 10x10 blocks. All colors are generated from the seed unless manually overriden. Blocky is sized based on the parent widget size.

Usage

// Create blocky
Blockies(
  seed: '0xe95C0ed548f63B181f6528B8e3c57a7c93C2E3Dc', // seed used to generate identicon
  color: Color(0xFFD95030),     // to manually specify the icon color, default: random
  bgColor: Color(0x000000),     // choose a different background color, default: random based on the seed
  spotColor: Color(0xFFE6D690), // choose a different spot color, default: random based on the seed
  size: 8,                      // width and height of the icon in blocks, default: 10
);

Changelog

Please see CHANGELOG for more information on what has changed recently.

Credits

License

The MIT License (MIT). Please see License File for more information.

Libraries

blockies