2020-04-17 18:07:32 +00:00
|
|
|
import React from 'react';
|
2020-04-17 18:45:20 +00:00
|
|
|
import styled from 'styled-components';
|
2020-04-17 21:43:03 +00:00
|
|
|
import ScreenBlock from '@/components/screens/ScreenBlock';
|
2020-04-17 18:07:32 +00:00
|
|
|
|
2020-04-17 21:43:03 +00:00
|
|
|
interface Props {
|
2020-04-17 18:07:32 +00:00
|
|
|
title?: string;
|
|
|
|
message: string;
|
2020-04-17 18:45:20 +00:00
|
|
|
onRetry?: () => void;
|
2020-04-17 18:27:52 +00:00
|
|
|
onBack?: () => void;
|
2020-04-17 18:07:32 +00:00
|
|
|
}
|
|
|
|
|
2020-04-17 18:45:20 +00:00
|
|
|
export default ({ title, message, onBack, onRetry }: Props) => (
|
2020-04-17 21:43:03 +00:00
|
|
|
// @ts-ignore
|
|
|
|
<ScreenBlock
|
|
|
|
title={title || 'Something went wrong'}
|
|
|
|
image={'/assets/svgs/server_error.svg'}
|
|
|
|
message={message}
|
|
|
|
onBack={onBack}
|
|
|
|
onRetry={onRetry}
|
|
|
|
/>
|
2020-04-17 18:07:32 +00:00
|
|
|
);
|