mirror of
https://github.com/gabehf/Fladder.git
synced 2026-03-14 01:37:07 -07:00
fix: Improved logic horizontal list navigation
This commit is contained in:
parent
b4e68c9e15
commit
47128eb3b6
4 changed files with 40 additions and 15 deletions
|
|
@ -10,6 +10,7 @@ import 'package:fladder/util/adaptive_layout/adaptive_layout.dart';
|
|||
import 'package:fladder/util/localization_helper.dart';
|
||||
import 'package:fladder/util/sticky_header_text.dart';
|
||||
import 'package:fladder/util/string_extensions.dart';
|
||||
import 'package:fladder/widgets/shared/ensure_visible.dart';
|
||||
|
||||
class NextUpEpisode extends ConsumerWidget {
|
||||
final EpisodeModel nextEpisode;
|
||||
|
|
@ -49,6 +50,11 @@ class NextUpEpisode extends ConsumerWidget {
|
|||
showLabel: false,
|
||||
onTap: () => nextEpisode.navigateTo(context),
|
||||
actions: const [],
|
||||
onFocusChanged: (value) {
|
||||
if (value) {
|
||||
context.ensureVisible();
|
||||
}
|
||||
},
|
||||
isCurrentEpisode: false,
|
||||
),
|
||||
const SizedBox(height: 16),
|
||||
|
|
@ -71,6 +77,11 @@ class NextUpEpisode extends ConsumerWidget {
|
|||
showLabel: false,
|
||||
onTap: () => nextEpisode.navigateTo(context),
|
||||
actions: const [],
|
||||
onFocusChanged: (value) {
|
||||
if (value) {
|
||||
context.ensureVisible();
|
||||
}
|
||||
},
|
||||
isCurrentEpisode: false,
|
||||
),
|
||||
),
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue