add : icons module

This commit is contained in:
morteza-mortezai
2025-12-16 09:53:20 +03:30
parent 6462354049
commit a3e7a39c88
11 changed files with 392 additions and 0 deletions
+25
View File
@@ -0,0 +1,25 @@
import { ApiProperty } from "@nestjs/swagger";
import { IsNotEmpty, IsOptional, IsString, IsUrl } from "class-validator";
export class CreateIconDto {
@IsNotEmpty()
@IsString()
@ApiProperty({ description: "Icon name", example: "home-icon" })
name: string;
@IsOptional()
@IsString()
@ApiProperty({ description: "Icon description", example: "Home icon", required: false })
description?: string;
@IsNotEmpty()
@IsUrl({ protocols: ["http", "https"], require_protocol: true })
@ApiProperty({ description: "Icon URL", example: "https://example.com/icons/home.svg" })
url: string;
@IsOptional()
@IsString()
@ApiProperty({ description: "Icon group ID", example: "group-123", required: false })
groupId?: string;
}