Page MenuHomePhabricator

TemplateStyles not applied in editnotice
Closed, InvalidPublic

Description

I have just noticed this recently, since very few meta templates on deWP are using TemplateStyles yet, but apparently TemplateStyles are not loaded in the editnotice, neither in the New Wikitext Mode (shown in the drop-down), nor in the old editor (shown above the editing window). Obviously, editnotices may contain templates, and if those templates depend on TemplateStyles, they need to be loaded, otherwise the editnotices are not shown to the editors the way they are intended to. I would have guessed the problem relates to T212085, but it also happens in the old editor, so this must be a general issue with how the editnotice is handled.

Event Timeline

@XanonymusX Could you please cite a specific example? I’m pretty sure the issue is not that TemplateStyles isn’t loaded, but that it doesn’t apply (the edit notice doesn’t get the mw-parser-output class).

Ah, that would make sense, yes! But as long as edit notices may contain templates, TemplateStyles must be applied there as well.

A concrete example would be my user talk page on deWP: its editnotice contains the user talk page template, which uses TemplateStyles. In the editnotice, borders, background and floating of the text blocks, as defined in the stylesheet, are missing.

XanonymusX renamed this task from TemplateStyles not loaded in editnotice to TemplateStyles not applied in editnotice.Mar 24 2020, 1:19 AM

This case is mentioned in https://www.mediawiki.org/wiki/Extension:TemplateStyles#Caveats. It suggests that the users should apply the appropriate class to places where TemplateStyles can really come up (e.g. MediaWiki:editnotice-3).

Oh, I see, that works, yeah! If that is the preferred solution, I guess it won't be necessary to keep this task open. Thanks for the explanation!

Added the instructions to Help:TemplateStyles, hopefully they will be more discoverable there.