Commit Graph

12496 Commits

Author SHA1 Message Date
Eli White 10277cc5ba Remove unused canonical check in fiber host component (#16914) 2019-10-02 11:07:20 -07:00
Nicolas Gallagher ab1a4f249e Move eventSystemFlags to last argument in event plugin extractors (#16978)
Fix for necolas/react-native-web#1443
2019-10-02 10:31:15 -07:00
Nicolas Gallagher f6efb224b0 [react-interactions] Tap cancels on second pointerdown (#16936)
This patch causes onTapCancel to be called whenever a second pointer interacts
with the responder target.
2019-10-01 15:13:31 -07:00
Dominic Gannaway 34457729a6 [react-interactions] Add allowModifiers flag to FocusList + FocusTable (#16971) 2019-10-01 17:59:52 +02:00
Rango Yuan b34f042e5b Fix mouseenter handlers fired twice (#16928) 2019-10-01 14:03:14 +02:00
Andrew Clark 05dc814cf0 Remove IIFE wrappers from dev invariant checks (#16963)
The error transform works by replacing calls to `invariant` with
an `if` statement.

Since we're replacing a call expression with a statement, Babel wraps
the new statement in an immediately-invoked function expression (IIFE).
This wrapper is unnecessary in practice because our `invariant` calls
are always part of their own expression statement.

In the production bundle, the function wrappers are removed by Closure.
But they remain in the development bundles.

This commit updates the transform to confirm that an `invariant` call
expression's parent node is an expression statement. (If not, it throws
a transform error.)

Then, it replaces the expression statement instead of the expression
itself, effectively removing the extraneous IIFE wrapper.
2019-09-30 11:14:51 -07:00
Brian Vaughn 2c8832075b React DevTools v4.1.2 -> v.4.1.3 2019-09-30 09:33:23 -07:00
Brian Vaughn 6c73a1e776 Updated DevTools CHANGELOG 2019-09-30 08:31:47 -07:00
David Huang 6a3de7a414 [DevTools] postMessage target origin needs to be '*' for local files (#16953) 2019-09-30 08:29:18 -07:00
Dominic Gannaway ac8e8b3278 [react-interactions] Add tab handling to FocusList (#16958) 2019-09-30 17:13:35 +02:00
Dominic Gannaway 10c7dfe3b4 [react-interactins] FocusTable tabScope handling+tabIndex control (#16922) 2019-09-30 11:41:20 +02:00
Kirankumar Ambati d3622d0f97 chore: updated comment message (#16949) 2019-09-29 15:00:49 -07:00
Andrew Clark 2a264a9dbe Update local version numbers for 16.10.1 release 2019-09-28 21:41:42 -07:00
Andrew Clark 22019ef5a2 Changelog for v16.10.1 2019-09-28 11:24:19 -07:00
Sebastian Markbåge d8a76ad580 Allow Suspense Mismatch on the Client to Silently Proceed (#16943)
* Regression test: Suspense + hydration + legacy

* Allow Suspense Mismatch on the Client to Silently Proceed

This fixes but isn't actually the semantics that we want this case to have.
2019-09-28 10:43:53 -07:00
Sebastian Markbåge 9d637844e9 Remove enableUserBlockingEvents flag (#16882)
Seems like this worked out. We can clean up the flag now.
2019-09-27 19:46:56 -07:00
Sebastian Markbåge fe31cc710e [Selective Hydration] Increase priority for non-synchronous discrete events and retries (#16935)
* Increase retryTime for increased priority dehydrated boundaries

* Increaese the priority to user blocking for every next discrete boundary
2019-09-27 17:27:17 -07:00
Brian Vaughn b550679617 Fixed typo in DevTools CHANGELOG 2019-09-27 17:10:27 -07:00
Brian Vaughn 5184346daf DevTools v4.1.1 -> v4.1.2 2019-09-27 17:03:17 -07:00
Brian Vaughn d4278663c6 Replaced === check with Object.is() to support values like NaN (#16934) 2019-09-27 16:54:53 -07:00
Nicolas Gallagher d1121c0174 [react-interactions] Fix virtual click heuristic (#16915) 2019-09-27 15:38:47 -07:00
Andrew Clark f553515d1e Fix heading level in changelog 2019-09-27 13:37:36 -07:00
Andrew Clark 7dc83a6100 Changelog for 16.10 2019-09-27 13:31:47 -07:00
Andrew Clark 93f5f11b79 Update local version numbers for 16.10 release 2019-09-27 13:31:35 -07:00
Luna Ruan c8dc7a926e expose isHydrating (#16909)
expose isHydrating for FB
2019-09-26 14:47:01 -07:00
Eli White db8afe4f63 Add HostComponent type to ReactNative (#16898)
* Add HostComponent type to ReactNative

* Use type alias imports instead of wildcard

* Fix forgotten Object in measureLayout type
2019-09-26 14:42:18 -07:00
Andrew Clark fad5102101 [bugfix] Fix false positive render phase update (#16907)
Need to reset the current "debug phase" inside the catch block.
Otherwise React thinks we're still in the render phase during the
subsequent event.
2019-09-26 12:47:48 -07:00
Brian Vaughn a9cd9a765b DevTools v4.1.0 -> v4.1.1 2019-09-26 10:22:59 -07:00
Brian Vaughn b6606ecba8 DevTools shows unsupported renderer version dialog (#16897)
* DevTools shows unsupported renderer version dialog

* Optimistic CHANGELOG udpate
2019-09-26 08:41:46 -07:00
Brian Vaughn 84e83db1ee Updated DevTools CHANGELOG 2019-09-26 08:26:18 -07:00
Dominic Gannaway b9811ed5bc [react-interactions] Add wrapping support to FocusList/FocusTable (#16903) 2019-09-26 15:15:48 +02:00
David Huang 49b0cb6db8 Moving backend injection to the content script (#16900) 2019-09-26 14:03:07 +01:00
Sebastian Markbåge 3694a3b5e9 Selective Hydration (#16880)
* Add Feature Flag for Selective Hydration

* Enable Synchronous Hydration of Discrete Events

* Resolve cyclic dependency
v16.10.0
2019-09-25 15:26:27 -07:00
Dominic Gannaway 4bb0e96b4b [react-interactions] FocusTable key press bound propgataion (#16895) 2019-09-25 21:12:39 +02:00
Brian Vaughn fa1a326227 Update useEditableValue hook to sync external value changes (#16878)
* Update useEditableValue to mirror value cahnges

Previously, the hook initialized local state (in useState) to mirror the prop/state value. Updates to the value were ignored though. (Once the state was initialized, it was never updated.) The new hook updates the local/editable state to mirror the external value unless there are already pending, local edits being made.

* Optimistic CHANGELOG update

* Added additional useEditableValue() unit test cases
2019-09-25 10:46:27 -07:00
Dominic Gannaway 57bf275fbd [devtools] Add support for React Scope symbol/number (#16893) 2019-09-25 19:03:37 +02:00
Dominic Gannaway 7c3bd08b37 [react-interactions] Add more documentation for a11y components (#16894) 2019-09-25 19:01:15 +02:00
Sebastian Markbåge a06d181af0 Include tag in begin/complete invariant (#16881) 2019-09-25 08:10:35 -07:00
Sebastian Markbåge 0d8c0cd096 These flags are hard coded in our internal config (#16883)
By hard coding them here they can get properly DCE and don't have to be
sent to users. The internal config should only have dynamic flags.
2019-09-25 08:00:29 -07:00
Dominic Gannaway d6d83d7060 [react-interactions] Add Portal propagation configuration (#16889) 2019-09-25 16:56:51 +02:00
Dominic Gannaway d0ebde77f6 [react-interactions] Add initial docs explaining React Scopes (#16892) 2019-09-25 14:57:47 +02:00
Joshua Gross 32e5c97d11 [React Native] Improve errors for invalid ViewConfig getter functions (#16879)
* [React Native] Improve logging for missing view configs and invalid view config getter functions

* [React Native] Improve logging for missing view configs and invalid view config getter functions
2019-09-24 17:46:21 -07:00
Dominic Gannaway ebc299fc2f [react-interactions] TabFocus -> FocusManager (#16874) 2019-09-24 23:26:20 +02:00
Dominic Gannaway 793f176dad [react-interactions] Make FocusList bundle (#16876) 2019-09-24 18:02:13 +02:00
Dominic Gannaway 68a87eee54 [react-interactions] Add FocusList component (#16875) 2019-09-24 17:14:29 +02:00
Jessica Franco 18d2e0c03e Warning system refactoring (part 1) (#16799)
* Rename lowPriorityWarning to lowPriorityWarningWithoutStack

This maintains parity with the other warning-like functions.

* Duplicate the toWarnDev tests to test toLowPriorityWarnDev

* Make a lowPriorityWarning version of warning.js

* Extract both variants in print-warning

Avoids parsing lowPriorityWarning.js itself as the way it forwards the
call to lowPriorityWarningWithoutStack is not analyzable.
2019-09-24 13:45:38 +01:00
Andrew Clark 8b580a89d6 Idle updates should not be blocked by hidden work (#16871)
* Idle updates should not be blocked by hidden work

Use the special `Idle` expiration time for updates that are triggered at
Scheduler's `IdlePriority`, instead of `Never`.

The key difference between Idle and Never¹ is that Never work can be
committed in an inconsistent state without tearing the UI. The main
example is offscreen content, like a hidden subtree.

¹ "Never" isn't the best name. I originally called it that because it
"never" expires, but neither does Idle. Since it's mostly used for
offscreen subtrees, we could call it "Offscreen." However, it's also
used for dehydrated Suspense boundaries, which are inconsistent in the
sense that they haven't finished yet, but aren't visibly inconsistent
because the server rendered HTML matches what the hydrated tree would
look like.

* Reset as early as possible using local variable

* Updates in a hidden effect should be Idle

I had made them Never to avoid an extra render when a hidden effect
updates the hidden component -- if they are Idle, we have to render once
at Idle, which bails out on the hidden subtree, then again at Never to
actually process the update -- but the problem of needing an extra
render pass to bail out hidden updates already exists and we should fix
that properly instead of adding yet another special case.
2019-09-23 20:52:48 -07:00
Nicolas Gallagher c5e7190ed4 [react-interactions] Press with useRef instead of useState (#16870)
We only need to read and modify the value for the lifetime of the hook
2019-09-23 16:25:13 -07:00
Brian Vaughn 911104a129 DevTools CHANGELOG update 2019-09-23 12:58:58 -07:00
Brian Vaughn bce2ac63a9 Revert change to backend injection method from PR #16752 (#16864)
PR #16752 changed how we were injecting the backend script to be done by the content script in order to work around Trusted Type limitations with our previous approach. This may have caused a regression (see #16840) so I'm backing it out to verify.
2019-09-23 12:56:36 -07:00