Skip to content

Commit 0dacf14

Browse files
committed
Fix border width looking thinner than 2px in design, because stroke draws half width outward which is clipped by the overlay. Using strokeBorder ensures the full border is drawn inward and visible in overlay.
1 parent a0e2374 commit 0dacf14

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

WooCommerce/Classes/POS/Presentation/Reusable Views/Buttons/POSButtonStyle.swift

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -80,8 +80,8 @@ struct POSButtonStyle: ButtonStyle {
8080
private var borderOverlay: some View {
8181
if variant == .outlined {
8282
RoundedRectangle(cornerRadius: Constants.cornerRadius)
83-
.stroke(isEnabled ? Color.posInverseSurface : .posDisabledContainer,
84-
lineWidth: Constants.borderStrokeWidth)
83+
.strokeBorder(isEnabled ? Color.posInverseSurface : .posDisabledContainer,
84+
lineWidth: Constants.borderStrokeWidth)
8585
}
8686
}
8787
}

0 commit comments

Comments
 (0)