364 Commits

Author SHA1 Message Date
Nick Lockwood
7fa08e5c3f Updates for Fri 10 Jul 2015-07-10 17:48:12 +01:00
Alex Akers
ffaf16283f [React Native] Add new E2E tests 2015-07-10 04:12:28 -08:00
LYK
fc059857e2 [Text] Get the system font instead of Helvetica programmatically and add a virtual fontName called "System"
Summary:
Get the system font instead of Helvetica programmatically and add a virtual fontName called "System" that defaults to whatever the current system font is.
#1611
Closes https://github.com/facebook/react-native/pull/1635
Github Author: LYK <dalinaum@gmail.com>
2015-07-09 15:48:49 -08:00
Spencer Ahrens
233f80d6c2 Fix tests
e2e flowconfig needed update, plus tweaks
2015-07-09 14:12:56 +02:00
Spencer Ahrens
7ce8cd7222 Updates Tue July 7th and Wed July 8th including Animated 2015-07-09 12:59:47 +02:00
Krzysztof Magiera
9b162d7659 [ReactNative] Add support for onLayout View property. 2015-07-09 00:56:09 -08:00
Jarrod Mosen
bb07817023 Update SegmentedControlIOSExample.js
Summary:
`event.nativeEvent` now uses `selectedSegmentIndex`, not `selectedIndex`.
Closes https://github.com/facebook/react-native/pull/1872
Github Author: Jarrod Mosen <jarrod.mosen@me.com>
2015-07-08 12:52:04 -08:00
Nick Lockwood
1b7699f671 Migrate unit tests from FBReactKitModules to FBReactKit 2015-07-07 16:39:35 -08:00
Spencer Ahrens
566ca9e58d [ReactNative] fix duplicate LayoutAnimation warning 2015-07-07 14:15:04 -08:00
Spencer Ahrens
b770310555 [ReactNative] Move Animated to Open Source
Summary:
Moves the files over and Exports Animated from 'react-native'.
2015-07-07 13:44:09 -08:00
KJlmfe
b57a14d07c <Text> module add textDecoration style attributes
Summary:
This is simply a rebased and squashed version of @KJlmfe's PR over at https://github.com/facebook/react-native/pull/845

It was actually already squashed into one commit, but for some reason that was hard to see from the original PR.
Closes https://github.com/facebook/react-native/pull/1869
Github Author: KJlmfe <kjlmfe@gmail.com>
2015-07-07 06:15:20 -08:00
Alexsander Akers
02db374e50 [React Native] Remove layout-only nodes (Take 2!)
Summary:
Remove layout-only views. Works by checking properties against a list of known properties that only affect layout. The `RCTShadowView` hierarchy still has a 1:1 correlation with the JS nodes.

This works by adjusting the tags and indices in `manageChildren`. For example, if JS told us to insert tag 1 at index 0 and tag 1 is layout-only with children whose tags are 2 and 3, we adjust it so we insert tags 2 and 3 at indices 0 and 1. This keeps changes out of `RCTView` and `RCTScrollView`. In order to simplify this logic, view moves are now processed as view removals followed by additions. A move from index 0 to 1 is recorded as a removal of view at indices 0 and 1 and an insertion of tags 1 and 2 at indices 0 and 1. Of course, the remaining indices have to be offset to take account for this.

The `collapsible` attribute is a bit of a hack to force `RCTScrollView` to always have one child. This was easier than rethinking out the logic there, but we could change this later.
2015-07-07 05:06:50 -08:00
Alexsander Akers
3325e8f768 Updates from Tuesday, 7 July 2015-07-07 13:56:11 +01:00
Alex Akers
b4cd019f39 [React Native] Remove animated GIFs from TicTacToe example 2015-07-06 04:11:03 -08:00
Alexsander Akers
e37e794ccf Merge new changes from fbobjc 2015-07-03 13:22:43 +01:00
Alex Akers
93d3cc135d [React Native] Fix failing UIExplorer integration tests 2015-07-03 04:15:54 -08:00
Alexsander Akers
c1d7c0df47 Updates from Thu 3 Jul 2015-07-03 11:37:17 +01:00
Alex Akers
16cb41a24e [React Native] Fix padding in UIExplorer 2015-07-03 02:24:56 -08:00
Rui Chen
66e32dc406 [Treehouse RN] Sync for D2161376 2015-07-02 19:50:47 -08:00
Alex Akers
00e85cbc85 [React Native] Persist open UIExplorer example between refreshes 2015-07-02 09:36:26 -08:00
Alexsander Akers
4886b3dc57 Merge branch 'flow-13' of https://github.com/ide/react-native into Update_Wed_1_Jul 2015-07-01 22:06:24 +01:00
Alexsander Akers
d161640f52 Update with required PRs 2015-07-01 22:05:10 +01:00
James Ide
7a8398b956 [Flow] Update flowconfig's version req to 0.13.1, fix Movies example typechecking
Summary:
This should fix tests.

