diff --git a/src/components/dialogs/nuxs/InviteFriendsAnnouncement.tsx b/src/components/dialogs/nuxs/InviteFriendsAnnouncement.tsx
index 8a8577d807..1ef8c5dbbc 100644
--- a/src/components/dialogs/nuxs/InviteFriendsAnnouncement.tsx
+++ b/src/components/dialogs/nuxs/InviteFriendsAnnouncement.tsx
@@ -1,9 +1,7 @@
import {useCallback} from 'react'
import {View} from 'react-native'
import {Image} from 'expo-image'
-import {msg} from '@lingui/core/macro'
-import {useLingui} from '@lingui/react'
-import {Trans} from '@lingui/react/macro'
+import {Trans, useLingui} from '@lingui/react/macro'
import {atoms as a, useTheme, web} from '#/alf'
import {Button, ButtonText} from '#/components/Button'
@@ -22,7 +20,7 @@ export const enabled = createIsEnabledCheck(() => {
export function InviteFriendsAnnouncement() {
const t = useTheme()
- const {_} = useLingui()
+ const {t: l} = useLingui()
const nuxDialogs = useNuxDialogContext()
const control = Dialog.useDialogControl()
@@ -37,9 +35,9 @@ export function InviteFriendsAnnouncement() {
// the invite dialog. The invite dialog is mounted persistently by NuxDialogs
// (not here) so it survives the dismissal - the native bottom sheet cannot
// hand off to a second sheet mounted in this same subtree. Defer the open to
- // the next tick so the announcement's teardown completes first.
+ // the next frame so the announcement's teardown completes first.
control.close(() => {
- setTimeout(() => nuxDialogs.openInviteFriends())
+ requestAnimationFrame(() => nuxDialogs.openInviteFriends())
})
}, [control, nuxDialogs])
@@ -52,7 +50,7 @@ export function InviteFriendsAnnouncement() {
)
}
diff --git a/src/features/inviteFriends/urls.test.ts b/src/features/inviteFriends/urls.test.ts
index 95e07dc6e3..e24c3ca1cc 100644
--- a/src/features/inviteFriends/urls.test.ts
+++ b/src/features/inviteFriends/urls.test.ts
@@ -22,9 +22,9 @@ describe('invite URLs', () => {
)
})
- it('lowercases the handle', () => {
+ it('passes the handle through verbatim (handles are API-normalized, like makeProfileLink)', () => {
expect(getInviteShareUrl('Alice.Bsky.Social')).toBe(
- 'https://bsky.app/profile/alice.bsky.social',
+ 'https://bsky.app/profile/Alice.Bsky.Social',
)
})
@@ -45,9 +45,9 @@ describe('invite URLs', () => {
expect(getInviteDisplayUrl('alice')).toBe('bsky.app/profile/alice')
})
- it('lowercases the handle', () => {
+ it('passes the handle through verbatim (handles are API-normalized, like makeProfileLink)', () => {
expect(getInviteDisplayUrl('Danielle.bsky.team')).toBe(
- 'bsky.app/profile/danielle.bsky.team',
+ 'bsky.app/profile/Danielle.bsky.team',
)
})
diff --git a/src/features/inviteFriends/urls.ts b/src/features/inviteFriends/urls.ts
index 1b5c68d965..7a22b8faf4 100644
--- a/src/features/inviteFriends/urls.ts
+++ b/src/features/inviteFriends/urls.ts
@@ -16,7 +16,7 @@ function stripLeadingAt(handle: string): string {
/** Canonical URL - used for QR payload, Share, and Copy. Empty handle -> empty string. */
export function getInviteShareUrl(handle: string): string {
- const bare = stripLeadingAt(handle).toLowerCase()
+ const bare = stripLeadingAt(handle)
if (!bare) return ''
return `https://bsky.app/profile/${bare}`
}