Skip to content

fix(material/select): remove internal-only M2 styles #31022

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 1 commit into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
13 changes: 3 additions & 10 deletions src/material/select/_m2-select.scss
Original file line number Diff line number Diff line change
Expand Up @@ -19,16 +19,9 @@ $prefix: (mat, select);
// Tokens that can be configured through Angular Material's color theming API.
@function get-color-tokens($theme, $palette-name: primary) {
$is-dark: inspection.get-theme-type($theme) == dark;

// Ideally we would derive all values directly from the theme, but it causes a lot of regressions
// internally. For now we fall back to the old hardcoded behavior only for internal apps.
$on-surface: if($is-dark, #fff, #000);
$text-color-base: if(m2-utils.$private-is-internal-build, $on-surface,
inspection.get-theme-color($theme, foreground, text, 1));
$disabled-text-color-base: if(m2-utils.$private-is-internal-build, $on-surface,
inspection.get-theme-color($theme, foreground, disabled-text, 1));
$icon-color-base: if(m2-utils.$private-is-internal-build, $on-surface,
inspection.get-theme-color($theme, foreground, divider, 1));
$text-color-base: inspection.get-theme-color($theme, foreground, text, 1);
$disabled-text-color-base: inspection.get-theme-color($theme, foreground, disabled-text, 1);
$icon-color-base: inspection.get-theme-color($theme, foreground, divider, 1);

@return (
panel-background-color: inspection.get-theme-color($theme, background, card),
Expand Down
Loading