Skip to content

Commit

Permalink
Update RadixButton.swift
Browse files Browse the repository at this point in the history
  • Loading branch information
amirsaam committed Oct 20, 2024
1 parent f2a567d commit 1151f28
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions Sources/RadixUI/RadixPrimitives/RadixButton.swift
Original file line number Diff line number Diff line change
Expand Up @@ -13,12 +13,9 @@ fileprivate struct RadixButton: ButtonStyle {

func makeBody(configuration: Configuration) -> some View {
configuration.label
.opacity(isEnabled ? 1 : 0.8)
.scaleEffect(configuration.isPressed ? 0.97 : 1)
.opacity(
isEnabled
? (configuration.isPressed ? 0.9 : 1)
: 0.6
)
.saturation(configuration.isPressed ? 1.2 : 1)
.animation(.easeInOut(duration: 0.2), value: configuration.isPressed)
}
}
Expand Down

0 comments on commit 1151f28

Please sign in to comment.