import { ApiProperty } from '@nestjs/swagger';
import { IsInt, IsNotEmpty, IsOptional, IsString, Min } from 'class-validator';

export class ProtestIncidentDTO {
  @ApiProperty()
  @IsInt()
  @Min(0)
  lap!: number;

  @ApiProperty()
  @IsString()
  @IsNotEmpty()
  description!: string;

  @ApiProperty({ required: false, description: 'Seconds from race start' })
  @IsOptional()
  @IsInt()
  @Min(0)
  timeInRace?: number;
}

