Skip to content

Commit

Permalink
fix(item): use the global activated background for md ripple color (#…
Browse files Browse the repository at this point in the history
  • Loading branch information
brandyscarney authored Apr 24, 2019
1 parent 33acd78 commit 95945c0
Show file tree
Hide file tree
Showing 5 changed files with 18 additions and 14 deletions.
22 changes: 11 additions & 11 deletions core/src/components/fab-button/fab-button.scss
Original file line number Diff line number Diff line change
Expand Up @@ -4,17 +4,6 @@
// --------------------------------------------------

:host {
--transition: background-color, opacity 100ms linear;
--ripple-color: currentColor;
--border-radius: #{$fab-border-radius};
--border-width: 0;
--border-style: none;
--border-color: initial;
--padding-top: 0;
--padding-end: 0;
--padding-bottom: 0;
--padding-start: 0;

/**
* @prop --background: Background of the button
* @prop --background-activated: Background of the button when activated
Expand All @@ -40,6 +29,17 @@
* @prop --padding-bottom: Padding bottom of the button
* @prop --padding-start: Padding start of the button
*/
--transition: background-color, opacity 100ms linear;
--ripple-color: currentColor;
--border-radius: #{$fab-border-radius};
--border-width: 0;
--border-style: none;
--border-color: initial;
--padding-top: 0;
--padding-end: 0;
--padding-bottom: 0;
--padding-start: 0;

@include margin(0);
display: block;

Expand Down
2 changes: 1 addition & 1 deletion core/src/components/item/item.scss
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@
--detail-icon-color: initial;
--detail-icon-font-size: 20px;
--detail-icon-opacity: 0.25;
--ripple-color: currentColor;
--ripple-color: var(--ion-item-background-activated, currentColor);

@include font-smoothing();

Expand Down
3 changes: 3 additions & 0 deletions core/src/themes/test/css-variables/css/dark.css
Original file line number Diff line number Diff line change
Expand Up @@ -24,4 +24,7 @@
--ion-background-color-rgb: 23,23,23;
--ion-background-color-rgb: 0,0,0;
--ion-text-color-rgb: 255,255,255;

--ion-item-background: #1b2025;
--ion-item-background-activated: #051b35;
}
1 change: 1 addition & 0 deletions core/src/themes/test/css-variables/css/vibrant.css
Original file line number Diff line number Diff line change
Expand Up @@ -77,4 +77,5 @@
--ion-background-color: #778899;
--ion-item-background: #fff;
--ion-item-border-color: #5bff76;
--ion-item-background-activated: #5bff76;
}
4 changes: 2 additions & 2 deletions core/src/themes/test/css-variables/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -141,11 +141,11 @@
<ion-label>Super Metroid</ion-label>
<ion-note slot="end">Note</ion-note>
</ion-item>
<ion-item>
<ion-item href="#">
<ion-label>Mega Man X</ion-label>
<ion-note slot="end">Note</ion-note>
</ion-item>
<ion-item>
<ion-item href="#" class="activated">
<ion-label>The Legend of Zelda</ion-label>
<ion-note slot="end">Note</ion-note>
</ion-item>
Expand Down

0 comments on commit 95945c0

Please sign in to comment.