From aaf1b2044d67ce9c08c6d34a4e3dd1364efa5efb Mon Sep 17 00:00:00 2001 From: Tatiana Washington <89934624+tsw5@users.noreply.github.com> Date: Fri, 2 Dec 2022 20:50:34 -0500 Subject: [PATCH] Delete home.dart --- app/lib/screens/pages/home.dart | 72 --------------------------------- 1 file changed, 72 deletions(-) delete mode 100644 app/lib/screens/pages/home.dart diff --git a/app/lib/screens/pages/home.dart b/app/lib/screens/pages/home.dart deleted file mode 100644 index 3a9deb0..0000000 --- a/app/lib/screens/pages/home.dart +++ /dev/null @@ -1,72 +0,0 @@ -import 'package:flutter/material.dart'; -import 'package:pohnpeian_language_app/data/catergories.dart'; -import 'package:pohnpeian_language_app/data/user.dart'; -import 'package:pohnpeian_language_app/models/categories.dart'; -import 'package:pohnpeian_language_app/screens/pages/category_page.dart'; -import 'package:pohnpeian_language_app/widget/app_widget.dart'; -import 'package:pohnpeian_language_app/widget/category_detail.dart'; -import 'package:pohnpeian_language_app/widget/category_header_widget.dart'; - -class HomePage extends StatelessWidget { - @override - Widget build(BuildContext context) => Scaffold( - appBar: MyAppBar(username: username), - body: ListView( - physics: BouncingScrollPhysics(), - padding: const EdgeInsets.all(16), - children: [ - SizedBox(height: 8), - buildCategories(), - SizedBox(height: 32), - buildPopular(context), - ], - ), - ); - - Widget buildCategories() => Container( - height: 300, - child: GridView( - primary: false, - gridDelegate: SliverGridDelegateWithFixedCrossAxisCount( - crossAxisCount: 2, - childAspectRatio: 4 / 3, - crossAxisSpacing: 10, - mainAxisSpacing: 10, - ), - children: categories - .map((category) => CategoryHeaderWidget(category: category)) - .toList(), - ), - ); - - Widget buildPopular(BuildContext context) => Column( - children: [ - Container( - alignment: Alignment.centerLeft, - child: Text( - 'Popular', - style: TextStyle(fontSize: 24, fontWeight: FontWeight.bold), - ), - ), - SizedBox(height: 16), - Container( - height: 240, - child: ListView( - physics: BouncingScrollPhysics(), - scrollDirection: Axis.horizontal, - children: categories - .map((category) => CategoryDetailWidget( - category: category, - onSelectedCategory: (category) { - Navigator.of(context).push(MaterialPageRoute( - builder: (context) => - CategoryPage(category: category), - )); - }, - )) - .toList(), - ), - ) - ], - ); -} \ No newline at end of file