2017-07-12 15:12:40 +00:00
|
|
|
/*
|
|
|
|
A file for css that corrects known rendering issues on known Wikimedia wikis.
|
|
|
|
|
|
|
|
the following definitions exist to deal with certain inline styles
|
|
|
|
present in wikitext.
|
|
|
|
This file should not need to exist
|
|
|
|
It will become redundant when the following RFC is resolved:
|
|
|
|
https://www.mediawiki.org/wiki/Requests_for_comment/Allow_styling_in_templates
|
|
|
|
|
|
|
|
FIXME: Review all of these hacks to see if they still apply.
|
|
|
|
*/
|
2021-04-29 01:01:54 +00:00
|
|
|
@import '../../../minerva.less/minerva.variables.less';
|
|
|
|
@import '../../../minerva.less/minerva.mixins.less';
|
2018-05-08 22:03:52 +00:00
|
|
|
@import 'templates/ambox.less';
|
2019-06-03 12:27:50 +00:00
|
|
|
@import 'templates/reflist.less';
|
2017-07-12 15:12:40 +00:00
|
|
|
|
|
|
|
.collapsible td {
|
|
|
|
width: auto !important;
|
|
|
|
}
|
|
|
|
|
|
|
|
.content {
|
2017-08-01 18:52:11 +00:00
|
|
|
.vertical-navbox,
|
|
|
|
.navbox {
|
|
|
|
display: none;
|
|
|
|
}
|
|
|
|
|
2019-11-26 05:02:40 +00:00
|
|
|
// stylelint-disable selector-max-id
|
2017-07-12 15:12:40 +00:00
|
|
|
#coordinates,
|
2018-12-12 23:20:10 +00:00
|
|
|
/* Hide article badges, clean-up notices, stub notices, and navigation boxes */
|
2018-05-08 22:03:52 +00:00
|
|
|
.topicon {
|
2017-07-12 15:12:40 +00:00
|
|
|
// It's important as some of these are tables which become display: table on larger screens
|
|
|
|
display: none !important;
|
|
|
|
}
|
2019-11-26 05:02:40 +00:00
|
|
|
// stylelint-enable selector-max-id
|
2017-07-12 15:12:40 +00:00
|
|
|
|
2020-07-17 18:00:51 +00:00
|
|
|
table,
|
|
|
|
.infobox {
|
|
|
|
// Unfloat tables and infoboxes:;
|
2017-07-12 15:12:40 +00:00
|
|
|
// A lot of templates introduce floating and horizontal margins inline styles
|
|
|
|
float: none !important;
|
|
|
|
margin-left: 0 !important;
|
|
|
|
margin-right: 0 !important;
|
2020-07-17 18:00:51 +00:00
|
|
|
}
|
2017-07-12 15:12:40 +00:00
|
|
|
|
2020-07-17 18:00:51 +00:00
|
|
|
.infobox {
|
|
|
|
font-size: 90%;
|
|
|
|
position: relative;
|
2024-02-14 21:18:21 +00:00
|
|
|
border: @border-width-base @border-style-base var( --border-color-muted );
|
2020-07-17 18:00:51 +00:00
|
|
|
margin-bottom: 2em;
|
2024-02-06 21:22:49 +00:00
|
|
|
color: var( --color-base );
|
2024-02-01 17:33:08 +00:00
|
|
|
background-color: var( --background-color-interactive-subtle );
|
2020-07-17 18:00:51 +00:00
|
|
|
display: flex;
|
|
|
|
flex: 1 1 100%;
|
|
|
|
flex-flow: column nowrap;
|
2020-07-17 21:25:18 +00:00
|
|
|
width: 100% !important;
|
|
|
|
max-width: 100% !important;
|
2020-07-17 18:00:51 +00:00
|
|
|
|
|
|
|
caption {
|
|
|
|
padding: 10px 10px 0;
|
|
|
|
text-align: center;
|
|
|
|
}
|
|
|
|
|
|
|
|
th, td {
|
|
|
|
vertical-align: top;
|
|
|
|
border: 0;
|
2024-02-14 21:18:21 +00:00
|
|
|
border-bottom: @border-width-base @border-style-base var( --border-color-muted );
|
2020-07-17 18:00:51 +00:00
|
|
|
padding: 7px 10px;
|
|
|
|
}
|
|
|
|
|
|
|
|
tbody > tr > td,
|
|
|
|
tbody > tr > th {
|
|
|
|
flex: 1 0;
|
|
|
|
}
|
|
|
|
|
|
|
|
td:only-child,
|
|
|
|
th:only-child {
|
|
|
|
width: 100%;
|
|
|
|
}
|
2018-01-13 20:07:29 +00:00
|
|
|
|
2020-07-17 18:00:51 +00:00
|
|
|
tr:last-child th,
|
|
|
|
tr:last-child td {
|
|
|
|
border: 0;
|
2017-07-12 15:12:40 +00:00
|
|
|
}
|
2018-01-13 20:07:29 +00:00
|
|
|
|
2020-07-17 18:00:51 +00:00
|
|
|
& > tbody,
|
|
|
|
& > caption {
|
2018-01-13 20:07:29 +00:00
|
|
|
display: flex;
|
|
|
|
flex-flow: column nowrap;
|
|
|
|
}
|
|
|
|
|
2020-07-17 18:00:51 +00:00
|
|
|
& > tbody > tr {
|
2018-01-13 20:07:29 +00:00
|
|
|
min-width: 100%;
|
|
|
|
display: flex;
|
|
|
|
flex-flow: row nowrap;
|
|
|
|
}
|
2017-07-12 15:12:40 +00:00
|
|
|
}
|
2018-06-17 18:58:38 +00:00
|
|
|
|
|
|
|
// Hack to assign info boxes properly when using RTL languages on LTR wiki
|
2020-07-17 18:00:51 +00:00
|
|
|
.mw-content-ltr .infobox {
|
2018-06-17 18:58:38 +00:00
|
|
|
/* @noflip */
|
|
|
|
text-align: left;
|
|
|
|
}
|
|
|
|
|
|
|
|
// Hack to assign info boxes properly when using LTR languages on RTL wiki
|
2020-07-17 18:00:51 +00:00
|
|
|
.mw-content-rtl .infobox {
|
2018-06-17 18:58:38 +00:00
|
|
|
/* @noflip */
|
|
|
|
text-align: right;
|
|
|
|
}
|
2017-07-12 15:12:40 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
// FIXME: Remove when filetoc is stripped from file pages a la table of contents (toc)
|
2019-11-26 05:02:40 +00:00
|
|
|
#filetoc { // stylelint-disable-line selector-max-id
|
2017-07-12 15:12:40 +00:00
|
|
|
display: none;
|
|
|
|
}
|
|
|
|
|
2022-07-18 13:20:11 +00:00
|
|
|
/* T36878: Set an optimal width for a column.
|
2017-07-12 15:12:40 +00:00
|
|
|
* Makes sure that on small screens column-count is only honored if column-width hint is not violated.
|
|
|
|
* https://developer.mozilla.org/en-US/docs/CSS/column-width
|
|
|
|
*/
|
|
|
|
.references-column-count,
|
|
|
|
.column-count {
|
|
|
|
-moz-column-width: 35em;
|
|
|
|
-webkit-column-width: 35em;
|
|
|
|
column-width: 35em;
|
|
|
|
}
|
|
|
|
|
|
|
|
// When JavaScript is disabled clarify to the user which reference they clicked on
|
|
|
|
.references li:target {
|
2024-02-01 17:33:08 +00:00
|
|
|
background-color: var( --background-color-progressive-subtle );
|
2017-07-12 15:12:40 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
.hatnote,
|
|
|
|
.dablink,
|
|
|
|
.rellink {
|
2017-09-06 14:09:54 +00:00
|
|
|
padding: 5px 7px;
|
2024-02-01 17:33:08 +00:00
|
|
|
color: var( --color-subtle );
|
2019-09-23 22:02:16 +00:00
|
|
|
font-size: @font-size-minerva-smallest;
|
2024-02-01 17:33:08 +00:00
|
|
|
background-color: var( --background-color-interactive-subtle );
|
2017-09-06 14:09:54 +00:00
|
|
|
margin-bottom: 1px;
|
2018-04-24 11:51:48 +00:00
|
|
|
overflow: hidden;
|
2018-12-12 23:20:10 +00:00
|
|
|
|
2017-09-06 14:09:54 +00:00
|
|
|
a {
|
2024-02-01 17:33:08 +00:00
|
|
|
color: var( --color-progressive );
|
2017-09-06 14:09:54 +00:00
|
|
|
}
|
2017-07-12 15:12:40 +00:00
|
|
|
}
|
|
|
|
|
2018-02-05 19:17:54 +00:00
|
|
|
@media all and ( min-width: @width-breakpoint-tablet ) {
|
2017-08-01 18:52:11 +00:00
|
|
|
// When in the HTML these should be revealed at tablet resolution (T172078)
|
|
|
|
.content {
|
|
|
|
.vertical-navbox,
|
|
|
|
.navbox {
|
|
|
|
display: inherit;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-07-12 15:12:40 +00:00
|
|
|
// Hacks to render galleries and multicol tables better on mobile
|
2018-02-05 19:17:54 +00:00
|
|
|
@media all and ( max-width: @width-breakpoint-tablet ) {
|
2017-07-12 15:12:40 +00:00
|
|
|
.content {
|
|
|
|
table {
|
|
|
|
// Make {{col-beg}}, {{col-break}}, and {{col-end}} templates display single column tables
|
|
|
|
&.multicol {
|
|
|
|
> tr > td,
|
|
|
|
> tbody > tr > td {
|
|
|
|
display: block !important;
|
|
|
|
width: auto !important;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// Deal with Template:Multiple_image. T38030 and T148505
|
|
|
|
.thumb .thumbinner {
|
|
|
|
.flex-display( flex );
|
|
|
|
justify-content: center;
|
|
|
|
flex-wrap: wrap;
|
|
|
|
align-content: flex-start;
|
2018-08-02 09:58:37 +00:00
|
|
|
// avoid image child overflowing the container (T200518)
|
2018-09-11 13:13:41 +00:00
|
|
|
// stylelint-disable-next-line declaration-block-no-redundant-longhand-properties
|
2018-08-02 09:58:37 +00:00
|
|
|
flex-direction: column;
|
2017-07-12 15:12:40 +00:00
|
|
|
|
|
|
|
> .thumbcaption {
|
|
|
|
.flex( 1, 0, 100% );
|
|
|
|
display: block;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
2024-02-29 21:23:48 +00:00
|
|
|
|
|
|
|
/* General case that templates/extensions can opt into */
|
|
|
|
.skin-nightmode-reset-color,
|
|
|
|
/* T357735 */
|
|
|
|
.quotebox,
|
|
|
|
/* T357726 */
|
|
|
|
.side-box, .side-box *,
|
|
|
|
/* T358012 */
|
|
|
|
.navbox-even, .navbox-abovebelow, .navbox-title {
|
2024-03-04 18:31:20 +00:00
|
|
|
&:not( .notheme ) {
|
|
|
|
background: inherit !important;
|
|
|
|
color: inherit !important;
|
|
|
|
}
|
2024-02-29 21:23:48 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
/* T358385 */
|
|
|
|
[ bgcolor ] {
|
|
|
|
// Important: this should correspond with the light mode theme version of color-base
|
|
|
|
color: #333;
|
|
|
|
}
|
2024-03-04 23:38:42 +00:00
|
|
|
|
|
|
|
/* T357453 - attempt to strip colors from the majority of infoboxes in night mode (unless notheme specified) */
|
|
|
|
// please forgive me for bypassing the linter there is no easy way to keep all of the infobox classes grouped without
|
|
|
|
// stylelint-disable no-descending-specificity
|
|
|
|
html.skin-night-mode-clientpref-1 {
|
|
|
|
.infobox td,
|
|
|
|
.infobox th,
|
|
|
|
.infobox-above,
|
|
|
|
/* itwiki */.sinottico th,
|
|
|
|
.infobox-header {
|
|
|
|
&:not( .notheme ) {
|
|
|
|
.night-mode-strip-all-colors-when-safe();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
/* T357453 - for automatic as well */
|
|
|
|
@media ( prefers-color-scheme: dark ) {
|
|
|
|
html.skin-night-mode-clientpref-2 {
|
|
|
|
.infobox td,
|
|
|
|
.infobox th,
|
|
|
|
.infobox-above,
|
|
|
|
/* itwiki */.sinottico th,
|
|
|
|
.infobox-header {
|
|
|
|
&:not( .notheme ) {
|
|
|
|
.night-mode-strip-all-colors-when-safe();
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// stylelint-enable no-descending-specificity
|