-
Notifications
You must be signed in to change notification settings - Fork 24.4k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Fix Android border clip check #37828
Conversation
Base commit: 03f70bf |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
if (isBorderColorDefined(Spacing.BLOCK)) { | ||
colorBottom = colorBlock; | ||
colorTop = colorBlock; | ||
} | ||
if (isBorderColorDefined(Spacing.BLOCK_END)) { | ||
colorBottom = colorBlockEnd; | ||
} | ||
if (isBorderColorDefined(Spacing.BLOCK_START)) { | ||
colorTop = colorBlockStart; | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
small nit and def not to address in this PR given the urgency - but this section of the code is repeated 3 times as far as I can see in this file (at L366, L575, L1171), we should look into dedup.
@cipolleschi has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
@cipolleschi merged this pull request in 7d1f7f3. |
Summary: Instead of requiring all types of border color values to be present we should only take into consideration the left, top, right, bottom, and allEdges values and inject block values into colorBottom and colorTop. This PR only addresses the first issue described here (#37753 (comment)) by kelset ## Changelog: [ANDROID] [FIXED] - Fix border clip check Pull Request resolved: #37828 Test Plan: Test through rn-tester if border color is being applied <img width="482" alt="image" src="https://github.com/facebook/react-native/assets/11707729/c8c8772c-da8d-4393-bc3f-5868eca5df15"> Reviewed By: lunaleaps Differential Revision: D46643773 Pulled By: cipolleschi fbshipit-source-id: efb1ea81bf2462c14767a2554880eb7c44989975
Summary: Instead of requiring all types of border color values to be present we should only take into consideration the left, top, right, bottom, and allEdges values and inject block values into colorBottom and colorTop. This PR only addresses the first issue described here (facebook#37753 (comment)) by kelset ## Changelog: [ANDROID] [FIXED] - Fix border clip check Pull Request resolved: facebook#37828 Test Plan: Test through rn-tester if border color is being applied <img width="482" alt="image" src="https://github.com/facebook/react-native/assets/11707729/c8c8772c-da8d-4393-bc3f-5868eca5df15"> Reviewed By: lunaleaps Differential Revision: D46643773 Pulled By: cipolleschi fbshipit-source-id: efb1ea81bf2462c14767a2554880eb7c44989975 (cherry picked from commit 2d15f50)
Summary:
Instead of requiring all types of border color values to be present we should only take into consideration the left, top, right, bottom, and allEdges values and inject block values into colorBottom and colorTop.
This PR only addresses the first issue described here (#37753 (comment)) by @kelset
Changelog:
[ANDROID] [FIXED] - Fix border clip check
Test Plan:
Test through rn-tester if border color is being applied