mirror of
https://github.com/KRTirtho/spotube.git
synced 2025-09-12 23:45:18 +00:00

* fix: certificate error by using custom ssl certificate * Cd/docker linux ar (#1468) * cd: use docker buildx * cd: use linux host for linux arm instead of macos m1 m1 doesn't support nested virtualization. (Apple truly sucks) * cd: don't specify arch in Dockerfile * cd: use custom Dockerfile from ubuntu instead of flutter image * cd: add setup java for android * cd: add flutter distributor pre-built docker image for arm * cd: save me from this cursed arm build * cd: ?? * cd: ?? * cd: use docker build * fix: windows SSL Exception for Signing in * refactor: extract update checker as a basic function instead of a hook
47 lines
1.3 KiB
Dart
47 lines
1.3 KiB
Dart
import 'package:flutter/material.dart';
|
|
import 'package:spotube/components/shared/links/anchor_button.dart';
|
|
import 'package:url_launcher/url_launcher_string.dart';
|
|
import 'package:version/version.dart';
|
|
|
|
class RootAppUpdateDialog extends StatelessWidget {
|
|
final Version? version;
|
|
const RootAppUpdateDialog({super.key, this.version});
|
|
|
|
@override
|
|
Widget build(BuildContext context) {
|
|
const url = "https://spotube.krtirtho.dev/downloads";
|
|
return AlertDialog(
|
|
title: const Text("Spotube has an update"),
|
|
actions: [
|
|
FilledButton(
|
|
child: const Text("Download Now"),
|
|
onPressed: () => launchUrlString(
|
|
url,
|
|
mode: LaunchMode.externalApplication,
|
|
),
|
|
),
|
|
],
|
|
content: Column(
|
|
mainAxisSize: MainAxisSize.min,
|
|
children: [
|
|
Text("Spotube v$version has been released"),
|
|
Row(
|
|
mainAxisAlignment: MainAxisAlignment.center,
|
|
children: [
|
|
const Text("Read the latest "),
|
|
AnchorButton(
|
|
"release notes",
|
|
style: const TextStyle(color: Colors.blue),
|
|
onTap: () => launchUrlString(
|
|
url,
|
|
mode: LaunchMode.externalApplication,
|
|
),
|
|
),
|
|
],
|
|
),
|
|
],
|
|
),
|
|
);
|
|
}
|
|
}
|