Bluesky app fork with some witchin' additions 💫
0
fork

Configure Feed

Select the types of activity you want to include in your feed.

Add label to profile card (#4843)

authored by

Eric Bailey and committed by
GitHub
50769b0b 043e5cea

+21 -7
+9 -3
src/components/FeedInterstitials.tsx
··· 190 190 {profiles.slice(0, maxLength).map(profile => ( 191 191 <ProfileCard.Link 192 192 key={profile.did} 193 - did={profile.handle} 193 + profile={profile} 194 194 onPress={() => { 195 195 logEvent('feed:interstitial:profileCard:press', {}) 196 196 }} ··· 266 266 a.pt_xs, 267 267 a.gap_md, 268 268 ]}> 269 - <InlineLinkText to="/search" style={[t.atoms.text_contrast_medium]}> 269 + <InlineLinkText 270 + label={_(msg`Browse more suggestions`)} 271 + to="/search" 272 + style={[t.atoms.text_contrast_medium]}> 270 273 <Trans>Browse more suggestions</Trans> 271 274 </InlineLinkText> 272 275 <Arrow size="sm" fill={t.atoms.text_contrast_medium.color} /> ··· 396 399 a.pt_xs, 397 400 a.gap_md, 398 401 ]}> 399 - <InlineLinkText to="/search" style={[t.atoms.text_contrast_medium]}> 402 + <InlineLinkText 403 + label={_(msg`Browse more suggestions`)} 404 + to="/search" 405 + style={[t.atoms.text_contrast_medium]}> 400 406 <Trans>Browse more suggestions</Trans> 401 407 </InlineLinkText> 402 408 <Arrow size="sm" fill={t.atoms.text_contrast_medium.color} />
+12 -4
src/components/ProfileCard.tsx
··· 36 36 logContext?: 'ProfileCard' | 'StarterPackProfilesList' 37 37 }) { 38 38 return ( 39 - <Link did={profile.did}> 39 + <Link profile={profile}> 40 40 <Card 41 41 profile={profile} 42 42 moderationOpts={moderationOpts} ··· 96 96 } 97 97 98 98 export function Link({ 99 - did, 99 + profile, 100 100 children, 101 101 style, 102 102 ...rest 103 - }: {did: string} & Omit<LinkProps, 'to'>) { 103 + }: { 104 + profile: AppBskyActorDefs.ProfileViewDetailed 105 + } & Omit<LinkProps, 'to' | 'label'>) { 106 + const {_} = useLingui() 104 107 return ( 105 108 <InternalLink 109 + label={_( 110 + msg`View ${ 111 + profile.displayName || sanitizeHandle(profile.handle) 112 + }'s profile`, 113 + )} 106 114 to={{ 107 115 screen: 'Profile', 108 - params: {name: did}, 116 + params: {name: profile.did}, 109 117 }} 110 118 style={[a.flex_col, style]} 111 119 {...rest}>