Common.css – MediaWiki

From Bohemia Interactive Community
Categories:
m (Fix toc rules)
m (Remove Navbar styles)
Line 729: Line 729:
}
}
.navbox .collapseButton { /* In navboxes, the show/hide button balances */
.navbox .collapseButton { /* In navboxes, the show/hide button balances */
width: 6em; /* the vde links from [[Template:Navbar]], */
width: 6em; /* the vde links from Navbar (removed on BIKI), */
} /* so they need to be the same width. */
} /* so they need to be the same width. */
.navbar { /* Navbox template links */
font-size: 88%; /* Default font-size */
font-weight: normal;
}
.navbox .navbar {
font-size: 100%; /* Font-size when nested within navbox */
}

Revision as of 07:06, 2 January 2021

/*****************************************************************************************
 * Any CSS here will be loaded for all users on every page load.
 *
 * As such, the content of this file page should be kept as minimal as possible.
 *
 *****************************************************************************************/

/*****************************************************************************************
 * Special styles for BIKI
 */

	/* global styles */

	#content a:link,
	#content a:visited {
		color: #0645AD;
	}
	#content a:hover:link,
	#content a:hover:visited,
	#content a:focus:link,
	#content a:focus:visited {
		color: #06C;
	}

	#content a.new:link,
	#content a.new:visited {
		color: #BA0000;
	}
	#content a.new:hover:link,
	#content a.new:hover:visited,
	#content a.new:focus:link,
	#content a.new:focus:visited {
		color: #B00;
	}

	#content a.oo-ui-buttonElement-button {
		color: #D33;
	}

	button::-moz-focus-inner {
		padding: 0;
	}
	div.editsection {
		margin-top: 2em;
	}
	h2 {
		margin-top: 1.5em;
	}
	h3 {
		margin-top: 1em;
	}
	h4 {
		font-size: 1.1em;
	}
	table h3 {
		margin-top: 0;
	}
	code,
	pre {
		margin: 0.5em 0 0.5em 0.5em;
		padding: 0.5em;
		background-color: #f9f9f9;
		border: 1px dashed #2f6fab;
		font-family: "Lucida Console", monospace;
		font-size: 0.9em;
		line-height: 1.4em;
		white-space: pre;
		overflow: auto;
	}
	/*Leave it compact on RecentChanges*/
	body:not(.mw-special-Recentchanges) code,pre {
		display:block;
	}
	tt {
		font-family: "Lucida Console", Consolas;
		background-color: ghostwhite;
		padding: 0.2em 0.3em;
		opacity: 0.9;
	}

	code,
	pre,
	#wpTextbox1 {
		tab-size: 4;
		-moz-tab-size: 4;
	}

	/* Hide subtitle and categories on Main Page*/

	.page-Main_Page #contentSub {
		display: none;
	}

	.page-Main_Page #catlinks {
		display: none;
	}

	.page-Main_Page #firstHeading {
		display: none;
	}

	/* span.keyboard for visual keyboard button emulation. Used by Template:Keyboard */

	span.keyboard {
		padding: 1px 4px;
		border: 2px outset #ccc;
		border-radius: 3px;
		background-color: #ddd;
		font-family: Consolas;
		color: #000;
		text-shadow: 1px 1px 0 #fff;
		font-weight: bold;
		white-space: nowrap;
		line-height: 2em;
	}

	table tr th.na-cell,
	table tr td.na-cell {
		background: #ececec;
		color: grey;
		font-size: 0.8em;
		text-align: center;
		vertical-align: middle;
	}

	/* wikitable class for skinning normal tables */

	table.wikitable {
		margin: 1em 1em 1em 0;
		background: #f9f9f9;
		border: 1px #aaa solid;
		border-collapse: collapse;
	}
	table.wikitable th, table.wikitable td {
		border: 1px #aaa solid;
		padding: 0.2em;
	}
	table.wikitable th {
		background: #f2f2f2;
		text-align: center; 
	}
	table.wikitable caption {
		margin-left: inherit;
		margin-right: inherit;
	}

	/* operator tables */

	table.operators {
		width: 500px;
		margin: 0 1em 1em 1em; 
		border: 1px solid #a3b0bf;
	}
	table.operators caption {
		margin-top: 1em;
		margin-bottom: 0.3em;
		color: #006;
	}
	table.operators th, table.operators td {
		padding: 2px 5px;
	}
	table.operators th {
		background-color: #cedff2;
	}
	table.operators td {
		background-color: #eee;
	}

	.toc {
		border-radius: 0.3rem;
	}

	/*
		[[Template:TOC]]
	*/
	.toc-abc {
		border: 1px solid #AAA;
	    display: flex;
		margin: 1em auto;
	    text-align: center;
    	max-width: 70em;
	}
	.toc-abc a {
    	flex-grow: 1;
		padding: 0.25em 0.5em;
	}

	.toc-horizontal {
		width: 100% !important;
		overflow: auto;
	}
	.toc-horizontal .toc ul li {
		display: inline-table;
		margin: 0;
	}
	.toc-horizontal .toc ul ul li {
		margin: 0 1em 0 0;
	}

	.toc-side {
		float: right;
		margin: 0 0 0.5em 1.5em;
		max-width: 25%;
	}

	.toc-nonum .tocnumber,
	.nonumtoc .tocnumber {
		display: none;
	}

	.toc-nonum .toc ul,
	.nonumtoc .toc ul {
		line-height: 1.5em;
		list-style: none;
		margin: .3em 0 0;
		padding: 0;
	}
	.toc-nonum .toc ul ul ,
	.nonumtoc .toc ul ul { 
		margin: 0 0 0 2em; 
	}

	/*
	* Allow limiting of which header levels are shown in a TOC;
	* <div class="toclimit-3">, for instance, will limit to
	* showing ==headings== and ===headings=== but no further
	* (as long as there are no =headings= on the page, which
	* there shouldn't be according to the MoS).
	*/

	.toclimit-2 .toclevel-1 ul,
	.toclimit-3 .toclevel-2 ul,
	.toclimit-4 .toclevel-3 ul,
	.toclimit-5 .toclevel-4 ul,
	.toclimit-6 .toclevel-5 ul,
	.toclimit-7 .toclevel-6 ul {
		display: none;
	}

	/* PRE tag without borders for Box_File template */

	.scroll pre {
		border: none;
		background-color: transparent;
	}

	/* Main Page floating boxes */

		/* Default base */

		div.floating-box {
			width: 300px;
			height: 200px;
			float: left;
			margin: 0 10px 10px 0;
			padding: 0 7px;
			border: 1px solid #ddd;
			color: #404040;
		}
		div.floating-box h2 {
			margin: 0.2em 0 0.2em 0;
		}
		div.floating-box p {
			margin: 0.2em;
		}
		div.floating-box dl {
			margin-top: 0;
		}
		div.floating-box dl dt {
			float: left;
		}
		div.floating-box dl dd {
			margin-left: 2.3em;
		}

	/**
	* Class handling presentation of game version image icons.
	* Use "Template:GVI" in conjunction.
	*/

	.gvi {
		display: inline-block;
		width: 30px;
		height: 30px;
		vertical-align: middle;
	}
	.gvi a {
		text-decoration: none;
	}
	.gvi a img {
		position: relative;
		z-index: 100;
		margin: unset;
	}
	.gvi span {
		position: absolute;
		min-width: 28px;
		height: 8px;
		padding: 1px;
		margin: 21px 0 0 -30px;
		line-height: 7px;
		background-color: #e0e0e0;
		font-family: Arial;
		font-size: 11px;
		font-weight: bold;
		color: #000;
		text-align: center;
		z-index: 99;
	}
	.gvi span.alpha {
		background-color: #adbf83;
	}
	.gvi span.beta {
		background-color: #8396bf;
	}
	.gvi span.release {
		background-color: #000;
		color: #fff;
	}

	/**
	* Class handling presentation of "Cfg* Config Reference" pages.
	* Use "Template:Cfg ref" in conjunction.
	*/

	.cfg_reference {
		width: 85%;
	}
	.cfg_reference h2 {
		font-size: 1.8em;
		font-weight: bold;
		color: #404040;
		margin-top: 1em;
		padding-top: 0;
		border: none;
	}
	.cfg_reference h3 {
		color: #404040;
		margin-top: 1em;
		padding-top: 0;
	}
	.cfg_reference p {
		margin-left: 1.2em;
	}
	.cfg_reference table {
		margin-left: 2em;
	}
	.cfg_reference img {
		margin: 0 0 10px 3px;
	}
	.cfg_reference span.mw-editsection {
		vertical-align: top;
	}
	.cfg_reference div.mw-geshi {
		margin: 1em 0 1em 2em;
		border: none;
		border-left: 1px solid #a0a0a0;
		background-color: #f4f4f4;
	}
	.cfg_reference div.abc {
		border-left: 25px solid #dfdfdf;
	}
	.cfg_reference div.abc h2 {
		background-color: #fff;
		margin-left: -25px;
		padding: 0.5em 0 0.5em 0.2em;
	}
	.cfg_reference div.abc h3 {
		float: left;
		width: 25px;
		margin: 0 0 0 -25px;
		padding-top: 0.3em;
		border: none;
		border-top: 1px solid #a0a0a0;
		font-size: 1.7em;
		font-weight: bold;
		color: #404040;
		text-align: center;
	}
	.cfg_reference div.abc h3 span.mw-editsection {
		display: none;
	}
	.cfg_reference div.abc h4,
	.cfg_reference div.abc h5 {
		background-color: #dfdfdf;
		background: -webkit-linear-gradient(90deg, #dfdfdf, rgba(223, 223, 223, 0));
		background: -o-linear-gradient(90deg, #dfdfdf, rgba(223, 223, 223, 0));
		background: -moz-linear-gradient(90deg, #dfdfdf, rgba(223, 223, 223, 0));
		background: linear-gradient(90deg, #dfdfdf, rgba(223, 223, 223, 0));
		padding: 0.3em 0.5em 0.1em 0.5em;
		border-top: 1px solid #a0a0a0;
		font-size: 1.3em;
		font-weight: normal;
		font-family: "Lucida Console", monospace;
		color: #404040;
	}
	.cfg_reference div.abc h4 span.mw-editsection,
	.cfg_reference div.abc h5 span.mw-editsection {
		vertical-align: middle;
		font-family: sans-serif;
		font-size: 70%;
		float: right;
	}
	.cfg_reference div.abc h4 span.mw-editsection span.mw-editsection-bracket,
	.cfg_reference div.abc h5 span.mw-editsection span.mw-editsection-bracket {
		display: none;
	}
	.cfg_reference div.abc h5 {
		margin-left: 0.6em;
		margin-right: 0.6em;
		font-size: 1.1em;
	}
	.cfg_reference div.abc h5 span.mw-editsection {
		font-size: 80%;
	}
	.cfg_reference div.abc h5 span.mw-editsection span.mw-editsection-bracket {
		display: none;
	}
	.cfg_reference div.abc dl {
		margin-left: 1.2em;
	}
	.cfg_reference div.abc dt {
		float: left;
		margin-right: 1em;
	}
	.cfg_reference div.abc dt:after {
		content: ":";
	}

	/**
	* Classes handling presentation of scripting Commands and Functions, and for Tools
	* Each controlled by their relative Template.
	*/

	._description {
		width: 85%;
	}
	._description h2 {
		font-size: 1.8em;
		font-weight: bold;
		border: none;
	}
	._description.cmd h2 {
		color: #6788c2;
	}
	._description.fnc h2 {
		color: #25a1a1;
	}
	._description.tool h2 {
		color: #62a762;
	}
	._description h3 {
		clear: both;
		margin: 0;
		padding: 0.3em 0.5em;
		font-size: 1.2em;
		font-weight: bold;
		border: 1px solid #ddd;
	}
	._description.cmd h3 {
		color: #6788c2;
		background-color: #e5eef8;
	}
	._description.fnc h3 {
		color: #25a1a1;
		background-color: #daf5f5;
	}
	._description.tool h3 {
		color: #62a762;
		background-color: #e9fae9;
	}

	._description .top-icons .gvi,
	._description .top-icons img {
		margin-right: 0.25em;
	}
	._description .top-icons .gvi img {
		margin-right: unset;
	}

	/* Same as h3 but used to hide h4 from table of content using toclimit template */
	._description h4 {
		clear: both;
		margin: 0;
		padding: 0.3em 0.5em;
		font-size: 1.2em;
		font-weight: bold;
		border: 1px solid #ddd;
	}
	._description.cmd h4 {
		color: #6788c2;
		background-color: #e5eef8;
	}
	._description.cmd pre,
	._description.cmd code {
		border-color: #6788c2;
		overflow: auto;
	}
	._description.fnc pre,
	._description.fnc code {
		border-color: #25a1a1;
		overflow: auto;
	}
	._description.tool pre,
	._description.tool code {
		border-color: #62a762;
		overflow: auto;
	}
	._description dt {
		width: 100px;
		float: left;
		clear: both;
		padding: 5px 5px 0 5px;
		font-weight: bold;
	}
	._description dd {
		margin: 0;
		padding: 5px 5px 5px 120px;
	}
	._description dd.param {
		padding-left: 140px;
		text-indent: -20px;
		background-color: #f8f8f8;
	}
	._description dd.param * {
		text-indent: 0;
	}

	._description dd.seealso {
		-webkit-column-count: 4;
		-moz-column-count: 4;
		column-count: 4;
		padding: 5px 0 0 10px;
	}
	._description dd.seealso a {
		display: block;
	}


	/* Legacy note handling for Command and Function pages */

	dl.command_description {
		width: 85%;
	}
	dl.command_description dt.note {
		width: 110px;
		float: left;
		padding: 5px;
		font-weight: bold;
	}
	dl.command_description dd.note {
		margin-left: 0;
		padding: 5px 5px 5px 120px;
		background-color: #e8e8e8;
	}
	dl.command_description dd.notedate {
		margin: 20px 0 0 0;
		padding: 2px;
		clear: both;
		font-size: 0.9em;
		text-align: right;
		border-bottom: 1px solid #ccc;
	}
	dl.command_description code{
		overflow: auto;
	}

/*

	TOP MENU

*/

.topmenu {
	box-shadow: 0 0 1em 0 rgba(0,0,0,0.25);
	display: flex;
	flex-wrap: wrap;
	font-size: 1.1em;
	margin: 0 auto 2em; /* 1em shadow + 1em */
	font-weight: bold;
	justify-content: center;
	line-height: 3em;
	text-align: center;
}
.topmenu a {
	flex-grow: 1;
	padding: 0.5em;
	white-space: nowrap;
}

/*

	MOBILES

*/

.messagebox {
	color: #FFF;
	display: flex;
	align-items: center;
	margin: 0.5em 0;
}

.messagebox > div:nth-child(1) {
	min-width: 28px;
	max-width: 60px;
	min-height: 28px;
	max-height: 44px;
	flex-shrink: 0;
	font-size: 28px;
	margin: 0 8px;
	overflow: hidden;
	text-align: center;
}

.messagebox > div:nth-child(2) {
	background-color: #FFF;
	color: #333;
	flex-grow: 1;
	height: 100%;
	margin: 0.25em 0.25em 0.25em 0;
	padding: 0.5em
}

@media screen and (orientation: portrait) {
	._description {
		width: 100%;
	}
	dl.command_description {
		width: 100%;
	}
}


/*****************************************************************************************
 * MediaWiki:Common.css copied from Wikipedia started here.
 * Most is now gone :-)
 */

	/* Reduce excess space between category links.
	Remove this when bug 31547 is resolved/deployed */

	#catlinks li {
		line-height: 1em;
		margin: 0.25em 0;
		padding: 0 0.5em;
	}
	#catlinks li:first-child {
		padding-left: 0.25em;
	}

	/* Edit window toolbar */

	#toolbar {
		height: 22px;
		margin-bottom: 6px;
	}

	/* Margins for <ol> and <ul> */

	div#content ol, div#content ul,
	div#mw_content ol, div#mw_content ul {
		margin-bottom: 0.5em;
	}

	/* Reduce line-height for <sup> and <sub> */

	sup, sub {
		line-height: 1em;
	}

