Jump to content

Skin talk:Citizen

Add topic
From mediawiki.org
Latest comment: 2 months ago by Fallbackintoreality in topic Redirects don't show properly in an inline link

Bugfix for Version 2.40.2

[edit]

"version": "2.40.2"; "MediaWiki": ">= 1.39.4"; "File": includes/Hooks/SkinHooks.php; "Line": 464

	private static function addIconsToMenuItems( &$links, $menu ) {
		// Loop through each menu to check/append its link classes.
		foreach ( $links[$menu] as $key => $item ) {
			[...]
		}
	}

Add a line, because $links[$menu] can be Boolean:

	private static function addIconsToMenuItems( &$links, $menu ) {
		if ( is_bool( $links[$menu] ) ) return; // <==== Add this line! <====
		// Loop through each menu to check/append its link classes.
		foreach ( $links[$menu] as $key => $item ) {
			[...]
		}
	}

WikiForMen (talk) 23:30, 6 January 2025 (UTC)Reply

Set Headers to Collapsed on Desktop

[edit]

On the desktop version, Headers are set as collapsible, but you need to click them.

On the mobile version, Heads are collapsed by default, and you click them to open them.

Is it possible to set this behaviour on Desktop? Like for specific headers? 144.6.223.215 07:45, 2 April 2025 (UTC)Reply

I'm using the latest Citizen code with MW1.43 and it works the same for mobile and desktop - section headers are collapsible but not collapsed, which is good. Jonathan3 (talk) 21:33, 22 January 2026 (UTC)Reply

[SOLVED] Responsive grid?

[edit]

What's the best/recommended way to replicate the responsive "grid" that's found in skins like Foreground and Chameleon, or at least achieve a similar result? I just want do do simple things like stack columns on smaller screens, nothing fancy. Thank you. Jonathan3 (talk) 14:53, 7 January 2026 (UTC)Reply

There didn't seem to be anything built-in with this skin, so I just used CSS for this. Jonathan3 (talk) 09:40, 12 January 2026 (UTC)Reply

Header on top of mobile screen?

[edit]

Is there an equivalent of $wgCitizenHeaderPosition (Position of the header on the desktop layout) for mobile? I'd like to have it at the top on desktop and mobile. Thank you for an excellent skin. Jonathan3 (talk) 15:26, 7 January 2026 (UTC)Reply

I've mentioned this here: https://github.com/StarCitizenTools/mediawiki-skins-Citizen/discussions/1263. Jonathan3 (talk) 21:38, 22 January 2026 (UTC)Reply

[SOLVED] Struggling customising colours

[edit]

I've read through https://starcitizentools.github.io/mediawiki-skins-Citizen/customization/theming but am still struggling.

Let's say that in light mode I'd like the body background to be white, and the citizen-header and citizen-footer to be black (with white text/icons). How would I go about changing this? Thanks. Jonathan3 (talk) 23:15, 7 January 2026 (UTC)Reply

I've worked out how to do that specific thing (using CSS) so maybe its just a question of perseverance. I think I just need to learn about the colour system and CSS variables. Jonathan3 (talk) 13:23, 8 January 2026 (UTC)Reply

Command palette icons display oddly

[edit]

The "pencil" icon, for the edit link, is superimposed on the box that says "Page". Maybe it is meant to appear beside the word "Page". Can anyone advise? You can see it on most of the showcased wikis. Thanks. Jonathan3 (talk) 12:13, 12 January 2026 (UTC)Reply

I mentioned this at: https://github.com/StarCitizenTools/mediawiki-skins-Citizen/discussions/1264. Jonathan3 (talk) 21:42, 22 January 2026 (UTC)Reply

The heading in Cargo's Special:Drilldown page disappears

[edit]

The main heading on this page flashes up on page load but is then hidden. Headings on other pages work fine. This page works fine on other skins. I wonder what's causing this. Thanks. Jonathan3 (talk) 00:01, 15 January 2026 (UTC)Reply

Just noticed that it jumps to the bottom of the page! Jonathan3 (talk) 00:03, 15 January 2026 (UTC)Reply
I've mentioned this here: https://github.com/StarCitizenTools/mediawiki-skins-Citizen/issues/1265. Jonathan3 (talk) 21:48, 22 January 2026 (UTC)Reply

cargoTable doesn't scroll sideways the same as wikitable

[edit]

I've noticed that tables on Special:Drilldown don't scroll. Normal wikitables do. What can I add to MediaWiki:Citizen.css to fix this? Thanks. Jonathan3 (talk) 00:28, 15 January 2026 (UTC)Reply

I mentioned this here: https://github.com/StarCitizenTools/mediawiki-skins-Citizen/discussions/1266. Jonathan3 (talk) 21:52, 22 January 2026 (UTC)Reply

"Standard" width for Special pages is wider

[edit]

How could I make the width of special pages be the same as for content pages? Thanks. Jonathan3 (talk) 00:53, 15 January 2026 (UTC)Reply

I've mentioned this here: https://github.com/StarCitizenTools/mediawiki-skins-Citizen/discussions/1267. Jonathan3 (talk) 21:55, 22 January 2026 (UTC)Reply

Citizen default theme to dark creates issue with Vector 2022 skin

[edit]

Using the latest version of the Citizen and Vector skins. Our wiki sites are set to use Vector 2022 as the default skin.

Using 1.43.5 version of Mediawiki.

We had this setting in our LocalSettings.php file for the Citizen skin:


wfLoadSkin( 'Citizen' );

$wgCitizenThemeDefault = 'dark';


Unfortunately this caused the Preferences page (with only the Vector 2022 skin) to use dark mode, even if the user was using Vector 2022 skin on light mode.

Commenting out the $wgCitizenThemeDefault = 'dark'; fixed this issue. The Preferences page now shows as light mode when the user has the Vector 2022 theme set to light mode. But why would the Citizen skin interfere with the Vector 2022 skin? Jbubz (talk) 20:44, 24 February 2026 (UTC)Reply

Headings within collapsibles mess up the TOC position indicator

[edit]

Whenever a heading (including subheadings) is inside of a collapsed mw-collapsible element, the TOC position indicator no longer behaves normally. It ends up indicating that you are currently at the collapsed section, apart from intermittent moments on scrolling where it switches to the correct section. The problem disappears when the sections uncollapsed and the headings exposed, so this seems to suggest to me that it has something to do with the hidden="until-found" that is applied to class="mw-collapsible-content".

The practical relevance of this issue is that some spoiler templates use collapsibles to hide spoiler content, so if the spoiler content is particularly large this will interfere with the TOC. The same issue also appears if the spoiler hiding is based on display:none. GuppyForce (talk) 02:53, 13 March 2026 (UTC)Reply

[edit]

A weird quirk I've found from this skin is that when you link to a redirect, the link changes not to the redirect but rather its target!

For example: I want to link to Bar through the redirect Foo, but instead of showing "Foo" in the line, it automatically displays "Bar" as the display link.

In practice, it also shows "(Redirected from Bar)" which is the target and not the redirect itself. That's wrong.

What part in the JavaScript of this skin is causing this? I am using Miraheze. Fallbackintoreality (talk) 02:02, 21 May 2026 (UTC)Reply