Skip to content

Commit

Permalink
Fix brave/brave-ios#8497: Scale VPN menu button icon correctly (brave…
Browse files Browse the repository at this point in the history
  • Loading branch information
kylehickinson committed Nov 30, 2023
1 parent 789624a commit 871a138
Showing 1 changed file with 3 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,8 @@ struct VPNMenuButton: View {
@State private var isVPNStatusChanging: Bool = BraveVPN.reconnectPending
@State private var isVPNEnabled = BraveVPN.isConnected
@State private var isErrorShowing: Bool = false

@ScaledMetric private var iconSize: CGFloat = 32.0

private var isVPNEnabledBinding: Binding<Bool> {
Binding(
Expand Down Expand Up @@ -126,7 +128,7 @@ struct VPNMenuButton: View {
HStack(spacing: 14) {
Image(braveSystemName: retryStateActive ? "leo.warning.triangle-filled" : "leo.product.vpn")
.font(.body)
.frame(width: 32, height: 32)
.frame(width: iconSize, height: iconSize)
.foregroundColor(retryStateActive ? Color(.braveErrorLabel) : Color(.braveLabel))
.background(
RoundedRectangle(cornerRadius: 8, style: .continuous)
Expand Down

0 comments on commit 871a138

Please sign in to comment.