@frontegg/vue 3.0.37 → 4.0.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/dist/StoreHolder.d.ts +3 -3
- package/dist/auth/mapAuthState.d.ts +171 -162
- package/dist/auth/service.d.ts +4 -6
- package/dist/index.js +19 -27
- package/dist/index.min.js +1 -1
- package/dist/index.ssr.js +18 -28
- package/dist/interfaces.d.ts +2 -5
- package/dist/types.d.ts +18 -20
- package/dist/utils.d.ts +3 -3
- package/package.json +2 -2
- package/dist/reducer.d.ts +0 -17
package/dist/StoreHolder.d.ts
CHANGED
|
@@ -1,11 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { FronteggStore } from '@frontegg/redux-store';
|
|
2
2
|
export declare class StoreHolder {
|
|
3
3
|
private static instance;
|
|
4
4
|
private store;
|
|
5
5
|
private baseName;
|
|
6
6
|
private static getInstance;
|
|
7
|
-
static setStore(store:
|
|
8
|
-
static getStore():
|
|
7
|
+
static setStore(store: FronteggStore): void;
|
|
8
|
+
static getStore(): FronteggStore;
|
|
9
9
|
static setBasename(baseName: string | undefined): void;
|
|
10
10
|
static getBasename(): string | undefined;
|
|
11
11
|
}
|
|
@@ -20,285 +20,294 @@ export declare const connectMapState: (_this: any) => void;
|
|
|
20
20
|
declare type MapLoginActions = LoginActions & {
|
|
21
21
|
loginWithRedirect: LoginActions['requestHostedLoginAuthorize'];
|
|
22
22
|
};
|
|
23
|
-
export declare const mapAuthActions: <K extends "requestHostedLoginAuthorize" | "setState" | "resetState" | "setUser" | "setEntitlements" | "loadEntitlements" | "setLoginState" | "resetLoginState" | "requestAuthorize" | "requestAuthorizeSSR" | "requestHostedLoginAuthorizeV2" | "handleHostedLoginCallback" | "afterAuthNavigation" | "preLogin" | "postLogin" | "login" | "loginWithMfa" | "recoverMfa" | "logout" | "silentLogout" | "checkIfAllowToRememberMfaDevice" | "changePhoneNumberWithVerification" | "verifyChangePhoneNumber" | "quickSmsPasswordlessPreLogin" | "passwordlessPreLogin" | "passwordlessPostLogin" | "verifyInviteToken" | "webAuthnPrelogin" | "webAuthnPostLogin" | "webAuthnCreateNewDeviceSession" | "webAuthnVerifyNewDeviceSession" | "getUserIP" | "preEnrollMFAWebAuthnForLogin" | "enrollMFAWebAuthnForLogin" | "enrollMFAAuthenticatorAppForLogin" | "preEnrollMFASMSForLogin" | "enrollMFASMSForLogin" | "preVerifyMFAWebAuthnForLogin" | "verifyMFAWebAuthnForLogin" | "preVerifyMFASMSForLogin" | "verifyMFASMSForLogin" | "preVerifyMFAEmailCode" | "verifyMFAEmailCode" | "resetBreachedPassword" | "setStepUpState" | "resetStepUpState" | "generateStepUpSession" | "stepUpHostedLogin" | "stepUpWithAuthenticator" | "preVerifyMFASMSForStepUp" | "verifyMFASMSForStepUp" | "preVerifyMFAWebAuthnForStepUp" | "verifyMFAWebAuthnForStepUp" | "preVerifyMFAEmailCodeForStepUp" | "verifyMFAEmailCodeForStepUp" | "setSocialLoginsState" | "resetSocialLoginsState" | "loadSocialLoginsConfiguration" | "loadSocialLoginsConfigurationV2" | "loginViaSocialLogin" | "setSocialLoginError" | "setActivateState" | "resetActivateState" | "setActivateStrategyState" | "activateAccount" | "preActivateAccount" | "resendActivationEmail" | "getActivateAccountStrategy" | "setImpersonateState" | "resetImpersonateState" | "impersonate" | "setAcceptInvitationState" | "resetAcceptInvitationState" | "acceptInvitation" | "setForgotPasswordState" | "resetForgotPasswordState" | "forgotPassword" | "resetPassword" | "loadPasswordConfig" | "setResetPhoneNumberState" | "resetResetPhoneNumberState" | "resetPhoneNumber" | "verifyResetPhoneNumber" | "changePhoneNumber" | "setSignUpState" | "resetSignUpState" | "signUpUser" | "resetSignUpStateSoft" | "setProfileState" | "resetProfileState" | "loadProfile" | "saveProfile" | "changePassword" | "setCustomLoginState" | "resetCustomLoginState" | "loadTenantMetadata" | "updateTenantMetadata" | "setApplicationsState" | "loadUserApplications" | "loadAccountApplications" | "assignUserToApps" | "unassignUserFromApps" | "loadSSOConfigurationsV2" | "saveSSOConfigurationV2" | "updateSSOConfiguration" | "deleteSSOConfiguration" | "deleteSSODomain" | "saveSSODomain" | "validateSSODomainV2" | "setSSODefaultRoles" | "setSSOGroups" | "updateSSOGroups" | "saveSSOConfigurationByMetadata" | "updateSSOConfigurationByMetadata" | "saveSSOConfigurationByData" | "saveSSOConfigurationByUrl" | "setSSOLoader" | "setSSOError" | "setSSOState" | "resetSSOState" | "loadSSOConfigurations" | "loadSSOAuthorizationRoles" | "saveSSOConfigurations" | "saveSSOConfigurationsFile" | "saveSSOConfigurationsFileWithCallback" | "validateSSODomain" | "updateSSOAuthorizationRoles" | "deleteSamlGroup" | "createSamlGroup" | "oidcPostlogin" | "setMfaState" | "resetMfaState" | "enrollMfa" | "getMFADevices" | "getMFAStrategies" | "verifyMfa" | "verifyMfaAfterForce" | "disableMfa" | "preDisableMfaSms" | "disableMfaSms" | "preEnrollMfaSms" | "enrollMfaSms" | "preEnrollMfaWebAuthn" | "enrollMfaWebAuthn" | "preDisableMfaWebAuthn" | "disableMfaWebAuthn" | "setTeamLoader" | "setTeamError" | "setTeamState" | "resetTeamState" | "loadUsersV2" | "loadUsers" | "loadAllSubTenantsUsers" | "loadRoles" | "addUsersBulk" | "addUser" | "addUserToSubTenants" | "setUserRolesForSubTenants" | "updateUser" | "deleteUser" | "enableUser" | "disableUser" | "deleteUserFromSubTenants" | "lockUser" | "resendActivationLink" | "resendInvitationLink" | "resendInvitationEmail" | "resendInvitationLinkToAllSubTenants" | "getTemporaryUsersConfig" | "updateUserExpirationTime" | "setUserAsPermanent" | "getInvitationLink" | "createInvitationLink" | "updateInvitationLink" | "deleteInvitationLink" | "openAddUserDialog" | "closeAddUserDialog" | "openDeleteUserDialog" | "closeDeleteUserDialog" | "openLockUserDialog" | "closeLockUserDialog" | "setUsersGroupsLoader" | "setUsersGroupsError" | "setGroupsState" | "resetUsersGroupsState" | "loadGroups" | "getGroupById" | "createGroup" | "updateGroup" | "deleteGroup" | "addRolesToGroup" | "deleteRolesFromGroup" | "addUsersToGroup" | "deleteUsersFromGroup" | "getGroupConfiguration" | "updateGroupConfiguration" | "getTeamUsers" | "setGroupsDialogsState" | "resetGroupsDialogsState" | "openAddGroupDialog" | "openAddMembersToGroupDialog" | "openEditGroupDialog" | "openDeleteGroupDialog" | "openDeleteMemberFromGroupDialog" | "closeAddGroupDialog" | "closeAddMembersToGroupDialog" | "closeEditGroupDialog" | "closeDeleteGroupDialog" | "closeDeleteMemberFromGroupDialog" | "setApiTokensLoader" | "setApiTokensError" | "setApiTokensState" | "resetApiTokensState" | "loadApiTokens" | "loadUserApiTokens" | "loadTenantApiTokens" | "initApiTokensData" | "addTenantApiToken" | "addUserApiToken" | "deleteUserApiToken" | "deleteTenantApiToken" | "setSecurityPolicyState" | "setSecurityPolicyGlobalState" | "setSecurityPolicyPublicState" | "setSecurityPolicyMfaState" | "setSecurityPolicyVendorMfaState" | "setSecurityPolicyLockoutState" | "setSecurityPolicyVendorLockoutState" | "setSecurityPolicyCaptchaState" | "setSecurityPolicyPasswordHistoryState" | "setSecurityPolicyVendorPasswordHistoryState" | "resetSecurityPolicyState" | "setSecurityPolicyPasswordState" | "setSecurityPolicyAuthStrategyPublicState" | "loadSecurityPolicy" | "loadPublicSecurityPolicy" | "loadVendorPasswordConfig" | "loadSecurityPolicyMfa" | "loadSecurityPolicyVendorMfa" | "saveSecurityPolicyMfa" | "loadSecurityPolicyLockout" | "loadSecurityPolicyVendorLockout" | "saveSecurityPolicyLockout" | "loadSecurityPolicyCaptcha" | "loadSecurityPolicyPasswordHistory" | "loadSecurityPolicyVendorPasswordHistory" | "saveSecurityPolicyPasswordHistory" | "loadPublicAuthStrategiesPolicy" | "setAccountSettingsState" | "resetAccountSettingsState" | "loadAccountSettings" | "saveAccountSettings" | "setTenantsState" | "resetTenantsState" | "switchTenant" | "loadTenants" | "loadSubTenants" | "loadSubTenantsTree" | "setRolesState" | "resetRolesState" | "setRolesStateLoader" | "setRolesStateError" | "loadRolesAndPermissions" | "addRole" | "addRoleV2" | "updateRole" | "deleteRole" | "attachPermissionsToRole" | "loadUserSessions" | "loadCurrentUserSession" | "setSessionsState" | "resetSessionsState" | "deleteUserSession" | "deleteAllUserSessions" | "revokeUserSessions" | "setRestrictionsState" | "setIpRestrictionsState" | "loadIpRestrictions" | "saveIpRestriction" | "saveIpRestrictionsConfig" | "deleteIpRestriction" | "checkIfUserIpValid" | "addCurrentUserIpAndActivate" | "setEmailDomainRestrictionsState" | "loadEmailDomainRestrictions" | "saveEmailDomainRestriction" | "saveEmailDomainRestrictionsConfig" | "deleteEmailDomainRestriction" | "setProvisioningState" | "resetProvisioningState" | "loadProvisionConnections" | "createProvisionConnection" | "deleteProvisionConnection" | "updateProvisionConnection" | "setPasskeysState" | "resetPasskeysState" | "loadWebAuthnDevices" | "deleteWebAuthnDevice" | "setAllAccountsLoader" | "setAllAccountsError" | "setAllAccountsState" | "setSelectedAccountState" | "resetAllAccountsState" | "loadAccounts" | "searchAccounts" | "updateSubAccountAccessForUser" | "createSubAccount" | "updateSubAccount" | "deleteSubAccount" | "updateSubAccountSettings" | "updateSubAccountManagement" | "updateSubAccountHierarchySettings" | "addUsersToAccount" | "getAccountUsers" | "deleteUsersFromAccount" | "setUserRolesForSubAccount" | "getUserJwtForSubAccount" | "setRootAccountData" | "setSelectedSubAccountData" | "loadNumberOfUsersForSelectedSubAccount" | "setAllAccountDialogsState" | "resetAllAccountDialogsState" | "openCreateSubAccountDialog" | "closeCreateSubAccountDialog" | "openUpdateSubAccountDialog" | "closeUpdateSubAccountDialog" | "openUpdateSubAccountHierarchySettingsDialog" | "closeUpdateSubAccountHierarchySettingsDialog" | "openEnableSubAccountManagementDialog" | "closeEnableSubAccountManagementDialog" | "openDisableSubAccountManagementDialog" | "closeDisableSubAccountManagementDialog" | "openDeleteSubAccountDialog" | "closeDeleteSubAccountDialog" | "openAddUsersToAccountDialog" | "closeAddUsersToAccountDialog" | "openDeleteUserFromAccountDialog" | "closeDeleteUserFromAccountDialog" | "openEditUserRolesDialog" | "closeEditUserRolesDialog" | "setSecurityCenterState" | "resetSecurityCenterState" | "setSecurityCenterStateLoader" | "setSecurityCenterStateError" | "loadRecommendations" | "loadInsights" | "sendResetBreachedPasswordEmail" | "sendBulkResetBreachedPasswordEmails" | "loadBreachedPasswordUsers" | "loadUnenrolledMfaUsers" | "loadInactiveUsers" | "setSmsState" | "resetSmsState" | "loadPhoneNumbers" | "setUpPhoneNumber" | "verifyPhoneNumber" | "deletePhoneNumber" | "verifyDeletePhoneNumber" | "preVerifyPhoneNumber">(action: K) => AuthActions[K];
|
|
24
|
-
export declare const mapLoginActions: <K extends "requestHostedLoginAuthorize" | "
|
|
23
|
+
export declare const mapAuthActions: <K extends "requestHostedLoginAuthorize" | "setState" | "setAuthState" | "resetAuthState" | "setUser" | "setAcceptInvitationState" | "resetAcceptInvitationState" | "acceptInvitation" | "setAccountSettingsState" | "resetAccountSettingsState" | "saveAccountSettings" | "loadAccountSettings" | "setActivateState" | "resetActivateState" | "setActivateStrategyState" | "activateAccount" | "preActivateAccount" | "getActivateAccountStrategy" | "resendActivationEmail" | "setApiTokensLoader" | "setApiTokensError" | "setApiTokensState" | "resetApiTokensState" | "loadApiTokens" | "loadUserApiTokens" | "loadTenantApiTokens" | "addTenantApiToken" | "addUserApiToken" | "deleteUserApiToken" | "deleteTenantApiToken" | "setApplicationsState" | "resetApplicationsState" | "loadUserApplications" | "loadAccountApplications" | "loadMultipleUsersApplications" | "assignUserToApps" | "unassignUserFromApps" | "assignNewUserToApps" | "mapUsersWithApplicationData" | "setCustomLoginState" | "resetCustomLoginState" | "loadTenantMetadata" | "updateTenantMetadata" | "customLoginEnabled" | "loadCustomLoginRoutes" | "setEntitlements" | "handleFetchedEntitlements" | "loadEntitlements" | "setForgotPasswordState" | "resetForgotPasswordState" | "forgotPassword" | "resetPassword" | "loadPasswordConfig" | "setUsersGroupsLoader" | "setUsersGroupsError" | "setGroupsState" | "resetUsersGroupsState" | "loadGroups" | "getGroupById" | "createGroup" | "updateGroup" | "deleteGroup" | "addRolesToGroup" | "deleteRolesFromGroup" | "addUsersToGroup" | "deleteUsersFromGroup" | "getGroupConfiguration" | "updateGroupConfiguration" | "getTeamUsers" | "setGroupsDialogsState" | "resetGroupsDialogsState" | "openAddGroupDialog" | "closeAddGroupDialog" | "openAddMembersToGroupDialog" | "closeAddMembersToGroupDialog" | "openEditGroupDialog" | "closeEditGroupDialog" | "openDeleteGroupDialog" | "closeDeleteGroupDialog" | "openDeleteMemberFromGroupDialog" | "closeDeleteMemberFromGroupDialog" | "setImpersonateState" | "resetImpersonateState" | "impersonate" | "preVerifyMFAWebAuthn" | "verifyMFAWebAuthn" | "preVerifyMFAWebAuthnForLogin" | "verifyMFAWebAuthnForLogin" | "preVerifyMFASMS" | "verifyMFASMS" | "preVerifyMFASMSForLogin" | "verifyMFASMSForLogin" | "preVerifyMFAEmailCode" | "verifyMFAEmailCode" | "preVerifyMFAEmailCodeForLogin" | "verifyMFAEmailCodeForLogin" | "mfaWithAuthenticator" | "loginWithMfa" | "getMfaRequiredState" | "postHandleVerifyMFAResponseForStepUp" | "postHandleVerifyMFAResponseForLogin" | "handleVerifyMFAResponse" | "getFeatureFlags" | "afterAuthNavigationUtil" | "afterAuthNavigation" | "afterStepUpAuthNavigation" | "afterAuthenticationStateUpdate" | "requestHostedLoginAuthorizeV2" | "__requestHostedLoginAuthorize" | "__requestHostedLoginSilentAuthorize" | "handleHostedLoginCallback" | "setLoginState" | "resetLoginState" | "requestAuthorize" | "requestAuthorizeSSR" | "preLogin" | "postLogin" | "login" | "logout" | "silentLogout" | "recoverMfa" | "quickSmsPasswordlessPreLogin" | "changePhoneNumberWithVerification" | "verifyChangePhoneNumber" | "passwordlessPreLogin" | "passwordlessPostLogin" | "verifyInviteToken" | "webAuthnPrelogin" | "webAuthnPostLogin" | "webAuthnCreateNewDeviceSession" | "webAuthnVerifyNewDeviceSession" | "getUserIP" | "preEnrollMFAWebAuthnForLogin" | "enrollMFAWebAuthnForLogin" | "enrollMFAAuthenticatorAppForLogin" | "preEnrollMFASMSForLogin" | "enrollMFASMSForLogin" | "handleEnrollMFAResponse" | "resetBreachedPassword" | "refreshTokenForSocialLogins" | "__refreshToken" | "setMfaState" | "resetMfaState" | "getMFADevices" | "getMFAStrategies" | "enrollMfa" | "verifyMfa" | "verifyMfaAfterForce" | "disableMfa" | "preDisableMfaSms" | "disableMfaSms" | "preEnrollMfaSms" | "enrollMfaSms" | "preEnrollMfaWebAuthn" | "enrollMfaWebAuthn" | "preDisableMfaWebAuthn" | "disableMfaWebAuthn" | "__getMfaStateAfterEnroll" | "setAllAccountsLoader" | "setAllAccountsError" | "setAllAccountsState" | "setSelectedAccountState" | "resetAllAccountsState" | "clearSelectedAccount" | "loadAccounts" | "searchAccounts" | "updateSubAccountAccessForUser" | "createSubAccount" | "updateSubAccount" | "deleteSubAccount" | "updateSubAccountSettings" | "updateSubAccountManagement" | "updateSubAccountHierarchySettings" | "addUsersToAccount" | "getAccountUsers" | "deleteUsersFromAccount" | "setUserRolesForSubAccount" | "getUserJwtForSubAccount" | "setRootAccountData" | "setSelectedSubAccountData" | "loadNumberOfUsersForSelectedSubAccount" | "setAllAccountDialogsState" | "resetAllAccountDialogsState" | "openCreateSubAccountDialog" | "closeCreateSubAccountDialog" | "openUpdateSubAccountDialog" | "closeUpdateSubAccountDialog" | "openEnableSubAccountManagementDialog" | "closeEnableSubAccountManagementDialog" | "openUpdateSubAccountHierarchySettingsDialog" | "closeUpdateSubAccountHierarchySettingsDialog" | "openDisableSubAccountManagementDialog" | "closeDisableSubAccountManagementDialog" | "openDeleteSubAccountDialog" | "closeDeleteSubAccountDialog" | "openAddUsersToAccountDialog" | "closeAddUsersToAccountDialog" | "openDeleteUserFromAccountDialog" | "closeDeleteUserFromAccountDialog" | "openEditUserRolesDialog" | "closeEditUserRolesDialog" | "setPasskeysState" | "resetPasskeysState" | "loadWebAuthnDevices" | "deleteWebAuthnDevice" | "__shouldShowPromptPasskeys" | "setProfileState" | "resetProfileState" | "loadProfile" | "saveProfile" | "changePassword" | "setProvisioningState" | "resetProvisioningState" | "__loadCountForConnection" | "loadProvisionConnections" | "createProvisionConnection" | "deleteProvisionConnection" | "updateProvisionConnection" | "setResetPhoneNumberState" | "resetResetPhoneNumberState" | "resetPhoneNumber" | "verifyResetPhoneNumber" | "changePhoneNumber" | "setRolesState" | "setRolesStateLoader" | "setRolesStateError" | "resetRolesState" | "loadRolesAndPermissions" | "addRole" | "addRoleV2" | "updateRole" | "deleteRole" | "attachPermissionsToRole" | "attachPermissionToRoles" | "setRestrictionsState" | "setIpRestrictionsState" | "setEmailDomainRestrictionsState" | "__securityCenterSagaWrapper" | "loadIpRestrictions" | "saveIpRestriction" | "saveIpRestrictionsConfig" | "deleteIpRestriction" | "checkIfUserIpValid" | "addCurrentUserIpAndActivate" | "loadEmailDomainRestrictions" | "saveEmailDomainRestriction" | "saveEmailDomainRestrictionsConfig" | "deleteEmailDomainRestriction" | "setSecurityCenterState" | "resetSecurityCenterState" | "setSecurityCenterStateLoader" | "setSecurityCenterStateError" | "loadRecommendations" | "loadInsights" | "sendResetBreachedPasswordEmail" | "sendBulkResetBreachedPasswordEmails" | "loadBreachedPasswordUsers" | "loadUnenrolledMfaUsers" | "loadInactiveUsers" | "setSecurityPolicyState" | "setSecurityPolicyGlobalState" | "setSecurityPolicyPublicState" | "setSecurityPolicyMfaState" | "setSecurityPolicyVendorMfaState" | "setSecurityPolicyLockoutState" | "setSecurityPolicyVendorLockoutState" | "setSecurityPolicyCaptchaState" | "setSecurityPolicyPasswordHistoryState" | "setSecurityPolicyVendorPasswordHistoryState" | "resetSecurityPolicyState" | "setSecurityPolicyPasswordState" | "setSecurityPolicyAuthStrategyPublicState" | "loadSecurityPolicy" | "loadGlobalSecurityPolicy" | "loadPublicSecurityPolicy" | "loadVendorPasswordConfig" | "loadSecurityPolicyMfa" | "loadSecurityPolicyVendorMfa" | "loadSecurityPolicyLockout" | "loadSecurityPolicyVendorLockout" | "loadSecurityPolicyCaptcha" | "loadSecurityPolicyPasswordHistory" | "loadSecurityPolicyVendorPasswordHistory" | "loadPublicAuthStrategiesPolicy" | "saveSecurityPolicyMfa" | "saveSecurityPolicyLockout" | "saveSecurityPolicyPasswordHistory" | "__getSecurityPolicyPublicStateWithCustomLogin" | "setSessionsPolicyState" | "resetSessionsPolicyState" | "loadSessionsPolicy" | "createOrUpdateSessionsPolicy" | "setSessionsState" | "resetSessionsState" | "loadUserSessions" | "loadCurrentUserSession" | "deleteUserSession" | "deleteAllUserSessions" | "revokeUserSessions" | "setSignUpState" | "resetSignUpState" | "resetSignUpStateSoft" | "signUpUser" | "loadAllowSignUps" | "setSmsState" | "resetSmsState" | "loadPhoneNumbers" | "setUpPhoneNumber" | "verifyPhoneNumber" | "deletePhoneNumber" | "verifyDeletePhoneNumber" | "preVerifyPhoneNumber" | "setSocialLoginsState" | "resetSocialLoginsState" | "setSocialLoginError" | "loadSocialLoginsConfiguration" | "loadSocialLoginsConfigurationV2" | "loginViaSocialLogin" | "loadSSOConfigurationsV2" | "saveSSOConfigurationV2" | "updateSSOConfiguration" | "deleteSSOConfiguration" | "saveSSODomain" | "deleteSSODomain" | "validateSSODomainV2" | "setSSOGroups" | "updateSSOGroups" | "setSSODefaultRoles" | "saveSSOConfigurationByMetadata" | "updateSSOConfigurationByMetadata" | "saveSSOConfigurationByUrl" | "saveSSOConfigurationByData" | "setSSOState" | "resetSSOState" | "setSSOLoader" | "setSSOError" | "loadSSOConfigurations" | "saveSSOConfigurations" | "saveSSOConfigurationsFile" | "saveSSOConfigurationsFileWithCallback" | "validateSSODomain" | "loadSSOAuthorizationRoles" | "updateSSOAuthorizationRoles" | "deleteSamlGroup" | "createSamlGroup" | "oidcPostlogin" | "stepUpHostedLogin" | "generateStepUpSession" | "setStepUpState" | "resetStepUpState" | "stepUpWithAuthenticator" | "preVerifyMFASMSForStepUp" | "verifyMFASMSForStepUp" | "preVerifyMFAWebAuthnForStepUp" | "verifyMFAWebAuthnForStepUp" | "preVerifyMFAEmailCodeForStepUp" | "verifyMFAEmailCodeForStepUp" | "getInvitationLink" | "createInvitationLink" | "updateInvitationLink" | "deleteInvitationLink" | "resendActivationLink" | "resendInvitationLink" | "resendInvitationEmail" | "resendInvitationLinkToAllSubTenants" | "loadAllSubTenantsUsers" | "setUserRolesForSubTenants" | "deleteUserFromSubTenants" | "addUserToSubTenants" | "loadRoles" | "loadUsers" | "loadUsersV2" | "addUser" | "addUsersBulk" | "updateUser" | "deleteUser" | "enableUser" | "disableUser" | "getTemporaryUsersConfig" | "updateUserExpirationTime" | "setUserAsPermanent" | "setTeamLoader" | "setTeamError" | "setTeamState" | "resetTeamState" | "openAddUserDialog" | "closeAddUserDialog" | "openDeleteUserDialog" | "closeDeleteUserDialog" | "lockUser" | "setTenantsState" | "resetTenantsState" | "switchTenant" | "loadTenants" | "loadSubTenants" | "loadSubTenantsTree">(action: K) => AuthActions[K];
|
|
24
|
+
export declare const mapLoginActions: <K extends "requestHostedLoginAuthorize" | "preVerifyMFAWebAuthn" | "verifyMFAWebAuthn" | "preVerifyMFAWebAuthnForLogin" | "verifyMFAWebAuthnForLogin" | "preVerifyMFASMS" | "verifyMFASMS" | "preVerifyMFASMSForLogin" | "verifyMFASMSForLogin" | "preVerifyMFAEmailCode" | "verifyMFAEmailCode" | "preVerifyMFAEmailCodeForLogin" | "verifyMFAEmailCodeForLogin" | "mfaWithAuthenticator" | "loginWithMfa" | "getMfaRequiredState" | "postHandleVerifyMFAResponseForStepUp" | "postHandleVerifyMFAResponseForLogin" | "handleVerifyMFAResponse" | "getFeatureFlags" | "afterAuthNavigationUtil" | "afterAuthNavigation" | "afterStepUpAuthNavigation" | "afterAuthenticationStateUpdate" | "requestHostedLoginAuthorizeV2" | "__requestHostedLoginAuthorize" | "__requestHostedLoginSilentAuthorize" | "handleHostedLoginCallback" | "setLoginState" | "resetLoginState" | "requestAuthorize" | "requestAuthorizeSSR" | "preLogin" | "postLogin" | "login" | "logout" | "silentLogout" | "recoverMfa" | "quickSmsPasswordlessPreLogin" | "changePhoneNumberWithVerification" | "verifyChangePhoneNumber" | "passwordlessPreLogin" | "passwordlessPostLogin" | "verifyInviteToken" | "webAuthnPrelogin" | "webAuthnPostLogin" | "webAuthnCreateNewDeviceSession" | "webAuthnVerifyNewDeviceSession" | "getUserIP" | "preEnrollMFAWebAuthnForLogin" | "enrollMFAWebAuthnForLogin" | "enrollMFAAuthenticatorAppForLogin" | "preEnrollMFASMSForLogin" | "enrollMFASMSForLogin" | "handleEnrollMFAResponse" | "resetBreachedPassword" | "refreshTokenForSocialLogins" | "__refreshToken" | "loginWithRedirect">(action: K) => MapLoginActions[K];
|
|
25
25
|
export declare const mapAcceptInvitationActions: <K extends "setAcceptInvitationState" | "resetAcceptInvitationState" | "acceptInvitation">(action: K) => {
|
|
26
|
-
setAcceptInvitationState: (state: Partial<import("@frontegg/redux-store").AcceptInvitationState>) =>
|
|
26
|
+
setAcceptInvitationState: (state: Partial<import("@frontegg/redux-store").AcceptInvitationState>) => {
|
|
27
|
+
readonly error?: string | undefined;
|
|
28
|
+
readonly step: import("@frontegg/redux-store").AcceptInvitationStep;
|
|
29
|
+
};
|
|
27
30
|
resetAcceptInvitationState: () => void;
|
|
28
|
-
acceptInvitation: (payload: import("@frontegg/rest-api").IAcceptInvitation) => void
|
|
31
|
+
acceptInvitation: (payload: import("@frontegg/rest-api").IAcceptInvitation) => Promise<void>;
|
|
29
32
|
}[K];
|
|
30
|
-
export declare const mapActivateAccountActions: <K extends "setActivateState" | "resetActivateState" | "setActivateStrategyState" | "activateAccount" | "preActivateAccount" | "
|
|
31
|
-
setActivateState: (state: Partial<import("@frontegg/redux-store").ActivateAccountState>) =>
|
|
33
|
+
export declare const mapActivateAccountActions: <K extends "setActivateState" | "resetActivateState" | "setActivateStrategyState" | "activateAccount" | "preActivateAccount" | "getActivateAccountStrategy" | "resendActivationEmail">(action: K) => {
|
|
34
|
+
setActivateState: (state: Partial<import("@frontegg/redux-store").ActivateAccountState>) => {
|
|
35
|
+
readonly loading: boolean;
|
|
36
|
+
readonly error?: any;
|
|
37
|
+
readonly step: import("@frontegg/redux-store").ActivateAccountStep;
|
|
38
|
+
readonly resentEmail: boolean;
|
|
39
|
+
readonly activationStrategy: {
|
|
40
|
+
readonly loading: boolean;
|
|
41
|
+
readonly error?: any;
|
|
42
|
+
readonly saving?: boolean | undefined;
|
|
43
|
+
readonly strategy?: {
|
|
44
|
+
readonly shouldSetPassword: boolean;
|
|
45
|
+
} | undefined;
|
|
46
|
+
};
|
|
47
|
+
};
|
|
32
48
|
resetActivateState: () => void;
|
|
33
49
|
setActivateStrategyState: (state: Partial<import("@frontegg/redux-store").ActivateAccountStrategyState>) => void;
|
|
34
|
-
activateAccount: (
|
|
35
|
-
preActivateAccount: (payload: import("@frontegg/redux-store").IPreActivateAccount) => void
|
|
36
|
-
|
|
37
|
-
|
|
50
|
+
activateAccount: (_payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/redux-store").IActivateAccountPayload, boolean>) => Promise<void>;
|
|
51
|
+
preActivateAccount: (payload: import("@frontegg/redux-store").IPreActivateAccount) => Promise<void>;
|
|
52
|
+
getActivateAccountStrategy: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IGetActivateAccountStrategy, import("@frontegg/rest-api").IGetActivateAccountStrategyResponse>) => Promise<void>;
|
|
53
|
+
resendActivationEmail: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IResendActivationEmail, boolean>) => Promise<void>;
|
|
38
54
|
}[K];
|
|
39
|
-
export declare const mapApiTokensActions: <K extends "setApiTokensLoader" | "setApiTokensError" | "setApiTokensState" | "resetApiTokensState" | "loadApiTokens" | "loadUserApiTokens" | "loadTenantApiTokens" | "
|
|
55
|
+
export declare const mapApiTokensActions: <K extends "setApiTokensLoader" | "setApiTokensError" | "setApiTokensState" | "resetApiTokensState" | "loadApiTokens" | "loadUserApiTokens" | "loadTenantApiTokens" | "addTenantApiToken" | "addUserApiToken" | "deleteUserApiToken" | "deleteTenantApiToken">(action: K) => {
|
|
40
56
|
setApiTokensLoader: (payload: import("@frontegg/redux-store").ApiStateIndicator) => void;
|
|
41
57
|
setApiTokensError: (payload: import("@frontegg/redux-store").ApiStateIndicator) => void;
|
|
42
58
|
setApiTokensState: (state: Partial<import("@frontegg/redux-store").ApiTokensState>) => void;
|
|
43
59
|
resetApiTokensState: () => void;
|
|
44
|
-
loadApiTokens: (payload?: import("@frontegg/redux-store").WithSilentLoad<
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
callback?: import("@frontegg/redux-store").CallbackMethod<boolean> | undefined;
|
|
52
|
-
}> | undefined) => void;
|
|
53
|
-
initApiTokensData: (payload: import("@frontegg/redux-store").ApiTokenType) => void;
|
|
54
|
-
addTenantApiToken: (payload: import("@frontegg/redux-store").WithCallback<Pick<import("@frontegg/redux-store").ITenantApiTokensData, "roleIds" | "description" | "expires">, boolean>) => void;
|
|
55
|
-
addUserApiToken: (payload: import("@frontegg/redux-store").WithCallback<Pick<import("@frontegg/redux-store").IApiTokensData, "description" | "expires">, boolean>) => void;
|
|
56
|
-
deleteUserApiToken: (payload: string) => void;
|
|
57
|
-
deleteTenantApiToken: (payload: string) => void;
|
|
60
|
+
loadApiTokens: (payload?: import("@frontegg/redux-store").WithSilentLoad<import("@frontegg/redux-store").WithCallback<object, boolean>> | undefined) => Promise<void>;
|
|
61
|
+
loadUserApiTokens: (payload?: import("@frontegg/redux-store").WithSilentLoad<import("@frontegg/redux-store").WithCallback<object, boolean>> | undefined) => Promise<void>;
|
|
62
|
+
loadTenantApiTokens: (payload?: import("@frontegg/redux-store").WithSilentLoad<import("@frontegg/redux-store").WithCallback<object, boolean>> | undefined) => Promise<void>;
|
|
63
|
+
addTenantApiToken: (payload: import("@frontegg/redux-store").WithCallback<Pick<import("@frontegg/redux-store").ITenantApiTokensData, "description" | "roleIds" | "expires">, boolean>) => Promise<void>;
|
|
64
|
+
addUserApiToken: (payload: import("@frontegg/redux-store").WithCallback<Pick<import("@frontegg/redux-store").IApiTokensData, "description" | "expires">, boolean>) => Promise<void>;
|
|
65
|
+
deleteUserApiToken: (payload: string) => Promise<void>;
|
|
66
|
+
deleteTenantApiToken: (payload: string) => Promise<void>;
|
|
58
67
|
}[K];
|
|
59
68
|
export declare const mapForgotPasswordActions: <K extends "setForgotPasswordState" | "resetForgotPasswordState" | "forgotPassword" | "resetPassword" | "loadPasswordConfig">(action: K) => {
|
|
60
|
-
setForgotPasswordState: (
|
|
69
|
+
setForgotPasswordState: (payload: Partial<import("@frontegg/redux-store").ForgotPasswordState>) => void;
|
|
61
70
|
resetForgotPasswordState: () => void;
|
|
62
|
-
forgotPassword: (payload: import("@frontegg/redux-store").IForgotPasswordPayload) => void
|
|
63
|
-
resetPassword: (payload: import("@frontegg/redux-store").IResetPasswordPayload) => void
|
|
64
|
-
loadPasswordConfig: (payload?: import("@frontegg/rest-api").IGetUserPasswordConfig | undefined) => void
|
|
71
|
+
forgotPassword: (payload: import("@frontegg/redux-store").IForgotPasswordPayload) => Promise<void>;
|
|
72
|
+
resetPassword: (payload: import("@frontegg/redux-store").IResetPasswordPayload) => Promise<void>;
|
|
73
|
+
loadPasswordConfig: (payload?: import("@frontegg/rest-api").IGetUserPasswordConfig | undefined) => Promise<void>;
|
|
65
74
|
}[K];
|
|
66
|
-
export declare const mapMfaActions: <K extends "setMfaState" | "resetMfaState" | "
|
|
75
|
+
export declare const mapMfaActions: <K extends "setMfaState" | "resetMfaState" | "getMFADevices" | "getMFAStrategies" | "enrollMfa" | "verifyMfa" | "verifyMfaAfterForce" | "disableMfa" | "preDisableMfaSms" | "disableMfaSms" | "preEnrollMfaSms" | "enrollMfaSms" | "preEnrollMfaWebAuthn" | "enrollMfaWebAuthn" | "preDisableMfaWebAuthn" | "disableMfaWebAuthn" | "__getMfaStateAfterEnroll">(action: K) => {
|
|
67
76
|
setMfaState: (state: Partial<import("@frontegg/redux-store").MFAState>) => void;
|
|
68
77
|
resetMfaState: () => void;
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
verifyMfa: (
|
|
73
|
-
verifyMfaAfterForce: (
|
|
74
|
-
disableMfa: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IDisableMfa, boolean>) => void
|
|
75
|
-
preDisableMfaSms: (
|
|
78
|
+
getMFADevices: () => Promise<void>;
|
|
79
|
+
getMFAStrategies: () => Promise<void>;
|
|
80
|
+
enrollMfa: () => Promise<void>;
|
|
81
|
+
verifyMfa: (_payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IVerifyMfa, string | undefined>) => Promise<void>;
|
|
82
|
+
verifyMfaAfterForce: (_payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ILoginWithMfa, string | undefined>) => Promise<void>;
|
|
83
|
+
disableMfa: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IDisableMfa, boolean>) => Promise<void>;
|
|
84
|
+
preDisableMfaSms: (_payload: import("@frontegg/redux-store").WithCallback<{
|
|
76
85
|
deviceId: string;
|
|
77
|
-
}, boolean>) => void
|
|
78
|
-
disableMfaSms: (
|
|
79
|
-
preEnrollMfaSms: (payload: import("@frontegg/redux-store").WithCallback<Pick<import("@frontegg/rest-api").IPreEnrollMFASMS, "phoneNumber">, boolean>) => void
|
|
80
|
-
enrollMfaSms: (
|
|
86
|
+
}, boolean>) => Promise<void>;
|
|
87
|
+
disableMfaSms: (_payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/redux-store").WithDeviceId<import("@frontegg/rest-api").IDisableMFASMS>, boolean>) => Promise<void>;
|
|
88
|
+
preEnrollMfaSms: (payload: import("@frontegg/redux-store").WithCallback<Pick<import("@frontegg/rest-api").IPreEnrollMFASMS, "phoneNumber">, boolean>) => Promise<void>;
|
|
89
|
+
enrollMfaSms: (_payload: import("@frontegg/redux-store").WithCallback<Pick<import("@frontegg/rest-api").IEnrollMFASMS, "otcToken" | "code">, string | undefined>) => Promise<void>;
|
|
81
90
|
preEnrollMfaWebAuthn: (payload: {
|
|
82
91
|
callback?: import("@frontegg/redux-store").CallbackMethod<import("@frontegg/redux-store").IPreEnrollMFAWebAuthNForLoginResponse> | undefined;
|
|
83
|
-
}) => void
|
|
84
|
-
enrollMfaWebAuthn: (
|
|
85
|
-
preDisableMfaWebAuthn: (
|
|
92
|
+
}) => Promise<void>;
|
|
93
|
+
enrollMfaWebAuthn: (_payload: import("@frontegg/redux-store").IUserEnrollMFAWebAuthnPayload) => Promise<void>;
|
|
94
|
+
preDisableMfaWebAuthn: (_payload: import("@frontegg/redux-store").WithCallback<{
|
|
86
95
|
deviceId: string;
|
|
87
|
-
}, import("@frontegg/redux-store").IPreVerifyMFAWebAuthNForLoginResponse>) => void
|
|
88
|
-
disableMfaWebAuthn: (
|
|
96
|
+
}, import("@frontegg/redux-store").IPreVerifyMFAWebAuthNForLoginResponse>) => Promise<void>;
|
|
97
|
+
disableMfaWebAuthn: (_payload: import("@frontegg/redux-store").IDisableMFAWebAuthnPayload) => Promise<void>;
|
|
98
|
+
__getMfaStateAfterEnroll: (res: import("@frontegg/rest-api").IVerifyMfaResponse) => Promise<import("@frontegg/redux-store").MFAState>;
|
|
89
99
|
}[K];
|
|
90
100
|
export declare const mapProfileActions: <K extends "setProfileState" | "resetProfileState" | "loadProfile" | "saveProfile" | "changePassword">(action: K) => {
|
|
91
101
|
setProfileState: (state: Partial<import("@frontegg/redux-store").ProfileState>) => void;
|
|
92
102
|
resetProfileState: () => void;
|
|
93
|
-
loadProfile: () => void
|
|
94
|
-
saveProfile: (
|
|
95
|
-
changePassword: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IChangePassword, boolean>) => void
|
|
103
|
+
loadProfile: () => Promise<void>;
|
|
104
|
+
saveProfile: (_payload: Partial<import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IGetUsersV2Response, import("@frontegg/rest-api").IGetUsersV2Response>>) => Promise<void>;
|
|
105
|
+
changePassword: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IChangePassword, boolean>) => Promise<void>;
|
|
96
106
|
}[K];
|
|
97
|
-
export declare const mapSecurityPolicyActions: <K extends "setSecurityPolicyState" | "setSecurityPolicyGlobalState" | "setSecurityPolicyPublicState" | "setSecurityPolicyMfaState" | "setSecurityPolicyVendorMfaState" | "setSecurityPolicyLockoutState" | "setSecurityPolicyVendorLockoutState" | "setSecurityPolicyCaptchaState" | "setSecurityPolicyPasswordHistoryState" | "setSecurityPolicyVendorPasswordHistoryState" | "resetSecurityPolicyState" | "setSecurityPolicyPasswordState" | "setSecurityPolicyAuthStrategyPublicState" | "loadSecurityPolicy" | "loadPublicSecurityPolicy" | "loadVendorPasswordConfig" | "loadSecurityPolicyMfa" | "loadSecurityPolicyVendorMfa" | "
|
|
107
|
+
export declare const mapSecurityPolicyActions: <K extends "setSecurityPolicyState" | "setSecurityPolicyGlobalState" | "setSecurityPolicyPublicState" | "setSecurityPolicyMfaState" | "setSecurityPolicyVendorMfaState" | "setSecurityPolicyLockoutState" | "setSecurityPolicyVendorLockoutState" | "setSecurityPolicyCaptchaState" | "setSecurityPolicyPasswordHistoryState" | "setSecurityPolicyVendorPasswordHistoryState" | "resetSecurityPolicyState" | "setSecurityPolicyPasswordState" | "setSecurityPolicyAuthStrategyPublicState" | "loadSecurityPolicy" | "loadGlobalSecurityPolicy" | "loadPublicSecurityPolicy" | "loadVendorPasswordConfig" | "loadSecurityPolicyMfa" | "loadSecurityPolicyVendorMfa" | "loadSecurityPolicyLockout" | "loadSecurityPolicyVendorLockout" | "loadSecurityPolicyCaptcha" | "loadSecurityPolicyPasswordHistory" | "loadSecurityPolicyVendorPasswordHistory" | "loadPublicAuthStrategiesPolicy" | "saveSecurityPolicyMfa" | "saveSecurityPolicyLockout" | "saveSecurityPolicyPasswordHistory" | "__getSecurityPolicyPublicStateWithCustomLogin">(action: K) => {
|
|
98
108
|
setSecurityPolicyState: (state: Partial<import("@frontegg/redux-store").SecurityPolicyState>) => void;
|
|
99
|
-
setSecurityPolicyGlobalState: (state: Partial<import("@frontegg/redux-store
|
|
109
|
+
setSecurityPolicyGlobalState: (state: Partial<import("@frontegg/redux-store").WithStatus & {
|
|
100
110
|
policy?: import("@frontegg/rest-api").ISecurityPolicy | undefined;
|
|
101
111
|
}>) => void;
|
|
102
|
-
setSecurityPolicyPublicState: (state: Partial<import("@frontegg/redux-store
|
|
112
|
+
setSecurityPolicyPublicState: (state: Partial<import("@frontegg/redux-store").WithStatus & {
|
|
103
113
|
policy?: import("@frontegg/rest-api").IVendorConfig | undefined;
|
|
104
114
|
}>) => void;
|
|
105
|
-
setSecurityPolicyMfaState: (state: Partial<import("@frontegg/redux-store
|
|
115
|
+
setSecurityPolicyMfaState: (state: Partial<import("@frontegg/redux-store").WithStatus & {
|
|
106
116
|
policy?: import("@frontegg/rest-api").ISecurityPolicyMfa | undefined;
|
|
107
117
|
}>) => void;
|
|
108
|
-
setSecurityPolicyVendorMfaState: (state: Partial<import("@frontegg/redux-store
|
|
118
|
+
setSecurityPolicyVendorMfaState: (state: Partial<import("@frontegg/redux-store").WithStatus & {
|
|
109
119
|
policy?: import("@frontegg/rest-api").ISecurityPolicyMfa | undefined;
|
|
110
120
|
}>) => void;
|
|
111
|
-
setSecurityPolicyLockoutState: (state: Partial<import("@frontegg/redux-store
|
|
121
|
+
setSecurityPolicyLockoutState: (state: Partial<import("@frontegg/redux-store").WithStatus & {
|
|
112
122
|
policy?: import("@frontegg/rest-api").ISecurityPolicyLockout | undefined;
|
|
113
123
|
}>) => void;
|
|
114
|
-
setSecurityPolicyVendorLockoutState: (state: Partial<import("@frontegg/redux-store
|
|
124
|
+
setSecurityPolicyVendorLockoutState: (state: Partial<import("@frontegg/redux-store").WithStatus & {
|
|
115
125
|
policy?: import("@frontegg/rest-api").ISecurityPolicyLockout | undefined;
|
|
116
126
|
}>) => void;
|
|
117
|
-
setSecurityPolicyCaptchaState: (state: Partial<import("@frontegg/redux-store
|
|
118
|
-
policy?: import("@frontegg/rest-api").ISecurityPolicyCaptcha | undefined;
|
|
127
|
+
setSecurityPolicyCaptchaState: (state: Partial<import("@frontegg/redux-store").WithStatus & {
|
|
128
|
+
policy?: import("@frontegg/rest-api").ISecurityPolicyCaptcha | null | undefined;
|
|
119
129
|
}>) => void;
|
|
120
|
-
setSecurityPolicyPasswordHistoryState: (state: Partial<import("@frontegg/redux-store
|
|
130
|
+
setSecurityPolicyPasswordHistoryState: (state: Partial<import("@frontegg/redux-store").WithStatus & {
|
|
121
131
|
policy?: import("@frontegg/rest-api").ISecurityPolicyPasswordHistory | undefined;
|
|
122
132
|
}>) => void;
|
|
123
|
-
setSecurityPolicyVendorPasswordHistoryState: (state: Partial<import("@frontegg/redux-store
|
|
133
|
+
setSecurityPolicyVendorPasswordHistoryState: (state: Partial<import("@frontegg/redux-store").WithStatus & {
|
|
124
134
|
policy?: import("@frontegg/rest-api").ISecurityPolicyPasswordHistory | undefined;
|
|
125
135
|
}>) => void;
|
|
126
136
|
resetSecurityPolicyState: () => void;
|
|
127
|
-
setSecurityPolicyPasswordState: (state: Partial<import("@frontegg/redux-store
|
|
137
|
+
setSecurityPolicyPasswordState: (state: Partial<import("@frontegg/redux-store").WithStatus & {
|
|
128
138
|
policy?: Partial<import("@frontegg/rest-api").TestConfig> | undefined;
|
|
129
139
|
}>) => void;
|
|
130
|
-
setSecurityPolicyAuthStrategyPublicState: (state: Partial<import("@frontegg/redux-store
|
|
140
|
+
setSecurityPolicyAuthStrategyPublicState: (state: Partial<import("@frontegg/redux-store").WithStatus & {
|
|
131
141
|
policy?: import("@frontegg/rest-api").IAuthStrategiesConfig | undefined;
|
|
132
142
|
}>) => void;
|
|
133
|
-
loadSecurityPolicy: () => void
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
139
|
-
loadSecurityPolicyLockout: () => void
|
|
140
|
-
loadSecurityPolicyVendorLockout: () => void
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
143
|
+
loadSecurityPolicy: () => Promise<void>;
|
|
144
|
+
loadGlobalSecurityPolicy: () => Promise<void>;
|
|
145
|
+
loadPublicSecurityPolicy: () => Promise<void>;
|
|
146
|
+
loadVendorPasswordConfig: () => Promise<void>;
|
|
147
|
+
loadSecurityPolicyMfa: () => Promise<void>;
|
|
148
|
+
loadSecurityPolicyVendorMfa: () => Promise<void>;
|
|
149
|
+
loadSecurityPolicyLockout: () => Promise<void>;
|
|
150
|
+
loadSecurityPolicyVendorLockout: () => Promise<void>;
|
|
151
|
+
loadSecurityPolicyCaptcha: () => Promise<void>;
|
|
152
|
+
loadSecurityPolicyPasswordHistory: () => Promise<void>;
|
|
153
|
+
loadSecurityPolicyVendorPasswordHistory: () => Promise<void>;
|
|
154
|
+
loadPublicAuthStrategiesPolicy: () => Promise<void>;
|
|
155
|
+
saveSecurityPolicyMfa: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ISaveSecurityPolicyMfa, import("@frontegg/rest-api").ISecurityPolicyMfa>) => Promise<void>;
|
|
156
|
+
saveSecurityPolicyLockout: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ISaveSecurityPolicyLockout, import("@frontegg/rest-api").ISecurityPolicyLockout>) => Promise<void>;
|
|
157
|
+
saveSecurityPolicyPasswordHistory: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ISaveSecurityPolicyPasswordHistory, import("@frontegg/rest-api").ISecurityPolicyPasswordHistory>) => Promise<void>;
|
|
158
|
+
__getSecurityPolicyPublicStateWithCustomLogin: (securityPolicyPublicState?: import("@frontegg/rest-api").IVendorConfig | undefined) => Promise<import("@frontegg/rest-api").IVendorConfig | undefined>;
|
|
147
159
|
}[K];
|
|
148
|
-
export declare const mapSignupActions: <K extends "setSignUpState" | "resetSignUpState" | "signUpUser" | "
|
|
160
|
+
export declare const mapSignupActions: <K extends "setSignUpState" | "resetSignUpState" | "resetSignUpStateSoft" | "signUpUser" | "loadAllowSignUps">(action: K) => {
|
|
149
161
|
setSignUpState: (state: Partial<import("@frontegg/redux-store").SignUpState>) => void;
|
|
150
162
|
resetSignUpState: () => void;
|
|
151
|
-
signUpUser: (payload: import("@frontegg/redux-store").ISignUpUserPayload) => void;
|
|
152
163
|
resetSignUpStateSoft: () => void;
|
|
164
|
+
signUpUser: (_payload: import("@frontegg/redux-store").ISignUpUserPayload) => Promise<void>;
|
|
165
|
+
loadAllowSignUps: () => Promise<void>;
|
|
153
166
|
}[K];
|
|
154
|
-
export declare const mapSocialLoginActions: <K extends "setSocialLoginsState" | "resetSocialLoginsState" | "
|
|
167
|
+
export declare const mapSocialLoginActions: <K extends "setSocialLoginsState" | "resetSocialLoginsState" | "setSocialLoginError" | "loadSocialLoginsConfiguration" | "loadSocialLoginsConfigurationV2" | "loginViaSocialLogin">(action: K) => {
|
|
155
168
|
setSocialLoginsState: (state: Partial<import("@frontegg/redux-store").SocialLoginState>) => void;
|
|
156
169
|
resetSocialLoginsState: () => void;
|
|
157
|
-
|
|
170
|
+
setSocialLoginError: (payload: import("@frontegg/rest-api").ISetSocialLoginError) => void;
|
|
171
|
+
loadSocialLoginsConfiguration: () => Promise<void>;
|
|
158
172
|
loadSocialLoginsConfigurationV2: (payload?: {
|
|
159
173
|
callback?: import("@frontegg/redux-store").CallbackMethod<import("@frontegg/redux-store").SocialLoginState> | undefined;
|
|
160
|
-
} | undefined) => void
|
|
161
|
-
loginViaSocialLogin: (
|
|
162
|
-
setSocialLoginError: (payload: import("@frontegg/rest-api").ISetSocialLoginError) => void;
|
|
174
|
+
} | undefined) => Promise<void>;
|
|
175
|
+
loginViaSocialLogin: (_payload: import("@frontegg/redux-store").ILoginViaSocialLoginPayload) => Promise<void>;
|
|
163
176
|
}[K];
|
|
164
|
-
export declare const mapSsoActions: <K extends "loadSSOConfigurationsV2" | "saveSSOConfigurationV2" | "updateSSOConfiguration" | "deleteSSOConfiguration" | "
|
|
165
|
-
loadSSOConfigurationsV2: () => void
|
|
166
|
-
saveSSOConfigurationV2: (payload: import("@frontegg/redux-store").WithCallback<Partial<Pick<import("@frontegg/rest-api").ISSOConfiguration, "groups" | "enabled" | "generatedVerification" | "ssoEndpoint" | "publicCertificate" | "signRequest" | "acsUrl" | "type" | "spEntityId" | "oidcClientId" | "oidcSecret" | "
|
|
167
|
-
updateSSOConfiguration: (payload: import("@frontegg/redux-store").WithCallback<Partial<Pick<import("@frontegg/rest-api").ISSOConfiguration, "groups" | "enabled" | "generatedVerification" | "ssoEndpoint" | "publicCertificate" | "signRequest" | "acsUrl" | "type" | "spEntityId" | "oidcClientId" | "oidcSecret" | "
|
|
177
|
+
export declare const mapSsoActions: <K extends "loadSSOConfigurationsV2" | "saveSSOConfigurationV2" | "updateSSOConfiguration" | "deleteSSOConfiguration" | "saveSSODomain" | "deleteSSODomain" | "validateSSODomainV2" | "setSSOGroups" | "updateSSOGroups" | "setSSODefaultRoles" | "saveSSOConfigurationByMetadata" | "updateSSOConfigurationByMetadata" | "saveSSOConfigurationByUrl" | "saveSSOConfigurationByData" | "setSSOState" | "resetSSOState" | "setSSOLoader" | "setSSOError" | "loadSSOConfigurations" | "saveSSOConfigurations" | "saveSSOConfigurationsFile" | "saveSSOConfigurationsFileWithCallback" | "validateSSODomain" | "loadSSOAuthorizationRoles" | "updateSSOAuthorizationRoles" | "deleteSamlGroup" | "createSamlGroup" | "oidcPostlogin">(action: K) => {
|
|
178
|
+
loadSSOConfigurationsV2: () => Promise<void>;
|
|
179
|
+
saveSSOConfigurationV2: (payload: import("@frontegg/redux-store").WithCallback<Partial<Pick<import("@frontegg/rest-api").ISSOConfiguration, "roleIds" | "groups" | "enabled" | "generatedVerification" | "ssoEndpoint" | "publicCertificate" | "signRequest" | "acsUrl" | "type" | "spEntityId" | "oidcClientId" | "oidcSecret" | "skipEmailDomainValidation">>, import("@frontegg/rest-api").ISSOConfiguration>) => Promise<void>;
|
|
180
|
+
updateSSOConfiguration: (payload: import("@frontegg/redux-store").WithCallback<Partial<Pick<import("@frontegg/rest-api").ISSOConfiguration, "roleIds" | "groups" | "enabled" | "generatedVerification" | "ssoEndpoint" | "publicCertificate" | "signRequest" | "acsUrl" | "type" | "spEntityId" | "oidcClientId" | "oidcSecret" | "skipEmailDomainValidation">> & {
|
|
168
181
|
ssoConfigId: string;
|
|
169
|
-
}, import("@frontegg/rest-api").ISSOConfiguration>) => void
|
|
182
|
+
}, import("@frontegg/rest-api").ISSOConfiguration>) => Promise<void>;
|
|
170
183
|
deleteSSOConfiguration: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
171
184
|
ssoConfigId: string;
|
|
172
|
-
}, boolean>) => void
|
|
185
|
+
}, boolean>) => Promise<void>;
|
|
186
|
+
saveSSODomain: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ICreateSSODomain & {
|
|
187
|
+
ssoConfigId: string;
|
|
188
|
+
}, import("@frontegg/rest-api").ISSODomain>) => Promise<void>;
|
|
173
189
|
deleteSSODomain: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
174
190
|
domainId: string;
|
|
175
191
|
ssoConfigId: string;
|
|
176
|
-
}, boolean>) => void
|
|
177
|
-
saveSSODomain: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ICreateSSODomain & {
|
|
178
|
-
ssoConfigId: string;
|
|
179
|
-
}, import("@frontegg/rest-api").ISSODomain>) => void;
|
|
192
|
+
}, boolean>) => Promise<void>;
|
|
180
193
|
validateSSODomainV2: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
181
194
|
domainId: string;
|
|
182
195
|
ssoConfigId: string;
|
|
183
|
-
}, boolean>) => void
|
|
184
|
-
setSSODefaultRoles: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
185
|
-
roleIds: string[];
|
|
186
|
-
ssoConfigId: string;
|
|
187
|
-
}, boolean>) => void;
|
|
196
|
+
}, boolean>) => Promise<void>;
|
|
188
197
|
setSSOGroups: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
189
198
|
ssoConfigId: string;
|
|
190
199
|
groupsToAdd: import("@frontegg/rest-api").ICreateSamlGroup[];
|
|
191
200
|
groupsToDelete: string[];
|
|
192
|
-
}, boolean>) => void
|
|
201
|
+
}, boolean>) => Promise<void>;
|
|
193
202
|
updateSSOGroups: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
194
203
|
ssoConfigId: string;
|
|
195
204
|
changedGroups: import("@frontegg/rest-api").IUpdateSamlGroup[];
|
|
196
|
-
}, boolean>) => void
|
|
205
|
+
}, boolean>) => Promise<void>;
|
|
206
|
+
setSSODefaultRoles: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
207
|
+
roleIds: string[];
|
|
208
|
+
ssoConfigId: string;
|
|
209
|
+
}, boolean>) => Promise<void>;
|
|
197
210
|
saveSSOConfigurationByMetadata: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
198
211
|
configFile: File;
|
|
199
|
-
}, import("@frontegg/rest-api").ISSOConfiguration>) => void
|
|
212
|
+
}, import("@frontegg/rest-api").ISSOConfiguration>) => Promise<void>;
|
|
200
213
|
updateSSOConfigurationByMetadata: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
201
214
|
configFile: File;
|
|
202
215
|
ssoConfigId: string;
|
|
203
|
-
}, import("@frontegg/rest-api").ISSOConfiguration>) => void
|
|
204
|
-
saveSSOConfigurationByData: (payload: import("@frontegg/redux-store").WithCallback<Partial<import("@frontegg/rest-api").ISSOConfiguration> & {
|
|
205
|
-
ssoConfigId?: string | undefined;
|
|
206
|
-
configMetadata?: Record<string, string> | undefined;
|
|
207
|
-
}, import("@frontegg/rest-api").ISSOConfiguration>) => void;
|
|
216
|
+
}, import("@frontegg/rest-api").ISSOConfiguration>) => Promise<void>;
|
|
208
217
|
saveSSOConfigurationByUrl: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
209
218
|
ssoConfigId?: string | undefined;
|
|
210
219
|
configMetadata?: Record<string, string> | undefined;
|
|
211
220
|
metadataUrl: string;
|
|
212
|
-
}, import("@frontegg/rest-api").ISSOConfiguration>) => void
|
|
213
|
-
|
|
214
|
-
|
|
221
|
+
}, import("@frontegg/rest-api").ISSOConfiguration>) => Promise<void>;
|
|
222
|
+
saveSSOConfigurationByData: (payload: import("@frontegg/redux-store").WithCallback<Partial<import("@frontegg/rest-api").ISSOConfiguration> & {
|
|
223
|
+
ssoConfigId?: string | undefined;
|
|
224
|
+
configMetadata?: Record<string, string> | undefined;
|
|
225
|
+
}, import("@frontegg/rest-api").ISSOConfiguration>) => Promise<void>;
|
|
215
226
|
setSSOState: (state: Partial<import("@frontegg/redux-store").SSOState>) => void;
|
|
216
227
|
resetSSOState: () => void;
|
|
217
|
-
|
|
218
|
-
|
|
228
|
+
setSSOLoader: (payload: import("@frontegg/redux-store").SSOStateIndicator) => void;
|
|
229
|
+
setSSOError: (payload: import("@frontegg/redux-store").SSOStateIndicator) => void;
|
|
230
|
+
loadSSOConfigurations: () => Promise<void>;
|
|
219
231
|
saveSSOConfigurations: (payload: import("@frontegg/redux-store").WithCallback<Partial<Pick<import("@frontegg/rest-api").ISamlConfiguration, "enabled" | "ssoEndpoint" | "publicCertificate" | "signRequest" | "acsUrl" | "type" | "spEntityId" | "oidcClientId" | "oidcSecret" | "domain" | "isSamlActive"> & {
|
|
220
232
|
samlVendor: import("@frontegg/redux-store").SamlVendors;
|
|
221
|
-
}>, boolean>) => void
|
|
222
|
-
saveSSOConfigurationsFile: (
|
|
233
|
+
}>, boolean>) => Promise<void>;
|
|
234
|
+
saveSSOConfigurationsFile: (configFile: File[]) => Promise<void>;
|
|
223
235
|
saveSSOConfigurationsFileWithCallback: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
224
236
|
configFile: File;
|
|
225
|
-
}, boolean>) => void
|
|
226
|
-
validateSSODomain: (payload?:
|
|
227
|
-
|
|
228
|
-
} | undefined) => void;
|
|
237
|
+
}, boolean>) => Promise<void>;
|
|
238
|
+
validateSSODomain: (payload?: import("@frontegg/redux-store").WithCallback<object, boolean> | undefined) => Promise<void>;
|
|
239
|
+
loadSSOAuthorizationRoles: () => Promise<void>;
|
|
229
240
|
updateSSOAuthorizationRoles: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
230
241
|
authorizationRoles: string[];
|
|
231
242
|
groups?: import("@frontegg/rest-api").ISamlRolesGroup[] | undefined;
|
|
232
|
-
}, boolean>) => void
|
|
243
|
+
}, boolean>) => Promise<void>;
|
|
233
244
|
deleteSamlGroup: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
234
245
|
id: string;
|
|
235
|
-
}, boolean>) => void
|
|
236
|
-
createSamlGroup: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ICreateSamlGroup, boolean>) => void
|
|
237
|
-
oidcPostlogin: (payload: import("@frontegg/rest-api").IOidcPostLogin) => void
|
|
246
|
+
}, boolean>) => Promise<void>;
|
|
247
|
+
createSamlGroup: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ICreateSamlGroup, boolean>) => Promise<void>;
|
|
248
|
+
oidcPostlogin: (payload: import("@frontegg/rest-api").IOidcPostLogin) => Promise<void>;
|
|
238
249
|
}[K];
|
|
239
|
-
export declare const mapTeamActions: <K extends "
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
250
|
+
export declare const mapTeamActions: <K extends "getInvitationLink" | "createInvitationLink" | "updateInvitationLink" | "deleteInvitationLink" | "resendActivationLink" | "resendInvitationLink" | "resendInvitationEmail" | "resendInvitationLinkToAllSubTenants" | "loadAllSubTenantsUsers" | "setUserRolesForSubTenants" | "deleteUserFromSubTenants" | "addUserToSubTenants" | "loadRoles" | "loadUsers" | "loadUsersV2" | "addUser" | "addUsersBulk" | "updateUser" | "deleteUser" | "enableUser" | "disableUser" | "getTemporaryUsersConfig" | "updateUserExpirationTime" | "setUserAsPermanent" | "setTeamLoader" | "setTeamError" | "setTeamState" | "resetTeamState" | "openAddUserDialog" | "closeAddUserDialog" | "openDeleteUserDialog" | "closeDeleteUserDialog" | "lockUser">(action: K) => {
|
|
251
|
+
getInvitationLink: () => Promise<void>;
|
|
252
|
+
createInvitationLink: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ICreateOrUpdateInviteUserLink, string>) => Promise<void>;
|
|
253
|
+
updateInvitationLink: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ICreateOrUpdateInviteUserLink, boolean>) => Promise<void>;
|
|
254
|
+
deleteInvitationLink: (payload?: {
|
|
255
|
+
callback?: import("@frontegg/redux-store").CallbackMethod<boolean> | undefined;
|
|
256
|
+
} | undefined) => Promise<void>;
|
|
257
|
+
resendActivationLink: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IResendActivationLink, boolean>) => Promise<void>;
|
|
258
|
+
resendInvitationLink: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IResendInvitationLink, boolean>) => Promise<void>;
|
|
259
|
+
resendInvitationEmail: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IResendInvitationEmail, boolean>) => Promise<void>;
|
|
260
|
+
resendInvitationLinkToAllSubTenants: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IResendInvitationLink, boolean>) => Promise<void>;
|
|
261
|
+
loadAllSubTenantsUsers: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/redux-store").WithSilentLoad<Partial<import("@frontegg/rest-api").ILoadAllUsers>>, import("@frontegg/rest-api").ISubTenantUser[]>) => Promise<void>;
|
|
262
|
+
setUserRolesForSubTenants: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").UpdateUserRolesForSubTenantsRequestDto & {
|
|
263
|
+
userId: string;
|
|
264
|
+
}, boolean>) => Promise<void>;
|
|
265
|
+
deleteUserFromSubTenants: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").RemoveUserFromSubTenantsRequest, boolean>) => Promise<void>;
|
|
266
|
+
addUserToSubTenants: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").AddUserToSubTenantsRequest, boolean>) => Promise<void>;
|
|
247
267
|
loadRoles: (payload?: {
|
|
248
268
|
callback?: import("@frontegg/redux-store").CallbackMethod<{
|
|
249
269
|
roles: import("@frontegg/rest-api").ITeamUserRole[];
|
|
250
270
|
permissions: import("@frontegg/rest-api").ITeamUserPermission[];
|
|
251
271
|
}> | undefined;
|
|
252
|
-
} | undefined) => void
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
|
|
259
|
-
updateUser: (payload: import("@frontegg/redux-store").WithCallback<Partial<import("@frontegg/rest-api").ITeamUser>, import("@frontegg/rest-api").ITeamUser>) => void;
|
|
260
|
-
deleteUser: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IDeleteUser, boolean>) => void;
|
|
272
|
+
} | undefined) => Promise<void>;
|
|
273
|
+
loadUsers: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/redux-store").WithSilentLoad<import("@frontegg/rest-api").ILoadUsers>, import("@frontegg/rest-api").ITeamUser[]>) => Promise<void>;
|
|
274
|
+
loadUsersV2: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/redux-store").WithSilentLoad<import("@frontegg/redux-store").IGetUsersV2Payload>, import("@frontegg/rest-api").ITeamUser[]>) => Promise<void>;
|
|
275
|
+
addUser: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/redux-store").AddUserPayload, import("@frontegg/rest-api").ITeamUser>) => Promise<void>;
|
|
276
|
+
addUsersBulk: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/redux-store").IAddUsers, import("@frontegg/redux-store").BulkInvintationData>) => Promise<void>;
|
|
277
|
+
updateUser: (payload: import("@frontegg/redux-store").WithCallback<Partial<import("@frontegg/rest-api").ITeamUser>, import("@frontegg/rest-api").ITeamUser>) => Promise<void>;
|
|
278
|
+
deleteUser: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IDeleteUser, boolean>) => Promise<void>;
|
|
261
279
|
enableUser: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
262
280
|
userId: string;
|
|
263
|
-
}, boolean>) => void
|
|
281
|
+
}, boolean>) => Promise<void>;
|
|
264
282
|
disableUser: (payload: import("@frontegg/redux-store").WithCallback<{
|
|
265
283
|
userId: string;
|
|
266
|
-
}, boolean>) => void
|
|
267
|
-
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
updateUserExpirationTime: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IUpdateUserExpiration, boolean>) => void;
|
|
275
|
-
setUserAsPermanent: (payload: import("@frontegg/redux-store").WithCallback<Pick<import("@frontegg/rest-api").IUpdateUserExpiration, "userId">, boolean>) => void;
|
|
276
|
-
getInvitationLink: () => void;
|
|
277
|
-
createInvitationLink: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ICreateOrUpdateInviteUserLink, string>) => void;
|
|
278
|
-
updateInvitationLink: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ICreateOrUpdateInviteUserLink, boolean>) => void;
|
|
279
|
-
deleteInvitationLink: (payload?: {
|
|
280
|
-
callback?: import("@frontegg/redux-store").CallbackMethod<boolean> | undefined;
|
|
281
|
-
} | undefined) => void;
|
|
284
|
+
}, boolean>) => Promise<void>;
|
|
285
|
+
getTemporaryUsersConfig: () => Promise<void>;
|
|
286
|
+
updateUserExpirationTime: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IUpdateUserExpiration, boolean>) => Promise<void>;
|
|
287
|
+
setUserAsPermanent: (payload: import("@frontegg/redux-store").WithCallback<Pick<import("@frontegg/rest-api").IUpdateUserExpiration, "userId">, boolean>) => Promise<void>;
|
|
288
|
+
setTeamLoader: (payload: import("@frontegg/redux-store").TeamStateIndicator) => void;
|
|
289
|
+
setTeamError: (payload: import("@frontegg/redux-store").TeamStateIndicator) => void;
|
|
290
|
+
setTeamState: (payload: Partial<import("@frontegg/redux-store").TeamState>) => void;
|
|
291
|
+
resetTeamState: () => void;
|
|
282
292
|
openAddUserDialog: (payload?: Pick<import("@frontegg/redux-store").AddUserDialogState, "onClose"> | undefined) => void;
|
|
283
293
|
closeAddUserDialog: (payload?: any) => void;
|
|
284
|
-
openDeleteUserDialog: (payload?: Pick<import("@frontegg/redux-store").DeleteUserDialogState, "
|
|
294
|
+
openDeleteUserDialog: (payload?: Pick<import("@frontegg/redux-store").DeleteUserDialogState, "userId" | "email" | "onClose"> | undefined) => void;
|
|
285
295
|
closeDeleteUserDialog: (payload?: any) => void;
|
|
286
|
-
|
|
287
|
-
closeLockUserDialog: (payload?: any) => void;
|
|
296
|
+
lockUser: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").IDeleteUser, boolean>) => Promise<void>;
|
|
288
297
|
}[K];
|
|
289
298
|
export declare const mapTenantsActions: <K extends "setTenantsState" | "resetTenantsState" | "switchTenant" | "loadTenants" | "loadSubTenants" | "loadSubTenantsTree">(action: K) => {
|
|
290
299
|
setTenantsState: (state: Partial<import("@frontegg/redux-store").TenantsState>) => void;
|
|
291
300
|
resetTenantsState: () => void;
|
|
292
|
-
switchTenant: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ISwitchTenant, boolean>) => void
|
|
301
|
+
switchTenant: (payload: import("@frontegg/redux-store").WithCallback<import("@frontegg/rest-api").ISwitchTenant, boolean>) => Promise<void>;
|
|
293
302
|
loadTenants: (payload?: {
|
|
294
303
|
callback?: import("@frontegg/redux-store").CallbackMethod<import("@frontegg/rest-api").ITenantsResponse[]> | undefined;
|
|
295
|
-
} | undefined) => void
|
|
304
|
+
} | undefined) => Promise<void>;
|
|
296
305
|
loadSubTenants: (payload?: {
|
|
297
306
|
callback?: import("@frontegg/redux-store").CallbackMethod<boolean> | undefined;
|
|
298
|
-
} | undefined) => void
|
|
307
|
+
} | undefined) => Promise<void>;
|
|
299
308
|
loadSubTenantsTree: (payload?: {
|
|
300
309
|
callback?: import("@frontegg/redux-store").CallbackMethod<boolean> | undefined;
|
|
301
|
-
} | undefined) => void
|
|
310
|
+
} | undefined) => Promise<void>;
|
|
302
311
|
}[K];
|
|
303
312
|
export declare const connectFronteggStoreV3: (store: CachedEnhancedStore) => {
|
|
304
313
|
authState: any;
|
package/dist/auth/service.d.ts
CHANGED
|
@@ -1,15 +1,13 @@
|
|
|
1
1
|
import { AuthPluginOptions } from './interfaces';
|
|
2
|
-
import { FronteggPluginService,
|
|
3
|
-
import {
|
|
4
|
-
import { CaseReducerActions, SliceCaseReducers } from '@frontegg/redux-store';
|
|
2
|
+
import { FronteggPluginService, PluginConfig, PluginOptions } from '../interfaces';
|
|
3
|
+
import { FronteggStore } from '@frontegg/redux-store';
|
|
5
4
|
import { LoginActions, SocialLoginActions, ActivateAccountActions, AcceptInvitationActions, ForgotPasswordActions, SignUpActions, ProfileActions, SSOActions, MfaActions, TeamActions, ApiTokensActions, SecurityPolicyActions, User, TenantsActions, AuthPageRoutes } from '@frontegg/redux-store';
|
|
6
5
|
import VueRouter from 'vue-router';
|
|
7
|
-
export declare const sliceReducerActionsBy: <T extends SliceCaseReducers<any>>(reducer: T) => CaseReducerActions<T>;
|
|
8
6
|
export declare class FronteggAuthService implements FronteggPluginService {
|
|
9
7
|
pluginConfig: PluginConfig;
|
|
10
8
|
router?: VueRouter | null;
|
|
11
9
|
private readonly _routes;
|
|
12
|
-
private store
|
|
10
|
+
private store;
|
|
13
11
|
private state;
|
|
14
12
|
loginActions: LoginActions;
|
|
15
13
|
socialLoginsActions: SocialLoginActions;
|
|
@@ -31,7 +29,7 @@ export declare class FronteggAuthService implements FronteggPluginService {
|
|
|
31
29
|
userRef: User | null | undefined;
|
|
32
30
|
get isAuthenticated(): boolean;
|
|
33
31
|
get user(): User | undefined | null;
|
|
34
|
-
init: (options: PluginOptions, store:
|
|
32
|
+
init: (options: PluginOptions, store: FronteggStore) => void;
|
|
35
33
|
storeSubscriber: () => void;
|
|
36
34
|
accessTokenUpdaterRef: any;
|
|
37
35
|
accessTokenUpdater: (firstTime?: boolean) => void;
|
package/dist/index.js
CHANGED
|
@@ -3,7 +3,7 @@ import { inject, computed, onMounted, onUpdated, reactive, ref } from 'vue';
|
|
|
3
3
|
import { ContextHolder, FronteggFrameworks } from '@frontegg/rest-api';
|
|
4
4
|
export { ContextHolder } from '@frontegg/rest-api';
|
|
5
5
|
import set from 'set-value';
|
|
6
|
-
import { isAuthRoute,
|
|
6
|
+
import { isAuthRoute, defaultFronteggRoutes, isSteppedUp, FRONTEGG_AFTER_AUTH_REDIRECT_URL, getFeatureEntitlements, getPermissionEntitlements, getEntitlements } from '@frontegg/redux-store';
|
|
7
7
|
import get from 'get-value';
|
|
8
8
|
import { initialize, AdminPortal } from '@frontegg/js';
|
|
9
9
|
export { AdminPortal } from '@frontegg/js';
|
|
@@ -228,32 +228,24 @@ class FronteggAuthService {
|
|
|
228
228
|
} = _a,
|
|
229
229
|
options = __rest(_a, ["router"]);
|
|
230
230
|
|
|
231
|
-
this.state = authInitialState;
|
|
232
231
|
this.userRef = undefined;
|
|
233
232
|
|
|
234
233
|
this.init = (options, store) => {
|
|
235
234
|
this.store = store;
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
}).forEach(([key, actions]) => {
|
|
251
|
-
Object.assign(this, {
|
|
252
|
-
[key]: bindActionCreators(actions, this.store.dispatch)
|
|
253
|
-
});
|
|
254
|
-
});
|
|
255
|
-
const detachableActions = bindActionCreators(authActions, this.store.dispatch);
|
|
256
|
-
ActionsHolder.setActions(detachableActions);
|
|
235
|
+
this.loginActions = store.stateActions.auth.loginActions;
|
|
236
|
+
this.socialLoginsActions = store.stateActions.auth.socialLoginActions;
|
|
237
|
+
this.activateAccountActions = store.stateActions.auth.activateAccountActions;
|
|
238
|
+
this.acceptInvitationActions = store.stateActions.auth.acceptInvitationActions;
|
|
239
|
+
this.forgotPasswordActions = store.stateActions.auth.forgotPasswordActions;
|
|
240
|
+
this.signUpActions = store.stateActions.auth.signUpActions;
|
|
241
|
+
this.profileActions = store.stateActions.auth.profileActions;
|
|
242
|
+
this.ssoActions = store.stateActions.auth.ssoActions;
|
|
243
|
+
this.mfaActions = store.stateActions.auth.mfaActions;
|
|
244
|
+
this.teamActions = store.stateActions.auth.teamActions;
|
|
245
|
+
this.apiTokensActions = store.stateActions.auth.apiTokensActions;
|
|
246
|
+
this.securityPolicyActions = store.stateActions.auth.securityPolicyActions;
|
|
247
|
+
this.tenantsActions = store.stateActions.auth.tenantsActions;
|
|
248
|
+
ActionsHolder.setActions(store.actions);
|
|
257
249
|
|
|
258
250
|
if (!options.hostedLoginBox) {
|
|
259
251
|
this.store.subscribe(this.storeSubscriber);
|
|
@@ -320,7 +312,7 @@ class FronteggAuthService {
|
|
|
320
312
|
return Object.values(this.routes).filter(route => route != this.routes.authenticatedUrl).includes(pathname);
|
|
321
313
|
};
|
|
322
314
|
|
|
323
|
-
this._routes = Object.assign(Object.assign({},
|
|
315
|
+
this._routes = Object.assign(Object.assign({}, defaultFronteggRoutes), options.routes);
|
|
324
316
|
this.router = router;
|
|
325
317
|
}
|
|
326
318
|
|
|
@@ -508,11 +500,11 @@ const useFrontegg = () => {
|
|
|
508
500
|
const fronteggStore = useFronteggStore();
|
|
509
501
|
|
|
510
502
|
const loginWithRedirect = () => {
|
|
511
|
-
var _a;
|
|
503
|
+
var _a, _b;
|
|
512
504
|
|
|
513
505
|
const path = fronteggAuth.getCurrentRoute();
|
|
514
506
|
|
|
515
|
-
if (!path.startsWith((_a = authState.routes.hostedLoginRedirectUrl) !== null && _a !== void 0 ? _a : defaultFronteggRoutes.hostedLoginRedirectUrl)) {
|
|
507
|
+
if (!path.startsWith((_b = (_a = authState.routes.hostedLoginRedirectUrl) !== null && _a !== void 0 ? _a : defaultFronteggRoutes.hostedLoginRedirectUrl) !== null && _b !== void 0 ? _b : "oauth/callback")) {
|
|
516
508
|
fronteggStore.dispatch({
|
|
517
509
|
type: 'auth/setState',
|
|
518
510
|
payload: {
|
|
@@ -575,7 +567,7 @@ const useFronteggAuthGuard = options => {
|
|
|
575
567
|
};
|
|
576
568
|
|
|
577
569
|
var sdkVersion = {
|
|
578
|
-
version: '
|
|
570
|
+
version: '4.0.0'
|
|
579
571
|
};
|
|
580
572
|
|
|
581
573
|
var name = "vue";
|
package/dist/index.min.js
CHANGED
|
@@ -13,4 +13,4 @@ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
|
|
|
13
13
|
OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
|
|
14
14
|
PERFORMANCE OF THIS SOFTWARE.
|
|
15
15
|
***************************************************************************** */
|
|
16
|
-
function m(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(t,r[o])&&(n[r[o]]=t[r[o]])}return n}var S=Symbol("fronteggLoade"),y=Symbol("authState"),O=Symbol("unsubscribeFronteggStore"),R=Symbol("fronteggAuth"),E=Symbol("loadEntitlements"),j=Symbol("router"),I=Symbol("fronteggOptions"),U=Symbol("fronteggStore"),P=Symbol("stepUp"),T=function(t,e){var n;return t.FRONTEGG_STORE_KEY=null!==(n=t.FRONTEGG_STORE_KEY)&&void 0!==n?n:e},w=function(t){return t.FRONTEGG_STORE_KEY},L=function(t){return t.FRONTEGG_REDUX_BINDINGS},k=function(){function t(){d(this,t)}return v(t,null,[{key:"getInstance",value:function(){return t.instance||(t.instance=new t),t.instance}},{key:"setStore",value:function(e){t.getInstance().store=e}},{key:"getStore",value:function(){return t.getInstance().store}},{key:"setBasename",value:function(e){t.getInstance().baseName=e}},{key:"getBasename",value:function(){return t.getInstance().baseName}}]),t}(),_=function(t){return function(e){return f.default(e,t)}},F=function(t,e,n){return function(){var r,o=this,i=Object.keys(e),u=f.default(w(o).getState(),t),a=function(t,e,n,r,o){return n.reduce((function(n,i){return Object.assign({},n,h({},e,Object.assign(Object.assign({},n[e]),h({},i,function(t,e,n){return"function"==typeof e?e.bind(t):n(e)}(t,r[i],o)))))}),L(t)||{})}(o,t,i,e,n);return r=a,o.FRONTEGG_REDUX_BINDINGS=r,i.reduce((function(t,r){return Object.assign({},t,h({},r,function(t,e,n,r){return"function"==typeof e?e.call(t,r):n(e)(r)}(o,e[r],n,u)))}),{})}},G=function(t){var e,n;return null!==(e=null==t?void 0:t.options.base)&&void 0!==e?e:null===(n=(null==t?void 0:t.options).history)||void 0===n?void 0:n.base},C=function(){function t(){d(this,t)}return v(t,null,[{key:"getInstance",value:function(){return t.instance||(t.instance=new t),t.instance}},{key:"setActions",value:function(e){t.getInstance().actions=e}},{key:"getAction",value:function(e){return t.getInstance().actions[e]}}]),t}(),N=function(){function t(e){var n=this;d(this,t);var r=e.router,i=m(e,["router"]);this.state=o.authInitialState,this.userRef=void 0,this.init=function(t,e){n.store=e,Object.entries({loginActions:o.loginActions,socialLoginsActions:o.socialLoginsActions,activateAccountActions:o.activateAccountActions,acceptInvitationActions:o.acceptInvitationActions,forgotPasswordActions:o.forgotPasswordActions,signUpActions:o.signUpActions,profileActions:o.profileActions,ssoActions:o.ssoActions,mfaActions:o.mfaActions,teamActions:o.teamActions,apiTokensActions:o.apiTokensActions,securityPolicyActions:o.securityPolicyActions,tenantsActions:o.tenantsActions}).forEach((function(t){var e=p(t,2),r=e[0],i=e[1];Object.assign(n,h({},r,o.bindActionCreators(i,n.store.dispatch)))}));var r=o.bindActionCreators(o.authActions,n.store.dispatch);C.setActions(r),t.hostedLoginBox||n.store.subscribe(n.storeSubscriber)},this.storeSubscriber=function(){n.state=n.store.getState().auth;var t=!1;n.state.user!==n.userRef&&(n.userRef=n.state.user,t=!0),n.state.isAuthenticated!==n.isAuthenticatedRef&&(n.isAuthenticatedRef=n.state.isAuthenticated,t=!0),n.userRef&&n.state.isAuthenticated?t&&n.accessTokenUpdater():clearInterval(n.accessTokenUpdaterRef)},this.accessTokenUpdater=function(){var t,e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(n.accessTokenUpdaterRef&&clearInterval(n.accessTokenUpdaterRef),e)n.loginActions.requestAuthorize(!0);else if(n.isAuthenticated){var r=1e3*((null===(t=n.user)||void 0===t?void 0:t.expiresIn)||20)*.8;n.accessTokenUpdaterRef=setInterval(n.loginActions.requestAuthorize,r)}},this.getCurrentRoute=function(){var t,e,r,o,i,u,a,s,c,l,f="/";return(null===(e=null===(t=n.router)||void 0===t?void 0:t.currentRoute)||void 0===e?void 0:e.path)&&(f=null===(o=null===(r=n.router)||void 0===r?void 0:r.currentRoute)||void 0===o?void 0:o.path),(null===(a=null===(u=null===(i=n.router)||void 0===i?void 0:i.currentRoute)||void 0===u?void 0:u.value)||void 0===a?void 0:a.fullPath)&&(f=null===(l=null===(c=null===(s=n.router)||void 0===s?void 0:s.currentRoute)||void 0===c?void 0:c.value)||void 0===l?void 0:l.fullPath),f},this.isAuthRoutes=function(t){var e=new URL(t,window.location.origin).pathname;return Object.values(n.routes).filter((function(t){return t!=n.routes.authenticatedUrl})).includes(e)},this._routes=Object.assign(Object.assign({},o.authInitialState.routes),i.routes),this.router=r}return v(t,[{key:"loading",get:function(){var t,e;return null===(e=null===(t=this.store)||void 0===t?void 0:t.getState().auth.isLoading)||void 0===e||e}},{key:"routes",get:function(){var t,e;return null!==(e=null===(t=this.store)||void 0===t?void 0:t.getState().auth.routes)&&void 0!==e?e:this._routes}},{key:"isAuthenticated",get:function(){var t,e;return null!==(e=null===(t=this.store)||void 0===t?void 0:t.getState().auth.isAuthenticated)&&void 0!==e&&e}},{key:"user",get:function(){var t;return null===(t=this.store)||void 0===t?void 0:t.getState().auth.user}}]),t}(),x=function(t,e){return function(){var n=h({},null!=e?e:t.substring("auth.".length),(function(t){return t}));return F(t,n,_).bind(this)()}},B=function(t){return x("auth","authState").bind(t)},H=function(t){return x("auth.loginState").bind(t)},z=function(t){return x("auth.acceptInvitationState").bind(t)},D=function(t){return x("auth.activateState").bind(t)},q=function(t){return x("auth.apiTokensState").bind(t)},W=function(t){return x("auth.forgotPasswordState").bind(t)},M=function(t){return x("auth.mfaState").bind(t)},V=function(t){return x("auth.profileState").bind(t)},$=function(t){return x("auth.securityPolicyState").bind(t)},K=function(t){return x("auth.signUpState").bind(t)},Y=function(t){return x("auth.socialLoginState").bind(t)},X=function(t){return x("auth.ssoState").bind(t)},Q=function(t){return x("auth.teamState").bind(t)},J=function(t){return x("auth.tenantsState").bind(t)},Z=function(t){Object.assign(t,{mapAuthState:B(t),mapLoginState:H(t),mapAcceptInvitationState:z(t),mapActivateAccountState:D(t),mapApiTokensState:q(t),mapForgotPasswordState:W(t),mapMfaState:M(t),mapProfileState:V(t),mapSecurityPolicyState:$(t),mapSignUpState:K(t),mapSocialLoginState:Y(t),mapSsoState:X(t),mapTeamState:Q(t),mapTenantsState:J(t)})},tt=function(t){return function(){return C.getAction(t).apply(void 0,arguments)}},et=function(){return e.inject(S)},nt=function(){return e.inject(y)},rt=function(){return e.inject(U)},ot=function(){return e.inject(R)},it="3.0.37",ut="2.6.12",at=function(t){var n=e.inject(y).user;return{entitlements:null==n?void 0:n.entitlements,attributes:{custom:t,jwt:n}}},st=null,ct={install:function(t,r){var i,a,s=null!=r?r:{},d=s.router,g=m(s,["router"]),v=(null!=r?r:{}).contextOptions;if(null==v)throw Error("contextOptions must be passed to Vue.use(Frontegg, { /* OPTIONS */ })");v.requestCredentials=null!==(i=v.requestCredentials)&&void 0!==i?i:"include",v.metadataHeaders={framework:"".concat(n.FronteggFrameworks.Vuejs,"@").concat(ut),fronteggSdkVersion:"@frontegg/vuejs@".concat(it)},n.ContextHolder.setContext(v);var h,A=!1,_=!1,F="3"===t.version.charAt(0);F&&(h=e.ref(!1));var C=new Set,x=d&&function(t,e){var r=G(t)||"";k.setBasename(r);var i=function(n,i){var u=n;u.startsWith(r)&&"/"!==r&&(u=u.substring(r.length-1)),((null==i?void 0:i.preserveQueryParams)||o.isAuthRoute(u,e))&&(u="".concat(u).concat(window.location.search)),(null==i?void 0:i.refresh)?window.location.href=u:(null==i?void 0:i.replace)?t.replace(u):t.push(u)};return n.ContextHolder.setOnRedirectTo(i),i}(d,null===(a=null==r?void 0:r.authOptions)||void 0===a?void 0:a.routes),B=(st=u.initialize(Object.assign(Object.assign({},g),{onRedirectTo:x,basename:G(d)}))).store;k.setStore(B),t.$fronteggApp=st,t.fronteggAuth||(t.fronteggAuth=new N({router:d}),function(t,e){var n;t.fronteggPlugins=null!==(n=t.fronteggPlugins)&&void 0!==n?n:[],t.fronteggPlugins.push(e)}(t,t.fronteggAuth));var H=function(){var e=(t.fronteggPlugins||[]).reduce((function(t,e){return t&&!e.loading}),!0);if(e!==_){_=e,F&&(h.value=e);var n,r=function(t,e){var n;if("undefined"==typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(n=b(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,o=function(){};return{s:o,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,u=!0,a=!1;return{s:function(){n=t[Symbol.iterator]()},n:function(){var t=n.next();return u=t.done,t},e:function(t){a=!0,i=t},f:function(){try{u||null==n.return||n.return()}finally{if(a)throw i}}}}(C);try{for(r.s();!(n=r.n()).done;){(0,n.value)()}}catch(t){r.e(t)}finally{r.f()}}};null==d||d.getRoutes().map((function(t){var e=t.beforeEnter;t.beforeEnter=function(t,n,r){var o=function(){e?e(t,n,r):r()};if(_)o();else var i=setInterval((function(){H(),_&&(clearInterval(i),o())}),1)}}));var z,D=setInterval((function(){H(),_&&clearInterval(D)}),10),q=function(e){if(e.authorizedContent&&!t.fronteggAuth.isAuthRoutes(e.$route.path)&&!t.fronteggAuth.loading&&!t.fronteggAuth.isAuthenticated)if(null==r?void 0:r.hostedLoginBox)t.fronteggAuth.loginActions.requestHostedLoginAuthorize();else{var n=t.fronteggAuth.routes.loginUrl;e.$router.push(n)}};function W(){this.$route.path.startsWith(t.fronteggAuth.routes.hostedLoginRedirectUrl)||(B.dispatch({type:"auth/setState",payload:{isLoading:!0}}),t.fronteggAuth.loginActions.requestHostedLoginAuthorize())}A||(z=t,A=!0,(t.fronteggPlugins||[]).forEach((function(t){return t.init(g,B)})),T(z,B),z.fronteggAuth=t.fronteggAuth,Z(z));var M=st.loadEntitlements.bind(st),V=st.stepUp.bind(st);if(F){t.provide(S,h);var $=function(t){var n=t.getState();if(t.subscribed)return{authState:t.previousAuthState,unsubscribe:t.previousUnsubscribe};var r=e.reactive(Object.assign({},n.auth)),o=t.subscribe((function(){t.subscribed=!0;var e=t.getState().auth;Object.entries(e).forEach((function(t){var n=p(t,2),o=n[0],i=n[1];r[o]!==e[o]&&(r[o]=i)}))})),i=function(){t.subscribed=!1,o()};return t.previousAuthState=r,t.previousUnsubscribe=i,{authState:r,unsubscribe:i}}(B),K=$.authState,Y=$.unsubscribe,X=e.reactive(Object.assign({},t.fronteggAuth));t.provide(y,K),t.provide(O,Y),t.provide(R,X),t.provide(j,d),t.provide(I,r),t.provide(U,B),t.provide(E,M),t.provide(P,V)}t.mixin({data:function(){return{fronteggLoaded:_}},beforeCreate:function(){T(this,B),this.fronteggAuth=t.fronteggAuth,this.loginWithRedirect=W.bind(this),this.getFeatureEntitlements=function(t,e,n){return st.getFeatureEntitlements(e,n)},this.getPermissionEntitlements=function(t,e,n){return st.getPermissionEntitlements(e,n)},this.getEntitlements=function(t,e,n){return st.getEntitlements(e,n)},this.loadEntitlements=M,this.isSteppedUp=function(t){return st.isSteppedUp()},Z(this)},updated:function(){q(this)},mounted:function(){q(this)},created:function(){var t,e;L(this)&&function(t,e){t.FRONTEGG_UNSUBSCRIBE=e}(this,B.subscribe((t=this,e=L(this),function(){var n=w(t).getState();Object.keys(e).forEach((function(r){Object.keys(e[r]).forEach((function(o){var i=e[r][o];if(i){var u,a=i(f.default(n,r)),s=Object.assign({},c);s.default&&(u=2),s.version&&"3"===s.version[0]&&(u=3),3===u&&l.default(t.$data,o,a),2===u&&l.default(t._data,o,a)}}))}))}))),function(t,e){t.FRONTEGG_LOADER_UNSUBSCRIBE=e}(this,function(t){var e=function(){t.fronteggLoaded=_};return C.add(e),function(){return C.delete(e)}}(this))},beforeDestroy:function(){!function(t){var e;null===(e=t.FRONTEGG_UNSUBSCRIBE)||void 0===e||e.call(t)}(this),function(t){var e;null===(e=t.FRONTEGG_LOADER_UNSUBSCRIBE)||void 0===e||e.call(t)}(this)}})}};return Object.defineProperty(t,"ContextHolder",{enumerable:!0,get:function(){return n.ContextHolder}}),Object.defineProperty(t,"AdminPortal",{enumerable:!0,get:function(){return u.AdminPortal}}),t.Frontegg=ct,t.closeAdminPortal=function(){return u.AdminPortal.hide()},t.isAuthenticatedGuard=function(t,e,n){var r,o,i=function(){var e,r=k.getStore().getState().auth;if(r.isAuthenticated)n();else{var o=null!==(e=k.getBasename())&&void 0!==e?e:"",i=o.endsWith("/")?o.substring(0,o.length-1):"";localStorage.setItem("FRONTEGG_AFTER_AUTH_REDIRECT_URL","".concat(i).concat(t.fullPath)),n({path:r.routes.loginUrl,replace:!0})}},u=null===(o=null===(r=k.getStore())||void 0===r?void 0:r.getState())||void 0===o?void 0:o.auth;if(!u||(null==u?void 0:u.isLoading))var a=setInterval((function(){var t,e;(u=null===(e=null===(t=k.getStore())||void 0===t?void 0:t.getState())||void 0===e?void 0:e.auth)&&!(null==u?void 0:u.isLoading)&&(clearInterval(a),i())}),1);else i()},t.mapAcceptInvitationActions=function(t){return tt(t)},t.mapActivateAccountActions=function(t){return tt(t)},t.mapApiTokensActions=function(t){return tt(t)},t.mapAuthActions=function(t){return tt(t)},t.mapForgotPasswordActions=function(t){return tt(t)},t.mapLoginActions=function(t){return tt("loginWithRedirect"===t?"requestHostedLoginAuthorize":t)},t.mapMfaActions=function(t){return tt(t)},t.mapProfileActions=function(t){return tt(t)},t.mapSecurityPolicyActions=function(t){return tt(t)},t.mapSignupActions=function(t){return tt(t)},t.mapSocialLoginActions=function(t){return tt(t)},t.mapSsoActions=function(t){return tt(t)},t.mapTeamActions=function(t){return tt(t)},t.openAdminPortal=function(){return u.AdminPortal.show()},t.useAuthState=nt,t.useEntitlements=function(t,n){return e.computed((function(){var e=at(n),r=e.entitlements,i=e.attributes;return o.getEntitlements(r,t,i,!0)}))},t.useFeatureEntitlements=function(t,n){return e.computed((function(){var e=at(n),r=e.entitlements,i=e.attributes;return o.getFeatureEntitlements(r,t,i,!0)}))},t.useFrontegg=function(){var t=et(),n=nt(),r=ot(),i=e.inject(E),u=e.inject(P),a=rt();return{fronteggLoaded:t,authState:n,fronteggAuth:r,loginWithRedirect:function(){var t;r.getCurrentRoute().startsWith(null!==(t=n.routes.hostedLoginRedirectUrl)&&void 0!==t?t:o.defaultFronteggRoutes.hostedLoginRedirectUrl)||(a.dispatch({type:"auth/setState",payload:{isLoading:!0}}),r.loginActions.requestHostedLoginAuthorize())},loadEntitlements:i,stepUp:u}},t.useFronteggAuthGuard=function(t){var n=(null!=t?t:{}).redirectUrl,r=ot(),i=e.inject(I),u=nt(),a=e.inject(j),s=rt(),c=function(){var t=r.getCurrentRoute();r.isAuthRoutes(t)||u.isAuthenticated||u.isLoading||(i.hostedLoginBox?(s.dispatch({type:"auth/setState",payload:{isLoading:!0}}),n&&localStorage.setItem(o.FRONTEGG_AFTER_AUTH_REDIRECT_URL,n),r.loginActions.requestHostedLoginAuthorize()):a.push(u.routes.loginUrl))};e.onMounted(c),e.onUpdated(c)},t.useFronteggLoaded=et,t.useIsSteppedUp=function(t){return e.computed((function(){var n=e.inject(y).user;return o.isSteppedUp(n,t)}))},t.usePermissionEntitlements=function(t,n){return e.computed((function(){var e=at(n),r=e.entitlements,i=e.attributes;return o.getPermissionEntitlements(r,t,i,!0)}))},t.useUnsubscribeFronteggStore=function(){return e.inject(O)},Object.defineProperty(t,"__esModule",{value:!0}),t}({},Vue,fronteggRestApi,setValue,fronteggReduxStore,getValue,js);
|
|
16
|
+
function m(t,e){var n={};for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&e.indexOf(r)<0&&(n[r]=t[r]);if(null!=t&&"function"==typeof Object.getOwnPropertySymbols){var o=0;for(r=Object.getOwnPropertySymbols(t);o<r.length;o++)e.indexOf(r[o])<0&&Object.prototype.propertyIsEnumerable.call(t,r[o])&&(n[r[o]]=t[r[o]])}return n}var S=Symbol("fronteggLoade"),y=Symbol("authState"),R=Symbol("unsubscribeFronteggStore"),O=Symbol("fronteggAuth"),E=Symbol("loadEntitlements"),j=Symbol("router"),U=Symbol("fronteggOptions"),I=Symbol("fronteggStore"),P=Symbol("stepUp"),T=function(t,e){var n;return t.FRONTEGG_STORE_KEY=null!==(n=t.FRONTEGG_STORE_KEY)&&void 0!==n?n:e},w=function(t){return t.FRONTEGG_STORE_KEY},L=function(t){return t.FRONTEGG_REDUX_BINDINGS},k=function(){function t(){d(this,t)}return v(t,null,[{key:"getInstance",value:function(){return t.instance||(t.instance=new t),t.instance}},{key:"setStore",value:function(e){t.getInstance().store=e}},{key:"getStore",value:function(){return t.getInstance().store}},{key:"setBasename",value:function(e){t.getInstance().baseName=e}},{key:"getBasename",value:function(){return t.getInstance().baseName}}]),t}(),F=function(t){return function(e){return f.default(e,t)}},_=function(t,e,n){return function(){var r,o=this,i=Object.keys(e),u=f.default(w(o).getState(),t),a=function(t,e,n,r,o){return n.reduce((function(n,i){return Object.assign({},n,h({},e,Object.assign(Object.assign({},n[e]),h({},i,function(t,e,n){return"function"==typeof e?e.bind(t):n(e)}(t,r[i],o)))))}),L(t)||{})}(o,t,i,e,n);return r=a,o.FRONTEGG_REDUX_BINDINGS=r,i.reduce((function(t,r){return Object.assign({},t,h({},r,function(t,e,n,r){return"function"==typeof e?e.call(t,r):n(e)(r)}(o,e[r],n,u)))}),{})}},G=function(t){var e,n;return null!==(e=null==t?void 0:t.options.base)&&void 0!==e?e:null===(n=(null==t?void 0:t.options).history)||void 0===n?void 0:n.base},N=function(){function t(){d(this,t)}return v(t,null,[{key:"getInstance",value:function(){return t.instance||(t.instance=new t),t.instance}},{key:"setActions",value:function(e){t.getInstance().actions=e}},{key:"getAction",value:function(e){return t.getInstance().actions[e]}}]),t}(),C=function(){function t(e){var n=this;d(this,t);var r=e.router,i=m(e,["router"]);this.userRef=void 0,this.init=function(t,e){n.store=e,n.loginActions=e.stateActions.auth.loginActions,n.socialLoginsActions=e.stateActions.auth.socialLoginActions,n.activateAccountActions=e.stateActions.auth.activateAccountActions,n.acceptInvitationActions=e.stateActions.auth.acceptInvitationActions,n.forgotPasswordActions=e.stateActions.auth.forgotPasswordActions,n.signUpActions=e.stateActions.auth.signUpActions,n.profileActions=e.stateActions.auth.profileActions,n.ssoActions=e.stateActions.auth.ssoActions,n.mfaActions=e.stateActions.auth.mfaActions,n.teamActions=e.stateActions.auth.teamActions,n.apiTokensActions=e.stateActions.auth.apiTokensActions,n.securityPolicyActions=e.stateActions.auth.securityPolicyActions,n.tenantsActions=e.stateActions.auth.tenantsActions,N.setActions(e.actions),t.hostedLoginBox||n.store.subscribe(n.storeSubscriber)},this.storeSubscriber=function(){n.state=n.store.getState().auth;var t=!1;n.state.user!==n.userRef&&(n.userRef=n.state.user,t=!0),n.state.isAuthenticated!==n.isAuthenticatedRef&&(n.isAuthenticatedRef=n.state.isAuthenticated,t=!0),n.userRef&&n.state.isAuthenticated?t&&n.accessTokenUpdater():clearInterval(n.accessTokenUpdaterRef)},this.accessTokenUpdater=function(){var t,e=arguments.length>0&&void 0!==arguments[0]&&arguments[0];if(n.accessTokenUpdaterRef&&clearInterval(n.accessTokenUpdaterRef),e)n.loginActions.requestAuthorize(!0);else if(n.isAuthenticated){var r=1e3*((null===(t=n.user)||void 0===t?void 0:t.expiresIn)||20)*.8;n.accessTokenUpdaterRef=setInterval(n.loginActions.requestAuthorize,r)}},this.getCurrentRoute=function(){var t,e,r,o,i,u,a,s,c,l,f="/";return(null===(e=null===(t=n.router)||void 0===t?void 0:t.currentRoute)||void 0===e?void 0:e.path)&&(f=null===(o=null===(r=n.router)||void 0===r?void 0:r.currentRoute)||void 0===o?void 0:o.path),(null===(a=null===(u=null===(i=n.router)||void 0===i?void 0:i.currentRoute)||void 0===u?void 0:u.value)||void 0===a?void 0:a.fullPath)&&(f=null===(l=null===(c=null===(s=n.router)||void 0===s?void 0:s.currentRoute)||void 0===c?void 0:c.value)||void 0===l?void 0:l.fullPath),f},this.isAuthRoutes=function(t){var e=new URL(t,window.location.origin).pathname;return Object.values(n.routes).filter((function(t){return t!=n.routes.authenticatedUrl})).includes(e)},this._routes=Object.assign(Object.assign({},o.defaultFronteggRoutes),i.routes),this.router=r}return v(t,[{key:"loading",get:function(){var t,e;return null===(e=null===(t=this.store)||void 0===t?void 0:t.getState().auth.isLoading)||void 0===e||e}},{key:"routes",get:function(){var t,e;return null!==(e=null===(t=this.store)||void 0===t?void 0:t.getState().auth.routes)&&void 0!==e?e:this._routes}},{key:"isAuthenticated",get:function(){var t,e;return null!==(e=null===(t=this.store)||void 0===t?void 0:t.getState().auth.isAuthenticated)&&void 0!==e&&e}},{key:"user",get:function(){var t;return null===(t=this.store)||void 0===t?void 0:t.getState().auth.user}}]),t}(),x=function(t,e){return function(){var n=h({},null!=e?e:t.substring("auth.".length),(function(t){return t}));return _(t,n,F).bind(this)()}},B=function(t){return x("auth","authState").bind(t)},H=function(t){return x("auth.loginState").bind(t)},z=function(t){return x("auth.acceptInvitationState").bind(t)},D=function(t){return x("auth.activateState").bind(t)},q=function(t){return x("auth.apiTokensState").bind(t)},W=function(t){return x("auth.forgotPasswordState").bind(t)},M=function(t){return x("auth.mfaState").bind(t)},V=function(t){return x("auth.profileState").bind(t)},$=function(t){return x("auth.securityPolicyState").bind(t)},K=function(t){return x("auth.signUpState").bind(t)},Y=function(t){return x("auth.socialLoginState").bind(t)},X=function(t){return x("auth.ssoState").bind(t)},Q=function(t){return x("auth.teamState").bind(t)},J=function(t){return x("auth.tenantsState").bind(t)},Z=function(t){Object.assign(t,{mapAuthState:B(t),mapLoginState:H(t),mapAcceptInvitationState:z(t),mapActivateAccountState:D(t),mapApiTokensState:q(t),mapForgotPasswordState:W(t),mapMfaState:M(t),mapProfileState:V(t),mapSecurityPolicyState:$(t),mapSignUpState:K(t),mapSocialLoginState:Y(t),mapSsoState:X(t),mapTeamState:Q(t),mapTenantsState:J(t)})},tt=function(t){return function(){return N.getAction(t).apply(void 0,arguments)}},et=function(){return e.inject(S)},nt=function(){return e.inject(y)},rt=function(){return e.inject(I)},ot=function(){return e.inject(O)},it="4.0.0",ut="2.6.12",at=function(t){var n=e.inject(y).user;return{entitlements:null==n?void 0:n.entitlements,attributes:{custom:t,jwt:n}}},st=null,ct={install:function(t,r){var i,a,s=null!=r?r:{},d=s.router,g=m(s,["router"]),v=(null!=r?r:{}).contextOptions;if(null==v)throw Error("contextOptions must be passed to Vue.use(Frontegg, { /* OPTIONS */ })");v.requestCredentials=null!==(i=v.requestCredentials)&&void 0!==i?i:"include",v.metadataHeaders={framework:"".concat(n.FronteggFrameworks.Vuejs,"@").concat(ut),fronteggSdkVersion:"@frontegg/vuejs@".concat(it)},n.ContextHolder.setContext(v);var h,A=!1,F=!1,_="3"===t.version.charAt(0);_&&(h=e.ref(!1));var N=new Set,x=d&&function(t,e){var r=G(t)||"";k.setBasename(r);var i=function(n,i){var u=n;u.startsWith(r)&&"/"!==r&&(u=u.substring(r.length-1)),((null==i?void 0:i.preserveQueryParams)||o.isAuthRoute(u,e))&&(u="".concat(u).concat(window.location.search)),(null==i?void 0:i.refresh)?window.location.href=u:(null==i?void 0:i.replace)?t.replace(u):t.push(u)};return n.ContextHolder.setOnRedirectTo(i),i}(d,null===(a=null==r?void 0:r.authOptions)||void 0===a?void 0:a.routes),B=(st=u.initialize(Object.assign(Object.assign({},g),{onRedirectTo:x,basename:G(d)}))).store;k.setStore(B),t.$fronteggApp=st,t.fronteggAuth||(t.fronteggAuth=new C({router:d}),function(t,e){var n;t.fronteggPlugins=null!==(n=t.fronteggPlugins)&&void 0!==n?n:[],t.fronteggPlugins.push(e)}(t,t.fronteggAuth));var H=function(){var e=(t.fronteggPlugins||[]).reduce((function(t,e){return t&&!e.loading}),!0);if(e!==F){F=e,_&&(h.value=e);var n,r=function(t,e){var n;if("undefined"==typeof Symbol||null==t[Symbol.iterator]){if(Array.isArray(t)||(n=b(t))||e&&t&&"number"==typeof t.length){n&&(t=n);var r=0,o=function(){};return{s:o,n:function(){return r>=t.length?{done:!0}:{done:!1,value:t[r++]}},e:function(t){throw t},f:o}}throw new TypeError("Invalid attempt to iterate non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.")}var i,u=!0,a=!1;return{s:function(){n=t[Symbol.iterator]()},n:function(){var t=n.next();return u=t.done,t},e:function(t){a=!0,i=t},f:function(){try{u||null==n.return||n.return()}finally{if(a)throw i}}}}(N);try{for(r.s();!(n=r.n()).done;){(0,n.value)()}}catch(t){r.e(t)}finally{r.f()}}};null==d||d.getRoutes().map((function(t){var e=t.beforeEnter;t.beforeEnter=function(t,n,r){var o=function(){e?e(t,n,r):r()};if(F)o();else var i=setInterval((function(){H(),F&&(clearInterval(i),o())}),1)}}));var z,D=setInterval((function(){H(),F&&clearInterval(D)}),10),q=function(e){if(e.authorizedContent&&!t.fronteggAuth.isAuthRoutes(e.$route.path)&&!t.fronteggAuth.loading&&!t.fronteggAuth.isAuthenticated)if(null==r?void 0:r.hostedLoginBox)t.fronteggAuth.loginActions.requestHostedLoginAuthorize();else{var n=t.fronteggAuth.routes.loginUrl;e.$router.push(n)}};function W(){this.$route.path.startsWith(t.fronteggAuth.routes.hostedLoginRedirectUrl)||(B.dispatch({type:"auth/setState",payload:{isLoading:!0}}),t.fronteggAuth.loginActions.requestHostedLoginAuthorize())}A||(z=t,A=!0,(t.fronteggPlugins||[]).forEach((function(t){return t.init(g,B)})),T(z,B),z.fronteggAuth=t.fronteggAuth,Z(z));var M=st.loadEntitlements.bind(st),V=st.stepUp.bind(st);if(_){t.provide(S,h);var $=function(t){var n=t.getState();if(t.subscribed)return{authState:t.previousAuthState,unsubscribe:t.previousUnsubscribe};var r=e.reactive(Object.assign({},n.auth)),o=t.subscribe((function(){t.subscribed=!0;var e=t.getState().auth;Object.entries(e).forEach((function(t){var n=p(t,2),o=n[0],i=n[1];r[o]!==e[o]&&(r[o]=i)}))})),i=function(){t.subscribed=!1,o()};return t.previousAuthState=r,t.previousUnsubscribe=i,{authState:r,unsubscribe:i}}(B),K=$.authState,Y=$.unsubscribe,X=e.reactive(Object.assign({},t.fronteggAuth));t.provide(y,K),t.provide(R,Y),t.provide(O,X),t.provide(j,d),t.provide(U,r),t.provide(I,B),t.provide(E,M),t.provide(P,V)}t.mixin({data:function(){return{fronteggLoaded:F}},beforeCreate:function(){T(this,B),this.fronteggAuth=t.fronteggAuth,this.loginWithRedirect=W.bind(this),this.getFeatureEntitlements=function(t,e,n){return st.getFeatureEntitlements(e,n)},this.getPermissionEntitlements=function(t,e,n){return st.getPermissionEntitlements(e,n)},this.getEntitlements=function(t,e,n){return st.getEntitlements(e,n)},this.loadEntitlements=M,this.isSteppedUp=function(t){return st.isSteppedUp()},Z(this)},updated:function(){q(this)},mounted:function(){q(this)},created:function(){var t,e;L(this)&&function(t,e){t.FRONTEGG_UNSUBSCRIBE=e}(this,B.subscribe((t=this,e=L(this),function(){var n=w(t).getState();Object.keys(e).forEach((function(r){Object.keys(e[r]).forEach((function(o){var i=e[r][o];if(i){var u,a=i(f.default(n,r)),s=Object.assign({},c);s.default&&(u=2),s.version&&"3"===s.version[0]&&(u=3),3===u&&l.default(t.$data,o,a),2===u&&l.default(t._data,o,a)}}))}))}))),function(t,e){t.FRONTEGG_LOADER_UNSUBSCRIBE=e}(this,function(t){var e=function(){t.fronteggLoaded=F};return N.add(e),function(){return N.delete(e)}}(this))},beforeDestroy:function(){!function(t){var e;null===(e=t.FRONTEGG_UNSUBSCRIBE)||void 0===e||e.call(t)}(this),function(t){var e;null===(e=t.FRONTEGG_LOADER_UNSUBSCRIBE)||void 0===e||e.call(t)}(this)}})}};return Object.defineProperty(t,"ContextHolder",{enumerable:!0,get:function(){return n.ContextHolder}}),Object.defineProperty(t,"AdminPortal",{enumerable:!0,get:function(){return u.AdminPortal}}),t.Frontegg=ct,t.closeAdminPortal=function(){return u.AdminPortal.hide()},t.isAuthenticatedGuard=function(t,e,n){var r,o,i=function(){var e,r=k.getStore().getState().auth;if(r.isAuthenticated)n();else{var o=null!==(e=k.getBasename())&&void 0!==e?e:"",i=o.endsWith("/")?o.substring(0,o.length-1):"";localStorage.setItem("FRONTEGG_AFTER_AUTH_REDIRECT_URL","".concat(i).concat(t.fullPath)),n({path:r.routes.loginUrl,replace:!0})}},u=null===(o=null===(r=k.getStore())||void 0===r?void 0:r.getState())||void 0===o?void 0:o.auth;if(!u||(null==u?void 0:u.isLoading))var a=setInterval((function(){var t,e;(u=null===(e=null===(t=k.getStore())||void 0===t?void 0:t.getState())||void 0===e?void 0:e.auth)&&!(null==u?void 0:u.isLoading)&&(clearInterval(a),i())}),1);else i()},t.mapAcceptInvitationActions=function(t){return tt(t)},t.mapActivateAccountActions=function(t){return tt(t)},t.mapApiTokensActions=function(t){return tt(t)},t.mapAuthActions=function(t){return tt(t)},t.mapForgotPasswordActions=function(t){return tt(t)},t.mapLoginActions=function(t){return tt("loginWithRedirect"===t?"requestHostedLoginAuthorize":t)},t.mapMfaActions=function(t){return tt(t)},t.mapProfileActions=function(t){return tt(t)},t.mapSecurityPolicyActions=function(t){return tt(t)},t.mapSignupActions=function(t){return tt(t)},t.mapSocialLoginActions=function(t){return tt(t)},t.mapSsoActions=function(t){return tt(t)},t.mapTeamActions=function(t){return tt(t)},t.openAdminPortal=function(){return u.AdminPortal.show()},t.useAuthState=nt,t.useEntitlements=function(t,n){return e.computed((function(){var e=at(n),r=e.entitlements,i=e.attributes;return o.getEntitlements(r,t,i,!0)}))},t.useFeatureEntitlements=function(t,n){return e.computed((function(){var e=at(n),r=e.entitlements,i=e.attributes;return o.getFeatureEntitlements(r,t,i,!0)}))},t.useFrontegg=function(){var t=et(),n=nt(),r=ot(),i=e.inject(E),u=e.inject(P),a=rt();return{fronteggLoaded:t,authState:n,fronteggAuth:r,loginWithRedirect:function(){var t,e;r.getCurrentRoute().startsWith(null!==(e=null!==(t=n.routes.hostedLoginRedirectUrl)&&void 0!==t?t:o.defaultFronteggRoutes.hostedLoginRedirectUrl)&&void 0!==e?e:"oauth/callback")||(a.dispatch({type:"auth/setState",payload:{isLoading:!0}}),r.loginActions.requestHostedLoginAuthorize())},loadEntitlements:i,stepUp:u}},t.useFronteggAuthGuard=function(t){var n=(null!=t?t:{}).redirectUrl,r=ot(),i=e.inject(U),u=nt(),a=e.inject(j),s=rt(),c=function(){var t=r.getCurrentRoute();r.isAuthRoutes(t)||u.isAuthenticated||u.isLoading||(i.hostedLoginBox?(s.dispatch({type:"auth/setState",payload:{isLoading:!0}}),n&&localStorage.setItem(o.FRONTEGG_AFTER_AUTH_REDIRECT_URL,n),r.loginActions.requestHostedLoginAuthorize()):a.push(u.routes.loginUrl))};e.onMounted(c),e.onUpdated(c)},t.useFronteggLoaded=et,t.useIsSteppedUp=function(t){return e.computed((function(){var n=e.inject(y).user;return o.isSteppedUp(n,t)}))},t.usePermissionEntitlements=function(t,n){return e.computed((function(){var e=at(n),r=e.entitlements,i=e.attributes;return o.getPermissionEntitlements(r,t,i,!0)}))},t.useUnsubscribeFronteggStore=function(){return e.inject(R)},Object.defineProperty(t,"__esModule",{value:!0}),t}({},Vue,fronteggRestApi,setValue,fronteggReduxStore,getValue,js);
|
package/dist/index.ssr.js
CHANGED
|
@@ -394,34 +394,24 @@ var getRouterBaseName = function getRouterBaseName(router) {
|
|
|
394
394
|
var router = _a.router,
|
|
395
395
|
options = __rest(_a, ["router"]);
|
|
396
396
|
|
|
397
|
-
this.state = reduxStore.authInitialState;
|
|
398
397
|
this.userRef = undefined;
|
|
399
398
|
|
|
400
399
|
this.init = function (options, store) {
|
|
401
400
|
_this.store = store;
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
}).forEach(function (_ref2) {
|
|
417
|
-
var _ref3 = _slicedToArray(_ref2, 2),
|
|
418
|
-
key = _ref3[0],
|
|
419
|
-
actions = _ref3[1];
|
|
420
|
-
|
|
421
|
-
Object.assign(_this, _defineProperty({}, key, reduxStore.bindActionCreators(actions, _this.store.dispatch)));
|
|
422
|
-
});
|
|
423
|
-
var detachableActions = reduxStore.bindActionCreators(reduxStore.authActions, _this.store.dispatch);
|
|
424
|
-
ActionsHolder.setActions(detachableActions);
|
|
401
|
+
_this.loginActions = store.stateActions.auth.loginActions;
|
|
402
|
+
_this.socialLoginsActions = store.stateActions.auth.socialLoginActions;
|
|
403
|
+
_this.activateAccountActions = store.stateActions.auth.activateAccountActions;
|
|
404
|
+
_this.acceptInvitationActions = store.stateActions.auth.acceptInvitationActions;
|
|
405
|
+
_this.forgotPasswordActions = store.stateActions.auth.forgotPasswordActions;
|
|
406
|
+
_this.signUpActions = store.stateActions.auth.signUpActions;
|
|
407
|
+
_this.profileActions = store.stateActions.auth.profileActions;
|
|
408
|
+
_this.ssoActions = store.stateActions.auth.ssoActions;
|
|
409
|
+
_this.mfaActions = store.stateActions.auth.mfaActions;
|
|
410
|
+
_this.teamActions = store.stateActions.auth.teamActions;
|
|
411
|
+
_this.apiTokensActions = store.stateActions.auth.apiTokensActions;
|
|
412
|
+
_this.securityPolicyActions = store.stateActions.auth.securityPolicyActions;
|
|
413
|
+
_this.tenantsActions = store.stateActions.auth.tenantsActions;
|
|
414
|
+
ActionsHolder.setActions(store.actions);
|
|
425
415
|
|
|
426
416
|
if (!options.hostedLoginBox) {
|
|
427
417
|
_this.store.subscribe(_this.storeSubscriber);
|
|
@@ -492,7 +482,7 @@ var getRouterBaseName = function getRouterBaseName(router) {
|
|
|
492
482
|
}).includes(pathname);
|
|
493
483
|
};
|
|
494
484
|
|
|
495
|
-
this._routes = Object.assign(Object.assign({}, reduxStore.
|
|
485
|
+
this._routes = Object.assign(Object.assign({}, reduxStore.defaultFronteggRoutes), options.routes);
|
|
496
486
|
this.router = router;
|
|
497
487
|
}
|
|
498
488
|
|
|
@@ -746,11 +736,11 @@ var useFrontegg = function useFrontegg() {
|
|
|
746
736
|
var fronteggStore = useFronteggStore();
|
|
747
737
|
|
|
748
738
|
var loginWithRedirect = function loginWithRedirect() {
|
|
749
|
-
var _a;
|
|
739
|
+
var _a, _b;
|
|
750
740
|
|
|
751
741
|
var path = fronteggAuth.getCurrentRoute();
|
|
752
742
|
|
|
753
|
-
if (!path.startsWith((_a = authState.routes.hostedLoginRedirectUrl) !== null && _a !== void 0 ? _a : reduxStore.defaultFronteggRoutes.hostedLoginRedirectUrl)) {
|
|
743
|
+
if (!path.startsWith((_b = (_a = authState.routes.hostedLoginRedirectUrl) !== null && _a !== void 0 ? _a : reduxStore.defaultFronteggRoutes.hostedLoginRedirectUrl) !== null && _b !== void 0 ? _b : "oauth/callback")) {
|
|
754
744
|
fronteggStore.dispatch({
|
|
755
745
|
type: 'auth/setState',
|
|
756
746
|
payload: {
|
|
@@ -811,7 +801,7 @@ var useFronteggAuthGuard = function useFronteggAuthGuard(options) {
|
|
|
811
801
|
Vue.onMounted(checkGuard);
|
|
812
802
|
Vue.onUpdated(checkGuard);
|
|
813
803
|
};var sdkVersion = {
|
|
814
|
-
version: '
|
|
804
|
+
version: '4.0.0'
|
|
815
805
|
};var name = "vue";
|
|
816
806
|
var version = "2.6.12";
|
|
817
807
|
var description = "Reactive, component-oriented view layer for modern web interfaces.";
|
package/dist/interfaces.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import VueRouter from 'vue-router';
|
|
2
|
-
import {
|
|
2
|
+
import { FronteggStore } from '@frontegg/redux-store';
|
|
3
3
|
import { FronteggAppOptions } from '@frontegg/types';
|
|
4
4
|
export interface PluginConfig {
|
|
5
5
|
storeName: string;
|
|
@@ -7,14 +7,11 @@ export interface PluginConfig {
|
|
|
7
7
|
sagas: () => void;
|
|
8
8
|
preloadedState: any;
|
|
9
9
|
}
|
|
10
|
-
export interface FronteggStore {
|
|
11
|
-
auth: AuthState;
|
|
12
|
-
}
|
|
13
10
|
export interface PluginOptions extends FronteggAppOptions {
|
|
14
11
|
router: VueRouter;
|
|
15
12
|
}
|
|
16
13
|
export declare abstract class FronteggPluginService {
|
|
17
14
|
loading: boolean;
|
|
18
15
|
pluginConfig: PluginConfig;
|
|
19
|
-
abstract init(options: PluginOptions, store:
|
|
16
|
+
abstract init(options: PluginOptions, store: FronteggStore): void;
|
|
20
17
|
}
|
package/dist/types.d.ts
CHANGED
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { Unsubscribe } from 'redux';
|
|
3
|
-
import { Entitlement, User } from '@frontegg/redux-store';
|
|
1
|
+
import { Entitlement, User, FronteggStore } from '@frontegg/redux-store';
|
|
4
2
|
import { EntitledToOptions, LoadEntitlementsCallback, CustomAttributes } from '@frontegg/types';
|
|
5
3
|
import { FronteggPluginService } from './interfaces';
|
|
6
4
|
declare module 'vue/types/vue' {
|
|
@@ -9,33 +7,33 @@ declare module 'vue/types/vue' {
|
|
|
9
7
|
fronteggPlugins: FronteggPluginService[];
|
|
10
8
|
}
|
|
11
9
|
interface Vue {
|
|
12
|
-
FRONTEGG_STORE_KEY?:
|
|
10
|
+
FRONTEGG_STORE_KEY?: FronteggStore;
|
|
13
11
|
FRONTEGG_ACTIONS_KEY?: any;
|
|
14
|
-
FRONTEGG_UNSUBSCRIBE?:
|
|
12
|
+
FRONTEGG_UNSUBSCRIBE?: () => void;
|
|
15
13
|
FRONTEGG_REDUX_BINDINGS?: any;
|
|
16
14
|
_data?: any;
|
|
17
15
|
fronteggLoaded: boolean;
|
|
18
16
|
loginWithRedirect: () => void;
|
|
19
17
|
/**
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
18
|
+
@param key feature key
|
|
19
|
+
@param customAttributes consumer attributes
|
|
20
|
+
@returns if the user is entitled to the given feature. Attaching the justification if not
|
|
21
|
+
@throws when entitlement is not enabled via frontegg options
|
|
22
|
+
*/
|
|
25
23
|
getFeatureEntitlements: (_user: User | undefined | null, key: string, customAttributes?: CustomAttributes) => Entitlement;
|
|
26
24
|
/**
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
25
|
+
@param key permission key
|
|
26
|
+
@param customAttributes consumer attributes
|
|
27
|
+
@returns if the user is entitled to the given permission. Attaching the justification if not
|
|
28
|
+
@throws when entitlement is not enabled via frontegg options
|
|
29
|
+
*/
|
|
32
30
|
getPermissionEntitlements: (_user: User | undefined | null, key: string, customAttributes?: CustomAttributes) => Entitlement;
|
|
33
31
|
/**
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
32
|
+
@param entitledToOptions - including permission or feature key
|
|
33
|
+
@param customAttributes consumer attributes
|
|
34
|
+
@returns if the user is entitled to the given permission or feature. Attaching the justification if not
|
|
35
|
+
@throws when entitlement is not enabled via frontegg options
|
|
36
|
+
*/
|
|
39
37
|
getEntitlements: (_user: User | undefined | null, entitledToOptions: EntitledToOptions, customAttributes?: CustomAttributes) => Entitlement;
|
|
40
38
|
/**
|
|
41
39
|
* Load entitlements
|
package/dist/utils.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import _Vue from 'vue';
|
|
2
|
-
import {
|
|
2
|
+
import { FronteggStore } from '@frontegg/redux-store';
|
|
3
3
|
import { FronteggPluginService } from './interfaces';
|
|
4
|
-
export declare const setStoreKey: (instance: any, store:
|
|
5
|
-
export declare const getStore: (instance: any) =>
|
|
4
|
+
export declare const setStoreKey: (instance: any, store: FronteggStore) => any;
|
|
5
|
+
export declare const getStore: (instance: any) => FronteggStore;
|
|
6
6
|
export declare const getStoreBinding: (instance: any) => any;
|
|
7
7
|
export declare const setStoreBinding: (instance: any, data: any) => any;
|
|
8
8
|
export declare const setStoreUnsubscribe: (instance: any, unsubscribe: () => void) => () => void;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@frontegg/vue",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "4.0.0",
|
|
4
4
|
"description": "",
|
|
5
5
|
"main": "dist/index.ssr.js",
|
|
6
6
|
"browser": "dist/index.js",
|
|
@@ -22,7 +22,7 @@
|
|
|
22
22
|
"build:unpkg": "cross-env NODE_ENV=production rollup --config rollup.config.js --format iife"
|
|
23
23
|
},
|
|
24
24
|
"dependencies": {
|
|
25
|
-
"@frontegg/js": "
|
|
25
|
+
"@frontegg/js": "7.2.0",
|
|
26
26
|
"get-value": "^3.0.1",
|
|
27
27
|
"set-value": "^4.0.1"
|
|
28
28
|
},
|
package/dist/reducer.d.ts
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
import { PayloadAction } from '@reduxjs/toolkit';
|
|
2
|
-
import { ContextOptions } from '@frontegg/rest-api';
|
|
3
|
-
export interface RootState {
|
|
4
|
-
context?: ContextOptions;
|
|
5
|
-
}
|
|
6
|
-
declare const initialState: RootState;
|
|
7
|
-
declare const reducer: import("redux").Reducer<RootState, import("redux").AnyAction>, actions: import("@reduxjs/toolkit").CaseReducerActions<{
|
|
8
|
-
setContext: {
|
|
9
|
-
prepare: (context: ContextOptions) => {
|
|
10
|
-
payload: ContextOptions;
|
|
11
|
-
};
|
|
12
|
-
reducer: (state: RootState, { payload }: PayloadAction<ContextOptions>) => {
|
|
13
|
-
context: ContextOptions;
|
|
14
|
-
};
|
|
15
|
-
};
|
|
16
|
-
}>;
|
|
17
|
-
export { reducer as rootReducer, actions as rootActions, initialState as rootInitialState };
|