returnFlightSection method

Column returnFlightSection(
  1. int arrivalDiff
)

Implementation

Column returnFlightSection(int arrivalDiff) {
  return Column(
    crossAxisAlignment: CrossAxisAlignment.end,
    children: [
      Text(
        arrivalTime,
        style: const TextStyle(
          fontSize: 14,
          fontWeight: FontWeight.w600,
          color: ColorHelper.neutralMediumText,
        ),
      ),
      Text(
        arrivalAirport,
        textAlign: TextAlign.end,
        style: const TextStyle(
          fontSize: 12,
          fontWeight: FontWeight.w400,
          color: ColorHelper.neutralLightText,
        ),
      ),
      if (arrivalDate != null && arrivalDiff > 0)
        Text(
          firstDate == null
              ? departureDate ?? ''
              : '+$arrivalDiff Day, ${DateFormat('dd-MM-yyyy').format(DateTime.parse(arrivalDate!))}',
          style: const TextStyle(
            fontSize: 10,
            fontWeight: FontWeight.w500,
            color: ColorHelper.primaryPurple,
          ),
        ),
    ],
  );
}