/* Default skin for navigation boxes */
table.navbox {					/* Navbox container style */
	border: 1px solid #aaa;
	width: 100%; 
	margin: auto;
	clear: both;
	font-size: 88%;
	text-align: center;
	padding: 1px;
}
table.navbox + table.navbox {	/* Single pixel border between adjacent navboxes	*/
	margin-top: -1px;			/* (doesn't work for IE6, but that's okay)			*/
}
.navbox-title,
.navbox-abovebelow,
table.navbox th {
	text-align: center;		/* Title and above/below styles */
	padding-left: 1em;
	padding-right: 1em;
}
.navbox-group {				/* Group style */
	white-space: nowrap;
	/* @noflip */text-align: right;
	font-weight: bold;
	padding-left: 1em;
	padding-right: 1em;
}
.navbox, .navbox-subgroup {
	background: #fdfdfd;	/* Background color */
}
.navbox-list {
	border-color: #fdfdfd;	/* Must match background color */
}
.navbox-title,
table.navbox th {
	background: #ccccff;	/* Level 1 color */
}
.navbox-abovebelow,
.navbox-group,
.navbox-subgroup .navbox-title {
	background: #ddddff;	/* Level 2 color */
}
.navbox-subgroup .navbox-group, .navbox-subgroup .navbox-abovebelow {
	background: #e6e6ff;	/* Level 3 color */
}
.navbox-even {
	background: #f7f7f7;	/* Even row striping */
}
.navbox-odd {
	background: transparent; /* Odd row striping */
}
 
.collapseButton {				/* 'show'/'hide' buttons created dynamically	*/
	/* @noflip */float: right;	/* by the CollapsibleTables javascript in		*/
	font-weight: normal;		/* [[MediaWiki:Common.js]] are styled here		*/
	/* @noflip */text-align: right;	/* so they can be customised.				*/
	width: auto;
}
.navbox .collapseButton {	/* In navboxes, the show/hide button balances	*/
	width: 6em;				/* the vde links from Navbar (removed on BIKI),	*/
}							/* so they need to be the same width.			*/