Refactor: one colorFade transition replaces internal.Fade
textInputFade becomes colorFade in theme.go and serves AvatarGroup, Image retry, Tag and EditableText, which used internal.Fade. MyGo already skips element transitions under ReduceMotion, so dropping the Motion check keeps behaviour.
This commit is contained in:
11 files changed
+167
-21
No files matched your search
+1
-1
@@ -48,7 +48,7 @@ func Checkbox(c *ui.Context, value *bool, label string, opts CheckboxOptions) *u
|
||||
bg, border := checkboxColors(k, on || mixed, hover, pressed)
|
||||
box := ui.Box(c).Size(checkboxSize, checkboxSize).Shrink(0).Radius(theme.ControlRadius).
|
||||
Background(bg).Border(theme.BorderWidth, border)
|
||||
box.Transition(textInputFade)
|
||||
box.Transition(colorFade)
|
||||
box.DrawOver(func(p *ui.Painter, r ui.Rect) {
|
||||
switch {
|
||||
case mixed:
|
||||
|
||||
Reference in new issue
Block a user