ZIm/crates/ui/src/components/button
Danilo Leal 115aa43354
Adjust TintColor color token terminology (#22826)
Previously, to use a green and red shade with `TintColor` you'd need to
pass `Positive` and `Negative`, respectively. This terminology always
tripped me up, because, for example, I'd often try to use something
like:

```
Button::new("icon_color", "Negative")
      style(ButtonStyle::Tinted(TintColor::Negative))
      .color(Color::Error)
      .icon_color(Color::Error)
      .icon(IconName::Trash),
)
```

...and due to `icon_color` taking `Color::Error`, I'd always get
`TintColor` wrong at a first try, because I would, out of muscle memory,
write `TintColor::Error`, which wouldn't compile. That's exactly the
change in this PR—`TintColor` now takes `Success` and `Error` instead of
`Positive` and `Negative`, for more consistency.


Release Notes:

- N/A
2025-01-08 14:40:48 +00:00
..
button.rs Adjust TintColor color token terminology (#22826) 2025-01-08 14:40:48 +00:00
button_icon.rs Toggle & Switch (#21979) 2024-12-13 14:23:02 -05:00
button_like.rs Adjust TintColor color token terminology (#22826) 2025-01-08 14:40:48 +00:00
icon_button.rs Toggle & Switch (#21979) 2024-12-13 14:23:02 -05:00
toggle_button.rs Toggle & Switch (#21979) 2024-12-13 14:23:02 -05:00