From 69d2d65be1a9a532333c2cb0f16f8b9b1eecc8cb Mon Sep 17 00:00:00 2001 From: PianoNic <79938743+Pianonic@users.noreply.github.com> Date: Wed, 12 Aug 2026 22:42:09 +0200 Subject: [PATCH] Link the setup guide from the Authenticator screen The empty state assumed you already knew where the QR code comes from. --- .../authenticator/authenticator_vault_screen.dart | 15 +++++++++++++++ 1 file changed, 15 insertions(+) diff --git a/lib/ui/authenticator/authenticator_vault_screen.dart b/lib/ui/authenticator/authenticator_vault_screen.dart index a838c2e..7fc58e5 100644 --- a/lib/ui/authenticator/authenticator_vault_screen.dart +++ b/lib/ui/authenticator/authenticator_vault_screen.dart @@ -3,6 +3,7 @@ import 'dart:async'; import 'package:flutter/material.dart'; import 'package:flutter/services.dart'; import 'package:forui/forui.dart'; +import 'package:url_launcher/url_launcher.dart'; import '../../services/private_account_store.dart'; import '../../services/totp_service.dart'; @@ -74,6 +75,13 @@ class _AuthenticatorVaultScreenState extends State { if (added != null) await _load(); } + Future _openGuide() async { + await launchUrl( + Uri.parse('https://docs.schuly.dev/getting-started/authenticator'), + mode: LaunchMode.externalApplication, + ); + } + Future _copy(String? code) async { if (code == null) return; await Clipboard.setData(ClipboardData(text: code)); @@ -149,6 +157,13 @@ class _AuthenticatorVaultScreenState extends State { ), const SizedBox(height: 24), FButton(prefix: const Icon(FIcons.plus), onPress: _add, child: const Text('Add authenticator')), + const SizedBox(height: 12), + FButton( + style: FButtonStyle.ghost(), + prefix: const Icon(FIcons.bookOpen), + onPress: _openGuide, + child: const Text('How do I set this up?'), + ), ], ), ),