Page MenuHomePhabricator

Request addition of a '.navbox' CSS class.
Closed, DeclinedPublic


Author: grendelkhan

The 'toccolours' CSS class, as it stands, doesn't fully format the table it's a
part of. This requires markup in the tables, which is suboptimal.

I propose the addition of the following to skins/common/common.css:

.toccolours th {

This is in concurrence with the standard Wikipedia style for navboxes. (See
[[en:Template:OSIModel]], [[en:Template:Gastroenterology]] and so forth.) This
will allow navboxes to be custom-styled along with the rest of the site, as well
as making it considerably easier to write a properly-styled navbox.

Version: unspecified
Severity: enhancement



Event Timeline

bzimport raised the priority of this task from to Lowest.Nov 21 2014, 8:14 PM
bzimport set Reference to bz1707.
bzimport added a subscriber: Unknown Object (MLST).

grendelkhan wrote:

It's tempting to add

.toccolours td {

but the merits are debatable. On the one hand, the vast majority of navboxes
shrink their contents so that they can fit more in. But on the other hand,
double-smalling the contents would make them illegibly tiny until someone went
through and fixed them all.

On the other hand, doing a

.toccolours {

.toccolours th {

would allow the user to easily override the table style in instances where small
contents are not in order ({| class="toccolours" style="font-size:normal"). The
small-text problem from above remains, but this would make the shrunken text
inside at least be the default. If there were a way to prevent double-shrinking,
that would be ideal.

grendelkhan wrote:

Diff to implement the conservative set of features in common.css.

This is a patch to be applied to common.css to implement the first, more
conservative version of this change.

attachment common.css.diff ignored as obsolete

grendelkhan wrote:

After discussion on [[WP:VP]] (proposals), I've decided to change the request to
ask for a new class entirely, instead of overloading the .toccolours class to do
things it was not originally intended for.

I would like the addition of a .navbox CSS class. In addition to being named for
what it would be used for, the automatic use of small fonts for the inside of
the navbox could be implemented, since the new class would only be used as the
navbox templates were rewritten. A new diff is being attached.

grendelkhan wrote:

Diff to create new .navbox CSS class.


zigger wrote:

Has this been superseded by the changes to the 1.5 navigation lists?

zigger wrote:

(In reply to comment #5)

Has this been superseded by the changes to the 1.5 navigation lists?

In answer to myself: No. Navboxes are not navigation lists.

Shouldn't this be in the local site css in the wiki?

robchur wrote:

Agreed; this can be changed depending upon the needs of the wiki itself, via
[[MediaWiki:monobook.css]], [[MediaWiki:classic.css]] et al. Marking WONTFIX.