diff --git a/lib/components/organism_components/local_profile_component/local_profile_component_widget.dart b/lib/components/organism_components/local_profile_component/local_profile_component_widget.dart index 708d5307..c6cf3123 100644 --- a/lib/components/organism_components/local_profile_component/local_profile_component_widget.dart +++ b/lib/components/organism_components/local_profile_component/local_profile_component_widget.dart @@ -59,9 +59,9 @@ class _LocalProfileComponentWidgetState width: double.infinity, height: 119.0, decoration: BoxDecoration( - color: const Color(0xFF1AAB5F), + color: FlutterFlowTheme.of(context).primary, border: Border.all( - color: const Color(0xFF1AAB5F), + color: FlutterFlowTheme.of(context).primary, ), ), child: Row( diff --git a/lib/components/organism_components/menu_component/menu_component_widget.dart b/lib/components/organism_components/menu_component/menu_component_widget.dart index 96489102..5e04eed6 100644 --- a/lib/components/organism_components/menu_component/menu_component_widget.dart +++ b/lib/components/organism_components/menu_component/menu_component_widget.dart @@ -546,7 +546,9 @@ class _MenuComponentWidgetState extends State { }(); return Padding( - padding: const EdgeInsetsDirectional.only(top: 10), + padding: const EdgeInsetsDirectional.only( + top: 10, + ), child: Builder( builder: (context) { if (widget.style == MenuView.list_grid && diff --git a/lib/pages/home_page/home_page_widget.dart b/lib/pages/home_page/home_page_widget.dart index 81665ba7..c23d7309 100644 --- a/lib/pages/home_page/home_page_widget.dart +++ b/lib/pages/home_page/home_page_widget.dart @@ -96,11 +96,57 @@ class _HomePageWidgetState extends State { : FocusScope.of(context).unfocus(), child: Scaffold( key: scaffoldKey, - backgroundColor: FlutterFlowTheme.of(context).secondaryBackground, + backgroundColor: FlutterFlowTheme.of(context).primaryBackground, // drawer: buildDrawer(context), drawerEnableOpenDragGesture: true, drawerDragStartBehavior: DragStartBehavior.start, drawer: CustomDrawer(model: _model), + appBar: AppBar( + backgroundColor: FlutterFlowTheme.of(context).primary, + automaticallyImplyLeading: false, + leading: FlutterFlowIconButton( + borderRadius: 20.0, + borderWidth: 1.0, + buttonSize: 40.0, + fillColor: FlutterFlowTheme.of(context).primary, + icon: const Icon( + Icons.menu_rounded, + color: Colors.white, + size: 28.0, + ), + onPressed: () async { + scaffoldKey.currentState!.openDrawer(); + }, + ), + title: Row( + mainAxisAlignment: MainAxisAlignment.center, + mainAxisSize: MainAxisSize.min, + children: [ + ClipRRect( + borderRadius: BorderRadius.circular(8.0), + child: Image.asset( + 'assets/images/logo.png', + width: 15.0, + height: 15.0, + fit: BoxFit.cover, + ), + ), + Text( + 'FRE ACCESS', + style: FlutterFlowTheme.of(context).bodyMedium.override( + fontFamily: FlutterFlowTheme.of(context).bodyMediumFamily, + color: FlutterFlowTheme.of(context).info, + letterSpacing: 0.0, + useGoogleFonts: GoogleFonts.asMap().containsKey( + FlutterFlowTheme.of(context).bodyMediumFamily), + ), + ), + ].divide(const SizedBox(width: 8.0)), + ), + actions: const [], + centerTitle: true, + elevation: 0.0, + ), body: buildPage(context), ), ); @@ -126,7 +172,6 @@ class _HomePageWidgetState extends State { verticalDirection: VerticalDirection.down, clipBehavior: Clip.none, children: [ - createHeader(context), createLocal(), createBody(), ], @@ -137,104 +182,21 @@ class _HomePageWidgetState extends State { ); } - Widget createHeader(BuildContext context) { + Widget createBody() { return Container( - width: MediaQuery.of(context).size.width, - height: MediaQuery.of(context).size.height * 0.13, - decoration: const BoxDecoration( - color: Color(0xFF1AAB5F), - ), - child: SafeArea( - child: Row( - mainAxisAlignment: MainAxisAlignment.spaceBetween, - children: [ - FlutterFlowIconButton( - borderRadius: 20.0, - borderWidth: 1.0, - buttonSize: 40.0, - fillColor: FlutterFlowTheme.of(context).primary, - icon: const Icon( - Icons.menu_rounded, - color: Colors.white, - size: 28.0, - ), - onPressed: () async { - scaffoldKey.currentState!.openDrawer(); - }, - ), - Row( - mainAxisAlignment: MainAxisAlignment.center, - children: [ - ClipRRect( - borderRadius: BorderRadius.circular(8.0), - child: Image.asset( - 'assets/images/logo.png', - width: 15.0, - height: 15.0, - fit: BoxFit.cover, - ), - ), - const SizedBox(width: 8.0), - Text( - 'FRE ACCESS', - style: FlutterFlowTheme.of(context).bodyMedium.override( - fontFamily: - FlutterFlowTheme.of(context).bodyMediumFamily, - color: FlutterFlowTheme.of(context).info, - letterSpacing: 0.0, - useGoogleFonts: GoogleFonts.asMap().containsKey( - FlutterFlowTheme.of(context).bodyMediumFamily), - ), - ), - ], - ), - const SizedBox(width: 60.0), - ], + color: FlutterFlowTheme.of(context).primaryBackground, + child: wrapWithModel( + model: _model.menuComponentModel, + updateCallback: () => setState(() {}), + child: const MenuComponentWidget( + expandable: true, + style: MenuView.list_grid, + item: MenuItem.button, ), ), ); } - Wrap createBody() { - return Wrap( - spacing: 0.0, - runSpacing: 0.0, - alignment: WrapAlignment.start, - crossAxisAlignment: WrapCrossAlignment.start, - direction: Axis.horizontal, - runAlignment: WrapAlignment.start, - verticalDirection: VerticalDirection.down, - clipBehavior: Clip.none, - children: [ - wrapWithModel( - model: _model.menuComponentModel, - updateCallback: () => setState(() {}), - child: const MenuComponentWidget( - expandable: true, - style: MenuView.list_grid, - item: MenuItem.button, - ), - ), - // Align( - // alignment: const AlignmentDirectional(0.0, 0.0), - // child: Provider( - // create: (_) => MessageWellNotifier(), - // child: wrapWithModel( - // model: _model.messageWellComponentModel, - // updateCallback: () => setState(() {}), - // child: const MessageWellComponentWidget(), - // ), - // ), - // ), - //footer - const SizedBox( - height: 100, - width: double.infinity, - ) - ], - ); - } - Widget createLocal() { return wrapWithModel( model: _model.localComponentModel,