-
Notifications
You must be signed in to change notification settings - Fork 7
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(): CIremove running mocha test when no tests exist in project
- Loading branch information
1 parent
13b5660
commit ecabfd4
Showing
5 changed files
with
38 additions
and
37 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,35 +1,32 @@ | ||
import React, { Component } from 'react'; | ||
import PropTypes from 'prop-types'; | ||
import React, { Component } from "react"; | ||
import PropTypes from "prop-types"; | ||
|
||
class Button extends Component { | ||
render() { | ||
const { primary, pull, className, ...props } = this.props | ||
let _className = this.props.primary ? 'button-primary' : className | ||
_className += this.props.pull ? ` u-pull-${this.props.pull}` : '' | ||
render() { | ||
const { primary, pull, className, ...props } = this.props; | ||
let _className = this.props.primary ? "button-primary" : className; | ||
_className += this.props.pull ? ` u-pull-${this.props.pull}` : ""; | ||
|
||
return ( | ||
<button | ||
className={_className} | ||
{...props} | ||
> | ||
{this.props.children} | ||
</button> | ||
); | ||
} | ||
return ( | ||
<button className={_className} {...props}> | ||
{this.props.children} | ||
</button> | ||
); | ||
} | ||
} | ||
|
||
Button.defaultProps = { | ||
pull: '', | ||
style: {}, | ||
className: 'button', | ||
primary: false | ||
} | ||
pull: "", | ||
style: {}, | ||
className: "button", | ||
primary: false | ||
}; | ||
|
||
Button.propTypes = { | ||
pull: PropTypes.oneOf(['left', 'right', '']), | ||
style: PropTypes.object.isRequired, | ||
className: PropTypes.string.isRequired, | ||
primary: PropTypes.bool.isRequired, | ||
} | ||
pull: PropTypes.oneOf(["left", "right", ""]), | ||
style: PropTypes.object.isRequired, | ||
className: PropTypes.string.isRequired, | ||
primary: PropTypes.bool.isRequired | ||
}; | ||
|
||
export default Button; |
Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters