mirror of
https://gitlab.com/famedly/fluffychat.git
synced 2024-12-29 01:22:37 +01:00
fix: Space settings routing problems
This commit is contained in:
parent
1d92af38cb
commit
c77ea2e325
@ -240,9 +240,9 @@ class ChatDetailsController extends State<ChatDetails> {
|
||||
if ((room.states['im.ponies.room_emotes'] ?? <String, Event>{})
|
||||
.keys
|
||||
.any((String s) => s.isNotEmpty)) {
|
||||
VRouter.of(context).to('/rooms/${room.id}/details/multiple_emotes');
|
||||
VRouter.of(context).to('multiple_emotes');
|
||||
} else {
|
||||
VRouter.of(context).to('/rooms/${room.id}/details/emotes');
|
||||
VRouter.of(context).to('emotes');
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -316,8 +316,8 @@ class ChatDetailsView extends StatelessWidget {
|
||||
foregroundColor: Colors.grey,
|
||||
child: Icon(Icons.edit_attributes_outlined),
|
||||
),
|
||||
onTap: () => VRouter.of(context)
|
||||
.to('/rooms/${room.id}/details/permissions'),
|
||||
onTap: () =>
|
||||
VRouter.of(context).to('permissions'),
|
||||
),
|
||||
Divider(thickness: 1),
|
||||
ListTile(
|
||||
@ -343,8 +343,8 @@ class ChatDetailsView extends StatelessWidget {
|
||||
radius: Avatar.defaultSize / 2,
|
||||
child: Icon(Icons.add_outlined),
|
||||
),
|
||||
onTap: () => VRouter.of(context)
|
||||
.to('/rooms/${room.id}/invite'),
|
||||
onTap: () =>
|
||||
VRouter.of(context).to('invite'),
|
||||
)
|
||||
: Container(),
|
||||
],
|
||||
|
@ -18,11 +18,13 @@ class ChatPermissionsSettingsView extends StatelessWidget {
|
||||
Widget build(BuildContext context) {
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
leading: IconButton(
|
||||
icon: Icon(Icons.close_outlined),
|
||||
onPressed: () =>
|
||||
VRouter.of(context).to('/rooms/${controller.roomId}'),
|
||||
),
|
||||
leading: VRouter.of(context).path.startsWith('/spaces/')
|
||||
? null
|
||||
: IconButton(
|
||||
icon: Icon(Icons.close_outlined),
|
||||
onPressed: () =>
|
||||
VRouter.of(context).to('/rooms/${controller.roomId}'),
|
||||
),
|
||||
title: Text(L10n.of(context).editChatPermissions),
|
||||
),
|
||||
body: MaxWidthBody(
|
||||
|
@ -21,11 +21,13 @@ class InvitationSelectionView extends StatelessWidget {
|
||||
room.name?.isEmpty ?? false ? L10n.of(context).group : room.name;
|
||||
return Scaffold(
|
||||
appBar: AppBar(
|
||||
leading: IconButton(
|
||||
icon: Icon(Icons.close_outlined),
|
||||
onPressed: () =>
|
||||
VRouter.of(context).to('/rooms/${controller.roomId}'),
|
||||
),
|
||||
leading: VRouter.of(context).path.startsWith('/spaces/')
|
||||
? null
|
||||
: IconButton(
|
||||
icon: Icon(Icons.close_outlined),
|
||||
onPressed: () =>
|
||||
VRouter.of(context).to('/rooms/${controller.roomId}'),
|
||||
),
|
||||
titleSpacing: 0,
|
||||
title: DefaultAppBarSearchField(
|
||||
autofocus: true,
|
||||
|
Loading…
Reference in New Issue
Block a user