feat:增加主题色模块
This commit is contained in:
@@ -82,9 +82,14 @@ class _RecipeListState extends State<RecipeList> {
|
||||
_buildSelectCategory(provider),
|
||||
SizedBox(height: 5),
|
||||
Expanded(
|
||||
child: ListView.separated(
|
||||
child: GridView.builder(
|
||||
gridDelegate: const SliverGridDelegateWithFixedCrossAxisCount(
|
||||
crossAxisCount: 2, // 每行2个
|
||||
crossAxisSpacing: 8, // 水平间距
|
||||
mainAxisSpacing: 8, // 垂直间距
|
||||
childAspectRatio: 0.9,
|
||||
),
|
||||
itemCount: provider.recipeSummaryList.length,
|
||||
separatorBuilder: (context, index) => SizedBox(height: 8),
|
||||
itemBuilder: (context, index) {
|
||||
return RecipeCard(recipe: provider.recipeSummaryList[index]);
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user