mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-12-15 10:02:47 +03:00
profile: surface "message" action on non-owned profiles
fixes urbit/landscape#532
This commit is contained in:
parent
487cb75313
commit
b7082343ec
@ -111,7 +111,7 @@ export function ProfileStatus(props: any): ReactElement {
|
||||
);
|
||||
}
|
||||
|
||||
export function ProfileOwnControls(props: any): ReactElement {
|
||||
export function ProfileActions(props: any): ReactElement {
|
||||
const { ship, isPublic, contact, api } = { ...props };
|
||||
const history = useHistory();
|
||||
return (
|
||||
@ -137,7 +137,18 @@ export function ProfileOwnControls(props: any): ReactElement {
|
||||
contact={contact}
|
||||
/>
|
||||
</>
|
||||
) : null}
|
||||
) : (
|
||||
<>
|
||||
<Text
|
||||
py='2'
|
||||
cursor='pointer'
|
||||
fontWeight='500'
|
||||
onClick={() => history.push(`/~landscape/dm/${ship}`)}
|
||||
>
|
||||
Message
|
||||
</Text>
|
||||
</>
|
||||
)}
|
||||
</Row>
|
||||
);
|
||||
}
|
||||
|
@ -11,7 +11,7 @@ import useLocalState from '~/logic/state/local';
|
||||
import {
|
||||
ProfileHeader,
|
||||
ProfileControls,
|
||||
ProfileOwnControls,
|
||||
ProfileActions,
|
||||
ProfileStatus,
|
||||
ProfileImages
|
||||
} from './Profile';
|
||||
@ -25,7 +25,7 @@ export function ViewProfile(props: any) {
|
||||
<>
|
||||
<ProfileHeader>
|
||||
<ProfileControls>
|
||||
<ProfileOwnControls
|
||||
<ProfileActions
|
||||
ship={ship}
|
||||
isPublic={isPublic}
|
||||
contact={contact}
|
||||
|
Loading…
Reference in New Issue
Block a user