chameleon icon indicating copy to clipboard operation
chameleon copied to clipboard

Move MediaWiki edit confirmations below navbar

Open krabina opened this issue 3 years ago • 2 comments

When using chameleon, the MediaWiki edit confirmations "Your edit was saved" or "Page was created" are on the top of the page over the main navigation menu. This can be unfortunate, becaus you have to wait until it goes away to access a navigation menu.

I would like to find a way to display these messages where SiteNotices are displayed, My grid is:

<grid class="flex-fill" mode="fluid">
                <row>
                        <cell>
                                <component type="SiteNotice"/>
                                <component type="NewtalkNotifier" class="mb-3"/>
                                <component type="MainContent"/>
                        </cell>
                </row>
        </grid>

So I would like MediaWiki to display these messages in the SitNotice area or at least add a margin-top to these messages that is as large as the navigation menu.

Any way to do this?

krabina avatar Feb 19 '22 17:02 krabina

I don't see an immediately easy way to handle this on the Chameleon side. This is the generated HTML:

<div class="postedit-container">
  <div class="postedit mw-notification">
    <div class="postedit-icon postedit-icon-checkmark postedit-content">Your edit was saved.</div>
  </div>
</div>

However, this is generated by MediaWiki Javascript (mediawiki.action.view.postEdit.js), so in order to handle this differently would require rewriting some of that.

In terms of a local CSS workaround: Add top on the .postedit class, since that is what other skins do.

Vector: Screenshot_20220221_143425

Monobook: Screenshot_20220221_143212

malberts avatar Feb 21 '22 12:02 malberts

The local CSS workaround is great, thank you!

krabina avatar Mar 18 '22 21:03 krabina