@lenne.tech/ng-base 14.3.1 → 14.6.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 (50) hide show
  1. package/base-components/base-components.module.d.ts +5 -4
  2. package/base-components/components/change-password/change-password.component.d.ts +24 -0
  3. package/base-components/components/input/input.component.d.ts +6 -1
  4. package/base-components/components/refence-input/refence-input.component.d.ts +10 -2
  5. package/base-components/components/tags/tags.component.d.ts +0 -2
  6. package/base-components/public-api.d.ts +1 -0
  7. package/base-prototype/base-prototype.module.d.ts +7 -6
  8. package/base-prototype/pages/reset-password/reset-password.component.d.ts +29 -0
  9. package/base-prototype/public-api.d.ts +1 -0
  10. package/esm2020/base-cms/pages/base-cms/base-cms.component.mjs +2 -2
  11. package/esm2020/base-components/base-components.module.mjs +5 -1
  12. package/esm2020/base-components/components/change-password/change-password.component.mjs +70 -0
  13. package/esm2020/base-components/components/input/input.component.mjs +17 -3
  14. package/esm2020/base-components/components/model-form/model-form.component.mjs +3 -3
  15. package/esm2020/base-components/components/model-form-sub/model-form-sub.component.mjs +3 -3
  16. package/esm2020/base-components/components/refence-input/refence-input.component.mjs +60 -10
  17. package/esm2020/base-components/components/tags/tags.component.mjs +12 -5
  18. package/esm2020/base-components/public-api.mjs +2 -1
  19. package/esm2020/base-prototype/base-prototype.module.mjs +7 -3
  20. package/esm2020/base-prototype/pages/forgot-password/forgot-password.component.mjs +4 -3
  21. package/esm2020/base-prototype/pages/login/login.component.mjs +4 -3
  22. package/esm2020/base-prototype/pages/profile/profile.component.mjs +2 -2
  23. package/esm2020/base-prototype/pages/register/register.component.mjs +4 -4
  24. package/esm2020/base-prototype/pages/reset-password/reset-password.component.mjs +82 -0
  25. package/esm2020/base-prototype/public-api.mjs +2 -1
  26. package/esm2020/shared/classes/graphql-meta.class.mjs +13 -2
  27. package/esm2020/shared/public-api.mjs +2 -1
  28. package/esm2020/shared/services/user.service.mjs +28 -1
  29. package/esm2020/shared/validators/email.validator.mjs +7 -0
  30. package/fesm2015/lenne.tech-ng-base-base-cms.mjs +4 -4
  31. package/fesm2015/lenne.tech-ng-base-base-cms.mjs.map +1 -1
  32. package/fesm2015/lenne.tech-ng-base-base-components.mjs +158 -24
  33. package/fesm2015/lenne.tech-ng-base-base-components.mjs.map +1 -1
  34. package/fesm2015/lenne.tech-ng-base-base-prototype.mjs +90 -13
  35. package/fesm2015/lenne.tech-ng-base-base-prototype.mjs.map +1 -1
  36. package/fesm2015/lenne.tech-ng-base-shared.mjs +47 -2
  37. package/fesm2015/lenne.tech-ng-base-shared.mjs.map +1 -1
  38. package/fesm2020/lenne.tech-ng-base-base-cms.mjs +1 -1
  39. package/fesm2020/lenne.tech-ng-base-base-cms.mjs.map +1 -1
  40. package/fesm2020/lenne.tech-ng-base-base-components.mjs +157 -21
  41. package/fesm2020/lenne.tech-ng-base-base-components.mjs.map +1 -1
  42. package/fesm2020/lenne.tech-ng-base-base-prototype.mjs +89 -13
  43. package/fesm2020/lenne.tech-ng-base-base-prototype.mjs.map +1 -1
  44. package/fesm2020/lenne.tech-ng-base-shared.mjs +47 -2
  45. package/fesm2020/lenne.tech-ng-base-shared.mjs.map +1 -1
  46. package/package.json +1 -1
  47. package/shared/classes/graphql-meta.class.d.ts +1 -1
  48. package/shared/public-api.d.ts +1 -0
  49. package/shared/services/user.service.d.ts +14 -0
  50. package/shared/validators/email.validator.d.ts +2 -0
@@ -1,7 +1,7 @@
1
1
  import * as i0 from '@angular/core';
2
2
  import { Component, Input, NgModule } from '@angular/core';
3
3
  import * as i3 from '@angular/forms';
4
- import { UntypedFormGroup, UntypedFormControl, Validators, FormsModule, ReactiveFormsModule } from '@angular/forms';
4
+ import { UntypedFormGroup, UntypedFormControl, Validators, FormControl, FormsModule, ReactiveFormsModule } from '@angular/forms';
5
5
  import * as i4 from '@angular/common';
6
6
  import { CommonModule } from '@angular/common';
7
7
  import * as i2 from '@angular/router';
@@ -9,9 +9,9 @@ import { RouterModule } from '@angular/router';
9
9
  import { BaseModule } from '@lenne.tech/ng-base';
10
10
  import * as i5 from '@lenne.tech/ng-base/base-components';
11
11
  import { BaseComponentsModule } from '@lenne.tech/ng-base/base-components';
12
- import { Subscription } from 'rxjs';
13
12
  import * as i1 from '@lenne.tech/ng-base/shared';
14
- import { Validation } from '@lenne.tech/ng-base/shared';
13
+ import { fullEmail, Validation, ToastType } from '@lenne.tech/ng-base/shared';
14
+ import { Subscription } from 'rxjs';
15
15
 
16
16
  class LoginComponent {
17
17
  constructor(formsService, userService, router, route) {
@@ -44,7 +44,7 @@ class LoginComponent {
44
44
  */
45
45
  createForm() {
46
46
  this.form = new UntypedFormGroup({
47
- email: new UntypedFormControl('', [Validators.required, Validators.email]),
47
+ email: new UntypedFormControl('', [Validators.required, fullEmail()]),
48
48
  password: new UntypedFormControl('', Validators.required),
49
49
  });
50
50
  }
@@ -93,7 +93,7 @@ class LoginComponent {
93
93
  }
94
94
  }
95
95
  LoginComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: LoginComponent, deps: [{ token: i1.FormsService }, { token: i1.UserService }, { token: i2.Router }, { token: i2.ActivatedRoute }], target: i0.ɵɵFactoryTarget.Component });
