view src/app/analysis-item/analysis-item.component.html @ 373:2df7b3722eb9

Remove unnecessary style template
author Lucas Thompson <dev@lucas.im>
date Wed, 31 May 2017 02:44:14 +0100
parents bc2680f0736b
children 35234006c3c3
line wrap: on
line source
<md-card>
  <md-card-header>
    <md-card-title>{{item.title}}</md-card-title>
    <md-card-subtitle>{{item.description}}</md-card-subtitle>
  </md-card-header>
  <md-card-content>
    <ng-template [ngIf]="isLoading()">
      <ugly-progress-bar
        [isDeterminate]="true"
        [progress]="item.progress"
      ></ugly-progress-bar>
    </ng-template>
    <div class="content">
      <ng-template [ngIf]="!isLoading()">
        <ng-template [ngIf]="isActive && isAudioItem()">
          <ugly-live-play-head
            [timeToPixel]="DOES_NOT_BELONG_HERE"
            [colour]="'#c33c54'"
          >
          </ugly-live-play-head>
        </ng-template>
        <ugly-waveform *ngIf="isAudioItem(); else notAudio"
          [timeline]="timeline"
          [trackIdPrefix]=" item.id"
          [width]="contentWidth"
          [audioBuffer]="item.audioData"
          [onSeek]="onSeek"
        ></ugly-waveform>

        <ng-template #notAudio>
          <div class="content"
            *ngIf="getFeatureShape() as shape; else showSpinner">
            <div [ngSwitch]="shape" class="content">
              <ugly-curve
                *ngSwitchCase="'vector'"
                [timeline]="timeline"
                [id]="item.id"
                [width]="contentWidth"
                [onSeek]="onSeek"
                [curve]="item.collected"
              ></ugly-curve>
              <ugly-tracks
                *ngSwitchCase="'tracks'"
                [timeline]="timeline"
                [trackIdPrefix]="item.id"
                [width]="contentWidth"
                [onSeek]="onSeek"
                [tracks]="item.collected"
              ></ugly-tracks>

              <div *ngSwitchDefault>Feature cannot be visualised.</div>
            </div>
          </div>
          <ng-template #showSpinner>
            <ugly-progress-spinner></ugly-progress-spinner>
          </ng-template>
        </ng-template>

      </ng-template>
    </div>
  </md-card-content>
</md-card>