Interface IUseDraggerDirectionProps

Hierarchy

  • Pick<NDraggerDirection.IStaticProps, "minLength">
  • Pick<NDraggerDirection.IChangeableProps, "isEnabled">
    • IUseDraggerDirectionProps

Properties

isEnabled?: boolean

Determines if dragging is enabled for the dragger. When set to false, dragging is disabled.

Default

true
minLength?: number

The minimum length (in pixels) required for a swipe to be considered valid and trigger direction events. If the drag distance is less than this value, no directional callback will be triggered.

Default

75
onAny?: ((direction) => void)

Type declaration

    • (direction): void
    • Callback event triggered on any swipe

      Parameters

      • direction: "left" | "right" | "up" | "down"

      Returns void

onDown?: (() => void)

Type declaration

    • (): void
    • Callback event triggered on down swipe

      Returns void

onLeft?: (() => void)

Type declaration

    • (): void
    • Callback event triggered on left swipe

      Returns void

onRight?: (() => void)

Type declaration

    • (): void
    • Callback event triggered on right swipe

      Returns void

onUp?: (() => void)

Type declaration

    • (): void
    • Callback event triggered on up swipe

      Returns void

ref: RefObject<HTMLElement>

Reference to the container element for dragging gestures