Skip to content

Commit d33e6f6

Browse files
committed
re-arrange More menu
1 parent 621c78b commit d33e6f6

File tree

7 files changed

+75
-83
lines changed

7 files changed

+75
-83
lines changed

lib/Frontend/pages/more.dart

Lines changed: 48 additions & 48 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,3 @@
1-
import 'package:feedback_sentry/feedback_sentry.dart';
21
import 'package:flutter/material.dart';
32
import 'package:flutter/services.dart';
43
import 'package:flutter_riverpod/flutter_riverpod.dart';
@@ -36,33 +35,6 @@ class _MoreState extends ConsumerState<More> {
3635
Widget build(BuildContext context) {
3736
return ListView(
3837
children: [
39-
if (HiveProxy.getOrDefault(settings, showDebugging, defaultValue: showDebuggingDefault)) ...[
40-
ListTile(
41-
title: Text(convertToUwU(joyStickPage())),
42-
subtitle: Text(convertToUwU(joyStickPageDescription())),
43-
leading: const Icon(Icons.gamepad),
44-
trailing: const Icon(Icons.bug_report),
45-
onTap: () async {
46-
const DirectGearControlRoute().push(context);
47-
},
48-
),
49-
],
50-
ListTile(
51-
title: Text(convertToUwU(sequencesPage())),
52-
subtitle: Text(convertToUwU(sequencesPageDescription())),
53-
leading: const Icon(Icons.list),
54-
onTap: () async {
55-
const MoveListRoute().push(context);
56-
},
57-
),
58-
ListTile(
59-
title: Text(convertToUwU(audioPage())),
60-
subtitle: Text(convertToUwU(audioEditDescription())),
61-
leading: const Icon(Icons.audio_file),
62-
onTap: () async {
63-
const CustomAudioRoute().push(context);
64-
},
65-
),
6638
Builder(builder: (context) {
6739
String couponCode = "APPCOV25";
6840
return ListTile(
@@ -75,6 +47,15 @@ class _MoreState extends ConsumerState<More> {
7547
},
7648
);
7749
}),
50+
ListTile(
51+
title: Text(convertToUwU(moreCoshubPromoTitle())),
52+
subtitle: Text(convertToUwU(moreCoshubPromoDescription())),
53+
leading: const Icon(Icons.get_app),
54+
trailing: const Icon(Icons.open_in_browser),
55+
onTap: () async {
56+
await launchUrl(Uri.parse('https://coshub.com/${getOutboundUtm()}'));
57+
},
58+
),
7859
ListTile(
7960
title: Text(convertToUwU(settingsPage())),
8061
subtitle: Text(convertToUwU(settingsDescription())),
@@ -94,22 +75,45 @@ class _MoreState extends ConsumerState<More> {
9475
),
9576
],
9677
ListTile(
97-
leading: const Icon(Icons.feedback),
98-
title: Text(convertToUwU(feedbackPage())),
99-
subtitle: Text(convertToUwU(feedbackPageDescription())),
100-
onTap: () {
101-
BetterFeedback.of(context).showAndUploadToSentry();
78+
title: Text(
79+
convertToUwU(moreExperimentalTitle()),
80+
style: Theme.of(context).textTheme.headlineLarge,
81+
),
82+
),
83+
if (HiveProxy.getOrDefault(settings, showDebugging, defaultValue: showDebuggingDefault)) ...[
84+
ListTile(
85+
title: Text(convertToUwU(joyStickPage())),
86+
subtitle: Text(convertToUwU(joyStickPageDescription())),
87+
leading: const Icon(Icons.gamepad),
88+
trailing: const Icon(Icons.bug_report),
89+
onTap: () async {
90+
const DirectGearControlRoute().push(context);
91+
},
92+
),
93+
],
94+
ListTile(
95+
title: Text(convertToUwU(sequencesPage())),
96+
subtitle: Text(convertToUwU(sequencesPageDescription())),
97+
leading: const Icon(Icons.list),
98+
onTap: () async {
99+
const MoveListRoute().push(context);
102100
},
103101
),
104102
ListTile(
105-
title: Text(
106-
convertToUwU(moreManualTitle()),
107-
style: Theme.of(context).textTheme.headlineLarge,
108-
)
103+
title: Text(convertToUwU(audioPage())),
104+
subtitle: Text(convertToUwU(audioEditDescription())),
105+
leading: const Icon(Icons.audio_file),
106+
onTap: () async {
107+
const CustomAudioRoute().push(context);
108+
},
109109
),
110+
ListTile(
111+
title: Text(
112+
convertToUwU("${moreManualTitle()} (${moreManualSubTitle()})"),
113+
style: Theme.of(context).textTheme.headlineLarge,
114+
)),
110115
ListTile(
111116
title: Text(convertToUwU(moreManualMiTailTitle())),
112-
subtitle:Text(convertToUwU(moreManualSubTitle())),
113117
onTap: () async {
114118
PDFPageRoute(
115119
$extra: PDFInfo(
@@ -121,7 +125,6 @@ class _MoreState extends ConsumerState<More> {
121125
),
122126
ListTile(
123127
title: Text(convertToUwU(moreManualEargearTitle())),
124-
subtitle:Text(convertToUwU(moreManualSubTitle())),
125128
onTap: () async {
126129
PDFPageRoute(
127130
$extra: PDFInfo(
@@ -133,7 +136,6 @@ class _MoreState extends ConsumerState<More> {
133136
),
134137
ListTile(
135138
title: Text(convertToUwU(moreManualFlutterWingsTitle())),
136-
subtitle:Text(convertToUwU(moreManualSubTitle())),
137139
onTap: () async {
138140
PDFPageRoute(
139141
$extra: PDFInfo(
@@ -145,7 +147,6 @@ class _MoreState extends ConsumerState<More> {
145147
),
146148
ListTile(
147149
title: Text(convertToUwU(moreManualResponsibleWaggingTitle())),
148-
subtitle:Text(convertToUwU(moreManualSubTitle())),
149150
onTap: () async {
150151
HtmlPageRoute(
151152
$extra: HtmlPageInfo(
@@ -156,11 +157,10 @@ class _MoreState extends ConsumerState<More> {
156157
},
157158
),
158159
ListTile(
159-
title: Text(
160-
convertToUwU(moreUsefulLinksTitle()),
161-
style: Theme.of(context).textTheme.headlineLarge,
162-
)
163-
),
160+
title: Text(
161+
convertToUwU(moreUsefulLinksTitle()),
162+
style: Theme.of(context).textTheme.headlineLarge,
163+
)),
164164
ListTile(
165165
title: Text(convertToUwU("Store")),
166166
leading: const Icon(Icons.store),
@@ -170,7 +170,7 @@ class _MoreState extends ConsumerState<More> {
170170
},
171171
),
172172
ListTile(
173-
title: Text(convertToUwU("Wiki")),
173+
title: Text(convertToUwU("Technical Wiki")),
174174
leading: const Icon(Icons.menu_book),
175175
trailing: const Icon(Icons.open_in_browser),
176176
onTap: () async {
@@ -218,7 +218,7 @@ class _MoreState extends ConsumerState<More> {
218218
},
219219
),
220220
ListTile(
221-
title:Text(convertToUwU(morePrivacyPolicyLinkTitle())),
221+
title: Text(convertToUwU(morePrivacyPolicyLinkTitle())),
222222
leading: const Icon(Icons.privacy_tip),
223223
onTap: () async {
224224
MarkdownViewerRoute(

lib/Frontend/translation_string_definitions.dart

Lines changed: 3 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -22,16 +22,14 @@ String joyStickPage() => Intl.message('Joystick', name: 'joyStickPage', desc: 'T
2222

2323
String joyStickPageDescription() => Intl.message("Directly control your gears' position.", name: 'joyStickPageDescription', desc: 'The description of the joystick page on the more page');
2424

25-
String feedbackPage() => Intl.message('Send Feedback', name: 'feedbackPage', desc: 'The label and title of the feedback page');
26-
27-
String feedbackPageDescription() => Intl.message('Have a suggestion or issue with the app? Let us know. Note: This is anonymous and can not be used to resolve issues with Gear',
28-
name: 'feedbackPageDescription', desc: 'The description of the feedback page');
29-
3025
String audioPage() => Intl.message('Custom Sounds', name: 'audioPage', desc: 'The label and title of the custom audio management page');
3126

3227
String aboutPage() => Intl.message('About', name: 'aboutPage', desc: 'The label and title of the about page');
3328

3429
String settingsPage() => Intl.message('Settings', name: 'settingsPage', desc: 'The label and title of the settings page');
30+
String moreExperimentalTitle() => Intl.message('Experimental', name: 'moreExperimentalTitle', desc: 'The label for the experimental features on the More page');
31+
String moreCoshubPromoTitle() => Intl.message('CosHub', name: 'moreCoshubPromoTitle', desc: 'The title for the coshub link on the More page');
32+
String moreCoshubPromoDescription() => Intl.message('Our latest app to help you plan, share and create your cosplay is here', name: 'moreCoshubPromoDescription', desc: 'The description for the coshub link on the More page');
3533

3634
String settingsDescription() => Intl.message('Change app color, configure Haptics, and more', name: 'settingsDescription', desc: 'The description of the settings page on the more page');
3735

lib/Frontend/utils.dart

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import 'package:device_info_plus/device_info_plus.dart';
44
import 'package:dio/dio.dart';
55
import 'package:dio_cache_interceptor/dio_cache_interceptor.dart';
66
import 'package:dio_smart_retry/dio_smart_retry.dart';
7+
import 'package:flutter/foundation.dart';
78
import 'package:flutter/material.dart';
89
import 'package:flutter/services.dart';
910
import 'package:flutter_riverpod/flutter_riverpod.dart';
@@ -34,6 +35,9 @@ enum BluetoothPermissionStatus {
3435
@riverpod
3536
Future<BluetoothPermissionStatus> getBluetoothPermission(Ref ref) async {
3637
BluetoothPermissionStatus status = BluetoothPermissionStatus.unknown;
38+
if (kIsWeb) {
39+
return BluetoothPermissionStatus.granted;
40+
}
3741
if (Platform.isAndroid && (await DeviceInfoPlugin().androidInfo).version.sdkInt > 30) {
3842
PermissionStatus permissionStatusScan = await Permission.bluetoothScan.request();
3943
//logger.info("permissionStatusScan $permissionStatusScan");

lib/main.dart

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import 'dart:io';
33
import 'dart:ui';
44

55
import 'package:device_info_plus/device_info_plus.dart';
6-
import 'package:feedback_sentry/feedback_sentry.dart';
76
import 'package:flutter/foundation.dart';
87
import 'package:flutter/material.dart';
98
import 'package:flutter_foreground_task/flutter_foreground_task.dart';
@@ -256,15 +255,11 @@ class TailApp extends ConsumerWidget {
256255
],
257256
child: _EagerInitialization(
258257
child: BtAppStateController(
259-
child: BetterFeedback(
260-
themeMode: ThemeMode.system,
261-
darkTheme: FeedbackThemeData.dark(),
262-
child: ValueListenableBuilder(
263-
valueListenable: Hive.box(settings).listenable(keys: [appColor]),
264-
builder: (BuildContext context, value, Widget? child) {
265-
return TailAppMainWidget();
266-
},
267-
),
258+
child: ValueListenableBuilder(
259+
valueListenable: Hive.box(settings).listenable(keys: [appColor]),
260+
builder: (BuildContext context, value, Widget? child) {
261+
return TailAppMainWidget();
262+
},
268263
),
269264
),
270265
),

pubspec.lock

Lines changed: 10 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -69,10 +69,10 @@ packages:
6969
dependency: transitive
7070
description:
7171
name: async
72-
sha256: d2872f9c19731c2e5f10444b14686eb7cc85c76274bd6c16e1816bff9a3bab63
72+
sha256: "758e6d74e971c3e5aceb4110bfd6698efc7f501675bcfe0c775459a8140750eb"
7373
url: "https://pub.dev"
7474
source: hosted
75-
version: "2.12.0"
75+
version: "2.13.0"
7676
audioplayers:
7777
dependency: "direct main"
7878
description:
@@ -454,10 +454,10 @@ packages:
454454
dependency: transitive
455455
description:
456456
name: fake_async
457-
sha256: "6a95e56b2449df2273fd8c45a662d6947ce1ebb7aafe80e550a3f68297f3cacc"
457+
sha256: "5368f224a74523e8d2e7399ea1638b37aecfca824a3cc4dfdf77bf1fa905ac44"
458458
url: "https://pub.dev"
459459
source: hosted
460-
version: "1.3.2"
460+
version: "1.3.3"
461461
feedback:
462462
dependency: "direct main"
463463
description:
@@ -466,14 +466,6 @@ packages:
466466
url: "https://pub.dev"
467467
source: hosted
468468
version: "3.1.0"
469-
feedback_sentry:
470-
dependency: "direct main"
471-
description:
472-
name: feedback_sentry
473-
sha256: ca6eb5344d8ada0bfbf0b5fee4531ab99fc4bd1c5dff831cbe34e835d3994c26
474-
url: "https://pub.dev"
475-
source: hosted
476-
version: "3.1.0"
477469
ffi:
478470
dependency: transitive
479471
description:
@@ -994,10 +986,10 @@ packages:
994986
dependency: "direct main"
995987
description:
996988
name: intl
997-
sha256: d6f56758b7d3014a48af9701c085700aac781a92a87a62b1333b46d8879661cf
989+
sha256: "3df61194eb431efc39c4ceba583b95633a403f46c9fd341e550ce0bfa50e9aa5"
998990
url: "https://pub.dev"
999991
source: hosted
1000-
version: "0.19.0"
992+
version: "0.20.2"
1001993
introduction_screen:
1002994
dependency: "direct main"
1003995
description:
@@ -1066,10 +1058,10 @@ packages:
10661058
dependency: transitive
10671059
description:
10681060
name: leak_tracker
1069-
sha256: c35baad643ba394b40aac41080300150a4f08fd0fd6a10378f8f7c6bc161acec
1061+
sha256: "6bb818ecbdffe216e81182c2f0714a2e62b593f4a4f13098713ff1685dfb6ab0"
10701062
url: "https://pub.dev"
10711063
source: hosted
1072-
version: "10.0.8"
1064+
version: "10.0.9"
10731065
leak_tracker_flutter_testing:
10741066
dependency: transitive
10751067
description:
@@ -1892,10 +1884,10 @@ packages:
18921884
dependency: transitive
18931885
description:
18941886
name: vm_service
1895-
sha256: "0968250880a6c5fe7edc067ed0a13d4bae1577fe2771dcf3010d52c4a9d3ca14"
1887+
sha256: ddfa8d30d89985b96407efce8acbdd124701f96741f2d981ca860662f1c0dc02
18961888
url: "https://pub.dev"
18971889
source: hosted
1898-
version: "14.3.1"
1890+
version: "15.0.0"
18991891
wakelock_plus:
19001892
dependency: "direct main"
19011893
description:

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ dependencies:
114114
sentry_logging: ^8.14.2 # Collects app logs
115115
#sentry_hive: ^8.12.0 # Collects Hive storage accesses
116116
sentry_dio: ^8.14.2 # Collects Dio HTTP requests
117-
feedback_sentry: ^3.1.0
117+
#feedback_sentry: ^3.1.0
118118

119119
dev_dependencies:
120120
build_runner: # Required for build

web/index.html

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,9 @@
2929

3030
<title>tail_app</title>
3131
<link rel="manifest" href="manifest.json">
32+
33+
34+
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" name="viewport">
3235
<style id="splash-screen-style">
3336
html {
3437
height: 100%
@@ -100,14 +103,14 @@
100103
document.body.style.background = "transparent";
101104
}
102105
</script>
103-
<meta content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" name="viewport">
104106
</head>
105107
<body>
106108
<picture id="splash">
107109
<source srcset="splash/img/light-1x.png 1x, splash/img/light-2x.png 2x, splash/img/light-3x.png 3x, splash/img/light-4x.png 4x" media="(prefers-color-scheme: light)">
108110
<source srcset="splash/img/dark-1x.png 1x, splash/img/dark-2x.png 2x, splash/img/dark-3x.png 3x, splash/img/dark-4x.png 4x" media="(prefers-color-scheme: dark)">
109111
<img class="center" aria-hidden="true" src="splash/img/light-1x.png" alt="">
110112
</picture>
113+
111114
<script src="https://cdn.jsdelivr.net/npm/[email protected]/build/pdf.min.mjs" type="module"></script>
112115
<script type="module">
113116
var { pdfjsLib } = globalThis;

0 commit comments

Comments
 (0)