@frontegg/redux-store 6.77.0 → 6.78.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,10 +1,11 @@
1
- import { ILoginViaSocialLogin, ISocialLoginProviderConfiguration, ISocialLoginProviderConfigurationV2 } from '@frontegg/rest-api';
1
+ import { ICustomSocialLoginProviderConfigurationV1, ILoginViaSocialLogin, ISocialLoginProviderConfiguration, ISocialLoginProviderConfigurationV2 } from '@frontegg/rest-api';
2
2
  import { CustomEventsOptions } from '../interfaces';
3
3
  export interface SocialLoginState {
4
4
  firstLoad: boolean;
5
5
  loading: boolean;
6
6
  socialLoginsConfig?: ISocialLoginProviderConfiguration[];
7
7
  socialLoginsConfigV2?: ISocialLoginProviderConfigurationV2[];
8
+ customSocialLoginsConfig?: ICustomSocialLoginProviderConfigurationV1['providers'];
8
9
  error?: string;
9
10
  }
10
11
  export interface ILoginViaSocialLoginPayload extends ILoginViaSocialLogin {
@@ -1,4 +1,4 @@
1
- import { ContextOptions, ISocialLoginProviderConfiguration, ISocialLoginProviderConfigurationV2 } from '@frontegg/rest-api';
1
+ import { ContextOptions, ICustomSocialLoginProviderConfigurationV1, ISocialLoginProviderConfiguration, ISocialLoginProviderConfigurationV2 } from '@frontegg/rest-api';
2
2
  export declare function loadSocialLoginsConfigurations(): Generator<import("redux-saga/effects").PutEffect<{
3
3
  payload: Partial<import("./interfaces").SocialLoginState>;
4
4
  type: string;
@@ -6,5 +6,5 @@ export declare function loadSocialLoginsConfigurations(): Generator<import("redu
6
6
  export declare function loadSocialLoginsConfigurationsV2(): Generator<import("redux-saga/effects").SelectEffect | import("redux-saga/effects").PutEffect<{
7
7
  payload: Partial<import("./interfaces").SocialLoginState>;
8
8
  type: string;
9
- }> | import("redux-saga/effects").CallEffect<ISocialLoginProviderConfigurationV2[]>, void, ContextOptions & ISocialLoginProviderConfigurationV2[]>;
9
+ }> | import("redux-saga/effects").CallEffect<ISocialLoginProviderConfigurationV2[]> | import("redux-saga/effects").CallEffect<ICustomSocialLoginProviderConfigurationV1>, void, ContextOptions & ISocialLoginProviderConfigurationV2[] & ICustomSocialLoginProviderConfigurationV1>;
10
10
  export declare function socialLoginsSaga(): Generator<import("redux-saga/effects").ForkEffect<never>, void, unknown>;
@@ -34,6 +34,9 @@ export function* loadSocialLoginsConfigurationsV2() {
34
34
  loading: true
35
35
  }));
36
36
  const socialLoginsConfigV2 = yield call(api.auth.getSocialLoginProvidersV2);
37
+ const {
38
+ providers: customSocialLoginsConfig
39
+ } = yield call(api.auth.getCustomSocialLoginProvidersV1);
37
40
  const socialLoginsConfigWithFullUrl = socialLoginsConfigV2.map(_ref => {
38
41
  let {
39
42
  authorizationUrl
@@ -46,6 +49,7 @@ export function* loadSocialLoginsConfigurationsV2() {
46
49
  });
47
50
  yield put(actions.setSocialLoginsState({
48
51
  socialLoginsConfigV2: socialLoginsConfigWithFullUrl,
52
+ customSocialLoginsConfig,
49
53
  loading: false,
50
54
  firstLoad: false
51
55
  }));
package/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license Frontegg v6.77.0
1
+ /** @license Frontegg v6.78.0
2
2
  *
3
3
  * This source code is licensed under the MIT license found in the
4
4
  * LICENSE file in the root directory of this source tree.
@@ -43,6 +43,9 @@ function* loadSocialLoginsConfigurationsV2() {
43
43
  loading: true
44
44
  }));
45
45
  const socialLoginsConfigV2 = yield (0, _effects.call)(_restApi.api.auth.getSocialLoginProvidersV2);
46
+ const {
47
+ providers: customSocialLoginsConfig
48
+ } = yield (0, _effects.call)(_restApi.api.auth.getCustomSocialLoginProvidersV1);
46
49
  const socialLoginsConfigWithFullUrl = socialLoginsConfigV2.map(_ref => {
47
50
  let {
48
51
  authorizationUrl
@@ -55,6 +58,7 @@ function* loadSocialLoginsConfigurationsV2() {
55
58
  });
56
59
  yield (0, _effects.put)(_reducer.actions.setSocialLoginsState({
57
60
  socialLoginsConfigV2: socialLoginsConfigWithFullUrl,
61
+ customSocialLoginsConfig,
58
62
  loading: false,
59
63
  firstLoad: false
60
64
  }));
package/node/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license Frontegg v6.77.0
1
+ /** @license Frontegg v6.78.0
2
2
  *
3
3
  * This source code is licensed under the MIT license found in the
4
4
  * LICENSE file in the root directory of this source tree.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@frontegg/redux-store",
3
- "version": "6.77.0",
3
+ "version": "6.78.0",
4
4
  "main": "./node/index.js",
5
5
  "license": "MIT",
6
6
  "author": "Frontegg LTD",