Rewrite frontend as single self-contained HTML file — all CSS/JS inline, no external files to fail loading
This commit is contained in:
76
dist/server/public/app.d.ts
vendored
Normal file
76
dist/server/public/app.d.ts
vendored
Normal file
@@ -0,0 +1,76 @@
|
||||
interface Job {
|
||||
id: string;
|
||||
video_path: string;
|
||||
video_filename: string;
|
||||
status: 'pending' | 'queued' | 'processing' | 'paused' | 'completed' | 'failed' | 'cancelled';
|
||||
config: string;
|
||||
progress: number;
|
||||
current_index: number;
|
||||
total_units: number;
|
||||
segments: string;
|
||||
last_context: string;
|
||||
current_time_position: number;
|
||||
error: string | null;
|
||||
created_at: string;
|
||||
updated_at: string;
|
||||
completed_at: string | null;
|
||||
output_audio: string | null;
|
||||
output_subtitles_srt: string | null;
|
||||
output_subtitles_vtt: string | null;
|
||||
output_muxed: string | null;
|
||||
output_options: string;
|
||||
}
|
||||
interface AudioSegment {
|
||||
audioFile: string;
|
||||
startTime: number;
|
||||
duration: number;
|
||||
description: string;
|
||||
}
|
||||
interface ProgressData {
|
||||
id: string;
|
||||
status: string;
|
||||
progress: number;
|
||||
currentIndex: number;
|
||||
totalUnits: number;
|
||||
segments: AudioSegment[];
|
||||
error: string | null;
|
||||
output_audio: string | null;
|
||||
output_subtitles_srt: string | null;
|
||||
output_subtitles_vtt: string | null;
|
||||
output_muxed: string | null;
|
||||
}
|
||||
interface FileInfo {
|
||||
filename: string;
|
||||
filePath: string;
|
||||
size: number;
|
||||
}
|
||||
declare let authToken: string | null;
|
||||
declare let selectedFilePath: string | null;
|
||||
declare const sseMap: Map<string, EventSource>;
|
||||
declare let pollTimer: number | null;
|
||||
declare const $: (sel: string) => HTMLElement;
|
||||
declare const $$: (sel: string) => NodeListOf<HTMLElement>;
|
||||
declare const el: (id: string) => HTMLElement;
|
||||
declare function apiHeaders(): Record<string, string>;
|
||||
declare function api(method: string, url: string, body?: unknown): Promise<Response>;
|
||||
declare function apiJson<T>(method: string, url: string, body?: unknown): Promise<T>;
|
||||
declare function showLoginScreen(): void;
|
||||
declare function showMainScreen(): void;
|
||||
declare function switchTab(name: string): void;
|
||||
declare function escapeHtml(str: string | null | undefined): string;
|
||||
declare function formatSize(bytes: number): string;
|
||||
declare function loadBrowseFiles(): Promise<void>;
|
||||
declare const videoUpload: HTMLInputElement;
|
||||
declare const uploadName: HTMLElement;
|
||||
declare function loadJobs(): Promise<void>;
|
||||
declare function renderJobs(jobs: Job[]): void;
|
||||
declare function handleJobAction(id: string, action: string): Promise<void>;
|
||||
declare function startPolling(): void;
|
||||
declare function connectSSE(jobId: string): void;
|
||||
declare function updateJobCard(jobId: string, data: ProgressData): void;
|
||||
declare function loadSettings(): Promise<void>;
|
||||
declare let selectedFiles: Set<string>;
|
||||
declare function loadFilesList(): Promise<void>;
|
||||
declare function updateFileSelection(): void;
|
||||
declare function loadConfigDefaults(): Promise<void>;
|
||||
declare function initApp(): void;
|
||||
Reference in New Issue
Block a user