Skip to content

Commit

Permalink
Fixed: Drag and Drop Causes Flashing and Disappearing Cards twentyhq#…
Browse files Browse the repository at this point in the history
…6001 by setting root to document's viewport
  • Loading branch information
rksingh2001 committed Jun 27, 2024
1 parent 1a66db5 commit 3cf8f26
Showing 1 changed file with 0 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,6 @@ import { Checkbox, CheckboxVariant } from '@/ui/input/components/Checkbox';
import { contextMenuIsOpenState } from '@/ui/navigation/context-menu/states/contextMenuIsOpenState';
import { contextMenuPositionState } from '@/ui/navigation/context-menu/states/contextMenuPositionState';
import { AnimatedEaseInOut } from '@/ui/utilities/animation/components/AnimatedEaseInOut';
import { ScrollWrapperContext } from '@/ui/utilities/scroll/components/ScrollWrapper';

const StyledBoardCard = styled.div<{ selected: boolean }>`
background-color: ${({ theme, selected }) =>
Expand Down Expand Up @@ -199,10 +198,7 @@ export const RecordBoardCard = () => {
return [updateEntity, { loading: false }];
};

const scrollWrapperRef = useContext(ScrollWrapperContext);

const { ref: cardRef, inView } = useInView({
root: scrollWrapperRef.current,
rootMargin: '1000px',
});

Expand Down

0 comments on commit 3cf8f26

Please sign in to comment.