@genesislcap/foundation-login 14.67.5-alpha-e36b6f2.0 → 14.67.6-alpha-5078280.0
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.
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"sso.d.ts","sourceRoot":"","sources":["../../../src/utils/sso.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,GAAG,EAAe,MAAM,iBAAiB,CAAC;
|
|
1
|
+
{"version":3,"file":"sso.d.ts","sourceRoot":"","sources":["../../../src/utils/sso.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,GAAG,EAAe,MAAM,iBAAiB,CAAC;AAYxD;;;;GAIG;AACH,eAAO,MAAM,cAAc,oDAK1B,CAAC;AAEF;;;;GAIG;AACH,eAAO,MAAM,SAAS,oCAA+C,QAAQ,GAAG,EAAE,CAkBjF,CAAC"}
|
package/dist/esm/utils/sso.js
CHANGED
|
@@ -1,12 +1,13 @@
|
|
|
1
1
|
import { __awaiter } from "tslib";
|
|
2
2
|
import { API_HOST } from '@genesislcap/foundation-utils';
|
|
3
3
|
import { logger } from './logger';
|
|
4
|
-
const getAPIHostHTTPURL = (host = API_HOST) => {
|
|
4
|
+
const getAPIHostHTTPURL = (host = API_HOST, includePath = false) => {
|
|
5
5
|
const url = new URL(host);
|
|
6
6
|
const protocol = url.protocol.replace('ws', 'http');
|
|
7
|
-
|
|
7
|
+
const path = includePath ? url.pathname : '';
|
|
8
|
+
return `${protocol}//${url.host}${path}`;
|
|
8
9
|
};
|
|
9
|
-
const getIPDEndpoint = (path, host) => `${getAPIHostHTTPURL(host)}
|
|
10
|
+
const getIPDEndpoint = (path, host) => `${getAPIHostHTTPURL(host)}/${path}`;
|
|
10
11
|
/**
|
|
11
12
|
* Get SSO identity provider login URL
|
|
12
13
|
*
|
|
@@ -16,7 +17,7 @@ export const getSSOLoginURL = (idp, path = '/login?idp=', host = API_HOST) => {
|
|
|
16
17
|
if (!idp || !idp.type || !idp.id) {
|
|
17
18
|
throw new Error(`Invalid IDP: ${JSON.stringify(idp)}`);
|
|
18
19
|
}
|
|
19
|
-
return `${getAPIHostHTTPURL(host)}${idp.type}${path}${idp.id}`;
|
|
20
|
+
return `${getAPIHostHTTPURL(host, true)}${idp.type}${path}${idp.id}`;
|
|
20
21
|
};
|
|
21
22
|
/**
|
|
22
23
|
* Request SSO identity provider list
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@genesislcap/foundation-login",
|
|
3
3
|
"description": "Genesis Foundation Login",
|
|
4
|
-
"version": "14.67.
|
|
4
|
+
"version": "14.67.6-alpha-5078280.0",
|
|
5
5
|
"license": "SEE LICENSE IN license.txt",
|
|
6
6
|
"main": "dist/esm/index.js",
|
|
7
7
|
"types": "dist/foundation-login.d.ts",
|
|
@@ -49,15 +49,15 @@
|
|
|
49
49
|
"test:debug": "genx test --debug"
|
|
50
50
|
},
|
|
51
51
|
"devDependencies": {
|
|
52
|
-
"@genesislcap/foundation-testing": "14.67.
|
|
53
|
-
"@genesislcap/genx": "14.67.
|
|
52
|
+
"@genesislcap/foundation-testing": "14.67.6-alpha-5078280.0",
|
|
53
|
+
"@genesislcap/genx": "14.67.6-alpha-5078280.0",
|
|
54
54
|
"rimraf": "^3.0.2"
|
|
55
55
|
},
|
|
56
56
|
"dependencies": {
|
|
57
|
-
"@genesislcap/foundation-comms": "14.67.
|
|
58
|
-
"@genesislcap/foundation-ui": "14.67.
|
|
59
|
-
"@genesislcap/foundation-utils": "14.67.
|
|
60
|
-
"@genesislcap/foundation-zero": "14.67.
|
|
57
|
+
"@genesislcap/foundation-comms": "14.67.6-alpha-5078280.0",
|
|
58
|
+
"@genesislcap/foundation-ui": "14.67.6-alpha-5078280.0",
|
|
59
|
+
"@genesislcap/foundation-utils": "14.67.6-alpha-5078280.0",
|
|
60
|
+
"@genesislcap/foundation-zero": "14.67.6-alpha-5078280.0",
|
|
61
61
|
"@microsoft/fast-components": "^2.21.3",
|
|
62
62
|
"@microsoft/fast-element": "^1.7.0",
|
|
63
63
|
"@microsoft/fast-foundation": "^2.33.2",
|
|
@@ -74,5 +74,5 @@
|
|
|
74
74
|
"access": "public"
|
|
75
75
|
},
|
|
76
76
|
"customElements": "dist/custom-elements.json",
|
|
77
|
-
"gitHead": "
|
|
77
|
+
"gitHead": "5ce5fb745fcd8818f0ffefded064c36b44388a5c"
|
|
78
78
|
}
|