@tehw0lf/contact-form 0.14.1 → 0.14.3
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/esm2020/lib/contact-form.module.mjs +5 -1
- package/fesm2015/tehw0lf-contact-form.mjs +5 -1
- package/fesm2015/tehw0lf-contact-form.mjs.map +1 -1
- package/fesm2020/tehw0lf-contact-form.mjs +5 -1
- package/fesm2020/tehw0lf-contact-form.mjs.map +1 -1
- package/lib/contact-form.module.d.ts +3 -2
- package/package.json +4 -4
|
@@ -2,6 +2,7 @@ import { CommonModule } from '@angular/common';
|
|
|
2
2
|
import { HttpClientModule } from '@angular/common/http';
|
|
3
3
|
import { NgModule } from '@angular/core';
|
|
4
4
|
import { ReactiveFormsModule } from '@angular/forms';
|
|
5
|
+
import { MatFormFieldModule } from '@angular/material/form-field';
|
|
5
6
|
import { MatInputModule } from '@angular/material/input';
|
|
6
7
|
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
|
7
8
|
import { ContactFormComponent } from './contact-form/contact-form.component';
|
|
@@ -14,11 +15,13 @@ ContactFormModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", versi
|
|
|
14
15
|
HttpClientModule,
|
|
15
16
|
BrowserAnimationsModule,
|
|
16
17
|
ReactiveFormsModule,
|
|
18
|
+
MatFormFieldModule,
|
|
17
19
|
MatInputModule], exports: [ContactFormComponent] });
|
|
18
20
|
ContactFormModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.1.3", ngImport: i0, type: ContactFormModule, providers: [EmailApiService], imports: [CommonModule,
|
|
19
21
|
HttpClientModule,
|
|
20
22
|
BrowserAnimationsModule,
|
|
21
23
|
ReactiveFormsModule,
|
|
24
|
+
MatFormFieldModule,
|
|
22
25
|
MatInputModule] });
|
|
23
26
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.3", ngImport: i0, type: ContactFormModule, decorators: [{
|
|
24
27
|
type: NgModule,
|
|
@@ -28,6 +31,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.3", ngImpor
|
|
|
28
31
|
HttpClientModule,
|
|
29
32
|
BrowserAnimationsModule,
|
|
30
33
|
ReactiveFormsModule,
|
|
34
|
+
MatFormFieldModule,
|
|
31
35
|
MatInputModule
|
|
32
36
|
],
|
|
33
37
|
declarations: [ContactFormComponent],
|
|
@@ -35,4 +39,4 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.3", ngImpor
|
|
|
35
39
|
providers: [EmailApiService]
|
|
36
40
|
}]
|
|
37
41
|
}] });
|
|
38
|
-
//# sourceMappingURL=data:application/json;base64,
|
|
42
|
+
//# sourceMappingURL=data:application/json;base64,eyJ2ZXJzaW9uIjozLCJmaWxlIjoiY29udGFjdC1mb3JtLm1vZHVsZS5qcyIsInNvdXJjZVJvb3QiOiIiLCJzb3VyY2VzIjpbIi4uLy4uLy4uLy4uLy4uL2xpYnMvY29udGFjdC1mb3JtL3NyYy9saWIvY29udGFjdC1mb3JtLm1vZHVsZS50cyJdLCJuYW1lcyI6W10sIm1hcHBpbmdzIjoiQUFBQSxPQUFPLEVBQUUsWUFBWSxFQUFFLE1BQU0saUJBQWlCLENBQUM7QUFDL0MsT0FBTyxFQUFFLGdCQUFnQixFQUFFLE1BQU0sc0JBQXNCLENBQUM7QUFDeEQsT0FBTyxFQUFFLFFBQVEsRUFBRSxNQUFNLGVBQWUsQ0FBQztBQUN6QyxPQUFPLEVBQUUsbUJBQW1CLEVBQUUsTUFBTSxnQkFBZ0IsQ0FBQztBQUNyRCxPQUFPLEVBQUUsa0JBQWtCLEVBQUUsTUFBTSw4QkFBOEIsQ0FBQztBQUNsRSxPQUFPLEVBQUUsY0FBYyxFQUFFLE1BQU0seUJBQXlCLENBQUM7QUFDekQsT0FBTyxFQUFFLHVCQUF1QixFQUFFLE1BQU0sc0NBQXNDLENBQUM7QUFFL0UsT0FBT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5ndWxhci9mb3Jtcyc7XG5pbXBvcnQgeyBNYXRGb3JtRmllbGRNb2R1bGUgfSBmcm9tICdAYW5ndWxhci9tYXRlcmlhbC9mb3JtLWZpZWxkJztcbmltcG9ydCB7IE1hdElucHV0TW9kdWxlIH0gZnJvbSAnQGFuZ3VsYXIvbWF0ZXJpYWwvaW5wdXQnO1xuaW1wb3J0IHsgQnJvd3NlckFuaW1hdGlvbnNNb2R1bGUgfSBmcm9tICdAYW5ndWxhci9wbGF0Zm9ybS1icm93c2VyL2FuaW1hdGlvbnMnO1xuXG5pbXBvcnQgeyBDb250YWN0Rm9ybUNvbXBvbmVudCB9IGZyb20gJy4vY29udGFjdC1mb3JtL2NvbnRhY3QtZm9ybS5jb21wb25lbnQnO1xuaW1wb3J0IHsgRW1haWxBcGlTZXJ2aWNlIH0gZnJvbSAnLi9lbWFpbC1hcGkuc2VydmljZSc7XG5cbkBOZ01vZHVsZSh7XG4gIGltcG9ydHM6IFtcbiAgICBDb21tb25Nb2R1bGUsXG4gICAgSHR0cENsaWVudE1vZHVsZSxcbiAgICBCcm93c2VyQW5pbWF0aW9uc01vZHVsZSxcbiAgICBSZWFjdGl2ZUZvcm1zTW9kdWxlLFxuICAgIE1hdEZvcm1GaWVsZE1vZHVsZSxcbiAgICBNYXRJbnB1dE1vZHVsZVxuICBdLFxuICBkZWNsYXJhdGlvbnM6IFtDb250YWN0Rm9ybUNvbXBvbmVudF0sXG4gIGV4cG9ydHM6IFtDb250YWN0Rm9ybUNvbXBvbmVudF0sXG4gIHByb3ZpZGVyczogW0VtYWlsQXBpU2VydmljZV1cbn0pXG5leHBvcnQgY2xhc3MgQ29udGFjdEZvcm1Nb2R1bGUge31cbiJdfQ==
|
|
@@ -6,12 +6,13 @@ import * as i0 from '@angular/core';
|
|
|
6
6
|
import { Injectable, Component, ViewEncapsulation, Input, NgModule } from '@angular/core';
|
|
7
7
|
import * as i1$1 from '@angular/forms';
|
|
8
8
|
import { UntypedFormControl, Validators, ReactiveFormsModule } from '@angular/forms';
|
|
9
|
+
import * as i4 from '@angular/material/form-field';
|
|
10
|
+
import { MatFormFieldModule } from '@angular/material/form-field';
|
|
9
11
|
import * as i5 from '@angular/material/input';
|
|
10
12
|
import { MatInputModule } from '@angular/material/input';
|
|
11
13
|
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
|
12
14
|
import { of, Subject } from 'rxjs';
|
|
13
15
|
import { map, catchError, tap, takeUntil } from 'rxjs/operators';
|
|
14
|
-
import * as i4 from '@angular/material/form-field';
|
|
15
16
|
|
|
16
17
|
class EmailApiService {
|
|
17
18
|
constructor(http) {
|
|
@@ -132,11 +133,13 @@ ContactFormModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", versi
|
|
|
132
133
|
HttpClientModule,
|
|
133
134
|
BrowserAnimationsModule,
|
|
134
135
|
ReactiveFormsModule,
|
|
136
|
+
MatFormFieldModule,
|
|
135
137
|
MatInputModule], exports: [ContactFormComponent] });
|
|
136
138
|
ContactFormModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.1.3", ngImport: i0, type: ContactFormModule, providers: [EmailApiService], imports: [CommonModule,
|
|
137
139
|
HttpClientModule,
|
|
138
140
|
BrowserAnimationsModule,
|
|
139
141
|
ReactiveFormsModule,
|
|
142
|
+
MatFormFieldModule,
|
|
140
143
|
MatInputModule] });
|
|
141
144
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.3", ngImport: i0, type: ContactFormModule, decorators: [{
|
|
142
145
|
type: NgModule,
|
|
@@ -146,6 +149,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.3", ngImpor
|
|
|
146
149
|
HttpClientModule,
|
|
147
150
|
BrowserAnimationsModule,
|
|
148
151
|
ReactiveFormsModule,
|
|
152
|
+
MatFormFieldModule,
|
|
149
153
|
MatInputModule
|
|
150
154
|
],
|
|
151
155
|
declarations: [ContactFormComponent],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tehw0lf-contact-form.mjs","sources":["../../../../libs/contact-form/src/lib/email-api.service.ts","../../../../libs/contact-form/src/lib/contact-form/contact-form.component.ts","../../../../libs/contact-form/src/lib/contact-form/contact-form.component.html","../../../../libs/contact-form/src/lib/contact-form.module.ts","../../../../libs/contact-form/src/tehw0lf-contact-form.ts"],"sourcesContent":["import { HttpClient, HttpHeaders } from '@angular/common/http';\nimport { Injectable } from '@angular/core';\nimport { Observable, of } from 'rxjs';\nimport { catchError, map } from 'rxjs/operators';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class EmailApiService {\n httpOptions = {\n headers: new HttpHeaders({\n 'Content-Type': 'application/json'\n })\n };\n constructor(private http: HttpClient) {}\n\n sendEmail(apiURL: string, data: any): Observable<any> {\n return this.http.post(apiURL, JSON.stringify(data), this.httpOptions).pipe(\n map((response: any) => {\n return response;\n }),\n catchError((error: any) => {\n return of(error.statusText);\n })\n );\n }\n}\n","import { Component, Input, OnDestroy, ViewEncapsulation } from '@angular/core';\nimport { UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\nimport { Subject } from 'rxjs';\nimport { takeUntil, tap } from 'rxjs/operators';\n\nimport { EmailApiService } from '../email-api.service';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'contact-form',\n templateUrl: './contact-form.component.html',\n encapsulation: ViewEncapsulation.None,\n styleUrls: ['./contact-form.component.scss']\n})\nexport class ContactFormComponent implements OnDestroy {\n @Input() buttonStyle = {\n 'background-color': '#333333',\n border: 'none',\n color: '#cc7832'\n };\n\n @Input() formStyle = {\n color: '#437da8',\n 'background-color': 'rgba(34, 34, 34, 0.75)',\n 'backdrop-filter': 'blur(50px)',\n 'box-shadow': '0 2px 10px rgba(0, 0, 0, 0.075)'\n };\n\n @Input() inputStyle = {\n color: '#282b2e'\n };\n\n @Input() textStyle = { color: '#cc7832' };\n\n @Input() nameLabel = 'Your Name';\n\n @Input() emailAddressLabel = 'Your E-Mail Address';\n\n @Input() messageLabel = 'Your Message';\n\n @Input() sendText = 'Send';\n\n @Input() sendSuccessfulText = 'E-Mail successfully sent';\n\n @Input() sendErrorText = 'Send error';\n\n @Input() apiURL = 'https://forwardmethis.com/';\n @Input() email = '';\n\n formGroup: UntypedFormGroup;\n emailSent: Subject<boolean | null> = new Subject();\n emailSent$ = this.emailSent.asObservable();\n\n private unsubscribe$: Subject<void> = new Subject();\n\n constructor(\n private builder: UntypedFormBuilder,\n private emailService: EmailApiService\n ) {\n this.emailSent.next(null);\n this.formGroup = this.builder.group({\n name: new UntypedFormControl('', [Validators.required]),\n email: new UntypedFormControl('', [Validators.required, Validators.email]),\n message: new UntypedFormControl('', [Validators.required])\n });\n }\n\n ngOnDestroy(): void {\n this.unsubscribe$.next();\n this.unsubscribe$.complete();\n }\n\n submitFormData(formData: UntypedFormGroup) {\n this.emailService\n .sendEmail(`${this.apiURL}${this.email}`, formData.value)\n .pipe(\n tap((response: string) => {\n if (response === 'OK') {\n this.emailSent.next(true);\n } else {\n this.emailSent.next(false);\n }\n }),\n takeUntil(this.unsubscribe$)\n )\n .subscribe();\n }\n}\n","<form\n [ngStyle]=\"formStyle\"\n class=\"contact-form\"\n [formGroup]=\"formGroup\"\n (ngSubmit)=\"submitFormData(formGroup)\"\n fxLayout=\"column\"\n fxFlex\n>\n <mat-form-field class=\"form-field\" appearance=\"outline\" fxFlex>\n <mat-label [ngStyle]=\"textStyle\" for=\"name\">{{ nameLabel }}</mat-label>\n <input\n [ngStyle]=\"textStyle\"\n matInput\n class=\"form-control\"\n type=\"text\"\n name=\"name\"\n formControlName=\"name\"\n />\n </mat-form-field>\n <mat-form-field class=\"form-field\" appearance=\"outline\" fxFlex>\n <mat-label [ngStyle]=\"textStyle\" for=\"email\">{{\n emailAddressLabel\n }}</mat-label>\n <input\n [ngStyle]=\"textStyle\"\n matInput\n class=\"form-control\"\n type=\"email\"\n name=\"email\"\n formControlName=\"email\"\n />\n </mat-form-field>\n <mat-form-field class=\"form-field\" appearance=\"outline\" fxFlex>\n <mat-label [ngStyle]=\"textStyle\" for=\"message\">\n {{ messageLabel }}\n </mat-label>\n <textarea\n [ngStyle]=\"inputStyle\"\n matInput\n formControlName=\"message\"\n name=\"message\"\n >\n </textarea>\n </mat-form-field>\n <button\n [ngStyle]=\"buttonStyle\"\n class=\"form-button\"\n type=\"submit\"\n [disabled]=\"!formGroup.valid\"\n >\n {{ sendText }}\n </button>\n <div\n [ngStyle]=\"textStyle\"\n class=\"form-status\"\n *ngIf=\"(emailSent$ | async) === true\"\n >\n {{ sendSuccessfulText }}\n </div>\n <div\n [ngStyle]=\"textStyle\"\n class=\"form-status\"\n *ngIf=\"(emailSent$ | async) === false\"\n >\n {{ sendErrorText }}\n </div>\n</form>\n","import { CommonModule } from '@angular/common';\nimport { HttpClientModule } from '@angular/common/http';\nimport { NgModule } from '@angular/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { MatInputModule } from '@angular/material/input';\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\n\nimport { ContactFormComponent } from './contact-form/contact-form.component';\nimport { EmailApiService } from './email-api.service';\n\n@NgModule({\n imports: [\n CommonModule,\n HttpClientModule,\n BrowserAnimationsModule,\n ReactiveFormsModule,\n MatInputModule\n ],\n declarations: [ContactFormComponent],\n exports: [ContactFormComponent],\n providers: [EmailApiService]\n})\nexport class ContactFormModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1","i2.EmailApiService"],"mappings":";;;;;;;;;;;;;;;MAQa,eAAe,CAAA;AAM1B,IAAA,WAAA,CAAoB,IAAgB,EAAA;AAAhB,QAAA,IAAI,CAAA,IAAA,GAAJ,IAAI,CAAY;QALpC,IAAA,CAAA,WAAW,GAAG;YACZ,OAAO,EAAE,IAAI,WAAW,CAAC;AACvB,gBAAA,cAAc,EAAE,kBAAkB;aACnC,CAAC;SACH,CAAC;KACsC;IAExC,SAAS,CAAC,M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AA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;+GAAjB,iBAAiB,EAAA,YAAA,EAAA,CAJb,oBAAoB,CAAA,EAAA,OAAA,EAAA,CANjC,YAAY;QACZ,gBAAgB;QAChB,uBAAuB;QACvB,mBAAmB;QACnB,cAAc,aAGN,oBAAoB,CAAA,EAAA,CAAA,CAAA;AAGnB,iBAAA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,iBAAiB,EAFjB,SAAA,EAAA,CAAC,eAAe,CAAC,YAR1B,YAAY;QACZ,gBAAgB;QAChB,uBAAuB;QACvB,mBAAmB;QACnB,cAAc,CAAA,EAAA,CAAA,CAAA;2FAML,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAZ7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE;wBACP,YAAY;wBACZ,gBAAgB;wBAChB,uBAAuB;wBACvB,mBAAmB;wBACnB,cAAc;AACf,qBAAA;oBACD,YAAY,EAAE,CAAC,oBAAoB,CAAC;oBACpC,OAAO,EAAE,CAAC,oBAAoB,CAAC;oBAC/B,SAAS,EAAE,CAAC,eAAe,CAAC;iBAC7B,CAAA;;;ACrBD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"tehw0lf-contact-form.mjs","sources":["../../../../libs/contact-form/src/lib/email-api.service.ts","../../../../libs/contact-form/src/lib/contact-form/contact-form.component.ts","../../../../libs/contact-form/src/lib/contact-form/contact-form.component.html","../../../../libs/contact-form/src/lib/contact-form.module.ts","../../../../libs/contact-form/src/tehw0lf-contact-form.ts"],"sourcesContent":["import { HttpClient, HttpHeaders } from '@angular/common/http';\nimport { Injectable } from '@angular/core';\nimport { Observable, of } from 'rxjs';\nimport { catchError, map } from 'rxjs/operators';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class EmailApiService {\n httpOptions = {\n headers: new HttpHeaders({\n 'Content-Type': 'application/json'\n })\n };\n constructor(private http: HttpClient) {}\n\n sendEmail(apiURL: string, data: any): Observable<any> {\n return this.http.post(apiURL, JSON.stringify(data), this.httpOptions).pipe(\n map((response: any) => {\n return response;\n }),\n catchError((error: any) => {\n return of(error.statusText);\n })\n );\n }\n}\n","import { Component, Input, OnDestroy, ViewEncapsulation } from '@angular/core';\nimport { UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\nimport { Subject } from 'rxjs';\nimport { takeUntil, tap } from 'rxjs/operators';\n\nimport { EmailApiService } from '../email-api.service';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'contact-form',\n templateUrl: './contact-form.component.html',\n encapsulation: ViewEncapsulation.None,\n styleUrls: ['./contact-form.component.scss']\n})\nexport class ContactFormComponent implements OnDestroy {\n @Input() buttonStyle = {\n 'background-color': '#333333',\n border: 'none',\n color: '#cc7832'\n };\n\n @Input() formStyle = {\n color: '#437da8',\n 'background-color': 'rgba(34, 34, 34, 0.75)',\n 'backdrop-filter': 'blur(50px)',\n 'box-shadow': '0 2px 10px rgba(0, 0, 0, 0.075)'\n };\n\n @Input() inputStyle = {\n color: '#282b2e'\n };\n\n @Input() textStyle = { color: '#cc7832' };\n\n @Input() nameLabel = 'Your Name';\n\n @Input() emailAddressLabel = 'Your E-Mail Address';\n\n @Input() messageLabel = 'Your Message';\n\n @Input() sendText = 'Send';\n\n @Input() sendSuccessfulText = 'E-Mail successfully sent';\n\n @Input() sendErrorText = 'Send error';\n\n @Input() apiURL = 'https://forwardmethis.com/';\n @Input() email = '';\n\n formGroup: UntypedFormGroup;\n emailSent: Subject<boolean | null> = new Subject();\n emailSent$ = this.emailSent.asObservable();\n\n private unsubscribe$: Subject<void> = new Subject();\n\n constructor(\n private builder: UntypedFormBuilder,\n private emailService: EmailApiService\n ) {\n this.emailSent.next(null);\n this.formGroup = this.builder.group({\n name: new UntypedFormControl('', [Validators.required]),\n email: new UntypedFormControl('', [Validators.required, Validators.email]),\n message: new UntypedFormControl('', [Validators.required])\n });\n }\n\n ngOnDestroy(): void {\n this.unsubscribe$.next();\n this.unsubscribe$.complete();\n }\n\n submitFormData(formData: UntypedFormGroup) {\n this.emailService\n .sendEmail(`${this.apiURL}${this.email}`, formData.value)\n .pipe(\n tap((response: string) => {\n if (response === 'OK') {\n this.emailSent.next(true);\n } else {\n this.emailSent.next(false);\n }\n }),\n takeUntil(this.unsubscribe$)\n )\n .subscribe();\n }\n}\n","<form\n [ngStyle]=\"formStyle\"\n class=\"contact-form\"\n [formGroup]=\"formGroup\"\n (ngSubmit)=\"submitFormData(formGroup)\"\n fxLayout=\"column\"\n fxFlex\n>\n <mat-form-field class=\"form-field\" appearance=\"outline\" fxFlex>\n <mat-label [ngStyle]=\"textStyle\" for=\"name\">{{ nameLabel }}</mat-label>\n <input\n [ngStyle]=\"textStyle\"\n matInput\n class=\"form-control\"\n type=\"text\"\n name=\"name\"\n formControlName=\"name\"\n />\n </mat-form-field>\n <mat-form-field class=\"form-field\" appearance=\"outline\" fxFlex>\n <mat-label [ngStyle]=\"textStyle\" for=\"email\">{{\n emailAddressLabel\n }}</mat-label>\n <input\n [ngStyle]=\"textStyle\"\n matInput\n class=\"form-control\"\n type=\"email\"\n name=\"email\"\n formControlName=\"email\"\n />\n </mat-form-field>\n <mat-form-field class=\"form-field\" appearance=\"outline\" fxFlex>\n <mat-label [ngStyle]=\"textStyle\" for=\"message\">\n {{ messageLabel }}\n </mat-label>\n <textarea\n [ngStyle]=\"inputStyle\"\n matInput\n formControlName=\"message\"\n name=\"message\"\n >\n </textarea>\n </mat-form-field>\n <button\n [ngStyle]=\"buttonStyle\"\n class=\"form-button\"\n type=\"submit\"\n [disabled]=\"!formGroup.valid\"\n >\n {{ sendText }}\n </button>\n <div\n [ngStyle]=\"textStyle\"\n class=\"form-status\"\n *ngIf=\"(emailSent$ | async) === true\"\n >\n {{ sendSuccessfulText }}\n </div>\n <div\n [ngStyle]=\"textStyle\"\n class=\"form-status\"\n *ngIf=\"(emailSent$ | async) === false\"\n >\n {{ sendErrorText }}\n </div>\n</form>\n","import { CommonModule } from '@angular/common';\nimport { HttpClientModule } from '@angular/common/http';\nimport { NgModule } from '@angular/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatInputModule } from '@angular/material/input';\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\n\nimport { ContactFormComponent } from './contact-form/contact-form.component';\nimport { EmailApiService } from './email-api.service';\n\n@NgModule({\n imports: [\n CommonModule,\n HttpClientModule,\n BrowserAnimationsModule,\n ReactiveFormsModule,\n MatFormFieldModule,\n MatInputModule\n ],\n declarations: [ContactFormComponent],\n exports: [ContactFormComponent],\n providers: [EmailApiService]\n})\nexport class ContactFormModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1","i2.EmailApiService"],"mappings":";;;;;;;;;;;;;;;;MAQa,eAAe,CAAA;AAM1B,IAAA,WAAA,CAAoB,IAAgB,EAAA;AAAhB,QAAA,IAAI,CAAA,IAAA,GAAJ,IAAI,CAAY;QALpC,IAAA,CAAA,WAAW,GAAG;YACZ,OAAO,EAAE,IAAI,WAAW,CAAC;AACvB,gBAAA,cAAc,EAAE,kBAAkB;aACnC,CAAC;SACH,CAAC;KACsC;IAExC,SAAS,CAAC,MAAc,EAAE,IAAS,EAAA;QACjC,OAAO,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC,IAAI,CACxE,GAAG,CAAC,CAAC,QAAa,KAAI;AACpB,YAAA,OAAO,QAAQ,CAAC;AAClB,SAAC,CAAC,EACF,UAAU,CAAC,CAAC,KAAU,KAAI;AACxB,YAAA,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AA,CAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,iBAAiB,EAFjB,SAAA,EAAA,CAAC,eAAe,CAAC,YAT1B,YAAY;QACZ,gBAAgB;QAChB,uBAAuB;QACvB,mBAAmB;QACnB,kBAAkB;QAClB,cAAc,CAAA,EAAA,CAAA,CAAA;2FAML,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAb7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE;wBACP,YAAY;wBACZ,gBAAgB;wBAChB,uBAAuB;wBACvB,mBAAmB;wBACnB,kBAAkB;wBAClB,cAAc;AACf,qBAAA;oBACD,YAAY,EAAE,CAAC,oBAAoB,CAAC;oBACpC,OAAO,EAAE,CAAC,oBAAoB,CAAC;oBAC/B,SAAS,EAAE,CAAC,eAAe,CAAC;iBAC7B,CAAA;;;ACvBD;;AAEG;;;;"}
|
|
@@ -6,12 +6,13 @@ import * as i0 from '@angular/core';
|
|
|
6
6
|
import { Injectable, Component, ViewEncapsulation, Input, NgModule } from '@angular/core';
|
|
7
7
|
import * as i1$1 from '@angular/forms';
|
|
8
8
|
import { UntypedFormControl, Validators, ReactiveFormsModule } from '@angular/forms';
|
|
9
|
+
import * as i4 from '@angular/material/form-field';
|
|
10
|
+
import { MatFormFieldModule } from '@angular/material/form-field';
|
|
9
11
|
import * as i5 from '@angular/material/input';
|
|
10
12
|
import { MatInputModule } from '@angular/material/input';
|
|
11
13
|
import { BrowserAnimationsModule } from '@angular/platform-browser/animations';
|
|
12
14
|
import { of, Subject } from 'rxjs';
|
|
13
15
|
import { map, catchError, tap, takeUntil } from 'rxjs/operators';
|
|
14
|
-
import * as i4 from '@angular/material/form-field';
|
|
15
16
|
|
|
16
17
|
class EmailApiService {
|
|
17
18
|
constructor(http) {
|
|
@@ -132,11 +133,13 @@ ContactFormModule.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", versi
|
|
|
132
133
|
HttpClientModule,
|
|
133
134
|
BrowserAnimationsModule,
|
|
134
135
|
ReactiveFormsModule,
|
|
136
|
+
MatFormFieldModule,
|
|
135
137
|
MatInputModule], exports: [ContactFormComponent] });
|
|
136
138
|
ContactFormModule.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "14.1.3", ngImport: i0, type: ContactFormModule, providers: [EmailApiService], imports: [CommonModule,
|
|
137
139
|
HttpClientModule,
|
|
138
140
|
BrowserAnimationsModule,
|
|
139
141
|
ReactiveFormsModule,
|
|
142
|
+
MatFormFieldModule,
|
|
140
143
|
MatInputModule] });
|
|
141
144
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.3", ngImport: i0, type: ContactFormModule, decorators: [{
|
|
142
145
|
type: NgModule,
|
|
@@ -146,6 +149,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "14.1.3", ngImpor
|
|
|
146
149
|
HttpClientModule,
|
|
147
150
|
BrowserAnimationsModule,
|
|
148
151
|
ReactiveFormsModule,
|
|
152
|
+
MatFormFieldModule,
|
|
149
153
|
MatInputModule
|
|
150
154
|
],
|
|
151
155
|
declarations: [ContactFormComponent],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"tehw0lf-contact-form.mjs","sources":["../../../../libs/contact-form/src/lib/email-api.service.ts","../../../../libs/contact-form/src/lib/contact-form/contact-form.component.ts","../../../../libs/contact-form/src/lib/contact-form/contact-form.component.html","../../../../libs/contact-form/src/lib/contact-form.module.ts","../../../../libs/contact-form/src/tehw0lf-contact-form.ts"],"sourcesContent":["import { HttpClient, HttpHeaders } from '@angular/common/http';\nimport { Injectable } from '@angular/core';\nimport { Observable, of } from 'rxjs';\nimport { catchError, map } from 'rxjs/operators';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class EmailApiService {\n httpOptions = {\n headers: new HttpHeaders({\n 'Content-Type': 'application/json'\n })\n };\n constructor(private http: HttpClient) {}\n\n sendEmail(apiURL: string, data: any): Observable<any> {\n return this.http.post(apiURL, JSON.stringify(data), this.httpOptions).pipe(\n map((response: any) => {\n return response;\n }),\n catchError((error: any) => {\n return of(error.statusText);\n })\n );\n }\n}\n","import { Component, Input, OnDestroy, ViewEncapsulation } from '@angular/core';\nimport { UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\nimport { Subject } from 'rxjs';\nimport { takeUntil, tap } from 'rxjs/operators';\n\nimport { EmailApiService } from '../email-api.service';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'contact-form',\n templateUrl: './contact-form.component.html',\n encapsulation: ViewEncapsulation.None,\n styleUrls: ['./contact-form.component.scss']\n})\nexport class ContactFormComponent implements OnDestroy {\n @Input() buttonStyle = {\n 'background-color': '#333333',\n border: 'none',\n color: '#cc7832'\n };\n\n @Input() formStyle = {\n color: '#437da8',\n 'background-color': 'rgba(34, 34, 34, 0.75)',\n 'backdrop-filter': 'blur(50px)',\n 'box-shadow': '0 2px 10px rgba(0, 0, 0, 0.075)'\n };\n\n @Input() inputStyle = {\n color: '#282b2e'\n };\n\n @Input() textStyle = { color: '#cc7832' };\n\n @Input() nameLabel = 'Your Name';\n\n @Input() emailAddressLabel = 'Your E-Mail Address';\n\n @Input() messageLabel = 'Your Message';\n\n @Input() sendText = 'Send';\n\n @Input() sendSuccessfulText = 'E-Mail successfully sent';\n\n @Input() sendErrorText = 'Send error';\n\n @Input() apiURL = 'https://forwardmethis.com/';\n @Input() email = '';\n\n formGroup: UntypedFormGroup;\n emailSent: Subject<boolean | null> = new Subject();\n emailSent$ = this.emailSent.asObservable();\n\n private unsubscribe$: Subject<void> = new Subject();\n\n constructor(\n private builder: UntypedFormBuilder,\n private emailService: EmailApiService\n ) {\n this.emailSent.next(null);\n this.formGroup = this.builder.group({\n name: new UntypedFormControl('', [Validators.required]),\n email: new UntypedFormControl('', [Validators.required, Validators.email]),\n message: new UntypedFormControl('', [Validators.required])\n });\n }\n\n ngOnDestroy(): void {\n this.unsubscribe$.next();\n this.unsubscribe$.complete();\n }\n\n submitFormData(formData: UntypedFormGroup) {\n this.emailService\n .sendEmail(`${this.apiURL}${this.email}`, formData.value)\n .pipe(\n tap((response: string) => {\n if (response === 'OK') {\n this.emailSent.next(true);\n } else {\n this.emailSent.next(false);\n }\n }),\n takeUntil(this.unsubscribe$)\n )\n .subscribe();\n }\n}\n","<form\n [ngStyle]=\"formStyle\"\n class=\"contact-form\"\n [formGroup]=\"formGroup\"\n (ngSubmit)=\"submitFormData(formGroup)\"\n fxLayout=\"column\"\n fxFlex\n>\n <mat-form-field class=\"form-field\" appearance=\"outline\" fxFlex>\n <mat-label [ngStyle]=\"textStyle\" for=\"name\">{{ nameLabel }}</mat-label>\n <input\n [ngStyle]=\"textStyle\"\n matInput\n class=\"form-control\"\n type=\"text\"\n name=\"name\"\n formControlName=\"name\"\n />\n </mat-form-field>\n <mat-form-field class=\"form-field\" appearance=\"outline\" fxFlex>\n <mat-label [ngStyle]=\"textStyle\" for=\"email\">{{\n emailAddressLabel\n }}</mat-label>\n <input\n [ngStyle]=\"textStyle\"\n matInput\n class=\"form-control\"\n type=\"email\"\n name=\"email\"\n formControlName=\"email\"\n />\n </mat-form-field>\n <mat-form-field class=\"form-field\" appearance=\"outline\" fxFlex>\n <mat-label [ngStyle]=\"textStyle\" for=\"message\">\n {{ messageLabel }}\n </mat-label>\n <textarea\n [ngStyle]=\"inputStyle\"\n matInput\n formControlName=\"message\"\n name=\"message\"\n >\n </textarea>\n </mat-form-field>\n <button\n [ngStyle]=\"buttonStyle\"\n class=\"form-button\"\n type=\"submit\"\n [disabled]=\"!formGroup.valid\"\n >\n {{ sendText }}\n </button>\n <div\n [ngStyle]=\"textStyle\"\n class=\"form-status\"\n *ngIf=\"(emailSent$ | async) === true\"\n >\n {{ sendSuccessfulText }}\n </div>\n <div\n [ngStyle]=\"textStyle\"\n class=\"form-status\"\n *ngIf=\"(emailSent$ | async) === false\"\n >\n {{ sendErrorText }}\n </div>\n</form>\n","import { CommonModule } from '@angular/common';\nimport { HttpClientModule } from '@angular/common/http';\nimport { NgModule } from '@angular/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { MatInputModule } from '@angular/material/input';\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\n\nimport { ContactFormComponent } from './contact-form/contact-form.component';\nimport { EmailApiService } from './email-api.service';\n\n@NgModule({\n imports: [\n CommonModule,\n HttpClientModule,\n BrowserAnimationsModule,\n ReactiveFormsModule,\n MatInputModule\n ],\n declarations: [ContactFormComponent],\n exports: [ContactFormComponent],\n providers: [EmailApiService]\n})\nexport class ContactFormModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1","i2.EmailApiService"],"mappings":";;;;;;;;;;;;;;;MAQa,eAAe,CAAA;AAM1B,IAAA,WAAA,CAAoB,IAAgB,EAAA;QAAhB,IAAI,CAAA,IAAA,GAAJ,IAAI,CAAY;AALpC,QAAA,IAAA,CAAA,WAAW,GAAG;YACZ,OAAO,EAAE,IAAI,WAAW,CAAC;AACvB,gBAAA,cAAc,EAAE,kBAAkB;aACnC,CAAC;SACH,CAAC;KACsC;IAExC,SAAS,CAAC,MAAc,EAAE,IAAS,EAAA;QACjC,OAAO,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC,IAAI,CACxE,GAAG,CAAC,CAAC,QAAa,KAAI;AACpB,YAAA,OAAO,QAAQ,CAAC;AAClB,SAAC,CAAC,EACF,UAAU,CAAC,CAAC,KAAU,KAAI;AACxB,YAAA,OAAO,EAAE,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC;SAC7B,CAAC,CACH,CAAC;KACH;;4GAjBU,eAAe,EAAA,IAAA,EAAA,CA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AFjB,SAAA,EAAA,CAAC,eAAe,CAAC,YAR1B,YAAY;QACZ,gBAAgB;QAChB,uBAAuB;QACvB,mBAAmB;QACnB,cAAc,CAAA,EAAA,CAAA,CAAA;2FAML,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAZ7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE;wBACP,YAAY;wBACZ,gBAAgB;wBAChB,uBAAuB;wBACvB,mBAAmB;wBACnB,cAAc;AACf,qBAAA;oBACD,YAAY,EAAE,CAAC,oBAAoB,CAAC;oBACpC,OAAO,EAAE,CAAC,oBAAoB,CAAC;oBAC/B,SAAS,EAAE,CAAC,eAAe,CAAC;AAC7B,iBAAA,CAAA;;;ACrBD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"tehw0lf-contact-form.mjs","sources":["../../../../libs/contact-form/src/lib/email-api.service.ts","../../../../libs/contact-form/src/lib/contact-form/contact-form.component.ts","../../../../libs/contact-form/src/lib/contact-form/contact-form.component.html","../../../../libs/contact-form/src/lib/contact-form.module.ts","../../../../libs/contact-form/src/tehw0lf-contact-form.ts"],"sourcesContent":["import { HttpClient, HttpHeaders } from '@angular/common/http';\nimport { Injectable } from '@angular/core';\nimport { Observable, of } from 'rxjs';\nimport { catchError, map } from 'rxjs/operators';\n\n@Injectable({\n providedIn: 'root'\n})\nexport class EmailApiService {\n httpOptions = {\n headers: new HttpHeaders({\n 'Content-Type': 'application/json'\n })\n };\n constructor(private http: HttpClient) {}\n\n sendEmail(apiURL: string, data: any): Observable<any> {\n return this.http.post(apiURL, JSON.stringify(data), this.httpOptions).pipe(\n map((response: any) => {\n return response;\n }),\n catchError((error: any) => {\n return of(error.statusText);\n })\n );\n }\n}\n","import { Component, Input, OnDestroy, ViewEncapsulation } from '@angular/core';\nimport { UntypedFormBuilder, UntypedFormControl, UntypedFormGroup, Validators } from '@angular/forms';\nimport { Subject } from 'rxjs';\nimport { takeUntil, tap } from 'rxjs/operators';\n\nimport { EmailApiService } from '../email-api.service';\n\n@Component({\n // eslint-disable-next-line @angular-eslint/component-selector\n selector: 'contact-form',\n templateUrl: './contact-form.component.html',\n encapsulation: ViewEncapsulation.None,\n styleUrls: ['./contact-form.component.scss']\n})\nexport class ContactFormComponent implements OnDestroy {\n @Input() buttonStyle = {\n 'background-color': '#333333',\n border: 'none',\n color: '#cc7832'\n };\n\n @Input() formStyle = {\n color: '#437da8',\n 'background-color': 'rgba(34, 34, 34, 0.75)',\n 'backdrop-filter': 'blur(50px)',\n 'box-shadow': '0 2px 10px rgba(0, 0, 0, 0.075)'\n };\n\n @Input() inputStyle = {\n color: '#282b2e'\n };\n\n @Input() textStyle = { color: '#cc7832' };\n\n @Input() nameLabel = 'Your Name';\n\n @Input() emailAddressLabel = 'Your E-Mail Address';\n\n @Input() messageLabel = 'Your Message';\n\n @Input() sendText = 'Send';\n\n @Input() sendSuccessfulText = 'E-Mail successfully sent';\n\n @Input() sendErrorText = 'Send error';\n\n @Input() apiURL = 'https://forwardmethis.com/';\n @Input() email = '';\n\n formGroup: UntypedFormGroup;\n emailSent: Subject<boolean | null> = new Subject();\n emailSent$ = this.emailSent.asObservable();\n\n private unsubscribe$: Subject<void> = new Subject();\n\n constructor(\n private builder: UntypedFormBuilder,\n private emailService: EmailApiService\n ) {\n this.emailSent.next(null);\n this.formGroup = this.builder.group({\n name: new UntypedFormControl('', [Validators.required]),\n email: new UntypedFormControl('', [Validators.required, Validators.email]),\n message: new UntypedFormControl('', [Validators.required])\n });\n }\n\n ngOnDestroy(): void {\n this.unsubscribe$.next();\n this.unsubscribe$.complete();\n }\n\n submitFormData(formData: UntypedFormGroup) {\n this.emailService\n .sendEmail(`${this.apiURL}${this.email}`, formData.value)\n .pipe(\n tap((response: string) => {\n if (response === 'OK') {\n this.emailSent.next(true);\n } else {\n this.emailSent.next(false);\n }\n }),\n takeUntil(this.unsubscribe$)\n )\n .subscribe();\n }\n}\n","<form\n [ngStyle]=\"formStyle\"\n class=\"contact-form\"\n [formGroup]=\"formGroup\"\n (ngSubmit)=\"submitFormData(formGroup)\"\n fxLayout=\"column\"\n fxFlex\n>\n <mat-form-field class=\"form-field\" appearance=\"outline\" fxFlex>\n <mat-label [ngStyle]=\"textStyle\" for=\"name\">{{ nameLabel }}</mat-label>\n <input\n [ngStyle]=\"textStyle\"\n matInput\n class=\"form-control\"\n type=\"text\"\n name=\"name\"\n formControlName=\"name\"\n />\n </mat-form-field>\n <mat-form-field class=\"form-field\" appearance=\"outline\" fxFlex>\n <mat-label [ngStyle]=\"textStyle\" for=\"email\">{{\n emailAddressLabel\n }}</mat-label>\n <input\n [ngStyle]=\"textStyle\"\n matInput\n class=\"form-control\"\n type=\"email\"\n name=\"email\"\n formControlName=\"email\"\n />\n </mat-form-field>\n <mat-form-field class=\"form-field\" appearance=\"outline\" fxFlex>\n <mat-label [ngStyle]=\"textStyle\" for=\"message\">\n {{ messageLabel }}\n </mat-label>\n <textarea\n [ngStyle]=\"inputStyle\"\n matInput\n formControlName=\"message\"\n name=\"message\"\n >\n </textarea>\n </mat-form-field>\n <button\n [ngStyle]=\"buttonStyle\"\n class=\"form-button\"\n type=\"submit\"\n [disabled]=\"!formGroup.valid\"\n >\n {{ sendText }}\n </button>\n <div\n [ngStyle]=\"textStyle\"\n class=\"form-status\"\n *ngIf=\"(emailSent$ | async) === true\"\n >\n {{ sendSuccessfulText }}\n </div>\n <div\n [ngStyle]=\"textStyle\"\n class=\"form-status\"\n *ngIf=\"(emailSent$ | async) === false\"\n >\n {{ sendErrorText }}\n </div>\n</form>\n","import { CommonModule } from '@angular/common';\nimport { HttpClientModule } from '@angular/common/http';\nimport { NgModule } from '@angular/core';\nimport { ReactiveFormsModule } from '@angular/forms';\nimport { MatFormFieldModule } from '@angular/material/form-field';\nimport { MatInputModule } from '@angular/material/input';\nimport { BrowserAnimationsModule } from '@angular/platform-browser/animations';\n\nimport { ContactFormComponent } from './contact-form/contact-form.component';\nimport { EmailApiService } from './email-api.service';\n\n@NgModule({\n imports: [\n CommonModule,\n HttpClientModule,\n BrowserAnimationsModule,\n ReactiveFormsModule,\n MatFormFieldModule,\n MatInputModule\n ],\n declarations: [ContactFormComponent],\n exports: [ContactFormComponent],\n providers: [EmailApiService]\n})\nexport class ContactFormModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1","i2.EmailApiService"],"mappings":";;;;;;;;;;;;;;;;MAQa,eAAe,CAAA;AAM1B,IAAA,WAAA,CAAoB,IAAgB,EAAA;QAAhB,IAAI,CAAA,IAAA,GAAJ,IAAI,CAAY;AALpC,QAAA,IAAA,CAAA,WAAW,GAAG;YACZ,OAAO,EAAE,IAAI,WAAW,CAAC;AACvB,gBAAA,cAAc,EAAE,kBAAkB;aACnC,CAAC;SACH,CAAC;KACsC;IAExC,SAAS,CAAC,MAAc,EAAE,IAAS,EAAA;QACjC,OAAO,IAAI,CAAC,IAAI,CAAC,IAAI,CAAC,MAAM,EAAE,IAAI,CAAC,SAAS,CAAC,IAAI,CAAC,EAAE,IAAI,CAAC,WAAW,CAAC,CAAC,IAAI,CACxE,GAAG,CAAC,CAAC,QAAa,KAAI;AACpB,YAAA,OAAO,QAAQ,CAAC;AAClB,SAAC,CAAC,EACF,UAAU,CAAC,CAAC,KAAU,KAAI;AACxB,YAAA,OAAO,EAAE,CAAC,KAAK,CAAC,UAAU,CAAC,CAAC;SAC7B,CAAC,CACH,CAAC;KACH;;4GAjBU,eAAe,EAAA,IAAA,EAAA,CAAA,EAAA,KAAA,EAAA,EAAA,CAAA,UAAA,EAAA,CAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,UAAA,EAAA,CAAA,CAAA;AAAf,eAAA,CAAA,KAAA,GAAA,EAAA,CAAA,qBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,eAAe,cAFd,MAAM,EAAA,CAAA,CAAA;2FAEP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AuB;wBACvB,mBAAmB;wBACnB,kBAAkB;wBAClB,cAAc;AACf,qBAAA;oBACD,YAAY,EAAE,CAAC,oBAAoB,CAAC;oBACpC,OAAO,EAAE,CAAC,oBAAoB,CAAC;oBAC/B,SAAS,EAAE,CAAC,eAAe,CAAC;AAC7B,iBAAA,CAAA;;;ACvBD;;AAEG;;;;"}
|
|
@@ -4,9 +4,10 @@ import * as i2 from "@angular/common";
|
|
|
4
4
|
import * as i3 from "@angular/common/http";
|
|
5
5
|
import * as i4 from "@angular/platform-browser/animations";
|
|
6
6
|
import * as i5 from "@angular/forms";
|
|
7
|
-
import * as i6 from "@angular/material/
|
|
7
|
+
import * as i6 from "@angular/material/form-field";
|
|
8
|
+
import * as i7 from "@angular/material/input";
|
|
8
9
|
export declare class ContactFormModule {
|
|
9
10
|
static ɵfac: i0.ɵɵFactoryDeclaration<ContactFormModule, never>;
|
|
10
|
-
static ɵmod: i0.ɵɵNgModuleDeclaration<ContactFormModule, [typeof i1.ContactFormComponent], [typeof i2.CommonModule, typeof i3.HttpClientModule, typeof i4.BrowserAnimationsModule, typeof i5.ReactiveFormsModule, typeof i6.MatInputModule], [typeof i1.ContactFormComponent]>;
|
|
11
|
+
static ɵmod: i0.ɵɵNgModuleDeclaration<ContactFormModule, [typeof i1.ContactFormComponent], [typeof i2.CommonModule, typeof i3.HttpClientModule, typeof i4.BrowserAnimationsModule, typeof i5.ReactiveFormsModule, typeof i6.MatFormFieldModule, typeof i7.MatInputModule], [typeof i1.ContactFormComponent]>;
|
|
11
12
|
static ɵinj: i0.ɵɵInjectorDeclaration<ContactFormModule>;
|
|
12
13
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tehw0lf/contact-form",
|
|
3
|
-
"version": "0.14.
|
|
3
|
+
"version": "0.14.3",
|
|
4
4
|
"license": "MIT",
|
|
5
5
|
"homepage": "https://github.com/tehw0lf/tehwol.fi.git",
|
|
6
6
|
"repository": {
|
|
@@ -9,12 +9,12 @@
|
|
|
9
9
|
},
|
|
10
10
|
"peerDependencies": {
|
|
11
11
|
"@angular/animations": "^14.1.3",
|
|
12
|
-
"@angular/cdk": "^14.1.
|
|
12
|
+
"@angular/cdk": "^14.1.3",
|
|
13
13
|
"@angular/common": "^14.1.3",
|
|
14
14
|
"@angular/core": "^14.1.3",
|
|
15
15
|
"@angular/flex-layout": "^14.0.0-beta.40",
|
|
16
16
|
"@angular/forms": "^14.1.3",
|
|
17
|
-
"@angular/material": "^14.1.
|
|
17
|
+
"@angular/material": "^14.1.3",
|
|
18
18
|
"@angular/platform-browser": "14.1.3",
|
|
19
19
|
"rxjs": "7.5.6",
|
|
20
20
|
"@angular/platform-browser-dynamic": "14.1.3"
|
|
@@ -43,4 +43,4 @@
|
|
|
43
43
|
}
|
|
44
44
|
},
|
|
45
45
|
"sideEffects": false
|
|
46
|
-
}
|
|
46
|
+
}
|