export interface MACDResult {
  time: string;
  dif: number;
  dea: number;
  macd: number;
}

export interface RSIResult {
  time: string;
  value: number;
  status: 'overbought' | 'oversold' | 'normal';
}

export interface BollingerResult {
  time: string;
  upper: number;
  middle: number;
  lower: number;
  position: 'upper' | 'middle' | 'lower';
}

export interface KDJResult {
  time: string;
  k: number;
  d: number;
  j: number;
  signal: 'golden_cross' | 'dead_cross' | 'neutral';
}

export interface SARResult {
  time: string;
  value: number;
  isLong: boolean;
}

export interface OBVResult {
  time: string;
  value: number;
}

export interface DMIResult {
  time: string;
  plusDI: number;
  minusDI: number;
  adx: number;
}

export interface CCIResult {
  time: string;
  value: number;
}

export interface WRResult {
  time: string;
  value: number;
}

export interface MAResult {
  time: string;
  value: number;
}

export interface IndicatorResults {
  macd: MACDResult[];
  rsi: RSIResult[];
  bollinger: BollingerResult[];
  kdj: KDJResult[];
  sar: SARResult[];
  obv: OBVResult[];
  dmi: DMIResult[];
  cci: CCIResult[];
  wr: WRResult[];
  ma5: MAResult[];
  ma10: MAResult[];
  ma20: MAResult[];
  ma60: MAResult[];
}

export type IndicatorType =
  | 'macd'
  | 'rsi'
  | 'bollinger'
  | 'kdj'
  | 'sar'
  | 'obv'
  | 'dmi'
  | 'cci'
  | 'wr'
  | 'ma5'
  | 'ma10'
  | 'ma20'
  | 'ma60';
