import { DataAssociation, DataEntity, DataModel, DataNamespace, DataProperty } from "@api-client/core/build/browser.js";
import { TemplateResult, nothing, CSSResult, PropertyValues } from "lit";
import ApiElement from "../ApiElement.js";
import VizWorkspaceElement from "../../visualization/elements/VizWorkspaceElement.js";
import '../../define/visualization/viz-workspace.js';
import '../../define/visualization/viz-association.js';
import '../../define/ui/ui-icon.js';
import { GroupSelection } from "../../visualization/plugin/group-selection/GroupSelection.js";
import { DragAndDropPlugin } from "../../visualization/plugin/dnd/DragAndDropPlugin.js";
interface VizModel {
    id?: string;
    entity: DataEntity;
    type: 'parent' | 'association' | 'internal' | 'external' | 'self';
    x?: number;
    y?: number;
}
export default class DataModelVisualizationElement extends ApiElement {
    static get styles(): CSSResult[];
    /**
     * The key of the entity to edit.
     */
    key?: string;
    /**
     * The read data namespace.
     */
    root?: DataNamespace;
    /**
     * The computed entity when the key or root change.
     */
    protected _model?: DataModel;
    protected _data?: VizModel[];
    protected _workspace?: VizWorkspaceElement;
    protected groupSelectionPlugin?: GroupSelection;
    protected dndPlugin?: DragAndDropPlugin;
    firstUpdated(cp: PropertyValues<this>): void;
    connectedCallback(): void;
    disconnectedCallback(): void;
    protected willUpdate(cp: PropertyValues<this>): void;
    /**
     * Reloads the generated view model, runs the auto layout, and updated the view.
     * Note, this is very expensive operation. It updates the view at least twice.
     * THe layout computation can be very complex.
     */
    refresh(): Promise<void>;
    /**
     * Computes the view value for the property.
     * This should be called before the update is complete so this won't trigger another update.
     */
    protected _computeModel(): void;
    protected _runLayout(): Promise<void>;
    protected _createVizData(): void;
    protected _repositionHandler(e: CustomEvent): Promise<void>;
    protected render(): TemplateResult;
    protected _modelContents(): TemplateResult[] | typeof nothing;
    protected _entityVisualization(model: VizModel): TemplateResult;
    protected _propertiesListTemplate(entity: DataEntity): TemplateResult;
    protected _propertyItemTemplate(item: DataProperty): TemplateResult;
    protected _associationTemplate(item: DataAssociation): TemplateResult | typeof nothing;
    protected _parentAssociationTemplate(id: string): TemplateResult;
}
export {};
//# sourceMappingURL=DataModelVisualizationElement.d.ts.map