fix(mobile): draw a pull request's bot authors as the panel does
Merged
DA
4d ago+139+139+012345678901234567890123456789-49-49-01234567890123456789
What
On iOS, a pull request page used to show a GitHub App's bot by its raw login (relay-review[bot], coderabbitai[bot]). It now draws the bot the way the panel does:
- Name: the login without GitHub's
[bot]suffix. - Avatar: the bot's avatar in a rounded square (this part was already right).
- Tag: a quiet "bot" tag after the name.
This applies to the bot's row under Reviews and to the "opened" line in the heading when a bot opened the pull request. Checks already name their App by its own name, so they don't change.
How
- The rule for naming a GitHub account moves out of
@repo/ui's actor model into a new module,@repo/features/github-login. It holdsisBotLogin,githubLoginNameandBOT_TAG_WORDS.@repo/ui-nativecan't import@repo/ui, so this lets both share the rule. These now read it:@repo/ui'sactorNameopenerOfinlink-standing-model- the panel's
BotBadge - iOS's
githubFace
@repo/ui-native:githubFacenames the account throughgithubLoginNameand sets the newFace.botfield.- New
BotTagcomponent. MarkRowdraws the tag after the title, using a newafterslot onRowHead, and says "bot" in the row's VoiceOver value.OpenedLinedraws the tag after a bot opener's name.
- Any later place on iOS that names a GitHub author should use
githubFace(person)for the face and name, andBotTagafter the name whereface.botis set.
Tests
- Ran
pnpm exec vitest run packages/ui/src/actor-model.test.ts packages/features/src/link-standing-model.test.ts: both files pass. tsc -bpasses forui-native,ui,panelandmobile, andpnpm oxlintreports no errors.apps/mobile/maestro/pull-request.yamlnow asserts the fixture's review bot is shown asrelay-review(the oldrelay-review[bot]label fails that match) and takes apull-request-reviewersframe. A simulator run on the Mac is pending. The rest is left to CI.
š¤ Generated with Claude Code