Skip to content

Commit 8456628

Browse files
committed
init
1 parent 1cc1bba commit 8456628

14 files changed

+226
-2
lines changed

.editorconfig

+9
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
# top-most EditorConfig file
2+
root = true
3+
4+
# Unix-style newlines with a newline ending every file
5+
[*.{js,css}]
6+
end_of_line = lf
7+
insert_final_newline = true
8+
indent_style = space
9+
indent_size = 2

.gitignore

+24
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
*.iml
2+
*.log
3+
.idea
4+
.ipr
5+
.iws
6+
*~
7+
~*
8+
*.diff
9+
*.patch
10+
*.bak
11+
.DS_Store
12+
Thumbs.db
13+
.project
14+
.*proj
15+
.svn
16+
*.swp
17+
*.swo
18+
*.pyc
19+
*.pyo
20+
node_modules
21+
.cache
22+
*.css
23+
build
24+
lib

.travis.yml

+38
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
language: node_js
2+
3+
sudo: false
4+
5+
notifications:
6+
email:
7+
8+
9+
node_js:
10+
- 4.0.0
11+
12+
before_install:
13+
- |
14+
if ! git diff --name-only $TRAVIS_COMMIT_RANGE | grep -qvE '(\.md$)|(^(docs|examples))/'
15+
then
16+
echo "Only docs were updated, stopping build process."
17+
exit
18+
fi
19+
npm install mocha-phantomjs -g
20+
phantomjs --version
21+
script:
22+
- |
23+
if [ "$TEST_TYPE" = test ]; then
24+
npm test
25+
else
26+
npm run $TEST_TYPE
27+
fi
28+
env:
29+
matrix:
30+
- TEST_TYPE=lint
31+
- TEST_TYPE=browser-test
32+
- TEST_TYPE=browser-test-cover
33+
- TEST_TYPE=saucelabs
34+
35+
36+
matrix:
37+
allow_failures:
38+
- env: "TEST_TYPE=saucelabs"

HISTORY.md

Whitespace-only changes.

README.md

