Skip to content

Commit

Permalink
Bugfix - Typos
Browse files Browse the repository at this point in the history
Summary:
Fixed few typos in `./Examples` and `./Libraries` folders.
Closes facebook#4788

Reviewed By: svcscm

Differential Revision: D2759918

Pulled By: androidtrunkagent

fb-gh-sync-id: d692b5c7f561822353e522f9d4dfde7e60b491cf
  • Loading branch information
jutaz authored and facebook-github-bot-4 committed Dec 15, 2015
1 parent 7871abf commit 0e8b207
Show file tree
Hide file tree
Showing 39 changed files with 57 additions and 58 deletions.
2 changes: 1 addition & 1 deletion Examples/2048/GameBoard.js
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@
'use strict';

// NB: Taken straight from: https://github.com/IvanVergiliev/2048-react/blob/master/src/board.js
// with no modificiation except to format it for CommonJS and fix lint/flow errors
// with no modification except to format it for CommonJS and fix lint/flow errors

var rotateLeft = function (matrix) {
var rows = matrix.length;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ @implementation LayoutSubviewsOrderingTest
/**
* This test exists to insure that didLayoutSubviews is always called immediately after layoutSubviews for a VC:View
* pair. In Catalyst we have multiple levels of ViewController containment, and we rely on this ordering
* to insure that layoutGuides are set on RKViewControllers before Views further down in the heirarchy have
* to insure that layoutGuides are set on RKViewControllers before Views further down in the hierarchy have
* their layoutSubviews called (and need to use the aforementioned layoutGuides)
*/
- (void)testLayoutSubviewsOrdering
Expand Down Expand Up @@ -63,7 +63,7 @@ - (void)testLayoutSubviewsOrdering
}
}] viewDidLayoutSubviews];

