Skip to content
This repository has been archived by the owner on Aug 18, 2020. It is now read-only.

Commit

Permalink
fix(components): accommodate linter
Browse files Browse the repository at this point in the history
  • Loading branch information
cdaringe committed Dec 7, 2017
1 parent b9f3bdf commit 65c28ac
Show file tree
Hide file tree
Showing 7 changed files with 29 additions and 35 deletions.
17 changes: 8 additions & 9 deletions src/components/native/LargeCard/LargeCard.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -13,15 +13,6 @@ import LargeCardStat from './LargeCardStat'
import LargeCardTitle from './LargeCardTitle'

class LargeCard extends React.Component {
static Action = LargeCardAction;
static Close = LargeCardClose;
static Gutter = LargeCardGutter;
static Content = LargeCardContent;
static KeyValue = LargeCardKeyValue;
static RecentList = LargeCardRecentList;
static Title = LargeCardTitle;
static Stat = LargeCardStat;

render () {
const externalAttributes = filterAttributesFromProps(this.props)
return (
Expand All @@ -39,6 +30,14 @@ class LargeCard extends React.Component {
)
}
}
LargeCard.Action = LargeCardAction
LargeCard.Close = LargeCardClose
LargeCard.Gutter = LargeCardGutter
LargeCard.Content = LargeCardContent
LargeCard.KeyValue = LargeCardKeyValue
LargeCard.RecentList = LargeCardRecentList
LargeCard.Title = LargeCardTitle
LargeCard.Stat = LargeCardStat

LargeCard.defaultProps = {
className: '',
Expand Down
11 changes: 5 additions & 6 deletions src/components/native/LeftNav/LeftNav.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -4,12 +4,6 @@ import LeftNavMenuItem from './LeftNavMenuItem'
import '../../../styles/components/left-nav.css'

class LeftNav extends React.Component {
static MenuItem = LeftNavMenuItem
static propTypes = {
/** One of: MenuItem, Node */
children: PropTypes.node
}

render () {
return (
<nav className='nav__left ' {...this.props}>
Expand All @@ -18,6 +12,11 @@ class LeftNav extends React.Component {
)
}
}
LeftNav.MenuItem = LeftNavMenuItem
LeftNav.propTypes = {
/** One of: MenuItem, Node */
children: PropTypes.node
}

LeftNav.defaultProps = {

Expand Down
11 changes: 5 additions & 6 deletions src/components/native/MicroCard/MicroCard.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,11 +10,6 @@ import '../../../styles/components/micro-card.css'
import filterAttributesFromProps from '../../../util/externalAttributeFilter'

class MicroCard extends React.Component {
static Gutter = MicroCardGutter;
static Action = MicroCardAction;
static Favorite = MicroCardFavorite;
static Content = MicroCardContent;
static Count = MicroCardCount;
render () {
const externalAttributes = filterAttributesFromProps(this.props)
return (
Expand All @@ -30,7 +25,11 @@ class MicroCard extends React.Component {
)
}
}

MicroCard.Gutter = MicroCardGutter
MicroCard.Action = MicroCardAction
MicroCard.Favorite = MicroCardFavorite
MicroCard.Content = MicroCardContent
MicroCard.Count = MicroCardCount
MicroCard.propTypes = {
cardContent: PropTypes.object
}
Expand Down
5 changes: 2 additions & 3 deletions src/components/native/MicroCard/MicroCardContent.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@ import MicroCardContentMessage from './MicroCardContentMessage'
import filterAttributesFromProps from '../../../util/externalAttributeFilter'

class MicroCardContent extends React.Component {
static Status = MicroCardContentStatus;
static Message = MicroCardContentMessage;

render () {
const externalAttributes = filterAttributesFromProps(this.props)
return (
Expand All @@ -23,6 +20,8 @@ class MicroCardContent extends React.Component {
)
}
}
MicroCardContent.Status = MicroCardContentStatus
MicroCardContent.Message = MicroCardContentMessage

MicroCardContent.defaultProps = {
title: ''
Expand Down
11 changes: 5 additions & 6 deletions src/components/native/ThinCard/ThinCard.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,6 @@ import ThinCardWidget from './ThinCardWidget'
import ThinCardDrawer from './ThinCardDrawer'

class ThinCard extends React.Component {
static Title = ThinCardTitle
static PrimaryAction = ThinCardPrimaryAction
static ActionButton = ThinCardActionButton
static Widget = ThinCardWidget
static Drawer = ThinCardDrawer

render () {
let borderClass = ''
if (this.props.noBorder) {
Expand Down Expand Up @@ -44,6 +38,11 @@ class ThinCard extends React.Component {
)
}
}
ThinCard.Title = ThinCardTitle
ThinCard.PrimaryAction = ThinCardPrimaryAction
ThinCard.ActionButton = ThinCardActionButton
ThinCard.Widget = ThinCardWidget
ThinCard.Drawer = ThinCardDrawer
ThinCard.defaultProps = {
folder: true,
noBorder: false
Expand Down
5 changes: 2 additions & 3 deletions src/components/native/ThinCard/ThinCardWidget.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -6,9 +6,6 @@ import ThinCardWidgetLabel from './ThinCardWidgetLabel'
import ThinCardWidgetValue from './ThinCardWidgetValue'

class ThinCardWidget extends React.Component {
static Label = ThinCardWidgetLabel
static Value = ThinCardWidgetValue

render () {
let borderClass = ''
if (this.props.borderLeft) {
Expand All @@ -34,6 +31,8 @@ class ThinCardWidget extends React.Component {
)
}
}
ThinCardWidget.Label = ThinCardWidgetLabel
ThinCardWidget.Value = ThinCardWidgetValue

ThinCardWidget.defaultProps = {
borderLeft: false,
Expand Down
4 changes: 2 additions & 2 deletions src/components/native/TopNav/TopNav.jsx
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ import LocalTime from './TopNavLocalTime'
import '../../../styles/components/top-nav.css'

class TopNav extends React.Component {
static Content = TopNavContent;
static LocalTime = LocalTime;
render () {
return (
<div className='nav__main clearfix'>
Expand All @@ -15,6 +13,8 @@ class TopNav extends React.Component {
)
}
}
TopNav.Content = TopNavContent
TopNav.LocalTime = LocalTime

TopNav.propTypes = {
/** One of: Content, LocalTime, Node */
Expand Down

0 comments on commit 65c28ac

Please sign in to comment.