mirror of
https://github.com/zhigang1992/react-native-web.git
synced 2026-04-04 22:57:38 +08:00
Compare commits
36 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
182149aac7 | ||
|
|
d6df440987 | ||
|
|
df16c24d68 | ||
|
|
8a2c259235 | ||
|
|
a7f265de11 | ||
|
|
581529540a | ||
|
|
8ad61d9061 | ||
|
|
3d79861970 | ||
|
|
0a84ccb299 | ||
|
|
3aa37450a0 | ||
|
|
450722153d | ||
|
|
fbba32defb | ||
|
|
d762d64b49 | ||
|
|
a5b1dda62d | ||
|
|
aad904b550 | ||
|
|
a01e895e30 | ||
|
|
52e5d41518 | ||
|
|
77a40b6237 | ||
|
|
4bbe1a40aa | ||
|
|
6942e4e417 | ||
|
|
63daff7f80 | ||
|
|
662b7c3d6e | ||
|
|
12fb588596 | ||
|
|
5cb09b1a9e | ||
|
|
c03cfdf8bd | ||
|
|
997b598de8 | ||
|
|
6fe796f9da | ||
|
|
0ad6ab948b | ||
|
|
32a23136af | ||
|
|
96f48226cb | ||
|
|
f1ef0f21af | ||
|
|
d42e8907ca | ||
|
|
90724b2cef | ||
|
|
dd0f1de3d1 | ||
|
|
fc751ed715 | ||
|
|
917b06a690 |
55
README.md
55
README.md
@@ -3,19 +3,23 @@
|
||||
[![Build Status][travis-image]][travis-url]
|
||||
[![npm version][npm-image]][npm-url]
|
||||
|
||||
"React Native for Web" brings [React Native][react-native-url]'s
|
||||
building blocks and touch handling to the Web.
|
||||
"React Native for Web" brings the platform-agnostic Components and APIs of
|
||||
[React Native][react-native-url] to the Web.
|
||||
|
||||
* [UI Explorer and documentation](https://necolas.github.io/react-native-web/storybook/).
|
||||
* [React Native for Web: Playground](https://glitch.com/edit/#!/react-native-web-playground) using create-react-app.
|
||||
Browse the [interactive
|
||||
documentation](https://necolas.github.io/react-native-web/storybook/) or [try
|
||||
it out](https://glitch.com/edit/#!/react-native-web-playground) on Glitch.
|
||||
|
||||
Browser support: Chrome, Firefox, Safari >= 7, IE 10, Edge.
|
||||
## Features
|
||||
|
||||
[npm-image]: https://badge.fury.io/js/react-native-web.svg
|
||||
[npm-url]: https://npmjs.org/package/react-native-web
|
||||
[react-native-url]: https://facebook.github.io/react-native/
|
||||
[travis-image]: https://travis-ci.org/necolas/react-native-web.svg?branch=master
|
||||
[travis-url]: https://travis-ci.org/necolas/react-native-web
|
||||
* Interoperability with ReactDOM components.
|
||||
* Native-like touch handling.
|
||||
* Built-in integration with web accessibility APIs.
|
||||
* Built-in support for LTR and RTL layouts.
|
||||
* Built-in expressive and reliable subset of CSS.
|
||||
* Optimized, vendor-prefixed CSS with [good runtime performance](benchmarks/README.md).
|
||||
* Server-side rendering of HTML and critical CSS.
|
||||
* Browser support: Chrome, Firefox, Safari >= 7, IE 10, Edge.
|
||||
|
||||
## Quick start
|
||||
|
||||
@@ -27,12 +31,28 @@ Install in your existing app using `yarn` or `npm`:
|
||||
yarn add react@15.6 react-dom@15.6 react-native-web
|
||||
```
|
||||
|
||||
Then read the [Getting Started](docs/guides/getting-started.md) guide.
|
||||
Add the `react-native-web/babel` plugin to your Babel configuration. This will
|
||||
alias `react-native` to `react-native-web` and exclude any modules not required
|
||||
by the app.
|
||||
|
||||
```json
|
||||
{
|
||||
"plugins": [
|
||||
"react-native-web/babel"
|
||||
],
|
||||
"presets": [
|
||||
"react-native"
|
||||
]
|
||||
}
|
||||
```
|
||||
|
||||
See the [Getting Started](docs/guides/getting-started.md) guide for more details.
|
||||
|
||||
## Documentation
|
||||
|
||||
The [UI Explorer](https://necolas.github.io/react-native-web/storybook/)
|
||||
interactively documents all the supported APIs and Components.
|
||||
The [interactive
|
||||
documentation](https://necolas.github.io/react-native-web/storybook/) shows all
|
||||
the supported APIs and Components.
|
||||
|
||||
Guides:
|
||||
|
||||
@@ -46,7 +66,8 @@ Guides:
|
||||
|
||||
## Starter kits
|
||||
|
||||
* [create-react-app](https://github.com/facebookincubator/create-react-app) ([on Glitch](https://glitch.com/edit/#!/react-native-web-playground))
|
||||
* [Glitch](https://glitch.com/edit/#!/react-native-web-playground)
|
||||
* [create-react-app](https://github.com/facebookincubator/create-react-app)
|
||||
* [react-native-web-starter](https://github.com/grabcode/react-native-web-starter)
|
||||
* [react-native-web-webpack](https://github.com/ndbroadbent/react-native-web-webpack)
|
||||
|
||||
@@ -99,3 +120,9 @@ AppRegistry.runApplication('MyApp', { rootTag: document.getElementById('react-ro
|
||||
## License
|
||||
|
||||
React Native for Web is [BSD licensed](LICENSE).
|
||||
|
||||
[npm-image]: https://badge.fury.io/js/react-native-web.svg
|
||||
[npm-url]: https://npmjs.org/package/react-native-web
|
||||
[react-native-url]: https://facebook.github.io/react-native/
|
||||
[travis-image]: https://travis-ci.org/necolas/react-native-web.svg?branch=master
|
||||
[travis-url]: https://travis-ci.org/necolas/react-native-web
|
||||
|
||||
@@ -127,6 +127,7 @@ import AppHeader from './src/AppHeader';
|
||||
import React from 'react';
|
||||
import ReactNative from 'react-native';
|
||||
|
||||
// use .hydrate if hydrating a SSR app
|
||||
ReactNative.render(<AppHeader />, document.getElementById('react-app-header'))
|
||||
```
|
||||
|
||||
|
||||
@@ -20,7 +20,7 @@ const NetInfoScreen = () => (
|
||||
NetInfo asynchronously determines the online/offline status of the application.
|
||||
</AppText>
|
||||
<AppText>
|
||||
Note that support for retrieving the connection type depends upon browswer support (and is
|
||||
Note that support for retrieving the connection type depends upon browser support (and is
|
||||
limited to mobile browsers). It will default to <Code>unknown</Code> when support is
|
||||
missing.
|
||||
</AppText>
|
||||
|
||||
@@ -14,7 +14,6 @@
|
||||
* @providesModule Game2048
|
||||
* @flow
|
||||
*/
|
||||
'use strict';
|
||||
|
||||
import { any, func, object } from 'prop-types';
|
||||
import GameBoard from './GameBoard';
|
||||
|
||||
@@ -14,7 +14,6 @@
|
||||
* @providesModule GameBoard
|
||||
* @flow
|
||||
*/
|
||||
'use strict';
|
||||
|
||||
// NB: Taken straight from: https://github.com/IvanVergiliev/2048-react/blob/master/src/board.js
|
||||
// with no modification except to format it for CommonJS and fix lint/flow errors
|
||||
|
||||
@@ -31,13 +31,13 @@ const DocItem = ({ description, example = {}, name, typeInfo, label }) => (
|
||||
)}
|
||||
{description && <View style={styles.description}>{createDescription(description)}</View>}
|
||||
{(example.render || example.code) && (
|
||||
<View style={styles.renderBox}>
|
||||
<AppText style={styles.exampleText}>Example</AppText>
|
||||
{example.render && <View>{example.render()}</View>}
|
||||
{example.render && example.code && <View style={styles.verticalDivider} />}
|
||||
{example.code && <Text style={styles.code}>{example.code}</Text>}
|
||||
</View>
|
||||
)}
|
||||
<View style={styles.renderBox}>
|
||||
<AppText style={styles.exampleText}>Example</AppText>
|
||||
{example.render && <View>{example.render()}</View>}
|
||||
{example.render && example.code && <View style={styles.verticalDivider} />}
|
||||
{example.code && <Text style={styles.code}>{example.code}</Text>}
|
||||
</View>
|
||||
)}
|
||||
</View>
|
||||
);
|
||||
|
||||
|
||||
4
jest-setup-framework.js
Normal file
4
jest-setup-framework.js
Normal file
@@ -0,0 +1,4 @@
|
||||
import Enzyme from 'enzyme';
|
||||
import Adapter from 'enzyme-adapter-react-16';
|
||||
|
||||
Enzyme.configure({ adapter: new Adapter() });
|
||||
56
package.json
56
package.json
@@ -1,8 +1,9 @@
|
||||
{
|
||||
"name": "react-native-web",
|
||||
"version": "0.0.124",
|
||||
"version": "0.1.0",
|
||||
"description": "React Native for Web",
|
||||
"main": "dist/index.js",
|
||||
"module": "dist/module.js",
|
||||
"files": [
|
||||
"babel",
|
||||
"dist",
|
||||
@@ -11,7 +12,7 @@
|
||||
],
|
||||
"scripts": {
|
||||
"benchmark": "cd benchmarks && yarn && webpack && open index.html",
|
||||
"build": "webpack --config webpack.config.js --sort-assets-by --progress",
|
||||
"build": "yarn compile && webpack --config webpack.config.js --sort-assets-by --progress",
|
||||
"clean-dist": "del ./dist && mkdir dist",
|
||||
"compile": "babel src -d dist --ignore *-test.js",
|
||||
"docs:build": "cd docs && yarn build",
|
||||
@@ -25,28 +26,21 @@
|
||||
"lint": "yarn lint:cmd -- babel benchmarks docs src",
|
||||
"lint:cmd": "eslint --ignore-path .gitignore --fix",
|
||||
"precommit": "lint-staged",
|
||||
"release": "yarn clean-dist && yarn lint && yarn test && yarn compile && yarn build && npm publish",
|
||||
"release": "yarn clean-dist && yarn lint && yarn test && yarn build && npm publish",
|
||||
"test": "flow && jest"
|
||||
},
|
||||
"babel": {
|
||||
"presets": [
|
||||
"react-native"
|
||||
],
|
||||
"presets": [ "react-native" ],
|
||||
"plugins": [
|
||||
[
|
||||
"transform-react-remove-prop-types",
|
||||
{
|
||||
"mode": "wrap"
|
||||
}
|
||||
]
|
||||
[ "transform-react-remove-prop-types", { "mode": "wrap" } ]
|
||||
]
|
||||
},
|
||||
"jest": {
|
||||
"testEnvironment": "jsdom",
|
||||
"timers": "fake",
|
||||
"snapshotSerializers": [
|
||||
"<rootDir>/node_modules/enzyme-to-json/serializer"
|
||||
]
|
||||
"setupFiles": [ "raf/polyfill" ],
|
||||
"setupTestFrameworkScriptFile": "<rootDir>/jest-setup-framework.js",
|
||||
"snapshotSerializers": [ "enzyme-to-json/serializer" ]
|
||||
},
|
||||
"lint-staged": {
|
||||
"**/*.js": [
|
||||
@@ -59,14 +53,14 @@
|
||||
"animated": "^0.2.0",
|
||||
"array-find-index": "^1.0.2",
|
||||
"babel-runtime": "^6.26.0",
|
||||
"create-react-class": "^15.6.0",
|
||||
"create-react-class": "^15.6.2",
|
||||
"debounce": "1.0.2",
|
||||
"deep-assign": "^2.0.0",
|
||||
"fbjs": "^0.8.14",
|
||||
"fbjs": "^0.8.16",
|
||||
"hyphenate-style-name": "^1.0.2",
|
||||
"inline-style-prefixer": "^3.0.7",
|
||||
"inline-style-prefixer": "^3.0.8",
|
||||
"normalize-css-color": "^1.0.2",
|
||||
"prop-types": "^15.5.10",
|
||||
"prop-types": "^15.6.0",
|
||||
"react-timer-mixin": "^0.13.3"
|
||||
},
|
||||
"devDependencies": {
|
||||
@@ -76,30 +70,32 @@
|
||||
"babel-loader": "^7.1.2",
|
||||
"babel-plugin-tester": "^4.0.0",
|
||||
"babel-plugin-transform-react-remove-prop-types": "^0.4.8",
|
||||
"babel-preset-react-native": "^3.0.2",
|
||||
"babel-preset-react-native": "^4.0.0",
|
||||
"caniuse-api": "^2.0.0",
|
||||
"del-cli": "^1.1.0",
|
||||
"enzyme": "^2.9.1",
|
||||
"enzyme-to-json": "^1.5.1",
|
||||
"enzyme": "^3.0.0",
|
||||
"enzyme-adapter-react-16": "^1.0.0",
|
||||
"enzyme-to-json": "next",
|
||||
"eslint": "^4.6.1",
|
||||
"eslint-config-prettier": "^2.4.0",
|
||||
"eslint-plugin-promise": "^3.5.0",
|
||||
"eslint-plugin-react": "^7.3.0",
|
||||
"file-loader": "^0.11.2",
|
||||
"flow-bin": "^0.49.1",
|
||||
"jest": "^21.0.2",
|
||||
"jest": "^21.1.0",
|
||||
"lint-staged": "^4.1.3",
|
||||
"prettier": "^1.6.1",
|
||||
"react": "^15.6.1",
|
||||
"react-dom": "^15.6.1",
|
||||
"react-test-renderer": "^15.6.1",
|
||||
"prettier": "^1.7.0",
|
||||
"raf": "^3.3.2",
|
||||
"react": "^16.0.0",
|
||||
"react-dom": "^16.0.0",
|
||||
"react-test-renderer": "^16.0.0",
|
||||
"url-loader": "^0.5.9",
|
||||
"webpack": "^3.5.6",
|
||||
"webpack": "^3.6.0",
|
||||
"webpack-bundle-analyzer": "^2.9.0"
|
||||
},
|
||||
"peerDependencies": {
|
||||
"react": "15.4.x || 15.5.x || 15.6.x",
|
||||
"react-dom": "15.4.x || 15.5.x || 15.6.x"
|
||||
"react": "16.x.x",
|
||||
"react-dom": "16.x.x"
|
||||
},
|
||||
"author": "Nicolas Gallagher",
|
||||
"license": "BSD-3-Clause",
|
||||
|
||||
@@ -7,7 +7,7 @@ const browserList = {
|
||||
firefox: 40,
|
||||
ios_saf: 7,
|
||||
safari: 7,
|
||||
ie: 11,
|
||||
ie: 10,
|
||||
ie_mob: 11,
|
||||
edge: 12,
|
||||
opera: 16,
|
||||
|
||||
@@ -38,7 +38,7 @@ exports[`apis/AppRegistry/renderApplication getApplication 3`] = `
|
||||
.rn-textAlign-1ttztb7{text-align:inherit}
|
||||
.rn-textDecoration-bauka4{text-decoration:none}
|
||||
.rn-listStyle-1ebb2ja{list-style:none}
|
||||
.rn-alignItems-1oszu61{-webkit-align-items:stretch;-webkit-box-align:stretch;align-items:stretch}
|
||||
.rn-alignItems-1oszu61{-ms-flex-align:stretch;-webkit-align-items:stretch;-webkit-box-align:stretch;align-items:stretch}
|
||||
.rn-borderTopStyle-1efd50x{border-top-style:solid}
|
||||
.rn-borderRightStyle-14skgim{border-right-style:solid}
|
||||
.rn-borderBottomStyle-rull8r{border-bottom-style:solid}
|
||||
@@ -50,11 +50,10 @@ exports[`apis/AppRegistry/renderApplication getApplication 3`] = `
|
||||
.rn-boxSizing-deolkf{box-sizing:border-box}
|
||||
.rn-display-6koalj{display:-webkit-box;display:-moz-box;display:-ms-flexbox;display:-webkit-flex;display:flex}
|
||||
.rn-display-xoduu5{display:-webkit-inline-box;display:-moz-inline-box;display:-ms-inline-flexbox;display:-webkit-inline-flex;display:inline-flex}
|
||||
.rn-flexShrink-1qe8dj5{-webkit-flex-shrink:0;flex-shrink:0}
|
||||
.rn-flexShrink-1wbh5a2{-webkit-flex-shrink:1;flex-shrink:1}
|
||||
.rn-flexBasis-1mlwlqe{-webkit-flex-basis:auto;flex-basis:auto}
|
||||
.rn-flexBasis-1ro0kt6{-webkit-flex-basis:0%;flex-basis:0%}
|
||||
.rn-flexDirection-eqz5dr{-webkit-box-direction:normal;-webkit-box-orient:vertical;-webkit-flex-direction:column;flex-direction:column}
|
||||
.rn-flexShrink-1pxmb3b{-ms-flex-negative:0 !important;-webkit-flex-shrink:0 !important;flex-shrink:0 !important}
|
||||
.rn-flexShrink-1awmn5t{-ms-flex-negative:1 !important;-webkit-flex-shrink:1 !important;flex-shrink:1 !important}
|
||||
.rn-flexBasis-7vfszb{-ms-flex-preferred-size:auto !important;-webkit-flex-basis:auto !important;flex-basis:auto !important}
|
||||
.rn-flexDirection-eqz5dr{-ms-flex-direction:column;-webkit-box-direction:normal;-webkit-box-orient:vertical;-webkit-flex-direction:column;flex-direction:column}
|
||||
.rn-marginTop-1mnahxq{margin-top:0px}
|
||||
.rn-marginRight-61z16t{margin-right:0px}
|
||||
.rn-marginBottom-p1pxzi{margin-bottom:0px}
|
||||
@@ -67,5 +66,6 @@ exports[`apis/AppRegistry/renderApplication getApplication 3`] = `
|
||||
.rn-paddingLeft-gy4na3{padding-left:0px}
|
||||
.rn-zIndex-1lgpqti{z-index:0}
|
||||
.rn-zIndex-1wyyakw{z-index:-1}
|
||||
.rn-flexGrow-16y2uox{-webkit-flex-grow:1;flex-grow:1}</style>"
|
||||
.rn-flex-13awgt0{-ms-flex:1;-webkit-flex:1;flex:1}
|
||||
.rn-flexGrow-1m1wadx{-ms-flex-positive:1 !important;-webkit-flex-grow:1 !important;flex-grow:1 !important}</style>"
|
||||
`;
|
||||
|
||||
13
src/apis/Easing/index.js
Normal file
13
src/apis/Easing/index.js
Normal file
@@ -0,0 +1,13 @@
|
||||
/**
|
||||
* Copyright (c) 2016-present, Nicolas Gallagher.
|
||||
* All rights reserved.
|
||||
*
|
||||
* This source code is licensed under the BSD-style license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @providesModule Easing
|
||||
* @noflow
|
||||
*/
|
||||
|
||||
import Easing from 'animated/lib/Easing';
|
||||
export default Easing;
|
||||
@@ -13,7 +13,9 @@
|
||||
import dismissKeyboard from '../../modules/dismissKeyboard';
|
||||
|
||||
const Keyboard = {
|
||||
addListener() {},
|
||||
addListener() {
|
||||
return { remove: () => {} };
|
||||
},
|
||||
dismiss() {
|
||||
dismissKeyboard();
|
||||
},
|
||||
|
||||
@@ -26,44 +26,44 @@ describe('apis/StyleSheet/createReactDOMStyle', () => {
|
||||
test('flex defaults', () => {
|
||||
expect(createReactDOMStyle({ display: 'flex' })).toEqual({
|
||||
display: 'flex',
|
||||
flexShrink: 0,
|
||||
flexBasis: 'auto'
|
||||
flexShrink: '0 !important',
|
||||
flexBasis: 'auto !important'
|
||||
});
|
||||
});
|
||||
|
||||
test('flex: -1', () => {
|
||||
expect(createReactDOMStyle({ display: 'flex', flex: -1 })).toEqual({
|
||||
display: 'flex',
|
||||
flexGrow: 0,
|
||||
flexShrink: 1,
|
||||
flexBasis: 'auto'
|
||||
flexGrow: '0 !important',
|
||||
flexShrink: '1 !important',
|
||||
flexBasis: 'auto !important'
|
||||
});
|
||||
});
|
||||
|
||||
test('flex: 0', () => {
|
||||
expect(createReactDOMStyle({ display: 'flex', flex: 0 })).toEqual({
|
||||
display: 'flex',
|
||||
flexGrow: 0,
|
||||
flexShrink: 0,
|
||||
flexBasis: 'auto'
|
||||
flexGrow: '0 !important',
|
||||
flexShrink: '0 !important',
|
||||
flexBasis: 'auto !important'
|
||||
});
|
||||
});
|
||||
|
||||
test('flex: 1', () => {
|
||||
expect(createReactDOMStyle({ display: 'flex', flex: 1 })).toEqual({
|
||||
display: 'flex',
|
||||
flexGrow: 1,
|
||||
flexShrink: 1,
|
||||
flexBasis: '0%'
|
||||
flex: 1,
|
||||
flexGrow: '1 !important',
|
||||
flexShrink: '1 !important'
|
||||
});
|
||||
});
|
||||
|
||||
test('flex: 10', () => {
|
||||
expect(createReactDOMStyle({ display: 'flex', flex: 10 })).toEqual({
|
||||
display: 'flex',
|
||||
flexGrow: 10,
|
||||
flexShrink: 1,
|
||||
flexBasis: '0%'
|
||||
flex: 10,
|
||||
flexGrow: '10 !important',
|
||||
flexShrink: '1 !important'
|
||||
});
|
||||
});
|
||||
|
||||
@@ -71,16 +71,17 @@ describe('apis/StyleSheet/createReactDOMStyle', () => {
|
||||
// is flex-basis applied?
|
||||
expect(createReactDOMStyle({ display: 'flex', flexBasis: '25%' })).toEqual({
|
||||
display: 'flex',
|
||||
flexShrink: 0,
|
||||
flexBasis: '25%'
|
||||
flexShrink: '0 !important',
|
||||
flexBasis: '25% !important'
|
||||
});
|
||||
|
||||
// can flex-basis override the 'flex' expansion?
|
||||
expect(createReactDOMStyle({ display: 'flex', flex: 1, flexBasis: '25%' })).toEqual({
|
||||
display: 'flex',
|
||||
flexGrow: 1,
|
||||
flexShrink: 1,
|
||||
flexBasis: '25%'
|
||||
flex: 1,
|
||||
flexGrow: '1 !important',
|
||||
flexShrink: '1 !important',
|
||||
flexBasis: '25% !important'
|
||||
});
|
||||
});
|
||||
|
||||
@@ -88,16 +89,16 @@ describe('apis/StyleSheet/createReactDOMStyle', () => {
|
||||
// is flex-shrink applied?
|
||||
expect(createReactDOMStyle({ display: 'flex', flexShrink: 1 })).toEqual({
|
||||
display: 'flex',
|
||||
flexShrink: 1,
|
||||
flexBasis: 'auto'
|
||||
flexShrink: '1 !important',
|
||||
flexBasis: 'auto !important'
|
||||
});
|
||||
|
||||
// can flex-shrink override the 'flex' expansion?
|
||||
expect(createReactDOMStyle({ display: 'flex', flex: 1, flexShrink: 2 })).toEqual({
|
||||
display: 'flex',
|
||||
flexGrow: 1,
|
||||
flexShrink: 2,
|
||||
flexBasis: '0%'
|
||||
flex: 1,
|
||||
flexGrow: '1 !important',
|
||||
flexShrink: '2 !important'
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
@@ -158,29 +158,56 @@ const createReducer = (style, styleProps) => {
|
||||
|
||||
case 'display': {
|
||||
resolvedStyle.display = value;
|
||||
// defaults of 'flexBasis:auto' and 'flexShrink:0' have lowest precedence
|
||||
if (style.display === 'flex') {
|
||||
// A flex container in React Native has these defaults which should be
|
||||
// set only if there is no otherwise supplied flex style.
|
||||
if (style.display === 'flex' && style.flex == null) {
|
||||
if (style.flexShrink == null) {
|
||||
resolvedStyle.flexShrink = 0;
|
||||
resolvedStyle.flexShrink = '0 !important';
|
||||
}
|
||||
if (style.flexBasis == null) {
|
||||
resolvedStyle.flexBasis = 'auto';
|
||||
resolvedStyle.flexBasis = 'auto !important';
|
||||
}
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
// The 'flex' property value in React Native must be a positive integer,
|
||||
// 0, or -1.
|
||||
//
|
||||
// On the web, a positive integer value for 'flex' is complicated by
|
||||
// browser differences. Although browsers render styles like 'flex:2'
|
||||
// consistently, they don't all set the same value for the resulting
|
||||
// 'flexBasis' (See #616). Expanding 'flex' in 'StyleSheet' would mean
|
||||
// setting different values for different browsers.
|
||||
//
|
||||
// This fix instead relies on the browser expanding 'flex' itself. And
|
||||
// because the 'flex' style is not being expanded the generated CSS is
|
||||
// likely to contain source order "conflicts". To avoid the browser
|
||||
// relying on source order to resolve the styles, all the longhand flex
|
||||
// property values must use '!important'.
|
||||
case 'flex': {
|
||||
if (value > 0) {
|
||||
resolvedStyle.flexGrow = value;
|
||||
resolvedStyle.flexShrink = 1;
|
||||
resolvedStyle.flexBasis = '0%';
|
||||
resolvedStyle.flex = value;
|
||||
resolvedStyle.flexGrow = `${value} !important`;
|
||||
resolvedStyle.flexShrink = '1 !important';
|
||||
} else if (value === 0) {
|
||||
resolvedStyle.flexGrow = 0;
|
||||
resolvedStyle.flexShrink = 0;
|
||||
resolvedStyle.flexGrow = '0 !important';
|
||||
resolvedStyle.flexShrink = '0 !important';
|
||||
resolvedStyle.flexBasis = 'auto !important';
|
||||
} else if (value === -1) {
|
||||
resolvedStyle.flexGrow = 0;
|
||||
resolvedStyle.flexShrink = 1;
|
||||
resolvedStyle.flexGrow = '0 !important';
|
||||
resolvedStyle.flexShrink = '1 !important';
|
||||
resolvedStyle.flexBasis = 'auto !important';
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
case 'flexGrow':
|
||||
case 'flexShrink':
|
||||
case 'flexBasis': {
|
||||
if (value != null) {
|
||||
const hasImportant = `${value}`.indexOf('!important') > -1;
|
||||
resolvedStyle[prop] = hasImportant ? value : `${value} !important`;
|
||||
}
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -1,18 +1,30 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`components/ActivityIndicator prop "animating" is "false" 1`] = `
|
||||
<div
|
||||
<View
|
||||
accessibilityRole="progressbar"
|
||||
aria-valuemax="1"
|
||||
aria-valuemin="0"
|
||||
class="rn-alignItems-1awozwy rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-justifyContent-1777fci rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim"
|
||||
role="progressbar"
|
||||
style={
|
||||
Array [
|
||||
15,
|
||||
undefined,
|
||||
]
|
||||
}
|
||||
>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-animationDuration-17bb2tj rn-animationIterationCount-1muvv40 rn-animationName-dozj4v rn-animationPlayState-1abnn5w rn-animationTimingFunction-1ldzwu0 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-height-z80fyv rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-visibility-11j9u27 rn-width-19wmn03"
|
||||
<View
|
||||
style={
|
||||
Array [
|
||||
19,
|
||||
17,
|
||||
18,
|
||||
16,
|
||||
]
|
||||
}
|
||||
>
|
||||
<svg
|
||||
height="100%"
|
||||
viewbox="0 0 32 32"
|
||||
viewBox="0 0 32 32"
|
||||
width="100%"
|
||||
>
|
||||
<circle
|
||||
@@ -20,35 +32,58 @@ exports[`components/ActivityIndicator prop "animating" is "false" 1`] = `
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:#1976D2;opacity:0.2;"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"opacity": 0.2,
|
||||
"stroke": "#1976D2",
|
||||
}
|
||||
}
|
||||
/>
|
||||
<circle
|
||||
cx="16"
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:#1976D2;stroke-dasharray:80;stroke-dashoffset:60;"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"stroke": "#1976D2",
|
||||
"strokeDasharray": 80,
|
||||
"strokeDashoffset": 60,
|
||||
}
|
||||
}
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
</div>
|
||||
</View>
|
||||
</View>
|
||||
`;
|
||||
|
||||
exports[`components/ActivityIndicator prop "animating" is "true" 1`] = `
|
||||
<div
|
||||
<View
|
||||
accessibilityRole="progressbar"
|
||||
aria-valuemax="1"
|
||||
aria-valuemin="0"
|
||||
class="rn-alignItems-1awozwy rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-justifyContent-1777fci rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim"
|
||||
role="progressbar"
|
||||
style={
|
||||
Array [
|
||||
15,
|
||||
undefined,
|
||||
]
|
||||
}
|
||||
>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-animationDuration-17bb2tj rn-animationIterationCount-1muvv40 rn-animationName-dozj4v rn-animationTimingFunction-1ldzwu0 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-height-z80fyv rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-width-19wmn03"
|
||||
<View
|
||||
style={
|
||||
Array [
|
||||
19,
|
||||
17,
|
||||
false,
|
||||
false,
|
||||
]
|
||||
}
|
||||
>
|
||||
<svg
|
||||
height="100%"
|
||||
viewbox="0 0 32 32"
|
||||
viewBox="0 0 32 32"
|
||||
width="100%"
|
||||
>
|
||||
<circle
|
||||
@@ -56,71 +91,94 @@ exports[`components/ActivityIndicator prop "animating" is "true" 1`] = `
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:#1976D2;opacity:0.2;"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"opacity": 0.2,
|
||||
"stroke": "#1976D2",
|
||||
}
|
||||
}
|
||||
/>
|
||||
<circle
|
||||
cx="16"
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:#1976D2;stroke-dasharray:80;stroke-dashoffset:60;"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"stroke": "#1976D2",
|
||||
"strokeDasharray": 80,
|
||||
"strokeDashoffset": 60,
|
||||
}
|
||||
}
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
</div>
|
||||
</View>
|
||||
</View>
|
||||
`;
|
||||
|
||||
exports[`components/ActivityIndicator prop "color" 1`] = `
|
||||
<div
|
||||
aria-valuemax="1"
|
||||
aria-valuemin="0"
|
||||
class="rn-alignItems-1awozwy rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-justifyContent-1777fci rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim"
|
||||
role="progressbar"
|
||||
<svg
|
||||
height="100%"
|
||||
viewBox="0 0 32 32"
|
||||
width="100%"
|
||||
>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-animationDuration-17bb2tj rn-animationIterationCount-1muvv40 rn-animationName-dozj4v rn-animationTimingFunction-1ldzwu0 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-height-z80fyv rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-width-19wmn03"
|
||||
>
|
||||
<svg
|
||||
height="100%"
|
||||
viewbox="0 0 32 32"
|
||||
width="100%"
|
||||
>
|
||||
<circle
|
||||
cx="16"
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:red;opacity:0.2;"
|
||||
/>
|
||||
<circle
|
||||
cx="16"
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:red;stroke-dasharray:80;stroke-dashoffset:60;"
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
</div>
|
||||
<circle
|
||||
cx="16"
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"opacity": 0.2,
|
||||
"stroke": "red",
|
||||
}
|
||||
}
|
||||
/>
|
||||
<circle
|
||||
cx="16"
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"stroke": "red",
|
||||
"strokeDasharray": 80,
|
||||
"strokeDashoffset": 60,
|
||||
}
|
||||
}
|
||||
/>
|
||||
</svg>
|
||||
`;
|
||||
|
||||
exports[`components/ActivityIndicator prop "hidesWhenStopped" is "false" 1`] = `
|
||||
<div
|
||||
<View
|
||||
accessibilityRole="progressbar"
|
||||
aria-valuemax="1"
|
||||
aria-valuemin="0"
|
||||
class="rn-alignItems-1awozwy rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-justifyContent-1777fci rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim"
|
||||
role="progressbar"
|
||||
style={
|
||||
Array [
|
||||
15,
|
||||
undefined,
|
||||
]
|
||||
}
|
||||
>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-animationDuration-17bb2tj rn-animationIterationCount-1muvv40 rn-animationName-dozj4v rn-animationPlayState-1abnn5w rn-animationTimingFunction-1ldzwu0 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-height-z80fyv rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-width-19wmn03"
|
||||
<View
|
||||
style={
|
||||
Array [
|
||||
19,
|
||||
17,
|
||||
18,
|
||||
false,
|
||||
]
|
||||
}
|
||||
>
|
||||
<svg
|
||||
height="100%"
|
||||
viewbox="0 0 32 32"
|
||||
viewBox="0 0 32 32"
|
||||
width="100%"
|
||||
>
|
||||
<circle
|
||||
@@ -128,35 +186,58 @@ exports[`components/ActivityIndicator prop "hidesWhenStopped" is "false" 1`] = `
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:#1976D2;opacity:0.2;"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"opacity": 0.2,
|
||||
"stroke": "#1976D2",
|
||||
}
|
||||
}
|
||||
/>
|
||||
<circle
|
||||
cx="16"
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:#1976D2;stroke-dasharray:80;stroke-dashoffset:60;"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"stroke": "#1976D2",
|
||||
"strokeDasharray": 80,
|
||||
"strokeDashoffset": 60,
|
||||
}
|
||||
}
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
</div>
|
||||
</View>
|
||||
</View>
|
||||
`;
|
||||
|
||||
exports[`components/ActivityIndicator prop "hidesWhenStopped" is "true" 1`] = `
|
||||
<div
|
||||
<View
|
||||
accessibilityRole="progressbar"
|
||||
aria-valuemax="1"
|
||||
aria-valuemin="0"
|
||||
class="rn-alignItems-1awozwy rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-justifyContent-1777fci rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim"
|
||||
role="progressbar"
|
||||
style={
|
||||
Array [
|
||||
15,
|
||||
undefined,
|
||||
]
|
||||
}
|
||||
>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-animationDuration-17bb2tj rn-animationIterationCount-1muvv40 rn-animationName-dozj4v rn-animationPlayState-1abnn5w rn-animationTimingFunction-1ldzwu0 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-height-z80fyv rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-visibility-11j9u27 rn-width-19wmn03"
|
||||
<View
|
||||
style={
|
||||
Array [
|
||||
19,
|
||||
17,
|
||||
18,
|
||||
16,
|
||||
]
|
||||
}
|
||||
>
|
||||
<svg
|
||||
height="100%"
|
||||
viewbox="0 0 32 32"
|
||||
viewBox="0 0 32 32"
|
||||
width="100%"
|
||||
>
|
||||
<circle
|
||||
@@ -164,35 +245,58 @@ exports[`components/ActivityIndicator prop "hidesWhenStopped" is "true" 1`] = `
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:#1976D2;opacity:0.2;"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"opacity": 0.2,
|
||||
"stroke": "#1976D2",
|
||||
}
|
||||
}
|
||||
/>
|
||||
<circle
|
||||
cx="16"
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:#1976D2;stroke-dasharray:80;stroke-dashoffset:60;"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"stroke": "#1976D2",
|
||||
"strokeDasharray": 80,
|
||||
"strokeDashoffset": 60,
|
||||
}
|
||||
}
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
</div>
|
||||
</View>
|
||||
</View>
|
||||
`;
|
||||
|
||||
exports[`components/ActivityIndicator prop "size" is "large" 1`] = `
|
||||
<div
|
||||
<View
|
||||
accessibilityRole="progressbar"
|
||||
aria-valuemax="1"
|
||||
aria-valuemin="0"
|
||||
class="rn-alignItems-1awozwy rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-justifyContent-1777fci rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim"
|
||||
role="progressbar"
|
||||
style={
|
||||
Array [
|
||||
15,
|
||||
undefined,
|
||||
]
|
||||
}
|
||||
>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-animationDuration-17bb2tj rn-animationIterationCount-1muvv40 rn-animationName-dozj4v rn-animationTimingFunction-1ldzwu0 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-height-1r8g8re rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-width-1acpoxo"
|
||||
<View
|
||||
style={
|
||||
Array [
|
||||
20,
|
||||
17,
|
||||
false,
|
||||
false,
|
||||
]
|
||||
}
|
||||
>
|
||||
<svg
|
||||
height="100%"
|
||||
viewbox="0 0 32 32"
|
||||
viewBox="0 0 32 32"
|
||||
width="100%"
|
||||
>
|
||||
<circle
|
||||
@@ -200,36 +304,61 @@ exports[`components/ActivityIndicator prop "size" is "large" 1`] = `
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:#1976D2;opacity:0.2;"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"opacity": 0.2,
|
||||
"stroke": "#1976D2",
|
||||
}
|
||||
}
|
||||
/>
|
||||
<circle
|
||||
cx="16"
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:#1976D2;stroke-dasharray:80;stroke-dashoffset:60;"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"stroke": "#1976D2",
|
||||
"strokeDasharray": 80,
|
||||
"strokeDashoffset": 60,
|
||||
}
|
||||
}
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
</div>
|
||||
</View>
|
||||
</View>
|
||||
`;
|
||||
|
||||
exports[`components/ActivityIndicator prop "size" is a number 1`] = `
|
||||
<div
|
||||
<View
|
||||
accessibilityRole="progressbar"
|
||||
aria-valuemax="1"
|
||||
aria-valuemin="0"
|
||||
class="rn-alignItems-1awozwy rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-justifyContent-1777fci rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim"
|
||||
role="progressbar"
|
||||
style={
|
||||
Array [
|
||||
15,
|
||||
undefined,
|
||||
]
|
||||
}
|
||||
>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-animationDuration-17bb2tj rn-animationIterationCount-1muvv40 rn-animationName-dozj4v rn-animationTimingFunction-1ldzwu0 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim"
|
||||
style="height:30px;width:30px;"
|
||||
<View
|
||||
style={
|
||||
Array [
|
||||
Object {
|
||||
"height": 30,
|
||||
"width": 30,
|
||||
},
|
||||
17,
|
||||
false,
|
||||
false,
|
||||
]
|
||||
}
|
||||
>
|
||||
<svg
|
||||
height="100%"
|
||||
viewbox="0 0 32 32"
|
||||
viewBox="0 0 32 32"
|
||||
width="100%"
|
||||
>
|
||||
<circle
|
||||
@@ -237,18 +366,29 @@ exports[`components/ActivityIndicator prop "size" is a number 1`] = `
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:#1976D2;opacity:0.2;"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"opacity": 0.2,
|
||||
"stroke": "#1976D2",
|
||||
}
|
||||
}
|
||||
/>
|
||||
<circle
|
||||
cx="16"
|
||||
cy="16"
|
||||
fill="none"
|
||||
r="14"
|
||||
stroke-width="4"
|
||||
style="stroke:#1976D2;stroke-dasharray:80;stroke-dashoffset:60;"
|
||||
strokeWidth="4"
|
||||
style={
|
||||
Object {
|
||||
"stroke": "#1976D2",
|
||||
"strokeDasharray": 80,
|
||||
"strokeDashoffset": 60,
|
||||
}
|
||||
}
|
||||
/>
|
||||
</svg>
|
||||
</div>
|
||||
</div>
|
||||
</View>
|
||||
</View>
|
||||
`;
|
||||
|
||||
@@ -2,46 +2,46 @@
|
||||
|
||||
import ActivityIndicator from '..';
|
||||
import React from 'react';
|
||||
import { render } from 'enzyme';
|
||||
import { shallow } from 'enzyme';
|
||||
|
||||
describe('components/ActivityIndicator', () => {
|
||||
describe('prop "animating"', () => {
|
||||
test('is "true"', () => {
|
||||
const component = render(<ActivityIndicator animating={true} />);
|
||||
const component = shallow(<ActivityIndicator animating={true} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('is "false"', () => {
|
||||
const component = render(<ActivityIndicator animating={false} />);
|
||||
const component = shallow(<ActivityIndicator animating={false} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
|
||||
test('prop "color"', () => {
|
||||
const component = render(<ActivityIndicator color="red" />);
|
||||
const component = shallow(<ActivityIndicator color="red" />).find('svg');
|
||||
expect(component).toMatchSnapshot();
|
||||
});
|
||||
|
||||
describe('prop "hidesWhenStopped"', () => {
|
||||
test('is "true"', () => {
|
||||
const component = render(<ActivityIndicator animating={false} hidesWhenStopped={true} />);
|
||||
const component = shallow(<ActivityIndicator animating={false} hidesWhenStopped={true} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('is "false"', () => {
|
||||
const component = render(<ActivityIndicator animating={false} hidesWhenStopped={false} />);
|
||||
const component = shallow(<ActivityIndicator animating={false} hidesWhenStopped={false} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
|
||||
describe('prop "size"', () => {
|
||||
test('is "large"', () => {
|
||||
const component = render(<ActivityIndicator size="large" />);
|
||||
const component = shallow(<ActivityIndicator size="large" />);
|
||||
expect(component).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('is a number', () => {
|
||||
const component = render(<ActivityIndicator size={30} />);
|
||||
const component = shallow(<ActivityIndicator size={30} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
|
||||
@@ -1,138 +1,17 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`components/Image passes other props through to underlying View 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-4gszlv rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
/>
|
||||
`;
|
||||
exports[`components/Image prop "defaultSource" sets background image when value is a string 1`] = `"url(\\"https://google.com/favicon.ico\\")"`;
|
||||
|
||||
exports[`components/Image prop "accessibilityLabel" 1`] = `
|
||||
<div
|
||||
aria-label="accessibilityLabel"
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-4gszlv rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
style="background-image:url(\\"https://google.com/favicon.ico\\");"
|
||||
>
|
||||
<img
|
||||
alt="accessibilityLabel"
|
||||
class="rn-bottom-1p0dtai rn-height-1pi2tsx rn-left-1d2f490 rn-opacity-1272l3b rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-width-13qz1uu rn-zIndex-1wyyakw"
|
||||
src="https://google.com/favicon.ico"
|
||||
/>
|
||||
</div>
|
||||
`;
|
||||
exports[`components/Image prop "defaultSource" sets background image when value is an object 1`] = `"url(\\"https://google.com/favicon.ico\\")"`;
|
||||
|
||||
exports[`components/Image prop "accessible" 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-4gszlv rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
/>
|
||||
`;
|
||||
exports[`components/Image prop "resizeMode" value "contain" 1`] = `"contain"`;
|
||||
|
||||
exports[`components/Image prop "children" 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-4gszlv rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
>
|
||||
<div
|
||||
class="unique"
|
||||
/>
|
||||
</div>
|
||||
`;
|
||||
exports[`components/Image prop "resizeMode" value "cover" 1`] = `"cover"`;
|
||||
|
||||
exports[`components/Image prop "defaultSource" does not override "height" and "width" styles 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-4gszlv rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
style="background-image:url(\\"https://google.com/favicon.ico\\");height:20px;width:40px;"
|
||||
>
|
||||
<img
|
||||
alt=""
|
||||
class="rn-bottom-1p0dtai rn-height-1pi2tsx rn-left-1d2f490 rn-opacity-1272l3b rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-width-13qz1uu rn-zIndex-1wyyakw"
|
||||
src="https://google.com/favicon.ico"
|
||||
/>
|
||||
</div>
|
||||
`;
|
||||
exports[`components/Image prop "resizeMode" value "none" 1`] = `"auto"`;
|
||||
|
||||
exports[`components/Image prop "defaultSource" sets "height" and "width" styles if missing 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-4gszlv rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
style="background-image:url(\\"https://google.com/favicon.ico\\");height:10px;width:20px;"
|
||||
>
|
||||
<img
|
||||
alt=""
|
||||
class="rn-bottom-1p0dtai rn-height-1pi2tsx rn-left-1d2f490 rn-opacity-1272l3b rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-width-13qz1uu rn-zIndex-1wyyakw"
|
||||
src="https://google.com/favicon.ico"
|
||||
/>
|
||||
</div>
|
||||
`;
|
||||
exports[`components/Image prop "resizeMode" value "stretch" 1`] = `"100% 100%"`;
|
||||
|
||||
exports[`components/Image prop "defaultSource" sets background image when value is a string 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-4gszlv rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
style="background-image:url(\\"https://google.com/favicon.ico\\");"
|
||||
>
|
||||
<img
|
||||
alt=""
|
||||
class="rn-bottom-1p0dtai rn-height-1pi2tsx rn-left-1d2f490 rn-opacity-1272l3b rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-width-13qz1uu rn-zIndex-1wyyakw"
|
||||
src="https://google.com/favicon.ico"
|
||||
/>
|
||||
</div>
|
||||
`;
|
||||
exports[`components/Image prop "resizeMode" value "undefined" 1`] = `"cover"`;
|
||||
|
||||
exports[`components/Image prop "defaultSource" sets background image when value is an object 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-4gszlv rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
style="background-image:url(\\"https://google.com/favicon.ico\\");"
|
||||
>
|
||||
<img
|
||||
alt=""
|
||||
class="rn-bottom-1p0dtai rn-height-1pi2tsx rn-left-1d2f490 rn-opacity-1272l3b rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-width-13qz1uu rn-zIndex-1wyyakw"
|
||||
src="https://google.com/favicon.ico"
|
||||
/>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`components/Image prop "resizeMode" value "contain" 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-ehq7j7 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`components/Image prop "resizeMode" value "cover" 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-4gszlv rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`components/Image prop "resizeMode" value "none" 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-1sxrcry rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`components/Image prop "resizeMode" value "stretch" 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-x3cy2q rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`components/Image prop "resizeMode" value "undefined" 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-4gszlv rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`components/Image prop "style" correctly supports "resizeMode" property 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-ehq7j7 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`components/Image prop "testID" 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-4gszlv rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
data-testid="testID"
|
||||
/>
|
||||
`;
|
||||
|
||||
exports[`components/Image sets correct accessibility role" 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-wib322 rn-backgroundPosition-vvn4in rn-backgroundRepeat-u6sd8q rn-backgroundSize-4gszlv rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
/>
|
||||
`;
|
||||
exports[`components/Image prop "style" correctly supports "resizeMode" property 1`] = `"contain"`;
|
||||
|
||||
@@ -1,12 +1,10 @@
|
||||
/* eslint-env jasmine, jest */
|
||||
|
||||
import ExecutionEnvironment from 'fbjs/lib/ExecutionEnvironment';
|
||||
import Image from '../';
|
||||
import ImageUriCache from '../ImageUriCache';
|
||||
import React from 'react';
|
||||
import { mount, render, shallow } from 'enzyme';
|
||||
import { mount, shallow } from 'enzyme';
|
||||
|
||||
const originalCanUseDOM = ExecutionEnvironment.canUseDOM;
|
||||
const originalImage = window.Image;
|
||||
|
||||
describe('components/Image', () => {
|
||||
@@ -18,42 +16,39 @@ describe('components/Image', () => {
|
||||
window.Image = originalImage;
|
||||
});
|
||||
|
||||
test('sets correct accessibility role"', () => {
|
||||
const component = render(<Image />);
|
||||
expect(component).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('prop "accessibilityLabel"', () => {
|
||||
const defaultSource = { uri: 'https://google.com/favicon.ico' };
|
||||
const component = render(
|
||||
const component = shallow(
|
||||
<Image accessibilityLabel="accessibilityLabel" defaultSource={defaultSource} />
|
||||
);
|
||||
expect(component).toMatchSnapshot();
|
||||
const img = component.find('img');
|
||||
expect(component.prop('accessibilityLabel')).toBe('accessibilityLabel');
|
||||
expect(img.prop('alt')).toBe('accessibilityLabel');
|
||||
});
|
||||
|
||||
test('prop "accessible"', () => {
|
||||
const component = render(<Image accessible={false} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Image accessible={false} />);
|
||||
expect(component.prop('accessible')).toBe(false);
|
||||
});
|
||||
|
||||
test('prop "children"', () => {
|
||||
const children = <div className="unique" />;
|
||||
const component = render(<Image children={children} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Image children={children} />);
|
||||
expect(component.find('.unique').length).toBe(1);
|
||||
});
|
||||
|
||||
describe('prop "defaultSource"', () => {
|
||||
test('sets background image when value is an object', () => {
|
||||
const defaultSource = { uri: 'https://google.com/favicon.ico' };
|
||||
const component = render(<Image defaultSource={defaultSource} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Image defaultSource={defaultSource} />);
|
||||
expect(component.prop('style').backgroundImage).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('sets background image when value is a string', () => {
|
||||
// emulate require-ed asset
|
||||
const defaultSource = 'https://google.com/favicon.ico';
|
||||
const component = render(<Image defaultSource={defaultSource} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Image defaultSource={defaultSource} />);
|
||||
expect(component.prop('style').backgroundImage).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('sets "height" and "width" styles if missing', () => {
|
||||
@@ -62,8 +57,10 @@ describe('components/Image', () => {
|
||||
height: 10,
|
||||
width: 20
|
||||
};
|
||||
const component = render(<Image defaultSource={defaultSource} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Image defaultSource={defaultSource} />);
|
||||
const { height, width } = component.prop('style');
|
||||
expect(height).toBe(10);
|
||||
expect(width).toBe(20);
|
||||
});
|
||||
|
||||
test('does not override "height" and "width" styles', () => {
|
||||
@@ -72,10 +69,12 @@ describe('components/Image', () => {
|
||||
height: 10,
|
||||
width: 20
|
||||
};
|
||||
const component = render(
|
||||
const component = shallow(
|
||||
<Image defaultSource={defaultSource} style={{ height: 20, width: 40 }} />
|
||||
);
|
||||
expect(component).toMatchSnapshot();
|
||||
const { height, width } = component.prop('style');
|
||||
expect(height).toBe(20);
|
||||
expect(width).toBe(40);
|
||||
});
|
||||
});
|
||||
|
||||
@@ -96,8 +95,8 @@ describe('components/Image', () => {
|
||||
undefined
|
||||
].forEach(resizeMode => {
|
||||
test(`value "${resizeMode}"`, () => {
|
||||
const component = render(<Image resizeMode={resizeMode} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Image resizeMode={resizeMode} />);
|
||||
expect(component.prop('style').backgroundSize).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -106,7 +105,7 @@ describe('components/Image', () => {
|
||||
test('is not set immediately if the image has not already been loaded', () => {
|
||||
const uri = 'https://google.com/favicon.ico';
|
||||
const source = { uri };
|
||||
const component = render(<Image source={source} />);
|
||||
const component = shallow(<Image source={source} />);
|
||||
expect(component.find('img')).toBeUndefined;
|
||||
});
|
||||
|
||||
@@ -136,21 +135,12 @@ describe('components/Image', () => {
|
||||
.attr('src')
|
||||
).toBe(uriTwo);
|
||||
});
|
||||
|
||||
test('is set immediately when rendered on the server', () => {
|
||||
ExecutionEnvironment.canUseDOM = false;
|
||||
const uri = 'https://google.com/favicon.ico';
|
||||
const component = render(<Image source={{ uri }} />);
|
||||
expect(component.find('img').attr('src')).toBe(uri);
|
||||
expect(ImageUriCache.has(uri)).toBe(true);
|
||||
ExecutionEnvironment.canUseDOM = originalCanUseDOM;
|
||||
});
|
||||
});
|
||||
|
||||
describe('prop "style"', () => {
|
||||
test('correctly supports "resizeMode" property', () => {
|
||||
const component = render(<Image style={{ resizeMode: Image.resizeMode.contain }} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Image style={{ resizeMode: Image.resizeMode.contain }} />);
|
||||
expect(component.prop('style').backgroundSize).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('removes other unsupported View styles', () => {
|
||||
@@ -161,13 +151,13 @@ describe('components/Image', () => {
|
||||
});
|
||||
|
||||
test('prop "testID"', () => {
|
||||
const component = render(<Image testID="testID" />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Image testID="testID" />);
|
||||
expect(component.prop('testID')).toBe('testID');
|
||||
});
|
||||
|
||||
test('passes other props through to underlying View', () => {
|
||||
const fn = () => {};
|
||||
const component = render(<Image onResponderGrant={fn} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Image onResponderGrant={fn} />);
|
||||
expect(component.prop('onResponderGrant')).toBe(fn);
|
||||
});
|
||||
});
|
||||
|
||||
@@ -11,7 +11,6 @@
|
||||
*/
|
||||
|
||||
import applyNativeMethods from '../../modules/applyNativeMethods';
|
||||
import { canUseDOM } from 'fbjs/lib/ExecutionEnvironment';
|
||||
import createElement from '../../modules/createElement';
|
||||
import { getAssetByID } from '../../modules/AssetRegistry';
|
||||
import ImageLoader from '../../modules/ImageLoader';
|
||||
@@ -131,7 +130,7 @@ class Image extends Component {
|
||||
super(props, context);
|
||||
// If an image has been loaded before, render it immediately
|
||||
const uri = resolveAssetSource(props.source);
|
||||
const shouldDisplaySource = ImageUriCache.has(uri) || !canUseDOM;
|
||||
const shouldDisplaySource = ImageUriCache.has(uri);
|
||||
this.state = { shouldDisplaySource };
|
||||
this._imageState = getImageState(uri, shouldDisplaySource);
|
||||
shouldDisplaySource && ImageUriCache.add(uri);
|
||||
|
||||
@@ -1,2 +1,55 @@
|
||||
import UnimplementedView from '../UnimplementedView';
|
||||
export default UnimplementedView;
|
||||
/**
|
||||
* Copyright (c) 2017-present, Nicolas Gallagher.
|
||||
* Copyright (c) 2015-present, Facebook, Inc.
|
||||
* All rights reserved.
|
||||
*
|
||||
* This source code is licensed under the BSD-style license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @providesModule RefreshControl
|
||||
* @flow
|
||||
*/
|
||||
|
||||
import ColorPropType from '../../propTypes/ColorPropType';
|
||||
import View from '../View';
|
||||
import ViewPropTypes from '../View/ViewPropTypes';
|
||||
import { arrayOf, bool, func, number, oneOf, string } from 'prop-types';
|
||||
import React, { Component } from 'react';
|
||||
|
||||
class RefreshControl extends Component {
|
||||
static propTypes = {
|
||||
...ViewPropTypes,
|
||||
colors: arrayOf(ColorPropType),
|
||||
enabled: bool,
|
||||
onRefresh: func,
|
||||
progressBackgroundColor: ColorPropType,
|
||||
progressViewOffset: number,
|
||||
refreshing: bool.isRequired,
|
||||
size: oneOf([0, 1]),
|
||||
tintColor: ColorPropType,
|
||||
title: string,
|
||||
titleColor: ColorPropType
|
||||
};
|
||||
|
||||
render() {
|
||||
const {
|
||||
/* eslint-disable */
|
||||
colors,
|
||||
enabled,
|
||||
onRefresh,
|
||||
progressBackgroundColor,
|
||||
progressViewOffset,
|
||||
refreshing,
|
||||
size,
|
||||
tintColor,
|
||||
title,
|
||||
titleColor,
|
||||
/* eslint-enable */
|
||||
...rest
|
||||
} = this.props;
|
||||
|
||||
return <View {...rest} />;
|
||||
}
|
||||
}
|
||||
|
||||
export default RefreshControl;
|
||||
|
||||
@@ -134,14 +134,39 @@ export default class ScrollViewBase extends Component {
|
||||
scrollEnabled,
|
||||
style,
|
||||
/* eslint-disable */
|
||||
alwaysBounceHorizontal,
|
||||
alwaysBounceVertical,
|
||||
automaticallyAdjustContentInsets,
|
||||
bounces,
|
||||
bouncesZoom,
|
||||
canCancelContentTouches,
|
||||
centerContent,
|
||||
contentInset,
|
||||
contentInsetAdjustmentBehavior,
|
||||
contentOffset,
|
||||
decelerationRate,
|
||||
directionalLockEnabled,
|
||||
endFillColor,
|
||||
indicatorStyle,
|
||||
keyboardShouldPersistTaps,
|
||||
maximumZoomScale,
|
||||
minimumZoomScale,
|
||||
onMomentumScrollBegin,
|
||||
onMomentumScrollEnd,
|
||||
onScrollBeginDrag,
|
||||
onScrollEndDrag,
|
||||
overScrollMode,
|
||||
pinchGestureEnabled,
|
||||
removeClippedSubviews,
|
||||
scrollEventThrottle,
|
||||
scrollIndicatorInsets,
|
||||
scrollPerfTag,
|
||||
scrollsToTop,
|
||||
showsHorizontalScrollIndicator,
|
||||
showsVerticalScrollIndicator,
|
||||
snapToInterval,
|
||||
snapToAlignment,
|
||||
zoomScale,
|
||||
/* eslint-enable */
|
||||
...other
|
||||
} = this.props;
|
||||
|
||||
@@ -137,6 +137,7 @@ const ScrollView = createReactClass({
|
||||
keyboardDismissMode,
|
||||
onScroll,
|
||||
pagingEnabled,
|
||||
stickyHeaderIndices,
|
||||
/* eslint-enable */
|
||||
...other
|
||||
} = this.props;
|
||||
|
||||
@@ -1,84 +0,0 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`components/Switch disabled when "false" a default checkbox is rendered 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-cursor-1loqt21 rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-userSelect-lrvibr"
|
||||
style="height:20px;width:40px;"
|
||||
>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-bottom-1p0dtai rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-height-1dernwh rn-left-1d2f490 rn-marginTop-1t01tom rn-marginRight-lchren rn-marginBottom-1qahzrx rn-marginLeft-1jj8364 rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-transitionDuration-13tjlyg rn-width-13qz1uu"
|
||||
style="background-color:rgba(147,147,147,1);border-top-left-radius:10px;border-top-right-radius:10px;border-bottom-right-radius:10px;border-bottom-left-radius:10px;"
|
||||
/>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-alignSelf-k200y rn-borderTopLeftRadius-jt3ufn rn-borderTopRightRadius-1e868j9 rn-borderBottomRightRadius-ujv9e3 rn-borderBottomLeftRadius-1hakmuk rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxShadow-1ewcgjf rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-left-1fe0xdi rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-transform-emqnss rn-transitionDuration-13tjlyg"
|
||||
style="background-color:rgba(250,250,250,1);height:20px;width:20px;"
|
||||
/>
|
||||
<input
|
||||
class="rn-bottom-1p0dtai rn-cursor-1ei5mc7 rn-height-1pi2tsx rn-left-1d2f490 rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-opacity-1272l3b rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-width-13qz1uu"
|
||||
type="checkbox"
|
||||
/>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`components/Switch disabled when "true" a disabled checkbox is rendered 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-cursor-7q8q6z rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-userSelect-lrvibr"
|
||||
style="height:20px;width:40px;"
|
||||
>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-backgroundColor-1hj8efq rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-bottom-1p0dtai rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-height-1dernwh rn-left-1d2f490 rn-marginTop-1t01tom rn-marginRight-lchren rn-marginBottom-1qahzrx rn-marginLeft-1jj8364 rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-transitionDuration-13tjlyg rn-width-13qz1uu"
|
||||
style="border-top-left-radius:10px;border-top-right-radius:10px;border-bottom-right-radius:10px;border-bottom-left-radius:10px;"
|
||||
/>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-alignSelf-k200y rn-backgroundColor-1bgzomc rn-borderTopLeftRadius-jt3ufn rn-borderTopRightRadius-1e868j9 rn-borderBottomRightRadius-ujv9e3 rn-borderBottomLeftRadius-1hakmuk rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxShadow-1ewcgjf rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-left-1fe0xdi rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-transform-emqnss rn-transitionDuration-13tjlyg"
|
||||
style="height:20px;width:20px;"
|
||||
/>
|
||||
<input
|
||||
aria-disabled="true"
|
||||
class="rn-bottom-1p0dtai rn-cursor-1ei5mc7 rn-height-1pi2tsx rn-left-1d2f490 rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-opacity-1272l3b rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-width-13qz1uu"
|
||||
disabled=""
|
||||
type="checkbox"
|
||||
/>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`components/Switch value when "false" an unchecked checkbox is rendered 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-cursor-1loqt21 rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-userSelect-lrvibr"
|
||||
style="height:20px;width:40px;"
|
||||
>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-bottom-1p0dtai rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-height-1dernwh rn-left-1d2f490 rn-marginTop-1t01tom rn-marginRight-lchren rn-marginBottom-1qahzrx rn-marginLeft-1jj8364 rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-transitionDuration-13tjlyg rn-width-13qz1uu"
|
||||
style="background-color:rgba(147,147,147,1);border-top-left-radius:10px;border-top-right-radius:10px;border-bottom-right-radius:10px;border-bottom-left-radius:10px;"
|
||||
/>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-alignSelf-k200y rn-borderTopLeftRadius-jt3ufn rn-borderTopRightRadius-1e868j9 rn-borderBottomRightRadius-ujv9e3 rn-borderBottomLeftRadius-1hakmuk rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxShadow-1ewcgjf rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-left-1fe0xdi rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-transform-emqnss rn-transitionDuration-13tjlyg"
|
||||
style="background-color:rgba(250,250,250,1);height:20px;width:20px;"
|
||||
/>
|
||||
<input
|
||||
class="rn-bottom-1p0dtai rn-cursor-1ei5mc7 rn-height-1pi2tsx rn-left-1d2f490 rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-opacity-1272l3b rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-width-13qz1uu"
|
||||
type="checkbox"
|
||||
/>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`components/Switch value when "true" a checked checkbox is rendered 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-cursor-1loqt21 rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-userSelect-lrvibr"
|
||||
style="height:20px;width:40px;"
|
||||
>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-bottom-1p0dtai rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-height-1dernwh rn-left-1d2f490 rn-marginTop-1t01tom rn-marginRight-lchren rn-marginBottom-1qahzrx rn-marginLeft-1jj8364 rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-transitionDuration-13tjlyg rn-width-13qz1uu"
|
||||
style="background-color:rgba(163,211,207,1);border-top-left-radius:10px;border-top-right-radius:10px;border-bottom-right-radius:10px;border-bottom-left-radius:10px;"
|
||||
/>
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-alignSelf-k200y rn-borderTopLeftRadius-jt3ufn rn-borderTopRightRadius-1e868j9 rn-borderBottomRightRadius-ujv9e3 rn-borderBottomLeftRadius-1hakmuk rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxShadow-1ewcgjf rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-left-7b7h2f rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-transform-emqnss rn-transitionDuration-13tjlyg"
|
||||
style="background-color:rgba(0,150,136,1);height:20px;margin-left:-20px;width:20px;"
|
||||
/>
|
||||
<input
|
||||
checked=""
|
||||
class="rn-bottom-1p0dtai rn-cursor-1ei5mc7 rn-height-1pi2tsx rn-left-1d2f490 rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-opacity-1272l3b rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-u8s1d rn-right-zchlnj rn-top-ipm5af rn-width-13qz1uu"
|
||||
type="checkbox"
|
||||
/>
|
||||
</div>
|
||||
`;
|
||||
@@ -1,19 +1,21 @@
|
||||
/* eslint-env jasmine, jest */
|
||||
|
||||
import React from 'react';
|
||||
import { render } from 'enzyme';
|
||||
import { shallow } from 'enzyme';
|
||||
import Switch from '..';
|
||||
|
||||
const checkboxSelector = 'input[type="checkbox"]';
|
||||
|
||||
describe('components/Switch', () => {
|
||||
describe('disabled', () => {
|
||||
test('when "false" a default checkbox is rendered', () => {
|
||||
const component = render(<Switch />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Switch />);
|
||||
expect(component.find(checkboxSelector).prop('disabled')).toBe(false);
|
||||
});
|
||||
|
||||
test('when "true" a disabled checkbox is rendered', () => {
|
||||
const component = render(<Switch disabled />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Switch disabled />);
|
||||
expect(component.find(checkboxSelector).prop('disabled')).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
@@ -35,13 +37,13 @@ describe('components/Switch', () => {
|
||||
|
||||
describe('value', () => {
|
||||
test('when "false" an unchecked checkbox is rendered', () => {
|
||||
const component = render(<Switch value={false} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Switch value={false} />);
|
||||
expect(component.find(checkboxSelector).prop('checked')).toBe(false);
|
||||
});
|
||||
|
||||
test('when "true" a checked checkbox is rendered', () => {
|
||||
const component = render(<Switch value />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<Switch value />);
|
||||
expect(component.find(checkboxSelector).prop('checked')).toBe(true);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
@@ -17,7 +17,7 @@ import { any, bool, func, number, oneOf } from 'prop-types';
|
||||
|
||||
const TextPropTypes = {
|
||||
...BaseComponentPropTypes,
|
||||
accessibilityRole: oneOf(['button', 'heading', 'link', 'listitem']),
|
||||
accessibilityRole: oneOf(['button', 'heading', 'label', 'link', 'listitem']),
|
||||
children: any,
|
||||
numberOfLines: number,
|
||||
onLayout: func,
|
||||
|
||||
@@ -366,12 +366,12 @@ describe('components/TextInput', () => {
|
||||
);
|
||||
|
||||
// default selection is 0
|
||||
expect(inputDefaultSelection.node.selectionStart).toEqual(0);
|
||||
expect(inputDefaultSelection.node.selectionEnd).toEqual(0);
|
||||
expect(inputDefaultSelection.instance().selectionStart).toEqual(0);
|
||||
expect(inputDefaultSelection.instance().selectionEnd).toEqual(0);
|
||||
|
||||
// custom selection sets cursor at custom position
|
||||
expect(inputCustomSelection.node.selectionStart).toEqual(cursorLocation.start);
|
||||
expect(inputCustomSelection.node.selectionEnd).toEqual(cursorLocation.end);
|
||||
expect(inputCustomSelection.instance().selectionStart).toEqual(cursorLocation.start);
|
||||
expect(inputCustomSelection.instance().selectionEnd).toEqual(cursorLocation.end);
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
@@ -12,6 +12,7 @@
|
||||
* @flow
|
||||
*/
|
||||
|
||||
import AccessibilityUtil from '../../modules/AccessibilityUtil';
|
||||
import BoundingDimensions from './BoundingDimensions';
|
||||
import findNodeHandle from '../../modules/findNodeHandle';
|
||||
import normalizeColor from 'normalize-css-color';
|
||||
@@ -819,7 +820,11 @@ const TouchableMixin = {
|
||||
}
|
||||
}
|
||||
e.stopPropagation();
|
||||
e.preventDefault();
|
||||
// prevent the default behaviour unless the Touchable functions as a link
|
||||
// and Enter is pressed
|
||||
if (!(which === ENTER && AccessibilityUtil.propsToAriaRole(this.props) === 'link')) {
|
||||
e.preventDefault();
|
||||
}
|
||||
}
|
||||
}
|
||||
};
|
||||
|
||||
@@ -19,7 +19,7 @@ import StyleSheet from '../../apis/StyleSheet';
|
||||
import TimerMixin from 'react-timer-mixin';
|
||||
import Touchable from './Touchable';
|
||||
import warning from 'fbjs/lib/warning';
|
||||
import { bool, element, func, number, string } from 'prop-types';
|
||||
import { bool, func, number, string } from 'prop-types';
|
||||
|
||||
type Event = Object;
|
||||
|
||||
@@ -33,7 +33,7 @@ const PRESS_RETENTION_OFFSET = { top: 20, left: 20, right: 20, bottom: 30 };
|
||||
* If you wish to have several child components, wrap them in a View.
|
||||
*/
|
||||
|
||||
/* eslint-disable react/prefer-es6-class */
|
||||
/* eslint-disable react/prefer-es6-class, react/prop-types */
|
||||
const TouchableWithoutFeedback = createReactClass({
|
||||
displayName: 'TouchableWithoutFeedback',
|
||||
mixins: [TimerMixin, Touchable.Mixin],
|
||||
@@ -44,7 +44,6 @@ const TouchableWithoutFeedback = createReactClass({
|
||||
accessibilityRole: BaseComponentPropTypes.accessibilityRole,
|
||||
accessibilityTraits: BaseComponentPropTypes.accessibilityTraits,
|
||||
accessible: bool,
|
||||
children: element,
|
||||
/**
|
||||
* Delay in ms, from onPressIn, before onLongPress is called.
|
||||
*/
|
||||
@@ -161,6 +160,7 @@ const TouchableWithoutFeedback = createReactClass({
|
||||
} = this.props;
|
||||
|
||||
// Note(avik): remove dynamic typecast once Flow has been upgraded
|
||||
// $FlowFixMe
|
||||
const child = React.Children.only(this.props.children);
|
||||
let children = child.props.children;
|
||||
warning(
|
||||
|
||||
@@ -11,18 +11,13 @@
|
||||
*/
|
||||
|
||||
import View from '../View';
|
||||
import { any, object } from 'prop-types';
|
||||
import React, { Component } from 'react';
|
||||
|
||||
/**
|
||||
* Common implementation for a simple stubbed view.
|
||||
*/
|
||||
/* eslint-disable react/prop-types */
|
||||
class UnimplementedView extends Component {
|
||||
static propTypes = {
|
||||
children: any,
|
||||
style: object
|
||||
};
|
||||
|
||||
setNativeProps() {
|
||||
// Do nothing.
|
||||
// This method is required in order to use this view as a Touchable* child.
|
||||
|
||||
@@ -1,29 +1,16 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`components/View prop "hitSlop" handles partial offsets 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
>
|
||||
<span
|
||||
class="rn-bottom-1p0dtai rn-left-1d2f490 rn-position-u8s1d rn-right-zchlnj rn-zIndex-1wyyakw"
|
||||
style="top:-10px;"
|
||||
/>
|
||||
</div>
|
||||
Object {
|
||||
"top": "-10px",
|
||||
}
|
||||
`;
|
||||
|
||||
exports[`components/View prop "hitSlop" renders a span with negative position offsets 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-position-bnwqim rn-zIndex-1lgpqti"
|
||||
>
|
||||
<span
|
||||
class="rn-position-u8s1d rn-zIndex-1wyyakw"
|
||||
style="bottom:-10px;left:-5px;right:-5px;top:-10px;"
|
||||
/>
|
||||
</div>
|
||||
`;
|
||||
|
||||
exports[`components/View prop "pointerEvents" 1`] = `
|
||||
<div
|
||||
class="rn-alignItems-1oszu61 rn-borderTopStyle-1efd50x rn-borderRightStyle-14skgim rn-borderBottomStyle-rull8r rn-borderLeftStyle-mm0ijv rn-borderTopWidth-13yce4e rn-borderRightWidth-fnigne rn-borderBottomWidth-ndvcnb rn-borderLeftWidth-gxnn5r rn-boxSizing-deolkf rn-display-6koalj rn-flexShrink-1qe8dj5 rn-flexBasis-1mlwlqe rn-flexDirection-eqz5dr rn-marginTop-1mnahxq rn-marginRight-61z16t rn-marginBottom-p1pxzi rn-marginLeft-11wrixw rn-minHeight-ifefl9 rn-minWidth-bcqeeo rn-paddingTop-wk8lta rn-paddingRight-9aemit rn-paddingBottom-1mdbw0j rn-paddingLeft-gy4na3 rn-pointerEvents-ah5dr5 rn-position-bnwqim"
|
||||
/>
|
||||
Object {
|
||||
"bottom": "-10px",
|
||||
"left": "-5px",
|
||||
"right": "-5px",
|
||||
"top": "-10px",
|
||||
}
|
||||
`;
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
/* eslint-env jasmine, jest */
|
||||
|
||||
import React from 'react';
|
||||
import { render, shallow } from 'enzyme';
|
||||
import { shallow } from 'enzyme';
|
||||
import View from '../';
|
||||
|
||||
describe('components/View', () => {
|
||||
@@ -12,26 +12,48 @@ describe('components/View', () => {
|
||||
});
|
||||
});
|
||||
|
||||
test('prop "children"', () => {
|
||||
const children = <View testID="1" />;
|
||||
const component = shallow(<View>{children}</View>);
|
||||
expect(component.contains(children)).toEqual(true);
|
||||
describe('prop "children"', () => {
|
||||
test('text node throws error (single)', () => {
|
||||
const render = () => shallow(<View>'hello'</View>);
|
||||
expect(render).toThrow();
|
||||
});
|
||||
|
||||
test('text node throws error (array)', () => {
|
||||
const render = () =>
|
||||
shallow(
|
||||
<View>
|
||||
<View />
|
||||
'hello'
|
||||
<View />
|
||||
</View>
|
||||
);
|
||||
expect(render).toThrow();
|
||||
});
|
||||
|
||||
test('non-text is rendered', () => {
|
||||
const children = <View testID="1" />;
|
||||
const component = shallow(<View>{children}</View>);
|
||||
expect(component.contains(children)).toEqual(true);
|
||||
});
|
||||
});
|
||||
|
||||
describe('prop "hitSlop"', () => {
|
||||
it('renders a span with negative position offsets', () => {
|
||||
const component = render(<View hitSlop={{ top: 10, bottom: 10, right: 5, left: 5 }} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<View hitSlop={{ top: 10, bottom: 10, right: 5, left: 5 }} />);
|
||||
const span = component.find('span');
|
||||
expect(span.length).toBe(1);
|
||||
expect(span.prop('style')).toMatchSnapshot();
|
||||
});
|
||||
|
||||
it('handles partial offsets', () => {
|
||||
const component = render(<View hitSlop={{ top: 10 }} />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<View hitSlop={{ top: 10 }} />);
|
||||
const span = component.find('span');
|
||||
expect(span.prop('style')).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
|
||||
test('prop "pointerEvents"', () => {
|
||||
const component = render(<View pointerEvents="box-only" />);
|
||||
expect(component).toMatchSnapshot();
|
||||
const component = shallow(<View pointerEvents="box-only" />);
|
||||
expect(component.prop('className').indexOf('pointerEvents') > -1).toBe(true);
|
||||
});
|
||||
});
|
||||
|
||||
@@ -11,6 +11,7 @@ import applyLayout from '../../modules/applyLayout';
|
||||
import applyNativeMethods from '../../modules/applyNativeMethods';
|
||||
import { bool } from 'prop-types';
|
||||
import createElement from '../../modules/createElement';
|
||||
import invariant from 'fbjs/lib/invariant';
|
||||
import StyleSheet from '../../apis/StyleSheet';
|
||||
import ViewPropTypes from './ViewPropTypes';
|
||||
import React, { Component } from 'react';
|
||||
@@ -49,6 +50,15 @@ class View extends Component {
|
||||
...otherProps
|
||||
} = this.props;
|
||||
|
||||
if (process.env.NODE_ENV !== 'production') {
|
||||
React.Children.toArray(this.props.children).forEach(item => {
|
||||
invariant(
|
||||
typeof item !== 'string',
|
||||
`Unexpected text node: ${item}. A text node cannot be a child of a <View>.`
|
||||
);
|
||||
});
|
||||
}
|
||||
|
||||
const { isInAParentText } = this.context;
|
||||
|
||||
otherProps.style = [styles.initial, isInAParentText && styles.inline, style];
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
import {
|
||||
// top-level API
|
||||
findNodeHandle,
|
||||
hydrate,
|
||||
render,
|
||||
unmountComponentAtNode,
|
||||
|
||||
@@ -67,6 +68,7 @@ import {
|
||||
const ReactNative = {
|
||||
// top-level API
|
||||
findNodeHandle,
|
||||
hydrate,
|
||||
render,
|
||||
unmountComponentAtNode,
|
||||
|
||||
|
||||
@@ -2,7 +2,7 @@ export { default as createElement } from './modules/createElement';
|
||||
export { default as findNodeHandle } from './modules/findNodeHandle';
|
||||
export { default as NativeModules } from './modules/NativeModules';
|
||||
export { default as processColor } from './modules/processColor';
|
||||
export { render, unmountComponentAtNode } from 'react-dom';
|
||||
export { hydrate, render, unmountComponentAtNode } from 'react-dom';
|
||||
|
||||
// APIs
|
||||
export { default as Animated } from './apis/Animated';
|
||||
@@ -12,7 +12,7 @@ export { default as AsyncStorage } from './apis/AsyncStorage';
|
||||
export { default as BackAndroid } from './apis/BackAndroid';
|
||||
export { default as Clipboard } from './apis/Clipboard';
|
||||
export { default as Dimensions } from './apis/Dimensions';
|
||||
export { default as Easing } from 'animated/lib/Easing';
|
||||
export { default as Easing } from './apis/Easing';
|
||||
export { default as I18nManager } from './apis/I18nManager';
|
||||
export { default as Keyboard } from './apis/Keyboard';
|
||||
export { default as InteractionManager } from './apis/InteractionManager';
|
||||
|
||||
@@ -4,6 +4,9 @@ exports[`modules/createElement it normalizes event.nativeEvent 1`] = `
|
||||
Object {
|
||||
"_normalized": true,
|
||||
"changedTouches": Array [],
|
||||
"identifier": undefined,
|
||||
"locationX": undefined,
|
||||
"locationY": undefined,
|
||||
"pageX": undefined,
|
||||
"pageY": undefined,
|
||||
"preventDefault": [Function],
|
||||
|
||||
@@ -19,11 +19,7 @@ describe('modules/createElement', () => {
|
||||
};
|
||||
const component = shallow(createElement('span', { onClick }));
|
||||
component.find('span').simulate('click', {
|
||||
nativeEvent: {
|
||||
preventDefault() {},
|
||||
stopImmediatePropagation() {},
|
||||
stopPropagation() {}
|
||||
}
|
||||
nativeEvent: {}
|
||||
});
|
||||
});
|
||||
|
||||
@@ -38,11 +34,7 @@ describe('modules/createElement', () => {
|
||||
);
|
||||
component.find('span').simulate('keyPress', {
|
||||
isDefaultPrevented() {},
|
||||
nativeEvent: {
|
||||
preventDefault() {},
|
||||
stopImmediatePropagation() {},
|
||||
stopPropagation() {}
|
||||
},
|
||||
nativeEvent: {},
|
||||
preventDefault() {},
|
||||
which
|
||||
});
|
||||
|
||||
@@ -1,9 +1,11 @@
|
||||
// based on https://github.com/facebook/react/pull/4303/files
|
||||
|
||||
import EventPluginHub from 'react-dom/lib/EventPluginHub';
|
||||
import normalizeNativeEvent from '../normalizeNativeEvent';
|
||||
import ResponderEventPlugin from 'react-dom/lib/ResponderEventPlugin';
|
||||
import ResponderTouchHistoryStore from 'react-dom/lib/ResponderTouchHistoryStore';
|
||||
import ReactDOM from 'react-dom';
|
||||
import ReactDOMUnstableNativeDependencies from 'react-dom/unstable-native-dependencies';
|
||||
|
||||
const { EventPluginHub } = ReactDOM.__SECRET_INTERNALS_DO_NOT_USE_OR_YOU_WILL_BE_FIRED;
|
||||
const { ResponderEventPlugin, ResponderTouchHistoryStore } = ReactDOMUnstableNativeDependencies;
|
||||
|
||||
const topMouseDown = 'topMouseDown';
|
||||
const topMouseMove = 'topMouseMove';
|
||||
|
||||
@@ -0,0 +1,124 @@
|
||||
// Jest Snapshot v1, https://goo.gl/fbAQLP
|
||||
|
||||
exports[`modules/normalizeNativeEvent mouse events simulated event 1`] = `
|
||||
Object {
|
||||
"_normalized": true,
|
||||
"changedTouches": Array [
|
||||
Object {
|
||||
"_normalized": true,
|
||||
"clientX": undefined,
|
||||
"clientY": undefined,
|
||||
"force": undefined,
|
||||
"identifier": 0,
|
||||
"locationX": undefined,
|
||||
"locationY": undefined,
|
||||
"pageX": undefined,
|
||||
"pageY": undefined,
|
||||
"screenX": undefined,
|
||||
"screenY": undefined,
|
||||
"target": undefined,
|
||||
"timestamp": 1496876171255,
|
||||
},
|
||||
],
|
||||
"identifier": 0,
|
||||
"locationX": undefined,
|
||||
"locationY": undefined,
|
||||
"pageX": undefined,
|
||||
"pageY": undefined,
|
||||
"preventDefault": [Function],
|
||||
"stopImmediatePropagation": [Function],
|
||||
"stopPropagation": [Function],
|
||||
"target": undefined,
|
||||
"timestamp": 1496876171255,
|
||||
"touches": Array [],
|
||||
}
|
||||
`;
|
||||
|
||||
exports[`modules/normalizeNativeEvent mouse events synthetic event 1`] = `
|
||||
Object {
|
||||
"_normalized": true,
|
||||
"changedTouches": Array [
|
||||
Object {
|
||||
"_normalized": true,
|
||||
"clientX": 100,
|
||||
"clientY": 100,
|
||||
"force": false,
|
||||
"identifier": 0,
|
||||
"locationX": 100,
|
||||
"locationY": 100,
|
||||
"pageX": 300,
|
||||
"pageY": 300,
|
||||
"screenX": 400,
|
||||
"screenY": 400,
|
||||
"target": undefined,
|
||||
"timestamp": 1496876171255,
|
||||
},
|
||||
],
|
||||
"identifier": 0,
|
||||
"locationX": 200,
|
||||
"locationY": 200,
|
||||
"pageX": 300,
|
||||
"pageY": 300,
|
||||
"preventDefault": [Function],
|
||||
"stopImmediatePropagation": [Function],
|
||||
"stopPropagation": [Function],
|
||||
"target": undefined,
|
||||
"timestamp": 1496876171255,
|
||||
"touches": Array [],
|
||||
}
|
||||
`;
|
||||
|
||||
exports[`modules/normalizeNativeEvent touch events simulated event 1`] = `
|
||||
Object {
|
||||
"_normalized": true,
|
||||
"changedTouches": Array [],
|
||||
"identifier": undefined,
|
||||
"locationX": undefined,
|
||||
"locationY": undefined,
|
||||
"pageX": undefined,
|
||||
"pageY": undefined,
|
||||
"preventDefault": [Function],
|
||||
"stopImmediatePropagation": [Function],
|
||||
"stopPropagation": [Function],
|
||||
"target": undefined,
|
||||
"timestamp": 1496876171255,
|
||||
"touches": Array [],
|
||||
}
|
||||
`;
|
||||
|
||||
exports[`modules/normalizeNativeEvent touch events synthetic event 1`] = `
|
||||
Object {
|
||||
"_normalized": true,
|
||||
"changedTouches": Array [
|
||||
Object {
|
||||
"_normalized": true,
|
||||
"clientX": 100,
|
||||
"clientY": 100,
|
||||
"force": false,
|
||||
"identifier": undefined,
|
||||
"locationX": undefined,
|
||||
"locationY": undefined,
|
||||
"pageX": 300,
|
||||
"pageY": 300,
|
||||
"radiusX": 10,
|
||||
"radiusY": 10,
|
||||
"rotationAngle": 45,
|
||||
"screenX": 400,
|
||||
"screenY": 400,
|
||||
"target": undefined,
|
||||
"timestamp": 1496876171255,
|
||||
},
|
||||
],
|
||||
"identifier": undefined,
|
||||
"locationX": undefined,
|
||||
"locationY": undefined,
|
||||
"pageX": 300,
|
||||
"pageY": 300,
|
||||
"preventDefault": [Function],
|
||||
"stopImmediatePropagation": [Function],
|
||||
"stopPropagation": [Function],
|
||||
"target": undefined,
|
||||
"timestamp": 1496876171255,
|
||||
"touches": Array [],
|
||||
}
|
||||
`;
|
||||
82
src/modules/normalizeNativeEvent/__tests__/index-test.js
Normal file
82
src/modules/normalizeNativeEvent/__tests__/index-test.js
Normal file
@@ -0,0 +1,82 @@
|
||||
/* eslint-env jasmine, jest */
|
||||
|
||||
import normalizeNativeEvent from '..';
|
||||
|
||||
const normalizeEvent = nativeEvent => {
|
||||
const result = normalizeNativeEvent(nativeEvent);
|
||||
result.timestamp = 1496876171255;
|
||||
if (result.changedTouches && result.changedTouches[0]) {
|
||||
result.changedTouches[0].timestamp = 1496876171255;
|
||||
}
|
||||
if (result.touches && result.touches[0]) {
|
||||
result.touches[0].timestamp = 1496876171255;
|
||||
}
|
||||
return result;
|
||||
};
|
||||
|
||||
describe('modules/normalizeNativeEvent', () => {
|
||||
describe('mouse events', () => {
|
||||
test('simulated event', () => {
|
||||
const nativeEvent = {
|
||||
type: 'mouseup'
|
||||
};
|
||||
|
||||
const result = normalizeEvent(nativeEvent);
|
||||
expect(result).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('synthetic event', () => {
|
||||
const nativeEvent = {
|
||||
type: 'mouseup',
|
||||
clientX: 100,
|
||||
clientY: 100,
|
||||
force: false,
|
||||
offsetX: 200,
|
||||
offsetY: 200,
|
||||
pageX: 300,
|
||||
pageY: 300,
|
||||
screenX: 400,
|
||||
screenY: 400
|
||||
};
|
||||
|
||||
const result = normalizeEvent(nativeEvent);
|
||||
expect(result).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
|
||||
describe('touch events', () => {
|
||||
test('simulated event', () => {
|
||||
const nativeEvent = {
|
||||
type: 'touchstart'
|
||||
};
|
||||
|
||||
const result = normalizeEvent(nativeEvent);
|
||||
expect(result).toMatchSnapshot();
|
||||
});
|
||||
|
||||
test('synthetic event', () => {
|
||||
const nativeEvent = {
|
||||
type: 'touchstart',
|
||||
changedTouches: [
|
||||
{
|
||||
clientX: 100,
|
||||
clientY: 100,
|
||||
force: false,
|
||||
pageX: 300,
|
||||
pageY: 300,
|
||||
radiusX: 10,
|
||||
radiusY: 10,
|
||||
rotationAngle: 45,
|
||||
screenX: 400,
|
||||
screenY: 400
|
||||
}
|
||||
],
|
||||
pageX: 300,
|
||||
pageY: 300
|
||||
};
|
||||
|
||||
const result = normalizeEvent(nativeEvent);
|
||||
expect(result).toMatchSnapshot();
|
||||
});
|
||||
});
|
||||
});
|
||||
@@ -5,19 +5,31 @@
|
||||
* This source code is licensed under the BSD-style license found in the
|
||||
* LICENSE file in the root directory of this source tree.
|
||||
*
|
||||
* @noflow
|
||||
* @flow
|
||||
*/
|
||||
|
||||
const emptyArray = [];
|
||||
const emptyFunction = () => {};
|
||||
|
||||
// Mobile Safari re-uses touch objects, so we copy the properties we want and normalize the identifier
|
||||
const normalizeTouches = (touches = emptyArray) =>
|
||||
Array.prototype.slice.call(touches).map(touch => {
|
||||
const identifier = touch.identifier > 20 ? touch.identifier % 20 : touch.identifier;
|
||||
const normalizeTouches = touches => {
|
||||
if (!touches) {
|
||||
return emptyArray;
|
||||
}
|
||||
|
||||
const rect = touch.target && touch.target.getBoundingClientRect();
|
||||
const locationX = touch.pageX - rect.left;
|
||||
const locationY = touch.pageY - rect.top;
|
||||
return Array.prototype.slice.call(touches).map(touch => {
|
||||
const identifier = touch.identifier > 20 ? touch.identifier % 20 : touch.identifier;
|
||||
let locationX, locationY;
|
||||
|
||||
const node = touch.target;
|
||||
if (node) {
|
||||
const isElement = node.nodeType === 1 /* Node.ELEMENT_NODE */;
|
||||
if (isElement && typeof node.getBoundingClientRect === 'function') {
|
||||
const rect = node.getBoundingClientRect();
|
||||
locationX = touch.pageX - rect.left;
|
||||
locationY = touch.pageY - rect.top;
|
||||
}
|
||||
}
|
||||
|
||||
return {
|
||||
_normalized: true,
|
||||
@@ -40,19 +52,36 @@ const normalizeTouches = (touches = emptyArray) =>
|
||||
timestamp: Date.now()
|
||||
};
|
||||
});
|
||||
};
|
||||
|
||||
function normalizeTouchEvent(nativeEvent) {
|
||||
const changedTouches = normalizeTouches(nativeEvent.changedTouches);
|
||||
const touches = normalizeTouches(nativeEvent.touches);
|
||||
|
||||
const preventDefault =
|
||||
typeof nativeEvent.preventDefault === 'function'
|
||||
? nativeEvent.preventDefault.bind(nativeEvent)
|
||||
: emptyFunction;
|
||||
const stopImmediatePropagation =
|
||||
typeof nativeEvent.stopImmediatePropagation === 'function'
|
||||
? nativeEvent.stopImmediatePropagation.bind(nativeEvent)
|
||||
: emptyFunction;
|
||||
const stopPropagation =
|
||||
typeof nativeEvent.stopPropagation === 'function'
|
||||
? nativeEvent.stopPropagation.bind(nativeEvent)
|
||||
: emptyFunction;
|
||||
|
||||
const event = {
|
||||
_normalized: true,
|
||||
changedTouches,
|
||||
identifier: undefined,
|
||||
locationX: undefined,
|
||||
locationY: undefined,
|
||||
pageX: nativeEvent.pageX,
|
||||
pageY: nativeEvent.pageY,
|
||||
preventDefault: nativeEvent.preventDefault.bind(nativeEvent),
|
||||
stopImmediatePropagation: nativeEvent.stopImmediatePropagation.bind(nativeEvent),
|
||||
stopPropagation: nativeEvent.stopPropagation.bind(nativeEvent),
|
||||
preventDefault,
|
||||
stopImmediatePropagation,
|
||||
stopPropagation,
|
||||
target: nativeEvent.target,
|
||||
// normalize the timestamp
|
||||
// https://stackoverflow.com/questions/26177087/ios-8-mobile-safari-wrong-timestamp-on-touch-events
|
||||
@@ -89,6 +118,20 @@ function normalizeMouseEvent(nativeEvent) {
|
||||
timestamp: Date.now()
|
||||
}
|
||||
];
|
||||
|
||||
const preventDefault =
|
||||
typeof nativeEvent.preventDefault === 'function'
|
||||
? nativeEvent.preventDefault.bind(nativeEvent)
|
||||
: emptyFunction;
|
||||
const stopImmediatePropagation =
|
||||
typeof nativeEvent.stopImmediatePropagation === 'function'
|
||||
? nativeEvent.stopImmediatePropagation.bind(nativeEvent)
|
||||
: emptyFunction;
|
||||
const stopPropagation =
|
||||
typeof nativeEvent.stopPropagation === 'function'
|
||||
? nativeEvent.stopPropagation.bind(nativeEvent)
|
||||
: emptyFunction;
|
||||
|
||||
return {
|
||||
_normalized: true,
|
||||
changedTouches: touches,
|
||||
@@ -97,22 +140,27 @@ function normalizeMouseEvent(nativeEvent) {
|
||||
locationY: nativeEvent.offsetY,
|
||||
pageX: nativeEvent.pageX,
|
||||
pageY: nativeEvent.pageY,
|
||||
preventDefault: nativeEvent.preventDefault.bind(nativeEvent),
|
||||
stopImmediatePropagation: nativeEvent.stopImmediatePropagation.bind(nativeEvent),
|
||||
stopPropagation: nativeEvent.stopPropagation.bind(nativeEvent),
|
||||
preventDefault,
|
||||
stopImmediatePropagation,
|
||||
stopPropagation,
|
||||
target: nativeEvent.target,
|
||||
timestamp: touches[0].timestamp,
|
||||
touches: nativeEvent.type === 'mouseup' ? emptyArray : touches
|
||||
};
|
||||
}
|
||||
|
||||
function normalizeNativeEvent(nativeEvent) {
|
||||
if (nativeEvent._normalized) {
|
||||
// TODO: how to best handle keyboard events?
|
||||
function normalizeNativeEvent(nativeEvent: Object) {
|
||||
if (!nativeEvent || nativeEvent._normalized) {
|
||||
return nativeEvent;
|
||||
}
|
||||
const eventType = nativeEvent.type || '';
|
||||
const mouse = eventType.indexOf('mouse') >= 0;
|
||||
return mouse ? normalizeMouseEvent(nativeEvent) : normalizeTouchEvent(nativeEvent);
|
||||
if (mouse) {
|
||||
return normalizeMouseEvent(nativeEvent);
|
||||
} else {
|
||||
return normalizeTouchEvent(nativeEvent);
|
||||
}
|
||||
}
|
||||
|
||||
export default normalizeNativeEvent;
|
||||
|
||||
@@ -2,6 +2,7 @@ import crossFade from 'inline-style-prefixer/static/plugins/crossFade';
|
||||
import cursor from 'inline-style-prefixer/static/plugins/cursor';
|
||||
import filter from 'inline-style-prefixer/static/plugins/filter';
|
||||
import flex from 'inline-style-prefixer/static/plugins/flex';
|
||||
import flexboxIE from 'inline-style-prefixer/static/plugins/flexboxIE';
|
||||
import flexboxOld from 'inline-style-prefixer/static/plugins/flexboxOld';
|
||||
import gradient from 'inline-style-prefixer/static/plugins/gradient';
|
||||
import imageSet from 'inline-style-prefixer/static/plugins/imageSet';
|
||||
@@ -21,6 +22,7 @@ export default {
|
||||
cursor,
|
||||
filter,
|
||||
flex,
|
||||
flexboxIE,
|
||||
flexboxOld,
|
||||
gradient,
|
||||
imageSet,
|
||||
@@ -82,13 +84,13 @@ export default {
|
||||
columns: wm,
|
||||
columnSpan: wm,
|
||||
columnWidth: wm,
|
||||
flex: w,
|
||||
flex: wms,
|
||||
flexBasis: w,
|
||||
flexDirection: w,
|
||||
flexDirection: wms,
|
||||
flexGrow: w,
|
||||
flexFlow: w,
|
||||
flexFlow: wms,
|
||||
flexShrink: w,
|
||||
flexWrap: w,
|
||||
flexWrap: wms,
|
||||
alignContent: w,
|
||||
alignItems: w,
|
||||
alignSelf: w,
|
||||
@@ -122,6 +124,7 @@ export default {
|
||||
wrapFlow: ms,
|
||||
wrapThrough: ms,
|
||||
wrapMargin: ms,
|
||||
touchAction: ms,
|
||||
gridTemplateColumns: ms,
|
||||
gridTemplateRows: ms,
|
||||
gridTemplateAreas: ms,
|
||||
|
||||
@@ -10,6 +10,9 @@
|
||||
* @flow
|
||||
*/
|
||||
|
||||
const isWebColor = (color: string) =>
|
||||
color === 'currentcolor' || color === 'inherit' || color.indexOf('var(') === 0;
|
||||
|
||||
const colorPropType = function(isRequired, props, propName, componentName, location, propFullName) {
|
||||
const normalizeColor = require('normalize-css-color');
|
||||
const color = props[propName];
|
||||
@@ -35,8 +38,8 @@ const colorPropType = function(isRequired, props, propName, componentName, locat
|
||||
return;
|
||||
}
|
||||
|
||||
// Web supports additional color keywords and custom property values
|
||||
if (color === 'currentcolor' || color === 'inherit' || color.indexOf('var(') === 0) {
|
||||
if (typeof color === 'string' && isWebColor(color)) {
|
||||
// Web supports additional color keywords and custom property values. Ignore them.
|
||||
return;
|
||||
}
|
||||
|
||||
|
||||
2
src/vendor/warnValidStyle/index.js
vendored
2
src/vendor/warnValidStyle/index.js
vendored
@@ -11,8 +11,6 @@
|
||||
* @providesModule warnValidStyle
|
||||
*/
|
||||
|
||||
'use strict';
|
||||
|
||||
var emptyFunction = require('fbjs/lib/emptyFunction');
|
||||
|
||||
var warnValidStyle = emptyFunction;
|
||||
|
||||
583
yarn.lock
583
yarn.lock
@@ -2,6 +2,10 @@
|
||||
# yarn lockfile v1
|
||||
|
||||
|
||||
"@types/node@^6.0.46":
|
||||
version "6.0.88"
|
||||
resolved "https://registry.yarnpkg.com/@types/node/-/node-6.0.88.tgz#f618f11a944f6a18d92b5c472028728a3e3d4b66"
|
||||
|
||||
abab@^1.0.3:
|
||||
version "1.0.3"
|
||||
resolved "https://registry.yarnpkg.com/abab/-/abab-1.0.3.tgz#b81de5f7274ec4e756d797cd834f303642724e5d"
|
||||
@@ -43,11 +47,7 @@ acorn@^4.0.3, acorn@^4.0.4:
|
||||
version "4.0.11"
|
||||
resolved "https://registry.yarnpkg.com/acorn/-/acorn-4.0.11.tgz#edcda3bd937e7556410d42ed5860f67399c794c0"
|
||||
|
||||
acorn@^5.0.0:
|
||||
version "5.0.3"
|
||||
resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.0.3.tgz#c460df08491463f028ccb82eab3730bf01087b3d"
|
||||
|
||||
acorn@^5.1.1:
|
||||
acorn@^5.0.0, acorn@^5.1.1:
|
||||
version "5.1.1"
|
||||
resolved "https://registry.yarnpkg.com/acorn/-/acorn-5.1.1.tgz#53fe161111f912ab999ee887a90a0bc52822fd75"
|
||||
|
||||
@@ -472,9 +472,9 @@ babel-plugin-jest-hoist@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/babel-plugin-jest-hoist/-/babel-plugin-jest-hoist-21.0.2.tgz#cfdce5bca40d772a056cb8528ad159c7bb4bb03d"
|
||||
|
||||
babel-plugin-react-transform@2.0.2:
|
||||
version "2.0.2"
|
||||
resolved "https://registry.yarnpkg.com/babel-plugin-react-transform/-/babel-plugin-react-transform-2.0.2.tgz#515bbfa996893981142d90b1f9b1635de2995109"
|
||||
babel-plugin-react-transform@^3.0.0:
|
||||
version "3.0.0"
|
||||
resolved "https://registry.yarnpkg.com/babel-plugin-react-transform/-/babel-plugin-react-transform-3.0.0.tgz#402f25137b7bb66e9b54ead75557dfbc7ecaaa74"
|
||||
dependencies:
|
||||
lodash "^4.6.1"
|
||||
|
||||
@@ -703,12 +703,12 @@ babel-preset-jest@^21.0.2:
|
||||
dependencies:
|
||||
babel-plugin-jest-hoist "^21.0.2"
|
||||
|
||||
babel-preset-react-native@^3.0.2:
|
||||
version "3.0.2"
|
||||
resolved "https://registry.yarnpkg.com/babel-preset-react-native/-/babel-preset-react-native-3.0.2.tgz#f9a391540caebbd5014391ac1447ef6d8c0a5b57"
|
||||
babel-preset-react-native@^4.0.0:
|
||||
version "4.0.0"
|
||||
resolved "https://registry.yarnpkg.com/babel-preset-react-native/-/babel-preset-react-native-4.0.0.tgz#3df80dd33a453888cdd33bdb87224d17a5d73959"
|
||||
dependencies:
|
||||
babel-plugin-check-es2015-constants "^6.5.0"
|
||||
babel-plugin-react-transform "2.0.2"
|
||||
babel-plugin-react-transform "^3.0.0"
|
||||
babel-plugin-syntax-async-functions "^6.5.0"
|
||||
babel-plugin-syntax-class-properties "^6.5.0"
|
||||
babel-plugin-syntax-dynamic-import "^6.18.0"
|
||||
@@ -837,9 +837,9 @@ boom@2.x.x:
|
||||
dependencies:
|
||||
hoek "2.x.x"
|
||||
|
||||
bowser@^1.6.0:
|
||||
version "1.6.0"
|
||||
resolved "https://registry.yarnpkg.com/bowser/-/bowser-1.6.0.tgz#37fc387b616cb6aef370dab4d6bd402b74c5c54d"
|
||||
bowser@^1.7.3:
|
||||
version "1.7.3"
|
||||
resolved "https://registry.yarnpkg.com/bowser/-/bowser-1.7.3.tgz#504bdb43118ca8db9cbbadf28fd60f265af96e4f"
|
||||
|
||||
boxen@^1.0.0:
|
||||
version "1.1.0"
|
||||
@@ -1049,26 +1049,16 @@ chalk@^2.0.1, chalk@^2.1.0:
|
||||
escape-string-regexp "^1.0.5"
|
||||
supports-color "^4.0.0"
|
||||
|
||||
cheerio@^0.22.0:
|
||||
version "0.22.0"
|
||||
resolved "https://registry.yarnpkg.com/cheerio/-/cheerio-0.22.0.tgz#a9baa860a3f9b595a6b81b1a86873121ed3a269e"
|
||||
cheerio@^1.0.0-rc.2:
|
||||
version "1.0.0-rc.2"
|
||||
resolved "https://registry.yarnpkg.com/cheerio/-/cheerio-1.0.0-rc.2.tgz#4b9f53a81b27e4d5dac31c0ffd0cfa03cc6830db"
|
||||
dependencies:
|
||||
css-select "~1.2.0"
|
||||
dom-serializer "~0.1.0"
|
||||
entities "~1.1.1"
|
||||
htmlparser2 "^3.9.1"
|
||||
lodash.assignin "^4.0.9"
|
||||
lodash.bind "^4.1.4"
|
||||
lodash.defaults "^4.0.1"
|
||||
lodash.filter "^4.4.0"
|
||||
lodash.flatten "^4.2.0"
|
||||
lodash.foreach "^4.3.0"
|
||||
lodash.map "^4.4.0"
|
||||
lodash.merge "^4.4.0"
|
||||
lodash.pick "^4.2.1"
|
||||
lodash.reduce "^4.4.0"
|
||||
lodash.reject "^4.4.0"
|
||||
lodash.some "^4.4.0"
|
||||
lodash "^4.15.0"
|
||||
parse5 "^3.0.1"
|
||||
|
||||
chokidar@^1.6.1:
|
||||
version "1.6.1"
|
||||
@@ -1179,6 +1169,10 @@ color-name@^1.1.1:
|
||||
version "1.1.1"
|
||||
resolved "https://registry.yarnpkg.com/color-name/-/color-name-1.1.1.tgz#4b1415304cf50028ea81643643bd82ea05803689"
|
||||
|
||||
colors@0.5.x:
|
||||
version "0.5.1"
|
||||
resolved "https://registry.yarnpkg.com/colors/-/colors-0.5.1.tgz#7d0023eaeb154e8ee9fce75dcb923d0ed1667774"
|
||||
|
||||
combined-stream@^1.0.5, combined-stream@~1.0.5:
|
||||
version "1.0.5"
|
||||
resolved "https://registry.yarnpkg.com/combined-stream/-/combined-stream-1.0.5.tgz#938370a57b4a51dea2c77c15d5c5fdf895164009"
|
||||
@@ -1318,9 +1312,9 @@ create-hmac@^1.1.0, create-hmac@^1.1.2:
|
||||
create-hash "^1.1.0"
|
||||
inherits "^2.0.1"
|
||||
|
||||
create-react-class@^15.6.0:
|
||||
version "15.6.0"
|
||||
resolved "https://registry.yarnpkg.com/create-react-class/-/create-react-class-15.6.0.tgz#ab448497c26566e1e29413e883207d57cfe7bed4"
|
||||
create-react-class@^15.6.2:
|
||||
version "15.6.2"
|
||||
resolved "https://registry.yarnpkg.com/create-react-class/-/create-react-class-15.6.2.tgz#cf1ed15f12aad7f14ef5f2dfe05e6c42f91ef02a"
|
||||
dependencies:
|
||||
fbjs "^0.8.9"
|
||||
loose-envify "^1.3.1"
|
||||
@@ -1366,9 +1360,9 @@ crypto-random-string@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/crypto-random-string/-/crypto-random-string-1.0.0.tgz#a230f64f568310e1498009940790ec99545bca7e"
|
||||
|
||||
css-in-js-utils@^1.0.3:
|
||||
version "1.0.3"
|
||||
resolved "https://registry.yarnpkg.com/css-in-js-utils/-/css-in-js-utils-1.0.3.tgz#9ac7e02f763cf85d94017666565ed68a5b5f3215"
|
||||
css-in-js-utils@^2.0.0:
|
||||
version "2.0.0"
|
||||
resolved "https://registry.yarnpkg.com/css-in-js-utils/-/css-in-js-utils-2.0.0.tgz#5af1dd70f4b06b331f48d22a3d86e0786c0b9435"
|
||||
dependencies:
|
||||
hyphenate-style-name "^1.0.2"
|
||||
|
||||
@@ -1560,6 +1554,10 @@ diffie-hellman@^5.0.0:
|
||||
miller-rabin "^4.0.0"
|
||||
randombytes "^2.0.0"
|
||||
|
||||
discontinuous-range@1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/discontinuous-range/-/discontinuous-range-1.0.0.tgz#e38331f0844bba49b9a9cb71c771585aab1bc65a"
|
||||
|
||||
doctrine@^2.0.0:
|
||||
version "2.0.0"
|
||||
resolved "https://registry.yarnpkg.com/doctrine/-/doctrine-2.0.0.tgz#c73d8d2909d22291e1a007a395804da8b665fe63"
|
||||
@@ -1678,32 +1676,44 @@ entities@^1.1.1, entities@~1.1.1:
|
||||
version "1.1.1"
|
||||
resolved "https://registry.yarnpkg.com/entities/-/entities-1.1.1.tgz#6e5c2d0a5621b5dadaecef80b90edfb5cd7772f0"
|
||||
|
||||
enzyme-to-json@^1.5.1:
|
||||
version "1.5.1"
|
||||
resolved "https://registry.yarnpkg.com/enzyme-to-json/-/enzyme-to-json-1.5.1.tgz#e34f4d126bb3f4696ce3800b51f9ed83df708799"
|
||||
enzyme-adapter-react-16@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/enzyme-adapter-react-16/-/enzyme-adapter-react-16-1.0.0.tgz#e7edd5536743818dcbef336d40d7da59b3a7db8e"
|
||||
dependencies:
|
||||
lodash.filter "^4.6.0"
|
||||
lodash.isnil "^4.0.0"
|
||||
lodash.isplainobject "^4.0.6"
|
||||
lodash.omitby "^4.5.0"
|
||||
lodash.range "^3.2.0"
|
||||
object-values "^1.0.0"
|
||||
object.entries "^1.0.3"
|
||||
enzyme-adapter-utils "^1.0.0"
|
||||
lodash "^4.17.4"
|
||||
object.assign "^4.0.4"
|
||||
object.values "^1.0.4"
|
||||
prop-types "^15.5.10"
|
||||
|
||||
enzyme@^2.9.1:
|
||||
version "2.9.1"
|
||||
resolved "https://registry.yarnpkg.com/enzyme/-/enzyme-2.9.1.tgz#07d5ce691241240fb817bf2c4b18d6e530240df6"
|
||||
enzyme-adapter-utils@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/enzyme-adapter-utils/-/enzyme-adapter-utils-1.0.0.tgz#e94eee63da9a798d498adb1162a2102ed04fc638"
|
||||
dependencies:
|
||||
cheerio "^0.22.0"
|
||||
function.prototype.name "^1.0.0"
|
||||
lodash "^4.17.4"
|
||||
object.assign "^4.0.4"
|
||||
prop-types "^15.5.10"
|
||||
|
||||
enzyme-to-json@next:
|
||||
version "3.0.0-beta6"
|
||||
resolved "https://registry.yarnpkg.com/enzyme-to-json/-/enzyme-to-json-3.0.0-beta6.tgz#db537fbd9d7d06b8f65124d115c38694f798f055"
|
||||
dependencies:
|
||||
lodash "^4.17.4"
|
||||
|
||||
enzyme@^3.0.0:
|
||||
version "3.0.0"
|
||||
resolved "https://registry.yarnpkg.com/enzyme/-/enzyme-3.0.0.tgz#94ce364254dc654c4e619b25eecc644bf6481de7"
|
||||
dependencies:
|
||||
cheerio "^1.0.0-rc.2"
|
||||
function.prototype.name "^1.0.3"
|
||||
is-subset "^0.1.1"
|
||||
lodash "^4.17.4"
|
||||
object-is "^1.0.1"
|
||||
object.assign "^4.0.4"
|
||||
object.entries "^1.0.4"
|
||||
object.values "^1.0.4"
|
||||
prop-types "^15.5.10"
|
||||
uuid "^3.0.1"
|
||||
raf "^3.3.2"
|
||||
rst-selector-parser "^2.2.1"
|
||||
|
||||
"errno@>=0.1.1 <0.2.0-0", errno@^0.1.3:
|
||||
version "0.1.4"
|
||||
@@ -2004,16 +2014,16 @@ expand-range@^1.8.1:
|
||||
dependencies:
|
||||
fill-range "^2.1.0"
|
||||
|
||||
expect@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/expect/-/expect-21.0.2.tgz#b34abf0635ec9d6aea1ce7edb4722afe86c4a38f"
|
||||
expect@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/expect/-/expect-21.1.0.tgz#1c138ec803c72d28cbd10dfe97104966d967c24a"
|
||||
dependencies:
|
||||
ansi-styles "^3.2.0"
|
||||
jest-diff "^21.0.2"
|
||||
jest-diff "^21.1.0"
|
||||
jest-get-type "^21.0.2"
|
||||
jest-matcher-utils "^21.0.2"
|
||||
jest-message-util "^21.0.2"
|
||||
jest-regex-util "^21.0.2"
|
||||
jest-matcher-utils "^21.1.0"
|
||||
jest-message-util "^21.1.0"
|
||||
jest-regex-util "^21.1.0"
|
||||
|
||||
express@^4.15.2:
|
||||
version "4.15.2"
|
||||
@@ -2084,9 +2094,9 @@ fb-watchman@^2.0.0:
|
||||
dependencies:
|
||||
bser "^2.0.0"
|
||||
|
||||
fbjs@^0.8.14, fbjs@^0.8.9:
|
||||
version "0.8.14"
|
||||
resolved "https://registry.yarnpkg.com/fbjs/-/fbjs-0.8.14.tgz#d1dbe2be254c35a91e09f31f9cd50a40b2a0ed1c"
|
||||
fbjs@^0.8.16, fbjs@^0.8.9:
|
||||
version "0.8.16"
|
||||
resolved "https://registry.yarnpkg.com/fbjs/-/fbjs-0.8.16.tgz#5e67432f550dc41b572bf55847b8aca64e5337db"
|
||||
dependencies:
|
||||
core-js "^1.0.0"
|
||||
isomorphic-fetch "^2.1.1"
|
||||
@@ -2276,13 +2286,13 @@ function-bind@^1.0.2, function-bind@^1.1.0, function-bind@~1.1.0:
|
||||
version "1.1.0"
|
||||
resolved "https://registry.yarnpkg.com/function-bind/-/function-bind-1.1.0.tgz#16176714c801798e4e8f2cf7f7529467bb4a5771"
|
||||
|
||||
function.prototype.name@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/function.prototype.name/-/function.prototype.name-1.0.0.tgz#5f523ca64e491a5f95aba80cc1e391080a14482e"
|
||||
function.prototype.name@^1.0.3:
|
||||
version "1.0.3"
|
||||
resolved "https://registry.yarnpkg.com/function.prototype.name/-/function.prototype.name-1.0.3.tgz#0099ae5572e9dd6f03c97d023fd92bcc5e639eac"
|
||||
dependencies:
|
||||
define-properties "^1.1.2"
|
||||
function-bind "^1.1.0"
|
||||
is-callable "^1.1.2"
|
||||
is-callable "^1.1.3"
|
||||
|
||||
functional-red-black-tree@^1.0.1:
|
||||
version "1.0.1"
|
||||
@@ -2632,12 +2642,12 @@ ini@~1.3.0:
|
||||
version "1.3.4"
|
||||
resolved "https://registry.yarnpkg.com/ini/-/ini-1.3.4.tgz#0537cb79daf59b59a1a517dff706c86ec039162e"
|
||||
|
||||
inline-style-prefixer@^3.0.7:
|
||||
version "3.0.7"
|
||||
resolved "https://registry.yarnpkg.com/inline-style-prefixer/-/inline-style-prefixer-3.0.7.tgz#0ccc92e5902fe6e0d28d975c4258443f880615f8"
|
||||
inline-style-prefixer@^3.0.8:
|
||||
version "3.0.8"
|
||||
resolved "https://registry.yarnpkg.com/inline-style-prefixer/-/inline-style-prefixer-3.0.8.tgz#8551b8e5b4d573244e66a34b04f7d32076a2b534"
|
||||
dependencies:
|
||||
bowser "^1.6.0"
|
||||
css-in-js-utils "^1.0.3"
|
||||
bowser "^1.7.3"
|
||||
css-in-js-utils "^2.0.0"
|
||||
|
||||
inquirer@^3.0.6:
|
||||
version "3.1.1"
|
||||
@@ -2696,7 +2706,7 @@ is-builtin-module@^1.0.0:
|
||||
dependencies:
|
||||
builtin-modules "^1.0.0"
|
||||
|
||||
is-callable@^1.1.1, is-callable@^1.1.2, is-callable@^1.1.3:
|
||||
is-callable@^1.1.1, is-callable@^1.1.3:
|
||||
version "1.1.3"
|
||||
resolved "https://registry.yarnpkg.com/is-callable/-/is-callable-1.1.3.tgz#86eb75392805ddc33af71c92a0eedf74ee7604b2"
|
||||
|
||||
@@ -2970,15 +2980,15 @@ istanbul-reports@^1.1.1:
|
||||
dependencies:
|
||||
handlebars "^4.0.3"
|
||||
|
||||
jest-changed-files@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-21.0.2.tgz#0a74f35cf2d3b7c8ef9ab4fac0a75409f81ec1b0"
|
||||
jest-changed-files@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-changed-files/-/jest-changed-files-21.1.0.tgz#e70f6b33b75d5987f4eae07e35bea5525635f92a"
|
||||
dependencies:
|
||||
throat "^4.0.0"
|
||||
|
||||
jest-cli@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-21.0.2.tgz#2e08af63d44fc21284ebf496cf71e381f3cc9786"
|
||||
jest-cli@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-cli/-/jest-cli-21.1.0.tgz#4f671885ea3521803c96a1fd95baaa6a1ba8d70f"
|
||||
dependencies:
|
||||
ansi-escapes "^3.0.0"
|
||||
chalk "^2.0.1"
|
||||
@@ -2989,17 +2999,17 @@ jest-cli@^21.0.2:
|
||||
istanbul-lib-coverage "^1.0.1"
|
||||
istanbul-lib-instrument "^1.4.2"
|
||||
istanbul-lib-source-maps "^1.1.0"
|
||||
jest-changed-files "^21.0.2"
|
||||
jest-config "^21.0.2"
|
||||
jest-environment-jsdom "^21.0.2"
|
||||
jest-haste-map "^21.0.2"
|
||||
jest-message-util "^21.0.2"
|
||||
jest-regex-util "^21.0.2"
|
||||
jest-resolve-dependencies "^21.0.2"
|
||||
jest-runner "^21.0.2"
|
||||
jest-runtime "^21.0.2"
|
||||
jest-snapshot "^21.0.2"
|
||||
jest-util "^21.0.2"
|
||||
jest-changed-files "^21.1.0"
|
||||
jest-config "^21.1.0"
|
||||
jest-environment-jsdom "^21.1.0"
|
||||
jest-haste-map "^21.1.0"
|
||||
jest-message-util "^21.1.0"
|
||||
jest-regex-util "^21.1.0"
|
||||
jest-resolve-dependencies "^21.1.0"
|
||||
jest-runner "^21.1.0"
|
||||
jest-runtime "^21.1.0"
|
||||
jest-snapshot "^21.1.0"
|
||||
jest-util "^21.1.0"
|
||||
micromatch "^2.3.11"
|
||||
node-notifier "^5.0.2"
|
||||
pify "^3.0.0"
|
||||
@@ -3010,76 +3020,76 @@ jest-cli@^21.0.2:
|
||||
worker-farm "^1.3.1"
|
||||
yargs "^9.0.0"
|
||||
|
||||
jest-config@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-21.0.2.tgz#ea42b94f3c22ae4e4aa11c69f5b45e34e342199d"
|
||||
jest-config@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-config/-/jest-config-21.1.0.tgz#7ef8778af679de30dad75e355a0dfbb0330b8d2f"
|
||||
dependencies:
|
||||
chalk "^2.0.1"
|
||||
glob "^7.1.1"
|
||||
jest-environment-jsdom "^21.0.2"
|
||||
jest-environment-node "^21.0.2"
|
||||
jest-environment-jsdom "^21.1.0"
|
||||
jest-environment-node "^21.1.0"
|
||||
jest-get-type "^21.0.2"
|
||||
jest-jasmine2 "^21.0.2"
|
||||
jest-regex-util "^21.0.2"
|
||||
jest-resolve "^21.0.2"
|
||||
jest-util "^21.0.2"
|
||||
jest-validate "^21.0.2"
|
||||
pretty-format "^21.0.2"
|
||||
jest-jasmine2 "^21.1.0"
|
||||
jest-regex-util "^21.1.0"
|
||||
jest-resolve "^21.1.0"
|
||||
jest-util "^21.1.0"
|
||||
jest-validate "^21.1.0"
|
||||
pretty-format "^21.1.0"
|
||||
|
||||
jest-diff@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-21.0.2.tgz#751014f36ad5d505f6affce5542fde0e444ee50a"
|
||||
jest-diff@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-diff/-/jest-diff-21.1.0.tgz#ca4c9d40272a6901dcde6c4c0bb2f568c363cc42"
|
||||
dependencies:
|
||||
chalk "^2.0.1"
|
||||
diff "^3.2.0"
|
||||
jest-get-type "^21.0.2"
|
||||
pretty-format "^21.0.2"
|
||||
pretty-format "^21.1.0"
|
||||
|
||||
jest-docblock@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-21.0.2.tgz#66f69ddb440799fc32f91d0ac3d8d35e99e2032f"
|
||||
jest-docblock@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-docblock/-/jest-docblock-21.1.0.tgz#43154be2441fb91403e36bb35cb791a5017cea81"
|
||||
|
||||
jest-environment-jsdom@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-21.0.2.tgz#6f6ab5bd71970d1900fbd47a46701c0a07fa3be5"
|
||||
jest-environment-jsdom@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-environment-jsdom/-/jest-environment-jsdom-21.1.0.tgz#40729a60cd4544625f7d3a33c32bdaad63e57db7"
|
||||
dependencies:
|
||||
jest-mock "^21.0.2"
|
||||
jest-util "^21.0.2"
|
||||
jest-mock "^21.1.0"
|
||||
jest-util "^21.1.0"
|
||||
jsdom "^9.12.0"
|
||||
|
||||
jest-environment-node@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-21.0.2.tgz#4267ceb39551f8ecaed182ab882a93ef4d5de240"
|
||||
jest-environment-node@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-environment-node/-/jest-environment-node-21.1.0.tgz#a11fd611e8ae6c3e02b785aa1b12a3009f4fd0f1"
|
||||
dependencies:
|
||||
jest-mock "^21.0.2"
|
||||
jest-util "^21.0.2"
|
||||
jest-mock "^21.1.0"
|
||||
jest-util "^21.1.0"
|
||||
|
||||
jest-get-type@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-get-type/-/jest-get-type-21.0.2.tgz#304e6b816dd33cd1f47aba0597bcad258a509fc6"
|
||||
|
||||
jest-haste-map@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-21.0.2.tgz#bd98bc6cd6f207eb029b2f5918da1a9347eb11b7"
|
||||
jest-haste-map@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-haste-map/-/jest-haste-map-21.1.0.tgz#08e7a8c584008d4b790b8dddf7dd3e3db03b75d3"
|
||||
dependencies:
|
||||
fb-watchman "^2.0.0"
|
||||
graceful-fs "^4.1.11"
|
||||
jest-docblock "^21.0.2"
|
||||
jest-docblock "^21.1.0"
|
||||
micromatch "^2.3.11"
|
||||
sane "^2.0.0"
|
||||
worker-farm "^1.3.1"
|
||||
|
||||
jest-jasmine2@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-21.0.2.tgz#a368abb3a686def4d6e763509a265104943cd469"
|
||||
jest-jasmine2@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-jasmine2/-/jest-jasmine2-21.1.0.tgz#975c3cd3ecd9d50d385bfe3c680dd61979f50c9c"
|
||||
dependencies:
|
||||
chalk "^2.0.1"
|
||||
expect "^21.0.2"
|
||||
expect "^21.1.0"
|
||||
graceful-fs "^4.1.11"
|
||||
jest-diff "^21.0.2"
|
||||
jest-matcher-utils "^21.0.2"
|
||||
jest-message-util "^21.0.2"
|
||||
jest-snapshot "^21.0.2"
|
||||
jest-diff "^21.1.0"
|
||||
jest-matcher-utils "^21.1.0"
|
||||
jest-message-util "^21.1.0"
|
||||
jest-snapshot "^21.1.0"
|
||||
p-cancelable "^0.3.0"
|
||||
|
||||
jest-matcher-utils@^20.0.3:
|
||||
@@ -3089,62 +3099,62 @@ jest-matcher-utils@^20.0.3:
|
||||
chalk "^1.1.3"
|
||||
pretty-format "^20.0.3"
|
||||
|
||||
jest-matcher-utils@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-21.0.2.tgz#eb6736a45b698546d71f7e1ffbbd36587eeb27bc"
|
||||
jest-matcher-utils@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-matcher-utils/-/jest-matcher-utils-21.1.0.tgz#b02e237b287c58915ce9a5bf3c7138dba95125a7"
|
||||
dependencies:
|
||||
chalk "^2.0.1"
|
||||
jest-get-type "^21.0.2"
|
||||
pretty-format "^21.0.2"
|
||||
pretty-format "^21.1.0"
|
||||
|
||||
jest-message-util@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-21.0.2.tgz#81242e07d426ad54c15f3d7c55b072e9db7b39a9"
|
||||
jest-message-util@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-message-util/-/jest-message-util-21.1.0.tgz#7f9a52535d1a640af0d4c800edde737e14ea0526"
|
||||
dependencies:
|
||||
chalk "^2.0.1"
|
||||
micromatch "^2.3.11"
|
||||
slash "^1.0.0"
|
||||
|
||||
jest-mock@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-21.0.2.tgz#5e92902450e1ce78be3864cc4d50dbd5d1582fbd"
|
||||
jest-mock@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-mock/-/jest-mock-21.1.0.tgz#c4dddfa893a0b120b72b5ae87c7506745213a790"
|
||||
|
||||
jest-regex-util@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-21.0.2.tgz#06248c07b53ff444223ebe8e33a25bc051ac976f"
|
||||
jest-regex-util@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-regex-util/-/jest-regex-util-21.1.0.tgz#59e4bad74f5ffd62a3835225f9bc1ee3796b5adb"
|
||||
|
||||
jest-resolve-dependencies@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-21.0.2.tgz#c42cc371034023ac1a226a7a52f86233c8871938"
|
||||
jest-resolve-dependencies@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-resolve-dependencies/-/jest-resolve-dependencies-21.1.0.tgz#9f78852e65d864d04ad0919ac8226b3f1434e7b0"
|
||||
dependencies:
|
||||
jest-regex-util "^21.0.2"
|
||||
jest-regex-util "^21.1.0"
|
||||
|
||||
jest-resolve@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-21.0.2.tgz#57b2c20cbeca2357eb5e638d5c28beca7f38c3f8"
|
||||
jest-resolve@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-resolve/-/jest-resolve-21.1.0.tgz#6bb806ca5ad876c250044fe62f298321d2da5c06"
|
||||
dependencies:
|
||||
browser-resolve "^1.11.2"
|
||||
chalk "^2.0.1"
|
||||
is-builtin-module "^1.0.0"
|
||||
|
||||
jest-runner@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-21.0.2.tgz#1462d431d25f7744e8b5e03837bbf9e268dc8b15"
|
||||
jest-runner@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-runner/-/jest-runner-21.1.0.tgz#d7ea7e2fa10ed673d4dd25ba2f3faae2efb89a07"
|
||||
dependencies:
|
||||
jest-config "^21.0.2"
|
||||
jest-docblock "^21.0.2"
|
||||
jest-haste-map "^21.0.2"
|
||||
jest-jasmine2 "^21.0.2"
|
||||
jest-message-util "^21.0.2"
|
||||
jest-runtime "^21.0.2"
|
||||
jest-util "^21.0.2"
|
||||
jest-config "^21.1.0"
|
||||
jest-docblock "^21.1.0"
|
||||
jest-haste-map "^21.1.0"
|
||||
jest-jasmine2 "^21.1.0"
|
||||
jest-message-util "^21.1.0"
|
||||
jest-runtime "^21.1.0"
|
||||
jest-util "^21.1.0"
|
||||
pify "^3.0.0"
|
||||
throat "^4.0.0"
|
||||
worker-farm "^1.3.1"
|
||||
|
||||
jest-runtime@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-21.0.2.tgz#ce26ba06bcd5501991bd994b1eacc0c7c7913895"
|
||||
jest-runtime@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-runtime/-/jest-runtime-21.1.0.tgz#c9a180a9e06ef046d0ad157dea52355abb7cbad4"
|
||||
dependencies:
|
||||
babel-core "^6.0.0"
|
||||
babel-jest "^21.0.2"
|
||||
@@ -3152,11 +3162,11 @@ jest-runtime@^21.0.2:
|
||||
chalk "^2.0.1"
|
||||
convert-source-map "^1.4.0"
|
||||
graceful-fs "^4.1.11"
|
||||
jest-config "^21.0.2"
|
||||
jest-haste-map "^21.0.2"
|
||||
jest-regex-util "^21.0.2"
|
||||
jest-resolve "^21.0.2"
|
||||
jest-util "^21.0.2"
|
||||
jest-config "^21.1.0"
|
||||
jest-haste-map "^21.1.0"
|
||||
jest-regex-util "^21.1.0"
|
||||
jest-resolve "^21.1.0"
|
||||
jest-util "^21.1.0"
|
||||
json-stable-stringify "^1.0.1"
|
||||
micromatch "^2.3.11"
|
||||
slash "^1.0.0"
|
||||
@@ -3164,27 +3174,27 @@ jest-runtime@^21.0.2:
|
||||
write-file-atomic "^2.1.0"
|
||||
yargs "^9.0.0"
|
||||
|
||||
jest-snapshot@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-21.0.2.tgz#5b8f4dd05c1759381db835451fba4bcd85a55611"
|
||||
jest-snapshot@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-snapshot/-/jest-snapshot-21.1.0.tgz#a5fa9d52847d8f52e19a1df6ccae9de699193ccc"
|
||||
dependencies:
|
||||
chalk "^2.0.1"
|
||||
jest-diff "^21.0.2"
|
||||
jest-matcher-utils "^21.0.2"
|
||||
jest-diff "^21.1.0"
|
||||
jest-matcher-utils "^21.1.0"
|
||||
mkdirp "^0.5.1"
|
||||
natural-compare "^1.4.0"
|
||||
pretty-format "^21.0.2"
|
||||
pretty-format "^21.1.0"
|
||||
|
||||
jest-util@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-21.0.2.tgz#3ee2380af25c414a39f07b23c84da6f2d5f1f76a"
|
||||
jest-util@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-util/-/jest-util-21.1.0.tgz#f92ff756422cc0609ddf5a9bfa4d34b2835d8c30"
|
||||
dependencies:
|
||||
callsites "^2.0.0"
|
||||
chalk "^2.0.1"
|
||||
graceful-fs "^4.1.11"
|
||||
jest-message-util "^21.0.2"
|
||||
jest-mock "^21.0.2"
|
||||
jest-validate "^21.0.2"
|
||||
jest-message-util "^21.1.0"
|
||||
jest-mock "^21.1.0"
|
||||
jest-validate "^21.1.0"
|
||||
mkdirp "^0.5.1"
|
||||
|
||||
jest-validate@^20.0.3:
|
||||
@@ -3196,20 +3206,20 @@ jest-validate@^20.0.3:
|
||||
leven "^2.1.0"
|
||||
pretty-format "^20.0.3"
|
||||
|
||||
jest-validate@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-21.0.2.tgz#dd066b257bd102759c214747d73bed6bcfa4349d"
|
||||
jest-validate@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest-validate/-/jest-validate-21.1.0.tgz#39d01115544a758bce49f221a5fcbb24ebdecc65"
|
||||
dependencies:
|
||||
chalk "^2.0.1"
|
||||
jest-get-type "^21.0.2"
|
||||
leven "^2.1.0"
|
||||
pretty-format "^21.0.2"
|
||||
pretty-format "^21.1.0"
|
||||
|
||||
jest@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/jest/-/jest-21.0.2.tgz#a5c9bdc9d4322ae672fe8cb3eaf25c268c5f04b2"
|
||||
jest@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/jest/-/jest-21.1.0.tgz#77c7baa8aa9e8bace7fe41a30d748ab56e89476a"
|
||||
dependencies:
|
||||
jest-cli "^21.0.2"
|
||||
jest-cli "^21.1.0"
|
||||
|
||||
jodid25519@^1.0.0:
|
||||
version "1.0.2"
|
||||
@@ -3217,11 +3227,7 @@ jodid25519@^1.0.0:
|
||||
dependencies:
|
||||
jsbn "~0.1.0"
|
||||
|
||||
js-tokens@^3.0.0:
|
||||
version "3.0.1"
|
||||
resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.1.tgz#08e9f132484a2c45a30907e9dc4d5567b7f114d7"
|
||||
|
||||
js-tokens@^3.0.2:
|
||||
js-tokens@^3.0.0, js-tokens@^3.0.2:
|
||||
version "3.0.2"
|
||||
resolved "https://registry.yarnpkg.com/js-tokens/-/js-tokens-3.0.2.tgz#9866df395102130e38f7f996bceb65443209c25b"
|
||||
|
||||
@@ -3453,79 +3459,23 @@ locate-path@^2.0.0:
|
||||
p-locate "^2.0.0"
|
||||
path-exists "^3.0.0"
|
||||
|
||||
lodash.assignin@^4.0.9:
|
||||
version "4.2.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.assignin/-/lodash.assignin-4.2.0.tgz#ba8df5fb841eb0a3e8044232b0e263a8dc6a28a2"
|
||||
|
||||
lodash.bind@^4.1.4:
|
||||
version "4.2.1"
|
||||
resolved "https://registry.yarnpkg.com/lodash.bind/-/lodash.bind-4.2.1.tgz#7ae3017e939622ac31b7d7d7dcb1b34db1690d35"
|
||||
|
||||
lodash.defaults@^4.0.1:
|
||||
version "4.2.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.defaults/-/lodash.defaults-4.2.0.tgz#d09178716ffea4dde9e5fb7b37f6f0802274580c"
|
||||
|
||||
lodash.filter@^4.4.0, lodash.filter@^4.6.0:
|
||||
version "4.6.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.filter/-/lodash.filter-4.6.0.tgz#668b1d4981603ae1cc5a6fa760143e480b4c4ace"
|
||||
|
||||
lodash.flatten@^4.2.0:
|
||||
lodash.flattendeep@^4.4.0:
|
||||
version "4.4.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.flatten/-/lodash.flatten-4.4.0.tgz#f31c22225a9632d2bbf8e4addbef240aa765a61f"
|
||||
|
||||
lodash.foreach@^4.3.0:
|
||||
version "4.5.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.foreach/-/lodash.foreach-4.5.0.tgz#1a6a35eace401280c7f06dddec35165ab27e3e53"
|
||||
|
||||
lodash.isnil@^4.0.0:
|
||||
version "4.0.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.isnil/-/lodash.isnil-4.0.0.tgz#49e28cd559013458c814c5479d3c663a21bfaa6c"
|
||||
|
||||
lodash.isplainobject@^4.0.6:
|
||||
version "4.0.6"
|
||||
resolved "https://registry.yarnpkg.com/lodash.isplainobject/-/lodash.isplainobject-4.0.6.tgz#7c526a52d89b45c45cc690b88163be0497f550cb"
|
||||
|
||||
lodash.map@^4.4.0:
|
||||
version "4.6.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.map/-/lodash.map-4.6.0.tgz#771ec7839e3473d9c4cde28b19394c3562f4f6d3"
|
||||
resolved "https://registry.yarnpkg.com/lodash.flattendeep/-/lodash.flattendeep-4.4.0.tgz#fb030917f86a3134e5bc9bec0d69e0013ddfedb2"
|
||||
|
||||
lodash.memoize@^4.1.2:
|
||||
version "4.1.2"
|
||||
resolved "https://registry.yarnpkg.com/lodash.memoize/-/lodash.memoize-4.1.2.tgz#bcc6c49a42a2840ed997f323eada5ecd182e0bfe"
|
||||
|
||||
lodash.merge@^4.4.0, lodash.merge@^4.6.0:
|
||||
lodash.merge@^4.6.0:
|
||||
version "4.6.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.merge/-/lodash.merge-4.6.0.tgz#69884ba144ac33fe699737a6086deffadd0f89c5"
|
||||
|
||||
lodash.omitby@^4.5.0:
|
||||
version "4.6.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.omitby/-/lodash.omitby-4.6.0.tgz#5c15ff4754ad555016b53c041311e8f079204791"
|
||||
|
||||
lodash.pick@^4.2.1:
|
||||
version "4.4.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.pick/-/lodash.pick-4.4.0.tgz#52f05610fff9ded422611441ed1fc123a03001b3"
|
||||
|
||||
lodash.range@^3.2.0:
|
||||
version "3.2.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.range/-/lodash.range-3.2.0.tgz#f461e588f66683f7eadeade513e38a69a565a15d"
|
||||
|
||||
lodash.reduce@^4.4.0:
|
||||
version "4.6.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.reduce/-/lodash.reduce-4.6.0.tgz#f1ab6b839299ad48f784abbf476596f03b914d3b"
|
||||
|
||||
lodash.reject@^4.4.0:
|
||||
version "4.6.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.reject/-/lodash.reject-4.6.0.tgz#80d6492dc1470864bbf583533b651f42a9f52415"
|
||||
|
||||
lodash.some@^4.4.0:
|
||||
version "4.6.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.some/-/lodash.some-4.6.0.tgz#1bb9f314ef6b8baded13b549169b2a945eb68e4d"
|
||||
|
||||
lodash.uniq@^4.5.0:
|
||||
version "4.5.0"
|
||||
resolved "https://registry.yarnpkg.com/lodash.uniq/-/lodash.uniq-4.5.0.tgz#d0225373aeb652adc1bc82e4945339a842754773"
|
||||
|
||||
lodash@^4.0.0, lodash@^4.14.0, lodash@^4.17.4, lodash@^4.2.0, lodash@^4.3.0, lodash@^4.6.1:
|
||||
lodash@^4.0.0, lodash@^4.14.0, lodash@^4.15.0, lodash@^4.17.4, lodash@^4.2.0, lodash@^4.3.0, lodash@^4.6.1:
|
||||
version "4.17.4"
|
||||
resolved "https://registry.yarnpkg.com/lodash/-/lodash-4.17.4.tgz#78203a4d1c328ae1d86dca6460e369b57f4055ae"
|
||||
|
||||
@@ -3737,6 +3687,14 @@ natural-compare@^1.4.0:
|
||||
version "1.4.0"
|
||||
resolved "https://registry.yarnpkg.com/natural-compare/-/natural-compare-1.4.0.tgz#4abebfeed7541f2c27acfb29bdbbd15c8d5ba4f7"
|
||||
|
||||
nearley@^2.7.10:
|
||||
version "2.11.0"
|
||||
resolved "https://registry.yarnpkg.com/nearley/-/nearley-2.11.0.tgz#5e626c79a6cd2f6ab9e7e5d5805e7668967757ae"
|
||||
dependencies:
|
||||
nomnom "~1.6.2"
|
||||
railroad-diagrams "^1.0.0"
|
||||
randexp "^0.4.2"
|
||||
|
||||
negotiator@0.6.1:
|
||||
version "0.6.1"
|
||||
resolved "https://registry.yarnpkg.com/negotiator/-/negotiator-0.6.1.tgz#2b327184e8992101177b28563fb5e7102acd0ca9"
|
||||
@@ -3818,6 +3776,13 @@ node-pre-gyp@^0.6.36:
|
||||
tar "^2.2.1"
|
||||
tar-pack "^3.4.0"
|
||||
|
||||
nomnom@~1.6.2:
|
||||
version "1.6.2"
|
||||
resolved "https://registry.yarnpkg.com/nomnom/-/nomnom-1.6.2.tgz#84a66a260174408fc5b77a18f888eccc44fb6971"
|
||||
dependencies:
|
||||
colors "0.5.x"
|
||||
underscore "~1.4.4"
|
||||
|
||||
nopt@^4.0.1:
|
||||
version "4.0.1"
|
||||
resolved "https://registry.yarnpkg.com/nopt/-/nopt-4.0.1.tgz#d0d4685afd5415193c8c7505602d0d17cd64474d"
|
||||
@@ -3926,10 +3891,6 @@ object-keys@^1.0.10, object-keys@^1.0.8:
|
||||
version "1.0.11"
|
||||
resolved "https://registry.yarnpkg.com/object-keys/-/object-keys-1.0.11.tgz#c54601778ad560f1142ce0e01bcca8b56d13426d"
|
||||
|
||||
object-values@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/object-values/-/object-values-1.0.0.tgz#72af839630119e5b98c3b02bb8c27e3237158105"
|
||||
|
||||
object.assign@^4.0.4:
|
||||
version "4.0.4"
|
||||
resolved "https://registry.yarnpkg.com/object.assign/-/object.assign-4.0.4.tgz#b1c9cc044ef1b9fe63606fc141abbb32e14730cc"
|
||||
@@ -3938,7 +3899,7 @@ object.assign@^4.0.4:
|
||||
function-bind "^1.1.0"
|
||||
object-keys "^1.0.10"
|
||||
|
||||
object.entries@^1.0.3, object.entries@^1.0.4:
|
||||
object.entries@^1.0.4:
|
||||
version "1.0.4"
|
||||
resolved "https://registry.yarnpkg.com/object.entries/-/object.entries-1.0.4.tgz#1bf9a4dd2288f5b33f3a993d257661f05d161a5f"
|
||||
dependencies:
|
||||
@@ -4121,6 +4082,12 @@ parse5@^1.5.1:
|
||||
version "1.5.1"
|
||||
resolved "https://registry.yarnpkg.com/parse5/-/parse5-1.5.1.tgz#9b7f3b0de32be78dc2401b17573ccaf0f6f59d94"
|
||||
|
||||
parse5@^3.0.1:
|
||||
version "3.0.2"
|
||||
resolved "https://registry.yarnpkg.com/parse5/-/parse5-3.0.2.tgz#05eff57f0ef4577fb144a79f8b9a967a6cc44510"
|
||||
dependencies:
|
||||
"@types/node" "^6.0.46"
|
||||
|
||||
parseurl@~1.3.1:
|
||||
version "1.3.1"
|
||||
resolved "https://registry.yarnpkg.com/parseurl/-/parseurl-1.3.1.tgz#c8ab8c9223ba34888aa64a297b28853bec18da56"
|
||||
@@ -4187,6 +4154,10 @@ performance-now@^0.2.0:
|
||||
version "0.2.0"
|
||||
resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-0.2.0.tgz#33ef30c5c77d4ea21c5a53869d91b56d8f2555e5"
|
||||
|
||||
performance-now@^2.1.0:
|
||||
version "2.1.0"
|
||||
resolved "https://registry.yarnpkg.com/performance-now/-/performance-now-2.1.0.tgz#6309f4e0e5fa913ec1c69307ae364b4b377c9e7b"
|
||||
|
||||
pify@^2.0.0, pify@^2.3.0:
|
||||
version "2.3.0"
|
||||
resolved "https://registry.yarnpkg.com/pify/-/pify-2.3.0.tgz#ed141a6ac043a849ea588498e7dca8b15330e90c"
|
||||
@@ -4227,9 +4198,9 @@ preserve@^0.2.0:
|
||||
version "0.2.0"
|
||||
resolved "https://registry.yarnpkg.com/preserve/-/preserve-0.2.0.tgz#815ed1f6ebc65926f865b310c0713bcb3315ce4b"
|
||||
|
||||
prettier@^1.6.1:
|
||||
version "1.6.1"
|
||||
resolved "https://registry.yarnpkg.com/prettier/-/prettier-1.6.1.tgz#850f411a3116226193e32ea5acfc21c0f9a76d7d"
|
||||
prettier@^1.7.0:
|
||||
version "1.7.0"
|
||||
resolved "https://registry.yarnpkg.com/prettier/-/prettier-1.7.0.tgz#47481588f41f7c90f63938feb202ac82554e7150"
|
||||
|
||||
pretty-format@^20.0.3:
|
||||
version "20.0.3"
|
||||
@@ -4238,9 +4209,9 @@ pretty-format@^20.0.3:
|
||||
ansi-regex "^2.1.1"
|
||||
ansi-styles "^3.0.0"
|
||||
|
||||
pretty-format@^21.0.2:
|
||||
version "21.0.2"
|
||||
resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-21.0.2.tgz#76adcebd836c41ccd2e6b626e70f63050d2a3534"
|
||||
pretty-format@^21.1.0:
|
||||
version "21.1.0"
|
||||
resolved "https://registry.yarnpkg.com/pretty-format/-/pretty-format-21.1.0.tgz#557428254323832ee8b7c971cb613442bea67f61"
|
||||
dependencies:
|
||||
ansi-regex "^3.0.0"
|
||||
ansi-styles "^3.2.0"
|
||||
@@ -4271,12 +4242,13 @@ promise@^7.1.1:
|
||||
dependencies:
|
||||
asap "~2.0.3"
|
||||
|
||||
prop-types@^15.5.10:
|
||||
version "15.5.10"
|
||||
resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.5.10.tgz#2797dfc3126182e3a95e3dfbb2e893ddd7456154"
|
||||
prop-types@^15.5.10, prop-types@^15.6.0:
|
||||
version "15.6.0"
|
||||
resolved "https://registry.yarnpkg.com/prop-types/-/prop-types-15.6.0.tgz#ceaf083022fc46b4a35f69e13ef75aed0d639856"
|
||||
dependencies:
|
||||
fbjs "^0.8.9"
|
||||
fbjs "^0.8.16"
|
||||
loose-envify "^1.3.1"
|
||||
object-assign "^4.1.1"
|
||||
|
||||
proxy-addr@~1.1.3:
|
||||
version "1.1.4"
|
||||
@@ -4327,6 +4299,23 @@ querystring@0.2.0:
|
||||
version "0.2.0"
|
||||
resolved "https://registry.yarnpkg.com/querystring/-/querystring-0.2.0.tgz#b209849203bb25df820da756e747005878521620"
|
||||
|
||||
raf@^3.3.2:
|
||||
version "3.3.2"
|
||||
resolved "https://registry.yarnpkg.com/raf/-/raf-3.3.2.tgz#0c13be0b5b49b46f76d6669248d527cf2b02fe27"
|
||||
dependencies:
|
||||
performance-now "^2.1.0"
|
||||
|
||||
railroad-diagrams@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/railroad-diagrams/-/railroad-diagrams-1.0.0.tgz#eb7e6267548ddedfb899c1b90e57374559cddb7e"
|
||||
|
||||
randexp@^0.4.2:
|
||||
version "0.4.6"
|
||||
resolved "https://registry.yarnpkg.com/randexp/-/randexp-0.4.6.tgz#e986ad5e5e31dae13ddd6f7b3019aa7c87f60ca3"
|
||||
dependencies:
|
||||
discontinuous-range "1.0.0"
|
||||
ret "~0.1.10"
|
||||
|
||||
randomatic@^1.1.3:
|
||||
version "1.1.5"
|
||||
resolved "https://registry.yarnpkg.com/randomatic/-/randomatic-1.1.5.tgz#5e9ef5f2d573c67bd2b8124ae90b5156e457840b"
|
||||
@@ -4364,14 +4353,14 @@ react-deep-force-update@^1.0.0:
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/react-deep-force-update/-/react-deep-force-update-1.0.1.tgz#f911b5be1d2a6fe387507dd6e9a767aa2924b4c7"
|
||||
|
||||
react-dom@^15.6.1:
|
||||
version "15.6.1"
|
||||
resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-15.6.1.tgz#2cb0ed4191038e53c209eb3a79a23e2a4cf99470"
|
||||
react-dom@^16.0.0:
|
||||
version "16.0.0"
|
||||
resolved "https://registry.yarnpkg.com/react-dom/-/react-dom-16.0.0.tgz#9cc3079c3dcd70d4c6e01b84aab2a7e34c303f58"
|
||||
dependencies:
|
||||
fbjs "^0.8.9"
|
||||
fbjs "^0.8.16"
|
||||
loose-envify "^1.1.0"
|
||||
object-assign "^4.1.0"
|
||||
prop-types "^15.5.10"
|
||||
object-assign "^4.1.1"
|
||||
prop-types "^15.6.0"
|
||||
|
||||
react-proxy@^1.1.7:
|
||||
version "1.1.8"
|
||||
@@ -4380,12 +4369,12 @@ react-proxy@^1.1.7:
|
||||
lodash "^4.6.1"
|
||||
react-deep-force-update "^1.0.0"
|
||||
|
||||
react-test-renderer@^15.6.1:
|
||||
version "15.6.1"
|
||||
resolved "https://registry.yarnpkg.com/react-test-renderer/-/react-test-renderer-15.6.1.tgz#026f4a5bb5552661fd2cc4bbcd0d4bc8a35ebf7e"
|
||||
react-test-renderer@^16.0.0:
|
||||
version "16.0.0"
|
||||
resolved "https://registry.yarnpkg.com/react-test-renderer/-/react-test-renderer-16.0.0.tgz#9fe7b8308f2f71f29fc356d4102086f131c9cb15"
|
||||
dependencies:
|
||||
fbjs "^0.8.9"
|
||||
object-assign "^4.1.0"
|
||||
fbjs "^0.8.16"
|
||||
object-assign "^4.1.1"
|
||||
|
||||
react-timer-mixin@^0.13.3:
|
||||
version "0.13.3"
|
||||
@@ -4398,15 +4387,14 @@ react-transform-hmr@^1.0.4:
|
||||
global "^4.3.0"
|
||||
react-proxy "^1.1.7"
|
||||
|
||||
react@^15.6.1:
|
||||
version "15.6.1"
|
||||
resolved "https://registry.yarnpkg.com/react/-/react-15.6.1.tgz#baa8434ec6780bde997cdc380b79cd33b96393df"
|
||||
react@^16.0.0:
|
||||
version "16.0.0"
|
||||
resolved "https://registry.yarnpkg.com/react/-/react-16.0.0.tgz#ce7df8f1941b036f02b2cca9dbd0cb1f0e855e2d"
|
||||
dependencies:
|
||||
create-react-class "^15.6.0"
|
||||
fbjs "^0.8.9"
|
||||
fbjs "^0.8.16"
|
||||
loose-envify "^1.1.0"
|
||||
object-assign "^4.1.0"
|
||||
prop-types "^15.5.10"
|
||||
object-assign "^4.1.1"
|
||||
prop-types "^15.6.0"
|
||||
|
||||
read-pkg-up@^1.0.1:
|
||||
version "1.0.1"
|
||||
@@ -4624,6 +4612,10 @@ resumer@~0.0.0:
|
||||
dependencies:
|
||||
through "~2.3.4"
|
||||
|
||||
ret@~0.1.10:
|
||||
version "0.1.15"
|
||||
resolved "https://registry.yarnpkg.com/ret/-/ret-0.1.15.tgz#b8a4825d5bdb1fc3f6f53c2bc33f81388681c7bc"
|
||||
|
||||
right-align@^0.1.1:
|
||||
version "0.1.3"
|
||||
resolved "https://registry.yarnpkg.com/right-align/-/right-align-0.1.3.tgz#61339b722fe6a3515689210d24e14c96148613ef"
|
||||
@@ -4646,6 +4638,13 @@ ripemd160@^1.0.0:
|
||||
version "1.0.1"
|
||||
resolved "https://registry.yarnpkg.com/ripemd160/-/ripemd160-1.0.1.tgz#93a4bbd4942bc574b69a8fa57c71de10ecca7d6e"
|
||||
|
||||
rst-selector-parser@^2.2.1:
|
||||
version "2.2.2"
|
||||
resolved "https://registry.yarnpkg.com/rst-selector-parser/-/rst-selector-parser-2.2.2.tgz#9927b619bd5af8dc23a76c64caef04edf90d2c65"
|
||||
dependencies:
|
||||
lodash.flattendeep "^4.4.0"
|
||||
nearley "^2.7.10"
|
||||
|
||||
run-async@^2.2.0:
|
||||
version "2.3.0"
|
||||
resolved "https://registry.yarnpkg.com/run-async/-/run-async-2.3.0.tgz#0371ab4ae0bdd720d4166d7dfda64ff7a445a6c0"
|
||||
@@ -5210,6 +5209,10 @@ ultron@~1.1.0:
|
||||
version "1.1.0"
|
||||
resolved "https://registry.yarnpkg.com/ultron/-/ultron-1.1.0.tgz#b07a2e6a541a815fc6a34ccd4533baec307ca864"
|
||||
|
||||
underscore@~1.4.4:
|
||||
version "1.4.4"
|
||||
resolved "https://registry.yarnpkg.com/underscore/-/underscore-1.4.4.tgz#61a6a32010622afa07963bf325203cf12239d604"
|
||||
|
||||
unique-string@^1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/unique-string/-/unique-string-1.0.0.tgz#9e1057cca851abb93398f8b33ae187b99caec11a"
|
||||
@@ -5275,7 +5278,7 @@ utils-merge@1.0.0:
|
||||
version "1.0.0"
|
||||
resolved "https://registry.yarnpkg.com/utils-merge/-/utils-merge-1.0.0.tgz#0294fb922bb9375153541c4f7096231f287c8af8"
|
||||
|
||||
uuid@^3.0.0, uuid@^3.0.1:
|
||||
uuid@^3.0.0:
|
||||
version "3.1.0"
|
||||
resolved "https://registry.yarnpkg.com/uuid/-/uuid-3.1.0.tgz#3dd3d3e790abc24d7b0d3a034ffababe28ebbc04"
|
||||
|
||||
@@ -5357,9 +5360,9 @@ webpack-sources@^1.0.1:
|
||||
source-list-map "^2.0.0"
|
||||
source-map "~0.5.3"
|
||||
|
||||
webpack@^3.5.6:
|
||||
version "3.5.6"
|
||||
resolved "https://registry.yarnpkg.com/webpack/-/webpack-3.5.6.tgz#a492fb6c1ed7f573816f90e00c8fbb5a20cc5c36"
|
||||
webpack@^3.6.0:
|
||||
version "3.6.0"
|
||||
resolved "https://registry.yarnpkg.com/webpack/-/webpack-3.6.0.tgz#a89a929fbee205d35a4fa2cc487be9cbec8898bc"
|
||||
dependencies:
|
||||
acorn "^5.0.0"
|
||||
acorn-dynamic-import "^2.0.0"
|
||||
|
||||
Reference in New Issue
Block a user