ExpansionTileCard constructor

const ExpansionTileCard({
  1. Key? key,
  2. Widget? leading,
  3. required Widget title,
  4. Widget? subtitle,
  5. ValueChanged<bool>? onExpansionChanged,
  6. List<Widget> children = const <Widget>[],
  7. Widget? trailing,
  8. BorderRadiusGeometry borderRadius = const BorderRadius.all(Radius.circular(8.0)),
  9. double elevation = 2.0,
  10. double initialElevation = 0.0,
  11. bool initiallyExpanded = false,
  12. EdgeInsetsGeometry initialPadding = EdgeInsets.zero,
  13. EdgeInsetsGeometry finalPadding = const EdgeInsets.only(bottom: 6.0),
  14. EdgeInsetsGeometry? contentPadding,
  15. Color? baseColor,
  16. Color? expandedColor,
  17. Color? expandedTextColor,
  18. Duration duration = const Duration(milliseconds: 200),
  19. Curve elevationCurve = Curves.easeOut,
  20. Curve heightFactorCurve = Curves.easeIn,
  21. Curve turnsCurve = Curves.easeIn,
  22. Curve colorCurve = Curves.easeIn,
  23. Curve paddingCurve = Curves.easeIn,
  24. bool isThreeLine = false,
  25. Color shadowColor = const Color(0xffaaaaaa),
  26. bool animateTrailing = false,
})

Creates a single-line ListTile with a trailing button that expands or collapses the tile to reveal or hide the children. The initiallyExpanded property must be non-null.

Implementation

const ExpansionTileCard({
  super.key,
  this.leading,
  required this.title,
  this.subtitle,
  this.onExpansionChanged,
  this.children = const <Widget>[],
  this.trailing,
  this.borderRadius = const BorderRadius.all(Radius.circular(8.0)),
  this.elevation = 2.0,
  this.initialElevation = 0.0,
  this.initiallyExpanded = false,
  this.initialPadding = EdgeInsets.zero,
  this.finalPadding = const EdgeInsets.only(bottom: 6.0),
  this.contentPadding,
  this.baseColor,
  this.expandedColor,
  this.expandedTextColor,
  this.duration = const Duration(milliseconds: 200),
  this.elevationCurve = Curves.easeOut,
  this.heightFactorCurve = Curves.easeIn,
  this.turnsCurve = Curves.easeIn,
  this.colorCurve = Curves.easeIn,
  this.paddingCurve = Curves.easeIn,
  this.isThreeLine = false,
  this.shadowColor = const Color(0xffaaaaaa),
  this.animateTrailing = false,
});