Page MenuHomePhabricator

Math formulas have a white background in dark mode on Minerva
Closed, ResolvedPublic1 Estimated Story PointsBUG REPORT

Description

Steps to replicate the issue (include links if applicable):

What happens?:

It appears on a white background in light theme

Screenshot 2024-05-29 at 1.32.33 PM.png (154×540 px, 18 KB)

What should have happened instead?:

The formula should be white and the background should be the same as the citation drawer around it. This behaviour is currently correct in light mode.

Screenshot 2024-05-29 at 1.33.00 PM.png (261×1 px, 58 KB)

Software version (on Special:Version page; skip for WMF-hosted wikis like Wikipedia):

Other information (browser name/version, screenshots, etc.):

  • Acceptance criteria **
  • Make sure skin-invert always applies inside the reference drawer e.g.
.references-drawer .skin-invert { filter: invert(1); }

QA Results - Beta

ACStatusDetails
1T366220#9992857

QA Results - PROD

ACStatusDetails
1T366220#9997106

Event Timeline

Jdlrobson triaged this task as Medium priority.May 29 2024, 11:36 PM
Jdlrobson updated the task description. (Show Details)

.references-drawer .skin-invert { filter: invert(1); }

You'll want to use the full colour-rotating inversion rule, as math can contain colours.

Jdlrobson set the point value for this task to 1.May 30 2024, 5:52 PM

When we switch to MathML (T271001) this will not be a problem and we may want to consider undo-ing this rule .

When we switch to MathML (T271001) this will not be a problem and we may want to consider undo-ing this rule .

It is already available as opt-in in user preferences. Will this change hide the formula for the users who opted in for MathML?

The issue is already fixed for users who opted in for MathML. The fix here would not impact this as it only applies to images.

When we switch to MathML (T271001) this will not be a problem and we may want to consider undo-ing this rule .

We would need the rule as long as math images are an option.

Jdlrobson lowered the priority of this task from Medium to Low.May 31 2024, 8:08 PM

When MathML is enabled, yes.. but not for anonymous page views.

When MathML is enabled, yes.. but not for anonymous page views.

...unless they use the native MathML plugin, cf. https://www.mediawiki.org/wiki/Extension:Math#Viewing_math

bwang removed bwang as the assignee of this task.Jul 10 2024, 4:07 PM
bwang moved this task from Doing to Code Review on the Web-Team-Backlog (FY2024-25 Q1 Sprint 1) board.
bwang subscribed.

Change #1053754 had a related patch set uploaded (by Bernard Wang; author: Bernard Wang):

[mediawiki/extensions/MobileFrontend@master] Fix MathML Drawers in dark and light mode

https://gerrit.wikimedia.org/r/1053754

Change #1053754 merged by jenkins-bot:

[mediawiki/extensions/MobileFrontend@master] Fix MathML Drawers in dark and light mode

https://gerrit.wikimedia.org/r/1053754

I don't understand the patch. Would that interfere with our intention to switch to native MathML rendering by default?

@Physikerwelt sorry for the confusion. No it doesn't interfere.

@Jdlrobson Please review issue from Light mode as seen in the gif, thanks!

Test Result - Beta

Status: ✅ PASS
Environment: Beta
OS: macOS Sonoma 14.5
Browser: Chrome 126
Device: MBA
Emulated Device: NA

Test Artifact(s):

Test Steps
  1. Click on [1] https://en.m.wikipedia.beta.wmflabs.org/wiki/Reflexive_space in light mode
  2. Click on [1] https://en.m.wikipedia.beta.wmflabs.org/wiki/Reflexive_space in dark mode
LightDark
Only can do it via &minervanightmode=0
2024-07-17_15-01-52.png (1×2 px, 302 KB)
}
No white background
2024-07-17_14-17-33.png (1×2 px, 320 KB)

❌ FAIL- Needs More work
I can't switch to light mode in mobile view

2024-07-17_14-31-50.mp4.gif (654×1 px, 1 MB)

@Jdlrobson Black drawer box is fine in light mode?

Test Result - PROD

Status: ✅ PASS
Environment: PROD
OS: macOS Sonoma 14.5
Browser: Chrome 126
Device: MBA
Emulated Device: NA

Test Artifact(s):

Test Steps
  1. Click on [1] https://en.m.wikipedia.org/wiki/Reflexive_space in light mode
  2. Click on [1] https://en.m.wikipedia.org/wiki/Reflexive_space in dark mode
LightDark
Black Drawer box is fine in light mode?
2024-07-18_15-15-40.png (1×2 px, 389 KB)
2024-07-18_15-14-59.png (1×2 px, 390 KB)
ovasileva claimed this task.