feat: do not show the address in invite QR code SVG

Addresses take space and sometimes
do not fit. We generally want
to deemphasize addresses in the UI,
especially randomized chatmail
addresses.
This commit is contained in:
link2xt
2024-07-22 14:56:29 +00:00
parent bd651d9ef3
commit a710c034e4
2 changed files with 24 additions and 2 deletions

View File

@@ -859,10 +859,10 @@ pub(crate) async fn setup_contact_qr_description(
display_name: &str,
addr: &str,
) -> String {
let name = if display_name == addr {
let name = if display_name.is_empty() {
addr.to_owned()
} else {
format!("{display_name} ({addr})")
display_name.to_owned()
};
translated(context, StockMessage::SetupContactQRDescription)
.await