@@ -2,7 +2,6 @@ import 'dart:convert';
22
33import 'package:flutter/material.dart' ;
44import 'package:flutter_markdown/flutter_markdown.dart' ;
5- import 'package:gap/gap.dart' ;
65
76import '../data/recipe_data.dart' ;
87import '../data/recipe_repository.dart' ;
@@ -35,7 +34,6 @@ class RecipeResponseView extends StatelessWidget {
3534 // extract the recipe
3635 final json = recipeWithText['recipe' ] as Map <String , dynamic >;
3736 final recipe = Recipe .fromJson (json);
38- children.add (const Gap (16 ));
3937 children.add (Column (
4038 crossAxisAlignment: CrossAxisAlignment .start,
4139 children: [
@@ -46,12 +44,10 @@ class RecipeResponseView extends StatelessWidget {
4644 ));
4745
4846 // add a button to add the recipe to the list
49- children.add (const Gap (16 ));
5047 children.add (OutlinedButton (
5148 onPressed: () => RecipeRepository .addNewRecipe (recipe),
5249 child: const Text ('Add Recipe' ),
5350 ));
54- children.add (const Gap (16 ));
5551 }
5652 } catch (e) {
5753 debugPrint ('Error parsing response: $e ' );
@@ -74,6 +70,7 @@ class RecipeResponseView extends StatelessWidget {
7470
7571 return Column (
7672 crossAxisAlignment: CrossAxisAlignment .start,
73+ spacing: 16 ,
7774 children: children,
7875 );
7976 }
0 commit comments