Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

zIndex 1000 - items not visible #86

Open
nbelyh-visualstrategy opened this issue Nov 17, 2020 · 3 comments
Open

zIndex 1000 - items not visible #86

nbelyh-visualstrategy opened this issue Nov 17, 2020 · 3 comments

Comments

@nbelyh-visualstrategy
Copy link

nbelyh-visualstrategy commented Nov 17, 2020

In my current application (using fluentui library), the zindex is 100000 (sidebar)
The smooth-dnd library sets it to 1000 (seems to be hardcoded), and therefore the dragged item becomes invisible.
Is it possible to change this value?

ghost.style.zIndex = '1000';
ghost.style.boxSizing = 'border-box';
ghost.style.position = 'fixed';

@nbelyh-visualstrategy
Copy link
Author

Need more investigation, maybe not actually the case

@nbelyh-visualstrategy
Copy link
Author

The issue seems to exist anyways. Would be great to be able to specify zIndex (can be required also for some other third-party libraries, not only fluentUI). Check out similar issue (bootstrap modal, material ui):
clauderic/react-sortable-hoc#87

@Mylogo
Copy link

Mylogo commented Jan 6, 2021

Had the exact same issue today. My workaround was to use CSS as every draggable has the class smooth-dnd-ghost.
So in your CSS, just add:

.smooth-dnd-ghost {
  z-index: 999999 !important;
}

Doesn't feel nice, but did the trick for me.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants