Page MenuHomePhabricator

Minerva reference drawer should have a light background
Open, MediumPublic

Description

Per T129054#3428646 and T129054#8363253, and the fact that other drawers in MF are white, as is the reference drawer on other platforms (Android/iOS).

Caused issues T129054 & T357988

As pointed out by @Diskdance the existing reference drawer has accessibility issues relating to the "Citation" header:

(it) has a background color of #000 (out of palette), text color of #c8ccd1 which is background-color-interactive--active (wrong semantics), heading color of color-subtle (which fails WCAG AA on this background), icon color of border-color-base (???).
All of these should use color tokens from Codex design tokens.

Event Timeline

Change #1015287 had a related patch set uploaded (by Esanders; author: Esanders):

[mediawiki/extensions/MobileFrontend@master] Remove black background from references drawer

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

Quoting relevant parts of previous task:

I propose we use the same drawer pattern as of warning messages like this >

Simulator Screen Shot Jul 11, 2017, 5.05.52 PM.png (1×750 px, 138 KB)

We can borrow the dismiss mechanism + browser support + fallback

Here's how the citations will look with the above drawer pattern

iPhone 7 Copy.png (1×750 px, 181 KB)

iPhone 7.png (1×750 px, 220 KB)

Only one drawback of this
We won't have a title that says "citation"
right now we have a very grey uppercase random icon and title which doesn't work. I don't think it's adding much value.
being said that, we do have drawer use cases where we _do_ need a title, in that case we should redo the title part of our drawer pattern.

for this task, let's just re-use it.

@Cenarium what do you think?

...

@Jdlrobson it seems like all 3 options use the drawer, and the differences are whether the drawer is white or black, and whether the math formula has a white background? I'm not sure what the rules are on when the drawer is black vs when it is white, but the white one is much easier to read, so we should use that if possible:

iPhone 7 Copy.png (1×750 px, 181 KB)

if we can't use that this is fine:

pasted_file (153×489 px, 29 KB)

...

For reference, the Android app also uses light drawers, with and additional dark overlay for the content area:

Screenshot_20240325-104550.png (2×1 px, 357 KB)

...

...as does MobileFrontend for the CTA drawer, used for redlinks, and actions while logged

image.png (397×450 px, 31 KB)
image.png (397×450 px, 37 KB)
ovasileva triaged this task as Medium priority.Jun 13 2024, 5:19 PM
ovasileva subscribed.

Discussed in task sync and we don't think we need this for the initial deploy. (will do T357988: Reference drawer: Visited links have insufficient contrast in Minerva in light theme as a quick fix instead) Would it be possible to expand the description on this one a bit as well so that it's easier to see what is needed here for the future? Maybe we can use https://www.mediawiki.org/w/index.php?title=Reading/Web/Request_process for the task template?

Unrelated to night mode issues this seems like a sensible fix, and is quite small change.

Is it the case that the reference drawer will be switch to have both light and dark modes in the future? I'm making a gadget that will have the same appearance with these drawers, hence asking for confirmation.

Test wiki on Patch demo by ESanders (WMF) using patch(es) linked to this task was deleted:

https://patchdemo.wmcloud.org/wikis/d4a3381c48/w/

Is it the case that the reference drawer will be switch to have both light and dark modes in the future? I'm making a gadget that will have the same appearance with these drawers, hence asking for confirmation.

Here's how dark mode looks:

Before patchAfter patch
image.png (937×434 px, 168 KB)
image.png (937×434 px, 161 KB)