You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
32 lines
836 B
32 lines
836 B
import type { InjectionKey } from 'vue';
|
|
import type Node from './node';
|
|
interface TreeNode {
|
|
node: Node;
|
|
$el?: HTMLElement;
|
|
}
|
|
interface DragOptions {
|
|
event: DragEvent;
|
|
treeNode: TreeNode;
|
|
}
|
|
export interface DragEvents {
|
|
treeNodeDragStart: (options: DragOptions) => void;
|
|
treeNodeDragOver: (options: DragOptions) => void;
|
|
treeNodeDragEnd: (event: DragEvent) => void;
|
|
}
|
|
export declare const dragEventsKey: InjectionKey<DragEvents>;
|
|
export declare function useDragNodeHandler({ props, ctx, el$, dropIndicator$, store }: {
|
|
props: any;
|
|
ctx: any;
|
|
el$: any;
|
|
dropIndicator$: any;
|
|
store: any;
|
|
}): {
|
|
dragState: import("vue").Ref<{
|
|
showDropIndicator: boolean;
|
|
draggingNode: null;
|
|
dropNode: null;
|
|
allowDrop: boolean;
|
|
dropType: null;
|
|
}>;
|
|
};
|
|
export {};
|
|
|