import { CSSProperties } from 'react';
export interface MultiLanguageText {
    en: string;
    'zh-CN': string;
    'zh-HK': string;
    'ja': string;
    'pt': string;
    original: string;
}
export interface BaseItem {
    id: number;
    name: string | MultiLanguageText;
    code: string;
    order?: number;
}
export interface SettingItem extends BaseItem {
    key?: string;
    scopes?: string[];
    groupId?: number;
    group_id?: number;
    fieldType?: string;
    type?: string;
    interfaceType?: string;
    interface?: string;
    description?: string | MultiLanguageText;
    systemDefaultValue?: string;
    default?: string;
    schema?: any;
    title?: string | MultiLanguageText;
    sort: number;
    created_at?: string | null;
    updated_at?: string | null;
    deleted_at?: string | null;
}
export interface SettingGroup extends BaseItem {
    items: SettingItem[];
    expanded?: boolean;
    sort: number;
    description?: MultiLanguageText;
    title?: MultiLanguageText;
}
export interface Section extends BaseItem {
    icon?: string;
    description?: string | MultiLanguageText;
    groups: SettingGroup[];
    created_at?: string | null;
    updated_at?: string | null;
    deleted_at?: string | null;
}
export interface TreeNode {
    key: string;
    type: 'group' | 'item';
    data: SettingGroup | SettingItem;
    children?: TreeNode[];
    parentKey?: string;
}
export declare type OperationType = 'add' | 'edit' | 'delete';
export interface DragItem {
    id: number;
    type: 'group' | 'item';
    groupId?: number;
}
export interface RegistryProps {
    className?: string;
    style?: CSSProperties;
    sections?: Section[];
    selectedSectionId?: number;
    onSectionSelect?: (sectionId: number) => void;
    onDataChange?: (sections: Section[]) => void;
    scene?: string;
}
export interface SectionListProps {
    sections: Section[];
    selectedSectionId?: number;
    onSectionSelect: (sectionId: number) => void;
    loading?: boolean;
    hasMore?: boolean;
    onLoadMore?: () => void;
}
export interface SettingsTableProps {
    section?: Section;
    groupList?: SettingGroup[];
    groupLoading?: boolean;
    onDataChange?: (section: Section) => void;
    onEditGroup?: (group: SettingGroup) => void;
    onDeleteGroup?: (groupId: number) => void;
    onAddItem?: (groupId: number) => void;
    onEditItem?: (item: SettingItem) => void;
    onDeleteItem?: (itemId: number) => void;
    onGroupReorder?: (groupIds: number[]) => void;
    onItemMove?: (itemId: number, targetGroupId: number, newOrder: number) => void;
}
export interface GroupFormData {
    title: MultiLanguageText;
    code: string;
    description?: MultiLanguageText;
}
export interface ItemFormData {
    name: MultiLanguageText;
    key: string;
    fieldType: string;
    interfaceType?: string;
    scopes: string[];
    description?: MultiLanguageText;
    default?: string | null;
    schema?: Record<string, any>;
    xDataSource?: {
        type?: string;
        options?: Array<{
            id?: string;
            label: string | MultiLanguageText;
            value: string;
            color?: string;
        }>;
        dataSource?: Record<string, any>;
        extraParams?: string;
    };
    xCustomUiSchema?: string;
    xRecordSchema?: string;
}
export interface GroupModalProps {
    open: boolean;
    type: OperationType;
    data?: SettingGroup;
    onOk: (data: GroupFormData) => void | Promise<void>;
    onCancel: () => void;
}
export interface ItemModalProps {
    open: boolean;
    type: OperationType;
    data?: SettingItem;
    section?: Section;
    onOk: (data: ItemFormData) => void | Promise<void>;
    onCancel: () => void;
    scene?: string;
}
export interface ApiResponse<T> {
    data: T[];
    meta: {
        count: number;
        page: number;
        pageSize: number;
        totalPage: number;
    };
}
