Page Menu
Home
WickedGov Phorge
Search
Configure Global Search
Log In
Files
F6124528
Theme.php
No One
Temporary
Actions
Download File
Edit File
Delete File
View Transforms
Subscribe
Flag For Later
Award Token
Size
724 B
Referenced Files
None
Subscribers
None
Theme.php
View Options
<?php
declare
(
strict_types
=
1
);
namespace
MediaWiki\Skins\Citizen\Partials
;
const
CLIENTPREFS_THEME_MAP
=
[
'auto'
=>
'os'
,
'light'
=>
'day'
,
'dark'
=>
'night'
];
/**
* Theme switcher partial of Skin Citizen
*/
final
class
Theme
extends
Partial
{
/**
* Sets the corresponding theme class on the <html> element
* If the theme is set to auto, the theme switcher script will be added
*/
public
function
setSkinTheme
():
void
{
// Set theme to site theme
$theme
=
$this
->
getConfigValue
(
'CitizenThemeDefault'
)
??
'auto'
;
// Add HTML class based on theme set
if
(
CLIENTPREFS_THEME_MAP
[
$theme
]
)
{
$this
->
out
->
addHtmlClasses
(
'skin-theme-clientpref-'
.
CLIENTPREFS_THEME_MAP
[
$theme
]
);
}
}
}
File Metadata
Details
Attached
Mime Type
text/x-php
Expires
Oct 7 2026, 08:15 (6 w, 3 d ago)
Storage Engine
local-disk
Storage Format
Raw Data
Storage Handle
a4/f0/65e55ba0ea014ce42a8985f9d6c0
Default Alt Text
Theme.php (724 B)
Attached To
Mode
rMWPROD MediaWiki Production
Attached
Detach File
Event Timeline
Log In to Comment