Prettify chart files
This commit is contained in:
@@ -7,24 +7,22 @@ import Tick from './tick'
|
||||
import { getTickList } from '../helpers/chart'
|
||||
|
||||
const TickList = ({ height }) => {
|
||||
|
||||
return (
|
||||
<View style={[styles.container, height]}>
|
||||
{
|
||||
getTickList(height)
|
||||
.map(({ isBold, label, position, shouldShowLabel, tickHeight}) => {
|
||||
return (
|
||||
<Tick
|
||||
height={tickHeight}
|
||||
isBold={isBold}
|
||||
key={label}
|
||||
label={label}
|
||||
shouldShowLabel={shouldShowLabel}
|
||||
yPosition={position}
|
||||
/>
|
||||
)
|
||||
})
|
||||
}
|
||||
{getTickList(height).map(
|
||||
({ isBold, label, position, shouldShowLabel, tickHeight }) => {
|
||||
return (
|
||||
<Tick
|
||||
height={tickHeight}
|
||||
isBold={isBold}
|
||||
key={label}
|
||||
label={label}
|
||||
shouldShowLabel={shouldShowLabel}
|
||||
yPosition={position}
|
||||
/>
|
||||
)
|
||||
}
|
||||
)}
|
||||
</View>
|
||||
)
|
||||
}
|
||||
@@ -35,8 +33,8 @@ TickList.propTypes = {
|
||||
|
||||
const styles = StyleSheet.create({
|
||||
container: {
|
||||
flex: 1
|
||||
}
|
||||
flex: 1,
|
||||
},
|
||||
})
|
||||
|
||||
export default TickList
|
||||
|
||||
Reference in New Issue
Block a user