mirror of
https://github.com/gabehf/Fladder.git
synced 2026-03-15 18:25:59 -07:00
fix: Hide subtitles with empty text (#242)
Co-authored-by: PartyDonut <PartyDonut@users.noreply.github.com>
This commit is contained in:
parent
48b1e4a6fb
commit
3ca3d72b9c
1 changed files with 35 additions and 32 deletions
|
|
@ -209,7 +209,9 @@ class SubtitleText extends ConsumerWidget {
|
||||||
// Ensure the text doesn't go off-screen
|
// Ensure the text doesn't go off-screen
|
||||||
position = position.clamp(0, availableHeight - textHeight);
|
position = position.clamp(0, availableHeight - textHeight);
|
||||||
|
|
||||||
return IgnorePointer(
|
return Visibility(
|
||||||
|
visible: text.isEmpty ? false : true,
|
||||||
|
child: IgnorePointer(
|
||||||
child: Stack(
|
child: Stack(
|
||||||
alignment: Alignment.bottomCenter,
|
alignment: Alignment.bottomCenter,
|
||||||
children: [
|
children: [
|
||||||
|
|
@ -247,6 +249,7 @@ class SubtitleText extends ConsumerWidget {
|
||||||
)
|
)
|
||||||
],
|
],
|
||||||
),
|
),
|
||||||
|
),
|
||||||
);
|
);
|
||||||
},
|
},
|
||||||
),
|
),
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue