motion-v
Version:
<h1 align="center"> <img width="35" height="35" alt="Motion logo" src="https://github.com/user-attachments/assets/00d6d1c3-72c4-4c2f-a664-69da13182ffc" /><br />Motion for Vue</h1>
18 lines (17 loc) • 467 B
JavaScript
var DragControls = class {
constructor() {
this.componentControls = /* @__PURE__ */ new Set();
}
subscribe(controls) {
this.componentControls.add(controls);
return () => this.componentControls.delete(controls);
}
start(event, options) {
this.componentControls.forEach((controls) => {
controls.start(event, options);
});
}
};
var createDragControls = () => new DragControls();
const useDragControls = createDragControls;
export { useDragControls };