refacto: types big review

This commit is contained in:
Julien Froidefond
2025-02-27 08:29:08 +01:00
parent 3b2d4cb0d5
commit 3c46afb294
39 changed files with 209 additions and 178 deletions

View File

@@ -1,3 +1,34 @@
// Types liés à la configuration
export interface User {
id: string;
email: string;
}
export interface KomgaConfigData {
url: string;
username: string;
password?: string | null;
authHeader: string;
}
export interface KomgaConfig extends KomgaConfigData {
userId: string;
}
export interface TTLConfigData {
defaultTTL: number;
homeTTL: number;
librariesTTL: number;
seriesTTL: number;
booksTTL: number;
imagesTTL: number;
}
export interface TTLConfig extends TTLConfigData {
userId: string;
}
// Types liés à l'API Komga
export interface KomgaUser {
id: string;
email: string;
@@ -107,3 +138,8 @@ export interface BookMetadata {
releaseDate: string;
isbn: string;
}
export interface KomgaBookWithPages {
book: KomgaBook;
pages: number[];
}