mirror of
https://github.com/blakeblackshear/frigate.git
synced 2026-04-05 14:47:40 +03:00
Fix fit-to-screen drag: use noCompactor for free horizontal movement
In fit-to-screen mode, pass noCompactor to <Responsive> so elements follow the mouse freely without vertical compaction pushing them down. The swap-on-drop logic (mouse coordinates in onDragStop) stays unchanged. https://claude.ai/code/session_01Cu7YDRKZrYX3sBs6g9w2dy
This commit is contained in:
parent
29e2003a84
commit
8fc7f6bdb7
@ -16,6 +16,7 @@ import {
|
||||
Layout,
|
||||
LayoutItem,
|
||||
ResponsiveGridLayout as Responsive,
|
||||
noCompactor,
|
||||
} from "react-grid-layout";
|
||||
import "react-grid-layout/css/styles.css";
|
||||
import "react-resizable/css/styles.css";
|
||||
@ -920,6 +921,7 @@ export default function DraggableGridLayout({
|
||||
{containerWidth > 0 && <Responsive
|
||||
className="grid-layout"
|
||||
width={availableWidth}
|
||||
compactor={fitToScreen ? noCompactor : undefined}
|
||||
layouts={{
|
||||
lg: activeGridLayout,
|
||||
md: activeGridLayout,
|
||||
|
||||
Loading…
Reference in New Issue
Block a user