refactor: Added and applied require_trailing_commas linter rule
This commit is contained in:
parent
adb3f766e5
commit
ec7acc5385
112 changed files with 3466 additions and 2855 deletions
|
|
@ -21,52 +21,54 @@ class HomeserverBottomSheet extends StatelessWidget {
|
|||
appBar: AppBar(
|
||||
title: Text(homeserver.homeserver.baseUrl.host),
|
||||
),
|
||||
body: ListView(children: [
|
||||
if (description != null && description.isNotEmpty)
|
||||
body: ListView(
|
||||
children: [
|
||||
if (description != null && description.isNotEmpty)
|
||||
ListTile(
|
||||
leading: const Icon(Icons.info_outlined),
|
||||
title: Text(description),
|
||||
),
|
||||
if (jurisdiction != null && jurisdiction.isNotEmpty)
|
||||
ListTile(
|
||||
leading: const Icon(Icons.location_city_outlined),
|
||||
title: Text(jurisdiction),
|
||||
),
|
||||
if (homeserverSoftware != null && homeserverSoftware.isNotEmpty)
|
||||
ListTile(
|
||||
leading: const Icon(Icons.domain_outlined),
|
||||
title: Text(homeserverSoftware),
|
||||
),
|
||||
ListTile(
|
||||
leading: const Icon(Icons.info_outlined),
|
||||
title: Text(description),
|
||||
onTap: () =>
|
||||
launchUrlString(homeserver.homeserver.baseUrl.toString()),
|
||||
leading: const Icon(Icons.link_outlined),
|
||||
title: Text(homeserver.homeserver.baseUrl.toString()),
|
||||
),
|
||||
if (jurisdiction != null && jurisdiction.isNotEmpty)
|
||||
ListTile(
|
||||
leading: const Icon(Icons.location_city_outlined),
|
||||
title: Text(jurisdiction),
|
||||
),
|
||||
if (homeserverSoftware != null && homeserverSoftware.isNotEmpty)
|
||||
ListTile(
|
||||
leading: const Icon(Icons.domain_outlined),
|
||||
title: Text(homeserverSoftware),
|
||||
),
|
||||
ListTile(
|
||||
onTap: () =>
|
||||
launchUrlString(homeserver.homeserver.baseUrl.toString()),
|
||||
leading: const Icon(Icons.link_outlined),
|
||||
title: Text(homeserver.homeserver.baseUrl.toString()),
|
||||
),
|
||||
if (registration != null)
|
||||
ListTile(
|
||||
onTap: () => launchUrlString(registration.toString()),
|
||||
leading: const Icon(Icons.person_add_outlined),
|
||||
title: Text(registration.toString()),
|
||||
),
|
||||
if (rules != null)
|
||||
ListTile(
|
||||
onTap: () => launchUrlString(rules.toString()),
|
||||
leading: const Icon(Icons.visibility_outlined),
|
||||
title: Text(rules.toString()),
|
||||
),
|
||||
if (privacy != null)
|
||||
ListTile(
|
||||
onTap: () => launchUrlString(privacy.toString()),
|
||||
leading: const Icon(Icons.shield_outlined),
|
||||
title: Text(privacy.toString()),
|
||||
),
|
||||
if (responseTime != null)
|
||||
ListTile(
|
||||
leading: const Icon(Icons.timer_outlined),
|
||||
title: Text('${responseTime.inMilliseconds}ms'),
|
||||
),
|
||||
]),
|
||||
if (registration != null)
|
||||
ListTile(
|
||||
onTap: () => launchUrlString(registration.toString()),
|
||||
leading: const Icon(Icons.person_add_outlined),
|
||||
title: Text(registration.toString()),
|
||||
),
|
||||
if (rules != null)
|
||||
ListTile(
|
||||
onTap: () => launchUrlString(rules.toString()),
|
||||
leading: const Icon(Icons.visibility_outlined),
|
||||
title: Text(rules.toString()),
|
||||
),
|
||||
if (privacy != null)
|
||||
ListTile(
|
||||
onTap: () => launchUrlString(privacy.toString()),
|
||||
leading: const Icon(Icons.shield_outlined),
|
||||
title: Text(privacy.toString()),
|
||||
),
|
||||
if (responseTime != null)
|
||||
ListTile(
|
||||
leading: const Icon(Icons.timer_outlined),
|
||||
title: Text('${responseTime.inMilliseconds}ms'),
|
||||
),
|
||||
],
|
||||
),
|
||||
);
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue