import VizWorkspaceElement from '../elements/VizWorkspaceElement.js';
import { ISelectedDomain } from './types.js';
export declare const clickHandler: unique symbol;
export declare const observeItems: unique symbol;
export declare const mutationHandler: unique symbol;
export declare const mutationObserver: unique symbol;
export declare const processAddedNodes: unique symbol;
export declare const processRemovedNodes: unique symbol;
export declare const processAttributeChanged: unique symbol;
export declare const propagateSelection: unique symbol;
export declare const selectAssociations: unique symbol;
export declare const selectReverseAssociations: unique symbol;
export declare const propagateDeselection: unique symbol;
export declare const deselectAssociations: unique symbol;
export declare const deselectReverseAssociations: unique symbol;
export declare const notifyChanged: unique symbol;
export declare const selectedItemsValue: unique symbol;
export declare const selectedIdsValue: unique symbol;
/**
 * A class that takes care of selection in the visualization workspace.
 */
export declare class SelectionManager {
    target: VizWorkspaceElement;
    /**
     * The list of currently selected elements
     */
    [selectedItemsValue]: Set<Element>;
    /**
     * The list of currently selected domain ids
     */
    [selectedIdsValue]: ISelectedDomain[];
    [mutationObserver]?: MutationObserver;
    /**
     * @returns A set of currently selected items.
     */
    get selectedItems(): Set<Element>;
    /**
     * @returns A list of currently selected domain ids.
     */
    get selected(): ISelectedDomain[];
    /**
     * @returns A list of all selectable items
     */
    get selectable(): Element[];
    constructor(target: VizWorkspaceElement);
    /**
     * Initializes the library. Should be called when the workspace is ready to render content.
     */
    connect(): void;
    /**
     * Cleans up and removes listeners
     */
    disconnect(): void;
    /**
     * Checks if given element is marked as selectable target
     * @param selectable The element to test for `selectable` or `data-selectable` attribute
     * @returns True if the element can be selected
     */
    isSelectable(selectable: Element): boolean;
    /**
     * Checks if given element is marked as selected
     * @param selectable The element to test for `selected` or `data-selected` attribute
     * @returns True if the element is marked as selected
     */
    isSelected(selectable: Element): boolean;
    /**
     * Marks an element as selected
     * @param selectable The element to add the selected mark to.
     */
    setSelected(selectable: Element): void;
    /**
     * Marks an element as not selected
     * @param selectable The element to remove the selected mark from.
     */
    setUnselected(selectable: Element): void;
    /**
     * Deselects all currently selected items.
     */
    selectAll(): void;
    /**
     * Deselects all currently selected items.
     */
    deselectAll(): void;
    /**
     * Selects objects that are selectable by their `key`.
     *
     * The `addToSelection` argument is equivalent of calling `deselectAll()` and then `select(...)`.
     *
     * @param keys The list of domain ids of objects to select.
     * @param addToSelection If true it adds to the current selection rather than replacing it.
     */
    select(keys: string[], addToSelection?: boolean): void;
    /**
     * Removes objects from selection.
     *
     * @param keys The list of domain ids of objects to deselect.
     */
    deselect(keys: string[]): void;
    /**
     * Synchronizes the selection state with the view
     */
    syncView(): void;
    /**
     * Reads the attribute value to get the `key` property.
     * @param selectable
     * @returns The domain id of the object or `null` when not found
     */
    readKey(selectable: Element): string | null;
    /**
     * Finds a workspace element that has the domain id.
     * @param id Target domain id
     */
    getDomainTarget(id: string): Element | null;
    /**
     * Finds a workspace element that has the domain id and is selectable.
     * @param id Target domain id
     */
    getSelectableDomainTarget(id: string): Element | null;
    [clickHandler](e: PointerEvent): void;
    /**
     * Observe items change in the element's light DOM
     * @returns The observer handler
     */
    [observeItems](): MutationObserver;
    /**
     * Processes mutations in the workspace and manages selection state.
     * @param mutationsList List of mutations.
     */
    [mutationHandler](mutationsList: MutationRecord[]): void;
    /**
     * Processes added to the canvas elements.
     * @param nodes The list of added nodes
     */
    [processAddedNodes](nodes: NodeList): void;
    /**
     * Processes removed from the canvas elements.
     * @param nodes The list of removed nodes
     */
    [processRemovedNodes](nodes: NodeList): void;
    /**
     * Processes changed attribute on any element in the canvas
     * @param node Changed element
     * @param prop Changed property
     */
    [processAttributeChanged](node: Element, prop: string): void;
    /**
     * Sets selection to the elements that are related to the `selectable` element.
     *
     * A related element is an element that is an association target to the `selectable`
     * ot the `selectable` has `parent` attribute.
     *
     * The related are not added to the `selectedItems` set and does not have `selected` attribute.
     * They are marked with `second-selected` attribute.
     */
    [propagateSelection](selectable: Element): void;
    /**
     * Marks `viz-association` and referenced targets of the `selectable` as a secondary selection.
     */
    [selectAssociations](selectable: Element): void;
    /**
     * Similar to `[selectAssociations]()` but it selects associations where
     * the `selectable` is the target.
     */
    [selectReverseAssociations](selectable: Element): void;
    /**
     * Removes secondary selection from the elements that are related to the `selectable` element.
     *
     * A related element is an element that is an association target to the `selectable`
     * ot the `selectable` has `parent` attribute.
     */
    [propagateDeselection](selectable: Element): void;
    /**
     * Removes secondary selection mark from `viz-association`
     */
    [deselectAssociations](selectable: Element): void;
    /**
     * Similar to `[selectAssociation]()` but it selects associations where
     * the `selectable` is the target.
     */
    [deselectReverseAssociations](selectable: Element): void;
    [notifyChanged](): void;
}
//# sourceMappingURL=SelectionManager.d.ts.map