export type Search<Type extends "simple" | "conditional" = "simple"> = {
    type: Type;
} & Type extends "simple" ? SimpleSearch : ConditionalSearch;
export interface SimpleSearch {
    type: "simple";
    user?: string;
    mode?: "fuzzy" | "exact" | "similarity";
    query?: string;
    count?: number;
    deleted?: boolean;
    hidden?: boolean | null;
    sortBy?: string | null;
    refreshInterval?: number;
    highlight?: SearchHighlightOption;
}
export interface ConditionalSearch {
    type: "conditional";
    user?: string;
    searchIds?: string[];
    searches?: string[];
    mode?: "fuzzy" | "exact" | "similarity";
    query?: string;
    sort?: string;
    hidden?: boolean | null;
    deleted?: boolean;
    count?: number;
    refreshInterval?: number;
    highlight?: SearchHighlightOption;
    timeField?: string;
    startTime?: string;
    endTime?: string;
    geoField?: string;
    geoBounds?: {
        x1: number;
        y1: number;
        x2: number;
        y2: number;
    };
}
export interface SearchHighlightOption {
    fields: {
        [field: string]: unknown;
    };
}
export interface SearchCondition {
    field?: string;
    type?: string;
    op?: string;
    value?: unknown;
}
export type SearchType = "conditions_and" | "conditions_or";
export type SearchView = "GRID_VIEW" | "LIST_VIEW" | "CALENDAR_VIEW" | "MAP_VIEW" | "AGENDA_VIEW" | "RESOURCE_VIEW";
export type SearchCalendarView = "day" | "week" | "month" | "work_week";
