25 lines
693 B
TypeScript
25 lines
693 B
TypeScript
import { Component, Input } from '@angular/core';
|
|
import { TypeValue } from '@redaction/red-ui-http';
|
|
|
|
@Component({
|
|
selector: 'redaction-annotation-icon',
|
|
templateUrl: './annotation-icon.component.html',
|
|
styleUrls: ['./annotation-icon.component.scss']
|
|
})
|
|
export class AnnotationIconComponent {
|
|
@Input() color: string;
|
|
@Input() type: 'square' | 'rhombus' | 'circle';
|
|
@Input() label: string;
|
|
@Input() dictType: TypeValue;
|
|
|
|
constructor() {}
|
|
|
|
public get isHint() {
|
|
return this.type === 'circle' || this.dictType?.type === 'hint';
|
|
}
|
|
|
|
public get isRequest() {
|
|
return this.type === 'rhombus' || this.dictType?.type === 'redaction';
|
|
}
|
|
}
|