import type { GetClusterAddons } from '../ComponentUninstalled';
import type { LogicalClusterItem, LogicalDatacenterItem } from '../LogicalResourceFilter';
import type { CascaderClusterServices } from './services';
export type { LogicalClusterItem, LogicalDatacenterItem };
export interface CascaderClusterFilterCache {
    name?: string | null;
    id?: string | null;
    dataCenterId?: string | number | null;
    logicalUnitId?: string | number | null;
    clusterName?: string;
}
export interface CascaderClusterStorage {
    getSession: (key: string, returnStr?: boolean) => unknown;
    setSession: (key: string, value: unknown) => void;
}
export interface CascaderClusterTexts {
    unbound?: string;
    clusterOffline?: string;
    searchByClusterName?: string;
    pleaseSelectCluster?: string;
    selectLogicalUnit?: string;
    nodata?: string;
}
export interface CascaderClusterDataInterface {
    datacenter?: {
        service?: (params: Record<string, unknown>) => Promise<LogicalDatacenterItem[]>;
        params?: Record<string, unknown>;
    };
    resource?: {
        service?: (params: Record<string, unknown>) => Promise<LogicalClusterItem[]>;
        params?: Record<string, unknown>;
    };
}
export interface CascaderClusterProps {
    /** project | org | system | cluster | networkManage */
    space: string;
    onClusterChange: (clusterName: string) => void;
    /** false 表示组件内拉取；数组表示外部传入 */
    datacenters?: LogicalDatacenterItem[] | false;
    clusters?: LogicalClusterItem[] | false;
    compoKey?: string | number;
    dataInterface?: CascaderClusterDataInterface;
    /** 与 space 配合自动拼装 dataInterface；与 dataInterface 二选一 */
    services?: CascaderClusterServices;
    storage?: CascaderClusterStorage;
    /** 未传时根据 URL 自动判断后台/用户侧 */
    isBackend?: boolean;
    pathname?: string;
    onFilterCacheChange?: (params: CascaderClusterFilterCache) => void;
    getClusterAddons?: GetClusterAddons;
    showComponentUninstalled?: boolean;
    texts?: CascaderClusterTexts;
}
