Page MenuHomePhabricator

TemplateStyles not setting display:none for <link> tags on Edge
Closed, InvalidPublic

Description

When a template uses TemplateStyles in its code, every <link> tag automatically created by the extension will have the same dimensions as the <div> tags, creating invisible “boxes” between divs. This can be fixed by setting display to none. This seems to happen only on Microsoft Edge.

Steps to reproduce:

  1. Open Microsoft Edge.
    1. With Edge 42 (42.17134.1.0), navigate to this page. This is what you'll see:
      image.png (600×740 px, 179 KB)
    2. Open up Developer Tools and activate the hovering function. You can see that the invisible “boxes” were rendered after the <link> tags.
    3. Select any of them and set display:none as a new CSS rule. The invisible boxes are now gone.
  2. Repeat step 1A with Chrome. The boxes are now correctly aligned:
    image.png (768×1 px, 132 KB)

This bug was found in this topic.

Event Timeline

Link tags aren't supposed to display anything in the first place. Seems like Edge is doing something weird.

Can't reproduce (Edge 44.17763.1.0 / EdgeHTML 18.17763 / Win 10) and it would be a strange thing for Edge to do. Can you test logged out, in InPrivate mode?

Can't reproduce (Edge 44.17763.1.0 / EdgeHTML 18.17763 / Win 10) and it would be a strange thing for Edge to do. Can you test logged out, in InPrivate mode?

Happens in InPrivate mode too. My computer is still running Edge 42.17134.1.0 / EdgeHTML 17.17134, so there's a chance that this was fixed in the October Update.

Anomie pointed me here from this en.wp topic. I think this one might be the bug causing the issue described there. It affects IE11 as well, though I haven't personally tested that case. However, I tried to set display: none in that case and what I got was the li bullet styles disappearing in Edge instead of the link element.

Woops, this was a false alarm for me (in the sense that my bug I do not think is this bug's bug). The template in question is outputting an empty div (besides some inner elements, which themselves contain no content) that Edge/IE treat as an interesting div and consequently assigning that div height. It doesn't seem to be an issue if the div gets some css (display none or float right).

I'll be moving along. ~

Krinkle subscribed.

Thanks, glad it was figured out. Do re-open if you find anything else :)

Not sure this should be closed; the bug in the description is not mine nor was my fix going to resolve the above.

Closing as "Invalid" sounds good to me, since the bug is IE Edge rendering a block for tags that aren't supposed to render anything. And may have been fixed in Edge somewhere between Edge 42 and Edge 44.

But I'll leave it to others to decide whether we want to keep it open as a "do weird stuff to work around an IE Edge bug".

TheDJ subscribed.

no further reports, so lets close.