|
|
|
@ -1,9 +1,11 @@
|
|
|
|
|
import 'package:famedlysdk/famedlysdk.dart';
|
|
|
|
|
import 'package:fluffychat/i18n/i18n.dart';
|
|
|
|
|
import 'package:fluffychat/views/sign_up.dart';
|
|
|
|
|
import 'package:flutter/foundation.dart';
|
|
|
|
|
import 'package:flutter/material.dart';
|
|
|
|
|
import 'package:flutter/services.dart';
|
|
|
|
|
import 'package:flutter_localizations/flutter_localizations.dart';
|
|
|
|
|
import 'package:universal_html/prefer_universal/html.dart' as html;
|
|
|
|
|
|
|
|
|
|
import 'components/matrix.dart';
|
|
|
|
|
import 'views/chat_list.dart';
|
|
|
|
@ -61,6 +63,9 @@ class App extends StatelessWidget {
|
|
|
|
|
const Locale('en'), // English
|
|
|
|
|
const Locale('de'), // German
|
|
|
|
|
],
|
|
|
|
|
locale: kIsWeb
|
|
|
|
|
? Locale(html.window.navigator.language.split("-").first)
|
|
|
|
|
: null,
|
|
|
|
|
home: FutureBuilder<LoginState>(
|
|
|
|
|
future: Matrix.of(context).client.onLoginStateChanged.stream.first,
|
|
|
|
|
builder: (context, snapshot) {
|
|
|
|
|