Page MenuHomePhabricator

Drop "position: absolute" on p-logo element
Open, MediumPublic

Description

The #mw-panel (sidebar) is at top: 160px
The logo is at top: -160px
This looks hacky so I set it to 0

Event Timeline

Change 364028 had a related patch set uploaded (by Golopotw; owner: Golopotw):
[mediawiki/skins/Vector@master] Drop position:absolute of logo.

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

Golopotw renamed this task from Logo icon: replace position:absolute with normal css box flow. to Drop position:absolute of logo.Jul 8 2017, 6:07 PM
Krinkle renamed this task from Drop position:absolute of logo to Drop "position: absolute" on p-logo element.Jul 13 2017, 4:40 AM
Krinkle assigned this task to Golopotw.
Krinkle triaged this task as Medium priority.
Krinkle added a project: Technical-Debt.
Krinkle added a project: MonoBook.

Change 364934 had a related patch set uploaded (by Krinkle; owner: Krinkle):
[mediawiki/skins/MonoBook@master] Remove "position: absolute" and z-index from #p-logo

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

Tested applied styles in IE 7 (identical rendering to before):

image.png (1×1 px, 947 KB)

Change 364028 merged by jenkins-bot:
[mediawiki/skins/Vector@master] Remove position: absolute from #p-logo element

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

Change 364934 merged by jenkins-bot:
[mediawiki/skins/MonoBook@master] Remove position: absolute and z-index from #p-logo

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

The z-index removal may have caused div#column-content to cover #p-logo.

Indeed. The margin-left for .mw-body on div#content.mw-body is reserving all transparent space on the left of the content area, thus preventing the logo from being a click target.

What I don't understand is... why does this only affects the logo anchor, and not the regular anchor links in the sidebar?

I've created an isolated test case here:
https://codepen.io/Krinkle/pen/pwMKVe?editors=1100

First idea without intense testing: Using position: relative; instead with z-index.

Indeed. This appears to fix it, but I don't quite know why.

In T170053#3457897, Legoktm wrote:

This was reverted in MonoBook, see T171195: Site logo is no longer clickable in monobook.

@Golopotw: Hi! This task has been assigned to you a while ago. Could you maybe share an update? Do you still plan to work on this task? Thanks! :)

@Aklapper: Hi! I think it will be better to reassign this ticket to another developer. Thanks for the invitation!