mirror of
https://github.com/maputnik/editor.git
synced 2025-12-24 15:10:01 +00:00
Fix layer selection (#1366)
## Launch Checklist - This fixes the issue of layer selection that was introduced as part of the migration to dnd-kit #1359 - Fixes #1364 This also adds the relevant test. - [x] Briefly describe the changes in this PR. - [x] Link to related issues. - [x] Write tests for all new functionality. --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
@@ -336,7 +336,7 @@ type LayerListProps = LayerListContainerProps & {
|
||||
};
|
||||
|
||||
const LayerList: React.FC<LayerListProps> = (props) => {
|
||||
const sensors = useSensors(useSensor(PointerSensor));
|
||||
const sensors = useSensors(useSensor(PointerSensor, { activationConstraint: { distance: 5 } }));
|
||||
|
||||
const handleDragEnd = (event: DragEndEvent) => {
|
||||
const {active, over} = event;
|
||||
|
||||
Reference in New Issue
Block a user