|
2 | 2 | <mat-card>
|
3 | 3 | <h1>Contact us</h1>
|
4 | 4 | <form class="form" (ngSubmit)="onSubmit(c)" #c="ngForm" >
|
5 |
| - <mat-input-container class="full-width"> |
| 5 | + <mat-form-field class="full-width"> |
6 | 6 | <input matInput placeholder="Company" id="company" name="company" value="Google" ngModel required>
|
7 |
| - </mat-input-container> |
| 7 | + </mat-form-field> |
8 | 8 |
|
9 | 9 | <table class="full-width" cellspacing="0"><tr>
|
10 |
| - <td><mat-input-container class="full-width"> |
| 10 | + <td><mat-form-field class="full-width"> |
11 | 11 | <input matInput placeholder="First name" id="firstname" name="firstname" ngModel required>
|
12 |
| - </mat-input-container></td> |
13 |
| - <td><mat-input-container class="full-width"> |
| 12 | + </mat-form-field></td> |
| 13 | + <td><mat-form-field class="full-width"> |
14 | 14 | <input matInput placeholder="Last name" id="lastname" name="lastname" ngModel required>
|
15 |
| - </mat-input-container></td> |
| 15 | + </mat-form-field></td> |
16 | 16 | </tr></table>
|
17 | 17 |
|
18 | 18 | <p>
|
19 |
| - <mat-input-container class="full-width"> |
| 19 | + <mat-form-field class="full-width"> |
20 | 20 | <textarea matInput placeholder="Address" value="Streetname 12a" id="address" name="address" ngModel required></textarea>
|
21 |
| - </mat-input-container> |
| 21 | + </mat-form-field> |
22 | 22 | </p>
|
23 | 23 |
|
24 | 24 | <table class="full-width" cellspacing="0"><tr>
|
25 |
| - <td><mat-input-container class="full-width"> |
| 25 | + <td><mat-form-field class="full-width"> |
26 | 26 | <input matInput placeholder="City" id="city" name="city" ngModel required>
|
27 |
| - </mat-input-container></td> |
28 |
| - <td><mat-input-container class="full-width"> |
| 27 | + </mat-form-field></td> |
| 28 | + <td><mat-form-field class="full-width"> |
29 | 29 | <input matInput #postalCode maxlength="6" id="postal" name="postal" placeholder="Zip Code" value="2900TY" ngModel required>
|
30 | 30 | <mat-hint align="end">{{postalCode.value.length}} / 6</mat-hint>
|
31 |
| - </mat-input-container></td> |
| 31 | + </mat-form-field></td> |
32 | 32 | </tr></table>
|
33 | 33 | <p>
|
34 |
| - <mat-input-container class="full-width"> |
| 34 | + <mat-form-field class="full-width"> |
35 | 35 | <textarea matInput placeholder="Your message" id="message" name="message" ngModel required></textarea>
|
36 |
| - </mat-input-container> |
| 36 | + </mat-form-field> |
37 | 37 | </p>
|
38 | 38 | <br />
|
39 | 39 | <button mat-raised-button type="submit" [disabled]="c.invalid">Submit</button>
|
|
0 commit comments