import { AdditionalFilter } from '../../../shared-logic/src/AdditionalFilter/types';
import { Cell } from './Cell';
import * as Views from './View';
/**
 * Represents a Library class.
 * @param components The `component` instance to be added to the library. `uniqueViewId` of the component, should always be the same and not auto-generated.
 */
export declare type LibraryView = {
    component: Views.AnyView;
    uniqueViewId: string;
};
export declare class Library {
    /**
     * An array of Cell instances representing the cells in the library.
     */
    library: Cell[] | undefined;
    /**
     * Creates a new instance of a Library.
     * @param attributes An optional object containing the attributes of the library.
     * @param components The `component` instance to be added to the library. `uniqueViewId` of the component, should always be the same and not auto-generated.
     */
    constructor(attributes?: {
        components?: LibraryView[];
    });
    /**
     * Adds a cell to the library at a specified position or appends it at the end if no position is specified.
     * @param component The Component instance to be added to the library.
     * @param uniqueViewId The unique view id of the component, should always be the same and not auto-generated. The `uniqueViewId` will become the `viewId` of the component.
     * @param attributes An optional object containing the attributes of the cell.
     * @example library.addComponent(Vizzly.AreaChart, "uniqueViewId");
     * @example library.addComponent(Vizzly.AreaChart, "uniqueViewId", { position: 0 });
     */
    addComponent(component: Views.AnyView, uniqueViewId: string, attributes?: {
        position?: number;
        localFilters?: AdditionalFilter[];
    }): void;
    /**
     *  Adds an array of cells to the library.
     * @param components The `component` instance to be added to the library. `uniqueViewId` of the component, should always be the same and not auto-generated.
     */
    addComponents(components: LibraryView[]): void;
}
export declare const mergeInViewId: (component: Views.AnyView, uniqueViewId: string) => Views.AnyView;
