Skip to content

Commit

Permalink
fix(Statistic) Lint fix
Browse files Browse the repository at this point in the history
  • Loading branch information
layershifter authored and levithomason committed Aug 14, 2016
1 parent 746f025 commit b43d353
Show file tree
Hide file tree
Showing 11 changed files with 32 additions and 32 deletions.
10 changes: 5 additions & 5 deletions docs/app/Examples/views/Statistic/Content/Labels.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react'
import {Statistic} from 'stardust'
import { Statistic } from 'stardust'

const {Label, Value} = Statistic
const { Label, Value } = Statistic

const Labels = () => (
<div>
Expand All @@ -11,11 +11,11 @@ const Labels = () => (
</Statistic>

<Statistic>
<Value value='2,204'/>
<Label label='Views'/>
<Value value='2,204' />
<Label label='Views' />
</Statistic>

<Statistic value='2,204' label='Views'/>
<Statistic value='2,204' label='Views' />
</div>
)

Expand Down
20 changes: 10 additions & 10 deletions docs/app/Examples/views/Statistic/Content/Props.js
Original file line number Diff line number Diff line change
@@ -1,23 +1,23 @@
import React from 'react'
import {Statistic} from 'stardust'
import { Statistic } from 'stardust'

const items = [
{label: 'Saves', value: '22'},
{label: 'Signups', text: true, value: 'Three Thousand'},
{label: 'Flights', value: '5'},
{label: 'Team Members', value: '42'},
{ label: 'Saves', value: '22' },
{ label: 'Signups', text: true, value: 'Three Thousand' },
{ label: 'Flights', value: '5' },
{ label: 'Team Members', value: '42' },
]

const Props = () => (
<div>
<Statistic.Group>
<Statistic label='Saves' value='22'/>
<Statistic label='Signups' value='Three Thousand' text/>
<Statistic label='Flights' value='5'/>
<Statistic label='Team Members' value='42'/>
<Statistic label='Saves' value='22' />
<Statistic label='Signups' value='Three Thousand' text />
<Statistic label='Flights' value='5' />
<Statistic label='Team Members' value='42' />
</Statistic.Group>

<Statistic.Group items={items}/>
<Statistic.Group items={items} />
</div>
)

Expand Down
8 changes: 4 additions & 4 deletions docs/app/Examples/views/Statistic/Content/Values.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react'
import {Icon, Image, Statistic} from 'stardust'
import { Icon, Image, Statistic } from 'stardust'

const {Group, Label, Value} = Statistic
const { Group, Label, Value } = Statistic

// TODO: Update <Image> usage after <Image> will be updated to v1 API

Expand All @@ -22,15 +22,15 @@ const Values = () => (

<Statistic>
<Value>
<Icon name='plane'/>
<Icon name='plane' />
5
</Value>
<Label>Flights</Label>
</Statistic>

<Statistic>
<Value>
<Image src='http://semantic-ui.com/images/avatar/small/joe.jpg' className='circular inline'/>
<Image src='http://semantic-ui.com/images/avatar/small/joe.jpg' className='circular inline' />
42
</Value>
<Label>Team Members</Label>
Expand Down
2 changes: 1 addition & 1 deletion docs/app/Examples/views/Statistic/Content/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const Content = () => (
description='A statistic can contain a numeric, icon, image, or text value'
examplePath='views/Statistic/Content/Values'
/>
<ComponentExample examplePath='views/Statistic/Content/Props'/>
<ComponentExample examplePath='views/Statistic/Content/Props' />

<ComponentExample
title='Label'
Expand Down
2 changes: 1 addition & 1 deletion docs/app/Examples/views/Statistic/Types/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const Types = () => (
description='A statistic can display a value with a label above or below it'
examplePath='views/Statistic/Types/BottomLabel'
/>
<ComponentExample examplePath='views/Statistic/Types/TopLabel'/>
<ComponentExample examplePath='views/Statistic/Types/TopLabel' />

<ComponentExample
title='Statistic Group'
Expand Down
8 changes: 4 additions & 4 deletions docs/app/Examples/views/Statistic/Variations/EvenlyDivided.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
import React from 'react'
import {Icon, Image, Statistic} from 'stardust'
import { Icon, Image, Statistic } from 'stardust'

const {Group, Label, Value} = Statistic
const { Group, Label, Value } = Statistic

const EvenlyDivided = () => (
<Group widths='four'>
Expand All @@ -20,15 +20,15 @@ const EvenlyDivided = () => (

<Statistic>
<Value>
<Icon name='plane'/>
<Icon name='plane' />
5
</Value>
<Label>Flights</Label>
</Statistic>

<Statistic>
<Value>
<Image src='http://semantic-ui.com/images/avatar/small/joe.jpg' className='circular inline'/>
<Image src='http://semantic-ui.com/images/avatar/small/joe.jpg' className='circular inline' />
42
</Value>
<Label>Team Members</Label>
Expand Down
4 changes: 2 additions & 2 deletions docs/app/Examples/views/Statistic/Variations/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ const Variations = () => (
description='A statistic can present its measurement horizontally'
examplePath='views/Statistic/Variations/Horizontal'
/>
<ComponentExample examplePath='views/Statistic/Variations/HorizontalGroup'/>
<ComponentExample examplePath='views/Statistic/Variations/HorizontalGroup' />

<ComponentExample
title='Colored'
Expand Down Expand Up @@ -41,7 +41,7 @@ const Variations = () => (
description='A statistic can vary in size'
examplePath='views/Statistic/Variations/Size'
/>
<ComponentExample examplePath='views/Statistic/Variations/SizeDivided'/>
<ComponentExample examplePath='views/Statistic/Variations/SizeDivided' />
</ExampleSection>
)

Expand Down
4 changes: 2 additions & 2 deletions docs/app/Examples/views/Statistic/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,8 @@ import Variations from './Variations'

const StatisticExamples = () => (
<div>
<Types/>
<Content/>
<Types />
<Content />
<Variations />
</div>
)
Expand Down
2 changes: 1 addition & 1 deletion src/views/Statistic/Statistic.js
Original file line number Diff line number Diff line change
Expand Up @@ -35,7 +35,7 @@ function Statistic(props) {
return (
<div {...rest} className={classes}>
<StatisticValue text={text} value={value} />
<StatisticLabel label={label}/>
<StatisticLabel label={label} />
</div>
)
}
Expand Down
2 changes: 1 addition & 1 deletion test/specs/views/Stastistic/StatisticLabel-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,6 @@ describe('StatisticLabel', () => {
it('renders text with label prop', () => {
const text = faker.hacker.phrase()

shallow(<StatisticLabel label={text}/>).should.contain.text(text)
shallow(<StatisticLabel label={text} />).should.contain.text(text)
})
})
2 changes: 1 addition & 1 deletion test/specs/views/Stastistic/StatisticValue-test.js
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ describe('StatisticValue', () => {
it('renders text with label prop', () => {
const text = faker.hacker.phrase()

shallow(<StatisticValue value={text}/>).should.contain.text(text)
shallow(<StatisticValue value={text} />).should.contain.text(text)
})
})

0 comments on commit b43d353

Please sign in to comment.