@dontdrinkandroot/ngx-extensions 0.6.0 → 0.20.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 (75) hide show
  1. package/fesm2022/dontdrinkandroot-ngx-extensions.mjs +203 -736
  2. package/fesm2022/dontdrinkandroot-ngx-extensions.mjs.map +1 -1
  3. package/index.d.ts +161 -5
  4. package/package.json +6 -7
  5. package/esm2022/dontdrinkandroot-ngx-extensions.mjs +0 -5
  6. package/esm2022/public-api.mjs +0 -29
  7. package/esm2022/src/cookie/cookie.service.mjs +0 -135
  8. package/esm2022/src/ddr-extensions.module.mjs +0 -67
  9. package/esm2022/src/http/redirect-to-login-interceptor.service.mjs +0 -35
  10. package/esm2022/src/http/url-info.mjs +0 -26
  11. package/esm2022/src/http/with-credentials-interceptor.service.mjs +0 -19
  12. package/esm2022/src/image/lazy-image.directive.mjs +0 -132
  13. package/esm2022/src/jwt/jwt-interceptor.service.mjs +0 -26
  14. package/esm2022/src/jwt/jwt-refresh-token-interceptor.service.mjs +0 -50
  15. package/esm2022/src/jwt/jwt-token-response.mjs +0 -2
  16. package/esm2022/src/jwt/jwt.service.mjs +0 -81
  17. package/esm2022/src/logger/console-logger.service.mjs +0 -43
  18. package/esm2022/src/logger/logger.service.mjs +0 -9
  19. package/esm2022/src/methoddecorator/debounce.mjs +0 -13
  20. package/esm2022/src/methoddecorator/limit.mjs +0 -16
  21. package/esm2022/src/oauth/json-web-token.mjs +0 -2
  22. package/esm2022/src/oauth/oauth2-access-token-interceptor.service.mjs +0 -26
  23. package/esm2022/src/oauth/oauth2-config.mjs +0 -11
  24. package/esm2022/src/oauth/oauth2-error.mjs +0 -8
  25. package/esm2022/src/oauth/oauth2-refresh-token-interceptor.service.mjs +0 -24
  26. package/esm2022/src/oauth/oauth2.module.mjs +0 -44
  27. package/esm2022/src/oauth/oauth2.service.mjs +0 -125
  28. package/esm2022/src/oauth/redirect-to-oauth2-login-interceptor.service.mjs +0 -41
  29. package/esm2022/src/oauth/token-response.mjs +0 -2
  30. package/esm2022/src/scroll/bottom-hit.directive.mjs +0 -60
  31. package/esm2022/src/scroll/scroll.service.mjs +0 -38
  32. package/esm2022/src/storage/local-storage.service.mjs +0 -53
  33. package/esm2022/src/storage/storage.service.mjs +0 -5
  34. package/esm2022/src/typeguard/is-non-null.mjs +0 -4
  35. package/esm2022/src/util/collection-utils.mjs +0 -27
  36. package/esm2022/src/util/number-utils.mjs +0 -10
  37. package/esm2022/src/util/object-utils.mjs +0 -9
  38. package/esm2022/src/util/string-utils.mjs +0 -35
  39. package/esm2022/src/util/type-utils.mjs +0 -9
  40. package/esm2022/src/visibility/visibility.service.mjs +0 -19
  41. package/public-api.d.ts +0 -25
  42. package/src/cookie/cookie.service.d.ts +0 -41
  43. package/src/ddr-extensions.module.d.ts +0 -11
  44. package/src/http/redirect-to-login-interceptor.service.d.ts +0 -15
  45. package/src/http/url-info.d.ts +0 -13
  46. package/src/http/with-credentials-interceptor.service.d.ts +0 -11
  47. package/src/image/lazy-image.directive.d.ts +0 -29
  48. package/src/jwt/jwt-interceptor.service.d.ts +0 -14
  49. package/src/jwt/jwt-refresh-token-interceptor.service.d.ts +0 -18
  50. package/src/jwt/jwt-token-response.d.ts +0 -4
  51. package/src/jwt/jwt.service.d.ts +0 -48
  52. package/src/logger/console-logger.service.d.ts +0 -22
  53. package/src/logger/logger.service.d.ts +0 -10
  54. package/src/methoddecorator/debounce.d.ts +0 -1
  55. package/src/methoddecorator/limit.d.ts +0 -1
  56. package/src/oauth/json-web-token.d.ts +0 -30
  57. package/src/oauth/oauth2-access-token-interceptor.service.d.ts +0 -14
  58. package/src/oauth/oauth2-config.d.ts +0 -9
  59. package/src/oauth/oauth2-error.d.ts +0 -5
  60. package/src/oauth/oauth2-refresh-token-interceptor.service.d.ts +0 -14
  61. package/src/oauth/oauth2.module.d.ts +0 -9
  62. package/src/oauth/oauth2.service.d.ts +0 -35
  63. package/src/oauth/redirect-to-oauth2-login-interceptor.service.d.ts +0 -18
  64. package/src/oauth/token-response.d.ts +0 -6
  65. package/src/scroll/bottom-hit.directive.d.ts +0 -14
  66. package/src/scroll/scroll.service.d.ts +0 -12
  67. package/src/storage/local-storage.service.d.ts +0 -23
  68. package/src/storage/storage.service.d.ts +0 -7
  69. package/src/typeguard/is-non-null.d.ts +0 -1
  70. package/src/util/collection-utils.d.ts +0 -10
  71. package/src/util/number-utils.d.ts +0 -3
  72. package/src/util/object-utils.d.ts +0 -4
  73. package/src/util/string-utils.d.ts +0 -6
  74. package/src/util/type-utils.d.ts +0 -3
  75. package/src/visibility/visibility.service.d.ts +0 -9
