fix: cooldown and teams, added correct textfield hint
This commit is contained in:
@@ -184,6 +184,8 @@ class EventChannel extends ChannelModel {
|
|||||||
DateTime? deletedAt,
|
DateTime? deletedAt,
|
||||||
required int memberCount,
|
required int memberCount,
|
||||||
Map<String, Object?>? extraData,
|
Map<String, Object?>? extraData,
|
||||||
|
required int cooldown,
|
||||||
|
String? team,
|
||||||
}) : super(
|
}) : super(
|
||||||
id: id,
|
id: id,
|
||||||
type: type,
|
type: type,
|
||||||
@@ -197,6 +199,8 @@ class EventChannel extends ChannelModel {
|
|||||||
deletedAt: deletedAt,
|
deletedAt: deletedAt,
|
||||||
memberCount: memberCount,
|
memberCount: memberCount,
|
||||||
extraData: extraData ?? {},
|
extraData: extraData ?? {},
|
||||||
|
cooldown: cooldown,
|
||||||
|
team: team,
|
||||||
);
|
);
|
||||||
|
|
||||||
/// Create a new instance from a json
|
/// Create a new instance from a json
|
||||||
|
|||||||
@@ -87,5 +87,7 @@ EventChannel _$EventChannelFromJson(Map<String, dynamic> json) {
|
|||||||
: DateTime.parse(json['deleted_at'] as String),
|
: DateTime.parse(json['deleted_at'] as String),
|
||||||
memberCount: json['member_count'] as int? ?? 0,
|
memberCount: json['member_count'] as int? ?? 0,
|
||||||
extraData: json['extra_data'] as Map<String, dynamic>? ?? {},
|
extraData: json['extra_data'] as Map<String, dynamic>? ?? {},
|
||||||
|
cooldown: json['cooldown'] as int? ?? 0,
|
||||||
|
team: json['team'] as String?,
|
||||||
);
|
);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -100,6 +100,9 @@ abstract class Translations {
|
|||||||
/// The label for write a message in [MessageInput]
|
/// The label for write a message in [MessageInput]
|
||||||
String get writeAMessageLabel;
|
String get writeAMessageLabel;
|
||||||
|
|
||||||
|
/// The label for slow mode enabled in [MessageInput]
|
||||||
|
String get slowModeOnLabel;
|
||||||
|
|
||||||
/// The label for instant commands in [MessageInput]
|
/// The label for instant commands in [MessageInput]
|
||||||
String get instantCommandsLabel;
|
String get instantCommandsLabel;
|
||||||
|
|
||||||
@@ -664,4 +667,7 @@ class DefaultTranslations implements Translations {
|
|||||||
|
|
||||||
@override
|
@override
|
||||||
String get replyToMessageLabel => 'Reply to Message';
|
String get replyToMessageLabel => 'Reply to Message';
|
||||||
|
|
||||||
|
@override
|
||||||
|
String get slowModeOnLabel => 'Slow mode ON';
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -835,6 +835,10 @@ class MessageInputState extends State<MessageInput> {
|
|||||||
if (_attachments.isNotEmpty) {
|
if (_attachments.isNotEmpty) {
|
||||||
return context.translations.addACommentOrSendLabel;
|
return context.translations.addACommentOrSendLabel;
|
||||||
}
|
}
|
||||||
|
if(_timeOut != 0 && _timeOut != null) {
|
||||||
|
return context.translations.slowModeOnLabel;
|
||||||
|
}
|
||||||
|
|
||||||
return context.translations.writeAMessageLabel;
|
return context.translations.writeAMessageLabel;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
@@ -357,4 +357,7 @@ class StreamChatLocalizationsEn extends GlobalStreamChatLocalizations {
|
|||||||
|
|
||||||
@override
|
@override
|
||||||
String get replyToMessageLabel => 'Reply to Message';
|
String get replyToMessageLabel => 'Reply to Message';
|
||||||
|
|
||||||
|
@override
|
||||||
|
String get slowModeOnLabel => 'Slow mode ON';
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -362,4 +362,7 @@ class StreamChatLocalizationsEs extends GlobalStreamChatLocalizations {
|
|||||||
|
|
||||||
@override
|
@override
|
||||||
String get replyToMessageLabel => 'Responder al Mensaje';
|
String get replyToMessageLabel => 'Responder al Mensaje';
|
||||||
|
|
||||||
|
@override
|
||||||
|
String get slowModeOnLabel => 'Modo lento activado';
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -361,4 +361,7 @@ class StreamChatLocalizationsFr extends GlobalStreamChatLocalizations {
|
|||||||
|
|
||||||
@override
|
@override
|
||||||
String get replyToMessageLabel => 'Répondre au Message';
|
String get replyToMessageLabel => 'Répondre au Message';
|
||||||
|
|
||||||
|
@override
|
||||||
|
String get slowModeOnLabel => 'Mode lent activé';
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -356,4 +356,7 @@ class StreamChatLocalizationsHi extends GlobalStreamChatLocalizations {
|
|||||||
|
|
||||||
@override
|
@override
|
||||||
String get replyToMessageLabel => 'संदेश का जवाब';
|
String get replyToMessageLabel => 'संदेश का जवाब';
|
||||||
|
|
||||||
|
@override
|
||||||
|
String get slowModeOnLabel => 'स्लो मोड चालू';
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -358,4 +358,7 @@ Il file è troppo grande per essere caricato. Il limite è di $limitInMB MB.''';
|
|||||||
|
|
||||||
@override
|
@override
|
||||||
String get replyToMessageLabel => 'Rispondi al messaggio';
|
String get replyToMessageLabel => 'Rispondi al messaggio';
|
||||||
|
|
||||||
|
@override
|
||||||
|
String get slowModeOnLabel => 'Modalità lenta attiva';
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user