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AAI7N,QAAQgP,aACpC,CAEInB,EAAIoB,WACNvB,GAAO,cAGLG,EAAIqB,SACNxB,GAAO,YAGT,GAAIG,EAAIsB,SAAU,CAIhB,OAHuC,kBAAjBtB,EAAIsB,SACtBtB,EAAIsB,SAASC,cAAgBvB,EAAIsB,UAGnC,KAAK,EACHzB,GAAO,oBACP,MACF,IAAK,MACHA,GAAO,iBACP,MACF,IAAK,SACHA,GAAO,oBACP,MACF,IAAK,OACHA,GAAO,kBACP,MACF,QACE,MAAM,IAAIC,UAAU,8BAE1B,CAEA,OAAOD,CACT,EAnKA,IAAIM,EAASqB,mBACTb,EAASc,mBAUTb,EAAqB,wCAkKzB,SAASH,EAAUZ,EAAKM,GACtB,IACE,OAAOA,EAAON,EAGhB,CAFE,MAAOlQ,GACP,OAAOkQ,CACT,CACF","sources":["features/login/interfaces/login.interface.ts","../node_modules/universal-cookie/es6/utils.js","../node_modules/universal-cookie/es6/Cookies.js","../node_modules/react-cookie/es6/Cookies.js","../node_modules/react-cookie/es6/CookiesContext.js","../node_modules/react-cookie/es6/useCookies.js","../node_modules/react-cookie/es6/utils.js","features/login/login.component.tsx","features/login/services/login.service.ts","lib/services/loader.service.ts","../node_modules/rxjs/src/internal/operators/concatMap.ts","../node_modules/rxjs/src/internal/operators/mergeMap.ts","../node_modules/rxjs/src/internal/operators/mergeInternals.ts","../node_modules/universal-cookie/node_modules/cookie/index.js"],"sourcesContent":["export interface IUserLookup {\n Id: number\n Username: string\n FirstName: string\n LastName: string\n FullName: string\n}\n\nexport interface ILoginResult {\n success: boolean;\n message: string;\n response: ILoginReponse;\n}\n\nexport interface ILoginReponse {\n resetPassword: boolean;\n user: ILoginResponseUser;\n reset_token: string;\n Companies: string[];\n CompanyList: string[];\n Roles: string[];\n LicProducts: string[];\n LicProductsList: { [key: string]: number };\n Id: number;\n UserType: number;\n Username: string;\n FirstName: string;\n LastName: string;\n FullName: string;\n Email: string;\n Phone: string;\n ParticipantId: number;\n CultureId: number;\n CultureName: string;\n CultureCode: string;\n RoleId: number;\n agreedToPrivacyStatement: boolean;\n PrivacyStatementDate: Date;\n UnknownParticipant: boolean;\n LastLoggedInDate: Date;\n}\n\nexport interface ILoginResponseUser {\n login_attempts: number;\n reason_code: number;\n locked_reason: number;\n FirstName: string\n LastName: string\n Email: string\n privacy_statement: boolean\n privacy_gdpr: boolean\n UserType: number\n ParticipantID: number\n UserID: number\n ParticipantCultureId: number\n Culture: string\n CultureId: number\n CultureName: string\n user_token: string\n loginAttempts: number\n username: string\n Roles: string[];\n Companies: string[];\n RedirectUrl: string;\n PQPId: number;\n}\n\nexport interface ILoginDispatch {\n id: number;\n type: number;\n role: number;\n roleName?: string;\n participantId: number;\n participantLanguageId: number;\n username: string;\n firstName: string;\n lastName: string;\n fullName: string;\n languageId: number;\n user_token: string;\n email: string;\n redirect: IRedirectInfo;\n unknownParticipant?: boolean;\n}\n\nexport interface IRedirectInfo {\n submitRedirect: string;\n assessmentRedirect: number;\n}\n\nexport interface ILoginData {\n username: string;\n password: string;\n}\n\nexport interface IReduxDispatchable {\n type: string,\n payload: T\n}\n\nexport enum KeyType {\n Enter\n}\n\nexport interface ITokenCheckResponse {\n userId: number\n membershipID: number\n username: string\n isNewUser: boolean\n isTokenValid: boolean\n isTokenExpired: boolean\n message: string\n usertype: number\n culturecode: string\n}\n","import * as cookie from 'cookie';\r\nexport function hasDocumentCookie() {\r\n // Can we get/set cookies on document.cookie?\r\n return typeof document === 'object' && typeof document.cookie === 'string';\r\n}\r\nexport function cleanCookies() {\r\n document.cookie.split(';').forEach(function (c) {\r\n document.cookie = c\r\n .replace(/^ +/, '')\r\n .replace(/=.*/, '=;expires=' + new Date().toUTCString() + ';path=/');\r\n });\r\n}\r\nexport function parseCookies(cookies, options) {\r\n if (typeof cookies === 'string') {\r\n return cookie.parse(cookies, options);\r\n }\r\n else if (typeof cookies === 'object' && cookies !== null) {\r\n return cookies;\r\n }\r\n else {\r\n return {};\r\n }\r\n}\r\nexport function isParsingCookie(value, doNotParse) {\r\n if (typeof doNotParse === 'undefined') {\r\n // We guess if the cookie start with { or [, it has been serialized\r\n doNotParse =\r\n !value || (value[0] !== '{' && value[0] !== '[' && value[0] !== '\"');\r\n }\r\n return !doNotParse;\r\n}\r\nexport function readCookie(value, options) {\r\n if (options === void 0) { options = {}; }\r\n var cleanValue = cleanupCookieValue(value);\r\n if (isParsingCookie(cleanValue, options.doNotParse)) {\r\n try {\r\n return JSON.parse(cleanValue);\r\n }\r\n catch (e) {\r\n // At least we tried\r\n }\r\n }\r\n // Ignore clean value if we failed the deserialization\r\n // It is not relevant anymore to trim those values\r\n return value;\r\n}\r\nfunction cleanupCookieValue(value) {\r\n // express prepend j: before serializing a cookie\r\n if (value && value[0] === 'j' && value[1] === ':') {\r\n return value.substr(2);\r\n }\r\n return value;\r\n}\r\n","var __assign = (this && this.__assign) || function () {\r\n __assign = Object.assign || function(t) {\r\n for (var s, i = 1, n = arguments.length; i < n; i++) {\r\n s = arguments[i];\r\n for (var p in s) if (Object.prototype.hasOwnProperty.call(s, p))\r\n t[p] = s[p];\r\n }\r\n return t;\r\n };\r\n return __assign.apply(this, arguments);\r\n};\r\nimport * as cookie from 'cookie';\r\nimport { hasDocumentCookie, parseCookies, readCookie } from './utils';\r\nvar Cookies = /** @class */ (function () {\r\n function Cookies(cookies, options) {\r\n var _this = this;\r\n this.changeListeners = [];\r\n this.HAS_DOCUMENT_COOKIE = false;\r\n this.cookies = parseCookies(cookies, options);\r\n new Promise(function () {\r\n _this.HAS_DOCUMENT_COOKIE = hasDocumentCookie();\r\n }).catch(function () { });\r\n }\r\n Cookies.prototype._updateBrowserValues = function (parseOptions) {\r\n if (!this.HAS_DOCUMENT_COOKIE) {\r\n return;\r\n }\r\n this.cookies = cookie.parse(document.cookie, parseOptions);\r\n };\r\n Cookies.prototype._emitChange = function (params) {\r\n for (var i = 0; i < this.changeListeners.length; ++i) {\r\n this.changeListeners[i](params);\r\n }\r\n };\r\n Cookies.prototype.get = function (name, options, parseOptions) {\r\n if (options === void 0) { options = {}; }\r\n this._updateBrowserValues(parseOptions);\r\n return readCookie(this.cookies[name], options);\r\n };\r\n Cookies.prototype.getAll = function (options, parseOptions) {\r\n if (options === void 0) { options = {}; }\r\n this._updateBrowserValues(parseOptions);\r\n var result = {};\r\n for (var name_1 in this.cookies) {\r\n result[name_1] = readCookie(this.cookies[name_1], options);\r\n }\r\n return result;\r\n };\r\n Cookies.prototype.set = function (name, value, options) {\r\n var _a;\r\n if (typeof value === 'object') {\r\n value = JSON.stringify(value);\r\n }\r\n this.cookies = __assign(__assign({}, this.cookies), (_a = {}, _a[name] = value, _a));\r\n if (this.HAS_DOCUMENT_COOKIE) {\r\n document.cookie = cookie.serialize(name, value, options);\r\n }\r\n this._emitChange({ name: name, value: value, options: options });\r\n };\r\n Cookies.prototype.remove = function (name, options) {\r\n var finalOptions = (options = __assign(__assign({}, options), { expires: new Date(1970, 1, 1, 0, 0, 1), maxAge: 0 }));\r\n this.cookies = __assign({}, this.cookies);\r\n delete this.cookies[name];\r\n if (this.HAS_DOCUMENT_COOKIE) {\r\n document.cookie = cookie.serialize(name, '', finalOptions);\r\n }\r\n this._emitChange({ name: name, value: undefined, options: options });\r\n };\r\n Cookies.prototype.addChangeListener = function (callback) {\r\n this.changeListeners.push(callback);\r\n };\r\n Cookies.prototype.removeChangeListener = function (callback) {\r\n var idx = this.changeListeners.indexOf(callback);\r\n if (idx >= 0) {\r\n this.changeListeners.splice(idx, 1);\r\n }\r\n };\r\n return Cookies;\r\n}());\r\nexport default Cookies;\r\n","import Cookies from 'universal-cookie';\r\nexport default Cookies;\r\n","import * as React from 'react';\r\nimport Cookies from './Cookies';\r\nvar CookiesContext = React.createContext(new Cookies());\r\nexport var Provider = CookiesContext.Provider, Consumer = CookiesContext.Consumer;\r\nexport default CookiesContext;\r\n","import { useContext, useLayoutEffect, useState, useRef, useMemo } from 'react';\r\nimport CookiesContext from './CookiesContext';\r\nimport { isInBrowser } from './utils';\r\nexport default function useCookies(dependencies) {\r\n var cookies = useContext(CookiesContext);\r\n if (!cookies) {\r\n throw new Error('Missing ');\r\n }\r\n var initialCookies = cookies.getAll();\r\n var _a = useState(initialCookies), allCookies = _a[0], setCookies = _a[1];\r\n var previousCookiesRef = useRef(allCookies);\r\n if (isInBrowser()) {\r\n useLayoutEffect(function () {\r\n function onChange() {\r\n var newCookies = cookies.getAll();\r\n if (shouldUpdate(dependencies || null, newCookies, previousCookiesRef.current)) {\r\n setCookies(newCookies);\r\n }\r\n previousCookiesRef.current = newCookies;\r\n }\r\n cookies.addChangeListener(onChange);\r\n return function () {\r\n cookies.removeChangeListener(onChange);\r\n };\r\n }, [cookies]);\r\n }\r\n var setCookie = useMemo(function () { return cookies.set.bind(cookies); }, [cookies]);\r\n var removeCookie = useMemo(function () { return cookies.remove.bind(cookies); }, [cookies]);\r\n return [allCookies, setCookie, removeCookie];\r\n}\r\nfunction shouldUpdate(dependencies, newCookies, oldCookies) {\r\n if (!dependencies) {\r\n return true;\r\n }\r\n for (var _i = 0, dependencies_1 = dependencies; _i < dependencies_1.length; _i++) {\r\n var dependency = dependencies_1[_i];\r\n if (newCookies[dependency] !== oldCookies[dependency]) {\r\n return true;\r\n }\r\n }\r\n return false;\r\n}\r\n","export function isInBrowser() {\r\n return (typeof window !== 'undefined' &&\r\n typeof window.document !== 'undefined' &&\r\n typeof window.document.createElement !== 'undefined');\r\n}\r\n","import { Fragment, useEffect, useState } from \"react\";\nimport { useParams, Link } from \"react-router-dom\";\nimport { useCookies } from \"react-cookie\";\nimport { LoginService } from \"./services/login.service\";\nimport './styles/login.styles.scss';\nimport { ILoginData, ILoginDispatch, ILoginReponse, IReduxDispatchable, IUserLookup, KeyType } from \"./interfaces/login.interface\";\nimport { AjaxError } from \"rxjs/ajax\";\nimport { FontAwesomeIcon } from '@fortawesome/react-fontawesome';\nimport { faEye, faEyeSlash, faUser, faKey } from '@fortawesome/free-solid-svg-icons';\nimport { useAppDispatch } from \"app/hooks\";\nimport { login } from \"lib/reducers/user.slice\";\nimport { concatMap } from \"rxjs\";\nimport { LoaderService } from \"lib/services/loader.service\";\n\n\nexport default function Login() {\n const [cookies, setCookie, removeCookie] = useCookies();\n const usernameFromCookie = cookies.QuestUsername; // Check for username in the cookie \"QuestUsername\"\n const params = useParams(); // Check for a username in the URL\n const dispatch = useAppDispatch();\n\n const usernameFromUrl = params.username; // Check for a username in the URL\n const [encryptedPqp, setEncryptedPqp] = useState(new URLSearchParams(window.location.search));\n\n const [firstName, setFirstName]: [string, Function] = useState(\"\");\n const [message, setMessage]: [string, Function] = useState(\"\");\n\n const [showPassword, setShowPassword]: [boolean, Function] = useState(false);\n const [loading, setLoading]: [boolean, Function] = useState(false);\n const loginService: LoginService = new LoginService();\n const [loginData, setLoginData]: [ILoginData, Function] = useState({\n username: \"\",\n password: \"\"\n });\n const [rememberMe, setRememberMe]: [boolean, Function] = useState(false);\n const [dispatchable, setDispatchable]: [IReduxDispatchable, Function] = useState({} as IReduxDispatchable);\n const loaderService = new LoaderService();\n let userLoginData: any = {};\n\n const doLogin = (event: any) => {\n setLoading(true);\n event.preventDefault();\n loginService.Login(loginData.username, loginData.password)\n .pipe(\n concatMap(obs => {\n userLoginData = { ...obs.response };\n return loginService.GetUserProfile(obs.response.user.UserID, obs.response.user.UserType)\n })\n )\n .subscribe({\n next: (response) => {\n const loginData: ILoginReponse = {\n ...response.response,\n ...userLoginData\n }\n processSuccess(loginData);\n },\n error: (response) => {\n console.log('error response', response);\n processFailure(response);\n }\n })\n }\n\n const redirectToReset = (response: ILoginReponse) => {\n window.location.href = `/change-password/${response.reset_token}`;\n }\n\n const processSuccess = (response: ILoginReponse) => {\n if (rememberMe) {\n setCookie(\"QuestUsername\", loginData.username, { path: \"/\", });\n }\n\n if (response.resetPassword) {\n redirectToReset(response);\n return;\n }\n\n setDispatchable({ ...loginService.DispatchLogin(response) })\n }\n\n const processFailure = (error: AjaxError) => {\n setLoginData((previousState: any) => {\n return { ...previousState, Password: \"\" };\n });\n setMessage(loginService.BuildMessage(error));\n setLoading(false);\n }\n\n const handleUsernameChange = (input: any) => {\n const value = input.target.value;\n setLoginData((previousState: any) => {\n return { ...previousState, username: value };\n });\n }\n\n const handlePasswordChange = (input: any) => {\n const value = input.target.value;\n setLoginData((previousState: any) => {\n return { ...previousState, password: value };\n });\n }\n\n const handleNotYou = () => {\n let route = window.location.href.split('/');\n removeCookie(\"QuestUsername\");\n if (route) {\n route.pop();\n window.location.href = route.join('/');\n }\n }\n\n const handleRememberMeCheckBox = () => {\n setRememberMe(!rememberMe);\n }\n\n useEffect(() => {\n loaderService.hide();\n if (usernameFromUrl || usernameFromCookie) {\n loginService.GetUserFromUsername(usernameFromUrl ? usernameFromUrl : usernameFromCookie)\n .subscribe({\n next: ({ response }: { response: IUserLookup }) => {\n setFirstName(response.FirstName);\n setLoginData((previousState: any) => {\n return { ...previousState, username: response.Username };\n });\n }\n })\n }\n\n\n }, [usernameFromCookie, usernameFromUrl]);\n\n useEffect(() => {\n loaderService.hide();\n if(!encryptedPqp || !encryptedPqp.get('pqp')) return;\n loginService.GetUserFromEncryptedPqp(encryptedPqp.get('pqp') ?? \"\")\n .pipe(\n concatMap(obs => {\n userLoginData = { ...obs.response };\n return loginService.GetUserProfile(obs.response.user.UserID, obs.response.user.UserType)\n })\n )\n .subscribe({\n next: (response) => {\n const loginData: ILoginReponse = {\n ...response.response,\n ...userLoginData\n }\n processSuccess(loginData);\n },\n error: (response) => {\n processFailure(response);\n }\n })\n }, [encryptedPqp])\n\n useEffect(() => {\n if (dispatchable.type === 'user/logIn')\n dispatch(login({ ...dispatchable.payload }));\n }, [dispatchable])\n\n return (\n \n

\n
\n Welcome\n {(firstName !== \"\")\n ? ` back to Quest, ${firstName}`\n : ` to Quest`\n }\n
\n Please sign in to your account\n

\n {message !== \"\" && \n {message !== \"\" ? message : \"\"}\n }\n\n
{ loginService.DetermineKeyPressed(target.key, KeyType.Enter) && doLogin(target) }}>\n
doLogin(event)}>\n
\n
\n
\n
\n
\n \n {firstName !== \"\" &&\n handleNotYou()}>Not You?\n }\n
\n
\n
\n
\n \n \n \n
\n \n
\n
\n
\n\n\n
\n
\n
\n\n
\n
\n
\n
\n
\n \n \n Forgot Password or Username\n \n
\n
\n
\n
\n \n \n \n
\n \n
\n setShowPassword(!showPassword)}>\n \n \n
\n
\n
\n
\n\n\n
\n
\n
\n\n
\n
\n \n \n
\n
\n\n
\n \n
\n
\n
\n
\n )\n}\n","\nimport { ApiRoutes } from \"lib/services/api.routes\";\nimport { NewApiService } from \"lib/services/api/newapi.service\";\nimport { Observable } from \"rxjs\";\nimport { AjaxError, AjaxResponse } from \"rxjs/ajax\";\nimport { ILoginDispatch, ILoginReponse, IReduxDispatchable, KeyType } from \"../interfaces/login.interface\";\n\nexport class LoginService {\n _apiService: NewApiService;\n /**\n *\n */\n constructor() {\n this._apiService = new NewApiService();\n this._apiService.setOptions({ handleErrors: false });\n\n }\n public DetermineKeyPressed(key: string, keyType: KeyType): boolean {\n switch (keyType) {\n case KeyType.Enter:\n return ((key === \"Enter\") || (key === \"NumpadEnter\"));\n default:\n return false;\n }\n }\n\n public Login(username: string, password: string): Observable> {\n return this._apiService.post({\n url: ApiRoutes.LoginPage.UserLogin,\n data: {\n email: username,\n password: password\n },\n params: {},\n isAuthenticated: false\n })\n }\n\n\n public GetUserFromUsername(username: string): Observable> {\n return this._apiService.get({\n url: ApiRoutes.LoginPage.GetNameFromUsername,\n params: { username },\n isAuthenticated: false\n })\n }\n\n public GetUserFromEncryptedPqp(encrypted: string) : Observable> {\n return this._apiService.post({\n url: ApiRoutes.LoginPage.LoginWithKey,\n data: {\n EncryptedPqp: encrypted\n },\n isAuthenticated: false\n });\n }\n\n public DispatchLogin(loginData: ILoginReponse): IReduxDispatchable {\n return {\n type: \"user/logIn\",\n payload: {\n id: loginData.user.UserID,\n type: loginData.UserType,\n role: loginData.RoleId,\n roleName: loginData.Roles ? loginData.Roles[0] : undefined,\n participantId: loginData.user.ParticipantID,\n participantLanguageId: loginData.user.ParticipantCultureId,\n username: loginData.Username,\n firstName: loginData.FirstName,\n lastName: loginData.LastName,\n fullName: loginData.FirstName + \" \" + loginData.LastName,\n languageId: loginData.CultureId,\n user_token: loginData.user.user_token,\n email: loginData.Email,\n redirect: {\n assessmentRedirect: loginData.user.PQPId,\n submitRedirect: loginData.user.RedirectUrl\n },\n unknownParticipant: loginData.UnknownParticipant\n },\n };\n }\n\n public BuildMessage(error: AjaxError) {\n if (!error.response || !error.response.reason_code)\n return `Invalid Username/Password`;\n\n switch (error.response.reason_code) {\n case 0:\n return `Invalid Username/Password`;\n case 1:\n return \"Account Locked\";\n case 2:\n return \"Accound Disabled\";\n }\n }\n\n GetUserProfile(UserId: number, UserType: number) {\n return this._apiService.get({\n url: ApiRoutes.Profile.GetUserProfile,\n params: {\n UserId,\n UserType\n },\n isAuthenticated: false\n })\n }\n\n}\n","import { WindowContainer } from \"../interfaces/user.interface\";\n\nexport class LoaderService {\n $ = WindowContainer.GetWindow().$;\n defaultMessage = 'Please wait while we load the page';\n\n constructor() {\n const loader = this.$('#mrg-loader');\n if (!loader.length) {\n const body = this.$('body');\n if (body) {\n body.append(`\n
\n
\n
\n
\n
\n
\n
\n

