Skip to content

Commit 987f060

Browse files
committed
fix: sankey color name
1 parent 649866b commit 987f060

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

src/components/Tooltip/DefaultContent.tsx

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -151,11 +151,13 @@ export const DefaultContent = ({hovered, xAxis, yAxis}: Props) => {
151151
case 'sankey': {
152152
const {target, data: source} = seriesItem as TooltipDataChunkSankey;
153153
const value = source.links.find((d) => d.name === target?.name)?.value;
154-
const color = source.color;
155154

156155
return (
157156
<div key={id} className={b('content-row')}>
158-
<div className={b('color')} style={{backgroundColor: color}} />
157+
<div
158+
className={b('color')}
159+
style={{backgroundColor: source.color}}
160+
/>
159161
<div style={{display: 'flex', gap: 8, verticalAlign: 'center'}}>
160162
{source.name} <span></span> {target?.name}: {value}
161163
</div>

0 commit comments

Comments
 (0)