mirror of
https://gitlab.com/famedly/fluffychat.git
synced 2024-11-27 14:59:29 +01:00
style: Minor adjustments for modal bottom sheets
This commit is contained in:
parent
3b6321383e
commit
f24b3ee09b
@ -326,7 +326,7 @@ class ChatView extends StatelessWidget {
|
||||
const EdgeInsets.all(16),
|
||||
),
|
||||
icon: const Icon(
|
||||
Icons.chat_outlined,
|
||||
Icons.forum_outlined,
|
||||
),
|
||||
onPressed:
|
||||
controller.recreateChat,
|
||||
|
@ -185,7 +185,7 @@ class ChatListViewBody extends StatelessWidget {
|
||||
if (controller.isSearchMode)
|
||||
SearchTitle(
|
||||
title: L10n.of(context)!.chats,
|
||||
icon: const Icon(Icons.chat_outlined),
|
||||
icon: const Icon(Icons.forum_outlined),
|
||||
),
|
||||
if (rooms.isEmpty && !controller.isSearchMode)
|
||||
Padding(
|
||||
|
@ -45,13 +45,13 @@ class ChatListView extends StatelessWidget {
|
||||
badgePosition: badgePosition,
|
||||
filter:
|
||||
controller.getRoomFilterByActiveFilter(ActiveFilter.messages),
|
||||
child: const Icon(Icons.chat_outlined),
|
||||
child: const Icon(Icons.forum_outlined),
|
||||
),
|
||||
selectedIcon: UnreadRoomsBadge(
|
||||
badgePosition: badgePosition,
|
||||
filter:
|
||||
controller.getRoomFilterByActiveFilter(ActiveFilter.messages),
|
||||
child: const Icon(Icons.chat),
|
||||
child: const Icon(Icons.forum),
|
||||
),
|
||||
label: L10n.of(context)!.messages,
|
||||
),
|
||||
@ -61,13 +61,13 @@ class ChatListView extends StatelessWidget {
|
||||
badgePosition: badgePosition,
|
||||
filter:
|
||||
controller.getRoomFilterByActiveFilter(ActiveFilter.allChats),
|
||||
child: const Icon(Icons.chat_outlined),
|
||||
child: const Icon(Icons.forum_outlined),
|
||||
),
|
||||
selectedIcon: UnreadRoomsBadge(
|
||||
badgePosition: badgePosition,
|
||||
filter:
|
||||
controller.getRoomFilterByActiveFilter(ActiveFilter.allChats),
|
||||
child: const Icon(Icons.chat),
|
||||
child: const Icon(Icons.forum),
|
||||
),
|
||||
label: L10n.of(context)!.chats,
|
||||
),
|
||||
|
@ -169,7 +169,7 @@ class SettingsView extends StatelessWidget {
|
||||
trailing: const Icon(Icons.chevron_right_outlined),
|
||||
),
|
||||
ListTile(
|
||||
leading: const Icon(Icons.chat_bubble_outline_outlined),
|
||||
leading: const Icon(Icons.forum_outlined),
|
||||
title: Text(L10n.of(context)!.chat),
|
||||
onTap: () => VRouter.of(context).to('/settings/chat'),
|
||||
trailing: const Icon(Icons.chevron_right_outlined),
|
||||
|
@ -33,8 +33,8 @@ class UserBottomSheetView extends StatelessWidget {
|
||||
child: OutlinedButton.icon(
|
||||
onPressed: () => controller
|
||||
.participantAction(UserBottomSheetAction.message),
|
||||
icon: const Icon(Icons.chat_outlined),
|
||||
label: Text(L10n.of(context)!.newChat),
|
||||
icon: const Icon(Icons.forum_outlined),
|
||||
label: Text(L10n.of(context)!.sendAMessage),
|
||||
),
|
||||
),
|
||||
],
|
||||
@ -72,7 +72,7 @@ class UserBottomSheetView extends StatelessWidget {
|
||||
),
|
||||
if (controller.widget.onMention != null)
|
||||
ListTile(
|
||||
trailing: const Icon(Icons.alternate_email_outlined),
|
||||
leading: const Icon(Icons.alternate_email_outlined),
|
||||
title: Text(L10n.of(context)!.mention),
|
||||
onTap: () =>
|
||||
controller.participantAction(UserBottomSheetAction.mention),
|
||||
@ -80,14 +80,14 @@ class UserBottomSheetView extends StatelessWidget {
|
||||
if (user.canChangePowerLevel)
|
||||
ListTile(
|
||||
title: Text(L10n.of(context)!.setPermissionsLevel),
|
||||
trailing: const Icon(Icons.edit_attributes_outlined),
|
||||
leading: const Icon(Icons.edit_attributes_outlined),
|
||||
onTap: () => controller
|
||||
.participantAction(UserBottomSheetAction.permission),
|
||||
),
|
||||
if (user.canKick)
|
||||
ListTile(
|
||||
title: Text(L10n.of(context)!.kickFromChat),
|
||||
trailing: const Icon(Icons.exit_to_app_outlined),
|
||||
leading: const Icon(Icons.exit_to_app_outlined),
|
||||
onTap: () =>
|
||||
controller.participantAction(UserBottomSheetAction.kick),
|
||||
),
|
||||
@ -101,7 +101,7 @@ class UserBottomSheetView extends StatelessWidget {
|
||||
else if (user.canBan && user.membership == Membership.ban)
|
||||
ListTile(
|
||||
title: Text(L10n.of(context)!.unbanFromChat),
|
||||
trailing: const Icon(Icons.warning_outlined),
|
||||
leading: const Icon(Icons.warning_outlined),
|
||||
onTap: () =>
|
||||
controller.participantAction(UserBottomSheetAction.unban),
|
||||
),
|
||||
@ -111,7 +111,7 @@ class UserBottomSheetView extends StatelessWidget {
|
||||
textColor: Theme.of(context).colorScheme.onErrorContainer,
|
||||
iconColor: Theme.of(context).colorScheme.onErrorContainer,
|
||||
title: Text(L10n.of(context)!.ignore),
|
||||
trailing: const Icon(Icons.block),
|
||||
leading: const Icon(Icons.block),
|
||||
onTap: () =>
|
||||
controller.participantAction(UserBottomSheetAction.ignore),
|
||||
),
|
||||
@ -120,7 +120,7 @@ class UserBottomSheetView extends StatelessWidget {
|
||||
textColor: Theme.of(context).colorScheme.error,
|
||||
iconColor: Theme.of(context).colorScheme.error,
|
||||
title: Text(L10n.of(context)!.reportUser),
|
||||
trailing: const Icon(Icons.shield_outlined),
|
||||
leading: const Icon(Icons.shield_outlined),
|
||||
onTap: () =>
|
||||
controller.participantAction(UserBottomSheetAction.report),
|
||||
),
|
||||
|
@ -8,7 +8,7 @@ Future<T?> showAdaptiveBottomSheet<T>({
|
||||
required BuildContext context,
|
||||
required Widget Function(BuildContext) builder,
|
||||
bool isDismissible = true,
|
||||
bool isScrollControlled = false,
|
||||
bool isScrollControlled = true,
|
||||
}) =>
|
||||
showModalBottomSheet(
|
||||
context: context,
|
||||
@ -16,8 +16,8 @@ Future<T?> showAdaptiveBottomSheet<T>({
|
||||
useRootNavigator: !PlatformInfos.isMobile,
|
||||
isDismissible: isDismissible,
|
||||
isScrollControlled: isScrollControlled,
|
||||
constraints: BoxConstraints(
|
||||
maxHeight: MediaQuery.of(context).size.height - 128,
|
||||
constraints: const BoxConstraints(
|
||||
maxHeight: 480,
|
||||
maxWidth: FluffyThemes.columnWidth * 1.5,
|
||||
),
|
||||
clipBehavior: Clip.hardEdge,
|
||||
|
Loading…
Reference in New Issue
Block a user