2023-01-03 19:55:46 +00:00
|
|
|
// Copyright 2019 Signal Messenger, LLC
|
2020-10-30 20:34:04 +00:00
|
|
|
// SPDX-License-Identifier: AGPL-3.0-only
|
|
|
|
|
2022-01-26 23:05:26 +00:00
|
|
|
import type { ReactChild, RefObject } from 'react';
|
2021-10-26 19:15:33 +00:00
|
|
|
import React from 'react';
|
2021-08-11 16:23:21 +00:00
|
|
|
|
2021-10-26 19:15:33 +00:00
|
|
|
import type { LocalizerType, ThemeType } from '../../types/Util';
|
2019-03-20 17:42:28 +00:00
|
|
|
|
2021-10-26 19:15:33 +00:00
|
|
|
import type { InteractionModeType } from '../../state/ducks/conversations';
|
2022-01-26 23:05:26 +00:00
|
|
|
import { TimelineDateHeader } from './TimelineDateHeader';
|
2021-10-26 19:15:33 +00:00
|
|
|
import type {
|
2020-05-05 19:49:34 +00:00
|
|
|
Props as AllMessageProps,
|
2022-11-04 13:22:07 +00:00
|
|
|
PropsData as TimelineMessageProps,
|
2019-03-20 17:42:28 +00:00
|
|
|
PropsActions as MessageActionsType,
|
2022-11-04 13:22:07 +00:00
|
|
|
} from './TimelineMessage';
|
2021-10-26 19:15:33 +00:00
|
|
|
import type { PropsActionsType as CallingNotificationActionsType } from './CallingNotification';
|
|
|
|
import { CallingNotification } from './CallingNotification';
|
|
|
|
import { ChatSessionRefreshedNotification } from './ChatSessionRefreshedNotification';
|
2022-12-21 03:25:10 +00:00
|
|
|
import type { PropsDataType as DeliveryIssueProps } from './DeliveryIssueNotification';
|
2021-10-26 19:15:33 +00:00
|
|
|
import { DeliveryIssueNotification } from './DeliveryIssueNotification';
|
|
|
|
import type { PropsData as ChangeNumberNotificationProps } from './ChangeNumberNotification';
|
|
|
|
import { ChangeNumberNotification } from './ChangeNumberNotification';
|
|
|
|
import type { CallingNotificationType } from '../../util/callingNotification';
|
2019-11-07 21:36:16 +00:00
|
|
|
import { InlineNotificationWrapper } from './InlineNotificationWrapper';
|
2022-12-20 01:04:47 +00:00
|
|
|
import type { PropsData as UnsupportedMessageProps } from './UnsupportedMessage';
|
2021-10-26 19:15:33 +00:00
|
|
|
import { UnsupportedMessage } from './UnsupportedMessage';
|
|
|
|
import type { PropsData as TimerNotificationProps } from './TimerNotification';
|
|
|
|
import { TimerNotification } from './TimerNotification';
|
|
|
|
import type {
|
2019-03-20 17:42:28 +00:00
|
|
|
PropsActions as SafetyNumberActionsType,
|
|
|
|
PropsData as SafetyNumberNotificationProps,
|
|
|
|
} from './SafetyNumberNotification';
|
2021-10-26 19:15:33 +00:00
|
|
|
import { SafetyNumberNotification } from './SafetyNumberNotification';
|
|
|
|
import type { PropsData as VerificationNotificationProps } from './VerificationNotification';
|
|
|
|
import { VerificationNotification } from './VerificationNotification';
|
|
|
|
import type { PropsData as GroupNotificationProps } from './GroupNotification';
|
|
|
|
import { GroupNotification } from './GroupNotification';
|
2022-03-16 00:11:28 +00:00
|
|
|
import type {
|
|
|
|
PropsDataType as GroupV2ChangeProps,
|
|
|
|
PropsActionsType as GroupV2ChangeActionsType,
|
|
|
|
} from './GroupV2Change';
|
2021-10-26 19:15:33 +00:00
|
|
|
import { GroupV2Change } from './GroupV2Change';
|
|
|
|
import type { PropsDataType as GroupV1MigrationProps } from './GroupV1Migration';
|
|
|
|
import { GroupV1Migration } from './GroupV1Migration';
|
|
|
|
import type { SmartContactRendererType } from '../../groupChange';
|
2019-03-20 17:42:28 +00:00
|
|
|
import { ResetSessionNotification } from './ResetSessionNotification';
|
2021-10-26 19:15:33 +00:00
|
|
|
import type { PropsType as ProfileChangeNotificationPropsType } from './ProfileChangeNotification';
|
|
|
|
import { ProfileChangeNotification } from './ProfileChangeNotification';
|
2022-11-30 21:47:54 +00:00
|
|
|
import type { PropsType as PaymentEventNotificationPropsType } from './PaymentEventNotification';
|
|
|
|
import { PaymentEventNotification } from './PaymentEventNotification';
|
2022-12-05 22:46:54 +00:00
|
|
|
import type { PropsDataType as ConversationMergeNotificationPropsType } from './ConversationMergeNotification';
|
|
|
|
import { ConversationMergeNotification } from './ConversationMergeNotification';
|
2021-12-16 17:44:54 +00:00
|
|
|
import type { FullJSXType } from '../Intl';
|
2022-11-04 13:22:07 +00:00
|
|
|
import { TimelineMessage } from './TimelineMessage';
|
2019-03-20 17:42:28 +00:00
|
|
|
|
2020-06-04 18:16:19 +00:00
|
|
|
type CallHistoryType = {
|
|
|
|
type: 'callHistory';
|
2020-12-07 20:43:19 +00:00
|
|
|
data: CallingNotificationType;
|
2020-06-04 18:16:19 +00:00
|
|
|
};
|
2021-02-18 16:40:26 +00:00
|
|
|
type ChatSessionRefreshedType = {
|
|
|
|
type: 'chatSessionRefreshed';
|
|
|
|
data: null;
|
|
|
|
};
|
2021-05-28 19:11:19 +00:00
|
|
|
type DeliveryIssueType = {
|
|
|
|
type: 'deliveryIssue';
|
|
|
|
data: DeliveryIssueProps;
|
|
|
|
};
|
2019-03-20 17:42:28 +00:00
|
|
|
type MessageType = {
|
|
|
|
type: 'message';
|
2022-11-04 13:22:07 +00:00
|
|
|
data: TimelineMessageProps;
|
2019-03-20 17:42:28 +00:00
|
|
|
};
|
2019-05-31 22:42:01 +00:00
|
|
|
type UnsupportedMessageType = {
|
|
|
|
type: 'unsupportedMessage';
|
|
|
|
data: UnsupportedMessageProps;
|
|
|
|
};
|
2019-03-20 17:42:28 +00:00
|
|
|
type TimerNotificationType = {
|
|
|
|
type: 'timerNotification';
|
|
|
|
data: TimerNotificationProps;
|
|
|
|
};
|
2021-06-01 20:45:43 +00:00
|
|
|
type UniversalTimerNotificationType = {
|
|
|
|
type: 'universalTimerNotification';
|
|
|
|
data: null;
|
|
|
|
};
|
2021-08-05 23:34:49 +00:00
|
|
|
type ChangeNumberNotificationType = {
|
|
|
|
type: 'changeNumberNotification';
|
|
|
|
data: ChangeNumberNotificationProps;
|
|
|
|
};
|
2019-03-20 17:42:28 +00:00
|
|
|
type SafetyNumberNotificationType = {
|
|
|
|
type: 'safetyNumberNotification';
|
|
|
|
data: SafetyNumberNotificationProps;
|
|
|
|
};
|
|
|
|
type VerificationNotificationType = {
|
|
|
|
type: 'verificationNotification';
|
|
|
|
data: VerificationNotificationProps;
|
|
|
|
};
|
|
|
|
type GroupNotificationType = {
|
|
|
|
type: 'groupNotification';
|
|
|
|
data: GroupNotificationProps;
|
|
|
|
};
|
2020-09-09 02:25:05 +00:00
|
|
|
type GroupV2ChangeType = {
|
|
|
|
type: 'groupV2Change';
|
|
|
|
data: GroupV2ChangeProps;
|
|
|
|
};
|
2020-11-20 17:30:45 +00:00
|
|
|
type GroupV1MigrationType = {
|
|
|
|
type: 'groupV1Migration';
|
|
|
|
data: GroupV1MigrationProps;
|
|
|
|
};
|
2019-03-20 17:42:28 +00:00
|
|
|
type ResetSessionNotificationType = {
|
|
|
|
type: 'resetSessionNotification';
|
|
|
|
data: null;
|
|
|
|
};
|
2020-07-29 23:20:05 +00:00
|
|
|
type ProfileChangeNotificationType = {
|
|
|
|
type: 'profileChange';
|
|
|
|
data: ProfileChangeNotificationPropsType;
|
|
|
|
};
|
2022-12-05 22:46:54 +00:00
|
|
|
type ConversationMergeNotificationType = {
|
|
|
|
type: 'conversationMerge';
|
|
|
|
data: ConversationMergeNotificationPropsType;
|
|
|
|
};
|
2022-11-30 21:47:54 +00:00
|
|
|
type PaymentEventType = {
|
|
|
|
type: 'paymentEvent';
|
|
|
|
data: Omit<PaymentEventNotificationPropsType, 'i18n'>;
|
|
|
|
};
|
2020-07-29 23:20:05 +00:00
|
|
|
|
2022-01-26 23:05:26 +00:00
|
|
|
export type TimelineItemType = (
|
2020-06-04 18:16:19 +00:00
|
|
|
| CallHistoryType
|
2022-12-05 22:46:54 +00:00
|
|
|
| ChangeNumberNotificationType
|
2021-02-18 16:40:26 +00:00
|
|
|
| ChatSessionRefreshedType
|
2022-12-05 22:46:54 +00:00
|
|
|
| ConversationMergeNotificationType
|
2021-05-28 19:11:19 +00:00
|
|
|
| DeliveryIssueType
|
2020-07-29 23:20:05 +00:00
|
|
|
| GroupNotificationType
|
2020-11-20 17:30:45 +00:00
|
|
|
| GroupV1MigrationType
|
2020-09-09 02:25:05 +00:00
|
|
|
| GroupV2ChangeType
|
2019-05-31 22:42:01 +00:00
|
|
|
| MessageType
|
2020-07-29 23:20:05 +00:00
|
|
|
| ProfileChangeNotificationType
|
2020-03-10 00:43:09 +00:00
|
|
|
| ResetSessionNotificationType
|
2019-05-31 22:42:01 +00:00
|
|
|
| SafetyNumberNotificationType
|
2020-03-10 00:43:09 +00:00
|
|
|
| TimerNotificationType
|
2021-06-01 20:45:43 +00:00
|
|
|
| UniversalTimerNotificationType
|
2020-03-10 00:43:09 +00:00
|
|
|
| UnsupportedMessageType
|
2022-01-26 23:05:26 +00:00
|
|
|
| VerificationNotificationType
|
2022-11-30 21:47:54 +00:00
|
|
|
| PaymentEventType
|
2022-01-26 23:05:26 +00:00
|
|
|
) & { timestamp: number };
|
2019-03-20 17:42:28 +00:00
|
|
|
|
2019-11-07 21:36:16 +00:00
|
|
|
type PropsLocalType = {
|
2021-08-20 19:36:27 +00:00
|
|
|
containerElementRef: RefObject<HTMLElement>;
|
2019-11-07 21:36:16 +00:00
|
|
|
conversationId: string;
|
2019-05-31 22:42:01 +00:00
|
|
|
item?: TimelineItemType;
|
2019-11-07 21:36:16 +00:00
|
|
|
id: string;
|
2022-03-28 22:55:12 +00:00
|
|
|
isNextItemCallingNotification: boolean;
|
2019-11-07 21:36:16 +00:00
|
|
|
isSelected: boolean;
|
|
|
|
selectMessage: (messageId: string, conversationId: string) => unknown;
|
2022-03-28 22:55:12 +00:00
|
|
|
shouldRenderDateHeader: boolean;
|
2021-12-16 17:44:54 +00:00
|
|
|
renderContact: SmartContactRendererType<FullJSXType>;
|
2021-06-01 20:45:43 +00:00
|
|
|
renderUniversalTimerNotification: () => JSX.Element;
|
2019-03-20 17:42:28 +00:00
|
|
|
i18n: LocalizerType;
|
2021-03-24 22:06:12 +00:00
|
|
|
interactionMode: InteractionModeType;
|
2021-11-15 22:53:42 +00:00
|
|
|
theme: ThemeType;
|
2019-03-20 17:42:28 +00:00
|
|
|
};
|
|
|
|
|
2019-11-07 21:36:16 +00:00
|
|
|
type PropsActionsType = MessageActionsType &
|
2020-12-07 20:43:19 +00:00
|
|
|
CallingNotificationActionsType &
|
2022-03-16 00:11:28 +00:00
|
|
|
GroupV2ChangeActionsType &
|
2019-05-31 22:42:01 +00:00
|
|
|
SafetyNumberActionsType;
|
2019-03-20 17:42:28 +00:00
|
|
|
|
2020-05-05 19:49:34 +00:00
|
|
|
export type PropsType = PropsLocalType &
|
|
|
|
PropsActionsType &
|
2021-09-10 18:00:31 +00:00
|
|
|
Pick<
|
|
|
|
AllMessageProps,
|
2021-10-12 23:59:08 +00:00
|
|
|
| 'containerWidthBreakpoint'
|
2021-11-17 21:11:46 +00:00
|
|
|
| 'getPreferredBadge'
|
2021-10-12 23:59:08 +00:00
|
|
|
| 'renderEmojiPicker'
|
|
|
|
| 'renderAudioAttachment'
|
|
|
|
| 'renderReactionPicker'
|
2022-03-28 22:55:12 +00:00
|
|
|
| 'shouldCollapseAbove'
|
|
|
|
| 'shouldCollapseBelow'
|
|
|
|
| 'shouldHideMetadata'
|
2021-09-10 18:00:31 +00:00
|
|
|
>;
|
2019-03-20 17:42:28 +00:00
|
|
|
|
2019-11-07 21:36:16 +00:00
|
|
|
export class TimelineItem extends React.PureComponent<PropsType> {
|
2021-11-12 23:44:20 +00:00
|
|
|
public override render(): JSX.Element | null {
|
2019-11-07 21:36:16 +00:00
|
|
|
const {
|
2021-08-20 19:36:27 +00:00
|
|
|
containerElementRef,
|
2019-11-07 21:36:16 +00:00
|
|
|
conversationId,
|
2021-11-17 21:11:46 +00:00
|
|
|
getPreferredBadge,
|
2022-03-28 22:55:12 +00:00
|
|
|
i18n,
|
2019-11-07 21:36:16 +00:00
|
|
|
id,
|
2022-03-28 22:55:12 +00:00
|
|
|
isNextItemCallingNotification,
|
2019-11-07 21:36:16 +00:00
|
|
|
isSelected,
|
|
|
|
item,
|
2021-06-01 20:45:43 +00:00
|
|
|
renderUniversalTimerNotification,
|
2020-12-07 20:43:19 +00:00
|
|
|
returnToActiveCall,
|
2019-11-07 21:36:16 +00:00
|
|
|
selectMessage,
|
2022-03-28 22:55:12 +00:00
|
|
|
shouldCollapseAbove,
|
|
|
|
shouldCollapseBelow,
|
|
|
|
shouldHideMetadata,
|
|
|
|
shouldRenderDateHeader,
|
2020-12-07 20:43:19 +00:00
|
|
|
startCallingLobby,
|
2022-03-28 22:55:12 +00:00
|
|
|
theme,
|
2022-12-19 22:33:55 +00:00
|
|
|
...reducedProps
|
2019-11-07 21:36:16 +00:00
|
|
|
} = this.props;
|
2019-03-20 17:42:28 +00:00
|
|
|
|
|
|
|
if (!item) {
|
2022-03-03 20:23:10 +00:00
|
|
|
// This can happen under normal conditions.
|
|
|
|
//
|
|
|
|
// `<Timeline>` and `<TimelineItem>` are connected to Redux separately. If a
|
|
|
|
// timeline item is removed from Redux, `<TimelineItem>` might re-render before
|
|
|
|
// `<Timeline>` does, which means we'll try to render nothing. This should resolve
|
|
|
|
// itself quickly, as soon as `<Timeline>` re-renders.
|
2019-05-31 22:42:01 +00:00
|
|
|
return null;
|
2019-03-20 17:42:28 +00:00
|
|
|
}
|
|
|
|
|
2022-01-26 23:05:26 +00:00
|
|
|
let itemContents: ReactChild;
|
2019-03-20 17:42:28 +00:00
|
|
|
if (item.type === 'message') {
|
2022-01-26 23:05:26 +00:00
|
|
|
itemContents = (
|
2022-11-04 13:22:07 +00:00
|
|
|
<TimelineMessage
|
2022-12-19 22:33:55 +00:00
|
|
|
{...reducedProps}
|
2021-06-29 19:58:29 +00:00
|
|
|
{...item.data}
|
2022-12-03 00:40:33 +00:00
|
|
|
isSelected={isSelected}
|
2022-03-28 22:55:12 +00:00
|
|
|
shouldCollapseAbove={shouldCollapseAbove}
|
|
|
|
shouldCollapseBelow={shouldCollapseBelow}
|
|
|
|
shouldHideMetadata={shouldHideMetadata}
|
2021-08-20 19:36:27 +00:00
|
|
|
containerElementRef={containerElementRef}
|
2021-11-17 21:11:46 +00:00
|
|
|
getPreferredBadge={getPreferredBadge}
|
2021-06-29 19:58:29 +00:00
|
|
|
i18n={i18n}
|
|
|
|
theme={theme}
|
|
|
|
/>
|
2021-02-12 01:50:11 +00:00
|
|
|
);
|
2022-01-26 23:05:26 +00:00
|
|
|
} else {
|
|
|
|
let notification;
|
2019-11-07 21:36:16 +00:00
|
|
|
|
2022-01-26 23:05:26 +00:00
|
|
|
if (item.type === 'unsupportedMessage') {
|
|
|
|
notification = (
|
2022-12-19 22:33:55 +00:00
|
|
|
<UnsupportedMessage {...reducedProps} {...item.data} i18n={i18n} />
|
2022-01-26 23:05:26 +00:00
|
|
|
);
|
|
|
|
} else if (item.type === 'callHistory') {
|
|
|
|
notification = (
|
|
|
|
<CallingNotification
|
|
|
|
conversationId={conversationId}
|
|
|
|
i18n={i18n}
|
2022-03-28 22:55:12 +00:00
|
|
|
isNextItemCallingNotification={isNextItemCallingNotification}
|
2022-01-26 23:05:26 +00:00
|
|
|
returnToActiveCall={returnToActiveCall}
|
|
|
|
startCallingLobby={startCallingLobby}
|
|
|
|
{...item.data}
|
|
|
|
/>
|
|
|
|
);
|
|
|
|
} else if (item.type === 'chatSessionRefreshed') {
|
|
|
|
notification = (
|
2022-12-19 22:33:55 +00:00
|
|
|
<ChatSessionRefreshedNotification {...reducedProps} i18n={i18n} />
|
2022-01-26 23:05:26 +00:00
|
|
|
);
|
|
|
|
} else if (item.type === 'deliveryIssue') {
|
|
|
|
notification = (
|
|
|
|
<DeliveryIssueNotification
|
|
|
|
{...item.data}
|
2022-12-19 22:33:55 +00:00
|
|
|
{...reducedProps}
|
2022-01-26 23:05:26 +00:00
|
|
|
i18n={i18n}
|
|
|
|
/>
|
|
|
|
);
|
|
|
|
} else if (item.type === 'timerNotification') {
|
|
|
|
notification = (
|
2022-12-19 22:33:55 +00:00
|
|
|
<TimerNotification {...reducedProps} {...item.data} i18n={i18n} />
|
2022-01-26 23:05:26 +00:00
|
|
|
);
|
|
|
|
} else if (item.type === 'universalTimerNotification') {
|
|
|
|
notification = renderUniversalTimerNotification();
|
|
|
|
} else if (item.type === 'changeNumberNotification') {
|
|
|
|
notification = (
|
|
|
|
<ChangeNumberNotification
|
2022-12-19 22:33:55 +00:00
|
|
|
{...reducedProps}
|
2022-01-26 23:05:26 +00:00
|
|
|
{...item.data}
|
|
|
|
i18n={i18n}
|
|
|
|
/>
|
|
|
|
);
|
|
|
|
} else if (item.type === 'safetyNumberNotification') {
|
|
|
|
notification = (
|
|
|
|
<SafetyNumberNotification
|
2022-12-19 22:33:55 +00:00
|
|
|
{...reducedProps}
|
2022-01-26 23:05:26 +00:00
|
|
|
{...item.data}
|
|
|
|
i18n={i18n}
|
|
|
|
/>
|
|
|
|
);
|
|
|
|
} else if (item.type === 'verificationNotification') {
|
|
|
|
notification = (
|
|
|
|
<VerificationNotification
|
2022-12-19 22:33:55 +00:00
|
|
|
{...reducedProps}
|
2022-01-26 23:05:26 +00:00
|
|
|
{...item.data}
|
|
|
|
i18n={i18n}
|
|
|
|
/>
|
|
|
|
);
|
|
|
|
} else if (item.type === 'groupNotification') {
|
|
|
|
notification = (
|
2022-12-19 22:33:55 +00:00
|
|
|
<GroupNotification {...reducedProps} {...item.data} i18n={i18n} />
|
2022-01-26 23:05:26 +00:00
|
|
|
);
|
|
|
|
} else if (item.type === 'groupV2Change') {
|
|
|
|
notification = (
|
2022-12-19 22:33:55 +00:00
|
|
|
<GroupV2Change {...reducedProps} {...item.data} i18n={i18n} />
|
2022-01-26 23:05:26 +00:00
|
|
|
);
|
|
|
|
} else if (item.type === 'groupV1Migration') {
|
|
|
|
notification = (
|
2022-12-19 22:33:55 +00:00
|
|
|
<GroupV1Migration
|
|
|
|
{...reducedProps}
|
|
|
|
{...item.data}
|
|
|
|
i18n={i18n}
|
|
|
|
getPreferredBadge={getPreferredBadge}
|
|
|
|
theme={theme}
|
|
|
|
/>
|
2022-01-26 23:05:26 +00:00
|
|
|
);
|
2022-12-05 22:46:54 +00:00
|
|
|
} else if (item.type === 'conversationMerge') {
|
|
|
|
notification = (
|
|
|
|
<ConversationMergeNotification
|
2022-12-19 22:33:55 +00:00
|
|
|
{...reducedProps}
|
2022-12-05 22:46:54 +00:00
|
|
|
{...item.data}
|
|
|
|
i18n={i18n}
|
|
|
|
/>
|
|
|
|
);
|
2022-01-26 23:05:26 +00:00
|
|
|
} else if (item.type === 'resetSessionNotification') {
|
2022-12-19 22:33:55 +00:00
|
|
|
notification = (
|
|
|
|
<ResetSessionNotification {...reducedProps} i18n={i18n} />
|
|
|
|
);
|
2022-01-26 23:05:26 +00:00
|
|
|
} else if (item.type === 'profileChange') {
|
|
|
|
notification = (
|
|
|
|
<ProfileChangeNotification
|
2022-12-19 22:33:55 +00:00
|
|
|
{...reducedProps}
|
2022-11-30 21:47:54 +00:00
|
|
|
{...item.data}
|
|
|
|
i18n={i18n}
|
|
|
|
/>
|
|
|
|
);
|
|
|
|
} else if (item.type === 'paymentEvent') {
|
|
|
|
notification = (
|
|
|
|
<PaymentEventNotification
|
2022-12-19 22:33:55 +00:00
|
|
|
{...reducedProps}
|
2022-01-26 23:05:26 +00:00
|
|
|
{...item.data}
|
|
|
|
i18n={i18n}
|
|
|
|
/>
|
|
|
|
);
|
|
|
|
} else {
|
|
|
|
// Weird, yes, but the idea is to get a compile error when we aren't comprehensive
|
|
|
|
// with our if/else checks above, but also log out the type we don't understand
|
|
|
|
// if we encounter it at runtime.
|
|
|
|
const unknownItem: never = item;
|
|
|
|
const asItem = unknownItem as TimelineItemType;
|
|
|
|
throw new Error(`TimelineItem: Unknown type: ${asItem.type}`);
|
|
|
|
}
|
2019-11-07 21:36:16 +00:00
|
|
|
|
2022-01-26 23:05:26 +00:00
|
|
|
itemContents = (
|
|
|
|
<InlineNotificationWrapper
|
|
|
|
id={id}
|
2020-12-07 20:43:19 +00:00
|
|
|
conversationId={conversationId}
|
2022-01-26 23:05:26 +00:00
|
|
|
isSelected={isSelected}
|
|
|
|
selectMessage={selectMessage}
|
|
|
|
>
|
|
|
|
{notification}
|
|
|
|
</InlineNotificationWrapper>
|
2021-08-05 23:34:49 +00:00
|
|
|
);
|
2022-01-26 23:05:26 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
if (shouldRenderDateHeader) {
|
|
|
|
return (
|
|
|
|
<>
|
|
|
|
<TimelineDateHeader i18n={i18n} timestamp={item.timestamp} />
|
|
|
|
{itemContents}
|
|
|
|
</>
|
2020-07-29 23:20:05 +00:00
|
|
|
);
|
2019-03-20 17:42:28 +00:00
|
|
|
}
|
2022-01-26 23:05:26 +00:00
|
|
|
return itemContents;
|
2019-03-20 17:42:28 +00:00
|
|
|
}
|
|
|
|
}
|