From f0d9356554950ef0d1093469a918c5f9ad47eca5 Mon Sep 17 00:00:00 2001 From: Martin Guillon Date: Fri, 6 Nov 2026 11:54:31 +0100 Subject: [PATCH] fix(ios): clear non-uniform border layer when all border widths go to 0 When the radii stay non-uniform but every border width is reset to 0, drawNonUniformBorders skipped the border branch and left the previous border layer in place. Clear it in that case. Co-Authored-By: Claude Sonnet 5.5 --- packages/core/ui/styling/background.ios.ts | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/packages/core/ui/styling/background.ios.ts b/packages/core/ui/styling/background.ios.ts index 1e5826ffe3..dd00f0e7d5 100644 --- a/packages/core/ui/styling/background.ios.ts +++ b/packages/core/ui/styling/background.ios.ts @@ -738,6 +738,11 @@ function drawNonUniformBorders(nativeView: NativeScriptUIView, background: Backg layer.mask.path = generateNonUniformBorderOuterClipPath(layerBounds, cappedOuterRadii); } + // all widths went back to 0 while the radii stay non-uniform: the previous border layer must go + if (!background.hasBorderWidth() && nativeView.hasNonUniformBorder) { + clearNonUniformBorders(nativeView); + } + if (background.hasBorderWidth()) { if (!nativeView.hasNonUniformBorder) { nativeView.borderLayer = CAShapeLayer.new();