authscape 1.0.27 → 1.0.30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json
CHANGED
package/services/authService.js
CHANGED
|
@@ -65,12 +65,12 @@ const authService = () => {
|
|
|
65
65
|
let url = "";
|
|
66
66
|
if (redirectUrl == null)
|
|
67
67
|
{
|
|
68
|
-
url = AuthUri + "/Account/Register?
|
|
68
|
+
url = AuthUri + "/Account/Register?returnUrl=" + window.location.href;
|
|
69
69
|
localStorage.setItem("redirectUri", window.location.href);
|
|
70
70
|
}
|
|
71
71
|
else
|
|
72
72
|
{
|
|
73
|
-
url = AuthUri + "/Account/Register?
|
|
73
|
+
url = AuthUri + "/Account/Register?returnUrl=" + redirectUrl;
|
|
74
74
|
localStorage.setItem("redirectUri", redirectUrl);
|
|
75
75
|
}
|
|
76
76
|
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import React, { useEffect, useState, useRef } from 'react';
|
|
2
2
|
import apiService from './apiService';
|
|
3
|
+
import Backdrop from '@mui/material/Backdrop';
|
|
4
|
+
import CircularProgress from '@mui/material/CircularProgress';
|
|
3
5
|
|
|
4
|
-
export default function AuthorizationComponent({children, setCurrentUser, userLoaded}) {
|
|
6
|
+
export default function AuthorizationComponent({children, setCurrentUser, userLoaded, isLoading}) {
|
|
5
7
|
|
|
6
8
|
const [loaded, setLoaded] = useState(false);
|
|
7
|
-
|
|
8
|
-
|
|
9
9
|
const validateUserSignedIn = async () => {
|
|
10
10
|
|
|
11
11
|
setLoaded(true);
|
|
@@ -32,5 +32,12 @@ export default function AuthorizationComponent({children, setCurrentUser, userLo
|
|
|
32
32
|
|
|
33
33
|
}, [loaded]);
|
|
34
34
|
|
|
35
|
-
return (
|
|
35
|
+
return (
|
|
36
|
+
<>
|
|
37
|
+
{children}
|
|
38
|
+
<Backdrop sx={{ color: '#fff', zIndex: 99999 }} open={isLoading}>
|
|
39
|
+
<CircularProgress color="inherit" />
|
|
40
|
+
</Backdrop>
|
|
41
|
+
</>
|
|
42
|
+
)
|
|
36
43
|
}
|