{"version":3,"sources":["constants.ts","utilities/helpers.ts","App.tsx","index.tsx"],"names":["process","REACT_APP_QR_TIMEOUT","REACT_APP_STATUS_POLLING","REACT_APP_ACCOUNT_API_URL","REACT_APP_IDENTITY_MATRIX_API_URL","REACT_APP_IDENTITY_AEGON_API_URL","REACT_APP_BASE_URL","REACT_APP_BASE_URL_AEGONBANK","API_IDP_MTX_BASE_PATH","API_ACCOUNT_BASE_PATH","API_IDP_AEG_BASE_PATH","parseNumericEnvVars","pollingTime","qrTimeoutTime","QR_CODE_TIMEOUT","QR_STATUS_POLLING","BASE_ROUTER_URL","BASE_ROUTER_URL_AEGONBANK","API_ERROR_PASSWORD_EXPIRED","API_ERROR_INVALID_CREDENTIALS","PASSWORD_EXPIRED_MESSAGE","INVALID_CREDENTIALS_MESSAGE","GENERIC_LOGIN_ERROR_MESSAGE","INVALID_CHARACTER_ERROR_MESSAGE","REQUIRED_FIELD_EMPTY_ERROR_MESSAGE","PERMISSION_REQUEST","IS_REQUESTING_YOUR_PERMISSION","REMEMBER_MY_DECISION","DO_NOT_ALLOW","YES_ALLOW","PERMISSION_REQUIRED","ACCESS_EXPIRES_ON","ACCESS_NEVER_EXPIRE","ALLOW_BUTTON_ID","DO_NOT_ALLOW_BUTTON_ID","REMEMBER_CONSENT_ID","SUPPORT_START","SUPPORT_END_OLD","SUPPORT_END_NEW","SUPPORT_END_CHANGE","Date","IDP_MTX_XSRF_COOKIE_NAME","IDP_MTX_XSRF_HEADER_NAME","ACCOUNT_XSRF_COOKIE_NAME","ACCOUNT_XSRF_HEADER_NAME","PAGE_NOT_FOUND_ERROR","GENERIC_ERROR","PAGE_NOT_FOUND_ERROR_TITLE","GENERIC_ERROR_TITLE","CLOSE_MOBILE_VIEW_BUTTON_ID","CLOSE","CLOSE_MOBILE_VIEW_DEEPLINK","CONSENT_VALID_UNTIL_FORMAT","OPEN_MOBILE_APP","values","map","value","numericValue","parseInt","Number","isNaN","getAvailabilityTime","oldTime","newTime","changeDate","currentDate","isString","getXsrfHeaders","header","cookie","headers","name","nameLengthPlus","length","document","split","c","trim","filter","substring","decodeURIComponent","substr","getCookie","knabStyleCache","createCache","key","nonce","window","EMOTIONJS_NONCE","aegonbankStyleCache","LoadKnab","React","lazy","LoadAegonbank","fallbackLoader","style","position","inset","display","alignItems","justifyContent","LoaderLiquid","color","App","theme","themeLight","className","path","render","Suspense","fallback","ReactDOM","getElementById"],"mappings":"kIAAA,o6CAEA,EAQIA,sYAPFC,EADF,EACEA,qBACAC,EAFF,EAEEA,yBACAC,EAHF,EAGEA,0BACAC,EAJF,EAIEA,kCACAC,EALF,EAKEA,iCACAC,EANF,EAMEA,mBACAC,EAPF,EAOEA,6BASWC,EAAwBJ,EACxBK,EAAwBN,EACxBO,EAAwBL,EAErC,EAAuCM,YAAoB,CACzDV,uBACAC,6BAFMU,EAAR,EAAQA,YAAaC,EAArB,EAAqBA,cAMRC,EAAe,OAAGD,QAAH,IAAGA,IAAiB,IAGnCE,EAAiB,OAAGH,QAAH,IAAGA,IAAe,IAGnCI,EAAkBV,EAClBW,EAA4BV,EAE5BW,EAA6B,kBAC7BC,EAAgC,qBAChCC,EACX,kMAEWC,EACX,yFACWC,EACX,qDAEWC,EACX,6EACWC,EACX,iDAEWC,EAAqB,sCACrBC,EACX,+BAEWC,EAAuB,0BACvBC,EAAe,qBACfC,EAAY,eACZC,EAAsB,cAEtBC,EAAoB,yBACpBC,EACX,kDAEWC,EAAkB,qBAClBC,EAAyB,0BACzBC,EAAsB,0BAEtBC,EAAgB,EAChBC,EAAkB,GAClBC,EAAkB,GAClBC,EAAqB,IAAIC,KAAK,KAAM,EAAG,GAEvCC,EAA2B,mBAC3BC,EAA2B,qBAC3BC,EAA2B,kBAC3BC,EAA2B,oBAE3BC,EACX,+CACWC,EACX,oDACWC,EAA6B,aAC7BC,EAAsB,QAEtBC,EAA8B,wBAC9BC,EAAQ,UACRC,GAA6B,6BAE7BC,GAA6B,aAI7BC,GAAkB,iB,sLC1FxB,SAAS1C,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kBACN,cAAC,IAAD,CAAepD,MAAOiC,EAAtB,SACE,cAAC,IAAMoB,SAAP,CAAgBC,SAAUhB,EAA1B,SACE,cAACD,EAAD,WAMR,cAAC,IAAD,CACEc,KAAK,IACLC,OAAQ,kBACN,cAAC,IAAD,CAAepD,MAAO2B,EAAtB,SACE,cAAC,IAAM0B,SAAP,CAAgBC,SAAUhB,EAA1B,SACE,cAACJ,EAAD,qB,OCpDpBqB,IAASH,OAAO,cAAC,EAAD,IAASlC,SAASsC,eAAe,W","file":"static/js/main.c18deeb9.chunk.js","sourcesContent":["import { parseNumericEnvVars } from './utilities/helpers';\n\nconst {\n REACT_APP_QR_TIMEOUT,\n REACT_APP_STATUS_POLLING,\n REACT_APP_ACCOUNT_API_URL,\n REACT_APP_IDENTITY_MATRIX_API_URL,\n REACT_APP_IDENTITY_AEGON_API_URL,\n REACT_APP_BASE_URL,\n REACT_APP_BASE_URL_AEGONBANK\n} = process.env;\n\nexport const ANDROID_APP_STORE_URL =\n 'https://play.google.com/store/apps/details?id=bvm.bvmapp';\nexport const IOS_APP_STORE_URL =\n 'https://apps.apple.com/nl/app/knab-bankieren/id529493145';\n\n/** Base URL that will be appended at the beginning of every API call */\nexport const API_IDP_MTX_BASE_PATH = REACT_APP_IDENTITY_MATRIX_API_URL;\nexport const API_ACCOUNT_BASE_PATH = REACT_APP_ACCOUNT_API_URL;\nexport const API_IDP_AEG_BASE_PATH = REACT_APP_IDENTITY_AEGON_API_URL;\n\nconst { pollingTime, qrTimeoutTime } = parseNumericEnvVars({\n REACT_APP_QR_TIMEOUT,\n REACT_APP_STATUS_POLLING,\n});\n\n/** Time in milliseconds for the current QR time to expire */\nexport const QR_CODE_TIMEOUT = qrTimeoutTime ?? 30000;\n\n/** How often (in milliseconds) the client will poll for changes */\nexport const QR_STATUS_POLLING = pollingTime ?? 2000;\n\n/** Represents the path where the base path where the app will be deployed */\nexport const BASE_ROUTER_URL = REACT_APP_BASE_URL;\nexport const BASE_ROUTER_URL_AEGONBANK = REACT_APP_BASE_URL_AEGONBANK;\n\nexport const API_ERROR_PASSWORD_EXPIRED = 'PasswordExpired';\nexport const API_ERROR_INVALID_CREDENTIALS = 'InvalidCredentials';\nexport const PASSWORD_EXPIRED_MESSAGE =\n 'Je wachtwoord is verlopen. Log in op https://persoonlijk.knab.nl/inloggen en wijzig je wachtwoord.';\nexport const INVALID_CREDENTIALS_MESSAGE =\n 'Het inloggen is helaas niet gelukt. Je gebruikersnaam en/ of wachtwoord is niet juist.';\nexport const GENERIC_LOGIN_ERROR_MESSAGE =\n 'Er is iets fout gegaan, probeer het later opnieuw.';\n\nexport const INVALID_CHARACTER_ERROR_MESSAGE =\n 'Je hebt een niet-toegestaan teken gebruikt, pas alsjeblieft je invoer aan.';\nexport const REQUIRED_FIELD_EMPTY_ERROR_MESSAGE =\n 'Dit veld is verplicht, vul het alsjeblieft in.';\n\nexport const PERMISSION_REQUEST = 'Er wordt gevraagd om je toestemming';\nexport const IS_REQUESTING_YOUR_PERMISSION =\n 'Je rekeninginformatie delen:';\nexport const PERSONAL_INFORMATION = 'Persoonlijke informatie';\nexport const REMEMBER_MY_DECISION = 'Onthoud Mijn Beslissing';\nexport const DO_NOT_ALLOW = 'Nee, Niet Toestaan';\nexport const YES_ALLOW = 'Ja, Toestaan';\nexport const PERMISSION_REQUIRED = '(verplicht)';\n\nexport const ACCESS_EXPIRES_ON = 'De toegang verloopt op';\nexport const ACCESS_NEVER_EXPIRE =\n 'De toegang stopt als jij je toestemming intrekt';\n\nexport const ALLOW_BUTTON_ID = 'allowConsentButton';\nexport const DO_NOT_ALLOW_BUTTON_ID = 'doNotAllowConsentButton';\nexport const REMEMBER_CONSENT_ID = 'rememberConsentCheckbox';\n\nexport const SUPPORT_START = 8;\nexport const SUPPORT_END_OLD = 22;\nexport const SUPPORT_END_NEW = 20;\nexport const SUPPORT_END_CHANGE = new Date(2021, 1, 1); // 01 feb 2021\n\nexport const IDP_MTX_XSRF_COOKIE_NAME = 'XSRF-TOKEN-IDMTX';\nexport const IDP_MTX_XSRF_HEADER_NAME = 'X-XSRF-TOKEN-IDMTX';\nexport const ACCOUNT_XSRF_COOKIE_NAME = 'XSRF-TOKEN-ACCT';\nexport const ACCOUNT_XSRF_HEADER_NAME = 'X-XSRF-TOKEN-ACCT';\n\nexport const PAGE_NOT_FOUND_ERROR =\n 'Oeps! Dit is niet de pagina die jij zoekt...';\nexport const GENERIC_ERROR =\n 'Sorry, er ging iets verkeerd. Probeer het opnieuw';\nexport const PAGE_NOT_FOUND_ERROR_TITLE = 'Error #404';\nexport const GENERIC_ERROR_TITLE = 'Error';\n\nexport const CLOSE_MOBILE_VIEW_BUTTON_ID = 'closeMobileViewButton';\nexport const CLOSE = 'Sluiten';\nexport const CLOSE_MOBILE_VIEW_DEEPLINK = 'knabapp://deeplink/dismiss';\n\nexport const CONSENT_VALID_UNTIL_FORMAT = 'dd/MM/yyyy';\nexport const DOWNLOAD_ON_MOBILE = 'Download op je mobiel';\n\nexport const MOBILE_DEEPLINK_SCHEME = 'knabapp://';\nexport const OPEN_MOBILE_APP = 'Open Knab App';\n","/**\n * Parse expected process.env numeric values. When one of the values is undefined\n * or not a valid number, `null` will be returned instead.\n */\nexport function parseNumericEnvVars(\n values: IParseNumericEnvVars,\n): IParseNumericEnvVarsReturnValue {\n const { REACT_APP_QR_TIMEOUT, REACT_APP_STATUS_POLLING } = values;\n\n const [qrTimeoutTime, pollingTime] = [\n REACT_APP_QR_TIMEOUT,\n REACT_APP_STATUS_POLLING,\n ].map(value => {\n if (value == null) return null;\n const numericValue = parseInt(value, 10);\n\n return !Number.isNaN(numericValue) ? numericValue : null;\n });\n\n return { qrTimeoutTime, pollingTime };\n}\n\ninterface IParseNumericEnvVars {\n REACT_APP_QR_TIMEOUT?: string;\n REACT_APP_STATUS_POLLING?: string;\n}\n\ninterface IParseNumericEnvVarsReturnValue {\n qrTimeoutTime: number | null;\n pollingTime: number | null;\n}\n\nexport const getAvailabilityTime = (\n oldTime: number,\n newTime: number,\n changeDate: Date,\n currentDate: Date,\n): number => (currentDate >= changeDate ? newTime : oldTime);\n\nexport const isString = (value: unknown): value is string =>\n typeof value === 'string';\n\nexport const getCookie = (name: string): string | null => {\n const nameLengthPlus = name.length + 1;\n\n return (\n document.cookie\n .split(';')\n .map(c => c.trim())\n .filter(c => c.substring(0, nameLengthPlus) === `${name}=`)\n .map(c => decodeURIComponent(c.substr(nameLengthPlus)))[0] || null\n );\n};\n\nexport const getXsrfHeaders = (\n header: string,\n cookie: string,\n): { [key: string]: string | null } => {\n const headers: { [key: string]: string | null } = {};\n headers[header] = getCookie(cookie);\n return headers;\n};\n","import React from 'react';\nimport { Switch, Route, BrowserRouter } from 'react-router-dom';\nimport { ThemeProvider, CacheProvider } from '@emotion/react';\nimport createCache from '@emotion/cache';\nimport { themeLight } from '@knab/frontend/styles/themes';\n\nimport { LoaderLiquid } from '@knab/frontend/components/LoaderLiquid';\nimport { BASE_ROUTER_URL_AEGONBANK } from './constants';\n\ndeclare global {\n interface Window {\n EMOTIONJS_NONCE: string;\n }\n}\n\nconst knabStyleCache = createCache({\n key: 'knab',\n nonce: window.EMOTIONJS_NONCE || '',\n});\nconst aegonbankStyleCache = createCache({\n key: 'aegonbank',\n nonce: window.EMOTIONJS_NONCE || '',\n});\n\nconst LoadKnab = React.lazy(() => import('./modules/knab/Knab'));\nconst LoadAegonbank = React.lazy(() => import('./modules/aegonbank/Aegonbank'));\nconst fallbackLoader = (\n \n \n \n);\n\nconst App = (): JSX.Element => {\n return (\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\nexport default App;\n","import 'react-app-polyfill/ie11';\nimport 'react-app-polyfill/stable';\n\nimport React from 'react';\nimport ReactDOM from 'react-dom';\n\nimport App from './App';\n\nimport './index.scss';\n\nReactDOM.render(, document.getElementById('root'));\n"],"sourceRoot":""}