0
Fork 0
mirror of https://github.com/logto-io/logto.git synced 2025-02-17 22:04:19 -05:00

fix(console): center align image and error message in error boundary

This commit is contained in:
Charles Zhao 2022-04-18 16:28:12 +08:00
parent 975ed6b6c3
commit 9dcfd0efaf
No known key found for this signature in database
GPG key ID: 4858774754C92DF2
2 changed files with 4 additions and 4 deletions

View file

@ -24,7 +24,7 @@
img, img,
h2 { h2 {
align-self: flex-end; align-self: center;
} }
details { details {

View file

@ -1,6 +1,6 @@
import { conditional } from '@silverhand/essentials'; import { conditional } from '@silverhand/essentials';
import React, { Component, ReactNode } from 'react'; import React, { Component, ReactNode } from 'react';
import { Namespace, TFunction, withTranslation } from 'react-i18next'; import { TFunction, withTranslation } from 'react-i18next';
import ErrorImage from '@/assets/images/table-error.svg'; import ErrorImage from '@/assets/images/table-error.svg';
@ -8,7 +8,7 @@ import * as styles from './index.module.scss';
type Props = { type Props = {
children: ReactNode; children: ReactNode;
t: TFunction<Namespace, 'admin_console'>; t: TFunction;
}; };
type State = { type State = {
@ -48,7 +48,7 @@ class ErrorBoundary extends Component<Props, State> {
<div className={styles.container}> <div className={styles.container}>
<div className={styles.wrapper}> <div className={styles.wrapper}>
<img src={ErrorImage} alt="oops" /> <img src={ErrorImage} alt="oops" />
<h2>{t('errors.something_went_wrong')}</h2> <h2>{t('admin_console.errors.something_went_wrong')}</h2>
<details open> <details open>
<summary>{errorMessage}</summary> <summary>{errorMessage}</summary>
{callStack} {callStack}