Add errata for fix to marginStart/End for row-reverse flex direction (#1419)
Summary: Pull Request resolved: https://github.com/facebook/yoga/pull/1419 X-link: https://github.com/facebook/litho/pull/961 X-link: https://github.com/facebook/react-native/pull/40803 This stack is ultimately aiming to solve https://github.com/facebook/yoga/issues/1208 This adds an value to the Errata enum. I will use this to gate this fix as there is potential for users to rely on this bug or have a hack in place to fix it and this would be a breaking change. Reviewed By: NickGerleman Differential Revision: D50145273 fbshipit-source-id: 913d2103cd31c1fa94cb39fc15d05b0c0b255920
This commit is contained in:
committed by
Facebook GitHub Bot
parent
50ecd98141
commit
50dc5ae2d1
@@ -93,6 +93,8 @@ const char* YGErrataToString(const YGErrata value) {
|
||||
return "none";
|
||||
case YGErrataStretchFlexBasis:
|
||||
return "stretch-flex-basis";
|
||||
case YGErrataStartingEndingEdgeFromFlexDirection:
|
||||
return "starting-ending-edge-from-flex-direction";
|
||||
case YGErrataAll:
|
||||
return "all";
|
||||
case YGErrataClassic:
|
||||
|
@@ -55,6 +55,7 @@ YG_ENUM_DECL(
|
||||
YGErrata,
|
||||
YGErrataNone = 0,
|
||||
YGErrataStretchFlexBasis = 1,
|
||||
YGErrataStartingEndingEdgeFromFlexDirection = 2,
|
||||
YGErrataAll = 2147483647,
|
||||
YGErrataClassic = 2147483646)
|
||||
YG_DEFINE_ENUM_FLAG_OPERATORS(YGErrata)
|
||||
|
@@ -18,6 +18,7 @@ namespace facebook::yoga {
|
||||
enum class Errata : uint32_t {
|
||||
None = YGErrataNone,
|
||||
StretchFlexBasis = YGErrataStretchFlexBasis,
|
||||
StartingEndingEdgeFromFlexDirection = YGErrataStartingEndingEdgeFromFlexDirection,
|
||||
All = YGErrataAll,
|
||||
Classic = YGErrataClassic,
|
||||
};
|
||||
@@ -26,12 +27,12 @@ YG_DEFINE_ENUM_FLAG_OPERATORS(Errata)
|
||||
|
||||
template <>
|
||||
constexpr inline int32_t ordinalCount<Errata>() {
|
||||
return 4;
|
||||
return 5;
|
||||
}
|
||||
|
||||
template <>
|
||||
constexpr inline int32_t bitCount<Errata>() {
|
||||
return 2;
|
||||
return 3;
|
||||
}
|
||||
|
||||
constexpr inline Errata scopedEnum(YGErrata unscoped) {
|
||||
|
Reference in New Issue
Block a user