refactor: apply consistent formatting to improve code quality
Ensure uniform code formatting across components by aligning with the established code style. Adjust imports, indentation, and spacing to enhance readability and maintainability.
This commit is contained in:
@@ -1,15 +1,22 @@
|
||||
export interface LoginResponse {
|
||||
message: string;
|
||||
userId: string;
|
||||
message: string;
|
||||
userId: string;
|
||||
}
|
||||
|
||||
export interface RegisterPayload {
|
||||
username: string;
|
||||
email: string;
|
||||
password: string;
|
||||
displayName?: string;
|
||||
}
|
||||
|
||||
export interface AuthStatus {
|
||||
isAuthenticated: boolean;
|
||||
user: null | {
|
||||
id: string;
|
||||
username: string;
|
||||
displayName?: string;
|
||||
avatarUrl?: string;
|
||||
};
|
||||
isLoading: boolean;
|
||||
isAuthenticated: boolean;
|
||||
user: null | {
|
||||
id: string;
|
||||
username: string;
|
||||
displayName?: string;
|
||||
avatarUrl?: string;
|
||||
};
|
||||
isLoading: boolean;
|
||||
}
|
||||
|
||||
@@ -1,46 +1,45 @@
|
||||
import type { User } from "./user";
|
||||
|
||||
export interface Content {
|
||||
id: string;
|
||||
title: string;
|
||||
slug: string;
|
||||
description?: string;
|
||||
url: string;
|
||||
thumbnailUrl?: string;
|
||||
type: "image" | "video";
|
||||
mimeType: string;
|
||||
size: number;
|
||||
width?: number;
|
||||
height?: number;
|
||||
duration?: number;
|
||||
views: number;
|
||||
usageCount: number;
|
||||
favoritesCount: number;
|
||||
tags: (string | Tag)[];
|
||||
category?: Category;
|
||||
authorId: string;
|
||||
author: User;
|
||||
createdAt: string;
|
||||
updatedAt: string;
|
||||
id: string;
|
||||
title: string;
|
||||
slug: string;
|
||||
description?: string;
|
||||
url: string;
|
||||
thumbnailUrl?: string;
|
||||
type: "image" | "video";
|
||||
mimeType: string;
|
||||
size: number;
|
||||
width?: number;
|
||||
height?: number;
|
||||
duration?: number;
|
||||
views: number;
|
||||
usageCount: number;
|
||||
favoritesCount: number;
|
||||
tags: (string | Tag)[];
|
||||
category?: Category;
|
||||
authorId: string;
|
||||
author: User;
|
||||
createdAt: string;
|
||||
updatedAt: string;
|
||||
}
|
||||
|
||||
export interface Tag {
|
||||
id: string;
|
||||
name: string;
|
||||
slug: string;
|
||||
id: string;
|
||||
name: string;
|
||||
slug: string;
|
||||
}
|
||||
|
||||
export interface Category {
|
||||
id: string;
|
||||
name: string;
|
||||
slug: string;
|
||||
description?: string;
|
||||
id: string;
|
||||
name: string;
|
||||
slug: string;
|
||||
description?: string;
|
||||
}
|
||||
|
||||
|
||||
export interface PaginatedResponse<T> {
|
||||
data: T[];
|
||||
total: number;
|
||||
limit: number;
|
||||
offset: number;
|
||||
data: T[];
|
||||
total: number;
|
||||
limit: number;
|
||||
offset: number;
|
||||
}
|
||||
|
||||
@@ -1,15 +1,15 @@
|
||||
export interface User {
|
||||
id: string;
|
||||
username: string;
|
||||
email: string;
|
||||
displayName?: string;
|
||||
avatarUrl?: string;
|
||||
role: "user" | "admin";
|
||||
createdAt: string;
|
||||
id: string;
|
||||
username: string;
|
||||
email: string;
|
||||
displayName?: string;
|
||||
avatarUrl?: string;
|
||||
role: "user" | "admin";
|
||||
createdAt: string;
|
||||
}
|
||||
|
||||
export interface UserProfile extends User {
|
||||
bio?: string;
|
||||
favoritesCount: number;
|
||||
uploadsCount: number;
|
||||
bio?: string;
|
||||
favoritesCount: number;
|
||||
uploadsCount: number;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user