New: Improved page loading errors

Closes #2605
This commit is contained in:
Bogdan
2023-06-17 00:50:29 +03:00
parent 3a3cf8511e
commit 53ced38221
15 changed files with 65 additions and 47 deletions
+5 -4
View File
@@ -1,5 +1,6 @@
import PropTypes from 'prop-types';
import React, { Component } from 'react';
import Alert from 'Components/Alert';
import LoadingIndicator from 'Components/Loading/LoadingIndicator';
import ConfirmModal from 'Components/Modal/ConfirmModal';
import PageContent from 'Components/Page/PageContent';
@@ -161,16 +162,16 @@ class Blocklist extends Component {
{
!isAnyFetching && !!error &&
<div>
<Alert kind={kinds.DANGER}>
{translate('UnableToLoadBlocklist')}
</div>
</Alert>
}
{
isAllPopulated && !error && !items.length &&
<div>
<Alert kind={kinds.INFO}>
{translate('NoHistoryBlocklist')}
</div>
</Alert>
}
{