echarts icon indicating copy to clipboard operation
echarts copied to clipboard

[Bug] How to make the hierarchy of emphasis in series above the axisPointer, while the axisPointer is above the series.areaStyle

Open aichitudou0823 opened this issue 8 months ago • 4 comments

Version

5.4.3

Link to Minimal Reproduction

see code

Steps to Reproduce

axisPointer: { type: 'line', lineStyle: { color: colorMap['fill-4-bg'], width: 2, type: 'solid', }, }, series: [ { type: 'line', smooth: true, symbol: 'none', symbolSize: 0, emphasis: { symbolSize: 10, itemStyle: { color: colorMap['main-1-cl'], borderWidth: 2, borderColor: colorMap['main-1-cl'], }, areaStyle: { color: { type: 'linear', x: 0, y: 0, x2: 0, y2: 1, colorStops: [ { offset: 0, color: colorMap['main-1-cl'] }, { offset: 1, color: 'transparent' }, ], }, }, }, ]

Current Behavior

How to make the hierarchy of emphasis in series above the axisPointer, while the axisPointer is above the series.areaStyle

Expected Behavior

How to make the hierarchy of emphasis in series above the axisPointer, while the axisPointer is above the series.areaStyle

Environment

- OS:macOS
- Browser:Chrome 145
- Framework:vue 2

Any additional comments?

Version

5.4.3

Link to Minimal Reproduction

see code

Steps to Reproduce

axisPointer: { type: 'line', lineStyle: { color: colorMap['fill-4-bg'], width: 2, type: 'solid', }, }, series: [ { type: 'line', smooth: true, symbol: 'none', symbolSize: 0, emphasis: { symbolSize: 10, itemStyle: { color: colorMap['main-1-cl'], borderWidth: 2, borderColor: colorMap['main-1-cl'], }, areaStyle: { color: { type: 'linear', x: 0, y: 0, x2: 0, y2: 1, colorStops: [ { offset: 0, color: colorMap['main-1-cl'] }, { offset: 1, color: 'transparent' }, ], }, }, }, ]

How to make the hierarchy of emphasis in series above the axisPointer, while the axisPointer is above the series.areaStyle

Current Behavior

How to make the hierarchy of emphasis in series above the axisPointer, while the axisPointer is above the series.areaStyle

Expected Behavior

How to make the hierarchy of emphasis in series above the axisPointer, while the axisPointer is above the series.areaStyle

Environment

- OS:macOS
- Browser:Chrome 145
- Framework:vue 2

Any additional comments?

No response

aichitudou0823 avatar Mar 20 '26 02:03 aichitudou0823

Like this ?

https://github.com/user-attachments/assets/106b7454-4fa0-4dc3-80f8-9111054e0ed5

helgasoft avatar Mar 20 '26 19:03 helgasoft

This seems like a z-index/layering issue.

axisPointer is rendered in a different layer, so its stacking can't be fully controlled with z/zlevel relative to series.

Is this expected behavior?

dilipkumar6306316-art avatar Mar 24 '26 13:03 dilipkumar6306316-art

Thanks for the details! It does seem like a layering issue with axisPointer being on a separate layer. I’ll look further into how the z-index can be managed between the series and axisPointer. If I find a solution, I’ll share it here.

Appreciate the input!

On Tue, Mar 24, 2026, 8:27 AM Dilip Kumar @.***> wrote:

dilipkumar6306316-art left a comment (apache/echarts#21549) https://github.com/apache/echarts/issues/21549#issuecomment-4118301801

This seems like a z-index/layering issue.

axisPointer is rendered in a different layer, so its stacking can't be fully controlled with z/zlevel relative to series.

Is this expected behavior?

— Reply to this email directly, view it on GitHub https://github.com/apache/echarts/issues/21549?email_source=notifications&email_token=B74GC3EWMDZPAF3VHSBODR34SKENDA5CNFSNUABFM5UWIORPF5TWS5BNNB2WEL2JONZXKZKDN5WW2ZLOOQXTIMJRHAZTAMJYGAY2M4TFMFZW63VKON2WE43DOJUWEZLEUVSXMZLOOSWGM33PORSXEX3DNRUWG2Y#issuecomment-4118301801, or unsubscribe https://github.com/notifications/unsubscribe-auth/B74GC3C776573WCVEYDTMB34SKENDAVCNFSM6AAAAACWYUHBFSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHM2DCMJYGMYDCOBQGE . You are receiving this because you are subscribed to this thread.Message ID: @.***>

Use two series, the first series: only responsible for displaying areaStyle (bottom layer, z=1), // the second series: only responsible for displaying lines and symbols (top layer, z=3)

aichitudou0823 avatar Jun 01 '26 02:06 aichitudou0823