mirror of
https://github.com/zoriya/react-native-web.git
synced 2026-06-03 18:52:07 +00:00
Add placeholder ListView and ScrollView
This commit is contained in:
@@ -0,0 +1,20 @@
|
|||||||
|
import React, { PropTypes } from 'react'
|
||||||
|
import ScrollView from '../ScrollView'
|
||||||
|
|
||||||
|
class ListView extends React.Component {
|
||||||
|
static propTypes = {
|
||||||
|
children: PropTypes.any
|
||||||
|
}
|
||||||
|
|
||||||
|
static defaultProps = {
|
||||||
|
className: ''
|
||||||
|
}
|
||||||
|
|
||||||
|
render() {
|
||||||
|
return (
|
||||||
|
<ScrollView {...this.props} />
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default ListView
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
/*
|
||||||
|
import assert from 'assert'
|
||||||
|
import React from 'react/addons'
|
||||||
|
|
||||||
|
import ListView from '.'
|
||||||
|
|
||||||
|
const ReactTestUtils = React.addons.TestUtils
|
||||||
|
|
||||||
|
function shallowRender(component, context = {}) {
|
||||||
|
const shallowRenderer = React.addons.TestUtils.createRenderer()
|
||||||
|
shallowRenderer.render(component, context)
|
||||||
|
return shallowRenderer.getRenderOutput()
|
||||||
|
}
|
||||||
|
|
||||||
|
suite.skip('ListView', () => {
|
||||||
|
test('prop "children"', () => {})
|
||||||
|
})
|
||||||
|
*/
|
||||||
@@ -0,0 +1,20 @@
|
|||||||
|
import React, { PropTypes } from 'react'
|
||||||
|
import View from '../View'
|
||||||
|
|
||||||
|
class ScrollView extends React.Component {
|
||||||
|
static propTypes = {
|
||||||
|
children: PropTypes.any
|
||||||
|
}
|
||||||
|
|
||||||
|
static defaultProps = {
|
||||||
|
className: ''
|
||||||
|
}
|
||||||
|
|
||||||
|
render() {
|
||||||
|
return (
|
||||||
|
<View {...this.props} />
|
||||||
|
)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
export default ScrollView
|
||||||
@@ -0,0 +1,18 @@
|
|||||||
|
/*
|
||||||
|
import assert from 'assert'
|
||||||
|
import React from 'react/addons'
|
||||||
|
|
||||||
|
import ScrollView from '.'
|
||||||
|
|
||||||
|
const ReactTestUtils = React.addons.TestUtils
|
||||||
|
|
||||||
|
function shallowRender(component, context = {}) {
|
||||||
|
const shallowRenderer = React.addons.TestUtils.createRenderer()
|
||||||
|
shallowRenderer.render(component, context)
|
||||||
|
return shallowRenderer.getRenderOutput()
|
||||||
|
}
|
||||||
|
|
||||||
|
suite.skip('ScrollView', () => {
|
||||||
|
test('prop "children"', () => {})
|
||||||
|
})
|
||||||
|
*/
|
||||||
Reference in New Issue
Block a user