Rename class from HomeScreen to Home

This commit is contained in:
Moe Poi ~ 2022-05-14 23:52:16 +07:00
parent abe36050f5
commit ba10a18d8b
2 changed files with 4 additions and 4 deletions
lib
components
screens

View file

@ -29,7 +29,7 @@ class _MenuState extends State<Menu> {
} else if (widget.initialScreen == 1) {
_selectedWidget = const Products();
} else if (widget.initialScreen == 2) {
_selectedWidget = const HomeScreen();
_selectedWidget = const Home();
} else if (widget.initialScreen == 3) {
_selectedWidget = const Cart();
} else if (widget.initialScreen == 4) {
@ -72,7 +72,7 @@ class _MenuState extends State<Menu> {
});
} else if (index == 1) {
html.window.history.pushState(null, '', '/products');
_selectedWidget = const HomeScreen();
_selectedWidget = const Home();
} else if (index == 2) {
_selectedWidget = const Products();
} else if (index == 3) {

View file

@ -7,8 +7,8 @@ import 'package:nekoya_flutter/components/new_arrival_products.dart';
import 'package:nekoya_flutter/components/popular_products.dart';
import 'package:nekoya_flutter/components/search_form.dart';
class HomeScreen extends StatelessWidget {
const HomeScreen({Key? key}) : super(key: key);
class Home extends StatelessWidget {
const Home({Key? key}) : super(key: key);
@override
Widget build(BuildContext context) {