Testing multiple choice line charts
This commit is contained in:
parent
1d948821ca
commit
b1d924614f
|
@ -87,7 +87,7 @@ export const AnswersGraph = memo(function AnswersGraph(props: {
|
||||||
>
|
>
|
||||||
<ResponsiveLine
|
<ResponsiveLine
|
||||||
data={data}
|
data={data}
|
||||||
yScale={{ min: 0, max: 100, type: 'linear', stacked: true }}
|
yScale={{ min: 0, max: 100, type: 'linear' }}
|
||||||
yFormat={formatPercent}
|
yFormat={formatPercent}
|
||||||
gridYValues={yTickValues}
|
gridYValues={yTickValues}
|
||||||
axisLeft={{
|
axisLeft={{
|
||||||
|
@ -107,20 +107,11 @@ export const AnswersGraph = memo(function AnswersGraph(props: {
|
||||||
format: (time) =>
|
format: (time) =>
|
||||||
formatTime(+time, multiYear, lessThanAWeek, includeMinute),
|
formatTime(+time, multiYear, lessThanAWeek, includeMinute),
|
||||||
}}
|
}}
|
||||||
colors={[
|
colors={{ scheme: 'category10' }}
|
||||||
'#fca5a5', // red-300
|
|
||||||
'#a5b4fc', // indigo-300
|
|
||||||
'#86efac', // green-300
|
|
||||||
'#fef08a', // yellow-200
|
|
||||||
'#fdba74', // orange-300
|
|
||||||
'#c084fc', // purple-400
|
|
||||||
]}
|
|
||||||
pointSize={0}
|
pointSize={0}
|
||||||
curve="stepAfter"
|
curve="stepAfter"
|
||||||
enableSlices="x"
|
enableSlices="x"
|
||||||
enableGridX={!!width && width >= 800}
|
enableGridX={!!width && width >= 800}
|
||||||
enableArea
|
|
||||||
areaOpacity={1}
|
|
||||||
margin={{ top: 20, right: 20, bottom: 25, left: 40 }}
|
margin={{ top: 20, right: 20, bottom: 25, left: 40 }}
|
||||||
legends={[
|
legends={[
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue
Block a user