834 Commits

Author SHA1 Message Date
Alex Akers
86709c15cb [React Native] Support variable corner radii on RCTView 2015-05-13 13:24:37 -07:00
Gabe Levi
184bb1151a [Flow] v0.11.0 cleaning - Part 14 (react-native-github) 2015-05-13 13:24:36 -07:00
Vladimir Kurchatkin
a142ed50ff Add letterSpacing style property for Text
Summary:
Fixes #457
Closes https://github.com/facebook/react-native/pull/482
Github Author: Vladimir Kurchatkin <vladimir.kurchatkin@gmail.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-05-13 13:24:36 -07:00
Tadeu Zagallo
ef339250b5 [ReactNative] Add prompt to AlertIOS
Summary:
Add `AlertIOS.prompt`

It's compatible with the js spec, with the exception that I had to add
a callback param since it's async. Also supports the same button configuration
as `AlertIOS.alert`.

@public

Test Plan:
I've updated the `AlertIOS` example on UIExplorer with every
valid combination of
parameters, so just going through it should be fine.
2015-05-13 13:24:36 -07:00
Krzysztof Magiera
ff00e1496c [ReactNative] Rename ReactIOS JS module (and relatives) to ReactNative. 2015-05-13 13:24:35 -07:00
Alex Kotliarskyi
9ff6c0e36b Upgrade SampleApp LaunchScreen.xib 2015-05-08 11:31:02 -07:00
Alex Kotliarskyi
4bd07f9b5e Fix flow errors 2015-05-08 11:04:22 -07:00
Alex Kotliarskyi
320208f4f7 Updates from Fri 8 May 2015-05-08 10:29:59 -07:00
Brent Vatne
7141948a05 Bump fetch and add exports/globals for Headers, Request and Response
Summary:
Now on fetch 0.8.1, the latest tagged release. Previous version used was 0.7.0. See #1162 cc @vjeux @jtremback
Closes https://github.com/facebook/react-native/pull/1192
Github Author: Brent Vatne <brent.vatne@madriska.com>

Test Plan: I arc patched and ran movies demo and storyline, they work fine
2015-05-07 13:24:16 -08:00
Spencer Ahrens
1ef4e00fba [ReactNative] Introduce onLayout events
Summary:
Simply add an `onLayout` callback to a native view component, and the callback
will be invoked with the current layout information when the view is mounted and
whenever the layout changes.

The only limitation is that scroll position and other stuff the layout system
isn't aware of is not taken into account.  This is because onLayout events
wouldn't be triggered for these changes and if they are desired they should be
tracked separately (e.g. with `onScroll`) and combined.

Also fixes some bugs with LayoutAnimation callbacks.

@public

Test Plan:
- Run new LayoutEventsExample in UIExplorer and see it work correctly.
- New integration test passes internally (IntegrationTest project seems busted).
- New jest test case passes.

{F22318433}

```
2015-05-06 15:45:05.848 [info][tid:com.facebook.React.JavaScript] "Running application "UIExplorerApp" with appParams: {"rootTag":1,"initialProps":{}}. __DEV__ === true, development-level warning are ON, performance optimizations are OFF"
2015-05-06 15:45:05.881 [info][tid:com.facebook.React.JavaScript] "received text layout event
", {"target":27,"layout":{"y":123,"x":12.5,"width":140.5,"height":18}}
2015-05-06 15:45:05.882 [info][tid:com.facebook.React.JavaScript] "received image layout event
", {"target":23,"layout":{"y":12.5,"x":122,"width":50,"height":50}}
2015-05-06 15:45:05.883 [info][tid:com.facebook.React.JavaScript] "received view layout event
", {"target":22,"layout":{"y":70.5,"x":20,"width":294,"height":204}}
2015-05-06 15:45:05.897 [info][tid:com.facebook.React.JavaScript] "received text layout event
", {"target":27,"layout":{"y":206.5,"x":12.5,"width":140.5,"height":18}}
2015-05-06 15:45:05.897 [info][tid:com.facebook.React.JavaScript] "received view layout event
", {"target":22,"layout":{"y":70.5,"x":20,"width":294,"height":287.5}}
2015-05-06 15:45:09.847 [info][tid:com.facebook.React.JavaScript] "layout animation done."
2015-05-06 15:45:09.847 [info][tid:com.facebook.React.JavaScript] "received image layout event
", {"target":23,"layout":{"y":12.5,"x":82,"width":50,"height":50}}
2015-05-06 15:45:09.848 [info][tid:com.facebook.React.JavaScript] "received view layout event
", {"target":22,"layout":{"y":110.5,"x":60,"width":214,"height":287.5}}
2015-05-06 15:45:09.862 [info][tid:com.facebook.React.JavaScript] "received text layout event
", {"target":27,"layout":{"y":206.5,"x":12.5,"width":120,"height":68}}
2015-05-06 15:45:09.863 [info][tid:com.facebook.React.JavaScript] "received image layout event
", {"target":23,"layout":{"y":12.5,"x":55,"width":50,"height":50}}
2015-05-06 15:45:09.863 [info][tid:com.facebook.React.JavaScript] "received view layout event
", {"target":22,"layout":{"y":128,"x":60,"width":160,"height":337.5}}
```
2015-05-07 12:27:44 -08:00
James Ide
b97ce93cea [Nav] Add support for bar button icons and left buttons
Summary:
NavigatorIOS supports four new properties:

  - **rightButtonImageSource:** The source of an image to display in the top right. This must be a static image since UINavigationController only supports UIImages. Adding support for UIImageViews (or arbitrary views) is more complicated because custom views do not fade on touch and do not have hit slop the same way that UIImage buttons do. Usage: `rightButtonImageSource: ix('ImageName')`
  - **backButtonImageSource:** Use a custom image for the back button. This does not replace the back caret (`<`) but instead replaces the text next to it.
  - **leftButtonTitle**: Text for the left nav button, which supersedes the previous nav item's back button when specified. The main use case for this is your initial screen/UIVC which has nothing to go back to (since it is the first VC on the stack) but need to display a left button. This does hide the back button if there would have been one otherwise.
  - **leftButtonImageSource:** Image source for the left button, super
