Page MenuHomePhabricator

Banner content code reuse is lower than it should be
Closed, ResolvedPublic

Description

This is a bit unfair to file as a bug... but the way CN is used, large blocks of style and other elements are copied between banners. For many reasons, all this stuff should be saved in a template and only the things which are actually changed should be in each banner text.

Looking through meta CN, I think I've identified an obstacle, and addressed with commit https://gerrit.wikimedia.org/r/28913 -- I found that the common elements never (?) included "message fields", possibly because of a quirk in the translation interface, possibly due to misunderstanding.

The message fields serve as named template parameters, basically. We should be able to get a lot more use out of this mechanism before resorting to copy n paste.


Version: unspecified
Severity: major

Details

Reference
bz41259

Event Timeline

bzimport raised the priority of this task from to Medium.Nov 22 2014, 1:06 AM
bzimport set Reference to bz41259.
bzimport added a subscriber: Unknown Object (MLST).

We've deployed another feature which should help with the code reuse issue:
https://www.mediawiki.org/wiki/Extension:CentralNotice/Banner_mixins

Krinkle set Security to None.
Krinkle removed a subscriber: Unknown Object (MLST).
atgo claimed this task.
atgo subscribed.

I'm closing this because, as you say, it's a bit unfair to file as a bug :)

We're working towards this with other things like mixins, which should cover us.

awight changed the task status from Declined to Resolved.Feb 27 2015, 7:12 AM

Agreed--not that it matters, but I'm closing as "resolved" instead, I just want to make it clear that https://gerrit.wikimedia.org/r/#/c/28913/ and the mixin feature are motivated by this issue.