As an identity holder, I want to see my full account ID, hand it to someone, and give the key a name I recognise, so that others can find me and I can tell my identities apart.
Situation
Someone asked for my account ID so they can mention me or give me access. I also have two identities whose short ids look alike. I am on the Me tab with at least one identity.
What I do
Tap my current identity, or open any identity from Vault.
Read the "Account ID" section.
Tap "Copy account ID", or "Share account ID…" and pick where to send it.
Tap "Key name", type a name, and tap "Save".
What I should see
A screen titled "Identity" with the avatar, the name, and "Current identity" or "On this device". See Identity detail.
Under "Account ID", the complete identifier in a fixed width face, wrapping over lines. I can also select it by hand.
"Copy account ID" puts it on the clipboard and the phone gives a success tap.
"Share account ID…" opens the system share sheet with the identifier as text.
A "Key name" row shows the current name, or "None".
The note below reads "The key name is only on this device. Your public name comes from your profile."
Tapping "Key name" opens an alert titled "Rename key" with "Letters, numbers, dashes and underscores.", a field, "Save" and "Cancel". The field starts with the present name.
After "Save" the row shows the new name. If I have no public profile name, the title here and my row on Me change to it too.
This is the only screen that shows the full identifier. Everywhere else I see names and short ids.
When something goes wrong
A name with spaces or symbols is refused. The note turns red and reads "Names may only contain letters, numbers, dashes and underscores." I tap "Key name" again and correct it.
A name another key uses gives "Name already exists, delete it first."
If the identity was removed meanwhile, the screen shows "This identity is no longer on this device."
Not included
Copying gives no visible confirmation, only the tap from the phone.
There is no QR code and no link to my public page from this screen.
With a remote vault connected, a key name can reach my other devices that have no name for that key, so "only on this device" is not always exact. See Keep my identities in sync across devices.
The share sheet and clipboard themselves are not checked by an automated test, only that the rows exist. See Contract UI tests.
Trace
Story US-ID-04, status Shipped. These links are kept in step with the traceability matrix and with the "User stories" section of every page listed here.
Design
Page | Part it plays |
|---|---|
The screen with the Account ID section and the Key name row | |
Entry point: the current identity row | |
Entry point: identity rows in the vault list | |
The header row with avatar, name and subtitle | |
The 56 point avatar in the header | |
The Rename key alert with its text field | |
The name field inside the alert | |
Copy and share rows and their feedback | |
The Rename key alert in the alert inventory | |
Where the rename error appears and how it is coloured | |
The success haptic on copy | |
Missing identity, no key name and rename refused states | |
The one place the full identifier is shown; key name versus public name | |
Copy and share kept for parity with the earlier app | |
Monospace footnote for the identifier | |
The copy and share symbols |
Implementation
Page | Part it plays |
|---|---|
Orientation: the package that owns identities | |
MeIdentityScreen, copyId, shareId and the rename actions | |
meRenameIdentity | |
renameKey, nameError and where the name is stored | |
Key names as per-device labels when a vault is connected | |
vaultTrackMe sends a rename to the vault | |
meRenameDraft, meRenamed and meRenameError | |
The identity route /me/id/:uid | |
The built-in copyText, share, haptic and showModal calls | |
The UI tests for rename and for the copy and share rows | |
Unit tests for the name rules |
Code
File | What |
|---|---|
MeIdentityScreen | |
copyId and shareId | |
Account ID section, Key name row and its footer | |
Rename key dialog | |
meRenameDraft | |
meRenamed and meRenameError | |
meAskRename, meEditRename, meRename | |
view wiring for the identity route | |
meRenameIdentity | |
renameKey | |
nameError |
Tests
File | What it checks |
|---|---|
me: rename the key, refusing a bad name | |
me: an unnamed identity shows its short id once, and its account ID copies and shares | |
me: identity detail exports the key file after asking, and removes | |
name rules; shortId | |
a normal name starting with z6Mk is not mistaken for a principal | |
a key name is a per-device label: two labels never rewrite the vault, a label fills in where there is none |
Delivery
Delivered by #1470.
Do you like what you are reading? Subscribe to receive updates.
Unsubscribe anytime