When defining background we should also define color to avoid mixing
styles provided by editor, and us.
This fixes the black on black in infoboxes on the Paris article
for example in night mode.
Bug: T356074
Change-Id: I5a73f5eaf269cb8f771663a9181a67f9af723b13
Whereas previously, the value of the query param would simply determine
whether or not night mode was enabled, we would like to be able to
control the actual night mode setting off of the query param
Now, it functions as an option to force the user into a particular
setting, be it automatic, night, or day. If the query param is not set
(if night mode is enabled via config), we will default to the user
option as before
Bug: T355118
Change-Id: I38ed94bfc1b80d0a827c63c6dbdd92eb6f1bf531
Add a new user option, `minerva-night-mode`, and configure it with a
default value of 2 (automatic based on OS). Rework the code in
`getHtmlElementAttributes` to set the initial class value according to
the user option, which will be set and saved inside of MobileFrontend
Bug: T355118
Change-Id: I4b0d63a186f490ba10b7655b3af4dcb8b64bd400
Retain the existing font,
margin and padding values as without
these we would trigger a visual regression.
Visual change: Four minor visual regression with this change
relating to the button in the AMC CTA Drawer and suggested
edits overlay heading. All are acceptable.
Bug: T205341
Change-Id: I6331d88e5b7301fd13249414350a539738cfae53
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
Adds an ADR explaining the intent of use CSS custom properties for
night mode in Minerva.
Bug: T356074
Change-Id: I3a67f31ec426a3bb29e36c45adbcc0122e673d85
Adds a config flag, `MinervaNightMode`, and wires it up as a skin option
for enabling/disabling the night mode toggle (sold separately)
Additionally, allow this feature to be enabled via the
`minervanightmode` query param
For now, turning the flag on will result in the class
`skin-nightmode-clientpref-1` being added to the HTML element, but in a
later change this will be updated to switch values based on the
forthcoming client pref
Bug: T355118
Change-Id: I35848ab80ee75d324ceb35d17794e2d3e620cc19
On English Wikipedia, talk tabs are enabled so this went undetected.
The history and diff pages should be loading these styles since they
both have tabs.
Bug: T356117
Change-Id: I380cc4ba9a4f809e4400873241d97de5a5fe6c1f
Adds the first ADR to the MinervaNeue skin.
The file is placed in a top-level `/adr` folder since the `/doc` folder
is already used for auto-generated documentation.
Change-Id: I83ad4a1bf8e81caaea9312d4c3efc3bf5ce419be
The latest update of 'svgo' dependency includes three optimizations on
converting path commands, which
- improves closing paths and how we determine if to use absolute or
relative commands.
- round arc or convert to lines based on the geometric sagitta
- convert cubic Bézier curves to quadratic Bézier curves where possible
Also unifiying npm command to qua standard notation `minify:svg`.
Bug: T354875
Change-Id: Ibf59b3435b82602c5355b6f1c9b03920ea2e8eab
To test you must be using desktop Minerva
This addresses only the problem described in
T353062#9438627.
Bug: T353062
Change-Id: Ia7053b94aae1b6ab48307769de063d825a47c1db
CHECKBOX_HACK_TARGET_SELECTOR only applies to the first list
and there are three lists in the menu. Use the parent instead.
Additional changes:
* Transform to ES6 while working on this code.
Bug: T354315
Change-Id: I354e33af872e9a2f93d97793f5f33b735d42e804
This omitted the important overflow and text-overflow
rules that we use in MobileFrontend. The line height also
needs a slight adjustment.
Bug: T354218
Change-Id: I4b8dee3395603933aba2818725b1f8fbbde0a2a6
Once the cache has cleared out and all tab links are nested in li
elements (983960), follow up on the fixmes introduced and update the
stylesheet to reflect the single way we will be styling `minerva__tab`s
going forward. This should not be merged until after the break to
ensure the cache has had time to clear
No visual changes on this one as it _should_ effectively be a noop
Bug: T340728
Change-Id: I36be5ab3cacfb5e0c0f056264055509d2ee22271