sforkowany z mirror/soapbox
Move timestamp back to Account
rodzic
24f4737a91
commit
d6c9952a8c
|
@ -310,13 +310,7 @@ const Status: React.FC<IStatus> = (props) => {
|
||||||
react: handleHotkeyReact,
|
react: handleHotkeyReact,
|
||||||
};
|
};
|
||||||
|
|
||||||
const timestampEl = (
|
const accountAction = props.accountAction;
|
||||||
<Link to={statusUrl} className='hover:underline' onClick={(event) => event.stopPropagation()}>
|
|
||||||
<RelativeTimestamp timestamp={actualStatus.created_at} theme='muted' size='sm' className='whitespace-nowrap' />
|
|
||||||
</Link>
|
|
||||||
);
|
|
||||||
|
|
||||||
const accountAction = props.accountAction || timestampEl;
|
|
||||||
|
|
||||||
const isUnderReview = actualStatus.visibility === 'self';
|
const isUnderReview = actualStatus.visibility === 'self';
|
||||||
const isSensitive = actualStatus.hidden;
|
const isSensitive = actualStatus.hidden;
|
||||||
|
@ -347,6 +341,8 @@ const Status: React.FC<IStatus> = (props) => {
|
||||||
<AccountContainer
|
<AccountContainer
|
||||||
key={String(actualStatus.getIn(['account', 'id']))}
|
key={String(actualStatus.getIn(['account', 'id']))}
|
||||||
id={String(actualStatus.getIn(['account', 'id']))}
|
id={String(actualStatus.getIn(['account', 'id']))}
|
||||||
|
timestamp={actualStatus.created_at}
|
||||||
|
timestampUrl={statusUrl}
|
||||||
action={accountAction}
|
action={accountAction}
|
||||||
hideActions={!accountAction}
|
hideActions={!accountAction}
|
||||||
showEdit={!!actualStatus.edited_at}
|
showEdit={!!actualStatus.edited_at}
|
||||||
|
|
|
@ -59,15 +59,6 @@ const DetailedStatus: React.FC<IDetailedStatus> = ({
|
||||||
const isUnderReview = actualStatus.visibility === 'self';
|
const isUnderReview = actualStatus.visibility === 'self';
|
||||||
const isSensitive = actualStatus.hidden;
|
const isSensitive = actualStatus.hidden;
|
||||||
|
|
||||||
const timestampEl = (
|
|
||||||
<RelativeTimestamp
|
|
||||||
timestamp={actualStatus.created_at}
|
|
||||||
theme='muted'
|
|
||||||
size='sm'
|
|
||||||
className='whitespace-nowrap'
|
|
||||||
/>
|
|
||||||
);
|
|
||||||
|
|
||||||
let statusTypeIcon = null;
|
let statusTypeIcon = null;
|
||||||
|
|
||||||
let quote;
|
let quote;
|
||||||
|
@ -97,7 +88,7 @@ const DetailedStatus: React.FC<IDetailedStatus> = ({
|
||||||
<Account
|
<Account
|
||||||
key={account.id}
|
key={account.id}
|
||||||
account={account}
|
account={account}
|
||||||
action={timestampEl}
|
timestamp={actualStatus.created_at}
|
||||||
avatarSize={42}
|
avatarSize={42}
|
||||||
hideActions
|
hideActions
|
||||||
/>
|
/>
|
||||||
|
|
Ładowanie…
Reference in New Issue