import Box from '@mui/material/Box';
import { BackstoryPageProps } from '../components/BackstoryTab';
import { Message } from '../components/Message';
import { ChatMessage } from 'types/types';

const LoadingPage = (props: BackstoryPageProps) => {
    const preamble: ChatMessage = {
        sender: 'system',
        status: 'done',
        sessionId: '',
        content: 'Please wait while connecting to Backstory...',
        timestamp: new Date()
    }

    return <Box sx={{display: "flex", flexGrow: 1, maxWidth: "1024px", margin: "0 auto"}}>
        <Message message={preamble} {...props} />
    </Box>
};

export {
  LoadingPage
};