Closed Bug 1522319 Opened 7 years ago Closed 7 years ago

translateZ(0) affects the scrollability of a menu on zalando.fr

Categories

(Core :: Layout, defect, P3)

66 Branch
Unspecified
Android
defect

Tracking

()

RESOLVED WORKSFORME
Webcompat Priority ?
Tracking Status
firefox66 --- affected

People

(Reporter: karlcow, Unassigned, NeedInfo)

References

()

Details

(Whiteboard: [webcompat])

This is a spin-off of https://webcompat.com/issues/22453

  1. with a tablet on Firefox Android or
    a mobile device in landscape mode.
  2. Access https://www.zalando.fr/boots-chaussure-montante-homme/?p=2
  3. Try to type "taille" or "marque" (an overlay menu appears)
  4. Try to scroll the list.

Actual:
The list doesn't scroll

Expected:
The list is scrolling.

The developers are blocking the scrolling of the body on this page with a common technique.

The body is already with overflow: auto;

<body style="
	margin-right: 0px;
	overflow: auto;">

This specific menu is rendered with

        {
          key: 'render',
          value: function () {
            var e = this,
            t = this.props,
            n = t.styles,
            r = t.children,
            o = t.enable;
            return i.default.createElement('div', {
              onMouseOver: function () {
                'boolean' != typeof o && e.disableBodyScroll()
              },
              onMouseOut: function (t) {
                'boolean' == typeof o || t.currentTarget.contains(t.relatedTarget) || e.enableBodyScroll()
              },
              className: n
            }, r)
          }
        }

which refers to

n.disableBodyScroll = function () {
          var e = window.document.body,
          t = window.innerWidth - e.clientWidth;
          e.style.marginRight = t + 'px',
          e.style.overflow = 'hidden'
        },
        n.enableBodyScroll = function () {
          var e = window.document.body;
          e.style.marginRight = '0px',
          e.style.overflow = 'auto'
        },
        n.checkScroll(n.props.enable),
        n

so indeed it sets onMouseOver, window.document.body.style.overflow = 'hidden'.

BUT something strange is happening.

Removing transform: translateZ(0); fixes the behavior. (fyi @emilio )

.cat_itemList-sgr85 {
	overflow-y: auto;
	overflow-x: hidden;
	min-height: 180px;
	max-height: 300px;
	height: 40vh;
	margin-right: 12px;
	color: #1a1a1a;
	/* transform: translateZ(0); */
}

reactivating it blocks the scrolling. This is reproducible.

Flags: webcompat?

I can't reproduce it on my Android phone on landscape mode with Firefox Beta. Did the website fix this or something changed recently?

It would be great if there can be a minimal testcase to help reproducing it.

Karl, do you have an archived versions of the site? (I've never tried to see the site)

Flags: needinfo?(kdubost)

Oh I actually tried once before. :)

Flags: needinfo?(kdubost) → needinfo?(hikezoe)

Migrating Webcompat whiteboard priorities to project flags. See bug 1547409.

Webcompat Priority: --- → ?

See bug 1547409. Migrating whiteboard priority tags to program flags.

This seems to be working now in Fennec Nightly and Fenix Preview. Thanks.

Status: NEW → RESOLVED
Closed: 7 years ago
Resolution: --- → WORKSFORME
You need to log in before you can comment on or make changes to this bug.