feat: 프로젝트 초기 설정 완료 - Vite + React + TypeScript, TailwindCSS + ShadCN UI, Zustand, 기본 타입 및 컴포넌트 구현
This commit is contained in:
56
src/types/sheet.ts
Normal file
56
src/types/sheet.ts
Normal file
@@ -0,0 +1,56 @@
|
||||
// 시트 관련 타입 정의
|
||||
|
||||
export interface SheetData {
|
||||
id: string;
|
||||
name: string;
|
||||
data: any[][]; // Luckysheet 데이터 형식
|
||||
config?: LuckysheetConfig;
|
||||
}
|
||||
|
||||
export interface LuckysheetConfig {
|
||||
container: string;
|
||||
title: string;
|
||||
lang: "en" | "ko";
|
||||
data: any[];
|
||||
options?: {
|
||||
showtoolbar?: boolean;
|
||||
showinfobar?: boolean;
|
||||
showsheetbar?: boolean;
|
||||
showstatisticBar?: boolean;
|
||||
allowCopy?: boolean;
|
||||
allowEdit?: boolean;
|
||||
enableAddRow?: boolean;
|
||||
enableAddCol?: boolean;
|
||||
};
|
||||
}
|
||||
|
||||
export interface FileUploadResult {
|
||||
success: boolean;
|
||||
data?: SheetData[];
|
||||
error?: string;
|
||||
fileName?: string;
|
||||
fileSize?: number;
|
||||
}
|
||||
|
||||
export interface ExportOptions {
|
||||
format: "xlsx" | "csv" | "json";
|
||||
fileName: string;
|
||||
sheetIndex?: number;
|
||||
}
|
||||
|
||||
export interface CellPosition {
|
||||
row: number;
|
||||
col: number;
|
||||
}
|
||||
|
||||
export interface CellRange {
|
||||
startRow: number;
|
||||
startCol: number;
|
||||
endRow: number;
|
||||
endCol: number;
|
||||
}
|
||||
|
||||
export interface SelectedRange {
|
||||
range: CellRange;
|
||||
sheetId: string;
|
||||
}
|
||||
Reference in New Issue
Block a user