Closes https://github.com/facebook/react-native/pull/1819
Github Author: James Ide <ide@jameside.com>

Test Plan:  Run Travis CI tests. Also run the movies app and verify that there are no invariant violations.
2015-07-01 13:01:52 -08:00
Alexsander Akers
44c587e828 Updates from Wed 1 Jul 2015-07-01 19:10:35 +01:00
Philipp von Weitershausen
14fef6474d [ReactNative] expose missing haste modules through 'react-native' node module 2015-06-30 18:57:26 -08:00
James Ide
301c01260d [Flow] Update flowconfig's version req to 0.13.1, fix Movies example typechecking
This should fix tests.

Test Plan: Run Travis CI tests. Also run the movies app and verify that there are no invariant violations.
2015-06-30 16:52:55 -07:00
Andy Street
7196445cc6 [react_native] Update common UI examples 2015-06-29 04:20:04 -08:00
Alex Kotliarskyi
843e181542 Updates from Fri 26, Jun 2015-06-26 15:16:59 -07:00
Owen Kelly
1cca4fb769 [NavigatorIOS] Allow translucent on NavigatorIOS
Summary:
Hi,

I've updated the NavigatorIOS component to allow setting the translucent property.

usage is:
```
            <NavigatorIOS
                translucent={false}
            />
```

This is my first contrib to react-native, so apologies if I've missed something.

Cheers,
Owen
Closes https://github.com/facebook/react-native/pull/1273
Github Author: Owen Kelly <owen@novede.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-06-26 07:17:54 -08:00
chaceliang
7159a4e947 Revert "[React Native] Remove layout-only nodes" 2015-06-25 13:30:06 -08:00
Alex Akers
3c5b4b0a9f [React Native] Remove layout-only nodes
Summary:
Remove layout-only views. Works by checking properties against a list of known properties that only affect layout. The `RCTShadowView` hierarchy still has a 1:1 correlation with the JS nodes.

This works by adjusting the tags and indices in `manageChildren`. For example, if JS told us to insert tag 1 at index 0 and tag 1 is layout-only with children whose tags are 2 and 3, we adjust it so we insert tags 2 and 3 at indices 0 and 1. This keeps changes out of `RCTView` and `RCTScrollView`. In order to simplify this logic, view moves are now processed as view removals followed by additions. A move from index 0 to 1 is recorded as a removal of view at indices 0 and 1 and an insertion of tags 1 and 2 at indices 0 and 1. Of course, the remaining indices have to be offset to take account for this.

The `collapsible` attribute is a bit of a hack to force `RCTScrollView` to always have one child. This was easier than rethinking out the logic there, but we could change this later.

@public

Test Plan: There are tests in `RCTUIManagerTests.m` that test the tag- and index-manipulation logic works. There are various scenarios including add-only, remove-only, and move. In addition, two scenario tests verify that the optimization works by checking the number of views and shadow views after various situations happen.
2015-06-25 09:12:00 -08:00
Alex Kotliarskyi
2e4cbc41b0 Updates from Wed 24 Jun 2015-06-24 10:49:09 -07:00
Hannes Verlinde
d859620816 Add unit tests for RCTShadowView. 2015-06-24 00:19:46 -08:00
Tadeu Zagallo
3bb303e81a [ReactNative] Explictly set displayName on tests
Summary:
@public

For some weird reason sometimes displayName is undefined on the OSS tests, manually
set it for now to unbreak the tests.

Test Plan: Run the tests on OSS
2015-06-23 19:14:55 -08:00
Nick Lockwood
0624a0fe52 Fixed async local storage 2015-06-23 14:24:42 -08:00
Nick Lockwood
86639450ee Fixed AsyncLocalStorage bug 2015-06-22 14:40:33 -08:00
Gabe Levi
972b546fc6 [Flow] Fix or suppress errors in react-native for Flow v0.13.0 2015-06-22 09:48:15 -08:00
Tadeu Zagallo
c9f193cdd0 [ReactNative] Stop build tests on non-test builds
Summary:
@public

UIExplrer's test targets were being built on normal builds as well, remove it.

Test Plan: Insert an `#error` on a test file, and run the project. It shouldn't fail anymore.
2015-06-22 02:56:32 -08:00
Brent Vatne
6e568ee811 [SampleApp] Remove $(SRCROOT) from INFOPLIST_FILE to fix agvtool
Summary:
Fixed #879 - I'm not too familiar with this aspect of XCode so a sanity check here would be great @tadeuzagallo 😉
Closes https://github.com/facebook/react-native/pull/1466
Github Author: Brent Vatne <brent.vatne@madriska.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-06-22 02:12:58 -08:00
Nick Lockwood
c8c254ce13 Changed methodQueue to a property 2015-06-19 04:20:39 -08:00
Spencer Ahrens
7d62b6077b [ReactNative] Fix 32 bit check compile error
Summary:
@public

The test file is getting compiled when hitting cmd+R which fails for 64-bit
devices even if not trying to run tests.  Change back to runtime check to fix.

Test Plan:
cmd+R works for iPhone 6, cmd+U fails as expected on iPhone 6, works
for iPhone 5
2015-06-18 20:20:18 -08:00
alvaromb
a48e9b4690 [WebView] Exposed scalesPageToFit UIWebView property
Summary:
Added the ``scalesPageToFit`` prop to ``WebView``. This allows ``UIWebView`` to handle user zoom and scale.
Closes https://github.com/facebook/react-native/pull/1631
Github Author: alvaromb <amedina@apsl.net>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-06-17 13:56:38 -08:00
Nick Lockwood
6573d256ba Improve test architecture so failures don't crash the simulator 2015-06-17 07:09:23 -08:00
Nick Lockwood
d83ee3bd5a Better text background behavior 2015-06-17 05:35:57 -08:00
Hedger Wang
0a875790f5 [Navigator]: Allow developer to observe the focus change events from the owner or the children
of the navigator component.

Summary:
Per offline discussion with @evv, we'd like to deprecate the `onDidFocus` and `onWillFocus`
API that makes it really hard for the descendent children of a navigator to observe its focus
change events.
@public

Since for now the descendent children do have access to the navigator via `this.props.navigator`,
this diff makes it easy to observe the focus change event by doing:

```
this.props.navigator.addListener('willfocus', this._onFocus);
```

The goal is to make the event system in navigator more useful and maintainable.

Test Plan:
Test Video: https://www.facebook.com/pxlcld/mrzS
1. jest:  ./Libraries/FBReactKit/js/runTests.js NavigationEventEmitter
2. Load UI Explorer: <Navigator />, see console logs that shows the focus change events fires.
2015-06-16 09:09:08 -08:00
Tadeu Zagallo
1607d8e9b4 Updates from Tue 16 Jun 2015-06-16 11:30:14 +01:00
Alex Akers
bd081d84a7 [React Native] Update operating system and architecture check 2015-06-16 02:00:02 -08:00
James Ide
5d6a89bc61 [Text] Support "textAlign: justify" in Text components
Summary:
Finished adding support for justified text on iOS... just had to expose a prop value.
Fixes #529

Closes https://github.com/facebook/react-native/pull/1486
Github Author: James Ide <ide@jameside.com>

Test Plan:
 View the Text example in the UIExplorer and see that all but the last lines of text in the justified text example are justified and extend to the far right of the available space. Tested on iOS 8, iPhone 6 simulator.

![text](https://cloud.githubusercontent.com/assets/379606/7926252/a90d2e98-0884-11e5-9f12-5cbb27505a0b.png)
2015-06-15 12:00:12 -08:00
Nick Lockwood
650fc9de4c Increased warning levels to -Wall -Wextra, and fixed Xcode 7 beta issues
Summary:
@public

I've increased the warning levels in the OSS frameworks, which caught a bunch of minor issues. I also fixed some new errors in Xcode 7 relating to designated initializers and TLS security.

Test Plan:
* Test the sample apps and make sure they still work.
* Run tests.
2015-06-15 07:52:50 -08:00
Tadeu Zagallo
0d00a0e600 Updates from Mon 15 Jun 2015-06-15 11:30:56 +01:00