feat: Update AuthFlow logic and enhance ChatsListScreen with styled truncated public key display

This commit is contained in:
k1ngsterr1
2026-01-09 02:59:26 +05:00
parent ff242a5c7f
commit 961e89d8ee
2 changed files with 10 additions and 7 deletions

View File

@@ -26,7 +26,6 @@ fun AuthFlow(
var currentScreen by remember { var currentScreen by remember {
mutableStateOf( mutableStateOf(
when { when {
hasExistingAccount && accounts.size > 1 -> AuthScreen.SELECT_ACCOUNT
hasExistingAccount -> AuthScreen.UNLOCK hasExistingAccount -> AuthScreen.UNLOCK
else -> AuthScreen.WELCOME else -> AuthScreen.WELCOME
} }

View File

@@ -386,12 +386,17 @@ fun ChatsListScreen(
Spacer(modifier = Modifier.height(16.dp)) Spacer(modifier = Modifier.height(16.dp))
// Public key instead of account name // Public key - truncated and styled
val truncatedKey = if (accountPublicKey.length > 12) {
"${accountPublicKey.take(6)}...${accountPublicKey.takeLast(4)}"
} else accountPublicKey
Text( Text(
text = accountPublicKey, text = truncatedKey,
fontSize = 14.sp, fontSize = 13.sp,
fontWeight = FontWeight.Medium, fontWeight = FontWeight.Normal,
color = secondaryTextColor, color = secondaryTextColor,
letterSpacing = 0.5.sp,
maxLines = 1 maxLines = 1
) )
} }
@@ -466,8 +471,7 @@ fun ChatsListScreen(
) )
} }
Spacer(modifier = Modifier.navigationBarsPadding()) Spacer(modifier = Modifier.height(32.dp))
Spacer(modifier = Modifier.height(16.dp))
} }
} }
) { ) {