scroll to top/bottom

This commit is contained in:
Fabian Freund
2026-03-12 15:14:31 +01:00
parent bf852295c3
commit 585fd7a362
2 changed files with 30 additions and 0 deletions
@@ -353,6 +353,16 @@ final List<ToolbarButtonDefinition> toolbarButtonRegistry = [
.pageUp();
}
},
onLongPress: scope.isPreview
? () {}
: () async {
final tabId = scope.selectedTabId;
if (tabId != null) {
await ref
.read(tabSessionProvider(tabId: tabId).notifier)
.scrollToTop();
}
},
icon: const Icon(MdiIcons.chevronDoubleUp),
);
},
@@ -373,6 +383,16 @@ final List<ToolbarButtonDefinition> toolbarButtonRegistry = [
.pageDown();
}
},
onLongPress: scope.isPreview
? () {}
: () async {
final tabId = scope.selectedTabId;
if (tabId != null) {
await ref
.read(tabSessionProvider(tabId: tabId).notifier)
.scrollToBottom();
}
},
icon: const Icon(MdiIcons.chevronDoubleDown),
);
},