Movatterモバイル変換


[0]ホーム

URL:


Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings
This repository was archived by the owner on Nov 8, 2022. It is now read-only.

Commitef098fd

Browse files
committed
wip antd
1 parentae2105c commitef098fd

File tree

10 files changed

+79
-10
lines changed

10 files changed

+79
-10
lines changed

‎components/AntUI/Button.js‎

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,31 @@
1+
/*
2+
*
3+
* AntUi
4+
*
5+
*/
6+
7+
importReactfrom'react'
8+
importPropTypesfrom'prop-types'
9+
10+
import{Button}from'antd'
11+
12+
// import styled from 'styled-components'
13+
14+
import{makeDebugger}from'../../utils/functions'
15+
/* eslint-disable no-unused-vars */
16+
constdebug=makeDebugger('c:MButton:index')
17+
/* eslint-enable no-unused-vars */
18+
19+
constMButton=({ children})=>{
20+
return<Button>{children}</Button>
21+
}
22+
23+
MButton.propTypes={
24+
children:PropTypes.string,
25+
}
26+
27+
MButton.defaultProps={
28+
children:'..?..',
29+
}
30+
31+
exportdefaultMButton

‎components/AntUI/index.js‎

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,9 @@
1+
/*
2+
*
3+
* AntUi Wrapper
4+
*
5+
*/
6+
7+
export{defaultasButton}from'./Button'
8+
9+
exportconstholder=1
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
// import React from 'react'
2+
// import { shallow } from 'enzyme'
3+
4+
// import AntUi from '../index'
5+
6+
describe('<AntUi />',()=>{
7+
it('Expect to have unit tests specified',()=>{
8+
expect(true).toEqual(false)
9+
})
10+
})

‎containers/Body/index.js‎

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ import keydown from 'react-keydown'
1010
importRfrom'ramda'
1111

1212
// import Link from 'next/link'
13-
import{Button}from'antd'
13+
import{Button}from'../../components/AntUI'
1414

1515
import{makeDebugger}from'../../utils/functions'
1616

‎docs/ideas.md‎

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -31,11 +31,7 @@
3131

3232
##TODO
3333

34-
-[ ] pages
35-
|-index.js
36-
|-admin.js
37-
|-intro.js
38-
34+
-[ ] use header section footer main ... html tags
3935
-[ ][字体问题参考](http://element.eleme.io/2.0/#/zh-CN/component/typography)
4036
-[ ][字体](https://github.com/ethantw/Han)
4137
-[ ] common suggestion error display

‎package.json‎

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -118,6 +118,7 @@
118118
"devDependencies": {
119119
"babel-eslint":"^8.0.0",
120120
"babel-jest":"^21.0.2",
121+
"babel-plugin-import":"^1.6.2",
121122
"babel-plugin-inline-react-svg":"^0.4.0",
122123
"babel-plugin-ramda":"^1.4.3",
123124
"babel-plugin-react-intl":"^2.3.1",

‎utils/scripts/generators/component/stateless.js.hbs‎

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,9 +15,11 @@ import lang from './lang'
1515
{{/if}}
1616

1717
import { makeDebugger } from '../../utils/functions'
18+
/* eslint-disable no-unused-vars */
1819
const debug = makeDebugger('c:{{properCasename}}:index')
20+
/* eslint-enable no-unused-vars */
1921

20-
exportconst{{properCasename}}(props) => {
22+
const{{properCasename}} =(props) => {
2123
return (
2224
<div>
2325
{{#ifwantI18n}}
@@ -27,9 +29,10 @@ export const {{ properCase name }}(props) => {
2729
)
2830
}
2931

30-
3132
{{properCasename}}.propTypes = {
3233
// https://www.npmjs.com/package/prop-types
3334
};
3435

3536
{{properCasename}}.defaultProps = {};
37+
38+
export default{{properCasename}}

‎utils/scripts/generators/container/class.js.hbs‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,6 @@ import React from 'react'
88
import { inject, observer } from 'mobx-react'
99

1010
// import Link from 'next/link'
11-
1211
{{#ifwantMessages}}
1312
import { FormattedMessage } from 'react-intl'
1413
import messages from './messages'

‎utils/scripts/generators/store/store.js.hbs‎

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ import { types as t, getParent } from 'mobx-state-tree'
77
import R from 'ramda'
88

99
import { markStates, makeDebugger } from '../../utils/functions'
10-
1110
/* eslint-disable no-unused-vars */
1211
const debug = makeDebugger('S:{{properCasename}}')
1312
/* eslint-enable no-unused-vars */

‎yarn.lock‎

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -601,6 +601,13 @@ babel-helper-hoist-variables@^6.24.1:
601601
babel-runtime "^6.22.0"
602602
babel-types "^6.24.1"
603603

604+
babel-helper-module-imports@^7.0.0-beta.3:
605+
version "7.0.0-beta.3"
606+
resolved "http://r.cnpmjs.org/babel-helper-module-imports/download/babel-helper-module-imports-7.0.0-beta.3.tgz#e15764e3af9c8e11810c09f78f498a2bdc71585a"
607+
dependencies:
608+
babel-types "7.0.0-beta.3"
609+
lodash "^4.2.0"
610+
604611
babel-helper-optimise-call-expression@^6.24.1:
605612
version "6.24.1"
606613
resolved "http://r.cnpmjs.org/babel-helper-optimise-call-expression/download/babel-helper-optimise-call-expression-6.24.1.tgz#f7a13427ba9f73f8f4fa993c54a97882d1244257"
@@ -682,6 +689,12 @@ babel-plugin-check-es2015-constants@^6.22.0:
682689
dependencies:
683690
babel-runtime "^6.22.0"
684691

692+
babel-plugin-import@^1.6.2:
693+
version "1.6.2"
694+
resolved "http://r.cnpmjs.org/babel-plugin-import/download/babel-plugin-import-1.6.2.tgz#09a8ff8ec8e67e0034f97adf1d833b0d5b6e815e"
695+
dependencies:
696+
babel-helper-module-imports "^7.0.0-beta.3"
697+
685698
babel-plugin-inline-react-svg@^0.4.0:
686699
version "0.4.0"
687700
resolved "http://r.cnpmjs.org/babel-plugin-inline-react-svg/download/babel-plugin-inline-react-svg-0.4.0.tgz#940f77be66324f2c75a0fb64f287f459c40602a7"
@@ -1220,6 +1233,14 @@ babel-types@7.0.0-beta.0:
12201233
lodash "^4.2.0"
12211234
to-fast-properties "^2.0.0"
12221235

1236+
babel-types@7.0.0-beta.3:
1237+
version "7.0.0-beta.3"
1238+
resolved "http://r.cnpmjs.org/babel-types/download/babel-types-7.0.0-beta.3.tgz#cd927ca70e0ae8ab05f4aab83778cfb3e6eb20b4"
1239+
dependencies:
1240+
esutils "^2.0.2"
1241+
lodash "^4.2.0"
1242+
to-fast-properties "^2.0.0"
1243+
12231244
babel-types@^6.18.0, babel-types@^6.19.0, babel-types@^6.24.1, babel-types@^6.25.0, babel-types@^6.26.0:
12241245
version "6.26.0"
12251246
resolved "http://r.cnpmjs.org/babel-types/download/babel-types-6.26.0.tgz#a3b073f94ab49eb6fa55cd65227a334380632497"

0 commit comments

Comments
 (0)

[8]ページ先頭

©2009-2025 Movatter.jp