import React from 'react'; import { defineMessages, useIntl } from 'react-intl'; import IconButton from 'soapbox/components/icon-button'; const messages = defineMessages({ error: { id: 'bundle_modal_error.message', defaultMessage: 'Something went wrong while loading this page.' }, retry: { id: 'bundle_modal_error.retry', defaultMessage: 'Try again' }, close: { id: 'bundle_modal_error.close', defaultMessage: 'Close' }, }); interface IBundleModalError { onRetry: () => void, onClose: () => void, } const BundleModalError: React.FC = ({ onRetry, onClose }) => { const intl = useIntl(); const handleRetry = () => { onRetry(); }; return (
{intl.formatMessage(messages.error)}
); }; export default BundleModalError;