-
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
Inverted descent/ascent Android prioritisation to match iOS lineHeight behaviour #16448
Inverted descent/ascent Android prioritisation to match iOS lineHeight behaviour #16448
Conversation
* Restructured the CustomLineHeightSpan code to improve readability * Added unit test for the resizing cases
@andreicoman11 Would you be able to review this PR as the original author of CustomLineHeightSpan? |
@shergin Hi, any chance you could review this PR? Thanks |
@hramos This PR is a small consistency fix, with a big positive impact; bringing Android and iOS behaviour in line and fixing broken behaviour on Android. |
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.
Hi, thanks for taking a swing at this, this definitely looks like something that is worth fixing.
Reviewing this code is a bit difficult though, since there are a number of different cases that all need to be tackled in a different way. That is the reason why the initial implementation was split into a couple of if-else statements. They make it easy to understand what cases there are, when and how are they handled.
The new implementation, while more elegant and less repetitive, is more difficult to understand. Do you mind changing it back to it's previous implementation style?
The tests are great, thanks for adding them!
@andreicoman11 Thanks for taking a look. I've changed the fix to be in the same style as your original implementation. It should be easier to review. |
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.
Thanks, looks good!
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.
@andreicoman11 has imported this pull request. If you are a Facebook employee, you can view this diff on Phabricator.
@@ -0,0 +1,74 @@ | |||
package com.facebook.react.views.text; |
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.
This is missing the license header, mind adding this so we can land this change?
final int additional = mHeight - (-fm.top + fm.bottom); | ||
fm.top -= additional; | ||
fm.ascent -= additional; |
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.
@bartolkaruza & @andreicoman11:
I've been looking at this PR and noticed a possible regression. Line height seems to be (more) broken on wrapped lines of text when line height is greater than font size. It seems to be related to this line of code.
Here is an example of what I'm seeing:
JSX:
<View style={{backgroundColor: "yellow", paddingTop: 100, paddingBottom: 100}}>
<Text style={{fontSize: 20, lineHeight: 60, backgroundColor: "blue", color: "white"}}>
Fontsize 20 Lineheight 60 qwertyuiopasdfghjklzxcvbnm QWERTYUIOPASDFGHJKLZXCVBNM
Fontsize 20 Lineheight 60 qwertyuiopasdfghjklzxcvbnm QWERTYUIOPASDFGHJKLZXCVBNM
</Text>
</View>```
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.
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.
Proposed fix to make Android consistent with iOS:
// Show proportionally additional ascent / top & descent / bottom
final int additional = mHeight - (-fm.top + fm.bottom);
fm.top -= additional / 2;
fm.ascent -= additional / 2;
fm.descent += additional / 2;
fm.bottom += additional / 2;
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.
@dickie81 Thank you for looking out, I did not check the full range of test cases on the actual UI when changing the style back to the original style, leaning on the unit tests instead. I'll try out your approach against the cases I have locally for all the lineHeight scenario's and post the test setup so everyone can verify.
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.
@dickie81 I've been testing the ui effects and there is definitely a regression in the case of bigger lineHeight and even with very small lineHeight something broke.
Unfortunately your proposed solution still causes cut-off at the bottom, when the lineHeight is small.
@andreicoman11 I'm looking into this more in depth, this PR is not ready yet as it stands now. I'll try to improve it to cover all scenario's.
Here is the testing setup that you can use to verify on your end: https://gist.github.com/bartolkaruza/b74f228636bb78fea00aa8bd82e3766d
And these are the 4 different implementations compared to iOS. Not one is quite right yet.
Current PR state after review changes:
Original implementation before PR:
Implementation before review changes:
Proposed change by @dickie81 :
@bartolkaruza: Sorry, I was not very clear when I proposed the change. I only meant for the code in the last else statement to be changed:
|
@bartolkaruza: It still seems your implementation before the review changes handled scenarios when line height is less than font sizes better. |
There was a bug still in the low lineHeight case and that fix combined with @dickie81's proposed proportional change leads to the below desired results: @andreicoman11 The PR is ready now, the fixes and the license header have been pushed and all tests are passing. |
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.
@andreicoman11 is landing this pull request. If you are a Facebook employee, you can view this diff on Phabricator.
…t behaviour Summary: We noticed that on Android the lineHeight behaviour is different from iOS for built in fonts and custom fonts. The problem becomes visible when the lineHeight approaches the fontSize, showing a cut-off on the bottom of the TextView. This issue has been raised before in facebook#10712. There is a mention of a PR with a fix in that issue, which has not been merged yet. This implementation is a less intrusive fix leaving the current lineHeight approach in place and fixing the discrepancy only. This proposed change prioritises ascent over descent for reduction, making the lineHeight functionality behave identical to iOS. There is no existing test covering the lineHeight property and its behaviour in the CustomLineHeightSpan. This PR contains new unit tests that covers the various scenario's for the lineHeight calculations. The original behaviour, before the change can against these unit tests. The case that fails is `shouldReduceAscentThird`, which can be made to succeed on the old code by changing the asserts to: ``` assertThat(fm.top).isEqualTo(-5); assertThat(fm.ascent).isEqualTo(-5); assertThat(fm.descent).isEqualTo(-4); assertThat(fm.bottom).isEqualTo(-4); ``` The unit test succeeds for the current implementation, which has the values for ascent and descent inverted. Below screenshots show before, after and iOS: BEFORE ![screen shot 2017-10-18 at 15 35 41](https://user-images.githubusercontent.com/1605731/31721688-58d7086a-b41a-11e7-8186-9a201e2acb01.png) AFTER ![screen shot 2017-10-18 at 15 37 02](https://user-images.githubusercontent.com/1605731/31721665-473cf86c-b41a-11e7-94d5-7a70eaf99889.png) iOS ![screen shot 2017-10-18 at 15 35 22](https://user-images.githubusercontent.com/1605731/31721712-707e30a6-b41a-11e7-9baa-f886a66837e6.png) [ANDROID] [BUGFIX] [Text] - Fix the lineHeight behaviour on Android to match iOS Closes facebook#16448 Differential Revision: D6221854 Pulled By: andreicoman11 fbshipit-source-id: 7292f0f05f212d79678ac9d73e8a46bf93f1a7c6
fm.top -= additional / 2; | ||
fm.ascent -= additional / 2; | ||
fm.descent += additional / 2; | ||
fm.bottom += additional / 2; |
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.
Why are you using integers? This will cause rounding errors since aditional is an int and 2 is an int so anything that is not divisible by two will be rounded down. (See: #10712 (comment) )
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.
Hi, for us it has solved the problems in the design completely, but I see that there is still something wrong for your design case. Maybe you can open up a new issue for this and see if you can get the attention of other developers, linking to these issues, to get your specific case fixed. Even better to open a new issue, with a PR that fixes it.
Summary: There seems to be a rounding error in the android code for line height, so that for some fonts and at some combinations of line height and font size the actual height of the elements seems to be slightly too short. I've identified one issue that I mentioned here #10712 (comment) that could at least explain some of the problem. That when the line-height minus the original sum of the absolute value of top and bottom from the metrics, happens to be an odd number, the division by two causes a rounding error of 1, so that the actual line height is 1pt less than it should. The fix uses floating point division instead of integer division, and rounds (arbitrarily) the negative values up and the positive values down so that the total is still the correct for odd numbers. It turns out that only ascent and descent is used to give the actual line-height between lines in the same text-element. The top and bottom values are only used for padding the top and bottom of the text. So when the line-height is greater than the font size and the extra padding this PR sets the ascent and descent to the same value as the top and bottom respectively. I've renamed the shouldIncreaseAllMetricsProportionally test to evenLineHeightShouldIncreaseAllMetricsProportionally and added an extra assertion to check that bottom-top still equals the line height. Added another test oddLineHeightShouldAlsoWork that is similar but uses an odd number for the line height to test that it still works with odd numbers. This test only uses the sum of the values so that it's indifferent to what value the implementation chooses to round up or down. Improvement on #16448 Fix line-height calculation on Android. | Before | After | | ------------- |-------------| | ![without fix](https://user-images.githubusercontent.com/2144849/36150230-4404a0cc-10c3-11e8-8880-4ab84339c741.png) | ![actual fix](https://user-images.githubusercontent.com/2144849/36156620-eb496d0e-10d7-11e8-8bd1-1cb536a38fbf.png) | (All three columns have font size 16 and lineHeight: 32. The first one is has fixed height 9*32, the second is 9 Text elements, the last is one text element with lots of text limited to 9 lines, so they should be the same height. ) Closes #17952 Differential Revision: D6980333 Pulled By: hramos fbshipit-source-id: 0a501358cfbf7f139fca46056d0d972b1daf6ae3
…t behaviour Summary: We noticed that on Android the lineHeight behaviour is different from iOS for built in fonts and custom fonts. The problem becomes visible when the lineHeight approaches the fontSize, showing a cut-off on the bottom of the TextView. This issue has been raised before in facebook#10712. There is a mention of a PR with a fix in that issue, which has not been merged yet. This implementation is a less intrusive fix leaving the current lineHeight approach in place and fixing the discrepancy only. This proposed change prioritises ascent over descent for reduction, making the lineHeight functionality behave identical to iOS. There is no existing test covering the lineHeight property and its behaviour in the CustomLineHeightSpan. This PR contains new unit tests that covers the various scenario's for the lineHeight calculations. The original behaviour, before the change can against these unit tests. The case that fails is `shouldReduceAscentThird`, which can be made to succeed on the old code by changing the asserts to: ``` assertThat(fm.top).isEqualTo(-5); assertThat(fm.ascent).isEqualTo(-5); assertThat(fm.descent).isEqualTo(-4); assertThat(fm.bottom).isEqualTo(-4); ``` The unit test succeeds for the current implementation, which has the values for ascent and descent inverted. Below screenshots show before, after and iOS: BEFORE ![screen shot 2017-10-18 at 15 35 41](https://user-images.githubusercontent.com/1605731/31721688-58d7086a-b41a-11e7-8186-9a201e2acb01.png) AFTER ![screen shot 2017-10-18 at 15 37 02](https://user-images.githubusercontent.com/1605731/31721665-473cf86c-b41a-11e7-94d5-7a70eaf99889.png) iOS ![screen shot 2017-10-18 at 15 35 22](https://user-images.githubusercontent.com/1605731/31721712-707e30a6-b41a-11e7-9baa-f886a66837e6.png) [ANDROID] [BUGFIX] [Text] - Fix the lineHeight behaviour on Android to match iOS Closes facebook#16448 Differential Revision: D6221854 Pulled By: andreicoman11 fbshipit-source-id: 7292f0f05f212d79678ac9d73e8a46bf93f1a7c6
Summary: There seems to be a rounding error in the android code for line height, so that for some fonts and at some combinations of line height and font size the actual height of the elements seems to be slightly too short. I've identified one issue that I mentioned here facebook#10712 (comment) that could at least explain some of the problem. That when the line-height minus the original sum of the absolute value of top and bottom from the metrics, happens to be an odd number, the division by two causes a rounding error of 1, so that the actual line height is 1pt less than it should. The fix uses floating point division instead of integer division, and rounds (arbitrarily) the negative values up and the positive values down so that the total is still the correct for odd numbers. It turns out that only ascent and descent is used to give the actual line-height between lines in the same text-element. The top and bottom values are only used for padding the top and bottom of the text. So when the line-height is greater than the font size and the extra padding this PR sets the ascent and descent to the same value as the top and bottom respectively. I've renamed the shouldIncreaseAllMetricsProportionally test to evenLineHeightShouldIncreaseAllMetricsProportionally and added an extra assertion to check that bottom-top still equals the line height. Added another test oddLineHeightShouldAlsoWork that is similar but uses an odd number for the line height to test that it still works with odd numbers. This test only uses the sum of the values so that it's indifferent to what value the implementation chooses to round up or down. Improvement on facebook#16448 Fix line-height calculation on Android. | Before | After | | ------------- |-------------| | ![without fix](https://user-images.githubusercontent.com/2144849/36150230-4404a0cc-10c3-11e8-8880-4ab84339c741.png) | ![actual fix](https://user-images.githubusercontent.com/2144849/36156620-eb496d0e-10d7-11e8-8bd1-1cb536a38fbf.png) | (All three columns have font size 16 and lineHeight: 32. The first one is has fixed height 9*32, the second is 9 Text elements, the last is one text element with lots of text limited to 9 lines, so they should be the same height. ) Closes facebook#17952 Differential Revision: D6980333 Pulled By: hramos fbshipit-source-id: 0a501358cfbf7f139fca46056d0d972b1daf6ae3
Summary: There seems to be a rounding error in the android code for line height, so that for some fonts and at some combinations of line height and font size the actual height of the elements seems to be slightly too short. I've identified one issue that I mentioned here facebook#10712 (comment) that could at least explain some of the problem. That when the line-height minus the original sum of the absolute value of top and bottom from the metrics, happens to be an odd number, the division by two causes a rounding error of 1, so that the actual line height is 1pt less than it should. The fix uses floating point division instead of integer division, and rounds (arbitrarily) the negative values up and the positive values down so that the total is still the correct for odd numbers. It turns out that only ascent and descent is used to give the actual line-height between lines in the same text-element. The top and bottom values are only used for padding the top and bottom of the text. So when the line-height is greater than the font size and the extra padding this PR sets the ascent and descent to the same value as the top and bottom respectively. I've renamed the shouldIncreaseAllMetricsProportionally test to evenLineHeightShouldIncreaseAllMetricsProportionally and added an extra assertion to check that bottom-top still equals the line height. Added another test oddLineHeightShouldAlsoWork that is similar but uses an odd number for the line height to test that it still works with odd numbers. This test only uses the sum of the values so that it's indifferent to what value the implementation chooses to round up or down. Improvement on facebook#16448 Fix line-height calculation on Android. | Before | After | | ------------- |-------------| | ![without fix](https://user-images.githubusercontent.com/2144849/36150230-4404a0cc-10c3-11e8-8880-4ab84339c741.png) | ![actual fix](https://user-images.githubusercontent.com/2144849/36156620-eb496d0e-10d7-11e8-8bd1-1cb536a38fbf.png) | (All three columns have font size 16 and lineHeight: 32. The first one is has fixed height 9*32, the second is 9 Text elements, the last is one text element with lots of text limited to 9 lines, so they should be the same height. ) Closes facebook#17952 Differential Revision: D6980333 Pulled By: hramos fbshipit-source-id: 0a501358cfbf7f139fca46056d0d972b1daf6ae3
Summary: There seems to be a rounding error in the android code for line height, so that for some fonts and at some combinations of line height and font size the actual height of the elements seems to be slightly too short. I've identified one issue that I mentioned here facebook#10712 (comment) that could at least explain some of the problem. That when the line-height minus the original sum of the absolute value of top and bottom from the metrics, happens to be an odd number, the division by two causes a rounding error of 1, so that the actual line height is 1pt less than it should. The fix uses floating point division instead of integer division, and rounds (arbitrarily) the negative values up and the positive values down so that the total is still the correct for odd numbers. It turns out that only ascent and descent is used to give the actual line-height between lines in the same text-element. The top and bottom values are only used for padding the top and bottom of the text. So when the line-height is greater than the font size and the extra padding this PR sets the ascent and descent to the same value as the top and bottom respectively. I've renamed the shouldIncreaseAllMetricsProportionally test to evenLineHeightShouldIncreaseAllMetricsProportionally and added an extra assertion to check that bottom-top still equals the line height. Added another test oddLineHeightShouldAlsoWork that is similar but uses an odd number for the line height to test that it still works with odd numbers. This test only uses the sum of the values so that it's indifferent to what value the implementation chooses to round up or down. Improvement on facebook#16448 Fix line-height calculation on Android. | Before | After | | ------------- |-------------| | ![without fix](https://user-images.githubusercontent.com/2144849/36150230-4404a0cc-10c3-11e8-8880-4ab84339c741.png) | ![actual fix](https://user-images.githubusercontent.com/2144849/36156620-eb496d0e-10d7-11e8-8bd1-1cb536a38fbf.png) | (All three columns have font size 16 and lineHeight: 32. The first one is has fixed height 9*32, the second is 9 Text elements, the last is one text element with lots of text limited to 9 lines, so they should be the same height. ) Closes facebook#17952 Differential Revision: D6980333 Pulled By: hramos fbshipit-source-id: 0a501358cfbf7f139fca46056d0d972b1daf6ae3
Summary: This sync includes the following changes: - **[4eeee358e](facebook/react@4eeee358e )**: [SuspenseList] Store lastEffect before rendering (#17131) //<Sebastian Markbåge>// - **[4fb5bf61d](facebook/react@4fb5bf61d )**: [react-interactions] Fix focus-visible heuristic (#17124) //<Nicolas Gallagher>// - **[8facc0537](facebook/react@8facc0537 )**: [react-interactions] Allow event.preventDefault on LegacyPress responder (#17113) //<Dominic Gannaway>// - **[7cec15155](facebook/react@7cec15155 )**: Remove prefixed concurrent APIs from www build (#17108) //<Andrew Clark>// - **[ed5f010ae](facebook/react@ed5f010ae )**: Client render Suspense content if there's no boundary match (#16945) //<Sebastian Markbåge>// - **[916937563](facebook/react@916937563 )**: [react-interactions] Add onFocusWithin event to FocusWithin responder (#17115) //<Dominic Gannaway>// - **[d7feeb25a](facebook/react@d7feeb25a )**: unstable_createRoot -> createRoot in test (#17107) //<Andrew Clark>// - **[6ff23f2a5](facebook/react@6ff23f2a5 )**: Change retry priority to "Never" for dehydrated boundaries (#17105) //<Sebastian Markbåge>// - **[3ac0eb075](facebook/react@3ac0eb075 )**: Modify Babel React JSX Duplicate Children Fix (#17101) //<Luna Ruan>// - **[43562455c](facebook/react@43562455c )**: Temporary patch www fork with prefixed APIs (#17103) //<Andrew Clark>// - **[9123c479f](facebook/react@9123c479f )**: Enable concurrent APIs in all experimental forks (#17102) //<Andrew Clark>// - **[30c5daf94](facebook/react@30c5daf94 )**: Remove concurrent apis from stable (#17088) //<Andrew Clark>// - **[4cb399a43](facebook/react@4cb399a43 )**: [react-interactions] Modify Scope query mechanism (#17095) //<Dominic Gannaway>// - **[e7704e22a](facebook/react@e7704e22a )**: [babel-plugin-react-jsx] Avoid duplicate "children" key in props object (#17094) //<Dominic Gannaway>// - **[fdba0e5ce](facebook/react@fdba0e5ce )**: Fixed a bug with illegal invocation for Trusted Types (#17083) //<Krzysztof Kotowicz>// - **[d364d8555](facebook/react@d364d8555 )**: Set up experimental builds (#17071) //<Andrew Clark>// - **[d5b54d0c3](facebook/react@d5b54d0c3 )**: [SuspenseList] Fix bugs with dropped Promises (#17082) //<Sebastian Markbåge>// - **[75955bf1d](facebook/react@75955bf1d )**: Pass prod error messages directly to constructor (#17063) //<Andrew Clark>// - **[0ac8e563d](facebook/react@0ac8e563d )**: [react-interactions] Add getInstanceFromNode support to TestHostRenderer (#17065) //<Dominic Gannaway>// - **[22b2642a5](facebook/react@22b2642a5 )**: DevTools test shell tweaks (#17054) //<Brian Vaughn>// - **[4be45be5f](facebook/react@4be45be5f )**: Stop warning about setNativeProps being deprecated (#17045) //<Eli White>// - **[b71ab61c8](facebook/react@b71ab61c8 )**: [react-interactions] Adds more experimental Scope API methods (#17042) //<Dominic Gannaway>// - **[5a71cbe7a](facebook/react@5a71cbe7a )**: Remove unused export //<Andrew Clark>// - **[71d012ecd](facebook/react@71d012ecd )**: Remove dormant createBatch experiment (#17035) //<Andrew Clark>// - **[cd1b167ad](facebook/react@cd1b167ad )**: [Scheduler Profiler] Use microsecond precision (#17010) //<Andrew Clark>// - **[55731fd8c](facebook/react@55731fd8c )**: [react-interactions] Refine a11y component flow types (#17032) //<Dominic Gannaway>// - **[a011aacaf](facebook/react@a011aacaf )**: [react-interactions] Remove FB builds of a11y components (#17030) //<Dominic Gannaway>// - **[fff5b1ca7](facebook/react@fff5b1ca7 )**: [react-interactions] Add FocusTable colSpan support (#17019) //<Dominic Gannaway>// - **[4bc52ef0d](facebook/react@4bc52ef0d )**: Revert "update hideOrUnhideAllChildren to hide portals that aren't wrapped in a host component (#16992)" (#17011) //<Luna Ruan>// - **[3a2b5f148](facebook/react@3a2b5f148 )**: [Selective Hydration] ReactDOM.unstable_scheduleHydration(domNode) (#17004) //<Sebastian Markbåge>// - **[26ba38ae4](facebook/react@26ba38ae4 )**: [EnterLeaveEventPlugin] Fix bug when dealing with unhandled DOM nodes (#17006) //<Dominic Gannaway>// - **[d256f88ac](facebook/react@d256f88ac )**: Update local version numbers for 16.10.2 release //<Andrew Clark>// - **[a8b8ffb89](facebook/react@a8b8ffb89 )**: DevTools v4.1.3 -> v4.2.0 //<Brian Vaughn>// - **[0545f366d](facebook/react@0545f366d )**: Added trace updates feature (DOM only) (#16989) //<Brian Vaughn>// - **[e09097a75](facebook/react@e09097a75 )**: chore: upgrade to jest 24 (#15778) //<Simen Bekkhus>// - **[5943b1da6](facebook/react@5943b1da6 )**: Fixing grammatical errors in error message (#16973) //<Rane Wallin>// - **[4c5698400](facebook/react@4c5698400 )**: [react-interactions] Remove context.setTimeout & context.clearTimeout (#17000) //<Dominic Gannaway>// - **[b33633d93](facebook/react@b33633d93 )**: [react-interactions] Repurpose React a11y modules (#16997) //<Dominic Gannaway>// - **[de2edc268](facebook/react@de2edc268 )**: update hideOrUnhideAllChildren to hide portals that aren't wrapped in a host component (#16992) //<Luna Ruan>// - **[bb680a090](facebook/react@bb680a090 )**: [Selective Hydration] Prioritize the last continuous target (#16937) //<Sebastian Markbåge>// - **[10277cc5b](facebook/react@10277cc5b )**: Remove unused canonical check in fiber host component (#16914) //<Eli White>// - **[ab1a4f249](facebook/react@ab1a4f249 )**: Move eventSystemFlags to last argument in event plugin extractors (#16978) //<Nicolas Gallagher>// - **[f6efb224b](facebook/react@f6efb224b )**: [react-interactions] Tap cancels on second pointerdown (#16936) //<Nicolas Gallagher>// - **[34457729a](facebook/react@34457729a )**: [react-interactions] Add allowModifiers flag to FocusList + FocusTable (#16971) //<Dominic Gannaway>// - **[b34f042e5](facebook/react@b34f042e5 )**: Fix mouseenter handlers fired twice (#16928) //<Rango Yuan>// - **[2c8832075](facebook/react@2c8832075 )**: React DevTools v4.1.2 -> v.4.1.3 //<Brian Vaughn>// - **[6c73a1e77](facebook/react@6c73a1e77 )**: Updated DevTools CHANGELOG //<Brian Vaughn>// - **[6a3de7a41](facebook/react@6a3de7a41 )**: [DevTools] postMessage target origin needs to be '*' for local files (#16953) //<David Huang>// - **[ac8e8b327](facebook/react@ac8e8b327 )**: [react-interactions] Add tab handling to FocusList (#16958) //<Dominic Gannaway>// - **[10c7dfe3b](facebook/react@10c7dfe3b )**: [react-interactins] FocusTable tabScope handling+tabIndex control (#16922) //<Dominic Gannaway>// - **[d3622d0f9](facebook/react@d3622d0f9 )**: chore: updated comment message (#16949) //<Kirankumar Ambati>// - **[2a264a9db](facebook/react@2a264a9db )**: Update local version numbers for 16.10.1 release //<Andrew Clark>// - **[d8a76ad58](facebook/react@d8a76ad58 )**: Allow Suspense Mismatch on the Client to Silently Proceed (#16943) //<Sebastian Markbåge>// - **[9d637844e](facebook/react@9d637844e )**: Remove enableUserBlockingEvents flag (#16882) //<Sebastian Markbåge>// - **[fe31cc710](facebook/react@fe31cc710 )**: [Selective Hydration] Increase priority for non-synchronous discrete events and retries (#16935) //<Sebastian Markbåge>// - **[b55067961](facebook/react@b55067961 )**: Fixed typo in DevTools CHANGELOG //<Brian Vaughn>// - **[5184346da](facebook/react@5184346da )**: DevTools v4.1.1 -> v4.1.2 //<Brian Vaughn>// - **[d4278663c](facebook/react@d4278663c )**: Replaced === check with Object.is() to support values like NaN (#16934) //<Brian Vaughn>// - **[d1121c017](facebook/react@d1121c017 )**: [react-interactions] Fix virtual click heuristic (#16915) //<Nicolas Gallagher>// - **[93f5f11b7](facebook/react@93f5f11b7 )**: Update local version numbers for 16.10 release //<Andrew Clark>// - **[c8dc7a926](facebook/react@c8dc7a926 )**: expose isHydrating (#16909) //<Luna Ruan>// - **[db8afe4f6](facebook/react@db8afe4f6 )**: Add HostComponent type to ReactNative (#16898) //<Eli White>// - **[fad510210](facebook/react@fad510210 )**: [bugfix] Fix false positive render phase update (#16907) //<Andrew Clark>// - **[a9cd9a765](facebook/react@a9cd9a765 )**: DevTools v4.1.0 -> v4.1.1 //<Brian Vaughn>// - **[b6606ecba](facebook/react@b6606ecba )**: DevTools shows unsupported renderer version dialog (#16897) //<Brian Vaughn>// - **[84e83db1e](facebook/react@84e83db1e )**: Updated DevTools CHANGELOG //<Brian Vaughn>// - **[b9811ed5b](facebook/react@b9811ed5b )**: [react-interactions] Add wrapping support to FocusList/FocusTable (#16903) //<Dominic Gannaway>// - **[49b0cb6db](facebook/react@49b0cb6db )**: Moving backend injection to the content script (#16900) //<David Huang>// - **[3694a3b5e](facebook/react@3694a3b5e )**: Selective Hydration (#16880) //<Sebastian Markbåge>// - **[4bb0e96b4](facebook/react@4bb0e96b4 )**: [react-interactions] FocusTable key press bound propgataion (#16895) //<Dominic Gannaway>// - **[fa1a32622](facebook/react@fa1a32622 )**: Update useEditableValue hook to sync external value changes (#16878) //<Brian Vaughn>// - **[57bf275fb](facebook/react@57bf275fb )**: [devtools] Add support for React Scope symbol/number (#16893) //<Dominic Gannaway>// - **[7c3bd08b3](facebook/react@7c3bd08b3 )**: [react-interactions] Add more documentation for a11y components (#16894) //<Dominic Gannaway>// - **[a06d181af](facebook/react@a06d181af )**: Include tag in begin/complete invariant (#16881) //<Sebastian Markbåge>// - **[0d8c0cd09](facebook/react@0d8c0cd09 )**: These flags are hard coded in our internal config (#16883) //<Sebastian Markbåge>// - **[d6d83d706](facebook/react@d6d83d706 )**: [react-interactions] Add Portal propagation configuration (#16889) //<Dominic Gannaway>// - **[d0ebde77f](facebook/react@d0ebde77f )**: [react-interactions] Add initial docs explaining React Scopes (#16892) //<Dominic Gannaway>// - **[32e5c97d1](facebook/react@32e5c97d1 )**: [React Native] Improve errors for invalid ViewConfig getter functions (#16879) //<Joshua Gross>// - **[ebc299fc2](facebook/react@ebc299fc2 )**: [react-interactions] TabFocus -> FocusManager (#16874) //<Dominic Gannaway>// - **[793f176da](facebook/react@793f176da )**: [react-interactions] Make FocusList bundle (#16876) //<Dominic Gannaway>// - **[68a87eee5](facebook/react@68a87eee5 )**: [react-interactions] Add FocusList component (#16875) //<Dominic Gannaway>// - **[18d2e0c03](facebook/react@18d2e0c03 )**: Warning system refactoring (part 1) (#16799) //<Jessica Franco>// - **[8b580a89d](facebook/react@8b580a89d )**: Idle updates should not be blocked by hidden work (#16871) //<Andrew Clark>// - **[c5e7190ed](facebook/react@c5e7190ed )**: [react-interactions] Press with useRef instead of useState (#16870) //<Nicolas Gallagher>// - **[911104a12](facebook/react@911104a12 )**: DevTools CHANGELOG update //<Brian Vaughn>// - **[bce2ac63a](facebook/react@bce2ac63a )**: Revert change to backend injection method from PR #16752 (#16864) //<Brian Vaughn>// - **[9b3cde9b6](facebook/react@9b3cde9b6 )**: Fix DevTools v4.1 editable hook regression (#16867) //<Brian Vaughn>// - **[1a6294d3e](facebook/react@1a6294d3e )**: [react-interaction] Refactor a11y components more (#16866) //<Dominic Gannaway>// - **[1758b3f7b](facebook/react@1758b3f7b )**: [react-interactions] Add no-op stopPropagation + preventDefault to Press (#16868) //<Dominic Gannaway>// - **[013b7ad11](facebook/react@013b7ad11 )**: [suspense][error handling] Inline renderRoot and fix error handling bug (#16801) //<Andrew Clark>// - **[0a527707c](facebook/react@0a527707c )**: Event Replaying (#16725) //<Sebastian Markbåge>// - **[a87d245fc](facebook/react@a87d245fc )**: [work loop] Prevent work loop from being inlined (#16865) //<Andrew Clark>// - **[312b462d5](facebook/react@312b462d5 )**: [react-interactions] Improve consistency of Tap responder (#16837) //<Nicolas Gallagher>// - **[70754f10d](facebook/react@70754f10d )**: [react-interaction] Tweak Focus Table component (#16862) //<Dominic Gannaway>// - **[d7f6dd5a8](facebook/react@d7f6dd5a8 )**: [react-interactions] Fix typo in FocusTable (#16860) //<Dominic Gannaway>// - **[cef47cbc0](facebook/react@cef47cbc0 )**: Rename experimental react-ui => react-interactions (#16842) //<Dan Abramov>// - **[57a5805a9](facebook/react@57a5805a9 )**: [react-ui] Add preventDefault+stopPropagation to Keyboard + update Focus components (#16833) //<Dominic Gannaway>// - **[08b51aa38](facebook/react@08b51aa38 )**: Added React DevTools v4.1.0 release date to CHANGELOG //<Brian Vaughn>// - **[b5cebedfb](facebook/react@b5cebedfb )**: React DevTools version bump 4.0.6 -> 4.1.0 //<Brian Vaughn>// - **[fd870e6b6](facebook/react@fd870e6b6 )**: [react-ui/events] Tap responder API changes (#16827) //<Nicolas Gallagher>// - **[4ddcb8e13](facebook/react@4ddcb8e13 )**: [DevTools] Remove Welcome dialog (#16834) //<Dan Abramov>// - **[924a30578](facebook/react@924a30578 )**: [react-ui] Remove event object warnings (#16822) //<Dominic Gannaway>// - **[a5df18a9e](facebook/react@a5df18a9e )**: prevent firefox marking required textareas invalid (#16578) //<halvves>// - **[f818af9b0](facebook/react@f818af9b0 )**: [Fresh] Always remount classes (#16823) //<Dan Abramov>// - **[6ecfa90eb](facebook/react@6ecfa90eb )**: [React Native] Fix for view config registrations (#16821) //<Ricky>// - **[18cb59050](facebook/react@18cb59050 )**: [react-core] Do not null fiber.sibling in detachFiber (#16820) //<Dominic Gannaway>// - **[d862f0ea5](facebook/react@d862f0ea5 )**: Optimize objectIs (#16212) //<Kuba Juszczyk>// - **[d1c255586](facebook/react@d1c255586 )**: [react-devtools-shared] Added string type check for object name prop in getDisplayName function (#16798) //<Pavlo Tymchuk>// - **[70dcdd265](facebook/react@70dcdd265 )**: Updated pending CHANGELOG for DevTools //<Brian Vaughn>// - **[8f1533f4d](facebook/react@8f1533f4d )**: [react-ui] Fix bundle name [hotfix] (#16811) //<Dominic Gannaway>// - **[7c802de79](facebook/react@7c802de79 )**: [react-a11y] Add react-ui/accessibility to bundle build (#16804) //<Dominic Gannaway>// - **[901139c29](facebook/react@901139c29 )**: [scheduler][profiler] Start time of delayed tasks (#16809) //<Andrew Clark>// - **[f40ceb001](facebook/react@f40ceb001 )**: [react-ui] FocusGrid -> ReactFocusTable + tweaks and fixes (#16806) //<Dominic Gannaway>// - **[2f1e8c5f7](facebook/react@2f1e8c5f7 )**: [react-core] Clear more properties in detachFiber (#16807) //<Dominic Gannaway>// - **[8e0c57412](facebook/react@8e0c57412 )**: Follow-up to initial Trusted Types support (#16795) //<Dan Abramov>// - **[3af05de1a](facebook/react@3af05de1a )**: [react-ui] usePress from useKeyboard and useTap (#16772) //<Nicolas Gallagher>// - **[494300b36](facebook/react@494300b36 )**: [react-ui] Move experimental event+a11y work to react-ui package (#16794) //<Dominic Gannaway>// - **[9691eb273](facebook/react@9691eb273 )**: [react-events] Keyboard support for virtual clicks (#16780) //<Nicolas Gallagher>// - **[b8d079b41](facebook/react@b8d079b41 )**: Add trusted types to react on client side (#16157) //<Emanuel Tesař>// - **[cdbfa5044](facebook/react@cdbfa5044 )**: fix typo inteval -> interval & continutation -> continuation (#16760) //<Heaven>// - **[45b6443c9](facebook/react@45b6443c9 )**: Spelling is fundamental (#16782) //<Andrew Clark>// - **[45898d0be](facebook/react@45898d0be )**: [Scheduler] Prevent event log from growing unbounded (#16781) //<Andrew Clark>// - **[87eaa90ef](facebook/react@87eaa90ef )**: [react-events] Keyboard calls preventDefault on 'click' events (#16779) //<Nicolas Gallagher>// - **[0c0b30b8c](facebook/react@0c0b30b8c )**: Remove unnecessary interaction tracing ping wrapper (#16777) //<Brian Vaughn>// - **[137ea783b](facebook/react@137ea783b )**: Re-enable risky work loop changes (#16771) //<Andrew Clark>// - **[d6f6b951e](facebook/react@d6f6b951e )**: Support disabling interaction tracing for suspense promises (#16776) //<Brian Vaughn>// - **[b4b8a349a](facebook/react@b4b8a349a )**: [react-interactions] Add experimental FocusGrid API (#16766) //<Dominic Gannaway>// - **[a7dabcb60](facebook/react@a7dabcb60 )**: Revert "Re-arrange slightly to prevent refactor hazard (#16743)" (#16769) //<Andrew Clark>// - **[4b0b556dc](facebook/react@4b0b556dc )**: [react-interactions] Refactor TabFocusController (#16768) //<Dominic Gannaway>// - **[fb39f6292](facebook/react@fb39f6292 )**: Added upcoming changes to DevTools CHANGELOG //<Brian Vaughn>// - **[ba932a5ad](facebook/react@ba932a5ad )**: fix: inspect ClassComponent.render instead of constructor, fixes #16749 (#16759) //<Anton Korzunov>// - **[35a202d0e](facebook/react@35a202d0e )**: [react-events] Ensure we restore currentInstance + currentTimers (#16758) //<Dominic Gannaway>// - **[3717c25a7](facebook/react@3717c25a7 )**: [react-interactions] More Tab Focus control handling (#16751) //<Dominic Gannaway>// - **[0a2215cc0](facebook/react@0a2215cc0 )**: [Scheduler][www] Put profiling feature behind flag (#16757) //<Andrew Clark>// - **[efa780d0a](facebook/react@efa780d0a )**: Removed DT inject() script since it's no longer being used //<Brian Vaughn>// - **[4290967d4](facebook/react@4290967d4 )**: Merge branch 'tt-compat' of https://github.com/onionymous/react into onionymous-tt-compat //<Brian Vaughn>// - **[f09854a9e](facebook/react@f09854a9e )**: Moved inline comment. //<Brian Vaughn>// - **[776d1c69b](facebook/react@776d1c69b )**: Lint fixes //<Stephanie Ding>// - **[2e75000f4](facebook/react@2e75000f4 )**: Removed done(), added some comments explaining the change //<Stephanie Ding>// - **[8a6cd3cd1](facebook/react@8a6cd3cd1 )**: remove ability to inject arbitrary scripts //<Stephanie Ding>// - **[d51f062d0](facebook/react@d51f062d0 )**: Formatting changes //<Stephanie Ding>// - **[85c721101](facebook/react@85c721101 )**: Moved injection logic to content script //<Stephanie Ding>// - **[788036c7e](facebook/react@788036c7e )**: Moved backend injection logic to content script //<Stephanie Ding>// - **[c93038fab](facebook/react@c93038fab )**: Moved backend injection logic to content script //<Stephanie Ding>// - **[3a49dff38](facebook/react@3a49dff38 )**: [react-events] Use context.objectAssign in Tap responder (#16748) //<Dominic Gannaway>// - **[56114a4b2](facebook/react@56114a4b2 )**: Change `trackedTouchCount` console.error to warn (#16750) //<Matt Kane>// - **[ae724be7b](facebook/react@ae724be7b )**: [react-interactions] Add TabFocusContainer and TabbableScope UI components (#16732) //<Dominic Gannaway>// - **[ab4951fc0](facebook/react@ab4951fc0 )**: Re-arrange slightly to prevent refactor hazard (#16743) //<Andrew Clark>// - **[b0a8a3e04](facebook/react@b0a8a3e04 )**: Mark root as already hydrated after committing (#16739) //<Sebastian Markbåge>// - **[e04f4259c](facebook/react@e04f4259c )**: Handle SuspenseListComponent getting retried (#16745) //<Sebastian Markbåge>// - **[2c98af77c](facebook/react@2c98af77c )**: DevTools: Props editing interface tweaks (#16740) //<Brian Vaughn>// - **[2ce5801c2](facebook/react@2ce5801c2 )**: Added upcoming changes to DevTools CHANGELOG //<Brian Vaughn>// - **[709baf1fe](facebook/react@709baf1fe )**: [DevTools] Support for adding props | Improved state/props value editing (#16700) //<Hristo Kanchev>// - **[4ef6387d6](facebook/react@4ef6387d6 )**: [DevTools] [Context] Legacy Context (#16617) //<Hristo Kanchev>// - **[c317fc273](facebook/react@c317fc273 )**: Correct link for troubleshooting react-dev-tools (#16690) (#16708) //<Liad Yosef>// - **[41a78cd85](facebook/react@41a78cd85 )**: [react-events] Tap: add maximumDistance prop (#16689) //<Nicolas Gallagher>// - **[240040078](facebook/react@240040078 )**: react-refresh@0.4.2 //<Dan Abramov>// - **[ba6bb0fcc](facebook/react@ba6bb0fcc )**: [Fresh] Hash signatures (#16738) //<Dan Abramov>// - **[fd3e8cb0a](facebook/react@fd3e8cb0a )**: [react-events] Remove stopPropagation (Press) + use document for delegation (#16730) //<Dominic Gannaway>// - **[38c03ce00](facebook/react@38c03ce00 )**: Fix typo in commet (#16727) //<Heaven>// - **[4905590e1](facebook/react@4905590e1 )**: Fixed font family issue in FF. (#16701) //<Hristo Kanchev>// - **[35f447ddb](facebook/react@35f447ddb )**: Remove console.log from copyWithSet (#16716) //<Daniel Lo Nigro>// - **[440cbf2ee](facebook/react@440cbf2ee )**: Let's schedule the passive effects even earlier (#16714) //<Sebastian Markbåge>// - **[cc2492ccf](facebook/react@cc2492ccf )**: Schedule passive callbacks before layout effects are invoked (#16713) //<Sebastian Markbåge>// - **[031eba789](facebook/react@031eba789 )**: [react-events] Tap: change order of events (#16694) //<Nicolas Gallagher>// - **[f26fe8c0a](facebook/react@f26fe8c0a )**: [react-events] Keyboard: fix callback return types (#16693) //<Nicolas Gallagher>// - **[9444c876d](facebook/react@9444c876d )**: Remove wrong copy-paste code in test (#16695) //<Heaven>// - **[b260bef39](facebook/react@b260bef39 )**: [Fresh] Add skipEnvCheck option to Babel plugin (#16688) //<Dan Abramov>// - **[2f1588185](facebook/react@2f1588185 )**: react-refresh@0.4.1 //<Dan Abramov>// - **[9044bb0fa](facebook/react@9044bb0fa )**: [Fresh] Fix a crash with implicit arrow return (#16687) //<Dan Abramov>// - **[21d79ce04](facebook/react@21d79ce04 )**: Add FreshRuntime WWW bundle, remove ESLint (#16684) //<Dan Abramov>// - **[206d61f72](facebook/react@206d61f72 )**: fix typos on react-devtools comments (#16681) //<Alex Rohleder>// - **[61836fba2](facebook/react@61836fba2 )**: Fix typo: wnless -> unless (#16680) //<Heaven>// - **[e11bf42ce](facebook/react@e11bf42ce )**: Check for Suspense boundary in a root Container (#16673) //<Sebastian Markbåge>// - **[962dfc2c3](facebook/react@962dfc2c3 )**: Remove experimental scheduler flags (#16672) //<Dan Abramov>// - **[ff006451a](facebook/react@ff006451a )**: [react-events] Fix isTargetWithinNode type (#16671) //<Nicolas Gallagher>// - **[040ca0fad](facebook/react@040ca0fad )**: Enable MessageLoop implementation by default (#16408) //<Dan Abramov>// - **[d96f478f8](facebook/react@d96f478f8 )**: use-subscription tearing fix (#16623) //<Brian Vaughn>// - **[79e46b677](facebook/react@79e46b677 )**: updated flags from false to dicated on www (#16647) //<Luna Ruan>// - **[8d7c733f1](facebook/react@8d7c733f1 )**: [Partial Hydration] Don't invoke listeners on parent of dehydrated event target (#16591) //<Sebastian Markbåge>// - **[9ce8711d5](facebook/react@9ce8711d5 )**: [react-events] Tap responder (#16628) //<Nicolas Gallagher>// - **[e86146e71](facebook/react@e86146e71 )**: [react-events] Refine executeUserEventHandler (#16662) //<Dominic Gannaway>// - **[c66edb9f8](facebook/react@c66edb9f8 )**: [react-events] Refactor getCurrentTarget to getResponderNode (#16660) //<Dominic Gannaway>// - **[9ff60ff16](facebook/react@9ff60ff16 )**: [react-events] Fix Scope listener issue (#16658) //<Dominic Gannaway>// - **[7126a37bf](facebook/react@7126a37bf )**: [react-events] Keyboard responder propagation handling (#16657) //<Dominic Gannaway>// - **[539640d89](facebook/react@539640d89 )**: [react-events] Various core tweaks for event responder system (#16654) //<Dominic Gannaway>// - **[af032764a](facebook/react@af032764a )**: [react-events] Adds preventKeys support to Keyboard responder (#16642) //<Dominic Gannaway>// - **[f705e2bac](facebook/react@f705e2bac )**: Updated pending CHANGELOG for DevTools //<Brian Vaughn>// - **[77bb10239](facebook/react@77bb10239 )**: [DevTools] [Profiler]: Save profile now working in Firefox (#16612) //<Hristo Kanchev>// - **[92f094d86](facebook/react@92f094d86 )**: fix typo: oncurrent - concurrent (#16633) //<Heaven>// - **[46f912fd5](facebook/react@46f912fd5 )**: [react-core] Add more support for experimental React Scope API (#16621) //<Dominic Gannaway>// - **[f962feb88](facebook/react@f962feb88 )**: Updated extensions build-from-source instructions in README //<Brian Vaughn>// - **[4e544cffe](facebook/react@4e544cffe )**: [react-events] Split out mixed event responder tests (#16608) //<Dominic Gannaway>// - **[f61138e06](facebook/react@f61138e06 )**: Use renderToStaticMarkup for tests (#16516) //<Gerald Monaco>// - **[980112b14](facebook/react@980112b14 )**: rephrase comment (#16559) //<James George>// - **[8a7c2e50f](facebook/react@8a7c2e50f )**: Remove duplicate character in regex group (#16572) //<Bas Peeters>// - **[557d472fe](facebook/react@557d472fe )**: add <thead>, <tfoot> to table > tr warning (#16535) //<Tom Quirk>// - **[bd79be9b6](facebook/react@bd79be9b6 )**: [react-core] Add experimental React Scope component API (#16587) //<Dominic Gannaway>// - **[996acf903](facebook/react@996acf903 )**: Updated DevTools extension build script to work when run remotely (#16603) //<Brian Vaughn>// - **[34aaec6f9](facebook/react@34aaec6f9 )**: [react-events] Ensure screen reader virtual clicks support preventDefault (#16600) //<Dominic Gannaway>// - **[01fb68b9b](facebook/react@01fb68b9b )**: Don't ignore dependencies for render phase update (#16574) //<Dan Abramov>// - **[b034ac6d3](facebook/react@b034ac6d3 )**: Merge branch 'master' into devtools-v4-merge //<Brian Vaughn>// - **[f51253775](facebook/react@f51253775 )**: Babel Transform JSX to React.jsx/React.jsxDEV Plugin (#16432) //<Luna Ruan>// - **[cb15f18dc](facebook/react@cb15f18dc )**: [react-events] Improve mock event object accuracy (#16590) //<Nicolas Gallagher>// - **[bc8b15332](facebook/react@bc8b15332 )**: Updated README docs, example screenshots, etc //<Brian Vaughn>// - **[7153dd516](facebook/react@7153dd516 )**: Fixed a StyleEditor variable resolution regression //<Brian Vaughn>// - **[33d439f8f](facebook/react@33d439f8f )**: Merge branch 'master' into devtools-v4-merge //<Brian Vaughn>// - **[4ef269606](facebook/react@4ef269606 )**: [react-events] Support screen reader virtual clicks (#16584) //<Dominic Gannaway>// - **[fb316787c](facebook/react@fb316787c )**: Removed unused Chrome Flow types //<Brian Vaughn>// - **[8e1434e80](facebook/react@8e1434e80 )**: Added FB copyright header //<Brian Vaughn>// - **[49b0f87d1](facebook/react@49b0f87d1 )**: Suppress act/renderer warning for DevTools tests //<Brian Vaughn>// - **[8c684bf7e](facebook/react@8c684bf7e )**: Removed forked DevTools Flow types //<Brian Vaughn>// - **[9a016c0c2](facebook/react@9a016c0c2 )**: Removed outdated snapshot //<Brian Vaughn>// - **[896c993ad](facebook/react@896c993ad )**: Fixed remaining DevTools broken tests by fixing a hydration/spread bug //<Brian Vaughn>// - **[e3cc42be9](facebook/react@e3cc42be9 )**: Fix Console patching test by resetting modules //<Brian Vaughn>// - **[177f357d9](facebook/react@177f357d9 )**: Updated DevTools test setup to no longer mock test renerer //<Brian Vaughn>// - **[a48593a8d](facebook/react@a48593a8d )**: Iterating on DevTools tests: Trying to run tests against pre-build react-dom and react-test-renderers //<Brian Vaughn>// - **[ee4806f47](facebook/react@ee4806f47 )**: Fixed flushing problem with tests //<Brian Vaughn>// - **[9d4fd7a24](facebook/react@9d4fd7a24 )**: Merged changes from 4.0.5 -> 4.0.6 from DevTools fork //<Brian Vaughn>// - **[a39d9c3df](facebook/react@a39d9c3df )**: 4.0.5 -> 4.0.6 //<Brian Vaughn>// - **[84b492f34](facebook/react@84b492f34 )**: Polyfill Symbol usage //<Brian Vaughn>// - **[c00a92064](facebook/react@c00a92064 )**: Merge branch 'master' into devtools-v4-merge //<Brian Vaughn>// - **[0da7bd060](facebook/react@0da7bd060 )**: React DevTools CHANGELOG entry for 4.0.6 //<Brian Vaughn>// - **[fc8077207](facebook/react@fc8077207 )**: [react-events] Ensure updateEventListeners updates in commit phase (#16540) //<Dominic Gannaway>// - **[0f6e3cd61](facebook/react@0f6e3cd61 )**: [Scheduler] Profiler Features (second try) (#16542) //<Dan Abramov>// - **[474b650ca](facebook/react@474b650ca )**: [react-events] Rename hook exports (#16533) //<Nicolas Gallagher>// - **[2f03aa6ee](facebook/react@2f03aa6ee )**: [react-events] Fix middle-click for Press (#16546) //<Nicolas Gallagher>// - **[16c340863](facebook/react@16c340863 )**: Only warn in case the fourth argument is a function (#16543) //<Bruno Scopelliti>// - **[05f5192e8](facebook/react@05f5192e8 )**: [Partial Hydration] Dispatching events should not work until hydration commits (#16532) //<Sebastian Markbåge>// - **[8a01b50fc](facebook/react@8a01b50fc )**: eslint-plugin-react-hooks@2.0.1 //<Dan Abramov>// - **[3ed289b3b](facebook/react@3ed289b3b )**: Clear canceled task node early (#16403) //<Dan Abramov>// - **[067282905](facebook/react@067282905 )**: Bump ESLint plugin to 2.0 (#16528) //<Dan Abramov>// - **[2559111c2](facebook/react@2559111c2 )**: [react-events] Rely on 'buttons' rather than 'button' (#16479) //<Nicolas Gallagher>// - **[c433fbb59](facebook/react@c433fbb59 )**: Revert "Revert "[ESLint] Forbid top-level use*() calls (#16455)"" (#16525) //<Dan Abramov>// - **[507f0fb37](facebook/react@507f0fb37 )**: Revert "[ESLint] Forbid top-level use*() calls (#16455)" (#16522) //<Sunil Pai>// - **[66c9fedc3](facebook/react@66c9fedc3 )**: Flow fixes //<Brian Vaughn>// - **[2e549efae](facebook/react@2e549efae )**: Moved DevTools custom Flow definitions //<Brian Vaughn>// - **[4da836af7](facebook/react@4da836af7 )**: Merged changes from 4.0.0 -> 4.0.5 from DevTools fork //<Brian Vaughn>// - **[5441b094a](facebook/react@5441b094a )**: 4.0.4 -> 4.0.5 //<Brian Vaughn>// - **[d2456c757](facebook/react@d2456c757 )**: Fixed standalone target not properly serving backend over localhost:8097 //<Brian Vaughn>// - **[3c6a21946](facebook/react@3c6a21946 )**: 4.0.3 -> 4.0.4 //<Brian Vaughn>// - **[95ca07955](facebook/react@95ca07955 )**: Fixed standalone bug that prevented backend from being served over localhost:8097 //<Brian Vaughn>// - **[95ffd3ccf](facebook/react@95ffd3ccf )**: 4.0.2 -> 4.0.3 //<Brian Vaughn>// - **[2bcc6c6d0](facebook/react@2bcc6c6d0 )**: 4.0.1 -> 4.0.2 //<Brian Vaughn>// - **[c100cc7b3](facebook/react@c100cc7b3 )**: 4.0.0 -> 4.0.1 //<Brian Vaughn>// - **[0763c48ed](facebook/react@0763c48ed )**: Bumped all versions to 4.0.0 //<Brian Vaughn>// - **[732f3a6ef](facebook/react@732f3a6ef )**: 4.0.0-alpha.9 -> 4.0.0-alpha.10 //<Brian Vaughn>// - **[db9e5c971](facebook/react@db9e5c971 )**: Updated all GitHub links to point to React repo //<Brian Vaughn>// - **[833f20634](facebook/react@833f20634 )**: Merge branch 'master' into devtools-v4-merge //<Brian Vaughn>// - **[efa5dbe7a](facebook/react@efa5dbe7a )**: Update CHANGELOG.md (#16439) //<bbolek>// - **[da0a47bec](facebook/react@da0a47bec )**: fix typo in CHNAGELOG.md (#16447) //<Heaven>// - **[69aafbf4d](facebook/react@69aafbf4d )**: Fix spelling in react-devtools CHANGELOG.md (#16448) //<Morgan McCauley>// - **[c80678c76](facebook/react@c80678c76 )**: Add "hydrationOptions" behind the enableSuspenseCallback flag (#16434) //<Sebastian Markbåge>// - **[2d68bd096](facebook/react@2d68bd096 )**: Fix message loop behavior when host callback is cancelled (#16407) //<Dan Abramov>// - **[96eb703bb](facebook/react@96eb703bb )**: [ESLint] Forbid top-level use*() calls (#16455) //<Dan Abramov>// - **[56f93a7f3](facebook/react@56f93a7f3 )**: Throw on unhandled SSR suspending (#16460) //<Dan Abramov>// - **[dce430ad9](facebook/react@dce430ad9 )**: [Flare] Rework the responder dispatching/batching mechanism (#16334) //<Dominic Gannaway>// - **[6ae6a7c02](facebook/react@6ae6a7c02 )**: Updated React DevTools changelog for 4.0.5 //<Brian Vaughn>// - **[56d1b0fb5](facebook/react@56d1b0fb5 )**: [react-events] DOM event testing library (#16433) //<Nicolas Gallagher>// - **[e89c19d16](facebook/react@e89c19d16 )**: Added DevTools 4.0.4 CHANGELOG entry //<Brian Vaughn>// - **[d97af798d](facebook/react@d97af798d )**: Updated DevTools CHANLOGE to add an unreleased change //<Brian Vaughn>// - **[21e793fb4](facebook/react@21e793fb4 )**: Added 4.0.1, 4.0.2, and 4.0.3 changelog entries (#16438) //<Brian Vaughn>// - **[c1d3f7f1a](facebook/react@c1d3f7f1a )**: [DevTools Changelog] Add a note on 4.0.2 //<Dan Abramov>// - **[6f86294e6](facebook/react@6f86294e6 )**: [DevTools Changelog] Add a note about restoring selection (#16409) //<Dan Abramov>// - **[600c57a9b](facebook/react@600c57a9b )**: Added OVERVIEW.md and updated CHANGELOG to point to it (#16405) //<Brian Vaughn>// - **[9b5985b3c](facebook/react@9b5985b3c )**: Added release date to DevTools CHANGELOG //<Brian Vaughn>// - **[ebd1f5ddb](facebook/react@ebd1f5ddb )**: [react-events] Press: improve test coverage (#16397) //<Nicolas Gallagher>// - **[85fbe3be3](facebook/react@85fbe3be3 )**: Merge branch 'master' into devtools-v4-merge //<Brian Vaughn>// - **[a9304e79d](facebook/react@a9304e79d )**: Add DevTools package placeholder package.json //<Brian Vaughn>// - **[6edff8f5e](facebook/react@6edff8f5e )**: Added CHANGELOG and READMEs for DevTools v4 NPM packages (#16404) //<Brian Vaughn>// - **[7ce229d3b](facebook/react@7ce229d3b )**: Made some incremental progress on Jest tests //<Brian Vaughn>// - **[41db902ed](facebook/react@41db902ed )**: Removed unused __TEST__ files //<Brian Vaughn>// - **[a473dca59](facebook/react@a473dca59 )**: Merge branch 'master' into devtools-v4-merge //<Brian Vaughn>// - **[4ba141230](facebook/react@4ba141230 )**: Revert "[Scheduler] Profiling features (#16145)" (#16392) //<Dan Abramov>// - **[407816725](facebook/react@407816725 )**: Removed (no longer necessary) node->node-events mapping //<Brian Vaughn>// - **[d7ca8847f](facebook/react@d7ca8847f )**: Add build-info.json to package files array for non-private DT packages //<Brian Vaughn>// - **[39209dc5b](facebook/react@39209dc5b )**: Update react-devtools-inline to embed react-debug-tools since it's not published yet //<Brian Vaughn>// - **[45dff31a7](facebook/react@45dff31a7 )**: Patched up react-devtools-core Webpack configs //<Brian Vaughn>// - **[58b39c60d](facebook/react@58b39c60d )**: Fixed web extensions //<Brian Vaughn>// - **[30b8ef375](facebook/react@30b8ef375 )**: Iterated on Webpack configs until I got the inline and shell packages seemingly working //<Brian Vaughn>// - **[44e410900](facebook/react@44e410900 )**: Merged master (with events -> legacy-events package rename) //<Brian Vaughn>// - **[b1a03dfdc](facebook/react@b1a03dfdc )**: Rename legacy "events" package to "legacy-events" (#16388) //<Brian Vaughn>// - **[9e64bf18e](facebook/react@9e64bf18e )**: [eslint-plugin-react-hooks] Fixed crash when referencing arguments in arrow functions. (#16356) //<Hristo Kanchev>// - **[e308a037b](facebook/react@e308a037b )**: chore: make tests compatible with Jest 24 (#15779) //<Simen Bekkhus>// - **[5fa99b5aa](facebook/react@5fa99b5aa )**: chore: add eslint-plugin-jest's valid-expect rule (#16332) //<Simen Bekkhus>// - **[a34ca7bce](facebook/react@a34ca7bce )**: [Scheduler] Profiling features (#16145) //<Andrew Clark>// - **[56636353d](facebook/react@56636353d )**: Partial support for React.lazy() in server renderer. (#16383) //<Lee Byron>// - **[6fbe63054](facebook/react@6fbe63054 )**: [Partial Hydration] Attempt hydration at a higher pri first if props/context changes (#16352) //<Sebastian Markbåge>// - **[e0a521b02](facebook/react@e0a521b02 )**: Make component stack last argument for deprecation warnings (#16384) //<Dan Abramov>// - **[1fd3906e9](facebook/react@1fd3906e9 )**: Remove "Waiting for async callback" User Timing measurement (#16379) //<Dan Abramov>// - **[89bbffed6](facebook/react@89bbffed6 )**: Cleanup Babel PR (ReactFreshPlugin) (#16340) //<lunaruan>// - **[441d014ce](facebook/react@441d014ce )**: Cleaned up some extnesions build script stuff //<Brian Vaughn>// - **[380da5fcc](facebook/react@380da5fcc )**: Moved OVERVIEW //<Brian Vaughn>// - **[b73e293cc](facebook/react@b73e293cc )**: Moved CHANGELOG //<Brian Vaughn>// - **[ac2e861fb](facebook/react@ac2e861fb )**: Fixed a bunch of Lint issues //<Brian Vaughn>// - **[51626ae2f](facebook/react@51626ae2f )**: Prettier //<Brian Vaughn>// - **[f7afe1b86](facebook/react@f7afe1b86 )**: Moved shell fixture into packages/react-devtools-shell //<Brian Vaughn>// - **[183f96f2a](facebook/react@183f96f2a )**: Prettier //<Brian Vaughn>// - **[edc46d7be](facebook/react@edc46d7be )**: Misc Flow and import fixes //<Brian Vaughn>// - **[08743b1a8](facebook/react@08743b1a8 )**: Reorganized folders into packages/* //<Brian Vaughn>// - **[ec7ef50e8](facebook/react@ec7ef50e8 )**: Reorganized things again into packages //<Brian Vaughn>// - **[65b93cd16](facebook/react@65b93cd16 )**: Merge remote-tracking branch 'devtools-merge/master' into devtools-v4-merge //<Brian Vaughn>// - **[6eb04b2b1](facebook/react@6eb04b2b1 )**: 4.0.0-alpha.8 -> 4.0.0-alpha.9 //<Brian Vaughn>// - **[8001b6432](facebook/react@8001b6432 )**: Fixed raw-loader + Jest problem //<Brian Vaughn>// - **[2eb3f4e9b](facebook/react@2eb3f4e9b )**: README typofix //<Brian Vaughn>// - **[2015a39c2](facebook/react@2015a39c2 )**: 4.0.0-alpha.7 -> 4.0.0-alpha.8 //<Brian Vaughn>// - **[e015e3d93](facebook/react@e015e3d93 )**: Added not about sync/batched root API being required //<Brian Vaughn>// - **[baac1dcc5](facebook/react@baac1dcc5 )**: Inline package tweaks: * Ignore messages from the DevTools browser extension. * Cleanup/clarify README //<Brian Vaughn>// - **[dc8580e64](facebook/react@dc8580e64 )**: New NPM package react-devtools-inline (#363) //<Brian Vaughn>// - **[db8542ad9](facebook/react@db8542ad9 )**: Refactor inspect/select logic so that $r contains hooks data (#364) //<Brian Vaughn>// - **[62e5fd57a](facebook/react@62e5fd57a )**: NPM package versions 4.0.0-alpha.5 -> 4.0.0-alpha.6 //<Brian Vaughn>// - **[4f8b7864e](facebook/react@4f8b7864e )**: Add "Welcome to the new DevTools" notification //<Brian Vaughn>// - **[3b2905b69](facebook/react@3b2905b69 )**: NPM package versions 4.0.0-alpha.4 -> 4.0.0-alpha.5 //<Brian Vaughn>// - **[7385de9fc](facebook/react@7385de9fc )**: react-devtools-core standalone bugfix: prevent electron crash //<Brian Vaughn>// - **[76c67399d](facebook/react@76c67399d )**: Re-enabled packages backend build to be production mode (whoops) //<Brian Vaughn>// - **[050cb8452](facebook/react@050cb8452 )**: 4.0.0-alpha.3 -> 4.0.0-alpha.4 //<Brian Vaughn>// - **[1e8aa8105](facebook/react@1e8aa8105 )**: Re-enable "view source" button for standalone shell //<Brian Vaughn>// - **[c7aff5503](facebook/react@c7aff5503 )**: 4.0.0-alpha.2 -> 4.0.0-alpha.3 //<Brian Vaughn>// - **[9a05e0b60](facebook/react@9a05e0b60 )**: Disable view-source button in standalone mode if no project roots are provided //<Brian Vaughn>// - **[56b001761](facebook/react@56b001761 )**: 4.0.0-alpha.1 -> 4.0.0-alpha.2 //<Brian Vaughn>// - **[f74c89b14](facebook/react@f74c89b14 )**: Misc improvements based on user feedback from Tim //<Brian Vaughn>// - **[ffb19346c](facebook/react@ffb19346c )**: NPM packages 4.0.0-alpha.0 -> 4.0.0-alpha.1 //<Brian Vaughn>// - **[4b34a77d2](facebook/react@4b34a77d2 )**: Improve Bridge Flow types (#352) //<Brian Vaughn>// - **[39ad101ea](facebook/react@39ad101ea )**: Removed reference to setDefaultThemeName() method //<Brian Vaughn>// - **[167daf7a4](facebook/react@167daf7a4 )**: Updating NPM packages as 4.0.0-alpha.0 //<Brian Vaughn>// - **[249a2e043](facebook/react@249a2e043 )**: Detect React Native v3 backend and show warning //<Brian Vaughn>// - **[cb3fb4212](facebook/react@cb3fb4212 )**: Patch console to append component stacks (#348) //<Brian Vaughn>// - **[0f2fb5bad](facebook/react@0f2fb5bad )**: Standalone NPM packages and React Native support (#335) //<Brian Vaughn>// - **[21d6395a1](facebook/react@21d6395a1 )**: Add test case for #16359 (#16371) //<Andrew Clark>// - **[a29adc9f6](facebook/react@a29adc9f6 )**: Dehydrated suspense boundaries in suspense list (#16369) //<Sebastian Markbåge>// - **[50addf4c0](facebook/react@50addf4c0 )**: Refactor Partial Hydration (#16346) //<Sebastian Markbåge>// - **[c2034716a](facebook/react@c2034716a )**: Fix typo in error code map (#16373) //<Andrew Clark>// - **[62b04cfa7](facebook/react@62b04cfa7 )**: Remove unused import //<Andrew Clark>// - **[3eeb64551](facebook/react@3eeb64551 )**: Remove flag that reverts #15650 (#16372) //<Andrew Clark>// - **[2716d91ec](facebook/react@2716d91ec )**: Reset didReceiveUpdate in beginWork (#16359) //<Sebastian Markbåge>// - **[9449f8bf3](facebook/react@9449f8bf3 )**: [react-events] Fix keyboard responder test (#16368) //<Nicolas Gallagher>// - **[107521a95](facebook/react@107521a95 )**: [react-events] Focus/FocusWithin responders with fallbacks (#16343) //<Nicolas Gallagher>// - **[7a7e792a6](facebook/react@7a7e792a6 )**: Make SchedulerMinHeap flow strict (#16351) //<Desmond Brand>// - **[e349da19b](facebook/react@e349da19b )**: [Scheduler] Temporarily remove wrapper function (#16345) //<Andrew Clark>// - **[0bd0c5269](facebook/react@0bd0c5269 )**: Upgrade ESLint so we can use JSX Fragment syntax (#16328) //<Andrew Clark>// - **[07d062dea](facebook/react@07d062dea )**: Mark spawned work for client-rendered suspense boundary (#16341) //<Sebastian Markbåge>// - **[07a02fb80](facebook/react@07a02fb80 )**: [react-events] Refactor unit tests for Hover (#16320) //<Nicolas Gallagher>// - **[f62b53d90](facebook/react@f62b53d90 )**: fix some missing assertions (#16336) //<Sunil Pai>// - **[b9faa3b09](facebook/react@b9faa3b09 )**: [act] remove obsolete container element (#16312) //<Sunil Pai>// - **[66a474227](facebook/react@66a474227 )**: use a different link in the UNSAFE_ component warnings (#16321) //<Sunil Pai>// - **[8d5403877](facebook/react@8d5403877 )**: Add use-subscription to Rollup bundle config (#16326) //<Brian Vaughn>// - **[b12a98206](facebook/react@b12a98206 )**: Babel 7 (#16297) //<lunaruan>// - **[d77c6232d](facebook/react@d77c6232d )**: [Scheduler] Store Tasks on a Min Binary Heap (#16245) //<Andrew Clark>// - **[95767acf8](facebook/react@95767acf8 )**: Bump deps in packages/**/package.json (#16325) //<Andrew Clark>// - **[6536973a0](facebook/react@6536973a0 )**: Prepare use-subscription v1 for publishing (#16324) //<Brian Vaughn>// Changelog: [General][Changed] - React sync for revisions 85d05b3...4eeee35 Reviewed By: TheSavior Differential Revision: D18008433 fbshipit-source-id: 3b528bb5019d84c69e4dda4f836e852a4f263ba4
Motivation
We noticed that on Android the lineHeight behaviour is different from iOS for built in fonts and custom fonts. The problem becomes visible when the lineHeight approaches the fontSize, showing a cut-off on the bottom of the TextView. This issue has been raised before in #10712. There is a mention of a PR with a fix in that issue, which has not been merged yet. This implementation is a less intrusive fix leaving the current lineHeight approach in place and fixing the discrepancy only.
This proposed change prioritises ascent over descent for reduction, making the lineHeight functionality behave identical to iOS.
Test Plan
There is no existing test covering the lineHeight property and its behaviour in the CustomLineHeightSpan. This PR contains new unit tests that covers the various scenario's for the lineHeight calculations.
The original behaviour, before the change can against these unit tests. The case that fails is
shouldReduceAscentThird
, which can be made to succeed on the old code by changing the asserts to:The unit test succeeds for the current implementation, which has the values for ascent and descent inverted.
Below screenshots show before, after and iOS:
BEFORE
AFTER
iOS
Release Notes
[ANDROID] [BUGFIX] [Text] - Fix the lineHeight behaviour on Android to match iOS