Skip to content
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

Publish DocDown Commits Into Next Release (0.29) #8480

Merged
merged 58 commits into from
Jun 29, 2016
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
58 commits
Select commit Hold shift + click to select a range
d610f96
Separate Out Core Components Into Individual Parts
JoelMarcey Jun 20, 2016
b04b443
Cleanup troubleshooting and debugging docs.
hramos Jun 20, 2016
e1a732a
Remove survey link
JoelMarcey Jun 21, 2016
d1f8937
Add docs to show how to select specific simulator.
joelcloralt Jun 21, 2016
7ae2d96
Add ScrollView to Basics docs
JoelMarcey Jun 21, 2016
acade44
Improve autogen for reference docs including jsdoc support
Jun 21, 2016
15aa570
overhaul showcase
lacker Jun 21, 2016
05ecef6
New React Native Landing Page
lacker Jun 22, 2016
adf24a1
Move Videos and Newsletter to Support
JoelMarcey Jun 22, 2016
a282b53
Include info about console.log
Emilios1995 Jun 22, 2016
37e56a3
Add a new Handling Touches guide
hramos Jun 22, 2016
445eebe
Remove Polyfills section from sidebar
JoelMarcey Jun 22, 2016
2b5f933
Docs: Basic Components Update
ericnakagawa Jun 22, 2016
9d531b7
Add react-native-web-player to core components docs
dabbott Jun 22, 2016
94f5a67
More Resources doc, updating Support doc and quickstart too
lacker Jun 22, 2016
ae2d77e
Add React Native Web Player to most component basics
JoelMarcey Jun 22, 2016
6b36d95
Update Navigator component doc
Jun 22, 2016
048bce9
fix Firefox bug
lacker Jun 23, 2016
a71d68c
Fix guides docs to es2015 classes and remove flowtype from Animation …
artyomtrityak Jun 23, 2016
4f02c39
Update Views API documentation
JoelMarcey Jun 23, 2016
d4482c9
Fixes #8252: Document how to connect to a non-default packager port o…
burgalon Jun 23, 2016
ad218dd
Add docs pages for basics: Dimensions and Layout
dabbott Jun 23, 2016
94974b5
ES6-ify ListView Basics
JoelMarcey Jun 23, 2016
6bc7579
Fix nits in update View API documentation
JoelMarcey Jun 23, 2016
fb48c72
ES6-ify ScrollView basics
JoelMarcey Jun 23, 2016
ac21933
ES6-ify View Basics
JoelMarcey Jun 23, 2016
279ca4f
ES6-ify Image Basics
JoelMarcey Jun 23, 2016
5e000a1
ES6-ify TextInput Basics
JoelMarcey Jun 23, 2016
2bf9e01
ES6-ify Text Basics
JoelMarcey Jun 23, 2016
9bf99cf
Update NavigatorIOS component doc
Jun 23, 2016
604e593
Update webview doc
Jun 23, 2016
fed184b
Move everything out of Known Issues and into more appropriate locations.
hramos Jun 23, 2016
5a49386
Make a new "Style" doc that's in The Basics and uses the RNWP
lacker Jun 23, 2016
22b8469
Add `extends Component` to Dimensions and Layout Basics Examples
JoelMarcey Jun 23, 2016
4ddb193
Bring out prop descriptions, for Flexbox
Jun 23, 2016
b416432
Update web player in docs for custom registerComponent names
dabbott Jun 24, 2016
46882b0
Networking Guide
hramos Jun 24, 2016
6c7498a
Move Component Embedded Simulator next to its example
JoelMarcey Jun 24, 2016
87d2fee
fix bugs on landing page code, make the url an easter egg
lacker Jun 24, 2016
4a87e19
Api documentation update for modal.js
ericnakagawa Jun 24, 2016
2bfb854
Update MapView doc
Jun 24, 2016
d469eec
Accessing console logs
hramos Jun 24, 2016
1ccc60d
Add Navigation Overview
hramos Jun 24, 2016
3e930de
Update AsyncStorage doc
Jun 24, 2016
874152f
Fix errors related to typehint when generating docs
Jun 24, 2016
a6d241e
Update Image API
JoelMarcey Jun 24, 2016
12e8754
Replace NavigatorComparison with the new Navigation guide.
hramos Jun 24, 2016
4f6c439
Overhaul the Flexbox documentation
lacker Jun 24, 2016
20233cb
Update TextInput API
JoelMarcey Jun 24, 2016
9264e7b
Make "The Basics" flow like a linear tutorial
lacker Jun 26, 2016
5681c8a
map -> object
sunnylqm Jun 27, 2016
7a3647e
Make the method signatures stand out more
JoelMarcey Jun 27, 2016
230dbe3
Use npmcdn in docs instead of rawgit for web player
dabbott Jun 27, 2016
bcf5b13
Update instructions for pointing Gradle to Android SDK
christopherdro Jun 27, 2016
ce945e6
Update RunningOnDeviceAndroid.md
drcallaway Jun 28, 2016
4b2d66a
improve text input docs
lacker Jun 28, 2016
52aab67
Update Text Component
JoelMarcey Jun 28, 2016
f511672
Fix TextInput API update nits
JoelMarcey Jun 28, 2016
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
89 changes: 59 additions & 30 deletions Libraries/Components/MapView/MapView.js
Original file line number Diff line number Diff line change
Expand Up @@ -27,21 +27,58 @@ const requireNativeComponent = require('requireNativeComponent');

type Event = Object;

