fix iOS swipe side colors
This commit is contained in:
@@ -256,18 +256,18 @@ struct RoundView: View {
|
||||
let isDraggingLeft = dragOffset.width < -dragThreshold
|
||||
|
||||
HStack(spacing: 0) {
|
||||
sideTint(
|
||||
title: sortedOutcomes(for: round).dropFirst().first.map(outcomeTitle) ?? localization.string(for: "round.no"),
|
||||
subtitle: localization.string(for: "round.swipe_left"),
|
||||
color: .red,
|
||||
opacity: isDraggingLeft ? min(abs(dragOffset.width) / 240.0, 0.95) : 0
|
||||
)
|
||||
sideTint(
|
||||
title: sortedOutcomes(for: round).first.map(outcomeTitle) ?? localization.string(for: "round.yes"),
|
||||
subtitle: localization.string(for: "round.swipe_right"),
|
||||
color: HermesTheme.positive,
|
||||
opacity: isDraggingRight ? min(abs(dragOffset.width) / 240.0, 0.95) : 0
|
||||
)
|
||||
sideTint(
|
||||
title: sortedOutcomes(for: round).dropFirst().first.map(outcomeTitle) ?? localization.string(for: "round.no"),
|
||||
subtitle: localization.string(for: "round.swipe_left"),
|
||||
color: .red,
|
||||
opacity: isDraggingLeft ? min(abs(dragOffset.width) / 240.0, 0.95) : 0
|
||||
)
|
||||
}
|
||||
.ignoresSafeArea()
|
||||
.allowsHitTesting(false)
|
||||
|
||||
Reference in New Issue
Block a user