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.
19 lines
474 B
19 lines
474 B
import * as React from 'react';
|
|
import { createDragDropManager, } from 'dnd-core';
|
|
/**
|
|
* Create the React Context
|
|
*/
|
|
export const DndContext = React.createContext({
|
|
dragDropManager: undefined,
|
|
});
|
|
/**
|
|
* Creates the context object we're providing
|
|
* @param backend
|
|
* @param context
|
|
*/
|
|
export function createDndContext(backend, context, options, debugMode) {
|
|
return {
|
|
dragDropManager: createDragDropManager(backend, context, options, debugMode),
|
|
};
|
|
}
|