avatar_fallback 0.1.0
avatar_fallback: ^0.1.0 copied to clipboard
A Flutter avatar widget with a reliable fallback chain: any ImageProvider down to deterministic, grapheme-safe initials that never fail.
0.1.0 #
Initial release.
AvatarFallbackwidget with a convenience constructor (image + initials fallback) and anAvatarFallback.sourcesconstructor for an explicit priority chain.AvatarSourcesealed hierarchy:ImageAvatarSource,NetworkAvatarSource,AssetAvatarSource,IconAvatarSource,WidgetAvatarSource.- Support for any
ImageProvider(network, asset, memory, file, or a pluggable cache such asCachedNetworkImageProvider). - Stable, deterministic background colors from names using an FNV-1a hash
(not
String.hashCode), with automatic contrasting text color. - Unicode-correct, grapheme-safe initials that handle emoji, combining marks and RTL names.
AvatarShapesealed type:circle,square, androunded(radius).AvatarGroupwith overlap control and a customizable+Noverflow indicator.- Badge slot, accessibility semantics, and image fade-in.
- Material 3 theming via
AvatarFallbackTheme(ThemeExtension). - Zero heavy dependencies; works on Android, iOS, web, macOS, Windows and Linux.