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

Categories

(Firefox :: Untriaged, defect)

66 Branch
Desktop
All
defect
Not set

Tracking

()

RESOLVED DUPLICATE of bug 1265104

People

(Reporter: adamlynch010, Unassigned)

Details

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

Steps to reproduce:

See https://codepen.io/adam-lynch/pen/mYPBOb.

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 https://codepen.io/davilera/pen/wpwrNW (which I found in https://neliosoftware.com/blog/native-drag-and-drop-with-html5/). This works as expected.

What I changed in my version:

  • Added a div.wrapper element around div.item
  • Added display: grid to div.day
  • I changed the ondrop callback to append the element into div.day 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: https://nightly.mozilla.org/

Thanks.

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

Reproducible on Linux.

mozregression -b 66 --find-fix --arg https://codepen.io/adam-lynch/pen/mYPBOb

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:
https://hg.mozilla.org/integration/autoland/pushloghtml?fromchange=b9b0378c5e0bd749b7904c2a5ccca74c9683bf42&tochange=e5e2e0d4eb054eb3b88748e5ef9dfadc7d2f2697

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

Status: UNCONFIRMED → RESOLVED
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.