annotate src/app/visualisations/curve/curve.component.ts @ 376:35234006c3c3

Use module scoped id generator instead of passing in an id to components.
author Lucas Thompson <dev@lucas.im>
date Wed, 31 May 2017 12:55:03 +0100
parents 2df7b3722eb9
children 9fe6e00e0700
rev   line source
dev@359 1 /**
dev@359 2 * Created by lucas on 30/05/2017.
dev@359 3 */
dev@366 4 import {
dev@366 5 ChangeDetectionStrategy,
dev@366 6 Component,
dev@372 7 Input
dev@366 8 } from "@angular/core";
dev@372 9 import {OnSeekHandler} from "../../playhead/PlayHeadHelpers";
dev@366 10 import {VectorFeature} from "piper/HigherLevelUtilities";
dev@359 11
dev@359 12 @Component({
dev@359 13 selector: 'ugly-curve',
dev@372 14 template: `<ugly-tracks
dev@372 15 [timeline]="timeline"
dev@372 16 [width]="width"
dev@372 17 [onSeek]="onSeek"
dev@372 18 [colour]="colour"
dev@372 19 [tracks]="[curve]"
dev@372 20 ></ugly-tracks>`,
dev@359 21 changeDetection: ChangeDetectionStrategy.OnPush
dev@359 22 })
dev@372 23 export class CurveComponent {
dev@376 24 @Input() timeline: Timeline; // TODO refactor WaveComponents to have own Timeline, sharing a TimeContext
dev@372 25 @Input() onSeek: OnSeekHandler;
dev@372 26 @Input() width: number;
dev@372 27 @Input() curve: VectorFeature;
dev@368 28 @Input() colour: string;
dev@359 29 }