MorphAnchor constructor

const MorphAnchor({
  1. Key? key,
  2. required bool isOpen,
  3. required VoidCallback onDismiss,
  4. required MorphTargetSpec target,
  5. required WidgetBuilder closedBuilder,
  6. required MorphContentBuilder openBuilder,
  7. Object? tagId,
  8. MorphSurfaceSpec? spec,
  9. ShapeBorder shape = const RoundedRectangleBorder(),
  10. Color? surfaceColor,
  11. double elevation = 0,
  12. Widget? replica,
  13. bool snapshotGhost = false,
  14. MorphMotion? motion,
  15. bool barrierDismissible = true,
  16. double? maxScrimOpacity,
  17. Color? scrimColor,
  18. Color? shadowColor,
  19. String? semanticLabel,
})

Creates a declarative morph driven by isOpen.

Implementation

const MorphAnchor({
  super.key,
  required this.isOpen,
  required this.onDismiss,
  required this.target,
  required this.closedBuilder,
  required this.openBuilder,
  this.tagId,
  this.spec,
  this.shape = const RoundedRectangleBorder(),
  this.surfaceColor,
  this.elevation = 0,
  this.replica,
  this.snapshotGhost = false,
  this.motion,
  this.barrierDismissible = true,
  this.maxScrimOpacity,
  this.scrimColor,
  this.shadowColor,
  this.semanticLabel,
});