Skip to content

Instantly share code, notes, and snippets.

@danielkuhlwein
Last active June 27, 2018 21:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save danielkuhlwein/4e57257050568089e9d130642817a213 to your computer and use it in GitHub Desktop.
Save danielkuhlwein/4e57257050568089e9d130642817a213 to your computer and use it in GitHub Desktop.
Dialog Example
<!-- -1 tabindex: doesn't autofocus this item when opening -->
<button mat-icon-button class="close-btn" tabindex="-1">
<mat-icon svgIcon="close" aria-label="close" (click)="close()"></mat-icon>
</button>
<mat-dialog-content>
<!-- 1. Insert your data here -->
<p>Your bulletin wasn't posted. Are you sure you want to exit?</p>
</mat-dialog-content>
<mat-dialog-actions>
<!-- 2. Insert your actions here -->
<button mat-raised-button class="prim-btn" tabindex="1" mat-dialog-close="leave">Leave Page</button>
<button mat-raised-button class="sec-btn" tabindex="2" mat-dialog-close="stay">Stay</button>
</mat-dialog-actions>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment