import type { StoreConfig, Action, ThunkArgs } from '../utils/store-types';
type Settings = Record<string, unknown>;
export declare enum ActionType {
    Unknown = "REDUX_UNKNOWN",
    ReceiveSettings = "RECEIVE_SETTINGS",
    SaveSettingsStart = "SAVE_SETTINGS_START",
    SaveSettingsFinish = "SAVE_SETTINGS_FINISH",
    SetSetting = "SET_SETTING"
}
type UnknownAction = Action<ActionType.Unknown>;
type ReceiveSettingsAction = Action<ActionType.ReceiveSettings, {
    settings: Settings;
}>;
type SaveSettingsStartAction = Action<ActionType.SaveSettingsStart>;
type SaveSettingsFinishAction = Action<ActionType.SaveSettingsFinish>;
type SetSettingAction = Action<ActionType.SetSetting, {
    setting: string;
    value: unknown;
}>;
export type CombinedAction = UnknownAction | ReceiveSettingsAction | SaveSettingsStartAction | SaveSettingsFinishAction | SetSettingAction;
export type State = {
    savedSettings: Settings | undefined;
    modifiedSettings: Settings;
    optionNameMap: Record<string, string>;
    isSavingSettings: boolean;
};
export type ActionCreators = typeof actions;
export type Selectors = typeof selectors;
type DispatcherArgs = ThunkArgs<State, ActionCreators, CombinedAction, Selectors>;
declare const actions: {
    /**
     * Receives settings from the server.
     *
     * @since 0.1.0
     *
     * @param settings - Settings received from the server, as key value pairs.
     * @returns Action creator.
     */
    receiveSettings(settings: Settings): ({ dispatch }: DispatcherArgs) => void;
    /**
     * Saves all settings to the server.
     *
     * @since 0.1.0
     *
     * @returns Action creator.
     */
    saveSettings(): ({ dispatch, select, registry }: DispatcherArgs) => Promise<void>;
    /**
     * Sets the value for a setting.
     *
     * @since 0.1.0
     *
     * @param setting - The setting name.
     * @param value   - The new value for the setting.
     * @returns Action creator.
     */
    setSetting(setting: string, value: unknown): ({ dispatch }: DispatcherArgs) => void;
    /**
     * Sets the value for an API key setting.
     *
     * @since 0.1.0
     *
     * @param service - The service name.
     * @param apiKey  - The new API key.
     * @returns Action creator.
     */
    setApiKey(service: string, apiKey: string): ({ dispatch }: DispatcherArgs) => void;
    /**
     * Sets the value for the deleteData setting.
     *
     * @since 0.1.0
     *
     * @param deleteData - The new deleteData value.
     * @returns Action creator.
     */
    setDeleteData(deleteData: boolean): ({ dispatch }: DispatcherArgs) => void;
};
declare const selectors: {
    getSettings: ((state: State) => {
        [x: string]: unknown;
    } | undefined) & import("rememo").EnhancedSelector;
    hasModifiedSettings: ((state: State) => boolean) & import("rememo").EnhancedSelector;
    isSavingSettings: (state: State) => boolean;
    areSettingsSaveable: {
        (): boolean;
        isRegistrySelector?: boolean;
        registry?: any;
    };
    getSetting: {
        (_state: State, setting: string): unknown;
        isRegistrySelector?: boolean;
        registry?: any;
    };
    getApiKey: (state: State, service: string) => string | undefined;
    getDeleteData: (state: State) => boolean | undefined;
    isSettingModified: (state: State, setting: string) => boolean;
    getOptionName: (state: State, setting: string) => string;
};
declare const storeConfig: StoreConfig<State, ActionCreators, CombinedAction, Selectors>;
export default storeConfig;
//# sourceMappingURL=settings.d.ts.map