Fix room login screen

This commit is contained in:
PacoX
2026-06-24 14:38:35 +02:00
parent ef6c1e0898
commit 3541b1bbac
2 changed files with 10 additions and 2 deletions
+6 -1
View File
@@ -1,6 +1,7 @@
import 'package:flutter/material.dart'; import 'package:flutter/material.dart';
import 'package:flutter/services.dart'; import 'package:flutter/services.dart';
import 'package:meshcore_open/connector/meshcore_protocol.dart'; import 'package:meshcore_open/connector/meshcore_protocol.dart';
import 'package:meshcore_open/connector/meshcore_connector.dart';
import 'package:provider/provider.dart'; import 'package:provider/provider.dart';
import '../l10n/l10n.dart'; import '../l10n/l10n.dart';
import '../models/contact.dart'; import '../models/contact.dart';
@@ -31,6 +32,7 @@ class RepeaterHubScreen extends StatelessWidget {
final l10n = context.l10n; final l10n = context.l10n;
final scheme = Theme.of(context).colorScheme; final scheme = Theme.of(context).colorScheme;
final settingsService = context.watch<AppSettingsService>(); final settingsService = context.watch<AppSettingsService>();
final connector = context.watch<MeshCoreConnector>();
final chemistry = settingsService.batteryChemistryForRepeater( final chemistry = settingsService.batteryChemistryForRepeater(
repeater.publicKeyHex, repeater.publicKeyHex,
); );
@@ -85,7 +87,10 @@ class RepeaterHubScreen extends StatelessWidget {
), ),
const SizedBox(height: 4), const SizedBox(height: 4),
Text( Text(
repeater.pathLabel(l10n), repeater.pathLabel(
l10n,
pathHashByteWidth: connector.pathHashByteWidth,
),
style: Theme.of(context).textTheme.bodySmall style: Theme.of(context).textTheme.bodySmall
?.copyWith(color: scheme.onSurfaceVariant), ?.copyWith(color: scheme.onSurfaceVariant),
), ),
+4 -1
View File
@@ -405,7 +405,10 @@ class _RoomLoginDialogState extends State<RoomLoginDialog> {
), ),
const SizedBox(height: 4), const SizedBox(height: 4),
Text( Text(
repeater.pathLabel(context.l10n), repeater.pathLabel(
context.l10n,
pathHashByteWidth: connector.pathHashByteWidth,
),
style: TextStyle( style: TextStyle(
fontSize: 11, fontSize: 11,
color: scheme.onSurfaceVariant, color: scheme.onSurfaceVariant,