Documentation
Avatar

Avatar

An image element with a fallback for representing the user.

Usage

FAvatar(...)

FAvatar(
  image: const NetworkImage('https://raw.githubusercontent.com/forus-labs/forui/main/samples/assets/avatar.png'),
  fallback: const Text('MN'),
);

FAvatar.raw(...)

// Raw constructor - with icon.
FAvatar.raw(
  child: FAssets.icons.baby(
    colorFilter: ColorFilter.mode(theme.colorScheme.mutedForeground, BlendMode.srcIn),
  ),
);
 
// Raw constructor - with text.
FAvatar.raw(child: const Text('MN'));

Examples

Invalid Image

Raw Constructor