YmAppBar constructor

YmAppBar(
  1. String title, {
  2. Color textColor = Colors.black,
  3. List<Color> background = const [const Color(0xFF606FFF), const Color(0xFF3446F2)],
  4. required dynamic onBackClick(),
  5. Widget? rightWidget,
  6. TextAlign textAlign = TextAlign.center,
})

构造方法传入标题栏

Implementation

YmAppBar(
  this.title, {
  this.textColor = Colors.black,
  this.background = const [
    const Color(0xFF606FFF),
    const Color(0xFF3446F2),
  ],
  required this.onBackClick,
  this.rightWidget,
  this.textAlign = TextAlign.center,
});