mirror of https://github.com/micromata/borgbackup-butler.git

Kai Reinhard
09.44.2019 3aecd74a7982ebea9ab5ac10ee8847e7268cd982
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
import React from 'react';
import PropTypes from 'prop-types';
import styles from './LoadingOverlay.module.css'
import {IconSpinner} from '../IconComponents';
 
function LoadingOverlay({active}) {
    if (!active) {
        return <React.Fragment />;
    }
 
    return (
        <div className={styles.loadingOverlay}>
            <div className={styles.content}>
                <IconSpinner />
            </div>
        </div>
    );
}
 
LoadingOverlay.propTypes = {
    active: PropTypes.bool
};
 
LoadingOverlay.defaultProps = {
    active: false
};
 
export default LoadingOverlay;