Comments (7)
CodePen would be nice. But basically: when dragging, your stuff is removed from its container, and appended to document.body
. So any styles your element inherited from its parent, or any styles affected by siblings of your element, are gone now. Take that into account when adjusting the styles for your drag shadow.
from dragula.
Lines 116 to 130 in 4d2c87b
from dragula.
Made a codepen but it doesn't seem to do the same.
In the codepen it hides the internal objects or something like that.
See for yourself over here:
http://codepen.io/johman10/pen/XbdNoo
Hope it shows the problem.
I'm think it has something to do with scss nesting... could that be it?
from dragula.
All your styles inherit from .options_menu
. The options_menu
class is nowhere in the dragged element.
from dragula.
Wow! That was pretty stupid! Should have seen that myself!
Thanks for you help and thanks for Dragula! Gotta love it!
from dragula.
Also fixed the example in the demo page for reference
from dragula.
Hi, a somewhat related question.
How do I change the cursor from grab
to grabbing
while dragging?
I've tried adding cursor: grabbing
to both .gu-mirror
and .gu-unselectable
(which are the ones that seem to be related), but neither one is working.
This is in Svelte:
.drgwrapper :is(:global(.gu-unselectable), :global(.gu-mirror)) {
cursor: grabbing;
}
I've also changed them inside /node_modules/dragula/dist/dragula.css
(and restarted bundler), still without success.
I'm using Chrome.
from dragula.
Related Issues (20)
- revertOnSpill mirror does not work correctly for last element in a container HOT 1
- Is there a maintained fork? HOT 1
- cancel event does not fired when copy: true HOT 1
- The slack link on your site points to a new heroku instance
- example.js and example.min.js do not match
- Is your project still maintained? HOT 9
- Option to disable drag shadow
- Drag and Drop not working in Bootstrap Tabs
- Angular 13 - Library Warning - depends on 'dragula'. CommonJS or AMD dependencies can cause optimization bailouts.
- Prevent dragging to an area in dragula container? HOT 1
- How get access to the https://dragula.slack.com/ How get an invite?
- Idea: Possibility to access initialSibling from outside the dragula function.
- Horizontal sorting is buggy in RTL and flex-direction: row-reverse containers HOT 1
- How to specify the HTML of a dropped element?
- New slack user request
- Delay redraw until drop. HOT 1
- tow questions and a bug report
- Is there a way to remove the event listening ?
- Clicking a select in a draggable item still drags the item on Firefox HOT 2
- Dragging outside the boundary causes error accessing attribute on a null object
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from dragula.