-
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
feat(tab): Implement a ripple color mixin for Tab #4421
Changes from 2 commits
e5a8bd6
d0db5c3
40c4a67
504dbe9
df208c1
5276f45
ad53d28
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,6 +20,7 @@ | |
// THE SOFTWARE. | ||
// | ||
|
||
@import "@material/ripple/mixins"; | ||
@import "@material/theme/mixins"; | ||
|
||
// Public mixins | ||
|
@@ -36,6 +37,17 @@ | |
} | ||
} | ||
|
||
@mixin mdc-tab-ripple-color($color) { | ||
.mdc-tab__ripple { | ||
@include mdc-states($color); | ||
} | ||
} | ||
|
||
@mixin mdc-tab-ink-color($color) { | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Since this is here... should this also set mdc-tab-icon-color so that everything is set together? (I forget why text and icon color were originally separate, maybe @patrickrodee can weigh in on this.) There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. We had separate mixins for text and icon in other components when I added these mixins. Setting There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Makes sense, my definition of ink was outdated. Done. |
||
@include mdc-tab-text-label-color($color); | ||
@include mdc-tab-ripple-color($color); | ||
} | ||
|
||
@mixin mdc-tab-parent-positioning { | ||
position: relative; | ||
} | ||
|
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.
Should we call this mdc-tab-states-color given that it's invoking mdc-states?
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.
That's a good idea.
Just an aside: the mixed naming between "ripple" and "states" keeps tripping me up.
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.
SGTM, done.