solid-dnd icon indicating copy to clipboard operation
solid-dnd copied to clipboard

Example suggest add touch-action:none tips

Open ymzuiku opened this issue 3 years ago • 2 comments

Solid-dnd is great dnd package. I use https://solid-dnd.com/ example, but it can't drag in touch/mobile. Because i didn't know need add touch-action:none to Draggable Element. I use many hour until view your website class detail, i know i miss the touch-action:none.

Example suggest add touch-action:none tips, to help some people like me, like this:

const Droppable = (props) => {
  const droppable = createDroppable(1);
  return (
    <div
      use:droppable
      // if your need use touch event, you need add touch-action:none
      style={{"touch-action":"none"}}
    >
      Droppable.
      {props.children}
    </div>
  );
};

ymzuiku avatar Sep 20 '22 19:09 ymzuiku

Thanks for the kind words.

I think I need to invest in better docs now to cover things like these tips. Related issue https://github.com/thisbeyond/solid-dnd/issues/17

martinpengellyphillips avatar Sep 22 '22 07:09 martinpengellyphillips

@ymzuiku Thank you very much for this suggestion/solution; I also got stuck on this for touch/mobile dragging!

peterboyer avatar Jul 05 '23 14:07 peterboyer