MediaWiki:Gadget-compact items.css

Note: After publishing, you may have to bypass your browser's cache to see the changes.

  • Firefox / Safari: Hold Shift while clicking Reload, or press either Ctrl-F5 or Ctrl-R (⌘-R on a Mac)
  • Google Chrome: Press Ctrl-Shift-R (⌘-Shift-R on a Mac)
  • Internet Explorer / Edge: Hold Ctrl while clicking Refresh, or press Ctrl-F5
  • Opera: Press Ctrl-F5.
/*
 * This CSS file makes the interface on item pages more compact by reducing
 * vertical white space, changing actions buttons to only icons (removing the
 * text) and making other adjustments.
 *
 * It depends on [[MediaWiki:Gadget-gridify.css]].
 */

.skin-vector .mw-body {
	/* In Vector there's 1.5em padding on the right side of the page when the
	 * page is at least 982px wide, which isn't there when the page is narrower.
	 * This gadget uses that space for the buttons for adding another value, so
	 * make sure the padding is always there to avoid causing horizontal scrolling. */
	padding-right: 1.5em;
}

.wikibase-entityview .wikibase-entityview-main {
	margin: 0 3em 2em 0; /* 0 2em 2em 0 */
}

.wikibase-statementgroupview {
	margin-bottom: 1em; /* 2em */
}

.wikibase-statementview-qualifiers:not( :empty ) {
	margin-bottom: 0.5em;
}

div.wikibase-statementview-mainsnak {
	margin-right: calc(18em + 20px);
}

div.wikibase-snakview,
.wikibase-statementgrouplistview .wikibase-statementgroupview-property .wikibase-statementgroupview-property-label {
	padding: 8px; /* 10px 5px 5px 10px || 10px */
}

.wikibase-toolbar-button a {
	display: inline-block; /* */
	overflow: hidden; /* */
	width: 20px; /* */
}

.wikibase-statementview .wikibase-toolbar-container {
	display: inline-block;
	right: 5px;
	text-align: right;
	top: 5px;
	width: 60px;
}

.wikibase-statementview .wikibase-statementview-references .wikibase-toolbar-container {
	max-width: 40px;
	min-width: 20px;
}

.wb-help-field-hint {
	display: none !important;
}

.wikibase-statementview-references-heading {
	margin: 0;
	padding-left: 0;
	position: absolute;
	right: 70px;
	top: 0;
	width: calc(18em - 70px - 20px);
}

.wikibase-referenceview .wikibase-snaklistview-listview .wikibase-snakview:not( .wb-edit ) .wikibase-snakview-value-container .wikibase-snakview-body,
.wikibase-statementview-qualifiers .wikibase-snaklistview:not( .wb-edit ) .wikibase-snaklistview-listview .wikibase-snakview-value-container .wikibase-snakview-body {
	margin-right: inherit; /* 18em */
	word-break: break-word; /* */
}

.wikibase-referenceview {
	border: 1px solid #c8ccd1; /* */
	border-bottom-left-radius: 0.5em; /* */
	border-right: 0; /* */
	border-top-left-radius: 0.5em; /* */
}

.wikibase-statementview-references .wikibase-toolbar-button-add .wb-icon {
	background-image: url(//upload.wikimedia.org/wikipedia/commons/5/5b/OOjs_UI_icon_quotesAdd-ltr.svg); /* + */
}

.wikibase-statementview-references > .wikibase-toolbar-container {
	display: block;
	float: none;
	position: absolute;
	right: calc(18em - 20px);
	top: 5px;
}

.wikibase-referenceview div.wikibase-referenceview-heading {
	display: contents; /* block */
}

.wikibase-statementview-qualifiers .wikibase-snaklistview:not( .wb-edit ) .wikibase-snaklistview-listview .wikibase-snakview,
.wikibase-referenceview .wikibase-snaklistview:not( .wb-edit ) .wikibase-snaklistview-listview .wikibase-snakview {
	margin-right: 20px;
}

.wikibase-statementview {
	padding-bottom: 0; /* 1em */
}

.wikibase-statementlistview > .wikibase-toolbar-wrapper {
	background: transparent !important; /* gray */
	bottom: 0; /* */
	display: flex; /* block */
	flex-direction: column-reverse; /* */
	height: 100%; /* */
	position: absolute; /* relative */
	right: -20px; /* */
	width: 20px; /* 18 em */
	top: 0; /* */
}

.wikibase-statementlistview > .wikibase-toolbar-wrapper .wikibase-toolbar-container {
	bottom: 0.5em; /* */
	height: 20px; /* */
	line-height: 20px; /* 2em */
	position: sticky; /* */
	width: 20px; /* */

	/* override the NarrowUI gadget for the buttons for adding a new value,
	 * so that it stays attached to the side of the statement box */
	padding-inline: 0;
}

.wikibase-statementlistview > .wikibase-toolbar-wrapper .wb-icon {
	background-color: #fff; /* */
	border: 1px solid #c8ccd1; /* */
	border-left: 0; /* */
	border-radius: 0 0.5em 0.5em 0; /* */
	box-sizing: border-box; /* */
}

.wikibase-toolbarbutton-disabled .wb-icon {
	opacity: 0.5; /* */
}

.wikibase-statementgrouplistview > .wikibase-toolbar-container,
.wikibase-entityview .wikibase-toolbar-container {
	text-align: right;
}

.wikibase-lexeme-forms-section > .wikibase-toolbar-container,
.wikibase-lexeme-senses-section > .wikibase-toolbar-container {
	text-align: left;
}

/*** Adaptions for [[User:Melderick/moveClaims2.js]] and [[MediaWiki:Gadget-Move.js]] ***/

.wikibase-sitelinkview {
	position: relative;
}

.wikibase-sitelinkgroupview .wikibase-sitelinkgroupview-heading-section {
	/* setting .wikibase-sitelinkview to relative makes the sitelinks overlap
	   the headings when scrolling */
	z-index: 1;
}

.wikibase-statementgroupview .move-button,
.wikibase-sitelinkview .move-button {
	background: url(//upload.wikimedia.org/wikipedia/commons/8/84/OOjs_UI_icon_arched-arrow-ltr.svg);
	opacity: 0.1;
	position: absolute;
	right: -25px;
	transition: all 0.1s;
}

.wikibase-statementgroupview:hover .move-button,
.wikibase-sitelinkview:hover .move-button {
	opacity: 1;
}

/*** Adaptions for [[MediaWiki:Gadget-RearrangeValues.js]] ***/

.move_arrows_block {
	background: #fff;
	float: none !important;
	margin-right: inherit !important;
	position: absolute;
	right: 0;
	top: 0;
	z-index: 5;
}

/*** Adaptions for [[User:TomT0m/classification.js]] ***/

#classification-gadget-P31-container,
#classification-gadget-P279-container {
	display: contents;
}

#classification-gadget-instances {
	display: block;
}