JsonAssetImage constructor

JsonAssetImage({
  1. Map<String, dynamic> args = const {},
  2. JsonWidgetRegistry? registry,
  3. Alignment alignment = Alignment.center,
  4. int? cacheHeight,
  5. int? cacheWidth,
  6. Rect? centerSlice,
  7. Color? color,
  8. BlendMode? colorBlendMode,
  9. Widget errorBuilder(
    1. BuildContext,
    2. Object,
    3. StackTrace?
    )?,
  10. bool excludeFromSemantics = false,
  11. FilterQuality filterQuality = FilterQuality.low,
  12. BoxFit? fit,
  13. Widget frameBuilder(
    1. BuildContext,
    2. Widget,
    3. int?,
    4. bool,
    )?,
  14. bool gaplessPlayback = false,
  15. double? height,
  16. bool isAntiAlias = false,
  17. bool matchTextDirection = false,
  18. required String name,
  19. double? opacity,
  20. String? package,
  21. ImageRepeat repeat = ImageRepeat.noRepeat,
  22. double? scale,
  23. String? semanticLabel,
  24. double? width,
})

Implementation

JsonAssetImage({
  Map<String, dynamic> args = const {},
  JsonWidgetRegistry? registry,
  this.alignment = Alignment.center,
  this.cacheHeight,
  this.cacheWidth,
  this.centerSlice,
  this.color,
  this.colorBlendMode,
  this.errorBuilder,
  this.excludeFromSemantics = false,
  this.filterQuality = FilterQuality.low,
  this.fit,
  this.frameBuilder,
  this.gaplessPlayback = false,
  this.height,
  this.isAntiAlias = false,
  this.matchTextDirection = false,
  required this.name,
  this.opacity,
  this.package,
  this.repeat = ImageRepeat.noRepeat,
  this.scale,
  this.semanticLabel,
  this.width,
}) : super(
        jsonWidgetArgs: JsonAssetImageBuilderModel.fromDynamic(
          {
            'alignment': alignment,
            'cacheHeight': cacheHeight,
            'cacheWidth': cacheWidth,
            'centerSlice': centerSlice,
            'color': color,
            'colorBlendMode': colorBlendMode,
            'errorBuilder': errorBuilder,
            'excludeFromSemantics': excludeFromSemantics,
            'filterQuality': filterQuality,
            'fit': fit,
            'frameBuilder': frameBuilder,
            'gaplessPlayback': gaplessPlayback,
            'height': height,
            'isAntiAlias': isAntiAlias,
            'matchTextDirection': matchTextDirection,
            'name': name,
            'opacity': opacity,
            'package': package,
            'repeat': repeat,
            'scale': scale,
            'semanticLabel': semanticLabel,
            'width': width,
            ...args,
          },
          args: args,
          registry: registry,
        ),
        jsonWidgetBuilder: () => JsonAssetImageBuilder(
          args: JsonAssetImageBuilderModel.fromDynamic(
            {
              'alignment': alignment,
              'cacheHeight': cacheHeight,
              'cacheWidth': cacheWidth,
              'centerSlice': centerSlice,
              'color': color,
              'colorBlendMode': colorBlendMode,
              'errorBuilder': errorBuilder,
              'excludeFromSemantics': excludeFromSemantics,
              'filterQuality': filterQuality,
              'fit': fit,
              'frameBuilder': frameBuilder,
              'gaplessPlayback': gaplessPlayback,
              'height': height,
              'isAntiAlias': isAntiAlias,
              'matchTextDirection': matchTextDirection,
              'name': name,
              'opacity': opacity,
              'package': package,
              'repeat': repeat,
              'scale': scale,
              'semanticLabel': semanticLabel,
              'width': width,
              ...args,
            },
            args: args,
            registry: registry,
          ),
        ),
        jsonWidgetType: JsonAssetImageBuilder.kType,
      );