96
- LoginComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: LoginComponent, selector: "base-login", ngImport: i0, template: "<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column login-container\">\n <div class=\"container\">\n <img *ngIf=\"config?.logoUrl\" class=\"img-fluid mb-5\" [src]=\"config.logoUrl\" alt=\"Logo\" />\n\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [control]=\"form.get('email')\"\n [autocomplete]=\"'email'\"\n ></base-input>\n <base-input\n [id]=\"'password'\"\n [name]=\"'password'\"\n [label]=\"'Passwort'\"\n [type]=\"'password'\"\n [autocomplete]=\"'current-password'\"\n [control]=\"form.get('password')\"\n ></base-input>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Einloggen</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../passwort-vergessen\" *ngIf=\"config?.showPasswordForget\">Passwort vergessen</a>\n <a routerLink=\"../registrieren\" *ngIf=\"config?.showRegister\">Noch kein Konto? Dann registriere Dich jetzt!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n", styles: [".login-container{width:100%;padding:20px 0}@media (min-width: 768px){.login-container{max-width:400px}}\n"], dependencies: [{ kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i5.InputComponent, selector: "base-input", inputs: ["id", "name", "label", "placeholder", "autocomplete", "tabIndex", "control", "type", "required"], outputs: ["enter"] }] });
96
+ LoginComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: LoginComponent, selector: "base-login", ngImport: i0, template: "<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column login-container\">\n <div class=\"container\">\n <img *ngIf=\"config?.logoUrl\" class=\"img-fluid mb-5\" [src]=\"config.logoUrl\" alt=\"Logo\" />\n\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [control]=\"form.get('email')\"\n [autocomplete]=\"'email'\"\n ></base-input>\n <base-input\n [id]=\"'password'\"\n [name]=\"'password'\"\n [label]=\"'Passwort'\"\n [type]=\"'password'\"\n [autocomplete]=\"'current-password'\"\n [control]=\"form.get('password')\"\n ></base-input>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Einloggen</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../passwort-vergessen\" *ngIf=\"config?.showPasswordForget\">Passwort vergessen</a>\n <a routerLink=\"../registrieren\" *ngIf=\"config?.showRegister\">Noch kein Konto? Dann registriere Dich jetzt!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n", styles: [".login-container{width:100%;padding:20px 0}@media (min-width: 768px){.login-container{max-width:400px}}\n"], dependencies: [{ kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i5.InputComponent, selector: "base-input", inputs: ["id", "name", "label", "placeholder", "autocomplete", "tabIndex", "control", "type", "required", "eyeButton"], outputs: ["enter"] }] });
97
97
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: LoginComponent, decorators: [{
98
98
  type: Component,
99
99
  args: [{ selector: 'base-login', template: "<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column login-container\">\n <div class=\"container\">\n <img *ngIf=\"config?.logoUrl\" class=\"img-fluid mb-5\" [src]=\"config.logoUrl\" alt=\"Logo\" />\n\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [control]=\"form.get('email')\"\n [autocomplete]=\"'email'\"\n ></base-input>\n <base-input\n [id]=\"'password'\"\n [name]=\"'password'\"\n [label]=\"'Passwort'\"\n [type]=\"'password'\"\n [autocomplete]=\"'current-password'\"\n [control]=\"form.get('password')\"\n ></base-input>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Einloggen</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../passwort-vergessen\" *ngIf=\"config?.showPasswordForget\">Passwort vergessen</a>\n <a routerLink=\"../registrieren\" *ngIf=\"config?.showRegister\">Noch kein Konto? Dann registriere Dich jetzt!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n", styles: [".login-container{width:100%;padding:20px 0}@media (min-width: 768px){.login-container{max-width:400px}}\n"] }]
@@ -115,7 +115,7 @@ class RegisterComponent {
115
115
  this.form = new UntypedFormGroup({
116
116
  firstName: new UntypedFormControl('', [Validators.required]),
117
117
  lastName: new UntypedFormControl('', [Validators.required]),
118
- email: new UntypedFormControl('', [Validators.required, Validators.email]),
118
+ email: new UntypedFormControl('', [Validators.required, fullEmail()]),
119
119
  password: new UntypedFormControl('', [Validators.required, Validators.minLength(6)]),
120
120
  passwordConfirm: new UntypedFormControl('', [Validators.required, Validators.minLength(6)]),
121
121
  privacy: new UntypedFormControl(false, Validators.requiredTrue),
@@ -164,7 +164,7 @@ class RegisterComponent {
164
164
  }
165
165
  }
166
166
  RegisterComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: RegisterComponent, deps: [{ token: i1.FormsService }, { token: i1.UserService }, { token: i2.Router }], target: i0.ɵɵFactoryTarget.Component });
167
- RegisterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: RegisterComponent, selector: "base-register", ngImport: i0, template: "<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column register-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div id=\"register-error\" class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'firstName'\"\n [name]=\"'firstName'\"\n [label]=\"'Vorname'\"\n [type]=\"'text'\"\n [control]=\"form.get('firstName')\"\n [autocomplete]=\"'given-name'\"\n ></base-input>\n <base-input\n [id]=\"'lastName'\"\n [name]=\"'lastName'\"\n [label]=\"'Nachname'\"\n [type]=\"'text'\"\n [control]=\"form.get('lastName')\"\n [autocomplete]=\"'family-name'\"\n ></base-input>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [control]=\"form.get('email')\"\n [autocomplete]=\"'email'\"\n ></base-input>\n <base-input\n [id]=\"'password'\"\n [name]=\"'password'\"\n [label]=\"'Passwort'\"\n [type]=\"'password'\"\n [autocomplete]=\"'new-password'\"\n [control]=\"form.get('password')\"\n ></base-input>\n <base-input\n [id]=\"'password-confirm'\"\n [name]=\"'password-confirm'\"\n [label]=\"'Passwort best\u00E4tigen'\"\n [autocomplete]=\"'new-password'\"\n [type]=\"'password'\"\n [control]=\"form.get('passwordConfirm')\"\n ></base-input>\n <base-checkbox [id]=\"'privacy'\" [control]=\"form.get('privacy')\">\n Hiermit best\u00E4tige ich, dass ich die <a routerLink=\"/datenschutz\">Datenschutzerkl\u00E4rung</a> gelesen habe und\n akzeptiere.\n </base-checkbox>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Registrieren</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../login\">Bereits ein Konto? Dann logge Dich hier ein!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n", styles: [".register-container{width:100%;padding:20px 0}@media (min-width: 768px){.register-container{max-width:400px}}\n"], dependencies: [{ kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i5.InputComponent, selector: "base-input", inputs: ["id", "name", "label", "placeholder", "autocomplete", "tabIndex", "control", "type", "required"], outputs: ["enter"] }, { kind: "component", type: i5.CheckboxComponent, selector: "base-checkbox", inputs: ["id", "name", "label", "value", "control", "required"] }] });
167
+ RegisterComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: RegisterComponent, selector: "base-register", ngImport: i0, template: "<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column register-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div id=\"register-error\" class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'firstName'\"\n [name]=\"'firstName'\"\n [label]=\"'Vorname'\"\n [type]=\"'text'\"\n [control]=\"form.get('firstName')\"\n [autocomplete]=\"'given-name'\"\n ></base-input>\n <base-input\n [id]=\"'lastName'\"\n [name]=\"'lastName'\"\n [label]=\"'Nachname'\"\n [type]=\"'text'\"\n [control]=\"form.get('lastName')\"\n [autocomplete]=\"'family-name'\"\n ></base-input>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [control]=\"form.get('email')\"\n [autocomplete]=\"'email'\"\n ></base-input>\n <base-input\n [id]=\"'password'\"\n [name]=\"'password'\"\n [label]=\"'Passwort'\"\n [type]=\"'password'\"\n [autocomplete]=\"'new-password'\"\n [control]=\"form.get('password')\"\n ></base-input>\n <base-input\n [id]=\"'password-confirm'\"\n [name]=\"'password-confirm'\"\n [label]=\"'Passwort best\u00E4tigen'\"\n [autocomplete]=\"'new-password'\"\n [type]=\"'password'\"\n [control]=\"form.get('passwordConfirm')\"\n ></base-input>\n <base-checkbox [id]=\"'privacy'\" [control]=\"form.get('privacy')\">\n Hiermit best\u00E4tige ich, dass ich die <a routerLink=\"/datenschutz\">Datenschutzerkl\u00E4rung</a> gelesen habe und\n akzeptiere.\n </base-checkbox>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Registrieren</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../login\">Bereits ein Konto? Dann logge Dich hier ein!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n", styles: [".register-container{width:100%;padding:20px 0}@media (min-width: 768px){.register-container{max-width:400px}}\n"], dependencies: [{ kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i5.InputComponent, selector: "base-input", inputs: ["id", "name", "label", "placeholder", "autocomplete", "tabIndex", "control", "type", "required", "eyeButton"], outputs: ["enter"] }, { kind: "component", type: i5.CheckboxComponent, selector: "base-checkbox", inputs: ["id", "name", "label", "value", "control", "required"] }] });
168
168
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: RegisterComponent, decorators: [{
169
169
  type: Component,
170
170
  args: [{ selector: 'base-register', template: "<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column register-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div id=\"register-error\" class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'firstName'\"\n [name]=\"'firstName'\"\n [label]=\"'Vorname'\"\n [type]=\"'text'\"\n [control]=\"form.get('firstName')\"\n [autocomplete]=\"'given-name'\"\n ></base-input>\n <base-input\n [id]=\"'lastName'\"\n [name]=\"'lastName'\"\n [label]=\"'Nachname'\"\n [type]=\"'text'\"\n [control]=\"form.get('lastName')\"\n [autocomplete]=\"'family-name'\"\n ></base-input>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [control]=\"form.get('email')\"\n [autocomplete]=\"'email'\"\n ></base-input>\n <base-input\n [id]=\"'password'\"\n [name]=\"'password'\"\n [label]=\"'Passwort'\"\n [type]=\"'password'\"\n [autocomplete]=\"'new-password'\"\n [control]=\"form.get('password')\"\n ></base-input>\n <base-input\n [id]=\"'password-confirm'\"\n [name]=\"'password-confirm'\"\n [label]=\"'Passwort best\u00E4tigen'\"\n [autocomplete]=\"'new-password'\"\n [type]=\"'password'\"\n [control]=\"form.get('passwordConfirm')\"\n ></base-input>\n <base-checkbox [id]=\"'privacy'\" [control]=\"form.get('privacy')\">\n Hiermit best\u00E4tige ich, dass ich die <a routerLink=\"/datenschutz\">Datenschutzerkl\u00E4rung</a> gelesen habe und\n akzeptiere.\n </base-checkbox>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Registrieren</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../login\">Bereits ein Konto? Dann logge Dich hier ein!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n", styles: [".register-container{width:100%;padding:20px 0}@media (min-width: 768px){.register-container{max-width:400px}}\n"] }]
@@ -184,7 +184,7 @@ class ForgotPasswordComponent {
184
184
  */
185
185
  createForm() {
186
186
  this.form = new UntypedFormGroup({
187
- email: new UntypedFormControl('', [Validators.required, Validators.email]),
187
+ email: new UntypedFormControl('', [Validators.required, fullEmail()]),
188
188
  });
189
189
  }
190
190
  /**
@@ -215,7 +215,7 @@ class ForgotPasswordComponent {
215
215
  }
216
216
  }
217
217
  ForgotPasswordComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: ForgotPasswordComponent, deps: [{ token: i1.FormsService }, { token: i1.UserService }, { token: i2.Router }], target: i0.ɵɵFactoryTarget.Component });
218
- ForgotPasswordComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: ForgotPasswordComponent, selector: "base-forgot-password", ngImport: i0, template: "<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column forgot-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [autocomplete]=\"'email'\"\n [control]=\"form.get('email')\"\n ></base-input>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">E-Mail senden</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../login\">Bereits ein Konto? Dann logge Dich hier ein!</a>\n <a routerLink=\"../registrieren\">Noch kein Konto? Dann registriere Dich jetzt!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n", styles: [".forgot-container{width:100%;padding:20px 0}@media (min-width: 768px){.forgot-container{max-width:400px}}\n"], dependencies: [{ kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i5.InputComponent, selector: "base-input", inputs: ["id", "name", "label", "placeholder", "autocomplete", "tabIndex", "control", "type", "required"], outputs: ["enter"] }] });
218
+ ForgotPasswordComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: ForgotPasswordComponent, selector: "base-forgot-password", ngImport: i0, template: "<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column forgot-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [autocomplete]=\"'email'\"\n [control]=\"form.get('email')\"\n ></base-input>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">E-Mail senden</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../login\">Bereits ein Konto? Dann logge Dich hier ein!</a>\n <a routerLink=\"../registrieren\">Noch kein Konto? Dann registriere Dich jetzt!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n", styles: [".forgot-container{width:100%;padding:20px 0}@media (min-width: 768px){.forgot-container{max-width:400px}}\n"], dependencies: [{ kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i2.RouterLinkWithHref, selector: "a[routerLink],area[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "preserveFragment", "skipLocationChange", "replaceUrl", "state", "relativeTo", "routerLink"] }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i5.InputComponent, selector: "base-input", inputs: ["id", "name", "label", "placeholder", "autocomplete", "tabIndex", "control", "type", "required", "eyeButton"], outputs: ["enter"] }] });
219
219
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: ForgotPasswordComponent, decorators: [{
220
220
  type: Component,
221
221
  args: [{ selector: 'base-forgot-password', template: "<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column forgot-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [autocomplete]=\"'email'\"\n [control]=\"form.get('email')\"\n ></base-input>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">E-Mail senden</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../login\">Bereits ein Konto? Dann logge Dich hier ein!</a>\n <a routerLink=\"../registrieren\">Noch kein Konto? Dann registriere Dich jetzt!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n", styles: [".forgot-container{width:100%;padding:20px 0}@media (min-width: 768px){.forgot-container{max-width:400px}}\n"] }]
@@ -257,9 +257,9 @@ class ProfileComponent {
257
257
  },
258
258
  };
259
259
  this.currentUser = authService.currentUser;
260
- this.profileConfig = Object.assign(Object.assign({}, this.profileConfig), this.config);
261
260
  }
262
261
  ngOnInit() {
262
+ this.profileConfig = Object.assign(Object.assign({}, this.profileConfig), this.config);
263
263
  this.route.data.subscribe((data) => {
264
264
  // Merge config from route to component
265
265
  if (data) {
@@ -287,6 +287,80 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImpor
287
287
  type: Input
288
288
  }] } });
289
289
 
290
+ class ResetPasswordComponent {
291
+ constructor(formsService, userService, toastService, route, router) {
292
+ this.formsService = formsService;
293
+ this.userService = userService;
294
+ this.toastService = toastService;
295
+ this.route = route;
296
+ this.router = router;
297
+ this.redirectUrl = '/';
298
+ this.loading = false;
299
+ this.error = '';
300
+ }
301
+ ngOnInit() {
302
+ var _a;
303
+ this.token = (_a = this.route.snapshot.params) === null || _a === void 0 ? void 0 : _a.token;
304
+ if (!this.token) {
305
+ this.error =
306
+ 'Der Link ist abgelaufen oder ungültig, bitte probiere es später erneut oder wende Dich an den Support.';
307
+ }
308
+ this.createForm();
309
+ }
310
+ /**
311
+ * Create password change form
312
+ */
313
+ createForm() {
314
+ this.form = new UntypedFormGroup({
315
+ password: new FormControl('', [Validators.required, Validators.minLength(6)]),
316
+ passwordConfirm: new FormControl('', [Validators.required, Validators.minLength(6)]),
317
+ }, { validators: Validation.match('password', 'passwordConfirm') });
318
+ }
319
+ /**
320
+ * Submit form and change password of user
321
+ */
322
+ submit() {
323
+ this.loading = true;
324
+ if (this.form.invalid) {
325
+ this.formsService.validateAllFormFields(this.form);
326
+ this.loading = false;
327
+ return;
328
+ }
329
+ this.userService.resetPassword(this.token, this.form.get('password').value).subscribe({
330
+ next: (response) => {
331
+ if (response) {
332
+ this.form.reset();
333
+ this.toastService.show({
334
+ id: 'password-reset-success',
335
+ title: 'Erfolgreich',
336
+ description: 'Passwort wurde erfolgreich geändert.',
337
+ type: ToastType.SUCCESS,
338
+ });
339
+ }
340
+ this.router.navigate([this.redirectUrl]);
341
+ this.loading = false;
342
+ },
343
+ error: (error) => {
344
+ this.loading = false;
345
+ this.toastService.show({
346
+ id: 'password-reset-error',
347
+ title: 'Fehlgeschlagen',
348
+ description: 'Passwort zurücksetzen ist fehlgeschlagen, bitte versuche es später erneut.',
349
+ type: ToastType.ERROR,
350
+ });
351
+ },
352
+ });
353
+ }
354
+ }
355
+ ResetPasswordComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: ResetPasswordComponent, deps: [{ token: i1.FormsService }, { token: i1.UserService }, { token: i1.ToastService }, { token: i2.ActivatedRoute }, { token: i2.Router }], target: i0.ɵɵFactoryTarget.Component });
356
+ ResetPasswordComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "14.1.0", type: ResetPasswordComponent, selector: "base-reset-password", inputs: { redirectUrl: "redirectUrl" }, ngImport: i0, template: "<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column reset-password-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'password'\"\n [label]=\"'Passwort'\"\n [required]=\"true\"\n [type]=\"'password'\"\n [control]=\"form.get('password')\"\n [tabIndex]=\"1\"\n [eyeButton]=\"true\"\n ></base-input>\n <base-input\n [id]=\"'password-confirm'\"\n [label]=\"'Passwort best\u00E4tigen'\"\n [required]=\"true\"\n [type]=\"'password'\"\n [control]=\"form.get('passwordConfirm')\"\n [tabIndex]=\"2\"\n [eyeButton]=\"true\"\n ></base-input>\n\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Passwort zur\u00FCcksetzen</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n </div>\n </form>\n </div>\n </div>\n</div>\n", styles: [".reset-password-container{width:100%;padding:20px 0}@media (min-width: 768px){.reset-password-container{max-width:400px}}\n"], dependencies: [{ kind: "directive", type: i3.ɵNgNoValidate, selector: "form:not([ngNoForm]):not([ngNativeValidate])" }, { kind: "directive", type: i3.NgControlStatusGroup, selector: "[formGroupName],[formArrayName],[ngModelGroup],[formGroup],form:not([ngNoForm]),[ngForm]" }, { kind: "directive", type: i3.FormGroupDirective, selector: "[formGroup]", inputs: ["formGroup"], outputs: ["ngSubmit"], exportAs: ["ngForm"] }, { kind: "directive", type: i4.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "component", type: i5.InputComponent, selector: "base-input", inputs: ["id", "name", "label", "placeholder", "autocomplete", "tabIndex", "control", "type", "required", "eyeButton"], outputs: ["enter"] }] });
357
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: ResetPasswordComponent, decorators: [{
358
+ type: Component,
359
+ args: [{ selector: 'base-reset-password', template: "<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column reset-password-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'password'\"\n [label]=\"'Passwort'\"\n [required]=\"true\"\n [type]=\"'password'\"\n [control]=\"form.get('password')\"\n [tabIndex]=\"1\"\n [eyeButton]=\"true\"\n ></base-input>\n <base-input\n [id]=\"'password-confirm'\"\n [label]=\"'Passwort best\u00E4tigen'\"\n [required]=\"true\"\n [type]=\"'password'\"\n [control]=\"form.get('passwordConfirm')\"\n [tabIndex]=\"2\"\n [eyeButton]=\"true\"\n ></base-input>\n\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Passwort zur\u00FCcksetzen</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n </div>\n </form>\n </div>\n </div>\n</div>\n", styles: [".reset-password-container{width:100%;padding:20px 0}@media (min-width: 768px){.reset-password-container{max-width:400px}}\n"] }]
360
+ }], ctorParameters: function () { return [{ type: i1.FormsService }, { type: i1.UserService }, { type: i1.ToastService }, { type: i2.ActivatedRoute }, { type: i2.Router }]; }, propDecorators: { redirectUrl: [{
361
+ type: Input
362
+ }] } });
363
+
290
364
  // Modules
