mirror of
https://github.com/SyncrowIOT/syncrow-app.git
synced 2026-10-24 19:17:55 +00:00
Added appbar actions for all the views
Added appbar leading logo for the menu view
This commit is contained in:
@@ -1,7 +1,6 @@
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_bloc/flutter_bloc.dart';
|
||||
import 'package:syncrow_app/features/app_layout/bloc/nav_cubit.dart';
|
||||
import 'package:syncrow_app/features/app_layout/view/widgets/app_bar_home_dropdown.dart';
|
||||
import 'package:syncrow_app/utils/resource_manager/constants.dart';
|
||||
|
||||
class DefaultAppBar extends StatelessWidget implements PreferredSizeWidget {
|
||||
@@ -20,16 +19,10 @@ class DefaultAppBar extends StatelessWidget implements PreferredSizeWidget {
|
||||
child: AppBar(
|
||||
backgroundColor: Colors.transparent,
|
||||
leadingWidth: 150,
|
||||
leading: const AppBarHomeDropdown(),
|
||||
actions: <Widget>[
|
||||
IconButton(
|
||||
icon: const Icon(
|
||||
Icons.add,
|
||||
size: 35,
|
||||
),
|
||||
onPressed: () {},
|
||||
),
|
||||
],
|
||||
leading: NavCubit.appBarLeading[
|
||||
NavCubit().bottomNavItems[NavCubit.pageIndex].label],
|
||||
actions: NavCubit.appBarActions[
|
||||
NavCubit().bottomNavItems[NavCubit.pageIndex].label],
|
||||
),
|
||||
);
|
||||
},
|
||||
|
||||
@@ -25,7 +25,7 @@ class DefaultNavBar extends StatelessWidget {
|
||||
DevicesCubit().clearCategoriesSelection(context);
|
||||
}
|
||||
},
|
||||
currentIndex: cubit.getPageIndex,
|
||||
currentIndex: NavCubit.pageIndex,
|
||||
selectedItemColor: ColorsManager.primaryColor,
|
||||
selectedLabelStyle: const TextStyle(
|
||||
color: ColorsManager.primaryColor,
|
||||
|
||||
Reference in New Issue
Block a user