[ReactNative] Fix warnings w/h => width/height
This commit is contained in:
parent
5e110d2776
commit
59997df1c1
|
@ -355,7 +355,7 @@ var ScrollResponderMixin = {
|
|||
|
||||
/**
|
||||
* A helper function to zoom to a specific rect in the scrollview.
|
||||
* @param {object} rect Should have shape {x, y, w, h}
|
||||
* @param {object} rect Should have shape {x, y, width, height}
|
||||
*/
|
||||
scrollResponderZoomTo: function(rect: { x: number; y: number; width: number; height: number; }) {
|
||||
RCTUIManagerDeprecated.zoomToRect(this.getNodeHandle(), rect);
|
||||
|
|
|
@ -30,7 +30,7 @@ var ViewStylePropTypes = {
|
|||
overflow: ReactPropTypes.oneOf(['visible', 'hidden']),
|
||||
shadowColor: ReactPropTypes.string,
|
||||
shadowOffset: ReactPropTypes.shape(
|
||||
{h: ReactPropTypes.number, w: ReactPropTypes.number}
|
||||
{width: ReactPropTypes.number, height: ReactPropTypes.number}
|
||||
),
|
||||
shadowOpacity: ReactPropTypes.number,
|
||||
shadowRadius: ReactPropTypes.number,
|
||||
|
|
|
@ -5,14 +5,14 @@
|
|||
*/
|
||||
'use strict';
|
||||
|
||||
var dummySize = {w: undefined, h: undefined};
|
||||
var dummySize = {width: undefined, height: undefined};
|
||||
|
||||
var sizesDiffer = function(one, two) {
|
||||
one = one || dummySize;
|
||||
two = two || dummySize;
|
||||
return one !== two && (
|
||||
one.w !== two.w ||
|
||||
one.h !== two.h
|
||||
one.width !== two.width ||
|
||||
one.height !== two.height
|
||||
);
|
||||
};
|
||||
|
||||
|
|
Loading…
Reference in New Issue