
export interface BookBaseData {
  width?: number;
  height?: number;
}

export interface QuestionInfo {
  type?: number;
  x: number;
  y: number;
  w: number;
  h: number;
  no: string;
}

export interface LayoutItem {
  questionId: number;
  question: QuestionInfo;
  answerList?: any[]; // Added based on topic-item-module usage
}

export interface BookPageQuestion {
  id: number;
  type?: number;
  [key: string]: any;
}

export interface BookPageAreas {
  id: number;
  [key: string]: any;
}

export interface CurrBookPageData {
  url?: string;
  bookPageId?: number;
  layout: LayoutItem[];
  questions: BookPageQuestion[];
  areas: BookPageAreas[];
}

export interface CurrBookPageAllInfo {
  bookBaseData: BookBaseData;
  currBookPageData: CurrBookPageData;
}

export type QuestionType = number;

export interface QuestionsImages {
  // Add properties as needed based on usage in util.ts
  [key: string]: any;
}

export interface CropImageOptions {
  x: number;
  y: number;
  width: number;
  height: number;
}

export interface AddBookTopicForm {
  type?: 100 | 101 | 102;
  pageNumb?: number;
  bigTpicNumb?: number;
  subTopicNumb?: number;
}

export interface BookPageOtherAddInput {
  bookId: number;
  bookPageId: number;
  no: string;
  type: number;
}

export interface BookPageOtherUpdateInput {
  bookId: number;
  bookPageId: number;
  no: string;
  type: number;
  id: number;
}

export interface TopicInfo {
  question: QuestionInfo;
  answerList?: any[];
  questionId: number;
}

export interface AnswerInfo {
  x: number;
  y: number;
  w: number;
  h: number;
}

export interface ImageInfo {
  file: File;
  width: number;
  height: number;
  url?: string;
}
