Skip to content

Commit 64a4b94

Browse files
author
Matty Goo
authored
feature(top app bar): create new top app bar component (material-components#13)
1 parent 98bcdfe commit 64a4b94

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

61 files changed

+7352
-3723
lines changed

.babelrc

+7-2
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,10 @@
11
{
22
"presets": [
3-
"es2015"
4-
]
3+
"es2015",
4+
"react"
5+
],
6+
"plugins": [
7+
"transform-class-properties",
8+
"transform-object-rest-spread"
9+
],
510
}

.eslintignore

+1
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
**/node_modules

.eslintrc.yml

+4-3
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,14 @@
1-
extends:
1+
extends:
22
- google
33
- plugin:react/recommended
44
parser: babel-eslint
5-
plugins:
5+
plugins:
66
- react
7-
rules:
7+
rules:
88
strict: 0
99
require-jsdoc: off
1010
valid-jsdoc: off
1111
switch-colon-spacing: 0
1212
max-len: [error, 120]
1313
indent: [error, 2, {"SwitchCase":1}]
14+
no-invalid-this: off

.gitignore

+2-1
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,5 @@ node_modules
55
*.iml
66
*.snapshot.png
77
*.diff.png
8-
key.json
8+
key.json
9+
*.golden.png

.travis.yml

+9-4
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,13 @@ matrix:
1313
include:
1414
- node_js: 8
1515
env: TEST_SUITE=unit
16-
install: npm i
17-
script: npm run test:unit-ci
16+
install:
17+
- npm i
18+
- npm i -g codecov
19+
script:
20+
- npm run test:unit-ci
21+
after_success:
22+
- codecov
1823

1924
- node_js: 8
2025
env: TEST_SUITE=lint
@@ -24,7 +29,7 @@ matrix:
2429
- node_js: 8
2530
env: TEST_SUITE=screenshots
2631
install: npm i
27-
script:
32+
script:
2833
- ./test/screenshot/start.sh
29-
- sleep 10s
34+
- sleep 60s
3035
- npm run test:image-diff

README.md

+3
Original file line numberDiff line numberDiff line change
@@ -1,2 +1,5 @@
1+
[![Build Status](https://img.shields.io/travis/material-components/material-components-web-react/master.svg)](https://travis-ci.org/material-components/material-components-web-react/)
2+
[![codecov](https://codecov.io/gh/material-components/material-components-web-react/branch/master/graph/badge.svg)](https://codecov.io/gh/material-components/material-components-web-react)
3+
14
# material-components-web-react
25
Material Components for React (MDC React)

docs/guidelines.md

+25
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,25 @@
1+
# General Guidelines
2+
3+
## Integrating with Components
4+
5+
Some of our components accept a `React.Component` as a prop. If you decide to build a component, it will more than likely need some additional feature or attributes added to operate correctly.
6+
7+
### Classnames
8+
9+
Pass the prop `className` to the className prop on the parent element. As an example please see the [MaterialIcon Component](../packages/material-icon/index.js) or the example below:
10+
11+
12+
```js
13+
class Dog extends React.Component {
14+
render() {
15+
const {className = ''} = this.props;
16+
const allClasses = `${className} dog-class`;
17+
18+
return (
19+
<div className={allClasses}>
20+
Woof
21+
</div>
22+
);
23+
}
24+
};
25+
```

lerna.json

+12
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
{
2+
"lerna": "2.9.0",
3+
"command": {
4+
"bootstrap": {
5+
"npmClientArgs": ["--no-package-lock"]
6+
}
7+
},
8+
"packages": [
9+
"packages/*"
10+
],
11+
"version": "0.0.0"
12+
}

0 commit comments

Comments
 (0)