lineStructure method

String lineStructure({
  1. required String spaceLeft,
  2. required String spaceCenter,
  3. required String spaceRight,
  4. String primaryText = '',
  5. String? primaryColor = '',
  6. String? secondaryText = '',
  7. String? secondaryColor = '',
})

Builds a line structure with the specified spaces and text, and optional primary and secondary colors.

The spaceLeft, spaceCenter, and spaceRight arguments are strings representing the spaces to add to the left, center, and right of the text, respectively.

The primaryText argument is the primary message to display, and primaryColor is the optional color of the primary message.

The secondaryText argument is the secondary message to display, and secondaryColor is the optional color of the secondary message.

Returns the concatenated string with the specified spaces and text, and optional primary and secondary colors.

Implementation

String lineStructure({
  required String spaceLeft,
  required String spaceCenter,
  required String spaceRight,
  String primaryText = '',
  String? primaryColor = '',
  String? secondaryText = '',
  String? secondaryColor = '',
}) {
  return spaceLeft +
      primaryColor! +
      primaryText +
      LoggerAnsiColors.reset.color +
      spaceCenter +
      secondaryColor! +
      secondaryText! +
      LoggerAnsiColors.reset.color +
      spaceRight;
}