import React from "react";
import { StandardError } from "../../../../../types";
import { Workspace, WorkspaceTemplate } from "../../../../types/workspaceTypes";
interface IProps {
    addListener: (fieldListener: {
        field: string;
    }, cb: (err: StandardError, data: any) => void) => void;
    getValue: (arr: string[], cb: (err: StandardError, data: Workspace[]) => void) => void;
    removeListener: (fieldName: {
        field: string;
    }, cb: (err: StandardError, data: any) => void) => void;
}
interface IState {
    initialAlwaysOnTop: boolean;
    alwaysOnTop: boolean;
    workspaceList: Workspace[];
    focusedWorkspace: string;
    activeWorkspace: string;
    editing: boolean;
    workspaceBeingEdited: string;
    templateName: string;
    adding: boolean;
    workspaceToLoadOnStart: string | null;
    focusedWorkspaceComponentList: string[];
    promptUserOnDirtyWorkspace: boolean;
    discardUnsavedChanges: boolean;
    permanentWorkspaces: string[];
}
export default class Workspaces extends React.Component<IProps, IState> {
    addWorkspace?: () => void;
    workspaceUpdatedSubscriber: {
        subscribeID: string;
        topic: string;
    };
    constructor(props: IProps);
    resetState(): void;
    bindCorrectContext(): void;
    setWorkspaceList(err: StandardError, data: {
        value: Workspace[];
    }): void;
    setPermanentWorkspaces(err: StandardError, config: any): void;
    addListeners(): void;
    /**
     * Sets the windowOptions.alwaysOnTop to the value supplied. The preferences component should
     * not be always on top when a file dialog is open.
     * @param {boolean} alwaysOnTop The value to set FEAGlobals.finsembleWindow.options.alwaysOnTop
     */
    changePreferencesAlwaysOnTop(alwaysOnTop: boolean): void;
    onDragEnd({ oldIndex, newIndex }: {
        oldIndex: number;
        newIndex: number;
    }): void;
    getComponentTypes(templateObject: WorkspaceTemplate): string[];
    setFocusedWorkspace(workspace: string): void;
    cancelEdit(): void;
    renameWorkspace(newName: string): void;
    startEditingWorkspace(e: React.SyntheticEvent, workspaceName?: string): void;
    startExportingTemplate(): void;
    startImportingTemplate(): void;
    deleteWorkspace(workspaceName?: string): void;
    setUIPreferencesState(err: StandardError, data: any): void;
    componentDidMount(): void;
    componentWillUnmount(): void;
    setPreference(field: string, value: any, cb?: Function): void;
    setWorkspaceToLoadOnStart(eventOrCb: React.ChangeEvent<HTMLInputElement> | (() => void)): void;
    openFileDialog(): void;
    /**
     * If the event is being listened to, when the preferences component is focused
     * it will set always on top to true, and remove the event listener
     *
     * This is to handle bringing alwaysOnTop back to true when file dialogs are closed
     * without changes (also handles bringing back to front after exporting)
     */
    preferencesFocused(): void;
    importWorkspace(evt: Event & {
        target: {
            files: File[];
            value?: string | string[];
        };
    }): void;
    exportWorkspace(): void;
    handleButtonClicks(e: React.MouseEvent<HTMLDivElement>): void;
    getFocusedWorkspaceComponentList(): Promise<never[] | undefined>;
    toggleDiscardUnsavedChanges(): void;
    togglePromptUserOnDirtyWorkspace(): void;
    render(): React.JSX.Element;
}
export {};
//# sourceMappingURL=Workspaces.d.ts.map