kopia lustrzana https://gitlab.com/soapbox-pub/soapbox
Merge branch 'since-date-title' into 'develop'
Add title to created_at label See merge request soapbox-pub/soapbox!2650environments/review-develop-3zknud/deployments/3760
commit
d64f49334a
|
@ -54,4 +54,4 @@ function useSignerStream() {
|
||||||
}, [relayUrl, pubkey]);
|
}, [relayUrl, pubkey]);
|
||||||
}
|
}
|
||||||
|
|
||||||
export { useSignerStream };
|
export { useSignerStream };
|
||||||
|
|
|
@ -18,6 +18,7 @@ import { useAppSelector, useAppDispatch } from 'soapbox/hooks';
|
||||||
import { isLocal } from 'soapbox/utils/accounts';
|
import { isLocal } from 'soapbox/utils/accounts';
|
||||||
|
|
||||||
import { showProfileHoverCard } from './hover-ref-wrapper';
|
import { showProfileHoverCard } from './hover-ref-wrapper';
|
||||||
|
import { dateFormatOptions } from './relative-timestamp';
|
||||||
import { Card, CardBody, HStack, Icon, Stack, Text } from './ui';
|
import { Card, CardBody, HStack, Icon, Stack, Text } from './ui';
|
||||||
|
|
||||||
import type { Account, PatronUser } from 'soapbox/schemas';
|
import type { Account, PatronUser } from 'soapbox/schemas';
|
||||||
|
@ -128,7 +129,7 @@ export const ProfileHoverCard: React.FC<IProfileHoverCard> = ({ visible = true }
|
||||||
className='h-4 w-4 text-gray-800 dark:text-gray-200'
|
className='h-4 w-4 text-gray-800 dark:text-gray-200'
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<Text size='sm'>
|
<Text size='sm' title={intl.formatDate(account.created_at, dateFormatOptions)}>
|
||||||
<FormattedMessage
|
<FormattedMessage
|
||||||
id='account.member_since' defaultMessage='Joined {date}' values={{
|
id='account.member_since' defaultMessage='Joined {date}' values={{
|
||||||
date: memberSinceDate,
|
date: memberSinceDate,
|
||||||
|
|
|
@ -16,7 +16,7 @@ const messages = defineMessages({
|
||||||
days_remaining: { id: 'time_remaining.days', defaultMessage: '{number, plural, one {# day} other {# days}} left' },
|
days_remaining: { id: 'time_remaining.days', defaultMessage: '{number, plural, one {# day} other {# days}} left' },
|
||||||
});
|
});
|
||||||
|
|
||||||
const dateFormatOptions: FormatDateOptions = {
|
export const dateFormatOptions: FormatDateOptions = {
|
||||||
hour12: true,
|
hour12: true,
|
||||||
year: 'numeric',
|
year: 'numeric',
|
||||||
month: 'short',
|
month: 'short',
|
||||||
|
|
|
@ -6,6 +6,7 @@ import { defineMessages, useIntl, FormattedMessage } from 'react-intl';
|
||||||
import { usePatronUser } from 'soapbox/api/hooks';
|
import { usePatronUser } from 'soapbox/api/hooks';
|
||||||
import Badge from 'soapbox/components/badge';
|
import Badge from 'soapbox/components/badge';
|
||||||
import Markup from 'soapbox/components/markup';
|
import Markup from 'soapbox/components/markup';
|
||||||
|
import { dateFormatOptions } from 'soapbox/components/relative-timestamp';
|
||||||
import { Icon, HStack, Stack, Text } from 'soapbox/components/ui';
|
import { Icon, HStack, Stack, Text } from 'soapbox/components/ui';
|
||||||
import { useAppSelector, useSoapboxConfig } from 'soapbox/hooks';
|
import { useAppSelector, useSoapboxConfig } from 'soapbox/hooks';
|
||||||
import { isLocal } from 'soapbox/utils/accounts';
|
import { isLocal } from 'soapbox/utils/accounts';
|
||||||
|
@ -184,7 +185,7 @@ const ProfileInfoPanel: React.FC<IProfileInfoPanel> = ({ account, username }) =>
|
||||||
className='h-4 w-4 text-gray-800 dark:text-gray-200'
|
className='h-4 w-4 text-gray-800 dark:text-gray-200'
|
||||||
/>
|
/>
|
||||||
|
|
||||||
<Text size='sm'>
|
<Text size='sm' title={intl.formatDate(account.created_at, dateFormatOptions)}>
|
||||||
<FormattedMessage
|
<FormattedMessage
|
||||||
id='account.member_since' defaultMessage='Joined {date}' values={{
|
id='account.member_since' defaultMessage='Joined {date}' values={{
|
||||||
date: memberSinceDate,
|
date: memberSinceDate,
|
||||||
|
|
|
@ -28,4 +28,4 @@ const getScopes = (state: RootState) => {
|
||||||
export {
|
export {
|
||||||
getInstanceScopes,
|
getInstanceScopes,
|
||||||
getScopes,
|
getScopes,
|
||||||
};
|
};
|
||||||
|
|
Ładowanie…
Reference in New Issue