/**
* State an annotation on the map.
*/
export type AnnotationDragState = $Enum<{
/**
* Annotation is not being touched.
*/
idle: string;
/**
* Annotation dragging has began.
*/
starting: string;
/**
* Annotation is being dragged.
*/
dragging: string;
/**
* Annotation dragging is being canceled.
*/
canceling: string;
/**
* Annotation dragging has ended.
*/
ending: string;
}>;

/**
* A component for displaying embeddable maps and annotations using the native
* iOS MKMapView class. The Android version is not currently available in the
* open source React Native project, but you can use Leland Richardson's
* cross-platform and more feature-complete
* **This component is only supported on iOS.**
*
* `MapView` is used to display embeddable maps and annotations using
* `MKMapView`.
*
* For a cross-platform solution, check out
* [react-native-maps](https://github.com/lelandrichardson/react-native-maps)
* instead.
* by Leland Richardson.
*
* ```
* import React, { Component } from 'react';
* import { MapView } from 'react-native';
*
* class MapMyRide extends Component {
* render() {
* return (
* <MapView
* style={{height: 200, margin: 40}}
* showsUserLocation={true}
* />
* );
* }
* }
* ```
*
*/

const MapView = React.createClass({
Expand All @@ -51,16 +88,15 @@ const MapView = React.createClass({
propTypes: {
...View.propTypes,
/**
* Used to style and layout the `MapView`. See `StyleSheet.js` and
* `ViewStylePropTypes.js` for more info.
* Used to style and layout the `MapView`.
*/
style: View.propTypes.style,

/**
* If `true` the app will ask for the user's location and display it on
* the map. Default value is `false`.
*
* **NOTE**: on iOS, you need to add the `NSLocationWhenInUseUsageDescription`
* **NOTE**: You'll need to add the `NSLocationWhenInUseUsageDescription`
* key in Info.plist to enable geolocation, otherwise it will fail silently.
*/
showsUserLocation: React.PropTypes.bool,
Expand All @@ -69,21 +105,18 @@ const MapView = React.createClass({
* If `true` the map will follow the user's location whenever it changes.
* Note that this has no effect unless `showsUserLocation` is enabled.
* Default value is `true`.
* @platform ios
*/
followUserLocation: React.PropTypes.bool,

/**
* If `false` points of interest won't be displayed on the map.
* Default value is `true`.
* @platform ios
*/
showsPointsOfInterest: React.PropTypes.bool,

/**
* If `false` compass won't be displayed on the map.
* If `false`, compass won't be displayed on the map.
* Default value is `true`.
* @platform ios
*/
showsCompass: React.PropTypes.bool,

Expand All @@ -96,7 +129,9 @@ const MapView = React.createClass({
/**
* When this property is set to `true` and a valid camera is associated with
* the map, the camera’s heading angle is used to rotate the plane of the
* map around its center point. When this property is set to `false`, the
* map around its center point.
*
* When this property is set to `false`, the
* camera’s heading angle is ignored and the map is always oriented so
* that true north is situated at the top of the map view
*/
Expand All @@ -105,7 +140,9 @@ const MapView = React.createClass({
/**
* When this property is set to `true` and a valid camera is associated
* with the map, the camera’s pitch angle is used to tilt the plane
* of the map. When this property is set to `false`, the camera’s pitch
* of the map.
*
* When this property is set to `false`, the camera’s pitch
* angle is ignored and the map is always displayed as if the user
* is looking straight down onto it.
*/
Expand All @@ -120,11 +157,9 @@ const MapView = React.createClass({
/**
* The map type to be displayed.
*
* - standard: standard road map (default)
* - satellite: satellite view
* - hybrid: satellite view with roads and points of interest overlaid
*
* @platform ios
* - `standard`: Standard road map (default).
* - `satellite`: Satellite view.
* - `hybrid`: Satellite view with roads and points of interest overlaid.
*/
mapType: React.PropTypes.oneOf([
'standard',
Expand Down Expand Up @@ -154,8 +189,7 @@ const MapView = React.createClass({
}),

/**
* Map annotations with title/subtitle.
* @platform ios
* Map annotations with title and subtitle.
*/
annotations: React.PropTypes.arrayOf(React.PropTypes.shape({
/**
Expand Down Expand Up @@ -192,7 +226,7 @@ const MapView = React.createClass({
onBlur: React.PropTypes.func,

/**
* Annotation title/subtile.
* Annotation title and subtile.
*/
title: React.PropTypes.string,
subtitle: React.PropTypes.string,
Expand Down Expand Up @@ -253,7 +287,6 @@ const MapView = React.createClass({

/**
* Map overlays
* @platform ios
*/
overlays: React.PropTypes.arrayOf(React.PropTypes.shape({
/**
Expand All @@ -278,21 +311,17 @@ const MapView = React.createClass({
})),

/**
* Maximum size of area that can be displayed.
* @platform ios
* Maximum size of the area that can be displayed.
*/
maxDelta: React.PropTypes.number,

/**
* Minimum size of area that can be displayed.
* @platform ios
* Minimum size of the area that can be displayed.
*/
minDelta: React.PropTypes.number,

/**
* Insets for the map's legal label, originally at bottom left of the map.
* See `EdgeInsetsPropType.js` for more information.
* @platform ios
*/
legalLabelInsets: EdgeInsetsPropType,

Expand All @@ -307,7 +336,7 @@ const MapView = React.createClass({
onRegionChangeComplete: React.PropTypes.func,

/**
* Deprecated. Use annotation onFocus and onBlur instead.
* Deprecated. Use annotation `onFocus` and `onBlur` instead.
*/
onAnnotationPress: React.PropTypes.func,

Expand Down
Loading