import { ChangeDetectionStrategy, Component, input } from '@angular/core';

export type BadgeVariant = 'neutral' | 'primary' | 'success' | 'warning' | 'danger' | 'info';

@Component({
  selector: 'app-badge',
  standalone: true,
  templateUrl: './badge.component.html',
  styleUrl: './badge.component.scss',
  changeDetection: ChangeDetectionStrategy.OnPush,
  host: {
    '[class.app-badge--neutral]': "variant() === 'neutral'",
    '[class.app-badge--primary]': "variant() === 'primary'",
    '[class.app-badge--success]': "variant() === 'success'",
    '[class.app-badge--warning]': "variant() === 'warning'",
    '[class.app-badge--danger]': "variant() === 'danger'",
    '[class.app-badge--info]': "variant() === 'info'"
  }
})
export class BadgeComponent {
  readonly variant = input<BadgeVariant>('neutral');
}
