Skip to content

Commit f41961b

Browse files
Merge pull request #155 from lokanandaprabhu/feature/SRVKP-6343
SRVKP-6343: Console crashes when ssh is selected in add secret for starting a pipeline run
2 parents a4b3159 + 8389a20 commit f41961b

File tree

1 file changed

+2
-5
lines changed

1 file changed

+2
-5
lines changed

src/components/text-column-field/drag-drop-context.tsx

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,17 +1,14 @@
11
import * as React from 'react';
2-
import { DndProvider, createDndContext } from 'react-dnd';
2+
import { DndProvider } from 'react-dnd';
33
import HTML5Backend from 'react-dnd-html5-backend';
44

5-
const dndContext = createDndContext(HTML5Backend);
6-
75
const withDragDropContext =
86
<TProps extends {}>(
97
Component: React.ComponentClass<TProps> | React.FC<TProps>,
108
) =>
119
(props: TProps) => {
12-
const manager = React.useRef(dndContext);
1310
return (
14-
<DndProvider manager={manager.current.dragDropManager}>
11+
<DndProvider backend={HTML5Backend} context={window}>
1512
<Component {...props} />
1613
</DndProvider>
1714
);

0 commit comments

Comments
 (0)