Skip to content

Commit

Permalink
remove background style for disabled buttons on hover and active, and…
Browse files Browse the repository at this point in the history
… avoid creating agin the opacity token
  • Loading branch information
brichet committed Nov 17, 2023
1 parent fb2b587 commit 0c639e5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 10 deletions.
5 changes: 0 additions & 5 deletions packages/components/src/button/button.styles.ts
Original file line number Diff line number Diff line change
Expand Up @@ -660,11 +660,6 @@ export const buttonStyles: (
appearanceBehavior(
'stealth',
css`
:host([appearance='stealth'][disabled]:hover),
:host([appearance='stealth'][disabled]:active) {
background: ${neutralFillStealthRest};
}
${StealthButtonStyles}
`.withBehaviors(
forcedColorsStylesheetBehavior(css`
Expand Down
8 changes: 3 additions & 5 deletions packages/components/src/design-tokens.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ import {
accentForegroundHoverDelta,
accentForegroundRestDelta,
ColorRecipe,
disabledOpacity,
fillColor,
InteractiveColorRecipe,
InteractiveSwatchSet,
Expand Down Expand Up @@ -64,6 +65,7 @@ export {
designUnit,
direction,
DirectionalStyleSheetBehavior,
disabledOpacity,
fillColor,
focusStrokeInner,
focusStrokeInnerRecipe,
Expand Down Expand Up @@ -173,11 +175,7 @@ export {

const { create } = DesignToken;

/**
* The default disabled opacity.
*/
export const disabledOpacity =
DesignToken.create<number>('opacity').withDefault(0.4);
disabledOpacity.withDefault(0.4);

/*
* The error palette is built using the same color algorithm as the accent palette
Expand Down

0 comments on commit 0c639e5

Please sign in to comment.