Skip to content
This repository was archived by the owner on Jan 13, 2025. It is now read-only.

Commit 9f37016

Browse files
authored
fix(card): Use on-surface color for action icons (#4519)
1 parent a8a6660 commit 9f37016

File tree

3 files changed

+8
-6
lines changed

3 files changed

+8
-6
lines changed

packages/mdc-card/_mixins.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -174,7 +174,7 @@
174174

175175
.mdc-card__action-icons {
176176
@include mdc-feature-targets($feat-color) {
177-
@include mdc-theme-prop(color, text-icon-on-background);
177+
@include mdc-theme-prop(color, $mdc-card-action-icon-color);
178178
}
179179

180180
@include mdc-feature-targets($feat-structure) {
@@ -264,7 +264,7 @@
264264

265265
.mdc-card__action--icon:not(:disabled) {
266266
@include mdc-feature-targets($feat-color) {
267-
@include mdc-theme-prop(color, text-icon-on-background);
267+
@include mdc-theme-prop(color, $mdc-card-action-icon-color);
268268
}
269269
}
270270

packages/mdc-card/_variables.scss

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,8 @@
2121
//
2222

2323
@import "@material/theme/mixins";
24+
@import "@material/theme/variables";
2425

26+
$mdc-card-action-icon-color: rgba(mdc-theme-prop-value(on-surface), mdc-theme-text-emphasis(medium)) !default;
2527
$mdc-card-outline-color: mix(mdc-theme-prop-value(on-surface), mdc-theme-prop-value(surface), 12%) !default;
2628
$mdc-card-outline-width: 1px !default;

test/screenshot/golden.json

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -160,11 +160,11 @@
160160
}
161161
},
162162
"spec/mdc-card/classes/media.html": {
163-
"public_url": "https://storage.googleapis.com/mdc-web-screenshot-tests/travis/2018/11/02/14_50_15_747/spec/mdc-card/classes/media.html?utm_source=golden_json",
163+
"public_url": "https://storage.googleapis.com/mdc-web-screenshot-tests/kfranqueiro/2019/03/25/21_32_26_116/spec/mdc-card/classes/media.html?utm_source=golden_json",
164164
"screenshots": {
165-
"desktop_windows_chrome@latest": "https://storage.googleapis.com/mdc-web-screenshot-tests/travis/2018/11/02/14_50_15_747/spec/mdc-card/classes/media.html.windows_chrome_69.png",
166-
"desktop_windows_firefox@latest": "https://storage.googleapis.com/mdc-web-screenshot-tests/travis/2018/11/02/14_50_15_747/spec/mdc-card/classes/media.html.windows_firefox_62.png",
167-
"desktop_windows_ie@11": "https://storage.googleapis.com/mdc-web-screenshot-tests/travis/2018/11/02/14_50_15_747/spec/mdc-card/classes/media.html.windows_ie_11.png"
165+
"desktop_windows_chrome@latest": "https://storage.googleapis.com/mdc-web-screenshot-tests/kfranqueiro/2019/03/25/21_32_26_116/spec/mdc-card/classes/media.html.windows_chrome_72.png",
166+
"desktop_windows_firefox@latest": "https://storage.googleapis.com/mdc-web-screenshot-tests/kfranqueiro/2019/03/25/21_32_26_116/spec/mdc-card/classes/media.html.windows_firefox_65.png",
167+
"desktop_windows_ie@11": "https://storage.googleapis.com/mdc-web-screenshot-tests/kfranqueiro/2019/03/25/21_32_26_116/spec/mdc-card/classes/media.html.windows_ie_11.png"
168168
}
169169
},
170170
"spec/mdc-card/mixins/color-and-shape.html": {

0 commit comments

Comments
 (0)