|
59 | 59 | :host(.button-outline) { |
60 | 60 | --border-width: #{globals.$ion-border-size-025}; |
61 | 61 | --border-style: #{globals.$ion-border-style-solid}; |
62 | | - --background-activated: #{globals.$ion-bg-neutral-subtlest-press}; |
| 62 | + --background-activated: var(--ion-color-subtle-shade, #{globals.current-color(shade, $subtle: true)}); |
63 | 63 | --background-focused: transparent; |
64 | | - --background-hover: #{globals.$ion-bg-neutral-subtlest-press}; |
| 64 | + --background-hover: var(--ion-color-subtle-shade, #{globals.current-color(shade, $subtle: true)}); |
65 | 65 | --background-hover-opacity: 1; |
66 | | - --border-color: #{globals.ion-color(primary, base)}; |
67 | | - --color: #{globals.ion-color(primary, base)}; |
| 66 | + --border-color: var(--ion-color-base, #{globals.ion-color(primary, base)}); |
| 67 | + --color: var(--ion-color-base, #{globals.ion-color(primary, base)}); |
68 | 68 | --ripple-opacity: var(--background-activated-opacity, 1); |
69 | 69 | --ripple-color: var(--background-activated); |
70 | 70 | } |
71 | 71 |
|
| 72 | +// Provide fallbacks for ion-color-base for all colors |
| 73 | +:host(.button-outline.ion-color.ion-color-warning){ |
| 74 | + .button-native { |
| 75 | + --ion-color-base: #{globals.$ion-text-warning}; |
| 76 | + } |
| 77 | + ion-ripple-effect { |
| 78 | + --ion-color-base: var(--ion-color-base, #{globals.current-color(shade, $subtle: true)}); |
| 79 | + } |
| 80 | +} |
| 81 | + |
| 82 | + |
72 | 83 | // Clear Button |
73 | 84 | // -------------------------------------------------- |
74 | 85 |
|
75 | 86 | :host(.button-clear) { |
76 | | - --background-activated: #{globals.$ion-bg-neutral-subtlest-press}; |
| 87 | + --background-activated: var(--ion-color-subtle-shade, #{globals.current-color( shade, $subtle: true)}); |
77 | 88 | --background-focused: transparent; |
78 | | - --background-hover: #{globals.$ion-bg-neutral-subtlest-press}; |
| 89 | + --background-hover: var(--ion-color-subtle-shade, #{globals.current-color( shade, $subtle: true)}); |
79 | 90 | --background-hover-opacity: 1; |
80 | 91 | --color: #{globals.ion-color(primary, foreground)}; |
81 | 92 | --ripple-opacity: var(--background-activated-opacity, 1); |
82 | 93 | --ripple-color: var(--background-activated); |
83 | 94 | } |
84 | 95 |
|
| 96 | +:host(.button-clear.ion-color) { |
| 97 | + .button-native { |
| 98 | + --ion-color-base: var(--ion-color-foreground, #{globals.current-color(foreground)}); |
| 99 | + } |
| 100 | +} |
| 101 | + |
85 | 102 | // Ripple Effect |
86 | 103 | // ------------------------------------------------------------------------------- |
87 | 104 |
|
88 | 105 | :host(.button-solid.ion-color) ion-ripple-effect { |
89 | | - color: globals.current-color(shade); |
| 106 | + color: var(--ion-color-shade, #{globals.ion-color(primary, shade)}); |
90 | 107 | } |
91 | 108 |
|
92 | 109 | :host(.button-outline.ion-color) ion-ripple-effect, |
93 | 110 | :host(.button-clear.ion-color) ion-ripple-effect { |
94 | | - color: globals.$ion-primitives-neutral-200; |
| 111 | + color: var(--ion-color-subtle-shade, #{globals.current-color(shade, $subtle: true)}); |
95 | 112 | } |
96 | 113 |
|
97 | 114 | // Button Sizes |
|
0 commit comments