This fixes a bug which occurred when returning from background - sometimes the system would set
an unexpected elevation value which seems like the default elevation.
This commit checks if the new elevation value was specified by RNN before setting it.
Fixes an issue with ScrollView inside an Overlay. While down events were propagated to the view, move events were consumed by the overlay preventing scroll components from functioning correctly.
Played around with context api, tried to get the wrapped component to rerender after global context
was updated - this is what I came up with.
Note: this commit makes the playground app use a newer js core as the js core which shipped with RN on Android
is missing javascript Proxy.
Closes #4517
Apparently TopBar elevation property is animated. Meaning that if 4dp elevation is set, when the
view appears its elevation is animated from 0dp to 4dp.
This resulted in rare race condition where the onAnimationEnd callback was called after
we set the desired elevation value, and an unexpected elevation value was set.
Add waitForRender options for setRoot animation and TopBar components
When set, the ui will become visible only after the root screen and TopBar components have been rendered.
Usage
Add the following to the root layout’s options, or to its child
```
animations: {
setRoot: {
waitForRender: true
}
}
```
TopBar components (Title, background, buttons) can be synced as well by adding `waitForRender: true`, for example:
```
component: {
name: 'navigation.playground.CustomTopBar',
alignment: 'center',
waitForRender: true,
}
```
## What this PR is about?
Finally all strict rules are enables for TypeScript compiler! 🎉 Basically previously `noImplicitAny` was turned off but now it plus all strict rules are turned ON! 💋
## Some highlights of the changes
- `Element` renamed internally to `SharedElement` to make more sense what is it
- `LayoutTreeParser`'s responsibility is now to do all `id` related stuff. Previously it was spread between `LayoutTreeCrawler` and `LayoutTreeParse` so it is more simple now
- clean up a lot of tests because they were testing duplicate stuff that was covered by other tests already
- removed all usages of `static get options` and replaces them with `static options`. This is how it is in the docs plus you cannot have `static get options(passProps)` because it is impossible to have getter with parameters.
Until now tabs were added to screen in reverse order, meaning the last tab was attached to hierarchy first and the first tab was attached last.
This caused the first tab, which usually should appear first, to be rendered last as the root view’s startReactApplication was called last.
This commit changes render order so that the first tab is rendered first. Some apps will probably see an improvement in time to interaction as a result.