add JumpToEventController to allow jumping to events from the NotificationsPage when it has been pushed from the NotificationController
This commit is contained in:
parent
c90a1c41b0
commit
1c1f585362
5 changed files with 70 additions and 65 deletions
|
|
@ -16,11 +16,8 @@ import "package:nexus/widgets/room_menu.dart";
|
|||
// Needed for navigation_rail_m3e (#65).
|
||||
import "package:flutter/material.dart" as old_mat;
|
||||
|
||||
class const Sidebar({
|
||||
required final bool isDesktop,
|
||||
required final void Function(String eventId) jumpToEvent,
|
||||
super.key,
|
||||
}) extends HookConsumerWidget {
|
||||
class const Sidebar({required final bool isDesktop, super.key})
|
||||
extends HookConsumerWidget {
|
||||
@override
|
||||
Widget build(BuildContext context, WidgetRef ref) {
|
||||
final selectedSpaceProvider = KeyController.provider(
|
||||
|
|
@ -197,8 +194,7 @@ class const Sidebar({
|
|||
tooltip: "Open notifications",
|
||||
onPressed: () => Navigator.of(context).push(
|
||||
MaterialPageRoute(
|
||||
builder: (_) =>
|
||||
NotificationsPage(jumpToEvent: jumpToEvent),
|
||||
builder: (_) => NotificationsPage(),
|
||||
),
|
||||
),
|
||||
icon: Icon(Icons.notifications),
|
||||
|
|
|
|||
Loading…
Reference in a new issue