@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.
- package/base-components/base-components.module.d.ts +5 -4
- package/base-components/components/change-password/change-password.component.d.ts +24 -0
- package/base-components/components/input/input.component.d.ts +6 -1
- package/base-components/components/refence-input/refence-input.component.d.ts +10 -2
- package/base-components/components/tags/tags.component.d.ts +0 -2
- package/base-components/public-api.d.ts +1 -0
- package/base-prototype/base-prototype.module.d.ts +7 -6
- package/base-prototype/pages/reset-password/reset-password.component.d.ts +29 -0
- package/base-prototype/public-api.d.ts +1 -0
- package/esm2020/base-cms/pages/base-cms/base-cms.component.mjs +2 -2
- package/esm2020/base-components/base-components.module.mjs +5 -1
- package/esm2020/base-components/components/change-password/change-password.component.mjs +70 -0
- package/esm2020/base-components/components/input/input.component.mjs +17 -3
- package/esm2020/base-components/components/model-form/model-form.component.mjs +3 -3
- package/esm2020/base-components/components/model-form-sub/model-form-sub.component.mjs +3 -3
- package/esm2020/base-components/components/refence-input/refence-input.component.mjs +60 -10
- package/esm2020/base-components/components/tags/tags.component.mjs +12 -5
- package/esm2020/base-components/public-api.mjs +2 -1
- package/esm2020/base-prototype/base-prototype.module.mjs +7 -3
- package/esm2020/base-prototype/pages/forgot-password/forgot-password.component.mjs +4 -3
- package/esm2020/base-prototype/pages/login/login.component.mjs +4 -3
- package/esm2020/base-prototype/pages/profile/profile.component.mjs +2 -2
- package/esm2020/base-prototype/pages/register/register.component.mjs +4 -4
- package/esm2020/base-prototype/pages/reset-password/reset-password.component.mjs +82 -0
- package/esm2020/base-prototype/public-api.mjs +2 -1
- package/esm2020/shared/classes/graphql-meta.class.mjs +13 -2
- package/esm2020/shared/public-api.mjs +2 -1
- package/esm2020/shared/services/user.service.mjs +28 -1
- package/esm2020/shared/validators/email.validator.mjs +7 -0
- package/fesm2015/lenne.tech-ng-base-base-cms.mjs +4 -4
- package/fesm2015/lenne.tech-ng-base-base-cms.mjs.map +1 -1
- package/fesm2015/lenne.tech-ng-base-base-components.mjs +158 -24
- package/fesm2015/lenne.tech-ng-base-base-components.mjs.map +1 -1
- package/fesm2015/lenne.tech-ng-base-base-prototype.mjs +90 -13
- package/fesm2015/lenne.tech-ng-base-base-prototype.mjs.map +1 -1
- package/fesm2015/lenne.tech-ng-base-shared.mjs +47 -2
- package/fesm2015/lenne.tech-ng-base-shared.mjs.map +1 -1
- package/fesm2020/lenne.tech-ng-base-base-cms.mjs +1 -1
- package/fesm2020/lenne.tech-ng-base-base-cms.mjs.map +1 -1
- package/fesm2020/lenne.tech-ng-base-base-components.mjs +157 -21
- package/fesm2020/lenne.tech-ng-base-base-components.mjs.map +1 -1
- package/fesm2020/lenne.tech-ng-base-base-prototype.mjs +89 -13
- package/fesm2020/lenne.tech-ng-base-base-prototype.mjs.map +1 -1
- package/fesm2020/lenne.tech-ng-base-shared.mjs +47 -2
- package/fesm2020/lenne.tech-ng-base-shared.mjs.map +1 -1
- package/package.json +1 -1
- package/shared/classes/graphql-meta.class.d.ts +1 -1
- package/shared/public-api.d.ts +1 -0
- package/shared/services/user.service.d.ts +14 -0
- 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,
|
|
47
|
+
email: new UntypedFormControl('', [Validators.required, fullEmail()]),
|
|
48
48
|
password: new UntypedFormControl('', Validators.required),
|
|
49
49
|
});
|
|
50
50
|
}
|
|
@@ -92,7 +92,7 @@ class LoginComponent {
|
|
|
92
92
|
}
|
|
93
93
|
}
|
|
94
94
|
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 });
|
|
95
|
-
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"] }] });
|
|
95
|
+
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"] }] });
|
|
96
96
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: LoginComponent, decorators: [{
|
|
97
97
|
type: Component,
|
|
98
98
|
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"] }]
|
|
@@ -114,7 +114,7 @@ class RegisterComponent {
|
|
|
114
114
|
this.form = new UntypedFormGroup({
|
|
115
115
|
firstName: new UntypedFormControl('', [Validators.required]),
|
|
116
116
|
lastName: new UntypedFormControl('', [Validators.required]),
|
|
117
|
-
email: new UntypedFormControl('', [Validators.required,
|
|
117
|
+
email: new UntypedFormControl('', [Validators.required, fullEmail()]),
|
|
118
118
|
password: new UntypedFormControl('', [Validators.required, Validators.minLength(6)]),
|
|
119
119
|
passwordConfirm: new UntypedFormControl('', [Validators.required, Validators.minLength(6)]),
|
|
120
120
|
privacy: new UntypedFormControl(false, Validators.requiredTrue),
|
|
@@ -162,7 +162,7 @@ class RegisterComponent {
|
|
|
162
162
|
}
|
|
163
163
|
}
|
|
164
164
|
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 });
|
|
165
|
-
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"] }] });
|
|
165
|
+
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"] }] });
|
|
166
166
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: RegisterComponent, decorators: [{
|
|
167
167
|
type: Component,
|
|
168
168
|
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"] }]
|
|
@@ -182,7 +182,7 @@ class ForgotPasswordComponent {
|
|
|
182
182
|
*/
|
|
183
183
|
createForm() {
|
|
184
184
|
this.form = new UntypedFormGroup({
|
|
185
|
-
email: new UntypedFormControl('', [Validators.required,
|
|
185
|
+
email: new UntypedFormControl('', [Validators.required, fullEmail()]),
|
|
186
186
|
});
|
|
187
187
|
}
|
|
188
188
|
/**
|
|
@@ -213,7 +213,7 @@ class ForgotPasswordComponent {
|
|
|
213
213
|
}
|
|
214
214
|
}
|
|
215
215
|
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 });
|
|
216
|
-
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"] }] });
|
|
216
|
+
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"] }] });
|
|
217
217
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: ForgotPasswordComponent, decorators: [{
|
|
218
218
|
type: Component,
|
|
219
219
|
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"] }]
|
|
@@ -255,9 +255,9 @@ class ProfileComponent {
|
|
|
255
255
|
},
|
|
256
256
|
};
|
|
257
257
|
this.currentUser = authService.currentUser;
|
|
258
|
-
this.profileConfig = { ...this.profileConfig, ...this.config };
|
|
259
258
|
}
|
|
260
259
|
ngOnInit() {
|
|
260
|
+
this.profileConfig = { ...this.profileConfig, ...this.config };
|
|
261
261
|
this.route.data.subscribe((data) => {
|
|
262
262
|
// Merge config from route to component
|
|
263
263
|
if (data) {
|
|
@@ -285,6 +285,79 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImpor
|
|
|
285
285
|
type: Input
|
|
286
286
|
}] } });
|
|
287
287
|
|
|
288
|
+
class ResetPasswordComponent {
|
|
289
|
+
constructor(formsService, userService, toastService, route, router) {
|
|
290
|
+
this.formsService = formsService;
|
|
291
|
+
this.userService = userService;
|
|
292
|
+
this.toastService = toastService;
|
|
293
|
+
this.route = route;
|
|
294
|
+
this.router = router;
|
|
295
|
+
this.redirectUrl = '/';
|
|
296
|
+
this.loading = false;
|
|
297
|
+
this.error = '';
|
|
298
|
+
}
|
|
299
|
+
ngOnInit() {
|
|
300
|
+
this.token = this.route.snapshot.params?.token;
|
|
301
|
+
if (!this.token) {
|
|
302
|
+
this.error =
|
|
303
|
+
'Der Link ist abgelaufen oder ungültig, bitte probiere es später erneut oder wende Dich an den Support.';
|
|
304
|
+
}
|
|
305
|
+
this.createForm();
|
|
306
|
+
}
|
|
307
|
+
/**
|
|
308
|
+
* Create password change form
|
|
309
|
+
*/
|
|
310
|
+
createForm() {
|
|
311
|
+
this.form = new UntypedFormGroup({
|
|
312
|
+
password: new FormControl('', [Validators.required, Validators.minLength(6)]),
|
|
313
|
+
passwordConfirm: new FormControl('', [Validators.required, Validators.minLength(6)]),
|
|
314
|
+
}, { validators: Validation.match('password', 'passwordConfirm') });
|
|
315
|
+
}
|
|
316
|
+
/**
|
|
317
|
+
* Submit form and change password of user
|
|
318
|
+
*/
|
|
319
|
+
submit() {
|
|
320
|
+
this.loading = true;
|
|
321
|
+
if (this.form.invalid) {
|
|
322
|
+
this.formsService.validateAllFormFields(this.form);
|
|
323
|
+
this.loading = false;
|
|
324
|
+
return;
|
|
325
|
+
}
|
|
326
|
+
this.userService.resetPassword(this.token, this.form.get('password').value).subscribe({
|
|
327
|
+
next: (response) => {
|
|
328
|
+
if (response) {
|
|
329
|
+
this.form.reset();
|
|
330
|
+
this.toastService.show({
|
|
331
|
+
id: 'password-reset-success',
|
|
332
|
+
title: 'Erfolgreich',
|
|
333
|
+
description: 'Passwort wurde erfolgreich geändert.',
|
|
334
|
+
type: ToastType.SUCCESS,
|
|
335
|
+
});
|
|
336
|
+
}
|
|
337
|
+
this.router.navigate([this.redirectUrl]);
|
|
338
|
+
this.loading = false;
|
|
339
|
+
},
|
|
340
|
+
error: (error) => {
|
|
341
|
+
this.loading = false;
|
|
342
|
+
this.toastService.show({
|
|
343
|
+
id: 'password-reset-error',
|
|
344
|
+
title: 'Fehlgeschlagen',
|
|
345
|
+
description: 'Passwort zurücksetzen ist fehlgeschlagen, bitte versuche es später erneut.',
|
|
346
|
+
type: ToastType.ERROR,
|
|
347
|
+
});
|
|
348
|
+
},
|
|
349
|
+
});
|
|
350
|
+
}
|
|
351
|
+
}
|
|
352
|
+
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 });
|
|
353
|
+
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"] }] });
|
|
354
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: ResetPasswordComponent, decorators: [{
|
|
355
|
+
type: Component,
|
|
356
|
+
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"] }]
|
|
357
|
+
}], ctorParameters: function () { return [{ type: i1.FormsService }, { type: i1.UserService }, { type: i1.ToastService }, { type: i2.ActivatedRoute }, { type: i2.Router }]; }, propDecorators: { redirectUrl: [{
|
|
358
|
+
type: Input
|
|
359
|
+
}] } });
|
|
360
|
+
|
|
288
361
|
// Modules
|
|
289
362
|
const imports = [BaseModule, FormsModule, RouterModule, ReactiveFormsModule, CommonModule, BaseComponentsModule];
|
|
290
363
|
// Imported and exported elements
|
|
@@ -294,6 +367,7 @@ const elements = [
|
|
|
294
367
|
RegisterComponent,
|
|
295
368
|
ForgotPasswordComponent,
|
|
296
369
|
ProfileComponent,
|
|
370
|
+
ResetPasswordComponent,
|
|
297
371
|
];
|
|
298
372
|
class BasePrototypeModule {
|
|
299
373
|
}
|
|
@@ -303,12 +377,14 @@ BasePrototypeModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", ver
|
|
|
303
377
|
LoginComponent,
|
|
304
378
|
RegisterComponent,
|
|
305
379
|
ForgotPasswordComponent,
|
|
306
|
-
ProfileComponent
|
|
380
|
+
ProfileComponent,
|
|
381
|
+
ResetPasswordComponent], imports: [BaseModule, FormsModule, RouterModule, ReactiveFormsModule, CommonModule, BaseComponentsModule], exports: [
|
|
307
382
|
// Components
|
|
308
383
|
LoginComponent,
|
|
309
384
|
RegisterComponent,
|
|
310
385
|
ForgotPasswordComponent,
|
|
311
|
-
ProfileComponent
|
|
386
|
+
ProfileComponent,
|
|
387
|
+
ResetPasswordComponent] });
|
|
312
388
|
BasePrototypeModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: BasePrototypeModule, imports: [imports] });
|
|
313
389
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: BasePrototypeModule, decorators: [{
|
|
314
390
|
type: NgModule,
|
|
@@ -327,5 +403,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.0", ngImpor
|
|
|
327
403
|
* Generated bundle index. Do not edit.
|
|
328
404
|
*/
|
|
329
405
|
|
|
330
|
-
export { BasePrototypeModule, ForgotPasswordComponent, LoginComponent, ProfileComponent, RegisterComponent };
|
|
406
|
+
export { BasePrototypeModule, ForgotPasswordComponent, LoginComponent, ProfileComponent, RegisterComponent, ResetPasswordComponent };
|
|
331
407
|
//# 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;QAHrB,IAAY,CAAA,YAAA,GAAZ,YAAY,CAAc;QAC1B,IAAW,CAAA,WAAA,GAAX,WAAW,CAAa;QACxB,IAAM,CAAA,MAAA,GAAN,MAAM,CAAQ;QACd,IAAK,CAAA,KAAA,GAAL,KAAK,CAAgB;AAZ/B,QAAA,IAAA,CAAA,YAAY,GAAG,IAAI,YAAY,EAAE,CAAC;AAClC,QAAA,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;;YAEjC,IAAI,IAAI,EAAE,MAAM,EAAE;AAChB,gBAAA,IAAI,CAAC,MAAM,GAAG,EAAE,GAAG,IAAI,CAAC,MAAM,EAAE,GAAG,IAAI,CAAC,MAAM,EAAE,CAAC;AAClD,aAAA;SACF,CAAC,CACH,CAAC;KACH;IAED,WAAW,GAAA;AACT,QAAA,IAAI,CAAC,YAAY,CAAC,WAAW,EAAE,CAAC;KACjC;AAED;;AAEG;IACH,UAAU,GAAA;AACR,QAAA,IAAI,CAAC,IA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,EAAE,oBAAoB,CAAC,CAAC;AAEjH;AACA,MAAM,QAAQ,GAAG;;IAEf,cAAc;IACd,iBAAiB;IACjB,uBAAuB;IACvB,gBAAgB;CACjB,CAAC;MAOW,mBAAmB,CAAA;;gHAAnB,mBAAmB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;iHAAnB,mBAAmB,EAAA,YAAA,EAAA;;QAX9B,cAAc;QACd,iBAAiB;QACjB,uBAAuB;QACvB,gBAAgB,CAAA,EAAA,OAAA,EAAA,CARD,UAAU,EAAE,WAAW,EAAE,YAAY,EAAE,mBAAmB,EAAE,YAAY,EAAE,oBAAoB,CAAA,EAAA,OAAA,EAAA;;QAK7G,cAAc;QACd,iBAAiB;QACjB,uBAAuB;QACvB,gBAAgB,CAAA,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;AAClB,iBAAA,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;QAHrB,IAAY,CAAA,YAAA,GAAZ,YAAY,CAAc;QAC1B,IAAW,CAAA,WAAA,GAAX,WAAW,CAAa;QACxB,IAAM,CAAA,MAAA,GAAN,MAAM,CAAQ;QACd,IAAK,CAAA,KAAA,GAAL,KAAK,CAAgB;AAZ/B,QAAA,IAAA,CAAA,YAAY,GAAG,IAAI,YAAY,EAAE,CAAC;AAClC,QAAA,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;;YAEjC,IAAI,IAAI,EAAE,MAAM,EAAE;AAChB,gBAAA,IAAI,CAAC,MAAM,GAAG,EAAE,GAAG,IAAI,CAAC,MAAM,EAAE,GAAG,IAAI,CAAC,MAAM,EAAE,CAAC;AAClD,aAAA;SACF,CAAC,CACH,CAAC;KACH;IAED,WAAW,GAAA;AACT,QAAA,IAAI,CAAC,YAAY,CAAC,WAAW,EAAE,CAAC;KACjC;AAED;;AAEG;IACH,UAAU,GAAA;AACR,QAAA,IAAI,CAAC,IAAI,GAAG,IAAI,gBAAgB,CAAC;AAC/B,YAAA,KAAK,EAAE,IAA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AAO;AACP,oBAAA,OAAO,EAAE,QAAQ;AAClB,iBAAA,CAAA;;;AC/BD;;AAEG;;ACFH;;AAEG;;;;"}
|
|
@@ -453,10 +453,13 @@ class GraphQLMeta {
|
|
|
453
453
|
*
|
|
454
454
|
* @returns An array of objects with the name of the model, and the CRUD operations that are available for that model.
|
|
455
455
|
*/
|
|
456
|
-
getTypes() {
|
|
456
|
+
getTypes(logging = false) {
|
|
457
457
|
const possibleTypes = [];
|
|
458
458
|
const mutationType = this.schema.getMutationType();
|
|
459
459
|
const queryType = this.schema.getQueryType();
|
|
460
|
+
if (logging) {
|
|
461
|
+
console.log('GraphQLMeta::getTypes->queryTypeFields', queryType.getFields());
|
|
462
|
+
}
|
|
460
463
|
for (const [key, value] of Object.entries(queryType.getFields())) {
|
|
461
464
|
if (key.startsWith('find')) {
|
|
462
465
|
possibleTypes.push({
|
|
@@ -468,6 +471,10 @@ class GraphQLMeta {
|
|
|
468
471
|
});
|
|
469
472
|
}
|
|
470
473
|
}
|
|
474
|
+
if (logging) {
|
|
475
|
+
console.log('GraphQLMeta::getTypes->mutationTypeFields', mutationType.getFields());
|
|
476
|
+
console.log('GraphQLMeta::getTypes->possibleTypes', possibleTypes);
|
|
477
|
+
}
|
|
471
478
|
for (const [key, value] of Object.entries(mutationType.getFields())) {
|
|
472
479
|
if (key.startsWith('create')) {
|
|
473
480
|
const model = key.split('create').pop();
|
|
@@ -494,6 +501,10 @@ class GraphQLMeta {
|
|
|
494
501
|
}
|
|
495
502
|
}
|
|
496
503
|
}
|
|
504
|
+
if (logging) {
|
|
505
|
+
console.log('GraphQLMeta::getTypes->possibleTypes', possibleTypes);
|
|
506
|
+
console.log('GraphQLMeta::getTypes->filteredPossibleTypes', possibleTypes.filter((e) => e.create || e.update));
|
|
507
|
+
}
|
|
497
508
|
return possibleTypes.filter((e) => e.create || e.update);
|
|
498
509
|
}
|
|
499
510
|
/**
|
|
@@ -1772,6 +1783,33 @@ class UserService extends GraphQLPlusService {
|
|
|
1772
1783
|
loading: true,
|
|
1773
1784
|
});
|
|
1774
1785
|
}
|
|
1786
|
+
/**
|
|
1787
|
+
* Change password of current user
|
|
1788
|
+
*
|
|
1789
|
+
* @param id
|
|
1790
|
+
* @param password
|
|
1791
|
+
*/
|
|
1792
|
+
changePassword(id, password) {
|
|
1793
|
+
return this.graphQl('updateUser', {
|
|
1794
|
+
arguments: { id, input: { password } },
|
|
1795
|
+
fields: ['id'],
|
|
1796
|
+
type: GraphQLRequestType.MUTATION,
|
|
1797
|
+
loading: true,
|
|
1798
|
+
});
|
|
1799
|
+
}
|
|
1800
|
+
/**
|
|
1801
|
+
* Set new password by token
|
|
1802
|
+
*
|
|
1803
|
+
* @param token
|
|
1804
|
+
* @param password
|
|
1805
|
+
*/
|
|
1806
|
+
resetPassword(token, password) {
|
|
1807
|
+
return this.graphQl('resetPassword', {
|
|
1808
|
+
arguments: { token, password },
|
|
1809
|
+
type: GraphQLRequestType.MUTATION,
|
|
1810
|
+
loading: true,
|
|
1811
|
+
});
|
|
1812
|
+
}
|
|
1775
1813
|
}
|
|
1776
1814
|
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 });
|
|
1777
1815
|
UserService.ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "14.1.0", ngImport: i0, type: UserService, providedIn: 'root' });
|
|
@@ -2330,6 +2368,13 @@ class Validation {
|
|
|
2330
2368
|
}
|
|
2331
2369
|
}
|
|
2332
2370
|
|
|
2371
|
+
function fullEmail() {
|
|
2372
|
+
return (control) => {
|
|
2373
|
+
const EMAIL_REGEXP = /^(([^<>()\[\]\.,;:\s@\"]+(\.[^<>()\[\]\.,;:\s@\"]+)*)|(\".+\"))@(([^<>()[\]\.,;:\s@\"]+\.)+[^<>()[\]\.,;:\s@\"]{2,})$/i;
|
|
2374
|
+
return !EMAIL_REGEXP.test(control.value) ? { invalidEmail: true } : null;
|
|
2375
|
+
};
|
|
2376
|
+
}
|
|
2377
|
+
|
|
2333
2378
|
function createRestartableClient(options) {
|
|
2334
2379
|
let restartRequested = false;
|
|
2335
2380
|
let restart = () => {
|
|
@@ -2376,5 +2421,5 @@ function createRestartableClient(options) {
|
|
|
2376
2421
|
* Generated bundle index. Do not edit.
|
|
2377
2422
|
*/
|
|
2378
2423
|
|
|
2379
|
-
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 };
|
|
2424
|
+
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 };
|
|
2380
2425
|
//# sourceMappingURL=lenne.tech-ng-base-shared.mjs.map
|