getContainerData method

Widget getContainerData()

Defines child widget of a container

Implementation

Widget getContainerData() {
  List<Widget> rowChildren = <Widget>[
    getIcon(),
    (iconWidget != null && text != null)
        ? const SizedBox(
            width: 4,
          )
        : const SizedBox.shrink(),
    getText(),
    (suffixIconWidget != null && text != null)
        ? const SizedBox(
            width: 4,
          )
        : const SizedBox.shrink(),
    getSuffixIcon(),
  ];

  return FittedBox(
    fit: BoxFit.scaleDown,
    child: Row(
      mainAxisAlignment: MainAxisAlignment.center,
      children: rowChildren,
    ),
  );
}