packages upgrade
This commit is contained in:
parent
5b7caa7caf
commit
194845fa56
12 changed files with 93 additions and 85 deletions
|
@ -156,12 +156,12 @@ dependencies {
|
|||
implementation 'androidx.multidex:multidex:2.0.1'
|
||||
implementation 'com.caverock:androidsvg-aar:1.4'
|
||||
implementation 'com.commonsware.cwac:document:0.4.1'
|
||||
implementation 'com.drewnoakes:metadata-extractor:2.17.0'
|
||||
implementation 'com.drewnoakes:metadata-extractor:2.18.0'
|
||||
// forked, built by JitPack, cf https://jitpack.io/p/deckerst/Android-TiffBitmapFactory
|
||||
implementation 'com.github.deckerst:Android-TiffBitmapFactory:876e53870a'
|
||||
// forked, built by JitPack, cf https://jitpack.io/p/deckerst/pixymeta-android
|
||||
implementation 'com.github.deckerst:pixymeta-android:706bd73d6e'
|
||||
implementation 'com.github.bumptech.glide:glide:4.13.1'
|
||||
implementation 'com.github.bumptech.glide:glide:4.13.2'
|
||||
implementation 'com.huawei.agconnect:agconnect-core:1.5.2.300'
|
||||
|
||||
kapt 'androidx.annotation:annotation:1.3.0'
|
||||
|
|
|
@ -35,6 +35,15 @@
|
|||
<intent>
|
||||
<action android:name="android.intent.action.MAIN" />
|
||||
</intent>
|
||||
<!--
|
||||
from Android R, `url_launcher` method `canLaunchUrl()` will return false,
|
||||
if appropriate intents are not declared, cf https://pub.dev/packages/url_launcher#configuration=
|
||||
-->
|
||||
<!-- to open https URLs -->
|
||||
<intent>
|
||||
<action android:name="android.intent.action.VIEW" />
|
||||
<data android:scheme="https" />
|
||||
</intent>
|
||||
</queries>
|
||||
|
||||
<application
|
||||
|
|
|
@ -79,7 +79,7 @@ class _AppReferenceState extends State<AppReference> {
|
|||
size: 24,
|
||||
),
|
||||
text: l10n.aboutLinkSources,
|
||||
url: Constants.avesGithub,
|
||||
urlString: Constants.avesGithub,
|
||||
),
|
||||
LinkChip(
|
||||
leading: const Icon(
|
||||
|
@ -87,7 +87,7 @@ class _AppReferenceState extends State<AppReference> {
|
|||
size: 22,
|
||||
),
|
||||
text: l10n.aboutLinkLicense,
|
||||
url: '${Constants.avesGithub}/blob/main/LICENSE',
|
||||
urlString: '${Constants.avesGithub}/blob/main/LICENSE',
|
||||
),
|
||||
LinkChip(
|
||||
leading: const Icon(
|
||||
|
|
|
@ -36,6 +36,8 @@ class _BugReportState extends State<BugReport> with FeedbackMixin {
|
|||
late Future<String> _infoLoader;
|
||||
bool _showInstructions = false;
|
||||
|
||||
static final bugReportUri = Uri.parse('${Constants.avesGithub}/issues/new?labels=type%3Abug&template=bug_report.md');
|
||||
|
||||
@override
|
||||
void initState() {
|
||||
super.initState();
|
||||
|
@ -198,6 +200,8 @@ class _BugReportState extends State<BugReport> with FeedbackMixin {
|
|||
}
|
||||
|
||||
Future<void> _goToGithub() async {
|
||||
await launch('${Constants.avesGithub}/issues/new?labels=type%3Abug&template=bug_report.md');
|
||||
if (await canLaunchUrl(bugReportUri)) {
|
||||
await launchUrl(bugReportUri, mode: LaunchMode.externalApplication);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -40,7 +40,7 @@ class AboutCredits extends StatelessWidget {
|
|||
const WidgetSpan(
|
||||
child: LinkChip(
|
||||
text: 'World Atlas',
|
||||
url: 'https://github.com/topojson/world-atlas',
|
||||
urlString: 'https://github.com/topojson/world-atlas',
|
||||
textStyle: TextStyle(fontWeight: FontWeight.bold),
|
||||
),
|
||||
alignment: PlaceholderAlignment.middle,
|
||||
|
|
|
@ -138,14 +138,14 @@ class LicenseRow extends StatelessWidget {
|
|||
children: [
|
||||
LinkChip(
|
||||
text: package.name,
|
||||
url: package.sourceUrl,
|
||||
urlString: package.sourceUrl,
|
||||
textStyle: const TextStyle(fontWeight: FontWeight.bold),
|
||||
),
|
||||
Padding(
|
||||
padding: const EdgeInsetsDirectional.only(start: 16),
|
||||
child: LinkChip(
|
||||
text: package.license,
|
||||
url: package.licenseUrl,
|
||||
urlString: package.licenseUrl,
|
||||
color: subColor,
|
||||
),
|
||||
),
|
||||
|
|
|
@ -5,7 +5,7 @@ import 'package:url_launcher/url_launcher.dart';
|
|||
class LinkChip extends StatelessWidget {
|
||||
final Widget? leading;
|
||||
final String text;
|
||||
final String? url;
|
||||
final String? urlString;
|
||||
final Color? color;
|
||||
final TextStyle? textStyle;
|
||||
final VoidCallback? onTap;
|
||||
|
@ -16,7 +16,7 @@ class LinkChip extends StatelessWidget {
|
|||
Key? key,
|
||||
this.leading,
|
||||
required this.text,
|
||||
this.url,
|
||||
this.urlString,
|
||||
this.color,
|
||||
this.textStyle,
|
||||
this.onTap,
|
||||
|
@ -24,15 +24,18 @@ class LinkChip extends StatelessWidget {
|
|||
|
||||
@override
|
||||
Widget build(BuildContext context) {
|
||||
final _url = url;
|
||||
final _urlString = urlString;
|
||||
return DefaultTextStyle.merge(
|
||||
style: (textStyle ?? const TextStyle()).copyWith(color: color),
|
||||
child: InkWell(
|
||||
borderRadius: borderRadius,
|
||||
onTap: onTap ??
|
||||
() async {
|
||||
if (_url != null && await canLaunch(_url)) {
|
||||
await launch(_url);
|
||||
if (_urlString != null) {
|
||||
final url = Uri.parse(_urlString);
|
||||
if (await canLaunchUrl(url)) {
|
||||
await launchUrl(url, mode: LaunchMode.externalApplication);
|
||||
}
|
||||
}
|
||||
},
|
||||
child: Padding(
|
||||
|
|
|
@ -44,8 +44,11 @@ class MarkdownContainer extends StatelessWidget {
|
|||
data: data,
|
||||
selectable: true,
|
||||
onTapLink: (text, href, title) async {
|
||||
if (href != null && await canLaunch(href)) {
|
||||
await launch(href);
|
||||
if (href != null) {
|
||||
final url = Uri.parse(href);
|
||||
if (await canLaunchUrl(url)) {
|
||||
await launchUrl(url, mode: LaunchMode.externalApplication);
|
||||
}
|
||||
}
|
||||
},
|
||||
shrinkWrap: true,
|
||||
|
|
|
@ -38,8 +38,11 @@ class Attribution extends StatelessWidget {
|
|||
p: theme.textTheme.caption!.merge(const TextStyle(fontSize: InfoRowGroup.fontSize)),
|
||||
),
|
||||
onTapLink: (text, href, title) async {
|
||||
if (href != null && await canLaunch(href)) {
|
||||
await launch(href);
|
||||
if (href != null) {
|
||||
final url = Uri.parse(href);
|
||||
if (await canLaunchUrl(url)) {
|
||||
await launchUrl(url, mode: LaunchMode.externalApplication);
|
||||
}
|
||||
}
|
||||
},
|
||||
),
|
||||
|
|
|
@ -72,35 +72,27 @@ class FilterTable<T extends Comparable> extends StatelessWidget {
|
|||
),
|
||||
),
|
||||
if (showPercentIndicator)
|
||||
// as of percent_indicator v4.0.0, bar radius is not correctly applied to progress bar
|
||||
// when width is lower than height, so we clip it and handle padding outside
|
||||
Padding(
|
||||
padding: EdgeInsets.symmetric(horizontal: lineHeight),
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.all(barRadius),
|
||||
child: FutureBuilder<Color>(
|
||||
future: filter.color(context),
|
||||
builder: (context, snapshot) {
|
||||
final color = snapshot.data;
|
||||
return LinearPercentIndicator(
|
||||
percent: percent,
|
||||
lineHeight: lineHeight,
|
||||
backgroundColor: theme.colorScheme.onPrimary.withOpacity(.1),
|
||||
progressColor: isMonochrome ? theme.colorScheme.secondary : color,
|
||||
animation: true,
|
||||
isRTL: isRtl,
|
||||
barRadius: barRadius,
|
||||
center: Text(
|
||||
intl.NumberFormat.percentPattern().format(percent),
|
||||
style: TextStyle(
|
||||
shadows: theme.brightness == Brightness.dark ? Constants.embossShadows : null,
|
||||
),
|
||||
),
|
||||
padding: EdgeInsets.zero,
|
||||
);
|
||||
},
|
||||
),
|
||||
),
|
||||
FutureBuilder<Color>(
|
||||
future: filter.color(context),
|
||||
builder: (context, snapshot) {
|
||||
final color = snapshot.data;
|
||||
return LinearPercentIndicator(
|
||||
percent: percent,
|
||||
lineHeight: lineHeight,
|
||||
backgroundColor: theme.colorScheme.onPrimary.withOpacity(.1),
|
||||
progressColor: isMonochrome ? theme.colorScheme.secondary : color,
|
||||
animation: true,
|
||||
isRTL: isRtl,
|
||||
barRadius: barRadius,
|
||||
center: Text(
|
||||
intl.NumberFormat.percentPattern().format(percent),
|
||||
style: TextStyle(
|
||||
shadows: theme.brightness == Brightness.dark ? Constants.embossShadows : null,
|
||||
),
|
||||
),
|
||||
padding: EdgeInsets.symmetric(horizontal: lineHeight),
|
||||
);
|
||||
},
|
||||
),
|
||||
Text(
|
||||
'$count',
|
||||
|
|
|
@ -110,36 +110,30 @@ class StatsPage extends StatelessWidget {
|
|||
padding: const EdgeInsets.all(16),
|
||||
child: Column(
|
||||
children: [
|
||||
// as of percent_indicator v4.0.0, bar radius is not correctly applied to progress bar
|
||||
// when width is lower than height, so we clip it and handle padding outside
|
||||
Row(
|
||||
mainAxisSize: MainAxisSize.min,
|
||||
children: [
|
||||
const Icon(AIcons.location),
|
||||
SizedBox(width: lineHeight),
|
||||
Expanded(
|
||||
child: ClipRRect(
|
||||
borderRadius: BorderRadius.all(barRadius),
|
||||
child: LinearPercentIndicator(
|
||||
percent: withGpsPercent,
|
||||
lineHeight: lineHeight,
|
||||
backgroundColor: theme.colorScheme.onPrimary.withOpacity(.1),
|
||||
progressColor: theme.colorScheme.secondary,
|
||||
animation: animate,
|
||||
isRTL: context.isRtl,
|
||||
barRadius: barRadius,
|
||||
center: Text(
|
||||
intl.NumberFormat.percentPattern().format(withGpsPercent),
|
||||
style: TextStyle(
|
||||
shadows: isDark ? Constants.embossShadows : null,
|
||||
),
|
||||
child: LinearPercentIndicator(
|
||||
percent: withGpsPercent,
|
||||
lineHeight: lineHeight,
|
||||
backgroundColor: theme.colorScheme.onPrimary.withOpacity(.1),
|
||||
progressColor: theme.colorScheme.secondary,
|
||||
animation: animate,
|
||||
isRTL: context.isRtl,
|
||||
barRadius: barRadius,
|
||||
center: Text(
|
||||
intl.NumberFormat.percentPattern().format(withGpsPercent),
|
||||
style: TextStyle(
|
||||
shadows: isDark ? Constants.embossShadows : null,
|
||||
),
|
||||
padding: EdgeInsets.zero,
|
||||
),
|
||||
padding: EdgeInsets.symmetric(horizontal: lineHeight),
|
||||
),
|
||||
),
|
||||
// end padding to match leading, so that inside label is aligned with outside label below
|
||||
SizedBox(width: lineHeight + 24),
|
||||
const SizedBox(width: 24),
|
||||
],
|
||||
),
|
||||
const SizedBox(height: 8),
|
||||
|
|
38
pubspec.lock
38
pubspec.lock
|
@ -326,42 +326,42 @@ packages:
|
|||
name: firebase_core
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.15.0"
|
||||
version: "1.16.0"
|
||||
firebase_core_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: firebase_core_platform_interface
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "4.2.5"
|
||||
version: "4.3.0"
|
||||
firebase_core_web:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: firebase_core_web
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.6.2"
|
||||
version: "1.6.3"
|
||||
firebase_crashlytics:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: firebase_crashlytics
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.6.3"
|
||||
version: "2.7.2"
|
||||
firebase_crashlytics_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: firebase_crashlytics_platform_interface
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "3.2.4"
|
||||
version: "3.2.5"
|
||||
flex_color_picker:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: flex_color_picker
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.4.0"
|
||||
version: "2.5.0"
|
||||
fluster:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
|
@ -489,7 +489,7 @@ packages:
|
|||
name: google_maps_flutter
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.1.3"
|
||||
version: "2.1.4"
|
||||
google_maps_flutter_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -629,7 +629,7 @@ packages:
|
|||
name: mime
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.0.1"
|
||||
version: "1.0.2"
|
||||
motion_sensors:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -776,7 +776,7 @@ packages:
|
|||
name: percent_indicator
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "4.0.0"
|
||||
version: "4.0.1"
|
||||
permission_handler:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
|
@ -895,35 +895,35 @@ packages:
|
|||
name: quiver
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "3.0.1+1"
|
||||
version: "3.1.0"
|
||||
screen_brightness:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
name: screen_brightness
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.1.4"
|
||||
version: "0.2.0"
|
||||
screen_brightness_android:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: screen_brightness_android
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.0.4"
|
||||
version: "0.1.0"
|
||||
screen_brightness_ios:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: screen_brightness_ios
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.0.5"
|
||||
version: "0.1.0"
|
||||
screen_brightness_platform_interface:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: screen_brightness_platform_interface
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "0.0.4"
|
||||
version: "0.1.0"
|
||||
shared_preferences:
|
||||
dependency: "direct main"
|
||||
description:
|
||||
|
@ -1161,14 +1161,14 @@ packages:
|
|||
name: url_launcher
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "6.0.20"
|
||||
version: "6.1.0"
|
||||
url_launcher_android:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: url_launcher_android
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "6.0.15"
|
||||
version: "6.0.16"
|
||||
url_launcher_ios:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -1238,7 +1238,7 @@ packages:
|
|||
name: web_socket_channel
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.1.0"
|
||||
version: "2.2.0"
|
||||
webdriver:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
@ -1252,14 +1252,14 @@ packages:
|
|||
name: webkit_inspection_protocol
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "1.0.0"
|
||||
version: "1.0.1"
|
||||
win32:
|
||||
dependency: transitive
|
||||
description:
|
||||
name: win32
|
||||
url: "https://pub.dartlang.org"
|
||||
source: hosted
|
||||
version: "2.5.1"
|
||||
version: "2.5.2"
|
||||
wkt_parser:
|
||||
dependency: transitive
|
||||
description:
|
||||
|
|
Loading…
Reference in a new issue