asb_cloud_front/src/components/SuspenseFallback.tsx
goodmice 60118f9327
* Публичные старницы перемещены в общую директорию
* SuspenseFallback перемещён в компоненты
* Добавлена ленивая загрузка основных страниц
2022-10-13 14:00:17 +05:00

18 lines
593 B
TypeScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

import { LoadingOutlined } from '@ant-design/icons'
import { CSSProperties, memo } from 'react'
import { Flex } from '@components/Grid'
export type SuspenseFallbackProps = {
style?: CSSProperties
}
export const SuspenseFallback = memo<SuspenseFallbackProps>(({ style }) => (
<Flex style={{ justifyContent: 'center', alignItems: 'center', minHeight: '400px', ...style }}>
<LoadingOutlined />
<div style={{ marginLeft: '10px' }}>Страница загружается, пожалуйста, подождите...</div>
</Flex>
))
export default SuspenseFallback