Skip to content

Commit

Permalink
Init statistics base screen
Browse files Browse the repository at this point in the history
  • Loading branch information
NikolaySimakov committed Aug 30, 2023
1 parent 3f3f205 commit 12c342c
Showing 1 changed file with 36 additions and 0 deletions.
36 changes: 36 additions & 0 deletions src/screens/statistics.js
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
import React, { Component } from 'react'
import { StyleSheet, ScrollView, Text, View } from 'react-native'
import PieChart from 'react-native-pie-chart'

export default function TestChart() {
const widthAndHeight = 250
const series = [123, 321, 123, 789, 537]
const sliceColor = ['#fbd203', '#ffb300', '#ff9100', '#ff6c00', '#ff3c00']

return (
<ScrollView style={{ flex: 1 }}>
<View style={styles.container}>
<Text style={styles.title}>Наиболее частые категории</Text>
<PieChart
widthAndHeight={widthAndHeight}
series={series}
sliceColor={sliceColor}
coverRadius={0.45}
coverFill={'#FFF'}
/>
</View>
</ScrollView>
)
}

const styles = StyleSheet.create({
container: {
flex: 1,
alignItems: 'center',
backgroundColor: 'white',
},
title: {
fontSize: 24,
margin: 10,
},
})

0 comments on commit 12c342c

Please sign in to comment.