@frontegg/react-hooks 5.67.1 → 5.68.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.
package/index.js CHANGED
@@ -83,9 +83,11 @@ const FronteggStoreProvider = ({ children, app, contextOptions, setLoading: setL
83
83
  var _a, _b, _c, _d, _e, _f;
84
84
  const context = (_b = (_a = app === null || app === void 0 ? void 0 : app.options) === null || _a === void 0 ? void 0 : _a.contextOptions) !== null && _b !== void 0 ? _b : contextOptions;
85
85
  const previewMode = (_d = (_c = app === null || app === void 0 ? void 0 : app.options) === null || _c === void 0 ? void 0 : _c.previewMode) !== null && _d !== void 0 ? _d : false;
86
- const authOptions = (_f = (_e = app === null || app === void 0 ? void 0 : app.options) === null || _e === void 0 ? void 0 : _e.authOptions) !== null && _f !== void 0 ? _f : {};
86
+ const authOptions = ((_e = app === null || app === void 0 ? void 0 : app.options) === null || _e === void 0 ? void 0 : _e.authOptions) ? Object.assign(Object.assign({}, app.options.authOptions), { hostedLoginBox: app.options.hostedLoginBox }) : { hostedLoginBox: (_f = app === null || app === void 0 ? void 0 : app.options) === null || _f === void 0 ? void 0 : _f.hostedLoginBox };
87
87
  ContextHolder.setContext(context);
88
- const store = useMemo(() => createFronteggStore({ context: context }, app, previewMode, authOptions), [app, previewMode]);
88
+ const store = useMemo(() => createFronteggStore({
89
+ context: context
90
+ }, app, previewMode, authOptions), [app, previewMode]);
89
91
  return (React.createElement(Provider, { context: FronteggStoreContext, store: store },
90
92
  React.createElement(FronteggContent, { setLoading: setLoadingProps !== null && setLoadingProps !== void 0 ? setLoadingProps : setLoading, app: app }, children)));
91
93
  };
package/node/index.js CHANGED
@@ -88,9 +88,11 @@ const FronteggStoreProvider = ({ children, app, contextOptions, setLoading: setL
88
88
  var _a, _b, _c, _d, _e, _f;
89
89
  const context = (_b = (_a = app === null || app === void 0 ? void 0 : app.options) === null || _a === void 0 ? void 0 : _a.contextOptions) !== null && _b !== void 0 ? _b : contextOptions;
90
90
  const previewMode = (_d = (_c = app === null || app === void 0 ? void 0 : app.options) === null || _c === void 0 ? void 0 : _c.previewMode) !== null && _d !== void 0 ? _d : false;
91
- const authOptions = (_f = (_e = app === null || app === void 0 ? void 0 : app.options) === null || _e === void 0 ? void 0 : _e.authOptions) !== null && _f !== void 0 ? _f : {};
91
+ const authOptions = ((_e = app === null || app === void 0 ? void 0 : app.options) === null || _e === void 0 ? void 0 : _e.authOptions) ? Object.assign(Object.assign({}, app.options.authOptions), { hostedLoginBox: app.options.hostedLoginBox }) : { hostedLoginBox: (_f = app === null || app === void 0 ? void 0 : app.options) === null || _f === void 0 ? void 0 : _f.hostedLoginBox };
92
92
  restApi.ContextHolder.setContext(context);
93
- const store = React.useMemo(() => reduxStore.createFronteggStore({ context: context }, app, previewMode, authOptions), [app, previewMode]);
93
+ const store = React.useMemo(() => reduxStore.createFronteggStore({
94
+ context: context
95
+ }, app, previewMode, authOptions), [app, previewMode]);
94
96
  return (React__default['default'].createElement(reactRedux.Provider, { context: FronteggStoreContext.FronteggStoreContext, store: store },
95
97
  React__default['default'].createElement(FronteggContent, { setLoading: setLoadingProps !== null && setLoadingProps !== void 0 ? setLoadingProps : setLoading, app: app }, children)));
96
98
  };
package/package.json CHANGED
@@ -1,13 +1,13 @@
1
1
  {
2
2
  "name": "@frontegg/react-hooks",
3
3
  "libName": "FronteggReactHooks",
4
- "version": "5.67.1",
4
+ "version": "5.68.0",
5
5
  "author": "Frontegg LTD",
6
6
  "main": "./node/index.js",
7
7
  "module": "./index.js",
8
8
  "types": "./index.d.ts",
9
9
  "dependencies": {
10
- "@frontegg/redux-store": "5.67.1",
10
+ "@frontegg/redux-store": "5.68.0",
11
11
  "react-redux": "^7.x"
12
12
  }
13
13
  }