Skip to content
This repository has been archived by the owner on May 10, 2024. It is now read-only.

Commit

Permalink
Fix #8497: Scale VPN menu button icon correctly (#8506)
Browse files Browse the repository at this point in the history
  • Loading branch information
kylehickinson authored Nov 30, 2023
1 parent 40fd7f6 commit 06a0f2c
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 06a0f2c

Please sign in to comment.