mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
feat(ui): disable keyboard dnd
Need to fix a bug w/ collision detection before enabling it. Will pursue later.
This commit is contained in:
parent
7bd94eac0e
commit
b1000e30c1
@ -46,9 +46,12 @@ const ImageDndContext = (props: ImageDndContextProps) => {
|
||||
const touchSensor = useSensor(TouchSensor, {
|
||||
activationConstraint: { distance: 15 },
|
||||
});
|
||||
const keyboardSensor = useSensor(KeyboardSensor);
|
||||
// TODO: Use KeyboardSensor - needs composition of multiple collisionDetection algos
|
||||
// Alternatively, fix `rectIntersection` collection detection to work with the drag overlay
|
||||
// (currently the drag element collision rect is not correctly calculated)
|
||||
// const keyboardSensor = useSensor(KeyboardSensor);
|
||||
|
||||
const sensors = useSensors(mouseSensor, touchSensor, keyboardSensor);
|
||||
const sensors = useSensors(mouseSensor, touchSensor);
|
||||
|
||||
return (
|
||||
<DndContext
|
||||
|
@ -70,6 +70,7 @@ const UnifiedCanvasContent = () => {
|
||||
return (
|
||||
<Box
|
||||
ref={setDroppableRef}
|
||||
tabIndex={0}
|
||||
sx={{
|
||||
w: 'full',
|
||||
h: 'full',
|
||||
@ -109,6 +110,7 @@ const UnifiedCanvasContent = () => {
|
||||
return (
|
||||
<Box
|
||||
ref={setDroppableRef}
|
||||
tabIndex={-1}
|
||||
sx={{
|
||||
w: 'full',
|
||||
h: 'full',
|
||||
|
Loading…
Reference in New Issue
Block a user