This commit is contained in:
Ryan Pandya 2023-06-02 01:03:01 -04:00
parent 5dcfd5da8d
commit 4f7d3879a8
2 changed files with 8 additions and 7 deletions

View File

@ -18,7 +18,7 @@ enum CategoryColor {
final String hex;
name() {
return this.toString().split('.').last;
return toString().split('.').last;
}
backgroundColor() {

View File

@ -48,6 +48,7 @@ class _CategoriesPageState extends State<CategoriesPage> {
}
return CategoryRow(category: category);
}
return null;
},
);
}),
@ -79,26 +80,26 @@ class CategoryRow extends StatelessWidget {
children: [
Container(
constraints: BoxConstraints(maxHeight: 80, maxWidth: 70),
color: category?.backgroundColor,
color: category.backgroundColor,
child: SizedBox.expand(
child: Center(
child: Text(
style: TextStyle(
fontWeight: FontWeight.bold,
color: category?.foregroundColor,
color: category.foregroundColor,
fontSize: 18,
),
category!.number.toString())),
category.number.toString())),
),
),
Expanded(
child: Padding(
padding: EdgeInsets.only(left: category!.leftPadding()),
padding: EdgeInsets.only(left: category.leftPadding()),
child: Text(
style: TextStyle(
fontSize: 17,
),
category!.name,
category.name,
),
),
),
@ -110,7 +111,7 @@ class CategoryRow extends StatelessWidget {
fontSize: 13,
color: Colors.white38,
),
"${category?.description}",
"${category.description}",
),
),
),