Skip to content

Commit

Permalink
Update settings button on tokens page (#5085)
Browse files Browse the repository at this point in the history
# Motivation

The icon buttons that use the ripple-effect look good in the dark theme
when focused or active (eg. after mouse down), but are too dim in the
light theme. This happens because, in the light theme, the button’s
background becomes dark when focused, and the icon color is also dark.

After updates in the gix-component
(dfinity/gix-components#452), it becomes
possible to provide the text color to the icon button with the ripple
effect. Here, we update the remaining button (settings) to look good
when pressed in the light theme.

# Changes

- Explicitly set the text color for the settings button to ensure it
looks good when pressed in the light theme.

# Screenshots

## Before

<img width="161" alt="image"
src="https://github.com/dfinity/nns-dapp/assets/98811342/baa4e160-0e3c-496e-b432-75c1a529be45">

## After

<img width="203" alt="image"
src="https://github.com/dfinity/nns-dapp/assets/98811342/a595524c-fe2d-4b4a-9512-cdbc64bb6564">
  • Loading branch information
mstrasinskis authored Jun 24, 2024
1 parent 4886aff commit 8d946e1
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions frontend/src/lib/pages/Tokens.svelte
Original file line number Diff line number Diff line change
Expand Up @@ -90,11 +90,11 @@
.settings-button {
--content-color: var(--text-description);
@include effect.ripple-effect(--primary-tint);
@include effect.ripple-effect(--primary-tint, var(--primary-contrast));
&:focus {
background: var(--primary-tint);
@include effect.ripple-effect(--primary-tint);
@include effect.ripple-effect(--primary-tint, var(--primary-contrast));
}
}
Expand Down

0 comments on commit 8d946e1

Please sign in to comment.