Skip to content

Use CSS for muted-blocking animation - #138

Draft
danirabbit wants to merge 6 commits into
mainfrom
muted-blocking-animation
Draft

Use CSS for muted-blocking animation#138
danirabbit wants to merge 6 commits into
mainfrom
muted-blocking-animation

Conversation

@danirabbit

@danirabbit danirabbit commented Mar 3, 2020

Copy link
Copy Markdown
Member

Fixes #137
Fixes #136

Instead of changing icon name, we transition color with CSS and add a little wiggle while we're at it

Since the current muted icon in the icon set is partial opacity, that is also preserved here. This will need to be changed in icons.

Made the transition a bit faster because:

  • We have a wiggle to help it be noticeable
  • It looks weird for it to linger too long if we unmute

@danirabbit
danirabbit requested a review from cassidyjames March 3, 2020 22:07
Comment thread data/indicator.css
Comment on lines +43 to +49
@keyframes volume-blocking {
0% { -gtk-icon-transform: rotate(20deg); }
25% { -gtk-icon-transform: rotate(-20deg); }
50% { -gtk-icon-transform: rotate(10deg); }
75% { -gtk-icon-transform: rotate(-10deg); }
100% { -gtk-icon-transform: rotate(5deg); }
}

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I like it in general, but the rotation feels weird to me since that icon is not visually weighted in the center. What about a side-to-side wiggle?

Suggested change
@keyframes volume-blocking {
0% { -gtk-icon-transform: rotate(20deg); }
25% { -gtk-icon-transform: rotate(-20deg); }
50% { -gtk-icon-transform: rotate(10deg); }
75% { -gtk-icon-transform: rotate(-10deg); }
100% { -gtk-icon-transform: rotate(5deg); }
}
@keyframes volume-blocking {
20% { -gtk-icon-transform: translateX(4px); }
40% { -gtk-icon-transform: translateX(-4px); }
60% { -gtk-icon-transform: translateX(2px); }
80% { -gtk-icon-transform: translateX(-2px); }
100% { -gtk-icon-transform: translateX(1px); }
}

@danirabbit

Copy link
Copy Markdown
Member Author

This also has an issue with light wallpapers where the transition to change color is very long. So it seems like we need some kind of other approach for transitioning back

@jeremypw

Copy link
Copy Markdown
Collaborator

@danrabbit I am converting this to draft as it blocked and there is no recent activity.

@jeremypw
jeremypw marked this pull request as draft May 11, 2021 17:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

change muted-blocking color with CSS Delay in icon color change of sound/audio settings from yellow to gray

3 participants