2017-07-12 15:12:40 +00:00
|
|
|
// Tables
|
|
|
|
@import 'mediawiki.mixins.less';
|
2021-04-29 01:01:54 +00:00
|
|
|
@import '../../../minerva.less/minerva.variables.less';
|
|
|
|
@import '../../../minerva.less/minerva.mixins.less';
|
2017-07-12 15:12:40 +00:00
|
|
|
|
2024-03-11 21:08:31 +00:00
|
|
|
// FIXME: Upstream to ResourceLoader/SkinModule content-tables styles [T359888]
|
2018-04-25 00:26:16 +00:00
|
|
|
// These are only intended for smaller screens.
|
|
|
|
// This avoids having to undo them from another media query,
|
|
|
|
// by putting the original in a media query instead.
|
|
|
|
// This also avoids having a reset with too-high specificity, which
|
|
|
|
// would break unrelated styles from core and extensions.
|
2023-11-07 09:03:29 +00:00
|
|
|
@media all and ( max-width: @max-width-breakpoint-mobile ) {
|
2018-04-25 00:26:16 +00:00
|
|
|
.content {
|
|
|
|
table {
|
|
|
|
display: block;
|
|
|
|
width: 100% !important;
|
2020-05-25 09:36:03 +00:00
|
|
|
box-sizing: border-box;
|
2019-08-05 11:34:22 +00:00
|
|
|
|
|
|
|
&.wikitable {
|
|
|
|
// Remove the outer table border as the table container may be
|
|
|
|
// wider than all the cells (T206762). In most cases the table
|
|
|
|
// border is not visible anyway due to border-collapse.
|
|
|
|
border: 0;
|
|
|
|
}
|
2018-04-25 00:26:16 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
caption {
|
|
|
|
display: block;
|
|
|
|
}
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
2017-07-12 15:12:40 +00:00
|
|
|
.content {
|
|
|
|
table {
|
|
|
|
margin: 1em 0;
|
|
|
|
|
|
|
|
/* following 4 rules are needed for scrolling */
|
|
|
|
overflow: auto; /* for browsers that don't support overflow-y */
|
2024-07-27 05:52:33 +00:00
|
|
|
overflow: auto hidden;
|
2024-02-20 00:34:27 +00:00
|
|
|
}
|
2017-07-12 15:12:40 +00:00
|
|
|
|
2024-02-20 00:34:27 +00:00
|
|
|
caption {
|
|
|
|
font-weight: bold;
|
|
|
|
text-align: left;
|
2018-10-11 13:38:07 +00:00
|
|
|
}
|
|
|
|
}
|
2017-07-12 15:12:40 +00:00
|
|
|
|
2024-03-11 21:08:31 +00:00
|
|
|
// Overrides for ResourceLoaderSkinModule "content".
|
2019-01-19 01:23:48 +00:00
|
|
|
.wikitable {
|
2018-10-11 13:38:07 +00:00
|
|
|
// We only style cells that are direct children of the wikitable table since
|
|
|
|
// table tags may be used for non-table purposes within the cells.
|
|
|
|
> tr > th,
|
|
|
|
> tr > td,
|
|
|
|
> * > tr > th,
|
|
|
|
> * > tr > td {
|
2024-03-11 21:08:31 +00:00
|
|
|
// content-tables uses 0.2em 0.4em. Can these be consolidated?
|
2018-10-11 13:38:07 +00:00
|
|
|
padding: 0.2em;
|
|
|
|
}
|
2017-07-12 15:12:40 +00:00
|
|
|
}
|