Page MenuHomePhabricator

Codex tokens: Implement new box-shadows and deprecate `box-shadow-drop-*` tokens
Closed, ResolvedPublic1 Estimated Story Points

Description

Background

As a result of the design decisions made in T382024: Shadows: revisit box-shadow-drop tokens, we need to implement the new shadows within Codex. Original iteration was in T297003: Define the system's box shadow styles.

Developer notes

The reason for providing box-shadow shorthand tokens is that we have a few often used box-shadow combos, but then also numerous colors with just a few directionalities. Making this split useful for consistency and application. That was also the original plan on splitting the directionalities from the colors.

box-shadow-color-base at a commit in the past has changed from before transparent color to a solid black. In order to make base not be a transparent color, which seemed bad to designers and myself behind the decision back then. -base has just never been used in action ever since.
Also for completion usage of
CodeSearch all transparent carrying shadows and CodeSearch all opacity 0 carrying ones.

Accessibility note

Even though the box-shadows with border combinations aren't currently 100% fulfilling contrast, we refrain for the time being from lowering the contrast even further to accommodate a bigger group of users of different visual acuity or device low contrast environments (sunset and similar).

Acceptance criteria

Design

  • Include the new shadows in the Figma library

Development

  • Restructure box-shadow tokens
  • Update box-shadow tokens
  • Add new 300 level/large box-shadow token
  • Deprecate 500 level/xx-large box-shadow token
  • Update components to use or not use new shadows
  • Write brief guidance on box-shadow page

Event Timeline

Change #1110892 had a related patch set uploaded (by Dtorsani; author: Dtorsani):

[design/codex@main] tokens, components: Add new and update box-shadow tokens and components they apply to

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

From the PatchDemo an example of a (OOUI) ProgressBar in action with shadow

image.png (2,422×1,016 px, 168 KB)

@Volker_E Makes sense that this one will differ slightly since it is OOUI, right?

Not quite sure, why PatchDemo hasn't posted the link automatically as I've put the checkmark there, but here we go:
https://5648f3da62.catalyst.wmcloud.org/wiki/Main_Page

@Volker_E Makes sense that this one will differ slightly since it is OOUI, right?

@DTorsani-WMF This was meant as example of a progress bar "laying" flat on canvas, instead of application loading as done in VE. I haven't seen many of these cases in implementation so wanted to share in order for us to also consider if the new box-shadow works here (when Codex will replace this occurrence).

Volker_E renamed this task from Implement new Codex box-shadows to Codex tokens: Implement new box-shadows and deprecate `box-shadow-drop-*` tokens.Feb 6 2025, 3:48 AM
Volker_E updated the task description. (Show Details)
Volker_E updated the task description. (Show Details)

Change #1110892 merged by jenkins-bot:

[design/codex@main] [DEPRECATING CHANGE] tokens, components: Add new and update box-shadow tokens and apply

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

@CCiufo-WMF The assigned '1' was clearly not rightfully representative of all the work that flew into this. More like a 2 or even a 3.

Change #1118607 had a related patch set uploaded (by VolkerE; author: VolkerE):

[design/codex@main] build: Limit color references only to `box-shadow` colors, not to all tokens

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

Change #1118607 merged by jenkins-bot:

[design/codex@main] build: Limit color references only to `box-shadow` colors, not to all tokens

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

Change #1121109 had a related patch set uploaded (by VolkerE; author: VolkerE):

[mediawiki/core@master] Update Codex from v1.20.1 to v1.20.2

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

Change #1121109 merged by jenkins-bot:

[mediawiki/core@master] Update Codex from v1.20.1 to v1.20.2

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