change: Sign in button according to apples HIG

This commit is contained in:
Christian Pauly 2021-07-08 18:09:19 +02:00
commit 6b30042184
3 changed files with 69 additions and 41 deletions

View file

@ -149,9 +149,13 @@ class HomeserverPickerController extends State<HomeserverPicker> {
final rawProviders = _rawLoginTypes.tryGetList('flows').singleWhere(
(flow) =>
flow['type'] == AuthenticationTypes.sso)['identity_providers'];
return (rawProviders as List)
final list = (rawProviders as List)
.map((json) => IdentityProvider.fromJson(json))
.toList();
if (!PlatformInfos.isCupertinoStyle) {
list.sort((a, b) => a.brand == 'apple' ? -1 : 1);
}
return list;
}
bool get passwordLoginSupported =>