Fixed scrolling issue on some screens

This commit is contained in:
Juan Gilsanz Polo 2023-05-21 14:52:35 +02:00
parent df4564e975
commit 9aa79806a9
2 changed files with 128 additions and 162 deletions

View file

@ -294,15 +294,8 @@ class LogDetailsScreen extends StatelessWidget {
}
else {
return Scaffold(
body: NestedScrollView(
headerSliverBuilder: (context, innerBoxIsScrolled) => [
SliverOverlapAbsorber(
handle: NestedScrollView.sliverOverlapAbsorberHandleFor(context),
sliver: SliverAppBar(
pinned: true,
floating: true,
appBar: AppBar(
centerTitle: false,
forceElevated: innerBoxIsScrolled,
title: Text(AppLocalizations.of(context)!.logDetails),
actions: [
if (serversProvider.filteringStatus != null) IconButton(
@ -319,10 +312,7 @@ class LogDetailsScreen extends StatelessWidget {
const SizedBox(width: 10)
],
),
)
],
body: content(),
),
);
}
}

View file

@ -109,29 +109,10 @@ class _GeneralSettingsState extends State<GeneralSettings> {
}
return Scaffold(
body: NestedScrollView(
headerSliverBuilder: (context, innerBoxIsScrolled) => [
SliverOverlapAbsorber(
handle: NestedScrollView.sliverOverlapAbsorberHandleFor(context),
sliver: SliverAppBar(
pinned: true,
floating: true,
centerTitle: false,
forceElevated: innerBoxIsScrolled,
appBar: AppBar(
title: Text(AppLocalizations.of(context)!.generalSettings),
)
)
],
body: SafeArea(
top: false,
bottom: false,
child: Builder(
builder: (context) => CustomScrollView(
slivers: [
SliverOverlapInjector(
handle: NestedScrollView.sliverOverlapAbsorberHandleFor(context),
),
SliverList.list(
body: ListView(
children: [
SectionLabel(label: AppLocalizations.of(context)!.home),
CustomListTile(
@ -242,11 +223,6 @@ class _GeneralSettingsState extends State<GeneralSettings> {
]
],
)
],
),
)
)
)
);
}
}