Closes https://github.com/facebook/react-native/pull/263
Github Author: James Ide <ide@jameside.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-05-07 08:03:21 -08:00
Alex Kotliarskyi
cad5cdef42 Updates from Wed 6 May 2015-05-06 16:08:10 -07:00
Alex Kotliarskyi
ee449301b6 [ReactNative] Fail faster in OSS tests 2015-05-06 14:28:30 -08:00
Alex Kotliarskyi
8c95de11e1 [ReactNative] Re-record OSS snapshot tests 2015-05-06 09:54:17 -08:00
Alex Kotliarskyi
735f67337a [ReactNative] Fail faster in OSS tests 2015-05-06 09:33:20 -07:00
Alex Kotliarskyi
286e1b0ae9 [ReactNative] Re-record OSS snapshot tests 2015-05-06 09:31:39 -07:00
Nick Lockwood
88a83084e4 Fixed UIExplorer in Catalyst shell 2015-05-06 00:08:08 -08:00
Alex Kotliarskyi
5df5602f1a Updates from Tue 5 May 2015-05-05 14:15:51 -07:00
Alex Akers
1a17cceb17 [React Native] Save UIExplorer search state 2015-05-05 05:46:53 -08:00
Alex Akers
5eca2e1d3c [React Native] Added RCTSettings 2015-05-05 05:46:52 -08:00
Nick Lockwood
ba501a1bf5 Upgraded dev menu 2015-05-01 06:36:49 -08:00
Nick Lockwood
eb0476074f Improved debug and fixed macros 2015-04-30 09:59:16 -08:00
Ben Alpert
648cdfeb18 [react-native] Fix example pages requiring React directly 2015-04-29 23:45:20 -08:00
Ben Alpert
d8ab648fce Updates from Wed 29 Apr 2015-04-29 18:55:07 -07:00
Ben Alpert
eff7c8018c [react-native] Update UIExplorer snapshot tests 2015-04-29 17:53:52 -08:00
Nick Lockwood
81e82d10ab Added missing features from Multiline Text commit 2015-04-29 15:27:15 -08:00
Clay Allsopp
11f204748d Add SegmentedControlIOS
Summary:
Fixes #534:

