@frontegg/react-hooks 6.102.0 → 6.103.0-alpha.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.
@@ -0,0 +1,9 @@
1
+ import { IAllAccountsState, AllAccountsActions, IAllAccountsDialogsState, AllAccountsDialogsActions } from '@frontegg/redux-store';
2
+ export declare type AllAccountsStateMapper<S> = (state: IAllAccountsState) => S;
3
+ export declare function useAllAccountsState(): IAllAccountsState;
4
+ export declare function useAllAccountsState<S>(stateMapper: AllAccountsStateMapper<S>): S;
5
+ export declare const useAllAccountsActions: () => AllAccountsActions;
6
+ export declare type AllAccountsDialogsStateMapper<S> = (state: IAllAccountsDialogsState) => S;
7
+ export declare function useAllAccountsDialogsState(): IAllAccountsDialogsState;
8
+ export declare function useAllAccountsDialogsState<S>(stateMapper: AllAccountsDialogsStateMapper<S>): S;
9
+ export declare const useAllAccountsDialogsActions: () => AllAccountsDialogsActions;
@@ -0,0 +1,15 @@
1
+ import { allAccountsActions, allAccountsReducers, allAccountsDialogsReducers } from '@frontegg/redux-store';
2
+ import { reducerActionsGenerator, stateHookGenerator } from '../hooks';
3
+ const defaultMapper = state => state;
4
+ export function useAllAccountsState(stateMapper = defaultMapper) {
5
+ return stateHookGenerator(stateMapper, 'allAccountsState');
6
+ }
7
+ export const useAllAccountsActions = () => reducerActionsGenerator(allAccountsActions, allAccountsReducers);
8
+
9
+ //dialogs
10
+
11
+ const defaultDialogsMapper = state => state;
12
+ export function useAllAccountsDialogsState(stateMapper = defaultDialogsMapper) {
13
+ return stateHookGenerator(stateMapper, 'allAccountsDialogsState');
14
+ }
15
+ export const useAllAccountsDialogsActions = () => reducerActionsGenerator({}, allAccountsDialogsReducers);
package/auth/index.d.ts CHANGED
@@ -22,3 +22,4 @@ export * from './impersonate';
22
22
  export * from './passkeys';
23
23
  export * from './groups';
24
24
  export * from './customLogin';
25
+ export * from './MSP/allAccounts';
package/auth/index.js CHANGED
@@ -21,4 +21,5 @@ export * from './provisioning';
21
21
  export * from './impersonate';
22
22
  export * from './passkeys';
23
23
  export * from './groups';
24
- export * from './customLogin';
24
+ export * from './customLogin';
25
+ export * from './MSP/allAccounts';
package/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license Frontegg v6.102.0
1
+ /** @license Frontegg v6.103.0-alpha.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.
@@ -0,0 +1,24 @@
1
+ "use strict";
2
+
3
+ Object.defineProperty(exports, "__esModule", {
4
+ value: true
5
+ });
6
+ exports.useAllAccountsDialogsActions = exports.useAllAccountsActions = void 0;
7
+ exports.useAllAccountsDialogsState = useAllAccountsDialogsState;
8
+ exports.useAllAccountsState = useAllAccountsState;
9
+ var _reduxStore = require("@frontegg/redux-store");
10
+ var _hooks = require("../hooks");
11
+ const defaultMapper = state => state;
12
+ function useAllAccountsState(stateMapper = defaultMapper) {
13
+ return (0, _hooks.stateHookGenerator)(stateMapper, 'allAccountsState');
14
+ }
15
+ const useAllAccountsActions = () => (0, _hooks.reducerActionsGenerator)(_reduxStore.allAccountsActions, _reduxStore.allAccountsReducers);
16
+
17
+ //dialogs
18
+ exports.useAllAccountsActions = useAllAccountsActions;
19
+ const defaultDialogsMapper = state => state;
20
+ function useAllAccountsDialogsState(stateMapper = defaultDialogsMapper) {
21
+ return (0, _hooks.stateHookGenerator)(stateMapper, 'allAccountsDialogsState');
22
+ }
23
+ const useAllAccountsDialogsActions = () => (0, _hooks.reducerActionsGenerator)({}, _reduxStore.allAccountsDialogsReducers);
24
+ exports.useAllAccountsDialogsActions = useAllAccountsDialogsActions;
@@ -337,4 +337,16 @@ Object.keys(_customLogin).forEach(function (key) {
337
337
  return _customLogin[key];
338
338
  }
339
339
  });
340
+ });
341
+ var _allAccounts = require("./MSP/allAccounts");
342
+ Object.keys(_allAccounts).forEach(function (key) {
343
+ if (key === "default" || key === "__esModule") return;
344
+ if (Object.prototype.hasOwnProperty.call(_exportNames, key)) return;
345
+ if (key in exports && exports[key] === _allAccounts[key]) return;
346
+ Object.defineProperty(exports, key, {
347
+ enumerable: true,
348
+ get: function () {
349
+ return _allAccounts[key];
350
+ }
351
+ });
340
352
  });
package/node/index.js CHANGED
@@ -1,4 +1,4 @@
1
- /** @license Frontegg v6.102.0
1
+ /** @license Frontegg v6.103.0-alpha.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,13 +1,13 @@
1
1
  {
2
2
  "name": "@frontegg/react-hooks",
3
- "version": "6.102.0",
3
+ "version": "6.103.0-alpha.0",
4
4
  "main": "./node/index.js",
5
5
  "license": "MIT",
6
6
  "author": "Frontegg LTD",
7
7
  "dependencies": {
8
8
  "@babel/runtime": "^7.18.6",
9
- "@frontegg/redux-store": "6.102.0",
10
- "@frontegg/types": "6.102.0",
9
+ "@frontegg/redux-store": "6.103.0-alpha.0",
10
+ "@frontegg/types": "6.103.0-alpha.0",
11
11
  "@types/react": "*",
12
12
  "get-value": "^3.0.1",
13
13
  "react-redux": "^7.x"