diff --git a/CHANGELOG.md b/CHANGELOG.md index 5277a1b..e2b4147 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,7 +4,7 @@ ## 0.0.93 - Feature: Verification checkmark for friends -- Fix: Added contacts in contact sharing where not click able +- Fix: Added contacts in contact sharing that were not clickable. - Fix: Open chat after the image expires in case a draft message exists - Fix: Restore flames as a plus user - Fix: Route not found when sharing image @@ -12,6 +12,7 @@ - Fix: Increase show time of the focus indication - Fix: Quoted text message not shown properly - Fix: Push notification in groups when someone saves an image +- Fix: Dark mode in diagnostics view ## 0.0.92 diff --git a/lib/src/providers/purchases.provider.dart b/lib/src/providers/purchases.provider.dart index 29ba6a8..3895c18 100644 --- a/lib/src/providers/purchases.provider.dart +++ b/lib/src/providers/purchases.provider.dart @@ -83,7 +83,7 @@ class PurchasesProvider with ChangeNotifier, DiagnosticableTreeMixin { if (user != null && isPayingUser(planFromString(user.subscriptionPlan))) { Log.info('Started IPA timer for verification.'); globalForceIpaCheck = Timer(const Duration(seconds: 5), () async { - Log.warn('Force Ipa check was not stopped. Requesting forced check...'); + Log.info('Force Ipa check was not stopped. Requesting forced check...'); await apiService.forceIpaCheck(); }); } diff --git a/lib/src/views/settings/help/diagnostics.view.dart b/lib/src/views/settings/help/diagnostics.view.dart index 8b05bcf..a96cd1c 100644 --- a/lib/src/views/settings/help/diagnostics.view.dart +++ b/lib/src/views/settings/help/diagnostics.view.dart @@ -1,7 +1,7 @@ import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; -import 'package:path_provider/path_provider.dart'; -import 'package:share_plus/share_plus.dart'; +import 'package:go_router/go_router.dart'; +import 'package:twonly/src/constants/routes.keys.dart'; import 'package:twonly/src/utils/log.dart'; import 'package:twonly/src/views/components/loader.dart'; @@ -13,8 +13,6 @@ class DiagnosticsView extends StatefulWidget { } class _DiagnosticsViewState extends State { - final ScrollController _scrollController = ScrollController(); - String? _debugLogText; @override @@ -28,41 +26,6 @@ class _DiagnosticsViewState extends State { setState(() {}); } - Future _scrollToBottom() async { - // Assuming the button is at the bottom of the scroll view - await _scrollController.animateTo( - _scrollController.position.maxScrollExtent, // Scroll to the bottom - duration: const Duration(milliseconds: 300), - curve: Curves.easeInOut, - ); - } - - Future _shareDebugLog() async { - if (_debugLogText == null) return; - final directory = await getApplicationSupportDirectory(); - final logFile = XFile('${directory.path}/app.log'); - - final params = ShareParams( - text: 'Debug log', - files: [logFile], - ); - - final result = await SharePlus.instance.share(params); - - if (result.status != ShareResultStatus.success) { - await Clipboard.setData( - ClipboardData(text: _debugLogText!), - ); - if (mounted) { - ScaffoldMessenger.of(context).showSnackBar( - const SnackBar( - content: Text('Log copied to clipboard!'), - ), - ); - } - } - } - Future _deleteDebugLog() async { if (await deleteLogFile()) { if (!mounted) return; @@ -100,13 +63,10 @@ class _DiagnosticsViewState extends State { mainAxisAlignment: MainAxisAlignment.spaceBetween, children: [ TextButton( - onPressed: _shareDebugLog, + onPressed: () => + context.push(Routes.settingsHelpContactUs), child: const Text('Share debug log'), ), - TextButton( - onPressed: _scrollToBottom, - child: const Text('Scroll to Bottom'), - ), TextButton( onPressed: _deleteDebugLog, child: const Text('Delete Log File'), @@ -186,7 +146,6 @@ class _LogViewerWidgetState extends State { selected: selected, onSelected: (_) => _setFilter(label), selectedColor: _colorForLevel(label).withAlpha(120), - backgroundColor: Colors.grey.shade200, ); } @@ -198,7 +157,7 @@ class _LogViewerWidgetState extends State { fontWeight: FontWeight.bold, fontFamily: 'monospace', ); - const msgStyle = TextStyle(color: Colors.black87, fontFamily: 'monospace'); + const msgStyle = TextStyle(fontFamily: 'monospace'); return TextSpan( children: [ @@ -249,12 +208,7 @@ class _LogViewerWidgetState extends State { ), Expanded( child: Container( - padding: const EdgeInsets.all(8), - decoration: BoxDecoration( - color: Colors.grey.shade50, - borderRadius: BorderRadius.circular(8), - border: Border.all(color: Colors.grey.shade300), - ), + padding: const EdgeInsets.only(left: 8), child: Scrollbar( controller: _controller, child: ListView.builder(