mirror of
https://gitlab.com/famedly/fluffychat.git
synced 2024-12-18 02:42:34 +01:00
feat: Implement hideAllStateEvents
This commit is contained in:
parent
240fcfb788
commit
721c0b2bfa
@ -16,6 +16,7 @@ abstract class AppConfig {
|
||||
static bool renderHtml = false;
|
||||
static bool hideRedactedEvents = false;
|
||||
static bool hideUnknownEvents = false;
|
||||
static const bool hideAllStateEvents = false;
|
||||
static const String inviteLinkPrefix = 'https://matrix.to/#/';
|
||||
static const String pushNotificationsChannelId = 'fluffychat_push';
|
||||
static const String pushNotificationsChannelName = 'FluffyChat push channel';
|
||||
|
@ -3,13 +3,17 @@ import 'package:fluffychat/utils/matrix_locals.dart';
|
||||
import 'package:flutter/material.dart';
|
||||
import 'package:flutter_gen/gen_l10n/l10n.dart';
|
||||
|
||||
import '../../app_config.dart';
|
||||
|
||||
class StateMessage extends StatelessWidget {
|
||||
final Event event;
|
||||
const StateMessage(this.event);
|
||||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
if (event.type == EventTypes.Redaction) return Container();
|
||||
if (event.type == EventTypes.Redaction || AppConfig.hideAllStateEvents) {
|
||||
return Container();
|
||||
}
|
||||
return Padding(
|
||||
padding: const EdgeInsets.only(
|
||||
left: 8.0,
|
||||
|
Loading…
Reference in New Issue
Block a user