+82-2
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,82 @@
1-
# form
2-
React Form High Order Component
1+
# rc-form
2+
---
3+
4+
React High Order Form Component
5+
6+
7+
[![NPM version][npm-image]][npm-url]
8+
[![build status][travis-image]][travis-url]
9+
[![Test coverage][coveralls-image]][coveralls-url]
10+
[![gemnasium deps][gemnasium-image]][gemnasium-url]
11+
[![node version][node-image]][node-url]
12+
[![npm download][download-image]][download-url]
13+
14+
[npm-image]: http://img.shields.io/npm/v/rc-form.svg?style=flat-square
15+
[npm-url]: http://npmjs.org/package/rc-form
16+
[travis-image]: https://img.shields.io/travis/react-component/form.svg?style=flat-square
17+
[travis-url]: https://travis-ci.org/react-component/form
18+
[coveralls-image]: https://img.shields.io/coveralls/react-component/form.svg?style=flat-square
19+
[coveralls-url]: https://coveralls.io/r/react-component/form?branch=master
20+
[gemnasium-image]: http://img.shields.io/gemnasium/react-component/form.svg?style=flat-square
21+
[gemnasium-url]: https://gemnasium.com/react-component/form
22+
[node-image]: https://img.shields.io/badge/node.js-%3E=_0.10-green.svg?style=flat-square
23+
[node-url]: http://nodejs.org/download/
24+
[download-image]: https://img.shields.io/npm/dm/rc-form.svg?style=flat-square
25+
[download-url]: https://npmjs.org/package/rc-form
26+
27+
28+
## Browser Support
29+
30+
|![IE](https://raw.github.com/alrra/browser-logos/master/internet-explorer/internet-explorer_48x48.png) | ![Chrome](https://raw.github.com/alrra/browser-logos/master/chrome/chrome_48x48.png) | ![Firefox](https://raw.github.com/alrra/browser-logos/master/firefox/firefox_48x48.png) | ![Opera](https://raw.github.com/alrra/browser-logos/master/opera/opera_48x48.png) | ![Safari](https://raw.github.com/alrra/browser-logos/master/safari/safari_48x48.png)|
31+
| --- | --- | --- | --- | --- |
32+
| IE 8+ ✔ | Chrome 31.0+ ✔ | Firefox 31.0+ ✔ | Opera 30.0+ ✔ | Safari 7.0+ ✔ |
33+
34+
35+
## Development
36+
37+
```
38+
npm install
39+
npm start
40+
```
41+
42+
## Example
43+
44+
http://localhost:8000/examples/
45+
46+
47+
online example: http://react-component.github.io/form/examples/
48+
49+
50+
## Feature
51+
52+
* support ie8,ie8+,chrome,firefox,safari
53+
54+
### Keyboard
55+
56+
57+
## install
58+
59+
60+
[![rc-form](https://nodei.co/npm/rc-form.png)](https://npmjs.org/package/rc-form)
61+
62+
63+
## Usage
64+
65+
```js
66+
```
67+
68+
## API
69+
70+
71+
72+
## Test Case
73+
74+
http://localhost:8000/tests/runner.html?coverage
75+
76+
## Coverage
77+
78+
http://localhost:8000/node_modules/rc-server/node_modules/node-jscover/lib/front-end/jscoverage.html?w=http://localhost:8000/tests/runner.html?coverage
79+
80+
## License
81+
82+
rc-form is released under the MIT license.

assets/index.less

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
@zero: 0;

examples/simple.html

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
placeholder

examples/simple.js

+8
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
// use jsx to render html, do not modify simple.html
2+
3+
import 'rc-form/assets/index.less';
4+
import Form from 'rc-form';
5+
import React from 'react';
6+
import ReactDOM from 'react-dom';
7+
8+
ReactDOM.render(<Form />, document.getElementById('__react-content'));

index.js

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
// export this package's api
2+
import Form from './src/';
3+
export default Form;

package.json

+50
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
{
2+
"name": "rc-form",
3+
"version": "0.0.0",
4+
"description": "form ui component for react",
5+
"keywords": [
6+
"react",
7+
"react-component",
8+
"react-form",
9+
"form"
10+
],
11+
"homepage": "https://github.com/react-component/form",
12+
"author": "",
13+
"repository": {
14+
"type": "git",
15+
"url": "https://github.com/react-component/form.git"
16+
},
17+
"bugs": {
18+
"url": "https://github.com/react-component/form/issues"
19+
},
20+
"files":["lib", "assets/*.css"],
21+
"licenses": "MIT",
22+
23+
"main":"./lib/index",
24+
"config":{
25+
"port": 8000
26+
},
27+
"scripts": {
28+
"build": "rc-tools run build",
29+
"gh-pages": "rc-tools run gh-pages",
30+
"start": "rc-server",
31+
"pub": "rc-tools run pub",
32+
"lint": "rc-tools run lint",
33+
"karma": "rc-tools run karma",
34+
"saucelabs": "rc-tools run saucelabs",
35+
"browser-test": "rc-tools run browser-test",
36+
"browser-test-cover": "rc-tools run browser-test-cover"
37+
},
38+
"devDependencies": {
39+
"expect.js": "0.3.x",
40+
"pre-commit": "1.x",
41+
"rc-server": "3.x",
42+
"rc-tools": "4.x",
43+
"react": "0.14.x",
44+
"react-addons-test-utils": "0.14.x",
45+
"react-dom": "0.14.x"
46+
},
47+
"pre-commit": [
48+
"lint"
49+
]
50+
}

src/Form.jsx

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
import React from 'react';
2+
const Form = React.createClass({});
3+
export default Form;

src/index.js

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
// export this package's api
2+
import Form from './Form';
3+
export default Form;

tests/index.spec.js

+3
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
/**
2+
* only require other specs here
3+
*/

tests/runner.html

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
stub

0 commit comments

Comments
 (0)