mario-core 2.9.217-release → 2.9.218-release
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/dist/containers/Login/components/ButtonLogin.d.ts +3 -0
- package/dist/containers/Login/constant/authConfig.d.ts +1 -2
- package/dist/containers/Login/constant/config.d.ts +6 -0
- package/dist/containers/Login/constant/types.d.ts +5 -0
- package/dist/index.js +15 -3
- package/dist/index.js.map +1 -1
- package/dist/index.modern.js +15 -3
- package/dist/index.modern.js.map +1 -1
- package/package.json +101 -101
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { LogLevel } from "@azure/msal-browser";
|
|
2
1
|
/**
|
|
3
2
|
* Configuration object to be passed to MSAL instance on creation.
|
|
4
3
|
* For a full list of MSAL.js configuration parameters, visit:
|
|
@@ -16,7 +15,7 @@ export declare const msalConfig: {
|
|
|
16
15
|
};
|
|
17
16
|
system: {
|
|
18
17
|
loggerOptions: {
|
|
19
|
-
loggerCallback: (level:
|
|
18
|
+
loggerCallback: (level: any, message: string, containsPii: any) => void;
|
|
20
19
|
};
|
|
21
20
|
};
|
|
22
21
|
};
|
package/dist/index.js
CHANGED
|
@@ -30117,6 +30117,14 @@ var getSchoolSettings = function getSchoolSettings() {
|
|
|
30117
30117
|
return api.get(SCHOOL_URL + "/settings");
|
|
30118
30118
|
};
|
|
30119
30119
|
|
|
30120
|
+
var LoginType;
|
|
30121
|
+
|
|
30122
|
+
(function (LoginType) {
|
|
30123
|
+
LoginType[LoginType["Default"] = 0] = "Default";
|
|
30124
|
+
LoginType[LoginType["Google"] = 1] = "Google";
|
|
30125
|
+
LoginType[LoginType["Impersonate"] = 2] = "Impersonate";
|
|
30126
|
+
})(LoginType || (LoginType = {}));
|
|
30127
|
+
|
|
30120
30128
|
var defaultInfo = {
|
|
30121
30129
|
email: "",
|
|
30122
30130
|
password: "",
|
|
@@ -30371,7 +30379,8 @@ var useLogin = function useLogin() {
|
|
|
30371
30379
|
isLoginGoogle: true,
|
|
30372
30380
|
rememberMe: false,
|
|
30373
30381
|
password: "default",
|
|
30374
|
-
accessToken: token
|
|
30382
|
+
accessToken: token,
|
|
30383
|
+
loginType: LoginType.Google
|
|
30375
30384
|
};
|
|
30376
30385
|
return Promise.resolve(userLogin(dataUser)).then(function () {
|
|
30377
30386
|
setIsLoginGoogle(false);
|
|
@@ -30428,7 +30437,8 @@ var useLogin = function useLogin() {
|
|
|
30428
30437
|
isLoginGoogle: true,
|
|
30429
30438
|
rememberMe: false,
|
|
30430
30439
|
password: "default",
|
|
30431
|
-
accessToken: infoUser.accessToken
|
|
30440
|
+
accessToken: infoUser.accessToken,
|
|
30441
|
+
loginType: LoginType.Google
|
|
30432
30442
|
};
|
|
30433
30443
|
setIsLoginGoogle(false);
|
|
30434
30444
|
return Promise.resolve(userLogin(dataLogin)).then(function () {
|
|
@@ -30727,6 +30737,7 @@ var BlockLogin = function BlockLogin(_ref) {
|
|
|
30727
30737
|
return Promise.resolve(clickHandler()).then(function (clickHandlerRes) {
|
|
30728
30738
|
if (!clickHandlerRes) return;
|
|
30729
30739
|
values.captcha = clickHandlerRes;
|
|
30740
|
+
values.loginType = LoginType.Default;
|
|
30730
30741
|
userLogin(values);
|
|
30731
30742
|
});
|
|
30732
30743
|
}, function (err) {
|
|
@@ -35165,7 +35176,8 @@ var useUserList = function useUserList() {
|
|
|
35165
35176
|
var req = {
|
|
35166
35177
|
email: data.email,
|
|
35167
35178
|
password: "default",
|
|
35168
|
-
accessToken: data.token
|
|
35179
|
+
accessToken: data.token,
|
|
35180
|
+
loginType: LoginType.Impersonate
|
|
35169
35181
|
};
|
|
35170
35182
|
return Promise.resolve(logIn(req)).then(function (res) {
|
|
35171
35183
|
localStorage.clear();
|