User Details Drawer
The userDetailsPage function opens a drawer displaying user details after a successful login. This feature is available only if you're using Conscent's login system.
Note: This feature works only with Conscent's login system.
const userDetailsPage = () => {
console.log('User details page on its way.');
// @ts-ignore
const csc = window._csc as any;
csc('open-user-details-page', {
onSuccess: (data: any) => {
console.log(data);
},
});
};
Usage:
Pre-requisite: Ensure Conscent's login system is integrated.
Trigger: Call
userDetailsPage()
after login to open the drawer with user details.On Success: User details will be available in the
data
object within theonSuccess
callback.Add a div defining the id to it. for eg: <div id="users"></div>
document.getElementById('profile-icon').addEventListener('click', () => {
userDetailsPage();
});
Last updated