[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Page MenuHomePhabricator

Some links to mentioned usernames get overlined instead of underlined when hovered with DiscussionTools using Chrome
Closed, ResolvedPublic

Description

Some links to mentioned usernames get overlined instead of underlined when hovered with DiscussionTools. Originally reported here: https://en.wikipedia.org/wiki/Wikipedia:Village_pump_(technical)#c-Klein_Muçi-20220902145700-Wikilink_overlined_(?!)

image.png (218×1 px, 67 KB)

This is a Chromium bug: https://bugs.chromium.org/p/chromium/issues/detail?id=1359501 but we should probably add a workaround until it's fixed.

Event Timeline

This happens when the first word in the comment is a link. The comment start marker gets placed inside the link and with its negative margin triggers the browser bug. We could consider moving the start marker outside the link, although we would probably need to be careful no to the move the start marker outside of block tags.

We adjust the marker position with position: relative; top: -1em, I thought we could try position: absolute; margin-top: -1em instead, which doesn't seem to trigger the bug.

I spent a few minutes puzzling over this last night. The class only being applied to the first link and only when a timestamp is present made it extra enjoyable to debug.

Change 832155 had a related patch set uploaded (by Esanders; author: Esanders):

[mediawiki/extensions/DiscussionTools@master] Use margin to position comment marker to avoid Chrome bug

https://gerrit.wikimedia.org/r/832155

This looks good.

Screenshot 2022-09-19 at 07.04.29.png (155×1 px, 40 KB)

I don't see a merge comment from gerritbot. @DLynch, kindly confirm that I can verify the task irrespective.

Change 832155 merged by jenkins-bot:

[mediawiki/extensions/DiscussionTools@master] Use margin to position comment marker to avoid Chrome bug

https://gerrit.wikimedia.org/r/832155

@EAkinloose The merge was caught up on all the DiscussionTools tests being broken by a recent VE change. Thanks to Bartosz for remembering to poke this patch now that's fixed.

ppelberg claimed this task.