Closed Bug 1550728 Opened 7 months ago Closed 7 months ago

Native drag & drop ghost not shown if combined with display: grid and display: contents


(Firefox :: Untriaged, defect)

66 Branch
Not set





(Reporter: adamlynch010, Unassigned)


User Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10.14; rv:66.0) Gecko/20100101 Firefox/66.0

Steps to reproduce:


Try to drag the item to the other box.

Actual results:

You don't see the native "ghost" element while it's being dragged. If you drop it in the box, that works fine. The rest works as expected.

Expected results:

The native "ghost" element should have been visible while dragging.

My CodePen was forked from (which I found in This works as expected.

What I changed in my version:

  • Added a div.wrapper element around div.item
  • Added display: grid to
  • I changed the ondrop callback to append the element into div.wrapper instead of div.wrapper

It seems to fail only when inside a element with display: contents which is inside an element with display: grid.

If either display rule is commented out, it works as expected.

It also works in other browsers I've tested. I'm on Mac OS X 10.14.4 if that helps.

The issue is reproducible on Firefox 66.0.5 but I couldn't reproduce the issue on the latest Firefox Nightly 68.0a1 or on Firefox 67.0b19.

Could you please try to see if the issue is reproducible on the latest Firefox Nightly? You can download it from here:


Flags: needinfo?(adamlynch010)
OS: Unspecified → macOS
Hardware: Unspecified → x86_64

Reproducible on Linux.

mozregression -b 66 --find-fix --arg

15:45.63 INFO: No more inbound revisions, bisection finished.
15:45.64 INFO: First good revision: e5e2e0d4eb054eb3b88748e5ef9dfadc7d2f2697
15:45.64 INFO: Last bad revision: b9b0378c5e0bd749b7904c2a5ccca74c9683bf42
15:45.64 INFO: Pushlog:

Olli Pettay — Bug 1265104, paint dnd'ed content also when it is under non-displayed content (display: contents or ShadowRoot), r=emilio

Closed: 7 months ago
Flags: needinfo?(adamlynch010)
OS: macOS → All
Hardware: x86_64 → Desktop
Resolution: --- → DUPLICATE
Duplicate of bug: 1265104

@hani it seems fixed in Nightly 69.0a1

You need to log in before you can comment on or make changes to this bug.