291
365
  const imports = [BaseModule, FormsModule, RouterModule, ReactiveFormsModule, CommonModule, BaseComponentsModule];
292
366
  // Imported and exported elements
@@ -296,6 +370,7 @@ const elements = [
296
370
  RegisterComponent,
297
371
  ForgotPasswordComponent,
298
372
  ProfileComponent,
373
+ ResetPasswordComponent,
299
374
  ];
300
375
  class BasePrototypeModule {
301
376
  }
@@ -305,13 +380,15 @@ BasePrototypeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", ver
305
380
  LoginComponent,
306
381
  RegisterComponent,
307
382
  ForgotPasswordComponent,
308
- ProfileComponent
383
+ ProfileComponent,
384
+ ResetPasswordComponent
309
385
  ], imports: [BaseModule, FormsModule, RouterModule, ReactiveFormsModule, CommonModule, BaseComponentsModule], exports: [
310
386
  // Components
311
387
  LoginComponent,
312
388
  RegisterComponent,
313
389
  ForgotPasswordComponent,
314
- ProfileComponent
390
+ ProfileComponent,
391
+ ResetPasswordComponent
315
392
  ] });
316
393
  BasePrototypeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: BasePrototypeModule, imports: [imports] });
317
394
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: BasePrototypeModule, decorators: [{
@@ -331,5 +408,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImpor
331
408
  * Generated bundle index. Do not edit.
332
409
  */
333
410
 
334
- export { BasePrototypeModule, ForgotPasswordComponent, LoginComponent, ProfileComponent, RegisterComponent };
411
+ export { BasePrototypeModule, ForgotPasswordComponent, LoginComponent, ProfileComponent, RegisterComponent, ResetPasswordComponent };
335
412
  //# sourceMappingURL=lenne.tech-ng-base-base-prototype.mjs.map
@@ -1 +1 @@
1
- {"version":3,"file":"lenne.tech-ng-base-base-prototype.mjs","sources":["../../../projects/ng-base/base-prototype/pages/login/login.component.ts","../../../projects/ng-base/base-prototype/pages/login/login.component.html","../../../projects/ng-base/base-prototype/pages/register/register.component.ts","../../../projects/ng-base/base-prototype/pages/register/register.component.html","../../../projects/ng-base/base-prototype/pages/forgot-password/forgot-password.component.ts","../../../projects/ng-base/base-prototype/pages/forgot-password/forgot-password.component.html","../../../projects/ng-base/base-prototype/pages/profile/profile.component.ts","../../../projects/ng-base/base-prototype/pages/profile/profile.component.html","../../../projects/ng-base/base-prototype/base-prototype.module.ts","../../../projects/ng-base/base-prototype/public-api.ts","../../../projects/ng-base/base-prototype/lenne.tech-ng-base-base-prototype.ts"],"sourcesContent":["import { Component, OnDestroy, OnInit } from '@angular/core';\nimport { UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\nimport { ActivatedRoute, Router } from '@angular/router';\nimport { FormsService, UserService } from '@lenne.tech/ng-base/shared';\nimport { Subscription } from 'rxjs';\n\n@Component({\n selector: 'base-login',\n templateUrl: './login.component.html',\n styleUrls: ['./login.component.scss'],\n})\nexport class LoginComponent implements OnInit, OnDestroy {\n form: UntypedFormGroup;\n error: string;\n loading: boolean;\n subscription = new Subscription();\n config = {\n redirectUrl: '/main',\n showPasswordForget: true,\n showRegister: true,\n logoUrl: '',\n };\n\n constructor(\n private formsService: FormsService,\n private userService: UserService,\n private router: Router,\n private route: ActivatedRoute\n ) {}\n\n ngOnInit(): void {\n this.createForm();\n\n this.subscription.add(\n this.route.data.subscribe((data) => {\n // Merge config from route to component\n if (data?.config) {\n this.config = { ...this.config, ...data.config };\n }\n })\n );\n }\n\n ngOnDestroy() {\n this.subscription.unsubscribe();\n }\n\n /**\n * Create login form\n */\n createForm() {\n this.form = new UntypedFormGroup({\n email: new UntypedFormControl('', [Validators.required, Validators.email]),\n password: new UntypedFormControl('', Validators.required),\n });\n }\n\n /**\n * Submit login form\n */\n submit() {\n this.error = '';\n this.loading = true;\n\n if (this.form.invalid) {\n this.formsService.validateAllFormFields(this.form);\n this.scrollToTop();\n this.loading = false;\n return;\n }\n\n this.userService.login(this.form.value).subscribe({\n next: (response) => {\n if (response) {\n this.router.navigate([this.config.redirectUrl]);\n this.form.reset();\n } else {\n this.error = 'Etwas ist schiefgelaufen. Bitte probiere es später erneut.';\n this.scrollToTop();\n }\n this.loading = false;\n },\n error: (error) => {\n this.error = 'Etwas ist schiefgelaufen. Bitte probiere es später erneut.';\n\n // Wrong password\n if (error?.message?.includes('Unauthorized')) {\n this.error = 'Dein Passwort ist leider falsch. Bitte überprüfe deine Eingabe!';\n }\n\n // User not found\n if (error?.message?.includes('Not user found')) {\n this.error = 'Es konnte kein Konto mit der E-Mail gefunden werden. Bitte gib eine gültige E-Mail ein!';\n }\n\n this.scrollToTop();\n this.loading = false;\n },\n });\n }\n\n scrollToTop() {\n window.scrollTo({ top: 0, behavior: 'smooth' });\n }\n}\n","<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column login-container\">\n <div class=\"container\">\n <img *ngIf=\"config?.logoUrl\" class=\"img-fluid mb-5\" [src]=\"config.logoUrl\" alt=\"Logo\" />\n\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [control]=\"form.get('email')\"\n [autocomplete]=\"'email'\"\n ></base-input>\n <base-input\n [id]=\"'password'\"\n [name]=\"'password'\"\n [label]=\"'Passwort'\"\n [type]=\"'password'\"\n [autocomplete]=\"'current-password'\"\n [control]=\"form.get('password')\"\n ></base-input>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Einloggen</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../passwort-vergessen\" *ngIf=\"config?.showPasswordForget\">Passwort vergessen</a>\n <a routerLink=\"../registrieren\" *ngIf=\"config?.showRegister\">Noch kein Konto? Dann registriere Dich jetzt!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n","import { Component, OnInit } from '@angular/core';\nimport { UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\nimport { FormsService, UserService, Validation } from '@lenne.tech/ng-base/shared';\nimport { Router } from '@angular/router';\n\n@Component({\n selector: 'base-register',\n templateUrl: './register.component.html',\n styleUrls: ['./register.component.scss'],\n})\nexport class RegisterComponent implements OnInit {\n form: UntypedFormGroup;\n error: string;\n loading: boolean;\n\n constructor(private formsService: FormsService, private userService: UserService, private router: Router) {}\n\n ngOnInit(): void {\n this.createForm();\n }\n\n /**\n * Create login form\n */\n createForm() {\n this.form = new UntypedFormGroup(\n {\n firstName: new UntypedFormControl('', [Validators.required]),\n lastName: new UntypedFormControl('', [Validators.required]),\n email: new UntypedFormControl('', [Validators.required, Validators.email]),\n password: new UntypedFormControl('', [Validators.required, Validators.minLength(6)]),\n passwordConfirm: new UntypedFormControl('', [Validators.required, Validators.minLength(6)]),\n privacy: new UntypedFormControl(false, Validators.requiredTrue),\n },\n {\n validators: [Validation.match('password', 'passwordConfirm')],\n }\n );\n }\n\n /**\n * Submit login form\n */\n submit() {\n this.error = '';\n this.loading = true;\n\n if (this.form.invalid) {\n this.formsService.validateAllFormFields(this.form);\n this.scrollToTop();\n this.loading = false;\n return;\n }\n\n const input = this.form.value;\n delete input.privacy;\n\n this.userService.register(input).subscribe({\n next: (auth) => {\n if (auth) {\n this.router.navigate(['/main']);\n } else {\n this.error = 'Etwas ist schiefgelaufen. Bitte probiere es später erneut.';\n this.scrollToTop();\n }\n this.loading = false;\n },\n error: (err) => {\n if (err?.message?.includes('already exists')) {\n this.error =\n 'Mit dieser E-Mail gibt es bereits ein Konto. Bitte wähle eine andere E-Mail Adresse oder logge dich mit deinem Passwort ein.';\n this.scrollToTop();\n }\n\n this.loading = false;\n },\n });\n }\n\n scrollToTop() {\n window.scrollTo({ top: 0, behavior: 'smooth' });\n }\n}\n","<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column register-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div id=\"register-error\" class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'firstName'\"\n [name]=\"'firstName'\"\n [label]=\"'Vorname'\"\n [type]=\"'text'\"\n [control]=\"form.get('firstName')\"\n [autocomplete]=\"'given-name'\"\n ></base-input>\n <base-input\n [id]=\"'lastName'\"\n [name]=\"'lastName'\"\n [label]=\"'Nachname'\"\n [type]=\"'text'\"\n [control]=\"form.get('lastName')\"\n [autocomplete]=\"'family-name'\"\n ></base-input>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [control]=\"form.get('email')\"\n [autocomplete]=\"'email'\"\n ></base-input>\n <base-input\n [id]=\"'password'\"\n [name]=\"'password'\"\n [label]=\"'Passwort'\"\n [type]=\"'password'\"\n [autocomplete]=\"'new-password'\"\n [control]=\"form.get('password')\"\n ></base-input>\n <base-input\n [id]=\"'password-confirm'\"\n [name]=\"'password-confirm'\"\n [label]=\"'Passwort bestätigen'\"\n [autocomplete]=\"'new-password'\"\n [type]=\"'password'\"\n [control]=\"form.get('passwordConfirm')\"\n ></base-input>\n <base-checkbox [id]=\"'privacy'\" [control]=\"form.get('privacy')\">\n Hiermit bestätige ich, dass ich die <a routerLink=\"/datenschutz\">Datenschutzerklärung</a> gelesen habe und\n akzeptiere.\n </base-checkbox>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Registrieren</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../login\">Bereits ein Konto? Dann logge Dich hier ein!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n","import { Component, OnInit } from '@angular/core';\nimport { UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\nimport { FormsService, UserService } from '@lenne.tech/ng-base/shared';\nimport { Router } from '@angular/router';\n\n@Component({\n selector: 'base-forgot-password',\n templateUrl: './forgot-password.component.html',\n styleUrls: ['./forgot-password.component.scss'],\n})\nexport class ForgotPasswordComponent implements OnInit {\n form: UntypedFormGroup;\n error: string;\n loading: boolean;\n\n constructor(private formsService: FormsService, private userService: UserService, private router: Router) {}\n\n ngOnInit(): void {\n this.createForm();\n }\n\n /**\n * Create login form\n */\n createForm() {\n this.form = new UntypedFormGroup({\n email: new UntypedFormControl('', [Validators.required, Validators.email]),\n });\n }\n\n /**\n * Submit form\n */\n submit() {\n this.loading = true;\n\n if (this.form.invalid) {\n this.formsService.validateAllFormFields(this.form);\n this.loading = false;\n return;\n }\n\n this.userService.requestPasswordResetMail(this.form.get('email').value).subscribe({\n next: (response) => {\n if (response) {\n this.router.navigate(['/']);\n } else {\n this.error = 'Etwas ist schiefgelaufen. Bitte probiere es später erneut.';\n }\n this.loading = false;\n },\n error: () => {\n this.error = 'Etwas ist schiefgelaufen. Bitte probiere es später erneut.';\n this.loading = false;\n },\n });\n }\n}\n","<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column forgot-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [autocomplete]=\"'email'\"\n [control]=\"form.get('email')\"\n ></base-input>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">E-Mail senden</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../login\">Bereits ein Konto? Dann logge Dich hier ein!</a>\n <a routerLink=\"../registrieren\">Noch kein Konto? Dann registriere Dich jetzt!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n","import { Component, Input, OnInit } from '@angular/core';\nimport { AuthService, BasicUser, UserService } from '@lenne.tech/ng-base/shared';\nimport { ActivatedRoute } from '@angular/router';\n\n@Component({\n selector: 'base-profile',\n templateUrl: './profile.component.html',\n styleUrls: ['./profile.component.scss'],\n})\nexport class ProfileComponent implements OnInit {\n @Input() config: any = {};\n profileConfig = {\n avatar: {\n label: 'E-Mail',\n placeholder: '',\n },\n email: {\n label: 'E-Mail',\n placeholder: '',\n },\n firstName: {\n label: 'Vorname',\n placeholder: '',\n },\n lastName: {\n label: 'Nachname',\n placeholder: '',\n },\n roles: {\n exclude: true,\n roles: ['admin'],\n },\n username: {\n label: 'Benutzername',\n placeholder: '',\n },\n password: {\n exclude: true,\n },\n };\n\n currentUser: BasicUser;\n\n constructor(private authService: AuthService, private route: ActivatedRoute, private userService: UserService) {\n this.currentUser = authService.currentUser;\n this.profileConfig = { ...this.profileConfig, ...this.config };\n }\n\n ngOnInit() {\n this.route.data.subscribe((data) => {\n // Merge config from route to component\n if (data) {\n this.profileConfig = { ...this.profileConfig, ...data };\n }\n });\n }\n\n /**\n * It gets the current user from the database and updates the current user in the session\n */\n updateSessionUser() {\n this.userService.get(this.authService.currentUser.id).subscribe((user) => {\n if (user) {\n this.authService.currentUser = user;\n }\n });\n }\n}\n","<div class=\"container\">\n <div class=\"py-5\">\n <base-model-form\n [id]=\"currentUser?.id\"\n [modelName]=\"'user'\"\n [label]=\"'Mein Profil'\"\n [config]=\"profileConfig || {}\"\n [delete]=\"false\"\n (finished)=\"updateSessionUser()\"\n ></base-model-form>\n </div>\n</div>\n","import { NgModule } from '@angular/core';\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\nimport { CommonModule } from '@angular/common';\nimport { RouterModule } from '@angular/router';\n\nimport { BaseModule } from '@lenne.tech/ng-base';\nimport { BaseComponentsModule } from '@lenne.tech/ng-base/base-components';\n\nimport { LoginComponent } from './pages/login/login.component';\nimport { RegisterComponent } from './pages/register/register.component';\nimport { ForgotPasswordComponent } from './pages/forgot-password/forgot-password.component';\nimport { ProfileComponent } from './pages/profile/profile.component';\n\n// Modules\nconst imports = [BaseModule, FormsModule, RouterModule, ReactiveFormsModule, CommonModule, BaseComponentsModule];\n\n// Imported and exported elements\nconst elements = [\n // Components\n LoginComponent,\n RegisterComponent,\n ForgotPasswordComponent,\n ProfileComponent,\n];\n\n@NgModule({\n declarations: elements,\n imports,\n exports: elements,\n})\nexport class BasePrototypeModule {}\n","/**\n * Exports for public API\n */\n\n// Module\nexport * from './base-prototype.module';\n\n// Pages\nexport * from './pages/login/login.component';\nexport * from './pages/register/register.component';\nexport * from './pages/forgot-password/forgot-password.component';\nexport * from './pages/profile/profile.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i3"],"mappings":";;;;;;;;;;;;;;;MAWa,cAAc,CAAA;AAYzB,IAAA,WAAA,CACU,YAA0B,EAC1B,WAAwB,EACxB,MAAc,EACd,KAAqB,EAAA;AAHrB,QAAA,IAAY,CAAA,YAAA,GAAZ,YAAY,CAAc;AAC1B,QAAA,IAAW,CAAA,WAAA,GAAX,WAAW,CAAa;AACxB,QAAA,IAAM,CAAA,MAAA,GAAN,MAAM,CAAQ;AACd,QAAA,IAAK,CAAA,KAAA,GAAL,KAAK,CAAgB;AAZ/B,QAAA,IAAA,CAAA,YAAY,GAAG,IAAI,YAAY,EAAE,CAAC;QAClC,IAAA,CAAA,MAAM,GAAG;AACP,YAAA,WAAW,EAAE,OAAO;AACpB,YAAA,kBAAkB,EAAE,IAAI;AACxB,YAAA,YAAY,EAAE,IAAI;AAClB,YAAA,OAAO,EAAE,EAAE;SACZ,CAAC;KAOE;IAEJ,QAAQ,GAAA;QACN,IAAI,CAAC,UAAU,EAAE,CAAC;AAElB,QAAA,IAAI,CAAC,YAAY,CAAC,GAAG,CACnB,IAAI,CAAC,KAAK,CAAC,IAAI,CAAC,SAAS,CAAC,CAAC,IAAI,KAAI;;AAEjC,YAAA,IAAI,IAAI,KAAJ,IAAA,IAAA,IAAI,uBAAJ,IAAI,CAAE,MAAM,EAAE;gBAChB,IAAI,CAAC,MAAM,GAAA,MAAA,CAAA,MAAA,CAAA,MAAA,CAAA,MAAA,CAAA,EAAA,EAAQ,IAAI,CAAC,MAAM,CAAA,EAA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AAU,EAAE,WAAW,EAAE,YAAY,EAAE,mBAAmB,EAAE,YAAY,EAAE,oBAAoB,CAAA,EAAA,OAAA,EAAA;;QAK7G,cAAc;QACd,iBAAiB;QACjB,uBAAuB;QACvB,gBAAgB;AAAA,KAAA,EAAA,CAAA,CAAA;AAQL,mBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,mBAAmB,YAH9B,OAAO,CAAA,EAAA,CAAA,CAAA;2FAGI,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAL/B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE,QAAQ;oBACtB,OAAO;AACP,oBAAA,OAAO,EAAE,QAAQ;iBAClB,CAAA;;;AC7BD;;AAEG;;ACFH;;AAEG;;;;"}
1
+ {"version":3,"file":"lenne.tech-ng-base-base-prototype.mjs","sources":["../../../projects/ng-base/base-prototype/pages/login/login.component.ts","../../../projects/ng-base/base-prototype/pages/login/login.component.html","../../../projects/ng-base/base-prototype/pages/register/register.component.ts","../../../projects/ng-base/base-prototype/pages/register/register.component.html","../../../projects/ng-base/base-prototype/pages/forgot-password/forgot-password.component.ts","../../../projects/ng-base/base-prototype/pages/forgot-password/forgot-password.component.html","../../../projects/ng-base/base-prototype/pages/profile/profile.component.ts","../../../projects/ng-base/base-prototype/pages/profile/profile.component.html","../../../projects/ng-base/base-prototype/pages/reset-password/reset-password.component.ts","../../../projects/ng-base/base-prototype/pages/reset-password/reset-password.component.html","../../../projects/ng-base/base-prototype/base-prototype.module.ts","../../../projects/ng-base/base-prototype/public-api.ts","../../../projects/ng-base/base-prototype/lenne.tech-ng-base-base-prototype.ts"],"sourcesContent":["import { Component, OnDestroy, OnInit } from '@angular/core';\nimport { UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\nimport { ActivatedRoute, Router } from '@angular/router';\nimport { FormsService, UserService, fullEmail } from '@lenne.tech/ng-base/shared';\nimport { Subscription } from 'rxjs';\n\n@Component({\n selector: 'base-login',\n templateUrl: './login.component.html',\n styleUrls: ['./login.component.scss'],\n})\nexport class LoginComponent implements OnInit, OnDestroy {\n form: UntypedFormGroup;\n error: string;\n loading: boolean;\n subscription = new Subscription();\n config = {\n redirectUrl: '/main',\n showPasswordForget: true,\n showRegister: true,\n logoUrl: '',\n };\n\n constructor(\n private formsService: FormsService,\n private userService: UserService,\n private router: Router,\n private route: ActivatedRoute\n ) {}\n\n ngOnInit(): void {\n this.createForm();\n\n this.subscription.add(\n this.route.data.subscribe((data) => {\n // Merge config from route to component\n if (data?.config) {\n this.config = { ...this.config, ...data.config };\n }\n })\n );\n }\n\n ngOnDestroy() {\n this.subscription.unsubscribe();\n }\n\n /**\n * Create login form\n */\n createForm() {\n this.form = new UntypedFormGroup({\n email: new UntypedFormControl('', [Validators.required, fullEmail()]),\n password: new UntypedFormControl('', Validators.required),\n });\n }\n\n /**\n * Submit login form\n */\n submit() {\n this.error = '';\n this.loading = true;\n\n if (this.form.invalid) {\n this.formsService.validateAllFormFields(this.form);\n this.scrollToTop();\n this.loading = false;\n return;\n }\n\n this.userService.login(this.form.value).subscribe({\n next: (response) => {\n if (response) {\n this.router.navigate([this.config.redirectUrl]);\n this.form.reset();\n } else {\n this.error = 'Etwas ist schiefgelaufen. Bitte probiere es später erneut.';\n this.scrollToTop();\n }\n this.loading = false;\n },\n error: (error) => {\n this.error = 'Etwas ist schiefgelaufen. Bitte probiere es später erneut.';\n\n // Wrong password\n if (error?.message?.includes('Unauthorized')) {\n this.error = 'Dein Passwort ist leider falsch. Bitte überprüfe deine Eingabe!';\n }\n\n // User not found\n if (error?.message?.includes('Not user found')) {\n this.error = 'Es konnte kein Konto mit der E-Mail gefunden werden. Bitte gib eine gültige E-Mail ein!';\n }\n\n this.scrollToTop();\n this.loading = false;\n },\n });\n }\n\n scrollToTop() {\n window.scrollTo({ top: 0, behavior: 'smooth' });\n }\n}\n","<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column login-container\">\n <div class=\"container\">\n <img *ngIf=\"config?.logoUrl\" class=\"img-fluid mb-5\" [src]=\"config.logoUrl\" alt=\"Logo\" />\n\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [control]=\"form.get('email')\"\n [autocomplete]=\"'email'\"\n ></base-input>\n <base-input\n [id]=\"'password'\"\n [name]=\"'password'\"\n [label]=\"'Passwort'\"\n [type]=\"'password'\"\n [autocomplete]=\"'current-password'\"\n [control]=\"form.get('password')\"\n ></base-input>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Einloggen</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../passwort-vergessen\" *ngIf=\"config?.showPasswordForget\">Passwort vergessen</a>\n <a routerLink=\"../registrieren\" *ngIf=\"config?.showRegister\">Noch kein Konto? Dann registriere Dich jetzt!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n","import { Component, OnInit } from '@angular/core';\nimport { UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\nimport { FormsService, UserService, Validation, fullEmail } from '@lenne.tech/ng-base/shared';\nimport { Router } from '@angular/router';\n\n@Component({\n selector: 'base-register',\n templateUrl: './register.component.html',\n styleUrls: ['./register.component.scss'],\n})\nexport class RegisterComponent implements OnInit {\n form: UntypedFormGroup;\n error: string;\n loading: boolean;\n\n constructor(private formsService: FormsService, private userService: UserService, private router: Router) {}\n\n ngOnInit(): void {\n this.createForm();\n }\n\n /**\n * Create login form\n */\n createForm() {\n this.form = new UntypedFormGroup(\n {\n firstName: new UntypedFormControl('', [Validators.required]),\n lastName: new UntypedFormControl('', [Validators.required]),\n email: new UntypedFormControl('', [Validators.required, fullEmail()]),\n password: new UntypedFormControl('', [Validators.required, Validators.minLength(6)]),\n passwordConfirm: new UntypedFormControl('', [Validators.required, Validators.minLength(6)]),\n privacy: new UntypedFormControl(false, Validators.requiredTrue),\n },\n {\n validators: [Validation.match('password', 'passwordConfirm')],\n }\n );\n }\n\n /**\n * Submit login form\n */\n submit() {\n this.error = '';\n this.loading = true;\n\n if (this.form.invalid) {\n this.formsService.validateAllFormFields(this.form);\n this.scrollToTop();\n this.loading = false;\n return;\n }\n\n const input = this.form.value;\n delete input.privacy;\n\n this.userService.register(input).subscribe({\n next: (auth) => {\n if (auth) {\n this.router.navigate(['/main']);\n } else {\n this.error = 'Etwas ist schiefgelaufen. Bitte probiere es später erneut.';\n this.scrollToTop();\n }\n this.loading = false;\n },\n error: (err) => {\n if (err?.message?.includes('already exists')) {\n this.error =\n 'Mit dieser E-Mail gibt es bereits ein Konto. Bitte wähle eine andere E-Mail Adresse oder logge dich mit deinem Passwort ein.';\n this.scrollToTop();\n }\n\n this.loading = false;\n },\n });\n }\n\n scrollToTop() {\n window.scrollTo({ top: 0, behavior: 'smooth' });\n }\n}\n","<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column register-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div id=\"register-error\" class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'firstName'\"\n [name]=\"'firstName'\"\n [label]=\"'Vorname'\"\n [type]=\"'text'\"\n [control]=\"form.get('firstName')\"\n [autocomplete]=\"'given-name'\"\n ></base-input>\n <base-input\n [id]=\"'lastName'\"\n [name]=\"'lastName'\"\n [label]=\"'Nachname'\"\n [type]=\"'text'\"\n [control]=\"form.get('lastName')\"\n [autocomplete]=\"'family-name'\"\n ></base-input>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [control]=\"form.get('email')\"\n [autocomplete]=\"'email'\"\n ></base-input>\n <base-input\n [id]=\"'password'\"\n [name]=\"'password'\"\n [label]=\"'Passwort'\"\n [type]=\"'password'\"\n [autocomplete]=\"'new-password'\"\n [control]=\"form.get('password')\"\n ></base-input>\n <base-input\n [id]=\"'password-confirm'\"\n [name]=\"'password-confirm'\"\n [label]=\"'Passwort bestätigen'\"\n [autocomplete]=\"'new-password'\"\n [type]=\"'password'\"\n [control]=\"form.get('passwordConfirm')\"\n ></base-input>\n <base-checkbox [id]=\"'privacy'\" [control]=\"form.get('privacy')\">\n Hiermit bestätige ich, dass ich die <a routerLink=\"/datenschutz\">Datenschutzerklärung</a> gelesen habe und\n akzeptiere.\n </base-checkbox>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Registrieren</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../login\">Bereits ein Konto? Dann logge Dich hier ein!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n","import { Component, OnInit } from '@angular/core';\nimport { UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\nimport { FormsService, UserService, fullEmail } from '@lenne.tech/ng-base/shared';\nimport { Router } from '@angular/router';\n\n@Component({\n selector: 'base-forgot-password',\n templateUrl: './forgot-password.component.html',\n styleUrls: ['./forgot-password.component.scss'],\n})\nexport class ForgotPasswordComponent implements OnInit {\n form: UntypedFormGroup;\n error: string;\n loading: boolean;\n\n constructor(private formsService: FormsService, private userService: UserService, private router: Router) {}\n\n ngOnInit(): void {\n this.createForm();\n }\n\n /**\n * Create login form\n */\n createForm() {\n this.form = new UntypedFormGroup({\n email: new UntypedFormControl('', [Validators.required, fullEmail()]),\n });\n }\n\n /**\n * Submit form\n */\n submit() {\n this.loading = true;\n\n if (this.form.invalid) {\n this.formsService.validateAllFormFields(this.form);\n this.loading = false;\n return;\n }\n\n this.userService.requestPasswordResetMail(this.form.get('email').value).subscribe({\n next: (response) => {\n if (response) {\n this.router.navigate(['/']);\n } else {\n this.error = 'Etwas ist schiefgelaufen. Bitte probiere es später erneut.';\n }\n this.loading = false;\n },\n error: () => {\n this.error = 'Etwas ist schiefgelaufen. Bitte probiere es später erneut.';\n this.loading = false;\n },\n });\n }\n}\n","<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column forgot-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'email'\"\n [name]=\"'email'\"\n [label]=\"'E-Mail Adresse'\"\n [type]=\"'email'\"\n [autocomplete]=\"'email'\"\n [control]=\"form.get('email')\"\n ></base-input>\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">E-Mail senden</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n <hr />\n <a routerLink=\"../login\">Bereits ein Konto? Dann logge Dich hier ein!</a>\n <a routerLink=\"../registrieren\">Noch kein Konto? Dann registriere Dich jetzt!</a>\n </div>\n </form>\n </div>\n </div>\n</div>\n","import { Component, Input, OnInit } from '@angular/core';\nimport { AuthService, BasicUser, UserService } from '@lenne.tech/ng-base/shared';\nimport { ActivatedRoute } from '@angular/router';\n\n@Component({\n selector: 'base-profile',\n templateUrl: './profile.component.html',\n styleUrls: ['./profile.component.scss'],\n})\nexport class ProfileComponent implements OnInit {\n @Input() config: any = {};\n profileConfig = {\n avatar: {\n label: 'E-Mail',\n placeholder: '',\n },\n email: {\n label: 'E-Mail',\n placeholder: '',\n },\n firstName: {\n label: 'Vorname',\n placeholder: '',\n },\n lastName: {\n label: 'Nachname',\n placeholder: '',\n },\n roles: {\n exclude: true,\n roles: ['admin'],\n },\n username: {\n label: 'Benutzername',\n placeholder: '',\n },\n password: {\n exclude: true,\n },\n };\n\n currentUser: BasicUser;\n\n constructor(private authService: AuthService, private route: ActivatedRoute, private userService: UserService) {\n this.currentUser = authService.currentUser;\n }\n\n ngOnInit() {\n this.profileConfig = { ...this.profileConfig, ...this.config };\n this.route.data.subscribe((data) => {\n // Merge config from route to component\n if (data) {\n this.profileConfig = { ...this.profileConfig, ...data };\n }\n });\n }\n\n /**\n * It gets the current user from the database and updates the current user in the session\n */\n updateSessionUser() {\n this.userService.get(this.authService.currentUser.id).subscribe((user) => {\n if (user) {\n this.authService.currentUser = user;\n }\n });\n }\n}\n","<div class=\"container\">\n <div class=\"py-5\">\n <base-model-form\n [id]=\"currentUser?.id\"\n [modelName]=\"'user'\"\n [label]=\"'Mein Profil'\"\n [config]=\"profileConfig || {}\"\n [delete]=\"false\"\n (finished)=\"updateSessionUser()\"\n ></base-model-form>\n </div>\n</div>\n","import { Component, Input, OnInit } from '@angular/core';\nimport { FormControl, FormGroup, UntypedFormGroup, Validators } from '@angular/forms';\nimport { FormsService, ToastService, ToastType, UserService, Validation } from '@lenne.tech/ng-base/shared';\nimport { ActivatedRoute, Router } from '@angular/router';\n\n@Component({\n selector: 'base-reset-password',\n templateUrl: './reset-password.component.html',\n styleUrls: ['./reset-password.component.scss'],\n})\nexport class ResetPasswordComponent implements OnInit {\n @Input() redirectUrl = '/';\n form: FormGroup;\n loading = false;\n token: string;\n error = '';\n\n constructor(\n private formsService: FormsService,\n private userService: UserService,\n private toastService: ToastService,\n private route: ActivatedRoute,\n private router: Router\n ) {}\n\n ngOnInit(): void {\n this.token = this.route.snapshot.params?.token;\n\n if (!this.token) {\n this.error =\n 'Der Link ist abgelaufen oder ungültig, bitte probiere es später erneut oder wende Dich an den Support.';\n }\n\n this.createForm();\n }\n\n /**\n * Create password change form\n */\n createForm() {\n this.form = new UntypedFormGroup(\n {\n password: new FormControl<string>('', [Validators.required, Validators.minLength(6)]),\n passwordConfirm: new FormControl<string>('', [Validators.required, Validators.minLength(6)]),\n },\n { validators: Validation.match('password', 'passwordConfirm') }\n );\n }\n\n /**\n * Submit form and change password of user\n */\n submit() {\n this.loading = true;\n\n if (this.form.invalid) {\n this.formsService.validateAllFormFields(this.form);\n this.loading = false;\n return;\n }\n\n this.userService.resetPassword(this.token, this.form.get('password').value).subscribe({\n next: (response) => {\n if (response) {\n this.form.reset();\n this.toastService.show({\n id: 'password-reset-success',\n title: 'Erfolgreich',\n description: 'Passwort wurde erfolgreich geändert.',\n type: ToastType.SUCCESS,\n });\n }\n\n this.router.navigate([this.redirectUrl]);\n this.loading = false;\n },\n error: (error) => {\n this.loading = false;\n this.toastService.show({\n id: 'password-reset-error',\n title: 'Fehlgeschlagen',\n description: 'Passwort zurücksetzen ist fehlgeschlagen, bitte versuche es später erneut.',\n type: ToastType.ERROR,\n });\n },\n });\n }\n}\n","<div class=\"d-flex justify-content-center align-items-center h-100 py-5\">\n <div class=\"d-flex flex-column reset-password-container\">\n <div class=\"container\">\n <form [formGroup]=\"form\">\n <div class=\"alert alert-danger\" role=\"alert\" *ngIf=\"error\">\n {{ error }}\n </div>\n <base-input\n [id]=\"'password'\"\n [label]=\"'Passwort'\"\n [required]=\"true\"\n [type]=\"'password'\"\n [control]=\"form.get('password')\"\n [tabIndex]=\"1\"\n [eyeButton]=\"true\"\n ></base-input>\n <base-input\n [id]=\"'password-confirm'\"\n [label]=\"'Passwort bestätigen'\"\n [required]=\"true\"\n [type]=\"'password'\"\n [control]=\"form.get('passwordConfirm')\"\n [tabIndex]=\"2\"\n [eyeButton]=\"true\"\n ></base-input>\n\n <div class=\"d-grid gap-2 text-center\">\n <button class=\"btn btn-primary\" (click)=\"submit()\" *ngIf=\"!loading\">Passwort zurücksetzen</button>\n <button class=\"btn btn-primary\" type=\"button\" disabled *ngIf=\"loading\">\n <span class=\"spinner-border spinner-border-sm\" role=\"status\" aria-hidden=\"true\"></span>\n Loading...\n </button>\n </div>\n </form>\n </div>\n </div>\n</div>\n","import { NgModule } from '@angular/core';\nimport { FormsModule, ReactiveFormsModule } from '@angular/forms';\nimport { CommonModule } from '@angular/common';\nimport { RouterModule } from '@angular/router';\n\nimport { BaseModule } from '@lenne.tech/ng-base';\nimport { BaseComponentsModule } from '@lenne.tech/ng-base/base-components';\n\nimport { LoginComponent } from './pages/login/login.component';\nimport { RegisterComponent } from './pages/register/register.component';\nimport { ForgotPasswordComponent } from './pages/forgot-password/forgot-password.component';\nimport { ProfileComponent } from './pages/profile/profile.component';\nimport { ResetPasswordComponent } from './pages/reset-password/reset-password.component';\n\n// Modules\nconst imports = [BaseModule, FormsModule, RouterModule, ReactiveFormsModule, CommonModule, BaseComponentsModule];\n\n// Imported and exported elements\nconst elements = [\n // Components\n LoginComponent,\n RegisterComponent,\n ForgotPasswordComponent,\n ProfileComponent,\n ResetPasswordComponent,\n];\n\n@NgModule({\n declarations: elements,\n imports,\n exports: elements,\n})\nexport class BasePrototypeModule {}\n","/**\n * Exports for public API\n */\n\n// Module\nexport * from './base-prototype.module';\n\n// Pages\nexport * from './pages/login/login.component';\nexport * from './pages/register/register.component';\nexport * from './pages/forgot-password/forgot-password.component';\nexport * from './pages/profile/profile.component';\nexport * from './pages/reset-password/reset-password.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":["i3"],"mappings":";;;;;;;;;;;;;;;MAWa,cAAc,CAAA;AAYzB,IAAA,WAAA,CACU,YAA0B,EAC1B,WAAwB,EACxB,MAAc,EACd,KAAqB,EAAA;AAHrB,QAAA,IAAY,CAAA,YAAA,GAAZ,YAAY,CAAc;AAC1B,QAAA,IAAW,CAAA,WAAA,GAAX,WAAW,CAAa;AACxB,QA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AAA,CATP,UAAU,EAAE,WAAW,EAAE,YAAY,EAAE,mBAAmB,EAAE,YAAY,EAAE,oBAAoB,CAAA,EAAA,OAAA,EAAA;;QAK7G,cAAc;QACd,iBAAiB;QACjB,uBAAuB;QACvB,gBAAgB;QAChB,sBAAsB;AAAA,KAAA,EAAA,CAAA,CAAA;AAQX,mBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,mBAAmB,YAH9B,OAAO,CAAA,EAAA,CAAA,CAAA;2FAGI,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAL/B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,YAAY,EAAE,QAAQ;oBACtB,OAAO;AACP,oBAAA,OAAO,EAAE,QAAQ;iBAClB,CAAA;;;AC/BD;;AAEG;;ACFH;;AAEG;;;;"}
@@ -449,10 +449,13 @@ class GraphQLMeta {
449
449
  *
450
450
  * @returns An array of objects with the name of the model, and the CRUD operations that are available for that model.
451
451
  */
452
- getTypes() {
452
+ getTypes(logging = false) {
453
453
  const possibleTypes = [];
454
454
  const mutationType = this.schema.getMutationType();
455
455
  const queryType = this.schema.getQueryType();
456
+ if (logging) {
457
+ console.log('GraphQLMeta::getTypes->queryTypeFields', queryType.getFields());
458
+ }
456
459
  for (const [key, value] of Object.entries(queryType.getFields())) {
457
460
  if (key.startsWith('find')) {
458
461
  possibleTypes.push({
@@ -464,6 +467,10 @@ class GraphQLMeta {
464
467
  });
465
468
  }
466
469
  }
470
+ if (logging) {
471
+ console.log('GraphQLMeta::getTypes->mutationTypeFields', mutationType.getFields());
472
+ console.log('GraphQLMeta::getTypes->possibleTypes', possibleTypes);
473
+ }
467
474
  for (const [key, value] of Object.entries(mutationType.getFields())) {
468
475
  if (key.startsWith('create')) {
469
476
  const model = key.split('create').pop();
@@ -490,6 +497,10 @@ class GraphQLMeta {
490
497
  }
491
498
  }
492
499
  }
500
+ if (logging) {
501
+ console.log('GraphQLMeta::getTypes->possibleTypes', possibleTypes);
502
+ console.log('GraphQLMeta::getTypes->filteredPossibleTypes', possibleTypes.filter((e) => e.create || e.update));
503
+ }
493
504
  return possibleTypes.filter((e) => e.create || e.update);
494
505
  }
495
506
  /**
@@ -1730,6 +1741,33 @@ class UserService extends GraphQLPlusService {
1730
1741
  loading: true,
1731
1742
  });
1732
1743
  }
1744
+ /**
1745
+ * Change password of current user
1746
+ *
1747
+ * @param id
1748
+ * @param password
1749
+ */
1750
+ changePassword(id, password) {
1751
+ return this.graphQl('updateUser', {
1752
+ arguments: { id, input: { password } },
1753
+ fields: ['id'],
1754
+ type: GraphQLRequestType.MUTATION,
1755
+ loading: true,
1756
+ });
1757
+ }
1758
+ /**
1759
+ * Set new password by token
1760
+ *
1761
+ * @param token
1762
+ * @param password
1763
+ */
1764
+ resetPassword(token, password) {
1765
+ return this.graphQl('resetPassword', {
1766
+ arguments: { token, password },
1767
+ type: GraphQLRequestType.MUTATION,
1768
+ loading: true,
1769
+ });
1770
+ }
1733
1771
  }
1734
1772
  UserService.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: UserService, deps: [{ token: i1.Apollo }, { token: GraphQLMetaService }, { token: LoaderService }, { token: AuthService }], target: i0.ɵɵFactoryTarget.Injectable });
1735
1773
  UserService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: UserService, providedIn: 'root' });
@@ -2281,6 +2319,13 @@ class Validation {
2281
2319
  }
2282
2320
  }
