Skip to content
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

Alternative box-shadow for dark theme. #8475

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Conversation

isoos
Copy link
Collaborator

@isoos isoos commented Jan 17, 2025

I've been looking into the recommendations for shadows in dark mode, and the most prominent one is just to remove them like in this article. However, another article suggested a different solution, and after a bit of experimentation, I think I like that we can have the same style for both modes.

Note: while the dark background is not really visible in dark mode, the additional opaque black shadow does create a slight contrast with the opaque white inset. To me it does feel like it has some kind of natural depth.

I am a bit undecided upon the "up" or "down" effect: in this article the "elevation" of an element is connected with the darkness and narrowness of the shadow. So if we want to keep being consistent, we want to have smaller shadow on hover (as well as darker, but that's already done). However, the current pub.dev implementation increases the shadow on hover, so I've kept it for now, but maybe we should rather go with the different direction?

image image

@isoos isoos requested a review from sigurdm January 17, 2025 17:11
@isoos
Copy link
Collaborator Author

isoos commented Jan 17, 2025

Note: a staging should have this online soon (alongside with a restore from backup).

/cc @parlough

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant