@auth0/auth0-angular 2.2.2 → 2.3.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (33) hide show
  1. package/README.md +1 -1
  2. package/esm2022/lib/abstract-navigator.mjs +35 -0
  3. package/esm2022/lib/auth.client.mjs +23 -0
  4. package/esm2022/lib/auth.config.mjs +97 -0
  5. package/esm2022/lib/auth.guard.mjs +40 -0
  6. package/esm2022/lib/auth.interceptor.mjs +134 -0
  7. package/{esm2020 → esm2022}/lib/auth.module.mjs +5 -5
  8. package/esm2022/lib/auth.service.mjs +233 -0
  9. package/{esm2020 → esm2022}/lib/auth.state.mjs +6 -6
  10. package/esm2022/lib/interfaces.mjs +2 -0
  11. package/esm2022/public-api.mjs +16 -0
  12. package/{esm2020 → esm2022}/useragent.mjs +2 -2
  13. package/{fesm2020 → fesm2022}/auth0-auth0-angular.mjs +40 -37
  14. package/fesm2022/auth0-auth0-angular.mjs.map +1 -0
  15. package/lib/auth.config.d.ts +1 -1
  16. package/lib/auth.guard.d.ts +2 -2
  17. package/package.json +7 -13
  18. package/public-api.d.ts +2 -1
  19. package/esm2020/lib/abstract-navigator.mjs +0 -35
  20. package/esm2020/lib/auth.client.mjs +0 -23
  21. package/esm2020/lib/auth.config.mjs +0 -97
  22. package/esm2020/lib/auth.guard.mjs +0 -36
  23. package/esm2020/lib/auth.interceptor.mjs +0 -134
  24. package/esm2020/lib/auth.service.mjs +0 -233
  25. package/esm2020/lib/interfaces.mjs +0 -2
  26. package/esm2020/public-api.mjs +0 -15
  27. package/fesm2015/auth0-auth0-angular.mjs +0 -736
  28. package/fesm2015/auth0-auth0-angular.mjs.map +0 -1
  29. package/fesm2020/auth0-auth0-angular.mjs.map +0 -1
  30. /package/{esm2020 → esm2022}/auth0-auth0-angular.mjs +0 -0
  31. /package/{esm2020 → esm2022}/lib/functional.mjs +0 -0
  32. /package/{esm2020 → esm2022}/lib/provide.mjs +0 -0
  33. /package/{auth0-auth0-angular.d.ts → index.d.ts} +0 -0
@@ -1 +0,0 @@
1
- {"version":3,"file":"auth0-auth0-angular.mjs","sources":["../../../projects/auth0-angular/src/useragent.ts","../../../projects/auth0-angular/src/lib/auth.client.ts","../../../projects/auth0-angular/src/lib/auth.config.ts","../../../projects/auth0-angular/src/lib/abstract-navigator.ts","../../../projects/auth0-angular/src/lib/auth.state.ts","../../../projects/auth0-angular/src/lib/auth.service.ts","../../../projects/auth0-angular/src/lib/auth.guard.ts","../../../projects/auth0-angular/src/lib/auth.module.ts","../../../projects/auth0-angular/src/lib/auth.interceptor.ts","../../../projects/auth0-angular/src/lib/provide.ts","../../../projects/auth0-angular/src/lib/functional.ts","../../../projects/auth0-angular/src/public-api.ts","../../../projects/auth0-angular/src/auth0-auth0-angular.ts"],"sourcesContent":["export default { name: '@auth0/auth0-angular', version: '2.2.2' };\n","import { InjectionToken, VERSION } from '@angular/core';\nimport { Auth0Client } from '@auth0/auth0-spa-js';\nimport { AuthClientConfig } from './auth.config';\nimport useragent from '../useragent';\n\nexport class Auth0ClientFactory {\n static createClient(configFactory: AuthClientConfig): Auth0Client {\n const config = configFactory.get();\n\n if (!config) {\n throw new Error(\n 'Configuration must be specified either through AuthModule.forRoot or through AuthClientConfig.set'\n );\n }\n\n return new Auth0Client({\n ...config,\n auth0Client: {\n name: useragent.name,\n version: useragent.version,\n env: {\n 'angular/core': VERSION.full,\n },\n },\n });\n }\n}\n\nexport const Auth0ClientService = new InjectionToken<Auth0Client>(\n 'auth0.client'\n);\n","import {\n Auth0ClientOptions,\n CacheLocation,\n GetTokenSilentlyOptions,\n ICache,\n} from '@auth0/auth0-spa-js';\n\nimport { InjectionToken, Injectable, Optional, Inject } from '@angular/core';\n\n/**\n * Defines a common set of HTTP methods.\n */\nexport const enum HttpMethod {\n Get = 'GET',\n Post = 'POST',\n Put = 'PUT',\n Patch = 'PATCH',\n Delete = 'DELETE',\n Head = 'HEAD',\n}\n\n/**\n * Defines the type for a route config entry. Can either be:\n *\n * - an object of type HttpInterceptorRouteConfig\n * - a string\n */\nexport type ApiRouteDefinition = HttpInterceptorRouteConfig | string;\n\n/**\n * A custom type guard to help identify route definitions that are actually HttpInterceptorRouteConfig types.\n *\n * @param def The route definition type\n */\nexport function isHttpInterceptorRouteConfig(\n def: ApiRouteDefinition\n): def is HttpInterceptorRouteConfig {\n return typeof def !== 'string';\n}\n\n/**\n * Configuration for the HttpInterceptor\n */\nexport interface HttpInterceptorConfig {\n allowedList: ApiRouteDefinition[];\n}\n\n/**\n * Configuration for a single interceptor route\n */\nexport interface HttpInterceptorRouteConfig {\n /**\n * The URL to test, by supplying the URL to match.\n * If `test` is a match for the current request path from the HTTP client, then\n * an access token is attached to the request in the\n * [\"Authorization\" header](https://tools.ietf.org/html/draft-ietf-oauth-v2-bearer-20#section-2.1).\n *\n * If the test does not pass, the request proceeds without the access token attached.\n *\n * A wildcard character can be used to match only the start of the URL.\n *\n * @usagenotes\n *\n * '/api' - exactly match the route /api\n * '/api/*' - match any route that starts with /api/\n */\n uri?: string;\n\n /**\n * A function that will be called with the HttpRequest.url value, allowing you to do\n * any kind of flexible matching.\n *\n * If this function returns true, then\n * an access token is attached to the request in the\n * [\"Authorization\" header](https://tools.ietf.org/html/draft-ietf-oauth-v2-bearer-20#section-2.1).\n *\n * If it returns false, the request proceeds without the access token attached.\n */\n uriMatcher?: (uri: string) => boolean;\n\n /**\n * The options that are passed to the SDK when retrieving the\n * access token to attach to the outgoing request.\n */\n tokenOptions?: GetTokenSilentlyOptions;\n\n /**\n * The HTTP method to match on. If specified, the HTTP method of\n * the outgoing request will be checked against this. If there is no match, the\n * Authorization header is not attached.\n *\n * The HTTP method name is case-sensitive.\n */\n httpMethod?: HttpMethod | string;\n\n /**\n * Allow the HTTP call to be executed anonymously, when no token is available.\n *\n * When omitted (or set to false), calls that match the configuration will fail when no token is available.\n */\n allowAnonymous?: boolean;\n}\n\n/**\n * Configuration for the authentication service\n */\nexport interface AuthConfig extends Auth0ClientOptions {\n /**\n * By default, if the page URL has code and state parameters, the SDK will assume they are for\n * an Auth0 application and attempt to exchange the code for a token.\n * In some cases the code might be for something else (e.g. another OAuth SDK). In these\n * instances you can instruct the client to ignore them by setting `skipRedirectCallback`.\n *\n * ```js\n * AuthModule.forRoot({\n * skipRedirectCallback: window.location.pathname === '/other-callback'\n * })\n * ```\n *\n * **Note**: In the above example, `/other-callback` is an existing route that will be called\n * by any other OAuth provider with a `code` (or `error` in case when something went wrong) and `state`.\n *\n */\n skipRedirectCallback?: boolean;\n\n /**\n * Configuration for the built-in Http Interceptor, used for\n * automatically attaching access tokens.\n */\n httpInterceptor?: HttpInterceptorConfig;\n\n /**\n * Path in your application to redirect to when the Authorization server\n * returns an error. Defaults to `/`\n */\n errorPath?: string;\n}\n\n/**\n * Angular specific state to be stored before redirect\n */\nexport interface AppState {\n /**\n * Target path the app gets routed to after\n * handling the callback from Auth0 (defaults to '/')\n */\n target?: string;\n\n /**\n * Any custom parameter to be stored in appState\n */\n [key: string]: any;\n}\n\n/**\n * Injection token for accessing configuration.\n *\n * @usageNotes\n *\n * Use the `Inject` decorator to access the configuration from a service or component:\n *\n * ```\n * class MyService(@Inject(AuthConfigService) config: AuthConfig) {}\n * ```\n */\nexport const AuthConfigService = new InjectionToken<AuthConfig>(\n 'auth0-angular.config'\n);\n\n/**\n * Gets and sets configuration for the internal Auth0 client. This can be\n * used to provide configuration outside of using AuthModule.forRoot, i.e. from\n * a factory provided by APP_INITIALIZER.\n *\n * @usage\n *\n * ```js\n * // app.module.ts\n * // ---------------------------\n * import { AuthModule, AuthClientConfig } from '@auth0/auth0-angular';\n *\n * // Provide an initializer function that returns a Promise\n * function configInitializer(\n * http: HttpClient,\n * config: AuthClientConfig\n * ) {\n * return () =>\n * http\n * .get('/config')\n * .toPromise()\n * .then((loadedConfig: any) => config.set(loadedConfig)); // Set the config that was loaded asynchronously here\n * }\n *\n * // Provide APP_INITIALIZER with this function. Note that there is no config passed to AuthModule.forRoot\n * imports: [\n * // other imports..\n *\n * HttpClientModule,\n * AuthModule.forRoot(), //<- don't pass any config here\n * ],\n * providers: [\n * {\n * provide: APP_INITIALIZER,\n * useFactory: configInitializer, // <- pass your initializer function here\n * deps: [HttpClient, AuthClientConfig],\n * multi: true,\n * },\n * ],\n * ```\n *\n */\n@Injectable({ providedIn: 'root' })\nexport class AuthClientConfig {\n private config?: AuthConfig;\n\n constructor(@Optional() @Inject(AuthConfigService) config?: AuthConfig) {\n if (config) {\n this.set(config);\n }\n }\n\n /**\n * Sets configuration to be read by other consumers of the service (see usage notes)\n *\n * @param config The configuration to set\n */\n set(config: AuthConfig): void {\n this.config = config;\n }\n\n /**\n * Gets the config that has been set by other consumers of the service\n */\n get(): AuthConfig {\n return this.config as AuthConfig;\n }\n}\n","import { Injectable, Injector } from '@angular/core';\nimport { Router } from '@angular/router';\nimport { Location } from '@angular/common';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class AbstractNavigator {\n private readonly router?: Router;\n\n constructor(private location: Location, injector: Injector) {\n try {\n this.router = injector.get(Router);\n } catch {}\n }\n\n /**\n * Navigates to the specified url. The router will be used if one is available, otherwise it falls back\n * to `window.history.replaceState`.\n *\n * @param url The url to navigate to\n */\n navigateByUrl(url: string): void {\n if (this.router) {\n this.router.navigateByUrl(url);\n\n return;\n }\n\n this.location.replaceState(url);\n }\n}\n","import { Inject, Injectable } from '@angular/core';\nimport { Auth0Client } from '@auth0/auth0-spa-js';\nimport {\n BehaviorSubject,\n defer,\n merge,\n of,\n ReplaySubject,\n Subject,\n} from 'rxjs';\nimport {\n concatMap,\n distinctUntilChanged,\n filter,\n mergeMap,\n scan,\n shareReplay,\n switchMap,\n} from 'rxjs/operators';\nimport { Auth0ClientService } from './auth.client';\n\n/**\n * Tracks the Authentication State for the SDK\n */\n@Injectable({ providedIn: 'root' })\nexport class AuthState {\n private isLoadingSubject$ = new BehaviorSubject<boolean>(true);\n private refresh$ = new Subject<void>();\n private accessToken$ = new ReplaySubject<string>(1);\n private errorSubject$ = new ReplaySubject<Error>(1);\n\n /**\n * Emits boolean values indicating the loading state of the SDK.\n */\n public readonly isLoading$ = this.isLoadingSubject$.asObservable();\n\n /**\n * Trigger used to pull User information from the Auth0Client.\n * Triggers when the access token has changed.\n */\n private accessTokenTrigger$ = this.accessToken$.pipe(\n scan(\n (\n acc: { current: string | null; previous: string | null },\n current: string | null\n ) => ({\n previous: acc.current,\n current,\n }),\n { current: null, previous: null }\n ),\n filter(({ previous, current }) => previous !== current)\n );\n\n /**\n * Trigger used to pull User information from the Auth0Client.\n * Triggers when an event occurs that needs to retrigger the User Profile information.\n * Events: Login, Access Token change and Logout\n */\n private readonly isAuthenticatedTrigger$ = this.isLoading$.pipe(\n filter((loading) => !loading),\n distinctUntilChanged(),\n switchMap(() =>\n // To track the value of isAuthenticated over time, we need to merge:\n // - the current value\n // - the value whenever the access token changes. (this should always be true of there is an access token\n // but it is safer to pass this through this.auth0Client.isAuthenticated() nevertheless)\n // - the value whenever refreshState$ emits\n merge(\n defer(() => this.auth0Client.isAuthenticated()),\n this.accessTokenTrigger$.pipe(\n mergeMap(() => this.auth0Client.isAuthenticated())\n ),\n this.refresh$.pipe(mergeMap(() => this.auth0Client.isAuthenticated()))\n )\n )\n );\n\n /**\n * Emits boolean values indicating the authentication state of the user. If `true`, it means a user has authenticated.\n * This depends on the value of `isLoading$`, so there is no need to manually check the loading state of the SDK.\n */\n readonly isAuthenticated$ = this.isAuthenticatedTrigger$.pipe(\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n /**\n * Emits details about the authenticated user, or null if not authenticated.\n */\n readonly user$ = this.isAuthenticatedTrigger$.pipe(\n concatMap((authenticated) =>\n authenticated ? this.auth0Client.getUser() : of(null)\n ),\n distinctUntilChanged()\n );\n\n /**\n * Emits ID token claims when authenticated, or null if not authenticated.\n */\n readonly idTokenClaims$ = this.isAuthenticatedTrigger$.pipe(\n concatMap((authenticated) =>\n authenticated ? this.auth0Client.getIdTokenClaims() : of(null)\n )\n );\n\n /**\n * Emits errors that occur during login, or when checking for an active session on startup.\n */\n public readonly error$ = this.errorSubject$.asObservable();\n\n constructor(@Inject(Auth0ClientService) private auth0Client: Auth0Client) {}\n\n /**\n * Update the isLoading state using the provided value\n *\n * @param isLoading The new value for isLoading\n */\n public setIsLoading(isLoading: boolean): void {\n this.isLoadingSubject$.next(isLoading);\n }\n\n /**\n * Refresh the state to ensure the `isAuthenticated`, `user$` and `idTokenClaims$`\n * reflect the most up-to-date values from Auth0Client.\n */\n public refresh(): void {\n this.refresh$.next();\n }\n\n /**\n * Update the access token, doing so will also refresh the state.\n *\n * @param accessToken The new Access Token\n */\n public setAccessToken(accessToken: string): void {\n this.accessToken$.next(accessToken);\n }\n\n /**\n * Emits the error in the `error$` observable.\n *\n * @param error The new error\n */\n public setError(error: any): void {\n this.errorSubject$.next(error);\n }\n}\n","import { Injectable, Inject, OnDestroy } from '@angular/core';\n\nimport {\n Auth0Client,\n PopupLoginOptions,\n PopupConfigOptions,\n GetTokenSilentlyOptions,\n GetTokenWithPopupOptions,\n RedirectLoginResult,\n GetTokenSilentlyVerboseResponse,\n} from '@auth0/auth0-spa-js';\n\nimport {\n of,\n from,\n Subject,\n Observable,\n iif,\n defer,\n ReplaySubject,\n throwError,\n} from 'rxjs';\n\nimport {\n concatMap,\n tap,\n map,\n takeUntil,\n catchError,\n switchMap,\n withLatestFrom,\n} from 'rxjs/operators';\n\nimport { Auth0ClientService } from './auth.client';\nimport { AbstractNavigator } from './abstract-navigator';\nimport { AuthClientConfig, AppState } from './auth.config';\nimport { AuthState } from './auth.state';\nimport { LogoutOptions, RedirectLoginOptions } from './interfaces';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class AuthService<TAppState extends AppState = AppState>\n implements OnDestroy\n{\n private appStateSubject$ = new ReplaySubject<TAppState>(1);\n\n // https://stackoverflow.com/a/41177163\n private ngUnsubscribe$ = new Subject<void>();\n /**\n * Emits boolean values indicating the loading state of the SDK.\n */\n readonly isLoading$ = this.authState.isLoading$;\n\n /**\n * Emits boolean values indicating the authentication state of the user. If `true`, it means a user has authenticated.\n * This depends on the value of `isLoading$`, so there is no need to manually check the loading state of the SDK.\n */\n readonly isAuthenticated$ = this.authState.isAuthenticated$;\n\n /**\n * Emits details about the authenticated user, or null if not authenticated.\n */\n readonly user$ = this.authState.user$;\n\n /**\n * Emits ID token claims when authenticated, or null if not authenticated.\n */\n readonly idTokenClaims$ = this.authState.idTokenClaims$;\n\n /**\n * Emits errors that occur during login, or when checking for an active session on startup.\n */\n readonly error$ = this.authState.error$;\n\n /**\n * Emits the value (if any) that was passed to the `loginWithRedirect` method call\n * but only **after** `handleRedirectCallback` is first called\n */\n readonly appState$ = this.appStateSubject$.asObservable();\n\n constructor(\n @Inject(Auth0ClientService) private auth0Client: Auth0Client,\n private configFactory: AuthClientConfig,\n private navigator: AbstractNavigator,\n private authState: AuthState\n ) {\n const checkSessionOrCallback$ = (isCallback: boolean) =>\n iif(\n () => isCallback,\n this.handleRedirectCallback(),\n defer(() => this.auth0Client.checkSession())\n );\n\n this.shouldHandleCallback()\n .pipe(\n switchMap((isCallback) =>\n checkSessionOrCallback$(isCallback).pipe(\n catchError((error) => {\n const config = this.configFactory.get();\n this.navigator.navigateByUrl(config.errorPath || '/');\n this.authState.setError(error);\n return of(undefined);\n })\n )\n ),\n tap(() => {\n this.authState.setIsLoading(false);\n }),\n takeUntil(this.ngUnsubscribe$)\n )\n .subscribe();\n }\n\n /**\n * Called when the service is destroyed\n */\n ngOnDestroy(): void {\n // https://stackoverflow.com/a/41177163\n this.ngUnsubscribe$.next();\n this.ngUnsubscribe$.complete();\n }\n\n /**\n * ```js\n * loginWithRedirect(options);\n * ```\n *\n * Performs a redirect to `/authorize` using the parameters\n * provided as arguments. Random and secure `state` and `nonce`\n * parameters will be auto-generated.\n *\n * @param options The login options\n */\n loginWithRedirect(\n options?: RedirectLoginOptions<TAppState>\n ): Observable<void> {\n return from(this.auth0Client.loginWithRedirect(options));\n }\n\n /**\n * ```js\n * await loginWithPopup(options);\n * ```\n *\n * Opens a popup with the `/authorize` URL using the parameters\n * provided as arguments. Random and secure `state` and `nonce`\n * parameters will be auto-generated. If the response is successful,\n * results will be valid according to their expiration times.\n *\n * IMPORTANT: This method has to be called from an event handler\n * that was started by the user like a button click, for example,\n * otherwise the popup will be blocked in most browsers.\n *\n * @param options The login options\n * @param config Configuration for the popup window\n */\n loginWithPopup(\n options?: PopupLoginOptions,\n config?: PopupConfigOptions\n ): Observable<void> {\n return from(\n this.auth0Client.loginWithPopup(options, config).then(() => {\n this.authState.refresh();\n })\n );\n }\n\n /**\n * ```js\n * logout();\n * ```\n *\n * Clears the application session and performs a redirect to `/v2/logout`, using\n * the parameters provided as arguments, to clear the Auth0 session.\n * If the `federated` option is specified it also clears the Identity Provider session.\n * If the `openUrl` option is set to false, it only clears the application session.\n * It is invalid to set both the `federated` to true and `openUrl` to `false`,\n * and an error will be thrown if you do.\n * [Read more about how Logout works at Auth0](https://auth0.com/docs/logout).\n *\n * @param options The logout options\n */\n logout(options?: LogoutOptions): Observable<void> {\n return from(\n this.auth0Client.logout(options).then(() => {\n if (options?.openUrl === false || options?.openUrl) {\n this.authState.refresh();\n }\n })\n );\n }\n\n /**\n * Fetches a new access token and returns the response from the /oauth/token endpoint, omitting the refresh token.\n *\n * @param options The options for configuring the token fetch.\n */\n getAccessTokenSilently(\n options: GetTokenSilentlyOptions & { detailedResponse: true }\n ): Observable<GetTokenSilentlyVerboseResponse>;\n\n /**\n * Fetches a new access token and returns it.\n *\n * @param options The options for configuring the token fetch.\n */\n getAccessTokenSilently(options?: GetTokenSilentlyOptions): Observable<string>;\n\n /**\n * ```js\n * getAccessTokenSilently(options).subscribe(token => ...)\n * ```\n *\n * If there's a valid token stored, return it. Otherwise, opens an\n * iframe with the `/authorize` URL using the parameters provided\n * as arguments. Random and secure `state` and `nonce` parameters\n * will be auto-generated. If the response is successful, results\n * will be valid according to their expiration times.\n *\n * If refresh tokens are used, the token endpoint is called directly with the\n * 'refresh_token' grant. If no refresh token is available to make this call,\n * the SDK falls back to using an iframe to the '/authorize' URL.\n *\n * This method may use a web worker to perform the token call if the in-memory\n * cache is used.\n *\n * If an `audience` value is given to this function, the SDK always falls\n * back to using an iframe to make the token exchange.\n *\n * Note that in all cases, falling back to an iframe requires access to\n * the `auth0` cookie, and thus will not work in browsers that block third-party\n * cookies by default (Safari, Brave, etc).\n *\n * @param options The options for configuring the token fetch.\n */\n getAccessTokenSilently(\n options: GetTokenSilentlyOptions = {}\n ): Observable<string | GetTokenSilentlyVerboseResponse> {\n return of(this.auth0Client).pipe(\n concatMap((client) =>\n options.detailedResponse === true\n ? client.getTokenSilently({ ...options, detailedResponse: true })\n : client.getTokenSilently(options)\n ),\n tap((token) => {\n if (token) {\n this.authState.setAccessToken(\n typeof token === 'string' ? token : token.access_token\n );\n }\n }),\n catchError((error) => {\n this.authState.setError(error);\n this.authState.refresh();\n return throwError(error);\n })\n );\n }\n\n /**\n * ```js\n * getTokenWithPopup(options).subscribe(token => ...)\n * ```\n *\n * Get an access token interactively.\n *\n * Opens a popup with the `/authorize` URL using the parameters\n * provided as arguments. Random and secure `state` and `nonce`\n * parameters will be auto-generated. If the response is successful,\n * results will be valid according to their expiration times.\n */\n getAccessTokenWithPopup(\n options?: GetTokenWithPopupOptions\n ): Observable<string | undefined> {\n return of(this.auth0Client).pipe(\n concatMap((client) => client.getTokenWithPopup(options)),\n tap((token) => {\n if (token) {\n this.authState.setAccessToken(token);\n }\n }),\n catchError((error) => {\n this.authState.setError(error);\n this.authState.refresh();\n return throwError(error);\n })\n );\n }\n\n /**\n * ```js\n * handleRedirectCallback(url).subscribe(result => ...)\n * ```\n *\n * After the browser redirects back to the callback page,\n * call `handleRedirectCallback` to handle success and error\n * responses from Auth0. If the response is successful, results\n * will be valid according to their expiration times.\n *\n * Calling this method also refreshes the authentication and user states.\n *\n * @param url The URL to that should be used to retrieve the `state` and `code` values. Defaults to `window.location.href` if not given.\n */\n handleRedirectCallback(\n url?: string\n ): Observable<RedirectLoginResult<TAppState>> {\n return defer(() =>\n this.auth0Client.handleRedirectCallback<TAppState>(url)\n ).pipe(\n withLatestFrom(this.authState.isLoading$),\n tap(([result, isLoading]) => {\n if (!isLoading) {\n this.authState.refresh();\n }\n const appState = result?.appState;\n const target = appState?.target ?? '/';\n\n if (appState) {\n this.appStateSubject$.next(appState);\n }\n\n this.navigator.navigateByUrl(target);\n }),\n map(([result]) => result)\n );\n }\n\n private shouldHandleCallback(): Observable<boolean> {\n return of(location.search).pipe(\n map((search) => {\n const searchParams = new URLSearchParams(search);\n return (\n (searchParams.has('code') || searchParams.has('error')) &&\n searchParams.has('state') &&\n !this.configFactory.get().skipRedirectCallback\n );\n })\n );\n }\n}\n","import { Injectable } from '@angular/core';\nimport {\n ActivatedRouteSnapshot,\n RouterStateSnapshot,\n CanActivate,\n CanLoad,\n Route,\n UrlSegment,\n CanActivateChild,\n} from '@angular/router';\nimport { Observable } from 'rxjs';\nimport { tap, take } from 'rxjs/operators';\nimport { AuthService } from './auth.service';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class AuthGuard implements CanActivate, CanLoad, CanActivateChild {\n constructor(private auth: AuthService) {}\n\n canLoad(route: Route, segments: UrlSegment[]): Observable<boolean> {\n return this.auth.isAuthenticated$.pipe(take(1));\n }\n\n canActivate(\n next: ActivatedRouteSnapshot,\n state: RouterStateSnapshot\n ): Observable<boolean> {\n return this.redirectIfUnauthenticated(state);\n }\n\n canActivateChild(\n childRoute: ActivatedRouteSnapshot,\n state: RouterStateSnapshot\n ): Observable<boolean> {\n return this.redirectIfUnauthenticated(state);\n }\n\n private redirectIfUnauthenticated(\n state: RouterStateSnapshot\n ): Observable<boolean> {\n return this.auth.isAuthenticated$.pipe(\n tap((loggedIn) => {\n if (!loggedIn) {\n this.auth.loginWithRedirect({\n appState: { target: state.url },\n });\n }\n })\n );\n }\n}\n","import { NgModule, ModuleWithProviders } from '@angular/core';\nimport { AuthService } from './auth.service';\nimport { AuthConfig, AuthConfigService, AuthClientConfig } from './auth.config';\nimport { Auth0ClientService, Auth0ClientFactory } from './auth.client';\nimport { AuthGuard } from './auth.guard';\n\n@NgModule()\nexport class AuthModule {\n /**\n * Initialize the authentication module system. Configuration can either be specified here,\n * or by calling AuthClientConfig.set (perhaps from an APP_INITIALIZER factory function).\n *\n * @param config The optional configuration for the SDK.\n */\n static forRoot(config?: AuthConfig): ModuleWithProviders<AuthModule> {\n return {\n ngModule: AuthModule,\n providers: [\n AuthService,\n AuthGuard,\n {\n provide: AuthConfigService,\n useValue: config,\n },\n {\n provide: Auth0ClientService,\n useFactory: Auth0ClientFactory.createClient,\n deps: [AuthClientConfig],\n },\n ],\n };\n }\n}\n","import {\n HttpInterceptor,\n HttpRequest,\n HttpHandler,\n HttpEvent,\n} from '@angular/common/http';\n\nimport { Observable, from, of, iif, throwError } from 'rxjs';\nimport { Inject, Injectable } from '@angular/core';\n\nimport {\n ApiRouteDefinition,\n isHttpInterceptorRouteConfig,\n AuthClientConfig,\n HttpInterceptorConfig,\n} from './auth.config';\n\nimport {\n switchMap,\n first,\n concatMap,\n catchError,\n tap,\n filter,\n mergeMap,\n mapTo,\n pluck,\n} from 'rxjs/operators';\nimport { Auth0Client, GetTokenSilentlyOptions } from '@auth0/auth0-spa-js';\nimport { Auth0ClientService } from './auth.client';\nimport { AuthState } from './auth.state';\nimport { AuthService } from './auth.service';\n\nconst waitUntil =\n <TSignal>(signal$: Observable<TSignal>) =>\n <TSource>(source$: Observable<TSource>) =>\n source$.pipe(mergeMap((value) => signal$.pipe(first(), mapTo(value))));\n\n@Injectable()\nexport class AuthHttpInterceptor implements HttpInterceptor {\n constructor(\n private configFactory: AuthClientConfig,\n @Inject(Auth0ClientService) private auth0Client: Auth0Client,\n private authState: AuthState,\n private authService: AuthService\n ) {}\n\n intercept(\n req: HttpRequest<any>,\n next: HttpHandler\n ): Observable<HttpEvent<any>> {\n const config = this.configFactory.get();\n if (!config.httpInterceptor?.allowedList) {\n return next.handle(req);\n }\n\n const isLoaded$ = this.authService.isLoading$.pipe(\n filter((isLoading) => !isLoading)\n );\n\n return this.findMatchingRoute(req, config.httpInterceptor).pipe(\n concatMap((route) =>\n iif(\n // Check if a route was matched\n () => route !== null,\n // If we have a matching route, call getTokenSilently and attach the token to the\n // outgoing request\n of(route).pipe(\n waitUntil(isLoaded$),\n pluck('tokenOptions'),\n concatMap<GetTokenSilentlyOptions, Observable<string>>((options) =>\n this.getAccessTokenSilently(options).pipe(\n catchError((err) => {\n if (this.allowAnonymous(route, err)) {\n return of('');\n }\n\n this.authState.setError(err);\n return throwError(err);\n })\n )\n ),\n switchMap((token: string) => {\n // Clone the request and attach the bearer token\n const clone = token\n ? req.clone({\n headers: req.headers.set(\n 'Authorization',\n `Bearer ${token}`\n ),\n })\n : req;\n\n return next.handle(clone);\n })\n ),\n // If the URI being called was not found in our httpInterceptor config, simply\n // pass the request through without attaching a token\n next.handle(req)\n )\n )\n );\n }\n\n /**\n * Duplicate of AuthService.getAccessTokenSilently, but with a slightly different error handling.\n * Only used internally in the interceptor.\n *\n * @param options The options for configuring the token fetch.\n */\n private getAccessTokenSilently(\n options?: GetTokenSilentlyOptions\n ): Observable<string> {\n return of(this.auth0Client).pipe(\n concatMap((client) => client.getTokenSilently(options)),\n tap((token) => this.authState.setAccessToken(token)),\n catchError((error) => {\n this.authState.refresh();\n return throwError(error);\n })\n );\n }\n\n /**\n * Strips the query and fragment from the given uri\n *\n * @param uri The uri to remove the query and fragment from\n */\n private stripQueryFrom(uri: string): string {\n if (uri.indexOf('?') > -1) {\n uri = uri.substr(0, uri.indexOf('?'));\n }\n\n if (uri.indexOf('#') > -1) {\n uri = uri.substr(0, uri.indexOf('#'));\n }\n\n return uri;\n }\n\n /**\n * Determines whether the specified route can have an access token attached to it, based on matching the HTTP request against\n * the interceptor route configuration.\n *\n * @param route The route to test\n * @param request The HTTP request\n */\n private canAttachToken(\n route: ApiRouteDefinition,\n request: HttpRequest<any>\n ): boolean {\n const testPrimitive = (value: string | undefined): boolean => {\n if (!value) {\n return false;\n }\n\n const requestPath = this.stripQueryFrom(request.url);\n\n if (value === requestPath) {\n return true;\n }\n\n // If the URL ends with an asterisk, match using startsWith.\n return (\n value.indexOf('*') === value.length - 1 &&\n request.url.startsWith(value.substr(0, value.length - 1))\n );\n };\n\n if (isHttpInterceptorRouteConfig(route)) {\n if (route.httpMethod && route.httpMethod !== request.method) {\n return false;\n }\n\n /* istanbul ignore if */\n if (!route.uri && !route.uriMatcher) {\n console.warn(\n 'Either a uri or uriMatcher is required when configuring the HTTP interceptor.'\n );\n }\n\n return route.uriMatcher\n ? route.uriMatcher(request.url)\n : testPrimitive(route.uri);\n }\n\n return testPrimitive(route);\n }\n\n /**\n * Tries to match a route from the SDK configuration to the HTTP request.\n * If a match is found, the route configuration is returned.\n *\n * @param request The Http request\n * @param config HttpInterceptorConfig\n */\n private findMatchingRoute(\n request: HttpRequest<any>,\n config: HttpInterceptorConfig\n ): Observable<ApiRouteDefinition | null> {\n return from(config.allowedList).pipe(\n first((route) => this.canAttachToken(route, request), null)\n );\n }\n\n private allowAnonymous(route: ApiRouteDefinition | null, err: any): boolean {\n return (\n !!route &&\n isHttpInterceptorRouteConfig(route) &&\n !!route.allowAnonymous &&\n ['login_required', 'consent_required', 'missing_refresh_token'].includes(\n err.error\n )\n );\n }\n}\n","import { Provider } from '@angular/core';\nimport { Auth0ClientService, Auth0ClientFactory } from './auth.client';\nimport { AuthConfig, AuthConfigService, AuthClientConfig } from './auth.config';\nimport { AuthGuard } from './auth.guard';\nimport { AuthHttpInterceptor } from './auth.interceptor';\nimport { AuthService } from './auth.service';\n\n/**\n * Initialize the authentication system. Configuration can either be specified here,\n * or by calling AuthClientConfig.set (perhaps from an APP_INITIALIZER factory function).\n *\n * Note: Should only be used as of Angular 15, and should not be added to a component's providers.\n *\n * @param config The optional configuration for the SDK.\n *\n * @example\n * bootstrapApplication(AppComponent, {\n * providers: [\n * provideAuth0(),\n * ],\n * });\n */\nexport function provideAuth0(config?: AuthConfig): Provider[] {\n return [\n AuthService,\n AuthHttpInterceptor,\n AuthGuard,\n {\n provide: AuthConfigService,\n useValue: config,\n },\n {\n provide: Auth0ClientService,\n useFactory: Auth0ClientFactory.createClient,\n deps: [AuthClientConfig],\n },\n ];\n}\n","import { HttpEvent, HttpRequest } from '@angular/common/http';\nimport { inject } from '@angular/core';\nimport { ActivatedRouteSnapshot, RouterStateSnapshot } from '@angular/router';\nimport { Observable } from 'rxjs';\nimport { AuthGuard } from './auth.guard';\nimport { AuthHttpInterceptor } from './auth.interceptor';\n\n/**\n * Functional AuthGuard to ensure routes can only be accessed when authenticated.\n *\n * Note: Should only be used as of Angular 15\n *\n * @param route Contains the information about a route associated with a component loaded in an outlet at a particular moment in time.\n * @param state Represents the state of the router at a moment in time.\n * @returns An Observable, indicating if the route can be accessed or not\n */\nexport const authGuardFn = (\n route: ActivatedRouteSnapshot,\n state: RouterStateSnapshot\n) => inject(AuthGuard).canActivate(route, state);\n\n/**\n * Functional AuthHttpInterceptor to include the access token in matching requests.\n *\n * Note: Should only be used as of Angular 15\n *\n * @param req An outgoing HTTP request with an optional typed body.\n * @param handle Represents the next interceptor in an interceptor chain, or the real backend if there are no\n * further interceptors.\n * @returns An Observable representing the intercepted HttpRequest\n */\nexport const authHttpInterceptorFn = (\n req: HttpRequest<any>,\n handle: (req: HttpRequest<unknown>) => Observable<HttpEvent<unknown>>\n) => inject(AuthHttpInterceptor).intercept(req, { handle });\n","/*\n * Public API Surface of auth0-angular\n */\n\nexport * from './lib/auth.service';\nexport * from './lib/auth.module';\nexport * from './lib/auth.guard';\nexport * from './lib/auth.interceptor';\nexport * from './lib/auth.config';\nexport * from './lib/auth.client';\nexport * from './lib/auth.state';\nexport * from './lib/interfaces';\nexport * from './lib/provide';\nexport * from './lib/functional';\n\nexport {\n AuthorizationParams,\n PopupLoginOptions,\n PopupConfigOptions,\n GetTokenWithPopupOptions,\n GetTokenSilentlyOptions,\n ICache,\n Cacheable,\n LocalStorageCache,\n InMemoryCache,\n IdToken,\n User,\n GenericError,\n TimeoutError,\n MfaRequiredError,\n PopupTimeoutError,\n AuthenticationError,\n PopupCancelledError,\n MissingRefreshTokenError\n} from '@auth0/auth0-spa-js';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i1.AuthClientConfig","i2.AbstractNavigator","i3.AuthState","i1.AuthService","i2.AuthState","i3.AuthService"],"mappings":";;;;;;;;;;AAAA,gBAAe,EAAE,IAAI,EAAE,sBAAsB,EAAE,OAAO,EAAE,OAAO,EAAE;;MCKpD,kBAAkB,CAAA;IAC7B,OAAO,YAAY,CAAC,aAA+B,EAAA;AACjD,QAAA,MAAM,MAAM,GAAG,aAAa,CAAC,GAAG,EAAE,CAAC;QAEnC,IAAI,CAAC,MAAM,EAAE;AACX,YAAA,MAAM,IAAI,KAAK,CACb,mGAAmG,CACpG,CAAC;AACH,SAAA;AAED,QAAA,OAAO,IAAI,WAAW,CAAA,MAAA,CAAA,MAAA,CAAA,MAAA,CAAA,MAAA,CAAA,EAAA,EACjB,MAAM,CAAA,EAAA,EACT,WAAW,EAAE;gBACX,IAAI,EAAE,SAAS,CAAC,IAAI;gBACpB,OAAO,EAAE,SAAS,CAAC,OAAO;AAC1B,gBAAA,GAAG,EAAE;oBACH,cAAc,EAAE,OAAO,CAAC,IAAI;AAC7B,iBAAA;AACF,aAAA,EAAA,CAAA,CACD,CAAC;KACJ;AACF,CAAA;MAEY,kBAAkB,GAAG,IAAI,cAAc,CAClD,cAAc;;ACAhB;;;;AAIG;AACG,SAAU,4BAA4B,CAC1C,GAAuB,EAAA;AAEvB,IAAA,OAAO,OAAO,GAAG,KAAK,QAAQ,CAAC;AACjC,CAAC;AAoHD;;;;;;;;;;AAUG;MACU,iBAAiB,GAAG,IAAI,cAAc,CACjD,sBAAsB,EACtB;AAEF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAyCG;MAEU,gBAAgB,CAAA;AAG3B,IAAA,WAAA,CAAm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QACL,WAAW;QACX,mBAAmB;QACnB,SAAS;AACT,QAAA;AACE,YAAA,OAAO,EAAE,iBAAiB;AAC1B,YAAA,QAAQ,EAAE,MAAM;AACjB,SAAA;AACD,QAAA;AACE,YAAA,OAAO,EAAE,kBAAkB;YAC3B,UAAU,EAAE,kBAAkB,CAAC,YAAY;YAC3C,IAAI,EAAE,CAAC,gBAAgB,CAAC;AACzB,SAAA;KACF,CAAC;AACJ;;AC9BA;;;;;;;;AAQG;MACU,WAAW,GAAG,CACzB,KAA6B,EAC7B,KAA0B,KACvB,MAAM,CAAC,SAAS,CAAC,CAAC,WAAW,CAAC,KAAK,EAAE,KAAK,EAAE;AAEjD;;;;;;;;;AASG;AACU,MAAA,qBAAqB,GAAG,CACnC,GAAqB,EACrB,MAAqE,KAClE,MAAM,CAAC,mBAAmB,CAAC,CAAC,SAAS,CAAC,GAAG,EAAE,EAAE,MAAM,EAAE;;AClC1D;;AAEG;;ACFH;;AAEG;;;;"}
@@ -1 +0,0 @@
1
- {"version":3,"file":"auth0-auth0-angular.mjs","sources":["../../../projects/auth0-angular/src/useragent.ts","../../../projects/auth0-angular/src/lib/auth.client.ts","../../../projects/auth0-angular/src/lib/auth.config.ts","../../../projects/auth0-angular/src/lib/abstract-navigator.ts","../../../projects/auth0-angular/src/lib/auth.state.ts","../../../projects/auth0-angular/src/lib/auth.service.ts","../../../projects/auth0-angular/src/lib/auth.guard.ts","../../../projects/auth0-angular/src/lib/auth.module.ts","../../../projects/auth0-angular/src/lib/auth.interceptor.ts","../../../projects/auth0-angular/src/lib/provide.ts","../../../projects/auth0-angular/src/lib/functional.ts","../../../projects/auth0-angular/src/public-api.ts","../../../projects/auth0-angular/src/auth0-auth0-angular.ts"],"sourcesContent":["export default { name: '@auth0/auth0-angular', version: '2.2.2' };\n","import { InjectionToken, VERSION } from '@angular/core';\nimport { Auth0Client } from '@auth0/auth0-spa-js';\nimport { AuthClientConfig } from './auth.config';\nimport useragent from '../useragent';\n\nexport class Auth0ClientFactory {\n static createClient(configFactory: AuthClientConfig): Auth0Client {\n const config = configFactory.get();\n\n if (!config) {\n throw new Error(\n 'Configuration must be specified either through AuthModule.forRoot or through AuthClientConfig.set'\n );\n }\n\n return new Auth0Client({\n ...config,\n auth0Client: {\n name: useragent.name,\n version: useragent.version,\n env: {\n 'angular/core': VERSION.full,\n },\n },\n });\n }\n}\n\nexport const Auth0ClientService = new InjectionToken<Auth0Client>(\n 'auth0.client'\n);\n","import {\n Auth0ClientOptions,\n CacheLocation,\n GetTokenSilentlyOptions,\n ICache,\n} from '@auth0/auth0-spa-js';\n\nimport { InjectionToken, Injectable, Optional, Inject } from '@angular/core';\n\n/**\n * Defines a common set of HTTP methods.\n */\nexport const enum HttpMethod {\n Get = 'GET',\n Post = 'POST',\n Put = 'PUT',\n Patch = 'PATCH',\n Delete = 'DELETE',\n Head = 'HEAD',\n}\n\n/**\n * Defines the type for a route config entry. Can either be:\n *\n * - an object of type HttpInterceptorRouteConfig\n * - a string\n */\nexport type ApiRouteDefinition = HttpInterceptorRouteConfig | string;\n\n/**\n * A custom type guard to help identify route definitions that are actually HttpInterceptorRouteConfig types.\n *\n * @param def The route definition type\n */\nexport function isHttpInterceptorRouteConfig(\n def: ApiRouteDefinition\n): def is HttpInterceptorRouteConfig {\n return typeof def !== 'string';\n}\n\n/**\n * Configuration for the HttpInterceptor\n */\nexport interface HttpInterceptorConfig {\n allowedList: ApiRouteDefinition[];\n}\n\n/**\n * Configuration for a single interceptor route\n */\nexport interface HttpInterceptorRouteConfig {\n /**\n * The URL to test, by supplying the URL to match.\n * If `test` is a match for the current request path from the HTTP client, then\n * an access token is attached to the request in the\n * [\"Authorization\" header](https://tools.ietf.org/html/draft-ietf-oauth-v2-bearer-20#section-2.1).\n *\n * If the test does not pass, the request proceeds without the access token attached.\n *\n * A wildcard character can be used to match only the start of the URL.\n *\n * @usagenotes\n *\n * '/api' - exactly match the route /api\n * '/api/*' - match any route that starts with /api/\n */\n uri?: string;\n\n /**\n * A function that will be called with the HttpRequest.url value, allowing you to do\n * any kind of flexible matching.\n *\n * If this function returns true, then\n * an access token is attached to the request in the\n * [\"Authorization\" header](https://tools.ietf.org/html/draft-ietf-oauth-v2-bearer-20#section-2.1).\n *\n * If it returns false, the request proceeds without the access token attached.\n */\n uriMatcher?: (uri: string) => boolean;\n\n /**\n * The options that are passed to the SDK when retrieving the\n * access token to attach to the outgoing request.\n */\n tokenOptions?: GetTokenSilentlyOptions;\n\n /**\n * The HTTP method to match on. If specified, the HTTP method of\n * the outgoing request will be checked against this. If there is no match, the\n * Authorization header is not attached.\n *\n * The HTTP method name is case-sensitive.\n */\n httpMethod?: HttpMethod | string;\n\n /**\n * Allow the HTTP call to be executed anonymously, when no token is available.\n *\n * When omitted (or set to false), calls that match the configuration will fail when no token is available.\n */\n allowAnonymous?: boolean;\n}\n\n/**\n * Configuration for the authentication service\n */\nexport interface AuthConfig extends Auth0ClientOptions {\n /**\n * By default, if the page URL has code and state parameters, the SDK will assume they are for\n * an Auth0 application and attempt to exchange the code for a token.\n * In some cases the code might be for something else (e.g. another OAuth SDK). In these\n * instances you can instruct the client to ignore them by setting `skipRedirectCallback`.\n *\n * ```js\n * AuthModule.forRoot({\n * skipRedirectCallback: window.location.pathname === '/other-callback'\n * })\n * ```\n *\n * **Note**: In the above example, `/other-callback` is an existing route that will be called\n * by any other OAuth provider with a `code` (or `error` in case when something went wrong) and `state`.\n *\n */\n skipRedirectCallback?: boolean;\n\n /**\n * Configuration for the built-in Http Interceptor, used for\n * automatically attaching access tokens.\n */\n httpInterceptor?: HttpInterceptorConfig;\n\n /**\n * Path in your application to redirect to when the Authorization server\n * returns an error. Defaults to `/`\n */\n errorPath?: string;\n}\n\n/**\n * Angular specific state to be stored before redirect\n */\nexport interface AppState {\n /**\n * Target path the app gets routed to after\n * handling the callback from Auth0 (defaults to '/')\n */\n target?: string;\n\n /**\n * Any custom parameter to be stored in appState\n */\n [key: string]: any;\n}\n\n/**\n * Injection token for accessing configuration.\n *\n * @usageNotes\n *\n * Use the `Inject` decorator to access the configuration from a service or component:\n *\n * ```\n * class MyService(@Inject(AuthConfigService) config: AuthConfig) {}\n * ```\n */\nexport const AuthConfigService = new InjectionToken<AuthConfig>(\n 'auth0-angular.config'\n);\n\n/**\n * Gets and sets configuration for the internal Auth0 client. This can be\n * used to provide configuration outside of using AuthModule.forRoot, i.e. from\n * a factory provided by APP_INITIALIZER.\n *\n * @usage\n *\n * ```js\n * // app.module.ts\n * // ---------------------------\n * import { AuthModule, AuthClientConfig } from '@auth0/auth0-angular';\n *\n * // Provide an initializer function that returns a Promise\n * function configInitializer(\n * http: HttpClient,\n * config: AuthClientConfig\n * ) {\n * return () =>\n * http\n * .get('/config')\n * .toPromise()\n * .then((loadedConfig: any) => config.set(loadedConfig)); // Set the config that was loaded asynchronously here\n * }\n *\n * // Provide APP_INITIALIZER with this function. Note that there is no config passed to AuthModule.forRoot\n * imports: [\n * // other imports..\n *\n * HttpClientModule,\n * AuthModule.forRoot(), //<- don't pass any config here\n * ],\n * providers: [\n * {\n * provide: APP_INITIALIZER,\n * useFactory: configInitializer, // <- pass your initializer function here\n * deps: [HttpClient, AuthClientConfig],\n * multi: true,\n * },\n * ],\n * ```\n *\n */\n@Injectable({ providedIn: 'root' })\nexport class AuthClientConfig {\n private config?: AuthConfig;\n\n constructor(@Optional() @Inject(AuthConfigService) config?: AuthConfig) {\n if (config) {\n this.set(config);\n }\n }\n\n /**\n * Sets configuration to be read by other consumers of the service (see usage notes)\n *\n * @param config The configuration to set\n */\n set(config: AuthConfig): void {\n this.config = config;\n }\n\n /**\n * Gets the config that has been set by other consumers of the service\n */\n get(): AuthConfig {\n return this.config as AuthConfig;\n }\n}\n","import { Injectable, Injector } from '@angular/core';\nimport { Router } from '@angular/router';\nimport { Location } from '@angular/common';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class AbstractNavigator {\n private readonly router?: Router;\n\n constructor(private location: Location, injector: Injector) {\n try {\n this.router = injector.get(Router);\n } catch {}\n }\n\n /**\n * Navigates to the specified url. The router will be used if one is available, otherwise it falls back\n * to `window.history.replaceState`.\n *\n * @param url The url to navigate to\n */\n navigateByUrl(url: string): void {\n if (this.router) {\n this.router.navigateByUrl(url);\n\n return;\n }\n\n this.location.replaceState(url);\n }\n}\n","import { Inject, Injectable } from '@angular/core';\nimport { Auth0Client } from '@auth0/auth0-spa-js';\nimport {\n BehaviorSubject,\n defer,\n merge,\n of,\n ReplaySubject,\n Subject,\n} from 'rxjs';\nimport {\n concatMap,\n distinctUntilChanged,\n filter,\n mergeMap,\n scan,\n shareReplay,\n switchMap,\n} from 'rxjs/operators';\nimport { Auth0ClientService } from './auth.client';\n\n/**\n * Tracks the Authentication State for the SDK\n */\n@Injectable({ providedIn: 'root' })\nexport class AuthState {\n private isLoadingSubject$ = new BehaviorSubject<boolean>(true);\n private refresh$ = new Subject<void>();\n private accessToken$ = new ReplaySubject<string>(1);\n private errorSubject$ = new ReplaySubject<Error>(1);\n\n /**\n * Emits boolean values indicating the loading state of the SDK.\n */\n public readonly isLoading$ = this.isLoadingSubject$.asObservable();\n\n /**\n * Trigger used to pull User information from the Auth0Client.\n * Triggers when the access token has changed.\n */\n private accessTokenTrigger$ = this.accessToken$.pipe(\n scan(\n (\n acc: { current: string | null; previous: string | null },\n current: string | null\n ) => ({\n previous: acc.current,\n current,\n }),\n { current: null, previous: null }\n ),\n filter(({ previous, current }) => previous !== current)\n );\n\n /**\n * Trigger used to pull User information from the Auth0Client.\n * Triggers when an event occurs that needs to retrigger the User Profile information.\n * Events: Login, Access Token change and Logout\n */\n private readonly isAuthenticatedTrigger$ = this.isLoading$.pipe(\n filter((loading) => !loading),\n distinctUntilChanged(),\n switchMap(() =>\n // To track the value of isAuthenticated over time, we need to merge:\n // - the current value\n // - the value whenever the access token changes. (this should always be true of there is an access token\n // but it is safer to pass this through this.auth0Client.isAuthenticated() nevertheless)\n // - the value whenever refreshState$ emits\n merge(\n defer(() => this.auth0Client.isAuthenticated()),\n this.accessTokenTrigger$.pipe(\n mergeMap(() => this.auth0Client.isAuthenticated())\n ),\n this.refresh$.pipe(mergeMap(() => this.auth0Client.isAuthenticated()))\n )\n )\n );\n\n /**\n * Emits boolean values indicating the authentication state of the user. If `true`, it means a user has authenticated.\n * This depends on the value of `isLoading$`, so there is no need to manually check the loading state of the SDK.\n */\n readonly isAuthenticated$ = this.isAuthenticatedTrigger$.pipe(\n distinctUntilChanged(),\n shareReplay(1)\n );\n\n /**\n * Emits details about the authenticated user, or null if not authenticated.\n */\n readonly user$ = this.isAuthenticatedTrigger$.pipe(\n concatMap((authenticated) =>\n authenticated ? this.auth0Client.getUser() : of(null)\n ),\n distinctUntilChanged()\n );\n\n /**\n * Emits ID token claims when authenticated, or null if not authenticated.\n */\n readonly idTokenClaims$ = this.isAuthenticatedTrigger$.pipe(\n concatMap((authenticated) =>\n authenticated ? this.auth0Client.getIdTokenClaims() : of(null)\n )\n );\n\n /**\n * Emits errors that occur during login, or when checking for an active session on startup.\n */\n public readonly error$ = this.errorSubject$.asObservable();\n\n constructor(@Inject(Auth0ClientService) private auth0Client: Auth0Client) {}\n\n /**\n * Update the isLoading state using the provided value\n *\n * @param isLoading The new value for isLoading\n */\n public setIsLoading(isLoading: boolean): void {\n this.isLoadingSubject$.next(isLoading);\n }\n\n /**\n * Refresh the state to ensure the `isAuthenticated`, `user$` and `idTokenClaims$`\n * reflect the most up-to-date values from Auth0Client.\n */\n public refresh(): void {\n this.refresh$.next();\n }\n\n /**\n * Update the access token, doing so will also refresh the state.\n *\n * @param accessToken The new Access Token\n */\n public setAccessToken(accessToken: string): void {\n this.accessToken$.next(accessToken);\n }\n\n /**\n * Emits the error in the `error$` observable.\n *\n * @param error The new error\n */\n public setError(error: any): void {\n this.errorSubject$.next(error);\n }\n}\n","import { Injectable, Inject, OnDestroy } from '@angular/core';\n\nimport {\n Auth0Client,\n PopupLoginOptions,\n PopupConfigOptions,\n GetTokenSilentlyOptions,\n GetTokenWithPopupOptions,\n RedirectLoginResult,\n GetTokenSilentlyVerboseResponse,\n} from '@auth0/auth0-spa-js';\n\nimport {\n of,\n from,\n Subject,\n Observable,\n iif,\n defer,\n ReplaySubject,\n throwError,\n} from 'rxjs';\n\nimport {\n concatMap,\n tap,\n map,\n takeUntil,\n catchError,\n switchMap,\n withLatestFrom,\n} from 'rxjs/operators';\n\nimport { Auth0ClientService } from './auth.client';\nimport { AbstractNavigator } from './abstract-navigator';\nimport { AuthClientConfig, AppState } from './auth.config';\nimport { AuthState } from './auth.state';\nimport { LogoutOptions, RedirectLoginOptions } from './interfaces';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class AuthService<TAppState extends AppState = AppState>\n implements OnDestroy\n{\n private appStateSubject$ = new ReplaySubject<TAppState>(1);\n\n // https://stackoverflow.com/a/41177163\n private ngUnsubscribe$ = new Subject<void>();\n /**\n * Emits boolean values indicating the loading state of the SDK.\n */\n readonly isLoading$ = this.authState.isLoading$;\n\n /**\n * Emits boolean values indicating the authentication state of the user. If `true`, it means a user has authenticated.\n * This depends on the value of `isLoading$`, so there is no need to manually check the loading state of the SDK.\n */\n readonly isAuthenticated$ = this.authState.isAuthenticated$;\n\n /**\n * Emits details about the authenticated user, or null if not authenticated.\n */\n readonly user$ = this.authState.user$;\n\n /**\n * Emits ID token claims when authenticated, or null if not authenticated.\n */\n readonly idTokenClaims$ = this.authState.idTokenClaims$;\n\n /**\n * Emits errors that occur during login, or when checking for an active session on startup.\n */\n readonly error$ = this.authState.error$;\n\n /**\n * Emits the value (if any) that was passed to the `loginWithRedirect` method call\n * but only **after** `handleRedirectCallback` is first called\n */\n readonly appState$ = this.appStateSubject$.asObservable();\n\n constructor(\n @Inject(Auth0ClientService) private auth0Client: Auth0Client,\n private configFactory: AuthClientConfig,\n private navigator: AbstractNavigator,\n private authState: AuthState\n ) {\n const checkSessionOrCallback$ = (isCallback: boolean) =>\n iif(\n () => isCallback,\n this.handleRedirectCallback(),\n defer(() => this.auth0Client.checkSession())\n );\n\n this.shouldHandleCallback()\n .pipe(\n switchMap((isCallback) =>\n checkSessionOrCallback$(isCallback).pipe(\n catchError((error) => {\n const config = this.configFactory.get();\n this.navigator.navigateByUrl(config.errorPath || '/');\n this.authState.setError(error);\n return of(undefined);\n })\n )\n ),\n tap(() => {\n this.authState.setIsLoading(false);\n }),\n takeUntil(this.ngUnsubscribe$)\n )\n .subscribe();\n }\n\n /**\n * Called when the service is destroyed\n */\n ngOnDestroy(): void {\n // https://stackoverflow.com/a/41177163\n this.ngUnsubscribe$.next();\n this.ngUnsubscribe$.complete();\n }\n\n /**\n * ```js\n * loginWithRedirect(options);\n * ```\n *\n * Performs a redirect to `/authorize` using the parameters\n * provided as arguments. Random and secure `state` and `nonce`\n * parameters will be auto-generated.\n *\n * @param options The login options\n */\n loginWithRedirect(\n options?: RedirectLoginOptions<TAppState>\n ): Observable<void> {\n return from(this.auth0Client.loginWithRedirect(options));\n }\n\n /**\n * ```js\n * await loginWithPopup(options);\n * ```\n *\n * Opens a popup with the `/authorize` URL using the parameters\n * provided as arguments. Random and secure `state` and `nonce`\n * parameters will be auto-generated. If the response is successful,\n * results will be valid according to their expiration times.\n *\n * IMPORTANT: This method has to be called from an event handler\n * that was started by the user like a button click, for example,\n * otherwise the popup will be blocked in most browsers.\n *\n * @param options The login options\n * @param config Configuration for the popup window\n */\n loginWithPopup(\n options?: PopupLoginOptions,\n config?: PopupConfigOptions\n ): Observable<void> {\n return from(\n this.auth0Client.loginWithPopup(options, config).then(() => {\n this.authState.refresh();\n })\n );\n }\n\n /**\n * ```js\n * logout();\n * ```\n *\n * Clears the application session and performs a redirect to `/v2/logout`, using\n * the parameters provided as arguments, to clear the Auth0 session.\n * If the `federated` option is specified it also clears the Identity Provider session.\n * If the `openUrl` option is set to false, it only clears the application session.\n * It is invalid to set both the `federated` to true and `openUrl` to `false`,\n * and an error will be thrown if you do.\n * [Read more about how Logout works at Auth0](https://auth0.com/docs/logout).\n *\n * @param options The logout options\n */\n logout(options?: LogoutOptions): Observable<void> {\n return from(\n this.auth0Client.logout(options).then(() => {\n if (options?.openUrl === false || options?.openUrl) {\n this.authState.refresh();\n }\n })\n );\n }\n\n /**\n * Fetches a new access token and returns the response from the /oauth/token endpoint, omitting the refresh token.\n *\n * @param options The options for configuring the token fetch.\n */\n getAccessTokenSilently(\n options: GetTokenSilentlyOptions & { detailedResponse: true }\n ): Observable<GetTokenSilentlyVerboseResponse>;\n\n /**\n * Fetches a new access token and returns it.\n *\n * @param options The options for configuring the token fetch.\n */\n getAccessTokenSilently(options?: GetTokenSilentlyOptions): Observable<string>;\n\n /**\n * ```js\n * getAccessTokenSilently(options).subscribe(token => ...)\n * ```\n *\n * If there's a valid token stored, return it. Otherwise, opens an\n * iframe with the `/authorize` URL using the parameters provided\n * as arguments. Random and secure `state` and `nonce` parameters\n * will be auto-generated. If the response is successful, results\n * will be valid according to their expiration times.\n *\n * If refresh tokens are used, the token endpoint is called directly with the\n * 'refresh_token' grant. If no refresh token is available to make this call,\n * the SDK falls back to using an iframe to the '/authorize' URL.\n *\n * This method may use a web worker to perform the token call if the in-memory\n * cache is used.\n *\n * If an `audience` value is given to this function, the SDK always falls\n * back to using an iframe to make the token exchange.\n *\n * Note that in all cases, falling back to an iframe requires access to\n * the `auth0` cookie, and thus will not work in browsers that block third-party\n * cookies by default (Safari, Brave, etc).\n *\n * @param options The options for configuring the token fetch.\n */\n getAccessTokenSilently(\n options: GetTokenSilentlyOptions = {}\n ): Observable<string | GetTokenSilentlyVerboseResponse> {\n return of(this.auth0Client).pipe(\n concatMap((client) =>\n options.detailedResponse === true\n ? client.getTokenSilently({ ...options, detailedResponse: true })\n : client.getTokenSilently(options)\n ),\n tap((token) => {\n if (token) {\n this.authState.setAccessToken(\n typeof token === 'string' ? token : token.access_token\n );\n }\n }),\n catchError((error) => {\n this.authState.setError(error);\n this.authState.refresh();\n return throwError(error);\n })\n );\n }\n\n /**\n * ```js\n * getTokenWithPopup(options).subscribe(token => ...)\n * ```\n *\n * Get an access token interactively.\n *\n * Opens a popup with the `/authorize` URL using the parameters\n * provided as arguments. Random and secure `state` and `nonce`\n * parameters will be auto-generated. If the response is successful,\n * results will be valid according to their expiration times.\n */\n getAccessTokenWithPopup(\n options?: GetTokenWithPopupOptions\n ): Observable<string | undefined> {\n return of(this.auth0Client).pipe(\n concatMap((client) => client.getTokenWithPopup(options)),\n tap((token) => {\n if (token) {\n this.authState.setAccessToken(token);\n }\n }),\n catchError((error) => {\n this.authState.setError(error);\n this.authState.refresh();\n return throwError(error);\n })\n );\n }\n\n /**\n * ```js\n * handleRedirectCallback(url).subscribe(result => ...)\n * ```\n *\n * After the browser redirects back to the callback page,\n * call `handleRedirectCallback` to handle success and error\n * responses from Auth0. If the response is successful, results\n * will be valid according to their expiration times.\n *\n * Calling this method also refreshes the authentication and user states.\n *\n * @param url The URL to that should be used to retrieve the `state` and `code` values. Defaults to `window.location.href` if not given.\n */\n handleRedirectCallback(\n url?: string\n ): Observable<RedirectLoginResult<TAppState>> {\n return defer(() =>\n this.auth0Client.handleRedirectCallback<TAppState>(url)\n ).pipe(\n withLatestFrom(this.authState.isLoading$),\n tap(([result, isLoading]) => {\n if (!isLoading) {\n this.authState.refresh();\n }\n const appState = result?.appState;\n const target = appState?.target ?? '/';\n\n if (appState) {\n this.appStateSubject$.next(appState);\n }\n\n this.navigator.navigateByUrl(target);\n }),\n map(([result]) => result)\n );\n }\n\n private shouldHandleCallback(): Observable<boolean> {\n return of(location.search).pipe(\n map((search) => {\n const searchParams = new URLSearchParams(search);\n return (\n (searchParams.has('code') || searchParams.has('error')) &&\n searchParams.has('state') &&\n !this.configFactory.get().skipRedirectCallback\n );\n })\n );\n }\n}\n","import { Injectable } from '@angular/core';\nimport {\n ActivatedRouteSnapshot,\n RouterStateSnapshot,\n CanActivate,\n CanLoad,\n Route,\n UrlSegment,\n CanActivateChild,\n} from '@angular/router';\nimport { Observable } from 'rxjs';\nimport { tap, take } from 'rxjs/operators';\nimport { AuthService } from './auth.service';\n\n@Injectable({\n providedIn: 'root',\n})\nexport class AuthGuard implements CanActivate, CanLoad, CanActivateChild {\n constructor(private auth: AuthService) {}\n\n canLoad(route: Route, segments: UrlSegment[]): Observable<boolean> {\n return this.auth.isAuthenticated$.pipe(take(1));\n }\n\n canActivate(\n next: ActivatedRouteSnapshot,\n state: RouterStateSnapshot\n ): Observable<boolean> {\n return this.redirectIfUnauthenticated(state);\n }\n\n canActivateChild(\n childRoute: ActivatedRouteSnapshot,\n state: RouterStateSnapshot\n ): Observable<boolean> {\n return this.redirectIfUnauthenticated(state);\n }\n\n private redirectIfUnauthenticated(\n state: RouterStateSnapshot\n ): Observable<boolean> {\n return this.auth.isAuthenticated$.pipe(\n tap((loggedIn) => {\n if (!loggedIn) {\n this.auth.loginWithRedirect({\n appState: { target: state.url },\n });\n }\n })\n );\n }\n}\n","import { NgModule, ModuleWithProviders } from '@angular/core';\nimport { AuthService } from './auth.service';\nimport { AuthConfig, AuthConfigService, AuthClientConfig } from './auth.config';\nimport { Auth0ClientService, Auth0ClientFactory } from './auth.client';\nimport { AuthGuard } from './auth.guard';\n\n@NgModule()\nexport class AuthModule {\n /**\n * Initialize the authentication module system. Configuration can either be specified here,\n * or by calling AuthClientConfig.set (perhaps from an APP_INITIALIZER factory function).\n *\n * @param config The optional configuration for the SDK.\n */\n static forRoot(config?: AuthConfig): ModuleWithProviders<AuthModule> {\n return {\n ngModule: AuthModule,\n providers: [\n AuthService,\n AuthGuard,\n {\n provide: AuthConfigService,\n useValue: config,\n },\n {\n provide: Auth0ClientService,\n useFactory: Auth0ClientFactory.createClient,\n deps: [AuthClientConfig],\n },\n ],\n };\n }\n}\n","import {\n HttpInterceptor,\n HttpRequest,\n HttpHandler,\n HttpEvent,\n} from '@angular/common/http';\n\nimport { Observable, from, of, iif, throwError } from 'rxjs';\nimport { Inject, Injectable } from '@angular/core';\n\nimport {\n ApiRouteDefinition,\n isHttpInterceptorRouteConfig,\n AuthClientConfig,\n HttpInterceptorConfig,\n} from './auth.config';\n\nimport {\n switchMap,\n first,\n concatMap,\n catchError,\n tap,\n filter,\n mergeMap,\n mapTo,\n pluck,\n} from 'rxjs/operators';\nimport { Auth0Client, GetTokenSilentlyOptions } from '@auth0/auth0-spa-js';\nimport { Auth0ClientService } from './auth.client';\nimport { AuthState } from './auth.state';\nimport { AuthService } from './auth.service';\n\nconst waitUntil =\n <TSignal>(signal$: Observable<TSignal>) =>\n <TSource>(source$: Observable<TSource>) =>\n source$.pipe(mergeMap((value) => signal$.pipe(first(), mapTo(value))));\n\n@Injectable()\nexport class AuthHttpInterceptor implements HttpInterceptor {\n constructor(\n private configFactory: AuthClientConfig,\n @Inject(Auth0ClientService) private auth0Client: Auth0Client,\n private authState: AuthState,\n private authService: AuthService\n ) {}\n\n intercept(\n req: HttpRequest<any>,\n next: HttpHandler\n ): Observable<HttpEvent<any>> {\n const config = this.configFactory.get();\n if (!config.httpInterceptor?.allowedList) {\n return next.handle(req);\n }\n\n const isLoaded$ = this.authService.isLoading$.pipe(\n filter((isLoading) => !isLoading)\n );\n\n return this.findMatchingRoute(req, config.httpInterceptor).pipe(\n concatMap((route) =>\n iif(\n // Check if a route was matched\n () => route !== null,\n // If we have a matching route, call getTokenSilently and attach the token to the\n // outgoing request\n of(route).pipe(\n waitUntil(isLoaded$),\n pluck('tokenOptions'),\n concatMap<GetTokenSilentlyOptions, Observable<string>>((options) =>\n this.getAccessTokenSilently(options).pipe(\n catchError((err) => {\n if (this.allowAnonymous(route, err)) {\n return of('');\n }\n\n this.authState.setError(err);\n return throwError(err);\n })\n )\n ),\n switchMap((token: string) => {\n // Clone the request and attach the bearer token\n const clone = token\n ? req.clone({\n headers: req.headers.set(\n 'Authorization',\n `Bearer ${token}`\n ),\n })\n : req;\n\n return next.handle(clone);\n })\n ),\n // If the URI being called was not found in our httpInterceptor config, simply\n // pass the request through without attaching a token\n next.handle(req)\n )\n )\n );\n }\n\n /**\n * Duplicate of AuthService.getAccessTokenSilently, but with a slightly different error handling.\n * Only used internally in the interceptor.\n *\n * @param options The options for configuring the token fetch.\n */\n private getAccessTokenSilently(\n options?: GetTokenSilentlyOptions\n ): Observable<string> {\n return of(this.auth0Client).pipe(\n concatMap((client) => client.getTokenSilently(options)),\n tap((token) => this.authState.setAccessToken(token)),\n catchError((error) => {\n this.authState.refresh();\n return throwError(error);\n })\n );\n }\n\n /**\n * Strips the query and fragment from the given uri\n *\n * @param uri The uri to remove the query and fragment from\n */\n private stripQueryFrom(uri: string): string {\n if (uri.indexOf('?') > -1) {\n uri = uri.substr(0, uri.indexOf('?'));\n }\n\n if (uri.indexOf('#') > -1) {\n uri = uri.substr(0, uri.indexOf('#'));\n }\n\n return uri;\n }\n\n /**\n * Determines whether the specified route can have an access token attached to it, based on matching the HTTP request against\n * the interceptor route configuration.\n *\n * @param route The route to test\n * @param request The HTTP request\n */\n private canAttachToken(\n route: ApiRouteDefinition,\n request: HttpRequest<any>\n ): boolean {\n const testPrimitive = (value: string | undefined): boolean => {\n if (!value) {\n return false;\n }\n\n const requestPath = this.stripQueryFrom(request.url);\n\n if (value === requestPath) {\n return true;\n }\n\n // If the URL ends with an asterisk, match using startsWith.\n return (\n value.indexOf('*') === value.length - 1 &&\n request.url.startsWith(value.substr(0, value.length - 1))\n );\n };\n\n if (isHttpInterceptorRouteConfig(route)) {\n if (route.httpMethod && route.httpMethod !== request.method) {\n return false;\n }\n\n /* istanbul ignore if */\n if (!route.uri && !route.uriMatcher) {\n console.warn(\n 'Either a uri or uriMatcher is required when configuring the HTTP interceptor.'\n );\n }\n\n return route.uriMatcher\n ? route.uriMatcher(request.url)\n : testPrimitive(route.uri);\n }\n\n return testPrimitive(route);\n }\n\n /**\n * Tries to match a route from the SDK configuration to the HTTP request.\n * If a match is found, the route configuration is returned.\n *\n * @param request The Http request\n * @param config HttpInterceptorConfig\n */\n private findMatchingRoute(\n request: HttpRequest<any>,\n config: HttpInterceptorConfig\n ): Observable<ApiRouteDefinition | null> {\n return from(config.allowedList).pipe(\n first((route) => this.canAttachToken(route, request), null)\n );\n }\n\n private allowAnonymous(route: ApiRouteDefinition | null, err: any): boolean {\n return (\n !!route &&\n isHttpInterceptorRouteConfig(route) &&\n !!route.allowAnonymous &&\n ['login_required', 'consent_required', 'missing_refresh_token'].includes(\n err.error\n )\n );\n }\n}\n","import { Provider } from '@angular/core';\nimport { Auth0ClientService, Auth0ClientFactory } from './auth.client';\nimport { AuthConfig, AuthConfigService, AuthClientConfig } from './auth.config';\nimport { AuthGuard } from './auth.guard';\nimport { AuthHttpInterceptor } from './auth.interceptor';\nimport { AuthService } from './auth.service';\n\n/**\n * Initialize the authentication system. Configuration can either be specified here,\n * or by calling AuthClientConfig.set (perhaps from an APP_INITIALIZER factory function).\n *\n * Note: Should only be used as of Angular 15, and should not be added to a component's providers.\n *\n * @param config The optional configuration for the SDK.\n *\n * @example\n * bootstrapApplication(AppComponent, {\n * providers: [\n * provideAuth0(),\n * ],\n * });\n */\nexport function provideAuth0(config?: AuthConfig): Provider[] {\n return [\n AuthService,\n AuthHttpInterceptor,\n AuthGuard,\n {\n provide: AuthConfigService,\n useValue: config,\n },\n {\n provide: Auth0ClientService,\n useFactory: Auth0ClientFactory.createClient,\n deps: [AuthClientConfig],\n },\n ];\n}\n","import { HttpEvent, HttpRequest } from '@angular/common/http';\nimport { inject } from '@angular/core';\nimport { ActivatedRouteSnapshot, RouterStateSnapshot } from '@angular/router';\nimport { Observable } from 'rxjs';\nimport { AuthGuard } from './auth.guard';\nimport { AuthHttpInterceptor } from './auth.interceptor';\n\n/**\n * Functional AuthGuard to ensure routes can only be accessed when authenticated.\n *\n * Note: Should only be used as of Angular 15\n *\n * @param route Contains the information about a route associated with a component loaded in an outlet at a particular moment in time.\n * @param state Represents the state of the router at a moment in time.\n * @returns An Observable, indicating if the route can be accessed or not\n */\nexport const authGuardFn = (\n route: ActivatedRouteSnapshot,\n state: RouterStateSnapshot\n) => inject(AuthGuard).canActivate(route, state);\n\n/**\n * Functional AuthHttpInterceptor to include the access token in matching requests.\n *\n * Note: Should only be used as of Angular 15\n *\n * @param req An outgoing HTTP request with an optional typed body.\n * @param handle Represents the next interceptor in an interceptor chain, or the real backend if there are no\n * further interceptors.\n * @returns An Observable representing the intercepted HttpRequest\n */\nexport const authHttpInterceptorFn = (\n req: HttpRequest<any>,\n handle: (req: HttpRequest<unknown>) => Observable<HttpEvent<unknown>>\n) => inject(AuthHttpInterceptor).intercept(req, { handle });\n","/*\n * Public API Surface of auth0-angular\n */\n\nexport * from './lib/auth.service';\nexport * from './lib/auth.module';\nexport * from './lib/auth.guard';\nexport * from './lib/auth.interceptor';\nexport * from './lib/auth.config';\nexport * from './lib/auth.client';\nexport * from './lib/auth.state';\nexport * from './lib/interfaces';\nexport * from './lib/provide';\nexport * from './lib/functional';\n\nexport {\n AuthorizationParams,\n PopupLoginOptions,\n PopupConfigOptions,\n GetTokenWithPopupOptions,\n GetTokenSilentlyOptions,\n ICache,\n Cacheable,\n LocalStorageCache,\n InMemoryCache,\n IdToken,\n User,\n GenericError,\n TimeoutError,\n MfaRequiredError,\n PopupTimeoutError,\n AuthenticationError,\n PopupCancelledError,\n MissingRefreshTokenError\n} from '@auth0/auth0-spa-js';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i1.AuthClientConfig","i2.AbstractNavigator","i3.AuthState","i1.AuthService","i2.AuthState","i3.AuthService"],"mappings":";;;;;;;;;;AAAA,gBAAe,EAAE,IAAI,EAAE,sBAAsB,EAAE,OAAO,EAAE,OAAO,EAAE;;MCKpD,kBAAkB,CAAA;IAC7B,OAAO,YAAY,CAAC,aAA+B,EAAA;AACjD,QAAA,MAAM,MAAM,GAAG,aAAa,CAAC,GAAG,EAAE,CAAC;QAEnC,IAAI,CAAC,MAAM,EAAE;AACX,YAAA,MAAM,IAAI,KAAK,CACb,mGAAmG,CACpG,CAAC;AACH,SAAA;QAED,OAAO,IAAI,WAAW,CAAC;AACrB,YAAA,GAAG,MAAM;AACT,YAAA,WAAW,EAAE;gBACX,IAAI,EAAE,SAAS,CAAC,I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