-
Notifications
You must be signed in to change notification settings - Fork 3.4k
fix(menu): support dark themes and non-grey backgrounds #9212
Conversation
@clshortfuse i'm not sure it's correct by the material design spec, |
@EladBezalel I see. Strange because that's not how Android's implementation of Material works. Still, there is an issue because it's not using the right contrast values causing issues if you use anything other than gray. I'll update it to be lighter but still support changing backgroundPalette. |
b0a5e5a
to
25554da
Compare
@clshortfuse dropdown menus should always be white: |
Add opacity keyword support (`secondary`, `icon`, `disabled`, `hint`, `divider`) Deprecate documentation of `foreground-*` in favor of `background-default-contrast-*` Allow `foregroundPallete` to override colors on default background and hues of equal contrast type
Menu popups should always be lightly colored and its content should use their respective contrast color and opactiy. - Set background color to background-50 - Use contrast values for buttons, icons, and dividers Fixes angular#9100
I took a colorpicker against the dropdown menu and it's not white. It's What it looks like now: If we want to hardcode the colors (#FAFAFA), it'll create some complications if the user decides to change the foreground color and/or use a dark theme. Perhaps we can add support in mdTheme for referencing by palette name, for example |
25554da
to
aca037f
Compare
@EladBezalel can you take a look at it now that I switched to |
So i'm really not sure what we should assume about background colors.. If we had a clear spec that said |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This PR gives the following behavior (after rebasing, see this branch)
After we made a bunch of dark theme updates, 1.1.20
now gives this behavior
We're going to stick with the current behavior in 1.1.20
as it better aligns with our expectations of dark mode.
Menu popups should always be lightly colored and its content
should use their respective contrast color and opactiy.
Fixes #9100