diet creation page

This commit is contained in:
Username1548
2024-11-20 15:28:48 +07:00
parent 92c1bb1a91
commit c292f3a767
19 changed files with 1036 additions and 38 deletions

View File

@@ -9,7 +9,7 @@ class CpfcContainer extends StatelessWidget {
final double protein;
final double fat;
final double carbohydrates;
final int roundDigit = 1;
@override
Widget build(BuildContext context) {
final s = S.of(context);
@@ -21,25 +21,25 @@ class CpfcContainer extends StatelessWidget {
children: [
Column(
children: [
Text('$calories', style: TextStyles.textMSemibold.copyWith(color: appTheme.black)),
Text('${calories.toStringAsFixed(roundDigit)}', style: TextStyles.textMSemibold.copyWith(color: appTheme.black)),
Text(s.calories, style: TextStyles.textXSSemibold.copyWith(color: appTheme.black)),
],
),
Column(
children: [
Text('$protein', style: TextStyles.textMSemibold.copyWith(color: appTheme.black)),
Text('${protein.toStringAsFixed(roundDigit)}', style: TextStyles.textMSemibold.copyWith(color: appTheme.black)),
Text(s.proteins, style: TextStyles.textXSSemibold.copyWith(color: appTheme.black)),
],
),
Column(
children: [
Text('$fat', style: TextStyles.textMSemibold.copyWith(color: appTheme.black)),
Text('${fat.toStringAsFixed(roundDigit)}', style: TextStyles.textMSemibold.copyWith(color: appTheme.black)),
Text(s.fats, style: TextStyles.textXSSemibold.copyWith(color: appTheme.black)),
],
),
Column(
children: [
Text('$carbohydrates', style: TextStyles.textMSemibold.copyWith(color: appTheme.black)),
Text('${carbohydrates.toStringAsFixed(roundDigit)}', style: TextStyles.textMSemibold.copyWith(color: appTheme.black)),
Text(s.carbohydrates, style: TextStyles.textXSSemibold.copyWith(color: appTheme.black)),
],
),