Commit graph

4043 commits

Author SHA1 Message Date
jenkins-bot 07b25670af Merge "Main page should work in night mode" 2024-02-29 20:35:45 +00:00
jenkins-bot 6927d38d91 Merge "Convert color-progressive and color-destructive to CSS variables" 2024-02-29 20:28:23 +00:00
jenkins-bot 671952cc74 Merge "styles: Update color in Less from #d33 to #d73333" 2024-02-29 15:18:54 +00:00
Translation updater bot c97e784fc0 Localisation updates from https://translatewiki.net.
Change-Id: Iee31bc7635a5824f2a9a75b86b4595022e5202d9
2024-02-29 08:38:38 +01:00
Jon Robson 55ea39bb30 Main page should work in night mode
Note: You need to enable wgMinervaApplyKnownTemplateHack in LocalSettings.php
for these styles to work.

Editors can opt out of these rules by using the already popularized
"notheme" class.

Bug: T357722
Change-Id: I32f3968b74bded987bb60e85a902e551727db545
2024-02-28 22:29:08 +00:00
lwatson 261eab0221 styles: Update color in Less from #d33 to #d73333
This patch promotes a consistent design decision across projects in
MediaWiki core, extensions, and skins. The darker red color meets the
W3C Web Content Accessibility Guidelines (WCAG) at Level AA that text
or images of text must have a contrast ratio of at least 4.5:1 (or 3:1
for large text).

Bug: T343239
Change-Id: I771fec3f567ea7ce5a25f8c63d88c956a27121ef
2024-02-28 17:10:08 -05:00
jenkins-bot 1b55f553bb Merge "Separate image inversion from widget inversion" 2024-02-28 21:04:39 +00:00
Jon Robson a195343417 Convert color-progressive and color-destructive to CSS variables
Also add @background-color-notice-subtle

Depends-On: I58e169613054c0ff3f24edfd4ef3ebb47e83cdba
Change-Id: Idc432cc65bfcfd4b6809c36359af4215514e9ca5
2024-02-28 21:01:49 +00:00
Fomafix e812a6b727 Improve PHP code style
* Remove phpcs rule exception
  MediaWiki.WhiteSpace.SpaceBeforeSingleLineComment.NewLineComment.
* Update or remove the comments not matching the rule.
* Fix double tab indention.

Change-Id: I68c43fe0db9384edfaaf64a155e904d629c7ade1
2024-02-28 08:59:17 +00:00
Fomafix 56bef8120f MinervaPagePermissionsTest: Remove unused parameter in buildPermissionsObject
Change-Id: Iaf0ec206a05b809edccb6e64ec3706a4c60faf84
2024-02-28 08:01:32 +00:00
Jon Robson f7124fdc6c Separate image inversion from widget inversion
For images only the filter is needed, not the entire
widget

Bug: T356822
Change-Id: Id0ace19d4071a987d132224612724259ed40aa1b
2024-02-27 11:29:06 -07:00
Fomafix 2d65be33ab Inject service UserIdentityUtils in DefaultMainMenuBuilder
Change-Id: I5f21dac80707a0dbc81ee8910feee74108363624
2024-02-27 14:48:47 +00:00
Fomafix 0f8800ac42 Inject services in Hooks and MobileFrontendHooks
Change-Id: I8e0673689c2dbe14a385bbd1fe1725d203386bde
2024-02-27 10:15:03 +00:00
Fomafix 3bb9611497 Replace global variable by config
Use $this->overrideConfigValues instead of $this->setMwGlobals in the
test.

Change-Id: I1ae238235476a001683ea81d2b65d209a2774549
2024-02-27 06:45:34 +00:00
jenkins-bot a59ddbb849 Merge "Inject service WatchlistManager into MinervaPagePermissions" 2024-02-27 03:54:53 +00:00
jenkins-bot 476f23935c Merge "Use $this->getServiceContainer() in tests" 2024-02-27 03:54:51 +00:00
jenkins-bot e35654f1f0 Merge "Assign a default background color for tables using "wikitable" class" 2024-02-27 01:18:33 +00:00
Jon Robson 224d44d897 Increase bundle size modestly to accomodate expected night mode CSS
This has been growing gradually. Having 0.5kb of wiggle room seems
appropriate.

Change-Id: I98fa43a608327331dd72086cacf09ddf32eb3a26
2024-02-26 22:13:51 +00:00
Fomafix 6e9dde3a8a Use $this->getServiceContainer() in tests
Use
	$this->getServiceContainer()
instead of
	MediaWikiServices::getInstance()
in tests.