\n
\n
`);\n }\n\n }\n }\n\n public show(hideBody = false, message = ''): void {\n const loader = this.$('#mrg-loader');\n if (loader.length) {\n if (message) {\n this.$('.loader-message').text(message);\n } else {\n this.$('.loader-message').text(this.defaultMessage);\n }\n\n setTimeout(() => {\n if (hideBody) {\n this.$('.app-header').siblings().hide();\n this.$('.app-main').siblings().hide();\n }\n\n this.$('#mrg-loader').fadeIn();\n });\n }\n }\n public hide(): void {\n setTimeout(() => {\n this.$('#mrg-loader').fadeOut();\n this.$('.app-header').siblings().fadeIn();\n this.$('.app-main').siblings().fadeIn();\n });\n }\n\n public showDefaultLoading(hideBody = false): void {\n this.show(hideBody, 'Loading...');\n }\n}","import { mergeMap } from './mergeMap';\nimport { ObservableInput, OperatorFunction, ObservedValueOf } from '../types';\nimport { isFunction } from '../util/isFunction';\n\n/* tslint:disable:max-line-length */\nexport function concatMap>(\n project: (value: T, index: number) => O\n): OperatorFunction>;\n/** @deprecated The `resultSelector` parameter will be removed in v8. Use an inner `map` instead. Details: https://rxjs.dev/deprecations/resultSelector */\nexport function concatMap>(\n project: (value: T, index: number) => O,\n resultSelector: undefined\n): OperatorFunction>;\n/** @deprecated The `resultSelector` parameter will be removed in v8. Use an inner `map` instead. Details: https://rxjs.dev/deprecations/resultSelector */\nexport function concatMap>(\n project: (value: T, index: number) => O,\n resultSelector: (outerValue: T, innerValue: ObservedValueOf, outerIndex: number, innerIndex: number) => R\n): OperatorFunction;\n/* tslint:enable:max-line-length */\n\n/**\n * Projects each source value to an Observable which is merged in the output\n * Observable, in a serialized fashion waiting for each one to complete before\n * merging the next.\n *\n * Maps each value to an Observable, then flattens all of\n * these inner Observables using {@link concatAll}.\n *\n * ![](concatMap.png)\n *\n * Returns an Observable that emits items based on applying a function that you\n * supply to each item emitted by the source Observable, where that function\n * returns an (so-called \"inner\") Observable. Each new inner Observable is\n * concatenated with the previous inner Observable.\n *\n * __Warning:__ if source values arrive endlessly and faster than their\n * corresponding inner Observables can complete, it will result in memory issues\n * as inner Observables amass in an unbounded buffer waiting for their turn to\n * be subscribed to.\n *\n * Note: `concatMap` is equivalent to `mergeMap` with concurrency parameter set\n * to `1`.\n *\n * ## Example\n *\n * For each click event, tick every second from 0 to 3, with no concurrency\n *\n * ```ts\n * import { fromEvent, concatMap, interval, take } from 'rxjs';\n *\n * const clicks = fromEvent(document, 'click');\n * const result = clicks.pipe(\n * concatMap(ev => interval(1000).pipe(take(4)))\n * );\n * result.subscribe(x => console.log(x));\n *\n * // Results in the following:\n * // (results are not concurrent)\n * // For every click on the \"document\" it will emit values 0 to 3 spaced\n * // on a 1000ms interval\n * // one click = 1000ms-> 0 -1000ms-> 1 -1000ms-> 2 -1000ms-> 3\n * ```\n *\n * @see {@link concat}\n * @see {@link concatAll}\n * @see {@link concatMapTo}\n * @see {@link exhaustMap}\n * @see {@link mergeMap}\n * @see {@link switchMap}\n *\n * @param {function(value: T, ?index: number): ObservableInput} project A function\n * that, when applied to an item emitted by the source Observable, returns an\n * Observable.\n * @return A function that returns an Observable that emits the result of\n * applying the projection function (and the optional deprecated\n * `resultSelector`) to each item emitted by the source Observable and taking\n * values from each projected inner Observable sequentially.\n */\nexport function concatMap>(\n project: (value: T, index: number) => O,\n resultSelector?: (outerValue: T, innerValue: ObservedValueOf, outerIndex: number, innerIndex: number) => R\n): OperatorFunction | R> {\n return isFunction(resultSelector) ? mergeMap(project, resultSelector, 1) : mergeMap(project, 1);\n}\n","import { ObservableInput, OperatorFunction, ObservedValueOf } from '../types';\nimport { map } from './map';\nimport { innerFrom } from '../observable/innerFrom';\nimport { operate } from '../util/lift';\nimport { mergeInternals } from './mergeInternals';\nimport { isFunction } from '../util/isFunction';\n\n/* tslint:disable:max-line-length */\nexport function mergeMap>(\n project: (value: T, index: number) => O,\n concurrent?: number\n): OperatorFunction>;\n/** @deprecated The `resultSelector` parameter will be removed in v8. Use an inner `map` instead. Details: https://rxjs.dev/deprecations/resultSelector */\nexport function mergeMap>(\n project: (value: T, index: number) => O,\n resultSelector: undefined,\n concurrent?: number\n): OperatorFunction>;\n/** @deprecated The `resultSelector` parameter will be removed in v8. Use an inner `map` instead. Details: https://rxjs.dev/deprecations/resultSelector */\nexport function mergeMap>(\n project: (value: T, index: number) => O,\n resultSelector: (outerValue: T, innerValue: ObservedValueOf, outerIndex: number, innerIndex: number) => R,\n concurrent?: number\n): OperatorFunction;\n/* tslint:enable:max-line-length */\n\n/**\n * Projects each source value to an Observable which is merged in the output\n * Observable.\n *\n * Maps each value to an Observable, then flattens all of\n * these inner Observables using {@link mergeAll}.\n *\n * ![](mergeMap.png)\n *\n * Returns an Observable that emits items based on applying a function that you\n * supply to each item emitted by the source Observable, where that function\n * returns an Observable, and then merging those resulting Observables and\n * emitting the results of this merger.\n *\n * ## Example\n *\n * Map and flatten each letter to an Observable ticking every 1 second\n *\n * ```ts\n * import { of, mergeMap, interval, map } from 'rxjs';\n *\n * const letters = of('a', 'b', 'c');\n * const result = letters.pipe(\n * mergeMap(x => interval(1000).pipe(map(i => x + i)))\n * );\n *\n * result.subscribe(x => console.log(x));\n *\n * // Results in the following:\n * // a0\n * // b0\n * // c0\n * // a1\n * // b1\n * // c1\n * // continues to list a, b, c every second with respective ascending integers\n * ```\n *\n * @see {@link concatMap}\n * @see {@link exhaustMap}\n * @see {@link merge}\n * @see {@link mergeAll}\n * @see {@link mergeMapTo}\n * @see {@link mergeScan}\n * @see {@link switchMap}\n *\n * @param {function(value: T, ?index: number): ObservableInput} project A function\n * that, when applied to an item emitted by the source Observable, returns an\n * Observable.\n * @param {number} [concurrent=Infinity] Maximum number of input\n * Observables being subscribed to concurrently.\n * @return A function that returns an Observable that emits the result of\n * applying the projection function (and the optional deprecated\n * `resultSelector`) to each item emitted by the source Observable and merging\n * the results of the Observables obtained from this transformation.\n */\nexport function mergeMap>(\n project: (value: T, index: number) => O,\n resultSelector?: ((outerValue: T, innerValue: ObservedValueOf, outerIndex: number, innerIndex: number) => R) | number,\n concurrent: number = Infinity\n): OperatorFunction | R> {\n if (isFunction(resultSelector)) {\n // DEPRECATED PATH\n return mergeMap((a, i) => map((b: any, ii: number) => resultSelector(a, b, i, ii))(innerFrom(project(a, i))), concurrent);\n } else if (typeof resultSelector === 'number') {\n concurrent = resultSelector;\n }\n\n return operate((source, subscriber) => mergeInternals(source, subscriber, project, concurrent));\n}\n","import { Observable } from '../Observable';\nimport { innerFrom } from '../observable/innerFrom';\nimport { Subscriber } from '../Subscriber';\nimport { ObservableInput, SchedulerLike } from '../types';\nimport { executeSchedule } from '../util/executeSchedule';\nimport { createOperatorSubscriber } from './OperatorSubscriber';\n\n/**\n * A process embodying the general \"merge\" strategy. This is used in\n * `mergeMap` and `mergeScan` because the logic is otherwise nearly identical.\n * @param source The original source observable\n * @param subscriber The consumer subscriber\n * @param project The projection function to get our inner sources\n * @param concurrent The number of concurrent inner subscriptions\n * @param onBeforeNext Additional logic to apply before nexting to our consumer\n * @param expand If `true` this will perform an \"expand\" strategy, which differs only\n * in that it recurses, and the inner subscription must be schedule-able.\n * @param innerSubScheduler A scheduler to use to schedule inner subscriptions,\n * this is to support the expand strategy, mostly, and should be deprecated\n */\nexport function mergeInternals(\n source: Observable,\n subscriber: Subscriber,\n project: (value: T, index: number) => ObservableInput,\n concurrent: number,\n onBeforeNext?: (innerValue: R) => void,\n expand?: boolean,\n innerSubScheduler?: SchedulerLike,\n additionalFinalizer?: () => void\n) {\n // Buffered values, in the event of going over our concurrency limit\n const buffer: T[] = [];\n // The number of active inner subscriptions.\n let active = 0;\n // An index to pass to our accumulator function\n let index = 0;\n // Whether or not the outer source has completed.\n let isComplete = false;\n\n /**\n * Checks to see if we can complete our result or not.\n */\n const checkComplete = () => {\n // If the outer has completed, and nothing is left in the buffer,\n // and we don't have any active inner subscriptions, then we can\n // Emit the state and complete.\n if (isComplete && !buffer.length && !active) {\n subscriber.complete();\n }\n };\n\n // If we're under our concurrency limit, just start the inner subscription, otherwise buffer and wait.\n const outerNext = (value: T) => (active < concurrent ? doInnerSub(value) : buffer.push(value));\n\n const doInnerSub = (value: T) => {\n // If we're expanding, we need to emit the outer values and the inner values\n // as the inners will \"become outers\" in a way as they are recursively fed\n // back to the projection mechanism.\n expand && subscriber.next(value as any);\n\n // Increment the number of active subscriptions so we can track it\n // against our concurrency limit later.\n active++;\n\n // A flag used to show that the inner observable completed.\n // This is checked during finalization to see if we should\n // move to the next item in the buffer, if there is on.\n let innerComplete = false;\n\n // Start our inner subscription.\n innerFrom(project(value, index++)).subscribe(\n createOperatorSubscriber(\n subscriber,\n (innerValue) => {\n // `mergeScan` has additional handling here. For example\n // taking the inner value and updating state.\n onBeforeNext?.(innerValue);\n\n if (expand) {\n // If we're expanding, then just recurse back to our outer\n // handler. It will emit the value first thing.\n outerNext(innerValue as any);\n } else {\n // Otherwise, emit the inner value.\n subscriber.next(innerValue);\n }\n },\n () => {\n // Flag that we have completed, so we know to check the buffer\n // during finalization.\n innerComplete = true;\n },\n // Errors are passed to the destination.\n undefined,\n () => {\n // During finalization, if the inner completed (it wasn't errored or\n // cancelled), then we want to try the next item in the buffer if\n // there is one.\n if (innerComplete) {\n // We have to wrap this in a try/catch because it happens during\n // finalization, possibly asynchronously, and we want to pass\n // any errors that happen (like in a projection function) to\n // the outer Subscriber.\n try {\n // INNER SOURCE COMPLETE\n // Decrement the active count to ensure that the next time\n // we try to call `doInnerSub`, the number is accurate.\n active--;\n // If we have more values in the buffer, try to process those\n // Note that this call will increment `active` ahead of the\n // next conditional, if there were any more inner subscriptions\n // to start.\n while (buffer.length && active < concurrent) {\n const bufferedValue = buffer.shift()!;\n // Particularly for `expand`, we need to check to see if a scheduler was provided\n // for when we want to start our inner subscription. Otherwise, we just start\n // are next inner subscription.\n if (innerSubScheduler) {\n executeSchedule(subscriber, innerSubScheduler, () => doInnerSub(bufferedValue));\n } else {\n doInnerSub(bufferedValue);\n }\n }\n // Check to see if we can complete, and complete if so.\n checkComplete();\n } catch (err) {\n subscriber.error(err);\n }\n }\n }\n )\n );\n };\n\n // Subscribe to our source observable.\n source.subscribe(\n createOperatorSubscriber(subscriber, outerNext, () => {\n // Outer completed, make a note of it, and check to see if we can complete everything.\n isComplete = true;\n checkComplete();\n })\n );\n\n // Additional finalization (for when the destination is torn down).\n // Other finalization is added implicitly via subscription above.\n return () => {\n additionalFinalizer?.();\n };\n}\n","/*!\n * cookie\n * Copyright(c) 2012-2014 Roman Shtylman\n * Copyright(c) 2015 Douglas Christopher Wilson\n * MIT Licensed\n */\n\n'use strict';\n\n/**\n * Module exports.\n * @public\n */\n\nexports.parse = parse;\nexports.serialize = serialize;\n\n/**\n * Module variables.\n * @private\n */\n\nvar decode = decodeURIComponent;\nvar encode = encodeURIComponent;\n\n/**\n * RegExp to match field-content in RFC 7230 sec 3.2\n *\n * field-content = field-vchar [ 1*( SP / HTAB ) field-vchar ]\n * field-vchar = VCHAR / obs-text\n * obs-text = %x80-FF\n */\n\nvar fieldContentRegExp = /^[\\u0009\\u0020-\\u007e\\u0080-\\u00ff]+$/;\n\n/**\n * Parse a cookie header.\n *\n * Parse the given cookie header string into an object\n * The object has the various cookies as keys(names) => values\n *\n * @param {string} str\n * @param {object} [options]\n * @return {object}\n * @public\n */\n\nfunction parse(str, options) {\n if (typeof str !== 'string') {\n throw new TypeError('argument str must be a string');\n }\n\n var obj = {}\n var opt = options || {};\n var pairs = str.split(';')\n var dec = opt.decode || decode;\n\n for (var i = 0; i < pairs.length; i++) {\n var pair = pairs[i];\n var index = pair.indexOf('=')\n\n // skip things that don't look like key=value\n if (index < 0) {\n continue;\n }\n\n var key = pair.substring(0, index).trim()\n\n // only assign once\n if (undefined == obj[key]) {\n var val = pair.substring(index + 1, pair.length).trim()\n\n // quoted values\n if (val[0] === '\"') {\n val = val.slice(1, -1)\n }\n\n obj[key] = tryDecode(val, dec);\n }\n }\n\n return obj;\n}\n\n/**\n * Serialize data into a cookie header.\n *\n * Serialize the a name value pair into a cookie string suitable for\n * http headers. An optional options object specified cookie parameters.\n *\n * serialize('foo', 'bar', { httpOnly: true })\n * => \"foo=bar; httpOnly\"\n *\n * @param {string} name\n * @param {string} val\n * @param {object} [options]\n * @return {string}\n * @public\n */\n\nfunction serialize(name, val, options) {\n var opt = options || {};\n var enc = opt.encode || encode;\n\n if (typeof enc !== 'function') {\n throw new TypeError('option encode is invalid');\n }\n\n if (!fieldContentRegExp.test(name)) {\n throw new TypeError('argument name is invalid');\n }\n\n var value = enc(val);\n\n if (value && !fieldContentRegExp.test(value)) {\n throw new TypeError('argument val is invalid');\n }\n\n var str = name + '=' + value;\n\n if (null != opt.maxAge) {\n var maxAge = opt.maxAge - 0;\n\n if (isNaN(maxAge) || !isFinite(maxAge)) {\n throw new TypeError('option maxAge is invalid')\n }\n\n str += '; Max-Age=' + Math.floor(maxAge);\n }\n\n if (opt.domain) {\n if (!fieldContentRegExp.test(opt.domain)) {\n throw new TypeError('option domain is invalid');\n }\n\n str += '; Domain=' + opt.domain;\n }\n\n if (opt.path) {\n if (!fieldContentRegExp.test(opt.path)) {\n throw new TypeError('option path is invalid');\n }\n\n str += '; Path=' + opt.path;\n }\n\n if (opt.expires) {\n if (typeof opt.expires.toUTCString !== 'function') {\n throw new TypeError('option expires is invalid');\n }\n\n str += '; Expires=' + opt.expires.toUTCString();\n }\n\n if (opt.httpOnly) {\n str += '; HttpOnly';\n }\n\n if (opt.secure) {\n str += '; Secure';\n }\n\n if (opt.sameSite) {\n var sameSite = typeof opt.sameSite === 'string'\n ? opt.sameSite.toLowerCase() : opt.sameSite;\n\n switch (sameSite) {\n case true:\n str += '; SameSite=Strict';\n break;\n case 'lax':\n str += '; SameSite=Lax';\n break;\n case 'strict':\n str += '; SameSite=Strict';\n break;\n case 'none':\n str += '; SameSite=None';\n break;\n default:\n throw new TypeError('option sameSite is invalid');\n }\n }\n\n return str;\n}\n\n/**\n * Try decoding a string using a decoding function.\n *\n * @param {string} str\n * @param {function} decode\n * @private\n */\n\nfunction tryDecode(str, decode) {\n try {\n return decode(str);\n } catch (e) {\n return str;\n }\n}\n"],"names":["KeyType","readCookie","value","options","cleanValue","substr","cleanupCookieValue","doNotParse","isParsingCookie","JSON","parse","e","__assign","Object","assign","t","s","i","n","arguments","length","p","prototype","hasOwnProperty","call","apply","this","Cookies","cookies","_this","changeListeners","HAS_DOCUMENT_COOKIE","cookie","parseCookies","Promise","document","catch","_updateBrowserValues","parseOptions","_emitChange","params","get","name","getAll","result","name_1","set","_a","stringify","remove","finalOptions","expires","Date","maxAge","undefined","addChangeListener","callback","push","removeChangeListener","idx","indexOf","splice","CookiesContext","React","Provider","Consumer","useCookies","dependencies","useContext","Error","initialCookies","useState","allCookies","setCookies","previousCookiesRef","useRef","window","createElement","useLayoutEffect","onChange","newCookies","oldCookies","_i","dependencies_1","dependency","shouldUpdate","current","useMemo","bind","Login","setCookie","removeCookie","usernameFromCookie","QuestUsername","useParams","dispatch","useAppDispatch","usernameFromUrl","username","URLSearchParams","location","search","encryptedPqp","firstName","setFirstName","message","setMessage","showPassword","setShowPassword","loading","setLoading","loginService","LoginService","password","loginData","setLoginData","rememberMe","setRememberMe","dispatchable","setDispatchable","loaderService","LoaderService","userLoginData","doLogin","event","preventDefault","pipe","concatMap","obs","response","GetUserProfile","user","UserID","UserType","subscribe","next","processSuccess","error","console","log","processFailure","path","resetPassword","href","reset_token","redirectToReset","DispatchLogin","previousState","Password","BuildMessage","useEffect","hide","GetUserFromUsername","FirstName","Username","GetUserFromEncryptedPqp","type","login","payload","Fragment","className","id","onKeyPress","target","DetermineKeyPressed","key","onSubmit","htmlFor","onClick","route","split","pop","join","handleNotYou","icon","faUser","placeholder","input","required","disabled","to","faKey","faEyeSlash","faEye","checked","_apiService","NewApiService","setOptions","handleErrors","keyType","post","url","ApiRoutes","data","email","isAuthenticated","encrypted","EncryptedPqp","role","RoleId","roleName","Roles","participantId","ParticipantID","participantLanguageId","ParticipantCultureId","lastName","LastName","fullName","languageId","CultureId","user_token","Email","redirect","assessmentRedirect","PQPId","submitRedirect","RedirectUrl","unknownParticipant","UnknownParticipant","reason_code","UserId","$","WindowContainer","defaultMessage","body","append","hideBody","loader","text","setTimeout","siblings","fadeIn","fadeOut","show","project","resultSelector","isFunction","mergeMap","concurrent","a","map","b","ii","innerFrom","operate","source","subscriber","onBeforeNext","expand","innerSubScheduler","additionalFinalizer","buffer","active","index","isComplete","checkComplete","complete","outerNext","doInnerSub","innerComplete","createOperatorSubscriber","innerValue","bufferedValue","shift","executeSchedule","err","mergeInternals","exports","str","TypeError","obj","opt","pairs","dec","decode","pair","substring","trim","val","slice","tryDecode","enc","encode","fieldContentRegExp","test","isNaN","isFinite","Math","floor","domain","toUTCString","httpOnly","secure","sameSite","toLowerCase","decodeURIComponent","encodeURIComponent"],"sourceRoot":""}