File tree 1 file changed +7
-6
lines changed
packages/ra-ui-materialui/src/layout
1 file changed +7
-6
lines changed Original file line number Diff line number Diff line change @@ -2,19 +2,19 @@ import * as React from 'react';
2
2
import PropTypes from 'prop-types' ;
3
3
import classNames from 'classnames' ;
4
4
import { useSelector } from 'react-redux' ;
5
- import { makeStyles } from '@material-ui/core/styles' ;
5
+ import { makeStyles , useTheme } from '@material-ui/core/styles' ;
6
6
import CircularProgress from '@material-ui/core/CircularProgress' ;
7
7
import { useRefreshWhenVisible } from 'ra-core' ;
8
8
9
9
import RefreshIconButton from '../button/RefreshIconButton' ;
10
10
11
11
const useStyles = makeStyles (
12
- {
12
+ theme => ( {
13
13
loader : {
14
- margin : 14 ,
14
+ margin : theme . spacing ( 2 ) ,
15
15
} ,
16
16
loadedIcon : { } ,
17
- } ,
17
+ } ) ,
18
18
{ name : 'RaLoadingIndicator' }
19
19
) ;
20
20
@@ -23,12 +23,13 @@ const LoadingIndicator = props => {
23
23
useRefreshWhenVisible ( ) ;
24
24
const loading = useSelector ( state => state . admin . loading > 0 ) ;
25
25
const classes = useStyles ( props ) ;
26
+ const theme = useTheme ( ) ;
26
27
return loading ? (
27
28
< CircularProgress
28
29
className = { classNames ( 'app-loader' , classes . loader , className ) }
29
30
color = "inherit"
30
- size = { 18 }
31
- thickness = { 5 }
31
+ size = { theme . spacing ( 2 ) }
32
+ thickness = { 6 }
32
33
{ ...rest }
33
34
/>
34
35
) : (
You can’t perform that action at this time.
0 commit comments