diff --git a/assets/bundled/federated_nexus.svg b/assets/bundled/federated_nexus.svg
new file mode 100644
index 0000000..0effd9a
--- /dev/null
+++ b/assets/bundled/federated_nexus.svg
@@ -0,0 +1,150 @@
+
+
+
+
diff --git a/assets/bundled/matrix.svg b/assets/bundled/matrix.svg
new file mode 100644
index 0000000..bfe705e
--- /dev/null
+++ b/assets/bundled/matrix.svg
@@ -0,0 +1,11 @@
+
diff --git a/lib/models/homeserver.dart b/lib/models/homeserver.dart
index 5504941..ca1a271 100644
--- a/lib/models/homeserver.dart
+++ b/lib/models/homeserver.dart
@@ -1,4 +1,5 @@
import "package:freezed_annotation/freezed_annotation.dart";
+import "package:material_ui/material_ui.dart";
part "homeserver.freezed.dart";
@@ -7,5 +8,5 @@ class const Homeserver({
required final String name,
required final String description,
required final Uri url,
- required final String iconUrl,
+ required final Widget icon,
}) with _$Homeserver;
diff --git a/lib/widgets/pages/select_server.dart b/lib/widgets/pages/select_server.dart
index 2bcbca7..a3102e6 100644
--- a/lib/widgets/pages/select_server.dart
+++ b/lib/widgets/pages/select_server.dart
@@ -190,31 +190,34 @@ class const SelectServerPage({super.key}) extends HookConsumerWidget {
name: "Matrix.org",
description: "The Matrix.org Foundation offers the matrix.org homeserver as an easy entry point for anyone wanting to try out Matrix.",
url: .https("matrix.org"),
- iconUrl:
- "https://raw.githubusercontent.com/element-hq/logos/refs/heads/master/matrix/matrix-favicon${Theme.brightnessOf(context) == Brightness.dark ? "-white" : ""}.png",
+ icon: SvgPicture.asset(
+ "assets/bundled/matrix.svg",
+ colorFilter: .mode(theme.colorScheme.onSurface, .srcIn),
+ ),
),
.new(
name: "Federated Nexus",
description: "Federated Nexus is a community resource hosting multiple FOSS (especially federated) services, including Matrix and Forgejo. By the same developers who made Nexus client.",
url: .https("federated.nexus"),
- iconUrl: "https://federated.nexus/images/icon.png",
+ icon: SvgPicture.asset(
+ "assets/bundled/federated_nexus.svg",
+ ),
),
// TODO: Add back unredacted when they have MAS, find where new favicon is
// .new(
// name: "Unredacted",
// description: "Unredacted is a 501(c)(3) non-profit organization that builds Internet infrastructure and services to help people evade censorship and protect their right to privacy.",
// url: .https("unredacted.org", "services/si/matrix"),
- // iconUrl: "https://unredacted.org/favicon.ico",
+ // icon: Image.network("https://unredacted.org/favicon.ico"),
// ),
].map(
(homeserver) => Card(
child: ListTile(
enabled: !isLoading.value,
title: Text(homeserver.name),
- leading: Image.network(
- homeserver.iconUrl,
- errorBuilder: (_, _, _) => SizedBox.shrink(),
- height: 32,
+ leading: SizedBox.square(
+ dimension: 32,
+ child: homeserver.icon,
),
subtitle: Text(homeserver.description),
onTap: isLoading.value