initial commit
This commit is contained in:
47
types.ts
Normal file
47
types.ts
Normal file
@@ -0,0 +1,47 @@
|
||||
|
||||
export enum FileType {
|
||||
FILE = 'FILE',
|
||||
FOLDER = 'FOLDER'
|
||||
}
|
||||
|
||||
export interface FileItem {
|
||||
id: string;
|
||||
name: string;
|
||||
type: FileType;
|
||||
size: number; // in bytes
|
||||
date: string;
|
||||
permissions: string;
|
||||
}
|
||||
|
||||
export interface LogEntry {
|
||||
id: string;
|
||||
timestamp: string;
|
||||
type: 'info' | 'success' | 'error' | 'command' | 'response';
|
||||
message: string;
|
||||
}
|
||||
|
||||
export interface TransferItem {
|
||||
id: string;
|
||||
direction: 'upload' | 'download';
|
||||
filename: string;
|
||||
progress: number; // 0 to 100
|
||||
status: 'queued' | 'transferring' | 'completed' | 'failed';
|
||||
speed: string;
|
||||
}
|
||||
|
||||
export interface FileSystemState {
|
||||
path: string;
|
||||
files: FileItem[];
|
||||
isLoading: boolean;
|
||||
}
|
||||
|
||||
export interface SiteConfig {
|
||||
id: string;
|
||||
name: string;
|
||||
protocol: 'ftp' | 'sftp';
|
||||
host: string;
|
||||
port: string;
|
||||
user: string;
|
||||
pass?: string; // Optional for security
|
||||
passiveMode?: boolean;
|
||||
}
|
||||
Reference in New Issue
Block a user