import { type DashboardAttributeFilterSelectionType, type FilterContextItem, type IAutomationMetadataObject, type IAutomationVisibleFilter, type IDashboardExportParameter, type IDashboardParameter, type IFilter, type IInsight, type IParameterMetadataObject } from "@gooddata/sdk-model";
import { type ExtendedDashboardWidget } from "../../../../../model/types/layoutTypes.js";
export interface IAutomationValidationResult {
    isValid: boolean;
    hiddenFilterIsMissingInSavedFilters: boolean;
    hiddenFilterHasDifferentValueInSavedFilter: boolean;
    lockedFilterIsMissingInSavedFilters: boolean;
    lockedFilterHasDifferentValueInSavedFilter: boolean;
    ignoredFilterIsAppliedInSavedFilters: boolean;
    removedFilterIsAppliedInSavedFilters: boolean;
    commonDateFilterIsMissingInSavedVisibleFilters: boolean;
    visibleFilterIsMissingInSavedFilters: boolean;
    visibleFiltersAreMissing: boolean;
    incompatibleSelectionTypeIsAppliedInSavedFilters: boolean;
    /**
     * A stored parameter override is stale. A missing workspace parameter (its ref left the
     * catalog) is the shared signal for both flows; export schedules additionally flag a removed
     * tab or a `readonly`/`hidden` parameter whose pinned value drifted from the dashboard.
     */
    parametersAreStale?: boolean;
    /**
     * Filter staleness in isolation — kept separate because `isValid` folds it together with
     * {@link parametersAreStale}, so a filters-only repair can't recover it from `!isValid`.
     */
    filtersAreStale?: boolean;
}
export declare function useValidateExistingAutomationFilters({ automationToEdit, widget, insight }: {
    automationToEdit?: IAutomationMetadataObject;
    widget?: ExtendedDashboardWidget;
    insight?: IInsight;
}): IAutomationValidationResult;
/**
 * Flags stale stored parameter overrides for an existing automation: a ref that left the workspace
 * catalog, a tab that no longer exists, or a `readonly`/`hidden` parameter whose pinned value
 * drifted from the current dashboard. `active` parameters are user-owned, so their drift is allowed.
 */
export declare function validateExistingAutomationParameters({ storedParametersByTab, catalog, dashboardParametersByTab, existingTabIds, widgetTabId }: {
    storedParametersByTab: Record<string, IDashboardExportParameter[]> | undefined;
    catalog: IParameterMetadataObject[];
    dashboardParametersByTab: Record<string, IDashboardParameter[]>;
    existingTabIds: Set<string>;
    /**
     * For widget schedules, the widget's current tab. A stored override under any other tab is
     * orphaned (the widget was moved) and flagged stale. Undefined for dashboard schedules and when
     * the tab can't be resolved, where every existing tab is accepted.
     */
    widgetTabId?: string;
}): boolean;
/**
 * Validate existing automation filters against current dashboard filter context and optionally saved widget / insight.
 * Check for inconsistencies, that could lead to unwanted results when editing existing automation.
 *
 * What can happen:
 * - Hidden filter value on the dashboard is different from the saved automation filter value, or it is missing
 * - Locked filter value on the dashboard is different from the saved automation filter value, or it is missing
 * - Some insight filter is missing in the saved automation, or it has different value
 * - Ignored filter is applied in the saved automation
 * - Removed filter is applied in the saved automation
 * - Attribute filter display form has changed
 * - Common non all-time date filter is missing in the saved automation visible filters
 * - Visible filter is missing in the saved automation filters
 */
export declare function validateExistingAutomationFilters({ savedAutomationFilters, savedAutomationVisibleFilters, hiddenFilters, lockedFilters, ignoredFilters, dashboardFilters, widget, insight, selectionTypeMap }: {
    savedAutomationFilters: IFilter[];
    savedAutomationVisibleFilters: undefined | IAutomationVisibleFilter[];
    hiddenFilters: FilterContextItem[];
    lockedFilters: FilterContextItem[];
    ignoredFilters: FilterContextItem[];
    dashboardFilters: FilterContextItem[];
    widget?: ExtendedDashboardWidget;
    insight?: IInsight;
    selectionTypeMap?: Map<string, DashboardAttributeFilterSelectionType | undefined>;
}): IAutomationValidationResult;
export interface IAutomationFiltersPerTabData {
    tabId: string;
    availableFilters: FilterContextItem[];
    hiddenFilters: FilterContextItem[];
    lockedFilters: FilterContextItem[];
}
/**
 * Validate existing automation filters for dashboards with per-tab filter structure.
 * Validates each tab's filters and aggregates results - if any tab is invalid, the whole automation is invalid.
 */
export declare function validateExistingAutomationFiltersPerTab({ savedDashboardFiltersByTab, savedAutomationVisibleFiltersByTab, dashboardFiltersPerTab, commonDateFilterId, selectionTypeMapByTab }: {
    savedDashboardFiltersByTab: Record<string, FilterContextItem[]>;
    savedAutomationVisibleFiltersByTab: Record<string, IAutomationVisibleFilter[]>;
    dashboardFiltersPerTab: IAutomationFiltersPerTabData[];
    commonDateFilterId?: string;
    selectionTypeMapByTab?: Record<string, Map<string, DashboardAttributeFilterSelectionType | undefined>>;
}): IAutomationValidationResult;
//# sourceMappingURL=useValidateExistingAutomationFilters.d.ts.map