[0.1.3]
This commit is contained in:
@@ -1,6 +1,7 @@
|
|||||||
## 0.1.3
|
## 0.1.3
|
||||||
- **FIX**: Added export for `ImageSizingMaster`.
|
- **FIX**: Added export for `ImageSizingMaster`.
|
||||||
- **FIX**: Removed `placeholderBuilder` Error because I was supplying it along with `progressIndicatorBuilder`.
|
- **FIX**: Removed `placeholderBuilder` Error because I was supplying it along with `progressIndicatorBuilder`.
|
||||||
|
- **FIX**: Fixed height wasn't constrained in Image widget.
|
||||||
|
|
||||||
## 0.1.2
|
## 0.1.2
|
||||||
- **FIX**: Updated Switcher toggle not recognizing disabled mode.
|
- **FIX**: Updated Switcher toggle not recognizing disabled mode.
|
||||||
|
|||||||
@@ -112,7 +112,7 @@ class AstromicImage extends StatelessWidget {
|
|||||||
/// Used when the height is Master and want to set fixed height OR if width is Master and want to constraint the height
|
/// Used when the height is Master and want to set fixed height OR if width is Master and want to constraint the height
|
||||||
final double? fixedHeight;
|
final double? fixedHeight;
|
||||||
//S1 -- STYLING
|
//S1 -- STYLING
|
||||||
final bool? isCircular;
|
final bool isCircular;
|
||||||
final double? borderWidth;
|
final double? borderWidth;
|
||||||
final Color? borderColor;
|
final Color? borderColor;
|
||||||
final EdgeInsetsGeometry? borderPadding;
|
final EdgeInsetsGeometry? borderPadding;
|
||||||
@@ -188,7 +188,7 @@ class AstromicImage extends StatelessWidget {
|
|||||||
key: ValueKey<String>(assetType == _DeclaredAssetType.bytes ? (assetRef as Uint8List).length.toString() : assetRef),
|
key: ValueKey<String>(assetType == _DeclaredAssetType.bytes ? (assetRef as Uint8List).length.toString() : assetRef),
|
||||||
//
|
//
|
||||||
width: size.width,
|
width: size.width,
|
||||||
height: size.height,
|
height: size.height == double.infinity? null : size.height,
|
||||||
fit: fit,
|
fit: fit,
|
||||||
alignment: alignment,
|
alignment: alignment,
|
||||||
filterQuality: FilterQuality.none,
|
filterQuality: FilterQuality.none,
|
||||||
@@ -196,7 +196,6 @@ class AstromicImage extends StatelessWidget {
|
|||||||
colorBlendMode: blendMode ?? (isSVG ? BlendMode.srcATop : null),
|
colorBlendMode: blendMode ?? (isSVG ? BlendMode.srcATop : null),
|
||||||
//
|
//
|
||||||
errorBuilder: (BuildContext context, Object error, StackTrace? stackTrace) {
|
errorBuilder: (BuildContext context, Object error, StackTrace? stackTrace) {
|
||||||
debugPrint('AstromicImage Error: $error');
|
|
||||||
return errorWidget != null
|
return errorWidget != null
|
||||||
? errorWidget!(error, stackTrace)
|
? errorWidget!(error, stackTrace)
|
||||||
: assetFallback != null
|
: assetFallback != null
|
||||||
@@ -206,7 +205,7 @@ class AstromicImage extends StatelessWidget {
|
|||||||
//
|
//
|
||||||
progressIndicatorBuilder: (_, ImageChunkEvent? bytes) => SizedBox(
|
progressIndicatorBuilder: (_, ImageChunkEvent? bytes) => SizedBox(
|
||||||
width: size.width,
|
width: size.width,
|
||||||
height: size.height,
|
height: size.height == double.infinity? null : size.height,
|
||||||
child: loadingWidget != null ? loadingWidget!(bytes?.cumulativeBytesLoaded, bytes?.expectedTotalBytes) : defaultLoadingWidget,
|
child: loadingWidget != null ? loadingWidget!(bytes?.cumulativeBytesLoaded, bytes?.expectedTotalBytes) : defaultLoadingWidget,
|
||||||
),
|
),
|
||||||
// placeholderBuilder: (BuildContext context) => loadingWidget != null ? loadingWidget!(null, null) : defaultLoadingWidget,
|
// placeholderBuilder: (BuildContext context) => loadingWidget != null ? loadingWidget!(null, null) : defaultLoadingWidget,
|
||||||
@@ -214,7 +213,7 @@ class AstromicImage extends StatelessWidget {
|
|||||||
fadeInDuration: fadeInDuration,
|
fadeInDuration: fadeInDuration,
|
||||||
imageBuilder: (BuildContext context, Widget image) => Container(
|
imageBuilder: (BuildContext context, Widget image) => Container(
|
||||||
width: size.width,
|
width: size.width,
|
||||||
height: size.height,
|
height: size.height == double.infinity? null : size.height,
|
||||||
padding: borderPadding ?? EdgeInsets.zero,
|
padding: borderPadding ?? EdgeInsets.zero,
|
||||||
margin: EdgeInsets.zero,
|
margin: EdgeInsets.zero,
|
||||||
decoration: BoxDecoration(
|
decoration: BoxDecoration(
|
||||||
@@ -224,15 +223,15 @@ class AstromicImage extends StatelessWidget {
|
|||||||
color: borderColor ?? const Color(0xff000000),
|
color: borderColor ?? const Color(0xff000000),
|
||||||
)
|
)
|
||||||
: null,
|
: null,
|
||||||
borderRadius: isCircular! ? BorderRadius.circular(10000000) : radius,
|
borderRadius: isCircular ? BorderRadius.circular(10000000) : radius,
|
||||||
boxShadow: shadow,
|
boxShadow: shadow,
|
||||||
),
|
),
|
||||||
child: isCircular!
|
child: isCircular
|
||||||
? ClipOval(
|
? ClipOval(
|
||||||
child: isSVG ? finalSVGWidget(size, loadingWidget != null ? loadingWidget!(null, null) : defaultLoadingWidget) : image,
|
child: isSVG ? finalSVGWidget(size, loadingWidget != null ? loadingWidget!(null, null) : defaultLoadingWidget) : image,
|
||||||
)
|
)
|
||||||
: ClipRRect(
|
: ClipRRect(
|
||||||
borderRadius: isCircular! ? BorderRadius.circular(10000000) : radius!,
|
borderRadius: isCircular ? BorderRadius.circular(10000000) : radius!,
|
||||||
child: isSVG ? finalSVGWidget(size, loadingWidget != null ? loadingWidget!(null, null) : defaultLoadingWidget) : image,
|
child: isSVG ? finalSVGWidget(size, loadingWidget != null ? loadingWidget!(null, null) : defaultLoadingWidget) : image,
|
||||||
),
|
),
|
||||||
),
|
),
|
||||||
|
|||||||
@@ -61,7 +61,7 @@ class AstromicWidgets {
|
|||||||
|
|
||||||
/// Used when the height is Master and want to set fixed height OR if width is Master and want to constraint the height
|
/// Used when the height is Master and want to set fixed height OR if width is Master and want to constraint the height
|
||||||
fixedHeight: fixedHeight,
|
fixedHeight: fixedHeight,
|
||||||
isCircular: isCircular,
|
isCircular: isCircular ?? false,
|
||||||
borderWidth: borderWidth,
|
borderWidth: borderWidth,
|
||||||
borderColor: borderColor,
|
borderColor: borderColor,
|
||||||
borderPadding: borderPadding,
|
borderPadding: borderPadding,
|
||||||
|
|||||||
Reference in New Issue
Block a user