Skip to content

Prevent dragging to an area in dragula container? #696

Description

@WriterStat

Hi All! Thanks for a great kit! And all the hard work.

We have a lib we are using from a third party that in turn uses dragula like many do.

Is it possible... to prevent dragging to an area in a dragula container?

Example: We want to have label divs in our dragula container. It all works great! We prepend/put a label div in the dragula container and we are able to drag both above and below it.

But we'd like the top label div to always stay on top, not allow items to be dragged above it. Is there any way to pin to top? Disallow any dragging above an item/top item?

Note: Clicking these label divs above in our code hide the dragula items below them. Re-clicking them allows them to show.

Thanks! Any workarounds/thoughts appreciated. We need to use one container. so moving the label divs outside or using multiple container divs outside, won't work for us.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions