Skip to content

Commit c814794

Browse files
committed
fix(button): use correct styles for the focused state and clear color
1 parent 9bfe374 commit c814794

File tree

2 files changed

+3
-14
lines changed

2 files changed

+3
-14
lines changed

core/src/components/button/button.common.scss

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -96,7 +96,7 @@
9696
:host(.button-clear) {
9797
--border-width: 0;
9898
--background: transparent;
99-
--color: #{ion-color(primary, base)};
99+
--color: #{ion-color(primary, foreground)};
100100
}
101101

102102
// Block Button
@@ -289,7 +289,7 @@ ion-ripple-effect {
289289
// Clear Button with Color
290290
:host(.button-clear.ion-color) .button-native {
291291
background: transparent;
292-
color: current-color(base);
292+
color: current-color(foreground);
293293
}
294294

295295
// Button in Toolbar

core/src/components/button/button.ionic.scss

Lines changed: 1 addition & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -45,8 +45,7 @@
4545
:host(.button-solid) {
4646
--background-activated: #{globals.ion-color(primary, shade)};
4747
--background-hover: #{globals.ion-color(primary, contrast)};
48-
--background-focused: #{globals.ion-color(primary, contrast)};
49-
--background-focused-opacity: 0.24;
48+
--background-focused: transparent;
5049
--background-hover-opacity: 0.08;
5150
--ripple-opacity: var(--background-activated-opacity, 1);
5251
--ripple-color: var(--background-activated);
@@ -217,16 +216,6 @@
217216
outline-offset: globals.$ion-border-size-050;
218217
}
219218

220-
/**
221-
* Only allow overriding of opacity here
222-
* as developers should not be overriding
223-
* colors when using the color prop.
224-
*/
225-
226-
:host(.button-solid.ion-color.ion-focused) .button-native::after {
227-
background: globals.current-color(contrast);
228-
}
229-
230219
// Button: Activated
231220
// --------------------------------------------------
232221

0 commit comments

Comments
 (0)