-
Notifications
You must be signed in to change notification settings - Fork 2.1k
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
fix(select): Fix dropdown color/opacity and options background #3553
Conversation
packages/mdc-select/_mixins.scss
Outdated
@@ -147,7 +147,10 @@ | |||
} | |||
} | |||
|
|||
@mixin mdc-select-dd-arrow-svg-bg_($fill-hex-number: 000000, $opacity: .54) { | |||
@mixin mdc-select-dd-arrow-svg-bg_($fill-hex-number: #000000, $opacity: .54) { | |||
// Remove leading # from |
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.
Is this comment missing some words? Or drop "from"?
packages/mdc-select/_mixins.scss
Outdated
@@ -147,7 +147,10 @@ | |||
} | |||
} | |||
|
|||
@mixin mdc-select-dd-arrow-svg-bg_($fill-hex-number: 000000, $opacity: .54) { | |||
@mixin mdc-select-dd-arrow-svg-bg_($fill-hex-number: #000000, $opacity: .54) { |
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.
- Remove the default value for the first parameter since we always specify it
- Should the default opacity be represented in a variable? Should we also always specify that in the mixin invocation rather than providing a default? (Currently we pass 1 parameter in one invocation, and 2 parameters in the other)
@@ -89,6 +89,8 @@ | |||
|
|||
// stylelint-disable-next-line selector-max-type, plugin/selector-bem-pattern | |||
> option { | |||
@include mdc-theme-prop(background-color, surface); |
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.
What effect does this have on native selects?
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 causes the background-color
to be the surface
color on browsers that allow it. Since we're changing the color on Line 94, we also need to adjust the background-color. On browsers that don't allow modifications to the dropdown options, neither of these apply and the dropdown is rendered with a white background and black text.
fixes: #3550