Skip to content

feat(overlays): MIN-191 add possibility to login

mateusz-winiarczyk requested to merge MIN-191-add-possibility-to-login into development
Short description:

Added the ability to log in via the form.

Approach:

Implemented the capability to facilitate user login through a designated form within the user overlays section in overlays. This enhancement lays the groundwork for incorporating future user overlay functionalities. Upon entering the accurate credentials, the backend system is expected to respond with a Set-Cookie header, thereby establishing the authentication token in the browser's cookies. In the event of successful validation (status code: 200), alongside storing the authentication token in cookies, the application will mark the user as logged in by setting authenticated flag to true and user login in redux store.

Upon logging in or when not logged in, a request is initiated to verify the accuracy of the session information stored in cookies. If the session is valid and the backend responds with a status code of 200, the authentication status in the Redux store is updated to true. Simultaneously, the user login name, as indicated in the backend response, is also adjusted accordingly.

How to test:
  1. Click the "Overlays" button in the top bar.
  2. Scroll in the drawer to the section: User provided overlays
  3. Click "Login" button
  4. Enter the appropriate credentials and click "Submit" button

log

Edited by mateusz-winiarczyk

Merge request reports