Improve UI.

This commit is contained in:
2025-02-15 11:27:33 +08:00
parent 0c7bc78541
commit 562ac9a95b
2 changed files with 4 additions and 6 deletions

View File

@@ -556,10 +556,8 @@ class _ComicDescription extends StatelessWidget {
softWrap: true, softWrap: true,
overflow: TextOverflow.ellipsis, overflow: TextOverflow.ellipsis,
), ),
const SizedBox( const SizedBox(height: 4),
height: 4, if (tags != null && tags!.isNotEmpty)
),
if (tags != null)
Expanded( Expanded(
child: LayoutBuilder(builder: (context, constraints) { child: LayoutBuilder(builder: (context, constraints) {
if (constraints.maxHeight < 22) { if (constraints.maxHeight < 22) {
@@ -624,7 +622,7 @@ class _ComicDescription extends StatelessWidget {
style: const TextStyle( style: const TextStyle(
fontSize: 12.0, fontSize: 12.0,
), ),
maxLines: 1, maxLines: (tags == null || tags!.isEmpty) ? 3 : 2,
overflow: TextOverflow.ellipsis, overflow: TextOverflow.ellipsis,
), ),
], ],

View File

@@ -362,7 +362,7 @@ class _ComicPageState extends LoadingState<ComicPage, ComicDetails>
: FilledButton(onPressed: read, child: Text("Read".tl)), : FilledButton(onPressed: read, child: Text("Read".tl)),
) )
], ],
).paddingHorizontal(16).paddingTop(8), ).paddingHorizontal(16).paddingVertical(8),
if (history != null) if (history != null)
Container( Container(
margin: const EdgeInsets.symmetric(horizontal: 16, vertical: 8), margin: const EdgeInsets.symmetric(horizontal: 16, vertical: 8),