Remove json translations approach, add example for adding language

Signed-off-by: Sahil Kumar <[email protected]>
This commit is contained in:
Sahil Kumar
2021-07-08 16:43:24 +05:30
parent d3e9bdafbd
commit 2691243102
12 changed files with 144 additions and 99 deletions
@@ -104,11 +104,7 @@ extension BuildContextX on BuildContext {
double get textScaleFactor =>
MediaQuery.maybeOf(this)?.textScaleFactor ?? 1.0;
String translate({
required String key,
required String defaultValue,
}) =>
StreamChatLocalizations.of(this)?.translate(key) ?? defaultValue;
StreamChatLocalizations? get translations => StreamChatLocalizations.of(this);
}
/// Extension on [BorderRadius]