import React from 'react';
import { ContactName } from './ContactName';
import { Intl } from '../Intl';
import { missingCaseError } from '../../util/missingCaseError';
import { SessionIcon, SessionIconSize, SessionIconType } from '../session/icon';
type Props = {
type: 'fromOther' | 'fromMe' | 'fromSync';
phoneNumber: string;
profileName?: string;
name?: string;
disabled: boolean;
timespan: string;
};
export const TimerNotification = (props: Props) => {
function renderContents() {
const { phoneNumber, profileName, timespan, type, disabled } = props;
const changeKey = disabled
? 'disabledDisappearingMessages'
: 'theyChangedTheTimer';
const contact = (
{profileName || phoneNumber}
);
switch (type) {
case 'fromOther':
return (