github clauderic/dnd-kit @dnd-kit/core@6.1.0

latest releases: @dnd-kit/dom@0.2.1, @dnd-kit/state@0.2.1, @dnd-kit/collision@0.2.1...
2 years ago

Minor Changes

  • #1271 bc588c7 Thanks @clauderic! - Introduce bypassActivationConstraint() option for PointerSensor, MouseSensor and TouchSensor. This optional argument can be used to conditionally bypass activation constraints. An example use-case would be to bypass activation constraints when the activator event target is the activatorNode of a draggable source.

    useSensor(PointerSensor, {
      activationConstraint: {
        delay: 250,
        tolerance: 5,
      },
      bypassActivationConstraint({event, activeNode}) {
        return activeNode.activatorNode.current?.contains(event.target);
      },
    });
  • #1269 b417f0f Thanks @clauderic! - Allow delay and distance activation constraints to be used concurrently for MouseSensor, TouchSensor and PointerSensor.

Patch Changes

  • Updated dependencies [aabb8bd, f342d5e]:
    • @dnd-kit/accessibility@3.1.0
    • @dnd-kit/utilities@3.2.2

Don't miss a new dnd-kit release

NewReleases is sending notifications on new releases.