MystenLabs / sui

Sui, a next-generation smart contract platform with high throughput, low latency, and an asset-oriented programming model powered by the Move programming language
https://sui.io
Apache License 2.0
6.27k stars 11.21k forks source link

Sui Feature Request - Minor bug with domain display in wallet #20409

Open yjshi2015 opened 1 day ago

yjshi2015 commented 1 day ago

Steps to Reproduce Issue

If a nickname is set first in the wallet's account and then a domain name is requested, the domain name is not automatically displayed in the wallet and there is no entry point to view the domain name(If you don't have a nickname set up you won't have this problem).

It can only be done as follows:

  1. delete the account and re-import it, but this is a very dangerous operation.

  2. Set the nickname to null value in the place of modifying the nickname, because the display priority is Nickname > Domain > Address, but this way may not be too friendly for common users.

    const accountName = account?.nickname ?? domainName ?? formatAddress(account?.address || '');

Expected Result

When modifying nicknames, display the domain name, and users can choose whether to use the domain name or continue to use the nickname. like this:

image

Actual Result

image