Documentation Index
Fetch the complete documentation index at: https://synapsync.mintlify.app/llms.txt
Use this file to discover all available pages before exploring further.
Overview
NbxNetworkImage is a comprehensive network image widget that wraps CachedNetworkImage and provides extensive customization for loading, caching, error handling, animations, and styling.
Basic Usage
Widget Properties
Required Properties
The URL of the image to load and display.
Size Properties
The width of the image. If null, the image will size itself based on its content.
The height of the image. If null, the image will size itself based on its content.
How to inscribe the image into the space allocated during layout.
State Widgets
Widget displayed while the image is loading. If null, a default loading indicator is shown.
Widget displayed when an error occurs while loading the image. If null, a default error widget is shown.
Network Properties
The HTTP headers to use when loading the image.
Configuration Objects
Cache configuration options for memory and disk caching.
Animation configuration for fade-in/fade-out effects.
Progress indicator configuration options.
Style configuration for borders, shadows, and filters.
Configuration Classes
NbxImageCacheConfig
Controls image caching behavior.Maximum width for the in-memory cache. Null means no constraint.
Maximum height for the in-memory cache. Null means no constraint.
Maximum width for the disk cache.
Maximum height for the disk cache.
Custom cache key. If null, the image URL is used.
Whether to keep displaying the old image when the URL changes.
Custom cache manager instance.
NbxImageAnimationConfig
Controls fade animations.Duration of the fade-in animation when the image loads.
Duration of the fade-out animation when the placeholder hides.
Curve for the fade-in animation.
Curve for the fade-out animation.
NbxImageProgressConfig
Controls the loading progress indicator.Custom progress indicator builder. When provided, overrides the default.
Size of the default progress indicator.
Color of the progress indicator.
Stroke width for the circular progress indicator.
Background color of the progress indicator track.
Whether to use a circular (true) or linear (false) progress indicator.
NbxImageStyleConfig
Controls visual styling.Border radius applied to the image container.
Border drawn around the image container.
Box shadows applied to the image container.
Clip behavior for the image container.
Color filter applied to the image.
Blend mode for the color filter.
Filter quality for image rendering.
How the image should be repeated if it doesn’t fill its bounds.
Whether to match the text direction for the image.
Factory Constructors
NbxNetworkImage.circular
Creates a circular network image.URL of the image.
Radius of the circular image.
How to fit the image.
Custom placeholder widget.
Custom error widget.
Override border radius (defaults to circular).
Border around the image.
Box shadows.
NbxNetworkImage.square
Creates a square network image.URL of the image.
Size of the square image (width and height).
How to fit the image.
Custom placeholder widget.
Custom error widget.
Border radius.
Border around the image.
Box shadows.
NbxNetworkImage.rounded
Creates a network image with rounded corners.URL of the image.
Width of the image.
Height of the image.
Border radius value.
How to fit the image.
Custom placeholder widget.
Custom error widget.
Border around the image.
Box shadows.
Examples
Basic Image
Circular Avatar
With Custom Cache
With Custom Progress Indicator
With Custom Placeholder and Error
With Border and Shadow
With HTTP Headers
With Color Filter
Thumbnail Grid
See Also
- CachedNetworkImage - Underlying package
- Image configuration classes - Configuration implementations