@dnd-kit/react 0.0.10-beta-20250219015224 → 0.0.10-beta-20250219015925
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/index.d.ts +5 -5
- package/package.json +4 -4
package/index.d.ts
CHANGED
|
@@ -51,10 +51,10 @@ declare function useDroppable<T extends Data = Data>(input: UseDroppableInput<T>
|
|
|
51
51
|
|
|
52
52
|
declare function useDragDropManager(): _dnd_kit_dom.DragDropManager<_dnd_kit_dom.Draggable<_dnd_kit_abstract.Data>, _dnd_kit_dom.Droppable<_dnd_kit_abstract.Data>> | null;
|
|
53
53
|
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
type EventHandlerName<T extends string> = `on${Capitalize<T>}`;
|
|
54
|
+
type DragDropEventMap = {
|
|
55
|
+
beforedragstart: 'onBeforeDragStart';
|
|
56
|
+
};
|
|
57
|
+
type EventHandlerName<T extends string> = T extends keyof DragDropEventMap ? DragDropEventMap[T] : T extends `drag${infer Second}${infer Rest}` ? `onDrag${Uppercase<Second>}${Rest}` : `on${Capitalize<T>}`;
|
|
58
58
|
/**
|
|
59
59
|
* Type for all possible event handlers
|
|
60
60
|
*/
|
|
@@ -63,7 +63,7 @@ type DndMonitorEventHandlers<T extends Data> = {
|
|
|
63
63
|
[K in keyof Events<T> as EventHandlerName<K>]?: Events<T>[K];
|
|
64
64
|
};
|
|
65
65
|
/**
|
|
66
|
-
* Hook to monitor drag and drop events within a DragDropProvider
|
|
66
|
+
* Hook to monitor drag and drop events anywhere within a DragDropProvider
|
|
67
67
|
* @param handlers Object containing event handlers for drag and drop events
|
|
68
68
|
*/
|
|
69
69
|
declare function useDragDropMonitor<T extends Data = Data>(handlers: DndMonitorEventHandlers<T>): void;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@dnd-kit/react",
|
|
3
|
-
"version": "0.0.10-beta-
|
|
3
|
+
"version": "0.0.10-beta-20250219015925",
|
|
4
4
|
"main": "./index.cjs",
|
|
5
5
|
"module": "./index.js",
|
|
6
6
|
"type": "module",
|
|
@@ -56,9 +56,9 @@
|
|
|
56
56
|
"clean": "rm -rf .turbo && rm -rf node_modules && rm -rf dist"
|
|
57
57
|
},
|
|
58
58
|
"dependencies": {
|
|
59
|
-
"@dnd-kit/abstract": "0.0.10-beta-
|
|
60
|
-
"@dnd-kit/dom": "0.0.10-beta-
|
|
61
|
-
"@dnd-kit/state": "0.0.10-beta-
|
|
59
|
+
"@dnd-kit/abstract": "0.0.10-beta-20250219015925",
|
|
60
|
+
"@dnd-kit/dom": "0.0.10-beta-20250219015925",
|
|
61
|
+
"@dnd-kit/state": "0.0.10-beta-20250219015925",
|
|
62
62
|
"tslib": "^2.6.2"
|
|
63
63
|
},
|
|
64
64
|
"peerDependencies": {
|