Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/lin-xi/react-selectview
js 模拟ios的选择控件
https://github.com/lin-xi/react-selectview
Last synced: about 6 hours ago
JSON representation
js 模拟ios的选择控件
- Host: GitHub
- URL: https://github.com/lin-xi/react-selectview
- Owner: lin-xi
- Created: 2016-02-22T11:03:21.000Z (almost 9 years ago)
- Default Branch: master
- Last Pushed: 2016-02-22T12:46:45.000Z (almost 9 years ago)
- Last Synced: 2024-11-11T09:44:36.553Z (about 2 months ago)
- Language: JavaScript
- Size: 102 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
React-SelectView
====>React-SelectView 是一个模拟ios原生的选择控件。
![selectview](./screenshot.png)
--------
##依赖
react
--------
##安装:
>npm install react-selectview --save
--------##所有配置项 props
data: array, 数组
show: bool, 显示或隐藏
change: function, 点击确认按钮的回调
selectChange: function, 选择项改变回调
--------
## 使用```
var snedTimeData = [
[], []
];
表示有两个选择项var snedTimeData = [
[], [], []
];
表示有三个选择项var snedTimeData = [
[
{
name: '2015-02-01',
value: '2015-02-01'
},
{
name: '2015-02-02',
value: '2015-02-01'
}
], [
{
name: '06:00',
value: '1456140397704'
},
{
name: '07:00',
value: '1456140397306'
},
{
name: '08:00',
value: '1456140397306'
}
]
];```