import { IsString, IsOptional, IsEnum, IsObject } from 'class-validator';
import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger';

export class UpdateWebsiteInfoDto {
  @ApiPropertyOptional({ description: '网站名称' })
  @IsOptional()
  @IsString()
  siteName?: string;

  @ApiPropertyOptional({ description: '网站标题' })
  @IsOptional()
  @IsString()
  siteTitle?: string;

  @ApiPropertyOptional({ description: '网站描述' })
  @IsOptional()
  @IsString()
  siteDescription?: string;

  @ApiPropertyOptional({ description: 'SEO关键词' })
  @IsOptional()
  @IsString()
  siteKeywords?: string;

  @ApiPropertyOptional({ description: 'Logo URL' })
  @IsOptional()
  @IsString()
  logo?: string;

  @ApiPropertyOptional({ description: '网站图标' })
  @IsOptional()
  @IsString()
  favicon?: string;

  @ApiPropertyOptional({ description: '联系电话' })
  @IsOptional()
  @IsString()
  contactPhone?: string;

  @ApiPropertyOptional({ description: '联系邮箱' })
  @IsOptional()
  @IsString()
  contactEmail?: string;

  @ApiPropertyOptional({ description: '联系地址' })
  @IsOptional()
  @IsString()
  contactAddress?: string;

  @ApiPropertyOptional({ description: 'ICP备案号' })
  @IsOptional()
  @IsString()
  icp?: string;

  @ApiPropertyOptional({ description: '版权信息' })
  @IsOptional()
  @IsString()
  copyright?: string;

  @ApiPropertyOptional({ description: '关于我们' })
  @IsOptional()
  @IsString()
  aboutUs?: string;

  @ApiPropertyOptional({ description: '服务协议' })
  @IsOptional()
  @IsString()
  serviceAgreement?: string;

  @ApiPropertyOptional({ description: '隐私政策' })
  @IsOptional()
  @IsString()
  privacyPolicy?: string;

  @ApiPropertyOptional({ description: '社交媒体链接' })
  @IsOptional()
  @IsObject()
  socialLinks?: Record<string, string>;

  @ApiPropertyOptional({ description: '状态', enum: ['active', 'inactive'] })
  @IsOptional()
  @IsEnum(['active', 'inactive'])
  status?: 'active' | 'inactive';
}
