-
Notifications
You must be signed in to change notification settings - Fork 6.8k
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(material/tabs): deprecate backgroundColor API #28262
Conversation
src/material/tabs/tab-group.ts
Outdated
@Input() | ||
get backgroundColor(): ThemePalette { | ||
return this._backgroundColor; | ||
} | ||
|
||
set backgroundColor(value: ThemePalette) { | ||
const classList: DOMTokenList = this._elementRef.nativeElement.classList; | ||
if (ENABLE_BACKGROUND_INPUT) { |
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.
nit: maybe we should log a warning here if it's disabled so that internal users don't wonder why it does nothing?
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.
Totally - in fact I'd take this one step further and throw an Error to say it's not a valid input. I wish it was namespaced more specifically just in case it's used by a sibling directive, but I don't expect that to be likely.
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.
The Error will help perform a migration to catch all usages before we disable it
5d8fc8b
to
3891451
Compare
3891451
to
78e891c
Compare
(cherry picked from commit 771f1df)
This issue has been automatically locked due to inactivity. Read more about our automatic conversation locking policy. This action has been performed automatically by a bot. |
Tabs background colors should be customized using the theming API instead of using component inputs. Adding a boolean check that can be modified internally to perform cleanup before v20.