PlaceholderImageProps class

Placeholder image component properties.

Constructors

PlaceholderImageProps({PlaceholderSource source = PlaceholderSource.cat, String? seed, PlaceholderSize size = PlaceholderSize.md, int? width, int? height, PlaceholderShape shape = PlaceholderShape.rounded, PlaceholderFit fit = PlaceholderFit.cover, String? alt, String? text, bool animated = false, bool grayscale = false, int? blur, String? backgroundColor, String? textColor, bool lazy = true, void onTap()?, String? classes})
const

Properties

alt String?
Alt text for accessibility.
final
animated bool
Use animated GIF (only for PlaceholderSource.cat).
final
backgroundColor String?
Background color for placeholder source.
final
blur int?
Blur amount (0-10, only for PlaceholderSource.picsum).
final
classes String?
Custom CSS classes.
final
fit PlaceholderFit
Object fit behavior.
final
grayscale bool
Grayscale filter.
final
hashCode int
The hash code for this object.
no setterinherited
height int?
Custom height (overrides size preset).
final
lazy bool
Use lazy loading.
final
onTap → void Function()?
Click handler.
final
resolvedHeight int
Get the resolved height in pixels.
no setter
resolvedWidth int
Get the resolved width in pixels.
no setter
runtimeType Type
A representation of the runtime type of the object.
no setterinherited
seed String?
Seed for deterministic/consistent images. The same seed will return the same image.
final
shape PlaceholderShape
Shape of the image container.
final
size PlaceholderSize
Size preset for the image.
final
source PlaceholderSource
The placeholder image source provider.
final
text String?
Text to overlay on cat images (only for PlaceholderSource.cat).
final
textColor String?
Text color for placeholder source.
final
width int?
Custom width (overrides size preset).
final

Methods

copyWith({PlaceholderSource? source, String? seed, PlaceholderSize? size, int? width, int? height, PlaceholderShape? shape, PlaceholderFit? fit, String? alt, String? text, bool? animated, bool? grayscale, int? blur, String? backgroundColor, String? textColor, bool? lazy, void onTap()?, String? classes}) PlaceholderImageProps
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited