import { ApiProperty, ApiPropertyOptional } from "@nestjs/swagger";
import { IsNotEmpty, IsOptional, IsString, MaxLength } from "class-validator";

export class CreateCosaTraeDto {
  @ApiProperty({ description: "Nombre del elemento" })
  @IsNotEmpty()
  @IsString()
  @MaxLength(150)
  nombre: string;

  @ApiPropertyOptional({ description: "Descripción" })
  @IsOptional()
  @IsString()
  descripcion?: string;
}
