@lenne.tech/ng-base 13.6.5 → 13.6.6
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.
- package/base-components/components/checkbox/checkbox.component.d.ts +1 -1
- package/base-prototype/base-prototype.module.d.ts +6 -5
- package/base-prototype/pages/forgot-password/forgot-password.component.d.ts +7 -2
- package/base-prototype/pages/login/login.component.d.ts +8 -2
- package/base-prototype/pages/register/register.component.d.ts +8 -2
- package/esm2020/base-components/components/checkbox/checkbox.component.mjs +3 -3
- package/esm2020/base-components/components/input/input.component.mjs +3 -3
- package/esm2020/base-prototype/base-prototype.module.mjs +5 -4
- package/esm2020/base-prototype/pages/forgot-password/forgot-password.component.mjs +30 -9
- package/esm2020/base-prototype/pages/login/login.component.mjs +46 -9
- package/esm2020/base-prototype/pages/register/register.component.mjs +45 -11
- package/esm2020/public-api.mjs +1 -42
- package/esm2020/shared/classes/auth.class.mjs +16 -0
- package/esm2020/shared/classes/basic-user.class.mjs +51 -0
- package/esm2020/shared/classes/graphql-enum.class.mjs +9 -0
- package/esm2020/shared/classes/graphql-meta.class.mjs +171 -0
- package/esm2020/shared/classes/graphql-type.class.mjs +13 -0
- package/esm2020/shared/classes/helper.class.mjs +304 -0
- package/esm2020/shared/classes/standard.class.mjs +40 -0
- package/esm2020/{src → shared}/enums/comparison-operator.enum.mjs +1 -1
- package/esm2020/shared/enums/graphql-request-type.enum.mjs +10 -0
- package/esm2020/shared/enums/logical-operator.enum.mjs +10 -0
- package/esm2020/shared/enums/sort-order.enum.mjs +6 -0
- package/esm2020/shared/functions/ws-client.function.mjs +39 -0
- package/esm2020/shared/interfaces/base-module-config.interface.mjs +3 -0
- package/esm2020/shared/interfaces/can-component-deactivate.interface.mjs +2 -0
- package/esm2020/shared/interfaces/combined-filter-input.interface.mjs +2 -0
- package/esm2020/shared/interfaces/field-object.interface.mjs +2 -0
- package/esm2020/shared/interfaces/field.interface.mjs +2 -0
- package/esm2020/shared/interfaces/filter-input.interface.mjs +2 -0
- package/esm2020/shared/interfaces/find-args.interface.mjs +2 -0
- package/esm2020/shared/interfaces/graphql-fields-object.interface.mjs +2 -0
- package/esm2020/shared/interfaces/graphql-options.interface.mjs +2 -0
- package/esm2020/shared/interfaces/graphql-plus-options.interfacen.mjs +2 -0
- package/esm2020/shared/interfaces/graphql-type-collection.interface.mjs +2 -0
- package/esm2020/shared/interfaces/single-filter-input.interface.mjs +2 -0
- package/esm2020/shared/interfaces/sort-input.interface.mjs +2 -0
- package/esm2020/shared/interfaces/time-components.interface.mjs +2 -0
- package/esm2020/shared/lenne.tech-ng-base-shared.mjs +5 -0
- package/esm2020/shared/public-api.mjs +51 -0
- package/esm2020/shared/services/auth.service.mjs +71 -0
- package/esm2020/shared/services/forms.service.mjs +25 -0
- package/esm2020/shared/services/graphql-meta.service.mjs +123 -0
- package/esm2020/shared/services/graphql-plus.service.mjs +84 -0
- package/esm2020/shared/services/graphql.service.mjs +441 -0
- package/esm2020/shared/services/image.service.mjs +102 -0
- package/esm2020/shared/services/loader.service.mjs +29 -0
- package/esm2020/shared/services/scroll.service.mjs +179 -0
- package/esm2020/shared/services/storage.service.mjs +132 -0
- package/esm2020/shared/services/user.service.mjs +82 -0
- package/esm2020/shared/services/ws.service.mjs +16 -0
- package/esm2020/shared/types/graphql-fields.type.mjs +2 -0
- package/esm2020/shared/types/storage.type.mjs +2 -0
- package/esm2020/shared/validators/match.validator.mjs +19 -0
- package/esm2020/src/base.module.mjs +14 -11
- package/esm2020/src/directives/match-height.directive.mjs +2 -2
- package/esm2020/src/factories/apollo-options.factory.mjs +14 -12
- package/esm2020/src/guards/auth.guard.mjs +3 -3
- package/esm2020/src/guards/can-deactivate.guard.mjs +1 -1
- package/esm2020/src/guards/logout.guard.mjs +2 -2
- package/esm2020/src/services/theme.service.mjs +2 -2
- package/fesm2015/lenne.tech-ng-base-base-components.mjs +4 -4
- package/fesm2015/lenne.tech-ng-base-base-components.mjs.map +1 -1
- package/fesm2015/lenne.tech-ng-base-base-prototype.mjs +113 -22
- package/fesm2015/lenne.tech-ng-base-base-prototype.mjs.map +1 -1
- package/fesm2015/lenne.tech-ng-base-shared.mjs +1878 -0
- package/fesm2015/lenne.tech-ng-base-shared.mjs.map +1 -0
- package/fesm2015/lenne.tech-ng-base.mjs +57 -1799
- package/fesm2015/lenne.tech-ng-base.mjs.map +1 -1
- package/fesm2020/lenne.tech-ng-base-base-components.mjs +4 -4
- package/fesm2020/lenne.tech-ng-base-base-components.mjs.map +1 -1
- package/fesm2020/lenne.tech-ng-base-base-prototype.mjs +111 -22
- package/fesm2020/lenne.tech-ng-base-base-prototype.mjs.map +1 -1
- package/fesm2020/lenne.tech-ng-base-shared.mjs +1939 -0
- package/fesm2020/lenne.tech-ng-base-shared.mjs.map +1 -0
- package/fesm2020/lenne.tech-ng-base.mjs +57 -1854
- package/fesm2020/lenne.tech-ng-base.mjs.map +1 -1
- package/package.json +10 -2
- package/public-api.d.ts +0 -36
- package/shared/classes/auth.class.d.ts +9 -0
- package/{src → shared}/classes/basic-user.class.d.ts +0 -0
- package/{src → shared}/classes/graphql-enum.class.d.ts +0 -0
- package/{src → shared}/classes/graphql-meta.class.d.ts +0 -0
- package/{src → shared}/classes/graphql-type.class.d.ts +0 -0
- package/{src → shared}/classes/helper.class.d.ts +0 -0
- package/{src → shared}/classes/standard.class.d.ts +0 -0
- package/{src → shared}/enums/comparison-operator.enum.d.ts +0 -0
- package/{src → shared}/enums/graphql-request-type.enum.d.ts +0 -0
- package/{src → shared}/enums/logical-operator.enum.d.ts +0 -0
- package/{src → shared}/enums/sort-order.enum.d.ts +0 -0
- package/shared/functions/ws-client.function.d.ts +5 -0
- package/{src → shared}/interfaces/base-module-config.interface.d.ts +1 -1
- package/{src → shared}/interfaces/can-component-deactivate.interface.d.ts +0 -0
- package/{src → shared}/interfaces/combined-filter-input.interface.d.ts +0 -0
- package/{src → shared}/interfaces/field-object.interface.d.ts +0 -0
- package/{src → shared}/interfaces/field.interface.d.ts +0 -0
- package/{src → shared}/interfaces/filter-input.interface.d.ts +0 -0
- package/{src → shared}/interfaces/find-args.interface.d.ts +0 -0
- package/{src → shared}/interfaces/graphql-fields-object.interface.d.ts +0 -0
- package/{src → shared}/interfaces/graphql-options.interface.d.ts +0 -0
- package/{src → shared}/interfaces/graphql-plus-options.interfacen.d.ts +0 -0
- package/{src → shared}/interfaces/graphql-type-collection.interface.d.ts +0 -0
- package/{src → shared}/interfaces/single-filter-input.interface.d.ts +0 -0
- package/{src → shared}/interfaces/sort-input.interface.d.ts +0 -0
- package/shared/interfaces/time-components.interface.d.ts +6 -0
- package/shared/lenne.tech-ng-base-shared.d.ts +5 -0
- package/shared/package.json +10 -0
- package/shared/public-api.d.ts +43 -0
- package/{src → shared}/services/auth.service.d.ts +0 -0
- package/{src → shared}/services/forms.service.d.ts +0 -1
- package/{src → shared}/services/graphql-meta.service.d.ts +0 -0
- package/{src → shared}/services/graphql-plus.service.d.ts +0 -0
- package/{src → shared}/services/graphql.service.d.ts +0 -0
- package/{src → shared}/services/image.service.d.ts +0 -0
- package/{src → shared}/services/loader.service.d.ts +0 -0
- package/{src → shared}/services/scroll.service.d.ts +0 -0
- package/{src → shared}/services/storage.service.d.ts +0 -0
- package/shared/services/user.service.d.ts +42 -0
- package/{src → shared}/services/ws.service.d.ts +2 -2
- package/{src → shared}/types/graphql-fields.type.d.ts +0 -0
- package/{src → shared}/types/storage.type.d.ts +0 -0
- package/shared/validators/match.validator.d.ts +4 -0
- package/src/base.module.d.ts +4 -2
- package/src/directives/match-height.directive.d.ts +1 -1
- package/src/factories/apollo-options.factory.d.ts +1 -3
- package/src/guards/auth.guard.d.ts +1 -2
- package/src/guards/can-deactivate.guard.d.ts +1 -1
- package/src/guards/logout.guard.d.ts +1 -1
- package/src/services/theme.service.d.ts +1 -1
- package/esm2020/src/classes/basic-user.class.mjs +0 -51
- package/esm2020/src/classes/graphql-enum.class.mjs +0 -9
- package/esm2020/src/classes/graphql-meta.class.mjs +0 -171
- package/esm2020/src/classes/graphql-type.class.mjs +0 -13
- package/esm2020/src/classes/helper.class.mjs +0 -304
- package/esm2020/src/classes/standard.class.mjs +0 -40
- package/esm2020/src/enums/graphql-request-type.enum.mjs +0 -10
- package/esm2020/src/enums/logical-operator.enum.mjs +0 -10
- package/esm2020/src/enums/sort-order.enum.mjs +0 -6
- package/esm2020/src/interfaces/base-module-config.interface.mjs +0 -3
- package/esm2020/src/interfaces/can-component-deactivate.interface.mjs +0 -2
- package/esm2020/src/interfaces/combined-filter-input.interface.mjs +0 -2
- package/esm2020/src/interfaces/field-object.interface.mjs +0 -2
- package/esm2020/src/interfaces/field.interface.mjs +0 -2
- package/esm2020/src/interfaces/filter-input.interface.mjs +0 -2
- package/esm2020/src/interfaces/find-args.interface.mjs +0 -2
- package/esm2020/src/interfaces/graphql-fields-object.interface.mjs +0 -2
- package/esm2020/src/interfaces/graphql-options.interface.mjs +0 -2
- package/esm2020/src/interfaces/graphql-plus-options.interfacen.mjs +0 -2
- package/esm2020/src/interfaces/graphql-type-collection.interface.mjs +0 -2
- package/esm2020/src/interfaces/single-filter-input.interface.mjs +0 -2
- package/esm2020/src/interfaces/sort-input.interface.mjs +0 -2
- package/esm2020/src/services/auth.service.mjs +0 -71
- package/esm2020/src/services/forms.service.mjs +0 -26
- package/esm2020/src/services/graphql-meta.service.mjs +0 -123
- package/esm2020/src/services/graphql-plus.service.mjs +0 -84
- package/esm2020/src/services/graphql.service.mjs +0 -441
- package/esm2020/src/services/image.service.mjs +0 -102
- package/esm2020/src/services/loader.service.mjs +0 -29
- package/esm2020/src/services/scroll.service.mjs +0 -179
- package/esm2020/src/services/storage.service.mjs +0 -132
- package/esm2020/src/services/ws.service.mjs +0 -17
- package/esm2020/src/types/graphql-fields.type.mjs +0 -2
- package/esm2020/src/types/storage.type.mjs +0 -2
- package/esm2020/src/validators/must-match.validator.mjs +0 -22
- package/src/validators/must-match.validator.d.ts +0 -6
package/public-api.d.ts
CHANGED
|
@@ -2,12 +2,6 @@
|
|
|
2
2
|
* Exports for public API
|
|
3
3
|
*/
|
|
4
4
|
export * from './src/base.module';
|
|
5
|
-
export * from './src/classes/basic-user.class';
|
|
6
|
-
export * from './src/classes/graphql-enum.class';
|
|
7
|
-
export * from './src/classes/graphql-meta.class';
|
|
8
|
-
export * from './src/classes/graphql-type.class';
|
|
9
|
-
export * from './src/classes/helper.class';
|
|
10
|
-
export * from './src/classes/standard.class';
|
|
11
5
|
export * from './src/directives/context-menu.directive';
|
|
12
6
|
export * from './src/directives/lazy-load.directive';
|
|
13
7
|
export * from './src/directives/match-height.directive';
|
|
@@ -17,39 +11,9 @@ export * from './src/factories/apollo-options.factory';
|
|
|
17
11
|
export * from './src/guards/auth.guard';
|
|
18
12
|
export * from './src/guards/can-deactivate.guard';
|
|
19
13
|
export * from './src/guards/logout.guard';
|
|
20
|
-
export * from './src/enums/comparison-operator.enum';
|
|
21
|
-
export * from './src/enums/graphql-request-type.enum';
|
|
22
|
-
export * from './src/enums/logical-operator.enum';
|
|
23
|
-
export * from './src/enums/sort-order.enum';
|
|
24
|
-
export * from './src/interfaces/base-module-config.interface';
|
|
25
|
-
export * from './src/interfaces/can-component-deactivate.interface';
|
|
26
|
-
export * from './src/interfaces/combined-filter-input.interface';
|
|
27
|
-
export * from './src/interfaces/field.interface';
|
|
28
|
-
export * from './src/interfaces/field-object.interface';
|
|
29
|
-
export * from './src/interfaces/filter-input.interface';
|
|
30
|
-
export * from './src/interfaces/graphql-options.interface';
|
|
31
|
-
export * from './src/interfaces/graphql-plus-options.interfacen';
|
|
32
|
-
export * from './src/interfaces/graphql-type-collection.interface';
|
|
33
|
-
export * from './src/interfaces/graphql-fields-object.interface';
|
|
34
|
-
export * from './src/interfaces/single-filter-input.interface';
|
|
35
|
-
export * from './src/interfaces/sort-input.interface';
|
|
36
|
-
export * from './src/interfaces/find-args.interface';
|
|
37
14
|
export * from './src/pipes/ellipses.pipe';
|
|
38
15
|
export * from './src/pipes/safe-html.pipe';
|
|
39
16
|
export * from './src/pipes/date-ago.pipe';
|
|
40
|
-
export * from './src/services/auth.service';
|
|
41
|
-
export * from './src/services/forms.service';
|
|
42
17
|
export * from './src/services/fullscreen.service';
|
|
43
|
-
export * from './src/services/graphql.service';
|
|
44
|
-
export * from './src/services/graphql-meta.service';
|
|
45
|
-
export * from './src/services/graphql-plus.service';
|
|
46
|
-
export * from './src/services/image.service';
|
|
47
|
-
export * from './src/services/loader.service';
|
|
48
|
-
export * from './src/services/scroll.service';
|
|
49
18
|
export * from './src/services/seo.service';
|
|
50
|
-
export * from './src/services/storage.service';
|
|
51
|
-
export * from './src/services/ws.service';
|
|
52
19
|
export * from './src/services/theme.service';
|
|
53
|
-
export * from './src/types/storage.type';
|
|
54
|
-
export * from './src/types/graphql-fields.type';
|
|
55
|
-
export * from './src/validators/must-match.validator';
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"module": "../fesm2015/lenne.tech-ng-base-shared.mjs",
|
|
3
|
+
"es2020": "../fesm2020/lenne.tech-ng-base-shared.mjs",
|
|
4
|
+
"esm2020": "../esm2020/shared/lenne.tech-ng-base-shared.mjs",
|
|
5
|
+
"fesm2020": "../fesm2020/lenne.tech-ng-base-shared.mjs",
|
|
6
|
+
"fesm2015": "../fesm2015/lenne.tech-ng-base-shared.mjs",
|
|
7
|
+
"typings": "lenne.tech-ng-base-shared.d.ts",
|
|
8
|
+
"sideEffects": false,
|
|
9
|
+
"name": "@lenne.tech/ng-base/shared"
|
|
10
|
+
}
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Exports for public API
|
|
3
|
+
*/
|
|
4
|
+
export * from './classes/basic-user.class';
|
|
5
|
+
export * from './classes/graphql-enum.class';
|
|
6
|
+
export * from './classes/graphql-meta.class';
|
|
7
|
+
export * from './classes/graphql-type.class';
|
|
8
|
+
export * from './classes/helper.class';
|
|
9
|
+
export * from './classes/standard.class';
|
|
10
|
+
export * from './classes/auth.class';
|
|
11
|
+
export * from './services/auth.service';
|
|
12
|
+
export * from './services/graphql.service';
|
|
13
|
+
export * from './services/graphql-meta.service';
|
|
14
|
+
export * from './services/graphql-plus.service';
|
|
15
|
+
export * from './services/forms.service';
|
|
16
|
+
export * from './services/storage.service';
|
|
17
|
+
export * from './services/ws.service';
|
|
18
|
+
export * from './services/user.service';
|
|
19
|
+
export * from './services/loader.service';
|
|
20
|
+
export * from './services/scroll.service';
|
|
21
|
+
export * from './services/image.service';
|
|
22
|
+
export * from './enums/comparison-operator.enum';
|
|
23
|
+
export * from './enums/graphql-request-type.enum';
|
|
24
|
+
export * from './enums/logical-operator.enum';
|
|
25
|
+
export * from './enums/sort-order.enum';
|
|
26
|
+
export * from './interfaces/base-module-config.interface';
|
|
27
|
+
export * from './interfaces/can-component-deactivate.interface';
|
|
28
|
+
export * from './interfaces/combined-filter-input.interface';
|
|
29
|
+
export * from './interfaces/field.interface';
|
|
30
|
+
export * from './interfaces/field-object.interface';
|
|
31
|
+
export * from './interfaces/filter-input.interface';
|
|
32
|
+
export * from './interfaces/graphql-options.interface';
|
|
33
|
+
export * from './interfaces/graphql-plus-options.interfacen';
|
|
34
|
+
export * from './interfaces/graphql-type-collection.interface';
|
|
35
|
+
export * from './interfaces/graphql-fields-object.interface';
|
|
36
|
+
export * from './interfaces/single-filter-input.interface';
|
|
37
|
+
export * from './interfaces/sort-input.interface';
|
|
38
|
+
export * from './interfaces/find-args.interface';
|
|
39
|
+
export * from './interfaces/time-components.interface';
|
|
40
|
+
export * from './types/storage.type';
|
|
41
|
+
export * from './types/graphql-fields.type';
|
|
42
|
+
export * from './validators/match.validator';
|
|
43
|
+
export * from './functions/ws-client.function';
|
|
File without changes
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { FormGroup } from '@angular/forms';
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
export declare class FormsService {
|
|
4
|
-
constructor();
|
|
5
4
|
validateAllFormFields(formGroup: FormGroup): void;
|
|
6
5
|
static ɵfac: i0.ɵɵFactoryDeclaration<FormsService, never>;
|
|
7
6
|
static ɵprov: i0.ɵɵInjectableDeclaration<FormsService>;
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
@@ -0,0 +1,42 @@
|
|
|
1
|
+
import { Apollo } from 'apollo-angular';
|
|
2
|
+
import { Auth } from '../classes/auth.class';
|
|
3
|
+
import { AuthService } from './auth.service';
|
|
4
|
+
import { GraphQLMetaService } from './graphql-meta.service';
|
|
5
|
+
import { GraphQLPlusService } from './graphql-plus.service';
|
|
6
|
+
import { LoaderService } from './loader.service';
|
|
7
|
+
import * as i0 from "@angular/core";
|
|
8
|
+
export declare class UserService extends GraphQLPlusService {
|
|
9
|
+
protected apollo: Apollo;
|
|
10
|
+
protected graphqlMetaService: GraphQLMetaService;
|
|
11
|
+
protected loaderService: LoaderService;
|
|
12
|
+
protected authService: AuthService;
|
|
13
|
+
constructor(apollo: Apollo, graphqlMetaService: GraphQLMetaService, loaderService: LoaderService, authService: AuthService);
|
|
14
|
+
/**
|
|
15
|
+
* Login
|
|
16
|
+
*
|
|
17
|
+
* @param input
|
|
18
|
+
*/
|
|
19
|
+
login(input: {
|
|
20
|
+
email: string;
|
|
21
|
+
password: string;
|
|
22
|
+
}): import("rxjs").Observable<Auth>;
|
|
23
|
+
/**
|
|
24
|
+
* Register
|
|
25
|
+
*
|
|
26
|
+
* @param input
|
|
27
|
+
*/
|
|
28
|
+
register(input: {
|
|
29
|
+
firstName: string;
|
|
30
|
+
lastName: string;
|
|
31
|
+
email: string;
|
|
32
|
+
password: string;
|
|
33
|
+
}): import("rxjs").Observable<Auth>;
|
|
34
|
+
/**
|
|
35
|
+
* Request password reset mail
|
|
36
|
+
*
|
|
37
|
+
* @param email
|
|
38
|
+
*/
|
|
39
|
+
requestPasswordResetMail(email: string): import("rxjs").Observable<any>;
|
|
40
|
+
static ɵfac: i0.ɵɵFactoryDeclaration<UserService, never>;
|
|
41
|
+
static ɵprov: i0.ɵɵInjectableDeclaration<UserService>;
|
|
42
|
+
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { RestartableClient } from '../functions/ws-client.function';
|
|
2
2
|
import * as i0 from "@angular/core";
|
|
3
3
|
export declare class WsService {
|
|
4
|
-
client:
|
|
4
|
+
client: RestartableClient;
|
|
5
5
|
reconnect(): void;
|
|
6
6
|
static ɵfac: i0.ɵɵFactoryDeclaration<WsService, never>;
|
|
7
7
|
static ɵprov: i0.ɵɵInjectableDeclaration<WsService>;
|
|
File without changes
|
|
File without changes
|
package/src/base.module.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { ModuleWithProviders } from '@angular/core';
|
|
2
|
-
import { BaseModuleConfig } from '
|
|
2
|
+
import { BaseModuleConfig } from '@lenne.tech/ng-base/shared';
|
|
3
3
|
import * as i0 from "@angular/core";
|
|
4
4
|
import * as i1 from "./directives/context-menu.directive";
|
|
5
5
|
import * as i2 from "./directives/lazy-load.directive";
|
|
@@ -8,6 +8,8 @@ import * as i4 from "./directives/resizable.directive";
|
|
|
8
8
|
import * as i5 from "./pipes/ellipses.pipe";
|
|
9
9
|
import * as i6 from "./pipes/safe-html.pipe";
|
|
10
10
|
import * as i7 from "./pipes/date-ago.pipe";
|
|
11
|
+
import * as i8 from "apollo-angular";
|
|
12
|
+
import * as i9 from "@angular/common/http";
|
|
11
13
|
/**
|
|
12
14
|
* Base module
|
|
13
15
|
*/
|
|
@@ -17,6 +19,6 @@ export declare class BaseModule {
|
|
|
17
19
|
*/
|
|
18
20
|
static forRoot(baseModuleConfig?: BaseModuleConfig, AppAuthService?: any): ModuleWithProviders<BaseModule>;
|
|
19
21
|
static ɵfac: i0.ɵɵFactoryDeclaration<BaseModule, never>;
|
|
20
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<BaseModule, [typeof i1.ContextMenuDirective, typeof i2.LazyLoadDirective, typeof i3.MatchHeightDirective, typeof i4.ResizableDirective, typeof i5.EllipsesPipe, typeof i6.SafeHtmlPipe, typeof i7.DateAgoPipe],
|
|
22
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<BaseModule, [typeof i1.ContextMenuDirective, typeof i2.LazyLoadDirective, typeof i3.MatchHeightDirective, typeof i4.ResizableDirective, typeof i5.EllipsesPipe, typeof i6.SafeHtmlPipe, typeof i7.DateAgoPipe], [typeof i8.ApolloModule, typeof i9.HttpClientModule], [typeof i1.ContextMenuDirective, typeof i2.LazyLoadDirective, typeof i3.MatchHeightDirective, typeof i4.ResizableDirective, typeof i5.EllipsesPipe, typeof i6.SafeHtmlPipe, typeof i7.DateAgoPipe, typeof i8.ApolloModule, typeof i9.HttpClientModule]>;
|
|
21
23
|
static ɵinj: i0.ɵɵInjectorDeclaration<BaseModule>;
|
|
22
24
|
}
|
|
@@ -1,9 +1,7 @@
|
|
|
1
1
|
import { HttpLink } from 'apollo-angular/http';
|
|
2
|
-
import { BaseModuleConfig } from '../interfaces/base-module-config.interface';
|
|
3
|
-
import { AuthService } from '../services/auth.service';
|
|
4
2
|
import { ApolloLink } from '@apollo/client/core';
|
|
5
3
|
import { InMemoryCache } from '@apollo/client/cache';
|
|
6
|
-
import { WsService } from '
|
|
4
|
+
import { AuthService, BaseModuleConfig, WsService } from '@lenne.tech/ng-base/shared';
|
|
7
5
|
/**
|
|
8
6
|
* Factory for apollo-angular options
|
|
9
7
|
*/
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { ActivatedRouteSnapshot, CanActivate, CanActivateChild, Router, RouterStateSnapshot } from '@angular/router';
|
|
2
2
|
import { Observable } from 'rxjs';
|
|
3
|
-
import { AuthService } from '
|
|
4
|
-
import { BaseModuleConfig } from '../interfaces/base-module-config.interface';
|
|
3
|
+
import { AuthService, BaseModuleConfig } from '@lenne.tech/ng-base/shared';
|
|
5
4
|
import * as i0 from "@angular/core";
|
|
6
5
|
/**
|
|
7
6
|
* Authentication guard
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { CanDeactivate } from '@angular/router';
|
|
2
|
-
import { ICanComponentDeactivate } from '
|
|
2
|
+
import { ICanComponentDeactivate } from '@lenne.tech/ng-base/shared';
|
|
3
3
|
import * as i0 from "@angular/core";
|
|
4
4
|
/**
|
|
5
5
|
* Guard to check if a component can be deactivated
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { ActivatedRouteSnapshot, CanActivate, CanActivateChild, Router, RouterStateSnapshot } from '@angular/router';
|
|
2
2
|
import { Observable } from 'rxjs';
|
|
3
|
-
import { AuthService } from '
|
|
3
|
+
import { AuthService } from '@lenne.tech/ng-base/shared';
|
|
4
4
|
import * as i0 from "@angular/core";
|
|
5
5
|
/**
|
|
6
6
|
* Logout guard
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { BehaviorSubject, Observable } from 'rxjs';
|
|
2
|
-
import { StorageService } from '
|
|
2
|
+
import { StorageService } from '@lenne.tech/ng-base/shared';
|
|
3
3
|
import * as i0 from "@angular/core";
|
|
4
4
|
export declare class ThemeService {
|
|
5
5
|
private storageService;
|
|
@@ -1,51 +0,0 @@
|
|
|
1
|
-
import { Standard } from './standard.class';
|
|
2
|
-
import { Helper } from './helper.class';
|
|
3
|
-
/**
|
|
4
|
-
* User class
|
|
5
|
-
*/
|
|
6
|
-
export class BasicUser extends Standard {
|
|
7
|
-
constructor() {
|
|
8
|
-
super(...arguments);
|
|
9
|
-
this.id = undefined;
|
|
10
|
-
this.email = undefined;
|
|
11
|
-
this.firstName = undefined;
|
|
12
|
-
this.lastName = undefined;
|
|
13
|
-
this.roles = [];
|
|
14
|
-
this.username = undefined;
|
|
15
|
-
}
|
|
16
|
-
// ===================================================================================================================
|
|
17
|
-
// Methods
|
|
18
|
-
// ===================================================================================================================
|
|
19
|
-
/**
|
|
20
|
-
* Mapping
|
|
21
|
-
*/
|
|
22
|
-
map(data) {
|
|
23
|
-
Helper.map(data, this);
|
|
24
|
-
return this;
|
|
25
|
-
}
|
|
26
|
-
/**
|
|
27
|
-
* Checks whether the user has at least one of the required roles
|
|
28
|
-
*/
|
|
29
|
-
hasRole(roles) {
|
|
30
|
-
if (typeof roles === 'string') {
|
|
31
|
-
roles = [roles];
|
|
32
|
-
}
|
|
33
|
-
if (!this.roles || this.roles.length < 1) {
|
|
34
|
-
return false;
|
|
35
|
-
}
|
|
36
|
-
return !roles || roles.length < 1 ? true : this.roles.some((role) => roles.includes(role));
|
|
37
|
-
}
|
|
38
|
-
/**
|
|
39
|
-
* Checks whether the user has all required roles
|
|
40
|
-
*/
|
|
41
|
-
hasAllRoles(roles) {
|
|
42
|
-
if (typeof roles === 'string') {
|
|
43
|
-
roles = [roles];
|
|
44
|
-
}
|
|
45
|
-
if (!this.roles || this.roles.length < 1) {
|
|
46
|
-
return false;
|
|
47
|
-
}
|
|
48
|
-
return !roles ? true : roles.every((role) => this.roles.includes(role));
|
|
49
|
-
}
|
|
50
|
-
}
|
|
51
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiYmFzaWMtdXNlci5jbGFzcy5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL3Byb2plY3RzL25nLWJhc2Uvc3JjL2NsYXNzZXMvYmFzaWMtdXNlci5jbGFzcy50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsUUFBUSxFQUFFLE1BQU0sa0JBQWtCLENBQUM7QUFDNUMsT0FBTyxFQUFFLE1BQU0sRUFBRSxNQUFNLGdC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PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09XG4gIC8vIE1ldGhvZHNcbiAgLy8gPT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PT09PVxuXG4gIC8qKlxuICAgKiBNYXBwaW5nXG4gICAqL1xuICBwdWJsaWMgbWFwKGRhdGE6IFBhcnRpYWw8dGhpcz4gfCB7IFtrZXk6IHN0cmluZ106IGFueSB9KTogdGhpcyB7XG4gICAgSGVscGVyLm1hcChkYXRhLCB0aGlzKTtcbiAgICByZXR1cm4gdGhpcztcbiAgfVxuXG4gIC8qKlxuICAgKiBDaGVja3Mgd2hldGhlciB0aGUgdXNlciBoYXMgYXQgbGVhc3Qgb25lIG9mIHRoZSByZXF1aXJlZCByb2xlc1xuICAgKi9cbiAgcHVibGljIGhhc1JvbGUocm9sZXM6IHN0cmluZyB8IHN0cmluZ1tdKSB7XG4gICAgaWYgKHR5cGVvZiByb2xlcyA9PT0gJ3N0cmluZycpIHtcbiAgICAgIHJvbGVzID0gW3JvbGVzXTtcbiAgICB9XG4gICAgaWYgKCF0aGlzLnJvbGVzIHx8IHRoaXMucm9sZXMubGVuZ3RoIDwgMSkge1xuICAgICAgcmV0dXJuIGZhbHNlO1xuICAgIH1cbiAgICByZXR1cm4gIXJvbGVzIHx8IHJvbGVzLmxlbmd0aCA8IDEgPyB0cnVlIDogdGhpcy5yb2xlcy5zb21lKChyb2xlKSA9PiByb2xlcy5pbmNsdWRlcyhyb2xlKSk7XG4gIH1cblxuICAvKipcbiAgICogQ2hlY2tzIHdoZXRoZXIgdGhlIHVzZXIgaGFzIGFsbCByZXF1aXJlZCByb2xlc1xuICAgKi9cbiAgcHVibGljIGhhc0FsbFJvbGVzKHJvbGVzOiBzdHJpbmcgfCBzdHJpbmdbXSkge1xuICAgIGlmICh0eXBlb2Ygcm9sZXMgPT09ICdzdHJpbmcnKSB7XG4gICAgICByb2xlcyA9IFtyb2xlc107XG4gICAgfVxuICAgIGlmICghdGhpcy5yb2xlcyB8fCB0aGlzLnJvbGVzLmxlbmd0aCA8IDEpIHtcbiAgICAgIHJldHVybiBmYWxzZTtcbiAgICB9XG4gICAgcmV0dXJuICFyb2xlcyA/IHRydWUgOiByb2xlcy5ldmVyeSgocm9sZSkgPT4gdGhpcy5yb2xlcy5pbmNsdWRlcyhyb2xlKSk7XG4gIH1cbn1cbiJdfQ==
|
|
@@ -1,9 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* GraphQL enum
|
|
3
|
-
*/
|
|
4
|
-
export class GraphQLEnum {
|
|
5
|
-
constructor(value) {
|
|
6
|
-
this.value = value;
|
|
7
|
-
}
|
|
8
|
-
}
|
|
9
|
-
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiZ3JhcGhxbC1lbnVtLmNsYXNzLmpzIiwic291cmNlUm9vdCI6IiIsInNvdXJjZXMiOlsiLi4vLi4vLi4vLi4vLi4vcHJvamVjdHMvbmctYmFzZS9zcmMvY2xhc3Nlcy9ncmFwaHFsLWVudW0uY2xhc3MudHMiXSwibmFtZXMiOltdLCJtYXBwaW5ncyI6IkFBQUE7O0dBRUc7QUFDSCxNQUFNLE9BQU8sV0FBVztJQUd0QixZQUFZLEtBQUs7UUFDZixJQUFJLENBQUMsS0FBSyxHQUFHLEtBQUssQ0FBQztJQUNyQixDQUFDO0NBQ0YiLCJzb3VyY2VzQ29udGVudCI6WyIvKipcbiAqIEdyYXBoUUwgZW51bVxuICovXG5leHBvcnQgY2xhc3MgR3JhcGhRTEVudW0ge1xuICB2YWx1ZTogc3RyaW5nO1xuXG4gIGNvbnN0cnVjdG9yKHZhbHVlKSB7XG4gICAgdGhpcy52YWx1ZSA9IHZhbHVlO1xuICB9XG59XG4iXX0=
|