mirror of
https://gerrit.wikimedia.org/r/mediawiki/extensions/Cite
synced 2024-11-23 22:45:20 +00:00
Group and nest stylesheets now they are .less files
Change-Id: Iedd9748cf9f38847ef4553459d533a67a0950645
This commit is contained in:
parent
80c8eaf3ce
commit
16711d681b
|
@ -4,11 +4,11 @@
|
||||||
|
|
||||||
.mw-cite-up-arrow-backlink {
|
.mw-cite-up-arrow-backlink {
|
||||||
display: none;
|
display: none;
|
||||||
}
|
|
||||||
|
|
||||||
:target .mw-cite-up-arrow-backlink {
|
:target & {
|
||||||
display: inline;
|
display: inline;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
:target .mw-cite-up-arrow {
|
:target .mw-cite-up-arrow {
|
||||||
display: none;
|
display: none;
|
||||||
|
|
|
@ -10,15 +10,17 @@
|
||||||
|
|
||||||
/* Upstream bug in stylelint makes it complain aboout the case of 'mw-Ref' */
|
/* Upstream bug in stylelint makes it complain aboout the case of 'mw-Ref' */
|
||||||
|
|
||||||
|
.mw-ref a {
|
||||||
/* With a group set */
|
/* With a group set */
|
||||||
.mw-ref a[ data-mw-group ]::after {
|
&[ data-mw-group ]::after {
|
||||||
content: '[' attr( data-mw-group ) ' ' counter( mw-Ref, decimal ) ']';
|
content: '[' attr( data-mw-group ) ' ' counter( mw-Ref, decimal ) ']';
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Without a group */
|
/* Without a group */
|
||||||
.mw-ref a::after {
|
&::after {
|
||||||
content: '[' counter( mw-Ref, decimal ) ']';
|
content: '[' counter( mw-Ref, decimal ) ']';
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* Hide the default rendering in browsers that support content
|
/* Hide the default rendering in browsers that support content
|
||||||
* generation by selecting for :after pseudo-element. */
|
* generation by selecting for :after pseudo-element. */
|
||||||
|
@ -44,9 +46,8 @@ ol.mw-references {
|
||||||
* is the one that seems to be winning.
|
* is the one that seems to be winning.
|
||||||
**/
|
**/
|
||||||
counter-reset: mw-ref-extends-parent mw-references list-item;
|
counter-reset: mw-ref-extends-parent mw-references list-item;
|
||||||
}
|
|
||||||
|
|
||||||
ol.mw-references > li {
|
> li {
|
||||||
/**
|
/**
|
||||||
* We have 2 counters for Parsoid HTML for different functionality.
|
* We have 2 counters for Parsoid HTML for different functionality.
|
||||||
* Make sure both are incremented!
|
* Make sure both are incremented!
|
||||||
|
@ -59,6 +60,7 @@ ol.mw-references > li {
|
||||||
**/
|
**/
|
||||||
counter-increment: mw-ref-extends-parent mw-references;
|
counter-increment: mw-ref-extends-parent mw-references;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
[ rel~='mw:referencedBy' ]::before {
|
[ rel~='mw:referencedBy' ]::before {
|
||||||
content: '↑ ';
|
content: '↑ ';
|
||||||
|
@ -66,9 +68,8 @@ ol.mw-references > li {
|
||||||
|
|
||||||
span[ rel~='mw:referencedBy' ] {
|
span[ rel~='mw:referencedBy' ] {
|
||||||
counter-reset: mw-ref-linkback -1;
|
counter-reset: mw-ref-linkback -1;
|
||||||
}
|
|
||||||
|
|
||||||
span[ rel~='mw:referencedBy' ] a::before {
|
a::before {
|
||||||
counter-increment: mw-ref-linkback;
|
counter-increment: mw-ref-linkback;
|
||||||
content: counter( mw-references, decimal ) '.' counter( mw-ref-linkback, decimal );
|
content: counter( mw-references, decimal ) '.' counter( mw-ref-linkback, decimal );
|
||||||
line-height: 1;
|
line-height: 1;
|
||||||
|
@ -76,14 +77,15 @@ span[ rel~='mw:referencedBy' ] a::before {
|
||||||
font-size: smaller; /* <sup> use in Cite */
|
font-size: smaller; /* <sup> use in Cite */
|
||||||
}
|
}
|
||||||
|
|
||||||
span[ rel~='mw:referencedBy' ] a::after {
|
a::after {
|
||||||
content: ' '; /* default separator outside <sup> */
|
content: ' '; /* default separator outside <sup> */
|
||||||
line-height: 1;
|
line-height: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
span[ rel~='mw:referencedBy' ] a:last-child::after {
|
a:last-child::after {
|
||||||
content: '';
|
content: '';
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* Hide the default rendering in browsers that support content
|
/* Hide the default rendering in browsers that support content
|
||||||
* generation by selecting for ::after pseudo-element. */
|
* generation by selecting for ::after pseudo-element. */
|
||||||
|
|
|
@ -11,19 +11,19 @@
|
||||||
-moz-column-width: 30em;
|
-moz-column-width: 30em;
|
||||||
column-width: 30em;
|
column-width: 30em;
|
||||||
margin-top: 0.3em;
|
margin-top: 0.3em;
|
||||||
}
|
|
||||||
|
|
||||||
/* Lines first column up nicely. */
|
/* Lines first column up nicely. */
|
||||||
.mw-parser-output .mw-references-columns .references {
|
.mw-parser-output & .references {
|
||||||
margin-top: 0;
|
margin-top: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
/* Avoid elements from breaking between columns */
|
/* Avoid elements from breaking between columns */
|
||||||
.mw-references-columns li {
|
li {
|
||||||
-webkit-column-break-inside: avoid;
|
-webkit-column-break-inside: avoid;
|
||||||
page-break-inside: avoid;
|
page-break-inside: avoid;
|
||||||
break-inside: avoid-column;
|
break-inside: avoid-column;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
ol.references {
|
ol.references {
|
||||||
/**
|
/**
|
||||||
|
@ -34,9 +34,8 @@ ol.references {
|
||||||
* Make sure both are reset!
|
* Make sure both are reset!
|
||||||
**/
|
**/
|
||||||
counter-reset: mw-ref-extends-parent mw-references list-item;
|
counter-reset: mw-ref-extends-parent mw-references list-item;
|
||||||
}
|
|
||||||
|
|
||||||
ol.references > li {
|
> li {
|
||||||
/**
|
/**
|
||||||
* We have 2 counters for Parsoid HTML for different functionality.
|
* We have 2 counters for Parsoid HTML for different functionality.
|
||||||
* Make sure both are incremented!
|
* Make sure both are incremented!
|
||||||
|
@ -45,10 +44,11 @@ ol.references > li {
|
||||||
counter-reset: mw-ref-extends-child;
|
counter-reset: mw-ref-extends-child;
|
||||||
}
|
}
|
||||||
|
|
||||||
ol.references .mw-extended-references {
|
.mw-extended-references {
|
||||||
list-style: none;
|
list-style: none;
|
||||||
margin-left: 2em;
|
margin-left: 2em;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
.mw-extended-references > li::before {
|
.mw-extended-references > li::before {
|
||||||
counter-increment: mw-ref-extends-child;
|
counter-increment: mw-ref-extends-child;
|
||||||
|
@ -81,9 +81,8 @@ sup.reference:target {
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
/* For the case that the error is embedded in an element with a different direction */
|
/* For the case that the error is embedded in an element with a different direction */
|
||||||
unicode-bidi: embed;
|
unicode-bidi: embed;
|
||||||
}
|
|
||||||
|
|
||||||
.mw-ext-cite-error code {
|
code {
|
||||||
/* As code is inheriting `#f8f9fa` as background color from `code`,
|
/* As code is inheriting `#f8f9fa` as background color from `code`,
|
||||||
we need to increase contrast, by setting it to `transparent`. See T247903. */
|
we need to increase contrast, by setting it to `transparent`. See T247903. */
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
|
@ -91,6 +90,7 @@ sup.reference:target {
|
||||||
/* Reduce inherited `padding` to make code fit in better in Resources list. */
|
/* Reduce inherited `padding` to make code fit in better in Resources list. */
|
||||||
padding: 1px 2px;
|
padding: 1px 2px;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
/* @noflip */
|
/* @noflip */
|
||||||
.mw-cite-dir-ltr .reference-text {
|
.mw-cite-dir-ltr .reference-text {
|
||||||
|
|
|
@ -40,12 +40,12 @@
|
||||||
user-select: none;
|
user-select: none;
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
}
|
}
|
||||||
}
|
|
||||||
|
|
||||||
.ve-ce-mwReferencesListNode-highlight {
|
&-highlight {
|
||||||
.ve-ce-surface-highlights-focused & {
|
.ve-ce-surface-highlights-focused & {
|
||||||
background: transparent;
|
background: transparent;
|
||||||
pointer-events: none;
|
pointer-events: none;
|
||||||
box-shadow: inset 0 0 0 1px #4c76ac, 0 0 0 2px #4c76ac;
|
box-shadow: inset 0 0 0 1px #4c76ac, 0 0 0 2px #4c76ac;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
|
@ -18,7 +18,7 @@
|
||||||
word-wrap: break-word;
|
word-wrap: break-word;
|
||||||
overflow-wrap: break-word;
|
overflow-wrap: break-word;
|
||||||
|
|
||||||
& + .ve-ui-mwReferenceContextItem-muted {
|
+ .ve-ui-mwReferenceContextItem-muted {
|
||||||
margin-top: 0.5em;
|
margin-top: 0.5em;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,20 +9,20 @@
|
||||||
position: relative;
|
position: relative;
|
||||||
padding: 1em;
|
padding: 1em;
|
||||||
border-bottom: 1px solid #eaecf0;
|
border-bottom: 1px solid #eaecf0;
|
||||||
}
|
|
||||||
|
|
||||||
.ve-ui-mwReferenceResultWidget:last-child {
|
&:last-child {
|
||||||
border-bottom: 0;
|
border-bottom: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.ve-ui-mwReferenceResultWidget.oo-ui-labelElement .oo-ui-labelElement-label {
|
&.oo-ui-labelElement .oo-ui-labelElement-label {
|
||||||
white-space: normal;
|
white-space: normal;
|
||||||
}
|
}
|
||||||
|
|
||||||
.ve-ui-mwReferenceResultWidget-shield {
|
&-shield {
|
||||||
position: absolute;
|
position: absolute;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
right: 0;
|
right: 0;
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
Loading…
Reference in a new issue