Thanks for the link.
About wrapping unconditionally - well, I'd like to avoid it. I checked
over the codebase and for now it shouldn't be a problem, but who knows
what the future will bring :). (and BTW, adjacency rules like `.mbox +
.mbox` are more readable this way).
I've however prepared a general template like {{Activate
TemplateStyles|...}} so that all templates (not only mboxes) could
potentially benefit from that without the need to remember what's so
magical in a div. In the end, I've also created a separate
{{Editnotice}} template that wraps normal {{mbox}} and additionally
attaches some CSS that adapts the template to very narrow containers,
for instance in VE, and gets rid of a MobileFrontend magic (bleh...).
During the work with unifying all the mbox flavours (which finished like
a few days ago), it turned out that mw-parser-output, apart from
{{Editnotice}}, was needed on like 2 or 3 pages on plwiki which made my
apply the described approach. Initially I've thought that it'd be worse,
but – well – I discovered that legacy code in interface messages
preserves very well :)
Msz2001
W dniu 19.12.2024 o 21:30, Gergo Tisza pisze:
Having two templates is the nicer solution, but you could just wrap
them unconditionally - being wrapped twice shouldn't be a problem.
FWIW there is a task for wrapping edit notices:
https://phabricator.wikimedia.org/T337640
_______________________________________________
Wikitech-l mailing list -- wikitech-l@lists.wikimedia.org
To unsubscribe send an email to wikitech-l-le...@lists.wikimedia.org
https://lists.wikimedia.org/postorius/lists/wikitech-l.lists.wikimedia.org/
_______________________________________________
Wikitech-l mailing list -- wikitech-l@lists.wikimedia.org
To unsubscribe send an email to wikitech-l-le...@lists.wikimedia.org
https://lists.wikimedia.org/postorius/lists/wikitech-l.lists.wikimedia.org/