Page MenuHomePhabricator

[native] Improve device labels on device list screen
ClosedPublic

Authored by bartek on Oct 17 2024, 7:43 AM.
Tags
None
Referenced Files
F3323470: D13747.id45720.diff
Wed, Nov 20, 3:42 AM
F3323373: D13747.diff
Wed, Nov 20, 3:41 AM
F3323018: D13747.id.diff
Wed, Nov 20, 2:44 AM
Unknown Object (File)
Mon, Nov 18, 5:02 PM
Unknown Object (File)
Fri, Nov 15, 2:54 AM
Unknown Object (File)
Fri, Nov 15, 2:05 AM
Unknown Object (File)
Thu, Nov 14, 10:13 PM
Unknown Object (File)
Sat, Nov 9, 10:42 AM
Subscribers

Details

Summary

Resolves ENG-9136

The previous label for current primary device looked weird with two parentheses:

someDeviceID (primary) (this device)

Depends on D13262

Test Plan
  • Opened devices screen on native and verified they're now displayed correctly

Simulator Screenshot - iPhone 15 Pro - 2024-10-18 at 10.55.22.png (2×1 px, 188 KB)

  • JS playground:
function getLabel(deviceID, isPrimary, isThisDevice) {
  // contents of useMemo
}

getLabel('123456789', false, false) // '1234567'
getLabel('123456789', false, true)  // '1234567 (this device)'
getLabel('123456789', true, false)  // '1234567 (primary)'
getLabel('123456789', true, true)   // '1234567 (primary, this device)'

Diff Detail

Repository
rCOMM Comm
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Can you share a screenshot of what it looks like now in the Test Plan?

This revision is now accepted and ready to land.Oct 17 2024, 9:03 AM