Uh oh!
There was an error while loading. Please reload this page.
fix: border rendering problem in Android - #36129
Conversation
analysis-bot
commented
Feb 10, 2023
Base commit: 96df8c0 |
facebook-github-bot
commented
Feb 15, 2023
@javache has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
cipolleschi
commented
Feb 15, 2023
/rebase |
| mInnerBottomRightCorner.x = mInnerClipTempRectForBorderRadius.right; | ||
| mInnerBottomRightCorner.y = mInnerClipTempRectForBorderRadius.bottom * -2; | ||
| mInnerBottomRightCorner.y = borderWidth.bottom != 0 |
There was a problem hiding this comment.
Could you explain why don't need this logic for mInnerTopLeftCorner and mInnerTopRightCorner?
There was a problem hiding this comment.
Yes, it can be added (my bad, I kinda had tunnel vision). In the cases where this bug happened it won't cause any difference though, because mInnerClipTempRectForBorderRadius.top was always 0. Do you want me to make a commit adding the same logic to mInnerTopLeftCorner and mInnerTopRightCorner?
There was a problem hiding this comment.
If it doesn't make a difference, we shouldn't add it. So you're saying we don't need similar logic for the top corners?
There was a problem hiding this comment.
I'm not totally sure. From what I saw from the code, mInnerClipTempRectForBorderRadius is set based on the getBounds of the drawable. In cases where the bounds don't change, top will always be 0. Is there any possibility of the bounds changing in this case?
Update: ah, there is if we change the size of drawable...I'll test it (nvm, not the case, from what I can tell top will always remain 0)
javache
commented
Feb 16, 2023
Looks like this logic was changed not too long ago in #34362. It seems there was no test-case added at that time, can you verify this doesn't regress it? |
BeeMargarida
commented
Feb 16, 2023
|
facebook-github-bot
commented
Feb 16, 2023
@javache Please add this to 0.71 |
javache
commented
Jun 13, 2023
@zbranevichfinstek: please raise this in the 0.71 release thread - https://github.com/reactwg/react-native-releases/discussions |
I don't want to upgrade the react native version, so is there any way to fix this issue? Dependencies: { |

Summary
Fixes#36036
The problem was in
ReactViewBackgroundDrawable.javathat was not accounting for adjacent borders that add width set to 0.Changelog
[Android] [Fixed] - Fix border rendering issue when bottom borders has no width
Test Plan