Change-Id: Ib6a4279e414a99dea052344f5d036f53fbf54d43
2024-02-26 20:08:42 +00:00
Fomafix 248180ef03 Inject service WatchlistManager into MinervaPagePermissions
Change-Id: Id41c85c8e119efbf9814be25ba659f1da1151eb4
2024-02-26 07:53:03 +00:00
Translation updater bot d429067861 Localisation updates from https://translatewiki.net.
Change-Id: I50a9d5384aaccf957ff37391d3a4184ad5fef545
2024-02-26 08:39:27 +01:00
anterdc99 0e068128a6
Assign a default background color for tables using "wikitable" class
Bug: T358449
Change-Id: Ia43683fe51aaffb08d08e40f5fe670d663749daa
2024-02-26 03:17:04 +08:00
Jon Robson c94c90d93d Adds color-emphasize to palette
Needed by the language overlay

Bug: T356825
Change-Id: I1d9551f1b42dec5be715e889069279f97f64749e
2024-02-23 20:21:02 +00:00
bwang dd32e6731d Add icon background styles to codex CSS icons
Bug: T358160
Change-Id: I6b7ec3c4e3837a68da98bd9f58dbade5fb4fa1ed
2024-02-23 20:20:26 +00:00
Jon Robson 9cec6a2230 Skin invert shouldn't apply in day mode.
Bug: T356425
Change-Id: Ic5c754734f7df093629d1121d61e89cd1f3225fc
2024-02-23 18:28:47 +00:00
jenkins-bot 2085354755 Merge "Allow things to be mark themselves as invert-able" 2024-02-22 15:58:51 +00:00
Translation updater bot dad3a0bf41 Localisation updates from https://translatewiki.net.
Change-Id: I3146d4ab50d488aae9da52c19d8e262b68c7b667
2024-02-22 08:46:14 +01:00
Jon Robson d32a682aad Allow things to be mark themselves as invert-able
When content is inverted via CSS filter, this sometimes inverts
CSS variables which have already been themselves inverted. Allowing
markup to explicitly mark itself as invertable would be helpful.

