forked from ddrilling/asb_cloud_front
Отображение тултипа в TVD улучшено
This commit is contained in:
parent
c3b48d210c
commit
e3066b7619
@ -35,7 +35,7 @@ const tooltipRender = (data) => {
|
|||||||
<LineChartOutlined style={{ color: chart.color }} />
|
<LineChartOutlined style={{ color: chart.color }} />
|
||||||
<span>{chart.label}:</span>
|
<span>{chart.label}:</span>
|
||||||
</div>
|
</div>
|
||||||
{data.map((d, i) => {
|
{data.slice(0, 2).map((d, i) => {
|
||||||
const text = `${xFormat(chart.x(d))} :: ${yFormat(chart.y(d))}`
|
const text = `${xFormat(chart.x(d))} :: ${yFormat(chart.y(d))}`
|
||||||
|
|
||||||
const href = ['plan', 'fact'].includes(chart.key) && `/well/${d.idWell}/operations/${chart.key}/?selectedId=${d.id}`
|
const href = ['plan', 'fact'].includes(chart.key) && `/well/${d.idWell}/operations/${chart.key}/?selectedId=${d.id}`
|
||||||
@ -103,7 +103,7 @@ const domain = {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const plugins = {
|
const plugins = {
|
||||||
tooltip: { enabled: true, limit: 3, render: tooltipRender },
|
tooltip: { enabled: true, limit: 3, height: 200, render: tooltipRender },
|
||||||
menu: { enabled: false },
|
menu: { enabled: false },
|
||||||
legend: { enabled: true, offset: { x: 400 }, type: 'horizontal' },
|
legend: { enabled: true, offset: { x: 400 }, type: 'horizontal' },
|
||||||
cursor: { enabled: false }
|
cursor: { enabled: false }
|
||||||
|
Loading…
Reference in New Issue
Block a user