// setup View heirarchy and force layout
// setup View hierarchy and force layout
parentVC.view = parentView;
childVC.view = childView;
[parentVC addChildViewController:childVC];
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ - (void)testJavaScriptCallSpeed
{
/**
* Since we almost don't change the RCTContextExecutor logic, and this test is
* very likely to become flaky (specially accross different devices) leave it
* very likely to become flaky (specially across different devices) leave it
* to be run manually
*
* Previous Values: If you change the executor code, you should update this values
Expand Down
2 changes: 1 addition & 1 deletion Examples/UIExplorer/WebViewExample.js
Original file line number Diff line number Diff line change
Expand Up @@ -148,7 +148,7 @@ var WebViewExample = React.createClass({
url: url,
});
}
// dismiss keyoard
// dismiss keyboard
this.refs[TEXT_INPUT_REF].blur();
},

Expand Down
2 changes: 1 addition & 1 deletion Examples/UIExplorer/XHRExample.android.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ var XHRExampleHeaders = require('./XHRExampleHeaders');
var XHRExampleCookies = require('./XHRExampleCookies');


// TODO t7093728 This is a simlified XHRExample.ios.js.
// TODO t7093728 This is a simplified XHRExample.ios.js.
// Once we have Camera roll, Toast, Intent (for opening URLs)
// we should make this consistent with iOS.

Expand Down
2 changes: 1 addition & 1 deletion Libraries/Animated/examples/demo.html
Original file line number Diff line number Diff line change
Expand Up @@ -326,7 +326,7 @@ <h2>stopAnimation</h2>

<p><code>Animated</code> can offload the animation to a different thread (CoreAnimation, CSS transitions, main thread...) and we don't have a good way to know the real value. If you try to query the value then modify it, you are going to be out of sync and the result will look terrible.</p>

<p>There's however one exception: when you want to stop the current animation. You need to know where it stopped in order to continue from there. We cannot know the value synchronously so we give it via a callback in <code>stopAnimation</code>. It will not suffer from beign out of sync since the animation is no longer running.</p>
<p>There's however one exception: when you want to stop the current animation. You need to know where it stopped in order to continue from there. We cannot know the value synchronously so we give it via a callback in <code>stopAnimation</code>. It will not suffer from being out of sync since the animation is no longer running.</p>

<script type="text/jsx;harmony=true;stripTypes=true">
examplify(React.createClass({
Expand Down
8 changes: 4 additions & 4 deletions Libraries/Animated/src/AnimatedImplementation.js
Original file line number Diff line number Diff line change
Expand Up @@ -578,7 +578,7 @@ class AnimatedValue extends AnimatedWithChildren {
/**
* Adds an asynchronous listener to the value so you can observe updates from
* animations or whathaveyou. This is useful because there is no way to
* syncronously read the value because it might be driven natively.
* synchronously read the value because it might be driven natively.
*/
addListener(callback: ValueListenerCallback): string {
var id = String(_uniqueId++);
Expand Down Expand Up @@ -1485,7 +1485,7 @@ var event = function(
* The simplest workflow is to create an `Animated.Value`, hook it up to one or
* more style attributes of an animated component, and then drive updates either
* via animations, such as `Animated.timing`, or by hooking into gestures like
* panning or scolling via `Animated.event`. `Animated.Value` can also bind to
* panning or scrolling via `Animated.event`. `Animated.Value` can also bind to
* props other than style, and can be interpolated as well. Here is a basic
* example of a container view that will fade in when it's mounted:
*
Expand Down Expand Up @@ -1517,7 +1517,7 @@ var event = function(
* Note that only animatable components can be animated. `View`, `Text`, and
* `Image` are already provided, and you can create custom ones with
* `createAnimatedComponent`. These special components do the magic of binding
* the animated values to the properties, and do targetted native updates to
* the animated values to the properties, and do targeted native updates to
* avoid the cost of the react render and reconciliation process on every frame.
* They also handle cleanup on unmount so they are safe by default.
*
Expand Down Expand Up @@ -1559,7 +1559,7 @@ var event = function(
* Animation App, and [Animations documentation guide](http://facebook.github.io/react-native/docs/animations.html).
*
* Note that `Animated` is designed to be fully serializable so that animations
* can be run in a high performace way, independent of the normal JavaScript
* can be run in a high performance way, independent of the normal JavaScript
* event loop. This does influence the API, so keep that in mind when it seems a
* little trickier to do something compared to a fully synchronous system.
* Checkout `Animated.Value.addListener` as a way to work around some of these
Expand Down
2 changes: 1 addition & 1 deletion Libraries/CameraRoll/CameraRoll.js
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ class CameraRoll {
*
* - local URI
* - assets-library tag
* - a tag not maching any of the above, which means the image data will
* - a tag not matching any of the above, which means the image data will
* be stored in memory (and consume memory as long as the process is alive)
*
* @param successCallback Invoked with the value of `tag` on success.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ var DrawerLayoutAndroid = React.createClass({
/**
* Function called when the drawer state has changed. The drawer can be in 3 states:
* - idle, meaning there is no interaction with the navigation view happening at the time
* - dragging, meaning there is currently an interation with the navigation view
* - dragging, meaning there is currently an interaction with the navigation view
* - settling, meaning that there was an interaction with the navigation view, and the
* navigation view is now finishing it's closing or opening animation
*/
Expand Down
6 changes: 3 additions & 3 deletions Libraries/Components/MapView/MapView.js
Original file line number Diff line number Diff line change
Expand Up @@ -150,7 +150,7 @@ var MapView = React.createClass({
*
* - standard: standard road map (default)
* - satellite: satellite view
* - hybrid: satellite view with roads and points of interest overlayed
* - hybrid: satellite view with roads and points of interest overlaid
*/
mapType: React.PropTypes.oneOf([
'standard',
Expand All @@ -172,7 +172,7 @@ var MapView = React.createClass({
longitude: React.PropTypes.number.isRequired,

/**
* Distance between the minimun and the maximum latitude/longitude
* Distance between the minimum and the maximum latitude/longitude
* to be displayed.
*/
latitudeDelta: React.PropTypes.number.isRequired,
Expand Down Expand Up @@ -218,7 +218,7 @@ var MapView = React.createClass({
* and custom pin images.
*
* Note that on iOS 8 and earlier, only the standard PinColor constants
* are supported for regualr pins. For custom pin images, any tintColor
* are supported for regular pins. For custom pin images, any tintColor
* value is supported on all iOS versions.
* @platform ios
*/
Expand Down
2 changes: 1 addition & 1 deletion Libraries/Components/Navigation/NavigatorIOS.ios.js
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ type Event = Object;
* },
* ```
*
* Now MyView will be rendered by the navigator. It will recieve the route
* Now MyView will be rendered by the navigator. It will receive the route
* object in the `route` prop, a navigator, and all of the props specified in
* `passProps`.
*
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -20,9 +20,9 @@ var INNERVIEW = 'InnerView';
* Wrapper around android native recycler view.
*
* It simply renders rows passed as children in a separate recycler view cells
* similarily to how `ScrollView` is doing it. Thanks to the fact that it uses
* similarly to how `ScrollView` is doing it. Thanks to the fact that it uses
* native `RecyclerView` though, rows that are out of sight are going to be
* automatically detached (similarily on how this would work with
* automatically detached (similarly on how this would work with
* `removeClippedSubviews = true` on a `ScrollView.js`).
*
* CAUTION: This is an experimental component and should only be used together
Expand Down
4 changes: 2 additions & 2 deletions Libraries/Components/ScrollView/ScrollView.js
Original file line number Diff line number Diff line change
Expand Up @@ -184,7 +184,7 @@ var ScrollView = React.createClass({
minimumZoomScale: PropTypes.number,
/**
* Fires at most once per frame during scrolling. The frequency of the
* events can be contolled using the `scrollEventThrottle` prop.
* events can be controlled using the `scrollEventThrottle` prop.
*/
onScroll: PropTypes.func,
/**
Expand Down Expand Up @@ -438,7 +438,7 @@ var ScrollView = React.createClass({

var onRefreshStart = this.props.onRefreshStart;
// this is necessary because if we set it on props, even when empty,
// it'll trigger the default pull-to-refresh behaviour on native.
// it'll trigger the default pull-to-refresh behavior on native.
props.onRefreshStart = onRefreshStart
? function() { onRefreshStart && onRefreshStart(this.endRefreshing); }.bind(this)
: null;
Expand Down
2 changes: 1 addition & 1 deletion Libraries/Components/SliderIOS/SliderIOS.ios.js
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ var SliderIOS = React.createClass({
* Default value is 0.
*
* *This is not a controlled component*, e.g. if you don't update
* the value, the component won't be reset to its inital value.
* the value, the component won't be reset to its initial value.
*/
value: PropTypes.number,

Expand Down
2 changes: 1 addition & 1 deletion Libraries/Components/Switch/Switch.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ var Switch = React.createClass({
*/
disabled: React.PropTypes.bool,
/**
* Invoked with the new value when the value chages.
* Invoked with the new value when the value changes.
*/
onValueChange: React.PropTypes.func,
/**
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,7 +36,7 @@ var SwitchAndroid = React.createClass({
*/
disabled: PropTypes.bool,
/**
* Invoked with the new value when the value chages.
* Invoked with the new value when the value changes.
*/
onValueChange: PropTypes.func,
/**
Expand Down
4 changes: 2 additions & 2 deletions Libraries/Components/TabBarIOS/TabBarItemIOS.ios.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ var TabBarItemIOS = React.createClass({
]),
/**
* Items comes with a few predefined system icons. Note that if you are
* using them, the title and selectedIcon will be overriden with the
* using them, the title and selectedIcon will be overridden with the
* system ones.
*/
systemIcon: React.PropTypes.oneOf([
Expand Down Expand Up @@ -109,7 +109,7 @@ var TabBarItemIOS = React.createClass({
} else {
var tabContents = <View />;
}

return (
<RCTTabBarItem
{...props}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ var ToolbarAndroid = React.createClass({
*/
navIcon: optionalImageSource,
/**
* Callback that is called when an action is selected. The only argument that is passeed to the
* Callback that is called when an action is selected. The only argument that is passed to the
* callback is the position of the action in the actions array.
*/
onActionSelected: ReactPropTypes.func,
Expand Down
3 changes: 1 addition & 2 deletions Libraries/Components/Touchable/Position.js
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@ var twoArgumentPooler = PooledClass.twoArgumentPooler;
/**
* Position does not expose methods for construction via an `HTMLDOMElement`,
* because it isn't meaningful to construct such a thing without first defining
* a frame of refrence.
* a frame of reference.
*
* @param {number} windowStartKey Key that window starts at.
* @param {number} windowEndKey Key that window ends at.
Expand All @@ -29,4 +29,3 @@ Position.prototype.destructor = function() {
PooledClass.addPoolingTo(Position, twoArgumentPooler);

module.exports = Position;

4 changes: 2 additions & 2 deletions Libraries/Components/Touchable/Touchable.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ var queryLayoutByID = require('queryLayoutByID');
*
* A good tap interaction isn't as simple as you might think. There should be a
* slight delay before showing a highlight when starting a touch. If a
* subsequent touch move exceeds the boundary of the elemement, it should
* subsequent touch move exceeds the boundary of the element, it should
* unhighlight, but if that same touch is brought back within the boundary, it
* should rehighlight again. A touch can move in and out of that boundary
* several times, each time toggling highlighting, but a "press" is only
Expand Down Expand Up @@ -574,7 +574,7 @@ var TouchableMixin = {
curState !== States.RESPONDER_ACTIVE_LONG_PRESS_IN) {
console.error('Attempted to transition from state `' + curState + '` to `' +
States.RESPONDER_ACTIVE_LONG_PRESS_IN + '`, which is not supported. This is ' +
'most likely due to `Touchable.longPressDelayTimeout` not being cancelled.');
'most likely due to `Touchable.longPressDelayTimeout` not being cancelled.');
} else {
this._receiveSignal(Signals.LONG_PRESS_DETECTED, e);
}
Expand Down
4 changes: 2 additions & 2 deletions Libraries/Components/ViewPager/ViewPagerAndroid.android.js
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ var VIEWPAGER_REF = 'viewPager';
/**
* Container that allows to flip left and right between child views. Each
* child view of the `ViewPagerAndroid` will be treated as a separate page
* and will be streched to fill the `ViewPagerAndroid`.
* and will be stretched to fill the `ViewPagerAndroid`.
*
* It is important all children are `<View>`s and not composite components.
* You can set style properties like `padding` or `backgroundColor` for each
Expand Down Expand Up @@ -79,7 +79,7 @@ var ViewPagerAndroid = React.createClass({
onPageScroll: ReactPropTypes.func,

/**
* This callback will be caleld once ViewPager finish navigating to selected page
* This callback will be called once ViewPager finish navigating to selected page
* (when user swipes between pages). The `event.nativeEvent` object passed to this
* callback will have following fields:
* - position - index of page that has been selected
Expand Down
2 changes: 1 addition & 1 deletion Libraries/CustomComponents/ListView/ListView.js
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,7 @@ var ListView = React.createClass({
renderRow: PropTypes.func.isRequired,
/**
* How many rows to render on initial component mount. Use this to make
* it so that the first screen worth of data apears at one time instead of
* it so that the first screen worth of data appears at one time instead of
* over the course of multiple frames.
*/
initialListSize: PropTypes.number,
Expand Down
2 changes: 1 addition & 1 deletion Libraries/CustomComponents/ListView/ListViewDataSource.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,7 +141,7 @@ class ListViewDataSource {

/**
* Clones this `ListViewDataSource` with the specified `dataBlob` and
* `rowIdentities`. The `dataBlob` is just an aribitrary blob of data. At
* `rowIdentities`. The `dataBlob` is just an arbitrary blob of data. At
* construction an extractor to get the interesting information was defined
* (or the default was used).
*
Expand Down
2 changes: 1 addition & 1 deletion Libraries/CustomComponents/Navigator/Navigator.js
Original file line number Diff line number Diff line change
Expand Up @@ -50,7 +50,7 @@ var rebound = require('rebound');
var PropTypes = React.PropTypes;

// TODO: this is not ideal because there is no guarantee that the navigator
// is full screen, hwoever we don't have a good way to measure the actual
// is full screen, however we don't have a good way to measure the actual
// size of the navigator right now, so this is the next best thing.
var SCREEN_WIDTH = Dimensions.get('window').width;
var SCREEN_HEIGHT = Dimensions.get('window').height;
Expand Down
2 changes: 1 addition & 1 deletion Libraries/Image/ImageResizeMode.js
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,7 @@ var ImageResizeMode = keyMirror({
/**
* stretch - The image will be stretched to fill the entire frame of the
* view without clipping. This may change the aspect ratio of the image,
* distoring it.
* distorting it.
*/
stretch: null,
});
Expand Down
6 changes: 3 additions & 3 deletions Libraries/JavaScriptAppEngine/Initialization/SourceMap.js
Original file line number Diff line number Diff line change
Expand Up @@ -327,7 +327,7 @@ define('source-map/source-map-generator', ['require', 'exports', 'module' , 'so
* Applies the mappings of a sub-source-map for a specific source file to the
* source map being generated. Each mapping to the supplied source file is
* rewritten using the supplied source map. Note: The resolution for the
* resulting mappings is the minimium of this map and the supplied map.
* resulting mappings is the minimum of this map and the supplied map.
*
* @param aSourceMapConsumer The source map to be applied.
* @param aSourceFile Optional. The filename of the source file.
Expand Down Expand Up @@ -1058,7 +1058,7 @@ define('source-map/source-map-consumer', ['require', 'exports', 'module' , 'sou
*
* - version: Which version of the source map spec this map is following.
* - sources: An array of URLs to the original source files.
* - names: An array of identifiers which can be referrenced by individual mappings.
* - names: An array of identifiers which can be referenced by individual mappings.
* - sourceRoot: Optional. The URL root from which all sources are relative.
* - sourcesContent: Optional. An array of contents of the original source files.
* - mappings: A string of base64 VLQs which contain the actual mappings.
Expand Down Expand Up @@ -1369,7 +1369,7 @@ define('source-map/source-map-consumer', ['require', 'exports', 'module' , 'sou
/**
* Returns the original source content. The only argument is the url of the
* original source file. Returns null if no original source content is
* availible.
* available.
*/
SourceMapConsumer.prototype.sourceContentFor =
function SourceMapConsumer_sourceContentFor(aSource) {
Expand Down
2 changes: 1 addition & 1 deletion Libraries/PushNotificationIOS/PushNotificationIOS.js
Original file line number Diff line number Diff line change
Expand Up @@ -235,7 +235,7 @@ class PushNotificationIOS {
}

/**
* You will never need to instansiate `PushNotificationIOS` yourself.
* You will never need to instantiate `PushNotificationIOS` yourself.
* Listening to the `notification` event and invoking
* `popInitialNotification` is sufficient
*/
Expand Down
4 changes: 2 additions & 2 deletions Libraries/RCTTest/FBSnapshotTestCase/FBSnapshotTestCase.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,7 +71,7 @@ FBSnapshotVerifyLayerWithReferenceDirectorySuffix(layer__, identifier__, @""); \
@property (readwrite, nonatomic, assign) BOOL recordMode;

/**
Performs the comparisong or records a snapshot of the layer if recordMode is YES.
Performs the comparisons or records a snapshot of the layer if recordMode is YES.
@param layer The Layer to snapshot
@param referenceImagesDirectory The directory in which reference images are stored.
@param identifier An optional identifier, used if there are multiple snapshot tests in a given -test method.
Expand All @@ -84,7 +84,7 @@ FBSnapshotVerifyLayerWithReferenceDirectorySuffix(layer__, identifier__, @""); \
error:(NSError **)errorPtr;

/**
Performs the comparisong or records a snapshot of the view if recordMode is YES.
Performs the comparisons or records a snapshot of the view if recordMode is YES.
@param view The view to snapshot
@param referenceImagesDirectory The directory in which reference images are stored.
@param identifier An optional identifier, used if there are multiple snapshot tests in a given -test method.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -97,7 +97,7 @@ extern NSString *const FBReferenceImageFilePathKey;


/**
The directory in which referfence images are stored.
The directory in which reference images are stored.
*/
@property (readwrite, nonatomic, copy) NSString *referenceImagesDirectory;

Expand Down
Loading

0 comments on commit 0e8b207

Please sign in to comment.