shakacode / shakacode/rescript-dnd
Can't set "cursor" CSS property on DraggableItem
Nobody has claimed this yet.
- Dominant language
- ReScript
- Stars
- 119
- Forks
- 14
- PR merge metrics
- No merged PRs in 30d
Description
I wanted to update the cursor for my Draggable Items to be grab and then grabbing while dragging, but it wasn't working. In doing some digging, I've found that adding pointer-events: none disables the use cursor (yay CSS 🙄).
I definitely understand the reasoning behind setting pointer-events: none, but I wonder if there'd be way to set it on the underlying child of DraggableItem instead of that <div/> itself, so you could still set the cursor prop of the div? 🤔
There may not be an easy/workable fix here, but I figured I'd file it anyway just to see if you had any ideas. Thanks!
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by locating the DraggableItem entry point and reproducing the interaction between its pointer-events styling and the cursor prop. Done means callers can use grab and grabbing cursor values while dragging still works as intended.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- css, react
- Domain
- frontend
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100