forked from Nexus/nexus
use gomuks for URL previews
This commit is contained in:
parent
16fdf0c420
commit
eca9d3b411
6 changed files with 18 additions and 69 deletions
|
|
@ -6,7 +6,7 @@ import "package:nexus/helpers/launch_helper.dart";
|
|||
import "package:nexus/helpers/mxc_image.dart";
|
||||
|
||||
class UrlPreview extends ConsumerWidget {
|
||||
final String link;
|
||||
final Uri link;
|
||||
const UrlPreview(this.link, {super.key});
|
||||
|
||||
@override
|
||||
|
|
@ -18,8 +18,7 @@ class UrlPreview extends ConsumerWidget {
|
|||
data: (preview) => preview == null
|
||||
? SizedBox.shrink()
|
||||
: InkWell(
|
||||
onTap: () =>
|
||||
ref.watch(LaunchHelper.provider).launchUrl(.parse(link)),
|
||||
onTap: () => ref.watch(LaunchHelper.provider).launchUrl(link),
|
||||
child: Card(
|
||||
margin: .symmetric(vertical: 4),
|
||||
color: Theme.of(
|
||||
|
|
|
|||
Loading…
Reference in a new issue