Created
May 11, 2018 19:45
-
-
Save ChrisMoney/8daf76b8c71e51670865a57919e744c8 to your computer and use it in GitHub Desktop.
Angular Edit Modal
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<div mat-dialog class="container"> | |
<div mat-dialog-title class="dialog-title"> | |
Edit - {{ documentContent.name }} | |
<span class="title-spacer"></span> | |
<button mat-icon-button mat-dialog-close> | |
<mat-icon>close</mat-icon> | |
</button> | |
</div> | |
<div mat-dialog-content fxLayout="column" fxLayoutAlign="space-between stretch"> | |
<mat-form-field> | |
<input matInput type="text" placeholder="Name" [(ngModel)]="documentContent.name" ng-maxlength="40"> | |
</mat-form-field> | |
<div ng-message="maxLength" style="color:red">File name cannot be longer than 40 characters including extension.</div> | |
</div> | |
<div mat-dialog-actions> | |
<button mat-raised-button color="primary" (click)="saveFileName(documentContent)">Save</button> | |
</div> | |
</div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment