valor-software/ng2-bootstrap

View on GitHub
demo/src/app/components/+timepicker/demos/custom/custom.html

Summary

Maintainability
Test Coverage
<timepicker [(ngModel)]="mytime" [hourStep]="hstep" [minuteStep]="mstep" [showSeconds]="true" [secondsStep]="sstep"></timepicker>

<pre class="alert alert-info">Time is: {{mytime}}</pre>

<div class="row">
  <div class="col-xs-6 col-6 col-md-3">
    Hours step is:
    <select class="form-control" [(ngModel)]="hstep">
      <option *ngFor="let opt of options.hstep" [value]="opt">{{opt}}</option>
    </select>
  </div>
  <div class="col-xs-6 col-6 col-md-3">
    Minutes step is:
    <select class="form-control" [(ngModel)]="mstep">
      <option *ngFor="let opt of options.mstep" [value]="opt">{{opt}}</option>
    </select>
  </div>
  <div class="col-xs-6 col-6 col-md-3">
    Seconds step is:
    <select class="form-control" [(ngModel)]="sstep">
      <option *ngFor="let opt of options.sstep" [value]="opt">{{opt}}</option>
    </select>
  </div>
</div>