Skip to content

Commit 37bba9a

Browse files
committed
fix(ios): 1px gap in gradient background under special circumstances (#4246)
1 parent 9c16179 commit 37bba9a

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

renderer/native/ios/renderer/component/view/HippyView.m

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -367,7 +367,8 @@ - (BOOL)getLayerContentForColor:(UIColor *)color completionBlock:(void (^)(UIIma
367367
});
368368
return NO;
369369
} else if (self.gradientObject) {
370-
CGSize size = theFrame.size;
370+
CGSize size = CGSizeMake(HippyRoundPixelValue(theFrame.size.width),
371+
HippyRoundPixelValue(theFrame.size.height));
371372
if (0 >= size.width || 0 >= size.height) {
372373
contentBlock(nil);
373374
return YES;

0 commit comments

Comments
 (0)