Skip to content

[Visual Refresh] Shadow tokens #8880

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 20 commits into
base: eui-theme/borealis-v2-poc
Choose a base branch
from

Conversation

acstll
Copy link
Contributor

@acstll acstll commented Jul 17, 2025

Summary

Implements https://github.com/elastic/eui-private/issues/195

Important

This PR targets a feature branch!

Docs draft: https://eui.elastic.co/pr_8880/docs/getting-started/theming/tokens/shadows/

Changes

  • Added new shadow tokens f48fbfc
  • Defined shadow tokens for Amsterdam, based on values from original mixins bbea477
    • in Amsterdam nothing should have changed
    • added a flat token to keep euiShadowFlat unchanged
    • in Borealis, flat falls back to xs
  • Updated mixins to use the new tokens
  • Added a docs page to Theming / Tokens / Shadows
  • Added tokens as JSON, Borealis-only
  • Added tokens as SCSS and update SCSS mixins 25ed168
  • Deprecated because undocumented and/or no longer needed
    • euiSlightShadowHover
    • euiShadowFlat
    • EuiShadowOptions.color
    • EuiShadowCustomColor
  • Added unit test to ensure overrides in theme.modify work as expected c3b2896
  • Updated VRT 1eb9aa6

Why are we making this change?

This is part of the Visual Refresh project.

Screenshots

N/A

Impact to users

No impact for users. The visual aspect of shadows is slightly different.

QA

Remove or strikethrough items that do not apply to your PR.

General checklist

  • Browser QA
    • Checked in both light and dark modes
    • Checked in both MacOS and Windows high contrast modes
    • Checked in mobile
    • Checked in Chrome, Safari, Edge, and Firefox
    • Checked for accessibility including keyboard-only and screenreader modes
  • Docs site QA
  • Code quality checklist
  • Release checklist
    • A changelog entry exists and is marked appropriately.
    • If applicable, added the breaking change issue label (and filled out the breaking change checklist)
  • Designer checklist
    • If applicable, file an issue to update EUI's Figma library with any corresponding UI changes. (This is an internal repo, if you are external to Elastic, ask a maintainer to submit this request)

@acstll acstll self-assigned this Jul 17, 2025
@acstll acstll added skip-changelog Use on PRs to skip changelog requirement (Don't delete - used for automation) visual refresh labels Jul 17, 2025
@mgadewoll mgadewoll self-requested a review July 21, 2025 08:26
@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

History

cc @acstll

@elasticmachine
Copy link
Collaborator

💚 Build Succeeded

History

cc @acstll

@acstll
Copy link
Contributor Author

acstll commented Jul 21, 2025

There is an issue with dark mode in EuiPanel. The new shadows include a slight light border in dark mode. Panels also have a very similar border (in order to make the panel more visible). So this border is double the size because they add up.

I'm working on removing this extra border for dark mode but it's not straightforward because of the many moving parts (Borealis/Amsterdam, accessibility, color mode, shadow/border props).

Toggle screenshot Screenshot 2025-07-19 at 09 26 15

Edit: solving the double-border-in-dark-mode issue is not straightforward. I'm putting that on hold until we understand the problem better.

@acstll acstll marked this pull request as ready for review July 21, 2025 13:23
@acstll acstll requested a review from a team as a code owner July 21, 2025 13:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
skip-changelog Use on PRs to skip changelog requirement (Don't delete - used for automation) visual refresh
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants