fix: improve layout and styling in manga detail view and chapter list tile

This commit is contained in:
Moustapha Kodjo Amadou 2025-11-12 15:23:17 +01:00
parent a8f78d41fb
commit daa205044f
2 changed files with 11 additions and 9 deletions

View file

@ -1936,10 +1936,11 @@ class _MangaDetailViewState extends ConsumerState<MangaDetailView>
return Container(
color: Theme.of(context).scaffoldBackgroundColor,
child: Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children: [
Expanded(child: widget.action!),
if (!isLocalArchive) Expanded(child: _smartUpdateDays()),
if (widget.itemType != ItemType.novel) Expanded(child: _action()),
_action(),
if (!isLocalArchive)
Expanded(
child: SizedBox(
@ -2031,9 +2032,9 @@ class _MangaDetailViewState extends ConsumerState<MangaDetailView>
builder: (context, snapshot) {
List<TrackPreference>? entries = snapshot.hasData ? snapshot.data! : [];
if (entries.isEmpty) {
return Container();
return SizedBox.shrink();
}
return SizedBox(
return Expanded(
child: ElevatedButton(
style: ElevatedButton.styleFrom(
backgroundColor: Theme.of(context).scaffoldBackgroundColor,

View file

@ -38,15 +38,16 @@ class ChapterListTileWidget extends ConsumerWidget {
onLongPress: () => _handleInteraction(ref),
onSecondaryTap: () => _handleInteraction(ref),
child: ListTile(
minLeadingWidth: 3,
minLeadingWidth: 0,
horizontalTitleGap: 13,
leading: Container(
width: 3,
height: 25,
width: 2,
height: 40,
decoration: BoxDecoration(
color: chapter.isRead!
? Colors.grey.withValues(alpha: 0.3)
: context.primaryColor,
borderRadius: BorderRadius.circular(5),
borderRadius: BorderRadius.circular(10),
),
),
tileColor: (chapter.isFiller ?? false)
@ -62,13 +63,13 @@ class ChapterListTileWidget extends ConsumerWidget {
: Colors.white,
onTap: () async => _handleInteraction(ref, context),
title: Row(
crossAxisAlignment: CrossAxisAlignment.end,
crossAxisAlignment: CrossAxisAlignment.start,
children: [
if (chapter.thumbnailUrl != null)
_thumbnailPreview(context, chapter.thumbnailUrl),
chapter.isBookmarked!
? Icon(Icons.bookmark, size: 16, color: context.primaryColor)
: Container(),
: SizedBox.shrink(),
chapter.description != null
? Flexible(
child: Column(