All colors used in Minerva are converted from Less variables
into CSS custom properties. A new file called CSSCustomProperties.less
is created in the skins.minerva.base.styles module to store
these custom properties and an ADR is provided on the rationale for
dropping support for browsers that don't support custom properties.
The new CSS custom properties follow Codex design token conventions
where possible (and noted when not).
Link colors are unique because their styles are defined in core,
so in that case the Less variables values are set to custom properties.
Those values are then fed back into MediaWiki core for core link
styling.
Also adds a temporary night-mode color palette under the
.skin-nightmode-1 class on the <html> element.
Bug: T356074
Change-Id: Ida1f14138f12bd3c600c264bde7b5100f9dbf4ff
Converts all Less variable names from CamelCase to snake-case
per the MediaWiki coding conventions.
Removes the following unused Less variables, mostly
related to icons, since those were converted to Codex:
- @icon-touch-area-sm
- @icon-touch-area-md
- @min-size-icon (replaced with @size-icon-medium)
- @icon-glyph-size-sm
- @icon-size-sm
- @icon-padding-sm
- @icon-glyph-size-md
- @icon-size-md
- @margin-icon-md-labelled
Bug: T350581
Change-Id: I1b16e77942d9bea20dcc5636a63d64aa2325a173
Add CSS to support new HTML markup for headings with section edit
links, which will soon be used by Parsoid page views (T269630)
and by the old parser (T13555). Keep the old rules to provide
temporary support for cached page HTML and emergency opt-outs,
as well as permanent support for plain headings on special pages
and in Parsoid edit mode HTML.
See documentation page for further explanation:
https://www.mediawiki.org/wiki/Heading_HTML_changes
Depends-On: I44587461582d648b56ef0c9c7ae0c322895c69c2
Bug: T13555
Bug: T269630
Change-Id: Ib97d034ab533124f06441e788c8608fb274dccf0
Replacing 'mediawiki.ui/variables.less' @import with
new skin-aware 'mediawiki.skin.variables.less' standard.
Removing calls for 'mediawiki.skin.variables.less' in favor for
'minerva.variables.less' for consistency.
Also
- replacing several static values with new Codex design token featuring
skin variables of `background-color`, `color`, `border-*` and
`transition` categories
- renaming several Less variables to variable naming standard
- moving a small number of MinervaNeue specific variables into
'minderva.variables.less' file. Those should be replaced in mid-future
by Codex design tokens
Please note, that this patch is not replacing all values with
possible Codex tokens. It's just applying them on selected
categories for consistency for now to keep the patch easier reviewable.
Further replacements will be done in follow-up patches.
Bump MediaWiki core required version to >= v1.41.0.
Bug: T319381
Bug: T332541
Depends-On: I98c8cc27527533e2efb3b987ee34bc403e988b75
Change-Id: I86c5a35377541a784552c29456e0b8b507b3ee9c
Per ResourceLoaderSkinModule disabling these styles is not
recommended. Enabling them is also now needed to support IP masking.
Bug: T325768
Change-Id: Ia7f2eb6ba902ebfc9364147ec0692eaae124469e
These styles have drifted away from the HTML structure since they were
written in 2017.
General:
* Add some comments
* Replace complicated selectors with simple class selectors
styles.less:
* Hide section edit links (previously we relied on MobileFrontend
styles, which one handled some cases - removing them in I9a88b80c2a)
* Show print footer, hide Minerva footer
header.less:
* Remove FIXME (resolved in c323c6858a).
* Fix hiding the search box. In 0bee6a1eb6 a <form> for the search box
was added to the header, and these styles (using tag selectors) were
not updated. Use class selectors instead.
* Remove styles for <h1>. The element was changed to <a> in
a905b1c161, styles to override font-size etc. are no longer needed.
* Consolidate 'padding' rules and remove unneeded !important.
article.less:
* Replace the `[ class|='mw-content' ]` selector, which was not
matching anything. It would match elements with `class="mw-content"`
or `class="mw-content-…"`, but the node we're trying to style has
`class="mw-body-content mw-content-ltr"` (since 7cda5b0bf8 in
MediaWiki core). Use a class selector instead.
* Replace the `.mw-body > .content` selector too. While this one
works, it is also needlessly complicated.
footer.less:
* Fix and simplify how last-modified info and license text is unhidden
(while other parts of the footer remain hidden).
* Remove styles for .license. Unused since 1f2b7dff15, use the desktop
footer added in that commit instead.
* Use the desktop footer for last-modified info, since it's more
suitable for "archiving" (it has a date rather than time ago).
Bug: T323636
Change-Id: I21ef26355e3e6dd8b0c34ae933b7f5b0b222655c
Additional change:
* The animation stylesheet pulled down for the storybook instance
in dev-scripts/setup-storybook.sh is no longer referenced anywhere
in assets so can be removed.
Bug: T306486
Bug: T308351
Bug: T308360
Change-Id: Ia9f2a05cde2724486f7e449261c5d4875388f5ab
Content using `header` as a CSS class was affected by skin styles
in Minerva being insufficiently specific to the skin‑specific elements.
This changes Minerva to use `class="minerva‑header"`, thus avoiding
the conflict and matching what Vector does.
Bug: T172626
Change-Id: Id8fbe61b2d1d4a89ec11ddfdf7837be797b3bd20
`lazy-image-placeholder` is needed only when MobileFrontend is enabled.
So it makes sense to move those styles to mobile.init css. See more details here: T199351#6380240
Bug: T260406
Change-Id: I16ca734af33fb0f3c4c67f20bbca8631279d7778
MoveLeadParagraphTransform treats div.infobox the same as table.infobox,
and should be fixed to match any element too.
Fix specificity of tablet overrides.
Bug: T258011
Change-Id: I9ada6d1b8b19b46dba6527f1f66edd2547fa0c88
When we built the new main menu we started using a `nav` element.
Update selectors to hide the `nav` element when printing from
mobile.
When printing from tablet or desktop make sure the header is displayed.
Bug: T244181
Change-Id: I7f60fd11d969a48e1c7926ad8acc4213f9affed4
* Drop non-existent pointer-overlay selector
* Drop redundant icon class for arrow
* Drop unnecessary !important
* Drop transparent-shield class
* Reword an existing FIXME about a contensious decision and
add a new FIXME for moving some code to a more appropriate place.
* Move an image into a ResourceLoaderImage module (test with
`mw.notify('error', { type: 'error'} )`)
Change-Id: I6e38f07772afae6f13c4851ca17a67d52ca7d331
Enabling 'selector-max-id' rule, and changing in rare exceptions like
`#bodyContent` to `.mw-body > .content` where there's only one less
specific option.
Bug: T239183
Change-Id: I9d929eaae09475b2e20d96cb19081aba3aec5877
* Remove ambiguity in imports - say the file extension
'less' for all instances of variables and mixins.
* Separate toast styles from drawer styles so they can be
imported separately
* associate header-action selector with its parent
(.overlay-header) not parent's parent (.overlay) so it can be imported
and rendered without the Overlay.
Change-Id: Ib7e19a440ba095d6424d35305fb41d643ca9764c
The CSS animation will never complete in print media so will not display
in PDF rendering. A note is added to explain this rule.
Bug: T220668
Change-Id: I82260fa4e18a13970243d3cb2fc585aefb3c1d09
There's no reason to have this as separate style file in content.styles
as common text styles are taken care of in 'text.less' and
'print/articles.less' for print. Moving contents rule there.
Change-Id: Ie613d95488e9b5a814b6be8f0c856e9e92ab5aed
Use local imports instead given all relevant files are within the
same repository, and don't vary by configuraion.
Bug: T140807
Depends-On: If3edac9a35b346af0320c12f70c0d978a6346201
Change-Id: Ife3cc345a63aff452e93accbe0a593fbaa358732
The link change overrides link colors in last modified,
talk button and main menu. This approach was obviously flawed.
Rather than enter a specificity
war let's instead limit the styles to links which do not have
an href. Volker you were right...
* Revert "Last modified links should not be progressive blue"
This reverts commit bc045b78a2.
* Revert "Do not style links without href attribute"
This reverts commit daa6ad5145.
* Apply a not selector for links
Certain links (including links inside navboxes) render
links to themselves - for example the navbox on the San
Francisco article (provided it is not removed by
wgMFRemovableClasses)
These links should be visually distinguished from normal links.
The not selector has support from IE9 onwards and given our browser
matrix and the low impact of if this fallback fails this is a perfectly
acceptable usecase.
Bug: T181472
Change-Id: I61b05e3c223f2ba5314aecdf26b8a0ee8caa6524
This regression was due to I9f842ae09751d299716d752328f747269597fbdb
Updated specifity of selector.
Additional change:
* Update comment per feedback from TheDj
Bug: T181472
Change-Id: I9534cce5f240009c9013b75e1367776519b00d81
$wgResourceLoaderLESSVars is deprecated. Let's not use it anymore.
Change-Id: If28ab6884668700bc46533c8e2c377f17e6be696
Depends-On: Ib9f843147db4473ce5590741e0fb490384b0007e
Bug: T171365
Replacing `#9aa0a7` with standard subtle `#999` print color.
Also clarfiying LESS variable naming and removing unused variable
`@printBorderColorLight`.
Change-Id: I2c1b36099935aa99d63a3316b3a107a23ffa0afd
The Popups extension uses a footer element so these rules clash with
that and probably other extensions.
To avoid this restrict the element to the skin.
Change-Id: Iac3aa8e600969a0feb0abeee745cd26592a594fd
We no longer need to keep this as a separate entry point now we do not
feature flag our print styles
Please enter the commit message for your changes. Lines starting
Change-Id: I6bf12980aa929e84f239931beb0a505809231830