|
1 | 1 | <div class="demo-button">
|
2 |
| - <section> |
3 |
| - <button mat-button>flat</button> |
4 |
| - <button mat-raised-button>raised</button> |
5 |
| - <button mat-fab> |
6 |
| - <mat-icon>check</mat-icon> |
7 |
| - </button> |
8 |
| - <button mat-fab>Btn</button> |
9 |
| - <a mat-fab routerLink=".">Link</a> |
10 |
| - <a mat-fab routerLink="."><mat-icon>check</mat-icon></a> |
11 |
| - <button mat-mini-fab> |
12 |
| - <mat-icon>check</mat-icon> |
13 |
| - </button> |
14 |
| - <button mat-mini-fab>Btn</button> |
15 |
| - <a mat-mini-fab routerLink=".">Link</a> |
16 |
| - </section> |
17 |
| - |
18 |
| - <section> |
19 |
| - <a href="http://www.google.com" mat-button color="primary">SEARCH</a> |
20 |
| - <a href="http://www.google.com" mat-raised-button>SEARCH</a> |
21 |
| - <a href="http://www.google.com" mat-fab> |
22 |
| - <mat-icon>check</mat-icon> |
23 |
| - </a> |
24 |
| - <a href="http://www.google.com" mat-mini-fab> |
25 |
| - <mat-icon>check</mat-icon> |
26 |
| - </a> |
27 |
| - </section> |
28 |
| - |
29 |
| - <section> |
| 2 | + <section class="outlined"> |
| 3 | + <label>Flat</label> |
| 4 | + <button mat-button>default</button> |
30 | 5 | <button mat-button color="primary">primary</button>
|
31 | 6 | <button mat-button color="accent">accent</button>
|
32 | 7 | <button mat-button color="warn">warn</button>
|
33 | 8 | </section>
|
34 | 9 |
|
35 |
| - <section> |
| 10 | + <section class="outlined"> |
| 11 | + <label>Raised</label> |
| 12 | + <button mat-raised-button>default</button> |
36 | 13 | <button mat-raised-button color="primary">primary</button>
|
37 | 14 | <button mat-raised-button color="accent">accent</button>
|
38 | 15 | <button mat-raised-button color="warn">warn</button>
|
39 | 16 | </section>
|
40 | 17 |
|
41 |
| - <section> |
42 |
| - <button mat-fab color="primary"> |
43 |
| - <mat-icon>home</mat-icon> |
44 |
| - </button> |
45 |
| - <button mat-fab color="accent"> |
46 |
| - <mat-icon>favorite</mat-icon> |
47 |
| - </button> |
48 |
| - <button mat-fab color="warn"> |
49 |
| - <mat-icon>feedback</mat-icon> |
50 |
| - </button> |
| 18 | + <section class="outlined"> |
| 19 | + <label>Icon</label> |
| 20 | + <button mat-icon-button><mat-icon>home</mat-icon></button> |
| 21 | + <button mat-icon-button color="primary"><mat-icon>home</mat-icon></button> |
| 22 | + <button mat-icon-button color="accent"><mat-icon>favorite</mat-icon></button> |
| 23 | + <button mat-icon-button color="warn"><mat-icon>feedback</mat-icon></button> |
51 | 24 | </section>
|
52 | 25 |
|
53 |
| - <section> |
54 |
| - <button mat-icon-button color="primary"> |
55 |
| - <mat-icon>menu</mat-icon> |
56 |
| - </button> |
| 26 | + <section class="outlined"> |
| 27 | + <label>FABs</label> |
| 28 | + <section> |
| 29 | + <mat-slide-toggle [(ngModel)]="extendOnHover">Extend On Hover</mat-slide-toggle> |
| 30 | + <mat-slide-toggle [(ngModel)]="extendOnFocus">Extend On Focus</mat-slide-toggle> |
| 31 | + <mat-slide-toggle [(ngModel)]="hasLabel">Has Label</mat-slide-toggle> |
| 32 | + <mat-form-field [style.display]="hasLabel ? 'inline-block' : 'none'" floatPlaceholder="never"> |
| 33 | + <input matInput type="text" [(ngModel)]="labelText"> |
| 34 | + </mat-form-field> |
| 35 | + </section> |
| 36 | + <section> |
| 37 | + <button mat-fab color="primary" |
| 38 | + [extendOnHover]="extendOnHover" [extendOnFocus]="extendOnFocus"> |
| 39 | + <mat-icon>check</mat-icon> |
| 40 | + <ng-template #label *ngIf="hasLabel">{{labelText}}</ng-template> |
| 41 | + </button> |
| 42 | + <button mat-fab color="accent" |
| 43 | + [extendOnHover]="extendOnHover" [extendOnFocus]="extendOnFocus"> |
| 44 | + <mat-icon>check</mat-icon> |
| 45 | + <ng-template #label *ngIf="hasLabel">{{labelText}}</ng-template> |
| 46 | + </button> |
| 47 | + <button mat-fab color="warn" |
| 48 | + [extendOnHover]="extendOnHover" [extendOnFocus]="extendOnFocus"> |
| 49 | + <mat-icon>check</mat-icon> |
| 50 | + <ng-template #label *ngIf="hasLabel">{{labelText}}</ng-template> |
| 51 | + </button> |
| 52 | + <button mat-mini-fab color="primary" |
| 53 | + [extendOnHover]="extendOnHover" [extendOnFocus]="extendOnFocus"> |
| 54 | + <mat-icon>check</mat-icon> |
| 55 | + <ng-template #label *ngIf="hasLabel">{{labelText}}</ng-template> |
| 56 | + </button> |
| 57 | + <button mat-mini-fab color="accent" |
| 58 | + [extendOnHover]="extendOnHover" [extendOnFocus]="extendOnFocus"> |
| 59 | + <mat-icon>check</mat-icon> |
| 60 | + <ng-template #label *ngIf="hasLabel">{{labelText}}</ng-template> |
| 61 | + </button> |
| 62 | + <button mat-mini-fab color="warn" |
| 63 | + [extendOnHover]="extendOnHover" [extendOnFocus]="extendOnFocus"> |
| 64 | + <mat-icon>check</mat-icon> |
| 65 | + <ng-template #label *ngIf="hasLabel">{{labelText}}</ng-template> |
| 66 | + </button> |
| 67 | + </section> |
| 68 | + </section> |
57 | 69 |
|
58 |
| - <button mat-icon-button color="accent"> |
59 |
| - <mat-icon>favorite</mat-icon> |
60 |
| - </button> |
61 | 70 |
|
62 |
| - <button mat-icon-button> |
63 |
| - <mat-icon>more_vert</mat-icon> |
64 |
| - </button> |
| 71 | + <section class="outlined"> |
| 72 | + <label>Anchors</label> |
| 73 | + <a href="http://www.google.com" mat-button color="primary">SEARCH</a> |
| 74 | + <a href="http://www.google.com" mat-raised-button>SEARCH</a> |
| 75 | + <a href="http://www.google.com" mat-fab><mat-icon>check</mat-icon></a> |
| 76 | + <a href="http://www.google.com" mat-mini-fab><mat-icon>check</mat-icon></a> |
| 77 | + <a href="http://www.google.com" mat-icon-button><mat-icon>check</mat-icon></a> |
65 | 78 | </section>
|
66 | 79 |
|
67 |
| - <section> |
68 |
| - <div> |
69 |
| - <p>isDisabled: {{isDisabled}}, clickCounter: <span>{{clickCounter}}</span></p> |
70 |
| - <button mat-raised-button (click)="isDisabled=!isDisabled"> |
71 |
| - Disable buttons |
72 |
| - </button> |
| 80 | + <section class="outlined"> |
| 81 | + <label>Disable and Focus</label> |
| 82 | + <section> |
| 83 | + <button mat-raised-button (click)="isDisabled=!isDisabled">Disable all</button> |
73 | 84 | <button mat-raised-button (click)="button1.focus()">Focus 1</button>
|
74 | 85 | <button mat-raised-button (click)="button2.focus()">Focus 2</button>
|
75 | 86 | <button mat-raised-button (click)="button3.focus()">Focus 3</button>
|
76 | 87 | <button mat-raised-button (click)="button4.focus()">Focus 4</button>
|
77 |
| - </div> |
78 |
| - <button mat-button #button1 [disabled]="isDisabled" (click)="clickCounter=clickCounter+1">off</button> |
79 |
| - <button mat-button #button2 color="primary" [disabled]="isDisabled">off</button> |
80 |
| - <a href="http://www.google.com" #button3 mat-button color="accent" [disabled]="isDisabled">off</a> |
81 |
| - <button mat-raised-button #button4 color="primary" [disabled]="isDisabled">off</button> |
82 |
| - <button mat-mini-fab [disabled]="isDisabled"> |
83 |
| - <mat-icon>check</mat-icon> |
84 |
| - </button> |
85 |
| - |
86 |
| - <button mat-icon-button color="accent" [disabled]="isDisabled"> |
87 |
| - <mat-icon>favorite</mat-icon> |
88 |
| - </button> |
89 |
| - </section> |
90 |
| - <section> |
91 |
| - <a href="http://www.google.com" mat-button color="primary">SEARCH</a> |
92 |
| - <button mat-button>DANCE</button> |
93 |
| - </section> |
94 |
| - <section> |
95 |
| - <a href="http://www.google.com" mat-raised-button color="primary">SEARCH</a> |
96 |
| - <button mat-raised-button>DANCE</button> |
97 |
| - </section> |
98 |
| - <section> |
99 |
| - <button mat-raised-button>More<mat-icon>more_vert</mat-icon></button> |
100 |
| - <button mat-raised-button>Check<mat-icon>check</mat-icon></button> |
101 |
| - <button mat-raised-button>Check<mat-icon>favorite</mat-icon></button> |
102 |
| - <button mat-raised-button>Last<mat-icon>navigate_before</mat-icon></button> |
103 |
| - </section> |
104 |
| - <section> |
105 |
| - <button mat-button>More<mat-icon>more_vert</mat-icon></button> |
106 |
| - <button mat-button>Check<mat-icon>check</mat-icon></button> |
107 |
| - <button mat-button>Check<mat-icon>favorite</mat-icon></button> |
108 |
| - <button mat-button>Last<mat-icon>navigate_before</mat-icon></button> |
109 |
| - </section> |
110 |
| - <section> |
111 |
| - <button mat-raised-button [disabled]="toggleDisable" (click)="toggleDisable = true">Disable</button> |
112 |
| - <button mat-button [disabled]="!toggleDisable" (click)="toggleDisable = false">Disable</button> |
| 88 | + <button mat-raised-button (click)="button5.focus()">Focus 5</button> |
| 89 | + </section> |
| 90 | + <section> |
| 91 | + <button #button1 mat-button color="primary" [disabled]="isDisabled">1</button> |
| 92 | + <button #button2 mat-raised-button color="accent" [disabled]="isDisabled">2</button> |
| 93 | + <button #button3 mat-fab color="warn" [disabled]="isDisabled">3</button> |
| 94 | + <button #button4 mat-mini-fab color="primary" [disabled]="isDisabled">4</button> |
| 95 | + <button #button5 mat-icon-button color="accent" [disabled]="isDisabled">5</button> |
| 96 | + </section> |
113 | 97 | </section>
|
114 | 98 | </div>
|
0 commit comments