![screen shot 2015-03-31 at 7 52 10 pm](https://cloud.githubusercontent.com/assets/153704/6934038/742ddd34-d7e3-11e4-8f55-3eb7d9d3f1cd.png)

```jsx
<SegmentedControlIOS
  tintColor="#ff0000"
  values={['One', 'Two', 'Three', 'Four']}
  selectedtIndex={0}
  momentary={false}
  enabled={true}
  onValueChange={ (value) => console.log(value) } />
```

This only supports string-based segments, not images. Also doesn't support full customization (no separator images etc); I figure this is a good MVP to lock-down a basic API

I also included a snapshot test case, but the images keep coming out funky. When I look at the sim, I see that the text labels show up for the selected segment, but the snapshot keeps coming out with no text on those segments. I tried forcing a delay, but same result. Is that explainable?

Obviously happy to change anything about the API, code-style nitpicks, etc
Closes https://github.com/facebook/react-native/pull/564
Github Author: Clay Allsopp <clay.allsopp@gmail.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-04-29 08:08:45 -08:00
Brent Vatne
c09bdebcd5 Add support for multiline TextInput via UITextView
Summary:
@nicklockwood - Could I get a review of this?

Just took `RCTTextField` and ported it from `UITextField` to `UITextView` as you mentioned in another discussion, and removed any `UITextField` specific attributes.

- How do you think this should behave when there are subviews?
- Do you know how we can respond to the `UIControlEventEditingDidEndOnExit` event to respond to submit? Because `UITextView` isn't a `UIControl` we can't just use `addTarget` with `UIControlEventEditingDidEndOnExit`.
- Any other feedback?

Still going to look over the `UITextView` docs in more detail and make sure we expose all important options, and add it to the UIExplorer example, just putting this out here for feedback.

![multiline](https://cloud.githubusercontent.com/assets/90494/7310854/32174d6a-e9e8-11e4-919e-71e54cf3c739.gif)

Closes https://github.com/facebook/react-native/pull/991
Github Author: Brent Vatne <brent.vatne@madriska.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-04-29 01:33:58 -08:00
Gabe Levi
b6e6dae6ba [Flow] Properly fix new errors as of Flow v0.10. 2015-04-27 14:56:21 -08:00
Alex Akers
826b56a41b [React Native] Update RCTView border implementation 2015-04-27 04:10:43 -08:00
Gabe Levi
70c9f5140d Clean the errors that Flow v0.10.0 finds 2015-04-26 18:31:53 -04:00
Nick Lockwood
77e38b26c5 Improved RCTActivityIndicatorView and fixed some flow errors 2015-04-26 02:17:13 -08:00
Spencer Ahrens
68eb3e4906 [ReactNative] geolocation method docs 2015-04-24 16:26:28 -08:00
Krzysztof Magiera
46db1826c5 [react_native] JS files from D2017699: Expose JavaScriptEnabled property for WebView component on android. 2015-04-24 11:53:35 -08:00
Spencer Ahrens
21b4b5b352 Updates from Fri 24 Apr 2015-04-24 11:46:18 -07:00
Alex Kotliarskyi
1f1c6af9cd [ReactNative] Add instructions for new react-native bundle 2015-04-23 15:34:07 -08:00
Eduardo
aa3d343547 NavigatorIOS custom nav bar colors
Summary:
NavigatorIOS with custom nav bar custom colors, working example included in
UIExplorer.

Based on pull request #318 to complete pending work based on comments.
Closes https://github.com/facebook/react-native/pull/695
Github Author: Eduardo <edo.lomeli@gmail.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-04-23 06:32:35 -08:00
Alex Kotliarskyi
7172c2b52b Re-record snapshot test 2015-04-22 16:26:13 -07:00
Mike Wilcox
17e5b04d1a Fix Typo
Summary:
* This PR fixes a typo for the NetInfo docs page
Closes https://github.com/facebook/react-native/pull/937
Github Author: Mike Wilcox <mwilcox56@gmail.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-04-21 16:41:34 -08:00
Arthur Lee
c13646fce1 Added bundle command using ReactPackager
Added bundle script
Pipe http response straight to file
Used ReactPackager directly, minor fixes
Added error handling to fs.writeFile
Changed .then to .done
2015-04-20 20:01:03 -04:00
Nick Lockwood
bbd5259586 Fixed reachability 2015-04-20 08:33:56 -08:00
Nick Lockwood
ead0f2e020 Implemented thread control for exported methods 2015-04-18 11:13:39 -08:00
Christopher Chedeau
014065b277 Updates from Fri 17 Apr 2015-04-17 08:42:57 -07:00
Spencer Ahrens
915151c5d7 [ReactNative] verifyPropTypes against native exports 2015-04-16 18:15:36 -08:00
Alex Kotliarskyi
df77c5ef1c Add test target to SampleApp 2015-04-15 09:26:57 -08:00
Christopher Chedeau
970dd8acca Merge branch 'oss-sync/master' into import_everycommit 2015-04-15 08:50:27 -07:00
guru inamdar
7a68691686 MapView to support MKPointAnnotation using new attribute annotate in Map...
Summary:
### MapView to support Pin annotation

    var pinLocation = {
			latitude: property.latitude,
			longitude: property.longitude,
			title: property.title
    };
    this.state = {propertyPoint: pinLocation};
    <MapView style={styles.map} region={this.state.region} annotate={this.state.propertyPoint}>
    </MapView>
![mapview-pinannotation](https://cloud.githubusercontent.com/assets/845379/7100280/6c1ffc08-dfe5-11e4-9d1b-8da6a65da1bc.png)

Closes https://github.com/facebook/react-native/pull/810
Github Author: guru inamdar <guru.inamdar@gmail.com>

Test Plan: Imported from GitHub, without a `Test Plan:` line.
2015-04-14 18:03:37 -08:00
Christopher Chedeau
99bbd4a38c Merge branch 'oss-sync/master' into HEAD 2015-04-14 18:16:23 -07:00
Alex Kotliarskyi
9b513ede77 Add flowconfig to SampleApp 2015-04-14 11:36:13 -07:00
Tadeu Zagallo
8d651a0353 [ReactNative] Sort UIExplorer examples 2015-04-13 04:34:23 -08:00