For now, usage is intended only for extensions integrating with
the skin. Since we're not sure this can be considered a stable
interface by editors we intentionally use the `skin-` prefix rather
than `mw-` interface given the note about confusion about what is
stable in [[mw:Stable_interface_policy/Frontend#Writing_code]]

Bug: T356425
Change-Id: I0cd0e36a6abe0bba9e98d1b319e636bef2952301
2024-02-21 15:49:26 -08:00
Jan Drewniak 7f1e394e9e Follow-up to a30b575271 Map color-based skin variables to CSS variables
Add an @import for Codex variables, i.e.
@import 'mediawiki.skin.codex-design-tokens/theme-wikimedia-ui.less';
that adds overrides to the variables from
'mediawiki.skin.defaults.less' to CSSCustomProperties.less.

Bug: T356427
Change-Id: I7c2c3a07899b4de735f7e7fd24e003ab69d449bb
2024-02-21 10:17:39 -05:00
Translation updater bot 451e3edf2f Localisation updates from https://translatewiki.net.
Change-Id: I7c07baea2de4a568667db22e0e67d99a1eea2194
2024-02-21 08:37:13 +01:00
Jon Robson cf3dc17d57 Fixes typo
Follow up to I0cd0e36a6abe0bba9e98d1b319e636bef2952301

Bug: T356427
Change-Id: I5d92328c910c8146fe0f467eb14e2036afbbbd6d
2024-02-21 02:00:12 +00:00
Jon Robson a30b575271 Map color-based skin variables to CSS variables
Additional changes:
* Separate CSSCustomProperties.less from skin.less so that
we can obtain the unmodified original values for the colors

Depends-On: I363a97d33d85a9033da753f2a8fe730d80206639
Depends-On: I148eaca747352ffdc9d1423f20d34bd5a1d0e447
Bug: T356427
Change-Id: I916450c276cabb0c7c871525c50f95fb87f498ad
2024-02-21 00:36:13 +00:00
Jon Robson 252abacc0d Increase bundlesize in anticipation of next Codex release
The increase is due to the increase in size of the cdx icon mixin.
This does not impact render blocking CSS so this is an acceptable change.

Bug: T358028
Change-Id: Icea7aa0d2f80f33fc64fd9c7721a371e115a32cb
2024-02-20 14:54:34 -08:00
jenkins-bot 7926101f48 Merge "Remove the rest of the reset" 2024-02-20 21:22:11 +00:00
Translation updater bot 12ab5d572d Localisation updates from https://translatewiki.net.
Change-Id: Ia867a5901b0f268b344ad0bfc6c7f5d9152e862b
2024-02-20 08:40:24 +01:00
Volker E d84216b0db styles: restore bold for captions in tables
This fixes the regression introduced in I6331d88e5b73.
Also un-nesting selector to necessary level.

Bug: T357849
Change-Id: I58ed32e63ad4c37aefd79edac5f1376ce4313ee3
2024-02-20 01:34:27 +01:00
Translation updater bot daa94d4b73 Localisation updates from https://translatewiki.net.
Change-Id: I9e732a7404feac8a28acefe11ec5370d2ff05e68
2024-02-19 08:43:05 +01:00
jenkins-bot b5c52e3287 Merge "Use border-color-muted CSS variable for Special:RecentChanges" 2024-02-16 18:58:00 +00:00
jenkins-bot 9f2a7a829b Merge "Add --color-link--visited to night mode palette" 2024-02-16 18:49:52 +00:00
Jon Robson 16139768c6 Use border-color-muted CSS variable for Special:RecentChanges
Bug: T356825
Change-Id: I8cc39a3150dd55f1ae65d4b4352ab3df3f053fe5
2024-02-16 10:32:50 -08:00
Jon Robson 003d9fea5b dd elements should have no margin
In 1.42.0-wmf.17 these had margin 0 in Minerva.
I incorrectly assumed we had defined an explicit margin in content
and for talk pages but apparently none exists, so I have restored
this rule to the list.less file.

Follow up to I6331d88e5b7301fd13249414350a539738cfae53

Bug: T357742
Change-Id: Ib3062bfbffe35415f479bae46ecf02e8a094958b
2024-02-16 16:56:26 +00:00
Steph Toyofuku c98508facb Add --color-link--visited to night mode palette
Right now visited links in night mode are showing the day mode style for
@color-visited, because --color-link--visited is defined, but never set
to a corresponding night mode style.  This defines the night mode
variant in the stylesheet, and sets it to the same value as
--color-visited

Visual change only in night mode, which is behind a feature flag

I also added /coverage/ to the eslintignore, as I was getting failures
on the pre-commit hook due to us linting the coverage report 🙃

Bug: T356825
Change-Id: I96695fe4c094b79385e36aef9e29b8d392c06302
2024-02-16 09:35:19 -05:00
Jon Robson 70e68aedd8 Remove the rest of the reset
VISUAL CHANGE:
* Improves top margin on User common.js for code

Bug: T205341
Change-Id: Ia402fd069341da14532d332fab7c109d34c7208d
2024-02-15 19:56:46 +00:00
David Lynch 57d1b2ab5b Add border-collapse to wikitable
Follow-up to 7c9304cbf4 which removed it
from all tables.

Bug: T357589
Change-Id: I1d62a9b2c0f571389f5cbebdc56b24ff4c325283
2024-02-15 18:28:33 +00:00
Translation updater bot acfffcdd5b Localisation updates from https://translatewiki.net.
Change-Id: I3ec6590e580b797ef4010c12445f304c5d5ced6b
2024-02-15 13:31:42 +01:00
Jon Robson 8de0d99882 Disable Extension:DarkMode on Minerva
Bug: T357598
Change-Id: I590ebe574c4c23507525a118cd99cbe31af022db
2024-02-15 01:39:43 +00:00
Jon Robson 145db70286 Reset: Drop p and div inside overlays
Required for proper presentation of page issues overlay
and multimedia viewer.

The div rules were unnecessary.

Bug: T205341
Change-Id: I6fea0f2013a11e5248b71619b795d794c8ed18ad
2024-02-14 22:20:43 +00:00
jenkins-bot 50a55bce7d Merge "Invert logos" 2024-02-14 22:00:47 +00:00
bwang 1e9de11ccf Invert logos
Bug: T356823
Change-Id: I5ccaa865197dd70afb524b3d47515ebc8e9db214
2024-02-14 21:35:27 +00:00
Steph Toyofuku 91c9e68afb Fix borders in night mode palette
Following a discussion in the ticket, update the places where `#eaecf0`
has been hardcoded to reflect whether it is intended to be a border or
background style and replace with CSS variables where applicable.  Add
`--border-color-muted` as a CSS custom property, and update the night
mode palette to use it.  Lastly, add `--color-error`, to be used in a
subsequent patch

Visual changes, but again gated behind night mode feature flag

Bug: T356825
Change-Id: Icb5741190f3e80a20dcedf9b13d6a34fe619b467
2024-02-14 16:18:21 -05:00