- Add `useEffect` in `ScribeLeftBar` for handling book state changes. - Extend `BooksSyncContext` with new properties and stricter typings. - Refine `Repositories` to include `lastUpdate` handling for synchronization processes. - Add comprehensive `fetchComplete*` repository methods for retrieving entity-specific sync data. - Enhance offline logic for chapters, characters, locations, and world synchronization. - Improve error handling across IPC handlers and repositories.
197 lines
4.4 KiB
TypeScript
197 lines
4.4 KiB
TypeScript
export interface EritBooksTable {
|
|
book_id:string;
|
|
type:string;
|
|
author_id:string;
|
|
title:string;
|
|
hashed_title:string;
|
|
sub_title:string|null;
|
|
hashed_sub_title:string|null;
|
|
summary:string|null;
|
|
serie_id:number|null;
|
|
desired_release_date:string|null;
|
|
desired_word_count:number|null;
|
|
words_count:number|null;
|
|
cover_image:string|null;
|
|
last_update:number;
|
|
}
|
|
|
|
export interface BookActSummariesTable {
|
|
act_sum_id: string;
|
|
book_id: string;
|
|
user_id: string;
|
|
act_index: number;
|
|
summary: string | null;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface BookAIGuideLineTable {
|
|
user_id: string;
|
|
book_id: string;
|
|
global_resume: string | null;
|
|
themes: string | null;
|
|
verbe_tense: number | null;
|
|
narrative_type: number | null;
|
|
langue: number | null;
|
|
dialogue_type: number | null;
|
|
tone: string | null;
|
|
atmosphere: string | null;
|
|
current_resume: string | null;
|
|
}
|
|
|
|
export interface BookChaptersTable {
|
|
chapter_id: string;
|
|
book_id: string;
|
|
author_id: string;
|
|
title: string;
|
|
hashed_title: string;
|
|
words_count: number | null;
|
|
chapter_order: number;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface BookChapterContentTable {
|
|
content_id: string;
|
|
chapter_id: string;
|
|
author_id: string;
|
|
version: number;
|
|
content: string | null;
|
|
words_count: number;
|
|
time_on_it: number;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface BookChapterInfosTable {
|
|
chapter_info_id: string;
|
|
chapter_id: string;
|
|
act_id: number;
|
|
incident_id: string | null;
|
|
plot_point_id: string | null;
|
|
book_id: string;
|
|
author_id: string;
|
|
summary: string | null;
|
|
goal: string | null;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface BookCharactersTable {
|
|
character_id: string;
|
|
book_id: string;
|
|
user_id: string;
|
|
first_name: string;
|
|
last_name: string | null;
|
|
category: string;
|
|
title: string | null;
|
|
image: string | null;
|
|
role: string | null;
|
|
biography: string | null;
|
|
history: string | null;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface BookCharactersAttributesTable {
|
|
attr_id: string;
|
|
character_id: string;
|
|
user_id: string;
|
|
attribute_name: string;
|
|
attribute_value: string;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface BookGuideLineTable {
|
|
user_id: string;
|
|
book_id: string;
|
|
tone: string | null;
|
|
atmosphere: string | null;
|
|
writing_style: string | null;
|
|
themes: string | null;
|
|
symbolism: string | null;
|
|
motifs: string | null;
|
|
narrative_voice: string | null;
|
|
pacing: string | null;
|
|
intended_audience: string | null;
|
|
key_messages: string | null;
|
|
}
|
|
|
|
export interface BookIncidentsTable {
|
|
incident_id: string;
|
|
author_id: string;
|
|
book_id: string;
|
|
title: string;
|
|
hashed_title: string;
|
|
summary: string | null;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface BookIssuesTable {
|
|
issue_id: string;
|
|
author_id: string;
|
|
book_id: string;
|
|
name: string;
|
|
hashed_issue_name: string;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface BookLocationTable {
|
|
loc_id: string;
|
|
book_id: string;
|
|
user_id: string;
|
|
loc_name: string;
|
|
loc_original_name: string;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface BookPlotPointsTable {
|
|
plot_point_id: string;
|
|
title: string;
|
|
hashed_title: string;
|
|
summary: string | null;
|
|
linked_incident_id: string | null;
|
|
author_id: string;
|
|
book_id: string;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface BookWorldTable {
|
|
world_id: string;
|
|
name: string;
|
|
hashed_name: string;
|
|
author_id: string;
|
|
book_id: string;
|
|
history: string | null;
|
|
politics: string | null;
|
|
economy: string | null;
|
|
religion: string | null;
|
|
languages: string | null;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface BookWorldElementsTable {
|
|
element_id: string;
|
|
world_id: string;
|
|
user_id: string;
|
|
element_type: number;
|
|
name: string;
|
|
original_name: string;
|
|
description: string | null;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface LocationElementTable {
|
|
element_id: string;
|
|
location: string;
|
|
user_id: string;
|
|
element_name: string;
|
|
original_name: string;
|
|
element_description: string | null;
|
|
last_update: number;
|
|
}
|
|
|
|
export interface LocationSubElementTable {
|
|
sub_element_id: string;
|
|
element_id: string;
|
|
user_id: string;
|
|
sub_elem_name: string;
|
|
original_name: string;
|
|
sub_elem_description: string | null;
|
|
last_update: number;
|
|
} |