Skip to content

Commit 37f74eb

Browse files
committed
chore: add stepper demo
1 parent 188da70 commit 37f74eb

File tree

1 file changed

+31
-0
lines changed

1 file changed

+31
-0
lines changed

src/app/dashboard/dashboard.component.html

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -99,5 +99,36 @@
9999
</mat-card>
100100
</mat-grid-tile>
101101

102+
<!-- stepper -->
103+
104+
<mat-grid-tile colspan="3" rowspan="1">
105+
<mat-card class="dashboard-card">
106+
<mat-card-header>
107+
<mat-card-title>
108+
Stepper
109+
<button mat-icon-button class="more-button" [matMenuTriggerFor]="menuStepper" aria-label="Toggle menu">
110+
<mat-icon>more_vert</mat-icon>
111+
</button>
112+
<mat-menu #menuStepper="matMenu" xPosition="before">
113+
<button mat-menu-item *ngIf="(stepper.device | async) === null" (click)="stepper.requestValue()">
114+
<mat-icon>bluetooth_searching</mat-icon>
115+
Connect
116+
</button>
117+
<button mat-menu-item *ngIf="(stepper.device | async)" (click)="stepper.disconnect()">
118+
<mat-icon>bluetooth_disabled</mat-icon>
119+
Disconnect
120+
</button>
121+
</mat-menu>
122+
</mat-card-title>
123+
<mat-card-subtitle *ngIf="(stepper.device | async) as device">
124+
{{ device.name }}
125+
</mat-card-subtitle>
126+
</mat-card-header>
127+
<mat-card-content class="dashboard-card-content">
128+
<ble-stepcounter #stepper></ble-stepcounter>
129+
</mat-card-content>
130+
</mat-card>
131+
</mat-grid-tile>
132+
102133
</mat-grid-list>
103134
</div>

0 commit comments

Comments
 (0)