CurtainSideBarConfig constructor Null safety

const CurtainSideBarConfig(
  1. {double width = _kSideBarWidth,
  2. double expandWidth = _kSideBarExpandWidth,
  3. Duration duration = _kSideBarDuration,
  4. Widget headerBuilder(
    1. bool isExpand,
    2. int page
    )?,
  5. Widget footerBuilder(
    1. bool isExpand,
    2. int page
    )?,
  6. Color backgroundColor = Colors.white,
  7. Color actionsBackgroundColor = Colors.white,
  8. Color actionsSelectedBackgroundColor = Colors.green,
  9. double actionsSpacing = 15,
  10. double selectedActionXOffset = 10,
  11. MainAxisAlignment mainAxisAlignment = MainAxisAlignment.end,
  12. CrossAxisAlignment crossAxisAlignment = CrossAxisAlignment.center}
)

Config of the CurtainSideBar.

Implementation

const CurtainSideBarConfig({
  this.width = _kSideBarWidth,
  this.expandWidth = _kSideBarExpandWidth,
  this.duration = _kSideBarDuration,
  this.headerBuilder,
  this.footerBuilder,
  this.backgroundColor = Colors.white,
  this.actionsBackgroundColor = Colors.white,
  this.actionsSelectedBackgroundColor = Colors.green,
  this.actionsSpacing = 15,
  this.selectedActionXOffset = 10,
  this.mainAxisAlignment = MainAxisAlignment.end,
  this.crossAxisAlignment = CrossAxisAlignment.center,
}) : assert(expandWidth > width, 'expandWidth should be greater than width');