import { DockviewCompositeDisposable as CompositeDisposable, DockviewEvent as Event, FloatingGroupDragContext, SmartGuidesOptions, SmartGuidesSnapEvent, SmartGuidesSnapTogetherEvent, ISmartGuidesHost, ISmartGuidesService } from 'dockview'; /** * Smart Guides: Figma-style alignment guides + magnetic snapping for floating * groups. * * The float drag loop stays fully owned by `Overlay`; this service is a pure * consumer. The component composes it into the loop's position-transform, so * each pointer-move frame the proposed, container-relative box is offered here * and an adjusted top-left returned. X and Y are resolved independently against * the other floats' and the container's edges + centers, with asymmetric * engage/release hysteresis to stop boundary oscillation; every alignment the * snapped box lands on is painted as a guide line. With `smartGuides` unset the * transform is a pass-through and no overlay is created. */ export declare class SmartGuidesService extends CompositeDisposable implements ISmartGuidesService { private readonly host; private readonly _sessions; /** Runtime option overrides (from `setEnabled` / `updateOptions`), merged * over the host's `smartGuides` option. */ private _override; private readonly _onDidSnapFloat; readonly onDidSnapFloat: Event; private readonly _onDidSnapTogether; readonly onDidSnapTogether: Event; constructor(host: ISmartGuidesHost); get enabled(): boolean; setEnabled(enabled: boolean): void; updateOptions(options: Partial): void; private _optsCache; private get _opts(); /** Whether the configured disable-modifier is held this frame. */ private _gated; transformFloatingGroupDrag(context: FloatingGroupDragContext): { top: number; left: number; } | void; private _startSession; /** Add snap candidates for the grid's splitters behind the float. */ private _pushSplitterCandidates; private _probes; /** * Resolve one axis: keep the engaged candidate until the pointer moves past * the release threshold, otherwise acquire the best in-range candidate. The * best is ranked edge-over-center, then source priority, then nearest. */ private _resolveAxis; /** Acquire: the highest-priority candidate within the engage threshold, * ranked edge-over-center, then source priority, then nearest. */ private _acquireBest; private _keyLess; /** Every candidate line the (already snapped) box's probes land on, so two * simultaneous alignments (e.g. left edges and tops) draw two guides. */ private _guideLines; /** * Detect a dock/merge intent for the snapped box against the other floats, * choosing the **best** target rather than the first in iteration order: a * tab-strip overlap (the dragged centre over a target) suggests a **center** * merge into a shared tabset; an edge flush against a target's opposite edge * (with ≥ 50% perpendicular overlap) suggests docking **beside** it. Among * matches, a centre stack beats an adjacency, and within a kind the nearest * target wins. */ private _detectSnapTogether; /** The single best dock/merge intent for one target (or undefined), with a * lower-is-better score: a centre stack always outranks an adjacency, and * the score breaks ties by nearness so clustered floats dock into the * closest neighbour. */ private _intentForTarget; private _commitAndEnd; private _endSession; } export declare const SmartGuidesModule: import("dockview").DockviewModule;