buildRatesSection method
Implementation
Widget buildRatesSection({
required String title,
required String totalPrice,
TextStyle? titleStyle,
required String totalPassenger,
required List<Widget> details,
}) {
return Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: [
Row(
children: [
Expanded(
flex: 2,
child: Text(
title,
textAlign: TextAlign.left,
style: titleStyle ??
const TextStyle(
fontSize: 14,
fontWeight: FontWeight.w400,
color: ColorHelper.neutralLightText),
),
),
const Expanded(
flex: 2,
child: Row(
mainAxisAlignment: MainAxisAlignment.end,
children: [
Text(
'See Breakdown',
textAlign: TextAlign.right,
style: TextStyle(
fontSize: 11,
fontWeight: FontWeight.w400,
color: ColorHelper.neutralLightText),
),
Icon(
Icons.keyboard_arrow_up_rounded,
color: ColorHelper.neutralLightText,
size: 13,
)
],
),
),
Expanded(
child: Text(
totalPrice,
textAlign: TextAlign.right,
style: const TextStyle(
fontSize: 12,
fontWeight: FontWeight.w500,
color: ColorHelper.neutralMediumText),
),
),
],
),
Column(
crossAxisAlignment: CrossAxisAlignment.start,
children: details,
),
],
);
}