diff --git a/web/components/charts/generic-charts.tsx b/web/components/charts/generic-charts.tsx
index a34803b4..d16de1cb 100644
--- a/web/components/charts/generic-charts.tsx
+++ b/web/components/charts/generic-charts.tsx
@@ -15,7 +15,7 @@ import {
import { range } from 'lodash'
import dayjs from 'dayjs'
-import { SVGChart, LinePath, AreaPath } from './helpers'
+import { SVGChart, AreaPath, AreaWithTopStroke } from './helpers'
import { formatLargeNumber } from 'common/util/format'
import { useEvent } from 'web/hooks/use-event'
@@ -90,21 +90,13 @@ export const SingleValueDistributionChart = (props: {
className="pointer-events-none absolute z-10 whitespace-pre rounded border-2 border-black bg-slate-600/75 p-2 text-white"
/>
(
data: P[]
px: number | ((p: P) => number)
py: number | ((p: P) => number)
- curve: CurveFactory
+ curve?: CurveFactory
} & SVGProps (px, py).curve(curve)
+ const d3Line = line (px, py).curve(curve ?? curveStepAfter)
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
return (
px: number | ((p: P) => number)
py0: number | ((p: P) => number)
py1: number | ((p: P) => number)
- curve: CurveFactory
+ curve?: CurveFactory
} & SVGProps (px, py0, py1).curve(curve)
+ const d3Area = area (px, py0, py1).curve(curve ?? curveStepAfter)
// eslint-disable-next-line @typescript-eslint/no-non-null-assertion
return (props: {
+ color: string
+ data: P[]
+ px: number | ((p: P) => number)
+ py0: number | ((p: P) => number)
+ py1: number | ((p: P) => number)
+ curve?: CurveFactory
+}) => {
+ const { color, data, px, py0, py1, curve } = props
+ return (
+