2283
2321
 
2322
+ function fullEmail() {
2323
+ return (control) => {
2324
+ const EMAIL_REGEXP = /^(([^<>()\[\]\.,;:\s@\"]+(\.[^<>()\[\]\.,;:\s@\"]+)*)|(\".+\"))@(([^<>()[\]\.,;:\s@\"]+\.)+[^<>()[\]\.,;:\s@\"]{2,})$/i;
2325
+ return !EMAIL_REGEXP.test(control.value) ? { invalidEmail: true } : null;
2326
+ };
2327
+ }
2328
+
2284
2329
  function createRestartableClient(options) {
2285
2330
  let restartRequested = false;
2286
2331
  let restart = () => {
@@ -2319,5 +2364,5 @@ function createRestartableClient(options) {
2319
2364
  * Generated bundle index. Do not edit.
2320
2365
  */
2321
2366
 
2322
- export { Auth, AuthService, BASE_MODULE_CONFIG, BasicUser, BreadcrumbService, CmsService, ComparisonOperatorEnum, FormsService, GraphQLEnum, GraphQLMeta, GraphQLMetaService, GraphQLPlusService, GraphQLRequestType, GraphQLService, GraphQLType, Helper, ImageService, LoaderService, LogicalOperatorEnum, NavigationService, ScrollService, SkeletonType, Sort, SortOrderEnum, Standard, StorageService, ToastService, ToastType, UserService, Validation, WsService, createRestartableClient, debounce };
2367
+ export { Auth, AuthService, BASE_MODULE_CONFIG, BasicUser, BreadcrumbService, CmsService, ComparisonOperatorEnum, FormsService, GraphQLEnum, GraphQLMeta, GraphQLMetaService, GraphQLPlusService, GraphQLRequestType, GraphQLService, GraphQLType, Helper, ImageService, LoaderService, LogicalOperatorEnum, NavigationService, ScrollService, SkeletonType, Sort, SortOrderEnum, Standard, StorageService, ToastService, ToastType, UserService, Validation, WsService, createRestartableClient, debounce, fullEmail };
2323
2368
  //# sourceMappingURL=lenne.tech-ng-base-shared.mjs.map