/// <reference types="react" />
import type { CreateDeviceConnectionPayload, DeviceBrandItem, DeviceConnectionItem, DeviceItem, DeviceModelItem, I18nText, LangDict, UpdateDeviceConnectionPayload, WorkAreaItem } from '../types';
export declare type ConnectMode = 'existing' | 'new' | 'edit';
export declare type ConnectStep = 'pick' | 'config';
export declare type NetworkMethod = 'auto' | 'manual';
export interface ConnectFormValues {
    name?: LangDict;
    workarea_id?: number;
    connection_type?: string;
    connection_method?: NetworkMethod;
    connection_ip?: string;
    profile_ids?: number[];
}
export interface UseConnectDeviceModalParams {
    open: boolean;
    mode: ConnectMode;
    currentDevice: DeviceItem;
    editConnection?: DeviceConnectionItem;
    connectedDeviceIds: number[];
    currentWorkAreaId?: number;
    getText: (key: string) => string;
    translation: (val?: I18nText) => string;
    onSubmit?: (payload: CreateDeviceConnectionPayload) => void;
    onUpdate?: (id: number, payload: UpdateDeviceConnectionPayload) => void;
}
export declare const useConnectDeviceModal: ({ open, mode, currentDevice, editConnection, connectedDeviceIds, currentWorkAreaId, getText, translation, onSubmit, onUpdate, }: UseConnectDeviceModalParams) => {
    step: ConnectStep;
    workAreas: WorkAreaItem[];
    brands: DeviceBrandItem[];
    models: DeviceModelItem[];
    selectedWorkAreaId: number | undefined;
    selectedModel: DeviceModelItem | undefined;
    keyword: string;
    editFormValues: ConnectFormValues | undefined;
    loading: boolean;
    detailLoading: boolean;
    pickingDeviceId: number | undefined;
    currentIsSmart: boolean;
    targetKind: "smart" | "dumb";
    peripheral: DeviceItem | undefined;
    smartDevice: DeviceItem | undefined;
    profileOptions: {
        label: string;
        value: number;
    }[];
    profileRequired: boolean;
    filteredDevices: DeviceItem[];
    getWorkAreaDeviceCount: (area: WorkAreaItem) => number;
    getDeviceCountText: (count: number) => string;
    setSelectedWorkAreaId: import("react").Dispatch<import("react").SetStateAction<number | undefined>>;
    setKeyword: import("react").Dispatch<import("react").SetStateAction<string>>;
    handlePickDevice: (device: DeviceItem) => void;
    handlePickModel: (model: DeviceModelItem) => void;
    handleBackToPick: () => void;
    handleSubmit: (values: ConnectFormValues) => void;
};
