import {DesktopHomeCommonFunctionListItem} from '@/generated/api';
import {MenuItem, HeaderProps} from '../layout.interface';

export interface DesktopHeaderProps extends HeaderProps {
  moduleName?: string;
  moduleId?: string;
}

export type DesktopActionType = 
  'init_functions' | 
  'drag_functions' |
  'delete_function' |
  'init_menus' | 
  'add_function' | 
  'toggle_selected'
; 


export interface DesktopAction {
  type: DesktopActionType;
  payload: {
    data: any;
  };
}

export interface DesktopState {
  functions: any[];
  selected: string[];
  menus: any[];
}

export interface SortableListProps {
  items: any[];
  edit: boolean;
  onAdd: () => void;
}

export interface SortableItemProps {
  dataSource: any;
  edit: boolean;
}

export interface SortableComponentProps {
  editDisable: boolean;
  onAdd: any;
}

export interface FeatureItemProps {
  edit: boolean;
}