button: Use primary or danger color for the disable background. (#252)
<img width="1624" alt="image" src="https://github.com/user-attachments/assets/61162ba5-9188-4cad-a154-2584abd0fd31"> Fix #251
This commit is contained in:
parent
8f0ba2e5c3
commit
d641c219a1
1 changed files with 2 additions and 0 deletions
|
|
@ -592,6 +592,8 @@ impl ButtonStyle {
|
|||
fn disabled(&self, cx: &WindowContext) -> ButtonStyles {
|
||||
let bg = match self {
|
||||
ButtonStyle::Link | ButtonStyle::Ghost | ButtonStyle::Text => cx.theme().transparent,
|
||||
ButtonStyle::Primary => cx.theme().primary.opacity(0.15),
|
||||
ButtonStyle::Danger => cx.theme().destructive.opacity(0.15),
|
||||
_ => cx.theme().secondary.darken(0.2).grayscale(),
|
||||
};
|
||||
let fg = match self {
|
||||
|
|
|
|||
Loading…
Reference in a new issue