@@ -1,35 +0,0 @@
1
- import { ActivatedRoute } from '@angular/router';
2
- import { Observable } from 'rxjs';
3
- import { HttpClient, HttpRequest } from '@angular/common/http';
4
- import { JsonWebToken } from './json-web-token';
5
- import { OAuth2Config } from './oauth2-config';
6
- import { Logger } from '../logger/logger.service';
7
- import * as i0 from "@angular/core";
8
- export declare class OAuth2Service {
9
- private route;
10
- private httpClient;
11
- private loggerService;
12
- private config;
13
- private static STORAGE_KEY_CHALLENGE;
14
- private static STORAGE_KEY_REFRESH_TOKEN;
15
- static STORAGE_KEY_RETURN_URL: string;
16
- private accessTokenString;
17
- private accessToken;
18
- private readonly REFRESH_MARGIN_SECONDS;
19
- private refreshTokenRequest$;
20
- constructor(route: ActivatedRoute, httpClient: HttpClient, loggerService: Logger, config: OAuth2Config);
21
- redirectToLogin(): void;
22
- handleCode(): Observable<JsonWebToken>;
23
- private createChallenge;
24
- private getRefreshToken;
25
- getAccessTokenString(): string | null;
26
- isAccessTokenExpired(): boolean;
27
- isRefreshPossibleAndRequired(req?: HttpRequest<any> | null): boolean;
28
- performRefresh(): Observable<JsonWebToken>;
29
- private processTokenResponse;
30
- clear(): void;
31
- setReturnUrl(url: string): void;
32
- getReturnUrl(): string | null;
33
- static ɵfac: i0.ɵɵFactoryDeclaration<OAuth2Service, never>;
34
- static ɵprov: i0.ɵɵInjectableDeclaration<OAuth2Service>;
35
- }
@@ -1,18 +0,0 @@
1
- import { HttpEvent, HttpHandler, HttpInterceptor, HttpRequest } from '@angular/common/http';
2
- import { Observable } from 'rxjs';
3
- import { Router } from '@angular/router';
4
- import { OAuth2Service } from './oauth2.service';
5
- import { OAuth2Config } from './oauth2-config';
6
- import * as i0 from "@angular/core";
7
- export declare class RedirectToOAuth2LoginInterceptor implements HttpInterceptor {
8
- private oAuth2Service;
9
- private router;
10
- private oAuth2Config;
11
- constructor(oAuth2Service: OAuth2Service, router: Router, oAuth2Config: OAuth2Config);
12
- /**
13
- * @override
14
- */
15
- intercept(req: HttpRequest<any>, next: HttpHandler): Observable<HttpEvent<any>>;
16
- static ɵfac: i0.ɵɵFactoryDeclaration<RedirectToOAuth2LoginInterceptor, never>;
17
- static ɵprov: i0.ɵɵInjectableDeclaration<RedirectToOAuth2LoginInterceptor>;
18
- }
@@ -1,6 +0,0 @@
1
- export interface TokenResponse {
2
- token_type: string;
3
- expires_in: number;
4
- access_token: string;
5
- refresh_token: string;
6
- }
@@ -1,14 +0,0 @@
1
- import { EventEmitter } from '@angular/core';
2
- import * as i0 from "@angular/core";
3
- export declare class BottomHitDirective {
4
- offset: number;
5
- onWindowBottomHit: EventEmitter<any>;
6
- private onElementBottomHit;
7
- constructor();
8
- scrolled($event: Event): void;
9
- windowScrolled($event: Event): void;
10
- protected windowScrollEvent($event: Event): void;
11
- protected elementScrollEvent($event: Event): void;
12
- static ɵfac: i0.ɵɵFactoryDeclaration<BottomHitDirective, never>;
13
- static ɵdir: i0.ɵɵDirectiveDeclaration<BottomHitDirective, "[ddrBottomHit]", never, {}, { "onWindowBottomHit": "onWindowBottomHit"; "onElementBottomHit": "onElementBottomHit"; }, never, never, false, never>;
14
- }
@@ -1,12 +0,0 @@
1
- import { Router } from '@angular/router';
2
- import { ViewportScroller } from '@angular/common';
3
- import * as i0 from "@angular/core";
4
- export declare class ScrollService {
5
- private router;
6
- private viewportScroller;
7
- private scrollPositionMap;
8
- constructor(router: Router, viewportScroller: ViewportScroller);
9
- restore(): void;
10
- static ɵfac: i0.ɵɵFactoryDeclaration<ScrollService, never>;
11
- static ɵprov: i0.ɵɵInjectableDeclaration<ScrollService>;
12
- }
@@ -1,23 +0,0 @@
1
- import { StorageService } from './storage.service';
2
- import { Logger } from '../logger/logger.service';
3
- import * as i0 from "@angular/core";
4
- export declare class LocalStorageService extends StorageService {
5
- protected storagePrefix: string;
6
- protected logger: Logger;
7
- constructor(storagePrefix: string, logger: Logger);
8
- /**
9
- * @override
10
- */
11
- retrieve<T>(key: string, defaultValue?: T | null): T | null;
12
- /**
13
- * @override
14
- */
15
- store<T>(key: string, value: T): void;
16
- /**
17
- * @override
18
- */
19
- remove(key: string): void;
20
- protected getFullKey(key: string): string;
21
- static ɵfac: i0.ɵɵFactoryDeclaration<LocalStorageService, never>;
22
- static ɵprov: i0.ɵɵInjectableDeclaration<LocalStorageService>;
23
- }
@@ -1,7 +0,0 @@
1
- import { InjectionToken } from "@angular/core";
2
- export declare const DDR_STORAGE_PREFIX: InjectionToken<string>;
3
- export declare abstract class StorageService {
4
- abstract store<T>(key: string, value: T): void;
5
- abstract retrieve<T>(key: string, defaultValue?: T): T | null;
6
- abstract remove(key: string): void;
7
- }
@@ -1 +0,0 @@
1
- export declare function isNonNull<T>(value: T): value is NonNullable<T>;
@@ -1,10 +0,0 @@
1
- export declare class CollectionUtils {
2
- /**
3
- * Maps an array into a Map by a specific property which should be unique.
4
- */
5
- static mapByProperty<V extends object, K extends keyof V>(entries: Array<V>, property: K): Map<any, V>;
6
- /**
7
- * Maps an array into a Map by a specified property and aggregates them into an array.
8
- */
9
- static mapArrayByProperty<V extends object, K extends keyof V>(entries: Array<V>, property: K): Map<any, V[]>;
10
- }
@@ -1,3 +0,0 @@
1
- export declare class NumberUtils {
2
- static getNextPowerOfTwo(value: number): number;
3
- }
@@ -1,4 +0,0 @@
1
- export declare class ObjectUtils {
2
- static deepCopy<T>(value: T): T;
3
- static getProperty<T, K extends keyof T>(o: T, propertyName: K): T[K];
4
- }
@@ -1,6 +0,0 @@
1
- export declare class StringUtils {
2
- static capitalizeFirstLetter(text: string): string;
3
- static stripTrailingSlash(text: string): string;
4
- static updateUrlParameter(uri: string, key: string, value: string): string;
5
- static createRandomString(lengthOfCode: number, possible: string): string;
6
- }
@@ -1,3 +0,0 @@
1
- export declare class TypeUtils {
2
- static notNull<T>(value: T | null | undefined, message?: string): T;
3
- }
@@ -1,9 +0,0 @@
1
- import { Observable } from 'rxjs';
2
- import * as i0 from "@angular/core";
3
- export declare class VisibilityService {
4
- private readonly visibility$;
5
- constructor();
6
- getVisibilityObservable(): Observable<boolean>;
7
- static ɵfac: i0.ɵɵFactoryDeclaration<VisibilityService, never>;
8
- static ɵprov: i0.ɵɵInjectableDeclaration<VisibilityService>;
9
- }