Browse Source

neon: HomePage externalize body

pull/362/head
Nikolas Rimikis 1 year ago
parent
commit
671107e363
No known key found for this signature in database
GPG Key ID: 85ED1DE9786A4FF2
  1. 31
      packages/neon/neon/lib/src/pages/home.dart

31
packages/neon/neon/lib/src/pages/home.dart

@ -518,18 +518,8 @@ class _HomePageState extends State<HomePage> {
],
);
return Row(
children: [
if (navigationMode == NavigationMode.drawerAlwaysVisible) ...[
drawer,
],
Expanded(
child: Scaffold(
key: _scaffoldKey,
resizeToAvoidBottomInset: false,
drawer: navigationMode == NavigationMode.drawer ? drawer : null,
appBar: appBar,
body: Row(
final body = Builder(
builder: (final context) => Row(
children: [
if (navigationMode == NavigationMode.quickBar) ...[
drawer,
@ -542,8 +532,7 @@ class _HomePageState extends State<HomePage> {
Expanded(
child: Center(
child: Text(
AppLocalizations.of(context)
.errorNoCompatibleNextcloudAppsFound,
AppLocalizations.of(context).errorNoCompatibleNextcloudAppsFound,
textAlign: TextAlign.center,
),
),
@ -563,6 +552,20 @@ class _HomePageState extends State<HomePage> {
),
],
),
);
return Row(
children: [
if (navigationMode == NavigationMode.drawerAlwaysVisible) ...[
drawer,
],
Expanded(
child: Scaffold(
key: _scaffoldKey,
resizeToAvoidBottomInset: false,
drawer: navigationMode == NavigationMode.drawer ? drawer : null,
appBar: appBar,
body: body,
),
),
],

Loading…
Cancel
Save