pimatic-angular-material-frontend
Version:
Provides an AngularJS webinterface for Pimatic with material design.
20 lines (19 loc) • 750 B
HTML
<md-card ng-controller="SwitchController">
<div layout="row" class="device-header">
<div class="device-icon-wrapper">
<span class="device-icon">
<i class="mdi mdi-toggle-switch"></i>
</span>
</div>
<div class="device-titles" layout="column" flex>
<h1>{{device.name}}</h1>
<h2>{{device.template}}</h2>
</div>
<div class="device-header-values" layout="row" layout-align="end center">
<md-switch class="device-switch" ng-model="getAttribute('state').value"
ng-change="updateValue(getAttribute('state'))"
aria-label="Switch">
</md-switch>
</div>
</div>
</md-card>