Skip to content

Latest commit

 

History

History
617 lines (454 loc) · 18.8 KB

project.md

File metadata and controls

617 lines (454 loc) · 18.8 KB

lib_UserManager_ui_ngx

The lib_UserManager enables your projects to include user management and authentication in your apps. This library will handle :

  • user login with user/password using a salted password security
  • user login using OpenID
References

lib_OAuth

lib_OAuth

see readme

lib_UserManager

lib_UserManager

see readme

Connectors

void

void connector, replace or don't use it

Transactions

void

does nothing

Sequences

GetSymbols

Variables

name comment
RequestableVariable metadata

Mobile Application

MobileApplication

Pages

ConfirmAccountPage

ConfirmAccountPage

DeleteAccountPage

DeleteAccountPage

ForgotPasswordPage

ForgotPasswordPage

ModalPopup

ModalPopup

Page

Page

Shared Actions

guardPages : Handles access control and redirection based on the user's authentication status and the page they are attempting to access

guardPages

Handles access control and redirection based on the user's authentication status and the page they are attempting to access.

This shared action should be invoked from an AppGuard component.

Behavior:

  • If the user is not authenticated and tries to access a page listed in authorizedPagesOnlyWithAuthentication, they will be redirected to unauthenticatedAccessRedirectPage.
  • If the user is authenticated and tries to access a page listed in authorizedPagesOnlyWithoutAuthentication, they will be redirected to authenticatedAccessRedirectPage.
  • If the current page is not restricted based on the user's authentication status, no redirection occurs.

Variables

name comment
UIStackVariable authenticatedAccessRedirectPage Type: String | Specifies the page to redirect users to when they attempt to access a page that should not be accessible after they have already logged in (e.g., login or registration pages).
UIStackVariable authorizedPagesOnlyWithAuthentication Type: Array of String | Specifies the list of pages that are only accessible to authenticated users. These pages should not be available to users who are not logged in (e.g., dashboard or profile pages).
UIStackVariable authorizedPagesOnlyWithoutAuthentication Type: Array of String | Specifies the list of pages that are only accessible to users who are **not** authenticated. These pages should be hidden or restricted once the user is logged in (e.g., login or registration pages).
UIStackVariable unauthenticatedAccessRedirectPage Type: String | Specifies the page to redirect users to when they attempt to access a restricted page without being authenticated. (e.g., dashboard or profile pages).

isAuthenticatedSession : Returns true if current session is authenticated

isAuthenticatedSession

Returns true if current session is authenticated

SignIn : The `SignIn` function handles user authentication and remember me feature

SignIn

The SignIn function handles user authentication and remember me feature

Variables

name comment
UIStackVariable password The user's password
UIStackVariable rememberMe Stay logged in for an extended period, even after closing the browser
UIStackVariable user The userID (user's email)

SignOut : The `SignOut` function handles user signout and remember me feature

SignOut

The SignOut function handles user signout and remember me feature

Shared Components

ConfirmAccount

ConfirmAccount

Variables

name comment
UICompVariable appName
UICompVariable imgUrl
UICompVariable resetKey

Events

name comment
UICompEvent PasswordChangedError
UICompEvent PasswordChangedOk

DeleteAccount

DeleteAccount

Variables

name comment
UICompVariable appName
UICompVariable imgUrl
UICompVariable moretext
UICompVariable resetKey

Events

name comment
UICompEvent PasswordChangedError
UICompEvent PasswordChangedOk

ForgotPassword

ForgotPassword

Variables

name comment
UICompVariable appName
UICompVariable imgUrl
UICompVariable resetKey

Events

name comment
UICompEvent PasswordChangedError
UICompEvent PasswordChangedOk

LoginComponent : This component handle a login / password form

LoginComponent

This component handle a login / password form. And uses the lib_UserManager

The component will check user / password and if successful will autenticate the user. When the user is authenticated, the component will fire a 'login' event that you can handle with a SubscribeHandler. use this event to close a modal page or to push/root a new page when the user is authenticated

Variables

name comment
UICompVariable enableAzureADLogin Set to false to disable login with AzureAD
UICompVariable enableCancelDismiss Set to true if you want a cancel button to be displayed causing a Modal Page dismiss
UICompVariable enableGoogleLogin Set to false to disable loggin with google
UICompVariable enableLinkedInLogin Set to false to disable login with LinkedIn
UICompVariable logoImage A logo image to be displayed over the login form (64x64)
UICompVariable logoWidth
UICompVariable scope Additional Scope to be added to the standard Scope. This will be concatenated to to the scopr string. For Azure AD start with a + sign
UICompVariable tenantid The tenant ID you want to restrict to, leave blank for no tenant.

Events

name comment
UICompEvent login This event will be fired when a login occurs : Check out.error and out.message for login errors The out.user will be user logged in