import { ApiPropertyOptional } from '@nestjs/swagger';
import { IsIn, IsOptional } from 'class-validator';

const CHART_RANGES = ['7d', '30d', '90d'] as const;

export class SuperAdminChartsQueryDto {
  @ApiPropertyOptional({ enum: CHART_RANGES, default: '30d' })
  @IsOptional()
  @IsIn(CHART_RANGES)
  range?: (typeof CHART_RANGES)[number];
}
